fix(CmdExecutor): Set sizing of input w/ frame padding (#1618)

This commit is contained in:
Andreas Maerten 2023-07-06 07:46:42 +02:00 committed by GitHub
parent 6dc7da4dbe
commit c571f5a1e7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -27,7 +27,7 @@ namespace big
// set focus by default on input box
ImGui::SetKeyboardFocusHere(0);
ImGui::SetNextItemWidth(screen_x * 0.5f);
ImGui::SetNextItemWidth((screen_x * 0.5f) - 30.f);
components::input_text_with_hint("", "CMD_EXECUTOR_TYPE_CMD"_T, command_buffer, sizeof(command_buffer), ImGuiInputTextFlags_EnterReturnsTrue, [] {
if (command::process(command_buffer, std::make_shared<default_command_context>(), true))
{