mirror of
https://github.com/ToshioCP/Gtk4-tutorial.git
synced 2024-11-16 19:50:35 +01:00
sec29: Fix a doc typo
This commit is contained in:
parent
b865488043
commit
81fc01c987
3 changed files with 3 additions and 3 deletions
|
@ -153,7 +153,7 @@ list. Because GListModel is a list of GObject objects and strings aren’t
|
|||
GObject objects. The word “GObject” here means “GObject class or its
|
||||
descendant class”. So, you need a wrapper which is a GObject and
|
||||
contains a string. GtkStringObject is the wrapper object and
|
||||
GStringList, implements GListModel, is a list of GtkStringObject.</p>
|
||||
GtkStringList, implements GListModel, is a list of GtkStringObject.</p>
|
||||
<div class="sourceCode" id="cb1"><pre class="sourceCode C"><code class="sourceCode c"><span id="cb1-1"><a href="#cb1-1" aria-hidden="true" tabindex="-1"></a><span class="dt">char</span> <span class="op">*</span>array<span class="op">[]</span> <span class="op">=</span> <span class="op">{</span><span class="st">"one"</span><span class="op">,</span> <span class="st">"two"</span><span class="op">,</span> <span class="st">"three"</span><span class="op">,</span> <span class="st">"four"</span><span class="op">,</span> NULL<span class="op">};</span></span>
|
||||
<span id="cb1-2"><a href="#cb1-2" aria-hidden="true" tabindex="-1"></a>GtkStringList <span class="op">*</span>stringlist <span class="op">=</span> gtk_string_list_new <span class="op">((</span><span class="dt">const</span> <span class="dt">char</span> <span class="op">*</span> <span class="dt">const</span> <span class="op">*)</span> array<span class="op">);</span></span></code></pre></div>
|
||||
<p>The function <code>gtk_string_list_new</code> creates a GtkStringList
|
||||
|
|
|
@ -40,7 +40,7 @@ If you want to make a list of strings with GListModel, for example, "one", "two"
|
|||
Because GListModel is a list of GObject objects and strings aren't GObject objects.
|
||||
The word "GObject" here means "GObject class or its descendant class".
|
||||
So, you need a wrapper which is a GObject and contains a string.
|
||||
GtkStringObject is the wrapper object and GStringList, implements GListModel, is a list of GtkStringObject.
|
||||
GtkStringObject is the wrapper object and GtkStringList, implements GListModel, is a list of GtkStringObject.
|
||||
|
||||
~~~C
|
||||
char *array[] = {"one", "two", "three", "four", NULL};
|
||||
|
|
|
@ -38,7 +38,7 @@ If you want to make a list of strings with GListModel, for example, "one", "two"
|
|||
Because GListModel is a list of GObject objects and strings aren't GObject objects.
|
||||
The word "GObject" here means "GObject class or its descendant class".
|
||||
So, you need a wrapper which is a GObject and contains a string.
|
||||
GtkStringObject is the wrapper object and GStringList, implements GListModel, is a list of GtkStringObject.
|
||||
GtkStringObject is the wrapper object and GtkStringList, implements GListModel, is a list of GtkStringObject.
|
||||
|
||||
@@@if gfm
|
||||
~~~C
|
||||
|
|
Loading…
Reference in a new issue