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
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
1184
1185
1186
1187
1188
1189
1190
1191
1192
1193
1194
1195
1196
1197
1198
1199
1200
1201
1202
1203
1204
1205
1206
1207
1208
1209
1210
1211
1212
1213
1214
1215
1216
1217
1218
1219
1220
1221
1222
1223
1224
1225
1226
1227
1228
1229
1230
1231
1232
1233
1234
1235
1236
1237
1238
1239
1240
1241
1242
1243
1244
1245
1246
1247
1248
1249
1250
1251
1252
1253
1254
1255
1256
1257
1258
1259
1260
1261
1262
1263
1264
1265
1266
1267
1268
1269
1270
1271
1272
1273
1274
1275
1276
1277
1278
1279
1280
1281
1282
1283
1284
1285
1286
1287
1288
1289
1290
1291
1292
1293
1294
1295
1296
1297
1298
1299
1300
1301
1302
1303
1304
1305
1306
1307
1308
1309
1310
1311
1312
1313
1314
1315
1316
1317
1318
1319
1320
1321
1322
1323
1324
1325
1326
1327
1328
1329
1330
1331
1332
1333
1334
1335
1336
1337
1338
1339
1340
1341
1342
1343
1344
1345
1346
1347
1348
1349
1350
1351
1352
1353
1354
1355
1356
1357
1358
1359
1360
1361
1362
1363
1364
1365
1366
1367
1368
1369
1370
1371
1372
1373
1374
1375
1376
1377
1378
1379
1380
1381
1382
1383
1384
1385
1386
1387
1388
1389
1390
1391
1392
1393
1394
1395
1396
1397
1398
1399
1400
1401
1402
1403
1404
1405
1406
1407
1408
1409
1410
1411
1412
1413
1414
1415
1416
1417
1418
1419
1420
1421
1422
1423
1424
1425
1426
1427
1428
1429
1430
1431
1432
1433
1434
1435
1436
1437
1438
1439
1440
1441
1442
1443
1444
1445
1446
1447
1448
1449
1450
1451
1452
1453
1454
1455
1456
1457
1458
1459
1460
1461
1462
1463
1464
1465
1466
1467
1468
1469
1470
1471
1472
1473
1474
1475
1476
1477
1478
1479
1480
1481
1482
1483
1484
1485
1486
1487
1488
1489
1490
1491
1492
1493
1494
1495
1496
1497
1498
1499
1500
1501
1502
1503
1504
1505
1506
1507
1508
1509
1510
1511
1512
1513
1514
1515
1516
1517
1518
1519
1520
1521
1522
1523
1524
1525
1526
1527
1528
1529
1530
1531
1532
1533
1534
1535
1536
1537
1538
1539
1540
1541
1542
1543
1544
1545
1546
1547
1548
1549
1550
1551
1552
1553
1554
1555
1556
1557
1558
1559
1560
1561
1562
1563
1564
1565
1566
1567
1568
1569
1570
1571
1572
1573
1574
1575
1576
1577
1578
1579
1580
1581
1582
1583
1584
1585
1586
1587
1588
1589
1590
1591
1592
1593
1594
1595
1596
1597
1598
1599
1600
// This file is auto-generated by rute_gen. DO NOT EDIT.

#[repr(u32)]
pub enum GlobalColor {
    Color0 = 0,
    Color1 = 1,
    Black = 2,
    White = 3,
    DarkGray = 4,
    Gray = 5,
    LightGray = 6,
    Red = 7,
    Green = 8,
    Blue = 9,
    Cyan = 10,
    Magenta = 11,
    Yellow = 12,
    DarkRed = 13,
    DarkGreen = 14,
    DarkBlue = 15,
    DarkCyan = 16,
    DarkMagenta = 17,
    DarkYellow = 18,
    Transparent = 19,
}

bitflags! {
    pub struct KeyboardModifier: u32 {
        const NoModifier = 0x0;
        const ShiftModifier = 0x2000000;
        const ControlModifier = 0x4000000;
        const AltModifier = 0x8000000;
        const MetaModifier = 0x10000000;
        const KeypadModifier = 0x20000000;
        const GroupSwitchModifier = 0x40000000;
        const KeyboardModifierMask = 0xfe000000;
    }
}

pub type KeyboardModifiers = KeyboardModifier;

bitflags! {
    pub struct Modifier: u32 {
        const Meta = 0x10000000;
        const Shift = 0x2000000;
        const Ctrl = 0x4000000;
        const Alt = 0x8000000;
        const ModifierMask = 0xfe000000;
        const UnicodeAccel = 0x0;
    }
}

bitflags! {
    pub struct MouseButton: u32 {
        const NoButton = 0x0;
        const LeftButton = 0x1;
        const RightButton = 0x2;
        const MidButton = 0x4;
        const MiddleButton = 0x4;
        const BackButton = 0x8;
        const XButton1 = 0x8;
        const ExtraButton1 = 0x8;
        const ForwardButton = 0x10;
        const XButton2 = 0x10;
        const ExtraButton2 = 0x10;
        const TaskButton = 0x20;
        const ExtraButton3 = 0x20;
        const ExtraButton4 = 0x40;
        const ExtraButton5 = 0x80;
        const ExtraButton6 = 0x100;
        const ExtraButton7 = 0x200;
        const ExtraButton8 = 0x400;
        const ExtraButton9 = 0x800;
        const ExtraButton10 = 0x1000;
        const ExtraButton11 = 0x2000;
        const ExtraButton12 = 0x4000;
        const ExtraButton13 = 0x8000;
        const ExtraButton14 = 0x10000;
        const ExtraButton15 = 0x20000;
        const ExtraButton16 = 0x40000;
        const ExtraButton17 = 0x80000;
        const ExtraButton18 = 0x100000;
        const ExtraButton19 = 0x200000;
        const ExtraButton20 = 0x400000;
        const ExtraButton21 = 0x800000;
        const ExtraButton22 = 0x1000000;
        const ExtraButton23 = 0x2000000;
        const ExtraButton24 = 0x4000000;
        const AllButtons = 0x7ffffff;
        const MaxMouseButton = 0x4000000;
        const MouseButtonMask = 0xffffffff;
    }
}

pub type MouseButtons = MouseButton;

#[repr(u32)]
pub enum Orientation {
    Horizontal = 1,
    Vertical = 2,
}

bitflags! {
    pub struct Orientations: u32 {
        const Horizontal = Orientation::Horizontal as u32;
        const Vertical = Orientation::Vertical as u32;
    }
}
#[repr(u32)]
pub enum FocusPolicy {
    NoFocus = 0,
    TabFocus = 1,
    ClickFocus = 2,
    StrongFocus = 11,
    WheelFocus = 15,
}

#[repr(u32)]
pub enum TabFocusBehavior {
    NoTabFocus = 0,
    TabFocusTextControls = 1,
    TabFocusListControls = 2,
    TabFocusAllControls = 255,
}

#[repr(u32)]
pub enum SortOrder {
    AscendingOrder = 0,
    DescendingOrder = 1,
}

#[repr(u32)]
pub enum TileRule {
    StretchTile = 0,
    RepeatTile = 1,
    RoundTile = 2,
}

bitflags! {
    pub struct AlignmentFlag: u32 {
        const AlignDefault = 0x0;
        const AlignLeft = 0x1;
        const AlignLeading = 0x1;
        const AlignRight = 0x2;
        const AlignTrailing = 0x2;
        const AlignHCenter = 0x4;
        const AlignJustify = 0x8;
        const AlignAbsolute = 0x10;
        const AlignHorizontalMask = 0x1f;
        const AlignTop = 0x20;
        const AlignBottom = 0x40;
        const AlignVCenter = 0x80;
        const AlignBaseline = 0x100;
        const AlignVerticalMask = 0x1e0;
        const AlignCenter = 0x84;
    }
}

pub type Alignment = AlignmentFlag;

bitflags! {
    pub struct TextFlag: u32 {
        const TextSingleLine = 0x100;
        const TextDontClip = 0x200;
        const TextExpandTabs = 0x400;
        const TextShowMnemonic = 0x800;
        const TextWordWrap = 0x1000;
        const TextWrapAnywhere = 0x2000;
        const TextDontPrint = 0x4000;
        const TextIncludeTrailingSpaces = 0x8000000;
        const TextHideMnemonic = 0x8000;
        const TextJustificationForced = 0x10000;
        const TextForceLeftToRight = 0x20000;
        const TextForceRightToLeft = 0x40000;
        const TextLongestVariant = 0x80000;
        const TextBypassShaping = 0x100000;
    }
}

#[repr(u32)]
pub enum TextElideMode {
    ElideLeft = 0,
    ElideRight = 1,
    ElideMiddle = 2,
    ElideNone = 3,
}

#[repr(u32)]
pub enum WhiteSpaceMode {
    WhiteSpaceNormal = 0,
    WhiteSpacePre = 1,
    WhiteSpaceNoWrap = 2,
    WhiteSpaceModeUndefined = 4294967295,
}

#[repr(u32)]
pub enum HitTestAccuracy {
    ExactHit = 0,
    FuzzyHit = 1,
}

bitflags! {
    pub struct WindowType: u32 {
        const Widget = 0x0;
        const Window = 0x1;
        const Dialog = 0x3;
        const Sheet = 0x5;
        const Drawer = 0x7;
        const Popup = 0x9;
        const Tool = 0xb;
        const ToolTip = 0xd;
        const SplashScreen = 0xf;
        const Desktop = 0x11;
        const SubWindow = 0x12;
        const ForeignWindow = 0x21;
        const CoverWindow = 0x41;
        const WindowTypeMask = 0xff;
        const MsWindowsFixedSizeDialogHint = 0x100;
        const MsWindowsOwnDc = 0x200;
        const BypassWindowManagerHint = 0x400;
        const X11BypassWindowManagerHint = 0x400;
        const FramelessWindowHint = 0x800;
        const WindowTitleHint = 0x1000;
        const WindowSystemMenuHint = 0x2000;
        const WindowMinimizeButtonHint = 0x4000;
        const WindowMaximizeButtonHint = 0x8000;
        const WindowMinMaxButtonsHint = 0xc000;
        const WindowContextHelpButtonHint = 0x10000;
        const WindowShadeButtonHint = 0x20000;
        const WindowStaysOnTopHint = 0x40000;
        const WindowTransparentForInput = 0x80000;
        const WindowOverridesSystemGestures = 0x100000;
        const WindowDoesNotAcceptFocus = 0x200000;
        const MaximizeUsingFullscreenGeometryHint = 0x400000;
        const CustomizeWindowHint = 0x2000000;
        const WindowStaysOnBottomHint = 0x4000000;
        const WindowCloseButtonHint = 0x8000000;
        const MacWindowToolBarButtonHint = 0x10000000;
        const BypassGraphicsProxyWidget = 0x20000000;
        const NoDropShadowWindowHint = 0x40000000;
        const WindowFullscreenButtonHint = 0x80000000;
    }
}

pub type WindowFlags = WindowType;

bitflags! {
    pub struct WindowState: u32 {
        const WindowNoState = 0x0;
        const WindowMinimized = 0x1;
        const WindowMaximized = 0x2;
        const WindowFullScreen = 0x4;
        const WindowActive = 0x8;
    }
}

pub type WindowStates = WindowState;

bitflags! {
    pub struct ApplicationState: u32 {
        const ApplicationSuspended = 0x0;
        const ApplicationHidden = 0x1;
        const ApplicationInactive = 0x2;
        const ApplicationActive = 0x4;
    }
}

bitflags! {
    pub struct ScreenOrientation: u32 {
        const PrimaryOrientation = 0x0;
        const PortraitOrientation = 0x1;
        const LandscapeOrientation = 0x2;
        const InvertedPortraitOrientation = 0x4;
        const InvertedLandscapeOrientation = 0x8;
    }
}

bitflags! {
    pub struct WidgetAttribute: u32 {
        const WaDisabled = 0x0;
        const WaUnderMouse = 0x1;
        const WaMouseTracking = 0x2;
        const WaContentsPropagated = 0x3;
        const WaOpaquePaintEvent = 0x4;
        const WaNoBackground = 0x4;
        const WaStaticContents = 0x5;
        const WaLaidOut = 0x7;
        const WaPaintOnScreen = 0x8;
        const WaNoSystemBackground = 0x9;
        const WaUpdatesDisabled = 0xa;
        const WaMapped = 0xb;
        const WaMacNoClickThrough = 0xc;
        const WaInputMethodEnabled = 0xe;
        const WaWStateVisible = 0xf;
        const WaWStateHidden = 0x10;
        const WaForceDisabled = 0x20;
        const WaKeyCompression = 0x21;
        const WaPendingMoveEvent = 0x22;
        const WaPendingResizeEvent = 0x23;
        const WaSetPalette = 0x24;
        const WaSetFont = 0x25;
        const WaSetCursor = 0x26;
        const WaNoChildEventsFromChildren = 0x27;
        const WaWindowModified = 0x29;
        const WaResized = 0x2a;
        const WaMoved = 0x2b;
        const WaPendingUpdate = 0x2c;
        const WaInvalidSize = 0x2d;
        const WaMacBrushedMetal = 0x2e;
        const WaMacMetalStyle = 0x2e;
        const WaCustomWhatsThis = 0x2f;
        const WaLayoutOnEntireRect = 0x30;
        const WaOutsideWsRange = 0x31;
        const WaGrabbedShortcut = 0x32;
        const WaTransparentForMouseEvents = 0x33;
        const WaPaintUnclipped = 0x34;
        const WaSetWindowIcon = 0x35;
        const WaNoMouseReplay = 0x36;
        const WaDeleteOnClose = 0x37;
        const WaRightToLeft = 0x38;
        const WaSetLayoutDirection = 0x39;
        const WaNoChildEventsForParent = 0x3a;
        const WaForceUpdatesDisabled = 0x3b;
        const WaWStateCreated = 0x3c;
        const WaWStateCompressKeys = 0x3d;
        const WaWStateInPaintEvent = 0x3e;
        const WaWStateReparented = 0x3f;
        const WaWStateConfigPending = 0x40;
        const WaWStatePolished = 0x42;
        const WaWStateDnd = 0x43;
        const WaWStateOwnSizePolicy = 0x44;
        const WaWStateExplicitShowHide = 0x45;
        const WaShowModal = 0x46;
        const WaMouseNoMask = 0x47;
        const WaGroupLeader = 0x48;
        const WaNoMousePropagation = 0x49;
        const WaHover = 0x4a;
        const WaInputMethodTransparent = 0x4b;
        const WaQuitOnClose = 0x4c;
        const WaKeyboardFocusChange = 0x4d;
        const WaAcceptDrops = 0x4e;
        const WaDropSiteRegistered = 0x4f;
        const WaForceAcceptDrops = 0x4f;
        const WaWindowPropagation = 0x50;
        const WaNoX11EventCompression = 0x51;
        const WaTintedBackground = 0x52;
        const WaX11OpenGlOverlay = 0x53;
        const WaAlwaysShowToolTips = 0x54;
        const WaMacOpaqueSizeGrip = 0x55;
        const WaSetStyle = 0x56;
        const WaSetLocale = 0x57;
        const WaMacShowFocusRect = 0x58;
        const WaMacNormalSize = 0x59;
        const WaMacSmallSize = 0x5a;
        const WaMacMiniSize = 0x5b;
        const WaLayoutUsesWidgetRect = 0x5c;
        const WaStyledBackground = 0x5d;
        const WaMsWindowsUseDirect3D = 0x5e;
        const WaCanHostQMdiSubWindowTitleBar = 0x5f;
        const WaMacAlwaysShowToolWindow = 0x60;
        const WaStyleSheet = 0x61;
        const WaShowWithoutActivating = 0x62;
        const WaX11BypassTransientForHint = 0x63;
        const WaNativeWindow = 0x64;
        const WaDontCreateNativeAncestors = 0x65;
        const WaMacVariableSize = 0x66;
        const WaDontShowOnScreen = 0x67;
        const WaX11NetWmWindowTypeDesktop = 0x68;
        const WaX11NetWmWindowTypeDock = 0x69;
        const WaX11NetWmWindowTypeToolBar = 0x6a;
        const WaX11NetWmWindowTypeMenu = 0x6b;
        const WaX11NetWmWindowTypeUtility = 0x6c;
        const WaX11NetWmWindowTypeSplash = 0x6d;
        const WaX11NetWmWindowTypeDialog = 0x6e;
        const WaX11NetWmWindowTypeDropDownMenu = 0x6f;
        const WaX11NetWmWindowTypePopupMenu = 0x70;
        const WaX11NetWmWindowTypeToolTip = 0x71;
        const WaX11NetWmWindowTypeNotification = 0x72;
        const WaX11NetWmWindowTypeCombo = 0x73;
        const WaX11NetWmWindowTypeDnd = 0x74;
        const WaMacFrameworkScaled = 0x75;
        const WaSetWindowModality = 0x76;
        const WaWStateWindowOpacitySet = 0x77;
        const WaTranslucentBackground = 0x78;
        const WaAcceptTouchEvents = 0x79;
        const WaWStateAcceptedTouchBeginEvent = 0x7a;
        const WaTouchPadAcceptSingleTouchEvents = 0x7b;
        const WaX11DoNotAcceptFocus = 0x7e;
        const WaMacNoShadow = 0x7f;
        const WaAlwaysStackOnTop = 0x80;
        const WaTabletTracking = 0x81;
        const WaContentsMarginsRespectsSafeArea = 0x82;
        const WaAttributeCount = 0x83;
    }
}

#[repr(u32)]
pub enum ApplicationAttribute {
    AaImmediateWidgetCreation = 0,
    AaMsWindowsUseDirect3DByDefault = 1,
    AaDontShowIconsInMenus = 2,
    AaNativeWindows = 3,
    AaDontCreateNativeWidgetSiblings = 4,
    AaPluginApplication = 5,
    AaDontUseNativeMenuBar = 6,
    AaMacDontSwapCtrlAndMeta = 7,
    AaUse96Dpi = 8,
    AaX11InitThreads = 10,
    AaSynthesizeTouchForUnhandledMouseEvents = 11,
    AaSynthesizeMouseForUnhandledTouchEvents = 12,
    AaUseHighDpiPixmaps = 13,
    AaForceRasterWidgets = 14,
    AaUseDesktopOpenGl = 15,
    AaUseOpenGles = 16,
    AaUseSoftwareOpenGl = 17,
    AaShareOpenGlContexts = 18,
    AaSetPalette = 19,
    AaDisableHighDpiScaling = 21,
    AaUseStyleSheetPropagationInWidgetStyles = 22,
    AaDontUseNativeDialogs = 23,
    AaSynthesizeMouseForUnhandledTabletEvents = 24,
    AaCompressHighFrequencyEvents = 25,
    AaDontCheckOpenGlContextThreadAffinity = 26,
    AaDisableShaderDiskCache = 27,
    AaDontShowShortcutsInContextMenus = 28,
    AaCompressTabletEvents = 29,
    AaDisableWindowContextHelpButton = 30,
    AaAttributeCount = 31,
}

bitflags! {
    pub struct ImageConversionFlag: u32 {
        const ColorModeMask = 0x3;
        const AutoColor = 0x0;
        const ColorOnly = 0x3;
        const MonoOnly = 0x2;
        const AlphaDitherMask = 0xc;
        const ThresholdAlphaDither = 0x0;
        const OrderedAlphaDither = 0x4;
        const DiffuseAlphaDither = 0x8;
        const NoAlpha = 0xc;
        const DitherMask = 0x30;
        const DiffuseDither = 0x0;
        const OrderedDither = 0x10;
        const ThresholdDither = 0x20;
        const DitherModeMask = 0xc0;
        const AutoDither = 0x0;
        const PreferDither = 0x40;
        const AvoidDither = 0x80;
        const NoOpaqueDetection = 0x100;
        const NoFormatConversion = 0x200;
    }
}

pub type ImageConversionFlags = ImageConversionFlag;

#[repr(u32)]
pub enum BGMode {
    TransparentMode = 0,
    OpaqueMode = 1,
}

bitflags! {
    pub struct Key: u32 {
        const KeyEscape = 0x1000000;
        const KeyTab = 0x1000001;
        const KeyBacktab = 0x1000002;
        const KeyBackspace = 0x1000003;
        const KeyReturn = 0x1000004;
        const KeyEnter = 0x1000005;
        const KeyInsert = 0x1000006;
        const KeyDelete = 0x1000007;
        const KeyPause = 0x1000008;
        const KeyPrint = 0x1000009;
        const KeySysReq = 0x100000a;
        const KeyClear = 0x100000b;
        const KeyHome = 0x1000010;
        const KeyEnd = 0x1000011;
        const KeyLeft = 0x1000012;
        const KeyUp = 0x1000013;
        const KeyRight = 0x1000014;
        const KeyDown = 0x1000015;
        const KeyPageUp = 0x1000016;
        const KeyPageDown = 0x1000017;
        const KeyShift = 0x1000020;
        const KeyControl = 0x1000021;
        const KeyMeta = 0x1000022;
        const KeyAlt = 0x1000023;
        const KeyCapsLock = 0x1000024;
        const KeyNumLock = 0x1000025;
        const KeyScrollLock = 0x1000026;
        const KeyF1 = 0x1000030;
        const KeyF2 = 0x1000031;
        const KeyF3 = 0x1000032;
        const KeyF4 = 0x1000033;
        const KeyF5 = 0x1000034;
        const KeyF6 = 0x1000035;
        const KeyF7 = 0x1000036;
        const KeyF8 = 0x1000037;
        const KeyF9 = 0x1000038;
        const KeyF10 = 0x1000039;
        const KeyF11 = 0x100003a;
        const KeyF12 = 0x100003b;
        const KeyF13 = 0x100003c;
        const KeyF14 = 0x100003d;
        const KeyF15 = 0x100003e;
        const KeyF16 = 0x100003f;
        const KeyF17 = 0x1000040;
        const KeyF18 = 0x1000041;
        const KeyF19 = 0x1000042;
        const KeyF20 = 0x1000043;
        const KeyF21 = 0x1000044;
        const KeyF22 = 0x1000045;
        const KeyF23 = 0x1000046;
        const KeyF24 = 0x1000047;
        const KeyF25 = 0x1000048;
        const KeyF26 = 0x1000049;
        const KeyF27 = 0x100004a;
        const KeyF28 = 0x100004b;
        const KeyF29 = 0x100004c;
        const KeyF30 = 0x100004d;
        const KeyF31 = 0x100004e;
        const KeyF32 = 0x100004f;
        const KeyF33 = 0x1000050;
        const KeyF34 = 0x1000051;
        const KeyF35 = 0x1000052;
        const KeySuperL = 0x1000053;
        const KeySuperR = 0x1000054;
        const KeyMenu = 0x1000055;
        const KeyHyperL = 0x1000056;
        const KeyHyperR = 0x1000057;
        const KeyHelp = 0x1000058;
        const KeyDirectionL = 0x1000059;
        const KeyDirectionR = 0x1000060;
        const KeySpace = 0x20;
        const KeyAny = 0x20;
        const KeyExclam = 0x21;
        const KeyQuoteDbl = 0x22;
        const KeyNumberSign = 0x23;
        const KeyDollar = 0x24;
        const KeyPercent = 0x25;
        const KeyAmpersand = 0x26;
        const KeyApostrophe = 0x27;
        const KeyParenLeft = 0x28;
        const KeyParenRight = 0x29;
        const KeyAsterisk = 0x2a;
        const KeyPlus = 0x2b;
        const KeyComma = 0x2c;
        const KeyMinus = 0x2d;
        const KeyPeriod = 0x2e;
        const KeySlash = 0x2f;
        const Key0 = 0x30;
        const Key1 = 0x31;
        const Key2 = 0x32;
        const Key3 = 0x33;
        const Key4 = 0x34;
        const Key5 = 0x35;
        const Key6 = 0x36;
        const Key7 = 0x37;
        const Key8 = 0x38;
        const Key9 = 0x39;
        const KeyColon = 0x3a;
        const KeySemicolon = 0x3b;
        const KeyLess = 0x3c;
        const KeyEqual = 0x3d;
        const KeyGreater = 0x3e;
        const KeyQuestion = 0x3f;
        const KeyAt = 0x40;
        const KeyA = 0x41;
        const KeyB = 0x42;
        const KeyC = 0x43;
        const KeyD = 0x44;
        const KeyE = 0x45;
        const KeyF = 0x46;
        const KeyG = 0x47;
        const KeyH = 0x48;
        const KeyI = 0x49;
        const KeyJ = 0x4a;
        const KeyK = 0x4b;
        const KeyL = 0x4c;
        const KeyM = 0x4d;
        const KeyN = 0x4e;
        const KeyO = 0x4f;
        const KeyP = 0x50;
        const KeyQ = 0x51;
        const KeyR = 0x52;
        const KeyS = 0x53;
        const KeyT = 0x54;
        const KeyU = 0x55;
        const KeyV = 0x56;
        const KeyW = 0x57;
        const KeyX = 0x58;
        const KeyY = 0x59;
        const KeyZ = 0x5a;
        const KeyBracketLeft = 0x5b;
        const KeyBackslash = 0x5c;
        const KeyBracketRight = 0x5d;
        const KeyAsciiCircum = 0x5e;
        const KeyUnderscore = 0x5f;
        const KeyQuoteLeft = 0x60;
        const KeyBraceLeft = 0x7b;
        const KeyBar = 0x7c;
        const KeyBraceRight = 0x7d;
        const KeyAsciiTilde = 0x7e;
        const KeyNobreakspace = 0xa0;
        const KeyExclamdown = 0xa1;
        const KeyCent = 0xa2;
        const KeySterling = 0xa3;
        const KeyCurrency = 0xa4;
        const KeyYen = 0xa5;
        const KeyBrokenbar = 0xa6;
        const KeySection = 0xa7;
        const KeyDiaeresis = 0xa8;
        const KeyCopyright = 0xa9;
        const KeyOrdfeminine = 0xaa;
        const KeyGuillemotleft = 0xab;
        const KeyNotsign = 0xac;
        const KeyHyphen = 0xad;
        const KeyRegistered = 0xae;
        const KeyMacron = 0xaf;
        const KeyDegree = 0xb0;
        const KeyPlusminus = 0xb1;
        const KeyTwosuperior = 0xb2;
        const KeyThreesuperior = 0xb3;
        const KeyAcute = 0xb4;
        const KeyMu = 0xb5;
        const KeyParagraph = 0xb6;
        const KeyPeriodcentered = 0xb7;
        const KeyCedilla = 0xb8;
        const KeyOnesuperior = 0xb9;
        const KeyMasculine = 0xba;
        const KeyGuillemotright = 0xbb;
        const KeyOnequarter = 0xbc;
        const KeyOnehalf = 0xbd;
        const KeyThreequarters = 0xbe;
        const KeyQuestiondown = 0xbf;
        const KeyAgrave = 0xc0;
        const KeyAacute = 0xc1;
        const KeyAcircumflex = 0xc2;
        const KeyAtilde = 0xc3;
        const KeyAdiaeresis = 0xc4;
        const KeyAring = 0xc5;
        const KeyAe = 0xc6;
        const KeyCcedilla = 0xc7;
        const KeyEgrave = 0xc8;
        const KeyEacute = 0xc9;
        const KeyEcircumflex = 0xca;
        const KeyEdiaeresis = 0xcb;
        const KeyIgrave = 0xcc;
        const KeyIacute = 0xcd;
        const KeyIcircumflex = 0xce;
        const KeyIdiaeresis = 0xcf;
        const KeyEth = 0xd0;
        const KeyNtilde = 0xd1;
        const KeyOgrave = 0xd2;
        const KeyOacute = 0xd3;
        const KeyOcircumflex = 0xd4;
        const KeyOtilde = 0xd5;
        const KeyOdiaeresis = 0xd6;
        const KeyMultiply = 0xd7;
        const KeyOoblique = 0xd8;
        const KeyUgrave = 0xd9;
        const KeyUacute = 0xda;
        const KeyUcircumflex = 0xdb;
        const KeyUdiaeresis = 0xdc;
        const KeyYacute = 0xdd;
        const KeyThorn = 0xde;
        const KeySsharp = 0xdf;
        const KeyDivision = 0xf7;
        const KeyYdiaeresis = 0xff;
        const KeyAltGr = 0x1001103;
        const KeyMultiKey = 0x1001120;
        const KeyCodeinput = 0x1001137;
        const KeySingleCandidate = 0x100113c;
        const KeyMultipleCandidate = 0x100113d;
        const KeyPreviousCandidate = 0x100113e;
        const KeyModeSwitch = 0x100117e;
        const KeyKanji = 0x1001121;
        const KeyMuhenkan = 0x1001122;
        const KeyHenkan = 0x1001123;
        const KeyRomaji = 0x1001124;
        const KeyHiragana = 0x1001125;
        const KeyKatakana = 0x1001126;
        const KeyHiraganaKatakana = 0x1001127;
        const KeyZenkaku = 0x1001128;
        const KeyHankaku = 0x1001129;
        const KeyZenkakuHankaku = 0x100112a;
        const KeyTouroku = 0x100112b;
        const KeyMassyo = 0x100112c;
        const KeyKanaLock = 0x100112d;
        const KeyKanaShift = 0x100112e;
        const KeyEisuShift = 0x100112f;
        const KeyEisuToggle = 0x1001130;
        const KeyHangul = 0x1001131;
        const KeyHangulStart = 0x1001132;
        const KeyHangulEnd = 0x1001133;
        const KeyHangulHanja = 0x1001134;
        const KeyHangulJamo = 0x1001135;
        const KeyHangulRomaja = 0x1001136;
        const KeyHangulJeonja = 0x1001138;
        const KeyHangulBanja = 0x1001139;
        const KeyHangulPreHanja = 0x100113a;
        const KeyHangulPostHanja = 0x100113b;
        const KeyHangulSpecial = 0x100113f;
        const KeyDeadGrave = 0x1001250;
        const KeyDeadAcute = 0x1001251;
        const KeyDeadCircumflex = 0x1001252;
        const KeyDeadTilde = 0x1001253;
        const KeyDeadMacron = 0x1001254;
        const KeyDeadBreve = 0x1001255;
        const KeyDeadAbovedot = 0x1001256;
        const KeyDeadDiaeresis = 0x1001257;
        const KeyDeadAbovering = 0x1001258;
        const KeyDeadDoubleacute = 0x1001259;
        const KeyDeadCaron = 0x100125a;
        const KeyDeadCedilla = 0x100125b;
        const KeyDeadOgonek = 0x100125c;
        const KeyDeadIota = 0x100125d;
        const KeyDeadVoicedSound = 0x100125e;
        const KeyDeadSemivoicedSound = 0x100125f;
        const KeyDeadBelowdot = 0x1001260;
        const KeyDeadHook = 0x1001261;
        const KeyDeadHorn = 0x1001262;
        const KeyDeadStroke = 0x1001263;
        const KeyDeadAbovecomma = 0x1001264;
        const KeyDeadAbovereversedcomma = 0x1001265;
        const KeyDeadDoublegrave = 0x1001266;
        const KeyDeadBelowring = 0x1001267;
        const KeyDeadBelowmacron = 0x1001268;
        const KeyDeadBelowcircumflex = 0x1001269;
        const KeyDeadBelowtilde = 0x100126a;
        const KeyDeadBelowbreve = 0x100126b;
        const KeyDeadBelowdiaeresis = 0x100126c;
        const KeyDeadInvertedbreve = 0x100126d;
        const KeyDeadBelowcomma = 0x100126e;
        const KeyDeadCurrency = 0x100126f;
        const KeyDeadA = 0x1001281;
        const KeyDeadE = 0x1001283;
        const KeyDeadI = 0x1001285;
        const KeyDeadO = 0x1001287;
        const KeyDeadU = 0x1001289;
        const KeyDeadSmallSchwa = 0x100128a;
        const KeyDeadCapitalSchwa = 0x100128b;
        const KeyDeadGreek = 0x100128c;
        const KeyDeadLowline = 0x1001290;
        const KeyDeadAboveverticalline = 0x1001291;
        const KeyDeadBelowverticalline = 0x1001292;
        const KeyDeadLongsolidusoverlay = 0x1001293;
        const KeyBack = 0x1000061;
        const KeyForward = 0x1000062;
        const KeyStop = 0x1000063;
        const KeyRefresh = 0x1000064;
        const KeyVolumeDown = 0x1000070;
        const KeyVolumeMute = 0x1000071;
        const KeyVolumeUp = 0x1000072;
        const KeyBassBoost = 0x1000073;
        const KeyBassUp = 0x1000074;
        const KeyBassDown = 0x1000075;
        const KeyTrebleUp = 0x1000076;
        const KeyTrebleDown = 0x1000077;
        const KeyMediaPlay = 0x1000080;
        const KeyMediaStop = 0x1000081;
        const KeyMediaPrevious = 0x1000082;
        const KeyMediaNext = 0x1000083;
        const KeyMediaRecord = 0x1000084;
        const KeyMediaPause = 0x1000085;
        const KeyMediaTogglePlayPause = 0x1000086;
        const KeyHomePage = 0x1000090;
        const KeyFavorites = 0x1000091;
        const KeySearch = 0x1000092;
        const KeyStandby = 0x1000093;
        const KeyOpenUrl = 0x1000094;
        const KeyLaunchMail = 0x10000a0;
        const KeyLaunchMedia = 0x10000a1;
        const KeyLaunch0 = 0x10000a2;
        const KeyLaunch1 = 0x10000a3;
        const KeyLaunch2 = 0x10000a4;
        const KeyLaunch3 = 0x10000a5;
        const KeyLaunch4 = 0x10000a6;
        const KeyLaunch5 = 0x10000a7;
        const KeyLaunch6 = 0x10000a8;
        const KeyLaunch7 = 0x10000a9;
        const KeyLaunch8 = 0x10000aa;
        const KeyLaunch9 = 0x10000ab;
        const KeyLaunchA = 0x10000ac;
        const KeyLaunchB = 0x10000ad;
        const KeyLaunchC = 0x10000ae;
        const KeyLaunchD = 0x10000af;
        const KeyLaunchE = 0x10000b0;
        const KeyLaunchF = 0x10000b1;
        const KeyMonBrightnessUp = 0x10000b2;
        const KeyMonBrightnessDown = 0x10000b3;
        const KeyKeyboardLightOnOff = 0x10000b4;
        const KeyKeyboardBrightnessUp = 0x10000b5;
        const KeyKeyboardBrightnessDown = 0x10000b6;
        const KeyPowerOff = 0x10000b7;
        const KeyWakeUp = 0x10000b8;
        const KeyEject = 0x10000b9;
        const KeyScreenSaver = 0x10000ba;
        const KeyWww = 0x10000bb;
        const KeyMemo = 0x10000bc;
        const KeyLightBulb = 0x10000bd;
        const KeyShop = 0x10000be;
        const KeyHistory = 0x10000bf;
        const KeyAddFavorite = 0x10000c0;
        const KeyHotLinks = 0x10000c1;
        const KeyBrightnessAdjust = 0x10000c2;
        const KeyFinance = 0x10000c3;
        const KeyCommunity = 0x10000c4;
        const KeyAudioRewind = 0x10000c5;
        const KeyBackForward = 0x10000c6;
        const KeyApplicationLeft = 0x10000c7;
        const KeyApplicationRight = 0x10000c8;
        const KeyBook = 0x10000c9;
        const KeyCd = 0x10000ca;
        const KeyCalculator = 0x10000cb;
        const KeyToDoList = 0x10000cc;
        const KeyClearGrab = 0x10000cd;
        const KeyClose = 0x10000ce;
        const KeyCopy = 0x10000cf;
        const KeyCut = 0x10000d0;
        const KeyDisplay = 0x10000d1;
        const KeyDos = 0x10000d2;
        const KeyDocuments = 0x10000d3;
        const KeyExcel = 0x10000d4;
        const KeyExplorer = 0x10000d5;
        const KeyGame = 0x10000d6;
        const KeyGo = 0x10000d7;
        const KeyITouch = 0x10000d8;
        const KeyLogOff = 0x10000d9;
        const KeyMarket = 0x10000da;
        const KeyMeeting = 0x10000db;
        const KeyMenuKb = 0x10000dc;
        const KeyMenuPb = 0x10000dd;
        const KeyMySites = 0x10000de;
        const KeyNews = 0x10000df;
        const KeyOfficeHome = 0x10000e0;
        const KeyOption = 0x10000e1;
        const KeyPaste = 0x10000e2;
        const KeyPhone = 0x10000e3;
        const KeyCalendar = 0x10000e4;
        const KeyReply = 0x10000e5;
        const KeyReload = 0x10000e6;
        const KeyRotateWindows = 0x10000e7;
        const KeyRotationPb = 0x10000e8;
        const KeyRotationKb = 0x10000e9;
        const KeySave = 0x10000ea;
        const KeySend = 0x10000eb;
        const KeySpell = 0x10000ec;
        const KeySplitScreen = 0x10000ed;
        const KeySupport = 0x10000ee;
        const KeyTaskPane = 0x10000ef;
        const KeyTerminal = 0x10000f0;
        const KeyTools = 0x10000f1;
        const KeyTravel = 0x10000f2;
        const KeyVideo = 0x10000f3;
        const KeyWord = 0x10000f4;
        const KeyXfer = 0x10000f5;
        const KeyZoomIn = 0x10000f6;
        const KeyZoomOut = 0x10000f7;
        const KeyAway = 0x10000f8;
        const KeyMessenger = 0x10000f9;
        const KeyWebCam = 0x10000fa;
        const KeyMailForward = 0x10000fb;
        const KeyPictures = 0x10000fc;
        const KeyMusic = 0x10000fd;
        const KeyBattery = 0x10000fe;
        const KeyBluetooth = 0x10000ff;
        const KeyWlan = 0x1000100;
        const KeyUwb = 0x1000101;
        const KeyAudioForward = 0x1000102;
        const KeyAudioRepeat = 0x1000103;
        const KeyAudioRandomPlay = 0x1000104;
        const KeySubtitle = 0x1000105;
        const KeyAudioCycleTrack = 0x1000106;
        const KeyTime = 0x1000107;
        const KeyHibernate = 0x1000108;
        const KeyView = 0x1000109;
        const KeyTopMenu = 0x100010a;
        const KeyPowerDown = 0x100010b;
        const KeySuspend = 0x100010c;
        const KeyContrastAdjust = 0x100010d;
        const KeyLaunchG = 0x100010e;
        const KeyLaunchH = 0x100010f;
        const KeyTouchpadToggle = 0x1000110;
        const KeyTouchpadOn = 0x1000111;
        const KeyTouchpadOff = 0x1000112;
        const KeyMicMute = 0x1000113;
        const KeyRed = 0x1000114;
        const KeyGreen = 0x1000115;
        const KeyYellow = 0x1000116;
        const KeyBlue = 0x1000117;
        const KeyChannelUp = 0x1000118;
        const KeyChannelDown = 0x1000119;
        const KeyGuide = 0x100011a;
        const KeyInfo = 0x100011b;
        const KeySettings = 0x100011c;
        const KeyMicVolumeUp = 0x100011d;
        const KeyMicVolumeDown = 0x100011e;
        const KeyNew = 0x1000120;
        const KeyOpen = 0x1000121;
        const KeyFind = 0x1000122;
        const KeyUndo = 0x1000123;
        const KeyRedo = 0x1000124;
        const KeyMediaLast = 0x100ffff;
        const KeySelect = 0x1010000;
        const KeyYes = 0x1010001;
        const KeyNo = 0x1010002;
        const KeyCancel = 0x1020001;
        const KeyPrinter = 0x1020002;
        const KeyExecute = 0x1020003;
        const KeySleep = 0x1020004;
        const KeyPlay = 0x1020005;
        const KeyZoom = 0x1020006;
        const KeyExit = 0x102000a;
        const KeyContext1 = 0x1100000;
        const KeyContext2 = 0x1100001;
        const KeyContext3 = 0x1100002;
        const KeyContext4 = 0x1100003;
        const KeyCall = 0x1100004;
        const KeyHangup = 0x1100005;
        const KeyFlip = 0x1100006;
        const KeyToggleCallHangup = 0x1100007;
        const KeyVoiceDial = 0x1100008;
        const KeyLastNumberRedial = 0x1100009;
        const KeyCamera = 0x1100020;
        const KeyCameraFocus = 0x1100021;
        const KeyUnknown = 0x1ffffff;
    }
}

#[repr(u32)]
pub enum ArrowType {
    NoArrow = 0,
    UpArrow = 1,
    DownArrow = 2,
    LeftArrow = 3,
    RightArrow = 4,
}

#[repr(u32)]
pub enum PenStyle {
    NoPen = 0,
    SolidLine = 1,
    DashLine = 2,
    DotLine = 3,
    DashDotLine = 4,
    DashDotDotLine = 5,
    CustomDashLine = 6,
    MPenStyle = 15,
}

#[repr(u32)]
pub enum PenCapStyle {
    FlatCap = 0,
    SquareCap = 16,
    RoundCap = 32,
    MPenCapStyle = 48,
}

bitflags! {
    pub struct PenJoinStyle: u32 {
        const MiterJoin = 0x0;
        const BevelJoin = 0x40;
        const RoundJoin = 0x80;
        const SvgMiterJoin = 0x100;
        const MPenJoinStyle = 0x1c0;
    }
}

#[repr(u32)]
pub enum BrushStyle {
    NoBrush = 0,
    SolidPattern = 1,
    Dense1Pattern = 2,
    Dense2Pattern = 3,
    Dense3Pattern = 4,
    Dense4Pattern = 5,
    Dense5Pattern = 6,
    Dense6Pattern = 7,
    Dense7Pattern = 8,
    HorPattern = 9,
    VerPattern = 10,
    CrossPattern = 11,
    BDiagPattern = 12,
    FDiagPattern = 13,
    DiagCrossPattern = 14,
    LinearGradientPattern = 15,
    RadialGradientPattern = 16,
    ConicalGradientPattern = 17,
    TexturePattern = 24,
}

#[repr(u32)]
pub enum SizeMode {
    AbsoluteSize = 0,
    RelativeSize = 1,
}

#[repr(u32)]
pub enum UIEffect {
    UiGeneral = 0,
    UiAnimateMenu = 1,
    UiFadeMenu = 2,
    UiAnimateCombo = 3,
    UiAnimateTooltip = 4,
    UiFadeTooltip = 5,
    UiAnimateToolBox = 6,
}

bitflags! {
    pub struct CursorShape: u32 {
        const ArrowCursor = 0x0;
        const UpArrowCursor = 0x1;
        const CrossCursor = 0x2;
        const WaitCursor = 0x3;
        const IBeamCursor = 0x4;
        const SizeVerCursor = 0x5;
        const SizeHorCursor = 0x6;
        const SizeBDiagCursor = 0x7;
        const SizeFDiagCursor = 0x8;
        const SizeAllCursor = 0x9;
        const BlankCursor = 0xa;
        const SplitVCursor = 0xb;
        const SplitHCursor = 0xc;
        const PointingHandCursor = 0xd;
        const ForbiddenCursor = 0xe;
        const WhatsThisCursor = 0xf;
        const BusyCursor = 0x10;
        const OpenHandCursor = 0x11;
        const ClosedHandCursor = 0x12;
        const DragCopyCursor = 0x13;
        const DragMoveCursor = 0x14;
        const DragLinkCursor = 0x15;
        const LastCursor = 0x15;
        const BitmapCursor = 0x18;
        const CustomCursor = 0x19;
    }
}

#[repr(u32)]
pub enum TextFormat {
    PlainText = 0,
    RichText = 1,
    AutoText = 2,
}

#[repr(u32)]
pub enum AspectRatioMode {
    IgnoreAspectRatio = 0,
    KeepAspectRatio = 1,
    KeepAspectRatioByExpanding = 2,
}

bitflags! {
    pub struct DockWidgetArea: u32 {
        const LeftDockWidgetArea = 0x1;
        const RightDockWidgetArea = 0x2;
        const TopDockWidgetArea = 0x4;
        const BottomDockWidgetArea = 0x8;
        const DockWidgetAreaMask = 0xf;
        const AllDockWidgetAreas = 0xf;
        const NoDockWidgetArea = 0x0;
    }
}

#[repr(u32)]
pub enum DockWidgetAreaSizes {
    NDockWidgetAreas = 4,
}

bitflags! {
    pub struct ToolBarArea: u32 {
        const LeftToolBarArea = 0x1;
        const RightToolBarArea = 0x2;
        const TopToolBarArea = 0x4;
        const BottomToolBarArea = 0x8;
        const ToolBarAreaMask = 0xf;
        const AllToolBarAreas = 0xf;
        const NoToolBarArea = 0x0;
    }
}

#[repr(u32)]
pub enum ToolBarAreaSizes {
    NToolBarAreas = 4,
}

bitflags! {
    pub struct DateFormat: u32 {
        const TextDate = 0x0;
        const IsoDate = 0x1;
        const SystemLocaleDate = 0x2;
        const LocalDate = 0x2;
        const LocaleDate = 0x3;
        const SystemLocaleShortDate = 0x4;
        const SystemLocaleLongDate = 0x5;
        const DefaultLocaleShortDate = 0x6;
        const DefaultLocaleLongDate = 0x7;
        const IsoDateWithMs = 0x9;
    }
}

#[repr(u32)]
pub enum TimeSpec {
    LocalTime = 0,
    Utc = 1,
    OffsetFromUtc = 2,
    TimeZone = 3,
}

#[repr(u32)]
pub enum DayOfWeek {
    Monday = 1,
    Tuesday = 2,
    Wednesday = 3,
    Thursday = 4,
    Friday = 5,
    Saturday = 6,
    Sunday = 7,
}

#[repr(u32)]
pub enum ScrollBarPolicy {
    ScrollBarAsNeeded = 0,
    ScrollBarAlwaysOff = 1,
    ScrollBarAlwaysOn = 2,
}

#[repr(u32)]
pub enum CaseSensitivity {
    CaseInsensitive = 0,
    CaseSensitive = 1,
}

#[repr(u32)]
pub enum Corner {
    TopLeftCorner = 0,
    TopRightCorner = 1,
    BottomLeftCorner = 2,
    BottomRightCorner = 3,
}

bitflags! {
    pub struct Edge: u32 {
        const TopEdge = 0x1;
        const LeftEdge = 0x2;
        const RightEdge = 0x4;
        const BottomEdge = 0x8;
    }
}

bitflags! {
    pub struct ConnectionType: u32 {
        const AutoConnection = 0x0;
        const DirectConnection = 0x1;
        const QueuedConnection = 0x2;
        const BlockingQueuedConnection = 0x3;
        const UniqueConnection = 0x80;
    }
}

#[repr(u32)]
pub enum ShortcutContext {
    WidgetShortcut = 0,
    WindowShortcut = 1,
    ApplicationShortcut = 2,
    WidgetWithChildrenShortcut = 3,
}

#[repr(u32)]
pub enum FillRule {
    OddEvenFill = 0,
    WindingFill = 1,
}

#[repr(u32)]
pub enum MaskMode {
    MaskInColor = 0,
    MaskOutColor = 1,
}

#[repr(u32)]
pub enum ClipOperation {
    NoClip = 0,
    ReplaceClip = 1,
    IntersectClip = 2,
}

#[repr(u32)]
pub enum ItemSelectionMode {
    ContainsItemShape = 0,
    IntersectsItemShape = 1,
    ContainsItemBoundingRect = 2,
    IntersectsItemBoundingRect = 3,
}

#[repr(u32)]
pub enum ItemSelectionOperation {
    ReplaceSelection = 0,
    AddToSelection = 1,
}

#[repr(u32)]
pub enum TransformationMode {
    FastTransformation = 0,
    SmoothTransformation = 1,
}

#[repr(u32)]
pub enum Axis {
    XAxis = 0,
    YAxis = 1,
    ZAxis = 2,
}

#[repr(u32)]
pub enum FocusReason {
    MouseFocusReason = 0,
    TabFocusReason = 1,
    BacktabFocusReason = 2,
    ActiveWindowFocusReason = 3,
    PopupFocusReason = 4,
    ShortcutFocusReason = 5,
    MenuBarFocusReason = 6,
    OtherFocusReason = 7,
    NoFocusReason = 8,
}

#[repr(u32)]
pub enum ContextMenuPolicy {
    NoContextMenu = 0,
    DefaultContextMenu = 1,
    ActionsContextMenu = 2,
    CustomContextMenu = 3,
    PreventContextMenu = 4,
}

bitflags! {
    pub struct InputMethodQuery: u32 {
        const ImEnabled = 0x1;
        const ImCursorRectangle = 0x2;
        const ImMicroFocus = 0x2;
        const ImFont = 0x4;
        const ImCursorPosition = 0x8;
        const ImSurroundingText = 0x10;
        const ImCurrentSelection = 0x20;
        const ImMaximumTextLength = 0x40;
        const ImAnchorPosition = 0x80;
        const ImHints = 0x100;
        const ImPreferredLanguage = 0x200;
        const ImAbsolutePosition = 0x400;
        const ImTextBeforeCursor = 0x800;
        const ImTextAfterCursor = 0x1000;
        const ImEnterKeyType = 0x2000;
        const ImAnchorRectangle = 0x4000;
        const ImInputItemClipRectangle = 0x8000;
        const ImPlatformData = 0x80000000;
        const ImQueryInput = 0x40ba;
        const ImQueryAll = 0xffffffff;
    }
}

bitflags! {
    pub struct InputMethodHint: u32 {
        const ImhNone = 0x0;
        const ImhHiddenText = 0x1;
        const ImhSensitiveData = 0x2;
        const ImhNoAutoUppercase = 0x4;
        const ImhPreferNumbers = 0x8;
        const ImhPreferUppercase = 0x10;
        const ImhPreferLowercase = 0x20;
        const ImhNoPredictiveText = 0x40;
        const ImhDate = 0x80;
        const ImhTime = 0x100;
        const ImhPreferLatin = 0x200;
        const ImhMultiLine = 0x400;
        const ImhNoEditMenu = 0x800;
        const ImhNoTextHandles = 0x1000;
        const ImhDigitsOnly = 0x10000;
        const ImhFormattedNumbersOnly = 0x20000;
        const ImhUppercaseOnly = 0x40000;
        const ImhLowercaseOnly = 0x80000;
        const ImhDialableCharactersOnly = 0x100000;
        const ImhEmailCharactersOnly = 0x200000;
        const ImhUrlCharactersOnly = 0x400000;
        const ImhLatinOnly = 0x800000;
        const ImhExclusiveInputMask = 0xffff0000;
    }
}

pub type InputMethodHints = InputMethodHint;

#[repr(u32)]
pub enum EnterKeyType {
    EnterKeyDefault = 0,
    EnterKeyReturn = 1,
    EnterKeyDone = 2,
    EnterKeyGo = 3,
    EnterKeySend = 4,
    EnterKeySearch = 5,
    EnterKeyNext = 6,
    EnterKeyPrevious = 7,
}

#[repr(u32)]
pub enum ToolButtonStyle {
    ToolButtonIconOnly = 0,
    ToolButtonTextOnly = 1,
    ToolButtonTextBesideIcon = 2,
    ToolButtonTextUnderIcon = 3,
    ToolButtonFollowStyle = 4,
}

#[repr(u32)]
pub enum LayoutDirection {
    LeftToRight = 0,
    RightToLeft = 1,
    LayoutDirectionAuto = 2,
}

#[repr(u32)]
pub enum AnchorPoint {
    AnchorLeft = 0,
    AnchorHorizontalCenter = 1,
    AnchorRight = 2,
    AnchorTop = 3,
    AnchorVerticalCenter = 4,
    AnchorBottom = 5,
}

#[repr(u32)]
pub enum FindChildOption {
    FindDirectChildrenOnly = 0,
    FindChildrenRecursively = 1,
}

bitflags! {
    pub struct FindChildOptions: u32 {
        const FindDirectChildrenOnly = FindChildOption::FindDirectChildrenOnly as u32;
        const FindChildrenRecursively = FindChildOption::FindChildrenRecursively as u32;
    }
}
#[repr(u32)]
pub enum DropAction {
    CopyAction = 1,
    MoveAction = 2,
    LinkAction = 4,
    ActionMask = 255,
    TargetMoveAction = 32770,
    IgnoreAction = 0,
}

bitflags! {
    pub struct DropActions: u32 {
        const CopyAction = DropAction::CopyAction as u32;
        const MoveAction = DropAction::MoveAction as u32;
        const LinkAction = DropAction::LinkAction as u32;
        const ActionMask = DropAction::ActionMask as u32;
        const TargetMoveAction = DropAction::TargetMoveAction as u32;
        const IgnoreAction = DropAction::IgnoreAction as u32;
    }
}
#[repr(u32)]
pub enum CheckState {
    Unchecked = 0,
    PartiallyChecked = 1,
    Checked = 2,
}

bitflags! {
    pub struct ItemDataRole: u32 {
        const DisplayRole = 0x0;
        const DecorationRole = 0x1;
        const EditRole = 0x2;
        const ToolTipRole = 0x3;
        const StatusTipRole = 0x4;
        const WhatsThisRole = 0x5;
        const FontRole = 0x6;
        const TextAlignmentRole = 0x7;
        const BackgroundColorRole = 0x8;
        const BackgroundRole = 0x8;
        const TextColorRole = 0x9;
        const ForegroundRole = 0x9;
        const CheckStateRole = 0xa;
        const AccessibleTextRole = 0xb;
        const AccessibleDescriptionRole = 0xc;
        const SizeHintRole = 0xd;
        const InitialSortOrderRole = 0xe;
        const DisplayPropertyRole = 0x1b;
        const DecorationPropertyRole = 0x1c;
        const ToolTipPropertyRole = 0x1d;
        const StatusTipPropertyRole = 0x1e;
        const WhatsThisPropertyRole = 0x1f;
        const UserRole = 0x100;
    }
}

bitflags! {
    pub struct ItemFlag: u32 {
        const NoItemFlags = 0x0;
        const ItemIsSelectable = 0x1;
        const ItemIsEditable = 0x2;
        const ItemIsDragEnabled = 0x4;
        const ItemIsDropEnabled = 0x8;
        const ItemIsUserCheckable = 0x10;
        const ItemIsEnabled = 0x20;
        const ItemIsAutoTristate = 0x40;
        const ItemIsTristate = 0x40;
        const ItemNeverHasChildren = 0x80;
        const ItemIsUserTristate = 0x100;
    }
}

pub type ItemFlags = ItemFlag;

bitflags! {
    pub struct MatchFlag: u32 {
        const MatchExactly = 0x0;
        const MatchContains = 0x1;
        const MatchStartsWith = 0x2;
        const MatchEndsWith = 0x3;
        const MatchRegExp = 0x4;
        const MatchWildcard = 0x5;
        const MatchFixedString = 0x8;
        const MatchCaseSensitive = 0x10;
        const MatchWrap = 0x20;
        const MatchRecursive = 0x40;
    }
}

#[repr(u32)]
pub enum WindowModality {
    NonModal = 0,
    WindowModal = 1,
    ApplicationModal = 2,
}

bitflags! {
    pub struct TextInteractionFlag: u32 {
        const NoTextInteraction = 0x0;
        const TextSelectableByMouse = 0x1;
        const TextSelectableByKeyboard = 0x2;
        const LinksAccessibleByMouse = 0x4;
        const LinksAccessibleByKeyboard = 0x8;
        const TextEditable = 0x10;
        const TextEditorInteraction = 0x13;
        const TextBrowserInteraction = 0xd;
    }
}

#[repr(u32)]
pub enum EventPriority {
    HighEventPriority = 1,
    NormalEventPriority = 0,
    LowEventPriority = 4294967295,
}

#[repr(u32)]
pub enum SizeHint {
    MinimumSize = 0,
    PreferredSize = 1,
    MaximumSize = 2,
    MinimumDescent = 3,
    NSizeHints = 4,
}

#[repr(u32)]
pub enum WindowFrameSection {
    NoSection = 0,
    LeftSection = 1,
    TopLeftSection = 2,
    TopSection = 3,
    TopRightSection = 4,
    RightSection = 5,
    BottomRightSection = 6,
    BottomSection = 7,
    BottomLeftSection = 8,
    TitleBarArea = 9,
}

#[repr(u32)]
pub enum Initialization {
    Uninitialized = 0,
}

#[repr(u32)]
pub enum CoordinateSystem {
    DeviceCoordinates = 0,
    LogicalCoordinates = 1,
}

bitflags! {
    pub struct TouchPointState: u32 {
        const TouchPointPressed = 0x1;
        const TouchPointMoved = 0x2;
        const TouchPointStationary = 0x4;
        const TouchPointReleased = 0x8;
    }
}

pub type TouchPointStates = TouchPointState;

#[repr(u32)]
pub enum GestureState {
    NoGesture = 0,
    GestureStarted = 1,
    GestureUpdated = 2,
    GestureFinished = 3,
    GestureCanceled = 4,
}

bitflags! {
    pub struct GestureType: u32 {
        const TapGesture = 0x1;
        const TapAndHoldGesture = 0x2;
        const PanGesture = 0x3;
        const PinchGesture = 0x4;
        const SwipeGesture = 0x5;
        const CustomGesture = 0x100;
        const LastGestureType = 0xffffffff;
    }
}

bitflags! {
    pub struct GestureFlag: u32 {
        const DontStartGestureOnChildren = 0x1;
        const ReceivePartialGestures = 0x2;
        const IgnoredGesturesPropagateToParent = 0x4;
    }
}

pub type GestureFlags = GestureFlag;

#[repr(u32)]
pub enum NativeGestureType {
    BeginNativeGesture = 0,
    EndNativeGesture = 1,
    PanNativeGesture = 2,
    ZoomNativeGesture = 3,
    SmartZoomNativeGesture = 4,
    RotateNativeGesture = 5,
    SwipeNativeGesture = 6,
}

#[repr(u32)]
pub enum NavigationMode {
    NavigationModeNone = 0,
    NavigationModeKeypadTabOrder = 1,
    NavigationModeKeypadDirectional = 2,
    NavigationModeCursorAuto = 3,
    NavigationModeCursorForceVisible = 4,
}

#[repr(u32)]
pub enum CursorMoveStyle {
    LogicalMoveStyle = 0,
    VisualMoveStyle = 1,
}

#[repr(u32)]
pub enum TimerType {
    PreciseTimer = 0,
    CoarseTimer = 1,
    VeryCoarseTimer = 2,
}

#[repr(u32)]
pub enum ScrollPhase {
    NoScrollPhase = 0,
    ScrollBegin = 1,
    ScrollUpdate = 2,
    ScrollEnd = 3,
}

#[repr(u32)]
pub enum MouseEventSource {
    MouseEventNotSynthesized = 0,
    MouseEventSynthesizedBySystem = 1,
    MouseEventSynthesizedByQt = 2,
    MouseEventSynthesizedByApplication = 3,
}

#[repr(u32)]
pub enum MouseEventFlag {
    MouseEventCreatedDoubleClick = 1,
    MouseEventFlagMask = 255,
}

bitflags! {
    pub struct MouseEventFlags: u32 {
        const MouseEventCreatedDoubleClick = MouseEventFlag::MouseEventCreatedDoubleClick as u32;
        const MouseEventFlagMask = MouseEventFlag::MouseEventFlagMask as u32;
    }
}
#[repr(u32)]
pub enum ChecksumType {
    ChecksumIso3309 = 0,
    ChecksumItuV41 = 1,
}