Changeset 347


Ignore:
Timestamp:
Dec 4, 2009 5:04:32 PM (11 years ago)
Author:
toby
Message:

# on 2000/11/21 21:21:57, toby did:
doc how to change fonts

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/doc/expgui_cfg.html

    • Property rcs:date changed from 2000/10/18 00:11:17 to 2000/11/21 21:21:57
    • Property rcs:lines changed from +2 -2 to +49 -1
    • Property rcs:rev changed from 1.15 to 1.16
    r338 r347  
    671671</UL>
    672672</OL>
     673
     674<hr><H2>
     675Customizing Example 4: Changing the fonts used in the GUI
     676</H2>
     677<B>Question: </B>
     678<I>I use a 19" screen with a resolution 1280x1024. With this resolution, the
     679fonts are really small in the GUI. Is a way exist to increase the font size?
     680</I>
     681<UL>
     682<B>Answer: </B>
     683The fonts used in EXPGUI can be customized by adding some code to the
     684<TT>localconfig</TT> file or the
     685<TT>~/.gsas_config</TT> or (or <TT>C:\GSAS\EXPGUI\.gsas_config</TT>) file.
     686By default, fonts are 14 point for the menus, buttons, labels,... and
     68712 point for the histogram and atom lists.
     688<P>
     689This code changes those fonts to 18 and 16 point, respectively.
     690<UL><PRE>
     691option add *Font            -*-helvetica-medium-r-normal-*-18-*-*-*-*-*-*-*
     692option add *font            -*-helvetica-medium-r-normal-*-18-*-*-*-*-*-*-*
     693option add *Menu.font       -*-helvetica-bold-r-normal-*-18-*-*-*-*-*-*-*
     694option add *Menubutton.font -*-helvetica-bold-r-normal-*-18-*-*-*-*-*-*-*
     695option add *Label.font      -*-helvetica-bold-r-normal-*-18-*-*-*-*-*-*-*
     696option add *Scale.font      -*-helvetica-bold-o-normal-*-18-*-*-*-*-*-*-*
     697option add *TitleFrame.font -*-helvetica-bold-o-normal-*-18-*-*-*-*-*-*-*
     698set expgui(coordfont) "-*-courier-bold-r-normal--16-*"
     699set expgui(histfont) "-*-courier-bold-r-normal--16-*"
     700</PRE></UL>
     701<P>
     702A slightly different and perhaps cleaner approach is to specify the font
     703sizes in pixels.
     704The code below uses font sizes of 18 and 16 pixels, respectively.
     705<UL><PRE>
     706option add *Font            "Helvetica -18"
     707option add *font            "Helvetica -18"
     708option add *Menu.font       "Helvetica -18 bold"
     709option add *Menubutton.font "Helvetica -18 bold"
     710option add *Label.font      "Helvetica -18 bold"
     711option add *Scale.font      "Helvetica -18 bold italic"
     712option add *TitleFrame.font "Helvetica -18 bold italic"
     713set expgui(coordfont) "Courier -16 bold"
     714set expgui(histfont)  "Courier -16 bold"
     715</PRE></UL>
     716It should be noted that the appearance of fonts depends on many factors --
     717the fonts installed on your computer, the screen size and resolution and your
     718eyes, so it is wise to experiment with different values in the above
     719examples.
     720</UL>
    673721<hr>
    674722<TABLE BORDER BGCOLOR="#FFFF40" ALIGN=RIGHT>
Note: See TracChangeset for help on using the changeset viewer.