ICU 75.1 75.1

udisplaycontext.h
Go to the documentation of this file.
1 // © 2016 and later: Unicode, Inc. and others.
2 // License & terms of use: http://www.unicode.org/copyright.html
3 /*
4 *****************************************************************************************
5 * Copyright (C) 2014-2016, International Business Machines
6 * Corporation and others. All Rights Reserved.
7 *****************************************************************************************
8 */
9
10 #ifndef UDISPLAYCONTEXT_H
11 #define UDISPLAYCONTEXT_H
12
13 #include "unicode/utypes.h"
14
15 #if !UCONFIG_NO_FORMATTING
16
27 enum UDisplayContextType {
33 UDISPCTX_TYPE_DIALECT_HANDLING = 0,
40 UDISPCTX_TYPE_CAPITALIZATION = 1,
46 UDISPCTX_TYPE_DISPLAY_LENGTH = 2,
52 UDISPCTX_TYPE_SUBSTITUTE_HANDLING = 3
53 };
57 typedef enum UDisplayContextType UDisplayContextType;
58
64 enum UDisplayContext {
77 UDISPCTX_STANDARD_NAMES = (UDISPCTX_TYPE_DIALECT_HANDLING<<8) + 0,
84 UDISPCTX_DIALECT_NAMES = (UDISPCTX_TYPE_DIALECT_HANDLING<<8) + 1,
98 UDISPCTX_CAPITALIZATION_NONE = (UDISPCTX_TYPE_CAPITALIZATION<<8) + 0,
104 UDISPCTX_CAPITALIZATION_FOR_MIDDLE_OF_SENTENCE = (UDISPCTX_TYPE_CAPITALIZATION<<8) + 1,
110 UDISPCTX_CAPITALIZATION_FOR_BEGINNING_OF_SENTENCE = (UDISPCTX_TYPE_CAPITALIZATION<<8) + 2,
116 UDISPCTX_CAPITALIZATION_FOR_UI_LIST_OR_MENU = (UDISPCTX_TYPE_CAPITALIZATION<<8) + 3,
123 UDISPCTX_CAPITALIZATION_FOR_STANDALONE = (UDISPCTX_TYPE_CAPITALIZATION<<8) + 4,
136 UDISPCTX_LENGTH_FULL = (UDISPCTX_TYPE_DISPLAY_LENGTH<<8) + 0,
143 UDISPCTX_LENGTH_SHORT = (UDISPCTX_TYPE_DISPLAY_LENGTH<<8) + 1,
156 UDISPCTX_SUBSTITUTE = (UDISPCTX_TYPE_SUBSTITUTE_HANDLING<<8) + 0,
163 UDISPCTX_NO_SUBSTITUTE = (UDISPCTX_TYPE_SUBSTITUTE_HANDLING<<8) + 1
164
165 };
169 typedef enum UDisplayContext UDisplayContext;
170
171 #endif /* #if !UCONFIG_NO_FORMATTING */
172
173 #endif
UDisplayContextType
UDisplayContextType
Display context types, for getting values of a particular setting.
Definition: udisplaycontext.h:27
UDISPCTX_TYPE_SUBSTITUTE_HANDLING
@ UDISPCTX_TYPE_SUBSTITUTE_HANDLING
Type to retrieve the substitute handling setting, e.g.
Definition: udisplaycontext.h:52
UDISPCTX_TYPE_DISPLAY_LENGTH
@ UDISPCTX_TYPE_DISPLAY_LENGTH
Type to retrieve the display length setting, e.g.
Definition: udisplaycontext.h:46
UDISPCTX_TYPE_CAPITALIZATION
@ UDISPCTX_TYPE_CAPITALIZATION
Type to retrieve the capitalization context setting, e.g.
Definition: udisplaycontext.h:40
UDISPCTX_TYPE_DIALECT_HANDLING
@ UDISPCTX_TYPE_DIALECT_HANDLING
Type to retrieve the dialect handling setting, e.g.
Definition: udisplaycontext.h:33
UDisplayContext
UDisplayContext
Display context settings.
Definition: udisplaycontext.h:64
UDISPCTX_NO_SUBSTITUTE
@ UDISPCTX_NO_SUBSTITUTE
A possible setting for SUBSTITUTE_HANDLING: Returns a null value with error code set to U_ILLEGAL_ARG...
Definition: udisplaycontext.h:163
UDISPCTX_LENGTH_SHORT
@ UDISPCTX_LENGTH_SHORT
A possible setting for DISPLAY_LENGTH: use short names when generating a locale name,...
Definition: udisplaycontext.h:143
UDISPCTX_CAPITALIZATION_FOR_UI_LIST_OR_MENU
@ UDISPCTX_CAPITALIZATION_FOR_UI_LIST_OR_MENU
The capitalization context if a date, date symbol or display name is to be formatted with capitalizat...
Definition: udisplaycontext.h:116
UDISPCTX_CAPITALIZATION_NONE
@ UDISPCTX_CAPITALIZATION_NONE
The capitalization context to be used is unknown (this is the default value).
Definition: udisplaycontext.h:98
UDISPCTX_STANDARD_NAMES
@ UDISPCTX_STANDARD_NAMES
A possible setting for DIALECT_HANDLING: use standard names when generating a locale name,...
Definition: udisplaycontext.h:77
UDISPCTX_LENGTH_FULL
@ UDISPCTX_LENGTH_FULL
A possible setting for DISPLAY_LENGTH: use full names when generating a locale name,...
Definition: udisplaycontext.h:136
UDISPCTX_DIALECT_NAMES
@ UDISPCTX_DIALECT_NAMES
A possible setting for DIALECT_HANDLING: use dialect names, when generating a locale name,...
Definition: udisplaycontext.h:84
UDISPCTX_SUBSTITUTE
@ UDISPCTX_SUBSTITUTE
A possible setting for SUBSTITUTE_HANDLING: Returns a fallback value (e.g., the input code) when no d...
Definition: udisplaycontext.h:156
UDISPCTX_CAPITALIZATION_FOR_BEGINNING_OF_SENTENCE
@ UDISPCTX_CAPITALIZATION_FOR_BEGINNING_OF_SENTENCE
The capitalization context if a date, date symbol or display name is to be formatted with capitalizat...
Definition: udisplaycontext.h:110
UDISPCTX_CAPITALIZATION_FOR_STANDALONE
@ UDISPCTX_CAPITALIZATION_FOR_STANDALONE
The capitalization context if a date, date symbol or display name is to be formatted with capitalizat...
Definition: udisplaycontext.h:123
UDISPCTX_CAPITALIZATION_FOR_MIDDLE_OF_SENTENCE
@ UDISPCTX_CAPITALIZATION_FOR_MIDDLE_OF_SENTENCE
The capitalization context if a date, date symbol or display name is to be formatted with capitalizat...
Definition: udisplaycontext.h:104
utypes.h
Basic definitions for ICU, for both C and C++ APIs.