bump product version to 4.1.6.2
[LibreOffice.git] / svx / source / sidebar / graphic / GraphicPropertyPanel.hxx
blobd5e0c093c9c8c8232953a171bf706e5d46a8653f
1 /*
2 * This file is part of the LibreOffice project.
4 * This Source Code Form is subject to the terms of the Mozilla Public
5 * License, v. 2.0. If a copy of the MPL was not distributed with this
6 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
8 * This file incorporates work covered by the following license notice:
10 * Licensed to the Apache Software Foundation (ASF) under one or more
11 * contributor license agreements. See the NOTICE file distributed
12 * with this work for additional information regarding copyright
13 * ownership. The ASF licenses this file to you under the Apache
14 * License, Version 2.0 (the "License"); you may not use this file
15 * except in compliance with the License. You may obtain a copy of
16 * the License at http://www.apache.org/licenses/LICENSE-2.0 .
18 #ifndef SVX_PROPERTYPANEL_GRAPHICPAGE_HXX
19 #define SVX_PROPERTYPANEL_GRAPHICPAGE_HXX
21 #include <vcl/ctrl.hxx>
22 #include <sfx2/sidebar/SidebarPanelBase.hxx>
23 #include <sfx2/sidebar/ControllerItem.hxx>
24 #include <vcl/fixed.hxx>
25 #include <boost/scoped_ptr.hpp>
27 class FixedText;
28 class MetricField;
29 class ListBox;
30 class FloatingWindow;
33 namespace svx { namespace sidebar {
35 class GraphicPropertyPanel
36 : public Control,
37 public ::sfx2::sidebar::ControllerItem::ItemUpdateReceiverInterface
39 public:
40 static GraphicPropertyPanel* Create(
41 Window* pParent,
42 const cssu::Reference<css::frame::XFrame>& rxFrame,
43 SfxBindings* pBindings);
45 virtual void DataChanged(
46 const DataChangedEvent& rEvent);
48 virtual void NotifyItemUpdate(
49 const sal_uInt16 nSId,
50 const SfxItemState eState,
51 const SfxPoolItem* pState,
52 const bool bIsEnabled);
54 SfxBindings* GetBindings();
56 private:
57 //ui controls
58 ::boost::scoped_ptr< FixedText > mpFtBrightness;
59 ::boost::scoped_ptr< MetricField > mpMtrBrightness;
60 ::boost::scoped_ptr< FixedText > mpFtContrast;
61 ::boost::scoped_ptr< MetricField > mpMtrContrast;
62 ::boost::scoped_ptr< FixedText > mpFtColorMode;
63 ::boost::scoped_ptr< ListBox > mpLBColorMode;
64 ::boost::scoped_ptr< FixedText > mpFtTrans;
65 ::boost::scoped_ptr< MetricField > mpMtrTrans;
66 ::boost::scoped_ptr< MetricField > mpMtrRed;
67 ::boost::scoped_ptr< MetricField > mpMtrGreen;
68 ::boost::scoped_ptr< MetricField > mpMtrBlue;
69 ::boost::scoped_ptr< MetricField > mpMtrGamma;
71 ::sfx2::sidebar::ControllerItem maBrightControl;
72 ::sfx2::sidebar::ControllerItem maContrastControl;
73 ::sfx2::sidebar::ControllerItem maTransparenceControl;
74 ::sfx2::sidebar::ControllerItem maRedControl;
75 ::sfx2::sidebar::ControllerItem maGreenControl;
76 ::sfx2::sidebar::ControllerItem maBlueControl;
77 ::sfx2::sidebar::ControllerItem maGammaControl;
78 ::sfx2::sidebar::ControllerItem maModeControl;
80 Image maImgNormal;
81 Image maImgBW;
82 Image maImgGray;
83 Image maImgWater;
85 FixedImage maImgRed;
86 FixedImage maImgGreen;
87 FixedImage maImgBlue;
88 FixedImage maImgGamma;
90 String msNormal;
91 String msBW;
92 String msGray;
93 String msWater;
95 cssu::Reference<css::frame::XFrame> mxFrame;
96 SfxBindings* mpBindings;
98 DECL_LINK( ModifyBrightnessHdl, void * );
99 DECL_LINK( ModifyContrastHdl, void * );
100 DECL_LINK( ModifyTransHdl, void * );
101 DECL_LINK( ClickColorModeHdl, void * );
102 DECL_LINK( ImplPopupModeEndHdl, FloatingWindow* );
103 DECL_LINK( RedHdl, void*);
104 DECL_LINK( GreenHdl, void*);
105 DECL_LINK( BlueHdl, void*);
106 DECL_LINK( GammaHdl, void*);
108 // constructor/destuctor
109 GraphicPropertyPanel(
110 Window* pParent,
111 const cssu::Reference<css::frame::XFrame>& rxFrame,
112 SfxBindings* pBindings);
113 virtual ~GraphicPropertyPanel();
115 void SetupIcons(void);
116 void Initialize();
120 } } // end of namespace ::svx::sidebar
122 #endif
124 // eof