Skip to content

Commit

Permalink
Fix about window pos and size
Browse files Browse the repository at this point in the history
  • Loading branch information
nat-js authored and nat-js committed Feb 25, 2022
1 parent ada83bb commit 50c0502
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions scripts/modules/gui/window.lua
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,11 @@ local layout = {
local function renderAboutWindow()
window.m_draw_about = ImGui.Begin(window.m_about_title, window.m_draw_about, ImGuiWindowFlags.NoSavedSettings)
if window.m_draw_about then
ImGui.SetWindowPos(dpi.GetDisplayResolution().x / 2 - 300 * dpi.GetScale(),
dpi.GetDisplayResolution().y * 0.1 * dpi.GetScale(),
ImGuiCond.FirstUseEver)
ImGui.SetWindowSize(600 * dpi.GetScale(),
dpi.GetDisplayResolution().y * 0.8, ImGuiCond.FirstUseEver)
ImGui.Text(window.m_about_text)
end
ImGui.End()
Expand Down

0 comments on commit 50c0502

Please sign in to comment.