xref: /haiku/src/apps/charactermap/UnicodeBlocks.h (revision 1e60bdeab63fa7a57bc9a55b032052e95a18bd2c)
1 /*
2  * Copyright 2009, Axel Dörfler, axeld@pinc-software.de.
3  * Distributed under the terms of the MIT License.
4  */
5 #ifndef UNICODE_BLOCKS_H
6 #define UNICODE_BLOCKS_H
7 
8 
9 #include <UnicodeBlockObjects.h>
10 
11 
12 struct unicode_block_entry {
13 	const char*				name;
14 	uint32					start;
15 	uint32					end;
16 	bool					private_block;
17 	const unicode_block&	block;
18 
19 	uint32 Count() const { return end + 1 - start; }
20 };
21 
22 extern const unicode_block kNoBlock;
23 extern const struct unicode_block_entry kUnicodeBlocks[];
24 extern const uint32 kNumUnicodeBlocks;
25 
26 int32 BlockForCharacter(const uint32 character);
27 
28 #endif	// UNICODE_BLOCKS_H
29