| Home · All Classes · Main Classes · Deprecated |
The MDeviceProfile class holds physical and simulated properties of the target device. More...
Inherits QObject.
Public Member Functions | |
| MDeviceProfile (QObject *parent=0) | |
| virtual | ~MDeviceProfile () |
| QSize | resolution () const |
| QSize | pixelsPerInch () const |
| bool | showStatusbar () const |
| M::Orientation | orientationFromAngle (M::OrientationAngle angle) const |
| bool | orientationAngleIsSupported (M::OrientationAngle angle, bool isKeyboardOpen) const |
| int | mmToPixels (qreal mm) |
| qreal | mmToPixelsF (qreal mm) |
| int | ptToPixels (qreal pt) |
| qreal | ptToPixelsF (qreal pt) |
| int | pixelsToPt (int pixels) |
| qreal | pixelsToPtF (qreal pixels) |
Static Public Member Functions | |
| static MDeviceProfile * | instance () |
Protected Attributes | |
| MDeviceProfilePrivate *const | d_ptr |
The MDeviceProfile class holds physical and simulated properties of the target device.
| MDeviceProfile::MDeviceProfile | ( | QObject * | parent = 0 |
) |
Default constructor.
Only used by MApplication class. Client classes should be using MDeviceProfile::instance() method.
| MDeviceProfile::~MDeviceProfile | ( | ) | [virtual] |
Default destructor.
| MDeviceProfile * MDeviceProfile::instance | ( | ) | [static] |
Returns the global MDeviceProfile instance.
| int MDeviceProfile::mmToPixels | ( | qreal | mm | ) |
Returns the number of pixels required to display a length of mm millimeters on this device.
| qreal MDeviceProfile::mmToPixelsF | ( | qreal | mm | ) |
Returns the number of pixels required to display a length of mm millimeters on this device using floating point precision.
| bool MDeviceProfile::orientationAngleIsSupported | ( | M::OrientationAngle | angle, | |
| bool | isKeyboardOpen | |||
| ) | const |
Returns true if orientation angle is supported for given keyboard state.
| M::Orientation MDeviceProfile::orientationFromAngle | ( | M::OrientationAngle | angle | ) | const |
Returns the resulting orientation of a device for a given rotation angle.
The rotation is relative to the position where the device's display has its top edge on top.
For devices whose display native resolution is landscape:
For devices whose display native resolution is portrait:
orientationFromAngle(M::Angle0) returns the display's native orientation.
| QSize MDeviceProfile::pixelsPerInch | ( | ) | const |
Return the target device pixels per inch.
| int MDeviceProfile::pixelsToPt | ( | int | pixels | ) |
Returns the result of pixels to points conversion.
| qreal MDeviceProfile::pixelsToPtF | ( | qreal | pixels | ) |
Returns the result of pixels to points conversion.
| int MDeviceProfile::ptToPixels | ( | qreal | pt | ) |
Returns point size in pixels on this device.
| qreal MDeviceProfile::ptToPixelsF | ( | qreal | pt | ) |
Returns point size in pixels using floating point precision on this device.
| QSize MDeviceProfile::resolution | ( | ) | const |
Return the target device resolution.
| bool MDeviceProfile::showStatusbar | ( | ) | const |
Return whether the status bar should be shown on target device.
MDeviceProfilePrivate* const MDeviceProfile::d_ptr [protected] |
| Copyright © 2010 Nokia Corporation | MeeGo Touch |