1 | <HTML> |
---|
2 | <HEAD> |
---|
3 | <TITLE> |
---|
4 | How to install new Type1 fonts on an HP-UX 10.20 machine |
---|
5 | </TITLE> |
---|
6 | </HEAD> |
---|
7 | <BODY> |
---|
8 | Sergey A. Babkin |
---|
9 | <br> |
---|
10 | <A HREF="mailto:babkin@bellatlantic.net"> |
---|
11 | <babkin@bellatlantic.net></A> or <A HREF="mailto:sab123@hotmail.com"><sab123@hotmail.com></A> |
---|
12 | <p> |
---|
13 | <! |
---|
14 | (Do not edit this file, it is generated from FONTS.hpux.html!!!) |
---|
15 | > |
---|
16 | |
---|
17 | <H3> |
---|
18 | How to install new Type1 fonts on an HP-UX 10.20 machine |
---|
19 | </H3> |
---|
20 | <! |
---|
21 | -------------------------------------------------------- |
---|
22 | > |
---|
23 | |
---|
24 | 1. Add the font files to <tt>/usr/lib/X11/fonts/type1.st/typefaces</tt>. |
---|
25 | <p> |
---|
26 | |
---|
27 | 2. Add the font descriptions to |
---|
28 | <tt>/usr/lib/X11/fonts/type1.st/typefaces/fonts.scale</tt>. Run `mkfontdir' |
---|
29 | in <tt>/usr/lib/X11/fonts/type1.st/typefaces</tt>. In the descriptions |
---|
30 | you have to specify the font manufacturer as `misc', like: |
---|
31 | <p> |
---|
32 | |
---|
33 | <tt> |
---|
34 | -misc-courier-... |
---|
35 | </tt> |
---|
36 | <p> |
---|
37 | |
---|
38 | 3. Copy <tt>/usr/lib/X11/fonts/type1.st/typefaces/fonts.dir</tt> to |
---|
39 | <tt>/usr/lib/X11/fonts/type1.st/licenses/STSYSTEM/DISPLAYS/fonts.dir</tt>. |
---|
40 | Better yet, create a symbolic link. |
---|
41 | <p> |
---|
42 | |
---|
43 | 4. For each font encoding you are going to use create a description |
---|
44 | file in <tt>/usr/lib/X11/fonts/stadmin/type1/charsets</tt>. Of course, if you |
---|
45 | are going to use the same fonts in several encodings, the best way |
---|
46 | would be to create fair descriptions of charsets and really store |
---|
47 | only one encoding in typefaces, all the others will be produced |
---|
48 | automatically. That's not difficult at all. |
---|
49 | But the simplest way is to just copy the file <tt>cp.iso8859-1</tt> |
---|
50 | to <tt>cp.<i><your-encoding-name></i></tt>, like <tt>cp.koi8-r</tt>. |
---|
51 | <p> |
---|
52 | |
---|
53 | 5. Restart you X server and/or font server. |
---|
54 | <p> |
---|
55 | |
---|
56 | <H4> |
---|
57 | What if you don't have the `root' privileges ? |
---|
58 | </H4> |
---|
59 | <! |
---|
60 | ---------------------------------------------- |
---|
61 | > |
---|
62 | |
---|
63 | You still can run the font server and configure your X server |
---|
64 | to get the fonts from it. |
---|
65 | <p> |
---|
66 | |
---|
67 | Further let's suppose that the name on which you are going |
---|
68 | to run the font server is named `somehost'. Login to it |
---|
69 | and configure the font server. |
---|
70 | <p> |
---|
71 | |
---|
72 | First, choose some unused port. Numbers around 9000 are a good |
---|
73 | choice. Verify that this port is not used by somebody else |
---|
74 | by entering |
---|
75 | <p> |
---|
76 | |
---|
77 | <blockquote><tt> |
---|
78 | netstat -naf inet |grep 9000 |
---|
79 | </tt></blockquote> |
---|
80 | |
---|
81 | and look what happens. If you get nothing, that's good, this |
---|
82 | port is unused. If you get some lines of data, try abother port. |
---|
83 | <p> |
---|
84 | |
---|
85 | Go to you home directory <tt>$HOME</tt> and create some directory for |
---|
86 | your font server, say, <tt>$HOME/fs</tt>. Copy the directory structure |
---|
87 | of <tt>/usr/lib/X11/fonts/type1.st</tt> into <tt>$HOME/fs</tt>, so that in result |
---|
88 | you get <tt>$HOME/fs/type1.st/<i><whatever was there></i></tt>. Copy the directory |
---|
89 | structure of <tt>/usr/lib/X11/fonts/stadmin/type1/charsets</tt> into <tt>$HOME/fs</tt>, |
---|
90 | so that in result you get <tt>$HOME/fs/charsets/<i><whatever was there></i></tt>. |
---|
91 | Install the new fonts in these directorues as described above. |
---|
92 | <p> |
---|
93 | |
---|
94 | Then create the fontserver configuration file, say, <tt>$HOME/fs/xfs.cfg</tt>. |
---|
95 | The sample contents (supposing that my <tt>$HOME</tt> is equal to <tt>/home/babkin</tt>) |
---|
96 | is: |
---|
97 | <p> |
---|
98 | |
---|
99 | <! |
---|
100 | --------------8<----------- cut here ----------------------------- |
---|
101 | > |
---|
102 | <hr> |
---|
103 | <tt> |
---|
104 | # font server configuration file |
---|
105 | <br> |
---|
106 | # $XConsortium: config.cpp,v 1.7 91/08/22 11:39:59 rws Exp $ |
---|
107 | <br> |
---|
108 | |
---|
109 | <br> |
---|
110 | rasterizers = /usr/lib/X11/fs/ufstrast.sl,/usr/lib/X11/fs/iforast.sl |
---|
111 | <br> |
---|
112 | |
---|
113 | <br> |
---|
114 | clone-self = off |
---|
115 | <br> |
---|
116 | use-syslog = off |
---|
117 | <br> |
---|
118 | catalogue = /home/babkin/fs/type1.st |
---|
119 | <br> |
---|
120 | # in decipoints |
---|
121 | <br> |
---|
122 | default-point-size = 120 |
---|
123 | <br> |
---|
124 | default-resolutions = 100,100,75,75 |
---|
125 | <br> |
---|
126 | port=9000 |
---|
127 | <br> |
---|
128 | error-file=/home/babkin/fs/fs.err |
---|
129 | </tt> |
---|
130 | <hr> |
---|
131 | <! |
---|
132 | --------------8<----------- cut here ----------------------------- |
---|
133 | > |
---|
134 | <p> |
---|
135 | |
---|
136 | Then create the script to start your font server, say, <tt>$HOME/fs/runme</tt>: |
---|
137 | <p> |
---|
138 | |
---|
139 | <! |
---|
140 | --------------8<----------- cut here ----------------------------- |
---|
141 | > |
---|
142 | <hr> |
---|
143 | <tt> |
---|
144 | TYPE1_CODEPAGE_DIR=$HOME/fs/charsets |
---|
145 | <br> |
---|
146 | export TYPE1_CODEPAGE_DIR |
---|
147 | <br> |
---|
148 | kill `ps -ef | grep $HOME/\[f\]s/xfs.cfg | awk '{print $2}'`; |
---|
149 | <br> |
---|
150 | nohup xfs -config $HOME/fs/xfs.cfg & |
---|
151 | </tt> |
---|
152 | <hr> |
---|
153 | <! |
---|
154 | --------------8<----------- cut here ----------------------------- |
---|
155 | > |
---|
156 | <p> |
---|
157 | |
---|
158 | Don't forget to make <tt>$HOME/fs/runme</tt> executable. Then you can |
---|
159 | execute it manually or from you .profile. |
---|
160 | <p> |
---|
161 | |
---|
162 | After you get your font server running, just execute the following |
---|
163 | command (with proper host name and port number) in your X session |
---|
164 | <p> |
---|
165 | |
---|
166 | <blockquote><tt> |
---|
167 | xset fp+ tcp/somehost:9000 |
---|
168 | </tt></blockquote> |
---|
169 | |
---|
170 | to get the access to your private font server. You can add this |
---|
171 | information to the configuration data of your X server or just |
---|
172 | put it also into your .profile. In the latter case the best way |
---|
173 | to do that would be like: |
---|
174 | <p> |
---|
175 | |
---|
176 | <! |
---|
177 | --------------8<----------- cut here ----------------------------- |
---|
178 | > |
---|
179 | <hr> |
---|
180 | <tt> |
---|
181 | ... |
---|
182 | <br> |
---|
183 | $HOME/fs/runme |
---|
184 | <br> |
---|
185 | sleep 2 # give it some time to start |
---|
186 | <br> |
---|
187 | xset fp+ tcp/somehost:9000 |
---|
188 | <br> |
---|
189 | ... |
---|
190 | </tt> |
---|
191 | <hr> |
---|
192 | <! |
---|
193 | --------------8<----------- cut here ----------------------------- |
---|
194 | > |
---|
195 | <p> |
---|
196 | </BODY> |
---|
197 | </HTML> |
---|