unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
From: Pascal Bourguignon <spam@thalassa.informatimago.com>
Subject: Re: How to set the font of a region?
Date: 29 Jul 2004 17:28:21 +0200	[thread overview]
Message-ID: <87oely6dey.fsf@thalassa.informatimago.com> (raw)
In-Reply-To: 8765876iil.fsf@thalassa.informatimago.com

Pascal Bourguignon <spam@thalassa.informatimago.com> writes:

> I tried this (on X, emacs 21.3.1): 
> 
> (let* ((default-font "-*-console-medium-r-normal-*-16-*-*-*-*-*-*-*")
>        (default-face (gensym "face")))
>   (make-face default-face)
>   (set-face-font default-face default-font)
>   (dolist (font font-list)
>     (let ((face (gensym "face")))
>       (make-face face)
>       (set-face-font face font)
>       (let ((start (point)))
>         (insert font)
>         (insert "\n")
>         (facemenu-add-face 'default start (point))
>         (facemenu-set-face default-face start (point)))
>       (let ((start (point)))
>         (insert "The lazy dog jumped over the fast fox! (let [it {be} and] say) no.more;\n")
>         (facemenu-add-face 'default start (point))
>         (facemenu-set-face face start (point))))))
> 
> -->
> 
> --international-medium-r-normal--15-150-72-72-m-90-iso8859-1
> The lazy dog jumped over the fast fox! (let [be {it} and] say) no.more;
> --iris-medium-r-normal--10-100-72-72-m-60-iso8859-1
> The lazy dog jumped over the fast fox! (let [be {it} and] say) no.more;
> --iris-medium-r-normal--12-120-72-72-m-80-iso8859-1
> The lazy dog jumped over the fast fox! (let [be {it} and] say) no.more;
> --iris-medium-r-normal--13-130-72-72-m-90-iso8859-1
> The lazy dog jumped over the fast fox! (let [be {it} and] say) no.more;
> ...
> 
> 
> but all the text generated keeps the same default font.  Why my
> facemenu-set-face calls are without effect?

No, apart being much slower, there's no change in results.

-- 
__Pascal Bourguignon__                     http://www.informatimago.com/

There is no worse tyranny than to force a man to pay for what he does not
want merely because you think it would be good for him. -- Robert Heinlein

  parent reply	other threads:[~2004-07-29 15:28 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-07-29 13:38 How to set the font of a region? Pascal Bourguignon
2004-07-29 14:51 ` Kevin Rodgers
2004-07-29 15:28 ` Pascal Bourguignon [this message]
2004-08-05  8:12 ` Oliver Scholz

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=87oely6dey.fsf@thalassa.informatimago.com \
    --to=spam@thalassa.informatimago.com \
    /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.
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).