From: Alexander Shukaev <haroogan@gmail.com>
To: 20592@debbugs.gnu.org
Subject: bug#20592: the `display' property messes the `face' properties after `concat'
Date: Sun, 17 May 2015 01:58:29 +0200 [thread overview]
Message-ID: <CAKu-7WxyDdwzkewqwVArbQy4WCs2T3apx8W-tC7tGjwziv4=gg@mail.gmail.com> (raw)
[-- Attachment #1: Type: text/plain, Size: 2203 bytes --]
Following the "Minibuffer tray to display current time and date"
discussion, it seems that a bug with the `display' property. Consider the
following code:
(setq-default minibuffer-line-format
'((:eval (propertize (format-time-string "%Y.%m.%d")
'face
'minibuffer-line-date))
" "
(:eval (propertize (format-time-string "%A")
'face
'minibuffer-line-weekday))
" "
(:eval (propertize (format-time-string "%R")
'face
'minibuffer-line-time))))
It works as expected.
Consider another piece of code:
(setq-default minibuffer-line-format
`((:eval
(let ((string (concat
(propertize (format-time-string
"%Y.%m.%d")
'face
'minibuffer-line-date)
" "
(propertize (format-time-string "%A")
'face
'minibuffer-line-weekday)
" "
(propertize (format-time-string "%R")
'face
'minibuffer-line-time))))
(concat (propertize " "
'display
`((space :align-to
(- right
right-fringe
,(length string)))))
string)))))
Alignment works as expected, but faces are messed up. In fact, the default
face is used everywhere (which comes from the `display' property), like if
subsequent propertizings of date, weekday, and time have never been there.
[-- Attachment #2: Type: text/html, Size: 4480 bytes --]
next reply other threads:[~2015-05-16 23:58 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-05-16 23:58 Alexander Shukaev [this message]
2015-05-17 14:39 ` bug#20592: the `display' property messes the `face' properties after `concat' Eli Zaretskii
2015-05-19 1:20 ` Stefan Monnier
2015-05-19 15:31 ` Eli Zaretskii
2015-06-25 19:16 ` Alexander Shukaev
2015-06-25 19:42 ` Eli Zaretskii
2021-12-02 10:00 ` Lars Ingebrigtsen
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='CAKu-7WxyDdwzkewqwVArbQy4WCs2T3apx8W-tC7tGjwziv4=gg@mail.gmail.com' \
--to=haroogan@gmail.com \
--cc=20592@debbugs.gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.