diff --git a/ChangeLog b/ChangeLog index 528316696f..fe95f837a1 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +Fri Feb 4 01:29:08 CET 2000 Sven Neumann + + * libgimp/gimpcolorbutton.c: documented GimpColorButton + Fri Feb 4 00:37:43 CET 2000 Sven Neumann * Makefile.am diff --git a/devel-docs/ChangeLog b/devel-docs/ChangeLog index 9ceb4cd195..6841432348 100644 --- a/devel-docs/ChangeLog +++ b/devel-docs/ChangeLog @@ -5,3 +5,8 @@ Fri Feb 4 00:40:47 CET 2000 Sven Neumann All the information so far is purely autogenerated. We will want to resort the chapters, add short explanantions and of course, most importantly, add comment blocks into the source. + +Fri Feb 4 01:27:41 CET 2000 Sven Neumann + + * libgimp/tmpl/gimpcolorbutton.sgml: documented GimpColorButton + to give you an example. diff --git a/devel-docs/libgimp/.cvsignore b/devel-docs/libgimp/.cvsignore index 146333c000..67428d2f60 100644 --- a/devel-docs/libgimp/.cvsignore +++ b/devel-docs/libgimp/.cvsignore @@ -2,4 +2,3 @@ Makefile Makefile.in html sgml -libgimp.signals diff --git a/devel-docs/libgimp/Makefile.am b/devel-docs/libgimp/Makefile.am index e9d6e2cce2..8c2f4f2dba 100644 --- a/devel-docs/libgimp/Makefile.am +++ b/devel-docs/libgimp/Makefile.am @@ -55,6 +55,7 @@ libgimp_docdir = $(HTML_DIR) EXTRA_DIST = \ libgimp.hierarchy \ + libgimp.signals \ libgimp.types \ libgimp-include.c \ libgimp-decl.txt \ diff --git a/devel-docs/libgimp/libgimp-docs.sgml b/devel-docs/libgimp/libgimp-docs.sgml index 9b6864de75..ee02d3a4dc 100644 --- a/devel-docs/libgimp/libgimp-docs.sgml +++ b/devel-docs/libgimp/libgimp-docs.sgml @@ -63,7 +63,7 @@ GIMP User Interface Library &GimpChainButton; - &GimpColorButton; + &GimpColorButton; &GimpFileSelection; &GimpPathEditor; &GimpSizeEntry; diff --git a/devel-docs/libgimp/libgimp.signals b/devel-docs/libgimp/libgimp.signals new file mode 100644 index 0000000000..b242c0318d --- /dev/null +++ b/devel-docs/libgimp/libgimp.signals @@ -0,0 +1,42 @@ + +GimpColorButton::color-changed +void +GimpColorButton *gimpcolorbutton + + + +GimpFileSelection::filename-changed +void +GimpFileSelection *gimpfileselection + + + +GimpPathEditor::path-changed +void +GimpPathEditor *gimppatheditor + + + +GimpSizeEntry::value-changed +void +GimpSizeEntry *gimpsizeentry + + + +GimpSizeEntry::refval-changed +void +GimpSizeEntry *gimpsizeentry + + + +GimpSizeEntry::unit-changed +void +GimpSizeEntry *gimpsizeentry + + + +GimpUnitMenu::unit-changed +void +GimpUnitMenu *gimpunitmenu + + diff --git a/devel-docs/libgimp/tmpl/gimpcolorbutton.sgml b/devel-docs/libgimp/tmpl/gimpcolorbutton.sgml index 279dd04126..3d9abf7a20 100644 --- a/devel-docs/libgimp/tmpl/gimpcolorbutton.sgml +++ b/devel-docs/libgimp/tmpl/gimpcolorbutton.sgml @@ -2,11 +2,16 @@ GimpColorButton - +Widget for selecting a color. - +This widget provides a simple button with a preview showing the color. +On click a GtkColorSelectionDialog is opened. Additionally the button +supports Drag and Drop and has a right-click menu that allows to choose +the color from the current FG or BG color. If the user changes the +color, the "color_changed" signal is emitted. Note that the color is +changed in place. diff --git a/libgimp/gimpcolorbutton.c b/libgimp/gimpcolorbutton.c index a4c6111b34..48bb41ec7a 100644 --- a/libgimp/gimpcolorbutton.c +++ b/libgimp/gimpcolorbutton.c @@ -208,7 +208,22 @@ gimp_color_button_get_type (void) return gcb_type; } - +/** + * gimp_color_button_new: + * @title: String that wil be used as title for the color_selector. + * @width: Width of the colorpreview in pixels. + * @height: Height of the colorpreview in pixels. + * @color: An array of guchar holding the color (RGB or RGBA) + * @bpp: May be 3 for RGB or 4 for RGBA. + * + * Creates a new GimpColorbutton widget. This returns a button with + * a preview showing the color. When the button is clicked a + * GtkColorSelectionDialog is opened. If the user changes the color + * the new color is written into the array that was used to pass + * the initial color and the "color_changed" signal is emitted. + * + * Returns: Pointer to the new GimpColorButton widget. + */ GtkWidget* gimp_color_button_new (gchar *title, @@ -293,6 +308,14 @@ gimp_color_button_new (gchar *title, return (GTK_WIDGET (gcb)); } +/** + * gimp_color_button_update: + * @gcb: Pointer to a #GimpColorButton. + * + * Should be used after the color controlled by a #GimpColorButton + * was changed. The color is then reread and the change is propagated + * to the preview and the GtkColorSelectionDialog if one is open. + */ void gimp_color_button_update (GimpColorButton *gcb) { diff --git a/libgimpwidgets/gimpcolorbutton.c b/libgimpwidgets/gimpcolorbutton.c index a4c6111b34..48bb41ec7a 100644 --- a/libgimpwidgets/gimpcolorbutton.c +++ b/libgimpwidgets/gimpcolorbutton.c @@ -208,7 +208,22 @@ gimp_color_button_get_type (void) return gcb_type; } - +/** + * gimp_color_button_new: + * @title: String that wil be used as title for the color_selector. + * @width: Width of the colorpreview in pixels. + * @height: Height of the colorpreview in pixels. + * @color: An array of guchar holding the color (RGB or RGBA) + * @bpp: May be 3 for RGB or 4 for RGBA. + * + * Creates a new GimpColorbutton widget. This returns a button with + * a preview showing the color. When the button is clicked a + * GtkColorSelectionDialog is opened. If the user changes the color + * the new color is written into the array that was used to pass + * the initial color and the "color_changed" signal is emitted. + * + * Returns: Pointer to the new GimpColorButton widget. + */ GtkWidget* gimp_color_button_new (gchar *title, @@ -293,6 +308,14 @@ gimp_color_button_new (gchar *title, return (GTK_WIDGET (gcb)); } +/** + * gimp_color_button_update: + * @gcb: Pointer to a #GimpColorButton. + * + * Should be used after the color controlled by a #GimpColorButton + * was changed. The color is then reread and the change is propagated + * to the preview and the GtkColorSelectionDialog if one is open. + */ void gimp_color_button_update (GimpColorButton *gcb) {