[gnome-devel-docs] tutorial python: succession of pages reviewed



commit 2a70180376ba3ec16ea841aab945fe83fbae6f57
Author: Marta Maria Casetti <mmcasetti gmail com>
Date:   Mon Feb 25 13:35:20 2013 +0100

    tutorial python: succession of pages reviewed

 platform-demos/C/GtkApplicationWindow.py.page |    1 +
 platform-demos/C/image.py.page                |    1 +
 platform-demos/C/label.py.page                |    6 +++---
 platform-demos/C/properties.py.page           |    6 +++---
 platform-demos/C/tutorial.py.page             |    8 ++++----
 platform-demos/C/window.py.page               |    4 ++--
 6 files changed, 14 insertions(+), 12 deletions(-)
---
diff --git a/platform-demos/C/GtkApplicationWindow.py.page b/platform-demos/C/GtkApplicationWindow.py.page
index 1dffd9a..11b5f1c 100644
--- a/platform-demos/C/GtkApplicationWindow.py.page
+++ b/platform-demos/C/GtkApplicationWindow.py.page
@@ -6,6 +6,7 @@
   <info>
     <title type="text">ApplicationWindow (Python)</title>
     <link type="guide" xref="beginner.py#windows"/>
+    <link type="seealso" xref="properties.py" />
     <link type="next" xref="image.py"/>
     <revision version="0.1" date="2012-06-10" status="draft"/>
 
diff --git a/platform-demos/C/image.py.page b/platform-demos/C/image.py.page
index 05dbf09..653e75e 100644
--- a/platform-demos/C/image.py.page
+++ b/platform-demos/C/image.py.page
@@ -6,6 +6,7 @@
   <info>
     <title type="text">Image (Python)</title>
     <link type="guide" xref="beginner.py#display-widgets"/>
+    <link type="seealso" xref="properties.py" />
     <link type="next" xref="strings.py"/>
     <revision version="0.2" date="2012-06-14" status="draft"/>
 
diff --git a/platform-demos/C/label.py.page b/platform-demos/C/label.py.page
index c7e8083..85f0233 100644
--- a/platform-demos/C/label.py.page
+++ b/platform-demos/C/label.py.page
@@ -6,8 +6,9 @@
   <info>
     <title type="text">Label (Python)</title>
     <link type="guide" xref="beginner.py#display-widgets"/>
+    <link type="seealso" xref="properties.py" />
     <link type="seealso" xref="strings.py" />
-    <link type="next" xref="grid.py" />
+    <link type="next" xref="properties.py" />
     <revision version="0.2" date="2012-06-18" status="draft"/>
 
     <credit type="author copyright">
@@ -67,8 +68,7 @@ class MyApplication(Gtk.Application):
 
   <section id="methods">
   <title>Useful methods for a Label widget</title>
-  <p>An explanation of how to deal with strings in GTK+ can be found at <link xref="strings.py.page" />.</p>
-  <p><code>label = Gtk.Label(label="Hello GNOME!")</code> could also be used to create a label and set the 
text directly. For a general discussion of this, see <link xref="properties.py" />.</p>
+  <p>An explanation of how to deal with strings in GTK+ can be found in <link xref="strings.py" />.</p>
   <list>
     <item><p><code>set_line_wrap(True)</code> breaks lines if the text of the label exceeds the size of the 
widget.</p></item>
     <item><p><code>set_justify(Gtk.Justification.LEFT)</code> (or <code>Gtk.Justification.RIGHT, 
Gtk.Justification.CENTER, Gtk.Justification.FILL</code>) sets the alignment of the lines in the text of the 
label relative to each other. The method has no effect on a single-line label.</p></item>
diff --git a/platform-demos/C/properties.py.page b/platform-demos/C/properties.py.page
index 01ae2af..9e2fa24 100644
--- a/platform-demos/C/properties.py.page
+++ b/platform-demos/C/properties.py.page
@@ -7,7 +7,7 @@
 <info>
   <title type="text">Properties (Python)</title>
   <link type="guide" xref="beginner.py#theory"/>
-  <link type="next" xref="window.py"/>
+  <link type="next" xref="grid.py"/>
   <revision version="0.1" date="2012-06-24" status="draft"/>
 
   <desc>An explanation of properties, getters and setters.</desc>
@@ -30,7 +30,7 @@
 <section id="overview">
 <title>Overview</title>
 
-<p><em>Properties</em> describe the configuration and state of widgets, and each widget has its own 
particular set of properties. For example, a widget such as a button or a label has the property "label" 
which contains the text of the widget. You can specify the name and value of any number of properties as 
keyword arguments when creating an instance of a widget: for example, to create a label with the text “Hello 
World”, an angle of 25 degrees, and aligned to the right, you can use:</p>
+<p><em>Properties</em> describe the configuration and state of widgets, and each widget has its own 
particular set of properties. For example, a widget such as a button or a label has the property 
<code>label</code> which contains the text of the widget. You can specify the name and value of any number of 
properties as keyword arguments when creating an instance of a widget: for example, to create a label with 
the text “Hello World”, an angle of 25 degrees, and aligned to the right, you can use:</p>
 <code>
 label = Gtk.Label(label="Hello World", angle=25, halign=Gtk.Align.END)</code>
 
@@ -41,7 +41,7 @@ label.set_label("Hello World")
 label.set_angle(25)
 label.set_halign(Gtk.Align.END)</code>
 
-<p>Once you have created such a label, you can get the text of the label with the getter 
<code>label.get_label()</code>, and analogously for the other properties.</p>
+<p>Once you have created such a label, you can get the text of the label with 
<code>label.get_label()</code>, and analogously for the other properties.</p>
 
 <p>Instead of using getters and setters you can also get and set the properties with 
<code>get_property(<var>"prop-name"</var>)</code> and <code>set_property(<var>"prop-name"</var>, 
<var>value</var>)</code>, respectively.</p>
 
diff --git a/platform-demos/C/tutorial.py.page b/platform-demos/C/tutorial.py.page
index 826a1d0..29e2220 100644
--- a/platform-demos/C/tutorial.py.page
+++ b/platform-demos/C/tutorial.py.page
@@ -53,10 +53,6 @@
 <steps>
   <title>Tutorial</title>
   <item><steps>
-    <title>Introduction to properties</title>
-    <item><p><link xref="properties.py" /></p></item>
-  </steps></item>
-  <item><steps>
     <title>Basic windows</title>
     <item><p><link xref="window.py" /></p></item>
     <item><p><link xref="GtkApplicationWindow.py" /></p></item>
@@ -68,6 +64,10 @@
     <item><p><link xref="label.py" /></p></item>
   </steps></item>
   <item><steps>
+    <title>Introduction to properties</title>
+    <item><p><link xref="properties.py" /></p></item>
+  </steps></item>
+  <item><steps>
     <title>Grid, separator and scrolling</title>
     <item><p><link xref="grid.py" /></p></item>
     <item><p><link xref="separator.py" /></p></item>
diff --git a/platform-demos/C/window.py.page b/platform-demos/C/window.py.page
index ad971cb..39ef222 100644
--- a/platform-demos/C/window.py.page
+++ b/platform-demos/C/window.py.page
@@ -6,6 +6,7 @@
   <info>
     <title type="text">Window (Python)</title>
     <link type="guide" xref="beginner.py#windows"/>
+    <link type="seealso" xref="properties.py" />
     <link type="next" xref="GtkApplicationWindow.py"/>
     <revision version="0.2" date="2012-06-09" status="draft"/>
 
@@ -32,7 +33,7 @@
         <p>A minimal Gtk+ Application: a window with a title.</p>
       </td>
       <td>
-        <p>Use <link xref="GtkApplicationWindow.py">Application Window</link> if you need GMenu support.</p>
+        <p>Use <link xref="GtkApplicationWindow.py" /> if you need <link xref="gmenu.py"/> support.</p>
       </td>
     </tr>
   </table>
@@ -48,7 +49,6 @@
 
   <section id="methods">
   <title>Useful methods for a Window widget</title>
-  <p><code>window = Gtk.Window(application=self, title="Welcome to GNOME")</code> sets the title as well, 
without the need for the line <code>window.set_title("Welcome to GNOME")</code>. For a general discussion of 
this, see <link xref="properties.py" />.</p>
   <list>
     <item><p><code>set_default_size(200, 100)</code> sets the default size of the window to a width of 
<code>200</code> and a height of <code>100</code>; if instead of a positive number we pass <code>-1</code> we 
have the default size.</p></item>
     <item><p><code>set_position(Gtk.WindowPosition.CENTER)</code> centers the window. Other options are 
<code>Gtk.WindowPosition.NONE, Gtk.WindowPosition.MOUSE, Gtk.WindowPosition.CENTER_ALWAYS, 
Gtk.WindowPosition.CENTER_ON_PARENT</code>.</p></item>


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]