all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Ingo Lohmar <ingo.lohmar@posteo.net>
To: Eli Zaretskii <eliz@gnu.org>, martin rudalics <rudalics@gmx.at>
Cc: emacs-devel@gnu.org
Subject: Re: set-frame-size should respect line-spacing!?
Date: Sat, 12 Oct 2019 11:56:03 +0200	[thread overview]
Message-ID: <871rvil230.fsf@kenko.localhost.com> (raw)
In-Reply-To: <8336fynvq4.fsf@gnu.org>

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.



  reply	other threads:[~2019-10-12  9:56 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
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 [this message]
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

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=871rvil230.fsf@kenko.localhost.com \
    --to=ingo.lohmar@posteo.net \
    --cc=eliz@gnu.org \
    --cc=emacs-devel@gnu.org \
    --cc=rudalics@gmx.at \
    /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.