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
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
// This file is auto-generated by rute_gen. DO NOT EDIT.
use rute_ffi_base::*;

#[allow(unused_imports)]
use auto::margins_ffi::RUMargins;
#[allow(unused_imports)]
use auto::object_ffi::*;
#[allow(unused_imports)]
use auto::paint_device_ffi::*;
#[allow(unused_imports)]
use auto::widget_ffi::*;
#[allow(unused_imports)]
use std::os::raw::c_void;
#[repr(C)]
#[derive(Copy, Clone)]
pub struct RULineEditFuncs {
    pub destroy: extern "C" fn(self_c: *const RUBase),
    pub text: extern "C" fn(self_c: *const RUBase) -> *const ::std::os::raw::c_char,
    pub display_text: extern "C" fn(self_c: *const RUBase) -> *const ::std::os::raw::c_char,
    pub placeholder_text: extern "C" fn(self_c: *const RUBase) -> *const ::std::os::raw::c_char,
    pub set_placeholder_text:
        extern "C" fn(self_c: *const RUBase, arg0: *const ::std::os::raw::c_char),
    pub max_length: extern "C" fn(self_c: *const RUBase) -> i32,
    pub set_max_length: extern "C" fn(self_c: *const RUBase, arg0: i32),
    pub set_frame: extern "C" fn(self_c: *const RUBase, arg0: bool),
    pub has_frame: extern "C" fn(self_c: *const RUBase) -> bool,
    pub set_clear_button_enabled: extern "C" fn(self_c: *const RUBase, enable: bool),
    pub is_clear_button_enabled: extern "C" fn(self_c: *const RUBase) -> bool,
    pub echo_mode: extern "C" fn(self_c: *const RUBase) -> u32,
    pub set_echo_mode: extern "C" fn(self_c: *const RUBase, arg0: u32),
    pub is_read_only: extern "C" fn(self_c: *const RUBase) -> bool,
    pub set_read_only: extern "C" fn(self_c: *const RUBase, arg0: bool),
    pub cursor_position: extern "C" fn(self_c: *const RUBase) -> i32,
    pub set_cursor_position: extern "C" fn(self_c: *const RUBase, arg0: i32),
    pub cursor_position_at: extern "C" fn(self_c: *const RUBase, pos: *const RUBase) -> i32,
    pub set_alignment: extern "C" fn(self_c: *const RUBase, flag: u32),
    pub alignment: extern "C" fn(self_c: *const RUBase) -> u32,
    pub cursor_forward: extern "C" fn(self_c: *const RUBase, mark: bool, steps: i32),
    pub cursor_backward: extern "C" fn(self_c: *const RUBase, mark: bool, steps: i32),
    pub cursor_word_forward: extern "C" fn(self_c: *const RUBase, mark: bool),
    pub cursor_word_backward: extern "C" fn(self_c: *const RUBase, mark: bool),
    pub backspace: extern "C" fn(self_c: *const RUBase),
    pub del: extern "C" fn(self_c: *const RUBase),
    pub home: extern "C" fn(self_c: *const RUBase, mark: bool),
    pub end: extern "C" fn(self_c: *const RUBase, mark: bool),
    pub is_modified: extern "C" fn(self_c: *const RUBase) -> bool,
    pub set_modified: extern "C" fn(self_c: *const RUBase, arg0: bool),
    pub set_selection: extern "C" fn(self_c: *const RUBase, arg0: i32, arg1: i32),
    pub has_selected_text: extern "C" fn(self_c: *const RUBase) -> bool,
    pub selected_text: extern "C" fn(self_c: *const RUBase) -> *const ::std::os::raw::c_char,
    pub selection_start: extern "C" fn(self_c: *const RUBase) -> i32,
    pub selection_end: extern "C" fn(self_c: *const RUBase) -> i32,
    pub selection_length: extern "C" fn(self_c: *const RUBase) -> i32,
    pub is_undo_available: extern "C" fn(self_c: *const RUBase) -> bool,
    pub is_redo_available: extern "C" fn(self_c: *const RUBase) -> bool,
    pub set_drag_enabled: extern "C" fn(self_c: *const RUBase, b: bool),
    pub drag_enabled: extern "C" fn(self_c: *const RUBase) -> bool,
    pub set_cursor_move_style: extern "C" fn(self_c: *const RUBase, style: u32),
    pub cursor_move_style: extern "C" fn(self_c: *const RUBase) -> u32,
    pub input_mask: extern "C" fn(self_c: *const RUBase) -> *const ::std::os::raw::c_char,
    pub set_input_mask:
        extern "C" fn(self_c: *const RUBase, input_mask: *const ::std::os::raw::c_char),
    pub has_acceptable_input: extern "C" fn(self_c: *const RUBase) -> bool,
    pub set_text_margins:
        extern "C" fn(self_c: *const RUBase, left: i32, top: i32, right: i32, bottom: i32),
    pub set_text_margins_2: extern "C" fn(self_c: *const RUBase, margins: *const RUBase),
    pub text_margins: extern "C" fn(self_c: *const RUBase) -> RUMargins,
    pub set_text: extern "C" fn(self_c: *const RUBase, arg0: *const ::std::os::raw::c_char),
    pub clear: extern "C" fn(self_c: *const RUBase),
    pub select_all: extern "C" fn(self_c: *const RUBase),
    pub undo: extern "C" fn(self_c: *const RUBase),
    pub redo: extern "C" fn(self_c: *const RUBase),
    pub cut: extern "C" fn(self_c: *const RUBase),
    pub copy: extern "C" fn(self_c: *const RUBase),
    pub paste: extern "C" fn(self_c: *const RUBase),
    pub deselect: extern "C" fn(self_c: *const RUBase),
    pub insert: extern "C" fn(self_c: *const RUBase, arg0: *const ::std::os::raw::c_char),
    pub set_text_changed_event: extern "C" fn(
        object: *const RUBase,
        user_data: *const c_void,
        trampoline_func: *const c_void,
        callback: *const c_void,
    ),

    pub set_text_edited_event: extern "C" fn(
        object: *const RUBase,
        user_data: *const c_void,
        trampoline_func: *const c_void,
        callback: *const c_void,
    ),

    pub set_cursor_position_changed_event: extern "C" fn(
        object: *const RUBase,
        user_data: *const c_void,
        trampoline_func: *const c_void,
        callback: *const c_void,
    ),

    pub set_return_pressed_event: extern "C" fn(
        object: *const RUBase,
        user_data: *const c_void,
        trampoline_func: *const c_void,
        callback: *const c_void,
    ),

    pub set_editing_finished_event: extern "C" fn(
        object: *const RUBase,
        user_data: *const c_void,
        trampoline_func: *const c_void,
        callback: *const c_void,
    ),

    pub set_selection_changed_event: extern "C" fn(
        object: *const RUBase,
        user_data: *const c_void,
        trampoline_func: *const c_void,
        callback: *const c_void,
    ),

    pub set_mouse_press_event: extern "C" fn(
        object: *const RUBase,
        user_data: *const c_void,
        trampoline_func: *const c_void,
        callback: *const c_void,
    ),

    pub remove_mouse_press_event: extern "C" fn(object: *const RUBase),

    pub set_mouse_move_event: extern "C" fn(
        object: *const RUBase,
        user_data: *const c_void,
        trampoline_func: *const c_void,
        callback: *const c_void,
    ),

    pub remove_mouse_move_event: extern "C" fn(object: *const RUBase),

    pub set_mouse_release_event: extern "C" fn(
        object: *const RUBase,
        user_data: *const c_void,
        trampoline_func: *const c_void,
        callback: *const c_void,
    ),

    pub remove_mouse_release_event: extern "C" fn(object: *const RUBase),

    pub set_mouse_double_click_event: extern "C" fn(
        object: *const RUBase,
        user_data: *const c_void,
        trampoline_func: *const c_void,
        callback: *const c_void,
    ),

    pub remove_mouse_double_click_event: extern "C" fn(object: *const RUBase),

    pub set_key_press_event: extern "C" fn(
        object: *const RUBase,
        user_data: *const c_void,
        trampoline_func: *const c_void,
        callback: *const c_void,
    ),

    pub remove_key_press_event: extern "C" fn(object: *const RUBase),

    pub set_focus_in_event: extern "C" fn(
        object: *const RUBase,
        user_data: *const c_void,
        trampoline_func: *const c_void,
        callback: *const c_void,
    ),

    pub remove_focus_in_event: extern "C" fn(object: *const RUBase),

    pub set_focus_out_event: extern "C" fn(
        object: *const RUBase,
        user_data: *const c_void,
        trampoline_func: *const c_void,
        callback: *const c_void,
    ),

    pub remove_focus_out_event: extern "C" fn(object: *const RUBase),

    pub set_paint_event: extern "C" fn(
        object: *const RUBase,
        user_data: *const c_void,
        trampoline_func: *const c_void,
        callback: *const c_void,
    ),

    pub remove_paint_event: extern "C" fn(object: *const RUBase),

    pub set_drag_enter_event: extern "C" fn(
        object: *const RUBase,
        user_data: *const c_void,
        trampoline_func: *const c_void,
        callback: *const c_void,
    ),

    pub remove_drag_enter_event: extern "C" fn(object: *const RUBase),

    pub set_drag_move_event: extern "C" fn(
        object: *const RUBase,
        user_data: *const c_void,
        trampoline_func: *const c_void,
        callback: *const c_void,
    ),

    pub remove_drag_move_event: extern "C" fn(object: *const RUBase),

    pub set_drag_leave_event: extern "C" fn(
        object: *const RUBase,
        user_data: *const c_void,
        trampoline_func: *const c_void,
        callback: *const c_void,
    ),

    pub remove_drag_leave_event: extern "C" fn(object: *const RUBase),

    pub set_drop_event: extern "C" fn(
        object: *const RUBase,
        user_data: *const c_void,
        trampoline_func: *const c_void,
        callback: *const c_void,
    ),

    pub remove_drop_event: extern "C" fn(object: *const RUBase),

    pub set_change_event: extern "C" fn(
        object: *const RUBase,
        user_data: *const c_void,
        trampoline_func: *const c_void,
        callback: *const c_void,
    ),

    pub remove_change_event: extern "C" fn(object: *const RUBase),

    pub set_context_menu_event: extern "C" fn(
        object: *const RUBase,
        user_data: *const c_void,
        trampoline_func: *const c_void,
        callback: *const c_void,
    ),

    pub remove_context_menu_event: extern "C" fn(object: *const RUBase),
}

#[repr(C)]
#[derive(Copy, Clone)]
pub struct RULineEditAllFuncs {
    pub object_funcs: *const RUObjectFuncs,
    pub paint_device_funcs: *const RUPaintDeviceFuncs,
    pub widget_funcs: *const RUWidgetFuncs,
    pub line_edit_funcs: *const RULineEditFuncs,
}

#[repr(C)]
#[derive(Copy, Clone)]
pub struct RULineEdit {
    pub qt_data: *const RUBase,
    pub host_data: *const RUBase,
    pub all_funcs: *const RULineEditAllFuncs,
}