| 1 | <html><head><meta http-equiv="Content-Type" content="text/html; charset=utf-8"><title>Reference Page Format</title><link rel="stylesheet" href="style.css" type="text/css"><meta name="generator" content="DocBook XSL Stylesheets V1.68.1"><link rel="start" href="index.html" title="PyGTK 2.0 Reference Manual"><link rel="up" href="pygtk-introduction.html" title="Introduction"><link rel="prev" href="pygtk-introduction.html" title="Introduction"><link rel="next" href="class-hierarchy.html" title="PyGTK Class Hierarchy"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">Reference Page Format</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="pygtk-introduction.html">Prev</a>Â </td><th width="60%" align="center">Introduction</th><td width="20%" align="right">Â <a accesskey="n" href="class-hierarchy.html">Next</a></td></tr></table><hr></div><div class="sect1" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="pygtk-reference-format"></a>Reference Page Format</h2></div></div></div><p>Each <code class="literal">PyGTK</code> class is described in a reference |
|---|
| 2 | page that has a number of sections in a fixed format. Each reference page |
|---|
| 3 | will have a subset of the following sections:</p><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><span class="term">Name</span></td><td>The name and a one-line description of the |
|---|
| 4 | class.</td></tr><tr><td><span class="term">Synopsis</span></td><td>A synopsis of the class and its methods and |
|---|
| 5 | optionally a list of associated functions.</td></tr><tr><td><span class="term">Ancestry</span></td><td>The list of the parent classes of the class. This |
|---|
| 6 | section may not be present in all class descriptions.</td></tr><tr><td><span class="term">Properties</span></td><td>A list of the properties (internal state) |
|---|
| 7 | supported by the class. This section may not be present in all classes. The |
|---|
| 8 | property descriptions include the name, the access operations (e.g. Read, |
|---|
| 9 | Write), and a brief description. Properties are accessed using the <PYGTKDOCLINK HREF="method-gobject--set-property"><code class="methodname">gobject.set_property</code>()</PYGTKDOCLINK> |
|---|
| 10 | and <PYGTKDOCLINK HREF="method-gobject--get-property"><code class="methodname">gobject.get_property</code>()</PYGTKDOCLINK> |
|---|
| 11 | methods that are available to every <code class="literal">PyGTK</code> object. This |
|---|
| 12 | section may not be present in all class descriptions.</td></tr><tr><td><span class="term">Style Properties</span></td><td>A list of style properties supported by the |
|---|
| 13 | class. Similar to the properties (described above) the style properties hold |
|---|
| 14 | information about the style of a widgets e.g. border style, shadow type, |
|---|
| 15 | etc. Most widgets do not support style properties so this section is not |
|---|
| 16 | present in most class descriptions. Only PyGTK 2.4 has the ability to access |
|---|
| 17 | style properties.</td></tr><tr><td><span class="term">Child Properties</span></td><td>A list of child properties supported by the |
|---|
| 18 | class. Similar to the properties (described above) the child properties hold |
|---|
| 19 | information about the properties of a widget's child widget. Only container |
|---|
| 20 | widgets support child properties so this section is not present in most |
|---|
| 21 | class descriptions.</td></tr><tr><td><span class="term">Attributes</span></td><td>A set of internal object state data accessible as |
|---|
| 22 | Python attributes (e.g. object.attr). The attribute descriptions include a |
|---|
| 23 | name by which the attribute data is accessed, the access mode (e.g. Read, |
|---|
| 24 | Write), and a brief description of the attribute. Most |
|---|
| 25 | <code class="literal">PyGTK</code> classes do not support attributes so this section |
|---|
| 26 | is not present in most class descriptions.</td></tr><tr><td><span class="term">Signal Prototypes</span></td><td>A list of the signals supported by the class |
|---|
| 27 | including the signal name and a synopsis of the signal handler function |
|---|
| 28 | prototype. This section may not be present in all class descriptions; most |
|---|
| 29 | <code class="literal">gtk.gdk</code> classes do not support signals.</td></tr><tr><td><span class="term">Description</span></td><td>A description of the class and possibly some of |
|---|
| 30 | the methods supported by the class.</td></tr><tr><td><span class="term">Constructor</span></td><td>The description of the class object constructor |
|---|
| 31 | including the synopsis with brief parameter descriptions and a description |
|---|
| 32 | of th use of the constructor. There may be more than one constructor |
|---|
| 33 | description if the constructor supports different parameter lists. This |
|---|
| 34 | section may not be present in all class descriptions.</td></tr><tr><td><span class="term">Methods</span></td><td>A list of methods supported by the class. Each |
|---|
| 35 | method description includes: a synopsis of the method and its parameters as |
|---|
| 36 | well as a brief description of each parameter and return value (if any); |
|---|
| 37 | and, a description of the use of the method.</td></tr><tr><td><span class="term">Functions</span></td><td>A list of related functions. Each function |
|---|
| 38 | description includes a synopsis of the function and its parameters and |
|---|
| 39 | return value (if any), and a description of the use of the |
|---|
| 40 | function.</td></tr><tr><td><span class="term">Signals</span></td><td>A list of signals including a synopsis of the |
|---|
| 41 | signal handler prototype function with its parameters and return value (if |
|---|
| 42 | any). The signal emission conditions are briefly described. This section is |
|---|
| 43 | not present in all class descriptions; specifically, the |
|---|
| 44 | <code class="literal">gtk.gdk</code> classes do not usually support signals.</td></tr></tbody></table><p>The function and method synopsis parameters are displayed in |
|---|
| 45 | <span class="bold"><strong>bold</strong></span> to denote Python keyword parameters. |
|---|
| 46 | Also if the parameter is optional its default value will be displayed. For |
|---|
| 47 | example the <a href="class-gtkbutton.html#constructor-gtkbutton" title="Constructor">gtk.Button</a>() |
|---|
| 48 | constructor synopsis is:</p><pre class="programlisting"> |
|---|
| 49 | <code class="constructorsynopsis"> <span class="methodname"><a href="class-gtkbutton.html#constructor-gtkbutton" title="Constructor">gtk.Button</a></span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>label</code></strong></span><span class="initializer">=None</span></span>, <span class="methodparam"><span class="parameter"><strong class="parameter"><code>stock</code></strong></span><span class="initializer">=None</span></span>)</code> |
|---|
| 50 | </pre><p>The parameters <em class="parameter"><code>label</code></em> and |
|---|
| 51 | <em class="parameter"><code>stock</code></em> are keyword parameters that can be specified in |
|---|
| 52 | a call either by position or keyword (in which case position is not |
|---|
| 53 | important). The following calls have the same result:</p><pre class="programlisting"> |
|---|
| 54 | b = gtk.Button("Cancel") |
|---|
| 55 | b = gtk.Button(label="Cancel") |
|---|
| 56 | b = gtk.Button("Cancel", None) |
|---|
| 57 | b = gtk.Button("Cancel", stock=None) |
|---|
| 58 | b = gtk.Button(stock=None, label="Cancel") |
|---|
| 59 | </pre><p>Parameters that are not keyword parameters are displayed in |
|---|
| 60 | <span class="emphasis"><em>italic</em></span> and must be specified positionally but may |
|---|
| 61 | also be optional.</p></div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="pygtk-introduction.html">Prev</a> </td><td width="20%" align="center"><a accesskey="u" href="pygtk-introduction.html">Up</a></td><td width="40%" align="right"> <a accesskey="n" href="class-hierarchy.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top">Introduction </td><td width="20%" align="center"><a accesskey="h" href="index.html">Home</a></td><td width="40%" align="right" valign="top"> PyGTK Class Hierarchy</td></tr></table></div></body></html> |
|---|