LibreOffice Module svx (master)  1
sdrattributecreator.hxx
Go to the documentation of this file.
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*
3  * This file is part of the LibreOffice project.
4  *
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/.
8  *
9  * This file incorporates work covered by the following license notice:
10  *
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 .
18  */
19 
20 #pragma once
21 
22 #include <sal/types.h>
23 #include <svx/svxdllapi.h>
24 
25 
26 // predefines
27 class SfxItemSet;
28 class SdrText;
29 
30 namespace drawinglayer { namespace attribute {
31  class SdrLineAttribute;
32  class SdrLineStartEndAttribute;
33  class SdrShadowAttribute;
34  class SdrFillAttribute;
35  class SdrTextAttribute;
36  class FillGradientAttribute;
37  class SdrFillGraphicAttribute;
38  class SdrShadowTextAttribute;
39  class SdrLineShadowTextAttribute;
40  class SdrLineFillShadowTextAttribute;
41  class SdrLineFillShadowAttribute3D;
42  class SdrSceneAttribute;
43  class SdrLightingAttribute;
44  class SdrFillTextAttribute;
45 }}
46 
47 namespace basegfx {
48  class B2DRange;
49 }
50 
51 
52 namespace drawinglayer
53 {
54  namespace primitive2d
55  {
56  // SdrAttribute creators
57  attribute::SdrLineAttribute SVXCORE_DLLPUBLIC createNewSdrLineAttribute(
58  const SfxItemSet& rSet);
59 
60  attribute::SdrLineStartEndAttribute SVXCORE_DLLPUBLIC createNewSdrLineStartEndAttribute(
61  const SfxItemSet& rSet,
62  double fWidth);
63 
64  attribute::SdrShadowAttribute createNewSdrShadowAttribute(
65  const SfxItemSet& rSet);
66 
67  attribute::SdrFillAttribute SVXCORE_DLLPUBLIC createNewSdrFillAttribute(
68  const SfxItemSet& rSet);
69 
70  // #i101508# Support handing over given text-to-border distances
71  attribute::SdrTextAttribute createNewSdrTextAttribute(
72  const SfxItemSet& rSet,
73  const SdrText& rText,
74  const sal_Int32* pLeft = nullptr,
75  const sal_Int32* pUpper = nullptr,
76  const sal_Int32* pRight = nullptr,
77  const sal_Int32* pLower = nullptr);
78 
79  attribute::FillGradientAttribute SVXCORE_DLLPUBLIC createNewTransparenceGradientAttribute(
80  const SfxItemSet& rSet);
81 
82  attribute::SdrFillGraphicAttribute createNewSdrFillGraphicAttribute(
83  const SfxItemSet& rSet);
84 
85  attribute::SdrShadowTextAttribute createNewSdrShadowTextAttribute(
86  const SfxItemSet& rSet,
87  const SdrText* pText,
88  bool bSuppressText); // #i98072# added option to suppress text on demand
89 
90  attribute::SdrLineShadowTextAttribute createNewSdrLineShadowTextAttribute(
91  const SfxItemSet& rSet,
92  const SdrText* pText);
93 
94  attribute::SdrLineFillShadowTextAttribute createNewSdrLineFillShadowTextAttribute(
95  const SfxItemSet& rSet,
96  const SdrText* pText,
97  bool bHasContent); // used from OLE and graphic
98 
99  attribute::SdrLineFillShadowAttribute3D createNewSdrLineFillShadowAttribute(
100  const SfxItemSet& rSet,
101  bool bSuppressFill);
102 
103  attribute::SdrSceneAttribute createNewSdrSceneAttribute(
104  const SfxItemSet& rSet);
105 
106  attribute::SdrLightingAttribute createNewSdrLightingAttribute(
107  const SfxItemSet& rSet);
108 
109  // #i101508# Support handing over given text-to-border distances
110  attribute::SdrFillTextAttribute createNewSdrFillTextAttribute(
111  const SfxItemSet& rSet,
112  const SdrText* pSdrText,
113  const sal_Int32* pLeft = nullptr,
114  const sal_Int32* pUpper = nullptr,
115  const sal_Int32* pRight = nullptr,
116  const sal_Int32* pLower = nullptr);
117 
118  // helpers
120  sal_Int32 nRadius,
121  const ::basegfx::B2DRange& rObjectRange,
122  double& rfCornerRadiusX,
123  double& rfCornerRadiusY);
124 
125  } // end of namespace primitive2d
126 } // end of namespace drawinglayer
127 
128 
129 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
attribute::SdrFillAttribute createNewSdrFillAttribute(const SfxItemSet &rSet)
attribute::SdrFillGraphicAttribute createNewSdrFillGraphicAttribute(const SfxItemSet &rSet)
attribute::SdrLineFillShadowAttribute3D createNewSdrLineFillShadowAttribute(const SfxItemSet &rSet, bool bSuppressFill)
attribute::SdrLineAttribute createNewSdrLineAttribute(const SfxItemSet &rSet)
attribute::SdrTextAttribute createNewSdrTextAttribute(const SfxItemSet &rSet, const SdrText &rText, const sal_Int32 *pLeft, const sal_Int32 *pUpper, const sal_Int32 *pRight, const sal_Int32 *pLower)
attribute::SdrLineFillShadowTextAttribute createNewSdrLineFillShadowTextAttribute(const SfxItemSet &rSet, const SdrText *pText, bool bHasContent)
attribute::FillGradientAttribute createNewTransparenceGradientAttribute(const SfxItemSet &rSet)
attribute::SdrLineShadowTextAttribute createNewSdrLineShadowTextAttribute(const SfxItemSet &rSet, const SdrText *pText)
void calculateRelativeCornerRadius(sal_Int32 nRadius, const basegfx::B2DRange &rObjectRange, double &rfCornerRadiusX, double &rfCornerRadiusY)
attribute::SdrShadowTextAttribute createNewSdrShadowTextAttribute(const SfxItemSet &rSet, const SdrText *pText, bool bSuppressText)
attribute::SdrLineStartEndAttribute createNewSdrLineStartEndAttribute(const SfxItemSet &rSet, double fWidth)
sal_Int32 attribute
attribute::SdrSceneAttribute createNewSdrSceneAttribute(const SfxItemSet &rSet)
attribute::SdrShadowAttribute createNewSdrShadowAttribute(const SfxItemSet &rSet)
#define SVXCORE_DLLPUBLIC
Definition: svxdllapi.h:35
attribute::SdrFillTextAttribute createNewSdrFillTextAttribute(const SfxItemSet &rSet, const SdrText *pText, const sal_Int32 *pLeft, const sal_Int32 *pUpper, const sal_Int32 *pRight, const sal_Int32 *pLower)
attribute::SdrLightingAttribute createNewSdrLightingAttribute(const SfxItemSet &rSet)