TachyonUI 1.1.0
High-performance UI for building tools.
Loading...
Searching...
No Matches
tachyon::GUIApplicationInitializeOptions Struct Reference

What GUIApplication::Initialize sets up besides the core systems. More...

#include <gui_controls/gui_application.h>

Public Attributes

bool loadStyles = true
 load the theme (InitializeStyles)
bool commandShortcuts = true
 route keys to commandManager's shortcuts
bool repaintWhileResizing = true
 onGui = OnFrame, unless onGui is already set
bool closeMenusOnWindowMove = true
 open menus close when a window moves or resizes
std::string_view fallbackFonts {}
 The optional fallback fonts (Noto: other scripts, emoji, symbols), relative to the resource root, e.g.
uint32_t imageSlots = 0
 How many images can be registered at once, fonts, icons and gradients included.
std::string_view gpu {}
 Which GPU to render with, when there's more than one: "integrated", "discrete", the GPU's number in the log's list, or part of its name (GraphicsContext::SetGpuPreference).
std::optional< GraphicsAPI > graphicsAPI {}
 The graphics API to render with.

Detailed Description

What GUIApplication::Initialize sets up besides the core systems.

All on by default; a host that does one itself turns it off.

Member Data Documentation

◆ loadStyles

bool tachyon::GUIApplicationInitializeOptions::loadStyles = true

load the theme (InitializeStyles)

◆ commandShortcuts

bool tachyon::GUIApplicationInitializeOptions::commandShortcuts = true

route keys to commandManager's shortcuts

◆ repaintWhileResizing

bool tachyon::GUIApplicationInitializeOptions::repaintWhileResizing = true

onGui = OnFrame, unless onGui is already set

◆ closeMenusOnWindowMove

bool tachyon::GUIApplicationInitializeOptions::closeMenusOnWindowMove = true

open menus close when a window moves or resizes

◆ fallbackFonts

std::string_view tachyon::GUIApplicationInitializeOptions::fallbackFonts {}

The optional fallback fonts (Noto: other scripts, emoji, symbols), relative to the resource root, e.g.

"fonts/Noto-otf". Empty: only the built-in fonts.

◆ imageSlots

uint32_t tachyon::GUIApplicationInitializeOptions::imageSlots = 0

How many images can be registered at once, fonts, icons and gradients included.

0: the backend's default (Vulkan: 4096). The device may hold fewer; graphicsContext->GetImageSlotCount() says how many there are.

◆ gpu

std::string_view tachyon::GUIApplicationInitializeOptions::gpu {}

Which GPU to render with, when there's more than one: "integrated", "discrete", the GPU's number in the log's list, or part of its name (GraphicsContext::SetGpuPreference).

Empty: the backend's choice, a discrete GPU first. TACHYON_GPU takes its place when set.

◆ graphicsAPI

std::optional<GraphicsAPI> tachyon::GUIApplicationInitializeOptions::graphicsAPI {}

The graphics API to render with.

Empty: the default (Metal on macOS, else Vulkan). GraphicsAPI::None: no GPU, the null backend. An API that isn't built in fails Initialize; one whose device can't start (Direct3D 12 without its runtime) falls back to the default, with a warning. A backend set with SetGraphicsBackend takes its place.


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