| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef BASE_I18N_RTL_H_ | 5 #ifndef BASE_I18N_RTL_H_ |
| 6 #define BASE_I18N_RTL_H_ | 6 #define BASE_I18N_RTL_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/compiler_specific.h" | 10 #include "base/compiler_specific.h" |
| (...skipping 13 matching lines...) Expand all Loading... |
| 24 const char16 kRightToLeftEmbeddingMark = 0x202B; | 24 const char16 kRightToLeftEmbeddingMark = 0x202B; |
| 25 const char16 kPopDirectionalFormatting = 0x202C; | 25 const char16 kPopDirectionalFormatting = 0x202C; |
| 26 const char16 kLeftToRightOverride = 0x202D; | 26 const char16 kLeftToRightOverride = 0x202D; |
| 27 const char16 kRightToLeftOverride = 0x202E; | 27 const char16 kRightToLeftOverride = 0x202E; |
| 28 | 28 |
| 29 // Locale.java mirrored this enum TextDirection. Please keep in sync. | 29 // Locale.java mirrored this enum TextDirection. Please keep in sync. |
| 30 enum TextDirection { | 30 enum TextDirection { |
| 31 UNKNOWN_DIRECTION = 0, | 31 UNKNOWN_DIRECTION = 0, |
| 32 RIGHT_TO_LEFT = 1, | 32 RIGHT_TO_LEFT = 1, |
| 33 LEFT_TO_RIGHT = 2, | 33 LEFT_TO_RIGHT = 2, |
| 34 TEXT_DIRECTION_NUM_DIRECTIONS = 3, | 34 TEXT_DIRECTION_MAX = LEFT_TO_RIGHT, |
| 35 }; | 35 }; |
| 36 | 36 |
| 37 // Get the locale that the currently running process has been configured to use. | 37 // Get the locale that the currently running process has been configured to use. |
| 38 // The return value is of the form language[-country] (e.g., en-US) where the | 38 // The return value is of the form language[-country] (e.g., en-US) where the |
| 39 // language is the 2 or 3 letter code from ISO-639. | 39 // language is the 2 or 3 letter code from ISO-639. |
| 40 BASE_I18N_EXPORT std::string GetConfiguredLocale(); | 40 BASE_I18N_EXPORT std::string GetConfiguredLocale(); |
| 41 | 41 |
| 42 // Canonicalize a string (eg. a POSIX locale string) to a Chrome locale name. | 42 // Canonicalize a string (eg. a POSIX locale string) to a Chrome locale name. |
| 43 BASE_I18N_EXPORT std::string GetCanonicalLocale(const std::string& locale); | 43 BASE_I18N_EXPORT std::string GetCanonicalLocale(const std::string& locale); |
| 44 | 44 |
| (...skipping 101 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 146 // return the text itself. Explicit bidi control characters display and have | 146 // return the text itself. Explicit bidi control characters display and have |
| 147 // semantic effect. They can be deleted so they might not always appear in a | 147 // semantic effect. They can be deleted so they might not always appear in a |
| 148 // pair. | 148 // pair. |
| 149 BASE_I18N_EXPORT string16 StripWrappingBidiControlCharacters( | 149 BASE_I18N_EXPORT string16 StripWrappingBidiControlCharacters( |
| 150 const string16& text) WARN_UNUSED_RESULT; | 150 const string16& text) WARN_UNUSED_RESULT; |
| 151 | 151 |
| 152 } // namespace i18n | 152 } // namespace i18n |
| 153 } // namespace base | 153 } // namespace base |
| 154 | 154 |
| 155 #endif // BASE_I18N_RTL_H_ | 155 #endif // BASE_I18N_RTL_H_ |
| OLD | NEW |