macOS: Display the newly created OS window in specified state

Fix the maximized window can't occupy full screen space when window
decoration or title bar is hidden.
Fix resize_in_steps being applied even when window is maximized.
Allows to specify `os_window_state` in startup session file.
This commit is contained in:
pagedown
2023-02-18 14:02:19 +08:00
parent 1b76cee9b4
commit ba83ce7b10
12 changed files with 109 additions and 33 deletions

View File

@@ -161,6 +161,8 @@ option in :file:`kitty.conf`. An example, showing all available commands:
os_window_size 80c 24c
# Set the --class for the new OS window
os_window_class mywindow
# Change the OS window state to normal, fullscreen, maximized or minimized
os_window_state normal
launch sh
# Resize the current window (see the resize_window action for details)
resize_window wider 2