Add new editor product shell baseline
This commit is contained in:
@@ -6,8 +6,55 @@
|
||||
|
||||
namespace XCEngine::UI::Editor {
|
||||
|
||||
enum class UIEditorShellToolbarGlyph : std::uint8_t {
|
||||
Play = 0,
|
||||
Pause,
|
||||
Step
|
||||
};
|
||||
|
||||
struct UIEditorShellToolbarButton {
|
||||
std::string buttonId = {};
|
||||
UIEditorShellToolbarGlyph glyph = UIEditorShellToolbarGlyph::Play;
|
||||
bool enabled = true;
|
||||
};
|
||||
|
||||
struct UIEditorShellToolbarLayout {
|
||||
::XCEngine::UI::UIRect bounds = {};
|
||||
::XCEngine::UI::UIRect groupRect = {};
|
||||
std::vector<::XCEngine::UI::UIRect> buttonRects = {};
|
||||
};
|
||||
|
||||
struct UIEditorShellToolbarMetrics {
|
||||
float barHeight = 24.0f;
|
||||
float groupPaddingX = 8.0f;
|
||||
float groupPaddingY = 3.0f;
|
||||
float buttonWidth = 20.0f;
|
||||
float buttonHeight = 18.0f;
|
||||
float buttonGap = 5.0f;
|
||||
float groupCornerRounding = 6.0f;
|
||||
float buttonCornerRounding = 4.0f;
|
||||
float borderThickness = 1.0f;
|
||||
float iconThickness = 1.35f;
|
||||
};
|
||||
|
||||
struct UIEditorShellToolbarPalette {
|
||||
::XCEngine::UI::UIColor barColor =
|
||||
::XCEngine::UI::UIColor(0.13f, 0.13f, 0.13f, 1.0f);
|
||||
::XCEngine::UI::UIColor groupColor =
|
||||
::XCEngine::UI::UIColor(0.16f, 0.16f, 0.16f, 1.0f);
|
||||
::XCEngine::UI::UIColor groupBorderColor =
|
||||
::XCEngine::UI::UIColor(0.30f, 0.30f, 0.30f, 1.0f);
|
||||
::XCEngine::UI::UIColor buttonColor =
|
||||
::XCEngine::UI::UIColor(0.20f, 0.20f, 0.20f, 1.0f);
|
||||
::XCEngine::UI::UIColor buttonBorderColor =
|
||||
::XCEngine::UI::UIColor(0.36f, 0.36f, 0.36f, 1.0f);
|
||||
::XCEngine::UI::UIColor iconColor =
|
||||
::XCEngine::UI::UIColor(0.84f, 0.84f, 0.84f, 1.0f);
|
||||
};
|
||||
|
||||
struct UIEditorShellComposeModel {
|
||||
std::vector<Widgets::UIEditorMenuBarItem> menuBarItems = {};
|
||||
std::vector<UIEditorShellToolbarButton> toolbarButtons = {};
|
||||
std::vector<Widgets::UIEditorStatusBarSegment> statusSegments = {};
|
||||
std::vector<UIEditorWorkspacePanelPresentationModel> workspacePresentations = {};
|
||||
};
|
||||
@@ -23,6 +70,7 @@ struct UIEditorShellComposeMetrics {
|
||||
float sectionGap = 8.0f;
|
||||
float surfaceCornerRounding = 10.0f;
|
||||
Widgets::UIEditorMenuBarMetrics menuBarMetrics = {};
|
||||
UIEditorShellToolbarMetrics toolbarMetrics = {};
|
||||
Widgets::UIEditorDockHostMetrics dockHostMetrics = {};
|
||||
Widgets::UIEditorViewportSlotMetrics viewportMetrics = {};
|
||||
Widgets::UIEditorStatusBarMetrics statusBarMetrics = {};
|
||||
@@ -34,6 +82,7 @@ struct UIEditorShellComposePalette {
|
||||
::XCEngine::UI::UIColor surfaceBorderColor =
|
||||
::XCEngine::UI::UIColor(0.27f, 0.27f, 0.27f, 1.0f);
|
||||
Widgets::UIEditorMenuBarPalette menuBarPalette = {};
|
||||
UIEditorShellToolbarPalette toolbarPalette = {};
|
||||
Widgets::UIEditorDockHostPalette dockHostPalette = {};
|
||||
Widgets::UIEditorViewportSlotPalette viewportPalette = {};
|
||||
Widgets::UIEditorStatusBarPalette statusBarPalette = {};
|
||||
@@ -43,9 +92,11 @@ struct UIEditorShellComposeLayout {
|
||||
::XCEngine::UI::UIRect bounds = {};
|
||||
::XCEngine::UI::UIRect contentRect = {};
|
||||
::XCEngine::UI::UIRect menuBarRect = {};
|
||||
::XCEngine::UI::UIRect toolbarRect = {};
|
||||
::XCEngine::UI::UIRect workspaceRect = {};
|
||||
::XCEngine::UI::UIRect statusBarRect = {};
|
||||
Widgets::UIEditorMenuBarLayout menuBarLayout = {};
|
||||
UIEditorShellToolbarLayout toolbarLayout = {};
|
||||
Widgets::UIEditorStatusBarLayout statusBarLayout = {};
|
||||
};
|
||||
|
||||
@@ -62,6 +113,7 @@ struct UIEditorShellComposeFrame {
|
||||
UIEditorShellComposeLayout BuildUIEditorShellComposeLayout(
|
||||
const ::XCEngine::UI::UIRect& bounds,
|
||||
const std::vector<Widgets::UIEditorMenuBarItem>& menuBarItems,
|
||||
const std::vector<UIEditorShellToolbarButton>& toolbarButtons,
|
||||
const std::vector<Widgets::UIEditorStatusBarSegment>& statusSegments,
|
||||
const UIEditorShellComposeMetrics& metrics = {});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user