📄 gtkarrow.html
字号:
<a name="id4210529"></a><h2>Description</h2><p>GtkArrow should be used to draw simple arrows that need to point inone of the four cardinal directions (up, down, left, or right). Thestyle of the arrow can be one of shadow in, shadow out, etched in, oretched out. Note that these directions and style types may beammended in versions of Gtk to come.</p><p>GtkArrow will fill any space alloted to it, but since it is inheritedfrom <a class="link" href="GtkMisc.html" title="GtkMisc"><span class="type">GtkMisc</span></a>, it can be padded and/or aligned, to fill exactly thespace the programmer desires.</p><p>Arrows are created with a call to <a class="link" href="GtkArrow.html#gtk-arrow-new"><code class="function">gtk_arrow_new()</code></a>. The direction orstyle of an arrow can be changed after creation by using <a class="link" href="GtkArrow.html#gtk-arrow-set"><code class="function">gtk_arrow_set()</code></a>.</p></div><div class="refsect1" lang="en"><a name="id4210598"></a><h2>Details</h2><div class="refsect2" lang="en"><a name="id4210608"></a><h3><a name="GtkArrow-struct"></a>GtkArrow</h3><a class="indexterm" name="id4210621"></a><pre class="programlisting">typedef struct _GtkArrow GtkArrow;</pre><p>The <a class="link" href="GtkArrow.html" title="GtkArrow"><span class="type">GtkArrow</span></a> struct containes the following fields.(These fields should be considered read-only. They should never be set byan application.)</p></div><hr><div class="refsect2" lang="en"><a name="id4210648"></a><h3><a name="gtk-arrow-new"></a>gtk_arrow_new ()</h3><a class="indexterm" name="id4210661"></a><pre class="programlisting"><a class="link" href="GtkWidget.html" title="GtkWidget">GtkWidget</a>* gtk_arrow_new (<a class="link" href="gtk-Standard-Enumerations.html#GtkArrowType">GtkArrowType</a> arrow_type, <a class="link" href="gtk-Standard-Enumerations.html#GtkShadowType">GtkShadowType</a> shadow_type);</pre><p>Creates a new arrow widget.</p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><p><span class="term"><em class="parameter"><code>arrow_type</code></em> :</span></p></td><td>a valid <a class="link" href="gtk-Standard-Enumerations.html#GtkArrowType"><span class="type">GtkArrowType</span></a>.</td></tr><tr><td><p><span class="term"><em class="parameter"><code>shadow_type</code></em> :</span></p></td><td>a valid <a class="link" href="gtk-Standard-Enumerations.html#GtkShadowType"><span class="type">GtkShadowType</span></a>.</td></tr><tr><td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td><td>the new <a class="link" href="GtkArrow.html" title="GtkArrow"><span class="type">GtkArrow</span></a> widget.</td></tr></tbody></table></div></div><hr><div class="refsect2" lang="en"><a name="id4210765"></a><h3><a name="gtk-arrow-set"></a>gtk_arrow_set ()</h3><a class="indexterm" name="id4210778"></a><pre class="programlisting">void gtk_arrow_set (<a class="link" href="GtkArrow.html" title="GtkArrow">GtkArrow</a> *arrow, <a class="link" href="gtk-Standard-Enumerations.html#GtkArrowType">GtkArrowType</a> arrow_type, <a class="link" href="gtk-Standard-Enumerations.html#GtkShadowType">GtkShadowType</a> shadow_type);</pre><p>Sets the direction and style of the <a class="link" href="GtkArrow.html" title="GtkArrow"><span class="type">GtkArrow</span></a>, <em class="parameter"><code>arrow</code></em>.</p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><p><span class="term"><em class="parameter"><code>arrow</code></em> :</span></p></td><td>a widget of type <a class="link" href="GtkArrow.html" title="GtkArrow"><span class="type">GtkArrow</span></a>.</td></tr><tr><td><p><span class="term"><em class="parameter"><code>arrow_type</code></em> :</span></p></td><td>a valid <a class="link" href="gtk-Standard-Enumerations.html#GtkArrowType"><span class="type">GtkArrowType</span></a>.</td></tr><tr><td><p><span class="term"><em class="parameter"><code>shadow_type</code></em> :</span></p></td><td>a valid <a class="link" href="gtk-Standard-Enumerations.html#GtkShadowType"><span class="type">GtkShadowType</span></a>.</td></tr></tbody></table></div></div></div><div class="refsect1" lang="en"><a name="id4210908"></a><h2>Property Details</h2><div class="refsect2" lang="en"><a name="id4210919"></a><h3><a name="GtkArrow--arrow-type"></a>The <code class="literal">"arrow-type"</code> property</h3><a class="indexterm" name="id4210936"></a><pre class="programlisting"> "arrow-type" <a class="link" href="gtk-Standard-Enumerations.html#GtkArrowType">GtkArrowType</a> : Read / Write</pre><p>The direction the arrow should point.</p><p>Default value: GTK_ARROW_RIGHT</p></div><hr><div class="refsect2" lang="en"><a name="id4210963"></a><h3><a name="GtkArrow--shadow-type"></a>The <code class="literal">"shadow-type"</code> property</h3><a class="indexterm" name="id4210979"></a><pre class="programlisting"> "shadow-type" <a class="link" href="gtk-Standard-Enumerations.html#GtkShadowType">GtkShadowType</a> : Read / Write</pre><p>Appearance of the shadow surrounding the arrow.</p><p>Default value: GTK_SHADOW_OUT</p></div></div><div class="refsect1" lang="en"><a name="id4211008"></a><h2>Style Property Details</h2><div class="refsect2" lang="en"><a name="id4211019"></a><h3><a name="GtkArrow--arrow-scaling"></a>The <code class="literal">"arrow-scaling"</code> style property</h3><a class="indexterm" name="id4211036"></a><pre class="programlisting"> "arrow-scaling" <ahref="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gfloat">gfloat</a> : Read</pre><p>Amount of space used up by arrow.</p><p>Allowed values: [0,1]</p><p>Default value: 0.7</p></div></div><div class="refsect1" lang="en"><a name="id4211067"></a><h2>See Also</h2><p></p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><p><span class="term"><a class="link" href="GtkStyle.html#gtk-paint-arrow"><code class="function">gtk_paint_arrow()</code></a></span></p></td><td><p>the function used internally to paint the arrow.</p></td></tr></tbody></table></div><p></p></div><div class="refsect1" lang="en"><a name="id4211100"></a><div class="refsect2" lang="en"><a name="id4211102"></a></div><hr><div class="refsect2" lang="en"><a name="id4211103"></a></div></div></div></body></html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -