updated polyglot protocol
[xboard.git] / winboard / install / files / root / WinBoard / doc / fonts.html
1 <html>\r
2 <header>\r
3 <title>WGP: Piece Fonts</title>\r
4 </header>\r
5 <body>\r
6 <table cellpadding="20"><tr><td>\r
7 <h1>The WinBoard Gold Pack 4.4.0</h1>\r
8 <h2>For the ultimate WinBoard experience!</h2>\r
9 </td><td>\r
10 <img src="mini.gif">\r
11 </td></tr></table>\r
12 <p>\r
13 Chess fonts are fonts where each letter is a small picture, like hieroglyphs.\r
14 The pictures represent Chess pieces, e.g. the A can look like a King, the B like a Queen.\r
15 Often there are separate characters for white and black pieces,\r
16 and often also for pieces on white and black squares.\r
17 In WinBoard 4.4, it is posible to use such fonts for displaying the pieces.\r
18 You would only need the pieces on light squares for this,\r
19 as WinBoard will draw the background by itself.\r
20 </p>\r
21 <h3>Step 1: Installing the Font on your Computer</h3>\r
22 <p>\r
23 The first step is to download the font.\r
24 The "Chess Mark" font that is provided as an example in already included in this package,\r
25 and the installer puts it in the Windows fonts folder for you,\r
26 so it becomes automatically available in all your Windows applications.\r
27 Other fonts can be obtained from the internet.\r
28 A link to the website from which ChessMark was originally obtained,\r
29 is given below.\r
30 It contains many freeware fonts.\r
31 You can pre-view the various fonts there as well.\r
32 </p><p>\r
33 To install new fonts, you can use the following procedure:\r
34 After clicking the download link you can ask to open the file,\r
35 Windows will then automatically show you its contents.\r
36 (Often this does not work, though.\r
37 In that case you will have to click 'Save' in stead of 'Open',\r
38 and save the downloaded .zip file somewhere.\r
39 After that you get the option to click 'Open' again,\r
40 and then it usually works.)\r
41 The opened zip file will in general contain 4 files,\r
42 two READ_ME files (one in Danish), a Word document, and the font file (.tff) itself.\r
43 </p><p>\r
44 Click "extract all files" on the upper left.\r
45 This makes the unpack wizzard pop up, which will guide you trough the unpacking process.\r
46 You can unpack the fonts download in any convenient place;\r
47 you will have to move some selected parts of it to another place anyway.\r
48 </p><p>\r
49 After unpacking,\r
50 the .tff file must be moved to the /WINDOWS/FONTS folder to become installed.\r
51 Sometimes it becomes only active after restarting your computer.\r
52 If the font is correctly installed, you will see some Chess-piece symbols\r
53 when you click the .tff file in your system's Fonts folder.\r
54 If the page you see when clicking this file is mostly blank,\r
55 you probably have to restart your computer.\r
56 </p>\r
57 <h3>Step 2: Tell WinBoard to use the Font</h3>\r
58 <p>\r
59 To use a font for rendering pieces, you have to tel WinBoard two things:\r
60 <br>\r
61 * Which font to use\r
62 <br>\r
63 * Which character represents which piece\r
64 <br>\r
65 The latter is unfortunately not standardized; every fonts does it differently.\r
66 For the first thing there is a command-line option /renderPiecesWithFont="Chess Mark"\r
67 (or whatever font you have downoaded).\r
68 If you want this to become the global default for your "board look",\r
69 you have to append this to the winboard.ini file in the WinBoard folder (i.e. ~\WinBoard\winboard.ini),\r
70 using a text editor (e.g. MS NotePad).\r
71 The option is already there in the winboard.ini supplied with the Gold Pack,\r
72 but it is made inactive by putting a '*' in front of the font name.\r
73 So you could also look for that option in the winboard.ini file, and delete the asterisk.\r
74 </p><p>\r
75 If you don't want to make the font a global default,\r
76 you could make a special shortcut for it,\r
77 that only works if WinBoard is invoked through this shortcut.\r
78 The options we discuss here should then not go into the winboard.ini file,\r
79 but in a separate small .ini file like the supplied example "ChessMark.ini".\r
80 </p><p>\r
81 The mapping of pieces on characters is controlled by the option /fontPieceToCharTable="...",\r
82 where the "..." lists the character needed to obtain PNBRQKpnbrqk, in that order.\r
83 Sometimes the mapping is specified in one of the README files that come with the font.\r
84 But if you don't know which to use,\r
85 you can experiment by making a text in MS Word consisting of the full alphabet,\r
86 and then changing the font for it to the font you just installed.\r
87 (If this package installed correctly, you should already have "ChessMark" in your font menu, there.)\r
88 The winboard.ini supplied with this package already sets the proper values for ChessMark,\r
89 but if you would try another font it would likely start to mix up the pieces unless you change these settings.\r
90 </p>\r
91 <h3>Coloring the Pieces and Fine Tuning</h3>\r
92 <p>\r
93 The inner part of the pieces (everything inside the black outline defined by the font)\r
94 is filled with a color gradient.\r
95 Usually, the black pieces have almost solid font images, so there is little to fill there.\r
96 If you don't want that, you can use the /allWhite=true option\r
97 (also selectable from the "Options -> Board..." menu dialog).\r
98 The actual colors are set by the following four options,\r
99 which define a foreground and background color for both the white and black pieces.\r
100 The actual color gradually changes from foreground on one side to backfground on the other,\r
101 to simulate shading.\r
102 If you don't want this shading, you can make foreground and background colors equal.\r
103 The colors (unfortnately) have to be given as hexadecimal code for RGB intensities...).\r
104 In the winboard.ini supplied with this package they are set to white and black.\r
105 </p><p>\r
106 Pieces rendered with fonts are automaticaly scaled with the board size. \r
107 Not all fonts are equally big though, even if they are all called 12-point (or whatever).\r
108 Therefore the size of the pieces can need some fine-tuning,\r
109 which can be done with the option /fontPieceSize=N, where N is a number.\r
110 The number is aproximately the percentage of the size that would nominally be needed\r
111 to fill an entire board square.\r
112 So usually we have to set it slightly below 100.\r
113 The settings used in the ChessMark.ini example file are:\r
114 </p>\r
115 <pre>\r
116 /renderPiecesWithFont="Chess Mark"\r
117 /fontPieceBackColorWhite=#ffffff\r
118 /fontPieceForeColorWhite=#000000\r
119 /fontPieceBackColorBlack=#ffffff\r
120 /fontPieceForeColorBlack=#000000\r
121 /fontPieceSize=80\r
122 /fontPieceToCharTable="pnbrqkomvtwl"\r
123 </pre>\r
124 <h3>Links</h3>\r
125 <p>\r
126 <a href="http://www.enpassant.dk/chess/fontedk.htm">A Download Page for Chess Fonts</a>\r
127 </p>\r
128 <p>\r
129 <a href="texture.html">Using arbitrary bitmaps for chess board</a>\r
130 </p>\r
131 <p>\r
132 <a href="shortcuts.html">Customizing WinBoard through shortcuts</a>\r
133 </p>\r
134 </body>\r
135 </html>\r