*** empty log message ***
[wmaker-crm.git] / util / wsetfont
blob9095776c2777050b4e0cf3e997c7b20fc979325a
1 #!/bin/sh
3 # language/font setting script for Window Maker
5 # by MANOME Tomonori <manome@itlb.te.noda.sut.ac.jp>
7 # [Special Thanks To]
8 # Korean fontset info from:
9 # Byeong-Chan, Kim <redhands@linux.sarang.net>
10 # Chae-yong Chong <cychong@metro.telecom.samsung.co.kr>
11 # Latin2 fontset info from:
12 # Piotr Dembinski <pdemb@aurora.put.poznan.pl>
13 # Toni Bilic <root@toni.hr.tel.hr>
14 # Greek fontset info from:
15 # Nikolaos Papagrigoriou <papanikos@usa.net>
16 # Quote bug fix info from:
17 # Luke Kendall <luke@research.canon.com.au>
18 # Bug fix info for Korean font section from:
19 # CHOI Junho <junker@jazz.snu.ac.kr>
21 VERSION="Version 0.5 1998/12/07"
23 WDWRITE="wdwrite"
24 PROGRAM=`basename $0`
26 if test $# != 1; then
27 echo
28 echo "$PROGRAM - font/language setting utility for Window Maker"
29 echo
30 echo "Usage: $VERSION"
31 echo " $PROGRAM <option> "
32 cat <<EOF
33 -----------------------------------------------------------------------
34 [Option] [Fontset] [Font Information]
35 default helvetica
36 latin1 helvetica(iso8859-1)
37 latin2 helvetica(iso8859-2) See *Note1.
38 greek helvetica(iso8859-7) See *Note1.
39 japanese helvetica/-*-fixed(jisx02XX) Included in X11R6/XFree86("fnon" pkg)
40 korean helvetica/-*-kodig(ksc5601) See *Note1.
41 korean2 helvetica/daewoo(ksc5601) Included in X11R6/XFree86("fnon" pkg)
42 russian helvetica(koi8-r) Included in X11R6/XFree86("fcyr" pkg)
43 turkish unknown See *Note2.
44 -----------------------------------------------------------------------
45 Latin1 Languages: Danish/Dutch/English/Finnish/French/Galician/German/
46 Italian/Norwegian/Portuguese/Spanish/Swedish/...
47 Latin2 Languages: Croatian/Czech/Polish/Romanian/Slovenian/...
49 *Note1: Not included in X11R6/XFree86. You can download them from ...
50 Latin2 X fonts packages: http://sizif.mf.uni-lj.si/linux/cee/iso8859-2.html
51 Greek X fonts packages: ftp://argeas.argos.hol.gr/pub/unix/linux/GREEK/fonts/
52 ftp://ftp.ntua.gr/pub/fonts/X11/
53 Korean X fonts packages: ftp://linux.sarang.net (Linux RPM)
54 ftp://ftp.kaist.ac.kr/pub/hangul/fonts
55 *Note2: please let me know appropriate font setting for WMGLOBAL/WindowMaker,
56 and the fonts' URL to download. mail-to: manome@itlb.te.noda.sut.ac.jp
57 EOF
58 exit
61 case $1 in
62 default)
63 SystemFont=\"-*-helvetica-medium-r-normal-*-%d-*-*-*-*-*-*-*\"
64 BoldSystemFont=\"-*-helvetica-bold-r-normal-*-%d-*-*-*-*-*-*-*\"
65 WindowTitleFont=\"-*-helvetica-bold-r-normal-*-12-*-*-*-*-*-*-*\"
66 MenuTitleFont=\"-*-helvetica-bold-r-normal-*-12-*-*-*-*-*-*-*\"
67 MenuTextFont=\"-*-helvetica-medium-r-normal-*-12-*-*-*-*-*-*-*\"
68 IconTitleFont=\"-*-helvetica-medium-r-normal-*-8-*-*-*-*-*-*-*\"
69 ClipTitleFont=\"-*-helvetica-bold-r-normal-*-10-*-*-*-*-*-*-*\"
70 DisplayFont=\"-*-helvetica-medium-r-normal-*-12-*-*-*-*-*-*-*\"
72 latin1)
73 SystemFont=\"-*-helvetica-medium-r-normal-*-%d-*-*-*-*-*-iso8859-1\"
74 BoldSystemFont=\"-*-helvetica-bold-r-normal-*-%d-*-*-*-*-*-iso8859-1\"
75 WindowTitleFont=\"-*-helvetica-bold-r-normal-*-12-*-*-*-*-*-iso8859-1\"
76 MenuTitleFont=\"-*-helvetica-bold-r-normal-*-12-*-*-*-*-*-iso8859-1\"
77 MenuTextFont=\"-*-helvetica-medium-r-normal-*-12-*-*-*-*-*-iso8859-1\"
78 IconTitleFont=\"-*-helvetica-medium-r-normal-*-8-*-*-*-*-*-iso8859-1\"
79 ClipTitleFont=\"-*-helvetica-bold-r-normal-*-10-*-*-*-*-*-iso8859-1\"
80 DisplayFont=\"-*-helvetica-medium-r-normal-*-12-*-*-*-*-*-iso8859-1\"
82 latin2)
83 SystemFont=\"-*-helvetica-medium-r-normal-*-%d-*-*-*-*-*-iso8859-2\"
84 BoldSystemFont=\"-*-helvetica-bold-r-normal-*-%d-*-*-*-*-*-iso8859-2\"
85 WindowTitleFont=\"-*-helvetica-bold-r-normal-*-12-*-*-*-*-*-iso8859-2\"
86 MenuTitleFont=\"-*-helvetica-bold-r-normal-*-12-*-*-*-*-*-iso8859-2\"
87 MenuTextFont=\"-*-helvetica-medium-r-normal-*-12-*-*-*-*-*-iso8859-2\"
88 IconTitleFont=\"-*-helvetica-medium-r-normal-*-8-*-*-*-*-*-iso8859-2\"
89 ClipTitleFont=\"-*-helvetica-bold-r-normal-*-10-*-*-*-*-*-iso8859-2\"
90 DisplayFont=\"-*-helvetica-medium-r-normal-*-12-*-*-*-*-*-iso8859-2\"
92 greek)
93 SystemFont=\"-*-helvetica-medium-r-normal-*-%d-*-*-*-*-*-iso8859-7\"
94 BoldSystemFont=\"-*-helvetica-bold-r-normal-*-%d-*-*-*-*-*-iso8859-7\"
95 WindowTitleFont=\"-*-helvetica-bold-r-normal-*-14-*-*-*-*-*-iso8859-7\"
96 MenuTitleFont=\"-*-helvetica-medium-r-normal-*-14-*-*-*-*-*-iso8859-7\"
97 MenuTextFont=\"-*-helvetica-medium-r-normal-*-14-*-*-*-*-*-iso8859-7\"
98 IconTitleFont=\"-*-helvetica-bold-r-normal-*-10-*-*-*-*-*-iso8859-7\"
99 ClipTitleFont=\"-*-helvetica-medium-r-normal-*-12-*-*-*-*-*-iso8859-7\"
100 DisplayFont=\"-*-helvetica-medium-r-normal-*-12-*-*-*-*-*-iso8859-7\"
102 russian)
103 SystemFont=\"-*-helvetica-medium-r-normal-*-%d-*-*-*-*-*-koi8-r\"
104 BoldSystemFont=\"-*-helvetica-bold-r-normal-*-%d-*-*-*-*-*-koi8-r\"
105 WindowTitleFont=\"-*-helvetica-bold-r-normal-*-12-*-*-*-*-*-koi8-r\"
106 MenuTitleFont=\"-*-helvetica-bold-r-normal-*-12-*-*-*-*-*-koi8-r\"
107 MenuTextFont=\"-*-helvetica-medium-r-normal-*-12-*-*-*-*-*-koi8-r\"
108 IconTitleFont=\"-*-helvetica-medium-r-normal-*-8-*-*-*-*-*-koi8-r\"
109 ClipTitleFont=\"-*-helvetica-bold-r-normal-*-10-*-*-*-*-*-koi8-r\"
110 DisplayFont=\"-*-helvetica-medium-r-normal-*-12-*-*-*-*-*-koi8-r\"
112 japanese)
113 SystemFont=\"-*-helvetica-medium-r-normal-*-%d-*-*-*-*-*-*-*,-*-*-medium-r-normal-*-%d-*,-*-*-medium-r-normal-*-*-*\"
114 BoldSystemFont=\"-*-helvetica-bold-r-normal-*-%d-*-*-*-*-*-*-*,-*-*-medium-r-normal-*-%d-*,-*-*-medium-r-normal-*-*-*\"
115 WindowTitleFont=\"-*-helvetica-bold-r-normal-*-12-*-*-*-*-*-*-*,-*-*-medium-r-normal-*-14-*,-*-*-medium-r-normal-*-*-*\"
116 MenuTitleFont=\"-*-helvetica-bold-r-normal-*-12-*-*-*-*-*-*-*,-*-*-medium-r-normal-*-14-*,-*-*-medium-r-normal-*-*-*\"
117 MenuTextFont=\"-*-helvetica-medium-r-normal-*-12-*-*-*-*-*-*-*,-*-*-medium-r-normal-*-14-*,-*-*-medium-r-normal-*-*-*\"
118 IconTitleFont=\"-*-helvetica-medium-r-normal-*-8-*-*-*-*-*-*-*,-*-*-medium-r-normal-*-12-*,-*-*-medium-r-normal-*-*-*\"
119 ClipTitleFont=\"-*-helvetica-bold-r-normal-*-10-*-*-*-*-*-*-*,-*-*-medium-r-normal-*-12-*,-*-*-medium-r-normal-*-*-*\"
120 DisplayFont=\"-*-helvetica-medium-r-normal-*-12-*-*-*-*-*-*-*,-*-*-medium-r-normal-*-14-*,-*-*-medium-r-normal-*-*-*\"
122 korean)
123 SystemFont=\"-*-helvetica-medium-r-normal-*-%d-*-*-*-*-*-*-*,-*-kodig-medium-r-normal--%d-*-*-*-*-*-*-*,*-*-medium-r-normal-*-%d-*-*-*-*-*-*-*,*-*-*-*-*--%d-*-*-*-*-*-*-*,*\"
124 BoldSystemFont=\"-*-helvetica-bold-r-normal-*-%d-*-*-*-*-*-*-*,-*-kodig-bold-r-normal--%d-*-*-*-*-*-*-*,-*-kodig-medium-r-normal--%d-*-*-*-*-*-*-*,*-*-bold-r-normal-*-%d-*-*-*-*-*-*-*,*-*-*-*-*--%d-*-*-*-*-*-*-*,*\"
125 WindowTitleFont=\"-*-helvetica-bold-r-normal-*-12-*-*-*-*-*-*-*,-*-kodig-medium-r-normal--12-*-*-*-*-*-*-*,-*-*-medium-r-normal--12-*-*-*-*-*-*-*,-*-*-medium-r-normal--*-*-*-*-*-*-*-*,-*-*-*-r-normal--*-*-*-*-*-*-*-*,-*-*-*-*-*--*-*-*-*-*-*-*-*,*\"
126 MenuTitleFont=\"-*-helvetica-bold-r-normal-*-12-*-*-*-*-*-*-*,-*-kodig-medium-r-normal--14-*-*-*-*-*-*-*,-*-*-medium-r-normal--12-*-*-*-*-*-*-*,*-*-medium-r-normal--*-*-*-*-*-*-*-*,*-*-*-r-normal--*-*-*-*-*-*-*-*,*\"
127 MenuTextFont=\"-*-helvetica-medium-r-normal-*-12-*-*-*-*-*-*-*,-*-kodig-medium-r-normal--14-*-*-*-*-*-*-*,*-*-medium-r-normal--12-*-*-*-*-*-*-*,*-*-medium-r-normal--*-*-*-*-*-*-*-*,*-*-*-r-normal--*-*-*-*-*-*-*-*,*\"
128 IconTitleFont=\"-*-helvetica-medium-r-normal-*-8-*-*-*-*-*-*-*,-*-kodig-medium-r-normal--10-*-*-*-*-*-*-*,*-*-medium-r-normal--10-*-*-*-*-*-*-*,*-*-medium-r-normal--*-*-*-*-*-*-*-*,*-*-*-r-normal--*-*-*-*-*-*-*-*,*\"
129 ClipTitleFont=\"-*-helvetica-bold-r-normal-*-10-*-*-*-*-*-*-*,-*-kodig-medium-r-normal--10-*-*-*-*-*-*-*,*-*-medium-r-normal--10-*-*-*-*-*-*-*,*-*-medium-r-normal--*-*-*-*-*-*-*-*,*-*-*-r-normal--*-*-*-*-*-*-*-*,*\"
130 DisplayFont=\"-*-helvetica-medium-r-normal-*-12-*-*-*-*-*-*-*,-*-kodig-medium-r-normal--12-*-*-*-*-*-*-*,*-*-medium-r-normal--12-*-*-*-*-*-*-*,*-*-medium-r-normal--*-*-*-*-*-*-*-*,*-*-*-r-normal--*-*-*-*-*-*-*-*,*\"
132 korean2)
133 SystemFont=\"-*-helvetica-medium-r-normal-*-%d-*-*-*-*-*-*-*,-*-medium-r-normal-*-%d-*,-*-medium-r-normal-*\"
134 BoldSystemFont=\"-*-helvetica-bold-r-normal-*-%d-*-*-*-*-*-*-*,-*-medium-r-normal-*-%d-*,-*-medium-r-normal-*\"
135 WindowTitleFont=\"7x14,-*-gothic-medium-r-normal-*-16-*-*-*-*-*-ksc5601.1987-*\"
136 MenuTitleFont=\"7x14,-*-gothic-medium-r-normal-*-16-*-*-*-*-*-ksc5601.1987-*\"
137 MenuTextFont=\"7x14,-*-gothic-medium-r-normal-*-16-*-*-*-*-*-ksc5601.1987-*\"
138 IconTitleFont=\"-*-helvetica-medium-r-normal-*-10-*-*-*-*-*-*-*,-*-gothic-medium-r-normal-*-12-*-*-*-*-*-ksc5601.1987-*\"
139 ClipTitleFont=\"-*-helvetica-bold-r-normal-*-10-*-*-*-*-*-*-*,-*-gothic-medium-r-normal-*-12-*-*-*-*-*-ksc5601.1987-*\"
140 DisplayFont=\"-*-helvetica-medium-r-normal-*-12-*-*-*-*-*-*-*,-*-gothic-medium-r-normal-*-16-*-*-*-*-*-ksc5601.1987-*\"
143 echo "NOTICE:"
144 echo "Sorry I don't know appropriate font configuration for \"$1\""
145 echo "please let me know your settings for SystemFont,BoldSystemFont,"
146 echo "WindowTitleFont,MenuTitleFont,IconTitleFont,ClipTitleFont,and"
147 echo "DisplayFont thanks"
148 echo "and please let me know also the URL of the fonts to download"
149 echo "if your language need some special fonts not included in "
150 echo "X11R6/XFree."
151 echo "mail-to: manome@itlb.te.noda.sut.ac.jp"
152 exit
154 esac
158 # setting fonts
161 echo "Setting up ~/GNUstep/Defaults/WMGLOBAL..."
163 $WDWRITE WMGLOBAL SystemFont "$SystemFont"
164 $WDWRITE WMGLOBAL BoldSystemFont "$BoldSystemFont"
166 echo
167 echo " SystemFont=$SystemFont"
168 echo " BoldSystemFont=$BoldSystemFont"
169 echo
170 echo "Setting up ~/GNUstep/Defaults/WindowMaker..."
172 $WDWRITE WindowMaker WindowTitleFont "$WindowTitleFont"
173 $WDWRITE WindowMaker MenuTitleFont "$MenuTitleFont"
174 $WDWRITE WindowMaker MenuTextFont "$MenuTextFont"
175 $WDWRITE WindowMaker IconTitleFont "$IconTitleFont"
176 $WDWRITE WindowMaker ClipTitleFont "$ClipTitleFont"
177 $WDWRITE WindowMaker DisplayFont "$DisplayFont"
179 echo
180 echo "WindowTitleFont=$WindowTitleFont"
181 echo "MenuTitleFont=$MenuTitleFont"
182 echo "MenuTextFont=$MenuTextFont"
183 echo "IconTitleFont=$IconTitleFont"
184 echo "ClipTitleFont=$ClipTitleFont"
185 echo "DisplayFont=$DisplayFont"
186 echo
187 echo "Done."