<?xml version="1.0"?>
<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN"
               "http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd" [
<!ENTITY % local.common.attrib "xmlns:xi  CDATA  #FIXED 'http://www.w3.org/2003/XInclude'">
<!ENTITY version SYSTEM "version.xml">
<!ENTITY pi "&#960;">
<!ENTITY solidus "&#8260;">
]>
<refentry id="GtkGestureStylus">
<refmeta>
<refentrytitle role="top_of_page" id="GtkGestureStylus.top_of_page">GtkGestureStylus</refentrytitle>
<manvolnum>3</manvolnum>
<refmiscinfo>GTK4 Library</refmiscinfo>
</refmeta>
<refnamediv>
<refname>GtkGestureStylus</refname>
<refpurpose>Gesture for stylus input</refpurpose>
</refnamediv>

<refsect1 id="GtkGestureStylus.functions" role="functions_proto">
<title role="functions_proto.title">Functions</title>
<informaltable pgwide="1" frame="none">
<tgroup cols="2">
<colspec colname="functions_proto_type" colwidth="150px"/>
<colspec colname="functions_proto_name"/>
<tbody>
<row><entry role="function_type"><link linkend="GtkGesture"><returnvalue>GtkGesture</returnvalue></link>&#160;*
</entry><entry role="function_name"><link linkend="gtk-gesture-stylus-new">gtk_gesture_stylus_new</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>
<row><entry role="function_type"><link linkend="gboolean"><returnvalue>gboolean</returnvalue></link>
</entry><entry role="function_name"><link linkend="gtk-gesture-stylus-get-axis">gtk_gesture_stylus_get_axis</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>
<row><entry role="function_type"><link linkend="gboolean"><returnvalue>gboolean</returnvalue></link>
</entry><entry role="function_name"><link linkend="gtk-gesture-stylus-get-axes">gtk_gesture_stylus_get_axes</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>
<row><entry role="function_type"><link linkend="gboolean"><returnvalue>gboolean</returnvalue></link>
</entry><entry role="function_name"><link linkend="gtk-gesture-stylus-get-backlog">gtk_gesture_stylus_get_backlog</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>
<row><entry role="function_type"><link linkend="GdkDeviceTool"><returnvalue>GdkDeviceTool</returnvalue></link>&#160;*
</entry><entry role="function_name"><link linkend="gtk-gesture-stylus-get-device-tool">gtk_gesture_stylus_get_device_tool</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>

</tbody>
</tgroup>
</informaltable>
</refsect1>
<refsect1 id="GtkGestureStylus.signals" role="signal_proto">
<title role="signal_proto.title">Signals</title>
<informaltable frame="none">
<tgroup cols="3">
<colspec colname="signal_proto_type" colwidth="150px"/>
<colspec colname="signal_proto_name" colwidth="300px"/>
<colspec colname="signal_proto_flags" colwidth="200px"/>
<tbody>
<row><entry role="signal_type"><link linkend="void"><returnvalue>void</returnvalue></link></entry><entry role="signal_name"><link linkend="GtkGestureStylus-down">down</link></entry><entry role="signal_flags"><link linkend="G-SIGNAL-RUN-LAST:CAPS">Run Last</link></entry></row>
<row><entry role="signal_type"><link linkend="void"><returnvalue>void</returnvalue></link></entry><entry role="signal_name"><link linkend="GtkGestureStylus-motion">motion</link></entry><entry role="signal_flags"><link linkend="G-SIGNAL-RUN-LAST:CAPS">Run Last</link></entry></row>
<row><entry role="signal_type"><link linkend="void"><returnvalue>void</returnvalue></link></entry><entry role="signal_name"><link linkend="GtkGestureStylus-proximity">proximity</link></entry><entry role="signal_flags"><link linkend="G-SIGNAL-RUN-LAST:CAPS">Run Last</link></entry></row>
<row><entry role="signal_type"><link linkend="void"><returnvalue>void</returnvalue></link></entry><entry role="signal_name"><link linkend="GtkGestureStylus-up">up</link></entry><entry role="signal_flags"><link linkend="G-SIGNAL-RUN-LAST:CAPS">Run Last</link></entry></row>

</tbody>
</tgroup>
</informaltable>
</refsect1>
<refsect1 id="GtkGestureStylus.other" role="other_proto">
<title role="other_proto.title">Types and Values</title>
<informaltable pgwide="1" frame="none">
<tgroup cols="2">
<colspec colname="other_proto_type" colwidth="150px"/>
<colspec colname="other_proto_name"/>
<tbody>
<row><entry role="datatype_keyword"></entry><entry role="function_name"><link linkend="GtkGestureStylus-struct">GtkGestureStylus</link></entry></row>

</tbody>
</tgroup>
</informaltable>
</refsect1>
<refsect1 id="GtkGestureStylus.object-hierarchy" role="object_hierarchy">
<title role="object_hierarchy.title">Object Hierarchy</title>
<screen>    <link linkend="GObject">GObject</link>
    <phrase role="lineart">&#9584;&#9472;&#9472;</phrase> <link linkend="GtkEventController">GtkEventController</link>
        <phrase role="lineart">&#9584;&#9472;&#9472;</phrase> <link linkend="GtkGesture">GtkGesture</link>
            <phrase role="lineart">&#9584;&#9472;&#9472;</phrase> <link linkend="GtkGestureSingle">GtkGestureSingle</link>
                <phrase role="lineart">&#9584;&#9472;&#9472;</phrase> GtkGestureStylus
</screen>
</refsect1>

<refsect1 id="GtkGestureStylus.includes"><title>Includes</title><synopsis>#include &lt;gtk/gtk.h&gt;
</synopsis></refsect1>

<refsect1 id="GtkGestureStylus.description" role="desc">
<title role="desc.title">Description</title>
<para><link linkend="GtkGestureStylus"><type>GtkGestureStylus</type></link> is a <link linkend="GtkGesture"><type>GtkGesture</type></link> implementation specific to stylus
input. The provided signals just provide the basic information</para>

</refsect1>
<refsect1 id="GtkGestureStylus.functions_details" role="details">
<title role="details.title">Functions</title>
<refsect2 id="gtk-gesture-stylus-new" role="function">
<title>gtk_gesture_stylus_new&#160;()</title>
<indexterm zone="gtk-gesture-stylus-new"><primary>gtk_gesture_stylus_new</primary></indexterm>
<programlisting language="C"><link linkend="GtkGesture"><returnvalue>GtkGesture</returnvalue></link>&#160;*
gtk_gesture_stylus_new (<parameter><type>void</type></parameter>);</programlisting>
<para>Creates a new <link linkend="GtkGestureStylus"><type>GtkGestureStylus</type></link>.</para>
<refsect3 id="gtk-gesture-stylus-new.returns" role="returns">
<title>Returns</title>
<para> a newly created stylus gesture</para>
</refsect3></refsect2>
<refsect2 id="gtk-gesture-stylus-get-axis" role="function">
<title>gtk_gesture_stylus_get_axis&#160;()</title>
<indexterm zone="gtk-gesture-stylus-get-axis"><primary>gtk_gesture_stylus_get_axis</primary></indexterm>
<programlisting language="C"><link linkend="gboolean"><returnvalue>gboolean</returnvalue></link>
gtk_gesture_stylus_get_axis (<parameter><link linkend="GtkGestureStylus"><type>GtkGestureStylus</type></link> *gesture</parameter>,
                             <parameter><link linkend="GdkAxisUse"><type>GdkAxisUse</type></link> axis</parameter>,
                             <parameter><link linkend="gdouble"><type>gdouble</type></link> *value</parameter>);</programlisting>
<para>Returns the current value for the requested <parameter>axis</parameter>
. This function
must be called from either the <link linkend="GtkGestureStylus-down"><type>“down”</type></link>,
<link linkend="GtkGestureStylus-motion"><type>“motion”</type></link>, <link linkend="GtkGestureStylus-up"><type>“up”</type></link> or <link linkend="GtkGestureStylus-proximity"><type>“proximity”</type></link>
signals.</para>
<refsect3 id="gtk-gesture-stylus-get-axis.parameters" role="parameters">
<title>Parameters</title>
<informaltable role="parameters_table" pgwide="1" frame="none">
<tgroup cols="3">
<colspec colname="parameters_name" colwidth="150px"/>
<colspec colname="parameters_description"/>
<colspec colname="parameters_annotations" colwidth="200px"/>
<tbody>
<row><entry role="parameter_name"><para>gesture</para></entry>
<entry role="parameter_description"><para>a <link linkend="GtkGestureStylus"><type>GtkGestureStylus</type></link></para></entry>
<entry role="parameter_annotations"></entry></row>
<row><entry role="parameter_name"><para>axis</para></entry>
<entry role="parameter_description"><para>requested device axis</para></entry>
<entry role="parameter_annotations"></entry></row>
<row><entry role="parameter_name"><para>value</para></entry>
<entry role="parameter_description"><para>return location for the axis value. </para></entry>
<entry role="parameter_annotations"><emphasis role="annotation">[<acronym>out</acronym>]</emphasis></entry></row>
</tbody></tgroup></informaltable>
</refsect3><refsect3 id="gtk-gesture-stylus-get-axis.returns" role="returns">
<title>Returns</title>
<para> <link linkend="TRUE:CAPS"><type>TRUE</type></link> if there is a current value for the axis</para>
</refsect3></refsect2>
<refsect2 id="gtk-gesture-stylus-get-axes" role="function">
<title>gtk_gesture_stylus_get_axes&#160;()</title>
<indexterm zone="gtk-gesture-stylus-get-axes"><primary>gtk_gesture_stylus_get_axes</primary></indexterm>
<programlisting language="C"><link linkend="gboolean"><returnvalue>gboolean</returnvalue></link>
gtk_gesture_stylus_get_axes (<parameter><link linkend="GtkGestureStylus"><type>GtkGestureStylus</type></link> *gesture</parameter>,
                             <parameter><link linkend="GdkAxisUse"><type>GdkAxisUse</type></link> axes[]</parameter>,
                             <parameter><link linkend="gdouble"><type>gdouble</type></link> **values</parameter>);</programlisting>
<para>Returns the current values for the requested <parameter>axes</parameter>
. This function
must be called from either the <link linkend="GtkGestureStylus-down"><type>“down”</type></link>,
<link linkend="GtkGestureStylus-motion"><type>“motion”</type></link>, <link linkend="GtkGestureStylus-up"><type>“up”</type></link> or <link linkend="GtkGestureStylus-proximity"><type>“proximity”</type></link>
signals.</para>
<refsect3 id="gtk-gesture-stylus-get-axes.parameters" role="parameters">
<title>Parameters</title>
<informaltable role="parameters_table" pgwide="1" frame="none">
<tgroup cols="3">
<colspec colname="parameters_name" colwidth="150px"/>
<colspec colname="parameters_description"/>
<colspec colname="parameters_annotations" colwidth="200px"/>
<tbody>
<row><entry role="parameter_name"><para>gesture</para></entry>
<entry role="parameter_description"><para>a GtkGestureStylus</para></entry>
<entry role="parameter_annotations"></entry></row>
<row><entry role="parameter_name"><para>axes</para></entry>
<entry role="parameter_description"><para>array of requested axes, terminated with <link linkend="GDK-AXIS-IGNORE:CAPS"><type>GDK_AXIS_IGNORE</type></link>. </para></entry>
<entry role="parameter_annotations"><emphasis role="annotation">[<acronym>array</acronym>]</emphasis></entry></row>
<row><entry role="parameter_name"><para>values</para></entry>
<entry role="parameter_description"><para>return location for the axis values. </para></entry>
<entry role="parameter_annotations"><emphasis role="annotation">[<acronym>out</acronym>][<acronym>array</acronym>]</emphasis></entry></row>
</tbody></tgroup></informaltable>
</refsect3><refsect3 id="gtk-gesture-stylus-get-axes.returns" role="returns">
<title>Returns</title>
<para> <link linkend="TRUE:CAPS"><type>TRUE</type></link> if there is a current value for the axes</para>
</refsect3></refsect2>
<refsect2 id="gtk-gesture-stylus-get-backlog" role="function">
<title>gtk_gesture_stylus_get_backlog&#160;()</title>
<indexterm zone="gtk-gesture-stylus-get-backlog"><primary>gtk_gesture_stylus_get_backlog</primary></indexterm>
<programlisting language="C"><link linkend="gboolean"><returnvalue>gboolean</returnvalue></link>
gtk_gesture_stylus_get_backlog (<parameter><link linkend="GtkGestureStylus"><type>GtkGestureStylus</type></link> *gesture</parameter>,
                                <parameter><link linkend="GdkTimeCoord"><type>GdkTimeCoord</type></link> **backlog</parameter>,
                                <parameter><link linkend="guint"><type>guint</type></link> *n_elems</parameter>);</programlisting>
<para>By default, GTK+ will limit rate of input events. On stylus input where
accuracy of strokes is paramount, this function returns the accumulated
coordinate/timing state before the emission of the current
<link linkend="GtkGestureStylus-motion"><type>“motion”</type></link> signal.</para>
<para>This function may only be called within a <link linkend="GtkGestureStylus-motion"><type>“motion”</type></link>
signal handler, the state given in this signal and obtainable through
<link linkend="gtk-gesture-stylus-get-axis"><function>gtk_gesture_stylus_get_axis()</function></link> call express the latest (most up-to-date)
state in motion history.</para>
<para><parameter>backlog</parameter>
 is provided in chronological order.</para>
<refsect3 id="gtk-gesture-stylus-get-backlog.parameters" role="parameters">
<title>Parameters</title>
<informaltable role="parameters_table" pgwide="1" frame="none">
<tgroup cols="3">
<colspec colname="parameters_name" colwidth="150px"/>
<colspec colname="parameters_description"/>
<colspec colname="parameters_annotations" colwidth="200px"/>
<tbody>
<row><entry role="parameter_name"><para>gesture</para></entry>
<entry role="parameter_description"><para>a <link linkend="GtkGestureStylus"><type>GtkGestureStylus</type></link></para></entry>
<entry role="parameter_annotations"></entry></row>
<row><entry role="parameter_name"><para>backlog</para></entry>
<entry role="parameter_description"><para>coordinates and times for the backlog events. </para></entry>
<entry role="parameter_annotations"><emphasis role="annotation">[<acronym>out</acronym>][<acronym>array</acronym> length=n_elems]</emphasis></entry></row>
<row><entry role="parameter_name"><para>n_elems</para></entry>
<entry role="parameter_description"><para>return location for the number of elements. </para></entry>
<entry role="parameter_annotations"><emphasis role="annotation">[<acronym>out</acronym>]</emphasis></entry></row>
</tbody></tgroup></informaltable>
</refsect3><refsect3 id="gtk-gesture-stylus-get-backlog.returns" role="returns">
<title>Returns</title>
<para> <link linkend="TRUE:CAPS"><type>TRUE</type></link> if there is a backlog to unfold in the current state.</para>
</refsect3></refsect2>
<refsect2 id="gtk-gesture-stylus-get-device-tool" role="function">
<title>gtk_gesture_stylus_get_device_tool&#160;()</title>
<indexterm zone="gtk-gesture-stylus-get-device-tool"><primary>gtk_gesture_stylus_get_device_tool</primary></indexterm>
<programlisting language="C"><link linkend="GdkDeviceTool"><returnvalue>GdkDeviceTool</returnvalue></link>&#160;*
gtk_gesture_stylus_get_device_tool (<parameter><link linkend="GtkGestureStylus"><type>GtkGestureStylus</type></link> *gesture</parameter>);</programlisting>
<para>Returns the <link linkend="GdkDeviceTool"><type>GdkDeviceTool</type></link> currently driving input through this gesture.
This function must be called from either the <link linkend="GtkGestureStylus-down"><type>“down”</type></link>,
<link linkend="GtkGestureStylus-motion"><type>“motion”</type></link>, <link linkend="GtkGestureStylus-up"><type>“up”</type></link> or <link linkend="GtkGestureStylus-proximity"><type>“proximity”</type></link>
signal handlers.</para>
<refsect3 id="gtk-gesture-stylus-get-device-tool.parameters" role="parameters">
<title>Parameters</title>
<informaltable role="parameters_table" pgwide="1" frame="none">
<tgroup cols="3">
<colspec colname="parameters_name" colwidth="150px"/>
<colspec colname="parameters_description"/>
<colspec colname="parameters_annotations" colwidth="200px"/>
<tbody>
<row><entry role="parameter_name"><para>gesture</para></entry>
<entry role="parameter_description"><para>a <link linkend="GtkGestureStylus"><type>GtkGestureStylus</type></link></para></entry>
<entry role="parameter_annotations"></entry></row>
</tbody></tgroup></informaltable>
</refsect3><refsect3 id="gtk-gesture-stylus-get-device-tool.returns" role="returns">
<title>Returns</title>
<para>The current stylus tool. </para>
<para><emphasis role="annotation">[<acronym>nullable</acronym>][<acronym>transfer none</acronym>]</emphasis></para>
</refsect3></refsect2>

</refsect1>
<refsect1 id="GtkGestureStylus.other_details" role="details">
<title role="details.title">Types and Values</title>
<refsect2 id="GtkGestureStylus-struct" role="struct">
<title>GtkGestureStylus</title>
<indexterm zone="GtkGestureStylus-struct"><primary>GtkGestureStylus</primary></indexterm>
<programlisting language="C">typedef struct _GtkGestureStylus GtkGestureStylus;</programlisting>
</refsect2>

</refsect1>
<refsect1 id="GtkGestureStylus.signal-details" role="signals">
<title role="signals.title">Signal Details</title>
<refsect2 id="GtkGestureStylus-down" role="signal"><title>The <literal>“down”</literal> signal</title>
<indexterm zone="GtkGestureStylus-down"><primary>GtkGestureStylus::down</primary></indexterm>
<programlisting language="C"><link linkend="void"><returnvalue>void</returnvalue></link>
user_function (<link linkend="GtkGestureStylus"><type>GtkGestureStylus</type></link> *gesturestylus,
               <link linkend="gdouble"><type>gdouble</type></link>           arg1,
               <link linkend="gdouble"><type>gdouble</type></link>           arg2,
               <link linkend="gpointer"><type>gpointer</type></link>          user_data)</programlisting>
<para>Flags: <link linkend="G-SIGNAL-RUN-LAST:CAPS">Run Last</link></para>
</refsect2><refsect2 id="GtkGestureStylus-motion" role="signal"><title>The <literal>“motion”</literal> signal</title>
<indexterm zone="GtkGestureStylus-motion"><primary>GtkGestureStylus::motion</primary></indexterm>
<programlisting language="C"><link linkend="void"><returnvalue>void</returnvalue></link>
user_function (<link linkend="GtkGestureStylus"><type>GtkGestureStylus</type></link> *gesturestylus,
               <link linkend="gdouble"><type>gdouble</type></link>           arg1,
               <link linkend="gdouble"><type>gdouble</type></link>           arg2,
               <link linkend="gpointer"><type>gpointer</type></link>          user_data)</programlisting>
<para>Flags: <link linkend="G-SIGNAL-RUN-LAST:CAPS">Run Last</link></para>
</refsect2><refsect2 id="GtkGestureStylus-proximity" role="signal"><title>The <literal>“proximity”</literal> signal</title>
<indexterm zone="GtkGestureStylus-proximity"><primary>GtkGestureStylus::proximity</primary></indexterm>
<programlisting language="C"><link linkend="void"><returnvalue>void</returnvalue></link>
user_function (<link linkend="GtkGestureStylus"><type>GtkGestureStylus</type></link> *gesturestylus,
               <link linkend="gdouble"><type>gdouble</type></link>           arg1,
               <link linkend="gdouble"><type>gdouble</type></link>           arg2,
               <link linkend="gpointer"><type>gpointer</type></link>          user_data)</programlisting>
<para>Flags: <link linkend="G-SIGNAL-RUN-LAST:CAPS">Run Last</link></para>
</refsect2><refsect2 id="GtkGestureStylus-up" role="signal"><title>The <literal>“up”</literal> signal</title>
<indexterm zone="GtkGestureStylus-up"><primary>GtkGestureStylus::up</primary></indexterm>
<programlisting language="C"><link linkend="void"><returnvalue>void</returnvalue></link>
user_function (<link linkend="GtkGestureStylus"><type>GtkGestureStylus</type></link> *gesturestylus,
               <link linkend="gdouble"><type>gdouble</type></link>           arg1,
               <link linkend="gdouble"><type>gdouble</type></link>           arg2,
               <link linkend="gpointer"><type>gpointer</type></link>          user_data)</programlisting>
<para>Flags: <link linkend="G-SIGNAL-RUN-LAST:CAPS">Run Last</link></para>
</refsect2>
</refsect1>
<refsect1 id="GtkGestureStylus.see-also">
<title>See Also</title>
<para><link linkend="GtkGesture"><type>GtkGesture</type></link>, <link linkend="GtkGestureSingle"><type>GtkGestureSingle</type></link></para>

</refsect1>

</refentry>
