< Home

< Table of Contents

REFERENCE MANUAL

WindowInfoControl Class Reference

#include <hps.h>

Inheritance diagram for WindowInfoControl:
Control Object

Public Member Functions

Type ObjectType () const
 
WindowInfoControloperator= (WindowInfoControl &&in_that)
 
WindowInfoControloperator= (WindowInfoControl const &in_that)
 
bool ShowPhysicalPixels (unsigned int &out_width, unsigned int &out_height) const
 
bool ShowPhysicalSize (float &out_width, float &out_height) const
 
bool ShowPixelAspectRatio (float &out_pixel_aspect) const
 
bool ShowResolution (float &out_horizontal, float &out_vertical) const
 
bool ShowWindowAspectRatio (float &out_window_aspect) const
 
bool ShowWindowPixels (unsigned int &out_width, unsigned int &out_height) const
 
bool ShowWindowSize (float &out_width, float &out_height) const
 
 WindowInfoControl (WindowKey &in_window)
 
 WindowInfoControl (WindowInfoControl const &in_that)
 
 WindowInfoControl (WindowInfoControl &&in_that)
 
 ~WindowInfoControl ()
 
- Public Member Functions inherited from Object
virtual bool Empty () const
 
intptr_t GetClassID () const
 
intptr_t GetInstanceID () const
 
bool HasType (Type in_mask) const
 
 Object (Object &&in_that)
 
Objectoperator= (Object const &other_object)
 
Objectoperator= (Object &&in_that)
 
virtual void Reset ()
 
Type Type () const
 

Additional Inherited Members

- Static Public Member Functions inherited from Object
template<typename T >
static intptr_t ClassID ()
 
- Protected Member Functions inherited from Control
 Control (Control &&in_that)
 
Controloperator= (Control &&in_that)
 

Detailed Description

The WindowInfoControl class is a smart pointer that is tied to a database object. This object allows you to query various attributes about a window, such as its size and aspect ratio.

Constructor & Destructor Documentation

WindowInfoControl::WindowInfoControl ( WindowKey in_window)
explicit

Initializes a control tied to the window segment in_window.

WindowInfoControl::WindowInfoControl ( WindowInfoControl const &  in_that)

Initializes a control tied to the same object as in_that.

WindowInfoControl::WindowInfoControl ( WindowInfoControl &&  in_that)

The move constructor creates a WindowInfoControl by transferring the underlying impl of the rvalue reference to this WindowInfoControl thereby avoiding a copy and allocation.

Parameters
in_thatAn rvalue reference to a WindowInfoControl to take the impl from.
WindowInfoControl::~WindowInfoControl ( )

Releases a reference to the database object this control is tied to.

Member Function Documentation

Type WindowInfoControl::ObjectType ( ) const
inlinevirtual

This function returns the type the object, as declared. This does not necessarily give the true type of the underlying object.

Returns
The declared type of the object in question, which may differ from the true, underlying type.

Reimplemented from Control.

WindowInfoControl& WindowInfoControl::operator= ( WindowInfoControl &&  in_that)

The move assignment operator transfers the underlying impl of the rvalue reference to this WindowInfoControl thereby avoiding a copy.

Parameters
in_thatAn rvalue reference to a WindowInfoControl to take the impl from.
Returns
A reference to this WindowInfoControl.
WindowInfoControl& WindowInfoControl::operator= ( WindowInfoControl const &  in_that)

Share the smart-pointer.

bool WindowInfoControl::ShowPhysicalPixels ( unsigned int &  out_width,
unsigned int &  out_height 
) const

Shows the number of pixels in the physical display (monitor, off-screen renderer, printer, etc.).

Parameters
out_widthThe width of the physical display in pixels.
out_heightThe height of the physical display in pixels.
Returns
true if the setting is valid, false otherwise.
bool WindowInfoControl::ShowPhysicalSize ( float &  out_width,
float &  out_height 
) const

Shows the size, in centimeters, of the physical display (monitor, off-screen renderer, printer, etc.).

Parameters
out_widthThe width of the physical display in centimeters.
out_heightThe height of the physical display in centimeters.
Returns
true if the setting is valid, false otherwise.
bool WindowInfoControl::ShowPixelAspectRatio ( float &  out_pixel_aspect) const

Shows the aspect ratio of the window's pixels. This is computed as the horizontal resolution divided by the vertical resolution.

Parameters
out_pixel_aspectThe aspect ratio of the window defined as width / height in pixels.
Returns
true if the setting is valid, false otherwise.
bool WindowInfoControl::ShowResolution ( float &  out_horizontal,
float &  out_vertical 
) const

Shows both the horizontal and vertical resolution of the window. Resolution is computed as pixels per centimeter. If the size or the pixels are not set, this function will return false.

Parameters
out_horizontalThe horizontal resolution of the window.
out_verticalThe vertical resolution of the window.
Returns
true if the setting is valid, false otherwise.
bool WindowInfoControl::ShowWindowAspectRatio ( float &  out_window_aspect) const

Shows the aspect ratio of the window. Aspect ratio is computed as width / height in centimeters.

Parameters
out_window_aspectThe aspect ratio of the window defined as width / height in centimeters.
Returns
true if the setting is valid, false otherwise.
bool WindowInfoControl::ShowWindowPixels ( unsigned int &  out_width,
unsigned int &  out_height 
) const

Shows the number of pixels in the window.

Parameters
out_widthThe width of the window in pixels.
out_heightThe height of the window in pixels.
Returns
true if the setting is valid, false otherwise.
bool WindowInfoControl::ShowWindowSize ( float &  out_width,
float &  out_height 
) const

Shows the size, in centimeters, of the window.

Parameters
out_widthThe width of the window in centimeters.
out_heightThe height of the window in centimeters.
Returns
true if the setting is valid, false otherwise.

The documentation for this class was generated from the following file: