1

I use the following in my .emacs to set my default font to Ubuntu Mono:

(set-face-attribute 'default nil :font "Ubuntu Mono")

However, the defauly font size is too tiny for me. In my menubar I see Options->Set Default Font..., but the changes I make there does not propogate to my next session.

Should I be setting something in .emacs to set default font size? (I like it to be 24)

Thanks!

3
  • 2
    possible duplicate stackoverflow.com/questions/294664/… Commented Feb 10, 2012 at 17:32
  • 1
    I think it's just because you didn't "save" the setting (I remember there is another option in the menubar to save the setting.)
    – yuyichao
    Commented Feb 10, 2012 at 17:37
  • @harish.venkat Nice find. We can't actually close as a duplicate of a post on another site, but I used that answer to write one here Commented Feb 10, 2012 at 19:18

1 Answer 1

3

An answer to a similar Stack Overflow question mentions that another argument to set-face-attribute is height, which takes an integer representing tenths of a point. So to make it 24pt, you would use:

(set-face-attribute 'default nil :font "Ubuntu Mono" :height 240)

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .