mirror of
https://github.com/ToshioCP/Gtk4-tutorial.git
synced 2025-01-12 20:03:28 +01:00
commit
e1a2119d1e
1 changed files with 3 additions and 3 deletions
|
@ -447,7 +447,7 @@ class="sourceCode numberSource C numberLines"><code class="sourceCode c"><span i
|
|||
<span id="cb9-8"><a href="#cb9-8"></a> <span class="cf">else</span></span>
|
||||
<span id="cb9-9"><a href="#cb9-9"></a> gtk_button_set_label <span class="op">(</span>btn<span class="op">,</span> <span class="st">"Hello."</span><span class="op">);</span></span>
|
||||
<span id="cb9-10"><a href="#cb9-10"></a><span class="op">}</span></span></code></pre></div>
|
||||
<p>The function <code>gtk_button_get_lable</code> returns a text from
|
||||
<p>The function <code>gtk_button_get_label</code> returns a text from
|
||||
the label. The string is owned by the button and you can’t modify or
|
||||
free it. The <code>const</code> qualifier is necessary for the string
|
||||
<code>s</code>. If you change the string, your compiler will give you a
|
||||
|
@ -458,8 +458,8 @@ the GTK 4 API reference.</p>
|
|||
<img src="image/screenshot_lb4.png" alt="Screenshot of the box" />
|
||||
<figcaption aria-hidden="true">Screenshot of the box</figcaption>
|
||||
</figure>
|
||||
<p>The handler corresponds to <code>btn1</code> toggles its label. The
|
||||
handler corresponds to <code>btn2</code> destroys the top-level window
|
||||
<p>The handler corresponding to <code>btn1</code> toggles its label. The
|
||||
handler corresponding to <code>btn2</code> destroys the top-level window
|
||||
and the application quits.</p>
|
||||
</div>
|
||||
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.0.2/dist/js/bootstrap.bundle.min.js" integrity="sha384-MrcW6ZMFYlzcLA8Nl+NtUVF0sA7MsXsP1UyJoMp4YLEuNSfAP+JcXn/tWtIaxVXM" crossorigin="anonymous"></script>
|
||||
|
|
Loading…
Reference in a new issue