@@ -84,18 +84,19 @@ Time windows define which hours are highlighted in the sparkline display using t
8484 '(("Lunch" 12 14)
8585 ("Commute" 17 19))
8686 "Time windows to highlight in forecast display.
87- Each window colours a portion of the sparkline and displays the worst weather
88- for that period.
87+ Each window colours a portion of the sparkline and displays the worst
88+ weather for that period.
8989
90- Define windows as (NAME START-HOUR END-HOUR) or (NAME START-HOUR END-HOUR FACE) where:
90+ Define windows as (NAME START-HOUR END-HOUR) or
91+ \(NAME START-HOUR END-HOUR FACE) where:
9192 NAME is a string describing the window (e.g., \"Lunch\", \"Commute\")
9293 START-HOUR is the first hour to highlight (0-23)
93- END-HOUR is the hour to stop before (0-23, not included in the window )
94- FACE colours the window; defaults to 'success if omitted
94+ END-HOUR is the hour to stop before (0-23, not included)
95+ FACE colours the window; defaults to \\= 'success if omitted
9596
9697Examples:
97- (\"Lunch\" 12 14) highlights hours 12 and 13 with 'success face
98- (\"Commute\" 17 19 warning) highlights hours 17 and 18 with 'warning face"
98+ (\"Lunch\" 12 14) highlights hours 12 and 13 with \\= 'success face
99+ (\"Commute\" 17 19 warning) highlights 17 and 18 with \\= 'warning face"
99100 :type '(repeat (choice
100101 (list (string :tag "Name")
101102 (integer :tag "Start hour (0-23)")
@@ -445,7 +446,7 @@ Prepare time window data for display by combining indices with faces and extract
445446(defun sparkweather--prepare-window (data window)
446447 "Prepare sparkline data for WINDOW from weather DATA.
447448WINDOW is (name start-hour end-hour) or (name start-hour end-hour face).
448- If FACE is omitted, defaults to 'success.
449+ If FACE is omitted, defaults to \\= 'success.
449450Returns plist with :name :face :indices :weather-info."
450451 (pcase-let* ((`(,name ,start ,end . ,rest) window)
451452 (face (or (car rest) 'success))
@@ -545,7 +546,9 @@ Footer generation and window height calculation to optionally hide footer lines.
545546#+begin_src emacs-lisp
546547(defun sparkweather--format-footer ()
547548 "Generate footer text with timestamp and optional location.
548- Returns string suitable for insertion at buffer end."
549+ Returns string suitable for insertion at buffer end.
550+ Leading newline provides spacing, allowing hiding of only the
551+ timestamp when footer is hidden."
549552 ;; Leading \n creates blank line for visual spacing.
550553 ;; sparkweather--window-max-height relies on this to hide only the timestamp line.
551554 (concat "\n" (format-time-string "%A %F %R")
@@ -560,8 +563,9 @@ Returns string suitable for insertion at buffer end."
560563
561564(defun sparkweather--window-max-height (window)
562565 "Calculate maximum height for sparkweather WINDOW.
563- Returns reduced height when `sparkweather-hide-footer' is enabled, nil otherwise.
564- Keeps blank line visible as buffer, hiding only timestamp/location line."
566+ Returns reduced height when `sparkweather-hide-footer' is enabled,
567+ nil otherwise. Keeps blank line visible as buffer, hiding only
568+ timestamp/location line."
565569 (when (and sparkweather-add-footer sparkweather-hide-footer)
566570 (with-current-buffer (window-buffer window)
567571 ;; Calculate desired body lines (total - 1 to hide timestamp)
0 commit comments