![]() |
Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
|
#include <qcocoascreen.h>
Public Member Functions | |
~QCocoaScreen () | |
QPixmap | grabWindow (WId window, int x, int y, int width, int height) const override |
QRect | geometry () const override |
Reimplement in subclass to return the pixel geometry of the screen. | |
QRect | availableGeometry () const override |
Reimplement in subclass to return the pixel geometry of the available space This normally is the desktop screen minus the task manager, global menubar etc. | |
int | depth () const override |
Reimplement in subclass to return current depth of the screen. | |
QImage::Format | format () const override |
Reimplement in subclass to return the image format which corresponds to the screen format. | |
QColorSpace | colorSpace () const override |
qreal | devicePixelRatio () const override |
Reimplement this function in subclass to return the device pixel ratio for the screen. | |
QSizeF | physicalSize () const override |
Reimplement this function in subclass to return the physical size of the screen, in millimeters. | |
QDpi | logicalBaseDpi () const override |
Reimplement to return the base logical DPI for the platform. | |
qreal | refreshRate () const override |
Reimplement this function in subclass to return the vertical refresh rate of the screen, in Hz. | |
QString | name () const override |
QPlatformCursor * | cursor () const override |
Reimplement this function in subclass to return the cursor of the screen. | |
QWindow * | topLevelAt (const QPoint &point) const override |
Return the given top level window for a given position. | |
QList< QPlatformScreen * > | virtualSiblings () const override |
Returns a list of all the platform screens that are part of the same virtual desktop. | |
QPlatformScreen::SubpixelAntialiasingType | subpixelAntialiasingTypeHint () const override |
Returns a hint about this screen's subpixel layout structure. | |
Qt::ScreenOrientation | orientation () const override |
Reimplement this function in subclass to return the current orientation of the screen, for example based on accelerometer data to determine the device orientation. | |
NSScreen * | nativeScreen () const override |
bool | requestUpdate () |
void | deliverUpdateRequests () |
Public Member Functions inherited from QPlatformScreen | |
QPlatformScreen () | |
virtual | ~QPlatformScreen () |
virtual bool | isPlaceholder () const |
virtual QDpi | logicalDpi () const |
Reimplement this function in subclass to return the logical horizontal and vertical dots per inch metrics of the screen. | |
virtual Qt::ScreenOrientation | nativeOrientation () const |
Reimplement this function in subclass to return the native orientation of the screen, e.g. | |
QWindowList | windows () const |
Return all windows residing on this screen. | |
const QPlatformScreen * | screenForPosition (const QPoint &point) const |
Find the sibling screen corresponding to globalPos. | |
QScreen * | screen () const |
virtual QString | manufacturer () const |
Reimplement this function in subclass to return the manufacturer of this screen. | |
virtual QString | model () const |
Reimplement this function in subclass to return the model of this screen. | |
virtual QString | serialNumber () const |
Reimplement this function in subclass to return the serial number of this screen. | |
virtual PowerState | powerState () const |
Returns the current power state. | |
virtual void | setPowerState (PowerState state) |
Sets the power state for this screen. | |
virtual QList< Mode > | modes () const |
Reimplement this function in subclass to return the list of modes for this screen. | |
virtual int | currentMode () const |
Reimplement this function in subclass to return the index of the current mode from the modes list. | |
virtual int | preferredMode () const |
Reimplement this function in subclass to return the preferred mode index from the modes list. |
Friends | |
class | QCocoaIntegration |
class | QCocoaWindow |
QDebug | operator<< (QDebug debug, const QCocoaScreen *screen) |
Additional Inherited Members | |
Public Types inherited from QPlatformScreen | |
enum | SubpixelAntialiasingType { Subpixel_None , Subpixel_RGB , Subpixel_BGR , Subpixel_VRGB , Subpixel_VBGR } |
enum | PowerState { PowerStateOn , PowerStateStandby , PowerStateSuspend , PowerStateOff } |
Protected Member Functions inherited from QPlatformScreen | |
void | resizeMaximizedWindows () |
Convenience method to resize all the maximized and fullscreen windows of this platform screen. | |
Protected Attributes inherited from QPlatformScreen | |
QScopedPointer< QPlatformScreenPrivate > | d_ptr |
Definition at line 23 of file qcocoascreen.h.
QCocoaScreen::~QCocoaScreen | ( | ) |
Definition at line 194 of file qcocoascreen.mm.
|
inlineoverridevirtual |
Reimplement in subclass to return the pixel geometry of the available space This normally is the desktop screen minus the task manager, global menubar etc.
Reimplemented from QPlatformScreen.
Definition at line 32 of file qcocoascreen.h.
|
inlineoverridevirtual |
Reimplemented from QPlatformScreen.
Definition at line 35 of file qcocoascreen.h.
|
inlineoverridevirtual |
Reimplement this function in subclass to return the cursor of the screen.
The default implementation returns \nullptr.
Reimplemented from QPlatformScreen.
Definition at line 41 of file qcocoascreen.h.
void QCocoaScreen::deliverUpdateRequests | ( | ) |
Definition at line 378 of file qcocoascreen.mm.
References DeferredDebugHelper::debug, and DeferredDebugHelper::flushOutput().
|
inlineoverridevirtual |
Reimplement in subclass to return current depth of the screen.
Implements QPlatformScreen.
Definition at line 33 of file qcocoascreen.h.
|
inlineoverridevirtual |
Reimplement this function in subclass to return the device pixel ratio for the screen.
This is the ratio between physical pixels and the device-independent pixels of the windowing system. The default implementation returns 1.0.
Reimplemented from QPlatformScreen.
Definition at line 36 of file qcocoascreen.h.
|
inlineoverridevirtual |
Reimplement in subclass to return the image format which corresponds to the screen format.
Implements QPlatformScreen.
Definition at line 34 of file qcocoascreen.h.
|
inlineoverridevirtual |
Reimplement in subclass to return the pixel geometry of the screen.
Implements QPlatformScreen.
Definition at line 31 of file qcocoascreen.h.
|
static |
Definition at line 772 of file qcocoascreen.mm.
|
static |
Definition at line 761 of file qcocoascreen.mm.
|
static |
Definition at line 746 of file qcocoascreen.mm.
|
overridevirtual |
Coordinates are in screen coordinates if view is 0, otherwise they are in view coordinates.
Reimplemented from QPlatformScreen.
Definition at line 601 of file qcocoascreen.mm.
|
inlineoverridevirtual |
Reimplement to return the base logical DPI for the platform.
This DPI value should correspond to a standard-DPI (1x) display. The default implementation returns 96.
QtGui will use this value (together with logicalDpi) to compute the scale factor when high-DPI scaling is enabled, as follows: factor = logicalDPI / baseDPI
Reimplemented from QPlatformScreen.
Definition at line 38 of file qcocoascreen.h.
|
static |
Definition at line 819 of file qcocoascreen.mm.
|
static |
Definition at line 825 of file qcocoascreen.mm.
|
static |
Definition at line 807 of file qcocoascreen.mm.
|
static |
Definition at line 813 of file qcocoascreen.mm.
|
inlineoverridevirtual |
Reimplemented from QPlatformScreen.
Definition at line 40 of file qcocoascreen.h.
|
override |
Definition at line 799 of file qcocoascreen.mm.
|
static |
Definition at line 790 of file qcocoascreen.mm.
|
overridevirtual |
Reimplement this function in subclass to return the current orientation of the screen, for example based on accelerometer data to determine the device orientation.
The default implementation returns Qt::PrimaryOrientation.
Reimplemented from QPlatformScreen.
Definition at line 541 of file qcocoascreen.mm.
|
inlineoverridevirtual |
Reimplement this function in subclass to return the physical size of the screen, in millimeters.
The physical size represents the actual physical dimensions of the display.
The default implementation takes the pixel size of the screen, considers a resolution of 100 dots per inch, and returns the calculated physical size. A device with a screen that has different resolutions will need to be supported by a suitable reimplementation of this function.
Reimplemented from QPlatformScreen.
Definition at line 37 of file qcocoascreen.h.
|
static |
The screen used as a reference for global window geometry.
Definition at line 727 of file qcocoascreen.mm.
|
inlineoverridevirtual |
Reimplement this function in subclass to return the vertical refresh rate of the screen, in Hz.
The default returns 60, a sensible default for modern displays.
Reimplemented from QPlatformScreen.
Definition at line 39 of file qcocoascreen.h.
bool QCocoaScreen::requestUpdate | ( | ) |
Definition at line 267 of file qcocoascreen.mm.
|
overridevirtual |
Returns a hint about this screen's subpixel layout structure.
The default implementation queries the {QT_SUBPIXEL_AA_TYPE} env variable. This is just a hint because most platforms don't have a way to retrieve the correct value from hardware and instead rely on font configurations.
Reimplemented from QPlatformScreen.
Definition at line 531 of file qcocoascreen.mm.
Return the given top level window for a given position.
Default implementation retrieves a list of all top level windows and finds the first window which contains point pos
Reimplemented from QPlatformScreen.
Definition at line 554 of file qcocoascreen.mm.
|
overridevirtual |
Returns a list of all the platform screens that are part of the same virtual desktop.
Screens part of the same virtual desktop share a common coordinate system, and windows can be freely moved between them.
Reimplemented from QPlatformScreen.
Definition at line 735 of file qcocoascreen.mm.
|
friend |
Definition at line 832 of file qcocoascreen.mm.
|
friend |
Definition at line 105 of file qcocoascreen.h.
|
friend |
Definition at line 106 of file qcocoascreen.h.