File: clutter-clutteralpha.xml

package info (click to toggle)
pyclutter 1.0.2-1
  • links: PTS, VCS
  • area: main
  • in suites: squeeze
  • size: 4,064 kB
  • ctags: 2,591
  • sloc: xml: 10,922; sh: 10,318; python: 7,188; ansic: 510; makefile: 423
file content (215 lines) | stat: -rw-r--r-- 7,348 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
<?xml version="1.0" standalone="no"?>
<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN"
    "http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd">
<refentry id="class-clutteralpha">
  <refmeta>
    <refentrytitle>clutter.Alpha</refentrytitle>
    <manvolnum>3</manvolnum>
    <refmiscinfo>PyGTK Docs</refmiscinfo>
  </refmeta>

  <refnamediv>
    <refname>clutter.Alpha</refname><refpurpose></refpurpose>
  </refnamediv>

  <refsect1>
    <title>Synopsis</title>

<classsynopsis language="python">
  <ooclass><classname>clutter.Alpha</classname></ooclass>
  <ooclass><classname><link linkend="class-gobject">GObject</link></classname></ooclass>
  <constructorsynopsis language="python">
    <methodname>__init__</methodname>
    <methodparam><parameter>timeline</parameter><initializer>None</initializer></methodparam>
    <methodparam><parameter>func</parameter><initializer>None</initializer></methodparam>
    <methodparam><parameter>data</parameter><initializer>None</initializer></methodparam>
  </constructorsynopsis>
  <methodsynopsis language="python">
    <methodname><link linkend="method-clutteralpha--get-alpha">get_alpha</link></methodname>
    <methodparam></methodparam>
  </methodsynopsis>
  <methodsynopsis language="python">
    <methodname><link linkend="method-clutteralpha--set-func">set_func</link></methodname>
    <methodparam><parameter>func</parameter></methodparam>
    <methodparam><parameter>data</parameter></methodparam>
  </methodsynopsis>
  <methodsynopsis language="python">
    <methodname><link linkend="method-clutteralpha--set-timeline">set_timeline</link></methodname>
    <methodparam><parameter>timeline</parameter></methodparam>
  </methodsynopsis>
  <methodsynopsis language="python">
    <methodname><link linkend="method-clutteralpha--get-timeline">get_timeline</link></methodname>
    <methodparam></methodparam>
  </methodsynopsis>
</classsynopsis>

  </refsect1>
  <refsect1>
    <title>Ancestry</title>

<synopsis>
<link linkend="class-gobject">gobject.GObject</link>
+-- <link linkend="class-gobject">gobject.GInitiallyUnowned</link>
  +-- <link linkend="class-clutteralpha">clutter.Alpha</link>
</synopsis>

  </refsect1>

  <refsect1>
    <title>Description</title>

    <para>clutter.Alpha is a class for calculating an integer value between
    0 and clutter.ALPHA_MAX_ALPHA as a function of time. You should
    provide a clutter.Timeline and bind it to the clutter.Alpha object;
    you should also provide a function returning the alpha value depending
    on the position inside the timeline; this function will be executed
    each time a new frame in the clutter.Timeline is reached. Since
    the alpha function is controlled by the timeline instance, you can
    pause or stop the clutter.Alpha from calling the alpha function by
    controlling the clutter.Timeline object.</para>

    <para>clutter.Alpha is used to "drive" a clutter.Behaviour
    instance.</para>
  </refsect1>

  <refsect1>
    <title>Constructor</title>

<programlisting>
  <constructorsynopsis language="python">
    <methodname>__init__</methodname>
    <methodparam><parameter>timeline</parameter><initializer>None</initializer></methodparam>
    <methodparam><parameter>func</parameter><initializer>None</initializer></methodparam>
    <methodparam><parameter>data</parameter><initializer>None</initializer></methodparam>
  </constructorsynopsis>
</programlisting>
  <variablelist>
    <varlistentry>
      <term><emphasis>Returns</emphasis>&nbsp;:</term>
      <listitem><simpara>a clutter.Alpha</simpara></listitem>
    </varlistentry>
  </variablelist>

  <para>Creates a new clutter.Alpha instance. You should use the newly
  created clutter.Alpha instance inside a clutter.Behaviour object.</para>

  </refsect1>

  <refsect1>
    <title>Methods</title>

  <refsect2 id="method-clutteralpha--get-alpha">
    <title>clutter.Alpha.get_alpha</title>

<programlisting>
  <methodsynopsis language="python">
    <methodname>get_alpha</methodname>
    <methodparam></methodparam>
  </methodsynopsis>
</programlisting>
  <variablelist>
    <varlistentry>
      <term><emphasis>Returns</emphasis>&nbsp;:</term>
      <listitem><simpara>a integer value between 0 and clutter.ALPHA_MAX_ALPHA</simpara></listitem>
    </varlistentry>
  </variablelist>
  <para>Queries the current alpha value.</para>
  </refsect2>


  <refsect2 id="method-clutteralpha--set-func">
    <title>clutter.Alpha.set_func</title>

<programlisting>
  <methodsynopsis language="python">
    <methodname>set_func</methodname>
    <methodparam><parameter>func</parameter></methodparam>
    <methodparam><parameter>data</parameter></methodparam>
  </methodsynopsis>
</programlisting>
  <variablelist>
    <varlistentry>
      <term><parameter>func</parameter>&nbsp;:</term>
      <listitem><simpara>a callable</simpara></listitem>
    </varlistentry>
    <varlistentry>
      <term><parameter>data</parameter>&nbsp;:</term>
      <listitem><simpara>data to pass to the callable</simpara></listitem>
    </varlistentry>
  </variablelist>
  <para>Sets the function used to compute the alpha value at each frame
  of the clutter.Timeline bound to the alpha instance.</para>
  </refsect2>


  <refsect2 id="method-clutteralpha--set-timeline">
    <title>clutter.Alpha.set_timeline</title>

<programlisting>
  <methodsynopsis language="python">
    <methodname>set_timeline</methodname>
    <methodparam><parameter>timeline</parameter></methodparam>
  </methodsynopsis>
</programlisting>
  <variablelist>
    <varlistentry>
      <term><parameter>timeline</parameter>&nbsp;:</term>
      <listitem><simpara>a clutter.Timeline</simpara></listitem>
    </varlistentry>
  </variablelist>
  <para>Binds a clutter.Alpha to a clutter.Timeline.</para>
  </refsect2>


  <refsect2 id="method-clutteralpha--get-timeline">
    <title>clutter.Alpha.get_timeline</title>

<programlisting>
  <methodsynopsis language="python">
    <methodname>get_timeline</methodname>
    <methodparam></methodparam>
  </methodsynopsis>
</programlisting>
  <variablelist>
    <varlistentry>
      <term><emphasis>Returns</emphasis>&nbsp;:</term>
      <listitem><simpara>a clutter.Timeline</simpara></listitem>
    </varlistentry>
  </variablelist>
  <para>Retrieves the clutter.Timeline bound to the alpha instance.</para>
  </refsect2>

  </refsect1>

  <refsect1>
    <title>Properties</title>

    <para><link linkend="properties-clutteralpha">clutter.Alpha Properties</link></para>

    <blockquote role="properties">
      <informaltable pgwide="1" frame="none">
        <tgroup cols="3">
          <colspec column="1" colwidth="1in"/>
          <colspec column="2" colwidth="1in"/>
          <colspec column="3" colwidth="4in"/>
          <tbody>
            <row valign="top">
              <entry>"timeline"</entry>
              <entry>Read-Write</entry>
              <entry>a <link linkend="class-cluttertimeline">clutter.Timeline</link> instance
              used as the time source for the alpha function.</entry>
            </row>

            <row valign="top">
              <entry>"alpha"</entry>
              <entry>Read-only</entry>
              <entry>The alpha value as computed by the alpha function</entry>
            </row>
          </tbody>
        </tgroup>
      </informaltable>
    </blockquote>

  </refsect1>

</refentry>