fix: shrink top run toolbar height

This commit is contained in:
2026-04-02 22:35:22 +08:00
parent 5ff97b437a
commit cd03465cd0

View File

@@ -17,10 +17,10 @@ namespace Editor {
namespace { namespace {
constexpr float kRunToolbarHeight = 30.0f; constexpr float kRunToolbarHeight = 28.0f;
constexpr float kRunToolbarButtonExtent = 26.0f; constexpr float kRunToolbarButtonExtent = 24.0f;
constexpr float kRunToolbarButtonSpacing = 8.0f; constexpr float kRunToolbarButtonSpacing = 8.0f;
constexpr float kRunToolbarIconInset = 4.0f; constexpr float kRunToolbarIconInset = 3.0f;
std::string BuildRunToolbarIconPath(const char* fileName) { std::string BuildRunToolbarIconPath(const char* fileName) {
const std::filesystem::path exeDir( const std::filesystem::path exeDir(
@@ -135,7 +135,7 @@ void MenuBar::RenderRunToolbar() {
ImGuiWindowFlags_NoMove | ImGuiWindowFlags_NoMove |
ImGuiWindowFlags_NoNavFocus; ImGuiWindowFlags_NoNavFocus;
ImGui::PushStyleVar(ImGuiStyleVar_WindowPadding, ImVec2(12.0f, 2.0f)); ImGui::PushStyleVar(ImGuiStyleVar_WindowPadding, ImVec2(12.0f, 1.0f));
ImGui::PushStyleVar(ImGuiStyleVar_WindowRounding, 0.0f); ImGui::PushStyleVar(ImGuiStyleVar_WindowRounding, 0.0f);
ImGui::PushStyleVar(ImGuiStyleVar_WindowBorderSize, 0.0f); ImGui::PushStyleVar(ImGuiStyleVar_WindowBorderSize, 0.0f);
ImGui::PushStyleColor(ImGuiCol_WindowBg, UI::ToolbarBackgroundColor()); ImGui::PushStyleColor(ImGuiCol_WindowBg, UI::ToolbarBackgroundColor());