App

Application class.

Header#include "nativeui/app.h"
Namespacenamespace nu
Typeclass

This class represents current app and provides app wide APIs.

This class can not be created by user, you must create State first and then receive an instance of App via App::GetCurrent.

nu::State state;
nu::App* app = nu::App::GetCurrent();

Class methods

App* GetCurrent()

Return current app.

Return

App*

Methods

void SetApplicationMenu(MenuBar* menu) macOS

Set the application menu bar.

Parameters

MenuBar* GetApplicationMenu() const macOS

Return the application menu bar.

Return

MenuBar*

Color GetColor(App::ThemeColor name)

Return color of a theme component.

Parameters

Return

Color

Font* GetDefaultFont()

Return the default font for displaying text.

Return

Font*