Top100
Your Personal Movie List (C++17 CLI + library)
Loading...
Searching...
No Matches
constants.h
Go to the documentation of this file.
1// SPDX-License-Identifier: Apache-2.0
2//-------------------------------------------------------------------------------
9// Top100 — Your Personal Movie List
10//
11// File: ui/common/constants.h
12// Purpose: Shared UI constants (initial sizes, poster ratios) used by both UIs.
13// Language: C++17 (header-only)
14//
15// Author: Andy McCall, mailme@andymccall.co.uk
16// Date: September 18, 2025
17//-------------------------------------------------------------------------------
18
19#pragma once
20
21namespace ui_constants {
22
23// Initial application window size
24constexpr int kInitialWidth = 1024;
25constexpr int kInitialHeight = 768;
26
27// Poster image maximum size as a fraction of the details pane size (make poster larger)
28constexpr double kPosterMaxWidthRatio = 0.90; // 90% of details pane width
29constexpr double kPosterMaxHeightRatio = 0.90; // 90% of details pane height
30
31// Shared spacing and margins for consistent look-and-feel
32constexpr int kSpacingSmall = 6; // small spacing between controls
33constexpr int kSpacingMedium = 10; // medium spacing (unused yet)
34constexpr int kSpacingLarge = 16; // large spacing for dialog sections
35constexpr int kGroupPadding = 8; // inner padding inside frames/groups
36constexpr int kLabelMinWidth = 90; // minimum width for labels in forms
37
38} // namespace ui_constants