1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
3 * This file is part of the LibreOffice project.
5 * This Source Code Form is subject to the terms of the Mozilla Public
6 * License, v. 2.0. If a copy of the MPL was not distributed with this
7 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
9 * This file incorporates work covered by the following license notice:
11 * Licensed to the Apache Software Foundation (ASF) under one or more
12 * contributor license agreements. See the NOTICE file distributed
13 * with this work for additional information regarding copyright
14 * ownership. The ASF licenses this file to you under the Apache
15 * License, Version 2.0 (the "License"); you may not use this file
16 * except in compliance with the License. You may obtain a copy of
17 * the License at http://www.apache.org/licenses/LICENSE-2.0 .
19 #ifndef INCLUDED_SVX_FLAGSDEF_HXX
20 #define INCLUDED_SVX_FLAGSDEF_HXX
22 #include <o3tl/typed_flags_set.hxx>
23 #include <o3tl/enumarray.hxx>
24 #include <o3tl/unit_conversion.hxx>
25 #include <tools/long.hxx>
27 // Border-Modes for SvxBorderTabPage
28 enum class SwBorderModes
38 template<> struct typed_flags
<SwBorderModes
> : is_typed_flags
<SwBorderModes
, 0x07> {};
41 // flags for SvxBackgroundTabPage
42 enum class SvxBackgroundTabFlags
47 SHOW_HIGHLIGHTING
= 0x10,
48 SHOW_CHAR_BKGCOLOR
= 0x20,
52 template<> struct typed_flags
<SvxBackgroundTabFlags
> : is_typed_flags
<SvxBackgroundTabFlags
, 0x39> {};
55 // flags for SvxBorderTabPage
56 #define SVX_HIDESHADOWCTL 0x01
58 #define DISABLE_CASEMAP (sal_uInt16(0x0001))
59 #define DISABLE_HIDE_LANGUAGE (sal_uInt16(0x0020))
61 // flags for SvxCharBasePage's child class
62 #define SVX_PREVIEW_CHARACTER 0x01
63 // flags for SvxCharNamePage
64 #define SVX_RELATIVE_MODE 0x02
65 // flags for SvxCharEffectsPage
66 #define SVX_ENABLE_CHAR_TRANSPARENCY 0x08
69 // Default values for Number Format Category List and Preview
70 enum class SvxNumValCategory
83 const o3tl::enumarray
<SvxNumValCategory
, double> fSvxNumValConst
= {
84 -1234.56789012345678, // SvxNumValCategory::Standard
85 -0.1295, // SvxNumValCategory::Percent
86 -1234.0, // SvxNumValCategory::Currency
87 // tdf#38231 - change default example date value to 1999-12-01
88 36495.5678935185, // SvxNumValCategory::Date
89 36495.5678935185, // SvxNumValCategory::Time
90 12345.67889, // SvxNumValCategory::Scientific
91 123.456, // SvxNumValCategory::Fraction
92 1.0, // SvxNumValCategory::Boolean
93 0.0 // SvxNumValCategory::NoValue
98 SVX_PAGE_MODE_STANDARD
,
100 SVX_PAGE_MODE_PRESENTATION
104 // Is also used for minimum size of LayFrms of any kind
105 constexpr tools::Long MM50
= o3tl::convert(tools::Long(5), o3tl::Length::mm
, o3tl::Length::twip
);
107 enum class TabulatorDisableFlags
{
111 TypeDecimal
= 0x0008,
116 FillDashLine
= 0x0040,
117 FillSolidLine
= 0x0080,
118 FillSpecial
= 0x0100,
122 template<> struct typed_flags
<TabulatorDisableFlags
> : is_typed_flags
<TabulatorDisableFlags
, 0x1ff> {};
127 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */