| 1 | <?xml version="1.0"?> |
| 2 | <!DOCTYPE fontconfig SYSTEM "urn:fontconfig:fonts.dtd"> |
| 3 | <!-- |
| 4 | fonts-persian.conf |
| 5 | To configure Persian fonts from The FarsiWeb Project. |
| 6 | |
| 7 | Copyright (C) 2005 Sharif FarsiWeb, Inc. <[email protected]> |
| 8 | |
| 9 | Permission to use, copy, modify, distribute, and sell this software and its |
| 10 | documentation for any purpose is hereby granted without fee, provided that |
| 11 | the above copyright notice appear in all copies and that both that |
| 12 | copyright notice and this permission notice appear in supporting |
| 13 | documentation, and that the name of Sharif FarsiWeb, Inc. not be used in |
| 14 | advertising or publicity pertaining to distribution of the software without |
| 15 | specific, written prior permission. Sharif FarsiWeb, Inc. makes no |
| 16 | representations about the suitability of this software for any purpose. It |
| 17 | is provided "as is" without express or implied warranty. |
| 18 | |
| 19 | SHARIF FARSIWEB, INC. DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, |
| 20 | INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO |
| 21 | EVENT SHALL THE AUTHOR(S) BE LIABLE FOR ANY SPECIAL, INDIRECT OR |
| 22 | CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, |
| 23 | DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER |
| 24 | TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR |
| 25 | PERFORMANCE OF THIS SOFTWARE. |
| 26 | |
| 27 | ChangeLog: |
| 28 | 2005-04-03 Behdad Esfahbod: Initial revision. |
| 29 | 2005-10-09 Behdad Esfahbod: Turned off back-slant and Tahoma sections. |
| 30 | 2005-11-30 Behdad Esfahbod: Set Titr susbtitution size to 24 points. |
| 31 | 2008 Behdad Esfahbod: Cleanup. Add fantasy and cursive. |
| 32 | --> |
| 33 | <fontconfig> |
| 34 | |
| 35 | <!-- Deprecated fonts are discouraged --> |
| 36 | |
| 37 | <!-- Nesf[2] is officially deprecated and has problematic tables --> |
| 38 | <alias binding="same"> |
| 39 | <family>Nesf</family> |
| 40 | <accept><family>Nesf2</family></accept> |
| 41 | </alias> |
| 42 | <alias binding="same"> |
| 43 | <family>Nesf2</family> |
| 44 | <accept><family>Persian_sansserif_default</family></accept> |
| 45 | </alias> |
| 46 | |
| 47 | <!-- Name changes and spelling variant aliases --> |
| 48 | |
| 49 | <alias binding="same"> |
| 50 | <family>Nazanin</family> |
| 51 | <accept><family>Nazli</family></accept> |
| 52 | </alias> |
| 53 | <alias binding="same"> |
| 54 | <family>Lotus</family> |
| 55 | <accept><family>Lotoos</family></accept> |
| 56 | </alias> |
| 57 | <alias binding="same"> |
| 58 | <family>Yaqut</family> |
| 59 | <accept><family>Yaghoot</family></accept> |
| 60 | </alias> |
| 61 | <alias binding="same"> |
| 62 | <family>Yaghut</family> |
| 63 | <accept><family>Yaghoot</family></accept> |
| 64 | </alias> |
| 65 | <alias binding="same"> |
| 66 | <family>Traffic</family> |
| 67 | <accept><family>Terafik</family></accept> |
| 68 | </alias> |
| 69 | <alias binding="same"> |
| 70 | <family>Ferdowsi</family> |
| 71 | <accept><family>Ferdosi</family></accept> |
| 72 | </alias> |
| 73 | <alias binding="same"> |
| 74 | <family>Fantezy</family> |
| 75 | <accept><family>Fantezi</family></accept> |
| 76 | </alias> |
| 77 | |
| 78 | |
| 79 | <!-- Classify fonts. --> |
| 80 | |
| 81 | <!-- Persian_title class --> |
| 82 | <alias binding="same"> |
| 83 | <family>Jadid</family> |
| 84 | <accept><family>Persian_title</family></accept> |
| 85 | </alias> |
| 86 | <alias binding="same"> |
| 87 | <family>Titr</family> |
| 88 | <accept><family>Persian_title</family></accept> |
| 89 | </alias> |
| 90 | |
| 91 | <!-- Persian_fantasy class --> |
| 92 | <alias binding="same"> |
| 93 | <family>Kamran</family> |
| 94 | <accept> |
| 95 | <family>Persian_fantasy</family> |
| 96 | <family>Homa</family> |
| 97 | </accept> |
| 98 | </alias> |
| 99 | <alias binding="same"> |
| 100 | <family>Homa</family> |
| 101 | <accept> |
| 102 | <family>Persian_fantasy</family> |
| 103 | <family>Kamran</family> |
| 104 | </accept> |
| 105 | </alias> |
| 106 | <alias binding="same"> |
| 107 | <family>Fantezi</family> |
| 108 | <accept><family>Persian_fantasy</family></accept> |
| 109 | </alias> |
| 110 | <alias binding="same"> |
| 111 | <family>Tabassom</family> |
| 112 | <accept><family>Persian_fantasy</family></accept> |
| 113 | </alias> |
| 114 | |
| 115 | <!-- Persian_square class --> |
| 116 | <alias binding="same"> |
| 117 | <family>Arshia</family> |
| 118 | <accept><family>Persian_square</family></accept> |
| 119 | </alias> |
| 120 | <alias binding="same"> |
| 121 | <family>Nasim</family> |
| 122 | <accept><family>Persian_square</family></accept> |
| 123 | </alias> |
| 124 | <alias binding="same"> |
| 125 | <family>Elham</family> |
| 126 | <accept> |
| 127 | <family>Persian_square</family> |
| 128 | <family>Farnaz</family> |
| 129 | </accept> |
| 130 | </alias> |
| 131 | <alias binding="same"> |
| 132 | <family>Farnaz</family> |
| 133 | <accept> |
| 134 | <family>Persian_square</family> |
| 135 | <family>Elham</family> |
| 136 | </accept> |
| 137 | </alias> |
| 138 | <alias binding="same"> |
| 139 | <family>Sina</family> |
| 140 | <accept><family>Persian_square</family></accept> |
| 141 | </alias> |
| 142 | |
| 143 | <!-- Font ordering per class --> |
| 144 | |
| 145 | <!-- Persian_title class --> |
| 146 | <alias binding="same"> |
| 147 | <family>Persian_title</family> |
| 148 | <accept> |
| 149 | <family>Titr</family> |
| 150 | <family>Jadid</family> |
| 151 | <family>Persian_serif</family> |
| 152 | </accept> |
| 153 | </alias> |
| 154 | |
| 155 | <!-- Persian_fantasy class --> |
| 156 | <alias binding="same"> |
| 157 | <family>Persian_fantasy</family> |
| 158 | <accept> |
| 159 | <family>Homa</family> |
| 160 | <family>Kamran</family> |
| 161 | <family>Fantezi</family> |
| 162 | <family>Tabassom</family> |
| 163 | <family>Persian_square</family> |
| 164 | </accept> |
| 165 | </alias> |
| 166 | |
| 167 | <!-- Persian_square class --> |
| 168 | <alias binding="same"> |
| 169 | <family>Persian_square</family> |
| 170 | <accept> |
| 171 | <family>Arshia</family> |
| 172 | <family>Elham</family> |
| 173 | <family>Farnaz</family> |
| 174 | <family>Nasim</family> |
| 175 | <family>Sina</family> |
| 176 | <family>Persian_serif</family> |
| 177 | </accept> |
| 178 | </alias> |
| 179 | |
| 180 | <!-- Register the fonts that we actually do have --> |
| 181 | |
| 182 | <match target="scan"> |
| 183 | <test name="family" compare="eq" ignore-blanks="true"> |
| 184 | <string>Elham</string> |
| 185 | </test> |
| 186 | <edit name="foundry"> |
| 187 | <string>farsiweb</string> |
| 188 | </edit> |
| 189 | </match> |
| 190 | |
| 191 | <match target="scan"> |
| 192 | <test name="family" compare="eq" ignore-blanks="true"> |
| 193 | <string>Homa</string> |
| 194 | </test> |
| 195 | <edit name="foundry"> |
| 196 | <string>farsiweb</string> |
| 197 | </edit> |
| 198 | </match> |
| 199 | |
| 200 | <match target="scan"> |
| 201 | <test name="family" compare="eq" ignore-blanks="true"> |
| 202 | <string>Koodak</string> |
| 203 | </test> |
| 204 | <edit name="foundry"> |
| 205 | <string>farsiweb</string> |
| 206 | </edit> |
| 207 | </match> |
| 208 | |
| 209 | <match target="scan"> |
| 210 | <test name="family" compare="eq" ignore-blanks="true"> |
| 211 | <string>Nazli</string> |
| 212 | </test> |
| 213 | <edit name="foundry"> |
| 214 | <string>farsiweb</string> |
| 215 | </edit> |
| 216 | </match> |
| 217 | |
| 218 | <match target="scan"> |
| 219 | <test name="family" compare="eq" ignore-blanks="true"> |
| 220 | <string>Roya</string> |
| 221 | </test> |
| 222 | <edit name="foundry"> |
| 223 | <string>farsiweb</string> |
| 224 | </edit> |
| 225 | </match> |
| 226 | |
| 227 | <match target="scan"> |
| 228 | <test name="family" compare="eq" ignore-blanks="true"> |
| 229 | <string>Terafik</string> |
| 230 | </test> |
| 231 | <edit name="foundry"> |
| 232 | <string>farsiweb</string> |
| 233 | </edit> |
| 234 | </match> |
| 235 | |
| 236 | <match target="scan"> |
| 237 | <test name="family" compare="eq" ignore-blanks="true"> |
| 238 | <string>Titr</string> |
| 239 | </test> |
| 240 | <edit name="foundry"> |
| 241 | <string>farsiweb</string> |
| 242 | </edit> |
| 243 | </match> |
| 244 | |
| 245 | |
| 246 | <!-- Our fonts should oblique to the other side (TURNED-OFF) --> |
| 247 | |
| 248 | <match target="font"> |
| 249 | <test name="foundry"> |
| 250 | <!--string>farsiweb</string--> |
| 251 | <string>TURNED-OFF</string> |
| 252 | </test> |
| 253 | <test name="foundry"> |
| 254 | <string>farsiweb</string> |
| 255 | </test> |
| 256 | <!-- check to see if the font is roman --> |
| 257 | <test name="slant"> |
| 258 | <const>roman</const> |
| 259 | </test> |
| 260 | <!-- check to see if the pattern requested non-roman --> |
| 261 | <test target="pattern" name="slant" compare="not_eq"> |
| 262 | <const>roman</const> |
| 263 | </test> |
| 264 | <!-- multiply the matrix to slant the font --> |
| 265 | <edit name="matrix" mode="assign"> |
| 266 | <times> |
| 267 | <name>matrix</name> |
| 268 | <matrix><double>1</double><double>-0.2</double> |
| 269 | <double>0</double><double>1</double> |
| 270 | </matrix> |
| 271 | </times> |
| 272 | </edit> |
| 273 | <!-- pretend the font is oblique now --> |
| 274 | <edit name="slant" mode="assign"> |
| 275 | <const>oblique</const> |
| 276 | </edit> |
| 277 | </match> |
| 278 | |
| 279 | |
| 280 | <!-- |
| 281 | We can't hint our fonts well, so turn off hinting. |
| 282 | Moreover, the bitmaps we have designed (well, they |
| 283 | have designed), suck, so disable them too. |
| 284 | --> |
| 285 | |
| 286 | <match target="font"> |
| 287 | <test name="foundry"> |
| 288 | <string>farsiweb</string> |
| 289 | </test> |
| 290 | <edit name="autohint"> |
| 291 | <bool>false</bool> |
| 292 | </edit> |
| 293 | <edit name="hinting"> |
| 294 | <bool>false</bool> |
| 295 | </edit> |
| 296 | <edit name="embeddedbitmap"> |
| 297 | <bool>false</bool> |
| 298 | </edit> |
| 299 | </match> |
| 300 | |
| 301 | |
| 302 | <!-- Alias our fonts to common families --> |
| 303 | |
| 304 | <!-- Persian serif fonts --> |
| 305 | <alias> |
| 306 | <family>serif</family> |
| 307 | <accept> |
| 308 | <family>Nazli</family> |
| 309 | <family>Lotoos</family> |
| 310 | <family>Mitra</family> |
| 311 | <family>Ferdosi</family> |
| 312 | <family>Badr</family> |
| 313 | <family>Zar</family> |
| 314 | </accept> |
| 315 | </alias> |
| 316 | |
| 317 | <!-- Persian sans-serif fonts --> |
| 318 | <alias> |
| 319 | <family>sans-serif</family> |
| 320 | <accept> |
| 321 | <family>Roya</family> |
| 322 | <family>Koodak</family> |
| 323 | <family>Terafik</family> |
| 324 | </accept> |
| 325 | </alias> |
| 326 | |
| 327 | <!-- Persian monospace fonts --> |
| 328 | <alias> |
| 329 | <family>monospace</family> |
| 330 | <accept> |
| 331 | <!-- Not really monospace --> |
| 332 | <family>Terafik</family> |
| 333 | </accept> |
| 334 | </alias> |
| 335 | |
| 336 | <!-- Persian fantasy fonts --> |
| 337 | <alias> |
| 338 | <family>fantasy</family> |
| 339 | <accept> |
| 340 | <family>Homa</family> |
| 341 | <family>Kamran</family> |
| 342 | <family>Fantezi</family> |
| 343 | <family>Tabassom</family> |
| 344 | </accept> |
| 345 | </alias> |
| 346 | |
| 347 | <!-- Persian (and Urdu) Nastaliq/cursive fonts --> |
| 348 | <alias> |
| 349 | <family>cursive</family> |
| 350 | <accept> |
| 351 | <family>IranNastaliq</family> |
| 352 | <family>Nafees Nastaleeq</family> |
| 353 | </accept> |
| 354 | </alias> |
| 355 | |
| 356 | <!-- Use Titr in titles --> |
| 357 | |
| 358 | <!-- Both serif... --> |
| 359 | <match> |
| 360 | <test name="family"> |
| 361 | <string>serif</string> |
| 362 | </test> |
| 363 | <test name="weight" compare="more_eq"> |
| 364 | <int>200</int> |
| 365 | </test> |
| 366 | <test name="size" compare="more_eq"> |
| 367 | <double>24</double> |
| 368 | </test> |
| 369 | <edit name="family" mode="prepend"> |
| 370 | <string>Titr</string> |
| 371 | </edit> |
| 372 | </match> |
| 373 | |
| 374 | <!-- and sans-serif. --> |
| 375 | <match> |
| 376 | <test name="family"> |
| 377 | <string>sans-serif</string> |
| 378 | </test> |
| 379 | <test name="weight" compare="more_eq"> |
| 380 | <int>200</int> |
| 381 | </test> |
| 382 | <test name="size" compare="more_eq"> |
| 383 | <double>24</double> |
| 384 | </test> |
| 385 | <edit name="family" mode="prepend"> |
| 386 | <string>Titr</string> |
| 387 | </edit> |
| 388 | </match> |
| 389 | |
| 390 | <!-- and more. --> |
| 391 | <match> |
| 392 | <test name="family"> |
| 393 | <string>Persian_sansserif_default</string> |
| 394 | </test> |
| 395 | <test name="weight" compare="more_eq"> |
| 396 | <int>200</int> |
| 397 | </test> |
| 398 | <test name="size" compare="more_eq"> |
| 399 | <double>24</double> |
| 400 | </test> |
| 401 | <edit name="family" mode="prepend" binding="same"> |
| 402 | <string>Titr</string> |
| 403 | </edit> |
| 404 | </match> |
| 405 | |
| 406 | |
| 407 | <!-- Default substituted for deprecated sans-serif fonts --> |
| 408 | |
| 409 | <match> |
| 410 | <test name="family"> |
| 411 | <string>Persian_sansserif_default</string> |
| 412 | </test> |
| 413 | <edit name="family" mode="assign" binding="same"> |
| 414 | <string>Roya</string> |
| 415 | </edit> |
| 416 | </match> |
| 417 | |
| 418 | </fontconfig> |