]> Pileus Git - ~andy/gtk/blob - gtk/gtkprogress.c
Pay attention to tags that turn invisibility off as well as tags that turn
[~andy/gtk] / gtk / gtkprogress.c
1 /* GTK - The GIMP Toolkit
2  * Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald
3  *
4  * This library is free software; you can redistribute it and/or
5  * modify it under the terms of the GNU Lesser General Public
6  * License as published by the Free Software Foundation; either
7  * version 2 of the License, or (at your option) any later version.
8  *
9  * This library is distributed in the hope that it will be useful,
10  * but WITHOUT ANY WARRANTY; without even the implied warranty of
11  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
12  * Lesser General Public License for more details.
13  *
14  * You should have received a copy of the GNU Lesser General Public
15  * License along with this library; if not, write to the
16  * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
17  * Boston, MA 02111-1307, USA.
18  */
19
20 /*
21  * Modified by the GTK+ Team and others 1997-2000.  See the AUTHORS
22  * file for a list of people on the GTK+ Team.  See the ChangeLog
23  * files for a list of changes.  These files are distributed with
24  * GTK+ at ftp://ftp.gtk.org/pub/gtk/. 
25  */
26
27 #include <config.h>
28 #include <math.h>
29 #include <string.h>
30 #undef GTK_DISABLE_DEPRECATED
31 #include "gtkprogress.h" 
32 #include "gtkprivate.h" 
33 #include "gtkintl.h"
34 #include "gtkalias.h"
35
36 #define EPSILON  1e-5
37 #define DEFAULT_FORMAT "%P %%"
38
39 enum {
40   PROP_0,
41   PROP_ACTIVITY_MODE,
42   PROP_SHOW_TEXT,
43   PROP_TEXT_XALIGN,
44   PROP_TEXT_YALIGN
45 };
46
47
48 static void gtk_progress_set_property    (GObject          *object,
49                                           guint             prop_id,
50                                           const GValue     *value,
51                                           GParamSpec       *pspec);
52 static void gtk_progress_get_property    (GObject          *object,
53                                           guint             prop_id,
54                                           GValue           *value,
55                                           GParamSpec       *pspec);
56 static void gtk_progress_destroy         (GtkObject        *object);
57 static void gtk_progress_finalize        (GObject          *object);
58 static void gtk_progress_realize         (GtkWidget        *widget);
59 static gboolean gtk_progress_expose      (GtkWidget        *widget,
60                                           GdkEventExpose   *event);
61 static void gtk_progress_size_allocate   (GtkWidget        *widget,
62                                           GtkAllocation    *allocation);
63 static void gtk_progress_create_pixmap   (GtkProgress      *progress);
64 static void gtk_progress_value_changed   (GtkAdjustment    *adjustment,
65                                           GtkProgress      *progress);
66 static void gtk_progress_changed         (GtkAdjustment    *adjustment,
67                                           GtkProgress      *progress);
68
69 G_DEFINE_TYPE (GtkProgress, gtk_progress, GTK_TYPE_WIDGET)
70
71 static void
72 gtk_progress_class_init (GtkProgressClass *class)
73 {
74   GObjectClass *gobject_class = G_OBJECT_CLASS (class);
75   GtkObjectClass *object_class;
76   GtkWidgetClass *widget_class;
77
78   object_class = (GtkObjectClass *) class;
79   widget_class = (GtkWidgetClass *) class;
80
81   gobject_class->finalize = gtk_progress_finalize;
82
83   gobject_class->set_property = gtk_progress_set_property;
84   gobject_class->get_property = gtk_progress_get_property;
85   object_class->destroy = gtk_progress_destroy;
86
87   widget_class->realize = gtk_progress_realize;
88   widget_class->expose_event = gtk_progress_expose;
89   widget_class->size_allocate = gtk_progress_size_allocate;
90
91   /* to be overridden */
92   class->paint = NULL;
93   class->update = NULL;
94   class->act_mode_enter = NULL;
95   
96   g_object_class_install_property (gobject_class,
97                                    PROP_ACTIVITY_MODE,
98                                    g_param_spec_boolean ("activity-mode",
99                                                          P_("Activity mode"),
100                                                          P_("If TRUE, the GtkProgress is in activity mode, meaning that it signals "
101                                                             "something is happening, but not how much of the activity is finished. "
102                                                             "This is used when you're doing something but don't know how long it will take."),
103                                                          FALSE,
104                                                          GTK_PARAM_READWRITE));
105   g_object_class_install_property (gobject_class,
106                                    PROP_SHOW_TEXT,
107                                    g_param_spec_boolean ("show-text",
108                                                          P_("Show text"),
109                                                          P_("Whether the progress is shown as text."),
110                                                          FALSE,
111                                                          GTK_PARAM_READWRITE));
112   g_object_class_install_property (gobject_class,
113                                    PROP_TEXT_XALIGN,
114                                    g_param_spec_float ("text-xalign",
115                                                        P_("Text x alignment"),
116                                                        P_("The horizontal text alignment, from 0 (left) to 1 (right). Reversed for RTL layouts."),
117                                                        0.0, 1.0, 0.5,
118                                                        GTK_PARAM_READWRITE));  
119   g_object_class_install_property (gobject_class,
120                                    PROP_TEXT_YALIGN,
121                                    g_param_spec_float ("text-yalign",
122                                                        P_("Text y alignment"),
123                                                        P_("The vertical text alignment, from 0 (top) to 1 (bottom)."),
124                                                        0.0, 1.0, 0.5,
125                                                        GTK_PARAM_READWRITE));
126 }
127
128 static void
129 gtk_progress_set_property (GObject      *object,
130                            guint         prop_id,
131                            const GValue *value,
132                            GParamSpec   *pspec)
133 {
134   GtkProgress *progress;
135   
136   progress = GTK_PROGRESS (object);
137
138   switch (prop_id)
139     {
140     case PROP_ACTIVITY_MODE:
141       gtk_progress_set_activity_mode (progress, g_value_get_boolean (value));
142       break;
143     case PROP_SHOW_TEXT:
144       gtk_progress_set_show_text (progress, g_value_get_boolean (value));
145       break;
146     case PROP_TEXT_XALIGN:
147       gtk_progress_set_text_alignment (progress,
148                                        g_value_get_float (value),
149                                        progress->y_align);
150       break;
151     case PROP_TEXT_YALIGN:
152       gtk_progress_set_text_alignment (progress,
153                                        progress->x_align,
154                                        g_value_get_float (value));
155       break;
156     default:
157       G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
158       break;
159     }
160 }
161
162 static void
163 gtk_progress_get_property (GObject      *object,
164                            guint         prop_id,
165                            GValue       *value,
166                            GParamSpec   *pspec)
167 {
168   GtkProgress *progress;
169   
170   progress = GTK_PROGRESS (object);
171
172   switch (prop_id)
173     {
174     case PROP_ACTIVITY_MODE:
175       g_value_set_boolean (value, (progress->activity_mode != FALSE));
176       break;
177     case PROP_SHOW_TEXT:
178       g_value_set_boolean (value, (progress->show_text != FALSE));
179       break;
180     case PROP_TEXT_XALIGN:
181       g_value_set_float (value, progress->x_align);
182       break;
183     case PROP_TEXT_YALIGN:
184       g_value_set_float (value, progress->y_align);
185       break;
186     default:
187       G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
188       break;
189     }
190 }
191
192 static void
193 gtk_progress_init (GtkProgress *progress)
194 {
195   progress->adjustment = NULL;
196   progress->offscreen_pixmap = NULL;
197   progress->format = g_strdup (DEFAULT_FORMAT);
198   progress->x_align = 0.5;
199   progress->y_align = 0.5;
200   progress->show_text = FALSE;
201   progress->activity_mode = FALSE;
202   progress->use_text_format = TRUE;
203 }
204
205 static void
206 gtk_progress_realize (GtkWidget *widget)
207 {
208   GtkProgress *progress;
209   GdkWindowAttr attributes;
210   gint attributes_mask;
211
212   g_return_if_fail (GTK_IS_PROGRESS (widget));
213
214   progress = GTK_PROGRESS (widget);
215   GTK_WIDGET_SET_FLAGS (widget, GTK_REALIZED);
216
217   attributes.window_type = GDK_WINDOW_CHILD;
218   attributes.x = widget->allocation.x;
219   attributes.y = widget->allocation.y;
220   attributes.width = widget->allocation.width;
221   attributes.height = widget->allocation.height;
222   attributes.wclass = GDK_INPUT_OUTPUT;
223   attributes.visual = gtk_widget_get_visual (widget);
224   attributes.colormap = gtk_widget_get_colormap (widget);
225   attributes.event_mask = gtk_widget_get_events (widget);
226   attributes.event_mask |= GDK_EXPOSURE_MASK;
227
228   attributes_mask = GDK_WA_X | GDK_WA_Y | GDK_WA_VISUAL | GDK_WA_COLORMAP;
229
230   widget->window = gdk_window_new (gtk_widget_get_parent_window (widget),
231                                    &attributes, attributes_mask);
232   gdk_window_set_user_data (widget->window, progress);
233
234   widget->style = gtk_style_attach (widget->style, widget->window);
235   gtk_style_set_background (widget->style, widget->window, GTK_STATE_ACTIVE);
236
237   gtk_progress_create_pixmap (progress);
238 }
239
240 static void
241 gtk_progress_destroy (GtkObject *object)
242 {
243   GtkProgress *progress;
244
245   g_return_if_fail (GTK_IS_PROGRESS (object));
246
247   progress = GTK_PROGRESS (object);
248
249   if (progress->adjustment)
250     {
251       g_signal_handlers_disconnect_by_func (progress->adjustment,
252                                             gtk_progress_value_changed,
253                                             progress);
254       g_signal_handlers_disconnect_by_func (progress->adjustment,
255                                             gtk_progress_changed,
256                                             progress);
257       g_object_unref (progress->adjustment);
258       progress->adjustment = NULL;
259     }
260
261   GTK_OBJECT_CLASS (gtk_progress_parent_class)->destroy (object);
262 }
263
264 static void
265 gtk_progress_finalize (GObject *object)
266 {
267   GtkProgress *progress;
268
269   g_return_if_fail (GTK_IS_PROGRESS (object));
270
271   progress = GTK_PROGRESS (object);
272
273   if (progress->offscreen_pixmap)
274     g_object_unref (progress->offscreen_pixmap);
275
276   g_free (progress->format);
277
278   G_OBJECT_CLASS (gtk_progress_parent_class)->finalize (object);
279 }
280
281 static gboolean
282 gtk_progress_expose (GtkWidget      *widget,
283                      GdkEventExpose *event)
284 {
285   g_return_val_if_fail (GTK_IS_PROGRESS (widget), FALSE);
286   g_return_val_if_fail (event != NULL, FALSE);
287
288   if (GTK_WIDGET_DRAWABLE (widget))
289     gdk_draw_drawable (widget->window,
290                        widget->style->black_gc,
291                        GTK_PROGRESS (widget)->offscreen_pixmap,
292                        event->area.x, event->area.y,
293                        event->area.x, event->area.y,
294                        event->area.width,
295                        event->area.height);
296
297   return FALSE;
298 }
299
300 static void
301 gtk_progress_size_allocate (GtkWidget     *widget,
302                             GtkAllocation *allocation)
303 {
304   g_return_if_fail (GTK_IS_PROGRESS (widget));
305   g_return_if_fail (allocation != NULL);
306
307   widget->allocation = *allocation;
308
309   if (GTK_WIDGET_REALIZED (widget))
310     {
311       gdk_window_move_resize (widget->window,
312                               allocation->x, allocation->y,
313                               allocation->width, allocation->height);
314
315       gtk_progress_create_pixmap (GTK_PROGRESS (widget));
316     }
317 }
318
319 static void
320 gtk_progress_create_pixmap (GtkProgress *progress)
321 {
322   GtkWidget *widget;
323
324   g_return_if_fail (GTK_IS_PROGRESS (progress));
325
326   if (GTK_WIDGET_REALIZED (progress))
327     {
328       widget = GTK_WIDGET (progress);
329
330       if (progress->offscreen_pixmap)
331         g_object_unref (progress->offscreen_pixmap);
332
333       progress->offscreen_pixmap = gdk_pixmap_new (widget->window,
334                                                    widget->allocation.width,
335                                                    widget->allocation.height,
336                                                    -1);
337
338       /* clear the pixmap for transparent themes */
339       gtk_paint_flat_box (widget->style,
340                           progress->offscreen_pixmap,
341                           GTK_STATE_NORMAL, GTK_SHADOW_NONE,
342                           NULL, widget, "trough", 0, 0, -1, -1);
343       
344       GTK_PROGRESS_GET_CLASS (progress)->paint (progress);
345     }
346 }
347
348 static void
349 gtk_progress_changed (GtkAdjustment *adjustment,
350                       GtkProgress   *progress)
351 {
352   /* A change in the value of adjustment->upper can change
353    * the size request
354    */
355   if (progress->use_text_format && progress->show_text)
356     gtk_widget_queue_resize (GTK_WIDGET (progress));
357   else
358     GTK_PROGRESS_GET_CLASS (progress)->update (progress);
359 }
360
361 static void
362 gtk_progress_value_changed (GtkAdjustment *adjustment,
363                             GtkProgress   *progress)
364 {
365   GTK_PROGRESS_GET_CLASS (progress)->update (progress);
366 }
367
368 static gchar *
369 gtk_progress_build_string (GtkProgress *progress,
370                            gdouble      value,
371                            gdouble      percentage)
372 {
373   gchar buf[256] = { 0 };
374   gchar tmp[256] = { 0 };
375   gchar *src;
376   gchar *dest;
377   gchar fmt[10];
378
379   src = progress->format;
380
381   /* This is the new supported version of this function */
382   if (!progress->use_text_format)
383     return g_strdup (src);
384
385   /* And here's all the deprecated goo. */
386   
387   dest = buf;
388  
389   while (src && *src)
390     {
391       if (*src != '%')
392         {
393           *dest = *src;
394           dest++;
395         }
396       else
397         {
398           gchar c;
399           gint digits;
400
401           c = *(src + sizeof(gchar));
402           digits = 0;
403
404           if (c >= '0' && c <= '2')
405             {
406               digits = (gint) (c - '0');
407               src++;
408               c = *(src + sizeof(gchar));
409             }
410
411           switch (c)
412             {
413             case '%':
414               *dest = '%';
415               src++;
416               dest++;
417               break;
418             case 'p':
419             case 'P':
420               if (digits)
421                 {
422                   g_snprintf (fmt, sizeof (fmt), "%%.%df", digits);
423                   g_snprintf (tmp, sizeof (tmp), fmt, 100 * percentage);
424                 }
425               else
426                 g_snprintf (tmp, sizeof (tmp), "%.0f", 100 * percentage);
427               strcat (buf, tmp);
428               dest = &(buf[strlen (buf)]);
429               src++;
430               break;
431             case 'v':
432             case 'V':
433               if (digits)
434                 {
435                   g_snprintf (fmt, sizeof (fmt), "%%.%df", digits);
436                   g_snprintf (tmp, sizeof (tmp), fmt, value);
437                 }
438               else
439                 g_snprintf (tmp, sizeof (tmp), "%.0f", value);
440               strcat (buf, tmp);
441               dest = &(buf[strlen (buf)]);
442               src++;
443               break;
444             case 'l':
445             case 'L':
446               if (digits)
447                 {
448                   g_snprintf (fmt, sizeof (fmt), "%%.%df", digits);
449                   g_snprintf (tmp, sizeof (tmp), fmt, progress->adjustment->lower);
450                 }
451               else
452                 g_snprintf (tmp, sizeof (tmp), "%.0f", progress->adjustment->lower);
453               strcat (buf, tmp);
454               dest = &(buf[strlen (buf)]);
455               src++;
456               break;
457             case 'u':
458             case 'U':
459               if (digits)
460                 {
461                   g_snprintf (fmt, sizeof (fmt), "%%.%df", digits);
462                   g_snprintf (tmp, sizeof (tmp), fmt, progress->adjustment->upper);
463                 }
464               else
465                 g_snprintf (tmp, sizeof (tmp), "%.0f", progress->adjustment->upper);
466               strcat (buf, tmp);
467               dest = &(buf[strlen (buf)]);
468               src++;
469               break;
470             default:
471               break;
472             }
473         }
474       src++;
475     }
476
477   return g_strdup (buf);
478 }
479
480 /***************************************************************/
481
482 void
483 gtk_progress_set_adjustment (GtkProgress   *progress,
484                              GtkAdjustment *adjustment)
485 {
486   g_return_if_fail (GTK_IS_PROGRESS (progress));
487   if (adjustment)
488     g_return_if_fail (GTK_IS_ADJUSTMENT (adjustment));
489   else
490     adjustment = (GtkAdjustment*) gtk_adjustment_new (0, 0, 100, 0, 0, 0);
491
492   if (progress->adjustment != adjustment)
493     {
494       if (progress->adjustment)
495         {
496           g_signal_handlers_disconnect_by_func (progress->adjustment,
497                                                 gtk_progress_changed,
498                                                 progress);
499           g_signal_handlers_disconnect_by_func (progress->adjustment,
500                                                 gtk_progress_value_changed,
501                                                 progress);
502           g_object_unref (progress->adjustment);
503         }
504       progress->adjustment = adjustment;
505       if (adjustment)
506         {
507           g_object_ref_sink (adjustment);
508           g_signal_connect (adjustment, "changed",
509                             G_CALLBACK (gtk_progress_changed),
510                             progress);
511           g_signal_connect (adjustment, "value_changed",
512                             G_CALLBACK (gtk_progress_value_changed),
513                             progress);
514         }
515
516       gtk_progress_changed (adjustment, progress);
517     }
518 }
519
520 void
521 gtk_progress_configure (GtkProgress *progress,
522                         gdouble      value,
523                         gdouble      min,
524                         gdouble      max)
525 {
526   GtkAdjustment *adj;
527   gboolean changed = FALSE;
528
529   g_return_if_fail (GTK_IS_PROGRESS (progress));
530   g_return_if_fail (min <= max);
531   g_return_if_fail (value >= min && value <= max);
532
533   if (!progress->adjustment)
534     gtk_progress_set_adjustment (progress, NULL);
535   adj = progress->adjustment;
536
537   if (fabs (adj->lower - min) > EPSILON || fabs (adj->upper - max) > EPSILON)
538     changed = TRUE;
539
540   adj->value = value;
541   adj->lower = min;
542   adj->upper = max;
543
544   gtk_adjustment_value_changed (adj);
545   if (changed)
546     gtk_adjustment_changed (adj);
547 }
548
549 void
550 gtk_progress_set_percentage (GtkProgress *progress,
551                              gdouble      percentage)
552 {
553   g_return_if_fail (GTK_IS_PROGRESS (progress));
554   g_return_if_fail (percentage >= 0 && percentage <= 1.0);
555
556   if (!progress->adjustment)
557     gtk_progress_set_adjustment (progress, NULL);
558   gtk_progress_set_value (progress, progress->adjustment->lower + percentage * 
559                  (progress->adjustment->upper - progress->adjustment->lower));
560 }
561
562 gdouble
563 gtk_progress_get_current_percentage (GtkProgress *progress)
564 {
565   g_return_val_if_fail (GTK_IS_PROGRESS (progress), 0);
566
567   if (!progress->adjustment)
568     gtk_progress_set_adjustment (progress, NULL);
569
570   return gtk_progress_get_percentage_from_value (progress, progress->adjustment->value);
571 }
572
573 gdouble
574 gtk_progress_get_percentage_from_value (GtkProgress *progress,
575                                         gdouble      value)
576 {
577   g_return_val_if_fail (GTK_IS_PROGRESS (progress), 0);
578
579   if (!progress->adjustment)
580     gtk_progress_set_adjustment (progress, NULL);
581
582   if (progress->adjustment->lower < progress->adjustment->upper &&
583       value >= progress->adjustment->lower &&
584       value <= progress->adjustment->upper)
585     return (value - progress->adjustment->lower) /
586       (progress->adjustment->upper - progress->adjustment->lower);
587   else
588     return 0.0;
589 }
590
591 void
592 gtk_progress_set_value (GtkProgress *progress,
593                         gdouble      value)
594 {
595   g_return_if_fail (GTK_IS_PROGRESS (progress));
596
597   if (!progress->adjustment)
598     gtk_progress_set_adjustment (progress, NULL);
599
600   if (fabs (progress->adjustment->value - value) > EPSILON)
601     gtk_adjustment_set_value (progress->adjustment, value);
602 }
603
604 gdouble
605 gtk_progress_get_value (GtkProgress *progress)
606 {
607   g_return_val_if_fail (GTK_IS_PROGRESS (progress), 0);
608
609   return progress->adjustment ? progress->adjustment->value : 0;
610 }
611
612 void
613 gtk_progress_set_show_text (GtkProgress *progress,
614                             gboolean     show_text)
615 {
616   g_return_if_fail (GTK_IS_PROGRESS (progress));
617
618   if (progress->show_text != show_text)
619     {
620       progress->show_text = show_text;
621
622       gtk_widget_queue_resize (GTK_WIDGET (progress));
623
624       g_object_notify (G_OBJECT (progress), "show-text");
625     }
626 }
627
628 void
629 gtk_progress_set_text_alignment (GtkProgress *progress,
630                                  gfloat       x_align,
631                                  gfloat       y_align)
632 {
633   g_return_if_fail (GTK_IS_PROGRESS (progress));
634   g_return_if_fail (x_align >= 0.0 && x_align <= 1.0);
635   g_return_if_fail (y_align >= 0.0 && y_align <= 1.0);
636
637   if (progress->x_align != x_align || progress->y_align != y_align)
638     {
639       g_object_freeze_notify (G_OBJECT (progress));
640       if (progress->x_align != x_align)
641         {
642           progress->x_align = x_align;
643           g_object_notify (G_OBJECT (progress), "text-xalign");
644         }
645
646       if (progress->y_align != y_align)
647         {
648           progress->y_align = y_align;
649           g_object_notify (G_OBJECT (progress), "text-yalign");
650         }
651       g_object_thaw_notify (G_OBJECT (progress));
652
653       if (GTK_WIDGET_DRAWABLE (GTK_WIDGET (progress)))
654         gtk_widget_queue_resize (GTK_WIDGET (progress));
655     }
656 }
657
658 void
659 gtk_progress_set_format_string (GtkProgress *progress,
660                                 const gchar *format)
661 {
662   gchar *old_format;
663   
664   g_return_if_fail (GTK_IS_PROGRESS (progress));
665
666   /* Turn on format, in case someone called
667    * gtk_progress_bar_set_text() and turned it off.
668    */
669   progress->use_text_format = TRUE;
670
671   old_format = progress->format;
672
673   if (!format)
674     format = DEFAULT_FORMAT;
675
676   progress->format = g_strdup (format);
677   g_free (old_format);
678   
679   gtk_widget_queue_resize (GTK_WIDGET (progress));
680 }
681
682 gchar *
683 gtk_progress_get_current_text (GtkProgress *progress)
684 {
685   g_return_val_if_fail (GTK_IS_PROGRESS (progress), NULL);
686
687   if (!progress->adjustment)
688     gtk_progress_set_adjustment (progress, NULL);
689
690   return gtk_progress_build_string (progress, progress->adjustment->value,
691                                     gtk_progress_get_current_percentage (progress));
692 }
693
694 gchar *
695 gtk_progress_get_text_from_value (GtkProgress *progress,
696                                   gdouble      value)
697 {
698   g_return_val_if_fail (GTK_IS_PROGRESS (progress), NULL);
699
700   if (!progress->adjustment)
701     gtk_progress_set_adjustment (progress, NULL);
702
703   return gtk_progress_build_string (progress, value,
704                                     gtk_progress_get_percentage_from_value (progress, value));
705 }
706
707 void
708 gtk_progress_set_activity_mode (GtkProgress *progress,
709                                 gboolean     activity_mode)
710 {
711   g_return_if_fail (GTK_IS_PROGRESS (progress));
712
713   if (progress->activity_mode != (activity_mode != FALSE))
714     {
715       progress->activity_mode = (activity_mode != FALSE);
716
717       if (progress->activity_mode)
718         GTK_PROGRESS_GET_CLASS (progress)->act_mode_enter (progress);
719
720       if (GTK_WIDGET_DRAWABLE (GTK_WIDGET (progress)))
721         gtk_widget_queue_resize (GTK_WIDGET (progress));
722
723       g_object_notify (G_OBJECT (progress), "activity-mode");
724     }
725 }
726
727 #define __GTK_PROGRESS_C__
728 #include "gtkaliasdef.c"