[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Calendar & proportional fonts

From: B. T. Raven
Subject: Re: Calendar & proportional fonts
Date: Sun, 30 Sep 2012 17:41:39 -0500
User-agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:15.0) Gecko/20120907 Thunderbird/15.0.1

> On 30/09/12 20:10, B. T. Raven wrote:
>> Die Sun Sep 30 2012 07:35:24 GMT-0500 (Central Daylight Time)
>> hairryharry <> scripsit:
>>> Hi,
>>> When I use proportional fonts in emacs 23 & 24 I find the calendar dates
>>> do not line up. OK with fixed fonts.
>>> Fairly new to emacs but have tried fiddling with calendar spacing
>>> variables but not able to fix.
>>> Any ideas or pointers would be gratefully received.
>>> Thanks,
>>> Mike
>> I set up two frames in .emacs, one with a default proportional font, and
>> the other with a fixed font. Then I can look at Calendar correctly in
>> the fixed font frame.
>> Ed
> Thanks Ed,
> Had sort of heard about doing that but not sure how to. Could you give
> me a pointer to how you set the frames up in your .emacs.
> Thanks,
> Mike

My .emacs intializes the w32 build, so you will need to use different
font names, etc. but the lisp functionality should be the same:

Near end of my .emacs is this

(setq initial-frame-alist '((name . "arial") (top . 370) (left . 1)
(width . 205) (height . 18)))

  ;; custom-set-faces was added by Custom.
  ;; If you edit it by hand, you could mess it up, so be careful.
  ;; Your init file should contain only one such instance.
  ;; If there is more than one, they won't work right.
 '(default ((t (:stipple nil :background "ghostwhite" :foreground
"black" :inverse-video nil :box nil :strike-through nil :overline nil
:underline nil :slant normal :weight normal :height 108 :width normal
:family "outline-arial unicode ms"))))
 '(scroll-bar ((t (:background "#ffffff" :foreground "#000000")))))

and then for the fixed Courier font:

(make-frame '((name . "courier")
           (top . 1) (left . 1) (width . 123) (height . 18)
           (visibility . icon) ; nil or icon

(select-frame-by-name "courier")
(set-frame-font "-outline-Courier

the frame coords are from long ago when they made approx. equal frames
at top and bottom of some monitor screen. It would be nice if they could
be parameterized somehow so that they would fit automatically on any
screen size. Lines would wrap at different points because a certain
screen width in pixels would accommodate only so many characters.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]