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
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
#[allow(unused_imports)]
use auto::application_ffi::*;
#[allow(unused_imports)]
use auto::backing_store_ffi::*;
#[allow(unused_imports)]
use auto::bitmap_ffi::*;
#[allow(unused_imports)]
use auto::brush_ffi::*;
#[allow(unused_imports)]
use auto::close_event_ffi::*;
#[allow(unused_imports)]
use auto::color_ffi::*;
#[allow(unused_imports)]
use auto::context_menu_event_ffi::*;
#[allow(unused_imports)]
use auto::cursor_ffi::*;
#[allow(unused_imports)]
use auto::drag_enter_event_ffi::*;
#[allow(unused_imports)]
use auto::drag_leave_event_ffi::*;
#[allow(unused_imports)]
use auto::drag_move_event_ffi::*;
#[allow(unused_imports)]
use auto::drop_event_ffi::*;
#[allow(unused_imports)]
use auto::event_ffi::*;
#[allow(unused_imports)]
use auto::expose_event_ffi::*;
#[allow(unused_imports)]
use auto::focus_event_ffi::*;
#[allow(unused_imports)]
use auto::font_ffi::*;
#[allow(unused_imports)]
use auto::font_info_ffi::*;
#[allow(unused_imports)]
use auto::gradient_ffi::*;
#[allow(unused_imports)]
use auto::hide_event_ffi::*;
#[allow(unused_imports)]
use auto::icon_ffi::*;
#[allow(unused_imports)]
use auto::image_ffi::*;
#[allow(unused_imports)]
use auto::input_event_ffi::*;
#[allow(unused_imports)]
use auto::key_event_ffi::*;
#[allow(unused_imports)]
use auto::key_sequence_ffi::*;
#[allow(unused_imports)]
use auto::layout_ffi::*;
#[allow(unused_imports)]
use auto::layout_item_ffi::*;
#[allow(unused_imports)]
use auto::line_f_ffi::*;
#[allow(unused_imports)]
use auto::line_ffi::*;
#[allow(unused_imports)]
use auto::list_widget_ffi::*;
#[allow(unused_imports)]
use auto::list_widget_item_ffi::*;
#[allow(unused_imports)]
use auto::margins_ffi::*;
#[allow(unused_imports)]
use auto::matrix_ffi::*;
#[allow(unused_imports)]
use auto::mime_data_ffi::*;
#[allow(unused_imports)]
use auto::mouse_event_ffi::*;
#[allow(unused_imports)]
use auto::move_event_ffi::*;
#[allow(unused_imports)]
use auto::object_ffi::*;
#[allow(unused_imports)]
use auto::paint_device_ffi::*;
#[allow(unused_imports)]
use auto::paint_engine_ffi::*;
#[allow(unused_imports)]
use auto::paint_engine_state_ffi::*;
#[allow(unused_imports)]
use auto::paint_event_ffi::*;
#[allow(unused_imports)]
use auto::painter_ffi::*;
#[allow(unused_imports)]
use auto::palette_ffi::*;
#[allow(unused_imports)]
use auto::pen_ffi::*;
#[allow(unused_imports)]
use auto::pixel_format_ffi::*;
#[allow(unused_imports)]
use auto::pixmap_ffi::*;
#[allow(unused_imports)]
use auto::point_f_ffi::*;
#[allow(unused_imports)]
use auto::point_ffi::*;
#[allow(unused_imports)]
use auto::polygon_f_ffi::*;
#[allow(unused_imports)]
use auto::polygon_ffi::*;
#[allow(unused_imports)]
use auto::push_button_ffi::*;
#[allow(unused_imports)]
use auto::rect_f_ffi::*;
#[allow(unused_imports)]
use auto::rect_ffi::*;
#[allow(unused_imports)]
use auto::region_ffi::*;
#[allow(unused_imports)]
use auto::resize_event_ffi::*;
#[allow(unused_imports)]
use auto::screen_ffi::*;
#[allow(unused_imports)]
use auto::show_event_ffi::*;
#[allow(unused_imports)]
use auto::size_f_ffi::*;
#[allow(unused_imports)]
use auto::size_ffi::*;
#[allow(unused_imports)]
use auto::size_policy_ffi::*;
#[allow(unused_imports)]
use auto::spacer_item_ffi::*;
#[allow(unused_imports)]
use auto::style_ffi::*;
#[allow(unused_imports)]
use auto::surface_ffi::*;
#[allow(unused_imports)]
use auto::surface_format_ffi::*;
#[allow(unused_imports)]
use auto::tablet_event_ffi::*;
#[allow(unused_imports)]
use auto::touch_event_ffi::*;
#[allow(unused_imports)]
use auto::transform_ffi::*;
#[allow(unused_imports)]
use auto::wheel_event_ffi::*;
#[allow(unused_imports)]
use auto::widget_ffi::*;
#[allow(unused_imports)]
use auto::window_ffi::*;
use rute_ffi_base::*;
use std::os::raw::c_void;

#[repr(C)]
#[derive(Copy, Clone)]
pub struct RuteFFI {
    pub create_application: extern "C" fn(priv_data: *const RUBase) -> RUApplication,
    pub get_application: extern "C" fn(priv_data: *const RUBase) -> RUApplication,
    pub create_bitmap: extern "C" fn(priv_data: *const RUBase) -> RUBitmap,
    pub get_bitmap: extern "C" fn(priv_data: *const RUBase) -> RUBitmap,
    pub create_brush: extern "C" fn(
        priv_data: *const RUBase,
        callback: unsafe extern "C" fn(),
        host_data: *const c_void,
    ) -> RUBrush,
    pub create_color: extern "C" fn(
        priv_data: *const RUBase,
        callback: unsafe extern "C" fn(),
        host_data: *const c_void,
    ) -> RUColor,
    pub get_color: extern "C" fn(priv_data: *const RUBase) -> RUColor,
    pub create_cursor: extern "C" fn(
        priv_data: *const RUBase,
        callback: unsafe extern "C" fn(),
        host_data: *const c_void,
    ) -> RUCursor,
    pub get_cursor: extern "C" fn(priv_data: *const RUBase) -> RUCursor,
    pub create_font: extern "C" fn(
        priv_data: *const RUBase,
        callback: unsafe extern "C" fn(),
        host_data: *const c_void,
    ) -> RUFont,
    pub get_font: extern "C" fn(priv_data: *const RUBase) -> RUFont,
    pub create_gradient: extern "C" fn(
        priv_data: *const RUBase,
        callback: unsafe extern "C" fn(),
        host_data: *const c_void,
    ) -> RUGradient,
    pub create_icon: extern "C" fn(
        priv_data: *const RUBase,
        callback: unsafe extern "C" fn(),
        host_data: *const c_void,
    ) -> RUIcon,
    pub get_icon: extern "C" fn(priv_data: *const RUBase) -> RUIcon,
    pub create_image: extern "C" fn(
        priv_data: *const RUBase,
        callback: unsafe extern "C" fn(),
        host_data: *const c_void,
    ) -> RUImage,
    pub get_image: extern "C" fn(priv_data: *const RUBase) -> RUImage,
    pub create_key_sequence: extern "C" fn(
        priv_data: *const RUBase,
        callback: unsafe extern "C" fn(),
        host_data: *const c_void,
    ) -> RUKeySequence,
    pub get_key_sequence: extern "C" fn(priv_data: *const RUBase) -> RUKeySequence,
    pub create_line: extern "C" fn(
        priv_data: *const RUBase,
        callback: unsafe extern "C" fn(),
        host_data: *const c_void,
    ) -> RULine,
    pub create_line_f: extern "C" fn(
        priv_data: *const RUBase,
        callback: unsafe extern "C" fn(),
        host_data: *const c_void,
    ) -> RULineF,
    pub get_line_f: extern "C" fn(priv_data: *const RUBase) -> RULineF,
    pub create_list_widget: extern "C" fn(
        priv_data: *const RUBase,
        callback: unsafe extern "C" fn(),
        host_data: *const c_void,
    ) -> RUListWidget,
    pub create_list_widget_item: extern "C" fn(
        priv_data: *const RUBase,
        callback: unsafe extern "C" fn(),
        host_data: *const c_void,
    ) -> RUListWidgetItem,
    pub create_margins: extern "C" fn(
        priv_data: *const RUBase,
        callback: unsafe extern "C" fn(),
        host_data: *const c_void,
    ) -> RUMargins,
    pub create_matrix: extern "C" fn(
        priv_data: *const RUBase,
        callback: unsafe extern "C" fn(),
        host_data: *const c_void,
    ) -> RUMatrix,
    pub create_mime_data: extern "C" fn(priv_data: *const RUBase) -> RUMimeData,
    pub create_object: extern "C" fn(
        priv_data: *const RUBase,
        callback: unsafe extern "C" fn(),
        host_data: *const c_void,
    ) -> RUObject,
    pub create_paint_engine_state: extern "C" fn(
        priv_data: *const RUBase,
        callback: unsafe extern "C" fn(),
        host_data: *const c_void,
    ) -> RUPaintEngineState,
    pub create_painter: extern "C" fn(
        priv_data: *const RUBase,
        callback: unsafe extern "C" fn(),
        host_data: *const c_void,
    ) -> RUPainter,
    pub get_painter: extern "C" fn(priv_data: *const RUBase) -> RUPainter,
    pub create_palette: extern "C" fn(
        priv_data: *const RUBase,
        callback: unsafe extern "C" fn(),
        host_data: *const c_void,
    ) -> RUPalette,
    pub create_pen: extern "C" fn(
        priv_data: *const RUBase,
        callback: unsafe extern "C" fn(),
        host_data: *const c_void,
    ) -> RUPen,
    pub create_pixel_format: extern "C" fn(
        priv_data: *const RUBase,
        callback: unsafe extern "C" fn(),
        host_data: *const c_void,
    ) -> RUPixelFormat,
    pub create_pixmap: extern "C" fn(
        priv_data: *const RUBase,
        callback: unsafe extern "C" fn(),
        host_data: *const c_void,
    ) -> RUPixmap,
    pub get_pixmap: extern "C" fn(priv_data: *const RUBase) -> RUPixmap,
    pub create_point: extern "C" fn(
        priv_data: *const RUBase,
        callback: unsafe extern "C" fn(),
        host_data: *const c_void,
    ) -> RUPoint,
    pub get_point: extern "C" fn(priv_data: *const RUBase) -> RUPoint,
    pub create_point_f: extern "C" fn(
        priv_data: *const RUBase,
        callback: unsafe extern "C" fn(),
        host_data: *const c_void,
    ) -> RUPointF,
    pub get_point_f: extern "C" fn(priv_data: *const RUBase) -> RUPointF,
    pub create_polygon: extern "C" fn(
        priv_data: *const RUBase,
        callback: unsafe extern "C" fn(),
        host_data: *const c_void,
    ) -> RUPolygon,
    pub create_polygon_f: extern "C" fn(
        priv_data: *const RUBase,
        callback: unsafe extern "C" fn(),
        host_data: *const c_void,
    ) -> RUPolygonF,
    pub create_push_button: extern "C" fn(
        priv_data: *const RUBase,
        callback: unsafe extern "C" fn(),
        host_data: *const c_void,
    ) -> RUPushButton,
    pub create_rect: extern "C" fn(
        priv_data: *const RUBase,
        callback: unsafe extern "C" fn(),
        host_data: *const c_void,
    ) -> RURect,
    pub create_rect_f: extern "C" fn(
        priv_data: *const RUBase,
        callback: unsafe extern "C" fn(),
        host_data: *const c_void,
    ) -> RURectF,
    pub create_region: extern "C" fn(
        priv_data: *const RUBase,
        callback: unsafe extern "C" fn(),
        host_data: *const c_void,
    ) -> RURegion,
    pub create_size: extern "C" fn(
        priv_data: *const RUBase,
        callback: unsafe extern "C" fn(),
        host_data: *const c_void,
    ) -> RUSize,
    pub create_size_f: extern "C" fn(
        priv_data: *const RUBase,
        callback: unsafe extern "C" fn(),
        host_data: *const c_void,
    ) -> RUSizeF,
    pub create_size_policy: extern "C" fn(
        priv_data: *const RUBase,
        callback: unsafe extern "C" fn(),
        host_data: *const c_void,
    ) -> RUSizePolicy,
    pub create_surface_format: extern "C" fn(
        priv_data: *const RUBase,
        callback: unsafe extern "C" fn(),
        host_data: *const c_void,
    ) -> RUSurfaceFormat,
    pub get_surface_format: extern "C" fn(priv_data: *const RUBase) -> RUSurfaceFormat,
    pub create_transform: extern "C" fn(
        priv_data: *const RUBase,
        callback: unsafe extern "C" fn(),
        host_data: *const c_void,
    ) -> RUTransform,
    pub get_transform: extern "C" fn(priv_data: *const RUBase) -> RUTransform,
    pub create_widget: extern "C" fn(
        priv_data: *const RUBase,
        callback: unsafe extern "C" fn(),
        host_data: *const c_void,
    ) -> RUWidget,
    pub get_widget: extern "C" fn(priv_data: *const RUBase) -> RUWidget,
    pub create_window: extern "C" fn(
        priv_data: *const RUBase,
        callback: unsafe extern "C" fn(),
        host_data: *const c_void,
    ) -> RUWindow,
    pub get_window: extern "C" fn(priv_data: *const RUBase) -> RUWindow,
}

extern "C" {
    pub fn rute_static_ffi_get() -> *const RuteFFI;
}