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 .
20 #ifndef _SVX_GRAFCTRL_HXX
21 #define _SVX_GRAFCTRL_HXX
23 #include <svl/lstner.hxx>
24 #include <svl/intitem.hxx>
25 #include <sfx2/tbxctrl.hxx>
26 #include "svx/svxdllapi.h"
32 class SVX_DLLPUBLIC TbxImageItem
: public SfxUInt16Item
36 TbxImageItem( sal_uInt16 nWhich
= 0, sal_uInt16 nImage
= 0 );
38 virtual SfxPoolItem
* Clone( SfxItemPool
* pPool
= 0 ) const;
39 virtual int operator==( const SfxPoolItem
& ) const;
42 // -------------------------------
43 // - SvxGrafFilterToolBoxControl -
44 // -------------------------------
46 class SVX_DLLPUBLIC SvxGrafFilterToolBoxControl
: public SfxToolBoxControl
50 SFX_DECL_TOOLBOX_CONTROL();
52 SvxGrafFilterToolBoxControl( sal_uInt16 nSlotId
, sal_uInt16 nId
, ToolBox
& rTbx
);
53 ~SvxGrafFilterToolBoxControl();
55 virtual void StateChanged( sal_uInt16 nSID
, SfxItemState eState
, const SfxPoolItem
* pState
);
56 virtual SfxPopupWindowType
GetPopupWindowType() const;
57 virtual SfxPopupWindow
* CreatePopupWindow();
60 // -------------------------
61 // - SvxGrafToolBoxControl -
62 // -------------------------
64 class SvxGrafToolBoxControl
: public SfxToolBoxControl
67 SvxGrafToolBoxControl( sal_uInt16 nSlotId
, sal_uInt16 nId
, ToolBox
& rTbx
);
68 ~SvxGrafToolBoxControl();
70 virtual void StateChanged( sal_uInt16 nSID
, SfxItemState eState
, const SfxPoolItem
* pState
);
71 virtual Window
* CreateItemWindow( Window
*pParent
);
74 // ----------------------------
75 // - SvxGrafRedToolBoxControl -
76 // ----------------------------
78 class SVX_DLLPUBLIC SvxGrafRedToolBoxControl
: public SvxGrafToolBoxControl
81 SFX_DECL_TOOLBOX_CONTROL();
82 SvxGrafRedToolBoxControl( sal_uInt16 nSlotId
, sal_uInt16 nId
, ToolBox
& rTbx
);
85 // ------------------------------
86 // - SvxGrafGreenToolBoxControl -
87 // ------------------------------
89 class SVX_DLLPUBLIC SvxGrafGreenToolBoxControl
: public SvxGrafToolBoxControl
92 SFX_DECL_TOOLBOX_CONTROL();
93 SvxGrafGreenToolBoxControl( sal_uInt16 nSlotId
, sal_uInt16 nId
, ToolBox
& rTbx
);
96 // -----------------------------
97 // - SvxGrafBlueToolBoxControl -
98 // -----------------------------
100 class SVX_DLLPUBLIC SvxGrafBlueToolBoxControl
: public SvxGrafToolBoxControl
103 SFX_DECL_TOOLBOX_CONTROL();
104 SvxGrafBlueToolBoxControl( sal_uInt16 nSlotId
, sal_uInt16 nId
, ToolBox
& rTbx
);
107 // ----------------------------------
108 // - SvxGrafLuminanceToolBoxControl -
109 // ----------------------------------
111 class SVX_DLLPUBLIC SvxGrafLuminanceToolBoxControl
: public SvxGrafToolBoxControl
114 SFX_DECL_TOOLBOX_CONTROL();
115 SvxGrafLuminanceToolBoxControl( sal_uInt16 nSlotId
, sal_uInt16 nId
, ToolBox
& rTbx
);
118 // ---------------------------------
119 // - SvxGrafContrastToolBoxControl -
120 // ---------------------------------
122 class SVX_DLLPUBLIC SvxGrafContrastToolBoxControl
: public SvxGrafToolBoxControl
125 SFX_DECL_TOOLBOX_CONTROL();
126 SvxGrafContrastToolBoxControl( sal_uInt16 nSlotId
, sal_uInt16 nId
, ToolBox
& rTbx
);
129 // ------------------------------
130 // - SvxGrafGammaToolBoxControl -
131 // ------------------------------
133 class SVX_DLLPUBLIC SvxGrafGammaToolBoxControl
: public SvxGrafToolBoxControl
136 SFX_DECL_TOOLBOX_CONTROL();
137 SvxGrafGammaToolBoxControl( sal_uInt16 nSlotId
, sal_uInt16 nId
, ToolBox
& rTbx
);
140 // -------------------------------------
141 // - SvxGrafTransparenceToolBoxControl -
142 // -------------------------------------
144 class SVX_DLLPUBLIC SvxGrafTransparenceToolBoxControl
: public SvxGrafToolBoxControl
147 SFX_DECL_TOOLBOX_CONTROL();
148 SvxGrafTransparenceToolBoxControl( sal_uInt16 nSlotId
, sal_uInt16 nId
, ToolBox
& rTbx
);
151 // -----------------------------
152 // - SvxGrafModeToolBoxControl -
153 // -----------------------------
155 class SVX_DLLPUBLIC SvxGrafModeToolBoxControl
: public SfxToolBoxControl
, public SfxListener
158 SFX_DECL_TOOLBOX_CONTROL();
159 SvxGrafModeToolBoxControl( sal_uInt16 nSlotId
, sal_uInt16 nId
, ToolBox
& rTbx
);
160 ~SvxGrafModeToolBoxControl();
162 virtual void StateChanged( sal_uInt16 nSID
, SfxItemState eState
, const SfxPoolItem
* pState
);
163 virtual Window
* CreateItemWindow( Window
*pParent
);
166 // ---------------------
167 // - SvxGrafAttrHelper -
168 // ---------------------
173 class SVX_DLLPUBLIC SvxGrafAttrHelper
177 static void ExecuteGrafAttr( SfxRequest
& rReq
, SdrView
& rView
);
178 static void GetGrafAttrState( SfxItemSet
& rSet
, SdrView
& rView
);
181 #endif // _SVX_GRAFCTRL_HXX
183 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */