Starting with GnuEmacs 23, you can zoom the text in the current buffer, in all frames displaying it: You can resize (text-scale) the text in a buffer (in all windows showing it), or you can resize the default font of a frame. You may have to fiddle because it’s a little unclear to me how the scale variables affect things, even reading this documentation: $ GDK_SCALE=1.7 GDK_DPI_SCALE=1.7 GTK_THEME=Adwaita emacs & In the end I found the GDK_SCALE, GDK_DPI_SCALE and GTK_THEME environment variables were a quick shortcut to the readability I wanted. I initially started digging into all these settings to change the menubar font size and color to be more readable. When using gtk emacs on a remote 4k display, I would get an small black menubar with tiny white lettering. will change all “toolkit” fonts (menus, dialogs). Widget "*emacs-menuitem*" style "menufont" This example changes to an Arial font with height 140: (face-remap-add-relative 'default :family "Arial" :height 140)Ĭhanging the (buffer) menu fonts for GTK emacsĪccording to say in ~/.emacs.d/gtkrc: style "menufont"įont_name = "monospace 10" # Pango font name To change the font of the current buffer, you can put code like this in your init file. In my ~/.Xresources and ~/.emacs, respectively. For instance, to use Terminus, 9 pixel size across the board, I needed to insert It doesn’t like (set-face-attribute ‘default nil :font FONT) and the like. But the declarations can’t conflict with each other. I found that the only way to set fonts so that they remain consistent across emacs -nw, emacs23(-gtk), emacsclient -t, emacsclient -c, was to declare them in. Including a set-face-attribute hook as described above for a particular mode does not work once you enter that mode the new font is set, but it is applied globally to all other open buffers!) Global Fonts. (There needs to be an explanation for how to set fonts for particular modes or buffers here. If you are using a development snapshot for what will become Emacs 24.4 then see Emacs bug #16529. As of Emacs 23, all of your system fonts including TrueType are available to Emacs. Where FONT is a string naming the font you want, for example, "Droid Sans Mono-10". To change the default font for the current frame, as well as future frames, put either of these in your init file: (set-face-attribute 'default nil :font FONT ) (set-frame-font FONT nil t) FONT )) (set-face-attribute 'default t :font FONT ) To change the default font for new (non special-display) frames, put either of these in your init file: (add-to-list 'default-frame-alist '(font. Use Anything command ‘anything-select-xfont’ to narrow the font list by typing some patterns.Use command ‘icicle-font’ in Icicles to do the same thing (cycle among fonts) – but with the added benefit of completion, including regexp matching.Use command ‘doremi-font’ in DoReMi to change the default font of a frame by cycling among the available fonts – just stop when you get to the font you want.See GoodFonts for some recommendations, see FontSets for how to set various fonts at the same time (one per coding system).
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |