-
What Operating System(s) are you running on?macOS Which Wayland compositor or X11 Window manager(s) are you using?No response WezTerm versionwezterm 20240203-110809-5046fc22 Ask your question!I have this scripture and seems to work fine for wezterm first spawning but if I CMD+N to create a new window it goes to a seemingly random position. -- center
wezterm.on("gui-startup", function()
local screen = wezterm.gui.screens().active
local _, _, window = wezterm.mux.spawn_window({})
local gui_window = window:gui_window()
-- Set dimensions to 85% of current screen size
-- The actual dimensions will be a bit bigger if we take into
-- account the decorations on top
local width = screen.width * 0.85
local height = screen.height * 0.85
gui_window:set_inner_size(width, height)
-- Position the window at the center of the screen
local dimensions = gui_window:get_dimensions()
local x = (screen.width - dimensions.pixel_width) * 0.5
local y = (screen.height - dimensions.pixel_height) * 0.5
gui_window:set_position(x, y)
end) demo of issue: 2024-06-17_10-53-24.mp4 |
Beta Was this translation helpful? Give feedback.
Answered by
Hacksore
Sep 8, 2024
Replies: 2 comments 4 replies
-
paging the termfather himself! @wez any ideas or pointers here? |
Beta Was this translation helpful? Give feedback.
4 replies
This comment was marked as off-topic.
This comment was marked as off-topic.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Was able to find a working solution for this with what @wez suggestion above.