Wireshark 2.9.0-477-g68ec514b The Wireshark network protocol analyzer

- Main Page
- Related Pages
- Modules
- Namespaces
- Classes
- Files

- File List
- File Members

utf8_entities.h
1 /* utf8_entities.h
2 * Byte sequences for various UTF-8 entities
3 *
4 * Wireshark - Network traffic analyzer
5 * By Gerald Combs <gerald@wireshark.org>
6 * Copyright 1998 Gerald Combs
7 *
8 * SPDX-License-Identifier: GPL-2.0-or-later
9 */
10
11
12 #ifndef __UTF8_ENTITIES_H__
13 #define __UTF8_ENTITIES_H__
14
15 /*
16 * Sequences can be found at
17 * http://www.fileformat.info/info/unicode/
18 * http://www.utf8-chartable.de/
19 * and other places
20 *
21 * Please be conservative when adding code points below. While many modern
22 * systems default to UTF-8 and handle it well, some do not. The Windows
23 * console is a notable example. As a general rule you probably shouldn't
24 * stray too far from code page 437 or WGL4:
25 * https://en.wikipedia.org/wiki/Code_page_437
26 * https://en.wikipedia.org/wiki/Windows_Glyph_List_4
27 *
28 * Hopefully we can dispense with the sequences below and simply encode our
29 * files as UTF 8 at some point. For example gcc has supported UTF 8 since
30 * at least 3.4. Visual C++ on the other hand is much more problematic.
31 * 2015 and later support /source-charset:utf-8, but prior versions appear
32 * to require a UTF 8 BOM.
33 */
34
35 #define UTF8_DEGREE_SIGN "\xc2\xb0" /* 176 / 0xb0 */
36 #define UTF8_SUPERSCRIPT_TWO "\xc2\xb2" /* 178 / 0xb2 */
37 #define UTF8_MICRO_SIGN "\xc2\xb5" /* 181 / 0xb5 */
38 #define UTF8_MIDDLE_DOT "\xc2\xb7" /* 183 / 0xb7 */
39 #define UTF8_RIGHT_POINTING_DOUBLE_ANGLE_QUOTATION_MARK "\xc2\xbb" /* 187 / 0xbb */
40
41 #define UTF8_BULLET "\xe2\x80\xa2" /* 8226 / 0x2024 */
42 #define UTF8_EM_DASH "\xe2\x80\x94" /* 8212 / 0x2014 */
43 #define UTF8_HORIZONTAL_ELLIPSIS "\xe2\x80\xa6" /* 8230 / 0x2026 */
44
45 #define UTF8_LEFTWARDS_ARROW "\xe2\x86\x90" /* 8592 / 0x2190 */
46 #define UTF8_RIGHTWARDS_ARROW "\xe2\x86\x92" /* 8594 / 0x2192 */
47 #define UTF8_LEFT_RIGHT_ARROW "\xe2\x86\x94" /* 8596 / 0x2194 */
48
49 /* macOS command key */
50 #define UTF8_PLACE_OF_INTEREST_SIGN "\xe2\x8c\x98" /* 8984 / 0x2318 */
51
52 #define UTF8_SYMBOL_FOR_NULL "\xe2\x90\x80" /* 9216 / 0x2400 */
53
54 #define UTF8_CHECK_MARK "\xe2\x9c\x93" /* 10003 / 0x2713 */
55 #define UTF8_BALLOT_X "\xe2\x9c\x97" /* 10007 / 0x2717 */
56 #define UTF8_LONG_RIGHTWARDS_ARROW "\xe2\x9f\xb6" /* 10230 / 0x27f6 */
57
58 #define UTF8_ZERO_WIDTH_NO_BREAK_SPACE "\xef\xbb\xbf" /* 65279 / 0xffef */
59 #define UTF8_BOM UTF8_ZERO_WIDTH_NO_BREAK_SPACE
60
61 #endif /* __UTF8_ENTITIES_H__ */
62
63 /*
64 * Editor modelines
65 *
66 * Local Variables:
67 * c-basic-offset: 4
68 * tab-width: 8
69 * indent-tabs-mode: nil
70 * End:
71 *
72 * ex: set shiftwidth=4 tabstop=8 expandtab
73 * :indentSize=4:tabSize=8:noTabs=true:
74 */