Add GtkExpander docs.

This commit is contained in:
Matthias Clasen 2003-07-01 19:46:22 +00:00
parent f976beaf41
commit 7f5968aa07
12 changed files with 359 additions and 5 deletions

View File

@ -1,3 +1,9 @@
2003-07-01 Matthias Clasen <maclas@gmx.de>
* gtk/gtk.h: Include gtkexpander.h
* gtk/gtkexpander.c: Small additions to the docs.
2003-07-01 Tor Lillqvist <tml@iki.fi>
* gdk/win32/gdkwindow-win32.c (_gdk_windowing_window_get_pointer):

View File

@ -1,3 +1,9 @@
2003-07-01 Matthias Clasen <maclas@gmx.de>
* gtk/gtk.h: Include gtkexpander.h
* gtk/gtkexpander.c: Small additions to the docs.
2003-07-01 Tor Lillqvist <tml@iki.fi>
* gdk/win32/gdkwindow-win32.c (_gdk_windowing_window_get_pointer):

View File

@ -1,3 +1,9 @@
2003-07-01 Matthias Clasen <maclas@gmx.de>
* gtk/gtk.h: Include gtkexpander.h
* gtk/gtkexpander.c: Small additions to the docs.
2003-07-01 Tor Lillqvist <tml@iki.fi>
* gdk/win32/gdkwindow-win32.c (_gdk_windowing_window_get_pointer):

View File

@ -1,3 +1,9 @@
2003-07-01 Matthias Clasen <maclas@gmx.de>
* gtk/gtk.h: Include gtkexpander.h
* gtk/gtkexpander.c: Small additions to the docs.
2003-07-01 Tor Lillqvist <tml@iki.fi>
* gdk/win32/gdkwindow-win32.c (_gdk_windowing_window_get_pointer):

View File

@ -1,3 +1,9 @@
2003-07-01 Matthias Clasen <maclas@gmx.de>
* gtk/gtk.h: Include gtkexpander.h
* gtk/gtkexpander.c: Small additions to the docs.
2003-07-01 Tor Lillqvist <tml@iki.fi>
* gdk/win32/gdkwindow-win32.c (_gdk_windowing_window_get_pointer):

View File

@ -1,5 +1,13 @@
2003-07-01 Matthias Clasen <maclas@gmx.de>
* gtk/tmpl/gtkexpander.sgml: New file. Template for GtkExpander docs.
* gtk/gtk-sections.txt: Add a section for GtkExpander.
* gtk/gtk-docs.sgml: Add an entity for GtkExpander.
* gtk/gtk.types: Add gtk_expander_get_type
* gdk/gdk-sections.txt: Add
gdk_cursor_new_from_pixbuf(), gdk_display_supports_cursor_alpha(),
gdk_display_supports_cursor_color(), gdk_display_get_default_cursor_size() and

View File

@ -14,6 +14,7 @@
<!ENTITY GtkCheckButton SYSTEM "xml/gtkcheckbutton.xml">
<!ENTITY GtkCheckMenuItem SYSTEM "xml/gtkcheckmenuitem.xml">
<!ENTITY GtkCList SYSTEM "xml/gtkclist.xml">
<!ENTITY GtkColorButton SYSTEM "xml/gtkcolorbutton.xml">
<!ENTITY GtkColorSelection SYSTEM "xml/gtkcolorsel.xml">
<!ENTITY GtkColorSelectionDialog SYSTEM "xml/gtkcolorseldlg.xml">
<!ENTITY GtkCombo SYSTEM "xml/gtkcombo.xml">
@ -26,8 +27,10 @@
<!ENTITY GtkOldEditable SYSTEM "xml/gtkoldeditable.xml">
<!ENTITY GtkEntry SYSTEM "xml/gtkentry.xml">
<!ENTITY GtkEventBox SYSTEM "xml/gtkeventbox.xml">
<!ENTITY GtkExpander SYSTEM "xml/gtkexpander.xml">
<!ENTITY GtkFileSelection SYSTEM "xml/gtkfilesel.xml">
<!ENTITY GtkFixed SYSTEM "xml/gtkfixed.xml">
<!ENTITY GtkFontButton SYSTEM "xml/gtkfontbutton.xml">
<!ENTITY GtkFontSelection SYSTEM "xml/gtkfontsel.xml">
<!ENTITY GtkFontSelectionDialog SYSTEM "xml/gtkfontseldlg.xml">
<!ENTITY GtkFrame SYSTEM "xml/gtkframe.xml">
@ -379,9 +382,11 @@ that is, GUI components such as <link linkend="GtkButton">GtkButton</link> or
<chapter id="SelectorWidgets">
<title>Selectors (File/Font/Color/Input Devices)</title>
&GtkColorButton;
&GtkColorSelection;
&GtkColorSelectionDialog;
&GtkFileSelection;
&GtkFontButton;
&GtkFontSelection;
&GtkFontSelectionDialog;
&GtkInputDialog;
@ -401,6 +406,7 @@ that is, GUI components such as <link linkend="GtkButton">GtkButton</link> or
&GtkLayout;
&GtkNotebook;
&GtkTable;
&GtkExpander;
</chapter>
<chapter id="Ornaments">

View File

@ -466,6 +466,31 @@ GTK_CLIST_GET_CLASS
gtk_clist_get_type
</SECTION>
<SECTION>
<FILE>gtkcolorbutton</FILE>
<TITLE>GtkColorButton</TITLE>
GtkColorButton
gtk_color_button_new
gtk_color_button_set_color
gtk_color_button_get_color
gtk_color_button_set_alpha
gtk_color_button_get_alpha
gtk_color_button_set_use_alpha
gtk_color_button_get_use_alpha
gtk_color_button_set_title
gtk_color_button_get_title
<SUBSECTION Standard>
GTK_COLOR_BUTTON
GTK_IS_COLOR_BUTTON
GTK_TYPE_COLOR_BUTTON
GTK_COLOR_BUTTON_CLASS
GTK_IS_COLOR_BUTTON_CLASS
GTK_COLOR_BUTTON_GET_CLASS
GTK_COLOR_BUTTON_GET_PRIVATE
<SUBSECTION Private>
gtk_color_button_get_type
</SECTION>
<SECTION>
<FILE>gtkcolorsel</FILE>
<TITLE>GtkColorSelection</TITLE>
@ -860,6 +885,33 @@ GTK_EVENT_BOX_GET_CLASS
gtk_event_box_get_type
</SECTION>
<SECTION>
<FILE>gtkexpander</FILE>
<TITLE>GtkExpander</TITLE>
GtkExpander
gtk_expander_new
gtk_expander_new_with_mnemonic
gtk_expander_set_expanded
gtk_expander_get_expanded
gtk_expander_set_spacing
gtk_expander_get_spacing
gtk_expander_set_label
gtk_expander_get_label
gtk_expander_set_use_underline
gtk_expander_get_use_underline
gtk_expander_set_label_widget
gtk_expander_get_label_widget
<SUBSECTION Standard>
GTK_TYPE_EXPANDER
GTK_EXPANDER_CLASS
GTK_EXPANDER
GTK_IS_EXPANDER
GTK_IS_EXPANDER_CLASS
GTK_EXPANDER_GET_CLASS
<SUBSECTION Private>
gtk_expander_get_type
</SECTION>
<SECTION>
<FILE>gtkfilesel</FILE>
<TITLE>GtkFileSelection</TITLE>
@ -905,6 +957,36 @@ GTK_FIXED_GET_CLASS
gtk_fixed_get_type
</SECTION>
<SECTION>
<FILE>gtkfontbutton</FILE>
<TITLE>GtkFontButton</TITLE>
GtkFontButton
gtk_font_button_new
gtk_font_button_new_with_font
gtk_font_button_set_font_name
gtk_font_button_get_font_name
gtk_font_button_set_show_style
gtk_font_button_get_show_style
gtk_font_button_set_show_size
gtk_font_button_get_show_size
gtk_font_button_set_use_font
gtk_font_button_get_use_font
gtk_font_button_set_use_size
gtk_font_button_get_use_size
gtk_font_button_set_title
gtk_font_button_get_title
<SUBSECTION Standard>
GTK_FONT_BUTTON
GTK_IS_FONT_BUTTON
GTK_TYPE_FONT_BUTTON
GTK_FONT_BUTTON_CLASS
GTK_IS_FONT_BUTTON_CLASS
GTK_FONT_BUTTON_GET_CLASS
GTK_FONT_BUTTON_GET_PRIVATE
<SUBSECTION Private>
gtk_font_button_get_type
</SECTION>
<SECTION>
<FILE>gtkfontsel</FILE>
<TITLE>GtkFontSelection</TITLE>

View File

@ -19,6 +19,7 @@ gtk_cell_renderer_toggle_get_type
gtk_check_button_get_type
gtk_check_menu_item_get_type
gtk_clist_get_type
gtk_color_button_get_type
gtk_color_selection_dialog_get_type
gtk_color_selection_get_type
gtk_combo_get_type
@ -29,8 +30,10 @@ gtk_dialog_get_type
gtk_drawing_area_get_type
gtk_entry_get_type
gtk_event_box_get_type
gtk_expander_get_type
gtk_file_selection_get_type
gtk_fixed_get_type
gtk_font_button_get_type
gtk_font_selection_dialog_get_type
gtk_font_selection_get_type
gtk_frame_get_type

View File

@ -0,0 +1,173 @@
<!-- ##### SECTION Title ##### -->
GtkExpander
<!-- ##### SECTION Short_Description ##### -->
A container which can hide its child
<!-- ##### SECTION Long_Description ##### -->
<para>
A #GtkExpander allows the user to hide or show its child by clicking on an expander triangle similar to
the triangles used in a #GtkTreeView.
</para>
<!-- ##### SECTION See_Also ##### -->
<para>
</para>
<!-- ##### STRUCT GtkExpander ##### -->
<para>
</para>
<!-- ##### FUNCTION gtk_expander_new ##### -->
<para>
</para>
@label:
@Returns:
<!-- ##### FUNCTION gtk_expander_new_with_mnemonic ##### -->
<para>
</para>
@label:
@Returns:
<!-- ##### FUNCTION gtk_expander_set_expanded ##### -->
<para>
</para>
@expander:
@expanded:
<!-- ##### FUNCTION gtk_expander_get_expanded ##### -->
<para>
</para>
@expander:
@Returns:
<!-- ##### FUNCTION gtk_expander_set_spacing ##### -->
<para>
</para>
@expander:
@spacing:
<!-- ##### FUNCTION gtk_expander_get_spacing ##### -->
<para>
</para>
@expander:
@Returns:
<!-- ##### FUNCTION gtk_expander_set_label ##### -->
<para>
</para>
@expander:
@label:
<!-- ##### FUNCTION gtk_expander_get_label ##### -->
<para>
</para>
@expander:
@Returns:
<!-- ##### FUNCTION gtk_expander_set_use_underline ##### -->
<para>
</para>
@expander:
@use_underline:
<!-- ##### FUNCTION gtk_expander_get_use_underline ##### -->
<para>
</para>
@expander:
@Returns:
<!-- ##### FUNCTION gtk_expander_set_label_widget ##### -->
<para>
</para>
@expander:
@label_widget:
<!-- ##### FUNCTION gtk_expander_get_label_widget ##### -->
<para>
</para>
@expander:
@Returns:
<!-- ##### SIGNAL GtkExpander::activate ##### -->
<para>
</para>
@expander: the object which received the signal.
<!-- ##### ARG GtkExpander:expanded ##### -->
<para>
</para>
<!-- ##### ARG GtkExpander:label ##### -->
<para>
</para>
<!-- ##### ARG GtkExpander:label-widget ##### -->
<para>
</para>
<!-- ##### ARG GtkExpander:spacing ##### -->
<para>
</para>
<!-- ##### ARG GtkExpander:use-underline ##### -->
<para>
</para>
<!-- ##### ARG GtkExpander:expander-size ##### -->
<para>
</para>
<!-- ##### ARG GtkExpander:expander-spacing ##### -->
<para>
</para>

View File

@ -51,6 +51,7 @@
#include <gtk/gtkcheckmenuitem.h>
#include <gtk/gtkclipboard.h>
#include <gtk/gtkclist.h>
#include <gtk/gtkcolorbutton.h>
#include <gtk/gtkcolorsel.h>
#include <gtk/gtkcolorseldialog.h>
#include <gtk/gtkcombo.h>
@ -64,8 +65,10 @@
#include <gtk/gtkentry.h>
#include <gtk/gtkenums.h>
#include <gtk/gtkeventbox.h>
#include <gtk/gtkexpander.h>
#include <gtk/gtkfilesel.h>
#include <gtk/gtkfixed.h>
#include <gtk/gtkfontbutton.h>
#include <gtk/gtkfontsel.h>
#include <gtk/gtkframe.h>
#include <gtk/gtkgamma.h>

View File

@ -246,7 +246,9 @@ gtk_expander_class_init (GtkExpanderClass *klass)
G_SIGNAL_RUN_LAST | G_SIGNAL_ACTION,
G_STRUCT_OFFSET (GtkExpanderClass, activate),
NULL, NULL,
_gtk_marshal_VOID__VOID,
_gtk_marsha /**
l_VOID__VOID,
G_TYPE_NONE, 0);
}
@ -1081,12 +1083,39 @@ gtk_expander_activate (GtkExpander *expander)
gtk_expander_set_expanded (expander, !expander->priv->expanded);
}
/**
* gtk_expander_new:
* @label: the text of the label
*
* Creates a new expander using @label as the text of the label.
*
* Return value: a new #GtkExpander widget.
*
* Since: 2.4
**/
GtkWidget *
gtk_expander_new (const gchar *label)
{
return g_object_new (GTK_TYPE_EXPANDER, "label", label, NULL);
}
/**
* gtk_expander_new_with_mnemonic:
* @label: the text of the label with an underscore in front of the
* mnemonic character
*
* Creates a new expander using @label as the text of the label.
* If characters in @label are preceded by an underscore, they are underlined.
* If you need a literal underscore character in a label, use '__' (two
* underscores). The first underlined character represents a keyboard
* accelerator called a mnemonic.
* Pressing Alt and that key activates the button.
*
* Return value: a new #GtkExpander widget.
*
* Since: 2.4
**/
GtkWidget *
gtk_expander_new_with_mnemonic (const gchar *label)
{
@ -1166,9 +1195,11 @@ gtk_expander_start_animation (GtkExpander *expander)
* @expander: a #GtkExpander
* @expanded: whether the child widget is revealed
*
* Sets the state of the expander. Set to #TRUE, if you want
* the child widget to be revealed, and #FALSE if you want the
* Sets the state of the expander. Set to %TRUE, if you want
* the child widget to be revealed, and %FALSE if you want the
* child widget to be hidden.
*
* Since: 2.4
**/
void
gtk_expander_set_expanded (GtkExpander *expander,
@ -1205,12 +1236,14 @@ gtk_expander_set_expanded (GtkExpander *expander,
* gtk_expander_get_expanded:
* @expander:a #GtkExpander
*
* Queries a #GtkExpander and returns its current state. Returns #TRUE
* Queries a #GtkExpander and returns its current state. Returns %TRUE
* if the child widget is revealed.
*
* See gtk_expander_set_expanded().
*
* Return value: the current state of the expander.
*
* Since: 2.4
**/
gboolean
gtk_expander_get_expanded (GtkExpander *expander)
@ -1227,6 +1260,8 @@ gtk_expander_get_expanded (GtkExpander *expander)
*
* Sets the spacing field of @expander, which is the number of pixels to
* place between expander and the child.
*
* Since: 2.4
**/
void
gtk_expander_set_spacing (GtkExpander *expander,
@ -1252,6 +1287,8 @@ gtk_expander_set_spacing (GtkExpander *expander,
* Gets the value set by gtk_expander_set_spacing().
*
* Return value: spacing between the expander and child.
*
* Since: 2.4
**/
gint
gtk_expander_get_spacing (GtkExpander *expander)
@ -1269,6 +1306,8 @@ gtk_expander_get_spacing (GtkExpander *expander)
* Sets the text of the label of the expander to @label.
*
* This will also clear any previously set labels.
*
* Since: 2.4
**/
void
gtk_expander_set_label (GtkExpander *expander,
@ -1306,6 +1345,8 @@ gtk_expander_set_label (GtkExpander *expander,
*
* Return value: The text of the label widget. This string is owned
* by the widget and must not be modified or freed.
*
* Since: 2.4
**/
G_CONST_RETURN char *
gtk_expander_get_label (GtkExpander *expander)
@ -1329,6 +1370,8 @@ gtk_expander_get_label (GtkExpander *expander)
*
* If true, an underline in the text of the expander label indicates
* the next character should be used for the mnemonic accelerator key.
*
* Since: 2.4
**/
void
gtk_expander_set_use_underline (GtkExpander *expander,
@ -1358,10 +1401,12 @@ gtk_expander_set_use_underline (GtkExpander *expander,
* @expander: a #GtkExpander
*
* Returns whether an embedded underline in the expander label indicates a
* mnemonic. See gtk_expander_set_use_underline ().
* mnemonic. See gtk_expander_set_use_underline().
*
* Return value: %TRUE if an embedded underline in the expander label
* indicates the mnemonic accelerator keys.
*
* Since: 2.4
**/
gboolean
gtk_expander_get_use_underline (GtkExpander *expander)
@ -1378,6 +1423,8 @@ gtk_expander_get_use_underline (GtkExpander *expander)
*
* Set the label widget for the expander. This is the widget
* that will appear embedded alongside the expander arrow.
*
* Since: 2.4
**/
void
gtk_expander_set_label_widget (GtkExpander *expander,
@ -1422,6 +1469,8 @@ gtk_expander_set_label_widget (GtkExpander *expander,
* gtk_expander_set_label_widget().
*
* Return value: the label widget, or %NULL if there is none.
*
* Since: 2.4
**/
GtkWidget *
gtk_expander_get_label_widget (GtkExpander *expander)