~timo-jyrinki/ubuntu/trusty/maliit-framework/fix_qt52

« back to all changes in this revision

Viewing changes to connection/text.xml

  • Committer: Package Import Robot
  • Author(s): Ricardo Salveti de Araujo
  • Date: 2013-07-23 19:47:04 UTC
  • mto: This revision was merged to the branch mainline in revision 8.
  • Revision ID: package-import@ubuntu.com-20130723194704-0o18p2ao0x9sa1zx
Tags: upstream-0.99.0+git20130615+97e8335
ImportĀ upstreamĀ versionĀ 0.99.0+git20130615+97e8335

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
<?xml version="1.0" encoding="UTF-8"?>
2
 
<protocol name="text">
3
 
 
4
 
  <copyright>
5
 
    Copyright Ā© 2012 Intel Corporation
6
 
 
7
 
    Permission to use, copy, modify, distribute, and sell this
8
 
    software and its documentation for any purpose is hereby granted
9
 
    without fee, provided that the above copyright notice appear in
10
 
    all copies and that both that copyright notice and this permission
11
 
    notice appear in supporting documentation, and that the name of
12
 
    the copyright holders not be used in advertising or publicity
13
 
    pertaining to distribution of the software without specific,
14
 
    written prior permission.  The copyright holders make no
15
 
    representations about the suitability of this software for any
16
 
    purpose.  It is provided "as is" without express or implied
17
 
    warranty.
18
 
 
19
 
    THE COPYRIGHT HOLDERS DISCLAIM ALL WARRANTIES WITH REGARD TO THIS
20
 
    SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND
21
 
    FITNESS, IN NO EVENT SHALL THE COPYRIGHT HOLDERS BE LIABLE FOR ANY
22
 
    SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
23
 
    WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN
24
 
    AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION,
25
 
    ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF
26
 
    THIS SOFTWARE.
27
 
  </copyright>
28
 
 
29
 
  <interface name="text_model" version="1">
30
 
    <description summary="text model">
31
 
      A model for text input. Adds support for text input and input methods to
32
 
      applications. A text_model object is created from a text_model_factory and
33
 
      corresponds typically to a text entry in an application. Requests are used
34
 
      to activate/deactivate the model and set information like surrounding and
35
 
      selected text or the content type. The information about entered text is
36
 
      sent to the model via the pre-edit and commit events. Using this interface
37
 
      removes the need for applications to directly process hardware key events
38
 
      and compose text out of them.
39
 
    </description>
40
 
    <request name="set_surrounding_text">
41
 
      <description summary="sets the surrounding text">
42
 
        Sets the plain surrounding text around the input position. Cursor is the
43
 
        byte index within the surrounding text. Anchor is the byte index of the
44
 
        selection anchor within the surrounding text. If there is no selected
45
 
        text anchor is the same as cursor.
46
 
      </description>
47
 
      <arg name="text" type="string"/>
48
 
      <arg name="cursor" type="uint"/>
49
 
      <arg name="anchor" type="uint"/>
50
 
    </request>
51
 
    <request name="activate">
52
 
      <description summary="request activation">
53
 
        Requests the model to be activated (typically when the text entry gets
54
 
        focus). The seat argument is a wl_seat which maintains the focus for
55
 
        this activation. The surface argument is a wl_surface assigned to the
56
 
        model and tracked for focus lost. The activated event is emitted on
57
 
        successful activation.
58
 
      </description>
59
 
      <arg name="serial" type="uint"/>
60
 
      <arg name="seat" type="object" interface="wl_seat"/>
61
 
      <arg name="surface" type="object" interface="wl_surface"/>
62
 
    </request>
63
 
    <request name="deactivate">
64
 
      <description summary="request deactivation">
65
 
        Requests the model to be deactivated (typically when the text entry
66
 
        lost focus). The seat argument is a wl_seat which was used for
67
 
        activation.
68
 
      </description>
69
 
      <arg name="seat" type="object" interface="wl_seat"/>
70
 
    </request>
71
 
    <request name="reset">
72
 
      <description summary="reset">
73
 
        Should be called by an editor widget when the input state should
74
 
        be reseted, for example after the text was changed outside of the
75
 
        normal input method flow.
76
 
      </description>
77
 
      <arg name="serial" type="uint"/>
78
 
    </request>
79
 
    <request name="set_micro_focus">
80
 
      <arg name="x" type="int"/>
81
 
      <arg name="y" type="int"/>
82
 
      <arg name="width" type="int"/>
83
 
      <arg name="height" type="int"/>
84
 
    </request>
85
 
    <request name="set_preedit"/>
86
 
    <enum name="content_hint">
87
 
      <description summary="content hint">
88
 
        Content hint is a bitmask to allow to modify the behavior of the text input
89
 
      </description>
90
 
      <entry name="none" value="0x0" summary="no special behaviour"/>
91
 
      <entry name="default" value="0x7" summary="auto completion, cotrrection and capitalization"/>
92
 
      <entry name="password" value="0xc" summary="hidden and sensitive text"/>
93
 
      <entry name="auto_completion" value="0x1" summary="suggest word completions"/>
94
 
      <entry name="auto_correction" value="0x2" summary="suggest word corrections"/>
95
 
      <entry name="auto_capitalization" value="0x4" summary="switch to upercase letters at the end of a sentence"/>
96
 
      <entry name="lowercase" value="0x8" summary="prefer lowercase letters"/>
97
 
      <entry name="uppercase" value="0x10" summary="prefer upercase letters"/>
98
 
      <entry name="titlecase" value="0x20" summary="switch to upercase letters at the end of a word"/>
99
 
      <entry name="hidden_text" value="0x40" summary="characters should be hidden"/>
100
 
      <entry name="sensitive_data" value="0x80" summary="typed text should not be stored"/>
101
 
      <entry name="multiline" value="0x200" summary="the text input is multiline"/>
102
 
    </enum>
103
 
    <enum name="content_purpose">
104
 
      <description summary="content purpose">
105
 
        The content purpose allows to specify the primary purpose of a text input.
106
 
 
107
 
        This allows an input method to show special purpose input panels or to
108
 
        disallow some characters.
109
 
      </description>
110
 
      <entry name="normal" value="0" summary="default input, allowing all characters"/>
111
 
      <entry name="latin" value="1" summary="allow just latin characters"/>
112
 
      <entry name="alpha" value="2" summary="allow only alphabetic characters"/>
113
 
      <entry name="digits" value="3" summary="allow only digits"/>
114
 
      <entry name="number" value="4" summary="input a number (including decimal dot and sign)"/>
115
 
      <entry name="phone" value="5" summary="input a ohone number"/>
116
 
      <entry name="url" value="6" summary="input an URL"/>
117
 
      <entry name="email" value="7" summary="input an email address"/>
118
 
      <entry name="name" value="8" summary="input a name of a person"/>
119
 
      <entry name="password" value="9" summary="input a password (combine with password or sensistive_data hint)"/>
120
 
      <entry name="date" value="10" summary="input a date"/>
121
 
      <entry name="time" value="11" summary="input a time"/>
122
 
      <entry name="datetime" value="12" summary="input a date and time"/>
123
 
      <entry name="terminal" value="13" summary="input for a terminal, show special control keys on a virtual keyboard"/>
124
 
    </enum>
125
 
    <request name="set_content_type">
126
 
      <description summary="set content purpose and hint">
127
 
        Sets the content purpose and content hint. While the purpose is the
128
 
        basic purpose of an input field, the hint flags allow to modify some
129
 
        of the behavior.
130
 
 
131
 
        When no content type is explicitly set, a normal content purpose with
132
 
        default hints (auto completion, auto correction, auto capitalization)
133
 
        should be assumed.
134
 
      </description>
135
 
      <arg name="hint" type="uint"/>
136
 
      <arg name="purpose" type="uint"/>
137
 
    </request>
138
 
    <request name="invoke_action">
139
 
      <arg name="button" type="uint"/>
140
 
      <arg name="index" type="uint"/>
141
 
    </request>
142
 
    <event name="commit_string">
143
 
      <description summary="commit">
144
 
        Notify when text should be inserted into the editor widget. The text
145
 
        to commit could be either just a single character after a key press
146
 
        or the result of some composing (pre-edit). It also sets the new
147
 
        cursor position (as byte index) relative to the inserted text.
148
 
 
149
 
        Any previously set composing text should be removed.
150
 
      </description>
151
 
      <arg name="serial" type="uint"/>
152
 
      <arg name="text" type="string"/>
153
 
      <arg name="index" type="uint"/>
154
 
    </event>
155
 
    <event name="preedit_string">
156
 
      <description summary="pre-edit">
157
 
        Notify when a new composing text (pre-edit) should be set around the
158
 
        current cursor position. Any previously set composing text should
159
 
        be removed.
160
 
 
161
 
        The commit text can be used to replace the preedit text on reset
162
 
        (for example on unfocus).
163
 
      </description>
164
 
      <arg name="serial" type="uint"/>
165
 
      <arg name="text" type="string"/>
166
 
      <arg name="commit" type="string"/>
167
 
    </event>
168
 
    <event name="delete_surrounding_text">
169
 
      <description summary="delete surrounding text">
170
 
        Notify when the text around the current cursor position should be
171
 
        deleted. Index is relative to the current cursor (as byte index).
172
 
        Length is the length of deleted text (as bytes).
173
 
      </description>
174
 
      <arg name="serial" type="uint"/>
175
 
      <arg name="index" type="int"/>
176
 
      <arg name="length" type="uint"/>
177
 
    </event>
178
 
    <enum name="preedit_style">
179
 
      <entry name="default" value="1"/>
180
 
      <entry name="active" value="2"/>
181
 
      <entry name="inactive" value="3"/>
182
 
      <entry name="highlight" value="4"/>
183
 
      <entry name="underline" value="5"/>
184
 
      <entry name="selection" value="6"/>
185
 
      <entry name="incorrect" value="7"/>
186
 
    </enum>
187
 
    <event name="preedit_styling">
188
 
      <description summary="pre-edit styling">
189
 
        Sets styling information on composing text. The style is applied for
190
 
        length (in bytes) characters from index relative to the beginning of
191
 
        the composing text (as byte index). Multiple styles can be applied
192
 
        to a composing text.
193
 
 
194
 
        This event should be handled as part of a following preedit_string
195
 
        event.
196
 
      </description>
197
 
      <arg name="serial" type="uint"/>
198
 
      <arg name="index" type="uint"/>
199
 
      <arg name="length" type="uint"/>
200
 
      <arg name="style" type="uint"/>
201
 
    </event>
202
 
    <event name="preedit_cursor">
203
 
      <description summary="pre-edit cursor">
204
 
        Sets the cursor position inside the composing text (as byte index)
205
 
        relative to the start of the composing text.
206
 
 
207
 
        This event should be handled as part of a following preedit_string
208
 
        event.
209
 
      </description>
210
 
      <arg name="serial" type="uint"/>
211
 
      <arg name="index" type="int"/>
212
 
    </event>
213
 
    <event name="modifiers_map">
214
 
      <description summary="modifiers map">
215
 
        Transfer an array of 0-terminated modifiers names. The position in
216
 
        the array is the index of the modifier as used in the modifiers
217
 
        bitmask in the keysym event.
218
 
      </description>
219
 
      <arg name="map" type="array"/>
220
 
    </event>
221
 
    <event name="keysym">
222
 
      <description summary="keysym">
223
 
        Notify when a key event was sent. Key events should not be used
224
 
        for normal text input operations, which should be done with
225
 
        commit_string, delete_surrounfing_text, etc. The key event follows
226
 
        the wl_keyboard key event convention. State is a XKB keysym, state a
227
 
        wl_keyboard key_state. Modifiers are a mask for effective modifiers
228
 
        (where the modfier indices are set by the modifiers_map event)
229
 
      </description>
230
 
      <arg name="serial" type="uint"/>
231
 
      <arg name="time" type="uint"/>
232
 
      <arg name="sym" type="uint"/>
233
 
      <arg name="state" type="uint"/>
234
 
      <arg name="modifiers" type="uint"/>
235
 
    </event>
236
 
    <event name="selection_replacement"/>
237
 
    <event name="direction"/>
238
 
    <event name="locale"/>
239
 
    <event name="enter">
240
 
      <description summary="enter event">
241
 
        Notify the model when it is activated. Typically in response to an
242
 
        activate request.
243
 
      </description>
244
 
      <arg name="surface" type="object" interface="wl_surface"/>
245
 
    </event>
246
 
    <event name="leave">
247
 
      <description summary="leave event">
248
 
        Notify the model when it is deactivated. Either in response to a
249
 
        deactivate request or when the assigned surface lost focus or was
250
 
        destroyed.
251
 
      </description>
252
 
    </event>
253
 
  </interface>
254
 
 
255
 
  <interface name="text_model_factory" version="1">
256
 
    <description summary="text model factory">
257
 
      A factory for text models. This object is a singleton global.
258
 
    </description>
259
 
    <request name="create_text_model">
260
 
      <description summary="create text model">
261
 
        Creates a new text model object.
262
 
      </description>
263
 
      <arg name="id" type="new_id" interface="text_model"/>
264
 
    </request>
265
 
  </interface>
266
 
</protocol>