Ember
Loading...
Searching...
No Matches
EmberUI::ScalableDialog Class Reference

DPI-aware dialog base class for scalable layouts. More...

#include <ScalableDialog.h>

Inheritance diagram for EmberUI::ScalableDialog:
BehaviorTreeProjectDialog EmberForge::OverrideSceneDialog LoadingDialog ParserConfigDialog PreferencesDialog ProjectManagerDialog

Public Member Functions

 ScalableDialog (wxWindow *parent, wxWindowID id, const wxString &title, const wxSize &logicalSize=wxDefaultSize, long style=wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER)
 Constructs the dialog with logical size for DPI scaling.
virtual ~ScalableDialog ()=default

Protected Member Functions

int Scaled (int px) const
 Scales a logical pixel value to physical pixels.
wxSize Scaled (const wxSize &size) const
 Scales a logical size to physical pixels.
int Margin () const
 Returns the standard margin in physical pixels.
int Spacing () const
 Returns the standard spacing in physical pixels.
int Padding () const
 Returns the standard padding in physical pixels.
wxStaticBoxSizer * CreateGroup (wxWindow *parent, const wxString &title)
 Creates a grouped section with a title.
wxBoxSizer * CreateLabeledRow (wxWindow *parent, const wxString &label, wxWindow *control, int logicalLabelWidth=Layout::LABEL_WIDTH)
 Creates a row with a label and control.

Detailed Description

DPI-aware dialog base class for scalable layouts.

Definition at line 14 of file ScalableDialog.h.

Constructor & Destructor Documentation

◆ ScalableDialog()

EmberUI::ScalableDialog::ScalableDialog ( wxWindow * parent,
wxWindowID id,
const wxString & title,
const wxSize & logicalSize = wxDefaultSize,
long style = wxDEFAULT_DIALOG_STYLE | wxRESIZE_BORDER )

Constructs the dialog with logical size for DPI scaling.

Definition at line 5 of file ScalableDialog.cpp.

◆ ~ScalableDialog()

virtual EmberUI::ScalableDialog::~ScalableDialog ( )
virtualdefault

Member Function Documentation

◆ CreateGroup()

wxStaticBoxSizer * EmberUI::ScalableDialog::CreateGroup ( wxWindow * parent,
const wxString & title )
protected

Creates a grouped section with a title.

Definition at line 24 of file ScalableDialog.cpp.

◆ CreateLabeledRow()

wxBoxSizer * EmberUI::ScalableDialog::CreateLabeledRow ( wxWindow * parent,
const wxString & label,
wxWindow * control,
int logicalLabelWidth = Layout::LABEL_WIDTH )
protected

Creates a row with a label and control.

Definition at line 28 of file ScalableDialog.cpp.

◆ Margin()

int EmberUI::ScalableDialog::Margin ( ) const
protected

Returns the standard margin in physical pixels.

Definition at line 18 of file ScalableDialog.cpp.

◆ Padding()

int EmberUI::ScalableDialog::Padding ( ) const
protected

Returns the standard padding in physical pixels.

Definition at line 22 of file ScalableDialog.cpp.

◆ Scaled() [1/2]

wxSize EmberUI::ScalableDialog::Scaled ( const wxSize & size) const
protected

Scales a logical size to physical pixels.

Definition at line 16 of file ScalableDialog.cpp.

◆ Scaled() [2/2]

int EmberUI::ScalableDialog::Scaled ( int px) const
protected

Scales a logical pixel value to physical pixels.

Definition at line 14 of file ScalableDialog.cpp.

◆ Spacing()

int EmberUI::ScalableDialog::Spacing ( ) const
protected

Returns the standard spacing in physical pixels.

Definition at line 20 of file ScalableDialog.cpp.


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