Version 7.6.3.2-android, tag libreoffice-7.6.3.2-android
[LibreOffice.git] / svx / source / inc / DefaultShapesPanel.hxx
blob788acab692a07a1cc9ff6a8cff056a1369d4ce69
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*
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_SOURCE_INC_DEFAULTSHAPESPANEL_HXX
20 #define INCLUDED_SVX_SOURCE_INC_DEFAULTSHAPESPANEL_HXX
22 #include <com/sun/star/frame/XFrame.hpp>
23 #include <sfx2/sidebar/PanelLayout.hxx>
24 #include <svtools/valueset.hxx>
25 #include <map>
26 #include "ShapesUtil.hxx"
28 using namespace css;
29 using namespace ::com::sun::star::uno;
30 using namespace ::com::sun::star::frame;
32 namespace svx::sidebar {
34 /** This panel provides buttons for inserting shapes into a document.
36 class DefaultShapesPanel final
37 : public PanelLayout, public SvxShapeCommandsMap
39 public:
40 DefaultShapesPanel (
41 weld::Widget* pParent,
42 css::uno::Reference<css::frame::XFrame> xFrame);
43 static std::unique_ptr<PanelLayout> Create(
44 weld::Widget* pParent,
45 const css::uno::Reference<css::frame::XFrame>& rxFrame);
46 virtual ~DefaultShapesPanel() override;
48 private:
49 std::unique_ptr<ValueSet> mxLineArrowSet;
50 std::unique_ptr<weld::CustomWeld> mxLineArrowSetWin;
51 std::unique_ptr<ValueSet> mxCurveSet;
52 std::unique_ptr<weld::CustomWeld> mxCurveSetWin;
53 std::unique_ptr<ValueSet> mxConnectorSet;
54 std::unique_ptr<weld::CustomWeld> mxConnectorSetWin;
55 std::unique_ptr<ValueSet> mxBasicShapeSet;
56 std::unique_ptr<weld::CustomWeld> mxBasicShapeSetWin;
57 std::unique_ptr<ValueSet> mxSymbolShapeSet;
58 std::unique_ptr<weld::CustomWeld> mxSymbolShapeSetWin;
59 std::unique_ptr<ValueSet> mxBlockArrowSet;
60 std::unique_ptr<weld::CustomWeld> mxBlockArrowSetWin;
61 std::unique_ptr<ValueSet> mxFlowchartSet;
62 std::unique_ptr<weld::CustomWeld> mxFlowchartSetWin;
63 std::unique_ptr<ValueSet> mxCalloutSet;
64 std::unique_ptr<weld::CustomWeld> mxCalloutSetWin;
65 std::unique_ptr<ValueSet> mxStarSet;
66 std::unique_ptr<weld::CustomWeld> mxStarSetWin;
67 std::unique_ptr<ValueSet> mx3DObjectSet;
68 std::unique_ptr<weld::CustomWeld> mx3DObjectSetWin;
70 Reference< XFrame > mxFrame;
71 std::map<ValueSet*, std::map<sal_uInt16, OUString>> mpShapesSetMap;
73 void populateShapes();
74 void Initialize();
75 DECL_LINK( ShapeSelectHdl, ValueSet*, void );
78 } // end of namespace sd::sidebar
80 #endif
82 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */