misc/libfreetype/src/pcf/README
author nemo
Mon, 28 May 2012 14:20:51 -0400
changeset 7144 6e3974128631
parent 5172 88f2e05288ba
permissions -rw-r--r--
Remove a couple more timers, should mean alpha matches old pulse time now
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
5172
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
     1
                  FreeType font driver for PCF fonts
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
     2
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
     3
                       Francesco Zappa Nardelli
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
     4
                  <francesco.zappa.nardelli@ens.fr>
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
     5
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
     6
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
     7
Introduction
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
     8
************
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
     9
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    10
PCF (Portable Compiled Format) is a binary bitmap font format, largely used
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    11
in X world. This code implements a PCF driver for the FreeType library.
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    12
Glyph images are loaded into memory only on demand, thus leading to a small
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    13
memory footprint.
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    14
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    15
Information on the PCF font format can only be worked out from
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    16
`pcfread.c', and `pcfwrite.c', to be found, for instance, in the XFree86
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    17
(www.xfree86.org) source tree (xc/lib/font/bitmap/).
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    18
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    19
Many good bitmap fonts in bdf format come with XFree86: they can be
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    20
compiled into the pcf format using the `bdftopcf' utility.
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    21
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    22
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    23
Supported hardware
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    24
******************
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    25
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    26
The driver has been tested on linux/x86 and sunos5.5/sparc.  In both
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    27
cases the compiler was gcc.  When back in Paris, I will test it also
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    28
on linux/alpha.
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    29
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    30
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    31
Encodings
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    32
*********
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    33
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    34
Use `FT_Get_BDF_Charset_ID' to access the encoding and registry.
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    35
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    36
The driver always exports `ft_encoding_none' as face->charmap.encoding. 
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    37
FT_Get_Char_Index() behavior is unmodified, that is, it converts the ULong
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    38
value given as argument into the corresponding glyph number.
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    39
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    40
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    41
Known problems
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    42
**************
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    43
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    44
- dealing explicitly with encodings breaks the uniformity of freetype2
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    45
  api.
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    46
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    47
- except for encodings properties, client applications have no
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    48
  visibility of the PCF_Face object.  This means that applications
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    49
  cannot directly access font tables and are obliged to trust
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    50
  FreeType.
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    51
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    52
- currently, glyph names and ink_metrics are ignored.
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    53
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    54
I plan to give full visibility of the PCF_Face object in the next
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    55
release of the driver, thus implementing also glyph names and
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    56
ink_metrics.
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    57
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    58
- height is defined as (ascent - descent).  Is this correct?
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    59
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    60
- if unable to read size information from the font, PCF_Init_Face
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    61
  sets available_size->width and available_size->height to 12.
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    62
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    63
- too many english grammar errors in the readme file :-(
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    64
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    65
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    66
License
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    67
*******
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    68
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    69
Copyright (C) 2000 by Francesco Zappa Nardelli
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    70
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    71
Permission is hereby granted, free of charge, to any person obtaining
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    72
a copy of this software and associated documentation files (the
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    73
"Software"), to deal in the Software without restriction, including
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    74
without limitation the rights to use, copy, modify, merge, publish,
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    75
distribute, sublicense, and/or sell copies of the Software, and to
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    76
permit persons to whom the Software is furnished to do so, subject to
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    77
the following conditions:
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    78
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    79
The above copyright notice and this permission notice shall be
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    80
included in all copies or substantial portions of the Software.
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    81
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    82
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    83
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    84
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    85
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    86
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    87
TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    88
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    89
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    90
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    91
Credits
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    92
*******
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    93
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    94
Keith Packard wrote the pcf driver found in XFree86.  His work is at
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    95
the same time the specification and the sample implementation of the
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    96
PCF format.  Undoubtedly, this driver is inspired from his work.