LibreOffice Module svx (master) 1
charthelper.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#ifndef INCLUDED_SVX_CHARTHELPER_HXX
21#define INCLUDED_SVX_CHARTHELPER_HXX
22
24#include <sal/types.h>
25#include <svx/svxdllapi.h>
26
27namespace com::sun::star {
28 namespace embed { class XEmbeddedObject; }
29 namespace frame { class XModel; }
30 namespace uno { template <typename > class Reference; }
31}
32
33namespace basegfx { class B2DRange; }
34
36{
37public:
39 static void updateChart( const css::uno::Reference< css::frame::XModel >& rXModel );
40
41 // try to access rXModel in case of a chart to get the chart content
42 // as sequence of primitives. Return range of primitives (chart size) in rRange;
43 // it will be used to embed the chart to the SdrObject transformation. This
44 // allows to define possible distances between chart and SDrObject bounds here
45 static drawinglayer::primitive2d::Primitive2DContainer tryToGetChartContentAsPrimitive2DSequence(
46 const css::uno::Reference< css::frame::XModel >& rXModel,
47 basegfx::B2DRange& rRange);
48
49 // #i121334# Allow to switch off line and fill style by setting these as attributes
50 // at the OLE chart object. This is needed to allow fill styles of the covering objects
51 // to make their own fill/line settings work. This should not be done by changing
52 // the defaults at the chart (see StaticPageBackgroundDefaults_Initializer::lcl_AddDefaultsToMap)
53 // since this would not be saved/loaded, thus the compatibility will be better when setting it at
54 // newly created charts using this method
55 static void AdaptDefaultsForChart(
56 const css::uno::Reference < css::embed::XEmbeddedObject > & xEmbObj);
57};
58
59#endif // INCLUDED_SVX_CHARTHELPER_HXX
60
61/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
Reference
#define SVXCORE_DLLPUBLIC
Definition: svxdllapi.h:35
#define SAL_WARN_UNUSED