⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 gtkscalebutton.html

📁 最新gtk中文资料集
💻 HTML
📖 第 1 页 / 共 2 页
字号:
                                                         const <ahref="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar">gchar</a> **icons);</pre><p>Sets the icons to be used by the scale button. For details, see the <a class="link" href="GtkScaleButton.html#GtkScaleButton--icons"><span class="type">"icons"</span></a> property.</p><p></p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><p><span class="term"><em class="parameter"><code>button</code></em>&#160;:</span></p></td><td> a <a class="link" href="GtkScaleButton.html" title="GtkScaleButton"><span class="type">GtkScaleButton</span></a></td></tr><tr><td><p><span class="term"><em class="parameter"><code>icons</code></em>&#160;:</span></p></td><td> a <ahref="/usr/share/gtk-doc/html/liboil/liboil-liboiljunk.html#NULL:CAPS"><code class="literal">NULL</code></a>-terminated array of icon names</td></tr></tbody></table></div><p class="since">Since  2.12</p></div><hr><div class="refsect2" lang="en"><a name="id3514603"></a><h3><a name="gtk-scale-button-set-value"></a>gtk_scale_button_set_value ()</h3><a class="indexterm" name="id3514619"></a><pre class="programlisting">void                gtk_scale_button_set_value          (<a class="link" href="GtkScaleButton.html" title="GtkScaleButton">GtkScaleButton</a> *button,                                                         <ahref="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gdouble">gdouble</a> value);</pre><p>Sets the current value of the scale; if the value is outside the minimum or maximum range values, it will be clamped to fit inside them. The scale button emits the <a class="link" href="GtkScaleButton.html#GtkScaleButton-value-changed"><span class="type">"value-changed"</span></a> signal if the value changes.</p><p></p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><p><span class="term"><em class="parameter"><code>button</code></em>&#160;:</span></p></td><td> a <a class="link" href="GtkScaleButton.html" title="GtkScaleButton"><span class="type">GtkScaleButton</span></a></td></tr><tr><td><p><span class="term"><em class="parameter"><code>value</code></em>&#160;:</span></p></td><td> new value of the scale button</td></tr></tbody></table></div><p class="since">Since  2.12</p></div><hr><div class="refsect2" lang="en"><a name="id3514717"></a><h3><a name="gtk-scale-button-get-adjustment"></a>gtk_scale_button_get_adjustment ()</h3><a class="indexterm" name="id3514733"></a><pre class="programlisting"><a class="link" href="GtkAdjustment.html" title="GtkAdjustment">GtkAdjustment</a>*      gtk_scale_button_get_adjustment     (<a class="link" href="GtkScaleButton.html" title="GtkScaleButton">GtkScaleButton</a> *button);</pre><p>Gets the <a class="link" href="GtkAdjustment.html" title="GtkAdjustment"><span class="type">GtkAdjustment</span></a> associated with the <a class="link" href="GtkScaleButton.html" title="GtkScaleButton"><span class="type">GtkScaleButton</span></a>'s scale.See <a class="link" href="GtkRange.html#gtk-range-get-adjustment"><code class="function">gtk_range_get_adjustment()</code></a> for details.</p><p></p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><p><span class="term"><em class="parameter"><code>button</code></em>&#160;:</span></p></td><td> a <a class="link" href="GtkScaleButton.html" title="GtkScaleButton"><span class="type">GtkScaleButton</span></a></td></tr><tr><td><p><span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></p></td><td> the adjustment associated with the scale</td></tr></tbody></table></div><p class="since">Since  2.12</p></div><hr><div class="refsect2" lang="en"><a name="id3514840"></a><h3><a name="gtk-scale-button-get-value"></a>gtk_scale_button_get_value ()</h3><a class="indexterm" name="id3514856"></a><pre class="programlisting"><ahref="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gdouble">gdouble</a>             gtk_scale_button_get_value          (<a class="link" href="GtkScaleButton.html" title="GtkScaleButton">GtkScaleButton</a> *button);</pre><p>Gets the current value of the scale button.</p><p></p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><p><span class="term"><em class="parameter"><code>button</code></em>&#160;:</span></p></td><td> a <a class="link" href="GtkScaleButton.html" title="GtkScaleButton"><span class="type">GtkScaleButton</span></a></td></tr><tr><td><p><span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></p></td><td> current value of the scale button</td></tr></tbody></table></div><p class="since">Since  2.12</p></div></div><div class="refsect1" lang="en"><a name="id3514933"></a><h2>Property Details</h2><div class="refsect2" lang="en"><a name="id3514944"></a><h3><a name="GtkScaleButton--adjustment"></a>The <code class="literal">"adjustment"</code> property</h3><a class="indexterm" name="id3514960"></a><pre class="programlisting">  "adjustment"               <a class="link" href="GtkAdjustment.html" title="GtkAdjustment">GtkAdjustment</a>         : Read / Write</pre><p>The GtkAdjustment that contains the current value of this scale button object.</p></div><hr><div class="refsect2" lang="en"><a name="id3514984"></a><h3><a name="GtkScaleButton--icons"></a>The <code class="literal">"icons"</code> property</h3><a class="indexterm" name="id3515000"></a><pre class="programlisting">  "icons"                    <ahref="/usr/share/gtk-doc/html/gobject/gobject-Boxed-Types.html#GStrv">GStrv</a>                 : Read / Write</pre><p>The names of the icons to be used by the scale button. The first item in the array will be used in the button when the current value is the lowest value, the second item for the highest value. All the subsequent icons will be used for all the other values, spread evenly over the range of values.</p><p>If there's only one icon name in the <em class="parameter"><code>icons</code></em> array, it will be used for all the values. If only two icon names are in the <em class="parameter"><code>icons</code></em> array, the first one will be used for the bottom 50% of the scale, and the second one for the top 50%.</p><p>It is recommended to use at least 3 icons so that the <a class="link" href="GtkScaleButton.html" title="GtkScaleButton"><span class="type">GtkScaleButton</span></a> reflects the current value of the scale better for the users.</p><p></p><p>Since  2.12</p></div><hr><div class="refsect2" lang="en"><a name="id3515070"></a><h3><a name="GtkScaleButton--size"></a>The <code class="literal">"size"</code> property</h3><a class="indexterm" name="id3515086"></a><pre class="programlisting">  "size"                     <a class="link" href="gtk-Themeable-Stock-Images.html#GtkIconSize">GtkIconSize</a>           : Read / Write</pre><p>The icon size.</p><p>Default value: GTK_ICON_SIZE_SMALL_TOOLBAR</p></div><hr><div class="refsect2" lang="en"><a name="id3515113"></a><h3><a name="GtkScaleButton--value"></a>The <code class="literal">"value"</code> property</h3><a class="indexterm" name="id3515129"></a><pre class="programlisting">  "value"                    <ahref="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gdouble">gdouble</a>               : Read / Write</pre><p>The value of the scale.</p><p>Default value: 0</p></div></div><div class="refsect1" lang="en"><a name="id3515157"></a><h2>Signal Details</h2><div class="refsect2" lang="en"><a name="id3515168"></a><h3><a name="GtkScaleButton-popdown"></a>The <code class="literal">"popdown"</code> signal</h3><a class="indexterm" name="id3515184"></a><pre class="programlisting">void                user_function                      (<a class="link" href="GtkScaleButton.html" title="GtkScaleButton">GtkScaleButton</a> *button,                                                        <ahref="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gpointer">gpointer</a>        user_data)      : Run Last / Action</pre><p>The ::popdown signal is a keybinding signal which gets emitted to popdown the scale widget.</p><p>The default binding for this signal is Escape.</p><p></p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><p><span class="term"><em class="parameter"><code>button</code></em>&#160;:</span></p></td><td> the object which received the signal</td></tr><tr><td><p><span class="term"><em class="parameter"><code>user_data</code></em>&#160;:</span></p></td><td>user data set when the signal handler was connected.</td></tr></tbody></table></div><p>Since  2.12</p></div><hr><div class="refsect2" lang="en"><a name="id3515275"></a><h3><a name="GtkScaleButton-popup"></a>The <code class="literal">"popup"</code> signal</h3><a class="indexterm" name="id3515291"></a><pre class="programlisting">void                user_function                      (<a class="link" href="GtkScaleButton.html" title="GtkScaleButton">GtkScaleButton</a> *button,                                                        <ahref="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gpointer">gpointer</a>        user_data)      : Run Last / Action</pre><p>The ::popup signal is a keybinding signal which gets emitted to popup the scale widget.</p><p>The default bindings for this signal are Space, Enter and Return.</p><p></p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><p><span class="term"><em class="parameter"><code>button</code></em>&#160;:</span></p></td><td> the object which received the signal</td></tr><tr><td><p><span class="term"><em class="parameter"><code>user_data</code></em>&#160;:</span></p></td><td>user data set when the signal handler was connected.</td></tr></tbody></table></div><p>Since  2.12</p></div><hr><div class="refsect2" lang="en"><a name="id3515381"></a><h3><a name="GtkScaleButton-value-changed"></a>The <code class="literal">"value-changed"</code> signal</h3><a class="indexterm" name="id3515397"></a><pre class="programlisting">void                user_function                      (<a class="link" href="GtkScaleButton.html" title="GtkScaleButton">GtkScaleButton</a> *button,                                                        <ahref="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gdouble">gdouble</a>         value,                                                        <ahref="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gpointer">gpointer</a>        user_data)      : Run Last</pre><p>The ::value-changed signal is emitted when the value field haschanged.</p><p></p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><p><span class="term"><em class="parameter"><code>button</code></em>&#160;:</span></p></td><td> the object which received the signal</td></tr><tr><td><p><span class="term"><em class="parameter"><code>value</code></em>&#160;:</span></p></td><td> the new value</td></tr><tr><td><p><span class="term"><em class="parameter"><code>user_data</code></em>&#160;:</span></p></td><td>user data set when the signal handler was connected.</td></tr></tbody></table></div><p>Since  2.12</p></div></div><div class="refsect1" lang="en"><a name="id3515499"></a><div class="refsect2" lang="en"><a name="id3515500"></a></div><hr><div class="refsect2" lang="en"><a name="id3515501"></a></div></div></div></body></html>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -