all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* Re: emacs menu font in GTK-2 and GTK-3
@ 2015-08-11 20:09 Nelson H. F. Beebe
  0 siblings, 0 replies; 4+ messages in thread
From: Nelson H. F. Beebe @ 2015-08-11 20:09 UTC (permalink / raw)
  To: emacs-devel; +Cc: beebe

Thanks to Paul Eggert's tips, and his pointer to

	http://superuser.com/questions/597076/gtk-3-menu-configuration-for-emacs

I now have a simple solution for GTK-3-based emacs builds that works for me,
and provides a larger, and more easily-readable, menu font:

    % cat ~/.config/gtk-3.0/gtk.css
    #pane #menubar,
    #pane #menubar GtkMenuShell,
    #pane #menubar GtkMenuShell *
    {
	font-family: "URWPalladio";
	font-size: 18px;
    }

I've done simple startup tests of the above initializations with

	emacs-23.4
	emacs-24.3.92
	emacs-24.3.93
	emacs-24.3.94
	emacs-24.4
	emacs-24.4.90
	emacs-24.5

on CentOS 7, and they all behave the same way: the menu bar is now
readable.


Until a few minutes ago when I did a mkdir, the directory
~/.config/gtk-3.0 did not exist on my system.

The above link suggests that such cascading-style-sheet file settings
are overly general, and apply to all GTK-based windows, instead of
restricting them to just emacs.

Perhaps other list members will have some insights on how to restrict
the initializations to just emacs.

I don't work in a Gnome window environment, so the generality does not
matter to me.  The important thing is that I can now get on with my
desktop migration from Solaris to CentOS 7, with my new
high-resolution display :^)!

-------------------------------------------------------------------------------
- Nelson H. F. Beebe                    Tel: +1 801 581 5254                  -
- University of Utah                    FAX: +1 801 581 4148                  -
- Department of Mathematics, 110 LCB    Internet e-mail: beebe@math.utah.edu  -
- 155 S 1400 E RM 233                       beebe@acm.org  beebe@computer.org -
- Salt Lake City, UT 84112-0090, USA    URL: http://www.math.utah.edu/~beebe/ -
-------------------------------------------------------------------------------



^ permalink raw reply	[flat|nested] 4+ messages in thread
* emacs menu font in GTK-2 and GTK-3
@ 2015-08-11 17:59 Nelson H. F. Beebe
  2015-08-11 19:25 ` Paul Eggert
  2015-08-12  6:35 ` Yuri Khan
  0 siblings, 2 replies; 4+ messages in thread
From: Nelson H. F. Beebe @ 2015-08-11 17:59 UTC (permalink / raw)
  To: emacs-devel; +Cc: beebe

I recently upgraded my desktop workstation, doubling my screen
resolution to 3840x2160 pixels, and changing from Solaris SPARC to
CentOS 7 x86-64.  The higher resolution has been welcome, but I'm
still struggling with selecting larger font sizes in several
applications, including emacs.

When emacs is linked with a GTK-2 library, such as
/usr/lib64/libgtk-x11-2.0.so.0 on CentOS 6, then a startup file of the
form

	% cat ~/.emacs.d/gtkrc
	style "menufont"
	{
	    font_name = "URWPalladio          16"
	}

	widget "*emacs-menuitem*" style "menufont"

suffices to enlarge the menu bar

	File  Edit  Options  Buffers  Tools  Emacs-Lisp  Help

to a readable size.  

However, on CentOS 7, linking is to /lib64/libgtk-3.so.0.  The above
setting then has no effect, and the default menu font is too small to
be read comfortably.

A system call trace of emacs startup shows that with GTK-3, the file
~/.emacs.d/gtkrc is not even read; instead, the file
~/.config/pango/pangorc seems to be the only user-specific GTK startup
file that is read.  However, its syntax is different from that of
gtkrc, so it does not seem to be the place where emacs menu font
choices are made.

Does anyone on this list know how menu-bar font names and sizes are
chosen with GTK-3 is linked into emacs?

Once we figure this out, the doc/emacs/xresources.texi needs to be
updated to document the procedure for GTK-3 library support.

-------------------------------------------------------------------------------
- Nelson H. F. Beebe                    Tel: +1 801 581 5254                  -
- University of Utah                    FAX: +1 801 581 4148                  -
- Department of Mathematics, 110 LCB    Internet e-mail: beebe@math.utah.edu  -
- 155 S 1400 E RM 233                       beebe@acm.org  beebe@computer.org -
- Salt Lake City, UT 84112-0090, USA    URL: http://www.math.utah.edu/~beebe/ -
-------------------------------------------------------------------------------



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

end of thread, other threads:[~2015-08-12  6:35 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-08-11 20:09 emacs menu font in GTK-2 and GTK-3 Nelson H. F. Beebe
  -- strict thread matches above, loose matches on Subject: below --
2015-08-11 17:59 Nelson H. F. Beebe
2015-08-11 19:25 ` Paul Eggert
2015-08-12  6:35 ` Yuri Khan

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.