* line-spacing in the minibuffer/echo area
@ 2015-10-12 1:33 Nick Helm
2015-10-12 10:14 ` Michael Heerdegen
2015-10-12 19:48 ` John Mastro
0 siblings, 2 replies; 4+ messages in thread
From: Nick Helm @ 2015-10-12 1:33 UTC (permalink / raw)
To: help-gnu-emacs
How do I change the line-spacing in the minibuffer/echo area? And
then, how do I make that change persistent?
I have this in my init.el
(setq-default line-spacing 2)
which works well for most windows and buffers, but not the minibuffer or
echo area.
I've tried a few things to change the vertical spacing, such as:
(with-current-buffer (get-buffer " *Minibuf-1*")
(setq-local line-spacing 2))
and this
(with-current-buffer (get-buffer " *Minibuf-1*")
(add-text-properties (point-min) (point-max) '(line-spacing 2)))
but they have no effect that I can see.
It's not that the minibuffer/echo area properties are read-only, because
I can change other properties without a problem. This example for a face
text property is adapted from one in the manual:
(with-current-buffer (get-buffer " *Echo Area 0*")
(setq-local face-remapping-alist '((default (:height 2.0)))))
This also works for *Minibuf-1* but, oddly, is not persistent.
Anyway, as far as I know, line-spacing and line-height are not valid frame
parameters, so I can't simply add to minibuffer-frame-alist.
What am I missing here?
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: line-spacing in the minibuffer/echo area
2015-10-12 1:33 line-spacing in the minibuffer/echo area Nick Helm
@ 2015-10-12 10:14 ` Michael Heerdegen
2015-10-15 4:04 ` Nick Helm
2015-10-12 19:48 ` John Mastro
1 sibling, 1 reply; 4+ messages in thread
From: Michael Heerdegen @ 2015-10-12 10:14 UTC (permalink / raw)
To: help-gnu-emacs
Nick Helm <nick@tenpoint.co.nz> writes:
> How do I change the line-spacing in the minibuffer/echo area? And
> then, how do I make that change persistent?
>
> I have this in my init.el
>
> (setq-default line-spacing 2)
>
> which works well for most windows and buffers, but not the minibuffer or
> echo area.
This works for me out of the box. I tested with Emacs 23.4, 24.5 and 25.
> I've tried a few things to change the vertical spacing, such as:
>
> (with-current-buffer (get-buffer " *Minibuf-1*")
> (setq-local line-spacing 2))
Local variables aren't durable in the minibuffers AFAIK, so this will
have not effect.
> What am I missing here?
Good question. For me, the effect of setq-default line-spacing is
respected by both minibuffers and echo area buffers. But it only makes
a difference when multiple lines are shown there (like in any other
buffer, too).
Michael.
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: line-spacing in the minibuffer/echo area
2015-10-12 1:33 line-spacing in the minibuffer/echo area Nick Helm
2015-10-12 10:14 ` Michael Heerdegen
@ 2015-10-12 19:48 ` John Mastro
1 sibling, 0 replies; 4+ messages in thread
From: John Mastro @ 2015-10-12 19:48 UTC (permalink / raw)
To: help-gnu-emacs@gnu.org; +Cc: Nick Helm
Nick Helm <nick@tenpoint.co.nz> wrote:
> How do I change the line-spacing in the minibuffer/echo area? And
> then, how do I make that change persistent?
>
> I have this in my init.el
>
> (setq-default line-spacing 2)
>
> which works well for most windows and buffers, but not the minibuffer or
> echo area.
That works for me on Emacs 25 (and I see Michael Heerdegen tested on
23.4 and 24.5 as well).
I'm not sure why it doesn't work for you, but you could try this, which
is also how you would do it if you only wanted it to affect the
minibuffer:
(defun my-minibuffer-line-spacing ()
(setq-local line-spacing 2))
(add-hook 'minibuffer-setup-hook #'my-minibuffer-line-spacing)
--
john
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: line-spacing in the minibuffer/echo area
2015-10-12 10:14 ` Michael Heerdegen
@ 2015-10-15 4:04 ` Nick Helm
0 siblings, 0 replies; 4+ messages in thread
From: Nick Helm @ 2015-10-15 4:04 UTC (permalink / raw)
To: Michael Heerdegen; +Cc: help-gnu-emacs
> This works for me out of the box. I tested with Emacs 23.4, 24.5 and 25.
As it turns out, it's working correctly for me as here well - I was
seeing one thing and expecting something else.
> For me, the effect of setq-default line-spacing is respected by both
> minibuffers and echo area buffers. But it only makes a difference when
> multiple lines are shown there (like in any other buffer, too).
This was the eureka moment. For some reason, I though line-spacing
worked by manipulating the :line-height property of the newline
character, so I could use it to change the apparent vertical space
available to even a single line. It's not and I can't.
As soon as I change to a multi-line minibuffer, the new line-spacing is
obvious.
Thanks for the help.
>
> Michael.
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2015-10-15 4:04 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-10-12 1:33 line-spacing in the minibuffer/echo area Nick Helm
2015-10-12 10:14 ` Michael Heerdegen
2015-10-15 4:04 ` Nick Helm
2015-10-12 19:48 ` John Mastro
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).