diff options
| author | Craig Jennings <c@cjennings.net> | 2026-06-28 03:20:12 -0400 |
|---|---|---|
| committer | Craig Jennings <c@cjennings.net> | 2026-06-28 03:20:12 -0400 |
| commit | e8ea03ecc8c1a2499046b34f785bca4f871531df (patch) | |
| tree | 33232649069265c4541545fc114a6410de369f3c /README.org | |
| parent | ee8fdeb692d666c12ce068a2b1ee90e9451ac892 (diff) | |
| download | emacs-wttrin-e8ea03ecc8c1a2499046b34f785bca4f871531df.tar.gz emacs-wttrin-e8ea03ecc8c1a2499046b34f785bca4f871531df.zip | |
feat: fit and center the weather buffer in its window
Centering and auto-fit share one resize hook (wttrin--update-layout on
window-configuration-change-hook).
Centering is always on. The block centers via the window's left margin,
measured in pixels from the buffer font so it stays exact under a font-height
remap. It centers against the available width including the current margin, so
the margin shrinking the body can't make the value oscillate.
Auto-fit is opt-in (wttrin-auto-fit-font, off by default). When on, the font is
sized so the whole buffer fits top to bottom (down to the row past the footer's
last menu item) without the widest line truncating, clamped to
wttrin-font-height-min and -max.
The pixel-exact measurement needs window-font-width and window-font-height, so
the minimum is now Emacs 25.1.
Diffstat (limited to 'README.org')
| -rw-r--r-- | README.org | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -8,7 +8,7 @@ [[https://github.com/cjennings/emacs-wttrin/actions/workflows/ci.yml][file:https://github.com/cjennings/emacs-wttrin/actions/workflows/ci.yml/badge.svg]] [[https://coveralls.io/github/cjennings/emacs-wttrin?branch=main][file:https://coveralls.io/repos/github/cjennings/emacs-wttrin/badge.svg?branch=main]] -Wttrin is a simple Emacs frontend for Igor Chubin's [[https://github.com/chubin/wttr.in][wttr.in]] weather service. It works with Emacs 24.4+ and needs [[https://github.com/atomontage/xterm-color][xterm-color]] for the colored ASCII art (MELPA handles that dependency for you). +Wttrin is a simple Emacs frontend for Igor Chubin's [[https://github.com/chubin/wttr.in][wttr.in]] weather service. It works with Emacs 25.1+ and needs [[https://github.com/atomontage/xterm-color][xterm-color]] for the colored ASCII art (MELPA handles that dependency for you). [[assets/wttrin.png]] |
