unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: storm@cua.dk (Kim F. Storm)
Cc: wilde@sha-bang.de, jyavner@member.fsf.org, rms@gnu.org,
	monnier@iro.umontreal.ca, emacs-devel@gnu.org
Subject: Re: Default face problem
Date: Mon, 01 May 2006 10:25:54 +0200	[thread overview]
Message-ID: <m3odyib17x.fsf@kfs-l.imdomain.dk> (raw)
In-Reply-To: <E1FaOLe-0001Vr-00@etlken> (Kenichi Handa's message of "Mon, 01 May 2006 11:41:18 +0900")

Kenichi Handa <handa@m17n.org> writes:

> In article <m3aca6lyrz.fsf_-_@kfs-l.imdomain.dk>, storm@cua.dk (Kim F. Storm) writes:
>
>> storm@cua.dk (Kim F. Storm) writes:
>>> Sascha Wilde <wilde@sha-bang.de> writes:
>>> 
>>>>>> I still do see a heavy misalignment of the header line in ses (with
>>>>>> X11), but only when using a font with an odd size
>>>>>> (-*-terminus-medium-r-*-*-17-*-*-*-*-*-iso8859-1 here).
>>> 
>>> I see it too.
>>> 
>>> If I customize the default face, and change the height from 99 to 100,
>>> it works again.  I'll look into what's wrong.
>
> This is because the current Emacs refuses to use an
> auto-scaled font because it's usually too agree to use for
> the editing work.  

Thanks for the explanation.  I think I understand.

But why does it think it is ok to use such a font as the
frame's default font?

The problem we see is because the :align-to specs in the header line
are formatted based on the width of the frame's default font, but if
the default font is not used in the frame text, the result is very
confusing.


>                    It at first checks the availability of
> the specified font (without checking it's auto-scaled or
> not), but, later on deciding a font for a face, it lists
> fonts matching with family-name and registry-name, then
> selects the best one among them.  

Wouldn't it make sense to fix the frame's default font at this
step (eg. in realize_basic_faces) when it is detected that
the specified default font is "not available".

The test could be something like this (pseudo-code) inserted
just after realizing the default face:

if (frame->default_face->font != frame->default_font)
  frame->default_font = frame->default_face->font;


>                                   On this selection,
> auto-scaled font is refused even if scalable-fonts-allowed
> is non-nil.  So, in your case the 16-dots font (that is
> surely included in terminus font package) is selected.

-- 
Kim F. Storm <storm@cua.dk> http://www.cua.dk

  parent reply	other threads:[~2006-05-01  8:25 UTC|newest]

Thread overview: 39+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-03-20 22:35 incomplete header-line with 3d boxes and prop fonts Stefan Monnier
2006-04-24  0:25 ` Kim F. Storm
2006-04-24  6:58   ` Stefan Monnier
2006-04-24 11:51   ` Richard Stallman
2006-04-24 12:11     ` Kim F. Storm
2006-04-25  3:16       ` Jonathan Yavner
2006-04-25 22:04         ` Richard Stallman
2006-04-25 12:38       ` Sascha Wilde
2006-04-25 14:47         ` Kim F. Storm
2006-04-25 15:11           ` Sascha Wilde
2006-04-27 22:53             ` Kim F. Storm
2006-04-28 11:34               ` Default face problem [was: Re: incomplete header-line with 3d boxes and prop fonts] Kim F. Storm
2006-05-01  2:41                 ` Kenichi Handa
2006-05-01  3:14                   ` Default face problem Stefan Monnier
2006-05-01  4:32                     ` Kenichi Handa
2006-05-01 12:34                       ` Stefan Monnier
2006-05-01 12:51                         ` Kenichi Handa
2006-05-01 13:58                           ` Stefan Monnier
2006-05-02  0:42                             ` Kenichi Handa
2006-05-01  8:25                   ` Kim F. Storm [this message]
2006-05-01 12:35                     ` Stefan Monnier
2006-05-01 12:49                       ` Kim F. Storm
2006-05-08  5:51                     ` Kenichi Handa
2006-05-08  8:47                       ` Kim F. Storm
2006-05-08 11:50                         ` Kenichi Handa
2006-05-08 12:19                           ` Kim F. Storm
2006-05-10  4:17                             ` Kenichi Handa
2006-05-10 12:21                               ` Kim F. Storm
2006-05-10 12:41                                 ` Kenichi Handa
2006-05-10 17:45                                   ` Eli Zaretskii
2006-05-11  0:36                                     ` Kenichi Handa
2006-05-11  3:40                                       ` Eli Zaretskii
2006-05-11  4:35                                         ` Kenichi Handa
2006-05-13 13:04                                           ` Eli Zaretskii
2006-05-15  1:41                                             ` Kenichi Handa
2006-05-15  3:33                                               ` Eli Zaretskii
2006-05-15  4:47                                                 ` Kenichi Handa
2006-05-10 17:45                               ` Eli Zaretskii
2006-04-24 13:02     ` incomplete header-line with 3d boxes and prop fonts Stefan Monnier

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

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=m3odyib17x.fsf@kfs-l.imdomain.dk \
    --to=storm@cua.dk \
    --cc=emacs-devel@gnu.org \
    --cc=jyavner@member.fsf.org \
    --cc=monnier@iro.umontreal.ca \
    --cc=rms@gnu.org \
    --cc=wilde@sha-bang.de \
    /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 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).