diff --git a/elisp/ha-focus.el b/elisp/ha-focus.el index 9d1aaa6..be2a5f0 100644 --- a/elisp/ha-focus.el +++ b/elisp/ha-focus.el @@ -47,7 +47,7 @@ This also starts another break timer, that calls `ha-focus-break-over' when finished." (interactive) (run-with-idle-timer 30 nil 'ha-focus-capture) - (ha-focus--command "tell application \"VLC\" to pause") + (ha-focus--command "tell application \"VLC\" to stop") (ha-focus-countdown-timer 5 'ha-focus-break-over) (message "🍅 Time to take a break.")) diff --git a/hammerspoon.org b/hammerspoon.org index 982774b..0f24567 100644 --- a/hammerspoon.org +++ b/hammerspoon.org @@ -2,7 +2,7 @@ #+author: Howard X. Abrams #+date: 2025-11-24 #+filetags: emacs hamacs -#+lastmod: [2026-08-10 Mon] +#+lastmod: [2026-08-12 Wed] A literate programming file for configuring Hammerspoon. @@ -304,6 +304,24 @@ My company gave me a nice monitor … maybe a little too nice, as I don’t care hs.hotkey.bind({"cmd", "alt", "ctrl", "shift"}, "Y", centerWindow) #+END_SRC +Similarly, I sometimes want a window as large as possible, but flushed to the edges of the monitor (a maximized frame, not macOS' native /full screen/): + +#+BEGIN_SRC lua + ---------------------------------------------------------------------- + -- Making a window as large as possible on its current monitor: + + function fullWindow() + local win = hs.window.focusedWindow() + if not win then return end -- Safety check in case no window is focused + + local screen = win:screen() + win:setFrame(screen:frame()) + hs.alert.show("Full Window") + end + + hs.hotkey.bind({"cmd", "alt", "ctrl", "shift"}, "U", fullWindow) +#+END_SRC + * Auto Reload Configuration Whenever my configuration file is altered (or with a ~Meh-R~ key), I reload the configuration: