From 1587d75b5e960854be17a017e8fc1cde03ed8058 Mon Sep 17 00:00:00 2001 From: Andreas Buhr Date: Thu, 24 Jun 2021 10:58:19 +0200 Subject: Consistent indentation for all Q_PROPERTYs Task-number: QTBUG-94407 Pick-to: 6.2 Change-Id: I8c97a0b2de2bed78456322be271724fc47479d83 Reviewed-by: Ivan Solovev Reviewed-by: Edward Welbourne --- src/gui/kernel/qaction.h | 12 ++++++++---- src/gui/kernel/qevent.h | 3 ++- src/gui/kernel/qguiapplication.h | 9 ++++++--- src/gui/kernel/qinputdevice.h | 3 ++- src/gui/kernel/qinputmethod.h | 3 ++- src/gui/kernel/qscreen.h | 12 ++++++++---- src/gui/kernel/qstylehints.h | 25 +++++++++++++++++-------- src/gui/kernel/qwindow.h | 15 ++++++++++----- 8 files changed, 55 insertions(+), 27 deletions(-) (limited to 'src/gui') diff --git a/src/gui/kernel/qaction.h b/src/gui/kernel/qaction.h index 865e5c5eb0..fc8b4a104f 100644 --- a/src/gui/kernel/qaction.h +++ b/src/gui/kernel/qaction.h @@ -68,7 +68,8 @@ class Q_GUI_EXPORT QAction : public QObject Q_PROPERTY(bool checkable READ isCheckable WRITE setCheckable NOTIFY checkableChanged FINAL) Q_PROPERTY(bool checked READ isChecked WRITE setChecked NOTIFY toggled) - Q_PROPERTY(bool enabled READ isEnabled WRITE setEnabled NOTIFY enabledChanged RESET resetEnabled FINAL) + Q_PROPERTY(bool enabled READ isEnabled WRITE setEnabled NOTIFY enabledChanged + RESET resetEnabled FINAL) Q_PROPERTY(QIcon icon READ icon WRITE setIcon NOTIFY changed) Q_PROPERTY(QString text READ text WRITE setText NOTIFY changed) Q_PROPERTY(QString iconText READ iconText WRITE setIconText NOTIFY changed) @@ -78,13 +79,16 @@ class Q_GUI_EXPORT QAction : public QObject Q_PROPERTY(QFont font READ font WRITE setFont NOTIFY changed) #if QT_CONFIG(shortcut) Q_PROPERTY(QKeySequence shortcut READ shortcut WRITE setShortcut NOTIFY changed) - Q_PROPERTY(Qt::ShortcutContext shortcutContext READ shortcutContext WRITE setShortcutContext NOTIFY changed) + Q_PROPERTY(Qt::ShortcutContext shortcutContext READ shortcutContext WRITE setShortcutContext + NOTIFY changed) Q_PROPERTY(bool autoRepeat READ autoRepeat WRITE setAutoRepeat NOTIFY changed) #endif // QT_CONFIG(shortcut) Q_PROPERTY(bool visible READ isVisible WRITE setVisible NOTIFY visibleChanged FINAL) Q_PROPERTY(MenuRole menuRole READ menuRole WRITE setMenuRole NOTIFY changed) - Q_PROPERTY(bool iconVisibleInMenu READ isIconVisibleInMenu WRITE setIconVisibleInMenu NOTIFY changed) - Q_PROPERTY(bool shortcutVisibleInContextMenu READ isShortcutVisibleInContextMenu WRITE setShortcutVisibleInContextMenu NOTIFY changed) + Q_PROPERTY(bool iconVisibleInMenu READ isIconVisibleInMenu WRITE setIconVisibleInMenu + NOTIFY changed) + Q_PROPERTY(bool shortcutVisibleInContextMenu READ isShortcutVisibleInContextMenu + WRITE setShortcutVisibleInContextMenu NOTIFY changed) Q_PROPERTY(Priority priority READ priority WRITE setPriority) public: diff --git a/src/gui/kernel/qevent.h b/src/gui/kernel/qevent.h index db886bdd98..6f38ef8d82 100644 --- a/src/gui/kernel/qevent.h +++ b/src/gui/kernel/qevent.h @@ -139,7 +139,8 @@ protected: class Q_GUI_EXPORT QSinglePointEvent : public QPointerEvent { Q_GADGET - Q_PROPERTY(QObject *exclusivePointGrabber READ exclusivePointGrabber WRITE setExclusivePointGrabber) + Q_PROPERTY(QObject *exclusivePointGrabber READ exclusivePointGrabber + WRITE setExclusivePointGrabber) Q_EVENT_DISABLE_COPY(QSinglePointEvent); public: diff --git a/src/gui/kernel/qguiapplication.h b/src/gui/kernel/qguiapplication.h index 02d0376e77..ba3d464bc8 100644 --- a/src/gui/kernel/qguiapplication.h +++ b/src/gui/kernel/qguiapplication.h @@ -73,11 +73,14 @@ class Q_GUI_EXPORT QGuiApplication : public QCoreApplication { Q_OBJECT Q_PROPERTY(QIcon windowIcon READ windowIcon WRITE setWindowIcon) - Q_PROPERTY(QString applicationDisplayName READ applicationDisplayName WRITE setApplicationDisplayName NOTIFY applicationDisplayNameChanged) + Q_PROPERTY(QString applicationDisplayName READ applicationDisplayName + WRITE setApplicationDisplayName NOTIFY applicationDisplayNameChanged) Q_PROPERTY(QString desktopFileName READ desktopFileName WRITE setDesktopFileName) - Q_PROPERTY(Qt::LayoutDirection layoutDirection READ layoutDirection WRITE setLayoutDirection NOTIFY layoutDirectionChanged) + Q_PROPERTY(Qt::LayoutDirection layoutDirection READ layoutDirection WRITE setLayoutDirection + NOTIFY layoutDirectionChanged) Q_PROPERTY(QString platformName READ platformName STORED false) - Q_PROPERTY(bool quitOnLastWindowClosed READ quitOnLastWindowClosed WRITE setQuitOnLastWindowClosed) + Q_PROPERTY(bool quitOnLastWindowClosed READ quitOnLastWindowClosed + WRITE setQuitOnLastWindowClosed) Q_PROPERTY(QScreen *primaryScreen READ primaryScreen NOTIFY primaryScreenChanged STORED false) public: diff --git a/src/gui/kernel/qinputdevice.h b/src/gui/kernel/qinputdevice.h index 0389c7856e..2fe69943bf 100644 --- a/src/gui/kernel/qinputdevice.h +++ b/src/gui/kernel/qinputdevice.h @@ -58,7 +58,8 @@ class Q_GUI_EXPORT QInputDevice : public QObject Q_PROPERTY(Capabilities capabilities READ capabilities CONSTANT) Q_PROPERTY(qint64 systemId READ systemId CONSTANT) Q_PROPERTY(QString seatName READ seatName CONSTANT) - Q_PROPERTY(QRect availableVirtualGeometry READ availableVirtualGeometry NOTIFY availableVirtualGeometryChanged) + Q_PROPERTY(QRect availableVirtualGeometry READ availableVirtualGeometry + NOTIFY availableVirtualGeometryChanged) public: enum class DeviceType { diff --git a/src/gui/kernel/qinputmethod.h b/src/gui/kernel/qinputmethod.h index 8f5eca3886..32831573a4 100644 --- a/src/gui/kernel/qinputmethod.h +++ b/src/gui/kernel/qinputmethod.h @@ -58,7 +58,8 @@ class Q_GUI_EXPORT QInputMethod : public QObject Q_PROPERTY(QRectF cursorRectangle READ cursorRectangle NOTIFY cursorRectangleChanged) Q_PROPERTY(QRectF anchorRectangle READ anchorRectangle NOTIFY anchorRectangleChanged) Q_PROPERTY(QRectF keyboardRectangle READ keyboardRectangle NOTIFY keyboardRectangleChanged) - Q_PROPERTY(QRectF inputItemClipRectangle READ inputItemClipRectangle NOTIFY inputItemClipRectangleChanged) + Q_PROPERTY(QRectF inputItemClipRectangle READ inputItemClipRectangle + NOTIFY inputItemClipRectangleChanged) Q_PROPERTY(bool visible READ isVisible NOTIFY visibleChanged) Q_PROPERTY(bool animating READ isAnimating NOTIFY animatingChanged) Q_PROPERTY(QLocale locale READ locale NOTIFY localeChanged) diff --git a/src/gui/kernel/qscreen.h b/src/gui/kernel/qscreen.h index 98271c0aa0..33778786e5 100644 --- a/src/gui/kernel/qscreen.h +++ b/src/gui/kernel/qscreen.h @@ -81,16 +81,20 @@ class Q_GUI_EXPORT QScreen : public QObject Q_PROPERTY(QRect geometry READ geometry NOTIFY geometryChanged) Q_PROPERTY(QRect availableGeometry READ availableGeometry NOTIFY availableGeometryChanged) Q_PROPERTY(QRect virtualGeometry READ virtualGeometry NOTIFY virtualGeometryChanged) - Q_PROPERTY(QRect availableVirtualGeometry READ availableVirtualGeometry NOTIFY virtualGeometryChanged) + Q_PROPERTY(QRect availableVirtualGeometry READ availableVirtualGeometry + NOTIFY virtualGeometryChanged) Q_PROPERTY(QSizeF physicalSize READ physicalSize NOTIFY physicalSizeChanged) - Q_PROPERTY(qreal physicalDotsPerInchX READ physicalDotsPerInchX NOTIFY physicalDotsPerInchChanged) - Q_PROPERTY(qreal physicalDotsPerInchY READ physicalDotsPerInchY NOTIFY physicalDotsPerInchChanged) + Q_PROPERTY(qreal physicalDotsPerInchX READ physicalDotsPerInchX + NOTIFY physicalDotsPerInchChanged) + Q_PROPERTY(qreal physicalDotsPerInchY READ physicalDotsPerInchY + NOTIFY physicalDotsPerInchChanged) Q_PROPERTY(qreal physicalDotsPerInch READ physicalDotsPerInch NOTIFY physicalDotsPerInchChanged) Q_PROPERTY(qreal logicalDotsPerInchX READ logicalDotsPerInchX NOTIFY logicalDotsPerInchChanged) Q_PROPERTY(qreal logicalDotsPerInchY READ logicalDotsPerInchY NOTIFY logicalDotsPerInchChanged) Q_PROPERTY(qreal logicalDotsPerInch READ logicalDotsPerInch NOTIFY logicalDotsPerInchChanged) Q_PROPERTY(qreal devicePixelRatio READ devicePixelRatio NOTIFY physicalDotsPerInchChanged) - Q_PROPERTY(Qt::ScreenOrientation primaryOrientation READ primaryOrientation NOTIFY primaryOrientationChanged) + Q_PROPERTY(Qt::ScreenOrientation primaryOrientation READ primaryOrientation + NOTIFY primaryOrientationChanged) Q_PROPERTY(Qt::ScreenOrientation orientation READ orientation NOTIFY orientationChanged) Q_PROPERTY(Qt::ScreenOrientation nativeOrientation READ nativeOrientation) Q_PROPERTY(qreal refreshRate READ refreshRate NOTIFY refreshRateChanged) diff --git a/src/gui/kernel/qstylehints.h b/src/gui/kernel/qstylehints.h index 30d8fdc64d..c2d5d87d31 100644 --- a/src/gui/kernel/qstylehints.h +++ b/src/gui/kernel/qstylehints.h @@ -56,25 +56,34 @@ class Q_GUI_EXPORT QStyleHints : public QObject Q_PROPERTY(int cursorFlashTime READ cursorFlashTime NOTIFY cursorFlashTimeChanged FINAL) Q_PROPERTY(qreal fontSmoothingGamma READ fontSmoothingGamma STORED false CONSTANT FINAL) Q_PROPERTY(int keyboardAutoRepeatRate READ keyboardAutoRepeatRate STORED false CONSTANT FINAL) - Q_PROPERTY(int keyboardInputInterval READ keyboardInputInterval NOTIFY keyboardInputIntervalChanged FINAL) - Q_PROPERTY(int mouseDoubleClickInterval READ mouseDoubleClickInterval NOTIFY mouseDoubleClickIntervalChanged FINAL) - Q_PROPERTY(int mousePressAndHoldInterval READ mousePressAndHoldInterval NOTIFY mousePressAndHoldIntervalChanged FINAL) + Q_PROPERTY(int keyboardInputInterval READ keyboardInputInterval + NOTIFY keyboardInputIntervalChanged FINAL) + Q_PROPERTY(int mouseDoubleClickInterval READ mouseDoubleClickInterval + NOTIFY mouseDoubleClickIntervalChanged FINAL) + Q_PROPERTY(int mousePressAndHoldInterval READ mousePressAndHoldInterval + NOTIFY mousePressAndHoldIntervalChanged FINAL) Q_PROPERTY(QChar passwordMaskCharacter READ passwordMaskCharacter STORED false CONSTANT FINAL) Q_PROPERTY(int passwordMaskDelay READ passwordMaskDelay STORED false CONSTANT FINAL) Q_PROPERTY(bool setFocusOnTouchRelease READ setFocusOnTouchRelease STORED false CONSTANT FINAL) Q_PROPERTY(bool showIsFullScreen READ showIsFullScreen STORED false CONSTANT FINAL) Q_PROPERTY(bool showIsMaximized READ showIsMaximized STORED false CONSTANT FINAL) - Q_PROPERTY(bool showShortcutsInContextMenus READ showShortcutsInContextMenus WRITE setShowShortcutsInContextMenus NOTIFY showShortcutsInContextMenusChanged FINAL) + Q_PROPERTY(bool showShortcutsInContextMenus READ showShortcutsInContextMenus + WRITE setShowShortcutsInContextMenus NOTIFY showShortcutsInContextMenusChanged FINAL) Q_PROPERTY(int startDragDistance READ startDragDistance NOTIFY startDragDistanceChanged FINAL) Q_PROPERTY(int startDragTime READ startDragTime NOTIFY startDragTimeChanged FINAL) Q_PROPERTY(int startDragVelocity READ startDragVelocity STORED false CONSTANT FINAL) Q_PROPERTY(bool useRtlExtensions READ useRtlExtensions STORED false CONSTANT FINAL) - Q_PROPERTY(Qt::TabFocusBehavior tabFocusBehavior READ tabFocusBehavior NOTIFY tabFocusBehaviorChanged FINAL) + Q_PROPERTY(Qt::TabFocusBehavior tabFocusBehavior READ tabFocusBehavior + NOTIFY tabFocusBehaviorChanged FINAL) Q_PROPERTY(bool singleClickActivation READ singleClickActivation STORED false CONSTANT FINAL) - Q_PROPERTY(bool useHoverEffects READ useHoverEffects WRITE setUseHoverEffects NOTIFY useHoverEffectsChanged FINAL) + Q_PROPERTY(bool useHoverEffects READ useHoverEffects WRITE setUseHoverEffects + NOTIFY useHoverEffectsChanged FINAL) Q_PROPERTY(int wheelScrollLines READ wheelScrollLines NOTIFY wheelScrollLinesChanged FINAL) - Q_PROPERTY(int mouseQuickSelectionThreshold READ mouseQuickSelectionThreshold WRITE setMouseQuickSelectionThreshold NOTIFY mouseQuickSelectionThresholdChanged FINAL) - Q_PROPERTY(int mouseDoubleClickDistance READ mouseDoubleClickDistance STORED false CONSTANT FINAL) + Q_PROPERTY(int mouseQuickSelectionThreshold READ mouseQuickSelectionThreshold + WRITE setMouseQuickSelectionThreshold NOTIFY mouseQuickSelectionThresholdChanged + FINAL) + Q_PROPERTY(int mouseDoubleClickDistance READ mouseDoubleClickDistance STORED false CONSTANT + FINAL) Q_PROPERTY(int touchDoubleTapDistance READ touchDoubleTapDistance STORED false CONSTANT FINAL) public: diff --git a/src/gui/kernel/qwindow.h b/src/gui/kernel/qwindow.h index 6200727789..d20694f625 100644 --- a/src/gui/kernel/qwindow.h +++ b/src/gui/kernel/qwindow.h @@ -118,18 +118,23 @@ class Q_GUI_EXPORT QWindow : public QObject, public QSurface Q_PROPERTY(int width READ width WRITE setWidth NOTIFY widthChanged) Q_PROPERTY(int height READ height WRITE setHeight NOTIFY heightChanged) Q_PROPERTY(int minimumWidth READ minimumWidth WRITE setMinimumWidth NOTIFY minimumWidthChanged) - Q_PROPERTY(int minimumHeight READ minimumHeight WRITE setMinimumHeight NOTIFY minimumHeightChanged) + Q_PROPERTY(int minimumHeight READ minimumHeight WRITE setMinimumHeight + NOTIFY minimumHeightChanged) Q_PROPERTY(int maximumWidth READ maximumWidth WRITE setMaximumWidth NOTIFY maximumWidthChanged) - Q_PROPERTY(int maximumHeight READ maximumHeight WRITE setMaximumHeight NOTIFY maximumHeightChanged) + Q_PROPERTY(int maximumHeight READ maximumHeight WRITE setMaximumHeight + NOTIFY maximumHeightChanged) Q_PROPERTY(bool visible READ isVisible WRITE setVisible NOTIFY visibleChanged) Q_PROPERTY(bool active READ isActive NOTIFY activeChanged REVISION(2, 1)) - Q_PROPERTY(Visibility visibility READ visibility WRITE setVisibility NOTIFY visibilityChanged REVISION(2, 1)) - Q_PROPERTY(Qt::ScreenOrientation contentOrientation READ contentOrientation WRITE reportContentOrientationChange NOTIFY contentOrientationChanged) + Q_PROPERTY(Visibility visibility READ visibility WRITE setVisibility NOTIFY visibilityChanged + REVISION(2, 1)) + Q_PROPERTY(Qt::ScreenOrientation contentOrientation READ contentOrientation + WRITE reportContentOrientationChange NOTIFY contentOrientationChanged) Q_PROPERTY(qreal opacity READ opacity WRITE setOpacity NOTIFY opacityChanged REVISION(2, 1)) #ifdef Q_QDOC Q_PROPERTY(QWindow* transientParent READ transientParent WRITE setTransientParent NOTIFY transientParentChanged) #else - Q_PRIVATE_PROPERTY(QWindow::d_func(), QWindow* transientParent MEMBER transientParent WRITE setTransientParent NOTIFY transientParentChanged REVISION(2, 13)) + Q_PRIVATE_PROPERTY(QWindow::d_func(), QWindow* transientParent MEMBER transientParent + WRITE setTransientParent NOTIFY transientParentChanged REVISION(2, 13)) #endif public: -- cgit v1.2.1