summaryrefslogtreecommitdiffstats
path: root/include/i18nutil
diff options
context:
space:
mode:
authorPhilipp Hofer <philipp.hofer@protonmail.com>2020-11-12 13:03:16 +0100
committerChristian Lohmaier <lohmaier+LibreOffice@googlemail.com>2020-11-21 13:19:17 +0100
commit01baeab99890e5650b3dabc15f8d900490a5a133 (patch)
tree64a1b30b20a53262605312fff4d035876fc7c811 /include/i18nutil
parenttdf#123936 Formatting files in module starmath with clang-format (diff)
downloadcore-01baeab99890e5650b3dabc15f8d900490a5a133.tar.gz
core-01baeab99890e5650b3dabc15f8d900490a5a133.zip
tdf#123936 Formatting files in module include with clang-format
Change-Id: I0507dd797cd5a35e0ae14f4b69ee4e172d08a71a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/105681 Reviewed-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com> Tested-by: Jenkins
Diffstat (limited to 'include/i18nutil')
-rw-r--r--include/i18nutil/i18nutildllapi.h4
-rw-r--r--include/i18nutil/paper.hxx18
-rw-r--r--include/i18nutil/unicode.hxx33
3 files changed, 28 insertions, 27 deletions
diff --git a/include/i18nutil/i18nutildllapi.h b/include/i18nutil/i18nutildllapi.h
index 7cd2d5e36563..9797e87a3613 100644
--- a/include/i18nutil/i18nutildllapi.h
+++ b/include/i18nutil/i18nutildllapi.h
@@ -23,9 +23,9 @@
#include <sal/types.h>
#if defined(I18NUTIL_DLLIMPLEMENTATION)
-#define I18NUTIL_DLLPUBLIC SAL_DLLPUBLIC_EXPORT
+#define I18NUTIL_DLLPUBLIC SAL_DLLPUBLIC_EXPORT
#else
-#define I18NUTIL_DLLPUBLIC SAL_DLLPUBLIC_IMPORT
+#define I18NUTIL_DLLPUBLIC SAL_DLLPUBLIC_IMPORT
#endif
#define I18NUTIL_DLLPRIVATE SAL_DLLPRIVATE
diff --git a/include/i18nutil/paper.hxx b/include/i18nutil/paper.hxx
index 5c64d646d7f7..1fc09f1f1267 100644
--- a/include/i18nutil/paper.hxx
+++ b/include/i18nutil/paper.hxx
@@ -24,7 +24,10 @@
#include <rtl/string.hxx>
#include <tools/long.hxx>
-namespace com::sun::star::lang { struct Locale; }
+namespace com::sun::star::lang
+{
+struct Locale;
+}
//!! The values of the following enumerators must correspond to the array position
//!! of the respective paper size in the file i18nutil/source/utility/paper.cxx
@@ -116,14 +119,13 @@ enum Paper : unsigned
};
// defined for 'equal size' test with the implementation array
-#define NUM_PAPER_ENTRIES (PAPER_16K_197x273 - PAPER_A0 + 1)
-
+#define NUM_PAPER_ENTRIES (PAPER_16K_197x273 - PAPER_A0 + 1)
class I18NUTIL_DLLPUBLIC PaperInfo
{
Paper m_eType;
- tools::Long m_nPaperWidth; // width in 100thMM
- tools::Long m_nPaperHeight; // height in 100thMM
+ tools::Long m_nPaperWidth; // width in 100thMM
+ tools::Long m_nPaperHeight; // height in 100thMM
public:
PaperInfo(Paper eType);
PaperInfo(tools::Long nPaperWidth, tools::Long nPaperHeight);
@@ -131,13 +133,13 @@ public:
Paper getPaper() const { return m_eType; }
tools::Long getWidth() const { return m_nPaperWidth; }
tools::Long getHeight() const { return m_nPaperHeight; }
- bool sloppyEqual(const PaperInfo &rOther) const;
+ bool sloppyEqual(const PaperInfo& rOther) const;
void doSloppyFit();
static PaperInfo getSystemDefaultPaper();
- static PaperInfo getDefaultPaperForLocale(const css::lang::Locale & rLocale);
+ static PaperInfo getDefaultPaperForLocale(const css::lang::Locale& rLocale);
- static Paper fromPSName(const OString &rName);
+ static Paper fromPSName(const OString& rName);
static OString toPSName(Paper eType);
static tools::Long sloppyFitPageDimension(tools::Long nDimension);
diff --git a/include/i18nutil/unicode.hxx b/include/i18nutil/unicode.hxx
index f0db87095f71..0ca14290981e 100644
--- a/include/i18nutil/unicode.hxx
+++ b/include/i18nutil/unicode.hxx
@@ -27,7 +27,8 @@
class LanguageTag;
-struct ScriptTypeList {
+struct ScriptTypeList
+{
css::i18n::UnicodeScript from;
css::i18n::UnicodeScript to;
sal_Int16 value;
@@ -36,16 +37,16 @@ struct ScriptTypeList {
class I18NUTIL_DLLPUBLIC unicode
{
public:
-
- static sal_Int16 getUnicodeType( const sal_Unicode ch );
- static sal_Int16 getUnicodeScriptType( const sal_Unicode ch, const ScriptTypeList *typeList, sal_Int16 unknownType = 0 );
+ static sal_Int16 getUnicodeType(const sal_Unicode ch);
+ static sal_Int16 getUnicodeScriptType(const sal_Unicode ch, const ScriptTypeList* typeList,
+ sal_Int16 unknownType = 0);
static sal_Unicode getUnicodeScriptStart(css::i18n::UnicodeScript type);
static sal_Unicode getUnicodeScriptEnd(css::i18n::UnicodeScript type);
- static sal_uInt8 getUnicodeDirection( const sal_Unicode ch );
- static bool isControl( const sal_Unicode ch);
- static bool isAlpha( const sal_Unicode ch);
- static bool isSpace( const sal_Unicode ch);
- static bool isWhiteSpace( const sal_Unicode ch);
+ static sal_uInt8 getUnicodeDirection(const sal_Unicode ch);
+ static bool isControl(const sal_Unicode ch);
+ static bool isAlpha(const sal_Unicode ch);
+ static bool isSpace(const sal_Unicode ch);
+ static bool isWhiteSpace(const sal_Unicode ch);
/** Check for Unicode variation sequence selectors
@@ -55,8 +56,8 @@ public:
*/
static bool isIVSSelector(sal_uInt32 nCode)
{
- return (nCode >= 0xFE00 && nCode <= 0xFE0F) // Variation Selectors block
- || (nCode >= 0xE0100 && nCode <= 0xE01EF);// Variation Selectors Supplement block
+ return (nCode >= 0xFE00 && nCode <= 0xFE0F) // Variation Selectors block
+ || (nCode >= 0xE0100 && nCode <= 0xE01EF); // Variation Selectors Supplement block
}
/** Check for base characters of a CJK ideographic variation sequence (IVS)
@@ -67,9 +68,9 @@ public:
*/
static bool isCJKIVSCharacter(sal_uInt32 nCode)
{
- return (nCode >= 0x4E00 && nCode <= 0x9FFF) // CJK Unified Ideographs
- || (nCode >= 0x3400 && nCode <= 0x4DBF) // CJK Unified Ideographs Extension A
- || (nCode >= 0x20000 && nCode <= 0x2A6DF); // CJK Unified Ideographs Extension B
+ return (nCode >= 0x4E00 && nCode <= 0x9FFF) // CJK Unified Ideographs
+ || (nCode >= 0x3400 && nCode <= 0x4DBF) // CJK Unified Ideographs Extension A
+ || (nCode >= 0x20000 && nCode <= 0x2A6DF); // CJK Unified Ideographs Extension B
}
//Map an ISO 15924 script code to Latin/Asian/Complex/Weak
@@ -80,8 +81,7 @@ public:
//Format a number as a percentage according to the rules of the given
//language, e.g. 100 -> "100%" for en-US vs "100 %" for de-DE
- static OUString formatPercent(double dNumber,
- const LanguageTag &rLangTag);
+ static OUString formatPercent(double dNumber, const LanguageTag& rLangTag);
};
/*
@@ -128,5 +128,4 @@ public:
#endif
-
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */