unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* set-frame-size should respect line-spacing!?
@ 2019-10-11 20:44 Ingo Lohmar
  2019-10-12  7:00 ` Eli Zaretskii
  0 siblings, 1 reply; 18+ messages in thread
From: Ingo Lohmar @ 2019-10-11 20:44 UTC (permalink / raw)
  To: emacs-devel

In Bug#37563, I reported that `fit-frame-to-buffer' ignores a default
value of `line-spacing' > 0, whence the buffer might not be tall enough
--- that's what happened with the `posframe' pkg that is, eg, used by
`company-posframe' to display completions. Martin fixed this and related
issues in window.el quickly and thoroughly, for which I am grateful.

Since I tested with a minimal example, however, I did not realize before
that there is another code path that directly uses the C function
`set-frame-size', with the same effect: If line-spacing is > 0 in the
frame, it is not accounted for, and the frame lacks a few pixels in
height (number of lines * "line-spacing effect").

This appears to be a bug: If asked for a frame N lines tall, N lines (of
default-font's character height plus the effect of line-spacing) should
fit, right?

Maybe this affords some opportunity to concentrate this code on either
the lisp or the C side..?



^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: set-frame-size should respect line-spacing!?
  2019-10-11 20:44 set-frame-size should respect line-spacing!? Ingo Lohmar
@ 2019-10-12  7:00 ` Eli Zaretskii
  2019-10-12  7:12   ` Ingo Lohmar
  0 siblings, 1 reply; 18+ messages in thread
From: Eli Zaretskii @ 2019-10-12  7:00 UTC (permalink / raw)
  To: Ingo Lohmar; +Cc: emacs-devel

> From: Ingo Lohmar <ingo.lohmar@posteo.net>
> Date: Fri, 11 Oct 2019 22:44:34 +0200
> 
> Since I tested with a minimal example, however, I did not realize before
> that there is another code path that directly uses the C function
> `set-frame-size', with the same effect: If line-spacing is > 0 in the
> frame, it is not accounted for, and the frame lacks a few pixels in
> height (number of lines * "line-spacing effect").
> 
> This appears to be a bug: If asked for a frame N lines tall, N lines (of
> default-font's character height plus the effect of line-spacing) should
> fit, right?

Not necessarily.  You didn't tell which command or API exhibits this
behavior, but in some cases we mean height in units of the frame's
canonical character height, ion which case it doesn't include any
effects like line-spacing etc.



^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: set-frame-size should respect line-spacing!?
  2019-10-12  7:00 ` Eli Zaretskii
@ 2019-10-12  7:12   ` Ingo Lohmar
  2019-10-12  7:48     ` Eli Zaretskii
  2019-10-12  8:25     ` martin rudalics
  0 siblings, 2 replies; 18+ messages in thread
From: Ingo Lohmar @ 2019-10-12  7:12 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: emacs-devel

On Sat, Oct 12 2019 10:00 (+0300), Eli Zaretskii wrote:

>> From: Ingo Lohmar <ingo.lohmar@posteo.net>
>> Date: Fri, 11 Oct 2019 22:44:34 +0200
>> 
>> Since I tested with a minimal example, however, I did not realize before
>> that there is another code path that directly uses the C function
>> `set-frame-size', with the same effect: If line-spacing is > 0 in the
>> frame, it is not accounted for, and the frame lacks a few pixels in
>> height (number of lines * "line-spacing effect").
>> 
>> This appears to be a bug: If asked for a frame N lines tall, N lines (of
>> default-font's character height plus the effect of line-spacing) should
>> fit, right?
>
> Not necessarily.  You didn't tell which command or API exhibits this
> behavior, but in some cases we mean height in units of the frame's
> canonical character height, ion which case it doesn't include any
> effects like line-spacing etc.

The C API function is `set-frame-size'.  If you're talking about the
*caller*, this is the code from posframe.el:

(defun posframe--set-frame-size (posframe height min-height width min-width)
  "Set POSFRAME's size.
It will set the size by the POSFRAME's HEIGHT, MIN-HEIGHT
WIDTH and MIN-WIDTH."
  (if (and width height)
      (unless (equal posframe--last-posframe-size
                     (cons width height))
        (set-frame-size posframe width height)
        (setq-local posframe--last-posframe-size
                    (cons width height)))
    (fit-frame-to-buffer
     posframe height min-height width min-width)))

The "else" path has been fixed by Martin in
e3f97d73653df725322d7f2392d36f858cce5a73.  But the "then" path has
exhibits the behavior.

Are you saying `set-frame-size' is supposed to ignore line-spacing?  In
that case, what is the correct way to set the frame-size in the
pixel-exact way?



^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: set-frame-size should respect line-spacing!?
  2019-10-12  7:12   ` Ingo Lohmar
@ 2019-10-12  7:48     ` Eli Zaretskii
  2019-10-12  8:25       ` martin rudalics
  2019-10-12  8:25     ` martin rudalics
  1 sibling, 1 reply; 18+ messages in thread
From: Eli Zaretskii @ 2019-10-12  7:48 UTC (permalink / raw)
  To: Ingo Lohmar; +Cc: emacs-devel

> From: Ingo Lohmar <ingo.lohmar@posteo.net>
> Cc: emacs-devel@gnu.org
> Date: Sat, 12 Oct 2019 09:12:17 +0200
> 
> Are you saying `set-frame-size' is supposed to ignore line-spacing?

Yes.  This part of the doc string hints on that, perhaps too
indirectly:

  When ‘frame-resize-pixelwise’ is nil, some window managers may refuse to
  honor a WIDTH that is not an integer multiple of the default frame font
  width or a HEIGHT that is not an integer multiple of the default frame
  font height.

> In that case, what is the correct way to set the frame-size in the
> pixel-exact way?

Use the optional argument PIXELWISE, and calculate the frame size in
pixels yourself.



^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: set-frame-size should respect line-spacing!?
  2019-10-12  7:12   ` Ingo Lohmar
  2019-10-12  7:48     ` Eli Zaretskii
@ 2019-10-12  8:25     ` martin rudalics
  2019-10-12  9:45       ` Eli Zaretskii
  1 sibling, 1 reply; 18+ messages in thread
From: martin rudalics @ 2019-10-12  8:25 UTC (permalink / raw)
  To: Ingo Lohmar, Eli Zaretskii; +Cc: emacs-devel

 > Are you saying `set-frame-size' is supposed to ignore line-spacing?  In
 > that case, what is the correct way to set the frame-size in the
 > pixel-exact way?

By using the PIXELWISE argument of 'set-frame-size'.  But note that
this sets the text size of the frame, see also the 'text-pixels' type
specification (section 29.4.3.3 Size Parameters of the Elisp manual).
I am working on 'inner-pixels', 'outer-pixels' and 'native-pixels' but
all these are so intrinsically platform dependent that I've hardly
made any progresss in the past years.

I earlier explained why we cannot make 'set-frame-size' obey the line
spacing of a specific buffer: A buffer might not be alone on a frame
and even if it is, switching to a buffer previously displayed in that
window might become inconvenient.

So we have a number of options which all will take considerable time
to implement:

(1) Change the semantics of the PIXELWISE argument for a number of
     user functions.  For 'set-frame-size' we could say that if its
     value is 'linewise', then use the 'window-default-line-height'
     value of the frame's selected window.

(2) Add, as also mentioned earlier, a frame parameter that controls
     the behavior in some way.

(3) Add some global option to control the behavior.  I suppose that
     this might be too strong.

And then we have to establish the set of commands we want to affect.
 From Bug#14825 we know that 'split-window-below' is one candidate and
probably most of the 'window-resize' type functions.  Then we probably
want to have size reporting functions handle line spaces as well.  If
you search for the occurrence of the term 'pixelwise' in the code of
window.el you will understand how much of change that would mean.

martin



^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: set-frame-size should respect line-spacing!?
  2019-10-12  7:48     ` Eli Zaretskii
@ 2019-10-12  8:25       ` martin rudalics
  0 siblings, 0 replies; 18+ messages in thread
From: martin rudalics @ 2019-10-12  8:25 UTC (permalink / raw)
  To: Eli Zaretskii, Ingo Lohmar; +Cc: emacs-devel

 >> Are you saying `set-frame-size' is supposed to ignore line-spacing?
 >
 > Yes.  This part of the doc string hints on that, perhaps too
 > indirectly:
 >
 >    When ‘frame-resize-pixelwise’ is nil, some window managers may refuse to
 >    honor a WIDTH that is not an integer multiple of the default frame font
 >    width or a HEIGHT that is not an integer multiple of the default frame
 >    font height.

The doc-string of 'set-frame-size' says

Set text size of FRAME to WIDTH by HEIGHT, measured in characters.

and Section 29.3.4 Frame Size says that

The canonical way to specify the “size of a frame” from within Emacs is
by specifying its “text size”—a tuple of the width and height of the
frame’s text area (*note Frame Layout::).  It can be measured either in
pixels or in terms of the frame’s canonical character size (*note Frame
Font::).

We could repeat some of the latter in the doc-strings of all functions
that access or set a frame's or window's size, if we want.

martin




^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: set-frame-size should respect line-spacing!?
  2019-10-12  8:25     ` martin rudalics
@ 2019-10-12  9:45       ` Eli Zaretskii
  2019-10-12  9:56         ` Ingo Lohmar
  2019-10-12 11:03         ` martin rudalics
  0 siblings, 2 replies; 18+ messages in thread
From: Eli Zaretskii @ 2019-10-12  9:45 UTC (permalink / raw)
  To: martin rudalics; +Cc: emacs-devel, ingo.lohmar

> Cc: emacs-devel@gnu.org
> From: martin rudalics <rudalics@gmx.at>
> Date: Sat, 12 Oct 2019 10:25:13 +0200
> 
> I earlier explained why we cannot make 'set-frame-size' obey the line
> spacing of a specific buffer: A buffer might not be alone on a frame
> and even if it is, switching to a buffer previously displayed in that
> window might become inconvenient.
> 
> So we have a number of options which all will take considerable time
> to implement:

I think we should first decide whether we want to invest such an
effort to support a rare use case, which is also not without its
pitfalls (as you describe above).

A buffer can specify, in addition to line-spacing, other display
features that will affect the metrics of its lines.  The simplest
example is the face of the text to display, which can include the
font.  It could even do this extremely subtly, by displaying text that
belongs to a script whose font is higher or lower than the default
face's font.  In all of these cases, the original number of text lines
will be inaccurate for some buffers shown in the same window on the
same frame.

So I don't think I understand why we need to support these specialized
use cases.



^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: set-frame-size should respect line-spacing!?
  2019-10-12  9:45       ` Eli Zaretskii
@ 2019-10-12  9:56         ` Ingo Lohmar
  2019-10-12 11:03         ` martin rudalics
  1 sibling, 0 replies; 18+ messages in thread
From: Ingo Lohmar @ 2019-10-12  9:56 UTC (permalink / raw)
  To: Eli Zaretskii, martin rudalics; +Cc: emacs-devel

On Sat, Oct 12 2019 12:45 (+0300), Eli Zaretskii wrote:

> I think we should first decide whether we want to invest such an
> effort to support a rare use case, which is also not without its
> pitfalls (as you describe above).
>
> A buffer can specify, in addition to line-spacing, other display
> features that will affect the metrics of its lines.  The simplest
> example is the face of the text to display, which can include the
> font.  It could even do this extremely subtly, by displaying text that
> belongs to a script whose font is higher or lower than the default
> face's font.  In all of these cases, the original number of text lines
> will be inaccurate for some buffers shown in the same window on the
> same frame.
>
> So I don't think I understand why we need to support these specialized
> use cases.

Just to be clear: While I do think that the relevant code at the C and
the Lisp level is not the easiest to follow, becuase a lot of different
concepts are implicitly involved (sorry Martin, for not remembering your
point about the line-spacing per buffer), I did not intend to start a
fundamental discussion on these issues.

My approach to this whole area was from the point of view of a user of
the posframe pkg (not even directly, but via company-posframe).  As
such, the question was "how to create a frame that fits N lines", and of
course, that is ill-defined (line-spacing, font choice subtleties, and
several more factors, I guess).

For the matter at hand, the fixed `fit-frame-to-buffer` does what I need
(or rather, what the posframe pkg needs); the rest is bug-fixing in the
pkg.



^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: set-frame-size should respect line-spacing!?
  2019-10-12  9:45       ` Eli Zaretskii
  2019-10-12  9:56         ` Ingo Lohmar
@ 2019-10-12 11:03         ` martin rudalics
  2019-10-12 13:11           ` Eli Zaretskii
  1 sibling, 1 reply; 18+ messages in thread
From: martin rudalics @ 2019-10-12 11:03 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: ingo.lohmar, emacs-devel

 > A buffer can specify, in addition to line-spacing, other display
 > features that will affect the metrics of its lines.  The simplest
 > example is the face of the text to display, which can include the
 > font.

'window-default-line-height' hopefully handles that already.

 > It could even do this extremely subtly, by displaying text that
 > belongs to a script whose font is higher or lower than the default
 > face's font.  In all of these cases, the original number of text lines
 > will be inaccurate for some buffers shown in the same window on the
 > same frame.
 >
 > So I don't think I understand why we need to support these specialized
 > use cases.

We still have to decide how to proceed with Bug#14825.

martin



^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: set-frame-size should respect line-spacing!?
  2019-10-12 11:03         ` martin rudalics
@ 2019-10-12 13:11           ` Eli Zaretskii
  2019-10-13  8:16             ` martin rudalics
  0 siblings, 1 reply; 18+ messages in thread
From: Eli Zaretskii @ 2019-10-12 13:11 UTC (permalink / raw)
  To: martin rudalics; +Cc: emacs-devel, ingo.lohmar

> From: martin rudalics <rudalics@gmx.at>
> Date: Sat, 12 Oct 2019 13:03:31 +0200
> Cc: ingo.lohmar@posteo.net, emacs-devel@gnu.org
> 
>  > A buffer can specify, in addition to line-spacing, other display
>  > features that will affect the metrics of its lines.  The simplest
>  > example is the face of the text to display, which can include the
>  > font.
> 
> 'window-default-line-height' hopefully handles that already.

There's no problem to handle that, if we want, but my point is that
you aske the frame to show N lines, and after switching to another
buffer it shows M ≠ N.

> We still have to decide how to proceed with Bug#14825.

The solution there could be local, so that it doesn't affect the use
cases described here.



^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: set-frame-size should respect line-spacing!?
  2019-10-12 13:11           ` Eli Zaretskii
@ 2019-10-13  8:16             ` martin rudalics
  2019-10-13  9:10               ` Eli Zaretskii
  0 siblings, 1 reply; 18+ messages in thread
From: martin rudalics @ 2019-10-13  8:16 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: emacs-devel, ingo.lohmar

 >> We still have to decide how to proceed with Bug#14825.
 >
 > The solution there could be local, so that it doesn't affect the use
 > cases described here.

So you mean that OT1H we should handle the case where 'split-window'
tells us that the window is too small and OTOH not handle the case
where 'window-resize' says that it cannot resize the window?  Wouldn't
that be inconsistent?

martin



^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: set-frame-size should respect line-spacing!?
  2019-10-13  8:16             ` martin rudalics
@ 2019-10-13  9:10               ` Eli Zaretskii
  2019-10-13 12:15                 ` martin rudalics
  0 siblings, 1 reply; 18+ messages in thread
From: Eli Zaretskii @ 2019-10-13  9:10 UTC (permalink / raw)
  To: martin rudalics; +Cc: emacs-devel, ingo.lohmar

> Cc: ingo.lohmar@posteo.net, emacs-devel@gnu.org
> From: martin rudalics <rudalics@gmx.at>
> Date: Sun, 13 Oct 2019 10:16:53 +0200
> 
>  >> We still have to decide how to proceed with Bug#14825.
>  >
>  > The solution there could be local, so that it doesn't affect the use
>  > cases described here.
> 
> So you mean that OT1H we should handle the case where 'split-window'
> tells us that the window is too small and OTOH not handle the case
> where 'window-resize' says that it cannot resize the window?

No, I'm saying that we should handle the case with split-window
without affecting set-frame-size in general.



^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: set-frame-size should respect line-spacing!?
  2019-10-13  9:10               ` Eli Zaretskii
@ 2019-10-13 12:15                 ` martin rudalics
  2019-10-13 12:18                   ` Eli Zaretskii
  0 siblings, 1 reply; 18+ messages in thread
From: martin rudalics @ 2019-10-13 12:15 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: ingo.lohmar, emacs-devel

 >> So you mean that OT1H we should handle the case where 'split-window'
 >> tells us that the window is too small and OTOH not handle the case
 >> where 'window-resize' says that it cannot resize the window?
 >
 > No, I'm saying that we should handle the case with split-window
 > without affecting set-frame-size in general.

Sorry for my insistence but 'window-resize' has nothing to do with the
frame size.  My concerns are that we call 'window--size-to-pixel' when
we resize or split a window.  So if we want to special-code the split
window case and _not_ the 'window-resize' case, I have to either
special-code 'window--size-to-pixel' too or call some other function
instead.  Please have a short look at the involved functions and tell
me what you would do.

martin



^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: set-frame-size should respect line-spacing!?
  2019-10-13 12:15                 ` martin rudalics
@ 2019-10-13 12:18                   ` Eli Zaretskii
  2019-10-13 12:51                     ` martin rudalics
  0 siblings, 1 reply; 18+ messages in thread
From: Eli Zaretskii @ 2019-10-13 12:18 UTC (permalink / raw)
  To: martin rudalics; +Cc: ingo.lohmar, emacs-devel

> Cc: emacs-devel@gnu.org, ingo.lohmar@posteo.net
> From: martin rudalics <rudalics@gmx.at>
> Date: Sun, 13 Oct 2019 14:15:50 +0200
> 
>  >> So you mean that OT1H we should handle the case where 'split-window'
>  >> tells us that the window is too small and OTOH not handle the case
>  >> where 'window-resize' says that it cannot resize the window?
>  >
>  > No, I'm saying that we should handle the case with split-window
>  > without affecting set-frame-size in general.
> 
> Sorry for my insistence but 'window-resize' has nothing to do with the
> frame size.

But this discussion was about set-frame-size, at least that's what I
thought.

> My concerns are that we call 'window--size-to-pixel' when
> we resize or split a window.  So if we want to special-code the split
> window case and _not_ the 'window-resize' case, I have to either
> special-code 'window--size-to-pixel' too or call some other function
> instead.

What is the window-resize case?



^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: set-frame-size should respect line-spacing!?
  2019-10-13 12:18                   ` Eli Zaretskii
@ 2019-10-13 12:51                     ` martin rudalics
  2019-10-13 13:20                       ` Eli Zaretskii
  0 siblings, 1 reply; 18+ messages in thread
From: martin rudalics @ 2019-10-13 12:51 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: emacs-devel, ingo.lohmar

 >> Sorry for my insistence but 'window-resize' has nothing to do with the
 >> frame size.
 >
 > But this discussion was about set-frame-size, at least that's what I
 > thought.

The 'set-frame-size' problem is inherently related to Bug#14825: Both
are about how to take line spacing and face remapping into account
when resizing windows.  Just that the former affects the frame size as
well.

 >> My concerns are that we call 'window--size-to-pixel' when
 >> we resize or split a window.  So if we want to special-code the split
 >> window case and _not_ the 'window-resize' case, I have to either
 >> special-code 'window--size-to-pixel' too or call some other function
 >> instead.
 >
 > What is the window-resize case?

That of how it should handle line spacing and face remapping when
resizing a window.  For example, how should we relate the desired
height of a window to the value of 'window-min-height' when these are
in effect?  We cannot leave this question unanswered when we allow
'split-window' to make a window smaller than 'window-min-height'
because face remapping has made a window's default face font smaller.

martin



^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: set-frame-size should respect line-spacing!?
  2019-10-13 12:51                     ` martin rudalics
@ 2019-10-13 13:20                       ` Eli Zaretskii
  2019-10-13 17:06                         ` martin rudalics
  0 siblings, 1 reply; 18+ messages in thread
From: Eli Zaretskii @ 2019-10-13 13:20 UTC (permalink / raw)
  To: martin rudalics; +Cc: emacs-devel, ingo.lohmar

> Cc: ingo.lohmar@posteo.net, emacs-devel@gnu.org
> From: martin rudalics <rudalics@gmx.at>
> Date: Sun, 13 Oct 2019 14:51:46 +0200
> 
>  >> Sorry for my insistence but 'window-resize' has nothing to do with the
>  >> frame size.
>  >
>  > But this discussion was about set-frame-size, at least that's what I
>  > thought.
> 
> The 'set-frame-size' problem is inherently related to Bug#14825: Both
> are about how to take line spacing and face remapping into account
> when resizing windows.  Just that the former affects the frame size as
> well.

And I was saying that we should be able to solve window-splitting and
resizing use cases while leaving set-frame-size unaffected.

>  >> My concerns are that we call 'window--size-to-pixel' when
>  >> we resize or split a window.  So if we want to special-code the split
>  >> window case and _not_ the 'window-resize' case, I have to either
>  >> special-code 'window--size-to-pixel' too or call some other function
>  >> instead.
>  >
>  > What is the window-resize case?
> 
> That of how it should handle line spacing and face remapping when
> resizing a window.  For example, how should we relate the desired
> height of a window to the value of 'window-min-height' when these are
> in effect?

I think the only case where the issues raised by bug#14825 should
matter is when we decide whether a window is too small.  E.g., what
bad things will happen if we interpret window-min-height in terms of
the default face's font set for the buffer shown (or to be shown) in
the window?



^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: set-frame-size should respect line-spacing!?
  2019-10-13 13:20                       ` Eli Zaretskii
@ 2019-10-13 17:06                         ` martin rudalics
  2019-10-14  8:06                           ` Eli Zaretskii
  0 siblings, 1 reply; 18+ messages in thread
From: martin rudalics @ 2019-10-13 17:06 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: ingo.lohmar, emacs-devel

 >> That of how it should handle line spacing and face remapping when
 >> resizing a window.  For example, how should we relate the desired
 >> height of a window to the value of 'window-min-height' when these are
 >> in effect?
 >
 > I think the only case where the issues raised by bug#14825 should
 > matter is when we decide whether a window is too small.  E.g., what
 > bad things will happen if we interpret window-min-height in terms of
 > the default face's font set for the buffer shown (or to be shown) in
 > the window?

Such an interpretation would cut both ways.  Think of people that use
'line-spacing' for ages or have remapped the default face font to
something higher.  They would be surprised that C-x 2 all of a sudden
complains that their window is "too small for splitting".

Also note that often the buffer to be shown in the new window, for
example via 'pop-to-buffer', is unknown to 'split-window'.

I'm not against a fix for Bug#14825.  But doing it in a clean and
consistent way will be pretty hard.  Look at how often 'split-window'
calls 'window-sizable-p'.  All these calls would have to be rewritten
in some way or the other.

martin



^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: set-frame-size should respect line-spacing!?
  2019-10-13 17:06                         ` martin rudalics
@ 2019-10-14  8:06                           ` Eli Zaretskii
  0 siblings, 0 replies; 18+ messages in thread
From: Eli Zaretskii @ 2019-10-14  8:06 UTC (permalink / raw)
  To: martin rudalics; +Cc: ingo.lohmar, emacs-devel

> Cc: emacs-devel@gnu.org, ingo.lohmar@posteo.net
> From: martin rudalics <rudalics@gmx.at>
> Date: Sun, 13 Oct 2019 19:06:52 +0200
> 
>  > I think the only case where the issues raised by bug#14825 should
>  > matter is when we decide whether a window is too small.  E.g., what
>  > bad things will happen if we interpret window-min-height in terms of
>  > the default face's font set for the buffer shown (or to be shown) in
>  > the window?
> 
> Such an interpretation would cut both ways.  Think of people that use
> 'line-spacing' for ages or have remapped the default face font to
> something higher.  They would be surprised that C-x 2 all of a sudden
> complains that their window is "too small for splitting".

I very much doubt that, since less than 4 lines in a window is hardly
useful.

> Also note that often the buffer to be shown in the new window, for
> example via 'pop-to-buffer', is unknown to 'split-window'.

In that case, let us behave as we do currently.

> I'm not against a fix for Bug#14825.  But doing it in a clean and
> consistent way will be pretty hard.

I'm not going to lament its not being solved; it was you who brought
it into this discussion.  I suggest to proceed with the original
discussion disregarding that bug for now.



^ permalink raw reply	[flat|nested] 18+ messages in thread

end of thread, other threads:[~2019-10-14  8:06 UTC | newest]

Thread overview: 18+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-10-11 20:44 set-frame-size should respect line-spacing!? Ingo Lohmar
2019-10-12  7:00 ` Eli Zaretskii
2019-10-12  7:12   ` Ingo Lohmar
2019-10-12  7:48     ` Eli Zaretskii
2019-10-12  8:25       ` martin rudalics
2019-10-12  8:25     ` martin rudalics
2019-10-12  9:45       ` Eli Zaretskii
2019-10-12  9:56         ` Ingo Lohmar
2019-10-12 11:03         ` martin rudalics
2019-10-12 13:11           ` Eli Zaretskii
2019-10-13  8:16             ` martin rudalics
2019-10-13  9:10               ` Eli Zaretskii
2019-10-13 12:15                 ` martin rudalics
2019-10-13 12:18                   ` Eli Zaretskii
2019-10-13 12:51                     ` martin rudalics
2019-10-13 13:20                       ` Eli Zaretskii
2019-10-13 17:06                         ` martin rudalics
2019-10-14  8:06                           ` Eli Zaretskii

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

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).