Replies: 1 comment
-
I have absolutely no idea how it works but it does: local seen = {}
wezterm.on('window-focus-changed', function(window, pane)
local wid = window:window_id()
if not seen[wid] then
seen[wid] = true
window:maximize()
end
end) The docs don't state if the GUI window ID is unique. From what I've seen, window IDs are not unique, but they still work. EDIT: Another approach could be abuse of the window configuration overrides via some unused option: wezterm.on('window-focus-changed', function(window, pane)
local overrides = window:get_config_overrides() or {}
if not overrides.allow_win32_input_mode then
window:maximize()
overrides.allow_win32_input_mode = true
window:set_config_overrides(overrides)
end
end) I'm on Linux so |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
What Operating System(s) are you running on?
Linux Wayland
Which Wayland compositor or X11 Window manager(s) are you using?
KWin
WezTerm version
wezterm 20240203-110809-5046fc22
Ask your question!
Hello!
Today I finally got around to giving wezterm a try and was now playing around with my config.
One thing I really like to have on my terminal emulators is for new windows to always start maximized, so that when I use
Super+T
(my global keybind to open a new terminal window), it fills my entire screen.Now, I've read #284 and used both GUI events as follows:
The first one works great, wezterm's first window is maximized (so are windows spawned with
--always-new-process
), but subsequent ones are not.I've even chucked some prints in both, and I see that
gui-startup
is being called, butgui-attached
isn't.Am I missing something obvious (likely!) or is this not working as intended?
Beta Was this translation helpful? Give feedback.
All reactions