cvs: php-gtk-doc /en/reference/gtk gtk-functions.xml gtkaccelgroup.xml gtkaccellabel.xml gtkarrow.xml gtkbin.xml gtkbox.xml gtkcheckbutton.xml
gtkcheckmenuitem.xml gtkentry.xml gtkfileselection.xml gtkframe.xml gtkhbox.xml gtkhbuttonbox.xml gtkhpaned.xml gtklabel.xml gtklist.xml gtkmenu.xml
gtkobject.xml gtkpaned.xml gtkprogressbar.xml gtktext.xml gtktogglebutton.xml gtkvbox.xml gtkvbuttonbox.xml gtkvpaned.xml gtkwidget.xml
| From: | Steph | Date: | Wed, 18 Jun 2003 17:19:26 +0000 |
| Subject: | cvs: php-gtk-doc /en/reference/gtk gtk-functions.xml gtkaccelgroup.xml gtkaccellabel.xml gtkarrow.xml gtkbin.xml gtkbox.xml gtkcheckbutton.xml gtkcheckmenuitem.xml gtkentry.xml gtkfileselection.xml gtkframe.xml gtkhbox.xml gtkhbuttonbox.xml gtkhpaned.xml gtklabel.xml gtklist.xml gtkmenu.xml gtkobject.xml gtkpaned.xml gtkprogressbar.xml gtktext.xml gtktogglebutton.xml gtkvbox.xml gtkvbuttonbox.xml gtkvpaned.xml gtkwidget.xml |
||
| Groups: | php.gtk.doc | ||
| Request: | Send a blank email to php-gtk-doc+get-805@lists.php.net to get a copy of this message | ||
sfox Wed Jun 18 13:19:26 2003 EDT
Modified files:
/php-gtk-doc/en/reference/gtk gtk-functions.xml gtkaccelgroup.xml
gtkaccellabel.xml gtkarrow.xml
gtkbin.xml gtkbox.xml
gtkcheckbutton.xml
gtkcheckmenuitem.xml gtkentry.xml
gtkfileselection.xml gtkframe.xml
gtkhbox.xml gtkhbuttonbox.xml
gtkhpaned.xml gtklabel.xml
gtklist.xml gtkmenu.xml gtkobject.xml
gtkpaned.xml gtkprogressbar.xml
gtktext.xml gtktogglebutton.xml
gtkvbox.xml gtkvbuttonbox.xml
gtkvpaned.xml gtkwidget.xml
Log:
Updating to reflect general changes
Index: php-gtk-doc/en/reference/gtk/gtk-functions.xml diff -u php-gtk-doc/en/reference/gtk/gtk-functions.xml:1.9 php-gtk-doc/en/reference/gtk/gtk-functions.xml:1.10 --- php-gtk-doc/en/reference/gtk/gtk-functions.xml:1.9 Tue Jun 17 17:27:57 2003 +++ php-gtk-doc/en/reference/gtk/gtk-functions.xml Wed Jun 18 13:19:26 2003 @@ -312,14 +312,12 @@ color as the area it is drawn onto. All positions and sizes are absolute in terms of the underlying drawable. </simpara> - <para> - <informalexample> - <programlisting role="php"> -gtk::draw_arrow($style, $gdkwindow, GTK_STATE_NORMAL, GTK_SHADOW_OUT, -GTK_ARROW_RIGHT, false, $x, $y, $width, $height); - </programlisting> - </informalexample> - </para> + <simpara> + <literal> + gtk::draw_arrow($style, $gdkwindow, GTK_STATE_NORMAL, GTK_SHADOW_OUT, + GTK_ARROW_RIGHT, false, $x, $y, $width, $height); + </literal> + </simpara> </desc> </method> @@ -358,14 +356,12 @@ Any coloring is completely dependant on the <classname>GtkStyle</classname> that is passed as the first parameter. </simpara> - <para> - <informalexample> - <programlisting role="php"> -gtk::draw_box($style, $gdkwindow, GTK_STATE_ACTIVE, GTK_SHADOW_IN, $x, $y, -$width, $height); - </programlisting> - </informalexample> - </para> + <simpara> + <literal> + gtk::draw_box($style, $gdkwindow, GTK_STATE_ACTIVE, GTK_SHADOW_IN, + $x, $y, $width, $height); + </literal> + </simpara> </desc> </method> @@ -596,7 +592,13 @@ The way it would be used in such a situation is to have <informalexample> <programlisting role="php"> +<![CDATA[ +<?php + while(gtk::events_pending()) gtk::main_iteration(); + +?> +]]> </programlisting> </informalexample> after every update that is made to the GUI. This causes the main loop Index: php-gtk-doc/en/reference/gtk/gtkaccelgroup.xml diff -u php-gtk-doc/en/reference/gtk/gtkaccelgroup.xml:1.6 php-gtk-doc/en/reference/gtk/gtkaccelgroup.xml:1.7 --- php-gtk-doc/en/reference/gtk/gtkaccelgroup.xml:1.6 Tue Jun 17 17:27:57 2003 +++ php-gtk-doc/en/reference/gtk/gtkaccelgroup.xml Wed Jun 18 13:19:26 2003 @@ -41,16 +41,12 @@ Provides the structure for a hash table of accelerator key information. </shortdesc> <desc> - <para> + <simpara> Although not a part of the GTK object hierarchy, <classname>GtkAccelGroup</classname> can be constructed in the same way as most GTK classes, i.e. - <informalexample> - <programlisting role="php"> -$accelgroup = &new GtkAccelGroup(); - </programlisting> - </informalexample> - </para> + <literal>$accelgroup = &new GtkAccelGroup();</literal> + </simpara> <simpara> In most cases, the newly-constructed <classname>GtkAccelGroup</classname> would be used by all the menus belonging to that toplevel window, and Index: php-gtk-doc/en/reference/gtk/gtkaccellabel.xml diff -u php-gtk-doc/en/reference/gtk/gtkaccellabel.xml:1.6 php-gtk-doc/en/reference/gtk/gtkaccellabel.xml:1.7 --- php-gtk-doc/en/reference/gtk/gtkaccellabel.xml:1.6 Tue Jun 17 17:27:57 2003 +++ php-gtk-doc/en/reference/gtk/gtkaccellabel.xml Wed Jun 18 13:19:26 2003 @@ -20,17 +20,13 @@ need to access it, for instance to parse an underline in a label's text string or to retrieve a menu's textual content. </simpara> - <para> + <simpara> To access the <classname>GtkAccelLabel</classname> within an existing menu item, use the following code: - <informalexample> - <programlisting role="php"> -$accel_label = $menu_item->child; - </programlisting> - </informalexample> + <literal>$accel_label = $menu_item->child;</literal> You will then be able to call most of the methods available to a new instance of a <classname>GtkAccelLabel</classname>. - </para> + </simpara> </desc> </classmeta> Index: php-gtk-doc/en/reference/gtk/gtkarrow.xml diff -u php-gtk-doc/en/reference/gtk/gtkarrow.xml:1.8 php-gtk-doc/en/reference/gtk/gtkarrow.xml:1.9 --- php-gtk-doc/en/reference/gtk/gtkarrow.xml:1.8 Tue Jun 17 17:27:57 2003 +++ php-gtk-doc/en/reference/gtk/gtkarrow.xml Wed Jun 18 13:19:26 2003 @@ -51,20 +51,12 @@ arrow can be redefined at any point using the <function class="GtkArrow">set</function> method. </simpara> - <para> + <simpara> The syntax to create a right-pointing, etched arrow would be: - <informalexample> - <programlisting role="php"> -<![CDATA[ -<?php - -$arrow = &new GtkArrow(GTK_ARROW_RIGHT, GTK_SHADOW_ETCHED_IN); - -?> -]]> - </programlisting> - </informalexample> - </para> + <literal> + $arrow = &new GtkArrow(GTK_ARROW_RIGHT, GTK_SHADOW_ETCHED_IN); + </literal> + </simpara> </desc> </constructor> Index: php-gtk-doc/en/reference/gtk/gtkbin.xml diff -u php-gtk-doc/en/reference/gtk/gtkbin.xml:1.12 php-gtk-doc/en/reference/gtk/gtkbin.xml:1.13 --- php-gtk-doc/en/reference/gtk/gtkbin.xml:1.12 Tue Jun 17 17:27:57 2003 +++ php-gtk-doc/en/reference/gtk/gtkbin.xml Wed Jun 18 13:19:26 2003 @@ -40,19 +40,9 @@ is <literal>NULL</literal>, then <classname>GtkBin</classname> object does not contain a child widget. </simpara> - <para> - <informalexample> - <programlisting role="php"> -<![CDATA[ -<?php - -$button->remove($button->child); - -?> -]]> - </programlisting> - </informalexample> - </para> + <simpara> + <literal>$button->remove($button->child);</literal> + </simpara> </desc> </prop> Index: php-gtk-doc/en/reference/gtk/gtkbox.xml diff -u php-gtk-doc/en/reference/gtk/gtkbox.xml:1.13 php-gtk-doc/en/reference/gtk/gtkbox.xml:1.14 --- php-gtk-doc/en/reference/gtk/gtkbox.xml:1.13 Tue Jun 17 17:27:57 2003 +++ php-gtk-doc/en/reference/gtk/gtkbox.xml Wed Jun 18 13:19:26 2003 @@ -131,15 +131,11 @@ container using the default parameter values <literal>true</literal>, <literal>true</literal>, <literal>0</literal>. </simpara> - <para> + <simpara> The same result can be achieved by using - <informalexample> - <programlisting role="php"> -$box->pack_start($child); - </programlisting> - </informalexample> + <literal>$box->pack_start($child);</literal> without specifying any further parameters. - </para> + </simpara> </desc> </method> @@ -162,15 +158,11 @@ container using the default parameter values <literal>true</literal>, <literal>true</literal>, <literal>0</literal>. </simpara> - <para> + <simpara> The same result can be achieved by using - <informalexample> - <programlisting role="php"> -$box->pack_end($child); - </programlisting> - </informalexample> + <literal>$box->pack_end($child);</literal> without specifying any further parameters. - </para> + </simpara> </desc> </method> Index: php-gtk-doc/en/reference/gtk/gtkcheckbutton.xml diff -u php-gtk-doc/en/reference/gtk/gtkcheckbutton.xml:1.5 php-gtk-doc/en/reference/gtk/gtkcheckbutton.xml:1.6 --- php-gtk-doc/en/reference/gtk/gtkcheckbutton.xml:1.5 Sun Jan 20 14:47:43 2002 +++ php-gtk-doc/en/reference/gtk/gtkcheckbutton.xml Wed Jun 18 13:19:26 2003 @@ -34,19 +34,17 @@ Creates a button with a small toggle indicator. </shortdesc> <desc> - <para> - <informalexample> - <programlisting role="php"> + <simpara> + <literal> $checkbutton = &new GtkCheckButton("GtkCheckButton label"); - </programlisting> - </informalexample> + </literal> instantiates a normal-sized <classname>GtkButton</classname> with a small draw_indicator toggle to the left of the button's label area. The indicator displays the <enumname>GtkShadowType</enumname> <literal>GTK_SHADOW_IN</literal> when the check button's <enumname>GtkStateType</enumname> is set as <literal>GTK_STATE_ACTIVE</literal>. - </para> + </simpara> <simpara> See also: <classname>GtkButton</classname>, <classname>GtkCheckMenuItem</classname>, Index: php-gtk-doc/en/reference/gtk/gtkcheckmenuitem.xml diff -u php-gtk-doc/en/reference/gtk/gtkcheckmenuitem.xml:1.8 php-gtk-doc/en/reference/gtk/gtkcheckmenuitem.xml:1.9 --- php-gtk-doc/en/reference/gtk/gtkcheckmenuitem.xml:1.8 Tue Jun 17 17:27:57 2003 +++ php-gtk-doc/en/reference/gtk/gtkcheckmenuitem.xml Wed Jun 18 13:19:26 2003 @@ -31,19 +31,17 @@ Creates a <classname>GtkMenuItem</classname> with a toggle indicator. </shortdesc> <desc> - <para> - <informalexample> - <programlisting role="php"> + <simpara> + <literal> $checkmenuitem = &new GtkCheckMenuItem("CheckMenuItem's Label"); - </programlisting> - </informalexample> + </literal> is the syntax that will create a new menu item with an indigenous toggle indicator placed to the left of any existing text. The <classname>GtkCheckMenuItem</classname> may be set to the active state - <enumname>GtkStateType</enumname> <literal>GTK_STATE_ACTIVE</literal> - or to the inactive state, <literal>GTK_STATE_NORMAL</literal>. When it is in the inactive state, the toggle indicator need not be displayed. - </para> + </simpara> </desc> </constructor> @@ -68,15 +66,11 @@ When the menu item is in its active state, the toggle indicator is always displayed. </simpara> - <para> - <informalexample> - <programlisting role="php"> -$checkmenuitem->set_active(true); - </programlisting> - </informalexample> + <simpara> + <literal>$checkmenuitem->set_active(true);</literal> will set the <classname>GtkCheckMenuItem</classname>'s state to <literal>active</literal>. - </para> + </simpara> <simpara> The default setting is <literal>false</literal>. </simpara> Index: php-gtk-doc/en/reference/gtk/gtkentry.xml diff -u php-gtk-doc/en/reference/gtk/gtkentry.xml:1.8 php-gtk-doc/en/reference/gtk/gtkentry.xml:1.9 --- php-gtk-doc/en/reference/gtk/gtkentry.xml:1.8 Tue Jun 17 17:27:57 2003 +++ php-gtk-doc/en/reference/gtk/gtkentry.xml Wed Jun 18 13:19:26 2003 @@ -127,13 +127,11 @@ <function class="GtkEntry">set_text</function> sets a string of given text in the entry field. </simpara> - <para> - <informalexample> - <programlisting role="php"> -$entry-gt;set_text("Programmed text entry"); - </programlisting> - </informalexample> - </para> + <simpara> + <literal> + $entry-gt;set_text("Programmed text entry"); + </literal> + </simpara> </desc> </method> @@ -152,13 +150,11 @@ <function class="GtkEntry">append_text</function> adds the given string to the end of any entered text. </simpara> - <para> - <informalexample> - <programlisting role="php"> -$entry->append_text("</END>"); - </programlisting> - </informalexample> - </para> + <simpara> + <literal> + $entry->append_text("</END>"); + </literal> + </simpara> </desc> </method> @@ -177,13 +173,11 @@ <function class="GtkEntry">prepend_text</function> adds the given string to the start of any entered text. </simpara> - <para> - <informalexample> - <programlisting role="php"> -$entry->prepend_text("<START>"); - </programlisting> - </informalexample> - </para> + <simpara> + <literal> + $entry->prepend_text("<START>"); + </literal> + </simpara> </desc> </method> Index: php-gtk-doc/en/reference/gtk/gtkfileselection.xml diff -u php-gtk-doc/en/reference/gtk/gtkfileselection.xml:1.11 php-gtk-doc/en/reference/gtk/gtkfileselection.xml:1.12 --- php-gtk-doc/en/reference/gtk/gtkfileselection.xml:1.11 Tue Jun 17 17:27:57 2003 +++ php-gtk-doc/en/reference/gtk/gtkfileselection.xml Wed Jun 18 13:19:26 2003 @@ -36,24 +36,16 @@ Creates a new <classname>GtkFileSelection</classname> widget. </shortdesc> <desc> - <para> + <simpara> The syntax to create a <classname>GtkFileSelection</classname> widget is: - <informalexample> - <programlisting role="php"> -<![CDATA[ -<?php - -$fs = &new GtkFileSelection("My File Selection"); - -?> -]]> - </programlisting> - </informalexample> + <literal> + $fs = &new GtkFileSelection("My File Selection"); + </literal> Note that if the <parameter>title</parameter> parameter is not supplied or is <literal>NULL</literal> the title will be set to the name of the file in which the PHP code resides. - </para> + </simpara> </desc> </constructor> @@ -73,19 +65,11 @@ <simpara> Sets the default path for the directory and/or file name. </simpara> - <para> - <informalexample> - <programlisting role = "php"> -<![CDATA[ -<?php - -$fs->set_filename("/home/user/php/"); - -?> -]]> - </programlisting> - </informalexample> - </para> + <simpara> + <literal> + $fs->set_filename("/home/user/php/"); + </literal> + </simpara> </desc> </method> @@ -105,19 +89,11 @@ selector. If no directory or file has been selected then the current path is returned. </simpara> - <para> - <informalexample> - <programlisting role="php"> -<![CDATA[ -<?php - -$filename = $fs->get_filename(); - -?> -]]> - </programlisting> - </informalexample> - </para> + <simpara> + <literal> + $filename = $fs->get_filename(); + </literal> + </simpara> </desc> </method> @@ -147,19 +123,11 @@ <simpara> Note that only a single wildcard field is effective here. </simpara> - <para> - <informalexample> - <programlisting role="php"> -<![CDATA[ -<?php - -$fs->complete("*.php"); - -?> -]]> - </programlisting> - </informalexample> - </para> + <simpara> + <literal> + $fs->complete("*.php"); + </literal> + </simpara> </desc> </method> @@ -186,19 +154,9 @@ buttons do not need any programming in order to carry out their respective functions, as these are already hard-coded into GTK+. </simpara> - <para> - <informalexample> - <programlisting role="php"> -<![CDATA[ -<?php - -$fs->show_fileop_buttons(); - -?> -]]> - </programlisting> - </informalexample> - </para> + <simpara> + <literal>$fs->show_fileop_buttons();</literal> + </simpara> </desc> </method> @@ -222,19 +180,9 @@ is useful where the programmer would prefer the end user not to have easy access to these file operations. </simpara> - <para> - <informalexample> - <programlisting role="php"> -<![CDATA[ -<?php - -$fs->hide_fileop_buttons(); - -?> -]]> - </programlisting> - </informalexample> - </para> + <simpara> + <literal>$fs->hide_fileop_buttons();</literal> + </simpara> </desc> </method> Index: php-gtk-doc/en/reference/gtk/gtkframe.xml diff -u php-gtk-doc/en/reference/gtk/gtkframe.xml:1.8 php-gtk-doc/en/reference/gtk/gtkframe.xml:1.9 --- php-gtk-doc/en/reference/gtk/gtkframe.xml:1.8 Tue Jun 17 17:27:57 2003 +++ php-gtk-doc/en/reference/gtk/gtkframe.xml Wed Jun 18 13:19:26 2003 @@ -58,19 +58,11 @@ <function class="GtkFrame">set_label</function> sets the label text programmatically. </simpara> - <para> - <informalexample> - <programlisting role="php"> -<![CDATA[ -<?php - -$frame->set_label("Alternative text string"); - -?> -]]> - </programlisting> - </informalexample> - </para> + <simpara> + <literal> + $frame->set_label("Alternative text string"); + </literal> + </simpara> </desc> </method> @@ -102,19 +94,9 @@ is <literal>0.5</literal> both currently and in development releases of GTK+, so it would seem advisable to use that value. </simpara> - <para> - <informalexample> - <programlisting role="php"> -<![CDATA[ -<?php - -$frame->set_label_align(0.7, 0.5); - -?> -]]> - </programlisting> - </informalexample> - </para> + <simpara> + <literal>$frame->set_label_align(0.7, 0.5);</literal> + </simpara> </desc> </method> Index: php-gtk-doc/en/reference/gtk/gtkhbox.xml diff -u php-gtk-doc/en/reference/gtk/gtkhbox.xml:1.10 php-gtk-doc/en/reference/gtk/gtkhbox.xml:1.11 --- php-gtk-doc/en/reference/gtk/gtkhbox.xml:1.10 Tue Jun 17 17:27:57 2003 +++ php-gtk-doc/en/reference/gtk/gtkhbox.xml Wed Jun 18 13:19:26 2003 @@ -53,7 +53,7 @@ Creates a new horizontal box container designed for packing a single row of child widgets. </simpara> - <para> + <simpara> The first parameter, <parameter>homogeneous</parameter>, is a boolean value which, if set to <literal>true</literal>, will set each child widget in the <classname>GtkHBox</classname> to the same width as that @@ -61,19 +61,9 @@ <parameter>spacing</parameter>, sets the minimum spacing between the child widgets along the width of the container, in pixels. Leaving both parameters empty, e.g. - <informalexample> - <programlisting role="php"> -<![CDATA[ -<?php - -$hbox = &new GtkHBox(); - -?> -]]> - </programlisting> - </informalexample> + <literal>$hbox = &new GtkHBox();</literal> will set the default behaviour of individual sizing and zero spacing. - </para> + </simpara> </desc> </constructor> Index: php-gtk-doc/en/reference/gtk/gtkhbuttonbox.xml diff -u php-gtk-doc/en/reference/gtk/gtkhbuttonbox.xml:1.7 php-gtk-doc/en/reference/gtk/gtkhbuttonbox.xml:1.8 --- php-gtk-doc/en/reference/gtk/gtkhbuttonbox.xml:1.7 Tue Jun 17 17:27:57 2003 +++ php-gtk-doc/en/reference/gtk/gtkhbuttonbox.xml Wed Jun 18 13:19:26 2003 @@ -30,21 +30,13 @@ Creates the basis for a horizontal button container. </shortdesc> <desc> - <para> + <simpara> The syntax for creating a horizontal buttonbox is: - <informalexample> - <programlisting role="php"> -<![CDATA[ -<?php - + <literal> $hbuttonbox = &new GtkHButtonBox(); - -?> -]]> - </programlisting> - </informalexample> + </literal> There are no parameters. - </para> + </simpara> <simpara> As with all container widgets, no physical space is taken by a <classname>GtkHButtonBox</classname> until its child widgets Index: php-gtk-doc/en/reference/gtk/gtkhpaned.xml diff -u php-gtk-doc/en/reference/gtk/gtkhpaned.xml:1.8 php-gtk-doc/en/reference/gtk/gtkhpaned.xml:1.9 --- php-gtk-doc/en/reference/gtk/gtkhpaned.xml:1.8 Tue Jun 17 17:27:57 2003 +++ php-gtk-doc/en/reference/gtk/gtkhpaned.xml Wed Jun 18 13:19:26 2003 @@ -31,16 +31,14 @@ Creates the basis for a horizontal dual-paned container. </shortdesc> <desc> - <para> + <simpara> The <classname>GtkHPaned</classname> widget should be thought of in terms of an arrangement of two child widgets, rather than as an object in its own right. The construct - <informalexample> - <programlisting role="php">$hbox = &new GtkHBox();</programlisting> - </informalexample> + <literal>$hbox = &new GtkHBox();</literal> needs to be within a containing <classname>GtkWindow</classname> and to contain two child widgets of its own in order to work. - </para> + </simpara> <para> <example> <title>Constructing a <classname>GtkHPaned widget</classname></title> Index: php-gtk-doc/en/reference/gtk/gtklabel.xml diff -u php-gtk-doc/en/reference/gtk/gtklabel.xml:1.11 php-gtk-doc/en/reference/gtk/gtklabel.xml:1.12 --- php-gtk-doc/en/reference/gtk/gtklabel.xml:1.11 Tue Jun 17 17:27:57 2003 +++ php-gtk-doc/en/reference/gtk/gtklabel.xml Wed Jun 18 13:19:26 2003 @@ -95,19 +95,11 @@ <function class="GtkLabel">set_pattern</function> with no parameters to erase these. </simpara> - <para> - <informalexample> - <programlisting role="php"> -<![CDATA[ -<?php - -$label->set_text("Whatever text you wish to pass"); - -?> -]]> - </programlisting> - </informalexample> - </para> + <simpara> + <literal> + $label->set_text("Whatever text you wish to pass"); + </literal> + </simpara> </desc> </method> @@ -181,19 +173,9 @@ underscore or space in the pattern maps directly to the character position in the label text. </simpara> - <para> - <informalexample> - <programlisting role="php"> -<![CDATA[ -<?php - -$label->set_pattern("_ _"); - -?> -]]> - </programlisting> - </informalexample> - </para> + <simpara> + <literal>$label->set_pattern("_ _");</literal> + </simpara> <simpara> Call this method with no parameters to erase existing underlines. </simpara> @@ -218,19 +200,9 @@ <literal>false</literal>, those lines will be cut off at the widget's edge. </simpara> - <para> - <informalexample> - <programlisting role="php"> -<![CDATA[ -<?php - -$label->set_line_wrap(true); - -?> -]]> - </programlisting> - </informalexample> - </para> + <simpara> + <literal>$label->set_line_wrap(true);</literal> + </simpara> </desc> </method> @@ -254,19 +226,9 @@ by <literal>get_text()</literal>. </simpara> </note> - <para> - <informalexample> - <programlisting role="php"> -<![CDATA[ -<?php - -$label->get(); - -?> -]]> - </programlisting> - </informalexample> - </para> + <simpara> + <literal>$label->get();</literal> + </simpara> </desc> </method> @@ -297,19 +259,9 @@ Note that this method is deprecated in GTK+ 2.0. </simpara> </note> - <para> - <informalexample> - <programlisting role="php"> -<![CDATA[ -<?php - -$label->parse_uline("_File"); - -?> -]]> - </programlisting> - </informalexample> - </para> + <simpara> + <literal>$label->parse_uline("_File");</literal> + </simpara> </desc> </method> Index: php-gtk-doc/en/reference/gtk/gtklist.xml diff -u php-gtk-doc/en/reference/gtk/gtklist.xml:1.7 php-gtk-doc/en/reference/gtk/gtklist.xml:1.8 --- php-gtk-doc/en/reference/gtk/gtklist.xml:1.7 Tue Jun 17 17:27:57 2003 +++ php-gtk-doc/en/reference/gtk/gtklist.xml Wed Jun 18 13:19:26 2003 @@ -755,13 +755,7 @@ array that contains any currently selected items. If there is no current selection, the array will be empty. If the selection mode does not allow multiple selection, - <programlisting role="php"> -<![CDATA[ -<?php -$list->selection[0]; -?> -]]> - </programlisting> will + <literal>$list->selection[0];</literal> will return the selected item. If the selection mode allows multiple selection, there will be as many elements in the array as there are currently-selected objects. Index: php-gtk-doc/en/reference/gtk/gtkmenu.xml diff -u php-gtk-doc/en/reference/gtk/gtkmenu.xml:1.11 php-gtk-doc/en/reference/gtk/gtkmenu.xml:1.12 --- php-gtk-doc/en/reference/gtk/gtkmenu.xml:1.11 Tue Jun 17 17:27:57 2003 +++ php-gtk-doc/en/reference/gtk/gtkmenu.xml Wed Jun 18 13:19:26 2003 @@ -209,16 +209,7 @@ <literal>0</literal> will make the menu disappear as soon as the user releases the mouse-button that triggered it. The safest setting for this parameter is - <programlisting> -<![CDATA[ -<?php - -$event->time - -?> -]]> - - </programlisting> - + <literal>$event->time</literal> - this being a setting that all <classname>GdkEvent</classname> structures share; it causes the popup menu to react as you'd expect it to, and won't spring any surprises if you duplicate or otherwise adapt Index: php-gtk-doc/en/reference/gtk/gtkobject.xml diff -u php-gtk-doc/en/reference/gtk/gtkobject.xml:1.10 php-gtk-doc/en/reference/gtk/gtkobject.xml:1.11 --- php-gtk-doc/en/reference/gtk/gtkobject.xml:1.10 Tue Jun 17 17:27:57 2003 +++ php-gtk-doc/en/reference/gtk/gtkobject.xml Wed Jun 18 13:19:26 2003 @@ -334,7 +334,8 @@ object. For example, in <filename>gtklabel.c</filename> in GTK 1.2.10 you will see this directly after the includes: <informalexample> - <programlisting> + <programlisting> +<![CDATA[ enum { ARG_0, ARG_LABEL, @@ -342,13 +343,15 @@ ARG_JUSTIFY, ARG_WRAP }; +]]> </programlisting> </informalexample> Around a hundred lines later, these argument types are defined as they are added to the widget, in the <literal>class_init</literal> function: <informalexample> - <programlisting> + <programlisting> +<![CDATA[ gtk_object_add_arg_type ("GtkLabel::label", GTK_TYPE_STRING, GTK_ARG_READWRITE, ARG_LABEL); gtk_object_add_arg_type ("GtkLabel::pattern", GTK_TYPE_STRING, @@ -357,6 +360,7 @@ GTK_TYPE_JUSTIFICATION, GTK_ARG_READWRITE, ARG_JUSTIFY); gtk_object_add_arg_type ("GtkLabel::wrap", GTK_TYPE_BOOL, GTK_ARG_READWRITE, ARG_WRAP); +]]> </programlisting> </informalexample> </para> Index: php-gtk-doc/en/reference/gtk/gtkpaned.xml diff -u php-gtk-doc/en/reference/gtk/gtkpaned.xml:1.10 php-gtk-doc/en/reference/gtk/gtkpaned.xml:1.11 --- php-gtk-doc/en/reference/gtk/gtkpaned.xml:1.10 Tue Jun 17 17:27:57 2003 +++ php-gtk-doc/en/reference/gtk/gtkpaned.xml Wed Jun 18 13:19:26 2003 @@ -212,20 +212,10 @@ without regard to the size requests of the child widgets in the panes. It is overridden by the user's repositioning of the dividing handle. </simpara> - <para> + <simpara> To unset the position of the dividing handle, use - <informalexample> - <programlisting role="php"> -<![CDATA[ -<?php - -$paned->set_position(-1); - -?> -]]> - </programlisting> - </informalexample> - </para> + <literal>$paned->set_position(-1);</literal> + </simpara> </desc> </method> Index: php-gtk-doc/en/reference/gtk/gtkprogressbar.xml diff -u php-gtk-doc/en/reference/gtk/gtkprogressbar.xml:1.9 php-gtk-doc/en/reference/gtk/gtkprogressbar.xml:1.10 --- php-gtk-doc/en/reference/gtk/gtkprogressbar.xml:1.9 Tue Jun 17 17:27:57 2003 +++ php-gtk-doc/en/reference/gtk/gtkprogressbar.xml Wed Jun 18 13:19:26 2003 @@ -60,8 +60,7 @@ <para> <example> <title>Setting up a Progress Bar</title> - <programlisting role="php"> - + <programlisting role="php"> <![CDATA[ <?php @@ -109,36 +108,12 @@ </example> To create a progress bar in <literal>activity</literal> mode, delete the references to the text string and replace them with - <programlisting role="php"> -<![CDATA[ -<?php - -$progressbar->set_activity_mode(true); - -?> -]]> - </programlisting> + <literal>$progressbar->set_activity_mode(true);</literal> and any further methods appropriate to an activity indicator. You will also need to replace - <programlisting role="php"> -<![CDATA[ -<?php - -$progressbar->set_percentage($value); - -?> -]]> - </programlisting> + <literal>$progressbar->set_percentage($value);</literal> in the <literal>update_bar()</literal> function with - <programlisting role="php"> -<![CDATA[ -<?php - -$progressbar->set_value($value); - -?> -]]> - </programlisting> + <literal>$progressbar->set_value($value);</literal> </para> <simpara> Note that a progress bar in <literal>activity</literal> mode will not Index: php-gtk-doc/en/reference/gtk/gtktext.xml diff -u php-gtk-doc/en/reference/gtk/gtktext.xml:1.11 php-gtk-doc/en/reference/gtk/gtktext.xml:1.12 --- php-gtk-doc/en/reference/gtk/gtktext.xml:1.11 Tue Jun 17 17:27:57 2003 +++ php-gtk-doc/en/reference/gtk/gtktext.xml Wed Jun 18 13:19:26 2003 @@ -458,20 +458,12 @@ by a user. The default length <literal>-1</literal> will allow the entire string. </simpara> - <para> + <simpara> You can use the current default style with: - <informalexample> - <programlisting role="php"> -<![CDATA[ -<?php - -$text->insert(null, null, null, "A string of text."); - -?> -]]> - </programlisting> - </informalexample> - </para> + <literal> + $text->insert(null, null, null, "A string of text."); + </literal> + </simpara> </desc> </method> Index: php-gtk-doc/en/reference/gtk/gtktogglebutton.xml diff -u php-gtk-doc/en/reference/gtk/gtktogglebutton.xml:1.7 php-gtk-doc/en/reference/gtk/gtktogglebutton.xml:1.8 --- php-gtk-doc/en/reference/gtk/gtktogglebutton.xml:1.7 Tue Jun 17 17:27:57 2003 +++ php-gtk-doc/en/reference/gtk/gtktogglebutton.xml Wed Jun 18 13:19:26 2003 @@ -41,21 +41,13 @@ Creates a button that can be toggled between two states. </shortdesc> <desc> - <para> - <informalexample> - <programlisting role="php"> -<![CDATA[ -<?php - -$togglebutton = &new GtkToggleButton("GtkToggleButton's label"); - -?> -]]> - </programlisting> - </informalexample> + <simpara> + <literal> + $togglebutton = &new GtkToggleButton("GtkToggleButton's label"); + </literal> creates a <classname>GtkToggleButton</classname> that can be toggled between active and normal states. - </para> + </simpara> </desc> </constructor> @@ -213,20 +205,10 @@ drawn or not. It is exposed here so that the value of the indicator's mode setting can be tested programmatically. </simpara> - <para> + <simpara> The property can be accessed using the syntax - <informalexample> - <programlisting role="php"> -<![CDATA[ -<?php - -$togglebutton->draw_indicator; - -?> -]]> - </programlisting> - </informalexample> - </para> + <literal>$togglebutton->draw_indicator;</literal> + </simpara> <simpara> The <propname>draw_indicator</propname> property should not be accessed directly. Use <function class="GtkToggleButton">set_mode</function> Index: php-gtk-doc/en/reference/gtk/gtkvbox.xml diff -u php-gtk-doc/en/reference/gtk/gtkvbox.xml:1.10 php-gtk-doc/en/reference/gtk/gtkvbox.xml:1.11 --- php-gtk-doc/en/reference/gtk/gtkvbox.xml:1.10 Tue Jun 17 17:27:57 2003 +++ php-gtk-doc/en/reference/gtk/gtkvbox.xml Wed Jun 18 13:19:26 2003 @@ -49,26 +49,16 @@ Creates a new vertical box container designed for packing a single column of child widgets. </simpara> - <para> + <simpara> The first parameter, <parameter>homogeneous</parameter>, is a boolean value which, if set to <literal>true</literal>, will set each child widget in the <classname>GtkVBox</classname> to the same height as that of the largest child widget. The second parameter, <parameter>spacing</parameter>, sets the minimum spacing between the child widgets, in pixels. Leaving both parameters empty, e.g. - <informalexample> - <programlisting role="php"> -<![CDATA[ -<?php - -$vbox = &new GtkVBox(); - -?> -]]> - </programlisting> - </informalexample> + <literal>$vbox = &new GtkVBox();</literal> will set the default behaviour of individual sizing and zero spacing. - </para> + </simpara> <para> <example> <title>Packing child widgets using <classname>GtkVBox</classname> and Index: php-gtk-doc/en/reference/gtk/gtkvbuttonbox.xml diff -u php-gtk-doc/en/reference/gtk/gtkvbuttonbox.xml:1.7 php-gtk-doc/en/reference/gtk/gtkvbuttonbox.xml:1.8 --- php-gtk-doc/en/reference/gtk/gtkvbuttonbox.xml:1.7 Tue Jun 17 17:27:57 2003 +++ php-gtk-doc/en/reference/gtk/gtkvbuttonbox.xml Wed Jun 18 13:19:26 2003 @@ -30,21 +30,11 @@ Creates the basis for a vertical button container. </shortdesc> <desc> - <para> + <simpara> The syntax for creating a vertical buttonbox is: - <informalexample> - <programlisting role="php"> -<![CDATA[ -<?php - -$vbuttonbox = &new GtkVButtonBox(); - -?> -]]> - </programlisting> - </informalexample> + <literal>$vbuttonbox = &new GtkVButtonBox();</literal> There are no parameters. - </para> + </simpara> <simpara> As with all container widgets, no physical space is taken by a <classname>GtkVButtonBox</classname> until its child widgets Index: php-gtk-doc/en/reference/gtk/gtkvpaned.xml diff -u php-gtk-doc/en/reference/gtk/gtkvpaned.xml:1.6 php-gtk-doc/en/reference/gtk/gtkvpaned.xml:1.7 --- php-gtk-doc/en/reference/gtk/gtkvpaned.xml:1.6 Sun Jan 20 14:47:43 2002 +++ php-gtk-doc/en/reference/gtk/gtkvpaned.xml Wed Jun 18 13:19:26 2003 @@ -31,16 +31,14 @@ Creates the basis for a vertical dual-paned container. </shortdesc> <desc> - <para> + <simpara> The <classname>GtkVPaned</classname> widget should be thought of in terms of an arrangement of two child widgets, rather than as an object in its own right. The construct - <informalexample> - <programlisting role="php">$vbox = &new GtkVBox();</programlisting> - </informalexample> + <literal>$vbox = &new GtkVBox();</literal> needs to be within a containing <classname>GtkWindow</classname> and to contain two child widgets of its own in order to work. - </para> + </simpara> <simpara> There is a code sample demonstrating the construction of a paned widget under the entry for the Index: php-gtk-doc/en/reference/gtk/gtkwidget.xml diff -u php-gtk-doc/en/reference/gtk/gtkwidget.xml:1.19 php-gtk-doc/en/reference/gtk/gtkwidget.xml:1.20 --- php-gtk-doc/en/reference/gtk/gtkwidget.xml:1.19 Tue Jun 17 17:27:57 2003 +++ php-gtk-doc/en/reference/gtk/gtkwidget.xml Wed Jun 18 13:19:26 2003 @@ -1041,23 +1041,15 @@ <function class="GtkWidget">set_events</function> can be used at any point in the widget's life-cycle. </simpara> - <para> + <simpara> Staying with the key-press example, the syntax would be: - <informalexample> - <programlisting role="php"> -<![CDATA[ -<?php - -$widget->set_events(GDK_KEY_PRESS_MASK | GDK_KEY_RELEASE_MASK); - -?> -]]> - </programlisting> - </informalexample> + <literal> + $widget->set_events(GDK_KEY_PRESS_MASK | GDK_KEY_RELEASE_MASK); + </literal> This would enable a previously keyboard-insensitive widget to emit <signalname class="GtkWidget">key-press-event</signalname> and <signalname class="GtkWidget">key-release-event</signalname> signals. - </para> + </simpara> </desc> </method> @@ -1089,23 +1081,15 @@ <function class="GtkWidget">show</function> routine as well as being a method/signal pair in its own right. </simpara> - <para> + <simpara> Staying with the button-press example, the syntax would be: - <informalexample> - <programlisting role="php"> -<![CDATA[ -<?php - -$widget->add_events(GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK); - -?> -]]> - </programlisting> - </informalexample> + <literal> + $widget->add_events(GDK_BUTTON_PRESS_MASK|GDK_BUTTON_RELEASE_MASK); + </literal> This would enable a previously mouse-insensitive widget to emit <signalname class="GtkWidget">button-press-event</signalname> and <signalname class="GtkWidget">button-release-event</signalname> signals. - </para> + </simpara> </desc> </method> @@ -2019,11 +2003,12 @@ function on_click($widget, $event, $data) { if($event->keyval==GDK_KEY_Return) { /*do something appropriate for the return key being pressed*/ -} + } elseif($event->keyval > GDK_KEY__a) { /*we can reach the character strings, too*/ -echo $event->string."\n"; -}} + echo $event->string."\n"; + } +} ?> ]]>
Index: php-gtk-doc/en/reference/gtk/gtk-functions.xml diff -u php-gtk-doc/en/reference/gtk/gtk-functions.xml:1.9 php-gtk-doc/en/reference/gtk/gtk-functions.xml:1.10 --- php-gtk-doc/en/reference/gtk/gtk-functions.xml:1.9 Tue Jun 17 17:27:57 2003 +++ php-gtk-doc/en/reference/gtk/gtk-functions.xml Wed Jun 18 13:19:26 2003 @@ -312,14 +312,12 @@ color as the area it is drawn onto. All positions and sizes are absolute in terms of the underlying drawable. </simpara> - <para> - <informalexample> - <programlisting role="php"> -gtk::draw_arrow($style, $gdkwindow, GTK_STATE_NORMAL, GTK_SHADOW_OUT, -GTK_ARROW_RIGHT, false, $x, $y, $width, $height); - </programlisting> - </informalexample> - </para> + <simpara> + <literal> + gtk::draw_arrow($style, $gdkwindow, GTK_STATE_NORMAL, GTK_SHADOW_OUT, + GTK_ARROW_RIGHT, false, $x, $y, $width, $height); + </literal> + </simpara> </desc> </method> @@ -358,14 +356,12 @@ Any coloring is completely dependant on the <classname>GtkStyle</classname> that is passed as the first parameter. </simpara> - <para> - <informalexample> - <programlisting role="php"> -gtk::draw_box($style, $gdkwindow, GTK_STATE_ACTIVE, GTK_SHADOW_IN, $x, $y, -$width, $height); - </programlisting> - </informalexample> - </para> + <simpara> + <literal> + gtk::draw_box($style, $gdkwindow, GTK_STATE_ACTIVE, GTK_SHADOW_IN, + $x, $y, $width, $height); + </literal> + </simpara> </desc> </method> @@ -596,7 +592,13 @@ The way it would be used in such a situation is to have <informalexample> <programlisting role="php"> +<![CDATA[ +<?php + while(gtk::events_pending()) gtk::main_iteration(); + +?> +]]> </programlisting> </informalexample> after every update that is made to the GUI. This causes the main loop Index: php-gtk-doc/en/reference/gtk/gtkaccelgroup.xml diff -u php-gtk-doc/en/reference/gtk/gtkaccelgroup.xml:1.6 php-gtk-doc/en/reference/gtk/gtkaccelgroup.xml:1.7 --- php-gtk-doc/en/reference/gtk/gtkaccelgroup.xml:1.6 Tue Jun 17 17:27:57 2003 +++ php-gtk-doc/en/reference/gtk/gtkaccelgroup.xml Wed Jun 18 13:19:26 2003 @@ -41,16 +41,12 @@ Provides the structure for a hash table of accelerator key information. </shortdesc> <desc> - <para> + <simpara> Although not a part of the GTK object hierarchy, <classname>GtkAccelGroup</classname> can be constructed in the same way as most GTK classes, i.e. - <informalexample> - <programlisting role="php"> -$accelgroup = &new GtkAccelGroup(); - </programlisting> - </informalexample> - </para> + <literal>$accelgroup = &new GtkAccelGroup();</literal> + </simpara> <simpara> In most cases, the newly-constructed <classname>GtkAccelGroup</classname> would be used by all the menus belonging to that toplevel window, and Index: php-gtk-doc/en/reference/gtk/gtkaccellabel.xml diff -u php-gtk-doc/en/reference/gtk/gtkaccellabel.xml:1.6 php-gtk-doc/en/reference/gtk/gtkaccellabel.xml:1.7 --- php-gtk-doc/en/reference/gtk/gtkaccellabel.xml:1.6 Tue Jun 17 17:27:57 2003 +++ php-gtk-doc/en/reference/gtk/gtkaccellabel.xml Wed Jun 18 13:19:26 2003 @@ -20,17 +20,13 @@ need to access it, for instance to parse an underline in a label's text string or to retrieve a menu's textual content. </simpara> - <para> + <simpara> To access the <classname>GtkAccelLabel</classname> within an existing menu item, use the following code: - <informalexample> - <programlisting role="php"> -$accel_label = $menu_item->child; - </programlisting> - </informalexample> + <literal>$accel_label = $menu_item->child;</literal> You will then be able to call most of the methods available to a new instance of a <classname>GtkAccelLabel</classname>. - </para> + </simpara> </desc> </classmeta> Index: php-gtk-doc/en/reference/gtk/gtkarrow.xml diff -u php-gtk-doc/en/reference/gtk/gtkarrow.xml:1.8 php-gtk-doc/en/reference/gtk/gtkarrow.xml:1.9 --- php-gtk-doc/en/reference/gtk/gtkarrow.xml:1.8 Tue Jun 17 17:27:57 2003 +++ php-gtk-doc/en/reference/gtk/gtkarrow.xml Wed Jun 18 13:19:26 2003 @@ -51,20 +51,12 @@ arrow can be redefined at any point using the <function class="GtkArrow">set</function> method. </simpara> - <para> + <simpara> The syntax to create a right-pointing, etched arrow would be: - <informalexample> - <programlisting role="php"> -<![CDATA[ -<?php - -$arrow = &new GtkArrow(GTK_ARROW_RIGHT, GTK_SHADOW_ETCHED_IN); - -?> -]]> - </programlisting> - </informalexample> - </para> + <literal> + $arrow = &new GtkArrow(GTK_ARROW_RIGHT, GTK_SHADOW_ETCHED_IN); + </literal> + </simpara> </desc> </constructor> Index: php-gtk-doc/en/reference/gtk/gtkbin.xml diff -u php-gtk-doc/en/reference/gtk/gtkbin.xml:1.12 php-gtk-doc/en/reference/gtk/gtkbin.xml:1.13 --- php-gtk-doc/en/reference/gtk/gtkbin.xml:1.12 Tue Jun 17 17:27:57 2003 +++ php-gtk-doc/en/reference/gtk/gtkbin.xml Wed Jun 18 13:19:26 2003 @@ -40,19 +40,9 @@ is <literal>NULL</literal>, then <classname>GtkBin</classname> object does not contain a child widget. </simpara> - <para> - <informalexample> - <programlisting role="php"> -<![CDATA[ -<?php - -$button->remove($button->child); - -?> -]]> - </programlisting> - </informalexample> - </para> + <simpara> + <literal>$button->remove($button->child);</literal> + </simpara> </desc> </prop> Index: php-gtk-doc/en/reference/gtk/gtkbox.xml diff -u php-gtk-doc/en/reference/gtk/gtkbox.xml:1.13 php-gtk-doc/en/reference/gtk/gtkbox.xml:1.14 --- php-gtk-doc/en/reference/gtk/gtkbox.xml:1.13 Tue Jun 17 17:27:57 2003 +++ php-gtk-doc/en/reference/gtk/gtkbox.xml Wed Jun 18 13:19:26 2003 @@ -131,15 +131,11 @@ container using the default parameter values <literal>true</literal>, <literal>true</literal>, <literal>0</literal>. </simpara> - <para> + <simpara> The same result can be achieved by using - <informalexample> - <programlisting role="php"> -$box->pack_start($child); - </programlisting> - </informalexample> + <literal>$box->pack_start($child);</literal> without specifying any further parameters. - </para> + </simpara> </desc> </method> @@ -162,15 +158,11 @@ container using the default parameter values <literal>true</literal>, <literal>true</literal>, <literal>0</literal>. </simpara> - <para> + <simpara> The same result can be achieved by using - <informalexample> - <programlisting role="php"> -$box->pack_end($child); - </programlisting> - </informalexample> + <literal>$box->pack_end($child);</literal> without specifying any further parameters. - </para> + </simpara> </desc> </method> Index: php-gtk-doc/en/reference/gtk/gtkcheckbutton.xml diff -u php-gtk-doc/en/reference/gtk/gtkcheckbutton.xml:1.5 php-gtk-doc/en/reference/gtk/gtkcheckbutton.xml:1.6 --- php-gtk-doc/en/reference/gtk/gtkcheckbutton.xml:1.5 Sun Jan 20 14:47:43 2002 +++ php-gtk-doc/en/reference/gtk/gtkcheckbutton.xml Wed Jun 18 13:19:26 2003 @@ -34,19 +34,17 @@ Creates a button with a small toggle indicator. </shortdesc> <desc> - <para> - <informalexample> - <programlisting role="php"> + <simpara> + <literal> $checkbutton = &new GtkCheckButton("GtkCheckButton label"); - </programlisting> - </informalexample> + </literal> instantiates a normal-sized <classname>GtkButton</classname> with a small draw_indicator toggle to the left of the button's label area. The indicator displays the <enumname>GtkShadowType</enumname> <literal>GTK_SHADOW_IN</literal> when the check button's <enumname>GtkStateType</enumname> is set as <literal>GTK_STATE_ACTIVE</literal>. - </para> + </simpara> <simpara> See also: <classname>GtkButton</classname>, <classname>GtkCheckMenuItem</classname>, Index: php-gtk-doc/en/reference/gtk/gtkcheckmenuitem.xml diff -u php-gtk-doc/en/reference/gtk/gtkcheckmenuitem.xml:1.8 php-gtk-doc/en/reference/gtk/gtkcheckmenuitem.xml:1.9 --- php-gtk-doc/en/reference/gtk/gtkcheckmenuitem.xml:1.8 Tue Jun 17 17:27:57 2003 +++ php-gtk-doc/en/reference/gtk/gtkcheckmenuitem.xml Wed Jun 18 13:19:26 2003 @@ -31,19 +31,17 @@ Creates a <classname>GtkMenuItem</classname> with a toggle indicator. </shortdesc> <desc> - <para> - <informalexample> - <programlisting role="php"> + <simpara> + <literal> $checkmenuitem = &new GtkCheckMenuItem("CheckMenuItem's Label"); - </programlisting> - </informalexample> + </literal> is the syntax that will create a new menu item with an indigenous toggle indicator placed to the left of any existing text. The <classname>GtkCheckMenuItem</classname> may be set to the active state - <enumname>GtkStateType</enumname> <literal>GTK_STATE_ACTIVE</literal> - or to the inactive state, <literal>GTK_STATE_NORMAL</literal>. When it is in the inactive state, the toggle indicator need not be displayed. - </para> + </simpara> </desc> </constructor> @@ -68,15 +66,11 @@ When the menu item is in its active state, the toggle indicator is always displayed. </simpara> - <para> - <informalexample> - <programlisting role="php"> -$checkmenuitem->set_active(true); - </programlisting> - </informalexample> + <simpara> + <literal>$checkmenuitem->set_active(true);</literal> will set the <classname>GtkCheckMenuItem</classname>'s state to <literal>active</literal>. - </para> + </simpara> <simpara> The default setting is <literal>false</literal>. </simpara> Index: php-gtk-doc/en/reference/gtk/gtkentry.xml diff -u php-gtk-doc/en/reference/gtk/gtkentry.xml:1.8 php-gtk-doc/en/reference/gtk/gtkentry.xml:1.9 --- php-gtk-doc/en/reference/gtk/gtkentry.xml:1.8 Tue Jun 17 17:27:57 2003 +++ php-gtk-doc/en/reference/gtk/gtkentry.xml Wed Jun 18 13:19:26 2003 @@ -127,13 +127,11 @@ <function class="GtkEntry">set_text</function> sets a string of given text in the entry field. </simpara> - <para> - <informalexample> - <programlisting role="php"> -$entry-gt;set_text("Programmed text entry"); - </programlisting> - </informalexample> - </para> + <simpara> + <literal> + $entry-gt;set_text("Programmed text entry"); + </literal> + </simpara> </desc> </method> @@ -152,13 +150,11 @@ <function class="GtkEntry">append_text</function> adds the given string to the end of any entered text. </simpara> - <para> - <informalexample> - <programlisting role="php"> -$entry->append_text("</END>"); - </programlisting> - </informalexample> - </para> + <simpara> + <literal> + $entry->append_text("</END>"); + </literal> + </simpara> </desc> </method> @@ -177,13 +173,11 @@ <function class="GtkEntry">prepend_text</function> adds the given string to the start of any entered text. </simpara> - <para> - <informalexample> - <programlisting role="php"> -$entry->prepend_text("<START>"); - </programlisting> - </informalexample> - </para> + <simpara> + <literal> + $entry->prepend_text("<START>"); + </literal> + </simpara> </desc> </method> Index: php-gtk-doc/en/reference/gtk/gtkfileselection.xml diff -u php-gtk-doc/en/reference/gtk/gtkfileselection.xml:1.11 php-gtk-doc/en/reference/gtk/gtkfileselection.xml:1.12 --- php-gtk-doc/en/reference/gtk/gtkfileselection.xml:1.11 Tue Jun 17 17:27:57 2003 +++ php-gtk-doc/en/reference/gtk/gtkfileselection.xml Wed Jun 18 13:19:26 2003 @@ -36,24 +36,16 @@ Creates a new <classname>GtkFileSelection</classname> widget. </shortdesc> <desc> - <para> + <simpara> The syntax to create a <classname>GtkFileSelection</classname> widget is: - <informalexample> - <programlisting role="php"> -<![CDATA[ -<?php - -$fs = &new GtkFileSelection("My File Selection"); - -?> -]]> - </programlisting> - </informalexample> + <literal> + $fs = &new GtkFileSelection("My File Selection"); + </literal> Note that if the <parameter>title</parameter> parameter is not supplied or is <literal>NULL</literal> the title will be set to the name of the file in which the PHP code resides. - </para> + </simpara> </desc> </constructor> @@ -73,19 +65,11 @@ <simpara> Sets the default path for the directory and/or file name. </simpara> - <para> - <informalexample> - <programlisting role = "php"> -<![CDATA[ -<?php - -$fs->set_filename("/home/user/php/"); - -?> -]]> - </programlisting> - </informalexample> - </para> + <simpara> + <literal> + $fs->set_filename("/home/user/php/"); + </literal> + </simpara> </desc> </method> @@ -105,19 +89,11 @@ selector. If no directory or file has been selected then the current path is returned. </simpara> - <para> - <informalexample> - <programlisting role="php"> -<![CDATA[ -<?php - -$filename = $fs->get_filename(); - -?> -]]> - </programlisting> - </informalexample> - </para> + <simpara> + <literal> + $filename = $fs->get_filename(); + </literal> + </simpara> </desc> </method> @@ -147,19 +123,11 @@ <simpara> Note that only a single wildcard field is effective here. </simpara> - <para> - <informalexample> - <programlisting role="php"> -<![CDATA[ -<?php - -$fs->complete("*.php"); - -?> -]]> - </programlisting> - </informalexample> - </para> + <simpara> + <literal> + $fs->complete("*.php"); + </literal> + </simpara> </desc> </method> @@ -186,19 +154,9 @@ buttons do not need any programming in order to carry out their respective functions, as these are already hard-coded into GTK+. </simpara> - <para> - <informalexample> - <programlisting role="php"> -<![CDATA[ -<?php - -$fs->show_fileop_buttons(); - -?> -]]> - </programlisting> - </informalexample> - </para> + <simpara> + <literal>$fs->show_fileop_buttons();</literal> + </simpara> </desc> </method> @@ -222,19 +180,9 @@ is useful where the programmer would prefer the end user not to have easy access to these file operations. </simpara> - <para> - <informalexample> - <programlisting role="php"> -<![CDATA[ -<?php - -$fs->hide_fileop_buttons(); - -?> -]]> - </programlisting> - </informalexample> - </para> + <simpara> + <literal>$fs->hide_fileop_buttons();</literal> + </simpara> </desc> </method> Index: php-gtk-doc/en/reference/gtk/gtkframe.xml diff -u php-gtk-doc/en/reference/gtk/gtkframe.xml:1.8 php-gtk-doc/en/reference/gtk/gtkframe.xml:1.9 --- php-gtk-doc/en/reference/gtk/gtkframe.xml:1.8 Tue Jun 17 17:27:57 2003 +++ php-gtk-doc/en/reference/gtk/gtkframe.xml Wed Jun 18 13:19:26 2003 @@ -58,19 +58,11 @@ <function class="GtkFrame">set_label</function> sets the label text programmatically. </simpara> - <para> - <informalexample> - <programlisting role="php"> -<![CDATA[ -<?php - -$frame->set_label("Alternative text string"); - -?> -]]> - </programlisting> - </informalexample> - </para> + <simpara> + <literal> + $frame->set_label("Alternative text string"); + </literal> + </simpara> </desc> </method> @@ -102,19 +94,9 @@ is <literal>0.5</literal> both currently and in development releases of GTK+, so it would seem advisable to use that value. </simpara> - <para> - <informalexample> - <programlisting role="php"> -<![CDATA[ -<?php - -$frame->set_label_align(0.7, 0.5); - -?> -]]> - </programlisting> - </informalexample> - </para> + <simpara> + <literal>$frame->set_label_align(0.7, 0.5);</literal> + </simpara> </desc> </method> Index: php-gtk-doc/en/reference/gtk/gtkhbox.xml diff -u php-gtk-doc/en/reference/gtk/gtkhbox.xml:1.10 php-gtk-doc/en/reference/gtk/gtkhbox.xml:1.11 --- php-gtk-doc/en/reference/gtk/gtkhbox.xml:1.10 Tue Jun 17 17:27:57 2003 +++ php-gtk-doc/en/reference/gtk/gtkhbox.xml Wed Jun 18 13:19:26 2003 @@ -53,7 +53,7 @@ Creates a new horizontal box container designed for packing a single row of child widgets. </simpara> - <para> + <simpara> The first parameter, <parameter>homogeneous</parameter>, is a boolean value which, if set to <literal>true</literal>, will set each child widget in the <classname>GtkHBox</classname> to the same width as that @@ -61,19 +61,9 @@ <parameter>spacing</parameter>, sets the minimum spacing between the child widgets along the width of the container, in pixels. Leaving both parameters empty, e.g. - <informalexample> - <programlisting role="php"> -<![CDATA[ -<?php - -$hbox = &new GtkHBox(); - -?> -]]> - </programlisting> - </informalexample> + <literal>$hbox = &new GtkHBox();</literal> will set the default behaviour of individual sizing and zero spacing. - </para> + </simpara> </desc> </constructor> Index: php-gtk-doc/en/reference/gtk/gtkhbuttonbox.xml diff -u php-gtk-doc/en/reference/gtk/gtkhbuttonbox.xml:1.7 php-gtk-doc/en/reference/gtk/gtkhbuttonbox.xml:1.8 --- php-gtk-doc/en/reference/gtk/gtkhbuttonbox.xml:1.7 Tue Jun 17 17:27:57 2003 +++ php-gtk-doc/en/reference/gtk/gtkhbuttonbox.xml Wed Jun 18 13:19:26 2003 @@ -30,21 +30,13 @@ Creates the basis for a horizontal button container. </shortdesc> <desc> - <para> + <simpara> The syntax for creating a horizontal buttonbox is: - <informalexample> - <programlisting role="php"> -<![CDATA[ -<?php - + <literal> $hbuttonbox = &new GtkHButtonBox(); - -?> -]]> - </programlisting> - </informalexample> + </literal> There are no parameters. - </para> + </simpara> <simpara> As with all container widgets, no physical space is taken by a <classname>GtkHButtonBox</classname> until its child widgets Index: php-gtk-doc/en/reference/gtk/gtkhpaned.xml diff -u php-gtk-doc/en/reference/gtk/gtkhpaned.xml:1.8 php-gtk-doc/en/reference/gtk/gtkhpaned.xml:1.9 --- php-gtk-doc/en/reference/gtk/gtkhpaned.xml:1.8 Tue Jun 17 17:27:57 2003 +++ php-gtk-doc/en/reference/gtk/gtkhpaned.xml Wed Jun 18 13:19:26 2003 @@ -31,16 +31,14 @@ Creates the basis for a horizontal dual-paned container. </shortdesc> <desc> - <para> + <simpara> The <classname>GtkHPaned</classname> widget should be thought of in terms of an arrangement of two child widgets, rather than as an object in its own right. The construct - <informalexample> - <programlisting role="php">$hbox = &new GtkHBox();</programlisting> - </informalexample> + <literal>$hbox = &new GtkHBox();</literal> needs to be within a containing <classname>GtkWindow</classname> and to contain two child widgets of its own in order to work. - </para> + </simpara> <para> <example> <title>Constructing a <classname>GtkHPaned widget</classname></title> Index: php-gtk-doc/en/reference/gtk/gtklabel.xml diff -u php-gtk-doc/en/reference/gtk/gtklabel.xml:1.11 php-gtk-doc/en/reference/gtk/gtklabel.xml:1.12 --- php-gtk-doc/en/reference/gtk/gtklabel.xml:1.11 Tue Jun 17 17:27:57 2003 +++ php-gtk-doc/en/reference/gtk/gtklabel.xml Wed Jun 18 13:19:26 2003 @@ -95,19 +95,11 @@ <function class="GtkLabel">set_pattern</function> with no parameters to erase these. </simpara> - <para> - <informalexample> - <programlisting role="php"> -<![CDATA[ -<?php - -$label->set_text("Whatever text you wish to pass"); - -?> -]]> - </programlisting> - </informalexample> - </para> + <simpara> + <literal> + $label->set_text("Whatever text you wish to pass"); + </literal> + </simpara> </desc> </method> @@ -181,19 +173,9 @@ underscore or space in the pattern maps directly to the character position in the label text. </simpara> - <para> - <informalexample> - <programlisting role="php"> -<![CDATA[ -<?php - -$label->set_pattern("_ _"); - -?> -]]> - </programlisting> - </informalexample> - </para> + <simpara> + <literal>$label->set_pattern("_ _");</literal> + </simpara> <simpara> Call this method with no parameters to erase existing underlines. </simpara> @@ -218,19 +200,9 @@ <literal>false</literal>, those lines will be cut off at the widget's edge. </simpara> - <para> - <informalexample> - <programlisting role="php"> -<![CDATA[ -<?php - -$label->set_line_wrap(true); - -?> -]]> - </programlisting> - </informalexample> - </para> + <simpara> + <literal>$label->set_line_wrap(true);</literal> + </simpara> </desc> </method> @@ -254,19 +226,9 @@ by <literal>get_text()</literal>. </simpara> </note> - <para> - <informalexample> - <programlisting role="php"> -<![CDATA[ -<?php - -$label->get(); - -?> -]]> - </programlisting> - </informalexample> - </para> + <simpara> + <literal>$label->get();</literal> + </simpara> </desc> </method> @@ -297,19 +259,9 @@ Note that this method is deprecated in GTK+ 2.0. </simpara> </note> - <para> - <informalexample> - <programlisting role="php"> -<![CDATA[ -<?php - -$label->parse_uline("_File"); - -?> -]]> - </programlisting> - </informalexample> - </para> + <simpara> + <literal>$label->parse_uline("_File");</literal> + </simpara> </desc> </method> Index: php-gtk-doc/en/reference/gtk/gtklist.xml diff -u php-gtk-doc/en/reference/gtk/gtklist.xml:1.7 php-gtk-doc/en/reference/gtk/gtklist.xml:1.8 --- php-gtk-doc/en/reference/gtk/gtklist.xml:1.7 Tue Jun 17 17:27:57 2003 +++ php-gtk-doc/en/reference/gtk/gtklist.xml Wed Jun 18 13:19:26 2003 @@ -755,13 +755,7 @@ array that contains any currently selected items. If there is no current selection, the array will be empty. If the selection mode does not allow multiple selection, - <programlisting role="php"> -<![CDATA[ -<?php -$list->selection[0]; -?> -]]> - </programlisting> will + <literal>$list->selection[0];</literal> will return the selected item. If the selection mode allows multiple selection, there will be as many elements in the array as there are currently-selected objects. Index: php-gtk-doc/en/reference/gtk/gtkmenu.xml diff -u php-gtk-doc/en/reference/gtk/gtkmenu.xml:1.11 php-gtk-doc/en/reference/gtk/gtkmenu.xml:1.12 --- php-gtk-doc/en/reference/gtk/gtkmenu.xml:1.11 Tue Jun 17 17:27:57 2003 +++ php-gtk-doc/en/reference/gtk/gtkmenu.xml Wed Jun 18 13:19:26 2003 @@ -209,16 +209,7 @@ <literal>0</literal> will make the menu disappear as soon as the user releases the mouse-button that triggered it. The safest setting for this parameter is - <programlisting> -<![CDATA[ -<?php - -$event->time - -?> -]]> - - </programlisting> - + <literal>$event->time</literal> - this being a setting that all <classname>GdkEvent</classname> structures share; it causes the popup menu to react as you'd expect it to, and won't spring any surprises if you duplicate or otherwise adapt Index: php-gtk-doc/en/reference/gtk/gtkobject.xml diff -u php-gtk-doc/en/reference/gtk/gtkobject.xml:1.10 php-gtk-doc/en/reference/gtk/gtkobject.xml:1.11 --- php-gtk-doc/en/reference/gtk/gtkobject.xml:1.10 Tue Jun 17 17:27:57 2003 +++ php-gtk-doc/en/reference/gtk/gtkobject.xml Wed Jun 18 13:19:26 2003 @@ -334,7 +334,8 @@ object. For example, in <filename>gtklabel.c</filename> in GTK 1.2.10 you will see this directly after the includes: <informalexample> - <programlisting> + <programlisting> +<![CDATA[ enum { ARG_0, ARG_LABEL, @@ -342,13 +343,15 @@ ARG_JUSTIFY, ARG_WRAP }; +]]> </programlisting> </informalexample> Around a hundred lines later, these argument types are defined as they are added to the widget, in the <literal>class_init</literal> function: <informalexample> - <programlisting> + <programlisting> +<![CDATA[ gtk_object_add_arg_type ("GtkLabel::label", GTK_TYPE_STRING, GTK_ARG_READWRITE, ARG_LABEL); gtk_object_add_arg_type ("GtkLabel::pattern", GTK_TYPE_STRING, @@ -357,6 +360,7 @@ GTK_TYPE_JUSTIFICATION, GTK_ARG_READWRITE, ARG_JUSTIFY); gtk_object_add_arg_type ("GtkLabel::wrap", GTK_TYPE_BOOL, GTK_ARG_READWRITE, ARG_WRAP); +]]> </programlisting> </informalexample> </para> Index: php-gtk-doc/en/reference/gtk/gtkpaned.xml diff -u php-gtk-doc/en/reference/gtk/gtkpaned.xml:1.10 php-gtk-doc/en/reference/gtk/gtkpaned.xml:1.11 --- php-gtk-doc/en/reference/gtk/gtkpaned.xml:1.10 Tue Jun 17 17:27:57 2003 +++ php-gtk-doc/en/reference/gtk/gtkpaned.xml Wed Jun 18 13:19:26 2003 @@ -212,20 +212,10 @@ without regard to the size requests of the child widgets in the panes. It is overridden by the user's repositioning of the dividing handle. </simpara> - <para> + <simpara> To unset the position of the dividing handle, use - <informalexample> - <programlisting role="php"> -<![CDATA[ -<?php - -$paned->set_position(-1); - -?> -]]> - </programlisting> - </informalexample> - </para> + <literal>$paned->set_position(-1);</literal> + </simpara> </desc> </method> Index: php-gtk-doc/en/reference/gtk/gtkprogressbar.xml diff -u php-gtk-doc/en/reference/gtk/gtkprogressbar.xml:1.9 php-gtk-doc/en/reference/gtk/gtkprogressbar.xml:1.10 --- php-gtk-doc/en/reference/gtk/gtkprogressbar.xml:1.9 Tue Jun 17 17:27:57 2003 +++ php-gtk-doc/en/reference/gtk/gtkprogressbar.xml Wed Jun 18 13:19:26 2003 @@ -60,8 +60,7 @@ <para> <example> <title>Setting up a Progress Bar</title> - <programlisting role="php"> - + <programlisting role="php"> <![CDATA[ <?php @@ -109,36 +108,12 @@ </example> To create a progress bar in <literal>activity</literal> mode, delete the references to the text string and replace them with - <programlisting role="php"> -<![CDATA[ -<?php - -$progressbar->set_activity_mode(true); - -?> -]]> - </programlisting> + <literal>$progressbar->set_activity_mode(true);</literal> and any further methods appropriate to an activity indicator. You will also need to replace - <programlisting role="php"> -<![CDATA[ -<?php - -$progressbar->set_percentage($value); - -?> -]]> - </programlisting> + <literal>$progressbar->set_percentage($value);</literal> in the <literal>update_bar()</literal> function with - <programlisting role="php"> -<![CDATA[ -<?php - -$progressbar->set_value($value); - -?> -]]> - </programlisting> + <literal>$progressbar->set_value($value);</literal> </para> <simpara> Note that a progress bar in <literal>activity</literal> mode will not Index: php-gtk-doc/en/reference/gtk/gtktext.xml diff -u php-gtk-doc/en/reference/gtk/gtktext.xml:1.11 php-gtk-doc/en/reference/gtk/gtktext.xml:1.12 --- php-gtk-doc/en/reference/gtk/gtktext.xml:1.11 Tue Jun 17 17:27:57 2003 +++ php-gtk-doc/en/reference/gtk/gtktext.xml Wed Jun 18 13:19:26 2003 @@ -458,20 +458,12 @@ by a user. The default length <literal>-1</literal> will allow the entire string. </simpara> - <para> + <simpara> You can use the current default style with: - <informalexample> - <programlisting role="php"> -<![CDATA[ -<?php - -$text->insert(null, null, null, "A string of text."); - -?> -]]> - </programlisting> - </informalexample> - </para> + <literal> + $text->insert(null, null, null, "A string of text."); + </literal> + </simpara> </desc> </method> Index: php-gtk-doc/en/reference/gtk/gtktogglebutton.xml diff -u php-gtk-doc/en/reference/gtk/gtktogglebutton.xml:1.7 php-gtk-doc/en/reference/gtk/gtktogglebutton.xml:1.8 --- php-gtk-doc/en/reference/gtk/gtktogglebutton.xml:1.7 Tue Jun 17 17:27:57 2003 +++ php-gtk-doc/en/reference/gtk/gtktogglebutton.xml Wed Jun 18 13:19:26 2003 @@ -41,21 +41,13 @@ Creates a button that can be toggled between two states. </shortdesc> <desc> - <para> - <informalexample> - <programlisting role="php"> -<![CDATA[ -<?php - -$togglebutton = &new GtkToggleButton("GtkToggleButton's label"); - -?> -]]> - </programlisting> - </informalexample> + <simpara> + <literal> + $togglebutton = &new GtkToggleButton("GtkToggleButton's label"); + </literal> creates a <classname>GtkToggleButton</classname> that can be toggled between active and normal states. - </para> + </simpara> </desc> </constructor> @@ -213,20 +205,10 @@ drawn or not. It is exposed here so that the value of the indicator's mode setting can be tested programmatically. </simpara> - <para> + <simpara> The property can be accessed using the syntax - <informalexample> - <programlisting role="php"> -<![CDATA[ -<?php - -$togglebutton->draw_indicator; - -?> -]]> - </programlisting> - </informalexample> - </para> + <literal>$togglebutton->draw_indicator;</literal> + </simpara> <simpara> The <propname>draw_indicator</propname> property should not be accessed directly. Use <function class="GtkToggleButton">set_mode</function> Index: php-gtk-doc/en/reference/gtk/gtkvbox.xml diff -u php-gtk-doc/en/reference/gtk/gtkvbox.xml:1.10 php-gtk-doc/en/reference/gtk/gtkvbox.xml:1.11 --- php-gtk-doc/en/reference/gtk/gtkvbox.xml:1.10 Tue Jun 17 17:27:57 2003 +++ php-gtk-doc/en/reference/gtk/gtkvbox.xml Wed Jun 18 13:19:26 2003 @@ -49,26 +49,16 @@ Creates a new vertical box container designed for packing a single column of child widgets. </simpara> - <para> + <simpara> The first parameter, <parameter>homogeneous</parameter>, is a boolean value which, if set to <literal>true</literal>, will set each child widget in the <classname>GtkVBox</classname> to the same height as that of the largest child widget. The second parameter, <parameter>spacing</parameter>, sets the minimum spacing between the child widgets, in pixels. Leaving both parameters empty, e.g. - <informalexample> - <programlisting role="php"> -<![CDATA[ -<?php - -$vbox = &new GtkVBox(); - -?> -]]> - </programlisting> - </informalexample> + <literal>$vbox = &new GtkVBox();</literal> will set the default behaviour of individual sizing and zero spacing. - </para> + </simpara> <para> <example> <title>Packing child widgets using <classname>GtkVBox</classname> and Index: php-gtk-doc/en/reference/gtk/gtkvbuttonbox.xml diff -u php-gtk-doc/en/reference/gtk/gtkvbuttonbox.xml:1.7 php-gtk-doc/en/reference/gtk/gtkvbuttonbox.xml:1.8 --- php-gtk-doc/en/reference/gtk/gtkvbuttonbox.xml:1.7 Tue Jun 17 17:27:57 2003 +++ php-gtk-doc/en/reference/gtk/gtkvbuttonbox.xml Wed Jun 18 13:19:26 2003 @@ -30,21 +30,11 @@ Creates the basis for a vertical button container. </shortdesc> <desc> - <para> + <simpara> The syntax for creating a vertical buttonbox is: - <informalexample> - <programlisting role="php"> -<![CDATA[ -<?php - -$vbuttonbox = &new GtkVButtonBox(); - -?> -]]> - </programlisting> - </informalexample> + <literal>$vbuttonbox = &new GtkVButtonBox();</literal> There are no parameters. - </para> + </simpara> <simpara> As with all container widgets, no physical space is taken by a <classname>GtkVButtonBox</classname> until its child widgets Index: php-gtk-doc/en/reference/gtk/gtkvpaned.xml diff -u php-gtk-doc/en/reference/gtk/gtkvpaned.xml:1.6 php-gtk-doc/en/reference/gtk/gtkvpaned.xml:1.7 --- php-gtk-doc/en/reference/gtk/gtkvpaned.xml:1.6 Sun Jan 20 14:47:43 2002 +++ php-gtk-doc/en/reference/gtk/gtkvpaned.xml Wed Jun 18 13:19:26 2003 @@ -31,16 +31,14 @@ Creates the basis for a vertical dual-paned container. </shortdesc> <desc> - <para> + <simpara> The <classname>GtkVPaned</classname> widget should be thought of in terms of an arrangement of two child widgets, rather than as an object in its own right. The construct - <informalexample> - <programlisting role="php">$vbox = &new GtkVBox();</programlisting> - </informalexample> + <literal>$vbox = &new GtkVBox();</literal> needs to be within a containing <classname>GtkWindow</classname> and to contain two child widgets of its own in order to work. - </para> + </simpara> <simpara> There is a code sample demonstrating the construction of a paned widget under the entry for the Index: php-gtk-doc/en/reference/gtk/gtkwidget.xml diff -u php-gtk-doc/en/reference/gtk/gtkwidget.xml:1.19 php-gtk-doc/en/reference/gtk/gtkwidget.xml:1.20 --- php-gtk-doc/en/reference/gtk/gtkwidget.xml:1.19 Tue Jun 17 17:27:57 2003 +++ php-gtk-doc/en/reference/gtk/gtkwidget.xml Wed Jun 18 13:19:26 2003 @@ -1041,23 +1041,15 @@ <function class="GtkWidget">set_events</function> can be used at any point in the widget's life-cycle. </simpara> - <para> + <simpara> Staying with the key-press example, the syntax would be: - <informalexample> - <programlisting role="php"> -<![CDATA[ -<?php - -$widget->set_events(GDK_KEY_PRESS_MASK | GDK_KEY_RELEASE_MASK); - -?> -]]> - </programlisting> - </informalexample> + <literal> + $widget->set_events(GDK_KEY_PRESS_MASK | GDK_KEY_RELEASE_MASK); + </literal> This would enable a previously keyboard-insensitive widget to emit <signalname class="GtkWidget">key-press-event</signalname> and <signalname class="GtkWidget">key-release-event</signalname> signals. - </para> + </simpara> </desc> </method> @@ -1089,23 +1081,15 @@ <function class="GtkWidget">show</function> routine as well as being a method/signal pair in its own right. </simpara> - <para> + <simpara> Staying with the button-press example, the syntax would be: - <informalexample> - <programlisting role="php"> -<![CDATA[ -<?php - -$widget->add_events(GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK); - -?> -]]> - </programlisting> - </informalexample> + <literal> + $widget->add_events(GDK_BUTTON_PRESS_MASK|GDK_BUTTON_RELEASE_MASK); + </literal> This would enable a previously mouse-insensitive widget to emit <signalname class="GtkWidget">button-press-event</signalname> and <signalname class="GtkWidget">button-release-event</signalname> signals. - </para> + </simpara> </desc> </method> @@ -2019,11 +2003,12 @@ function on_click($widget, $event, $data) { if($event->keyval==GDK_KEY_Return) { /*do something appropriate for the return key being pressed*/ -} + } elseif($event->keyval > GDK_KEY__a) { /*we can reach the character strings, too*/ -echo $event->string."\n"; -}} + echo $event->string."\n"; + } +} ?> ]]>