unicode.h

Go to the documentation of this file.
00001 /* $Id: unicode.h 17596 2009-09-20 23:11:01Z smatz $ */
00002 
00003 /*
00004  * This file is part of OpenTTD.
00005  * OpenTTD is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, version 2.
00006  * OpenTTD is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
00007  * See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with OpenTTD. If not, see <http://www.gnu.org/licenses/>.
00008  */
00009 
00012 struct DefaultUnicodeMapping {
00013   WChar code; 
00014   byte key;   
00015 };
00016 
00017 enum {
00018   CLRA = 0, 
00019   CLRL = 1, 
00020 };
00021 
00022 /* Default unicode mapping table for sprite based glyphs.
00023  * This table allows us use unicode characters even though the glyphs don't
00024  * exist, or are in the wrong place, in the standard sprite fonts.
00025  * This is not used for FreeType rendering */
00026 
00027 static const DefaultUnicodeMapping _default_unicode_map[] = {
00028   { 0x00A0, 0x20 }, // Non-breaking space / Up arrow
00029   { 0x00A4, CLRL }, // Currency sign
00030   { 0x00A6, CLRL }, // Broken bar
00031   { 0x00A7, CLRL }, // Section sign
00032   { 0x00A8, CLRL }, // Diaeresis
00033   { 0x00A9, CLRL }, // Copyright sign
00034   { 0x00AA, CLRA }, // Feminine ordinal indicator / Down arrow
00035   { 0x00AC, CLRA }, // Not sign / Tick mark
00036   { 0x00AD, 0x20 }, // Soft hyphen / X mark
00037   { 0x00AF, CLRA }, // Macron / Right arrow
00038   { 0x00B0, CLRL }, // Degree sign
00039   { 0x00B1, CLRL }, // Plus-Minus sign
00040   { 0x00B2, CLRL }, // Superscript 2
00041   { 0x00B3, CLRL }, // Superscript 3
00042   { 0x00B4, CLRA }, // Acute accent / Train symbol
00043   { 0x00B5, CLRA }, // Micro sign / Truck symbol
00044   { 0x00B6, CLRA }, // Pilcrow sign / Bus symbol
00045   { 0x00B7, CLRA }, // Middle dot / Aircraft symbol
00046   { 0x00B8, CLRA }, // Cedilla / Ship symbol
00047   { 0x00B9, CLRA }, // Superscript 1 / Superscript -1
00048   { 0x00BA, CLRL }, // Masculine ordinal indicator
00049   { 0x00BC, CLRA }, // One quarter / Small up arrow
00050   { 0x00BD, CLRA }, // One half / Small down arrow
00051   { 0x00BE, CLRL }, // Three quarters
00052   { 0x00D0, CLRL }, // Capital letter eth
00053   { 0x00D7, CLRL }, // Multiplication sign
00054   { 0x00D8, CLRL }, // Capital letter O with stroke
00055   { 0x00D9, CLRL }, // Capital letter U with grave
00056   { 0x00DE, CLRL }, // Capital letter thorn
00057   { 0x00E6, CLRL }, // Small letter ae
00058   { 0x00F0, CLRL }, // Small letter eth
00059   { 0x00F7, CLRL }, // Divison sign
00060   { 0x00F8, CLRL }, // Small letter o with stroke
00061   { 0x00FE, CLRL }, // Small letter thorn
00062   { 0x0178, 0x9F }, // Capital letter Y with diaeresis
00063   { 0x010D, 0x63 }, // Small letter c with caron
00064 };

Generated on Thu Feb 4 17:20:29 2010 for OpenTTD by  doxygen 1.5.6