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 .
21 #include <rtl/ustring.hxx>
22 #include <svx/unoshape.hxx>
25 namespace com::sun::star::drawing
{ struct HomogenMatrix
; }
26 namespace com::sun::star::drawing
{ struct Position3D
; }
27 namespace com::sun::star::drawing
{ class XShapes
; }
28 namespace com::sun::star::lang
{ class XMultiServiceFactory
; }
30 namespace chart
{ struct ExplicitScaleData
; }
35 class PlottingPositionHelper
;
38 /** This class provides methods for setting axis scales and for performing
39 * scene to screen transformations. It is used as the base class for all
45 PlotterBase( sal_Int32 nDimension
);
46 virtual ~PlotterBase();
48 /// @throws css::uno::RuntimeException
49 virtual void initPlotter(
50 const rtl::Reference
<SvxShapeGroupAnyD
>& xLogicTarget
51 , const rtl::Reference
<SvxShapeGroupAnyD
>& xFinalTarget
52 , const OUString
& rCID
55 virtual void setScales( std::vector
< ExplicitScaleData
>&& rScales
, bool bSwapXAndYAxis
);
57 virtual void setTransformationSceneToScreen( const css::drawing::HomogenMatrix
& rMatrix
);
59 virtual void createShapes() = 0;
61 static bool isValidPosition( const css::drawing::Position3D
& rPos
);
64 rtl::Reference
< SvxShapeGroupAnyD
>
65 createGroupShape( const rtl::Reference
< SvxShapeGroupAnyD
>& xTarget
66 , const OUString
& rName
=OUString() );
69 rtl::Reference
< SvxShapeGroupAnyD
> m_xLogicTarget
;
70 rtl::Reference
< SvxShapeGroupAnyD
> m_xFinalTarget
;
73 const sal_Int32 m_nDimension
;
74 // needs to be created and deleted by the derived class
75 PlottingPositionHelper
* m_pPosHelper
;
79 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */