1/****************************************************************************
2**
3** Copyright (C) 2020 The Qt Company Ltd.
4** Contact: https://www.qt.io/licensing/
5**
6** This file is part of the QtCore module of the Qt Toolkit.
7**
8** $QT_BEGIN_LICENSE:LGPL$
9** Commercial License Usage
10** Licensees holding valid commercial Qt licenses may use this file in
11** accordance with the commercial license agreement provided with the
12** Software or, alternatively, in accordance with the terms contained in
13** a written agreement between you and The Qt Company. For licensing terms
14** and conditions see https://www.qt.io/terms-conditions. For further
15** information use the contact form at https://www.qt.io/contact-us.
16**
17** GNU Lesser General Public License Usage
18** Alternatively, this file may be used under the terms of the GNU Lesser
19** General Public License version 3 as published by the Free Software
20** Foundation and appearing in the file LICENSE.LGPL3 included in the
21** packaging of this file. Please review the following information to
22** ensure the GNU Lesser General Public License version 3 requirements
23** will be met: https://www.gnu.org/licenses/lgpl-3.0.html.
24**
25** GNU General Public License Usage
26** Alternatively, this file may be used under the terms of the GNU
27** General Public License version 2.0 or (at your option) the GNU General
28** Public license version 3 or any later version approved by the KDE Free
29** Qt Foundation. The licenses are as published by the Free Software
30** Foundation and appearing in the file LICENSE.GPL2 and LICENSE.GPL3
31** included in the packaging of this file. Please review the following
32** information to ensure the GNU General Public License requirements will
33** be met: https://www.gnu.org/licenses/gpl-2.0.html and
34** https://www.gnu.org/licenses/gpl-3.0.html.
35**
36** $QT_END_LICENSE$
37**
38****************************************************************************/
39
40#ifndef QNAMESPACE_H
41#define QNAMESPACE_H
42
43#include <QtCore/qglobal.h>
44
45#if defined(__OBJC__) && !defined(__cplusplus)
46# warning "File built in Objective-C mode (.m), but using Qt requires Objective-C++ (.mm)"
47#endif
48
49QT_BEGIN_NAMESPACE
50
51#if !defined(Q_QDOC) && !defined(Q_MOC_RUN)
52struct QMetaObject;
53const QMetaObject *qt_getQtMetaObject() noexcept; // defined in qobject.h (which can't be included here)
54#define QT_Q_ENUM(ENUM) \
55 inline const QMetaObject *qt_getEnumMetaObject(ENUM) noexcept { return qt_getQtMetaObject(); } \
56 inline Q_DECL_CONSTEXPR const char *qt_getEnumName(ENUM) noexcept { return #ENUM; }
57#define QT_Q_FLAG(ENUM) QT_Q_ENUM(ENUM)
58#else
59#define QT_Q_ENUM Q_ENUM
60#define QT_Q_FLAG Q_FLAG
61#endif
62
63#ifndef Q_MOC_RUN
64namespace
65#else
66class Q_CORE_EXPORT
67#endif
68Qt {
69
70#if defined(Q_MOC_RUN)
71 Q_OBJECT
72public:
73#endif
74
75 enum GlobalColor {
76 color0,
77 color1,
78 black,
79 white,
80 darkGray,
81 gray,
82 lightGray,
83 red,
84 green,
85 blue,
86 cyan,
87 magenta,
88 yellow,
89 darkRed,
90 darkGreen,
91 darkBlue,
92 darkCyan,
93 darkMagenta,
94 darkYellow,
95 transparent
96 };
97
98 enum KeyboardModifier {
99 NoModifier = 0x00000000,
100 ShiftModifier = 0x02000000,
101 ControlModifier = 0x04000000,
102 AltModifier = 0x08000000,
103 MetaModifier = 0x10000000,
104 KeypadModifier = 0x20000000,
105 GroupSwitchModifier = 0x40000000,
106 // Do not extend the mask to include 0x01000000
107 KeyboardModifierMask = 0xfe000000
108 };
109 Q_DECLARE_FLAGS(KeyboardModifiers, KeyboardModifier)
110 Q_DECLARE_OPERATORS_FOR_FLAGS(KeyboardModifiers)
111
112 //shorter names for shortcuts
113 // The use of all-caps identifiers has the potential for clashing with
114 // user-defined or third-party macros. More so when the identifiers are not
115 // "namespace"-prefixed. This is considered bad practice and is why
116 // KeypadModifier was not added to the Modifier enum.
117 enum Modifier {
118 META = Qt::MetaModifier,
119 SHIFT = Qt::ShiftModifier,
120 CTRL = Qt::ControlModifier,
121 ALT = Qt::AltModifier,
122 MODIFIER_MASK = KeyboardModifierMask,
123 UNICODE_ACCEL = 0x00000000
124 };
125
126 enum MouseButton {
127 NoButton = 0x00000000,
128 LeftButton = 0x00000001,
129 RightButton = 0x00000002,
130 MiddleButton = 0x00000004,
131#if QT_DEPRECATED_SINCE(5, 15) // commented as such since 4.7.0
132 MidButton Q_DECL_ENUMERATOR_DEPRECATED_X("MidButton is deprecated. Use MiddleButton instead") = MiddleButton,
133#endif
134 BackButton = 0x00000008,
135 XButton1 = BackButton,
136 ExtraButton1 = XButton1,
137 ForwardButton = 0x00000010,
138 XButton2 = ForwardButton,
139 ExtraButton2 = ForwardButton,
140 TaskButton = 0x00000020,
141 ExtraButton3 = TaskButton,
142 ExtraButton4 = 0x00000040,
143 ExtraButton5 = 0x00000080,
144 ExtraButton6 = 0x00000100,
145 ExtraButton7 = 0x00000200,
146 ExtraButton8 = 0x00000400,
147 ExtraButton9 = 0x00000800,
148 ExtraButton10 = 0x00001000,
149 ExtraButton11 = 0x00002000,
150 ExtraButton12 = 0x00004000,
151 ExtraButton13 = 0x00008000,
152 ExtraButton14 = 0x00010000,
153 ExtraButton15 = 0x00020000,
154 ExtraButton16 = 0x00040000,
155 ExtraButton17 = 0x00080000,
156 ExtraButton18 = 0x00100000,
157 ExtraButton19 = 0x00200000,
158 ExtraButton20 = 0x00400000,
159 ExtraButton21 = 0x00800000,
160 ExtraButton22 = 0x01000000,
161 ExtraButton23 = 0x02000000,
162 ExtraButton24 = 0x04000000,
163 AllButtons = 0x07ffffff,
164 MaxMouseButton = ExtraButton24,
165 // 4 high-order bits remain available for future use (0x08000000 through 0x40000000).
166 MouseButtonMask = 0xffffffff
167 };
168 Q_DECLARE_FLAGS(MouseButtons, MouseButton)
169 Q_DECLARE_OPERATORS_FOR_FLAGS(MouseButtons)
170
171 enum Orientation {
172 Horizontal = 0x1,
173 Vertical = 0x2
174 };
175
176 Q_DECLARE_FLAGS(Orientations, Orientation)
177 Q_DECLARE_OPERATORS_FOR_FLAGS(Orientations)
178
179 enum FocusPolicy {
180 NoFocus = 0,
181 TabFocus = 0x1,
182 ClickFocus = 0x2,
183 StrongFocus = TabFocus | ClickFocus | 0x8,
184 WheelFocus = StrongFocus | 0x4
185 };
186
187 enum TabFocusBehavior {
188 NoTabFocus = 0x00,
189 TabFocusTextControls = 0x01,
190 TabFocusListControls = 0x02,
191 TabFocusAllControls = 0xff
192 };
193
194 enum SortOrder {
195 AscendingOrder,
196 DescendingOrder
197 };
198
199 enum SplitBehaviorFlags {
200 KeepEmptyParts = 0,
201 SkipEmptyParts = 0x1,
202 };
203 Q_DECLARE_FLAGS(SplitBehavior, SplitBehaviorFlags)
204 Q_DECLARE_OPERATORS_FOR_FLAGS(SplitBehavior)
205
206 enum TileRule {
207 StretchTile,
208 RepeatTile,
209 RoundTile
210 };
211
212 // Text formatting flags for QPainter::drawText and QLabel.
213 // The following two enums can be combined to one integer which
214 // is passed as 'flags' to QPainter::drawText, QFontMetrics::boundingRect and qt_format_text.
215
216 enum AlignmentFlag {
217 AlignLeft = 0x0001,
218 AlignLeading = AlignLeft,
219 AlignRight = 0x0002,
220 AlignTrailing = AlignRight,
221 AlignHCenter = 0x0004,
222 AlignJustify = 0x0008,
223 AlignAbsolute = 0x0010,
224 AlignHorizontal_Mask = AlignLeft | AlignRight | AlignHCenter | AlignJustify | AlignAbsolute,
225
226 AlignTop = 0x0020,
227 AlignBottom = 0x0040,
228 AlignVCenter = 0x0080,
229 AlignBaseline = 0x0100,
230 // Note that 0x100 will clash with Qt::TextSingleLine = 0x100 due to what the comment above
231 // this enum declaration states. However, since Qt::AlignBaseline is only used by layouts,
232 // it doesn't make sense to pass Qt::AlignBaseline to QPainter::drawText(), so there
233 // shouldn't really be any ambiguity between the two overlapping enum values.
234 AlignVertical_Mask = AlignTop | AlignBottom | AlignVCenter | AlignBaseline,
235
236 AlignCenter = AlignVCenter | AlignHCenter
237 };
238
239 Q_DECLARE_FLAGS(Alignment, AlignmentFlag)
240 Q_DECLARE_OPERATORS_FOR_FLAGS(Alignment)
241
242 enum TextFlag {
243 TextSingleLine = 0x0100,
244 TextDontClip = 0x0200,
245 TextExpandTabs = 0x0400,
246 TextShowMnemonic = 0x0800,
247 TextWordWrap = 0x1000,
248 TextWrapAnywhere = 0x2000,
249 TextDontPrint = 0x4000,
250 TextIncludeTrailingSpaces = 0x08000000,
251 TextHideMnemonic = 0x8000,
252 TextJustificationForced = 0x10000,
253 TextForceLeftToRight = 0x20000,
254 TextForceRightToLeft = 0x40000,
255 // Ensures that the longest variant is always used when computing the
256 // size of a multi-variant string.
257 TextLongestVariant = 0x80000
258
259#if QT_DEPRECATED_SINCE(5, 11) && QT_VERSION < QT_VERSION_CHECK(6, 0, 0)
260 , TextBypassShaping = 0x100000
261#endif
262 };
263
264 enum TextElideMode {
265 ElideLeft,
266 ElideRight,
267 ElideMiddle,
268 ElideNone
269 };
270
271 enum WhiteSpaceMode {
272 WhiteSpaceNormal,
273 WhiteSpacePre,
274 WhiteSpaceNoWrap,
275 WhiteSpaceModeUndefined = -1
276 };
277
278 enum HitTestAccuracy { ExactHit, FuzzyHit };
279
280 enum WindowType {
281 Widget = 0x00000000,
282 Window = 0x00000001,
283 Dialog = 0x00000002 | Window,
284 Sheet = 0x00000004 | Window,
285 Drawer = Sheet | Dialog,
286 Popup = 0x00000008 | Window,
287 Tool = Popup | Dialog,
288 ToolTip = Popup | Sheet,
289 SplashScreen = ToolTip | Dialog,
290 Desktop = 0x00000010 | Window,
291 SubWindow = 0x00000012,
292 ForeignWindow = 0x00000020 | Window,
293 CoverWindow = 0x00000040 | Window,
294
295 WindowType_Mask = 0x000000ff,
296 MSWindowsFixedSizeDialogHint = 0x00000100,
297 MSWindowsOwnDC = 0x00000200,
298 BypassWindowManagerHint = 0x00000400,
299 X11BypassWindowManagerHint = BypassWindowManagerHint,
300 FramelessWindowHint = 0x00000800,
301 WindowTitleHint = 0x00001000,
302 WindowSystemMenuHint = 0x00002000,
303 WindowMinimizeButtonHint = 0x00004000,
304 WindowMaximizeButtonHint = 0x00008000,
305 WindowMinMaxButtonsHint = WindowMinimizeButtonHint | WindowMaximizeButtonHint,
306 WindowContextHelpButtonHint = 0x00010000,
307 WindowShadeButtonHint = 0x00020000,
308 WindowStaysOnTopHint = 0x00040000,
309 WindowTransparentForInput = 0x00080000,
310 WindowOverridesSystemGestures = 0x00100000,
311 WindowDoesNotAcceptFocus = 0x00200000,
312 MaximizeUsingFullscreenGeometryHint = 0x00400000,
313
314 CustomizeWindowHint = 0x02000000,
315 WindowStaysOnBottomHint = 0x04000000,
316 WindowCloseButtonHint = 0x08000000,
317 MacWindowToolBarButtonHint = 0x10000000,
318 BypassGraphicsProxyWidget = 0x20000000,
319 NoDropShadowWindowHint = 0x40000000,
320 WindowFullscreenButtonHint = 0x80000000
321 };
322
323 Q_DECLARE_FLAGS(WindowFlags, WindowType)
324 Q_DECLARE_OPERATORS_FOR_FLAGS(WindowFlags)
325
326 enum WindowState {
327 WindowNoState = 0x00000000,
328 WindowMinimized = 0x00000001,
329 WindowMaximized = 0x00000002,
330 WindowFullScreen = 0x00000004,
331 WindowActive = 0x00000008
332 };
333
334 Q_DECLARE_FLAGS(WindowStates, WindowState)
335 Q_DECLARE_OPERATORS_FOR_FLAGS(WindowStates)
336
337 enum ApplicationState {
338 ApplicationSuspended = 0x00000000,
339 ApplicationHidden = 0x00000001,
340 ApplicationInactive = 0x00000002,
341 ApplicationActive = 0x00000004
342 };
343
344 Q_DECLARE_FLAGS(ApplicationStates, ApplicationState)
345
346 enum ScreenOrientation {
347 PrimaryOrientation = 0x00000000,
348 PortraitOrientation = 0x00000001,
349 LandscapeOrientation = 0x00000002,
350 InvertedPortraitOrientation = 0x00000004,
351 InvertedLandscapeOrientation = 0x00000008
352 };
353
354 Q_DECLARE_FLAGS(ScreenOrientations, ScreenOrientation)
355 Q_DECLARE_OPERATORS_FOR_FLAGS(ScreenOrientations)
356
357 enum WidgetAttribute {
358 WA_Disabled = 0,
359 WA_UnderMouse = 1,
360 WA_MouseTracking = 2,
361#if QT_DEPRECATED_SINCE(5, 15) // commented as such since 4.5.1
362 WA_ContentsPropagated Q_DECL_ENUMERATOR_DEPRECATED = 3,
363#endif
364 WA_OpaquePaintEvent = 4,
365#if QT_DEPRECATED_SINCE(5, 14)
366 WA_NoBackground Q_DECL_ENUMERATOR_DEPRECATED = WA_OpaquePaintEvent,
367#endif
368 WA_StaticContents = 5,
369 WA_LaidOut = 7,
370 WA_PaintOnScreen = 8,
371 WA_NoSystemBackground = 9,
372 WA_UpdatesDisabled = 10,
373 WA_Mapped = 11,
374#if QT_DEPRECATED_SINCE(5, 14)
375 WA_MacNoClickThrough Q_DECL_ENUMERATOR_DEPRECATED = 12,
376#endif
377 WA_InputMethodEnabled = 14,
378 WA_WState_Visible = 15,
379 WA_WState_Hidden = 16,
380
381 WA_ForceDisabled = 32,
382 WA_KeyCompression = 33,
383 WA_PendingMoveEvent = 34,
384 WA_PendingResizeEvent = 35,
385 WA_SetPalette = 36,
386 WA_SetFont = 37,
387 WA_SetCursor = 38,
388 WA_NoChildEventsFromChildren = 39,
389 WA_WindowModified = 41,
390 WA_Resized = 42,
391 WA_Moved = 43,
392 WA_PendingUpdate = 44,
393 WA_InvalidSize = 45,
394#if QT_DEPRECATED_SINCE(5, 14)
395 WA_MacBrushedMetal Q_DECL_ENUMERATOR_DEPRECATED = 46,
396 WA_MacMetalStyle Q_DECL_ENUMERATOR_DEPRECATED = 46,
397#endif
398 WA_CustomWhatsThis = 47,
399 WA_LayoutOnEntireRect = 48,
400 WA_OutsideWSRange = 49,
401 WA_GrabbedShortcut = 50,
402 WA_TransparentForMouseEvents = 51,
403 WA_PaintUnclipped = 52,
404 WA_SetWindowIcon = 53,
405 WA_NoMouseReplay = 54,
406 WA_DeleteOnClose = 55,
407 WA_RightToLeft = 56,
408 WA_SetLayoutDirection = 57,
409 WA_NoChildEventsForParent = 58,
410 WA_ForceUpdatesDisabled = 59,
411
412 WA_WState_Created = 60,
413 WA_WState_CompressKeys = 61,
414 WA_WState_InPaintEvent = 62,
415 WA_WState_Reparented = 63,
416 WA_WState_ConfigPending = 64,
417 WA_WState_Polished = 66,
418#if QT_DEPRECATED_SINCE(5, 15) // commented as such in 4.5.1
419 WA_WState_DND Q_DECL_ENUMERATOR_DEPRECATED = 67,
420#endif
421 WA_WState_OwnSizePolicy = 68,
422 WA_WState_ExplicitShowHide = 69,
423
424 WA_ShowModal = 70, // ## deprecated since since 4.5.1 but still in use :-(
425 WA_MouseNoMask = 71,
426 WA_GroupLeader = 72, // ## deprecated since since 4.5.1 but still in use :-(
427 WA_NoMousePropagation = 73, // for now, might go away.
428 WA_Hover = 74,
429 WA_InputMethodTransparent = 75, // Don't reset IM when user clicks on this (for virtual keyboards on embedded)
430 WA_QuitOnClose = 76,
431
432 WA_KeyboardFocusChange = 77,
433
434 WA_AcceptDrops = 78,
435 WA_DropSiteRegistered = 79, // internal
436#if QT_DEPRECATED_SINCE(5, 15) // commented as such since 4.5.1
437 WA_ForceAcceptDrops Q_DECL_ENUMERATOR_DEPRECATED_X("WA_ForceAcceptDrops is deprecated. Use WA_DropSiteRegistered instead") = WA_DropSiteRegistered,
438#endif
439
440 WA_WindowPropagation = 80,
441
442 WA_NoX11EventCompression = 81,
443 WA_TintedBackground = 82,
444 WA_X11OpenGLOverlay = 83,
445 WA_AlwaysShowToolTips = 84,
446 WA_MacOpaqueSizeGrip = 85,
447 WA_SetStyle = 86,
448
449 WA_SetLocale = 87,
450 WA_MacShowFocusRect = 88,
451
452 WA_MacNormalSize = 89, // Mac only
453 WA_MacSmallSize = 90, // Mac only
454 WA_MacMiniSize = 91, // Mac only
455
456 WA_LayoutUsesWidgetRect = 92,
457 WA_StyledBackground = 93, // internal
458#if QT_DEPRECATED_SINCE(5, 14)
459 WA_MSWindowsUseDirect3D Q_DECL_ENUMERATOR_DEPRECATED = 94,
460#endif
461 WA_CanHostQMdiSubWindowTitleBar = 95, // Internal
462
463 WA_MacAlwaysShowToolWindow = 96, // Mac only
464
465 WA_StyleSheet = 97, // internal
466
467 WA_ShowWithoutActivating = 98,
468
469 WA_X11BypassTransientForHint = 99,
470
471 WA_NativeWindow = 100,
472 WA_DontCreateNativeAncestors = 101,
473
474 WA_MacVariableSize = 102, // Mac only
475
476 WA_DontShowOnScreen = 103,
477
478 // window types from http://standards.freedesktop.org/wm-spec/
479 WA_X11NetWmWindowTypeDesktop = 104,
480 WA_X11NetWmWindowTypeDock = 105,
481 WA_X11NetWmWindowTypeToolBar = 106,
482 WA_X11NetWmWindowTypeMenu = 107,
483 WA_X11NetWmWindowTypeUtility = 108,
484 WA_X11NetWmWindowTypeSplash = 109,
485 WA_X11NetWmWindowTypeDialog = 110,
486 WA_X11NetWmWindowTypeDropDownMenu = 111,
487 WA_X11NetWmWindowTypePopupMenu = 112,
488 WA_X11NetWmWindowTypeToolTip = 113,
489 WA_X11NetWmWindowTypeNotification = 114,
490 WA_X11NetWmWindowTypeCombo = 115,
491 WA_X11NetWmWindowTypeDND = 116,
492#if QT_DEPRECATED_SINCE(5, 14)
493 WA_MacFrameworkScaled Q_DECL_ENUMERATOR_DEPRECATED = 117,
494#endif
495 WA_SetWindowModality = 118,
496 WA_WState_WindowOpacitySet = 119, // internal
497 WA_TranslucentBackground = 120,
498
499 WA_AcceptTouchEvents = 121,
500 WA_WState_AcceptedTouchBeginEvent = 122,
501 WA_TouchPadAcceptSingleTouchEvents = 123,
502
503 WA_X11DoNotAcceptFocus = 126,
504 WA_MacNoShadow = 127,
505
506 WA_AlwaysStackOnTop = 128,
507
508 WA_TabletTracking = 129,
509
510 WA_ContentsMarginsRespectsSafeArea = 130,
511
512 WA_StyleSheetTarget = 131,
513
514 // Add new attributes before this line
515 WA_AttributeCount
516 };
517
518 enum ApplicationAttribute
519 {
520 AA_ImmediateWidgetCreation = 0,
521#if QT_DEPRECATED_SINCE(5, 14)
522 AA_MSWindowsUseDirect3DByDefault Q_DECL_ENUMERATOR_DEPRECATED = 1,
523#endif
524 AA_DontShowIconsInMenus = 2,
525 AA_NativeWindows = 3,
526 AA_DontCreateNativeWidgetSiblings = 4,
527 AA_PluginApplication = 5,
528#if QT_DEPRECATED_SINCE(5, 13) // ### Qt 6: remove me
529 AA_MacPluginApplication Q_DECL_ENUMERATOR_DEPRECATED = AA_PluginApplication,
530#endif
531 AA_DontUseNativeMenuBar = 6,
532 AA_MacDontSwapCtrlAndMeta = 7,
533 AA_Use96Dpi = 8,
534 AA_DisableNativeVirtualKeyboard = 9,
535#if QT_DEPRECATED_SINCE(5, 14)
536 AA_X11InitThreads Q_DECL_ENUMERATOR_DEPRECATED = 10,
537#endif
538 AA_SynthesizeTouchForUnhandledMouseEvents = 11,
539 AA_SynthesizeMouseForUnhandledTouchEvents = 12,
540 AA_UseHighDpiPixmaps = 13,
541 AA_ForceRasterWidgets = 14,
542 AA_UseDesktopOpenGL = 15,
543 AA_UseOpenGLES = 16,
544 AA_UseSoftwareOpenGL = 17,
545 AA_ShareOpenGLContexts = 18,
546 AA_SetPalette = 19,
547 AA_EnableHighDpiScaling = 20,
548 AA_DisableHighDpiScaling = 21,
549 AA_UseStyleSheetPropagationInWidgetStyles = 22,
550 AA_DontUseNativeDialogs = 23,
551 AA_SynthesizeMouseForUnhandledTabletEvents = 24,
552 AA_CompressHighFrequencyEvents = 25,
553 AA_DontCheckOpenGLContextThreadAffinity = 26,
554 AA_DisableShaderDiskCache = 27,
555 AA_DontShowShortcutsInContextMenus = 28,
556 AA_CompressTabletEvents = 29,
557 AA_DisableWindowContextHelpButton = 30, // ### Qt 6: remove me
558 AA_DisableSessionManager = 31,
559
560 // Add new attributes before this line
561 AA_AttributeCount
562 };
563
564
565 // Image conversion flags. The unusual ordering is caused by
566 // compatibility and default requirements.
567
568 enum ImageConversionFlag {
569 ColorMode_Mask = 0x00000003,
570 AutoColor = 0x00000000,
571 ColorOnly = 0x00000003,
572 MonoOnly = 0x00000002,
573 // Reserved = 0x00000001,
574
575 AlphaDither_Mask = 0x0000000c,
576 ThresholdAlphaDither = 0x00000000,
577 OrderedAlphaDither = 0x00000004,
578 DiffuseAlphaDither = 0x00000008,
579 NoAlpha = 0x0000000c, // Not supported
580
581 Dither_Mask = 0x00000030,
582 DiffuseDither = 0x00000000,
583 OrderedDither = 0x00000010,
584 ThresholdDither = 0x00000020,
585 // ReservedDither = 0x00000030,
586
587 DitherMode_Mask = 0x000000c0,
588 AutoDither = 0x00000000,
589 PreferDither = 0x00000040,
590 AvoidDither = 0x00000080,
591
592 NoOpaqueDetection = 0x00000100,
593 NoFormatConversion = 0x00000200
594 };
595 Q_DECLARE_FLAGS(ImageConversionFlags, ImageConversionFlag)
596 Q_DECLARE_OPERATORS_FOR_FLAGS(ImageConversionFlags)
597
598 enum BGMode {
599 TransparentMode,
600 OpaqueMode
601 };
602
603 enum Key {
604 Key_Escape = 0x01000000, // misc keys
605 Key_Tab = 0x01000001,
606 Key_Backtab = 0x01000002,
607 Key_Backspace = 0x01000003,
608 Key_Return = 0x01000004,
609 Key_Enter = 0x01000005,
610 Key_Insert = 0x01000006,
611 Key_Delete = 0x01000007,
612 Key_Pause = 0x01000008,
613 Key_Print = 0x01000009, // print screen
614 Key_SysReq = 0x0100000a,
615 Key_Clear = 0x0100000b,
616 Key_Home = 0x01000010, // cursor movement
617 Key_End = 0x01000011,
618 Key_Left = 0x01000012,
619 Key_Up = 0x01000013,
620 Key_Right = 0x01000014,
621 Key_Down = 0x01000015,
622 Key_PageUp = 0x01000016,
623 Key_PageDown = 0x01000017,
624 Key_Shift = 0x01000020, // modifiers
625 Key_Control = 0x01000021,
626 Key_Meta = 0x01000022,
627 Key_Alt = 0x01000023,
628 Key_CapsLock = 0x01000024,
629 Key_NumLock = 0x01000025,
630 Key_ScrollLock = 0x01000026,
631 Key_F1 = 0x01000030, // function keys
632 Key_F2 = 0x01000031,
633 Key_F3 = 0x01000032,
634 Key_F4 = 0x01000033,
635 Key_F5 = 0x01000034,
636 Key_F6 = 0x01000035,
637 Key_F7 = 0x01000036,
638 Key_F8 = 0x01000037,
639 Key_F9 = 0x01000038,
640 Key_F10 = 0x01000039,
641 Key_F11 = 0x0100003a,
642 Key_F12 = 0x0100003b,
643 Key_F13 = 0x0100003c,
644 Key_F14 = 0x0100003d,
645 Key_F15 = 0x0100003e,
646 Key_F16 = 0x0100003f,
647 Key_F17 = 0x01000040,
648 Key_F18 = 0x01000041,
649 Key_F19 = 0x01000042,
650 Key_F20 = 0x01000043,
651 Key_F21 = 0x01000044,
652 Key_F22 = 0x01000045,
653 Key_F23 = 0x01000046,
654 Key_F24 = 0x01000047,
655 Key_F25 = 0x01000048, // F25 .. F35 only on X11
656 Key_F26 = 0x01000049,
657 Key_F27 = 0x0100004a,
658 Key_F28 = 0x0100004b,
659 Key_F29 = 0x0100004c,
660 Key_F30 = 0x0100004d,
661 Key_F31 = 0x0100004e,
662 Key_F32 = 0x0100004f,
663 Key_F33 = 0x01000050,
664 Key_F34 = 0x01000051,
665 Key_F35 = 0x01000052,
666 Key_Super_L = 0x01000053, // extra keys
667 Key_Super_R = 0x01000054,
668 Key_Menu = 0x01000055,
669 Key_Hyper_L = 0x01000056,
670 Key_Hyper_R = 0x01000057,
671 Key_Help = 0x01000058,
672 Key_Direction_L = 0x01000059,
673 Key_Direction_R = 0x01000060,
674 Key_Space = 0x20, // 7 bit printable ASCII
675 Key_Any = Key_Space,
676 Key_Exclam = 0x21,
677 Key_QuoteDbl = 0x22,
678 Key_NumberSign = 0x23,
679 Key_Dollar = 0x24,
680 Key_Percent = 0x25,
681 Key_Ampersand = 0x26,
682 Key_Apostrophe = 0x27,
683 Key_ParenLeft = 0x28,
684 Key_ParenRight = 0x29,
685 Key_Asterisk = 0x2a,
686 Key_Plus = 0x2b,
687 Key_Comma = 0x2c,
688 Key_Minus = 0x2d,
689 Key_Period = 0x2e,
690 Key_Slash = 0x2f,
691 Key_0 = 0x30,
692 Key_1 = 0x31,
693 Key_2 = 0x32,
694 Key_3 = 0x33,
695 Key_4 = 0x34,
696 Key_5 = 0x35,
697 Key_6 = 0x36,
698 Key_7 = 0x37,
699 Key_8 = 0x38,
700 Key_9 = 0x39,
701 Key_Colon = 0x3a,
702 Key_Semicolon = 0x3b,
703 Key_Less = 0x3c,
704 Key_Equal = 0x3d,
705 Key_Greater = 0x3e,
706 Key_Question = 0x3f,
707 Key_At = 0x40,
708 Key_A = 0x41,
709 Key_B = 0x42,
710 Key_C = 0x43,
711 Key_D = 0x44,
712 Key_E = 0x45,
713 Key_F = 0x46,
714 Key_G = 0x47,
715 Key_H = 0x48,
716 Key_I = 0x49,
717 Key_J = 0x4a,
718 Key_K = 0x4b,
719 Key_L = 0x4c,
720 Key_M = 0x4d,
721 Key_N = 0x4e,
722 Key_O = 0x4f,
723 Key_P = 0x50,
724 Key_Q = 0x51,
725 Key_R = 0x52,
726 Key_S = 0x53,
727 Key_T = 0x54,
728 Key_U = 0x55,
729 Key_V = 0x56,
730 Key_W = 0x57,
731 Key_X = 0x58,
732 Key_Y = 0x59,
733 Key_Z = 0x5a,
734 Key_BracketLeft = 0x5b,
735 Key_Backslash = 0x5c,
736 Key_BracketRight = 0x5d,
737 Key_AsciiCircum = 0x5e,
738 Key_Underscore = 0x5f,
739 Key_QuoteLeft = 0x60,
740 Key_BraceLeft = 0x7b,
741 Key_Bar = 0x7c,
742 Key_BraceRight = 0x7d,
743 Key_AsciiTilde = 0x7e,
744
745 Key_nobreakspace = 0x0a0,
746 Key_exclamdown = 0x0a1,
747 Key_cent = 0x0a2,
748 Key_sterling = 0x0a3,
749 Key_currency = 0x0a4,
750 Key_yen = 0x0a5,
751 Key_brokenbar = 0x0a6,
752 Key_section = 0x0a7,
753 Key_diaeresis = 0x0a8,
754 Key_copyright = 0x0a9,
755 Key_ordfeminine = 0x0aa,
756 Key_guillemotleft = 0x0ab, // left angle quotation mark
757 Key_notsign = 0x0ac,
758 Key_hyphen = 0x0ad,
759 Key_registered = 0x0ae,
760 Key_macron = 0x0af,
761 Key_degree = 0x0b0,
762 Key_plusminus = 0x0b1,
763 Key_twosuperior = 0x0b2,
764 Key_threesuperior = 0x0b3,
765 Key_acute = 0x0b4,
766 Key_mu = 0x0b5,
767 Key_paragraph = 0x0b6,
768 Key_periodcentered = 0x0b7,
769 Key_cedilla = 0x0b8,
770 Key_onesuperior = 0x0b9,
771 Key_masculine = 0x0ba,
772 Key_guillemotright = 0x0bb, // right angle quotation mark
773 Key_onequarter = 0x0bc,
774 Key_onehalf = 0x0bd,
775 Key_threequarters = 0x0be,
776 Key_questiondown = 0x0bf,
777 Key_Agrave = 0x0c0,
778 Key_Aacute = 0x0c1,
779 Key_Acircumflex = 0x0c2,
780 Key_Atilde = 0x0c3,
781 Key_Adiaeresis = 0x0c4,
782 Key_Aring = 0x0c5,
783 Key_AE = 0x0c6,
784 Key_Ccedilla = 0x0c7,
785 Key_Egrave = 0x0c8,
786 Key_Eacute = 0x0c9,
787 Key_Ecircumflex = 0x0ca,
788 Key_Ediaeresis = 0x0cb,
789 Key_Igrave = 0x0cc,
790 Key_Iacute = 0x0cd,
791 Key_Icircumflex = 0x0ce,
792 Key_Idiaeresis = 0x0cf,
793 Key_ETH = 0x0d0,
794 Key_Ntilde = 0x0d1,
795 Key_Ograve = 0x0d2,
796 Key_Oacute = 0x0d3,
797 Key_Ocircumflex = 0x0d4,
798 Key_Otilde = 0x0d5,
799 Key_Odiaeresis = 0x0d6,
800 Key_multiply = 0x0d7,
801 Key_Ooblique = 0x0d8,
802 Key_Ugrave = 0x0d9,
803 Key_Uacute = 0x0da,
804 Key_Ucircumflex = 0x0db,
805 Key_Udiaeresis = 0x0dc,
806 Key_Yacute = 0x0dd,
807 Key_THORN = 0x0de,
808 Key_ssharp = 0x0df,
809 Key_division = 0x0f7,
810 Key_ydiaeresis = 0x0ff,
811
812 // International input method support (X keycode - 0xEE00, the
813 // definition follows Qt/Embedded 2.3.7) Only interesting if
814 // you are writing your own input method
815
816 // International & multi-key character composition
817 Key_AltGr = 0x01001103,
818 Key_Multi_key = 0x01001120, // Multi-key character compose
819 Key_Codeinput = 0x01001137,
820 Key_SingleCandidate = 0x0100113c,
821 Key_MultipleCandidate = 0x0100113d,
822 Key_PreviousCandidate = 0x0100113e,
823
824 // Misc Functions
825 Key_Mode_switch = 0x0100117e, // Character set switch
826 //Key_script_switch = 0x0100117e, // Alias for mode_switch
827
828 // Japanese keyboard support
829 Key_Kanji = 0x01001121, // Kanji, Kanji convert
830 Key_Muhenkan = 0x01001122, // Cancel Conversion
831 //Key_Henkan_Mode = 0x01001123, // Start/Stop Conversion
832 Key_Henkan = 0x01001123, // Alias for Henkan_Mode
833 Key_Romaji = 0x01001124, // to Romaji
834 Key_Hiragana = 0x01001125, // to Hiragana
835 Key_Katakana = 0x01001126, // to Katakana
836 Key_Hiragana_Katakana = 0x01001127, // Hiragana/Katakana toggle
837 Key_Zenkaku = 0x01001128, // to Zenkaku
838 Key_Hankaku = 0x01001129, // to Hankaku
839 Key_Zenkaku_Hankaku = 0x0100112a, // Zenkaku/Hankaku toggle
840 Key_Touroku = 0x0100112b, // Add to Dictionary
841 Key_Massyo = 0x0100112c, // Delete from Dictionary
842 Key_Kana_Lock = 0x0100112d, // Kana Lock
843 Key_Kana_Shift = 0x0100112e, // Kana Shift
844 Key_Eisu_Shift = 0x0100112f, // Alphanumeric Shift
845 Key_Eisu_toggle = 0x01001130, // Alphanumeric toggle
846 //Key_Kanji_Bangou = 0x01001137, // Codeinput
847 //Key_Zen_Koho = 0x0100113d, // Multiple/All Candidate(s)
848 //Key_Mae_Koho = 0x0100113e, // Previous Candidate
849
850 // Korean keyboard support
851 //
852 // In fact, many Korean users need only 2 keys, Key_Hangul and
853 // Key_Hangul_Hanja. But rest of the keys are good for future.
854
855 Key_Hangul = 0x01001131, // Hangul start/stop(toggle)
856 Key_Hangul_Start = 0x01001132, // Hangul start
857 Key_Hangul_End = 0x01001133, // Hangul end, English start
858 Key_Hangul_Hanja = 0x01001134, // Start Hangul->Hanja Conversion
859 Key_Hangul_Jamo = 0x01001135, // Hangul Jamo mode
860 Key_Hangul_Romaja = 0x01001136, // Hangul Romaja mode
861 //Key_Hangul_Codeinput = 0x01001137, // Hangul code input mode
862 Key_Hangul_Jeonja = 0x01001138, // Jeonja mode
863 Key_Hangul_Banja = 0x01001139, // Banja mode
864 Key_Hangul_PreHanja = 0x0100113a, // Pre Hanja conversion
865 Key_Hangul_PostHanja = 0x0100113b, // Post Hanja conversion
866 //Key_Hangul_SingleCandidate = 0x0100113c, // Single candidate
867 //Key_Hangul_MultipleCandidate = 0x0100113d, // Multiple candidate
868 //Key_Hangul_PreviousCandidate = 0x0100113e, // Previous candidate
869 Key_Hangul_Special = 0x0100113f, // Special symbols
870 //Key_Hangul_switch = 0x0100117e, // Alias for mode_switch
871
872 // dead keys (X keycode - 0xED00 to avoid the conflict)
873 Key_Dead_Grave = 0x01001250,
874 Key_Dead_Acute = 0x01001251,
875 Key_Dead_Circumflex = 0x01001252,
876 Key_Dead_Tilde = 0x01001253,
877 Key_Dead_Macron = 0x01001254,
878 Key_Dead_Breve = 0x01001255,
879 Key_Dead_Abovedot = 0x01001256,
880 Key_Dead_Diaeresis = 0x01001257,
881 Key_Dead_Abovering = 0x01001258,
882 Key_Dead_Doubleacute = 0x01001259,
883 Key_Dead_Caron = 0x0100125a,
884 Key_Dead_Cedilla = 0x0100125b,
885 Key_Dead_Ogonek = 0x0100125c,
886 Key_Dead_Iota = 0x0100125d,
887 Key_Dead_Voiced_Sound = 0x0100125e,
888 Key_Dead_Semivoiced_Sound = 0x0100125f,
889 Key_Dead_Belowdot = 0x01001260,
890 Key_Dead_Hook = 0x01001261,
891 Key_Dead_Horn = 0x01001262,
892 Key_Dead_Stroke = 0x01001263,
893 Key_Dead_Abovecomma = 0x01001264,
894 Key_Dead_Abovereversedcomma = 0x01001265,
895 Key_Dead_Doublegrave = 0x01001266,
896 Key_Dead_Belowring = 0x01001267,
897 Key_Dead_Belowmacron = 0x01001268,
898 Key_Dead_Belowcircumflex = 0x01001269,
899 Key_Dead_Belowtilde = 0x0100126a,
900 Key_Dead_Belowbreve = 0x0100126b,
901 Key_Dead_Belowdiaeresis = 0x0100126c,
902 Key_Dead_Invertedbreve = 0x0100126d,
903 Key_Dead_Belowcomma = 0x0100126e,
904 Key_Dead_Currency = 0x0100126f,
905 Key_Dead_a = 0x01001280,
906 Key_Dead_A = 0x01001281,
907 Key_Dead_e = 0x01001282,
908 Key_Dead_E = 0x01001283,
909 Key_Dead_i = 0x01001284,
910 Key_Dead_I = 0x01001285,
911 Key_Dead_o = 0x01001286,
912 Key_Dead_O = 0x01001287,
913 Key_Dead_u = 0x01001288,
914 Key_Dead_U = 0x01001289,
915 Key_Dead_Small_Schwa = 0x0100128a,
916 Key_Dead_Capital_Schwa = 0x0100128b,
917 Key_Dead_Greek = 0x0100128c,
918 Key_Dead_Lowline = 0x01001290,
919 Key_Dead_Aboveverticalline = 0x01001291,
920 Key_Dead_Belowverticalline = 0x01001292,
921 Key_Dead_Longsolidusoverlay = 0x01001293,
922
923 // multimedia/internet keys - ignored by default - see QKeyEvent c'tor
924 Key_Back = 0x01000061,
925 Key_Forward = 0x01000062,
926 Key_Stop = 0x01000063,
927 Key_Refresh = 0x01000064,
928 Key_VolumeDown = 0x01000070,
929 Key_VolumeMute = 0x01000071,
930 Key_VolumeUp = 0x01000072,
931 Key_BassBoost = 0x01000073,
932 Key_BassUp = 0x01000074,
933 Key_BassDown = 0x01000075,
934 Key_TrebleUp = 0x01000076,
935 Key_TrebleDown = 0x01000077,
936 Key_MediaPlay = 0x01000080,
937 Key_MediaStop = 0x01000081,
938 Key_MediaPrevious = 0x01000082,
939 Key_MediaNext = 0x01000083,
940 Key_MediaRecord = 0x01000084,
941 Key_MediaPause = 0x1000085,
942 Key_MediaTogglePlayPause = 0x1000086,
943 Key_HomePage = 0x01000090,
944 Key_Favorites = 0x01000091,
945 Key_Search = 0x01000092,
946 Key_Standby = 0x01000093,
947 Key_OpenUrl = 0x01000094,
948 Key_LaunchMail = 0x010000a0,
949 Key_LaunchMedia = 0x010000a1,
950 Key_Launch0 = 0x010000a2,
951 Key_Launch1 = 0x010000a3,
952 Key_Launch2 = 0x010000a4,
953 Key_Launch3 = 0x010000a5,
954 Key_Launch4 = 0x010000a6,
955 Key_Launch5 = 0x010000a7,
956 Key_Launch6 = 0x010000a8,
957 Key_Launch7 = 0x010000a9,
958 Key_Launch8 = 0x010000aa,
959 Key_Launch9 = 0x010000ab,
960 Key_LaunchA = 0x010000ac,
961 Key_LaunchB = 0x010000ad,
962 Key_LaunchC = 0x010000ae,
963 Key_LaunchD = 0x010000af,
964 Key_LaunchE = 0x010000b0,
965 Key_LaunchF = 0x010000b1,
966 Key_MonBrightnessUp = 0x010000b2,
967 Key_MonBrightnessDown = 0x010000b3,
968 Key_KeyboardLightOnOff = 0x010000b4,
969 Key_KeyboardBrightnessUp = 0x010000b5,
970 Key_KeyboardBrightnessDown = 0x010000b6,
971 Key_PowerOff = 0x010000b7,
972 Key_WakeUp = 0x010000b8,
973 Key_Eject = 0x010000b9,
974 Key_ScreenSaver = 0x010000ba,
975 Key_WWW = 0x010000bb,
976 Key_Memo = 0x010000bc,
977 Key_LightBulb = 0x010000bd,
978 Key_Shop = 0x010000be,
979 Key_History = 0x010000bf,
980 Key_AddFavorite = 0x010000c0,
981 Key_HotLinks = 0x010000c1,
982 Key_BrightnessAdjust = 0x010000c2,
983 Key_Finance = 0x010000c3,
984 Key_Community = 0x010000c4,
985 Key_AudioRewind = 0x010000c5, // Media rewind
986 Key_BackForward = 0x010000c6,
987 Key_ApplicationLeft = 0x010000c7,
988 Key_ApplicationRight = 0x010000c8,
989 Key_Book = 0x010000c9,
990 Key_CD = 0x010000ca,
991 Key_Calculator = 0x010000cb,
992 Key_ToDoList = 0x010000cc,
993 Key_ClearGrab = 0x010000cd,
994 Key_Close = 0x010000ce,
995 Key_Copy = 0x010000cf,
996 Key_Cut = 0x010000d0,
997 Key_Display = 0x010000d1, // Output switch key
998 Key_DOS = 0x010000d2,
999 Key_Documents = 0x010000d3,
1000 Key_Excel = 0x010000d4,
1001 Key_Explorer = 0x010000d5,
1002 Key_Game = 0x010000d6,
1003 Key_Go = 0x010000d7,
1004 Key_iTouch = 0x010000d8,
1005 Key_LogOff = 0x010000d9,
1006 Key_Market = 0x010000da,
1007 Key_Meeting = 0x010000db,
1008 Key_MenuKB = 0x010000dc,
1009 Key_MenuPB = 0x010000dd,
1010 Key_MySites = 0x010000de,
1011 Key_News = 0x010000df,
1012 Key_OfficeHome = 0x010000e0,
1013 Key_Option = 0x010000e1,
1014 Key_Paste = 0x010000e2,
1015 Key_Phone = 0x010000e3,
1016 Key_Calendar = 0x010000e4,
1017 Key_Reply = 0x010000e5,
1018 Key_Reload = 0x010000e6,
1019 Key_RotateWindows = 0x010000e7,
1020 Key_RotationPB = 0x010000e8,
1021 Key_RotationKB = 0x010000e9,
1022 Key_Save = 0x010000ea,
1023 Key_Send = 0x010000eb,
1024 Key_Spell = 0x010000ec,
1025 Key_SplitScreen = 0x010000ed,
1026 Key_Support = 0x010000ee,
1027 Key_TaskPane = 0x010000ef,
1028 Key_Terminal = 0x010000f0,
1029 Key_Tools = 0x010000f1,
1030 Key_Travel = 0x010000f2,
1031 Key_Video = 0x010000f3,
1032 Key_Word = 0x010000f4,
1033 Key_Xfer = 0x010000f5,
1034 Key_ZoomIn = 0x010000f6,
1035 Key_ZoomOut = 0x010000f7,
1036 Key_Away = 0x010000f8,
1037 Key_Messenger = 0x010000f9,
1038 Key_WebCam = 0x010000fa,
1039 Key_MailForward = 0x010000fb,
1040 Key_Pictures = 0x010000fc,
1041 Key_Music = 0x010000fd,
1042 Key_Battery = 0x010000fe,
1043 Key_Bluetooth = 0x010000ff,
1044 Key_WLAN = 0x01000100,
1045 Key_UWB = 0x01000101,
1046 Key_AudioForward = 0x01000102, // Media fast-forward
1047 Key_AudioRepeat = 0x01000103, // Toggle repeat mode
1048 Key_AudioRandomPlay = 0x01000104, // Toggle shuffle mode
1049 Key_Subtitle = 0x01000105,
1050 Key_AudioCycleTrack = 0x01000106,
1051 Key_Time = 0x01000107,
1052 Key_Hibernate = 0x01000108,
1053 Key_View = 0x01000109,
1054 Key_TopMenu = 0x0100010a,
1055 Key_PowerDown = 0x0100010b,
1056 Key_Suspend = 0x0100010c,
1057 Key_ContrastAdjust = 0x0100010d,
1058
1059 Key_LaunchG = 0x0100010e,
1060 Key_LaunchH = 0x0100010f,
1061
1062 Key_TouchpadToggle = 0x01000110,
1063 Key_TouchpadOn = 0x01000111,
1064 Key_TouchpadOff = 0x01000112,
1065
1066 Key_MicMute = 0x01000113,
1067
1068 Key_Red = 0x01000114,
1069 Key_Green = 0x01000115,
1070 Key_Yellow = 0x01000116,
1071 Key_Blue = 0x01000117,
1072
1073 Key_ChannelUp = 0x01000118,
1074 Key_ChannelDown = 0x01000119,
1075
1076 Key_Guide = 0x0100011a,
1077 Key_Info = 0x0100011b,
1078 Key_Settings = 0x0100011c,
1079
1080 Key_MicVolumeUp = 0x0100011d,
1081 Key_MicVolumeDown = 0x0100011e,
1082
1083 Key_New = 0x01000120,
1084 Key_Open = 0x01000121,
1085 Key_Find = 0x01000122,
1086 Key_Undo = 0x01000123,
1087 Key_Redo = 0x01000124,
1088
1089 Key_MediaLast = 0x0100ffff,
1090
1091 // Keypad navigation keys
1092 Key_Select = 0x01010000,
1093 Key_Yes = 0x01010001,
1094 Key_No = 0x01010002,
1095
1096 // Newer misc keys
1097 Key_Cancel = 0x01020001,
1098 Key_Printer = 0x01020002,
1099 Key_Execute = 0x01020003,
1100 Key_Sleep = 0x01020004,
1101 Key_Play = 0x01020005, // Not the same as Key_MediaPlay
1102 Key_Zoom = 0x01020006,
1103 //Key_Jisho = 0x01020007, // IME: Dictionary key
1104 //Key_Oyayubi_Left = 0x01020008, // IME: Left Oyayubi key
1105 //Key_Oyayubi_Right = 0x01020009, // IME: Right Oyayubi key
1106 Key_Exit = 0x0102000a,
1107
1108 // Device keys
1109 Key_Context1 = 0x01100000,
1110 Key_Context2 = 0x01100001,
1111 Key_Context3 = 0x01100002,
1112 Key_Context4 = 0x01100003,
1113 Key_Call = 0x01100004, // set absolute state to in a call (do not toggle state)
1114 Key_Hangup = 0x01100005, // set absolute state to hang up (do not toggle state)
1115 Key_Flip = 0x01100006,
1116 Key_ToggleCallHangup = 0x01100007, // a toggle key for answering, or hanging up, based on current call state
1117 Key_VoiceDial = 0x01100008,
1118 Key_LastNumberRedial = 0x01100009,
1119
1120 Key_Camera = 0x01100020,
1121 Key_CameraFocus = 0x01100021,
1122
1123 Key_unknown = 0x01ffffff
1124 };
1125
1126 enum ArrowType {
1127 NoArrow,
1128 UpArrow,
1129 DownArrow,
1130 LeftArrow,
1131 RightArrow
1132 };
1133
1134 enum PenStyle { // pen style
1135 NoPen,
1136 SolidLine,
1137 DashLine,
1138 DotLine,
1139 DashDotLine,
1140 DashDotDotLine,
1141 CustomDashLine
1142#ifndef Q_MOC_RUN
1143 , MPenStyle = 0x0f
1144#endif
1145 };
1146
1147 enum PenCapStyle { // line endcap style
1148 FlatCap = 0x00,
1149 SquareCap = 0x10,
1150 RoundCap = 0x20,
1151 MPenCapStyle = 0x30
1152 };
1153
1154 enum PenJoinStyle { // line join style
1155 MiterJoin = 0x00,
1156 BevelJoin = 0x40,
1157 RoundJoin = 0x80,
1158 SvgMiterJoin = 0x100,
1159 MPenJoinStyle = 0x1c0
1160 };
1161
1162 enum BrushStyle { // brush style
1163 NoBrush,
1164 SolidPattern,
1165 Dense1Pattern,
1166 Dense2Pattern,
1167 Dense3Pattern,
1168 Dense4Pattern,
1169 Dense5Pattern,
1170 Dense6Pattern,
1171 Dense7Pattern,
1172 HorPattern,
1173 VerPattern,
1174 CrossPattern,
1175 BDiagPattern,
1176 FDiagPattern,
1177 DiagCrossPattern,
1178 LinearGradientPattern,
1179 RadialGradientPattern,
1180 ConicalGradientPattern,
1181 TexturePattern = 24
1182 };
1183
1184 enum SizeMode {
1185 AbsoluteSize,
1186 RelativeSize
1187 };
1188
1189 enum UIEffect {
1190 UI_General,
1191 UI_AnimateMenu,
1192 UI_FadeMenu,
1193 UI_AnimateCombo,
1194 UI_AnimateTooltip,
1195 UI_FadeTooltip,
1196 UI_AnimateToolBox
1197 };
1198
1199 enum CursorShape {
1200 ArrowCursor,
1201 UpArrowCursor,
1202 CrossCursor,
1203 WaitCursor,
1204 IBeamCursor,
1205 SizeVerCursor,
1206 SizeHorCursor,
1207 SizeBDiagCursor,
1208 SizeFDiagCursor,
1209 SizeAllCursor,
1210 BlankCursor,
1211 SplitVCursor,
1212 SplitHCursor,
1213 PointingHandCursor,
1214 ForbiddenCursor,
1215 WhatsThisCursor,
1216 BusyCursor,
1217 OpenHandCursor,
1218 ClosedHandCursor,
1219 DragCopyCursor,
1220 DragMoveCursor,
1221 DragLinkCursor,
1222 LastCursor = DragLinkCursor,
1223 BitmapCursor = 24,
1224 CustomCursor = 25
1225 };
1226
1227 enum TextFormat {
1228 PlainText,
1229 RichText,
1230 AutoText,
1231 MarkdownText
1232 };
1233
1234 enum AspectRatioMode {
1235 IgnoreAspectRatio,
1236 KeepAspectRatio,
1237 KeepAspectRatioByExpanding
1238 };
1239
1240 enum DockWidgetArea {
1241 LeftDockWidgetArea = 0x1,
1242 RightDockWidgetArea = 0x2,
1243 TopDockWidgetArea = 0x4,
1244 BottomDockWidgetArea = 0x8,
1245
1246 DockWidgetArea_Mask = 0xf,
1247 AllDockWidgetAreas = DockWidgetArea_Mask,
1248 NoDockWidgetArea = 0
1249 };
1250 enum DockWidgetAreaSizes {
1251 NDockWidgetAreas = 4
1252 };
1253
1254 Q_DECLARE_FLAGS(DockWidgetAreas, DockWidgetArea)
1255 Q_DECLARE_OPERATORS_FOR_FLAGS(DockWidgetAreas)
1256
1257 enum ToolBarArea {
1258 LeftToolBarArea = 0x1,
1259 RightToolBarArea = 0x2,
1260 TopToolBarArea = 0x4,
1261 BottomToolBarArea = 0x8,
1262
1263 ToolBarArea_Mask = 0xf,
1264 AllToolBarAreas = ToolBarArea_Mask,
1265 NoToolBarArea = 0
1266 };
1267
1268 enum ToolBarAreaSizes {
1269 NToolBarAreas = 4
1270 };
1271
1272 Q_DECLARE_FLAGS(ToolBarAreas, ToolBarArea)
1273 Q_DECLARE_OPERATORS_FOR_FLAGS(ToolBarAreas)
1274
1275 enum DateFormat {
1276 TextDate, // default Qt
1277 ISODate, // ISO 8601
1278#if QT_DEPRECATED_SINCE(5, 15)
1279 SystemLocaleDate Q_DECL_ENUMERATOR_DEPRECATED_X("Use QLocale"),
1280 LocalDate Q_DECL_ENUMERATOR_DEPRECATED_X("Use QLocale") = 2, // i.e. SystemLocaleDate
1281 LocaleDate Q_DECL_ENUMERATOR_DEPRECATED_X("Use QLocale"),
1282 SystemLocaleShortDate Q_DECL_ENUMERATOR_DEPRECATED_X("Use QLocale"),
1283 SystemLocaleLongDate Q_DECL_ENUMERATOR_DEPRECATED_X("Use QLocale"),
1284 DefaultLocaleShortDate Q_DECL_ENUMERATOR_DEPRECATED_X("Use QLocale"),
1285 DefaultLocaleLongDate Q_DECL_ENUMERATOR_DEPRECATED_X("Use QLocale"),
1286#endif
1287 RFC2822Date = 8, // RFC 2822 (+ 850 and 1036 during parsing)
1288 ISODateWithMs
1289 };
1290
1291 enum TimeSpec {
1292 LocalTime,
1293 UTC,
1294 OffsetFromUTC,
1295 TimeZone
1296 };
1297
1298 enum DayOfWeek {
1299 Monday = 1,
1300 Tuesday = 2,
1301 Wednesday = 3,
1302 Thursday = 4,
1303 Friday = 5,
1304 Saturday = 6,
1305 Sunday = 7
1306 };
1307
1308 enum ScrollBarPolicy {
1309 ScrollBarAsNeeded,
1310 ScrollBarAlwaysOff,
1311 ScrollBarAlwaysOn
1312 };
1313
1314 enum CaseSensitivity {
1315 CaseInsensitive,
1316 CaseSensitive
1317 };
1318
1319 enum Corner {
1320 TopLeftCorner = 0x00000,
1321 TopRightCorner = 0x00001,
1322 BottomLeftCorner = 0x00002,
1323 BottomRightCorner = 0x00003
1324 };
1325
1326 enum Edge {
1327 TopEdge = 0x00001,
1328 LeftEdge = 0x00002,
1329 RightEdge = 0x00004,
1330 BottomEdge = 0x00008
1331 };
1332
1333 Q_DECLARE_FLAGS(Edges, Edge)
1334 Q_DECLARE_OPERATORS_FOR_FLAGS(Edges)
1335
1336 enum ConnectionType {
1337 AutoConnection,
1338 DirectConnection,
1339 QueuedConnection,
1340 BlockingQueuedConnection,
1341 UniqueConnection = 0x80
1342 };
1343
1344 enum ShortcutContext {
1345 WidgetShortcut,
1346 WindowShortcut,
1347 ApplicationShortcut,
1348 WidgetWithChildrenShortcut
1349 };
1350
1351 enum FillRule {
1352 OddEvenFill,
1353 WindingFill
1354 };
1355
1356 enum MaskMode {
1357 MaskInColor,
1358 MaskOutColor
1359 };
1360
1361 enum ClipOperation {
1362 NoClip,
1363 ReplaceClip,
1364 IntersectClip
1365 };
1366
1367 // Shape = 0x1, BoundingRect = 0x2
1368 enum ItemSelectionMode {
1369 ContainsItemShape = 0x0,
1370 IntersectsItemShape = 0x1,
1371 ContainsItemBoundingRect = 0x2,
1372 IntersectsItemBoundingRect = 0x3
1373 };
1374
1375 enum ItemSelectionOperation {
1376 ReplaceSelection,
1377 AddToSelection
1378 };
1379
1380 enum TransformationMode {
1381 FastTransformation,
1382 SmoothTransformation
1383 };
1384
1385 enum Axis {
1386 XAxis,
1387 YAxis,
1388 ZAxis
1389 };
1390
1391 enum FocusReason {
1392 MouseFocusReason,
1393 TabFocusReason,
1394 BacktabFocusReason,
1395 ActiveWindowFocusReason,
1396 PopupFocusReason,
1397 ShortcutFocusReason,
1398 MenuBarFocusReason,
1399 OtherFocusReason,
1400 NoFocusReason
1401 };
1402
1403 enum ContextMenuPolicy {
1404 NoContextMenu,
1405 DefaultContextMenu,
1406 ActionsContextMenu,
1407 CustomContextMenu,
1408 PreventContextMenu
1409 };
1410
1411 enum InputMethodQuery {
1412 ImEnabled = 0x1,
1413 ImCursorRectangle = 0x2,
1414#if QT_DEPRECATED_SINCE(5, 14)
1415 ImMicroFocus Q_DECL_ENUMERATOR_DEPRECATED = 0x2,
1416#endif
1417 ImFont = 0x4,
1418 ImCursorPosition = 0x8,
1419 ImSurroundingText = 0x10,
1420 ImCurrentSelection = 0x20,
1421 ImMaximumTextLength = 0x40,
1422 ImAnchorPosition = 0x80,
1423 ImHints = 0x100,
1424 ImPreferredLanguage = 0x200,
1425
1426 ImAbsolutePosition = 0x400,
1427 ImTextBeforeCursor = 0x800,
1428 ImTextAfterCursor = 0x1000,
1429 ImEnterKeyType = 0x2000,
1430 ImAnchorRectangle = 0x4000,
1431 ImInputItemClipRectangle = 0x8000,
1432
1433 ImPlatformData = 0x80000000,
1434 ImQueryInput = ImCursorRectangle | ImCursorPosition | ImSurroundingText |
1435 ImCurrentSelection | ImAnchorRectangle | ImAnchorPosition,
1436 ImQueryAll = 0xffffffff
1437 };
1438 Q_DECLARE_FLAGS(InputMethodQueries, InputMethodQuery)
1439 Q_DECLARE_OPERATORS_FOR_FLAGS(InputMethodQueries)
1440
1441 enum InputMethodHint {
1442 ImhNone = 0x0,
1443
1444 ImhHiddenText = 0x1,
1445 ImhSensitiveData = 0x2,
1446 ImhNoAutoUppercase = 0x4,
1447 ImhPreferNumbers = 0x8,
1448 ImhPreferUppercase = 0x10,
1449 ImhPreferLowercase = 0x20,
1450 ImhNoPredictiveText = 0x40,
1451
1452 ImhDate = 0x80,
1453 ImhTime = 0x100,
1454
1455 ImhPreferLatin = 0x200,
1456
1457 ImhMultiLine = 0x400,
1458
1459 ImhNoEditMenu = 0x800,
1460 ImhNoTextHandles = 0x1000,
1461
1462 ImhDigitsOnly = 0x10000,
1463 ImhFormattedNumbersOnly = 0x20000,
1464 ImhUppercaseOnly = 0x40000,
1465 ImhLowercaseOnly = 0x80000,
1466 ImhDialableCharactersOnly = 0x100000,
1467 ImhEmailCharactersOnly = 0x200000,
1468 ImhUrlCharactersOnly = 0x400000,
1469 ImhLatinOnly = 0x800000,
1470
1471 ImhExclusiveInputMask = 0xffff0000
1472 };
1473 Q_DECLARE_FLAGS(InputMethodHints, InputMethodHint)
1474 Q_DECLARE_OPERATORS_FOR_FLAGS(InputMethodHints)
1475
1476 enum EnterKeyType {
1477 EnterKeyDefault,
1478 EnterKeyReturn,
1479 EnterKeyDone,
1480 EnterKeyGo,
1481 EnterKeySend,
1482 EnterKeySearch,
1483 EnterKeyNext,
1484 EnterKeyPrevious
1485 };
1486
1487 enum ToolButtonStyle {
1488 ToolButtonIconOnly,
1489 ToolButtonTextOnly,
1490 ToolButtonTextBesideIcon,
1491 ToolButtonTextUnderIcon,
1492 ToolButtonFollowStyle
1493 };
1494
1495 enum LayoutDirection {
1496 LeftToRight,
1497 RightToLeft,
1498 LayoutDirectionAuto
1499 };
1500
1501 enum AnchorPoint {
1502 AnchorLeft = 0,
1503 AnchorHorizontalCenter,
1504 AnchorRight,
1505 AnchorTop,
1506 AnchorVerticalCenter,
1507 AnchorBottom
1508 };
1509
1510 enum FindChildOption {
1511 FindDirectChildrenOnly = 0x0,
1512 FindChildrenRecursively = 0x1
1513 };
1514 Q_DECLARE_FLAGS(FindChildOptions, FindChildOption)
1515
1516 enum DropAction {
1517 CopyAction = 0x1,
1518 MoveAction = 0x2,
1519 LinkAction = 0x4,
1520 ActionMask = 0xff,
1521 TargetMoveAction = 0x8002,
1522 IgnoreAction = 0x0
1523 };
1524 Q_DECLARE_FLAGS(DropActions, DropAction)
1525 Q_DECLARE_OPERATORS_FOR_FLAGS(DropActions)
1526
1527 enum CheckState {
1528 Unchecked,
1529 PartiallyChecked,
1530 Checked
1531 };
1532
1533 enum ItemDataRole {
1534 DisplayRole = 0,
1535 DecorationRole = 1,
1536 EditRole = 2,
1537 ToolTipRole = 3,
1538 StatusTipRole = 4,
1539 WhatsThisRole = 5,
1540 // Metadata
1541 FontRole = 6,
1542 TextAlignmentRole = 7,
1543 BackgroundRole = 8,
1544 ForegroundRole = 9,
1545#if QT_DEPRECATED_SINCE(5, 13) // ### Qt 6: remove me
1546 BackgroundColorRole Q_DECL_ENUMERATOR_DEPRECATED = BackgroundRole,
1547 TextColorRole Q_DECL_ENUMERATOR_DEPRECATED = ForegroundRole,
1548#endif
1549 CheckStateRole = 10,
1550 // Accessibility
1551 AccessibleTextRole = 11,
1552 AccessibleDescriptionRole = 12,
1553 // More general purpose
1554 SizeHintRole = 13,
1555 InitialSortOrderRole = 14,
1556 // Internal UiLib roles. Start worrying when public roles go that high.
1557 DisplayPropertyRole = 27,
1558 DecorationPropertyRole = 28,
1559 ToolTipPropertyRole = 29,
1560 StatusTipPropertyRole = 30,
1561 WhatsThisPropertyRole = 31,
1562 // Reserved
1563 UserRole = 0x0100
1564 };
1565
1566 enum ItemFlag {
1567 NoItemFlags = 0,
1568 ItemIsSelectable = 1,
1569 ItemIsEditable = 2,
1570 ItemIsDragEnabled = 4,
1571 ItemIsDropEnabled = 8,
1572 ItemIsUserCheckable = 16,
1573 ItemIsEnabled = 32,
1574 ItemIsAutoTristate = 64,
1575#if QT_DEPRECATED_SINCE(5, 6)
1576 ItemIsTristate = ItemIsAutoTristate,
1577#endif
1578 ItemNeverHasChildren = 128,
1579 ItemIsUserTristate = 256
1580 };
1581 Q_DECLARE_FLAGS(ItemFlags, ItemFlag)
1582 Q_DECLARE_OPERATORS_FOR_FLAGS(ItemFlags)
1583
1584 enum MatchFlag {
1585 MatchExactly = 0,
1586 MatchContains = 1,
1587 MatchStartsWith = 2,
1588 MatchEndsWith = 3,
1589#if QT_DEPRECATED_SINCE(5, 15)
1590 MatchRegExp Q_DECL_ENUMERATOR_DEPRECATED_X("MatchRegExp is deprecated. Use MatchRegularExpression instead") = 4,
1591#endif
1592 MatchWildcard = 5,
1593 MatchFixedString = 8,
1594 MatchRegularExpression = 9,
1595 MatchCaseSensitive = 16,
1596 MatchWrap = 32,
1597 MatchRecursive = 64
1598 };
1599 Q_DECLARE_FLAGS(MatchFlags, MatchFlag)
1600 Q_DECLARE_OPERATORS_FOR_FLAGS(MatchFlags)
1601
1602 typedef void * HANDLE;
1603#if QT_DEPRECATED_SINCE(5, 0)
1604 typedef WindowFlags WFlags;
1605#endif
1606
1607 enum WindowModality {
1608 NonModal,
1609 WindowModal,
1610 ApplicationModal
1611 };
1612
1613 enum TextInteractionFlag {
1614 NoTextInteraction = 0,
1615 TextSelectableByMouse = 1,
1616 TextSelectableByKeyboard = 2,
1617 LinksAccessibleByMouse = 4,
1618 LinksAccessibleByKeyboard = 8,
1619 TextEditable = 16,
1620
1621 TextEditorInteraction = TextSelectableByMouse | TextSelectableByKeyboard | TextEditable,
1622 TextBrowserInteraction = TextSelectableByMouse | LinksAccessibleByMouse | LinksAccessibleByKeyboard
1623 };
1624 Q_DECLARE_FLAGS(TextInteractionFlags, TextInteractionFlag)
1625 Q_DECLARE_OPERATORS_FOR_FLAGS(TextInteractionFlags)
1626
1627 enum EventPriority {
1628 HighEventPriority = 1,
1629 NormalEventPriority = 0,
1630 LowEventPriority = -1
1631 };
1632
1633 enum SizeHint {
1634 MinimumSize,
1635 PreferredSize,
1636 MaximumSize,
1637 MinimumDescent,
1638 NSizeHints
1639 };
1640
1641 enum WindowFrameSection {
1642 NoSection,
1643 LeftSection, // For resize
1644 TopLeftSection,
1645 TopSection,
1646 TopRightSection,
1647 RightSection,
1648 BottomRightSection,
1649 BottomSection,
1650 BottomLeftSection,
1651 TitleBarArea // For move
1652 };
1653
1654#if defined(Q_COMPILER_CONSTEXPR)
1655 enum class Initialization {
1656 Uninitialized
1657 };
1658 static constexpr Q_DECL_UNUSED Initialization Uninitialized = Initialization::Uninitialized;
1659#else
1660 enum Initialization {
1661 Uninitialized
1662 };
1663#endif
1664
1665 enum CoordinateSystem {
1666 DeviceCoordinates,
1667 LogicalCoordinates
1668 };
1669
1670 enum TouchPointState {
1671 TouchPointPressed = 0x01,
1672 TouchPointMoved = 0x02,
1673 TouchPointStationary = 0x04,
1674 TouchPointReleased = 0x08
1675 };
1676 Q_DECLARE_FLAGS(TouchPointStates, TouchPointState)
1677 Q_DECLARE_OPERATORS_FOR_FLAGS(TouchPointStates)
1678
1679#ifndef QT_NO_GESTURES
1680 enum GestureState
1681 {
1682 NoGesture,
1683 GestureStarted = 1,
1684 GestureUpdated = 2,
1685 GestureFinished = 3,
1686 GestureCanceled = 4
1687 };
1688
1689 enum GestureType
1690 {
1691 TapGesture = 1,
1692 TapAndHoldGesture = 2,
1693 PanGesture = 3,
1694 PinchGesture = 4,
1695 SwipeGesture = 5,
1696
1697 CustomGesture = 0x0100,
1698
1699 LastGestureType = ~0u
1700 };
1701
1702 enum GestureFlag
1703 {
1704 DontStartGestureOnChildren = 0x01,
1705 ReceivePartialGestures = 0x02,
1706 IgnoredGesturesPropagateToParent = 0x04
1707 };
1708 Q_DECLARE_FLAGS(GestureFlags, GestureFlag)
1709 Q_DECLARE_OPERATORS_FOR_FLAGS(GestureFlags)
1710
1711 enum NativeGestureType
1712 {
1713 BeginNativeGesture,
1714 EndNativeGesture,
1715 PanNativeGesture,
1716 ZoomNativeGesture,
1717 SmartZoomNativeGesture,
1718 RotateNativeGesture,
1719 SwipeNativeGesture
1720 };
1721
1722#endif // QT_NO_GESTURES
1723
1724 enum NavigationMode
1725 {
1726 NavigationModeNone,
1727 NavigationModeKeypadTabOrder,
1728 NavigationModeKeypadDirectional,
1729 NavigationModeCursorAuto,
1730 NavigationModeCursorForceVisible
1731 };
1732
1733 enum CursorMoveStyle {
1734 LogicalMoveStyle,
1735 VisualMoveStyle
1736 };
1737
1738 enum TimerType {
1739 PreciseTimer,
1740 CoarseTimer,
1741 VeryCoarseTimer
1742 };
1743
1744 enum ScrollPhase {
1745 NoScrollPhase = 0,
1746 ScrollBegin,
1747 ScrollUpdate,
1748 ScrollEnd,
1749 ScrollMomentum
1750 };
1751
1752 enum MouseEventSource {
1753 MouseEventNotSynthesized,
1754 MouseEventSynthesizedBySystem,
1755 MouseEventSynthesizedByQt,
1756 MouseEventSynthesizedByApplication
1757 };
1758
1759 enum MouseEventFlag {
1760 MouseEventCreatedDoubleClick = 0x01,
1761 MouseEventFlagMask = 0xFF
1762 };
1763 Q_DECLARE_FLAGS(MouseEventFlags, MouseEventFlag)
1764 Q_DECLARE_OPERATORS_FOR_FLAGS(MouseEventFlags)
1765
1766 enum ChecksumType {
1767 ChecksumIso3309,
1768 ChecksumItuV41
1769 };
1770
1771 enum class HighDpiScaleFactorRoundingPolicy {
1772 Unset,
1773 Round,
1774 Ceil,
1775 Floor,
1776 RoundPreferFloor,
1777 PassThrough
1778 };
1779
1780 // QTBUG-48701
1781 enum ReturnByValueConstant { ReturnByValue }; // ### Qt 7: Remove me
1782
1783#ifndef Q_QDOC
1784 // NOTE: Generally, do not add QT_Q_ENUM if a corresponding Q_Q_FLAG exists.
1785 QT_Q_ENUM(ScrollBarPolicy)
1786 QT_Q_ENUM(FocusPolicy)
1787 QT_Q_ENUM(ContextMenuPolicy)
1788 QT_Q_ENUM(ArrowType)
1789 QT_Q_ENUM(ToolButtonStyle)
1790 QT_Q_ENUM(PenStyle)
1791 QT_Q_ENUM(PenCapStyle)
1792 QT_Q_ENUM(PenJoinStyle)
1793 QT_Q_ENUM(BrushStyle)
1794 QT_Q_ENUM(FillRule)
1795 QT_Q_ENUM(MaskMode)
1796 QT_Q_ENUM(BGMode)
1797 QT_Q_ENUM(ClipOperation)
1798 QT_Q_ENUM(SizeMode)
1799 QT_Q_ENUM(Axis)
1800 QT_Q_ENUM(Corner)
1801 QT_Q_ENUM(Edge)
1802 QT_Q_ENUM(LayoutDirection)
1803 QT_Q_ENUM(SizeHint)
1804 QT_Q_ENUM(Orientation)
1805 QT_Q_ENUM(DropAction)
1806 QT_Q_FLAG(Alignment)
1807 QT_Q_ENUM(TextFlag)
1808 QT_Q_FLAG(Orientations)
1809 QT_Q_FLAG(SplitBehavior)
1810 QT_Q_FLAG(DropActions)
1811 QT_Q_FLAG(Edges)
1812 QT_Q_FLAG(DockWidgetAreas)
1813 QT_Q_FLAG(ToolBarAreas)
1814 QT_Q_ENUM(DockWidgetArea)
1815 QT_Q_ENUM(ToolBarArea)
1816 QT_Q_ENUM(TextFormat)
1817 QT_Q_ENUM(TextElideMode)
1818 QT_Q_ENUM(DateFormat)
1819 QT_Q_ENUM(TimeSpec)
1820 QT_Q_ENUM(DayOfWeek)
1821 QT_Q_ENUM(CursorShape)
1822 QT_Q_ENUM(GlobalColor)
1823 QT_Q_ENUM(AspectRatioMode)
1824 QT_Q_ENUM(TransformationMode)
1825 QT_Q_FLAG(ImageConversionFlags)
1826 QT_Q_ENUM(Key)
1827 QT_Q_ENUM(ShortcutContext)
1828 QT_Q_ENUM(TextInteractionFlag)
1829 QT_Q_FLAG(TextInteractionFlags)
1830 QT_Q_ENUM(ItemSelectionMode)
1831 QT_Q_ENUM(ItemSelectionOperation)
1832 QT_Q_FLAG(ItemFlags)
1833 QT_Q_ENUM(CheckState)
1834 QT_Q_ENUM(ItemDataRole)
1835 QT_Q_ENUM(SortOrder)
1836 QT_Q_ENUM(CaseSensitivity)
1837 QT_Q_FLAG(MatchFlags)
1838 QT_Q_FLAG(KeyboardModifiers)
1839 QT_Q_FLAG(MouseButtons)
1840 QT_Q_ENUM(WindowType)
1841 QT_Q_ENUM(WindowState)
1842 QT_Q_ENUM(WindowModality)
1843 QT_Q_ENUM(WidgetAttribute)
1844 QT_Q_ENUM(ApplicationAttribute)
1845 QT_Q_FLAG(WindowFlags)
1846 QT_Q_FLAG(WindowStates)
1847 QT_Q_ENUM(FocusReason)
1848 QT_Q_ENUM(InputMethodHint)
1849 QT_Q_ENUM(InputMethodQuery)
1850 QT_Q_FLAG(InputMethodHints)
1851 QT_Q_ENUM(EnterKeyType)
1852 QT_Q_FLAG(InputMethodQueries)
1853 QT_Q_FLAG(TouchPointStates)
1854 QT_Q_ENUM(ScreenOrientation)
1855 QT_Q_FLAG(ScreenOrientations)
1856 QT_Q_ENUM(ConnectionType)
1857 QT_Q_ENUM(ApplicationState)
1858#ifndef QT_NO_GESTURES
1859 QT_Q_ENUM(GestureState)
1860 QT_Q_ENUM(GestureType)
1861 QT_Q_ENUM(NativeGestureType)
1862#endif
1863 QT_Q_ENUM(CursorMoveStyle)
1864 QT_Q_ENUM(TimerType)
1865 QT_Q_ENUM(ScrollPhase)
1866 QT_Q_ENUM(MouseEventSource)
1867 QT_Q_FLAG(MouseEventFlag)
1868 QT_Q_ENUM(ChecksumType)
1869 QT_Q_ENUM(HighDpiScaleFactorRoundingPolicy)
1870 QT_Q_ENUM(TabFocusBehavior)
1871#endif // Q_DOC
1872
1873}
1874#ifdef Q_MOC_RUN
1875 ;
1876#endif
1877
1878#undef QT_Q_ENUM
1879#undef QT_Q_FLAG
1880
1881typedef bool (*qInternalCallback)(void **);
1882
1883class Q_CORE_EXPORT QInternal {
1884public:
1885 enum PaintDeviceFlags {
1886 UnknownDevice = 0x00,
1887 Widget = 0x01,
1888 Pixmap = 0x02,
1889 Image = 0x03,
1890 Printer = 0x04,
1891 Picture = 0x05,
1892 Pbuffer = 0x06, // GL pbuffer
1893 FramebufferObject = 0x07, // GL framebuffer object
1894 CustomRaster = 0x08,
1895 MacQuartz = 0x09,
1896 PaintBuffer = 0x0a,
1897 OpenGL = 0x0b
1898 };
1899 enum RelayoutType {
1900 RelayoutNormal,
1901 RelayoutDragging,
1902 RelayoutDropped
1903 };
1904
1905 enum DockPosition {
1906 LeftDock,
1907 RightDock,
1908 TopDock,
1909 BottomDock,
1910 DockCount
1911 };
1912
1913 enum Callback {
1914 EventNotifyCallback,
1915 LastCallback
1916 };
1917 static bool registerCallback(Callback, qInternalCallback);
1918 static bool unregisterCallback(Callback, qInternalCallback);
1919 static bool activateCallbacks(Callback, void **);
1920};
1921
1922QT_END_NAMESPACE
1923
1924#endif // QNAMESPACE_H
1925