- cinder::app::AppBase::Settings
- cinder::app::AppCocoaTouch::Settings
Public Member Functions
-
Settings ()
Customizes some AppBase::Settings , enabling power management, high density display, and multitouch by default.
-
voidsetStatusBarEnabled (bool enable=true)
Determines whether the system status bar is visible initially. Default is
false. -
boolisStatusBarEnabled () const
Returns whether the system status bar is visible initially. Default is
false. -
voidsetWindowSize (int windowSizeX, int windowSizeY)
Sets the size of the default window measured in points.
-
voidsetWindowSize (const ivec2 &size)
Sets the size of the default window measured in points.
-
ivec2getWindowSize () const
Gets the size of the default window measured in points.
-
ivec2getWindowPos () const
Returns the position of the default window in screen coordinates measured in pixels.
-
voidsetWindowPos (int windowPosX, int windowPosY)
Sets the position of the default window in screen coordinates measured in pixels.
-
voidsetWindowPos (const ivec2 &windowPos)
Sets the position of the default window in screen coordinates measured in pixels.
-
boolisWindowPosSpecified () const
Returns whether a non-default window position has been requested.
-
voidsetWindowPosUnspecified ()
Marks the window position setting as unspecified, effectively requesting the default.
-
voidsetQuitOnLastWindowCloseEnabled (bool enable=true)
Sets whether the app quits automatically when its last window is closed. Enabled by default.
-
boolisQuitOnLastWindowCloseEnabled () const
Returns whether the app quits automatically when its last window is closed. Enabled by default.
-
boolisFullScreen () const
Returns whether the default window is fullscreen.
-
voidsetFullScreen (bool fullScreen=true, const FullScreenOptions &options=FullScreenOptions())
Sets whether the default window is fullscreen at startup with FullScreenOptions options . Kiosk Mode is enabled by default.
-
boolisResizable () const
Returns whether the default window is resizable.
-
voidsetResizable (bool resizable=true)
Sets the default window to be resizable or not.
-
boolisBorderless () const
Returns whether the default window will be created without a border (chrome/frame)
-
voidsetBorderless (bool borderless=true)
Sets the default window to be created without a border (chrome/frame)
-
boolisAlwaysOnTop () const
Returns whether the default window always remains above all other windows.
-
voidsetAlwaysOnTop (bool alwaysOnTop=true)
Sets whether the default window always remains above all other windows.
-
getDisplay () const
Returns the display for the default window.
-
voidsetDisplay (DisplayRef display)
Sets the display for the default window.
-
getDefaultWindowFormat () const
Returns the Window::Format which will be used if no calls are made to Settings::prepareWindow()
-
voidsetDefaultWindowFormat (const Window::Format &format)
Sets the Window::Format which will be used if no calls are made to Settings::prepareWindow()
-
voidsetDefaultRenderer (const RendererRef &renderer)
Sets the default Renderer , overridding what was passed in during app instantiation.
-
getDefaultRenderer () const
Returns the default Renderer .
-
voidprepareWindow (const Window::Format &format)
-
std::vector< Window::Format > &getWindowFormats ()
-
const std::vector< Window::Format > &getWindowFormats () const
-
const std::string &getTitle () const
the title of the app reflected in ways particular to the app type and platform (such as its Window or menu)
-
voidsetTitle (const std::string &title)
the title of the app reflected in ways particular to the app type and platform (such as its Window or menu)
-
voidsetHighDensityDisplayEnabled (bool enable=true)
Sets whether Windows created on a high-density (Retina) display will have their resolution doubled. Default is
trueon iOS andfalseon other platforms. -
boolisHighDensityDisplayEnabled () const
Returns whether Windows created on a high-density (Retina) display will have their resolution doubled. Default is
trueon iOS andfalseon other platforms. -
voidsetMultiTouchEnabled (bool enable=true)
Registers the app to receive multiTouch events from the operating system. Disabled by default on desktop platforms, enabled on mobile.
-
boolisMultiTouchEnabled () const
Returns whether the app is registered to receive multiTouch events from the operating system. Disabled by default on desktop platforms, enabled on mobile.
-
voidsetPowerManagementEnabled (bool enable=true)
a value of
trueallows screensavers or the system's power management to hide the app. Default value isfalseon desktop, andtrueon mobile -
boolisPowerManagementEnabled () const
is power management enabled, allowing screensavers and the system's power management to hide the application
-
voidsetFrameRate (float frameRate)
Sets maximum frameRate the update/draw loop will execute at, specified in frames per second. FrameRate limiting is on by default, at 60 FPS.
-
voiddisableFrameRate ()
Disables the frameRate limiting, which is on by default. Restore using setFrameRate() . See also enableVerticalSync() .
-
boolisFrameRateEnabled () const
Returns whether frameRate limiting is enabled. On by default, at 60 FPS.
-
floatgetFrameRate () const
Maximum frameRate of the application specified in frames per second.
-
const std::vector< std::string > &getCommandLineArgs () const
Returns the command line args passed to the application from its entry point (ex. a main's argc / argv).
-
voidsetCommandLineArgs (const std::vector< std::string > &commandLineArgs)
Primarily for internal use. Replaces the command line args.
-
voidsetShouldQuit (bool shouldQuit=true)
Set this to true if the app should terminate prior to launching.
-
boolgetShouldQuit () const
Whether or not the app should terminate prior to launching.
Protected Member Functions
Protected Attributes
-
std::vector< Window::Format >mWindowFormats
-
mDefaultWindowFormat
-
mDefaultRenderer
-
std::stringmTitle
-
std::vector< std::string >mCommandLineArgs
-
boolmFrameRateEnabled
-
floatmFrameRate
-
boolmPowerManagementEnabled
-
boolmHighDensityDisplayEnabled
-
boolmMultiTouchEnabled
-
boolmQuitOnLastWindowClose
-
boolmShouldQuit
-
friendAppBase