include/vcl/outdev.hxx                               |   98 +------------------
 include/vcl/rendercontext/AddFontSubstituteFlags.hxx |   38 +++++++
 include/vcl/rendercontext/AntialiasingFlags.hxx      |   38 +++++++
 include/vcl/rendercontext/DrawGridFlags.hxx          |   38 +++++++
 include/vcl/rendercontext/DrawModeFlags.hxx          |   56 ++++++++++
 include/vcl/rendercontext/GetDefaultFontFlags.hxx    |   36 ++++++
 include/vcl/rendercontext/InvertFlags.hxx            |   37 +++++++
 7 files changed, 249 insertions(+), 92 deletions(-)

New commits:
commit d4f116d9576453f5974eb63db37a33c59ac53bc9
Author:     Chris Sherlock <chris.sherloc...@gmail.com>
AuthorDate: Sun May 2 20:35:25 2021 +1000
Commit:     Tomaž Vajngerl <qui...@gmail.com>
CommitDate: Mon May 10 09:38:08 2021 +0200

    vcl: move outdev.hxx flags into own headers
    
    Change-Id: I550a0b374736b25d972d356ddbe62942590cfa1c
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114992
    Reviewed-by: Tomaž Vajngerl <qui...@gmail.com>
    Tested-by: Jenkins

diff --git a/include/vcl/outdev.hxx b/include/vcl/outdev.hxx
index 18ea39ba8e93..90e2fda67918 100644
--- a/include/vcl/outdev.hxx
+++ b/include/vcl/outdev.hxx
@@ -31,8 +31,14 @@
 #include <vcl/dllapi.h>
 #include <vcl/font.hxx>
 #include <vcl/region.hxx>
+#include <vcl/rendercontext/AddFontSubstituteFlags.hxx>
+#include <vcl/rendercontext/AntialiasingFlags.hxx>
+#include <vcl/rendercontext/DrawGridFlags.hxx>
 #include <vcl/rendercontext/DrawImageFlags.hxx>
+#include <vcl/rendercontext/DrawModeFlags.hxx>
 #include <vcl/rendercontext/DrawTextFlags.hxx>
+#include <vcl/rendercontext/GetDefaultFontFlags.hxx>
+#include <vcl/rendercontext/InvertFlags.hxx>
 #include <vcl/rendercontext/SalLayoutFlags.hxx>
 #include <vcl/mapmod.hxx>
 #include <vcl/wall.hxx>
@@ -126,98 +132,6 @@ namespace com::sun::star::rendering {
 
 // OutputDevice-Types
 
-// Flags for DrawGrid()
-enum class DrawGridFlags
-{
-    NONE                 = 0x0000,
-    Dots                 = 0x0001,
-    HorzLines            = 0x0002,
-    VertLines            = 0x0004
-};
-namespace o3tl
-{
-    template<> struct typed_flags<DrawGridFlags> : 
is_typed_flags<DrawGridFlags, 0x0007> {};
-}
-
-// DrawModes
-enum class DrawModeFlags : sal_uInt32
-{
-    Default                = 0x00000000,
-    BlackLine              = 0x00000001,
-    BlackFill              = 0x00000002,
-    BlackText              = 0x00000004,
-    BlackBitmap            = 0x00000008,
-    BlackGradient          = 0x00000010,
-    GrayLine               = 0x00000020,
-    GrayFill               = 0x00000040,
-    GrayText               = 0x00000080,
-    GrayBitmap             = 0x00000100,
-    GrayGradient           = 0x00000200,
-    NoFill                 = 0x00000400,
-    WhiteLine              = 0x00000800,
-    WhiteFill              = 0x00001000,
-    WhiteText              = 0x00002000,
-    WhiteBitmap            = 0x00004000,
-    WhiteGradient          = 0x00008000,
-    SettingsLine           = 0x00010000,
-    SettingsFill           = 0x00020000,
-    SettingsText           = 0x00040000,
-    SettingsGradient       = 0x00080000,
-    NoTransparency         = 0x00100000,
-};
-namespace o3tl
-{
-    template<> struct typed_flags<DrawModeFlags> : 
is_typed_flags<DrawModeFlags, 0x1fffff> {};
-}
-
-// Antialiasing
-enum class AntialiasingFlags
-{
-    NONE                = 0x0000,
-    DisableText         = 0x0001,
-    Enable              = 0x0002,
-    PixelSnapHairline  = 0x0004,
-};
-namespace o3tl
-{
-    template<> struct typed_flags<AntialiasingFlags> : 
is_typed_flags<AntialiasingFlags, 0x07> {};
-}
-
-// AddFontSubstitute() flags
-enum class AddFontSubstituteFlags
-{
-    NONE            = 0x00,
-    ALWAYS          = 0x01,
-    ScreenOnly      = 0x02,
-};
-namespace o3tl
-{
-    template<> struct typed_flags<AddFontSubstituteFlags> : 
is_typed_flags<AddFontSubstituteFlags, 0x03> {};
-}
-
-// GetDefaultFont() flags
-enum class GetDefaultFontFlags
-{
-    NONE          = 0x0000,
-    OnlyOne       = 0x0001,
-};
-namespace o3tl
-{
-    template<> struct typed_flags<GetDefaultFontFlags> : 
is_typed_flags<GetDefaultFontFlags, 0x01> {};
-}
-
-// Flags for Invert()
-enum class InvertFlags
-{
-    NONE                    = 0x0000,
-    N50                     = 0x0001,
-    TrackFrame              = 0x0002
-};
-namespace o3tl
-{
-    template<> struct typed_flags<InvertFlags> : is_typed_flags<InvertFlags, 
0x0003> {};
-}
-
 enum OutDevType { OUTDEV_WINDOW, OUTDEV_PRINTER, OUTDEV_VIRDEV, OUTDEV_PDF };
 
 enum class OutDevViewType { DontKnow, PrintPreview, SlideShow };
diff --git a/include/vcl/rendercontext/AddFontSubstituteFlags.hxx 
b/include/vcl/rendercontext/AddFontSubstituteFlags.hxx
new file mode 100644
index 000000000000..d2cb90a28aa0
--- /dev/null
+++ b/include/vcl/rendercontext/AddFontSubstituteFlags.hxx
@@ -0,0 +1,38 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4; 
fill-column: 100 -*- */
+/*
+ * This file is part of the LibreOffice project.
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ *
+ * This file incorporates work covered by the following license notice:
+ *
+ *   Licensed to the Apache Software Foundation (ASF) under one or more
+ *   contributor license agreements. See the NOTICE file distributed
+ *   with this work for additional information regarding copyright
+ *   ownership. The ASF licenses this file to you under the Apache
+ *   License, Version 2.0 (the "License"); you may not use this file
+ *   except in compliance with the License. You may obtain a copy of
+ *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
+ */
+
+#pragma once
+
+#include <o3tl/typed_flags_set.hxx>
+
+enum class AddFontSubstituteFlags
+{
+    NONE = 0x00,
+    ALWAYS = 0x01,
+    ScreenOnly = 0x02,
+};
+namespace o3tl
+{
+template <>
+struct typed_flags<AddFontSubstituteFlags> : 
is_typed_flags<AddFontSubstituteFlags, 0x03>
+{
+};
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab cinoptions=b1,g0,N-s 
cinkeys+=0=break: */
diff --git a/include/vcl/rendercontext/AntialiasingFlags.hxx 
b/include/vcl/rendercontext/AntialiasingFlags.hxx
new file mode 100644
index 000000000000..98ce2e882f80
--- /dev/null
+++ b/include/vcl/rendercontext/AntialiasingFlags.hxx
@@ -0,0 +1,38 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4; 
fill-column: 100 -*- */
+/*
+ * This file is part of the LibreOffice project.
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ *
+ * This file incorporates work covered by the following license notice:
+ *
+ *   Licensed to the Apache Software Foundation (ASF) under one or more
+ *   contributor license agreements. See the NOTICE file distributed
+ *   with this work for additional information regarding copyright
+ *   ownership. The ASF licenses this file to you under the Apache
+ *   License, Version 2.0 (the "License"); you may not use this file
+ *   except in compliance with the License. You may obtain a copy of
+ *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
+ */
+
+#pragma once
+
+#include <o3tl/typed_flags_set.hxx>
+
+enum class AntialiasingFlags
+{
+    NONE = 0x0000,
+    DisableText = 0x0001,
+    Enable = 0x0002,
+    PixelSnapHairline = 0x0004,
+};
+namespace o3tl
+{
+template <> struct typed_flags<AntialiasingFlags> : 
is_typed_flags<AntialiasingFlags, 0x07>
+{
+};
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab cinoptions=b1,g0,N-s 
cinkeys+=0=break: */
diff --git a/include/vcl/rendercontext/DrawGridFlags.hxx 
b/include/vcl/rendercontext/DrawGridFlags.hxx
new file mode 100644
index 000000000000..4d783e780976
--- /dev/null
+++ b/include/vcl/rendercontext/DrawGridFlags.hxx
@@ -0,0 +1,38 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4; 
fill-column: 100 -*- */
+/*
+ * This file is part of the LibreOffice project.
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ *
+ * This file incorporates work covered by the following license notice:
+ *
+ *   Licensed to the Apache Software Foundation (ASF) under one or more
+ *   contributor license agreements. See the NOTICE file distributed
+ *   with this work for additional information regarding copyright
+ *   ownership. The ASF licenses this file to you under the Apache
+ *   License, Version 2.0 (the "License"); you may not use this file
+ *   except in compliance with the License. You may obtain a copy of
+ *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
+ */
+
+#pragma once
+
+#include <o3tl/typed_flags_set.hxx>
+
+enum class DrawGridFlags
+{
+    NONE = 0x0000,
+    Dots = 0x0001,
+    HorzLines = 0x0002,
+    VertLines = 0x0004
+};
+namespace o3tl
+{
+template <> struct typed_flags<DrawGridFlags> : is_typed_flags<DrawGridFlags, 
0x0007>
+{
+};
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab cinoptions=b1,g0,N-s 
cinkeys+=0=break: */
diff --git a/include/vcl/rendercontext/DrawModeFlags.hxx 
b/include/vcl/rendercontext/DrawModeFlags.hxx
new file mode 100644
index 000000000000..9ea4888eb265
--- /dev/null
+++ b/include/vcl/rendercontext/DrawModeFlags.hxx
@@ -0,0 +1,56 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4; 
fill-column: 100 -*- */
+/*
+ * This file is part of the LibreOffice project.
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ *
+ * This file incorporates work covered by the following license notice:
+ *
+ *   Licensed to the Apache Software Foundation (ASF) under one or more
+ *   contributor license agreements. See the NOTICE file distributed
+ *   with this work for additional information regarding copyright
+ *   ownership. The ASF licenses this file to you under the Apache
+ *   License, Version 2.0 (the "License"); you may not use this file
+ *   except in compliance with the License. You may obtain a copy of
+ *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
+ */
+
+#pragma once
+
+#include <o3tl/typed_flags_set.hxx>
+
+enum class DrawModeFlags : sal_uInt32
+{
+    Default = 0x00000000,
+    BlackLine = 0x00000001,
+    BlackFill = 0x00000002,
+    BlackText = 0x00000004,
+    BlackBitmap = 0x00000008,
+    BlackGradient = 0x00000010,
+    GrayLine = 0x00000020,
+    GrayFill = 0x00000040,
+    GrayText = 0x00000080,
+    GrayBitmap = 0x00000100,
+    GrayGradient = 0x00000200,
+    NoFill = 0x00000400,
+    WhiteLine = 0x00000800,
+    WhiteFill = 0x00001000,
+    WhiteText = 0x00002000,
+    WhiteBitmap = 0x00004000,
+    WhiteGradient = 0x00008000,
+    SettingsLine = 0x00010000,
+    SettingsFill = 0x00020000,
+    SettingsText = 0x00040000,
+    SettingsGradient = 0x00080000,
+    NoTransparency = 0x00100000,
+};
+namespace o3tl
+{
+template <> struct typed_flags<DrawModeFlags> : is_typed_flags<DrawModeFlags, 
0x1fffff>
+{
+};
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab cinoptions=b1,g0,N-s 
cinkeys+=0=break: */
diff --git a/include/vcl/rendercontext/GetDefaultFontFlags.hxx 
b/include/vcl/rendercontext/GetDefaultFontFlags.hxx
new file mode 100644
index 000000000000..a100e2f2f4ba
--- /dev/null
+++ b/include/vcl/rendercontext/GetDefaultFontFlags.hxx
@@ -0,0 +1,36 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4; 
fill-column: 100 -*- */
+/*
+ * This file is part of the LibreOffice project.
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ *
+ * This file incorporates work covered by the following license notice:
+ *
+ *   Licensed to the Apache Software Foundation (ASF) under one or more
+ *   contributor license agreements. See the NOTICE file distributed
+ *   with this work for additional information regarding copyright
+ *   ownership. The ASF licenses this file to you under the Apache
+ *   License, Version 2.0 (the "License"); you may not use this file
+ *   except in compliance with the License. You may obtain a copy of
+ *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
+ */
+
+#pragma once
+
+#include <o3tl/typed_flags_set.hxx>
+
+enum class GetDefaultFontFlags
+{
+    NONE = 0x0000,
+    OnlyOne = 0x0001,
+};
+namespace o3tl
+{
+template <> struct typed_flags<GetDefaultFontFlags> : 
is_typed_flags<GetDefaultFontFlags, 0x01>
+{
+};
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab cinoptions=b1,g0,N-s 
cinkeys+=0=break: */
diff --git a/include/vcl/rendercontext/InvertFlags.hxx 
b/include/vcl/rendercontext/InvertFlags.hxx
new file mode 100644
index 000000000000..86fe96fd42fe
--- /dev/null
+++ b/include/vcl/rendercontext/InvertFlags.hxx
@@ -0,0 +1,37 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4; 
fill-column: 100 -*- */
+/*
+ * This file is part of the LibreOffice project.
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ *
+ * This file incorporates work covered by the following license notice:
+ *
+ *   Licensed to the Apache Software Foundation (ASF) under one or more
+ *   contributor license agreements. See the NOTICE file distributed
+ *   with this work for additional information regarding copyright
+ *   ownership. The ASF licenses this file to you under the Apache
+ *   License, Version 2.0 (the "License"); you may not use this file
+ *   except in compliance with the License. You may obtain a copy of
+ *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
+ */
+
+#pragma once
+
+#include <o3tl/typed_flags_set.hxx>
+
+enum class InvertFlags
+{
+    NONE = 0x0000,
+    N50 = 0x0001,
+    TrackFrame = 0x0002
+};
+namespace o3tl
+{
+template <> struct typed_flags<InvertFlags> : is_typed_flags<InvertFlags, 
0x0003>
+{
+};
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab cinoptions=b1,g0,N-s 
cinkeys+=0=break: */
_______________________________________________
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

Reply via email to