From e92d04557bc87f0b5478f48f2dd8ee63834ba055 Mon Sep 17 00:00:00 2001 From: Miranda Marquez Date: Sat, 28 Sep 2024 18:26:58 -0800 Subject: [PATCH] right-alignment is slightly less janky now yaaaaay!!! --- p11k.el | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/p11k.el b/p11k.el index bd6902a..ec453df 100644 --- a/p11k.el +++ b/p11k.el @@ -233,7 +233,13 @@ Use 'window-width' to calculate the total final width." (left-length (length left-str)) (right-length (length right-str)) (middle-spc (- (window-width nil 'remap) (+ left-length right-length)))) - (concat left-str (make-string middle-spc (string-to-char " ")) right-str))) + (concat left-str + ;; (make-string middle-spc (string-to-char " ")) + (propertize " " + 'display + `(space :align-to ,(- (window-width nil 'remap) right-length))) + right-str + ))) ;; (eval `(concat ,@'("one" "two"))) ;; (p11k/justificate '("one" "wto" "three") '("twenty" "23" "forthy-three"))