Repository navigation
Expand file tree
/
Copy pathimgui.v
More file actions
17898 lines (14149 loc) · 468 KB
/
Copy pathimgui.v
File metadata and controls
17898 lines (14149 loc) · 468 KB
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
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
module imgui
/*
Generated ImGui/ImPlot API bindings; native context and resource lifetimes follow upstream.
Regenerate with ./generate.vsh; this preface is emitted by cleanup_imgui_implot.vsh.
Do not edit generated declarations by hand.
cleanup_imgui_implot.vsh non-regression notes
Keep this block current when changing cleanup rules. Do not hardcode one
function, enum member, or struct member; derive facts from cimgui/cimgui.h or
cimplot/cimplot.h, then apply generic V cleanup.
Covered cases and examples:
1. Strip raw C/preprocessor leakage:
Callback typedef parsing is line-based so it never recreates:
broken callback alias with u64 payload
2. Const parameter names come from header prototypes:
CIMGUI_API bool igButton(const char* label,const ImVec2_c size);
This yields const_label/const_size generically.
3. Missing aliases/opaque declarations are inferred from type positions and
header typedefs only, not arbitrary capitalized field names.
4. Value backing structs such as ImVec2_c/ImVec4_c/ImColor_c/ImRect_c back public
aliases ImVec2/ImVec4/ImColor/ImRect. Do not emit duplicate empty C structs.
Vector fields remain lowercase x/y/z/w for V literals.
5. Remove self-module prefixes: imgui.v must not refer to Type; implot.v
must not refer to implot.Type, because each file is already inside that module.
6. STB rectpack names are intentionally preserved from C when c2v title-cases
lower-case C identifiers in aliases like:
example: `pub type Stbrp_node_im = Stbrp_node`
Normalize those references to C.stbrp_node/C.stbrp_context_opaque and emit
their C-backed declarations with the identifiers used by the headers.
7. Enum aliases are handled dynamically, never by member-name lists. V enums
reject duplicate integer values, while C/C++ enums often define aliases:
any_popup = 1 << 10 | 1 << 11
mouse_button_shift_ = 1 << 1
mouse_button_mask_ = 1 << 2 | 1 << 3
another_alias = 12
The cleanup evaluates safe integer enum expressions as it emits each enum;
if a value was already emitted earlier in the same enum, the later member
is commented out. This prevents regressions such as `enum value 12 already
exists` without hardcoding a specific enum or member name.
*/
/*
MIT License
Copyright (c) 2025-2026 Anton Oreskin
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
*/
pub const version = '1.92.9b'
pub const version_num = 19291
pub type BindingFixedArray1 = [63]ImVec4_c
pub type BindingFixedArray2 = [5]bool
pub type BindingFixedArray3 = [155]KeyData
pub type BindingFixedArray4 = [5]ImVec2_c
pub type BindingFixedArray5 = [5]f64
pub type BindingFixedArray6 = [5]ImU16
pub type BindingFixedArray7 = [5]f32
pub type BindingFixedArray8 = [33]i8
pub type BindingFixedArray9 = [40]i8
pub type BindingFixedArray10 = [33]ImVec4_c
pub type BindingFixedArray11 = [1]ImU8
pub type BindingFixedArray12 = [48]ImVec2_c
pub type BindingFixedArray13 = [64]ImU8
pub type BindingFixedArray14 = [8]ImU8
pub type BindingFixedArray15 = [4]ImU16
pub type BindingFixedArray16 = [5]ImU32
pub type BindingFixedArray17 = [155]KeyRoutingIndex
pub type BindingFixedArray18 = [64]i8
pub type BindingFixedArray19 = [2]ImRect_c
pub type BindingFixedArray20 = [9]ImU32
pub type BindingFixedArray21 = [2]f32
pub type BindingFixedArray22 = [6]DebugAllocEntry
pub type BindingFixedArray23 = [16]i8
pub type BindingFixedArray24 = [155]KeyOwnerData
pub type BindingFixedArray25 = [16]u8
pub type BindingFixedArray26 = [60]f32
pub type BindingFixedArray27 = [2]ID
pub type BindingFixedArray28 = [2]ImVec2_c
pub type BindingFixedArray29 = [2]ImU32
pub type BindingFixedArray30 = [80]i8
pub type BindingFixedArray31 = [99]StbUndoRecord
pub type BindingFixedArray32 = [999]i8
pub type ImWchar = u32
pub type InputTextCallback = fn (mut InputTextCallbackData) i32
pub type SizeCallback = fn (&SizeCallbackData)
@[typedef]
pub type Va_list = C.va_list
@[typedef]
pub struct C.va_list {}
// External C type declarations (from headers)
pub type ImVec2_c = C.ImVec2_c
@[typedef]
pub struct C.ImVec2_c {
pub mut:
x f32
y f32
}
// docking branch
pub type ImColor = C.ImColor_c
pub type ImRect = C.ImRect_c
pub type ImTextureRef = C.ImTextureRef_c
pub type ImVec2 = C.ImVec2_c
pub type ImVec2i = C.ImVec2i_c
pub type ImVec4 = C.ImVec4_c
pub type TextFilter = C.ImGuiTextFilter
@[typedef]
pub struct C.ImGuiTextFilter {}
pub type DockRequest = C.ImGuiDockRequest
@[typedef]
pub struct C.ImGuiDockRequest {}
pub type DockNodeSettings = C.ImGuiDockNodeSettings
@[typedef]
pub struct C.ImGuiDockNodeSettings {}
pub type InputTextDeactivateData = C.ImGuiInputTextDeactivateData
@[typedef]
pub struct C.ImGuiInputTextDeactivateData {}
pub type TableColumnsSettings = C.ImGuiTableColumnsSettings
@[typedef]
pub struct C.ImGuiTableColumnsSettings {}
pub type Stbrp_node = C.stbrp_node
@[typedef]
pub struct C.stbrp_node {}
pub type ImVector_const_charPtr = C.ImVector_const_charPtr
@[typedef]
pub struct C.ImVector_const_charPtr {
pub mut:
Size i32
Capacity i32
Data &&u8
}
pub type ID = u32
pub type ImS8 = i8
pub type ImU8 = u8
pub type ImS16 = i16
pub type ImU16 = u16
pub type ImS32 = i32
pub type ImU32 = u32
pub type ImS64 = i64
pub type ImU64 = u64
pub type Col = i32
pub type Cond = i32
pub type DataType = i32
pub type MouseButton = i32
pub type MouseCursor = i32
pub type StyleVar = i32
pub type TableBgTarget = i32
pub type ImDrawFlags = i32
pub type ImDrawListFlags = i32
pub type ImDrawTextFlags = i32
pub type ImFontFlags = i32
pub type ImFontAtlasFlags = i32
pub type BackendFlags = i32
pub type ButtonFlags = i32
pub type ChildFlags = i32
pub type ColorEditFlags = i32
pub type ConfigFlags = i32
pub type ComboFlags = i32
pub type DockNodeFlags = i32
pub type DragDropFlags = i32
pub type FocusedFlags = i32
pub type HoveredFlags = i32
pub type InputFlags = i32
pub type InputTextFlags = i32
pub type ItemFlags = i32
pub type KeyChord = i32
pub type ListClipperFlags = i32
pub type PopupFlags = i32
pub type MultiSelectFlags = i32
pub type SelectableFlags = i32
pub type SliderFlags = i32
pub type TabBarFlags = i32
pub type TabItemFlags = i32
pub type TableFlags = i32
pub type TableColumnFlags = i32
pub type TableRowFlags = i32
pub type TreeNodeFlags = i32
pub type ViewportFlags = i32
pub type WindowFlags = i32
pub type ImWchar32 = u32
pub type ImWchar16 = u16
pub type SelectionUserData = i64
pub type MemAllocFunc = fn (usize, voidptr) voidptr
pub type MemFreeFunc = fn (voidptr, voidptr)
pub type ImVec4_c = C.ImVec4_c
@[typedef]
pub struct C.ImVec4_c {
pub mut:
x f32
y f32
z f32
w f32
}
pub type ImTextureID = u64
pub type ImTextureRef_c = C.ImTextureRef_c
@[typedef]
pub struct C.ImTextureRef_c {
pub mut:
_TexData &ImTextureData
_TexID ImTextureID
}
pub enum WindowFlags_ {
none = 0
no_title_bar = 1 << 0
no_resize = 1 << 1
no_move = 1 << 2
no_scrollbar = 1 << 3
no_scroll_with_mouse = 1 << 4
no_collapse = 1 << 5
always_auto_resize = 1 << 6
no_background = 1 << 7
no_saved_settings = 1 << 8
no_mouse_inputs = 1 << 9
menu_bar = 1 << 10
horizontal_scrollbar = 1 << 11
no_focus_on_appearing = 1 << 12
no_bring_to_front_on_focus = 1 << 13
always_vertical_scrollbar = 1 << 14
always_horizontal_scrollbar = 1 << 15
no_nav_inputs = 1 << 16
no_nav_focus = 1 << 17
unsaved_document = 1 << 18
no_docking = 1 << 19
no_nav = 1 << 16 | 1 << 17
no_decoration = 1 << 0 | 1 << 1 | 1 << 3 | 1 << 5
no_inputs = 1 << 9 | 1 << 16 | 1 << 17
dock_node_host = 1 << 23
child_window = 1 << 24
tooltip = 1 << 25
popup = 1 << 26
modal = 1 << 27
child_menu = 1 << 28
}
pub enum ChildFlags_ {
none = 0
borders = 1 << 0
always_use_window_padding = 1 << 1
resize_x = 1 << 2
resize_y = 1 << 3
auto_resize_x = 1 << 4
auto_resize_y = 1 << 5
always_auto_resize = 1 << 6
frame_style = 1 << 7
nav_flattened = 1 << 8
}
pub enum ItemFlags_ {
none = 0
no_tab_stop = 1 << 0
no_nav = 1 << 1
no_nav_default_focus = 1 << 2
button_repeat = 1 << 3
auto_close_popups = 1 << 4
allow_duplicate_id = 1 << 5
disabled = 1 << 6
live_edit_on_input_text = 1 << 7
live_edit_on_input_scalar = 1 << 8
live_edit_on_input = 1 << 7 | 1 << 8
}
pub enum InputTextFlags_ {
none = 0
chars_decimal = 1 << 0
chars_hexadecimal = 1 << 1
chars_scientific = 1 << 2
chars_uppercase = 1 << 3
chars_no_blank = 1 << 4
allow_tab_input = 1 << 5
enter_returns_true = 1 << 6
escape_clears_all = 1 << 7
ctrl_enter_for_new_line = 1 << 8
read_only = 1 << 9
password = 1 << 10
always_overwrite = 1 << 11
auto_select_all = 1 << 12
parse_empty_ref_val = 1 << 13
display_empty_ref_val = 1 << 14
no_horizontal_scroll = 1 << 15
no_undo_redo = 1 << 16
elide_left = 1 << 17
callback_completion = 1 << 18
callback_history = 1 << 19
callback_always = 1 << 20
callback_char_filter = 1 << 21
callback_resize = 1 << 22
callback_edit = 1 << 23
word_wrap = 1 << 24
}
pub enum TreeNodeFlags_ {
none = 0
selected = 1 << 0
framed = 1 << 1
allow_overlap = 1 << 2
no_tree_push_on_open = 1 << 3
no_auto_open_on_log = 1 << 4
default_open = 1 << 5
open_on_double_click = 1 << 6
open_on_arrow = 1 << 7
leaf = 1 << 8
bullet = 1 << 9
frame_padding = 1 << 10
span_avail_width = 1 << 11
span_full_width = 1 << 12
span_label_width = 1 << 13
span_all_columns = 1 << 14
label_span_all_columns = 1 << 15
nav_left_jumps_to_parent = 1 << 17
collapsing_header = 1 << 1 | 1 << 3 | 1 << 4
draw_lines_none = 1 << 18
draw_lines_full = 1 << 19
draw_lines_to_nodes = 1 << 20
}
pub enum PopupFlags_ {
none = 0
mouse_button_left = 1 << 2
mouse_button_right = 1 << 3
mouse_button_middle = 1 << 2 | 1 << 3
no_reopen = 1 << 5
no_open_over_existing_popup = 1 << 7
no_open_over_items = 1 << 8
any_popup_id = 1 << 10
any_popup_level = 1 << 11
any_popup = 1 << 10 | 1 << 11
mouse_button_shift_ = 1 << 1
invalid_mask_ = 1 << 0 | 1 << 1
}
pub enum SelectableFlags_ {
none = 0
no_auto_close_popups = 1 << 0
span_all_columns = 1 << 1
allow_double_click = 1 << 2
disabled = 1 << 3
allow_overlap = 1 << 4
highlight = 1 << 5
select_on_nav = 1 << 6
}
pub enum ComboFlags_ {
none = 0
popup_align_left = 1 << 0
height_small = 1 << 1
height_regular = 1 << 2
height_large = 1 << 3
height_largest = 1 << 4
no_arrow_button = 1 << 5
no_preview = 1 << 6
width_fit_preview = 1 << 7
height_mask_ = 1 << 1 | 1 << 2 | 1 << 3 | 1 << 4
}
pub enum TabBarFlags_ {
none = 0
reorderable = 1 << 0
auto_select_new_tabs = 1 << 1
tab_list_popup_button = 1 << 2
no_close_with_middle_mouse_button = 1 << 3
no_tab_list_scrolling_buttons = 1 << 4
no_tooltip = 1 << 5
draw_selected_overline = 1 << 6
fitting_policy_mixed = 1 << 7
fitting_policy_shrink = 1 << 8
fitting_policy_scroll = 1 << 9
fitting_policy_mask_ = 1 << 7 | 1 << 8 | 1 << 9
}
pub enum TabItemFlags_ {
none = 0
unsaved_document = 1 << 0
set_selected = 1 << 1
no_close_with_middle_mouse_button = 1 << 2
no_push_id = 1 << 3
no_tooltip = 1 << 4
no_reorder = 1 << 5
leading = 1 << 6
trailing = 1 << 7
no_assumed_closure = 1 << 8
}
pub enum FocusedFlags_ {
none = 0
child_windows = 1 << 0
root_window = 1 << 1
any_window = 1 << 2
no_popup_hierarchy = 1 << 3
dock_hierarchy = 1 << 4
root_and_child_windows = 1 << 0 | 1 << 1
}
pub enum HoveredFlags_ {
none = 0
child_windows = 1 << 0
root_window = 1 << 1
any_window = 1 << 2
no_popup_hierarchy = 1 << 3
dock_hierarchy = 1 << 4
allow_when_blocked_by_popup = 1 << 5
allow_when_blocked_by_active_item = 1 << 7
allow_when_overlapped_by_item = 1 << 8
allow_when_overlapped_by_window = 1 << 9
allow_when_disabled = 1 << 10
no_nav_override = 1 << 11
allow_when_overlapped = 1 << 8 | 1 << 9
rect_only = 1 << 5 | 1 << 7 | 1 << 8 | 1 << 9
root_and_child_windows = 1 << 0 | 1 << 1
for_tooltip = 1 << 12
stationary = 1 << 13
delay_none = 1 << 14
delay_short = 1 << 15
delay_normal = 1 << 16
no_shared_delay = 1 << 17
}
pub enum DockNodeFlags_ {
none = 0
keep_alive_only = 1 << 0
no_docking_over_central_node = 1 << 2
passthru_central_node = 1 << 3
no_docking_split = 1 << 4
no_resize = 1 << 5
auto_hide_tab_bar = 1 << 6
no_undocking = 1 << 7
}
pub enum DragDropFlags_ {
none = 0
source_no_preview_tooltip = 1 << 0
source_no_disable_hover = 1 << 1
source_no_hold_to_open_others = 1 << 2
source_allow_null_id = 1 << 3
source_extern = 1 << 4
payload_auto_expire = 1 << 5
payload_no_cross_context = 1 << 6
payload_no_cross_process = 1 << 7
accept_before_delivery = 1 << 10
accept_no_draw_default_rect = 1 << 11
accept_no_preview_tooltip = 1 << 12
accept_draw_as_hovered = 1 << 13
accept_peek_only = 1 << 10 | 1 << 11
}
pub enum DataType_ {
s8
u8
s16
u16
s32
u32
s64
u64
float
double
bool
string
count
}
pub enum Dir {
none = -1
left = 0
right = 1
up = 2
down = 3
count = 4
}
pub enum SortDirection {
none = 0
ascending = 1
descending = 2
}
pub enum Key {
none = 0
named_key_begin = 512
left_arrow = 513
right_arrow = 514
up_arrow = 515
down_arrow = 516
page_up = 517
page_down = 518
home = 519
end = 520
insert = 521
delete = 522
backspace = 523
space = 524
enter = 525
escape = 526
left_ctrl = 527
left_shift = 528
left_alt = 529
left_super = 530
right_ctrl = 531
right_shift = 532
right_alt = 533
right_super = 534
menu = 535
_0 = 536
_1 = 537
_2 = 538
_3 = 539
_4 = 540
_5 = 541
_6 = 542
_7 = 543
_8 = 544
_9 = 545
a = 546
b = 547
c = 548
d = 549
e = 550
f = 551
g = 552
h = 553
i = 554
j = 555
k = 556
l = 557
m = 558
n = 559
o = 560
p = 561
q = 562
r = 563
s = 564
t = 565
u = 566
v = 567
w = 568
x = 569
y = 570
z = 571
f1 = 572
f2 = 573
f3 = 574
f4 = 575
f5 = 576
f6 = 577
f7 = 578
f8 = 579
f9 = 580
f10 = 581
f11 = 582
f12 = 583
f13 = 584
f14 = 585
f15 = 586
f16 = 587
f17 = 588
f18 = 589
f19 = 590
f20 = 591
f21 = 592
f22 = 593
f23 = 594
f24 = 595
apostrophe = 596
comma = 597
minus = 598
period = 599
slash = 600
semicolon = 601
equal = 602
left_bracket = 603
backslash = 604
right_bracket = 605
grave_accent = 606
caps_lock = 607
scroll_lock = 608
num_lock = 609
print_screen = 610
pause = 611
keypad0 = 612
keypad1 = 613
keypad2 = 614
keypad3 = 615
keypad4 = 616
keypad5 = 617
keypad6 = 618
keypad7 = 619
keypad8 = 620
keypad9 = 621
keypad_decimal = 622
keypad_divide = 623
keypad_multiply = 624
keypad_subtract = 625
keypad_add = 626
keypad_enter = 627
keypad_equal = 628
app_back = 629
app_forward = 630
oem102 = 631
gamepad_start = 632
gamepad_back = 633
gamepad_face_left = 634
gamepad_face_right = 635
gamepad_face_up = 636
gamepad_face_down = 637
gamepad_dpad_left = 638
gamepad_dpad_right = 639
gamepad_dpad_up = 640
gamepad_dpad_down = 641
gamepad_l1 = 642
gamepad_r1 = 643
gamepad_l2 = 644
gamepad_r2 = 645
gamepad_l3 = 646
gamepad_r3 = 647
gamepad_ls_tick_left = 648
gamepad_ls_tick_right = 649
gamepad_ls_tick_up = 650
gamepad_ls_tick_down = 651
gamepad_rs_tick_left = 652
gamepad_rs_tick_right = 653
gamepad_rs_tick_up = 654
gamepad_rs_tick_down = 655
mouse_left = 656
mouse_right = 657
mouse_middle = 658
mouse_x1 = 659
mouse_x2 = 660
mouse_wheel_x = 661
mouse_wheel_y = 662
reserved_for_mod_ctrl = 663
reserved_for_mod_shift = 664
reserved_for_mod_alt = 665
reserved_for_mod_super = 666
named_key_end = 667
named_key_count = 155
mod_ctrl = 4096
mod_shift = 8192
mod_alt = 16384
mod_super = 32768
mod_mask_ = 61440
}
pub enum InputFlags_ {
none = 0
repeat = 1 << 0
route_active = 1 << 10
route_focused = 1 << 11
route_global = 1 << 12
route_always = 1 << 13
route_over_focused = 1 << 14
route_over_active = 1 << 15
route_unless_bg_focused = 1 << 16
route_from_root_window = 1 << 17
tooltip = 1 << 18
}
pub enum ConfigFlags_ {
none = 0
nav_enable_keyboard = 1 << 0
nav_enable_gamepad = 1 << 1
no_mouse = 1 << 4
no_mouse_cursor_change = 1 << 5
no_keyboard = 1 << 6
docking_enable = 1 << 7
viewports_enable = 1 << 10
is_srgb = 1 << 20
is_touch_screen = 1 << 21
}
pub enum BackendFlags_ {
none = 0
has_gamepad = 1 << 0
has_mouse_cursors = 1 << 1
has_set_mouse_pos = 1 << 2
renderer_has_vtx_offset = 1 << 3
renderer_has_textures = 1 << 4
renderer_has_viewports = 1 << 10
platform_has_viewports = 1 << 11
has_mouse_hovered_viewport = 1 << 12
has_parent_viewport = 1 << 13
}
pub enum Col_ {
text
text_disabled
window_bg
child_bg
popup_bg
border
border_shadow
frame_bg
frame_bg_hovered
frame_bg_active
title_bg
title_bg_active
title_bg_collapsed
menu_bar_bg
scrollbar_bg
scrollbar_grab
scrollbar_grab_hovered
scrollbar_grab_active
check_mark
checkbox_selected_bg
slider_grab
slider_grab_active
button
button_hovered
button_active
header
header_hovered
header_active
separator
separator_hovered
separator_active
resize_grip
resize_grip_hovered
resize_grip_active
input_text_cursor
tab_hovered
tab
tab_selected
tab_selected_overline
tab_dimmed
tab_dimmed_selected
tab_dimmed_selected_overline
docking_preview
docking_empty_bg
plot_lines
plot_lines_hovered
plot_histogram
plot_histogram_hovered
table_header_bg
table_border_strong
table_border_light
table_row_bg
table_row_bg_alt
text_link
text_selected_bg
tree_lines
drag_drop_target
drag_drop_target_bg
unsaved_marker
nav_cursor
nav_windowing_highlight
nav_windowing_dim_bg
modal_window_dim_bg
count
}
pub enum StyleVar_ {
alpha
disabled_alpha
window_padding
window_rounding
window_border_size
window_min_size
window_title_align
child_rounding
child_border_size
popup_rounding
popup_border_size
frame_padding
frame_rounding
frame_border_size
item_spacing
item_inner_spacing
indent_spacing
cell_padding
scrollbar_size
scrollbar_rounding
scrollbar_padding
grab_min_size
grab_rounding
image_rounding
image_border_size
tab_rounding
tab_border_size
tab_min_width_base
tab_min_width_shrink
tab_bar_border_size
tab_bar_overline_size
table_angled_headers_angle
table_angled_headers_text_align
tree_lines_size
tree_lines_rounding
menu_item_rounding
selectable_rounding
drag_drop_target_rounding
button_text_align
selectable_text_align
separator_size
separator_text_border_size
separator_text_align
separator_text_padding
docking_separator_size
count
}
pub enum ButtonFlags_ {
none = 0
mouse_button_left = 1 << 0
mouse_button_right = 1 << 1
mouse_button_middle = 1 << 2
mouse_button_mask_ = 1 << 0 | 1 << 1 | 1 << 2
enable_nav = 1 << 3
allow_overlap = 1 << 12
}
pub enum ColorEditFlags_ {
none = 0
no_alpha = 1 << 1
no_picker = 1 << 2
no_options = 1 << 3
no_small_preview = 1 << 4
no_inputs = 1 << 5
no_tooltip = 1 << 6
no_label = 1 << 7
no_side_preview = 1 << 8
no_drag_drop = 1 << 9
no_border = 1 << 10
no_color_markers = 1 << 11
alpha_opaque = 1 << 12
alpha_no_bg = 1 << 13
alpha_preview_half = 1 << 14
alpha_bar = 1 << 18
hdr = 1 << 19
display_rgb = 1 << 20
display_hsv = 1 << 21
display_hex = 1 << 22
uint8 = 1 << 23
float = 1 << 24
picker_hue_bar = 1 << 25
picker_hue_wheel = 1 << 26
picker_no_rotate = 1 << 27
input_rgb = 1 << 28
input_hsv = 1 << 29
default_options_ = 1 << 20 | 1 << 23 | 1 << 25 | 1 << 28
alpha_mask_ = 1 << 1 | 1 << 12 | 1 << 13 | 1 << 14
display_mask_ = 1 << 20 | 1 << 21 | 1 << 22
data_type_mask_ = 1 << 23 | 1 << 24
picker_mask_ = 1 << 25 | 1 << 26
input_mask_ = 1 << 28 | 1 << 29
}
pub enum SliderFlags_ {
none = 0
logarithmic = 1 << 5
no_round_to_format = 1 << 6
no_input = 1 << 7
wrap_around = 1 << 8
clamp_on_input = 1 << 9
clamp_zero_range = 1 << 10
no_speed_tweaks = 1 << 11
color_markers = 1 << 12
always_clamp = 1 << 9 | 1 << 10
invalid_mask_ = 1 << 0 | 1 << 1 | 1 << 2 | 1 << 3 | 1 << 28 | 1 << 29 | 1 << 30
}
pub enum MouseButton_ {
left = 0
right = 1
middle = 2
count = 5
}
pub enum MouseCursor_ {
none = -1
arrow = 0
text_input
resize_all
resize_ns
resize_ew
resize_nesw
resize_nwse
hand
wait
progress
not_allowed
count
}
pub enum MouseSource {
mouse = 0
touch_screen = 1
pen = 2
count = 3
}
pub enum Cond_ {
none = 0
always = 1
once = 2
first_use_ever = 4
appearing = 8
}
pub enum TableFlags_ {
none = 0
resizable = 1 << 0
reorderable = 1 << 1
hideable = 1 << 2
sortable = 1 << 3
no_saved_settings = 1 << 4
context_menu_in_body = 1 << 5
row_bg = 1 << 6
borders_inner_h = 1 << 7
borders_outer_h = 1 << 8
borders_inner_v = 1 << 9
borders_outer_v = 1 << 10
borders_h = 1 << 7 | 1 << 8
borders_v = 1 << 9 | 1 << 10
borders_inner = 1 << 7 | 1 << 9
borders_outer = 1 << 8 | 1 << 10
borders = 1 << 7 | 1 << 8 | 1 << 9 | 1 << 10
no_borders_in_body = 1 << 11
no_borders_in_body_until_resize = 1 << 12
sizing_fixed_fit = 1 << 13
sizing_fixed_same = 1 << 14
sizing_stretch_prop = 1 << 13 | 1 << 14
sizing_stretch_same = 1 << 15
no_host_extend_x = 1 << 16
no_host_extend_y = 1 << 17
no_keep_columns_visible = 1 << 18
precise_widths = 1 << 19
no_clip = 1 << 20
pad_outer_x = 1 << 21
no_pad_outer_x = 1 << 22
no_pad_inner_x = 1 << 23
scroll_x = 1 << 24
scroll_y = 1 << 25
sort_multi = 1 << 26
sort_tristate = 1 << 27
highlight_hovered_column = 1 << 28
sizing_mask_ = 1 << 13 | 1 << 14 | 1 << 15
}
pub enum TableColumnFlags_ {
none = 0
disabled = 1 << 0
default_hide = 1 << 1
default_sort = 1 << 2
width_stretch = 1 << 3
width_fixed = 1 << 4
no_resize = 1 << 5
no_reorder = 1 << 6
no_hide = 1 << 7
no_clip = 1 << 8
no_sort = 1 << 9
no_sort_ascending = 1 << 10
no_sort_descending = 1 << 11
no_header_label = 1 << 12