raylib-bindings 0.0.3 → 0.0.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/ChangeLog +153 -145
- data/LICENSE.txt +0 -0
- data/README.md +82 -82
- data/lib/libraylib.dll +0 -0
- data/lib/libraylib.dylib +0 -0
- data/lib/physac.dll +0 -0
- data/lib/physac.dylib +0 -0
- data/lib/physac.rb +178 -178
- data/lib/raygui.dll +0 -0
- data/lib/raygui.dylib +0 -0
- data/lib/raygui.rb +305 -305
- data/lib/raylib.rb +154 -154
- data/lib/raylib_main.rb +2157 -2154
- data/lib/raymath.rb +342 -342
- data/lib/rlgl.rb +648 -648
- metadata +2 -4
- data/lib/libraylib.4.0.0.dylib +0 -0
- data/lib/libraylib.400.dylib +0 -1
- data/lib/libraylib.dylib +0 -1
data/lib/raygui.rb
CHANGED
@@ -1,305 +1,305 @@
|
|
1
|
-
# Yet another raylib wrapper for Ruby
|
2
|
-
#
|
3
|
-
# * https://github.com/vaiorabbit/raylib-bindings
|
4
|
-
#
|
5
|
-
# [NOTICE] This is an automatically generated file.
|
6
|
-
|
7
|
-
require 'ffi'
|
8
|
-
|
9
|
-
module Raylib
|
10
|
-
extend FFI::Library
|
11
|
-
# Define/Macro
|
12
|
-
|
13
|
-
RAYGUI_VERSION = "3.0"
|
14
|
-
|
15
|
-
# Enum
|
16
|
-
|
17
|
-
GUI_STATE_NORMAL = 0
|
18
|
-
GUI_STATE_FOCUSED = 1
|
19
|
-
GUI_STATE_PRESSED = 2
|
20
|
-
GUI_STATE_DISABLED = 3
|
21
|
-
GUI_TEXT_ALIGN_LEFT = 0
|
22
|
-
GUI_TEXT_ALIGN_CENTER = 1
|
23
|
-
GUI_TEXT_ALIGN_RIGHT = 2
|
24
|
-
DEFAULT = 0
|
25
|
-
LABEL = 1
|
26
|
-
BUTTON = 2
|
27
|
-
TOGGLE = 3
|
28
|
-
SLIDER = 4
|
29
|
-
PROGRESSBAR = 5
|
30
|
-
CHECKBOX = 6
|
31
|
-
COMBOBOX = 7
|
32
|
-
DROPDOWNBOX = 8
|
33
|
-
TEXTBOX = 9
|
34
|
-
VALUEBOX = 10
|
35
|
-
SPINNER = 11
|
36
|
-
LISTVIEW = 12
|
37
|
-
COLORPICKER = 13
|
38
|
-
SCROLLBAR = 14
|
39
|
-
STATUSBAR = 15
|
40
|
-
BORDER_COLOR_NORMAL = 0
|
41
|
-
BASE_COLOR_NORMAL = 1
|
42
|
-
TEXT_COLOR_NORMAL = 2
|
43
|
-
BORDER_COLOR_FOCUSED = 3
|
44
|
-
BASE_COLOR_FOCUSED = 4
|
45
|
-
TEXT_COLOR_FOCUSED = 5
|
46
|
-
BORDER_COLOR_PRESSED = 6
|
47
|
-
BASE_COLOR_PRESSED = 7
|
48
|
-
TEXT_COLOR_PRESSED = 8
|
49
|
-
BORDER_COLOR_DISABLED = 9
|
50
|
-
BASE_COLOR_DISABLED = 10
|
51
|
-
TEXT_COLOR_DISABLED = 11
|
52
|
-
BORDER_WIDTH = 12
|
53
|
-
TEXT_PADDING = 13
|
54
|
-
TEXT_ALIGNMENT = 14
|
55
|
-
RESERVED = 15
|
56
|
-
TEXT_SIZE = 16
|
57
|
-
TEXT_SPACING = 17
|
58
|
-
LINE_COLOR = 18
|
59
|
-
BACKGROUND_COLOR = 19
|
60
|
-
GROUP_PADDING = 16
|
61
|
-
SLIDER_WIDTH = 16
|
62
|
-
SLIDER_PADDING = 17
|
63
|
-
PROGRESS_PADDING = 16
|
64
|
-
CHECK_PADDING = 16
|
65
|
-
COMBO_BUTTON_WIDTH = 16
|
66
|
-
COMBO_BUTTON_PADDING = 17
|
67
|
-
ARROW_PADDING = 16
|
68
|
-
DROPDOWN_ITEMS_PADDING = 17
|
69
|
-
TEXT_INNER_PADDING = 16
|
70
|
-
TEXT_LINES_PADDING = 17
|
71
|
-
COLOR_SELECTED_FG = 18
|
72
|
-
COLOR_SELECTED_BG = 19
|
73
|
-
SPIN_BUTTON_WIDTH = 16
|
74
|
-
SPIN_BUTTON_PADDING = 17
|
75
|
-
ARROWS_SIZE = 16
|
76
|
-
ARROWS_VISIBLE = 17
|
77
|
-
SCROLL_SLIDER_PADDING = 18
|
78
|
-
SCROLL_SLIDER_SIZE = 19
|
79
|
-
SCROLL_PADDING = 20
|
80
|
-
SCROLL_SPEED = 21
|
81
|
-
SCROLLBAR_LEFT_SIDE = 0
|
82
|
-
SCROLLBAR_RIGHT_SIDE = 1
|
83
|
-
LIST_ITEMS_HEIGHT = 16
|
84
|
-
LIST_ITEMS_PADDING = 17
|
85
|
-
SCROLLBAR_WIDTH = 18
|
86
|
-
SCROLLBAR_SIDE = 19
|
87
|
-
COLOR_SELECTOR_SIZE = 16
|
88
|
-
HUEBAR_WIDTH = 17
|
89
|
-
HUEBAR_PADDING = 18
|
90
|
-
HUEBAR_SELECTOR_HEIGHT = 19
|
91
|
-
HUEBAR_SELECTOR_OVERFLOW = 20
|
92
|
-
|
93
|
-
# Typedef
|
94
|
-
|
95
|
-
typedef :int, :GuiControlState
|
96
|
-
typedef :int, :GuiTextAlignment
|
97
|
-
typedef :int, :GuiControl
|
98
|
-
typedef :int, :GuiControlProperty
|
99
|
-
typedef :int, :GuiDefaultProperty
|
100
|
-
typedef :int, :GuiToggleProperty
|
101
|
-
typedef :int, :GuiSliderProperty
|
102
|
-
typedef :int, :GuiProgressBarProperty
|
103
|
-
typedef :int, :GuiCheckBoxProperty
|
104
|
-
typedef :int, :GuiComboBoxProperty
|
105
|
-
typedef :int, :GuiDropdownBoxProperty
|
106
|
-
typedef :int, :GuiTextBoxProperty
|
107
|
-
typedef :int, :GuiSpinnerProperty
|
108
|
-
typedef :int, :GuiScrollBarProperty
|
109
|
-
typedef :int, :GuiScrollBarSide
|
110
|
-
typedef :int, :GuiListViewProperty
|
111
|
-
typedef :int, :GuiColorPickerProperty
|
112
|
-
|
113
|
-
# Struct
|
114
|
-
|
115
|
-
class GuiStyleProp < FFI::Struct
|
116
|
-
layout(
|
117
|
-
:controlId, :ushort,
|
118
|
-
:propertyId, :ushort,
|
119
|
-
:propertyValue, :int,
|
120
|
-
)
|
121
|
-
end
|
122
|
-
|
123
|
-
|
124
|
-
# Function
|
125
|
-
|
126
|
-
def self.setup_raygui_symbols()
|
127
|
-
symbols = [
|
128
|
-
:GuiEnable,
|
129
|
-
:GuiDisable,
|
130
|
-
:GuiLock,
|
131
|
-
:GuiUnlock,
|
132
|
-
:GuiIsLocked,
|
133
|
-
:GuiFade,
|
134
|
-
:GuiSetState,
|
135
|
-
:GuiGetState,
|
136
|
-
:GuiSetFont,
|
137
|
-
:GuiGetFont,
|
138
|
-
:GuiSetStyle,
|
139
|
-
:GuiGetStyle,
|
140
|
-
:GuiWindowBox,
|
141
|
-
:GuiGroupBox,
|
142
|
-
:GuiLine,
|
143
|
-
:GuiPanel,
|
144
|
-
:GuiScrollPanel,
|
145
|
-
:GuiLabel,
|
146
|
-
:GuiButton,
|
147
|
-
:GuiLabelButton,
|
148
|
-
:GuiToggle,
|
149
|
-
:GuiToggleGroup,
|
150
|
-
:GuiCheckBox,
|
151
|
-
:GuiComboBox,
|
152
|
-
:GuiDropdownBox,
|
153
|
-
:GuiSpinner,
|
154
|
-
:GuiValueBox,
|
155
|
-
:GuiTextBox,
|
156
|
-
:GuiTextBoxMulti,
|
157
|
-
:GuiSlider,
|
158
|
-
:GuiSliderBar,
|
159
|
-
:GuiProgressBar,
|
160
|
-
:GuiStatusBar,
|
161
|
-
:GuiDummyRec,
|
162
|
-
:GuiScrollBar,
|
163
|
-
:GuiGrid,
|
164
|
-
:GuiListView,
|
165
|
-
:GuiListViewEx,
|
166
|
-
:GuiMessageBox,
|
167
|
-
:GuiTextInputBox,
|
168
|
-
:GuiColorPicker,
|
169
|
-
:GuiColorPanel,
|
170
|
-
:GuiColorBarAlpha,
|
171
|
-
:GuiColorBarHue,
|
172
|
-
:GuiLoadStyle,
|
173
|
-
:GuiLoadStyleDefault,
|
174
|
-
:GuiIconText,
|
175
|
-
:GuiDrawIcon,
|
176
|
-
:GuiGetIcons,
|
177
|
-
:GuiGetIconData,
|
178
|
-
:GuiSetIconData,
|
179
|
-
:GuiSetIconPixel,
|
180
|
-
:GuiClearIconPixel,
|
181
|
-
:GuiCheckIconPixel,
|
182
|
-
]
|
183
|
-
args = {
|
184
|
-
:GuiEnable => [],
|
185
|
-
:GuiDisable => [],
|
186
|
-
:GuiLock => [],
|
187
|
-
:GuiUnlock => [],
|
188
|
-
:GuiIsLocked => [],
|
189
|
-
:GuiFade => [:float],
|
190
|
-
:GuiSetState => [:int],
|
191
|
-
:GuiGetState => [],
|
192
|
-
:GuiSetFont => [Font.by_value],
|
193
|
-
:GuiGetFont => [],
|
194
|
-
:GuiSetStyle => [:int, :int, :int],
|
195
|
-
:GuiGetStyle => [:int, :int],
|
196
|
-
:GuiWindowBox => [Rectangle.by_value, :pointer],
|
197
|
-
:GuiGroupBox => [Rectangle.by_value, :pointer],
|
198
|
-
:GuiLine => [Rectangle.by_value, :pointer],
|
199
|
-
:GuiPanel => [Rectangle.by_value],
|
200
|
-
:GuiScrollPanel => [Rectangle.by_value, Rectangle.by_value, :pointer],
|
201
|
-
:GuiLabel => [Rectangle.by_value, :pointer],
|
202
|
-
:GuiButton => [Rectangle.by_value, :pointer],
|
203
|
-
:GuiLabelButton => [Rectangle.by_value, :pointer],
|
204
|
-
:GuiToggle => [Rectangle.by_value, :pointer, :bool],
|
205
|
-
:GuiToggleGroup => [Rectangle.by_value, :pointer, :int],
|
206
|
-
:GuiCheckBox => [Rectangle.by_value, :pointer, :bool],
|
207
|
-
:GuiComboBox => [Rectangle.by_value, :pointer, :int],
|
208
|
-
:GuiDropdownBox => [Rectangle.by_value, :pointer, :pointer, :bool],
|
209
|
-
:GuiSpinner => [Rectangle.by_value, :pointer, :pointer, :int, :int, :bool],
|
210
|
-
:GuiValueBox => [Rectangle.by_value, :pointer, :pointer, :int, :int, :bool],
|
211
|
-
:GuiTextBox => [Rectangle.by_value, :pointer, :int, :bool],
|
212
|
-
:GuiTextBoxMulti => [Rectangle.by_value, :pointer, :int, :bool],
|
213
|
-
:GuiSlider => [Rectangle.by_value, :pointer, :pointer, :float, :float, :float],
|
214
|
-
:GuiSliderBar => [Rectangle.by_value, :pointer, :pointer, :float, :float, :float],
|
215
|
-
:GuiProgressBar => [Rectangle.by_value, :pointer, :pointer, :float, :float, :float],
|
216
|
-
:GuiStatusBar => [Rectangle.by_value, :pointer],
|
217
|
-
:GuiDummyRec => [Rectangle.by_value, :pointer],
|
218
|
-
:GuiScrollBar => [Rectangle.by_value, :int, :int, :int],
|
219
|
-
:GuiGrid => [Rectangle.by_value, :float, :int],
|
220
|
-
:GuiListView => [Rectangle.by_value, :pointer, :pointer, :int],
|
221
|
-
:GuiListViewEx => [Rectangle.by_value, :pointer, :int, :pointer, :pointer, :int],
|
222
|
-
:GuiMessageBox => [Rectangle.by_value, :pointer, :pointer, :pointer],
|
223
|
-
:GuiTextInputBox => [Rectangle.by_value, :pointer, :pointer, :pointer, :pointer],
|
224
|
-
:GuiColorPicker => [Rectangle.by_value, Color.by_value],
|
225
|
-
:GuiColorPanel => [Rectangle.by_value, Color.by_value],
|
226
|
-
:GuiColorBarAlpha => [Rectangle.by_value, :float],
|
227
|
-
:GuiColorBarHue => [Rectangle.by_value, :float],
|
228
|
-
:GuiLoadStyle => [:pointer],
|
229
|
-
:GuiLoadStyleDefault => [],
|
230
|
-
:GuiIconText => [:int, :pointer],
|
231
|
-
:GuiDrawIcon => [:int, :int, :int, :int, Color.by_value],
|
232
|
-
:GuiGetIcons => [],
|
233
|
-
:GuiGetIconData => [:int],
|
234
|
-
:GuiSetIconData => [:int, :pointer],
|
235
|
-
:GuiSetIconPixel => [:int, :int, :int],
|
236
|
-
:GuiClearIconPixel => [:int, :int, :int],
|
237
|
-
:GuiCheckIconPixel => [:int, :int, :int],
|
238
|
-
}
|
239
|
-
retvals = {
|
240
|
-
:GuiEnable => :void,
|
241
|
-
:GuiDisable => :void,
|
242
|
-
:GuiLock => :void,
|
243
|
-
:GuiUnlock => :void,
|
244
|
-
:GuiIsLocked => :bool,
|
245
|
-
:GuiFade => :void,
|
246
|
-
:GuiSetState => :void,
|
247
|
-
:GuiGetState => :int,
|
248
|
-
:GuiSetFont => :void,
|
249
|
-
:GuiGetFont => Font.by_value,
|
250
|
-
:GuiSetStyle => :void,
|
251
|
-
:GuiGetStyle => :int,
|
252
|
-
:GuiWindowBox => :bool,
|
253
|
-
:GuiGroupBox => :void,
|
254
|
-
:GuiLine => :void,
|
255
|
-
:GuiPanel => :void,
|
256
|
-
:GuiScrollPanel => Rectangle.by_value,
|
257
|
-
:GuiLabel => :void,
|
258
|
-
:GuiButton => :bool,
|
259
|
-
:GuiLabelButton => :bool,
|
260
|
-
:GuiToggle => :bool,
|
261
|
-
:GuiToggleGroup => :int,
|
262
|
-
:GuiCheckBox => :bool,
|
263
|
-
:GuiComboBox => :int,
|
264
|
-
:GuiDropdownBox => :bool,
|
265
|
-
:GuiSpinner => :bool,
|
266
|
-
:GuiValueBox => :bool,
|
267
|
-
:GuiTextBox => :bool,
|
268
|
-
:GuiTextBoxMulti => :bool,
|
269
|
-
:GuiSlider => :float,
|
270
|
-
:GuiSliderBar => :float,
|
271
|
-
:GuiProgressBar => :float,
|
272
|
-
:GuiStatusBar => :void,
|
273
|
-
:GuiDummyRec => :void,
|
274
|
-
:GuiScrollBar => :int,
|
275
|
-
:GuiGrid => Vector2.by_value,
|
276
|
-
:GuiListView => :int,
|
277
|
-
:GuiListViewEx => :int,
|
278
|
-
:GuiMessageBox => :int,
|
279
|
-
:GuiTextInputBox => :int,
|
280
|
-
:GuiColorPicker => Color.by_value,
|
281
|
-
:GuiColorPanel => Color.by_value,
|
282
|
-
:GuiColorBarAlpha => :float,
|
283
|
-
:GuiColorBarHue => :float,
|
284
|
-
:GuiLoadStyle => :void,
|
285
|
-
:GuiLoadStyleDefault => :void,
|
286
|
-
:GuiIconText => :pointer,
|
287
|
-
:GuiDrawIcon => :void,
|
288
|
-
:GuiGetIcons => :pointer,
|
289
|
-
:GuiGetIconData => :pointer,
|
290
|
-
:GuiSetIconData => :void,
|
291
|
-
:GuiSetIconPixel => :void,
|
292
|
-
:GuiClearIconPixel => :void,
|
293
|
-
:GuiCheckIconPixel => :bool,
|
294
|
-
}
|
295
|
-
symbols.each do |sym|
|
296
|
-
begin
|
297
|
-
attach_function sym, args[sym], retvals[sym]
|
298
|
-
rescue FFI::NotFoundError => error
|
299
|
-
$stderr.puts("[Warning] Failed to import #{sym} (#{error}).")
|
300
|
-
end
|
301
|
-
end
|
302
|
-
end
|
303
|
-
|
304
|
-
end
|
305
|
-
|
1
|
+
# Yet another raylib wrapper for Ruby
|
2
|
+
#
|
3
|
+
# * https://github.com/vaiorabbit/raylib-bindings
|
4
|
+
#
|
5
|
+
# [NOTICE] This is an automatically generated file.
|
6
|
+
|
7
|
+
require 'ffi'
|
8
|
+
|
9
|
+
module Raylib
|
10
|
+
extend FFI::Library
|
11
|
+
# Define/Macro
|
12
|
+
|
13
|
+
RAYGUI_VERSION = "3.0"
|
14
|
+
|
15
|
+
# Enum
|
16
|
+
|
17
|
+
GUI_STATE_NORMAL = 0
|
18
|
+
GUI_STATE_FOCUSED = 1
|
19
|
+
GUI_STATE_PRESSED = 2
|
20
|
+
GUI_STATE_DISABLED = 3
|
21
|
+
GUI_TEXT_ALIGN_LEFT = 0
|
22
|
+
GUI_TEXT_ALIGN_CENTER = 1
|
23
|
+
GUI_TEXT_ALIGN_RIGHT = 2
|
24
|
+
DEFAULT = 0
|
25
|
+
LABEL = 1
|
26
|
+
BUTTON = 2
|
27
|
+
TOGGLE = 3
|
28
|
+
SLIDER = 4
|
29
|
+
PROGRESSBAR = 5
|
30
|
+
CHECKBOX = 6
|
31
|
+
COMBOBOX = 7
|
32
|
+
DROPDOWNBOX = 8
|
33
|
+
TEXTBOX = 9
|
34
|
+
VALUEBOX = 10
|
35
|
+
SPINNER = 11
|
36
|
+
LISTVIEW = 12
|
37
|
+
COLORPICKER = 13
|
38
|
+
SCROLLBAR = 14
|
39
|
+
STATUSBAR = 15
|
40
|
+
BORDER_COLOR_NORMAL = 0
|
41
|
+
BASE_COLOR_NORMAL = 1
|
42
|
+
TEXT_COLOR_NORMAL = 2
|
43
|
+
BORDER_COLOR_FOCUSED = 3
|
44
|
+
BASE_COLOR_FOCUSED = 4
|
45
|
+
TEXT_COLOR_FOCUSED = 5
|
46
|
+
BORDER_COLOR_PRESSED = 6
|
47
|
+
BASE_COLOR_PRESSED = 7
|
48
|
+
TEXT_COLOR_PRESSED = 8
|
49
|
+
BORDER_COLOR_DISABLED = 9
|
50
|
+
BASE_COLOR_DISABLED = 10
|
51
|
+
TEXT_COLOR_DISABLED = 11
|
52
|
+
BORDER_WIDTH = 12
|
53
|
+
TEXT_PADDING = 13
|
54
|
+
TEXT_ALIGNMENT = 14
|
55
|
+
RESERVED = 15
|
56
|
+
TEXT_SIZE = 16
|
57
|
+
TEXT_SPACING = 17
|
58
|
+
LINE_COLOR = 18
|
59
|
+
BACKGROUND_COLOR = 19
|
60
|
+
GROUP_PADDING = 16
|
61
|
+
SLIDER_WIDTH = 16
|
62
|
+
SLIDER_PADDING = 17
|
63
|
+
PROGRESS_PADDING = 16
|
64
|
+
CHECK_PADDING = 16
|
65
|
+
COMBO_BUTTON_WIDTH = 16
|
66
|
+
COMBO_BUTTON_PADDING = 17
|
67
|
+
ARROW_PADDING = 16
|
68
|
+
DROPDOWN_ITEMS_PADDING = 17
|
69
|
+
TEXT_INNER_PADDING = 16
|
70
|
+
TEXT_LINES_PADDING = 17
|
71
|
+
COLOR_SELECTED_FG = 18
|
72
|
+
COLOR_SELECTED_BG = 19
|
73
|
+
SPIN_BUTTON_WIDTH = 16
|
74
|
+
SPIN_BUTTON_PADDING = 17
|
75
|
+
ARROWS_SIZE = 16
|
76
|
+
ARROWS_VISIBLE = 17
|
77
|
+
SCROLL_SLIDER_PADDING = 18
|
78
|
+
SCROLL_SLIDER_SIZE = 19
|
79
|
+
SCROLL_PADDING = 20
|
80
|
+
SCROLL_SPEED = 21
|
81
|
+
SCROLLBAR_LEFT_SIDE = 0
|
82
|
+
SCROLLBAR_RIGHT_SIDE = 1
|
83
|
+
LIST_ITEMS_HEIGHT = 16
|
84
|
+
LIST_ITEMS_PADDING = 17
|
85
|
+
SCROLLBAR_WIDTH = 18
|
86
|
+
SCROLLBAR_SIDE = 19
|
87
|
+
COLOR_SELECTOR_SIZE = 16
|
88
|
+
HUEBAR_WIDTH = 17
|
89
|
+
HUEBAR_PADDING = 18
|
90
|
+
HUEBAR_SELECTOR_HEIGHT = 19
|
91
|
+
HUEBAR_SELECTOR_OVERFLOW = 20
|
92
|
+
|
93
|
+
# Typedef
|
94
|
+
|
95
|
+
typedef :int, :GuiControlState
|
96
|
+
typedef :int, :GuiTextAlignment
|
97
|
+
typedef :int, :GuiControl
|
98
|
+
typedef :int, :GuiControlProperty
|
99
|
+
typedef :int, :GuiDefaultProperty
|
100
|
+
typedef :int, :GuiToggleProperty
|
101
|
+
typedef :int, :GuiSliderProperty
|
102
|
+
typedef :int, :GuiProgressBarProperty
|
103
|
+
typedef :int, :GuiCheckBoxProperty
|
104
|
+
typedef :int, :GuiComboBoxProperty
|
105
|
+
typedef :int, :GuiDropdownBoxProperty
|
106
|
+
typedef :int, :GuiTextBoxProperty
|
107
|
+
typedef :int, :GuiSpinnerProperty
|
108
|
+
typedef :int, :GuiScrollBarProperty
|
109
|
+
typedef :int, :GuiScrollBarSide
|
110
|
+
typedef :int, :GuiListViewProperty
|
111
|
+
typedef :int, :GuiColorPickerProperty
|
112
|
+
|
113
|
+
# Struct
|
114
|
+
|
115
|
+
class GuiStyleProp < FFI::Struct
|
116
|
+
layout(
|
117
|
+
:controlId, :ushort,
|
118
|
+
:propertyId, :ushort,
|
119
|
+
:propertyValue, :int,
|
120
|
+
)
|
121
|
+
end
|
122
|
+
|
123
|
+
|
124
|
+
# Function
|
125
|
+
|
126
|
+
def self.setup_raygui_symbols()
|
127
|
+
symbols = [
|
128
|
+
:GuiEnable,
|
129
|
+
:GuiDisable,
|
130
|
+
:GuiLock,
|
131
|
+
:GuiUnlock,
|
132
|
+
:GuiIsLocked,
|
133
|
+
:GuiFade,
|
134
|
+
:GuiSetState,
|
135
|
+
:GuiGetState,
|
136
|
+
:GuiSetFont,
|
137
|
+
:GuiGetFont,
|
138
|
+
:GuiSetStyle,
|
139
|
+
:GuiGetStyle,
|
140
|
+
:GuiWindowBox,
|
141
|
+
:GuiGroupBox,
|
142
|
+
:GuiLine,
|
143
|
+
:GuiPanel,
|
144
|
+
:GuiScrollPanel,
|
145
|
+
:GuiLabel,
|
146
|
+
:GuiButton,
|
147
|
+
:GuiLabelButton,
|
148
|
+
:GuiToggle,
|
149
|
+
:GuiToggleGroup,
|
150
|
+
:GuiCheckBox,
|
151
|
+
:GuiComboBox,
|
152
|
+
:GuiDropdownBox,
|
153
|
+
:GuiSpinner,
|
154
|
+
:GuiValueBox,
|
155
|
+
:GuiTextBox,
|
156
|
+
:GuiTextBoxMulti,
|
157
|
+
:GuiSlider,
|
158
|
+
:GuiSliderBar,
|
159
|
+
:GuiProgressBar,
|
160
|
+
:GuiStatusBar,
|
161
|
+
:GuiDummyRec,
|
162
|
+
:GuiScrollBar,
|
163
|
+
:GuiGrid,
|
164
|
+
:GuiListView,
|
165
|
+
:GuiListViewEx,
|
166
|
+
:GuiMessageBox,
|
167
|
+
:GuiTextInputBox,
|
168
|
+
:GuiColorPicker,
|
169
|
+
:GuiColorPanel,
|
170
|
+
:GuiColorBarAlpha,
|
171
|
+
:GuiColorBarHue,
|
172
|
+
:GuiLoadStyle,
|
173
|
+
:GuiLoadStyleDefault,
|
174
|
+
:GuiIconText,
|
175
|
+
:GuiDrawIcon,
|
176
|
+
:GuiGetIcons,
|
177
|
+
:GuiGetIconData,
|
178
|
+
:GuiSetIconData,
|
179
|
+
:GuiSetIconPixel,
|
180
|
+
:GuiClearIconPixel,
|
181
|
+
:GuiCheckIconPixel,
|
182
|
+
]
|
183
|
+
args = {
|
184
|
+
:GuiEnable => [],
|
185
|
+
:GuiDisable => [],
|
186
|
+
:GuiLock => [],
|
187
|
+
:GuiUnlock => [],
|
188
|
+
:GuiIsLocked => [],
|
189
|
+
:GuiFade => [:float],
|
190
|
+
:GuiSetState => [:int],
|
191
|
+
:GuiGetState => [],
|
192
|
+
:GuiSetFont => [Font.by_value],
|
193
|
+
:GuiGetFont => [],
|
194
|
+
:GuiSetStyle => [:int, :int, :int],
|
195
|
+
:GuiGetStyle => [:int, :int],
|
196
|
+
:GuiWindowBox => [Rectangle.by_value, :pointer],
|
197
|
+
:GuiGroupBox => [Rectangle.by_value, :pointer],
|
198
|
+
:GuiLine => [Rectangle.by_value, :pointer],
|
199
|
+
:GuiPanel => [Rectangle.by_value, :pointer],
|
200
|
+
:GuiScrollPanel => [Rectangle.by_value, :pointer, Rectangle.by_value, :pointer],
|
201
|
+
:GuiLabel => [Rectangle.by_value, :pointer],
|
202
|
+
:GuiButton => [Rectangle.by_value, :pointer],
|
203
|
+
:GuiLabelButton => [Rectangle.by_value, :pointer],
|
204
|
+
:GuiToggle => [Rectangle.by_value, :pointer, :bool],
|
205
|
+
:GuiToggleGroup => [Rectangle.by_value, :pointer, :int],
|
206
|
+
:GuiCheckBox => [Rectangle.by_value, :pointer, :bool],
|
207
|
+
:GuiComboBox => [Rectangle.by_value, :pointer, :int],
|
208
|
+
:GuiDropdownBox => [Rectangle.by_value, :pointer, :pointer, :bool],
|
209
|
+
:GuiSpinner => [Rectangle.by_value, :pointer, :pointer, :int, :int, :bool],
|
210
|
+
:GuiValueBox => [Rectangle.by_value, :pointer, :pointer, :int, :int, :bool],
|
211
|
+
:GuiTextBox => [Rectangle.by_value, :pointer, :int, :bool],
|
212
|
+
:GuiTextBoxMulti => [Rectangle.by_value, :pointer, :int, :bool],
|
213
|
+
:GuiSlider => [Rectangle.by_value, :pointer, :pointer, :float, :float, :float],
|
214
|
+
:GuiSliderBar => [Rectangle.by_value, :pointer, :pointer, :float, :float, :float],
|
215
|
+
:GuiProgressBar => [Rectangle.by_value, :pointer, :pointer, :float, :float, :float],
|
216
|
+
:GuiStatusBar => [Rectangle.by_value, :pointer],
|
217
|
+
:GuiDummyRec => [Rectangle.by_value, :pointer],
|
218
|
+
:GuiScrollBar => [Rectangle.by_value, :int, :int, :int],
|
219
|
+
:GuiGrid => [Rectangle.by_value, :float, :int],
|
220
|
+
:GuiListView => [Rectangle.by_value, :pointer, :pointer, :int],
|
221
|
+
:GuiListViewEx => [Rectangle.by_value, :pointer, :int, :pointer, :pointer, :int],
|
222
|
+
:GuiMessageBox => [Rectangle.by_value, :pointer, :pointer, :pointer],
|
223
|
+
:GuiTextInputBox => [Rectangle.by_value, :pointer, :pointer, :pointer, :pointer],
|
224
|
+
:GuiColorPicker => [Rectangle.by_value, :pointer, Color.by_value],
|
225
|
+
:GuiColorPanel => [Rectangle.by_value, :pointer, Color.by_value],
|
226
|
+
:GuiColorBarAlpha => [Rectangle.by_value, :pointer, :float],
|
227
|
+
:GuiColorBarHue => [Rectangle.by_value, :pointer, :float],
|
228
|
+
:GuiLoadStyle => [:pointer],
|
229
|
+
:GuiLoadStyleDefault => [],
|
230
|
+
:GuiIconText => [:int, :pointer],
|
231
|
+
:GuiDrawIcon => [:int, :int, :int, :int, Color.by_value],
|
232
|
+
:GuiGetIcons => [],
|
233
|
+
:GuiGetIconData => [:int],
|
234
|
+
:GuiSetIconData => [:int, :pointer],
|
235
|
+
:GuiSetIconPixel => [:int, :int, :int],
|
236
|
+
:GuiClearIconPixel => [:int, :int, :int],
|
237
|
+
:GuiCheckIconPixel => [:int, :int, :int],
|
238
|
+
}
|
239
|
+
retvals = {
|
240
|
+
:GuiEnable => :void,
|
241
|
+
:GuiDisable => :void,
|
242
|
+
:GuiLock => :void,
|
243
|
+
:GuiUnlock => :void,
|
244
|
+
:GuiIsLocked => :bool,
|
245
|
+
:GuiFade => :void,
|
246
|
+
:GuiSetState => :void,
|
247
|
+
:GuiGetState => :int,
|
248
|
+
:GuiSetFont => :void,
|
249
|
+
:GuiGetFont => Font.by_value,
|
250
|
+
:GuiSetStyle => :void,
|
251
|
+
:GuiGetStyle => :int,
|
252
|
+
:GuiWindowBox => :bool,
|
253
|
+
:GuiGroupBox => :void,
|
254
|
+
:GuiLine => :void,
|
255
|
+
:GuiPanel => :void,
|
256
|
+
:GuiScrollPanel => Rectangle.by_value,
|
257
|
+
:GuiLabel => :void,
|
258
|
+
:GuiButton => :bool,
|
259
|
+
:GuiLabelButton => :bool,
|
260
|
+
:GuiToggle => :bool,
|
261
|
+
:GuiToggleGroup => :int,
|
262
|
+
:GuiCheckBox => :bool,
|
263
|
+
:GuiComboBox => :int,
|
264
|
+
:GuiDropdownBox => :bool,
|
265
|
+
:GuiSpinner => :bool,
|
266
|
+
:GuiValueBox => :bool,
|
267
|
+
:GuiTextBox => :bool,
|
268
|
+
:GuiTextBoxMulti => :bool,
|
269
|
+
:GuiSlider => :float,
|
270
|
+
:GuiSliderBar => :float,
|
271
|
+
:GuiProgressBar => :float,
|
272
|
+
:GuiStatusBar => :void,
|
273
|
+
:GuiDummyRec => :void,
|
274
|
+
:GuiScrollBar => :int,
|
275
|
+
:GuiGrid => Vector2.by_value,
|
276
|
+
:GuiListView => :int,
|
277
|
+
:GuiListViewEx => :int,
|
278
|
+
:GuiMessageBox => :int,
|
279
|
+
:GuiTextInputBox => :int,
|
280
|
+
:GuiColorPicker => Color.by_value,
|
281
|
+
:GuiColorPanel => Color.by_value,
|
282
|
+
:GuiColorBarAlpha => :float,
|
283
|
+
:GuiColorBarHue => :float,
|
284
|
+
:GuiLoadStyle => :void,
|
285
|
+
:GuiLoadStyleDefault => :void,
|
286
|
+
:GuiIconText => :pointer,
|
287
|
+
:GuiDrawIcon => :void,
|
288
|
+
:GuiGetIcons => :pointer,
|
289
|
+
:GuiGetIconData => :pointer,
|
290
|
+
:GuiSetIconData => :void,
|
291
|
+
:GuiSetIconPixel => :void,
|
292
|
+
:GuiClearIconPixel => :void,
|
293
|
+
:GuiCheckIconPixel => :bool,
|
294
|
+
}
|
295
|
+
symbols.each do |sym|
|
296
|
+
begin
|
297
|
+
attach_function sym, args[sym], retvals[sym]
|
298
|
+
rescue FFI::NotFoundError => error
|
299
|
+
$stderr.puts("[Warning] Failed to import #{sym} (#{error}).")
|
300
|
+
end
|
301
|
+
end
|
302
|
+
end
|
303
|
+
|
304
|
+
end
|
305
|
+
|