all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* How to set the font of a region?
@ 2004-07-29 13:38 Pascal Bourguignon
  2004-07-29 14:51 ` Kevin Rodgers
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Pascal Bourguignon @ 2004-07-29 13:38 UTC (permalink / raw)



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?

-- 
__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

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

end of thread, other threads:[~2004-08-05  8:12 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
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
2004-08-05  8:12 ` Oliver Scholz

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.