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 INCLUDED_VCL_BUTTON_HXX
21 #define INCLUDED_VCL_BUTTON_HXX
23 #include <tools/solar.h>
24 #include <tools/color.hxx>
25 #include <vcl/dllapi.h>
26 #include <vcl/image.hxx>
27 #include <vcl/ctrl.hxx>
28 #include <vcl/bitmap.hxx>
29 #include <vcl/salnativewidgets.hxx>
30 #include <rsc/rsc-vcl-shared-types.hxx>
31 #include <vcl/vclptr.hxx>
35 class ImplCommonButtonData
;
36 enum class DrawButtonFlags
;
38 class VCL_DLLPUBLIC Button
: public Control
41 std::unique_ptr
<ImplCommonButtonData
> mpButtonData
;
44 /// Command URL (like .uno:Save) in case the button should handle it.
47 Button (const Button
&) SAL_DELETED_FUNCTION
;
48 Button
& operator= (const Button
&) SAL_DELETED_FUNCTION
;
50 SAL_DLLPRIVATE DrawButtonFlags
ImplGetButtonState() const;
51 SAL_DLLPRIVATE DrawButtonFlags
& ImplGetButtonState();
52 SAL_DLLPRIVATE DrawTextFlags
ImplGetTextStyle( OUString
& rText
, WinBits nWinStyle
, sal_uLong nDrawFlags
);
53 SAL_DLLPRIVATE
void ImplDrawAlignedImage(OutputDevice
* pDev
, Point
& rPos
, Size
& rSize
,
54 bool bLayout
, sal_uLong nImageSep
, sal_uLong nDrawFlags
,
55 DrawTextFlags nTextStyle
, Rectangle
*pSymbolRect
=NULL
, bool bAddImageSep
= false );
56 SAL_DLLPRIVATE
void ImplSetFocusRect( const Rectangle
&rFocusRect
);
57 SAL_DLLPRIVATE
const Rectangle
& ImplGetFocusRect() const;
58 SAL_DLLPRIVATE
void ImplSetSymbolAlign( SymbolAlign eAlign
);
59 /// The x-coordinate of the vertical separator line, use in MenuButton subclass only.
60 SAL_DLLPRIVATE
long ImplGetSeparatorX() const;
61 SAL_DLLPRIVATE
void ImplSetSeparatorX( long nX
);
64 explicit Button( WindowType nType
);
68 virtual void dispose() SAL_OVERRIDE
;
72 void SetClickHdl( const Link
<>& rLink
) { maClickHdl
= rLink
; }
73 const Link
<>& GetClickHdl() const { return maClickHdl
; }
75 /// Setup handler for UNO commands so that commands like .uno:Something are handled automagically by this button.
76 void SetCommandHandler(const OUString
& aCommand
);
78 static OUString
GetStandardText( StandardButtonType eButton
);
80 bool SetModeImage( const Image
& rImage
);
81 const Image
GetModeImage( ) const;
82 bool HasImage() const;
83 void SetImageAlign( ImageAlign eAlign
);
84 ImageAlign
GetImageAlign() const;
86 void EnableImageDisplay( bool bEnable
);
87 void EnableTextDisplay( bool bEnable
);
89 void SetFocusRect( const Rectangle
& rFocusRect
);
90 bool IsSmallSymbol() const;
91 void SetSmallSymbol(bool bSmall
= true);
92 virtual bool set_property(const OString
&rKey
, const OString
&rValue
) SAL_OVERRIDE
;
96 /// Handler for click, in case we want the button to handle uno commands (.uno:Something).
97 static sal_IntPtr
dispatchCommandHandler(void *, void *pCaller
);
101 // - PushButton-Types -
104 enum class PushButtonDropdownStyle
115 class VCL_DLLPUBLIC PushButton
: public Button
120 TriState meSaveValue
;
121 PushButtonDropdownStyle mnDDStyle
;
126 SAL_DLLPRIVATE
void ImplInitPushButtonData();
127 SAL_DLLPRIVATE WinBits
ImplInitStyle( const vcl::Window
* pPrevWindow
, WinBits nStyle
);
128 SAL_DLLPRIVATE
void ImplInitSettings( bool bFont
, bool bForeground
, bool bBackground
);
129 SAL_DLLPRIVATE
void ImplDrawPushButtonContent(OutputDevice
* pDev
, sal_uLong nDrawFlags
,
130 const Rectangle
& rRect
, bool bLayout
, bool bMenuBtnSep
);
131 SAL_DLLPRIVATE
void ImplDrawPushButton(vcl::RenderContext
& rRenderContext
, bool bLayout
= false);
132 using Button::ImplGetTextStyle
;
133 SAL_DLLPRIVATE DrawTextFlags
ImplGetTextStyle( sal_uLong nDrawFlags
) const;
134 SAL_DLLPRIVATE
bool IsSymbol() const { return ( (meSymbol
!= SymbolType::DONTKNOW
) && (meSymbol
!= SymbolType::IMAGE
) ); }
135 SAL_DLLPRIVATE
bool IsImage() const { return Button::HasImage(); }
137 // Copy assignment is forbidden and not implemented.
138 SAL_DLLPRIVATE
PushButton( const PushButton
& );
139 SAL_DLLPRIVATE PushButton
& operator=( const PushButton
& );
141 SAL_DLLPRIVATE
void ImplInit( vcl::Window
* pParent
, WinBits nStyle
);
143 using Control::ImplInitSettings
;
144 using Window::ImplInit
;
146 SAL_DLLPRIVATE
void ImplSetDefButton( bool bSet
);
147 SAL_DLLPRIVATE
void ImplDrawPushButtonFrame(vcl::RenderContext
& rRenderContext
, Rectangle
& rRect
, DrawButtonFlags nStyle
);
148 SAL_DLLPRIVATE
static bool ImplHitTestPushButton(vcl::Window
* pDev
, const Point
& rPos
);
149 SAL_DLLPRIVATE
bool ImplIsDefButton() const;
152 explicit PushButton( WindowType nType
);
154 virtual void FillLayoutData() const SAL_OVERRIDE
;
155 virtual const vcl::Font
&
156 GetCanonicalFont( const StyleSettings
& _rStyle
) const SAL_OVERRIDE
;
158 GetCanonicalTextColor( const StyleSettings
& _rStyle
) const SAL_OVERRIDE
;
160 explicit PushButton( vcl::Window
* pParent
, WinBits nStyle
= 0 );
161 explicit PushButton( vcl::Window
* pParent
, const ResId
& );
163 virtual void MouseButtonDown( const MouseEvent
& rMEvt
) SAL_OVERRIDE
;
164 virtual void Tracking( const TrackingEvent
& rTEvt
) SAL_OVERRIDE
;
165 virtual void KeyInput( const KeyEvent
& rKEvt
) SAL_OVERRIDE
;
166 virtual void KeyUp( const KeyEvent
& rKEvt
) SAL_OVERRIDE
;
167 virtual void Paint( vcl::RenderContext
& rRenderContext
, const Rectangle
& rRect
) SAL_OVERRIDE
;
168 virtual void Draw( OutputDevice
* pDev
, const Point
& rPos
, const Size
& rSize
, sal_uLong nFlags
) SAL_OVERRIDE
;
169 virtual void Resize() SAL_OVERRIDE
;
170 virtual void GetFocus() SAL_OVERRIDE
;
171 virtual void LoseFocus() SAL_OVERRIDE
;
172 virtual void StateChanged( StateChangedType nType
) SAL_OVERRIDE
;
173 virtual void DataChanged( const DataChangedEvent
& rDCEvt
) SAL_OVERRIDE
;
174 virtual bool PreNotify( NotifyEvent
& rNEvt
) SAL_OVERRIDE
;
178 void SetSymbol( SymbolType eSymbol
);
179 SymbolType
GetSymbol() const { return meSymbol
; }
180 void SetSymbolAlign( SymbolAlign eAlign
);
182 void SetDropDown( PushButtonDropdownStyle nStyle
);
183 PushButtonDropdownStyle
GetDropDown() const { return mnDDStyle
; }
185 void SetState( TriState eState
);
186 TriState
GetState() const { return meState
; }
188 void Check( bool bCheck
= true );
189 bool IsChecked() const;
191 void SetPressed( bool bPressed
);
192 bool IsPressed() const { return mbPressed
; }
196 void SaveValue() { meSaveValue
= GetState(); }
197 TriState
GetSavedValue() const { return meSaveValue
; }
198 bool IsValueChangedFromSaved() const { return meSaveValue
!= GetState(); }
200 Size
CalcMinimumSize( long nMaxWidth
= 0 ) const;
201 virtual Size
GetOptimalSize() const SAL_OVERRIDE
;
203 void SetToggleHdl( const Link
<>& rLink
) { maToggleHdl
= rLink
; }
204 const Link
<>& GetToggleHdl() const { return maToggleHdl
; }
205 virtual bool set_property(const OString
&rKey
, const OString
&rValue
) SAL_OVERRIDE
;
206 virtual void ShowFocus(const Rectangle
& rRect
) SAL_OVERRIDE
;
209 inline void PushButton::Check( bool bCheck
)
211 SetState( (bCheck
) ? TRISTATE_TRUE
: TRISTATE_FALSE
);
214 inline bool PushButton::IsChecked() const
216 return (GetState() == TRISTATE_TRUE
);
219 class VCL_DLLPUBLIC OKButton
: public PushButton
222 using PushButton::ImplInit
;
224 SAL_DLLPRIVATE
void ImplInit( vcl::Window
* pParent
, WinBits nStyle
);
226 OKButton (const OKButton
&) SAL_DELETED_FUNCTION
;
227 OKButton
& operator= (const OKButton
&) SAL_DELETED_FUNCTION
;
230 explicit OKButton( vcl::Window
* pParent
, WinBits nStyle
= WB_DEFBUTTON
);
232 virtual void Click() SAL_OVERRIDE
;
235 class VCL_DLLPUBLIC CancelButton
: public PushButton
238 using PushButton::ImplInit
;
240 SAL_DLLPRIVATE
void ImplInit( vcl::Window
* pParent
, WinBits nStyle
);
242 CancelButton (const CancelButton
&) SAL_DELETED_FUNCTION
;
243 CancelButton
& operator= (const CancelButton
&) SAL_DELETED_FUNCTION
;
246 explicit CancelButton( vcl::Window
* pParent
, WinBits nStyle
= 0 );
248 virtual void Click() SAL_OVERRIDE
;
251 class VCL_DLLPUBLIC CloseButton
: public CancelButton
254 explicit CloseButton(vcl::Window
* pParent
, WinBits nStyle
= 0);
262 class VCL_DLLPUBLIC HelpButton
: public PushButton
265 using PushButton::ImplInit
;
267 SAL_DLLPRIVATE
void ImplInit( vcl::Window
* pParent
, WinBits nStyle
);
269 HelpButton( const HelpButton
& ) SAL_DELETED_FUNCTION
;
270 HelpButton
& operator= ( const HelpButton
& ) SAL_DELETED_FUNCTION
;
273 explicit HelpButton( vcl::Window
* pParent
, WinBits nStyle
= 0 );
275 virtual void Click() SAL_OVERRIDE
;
280 class VCL_DLLPUBLIC RadioButton
: public Button
283 std::shared_ptr
< std::vector
< VclPtr
< RadioButton
> > > m_xGroup
;
284 Rectangle maStateRect
;
285 Rectangle maMouseRect
;
292 // when mbLegacyNoTextAlign is set then the old behaviour where
293 // the WB_LEFT, WB_RIGHT & WB_CENTER affect the image placement
294 // occurs, otherwise the image ( radiobutton circle ) is placed
295 // to the left or right ( depending on RTL or LTR settings )
296 bool mbLegacyNoTextAlign
;
297 SAL_DLLPRIVATE
void ImplInitRadioButtonData();
298 SAL_DLLPRIVATE WinBits
ImplInitStyle( const vcl::Window
* pPrevWindow
, WinBits nStyle
);
299 SAL_DLLPRIVATE
void ImplInitSettings( bool bFont
, bool bForeground
, bool bBackground
);
300 SAL_DLLPRIVATE
void ImplDrawRadioButtonState(vcl::RenderContext
& rRenderContext
);
301 SAL_DLLPRIVATE
void ImplDraw( OutputDevice
* pDev
, sal_uLong nDrawFlags
,
302 const Point
& rPos
, const Size
& rSize
,
303 const Size
& rImageSize
, Rectangle
& rStateRect
,
304 Rectangle
& rMouseRect
, bool bLayout
= false );
305 SAL_DLLPRIVATE
void ImplDrawRadioButton(vcl::RenderContext
& rRenderContext
, bool bLayout
= false );
306 SAL_DLLPRIVATE
void ImplUncheckAllOther();
307 SAL_DLLPRIVATE Size
ImplGetRadioImageSize() const;
308 SAL_DLLPRIVATE
long ImplGetImageToTextDistance() const;
310 RadioButton(const RadioButton
&) SAL_DELETED_FUNCTION
;
311 RadioButton
& operator= (const RadioButton
&) SAL_DELETED_FUNCTION
;
314 using Control::ImplInitSettings
;
315 using Window::ImplInit
;
316 SAL_DLLPRIVATE
void ImplInit( vcl::Window
* pParent
, WinBits nStyle
);
317 SAL_DLLPRIVATE
void ImplLoadRes( const ResId
& rResId
);
320 SAL_DLLPRIVATE
void ImplCallClick( bool bGrabFocus
= false, sal_uInt16 nFocusFlags
= 0 );
321 SAL_DLLPRIVATE
void ImplSetMinimumNWFSize();
324 virtual void FillLayoutData() const SAL_OVERRIDE
;
325 virtual const vcl::Font
&
326 GetCanonicalFont( const StyleSettings
& _rStyle
) const SAL_OVERRIDE
;
328 GetCanonicalTextColor( const StyleSettings
& _rStyle
) const SAL_OVERRIDE
;
330 inline void SetMouseRect( const Rectangle
& _rMouseRect
) { maMouseRect
= _rMouseRect
; }
331 inline const Rectangle
& GetMouseRect( ) const { return maMouseRect
; }
332 inline void SetStateRect( const Rectangle
& _rStateRect
) { maStateRect
= _rStateRect
; }
333 inline const Rectangle
& GetStateRect( ) const { return maStateRect
; }
335 // draws the radio button (the knob image), in its current state (pressed/checked)
336 // at the usual location, which can be overridden with SetStateRect
337 void DrawRadioButtonState(vcl::RenderContext
& rRenderContext
);
340 explicit RadioButton( vcl::Window
* pParent
, WinBits nWinStyle
= 0 );
341 explicit RadioButton( vcl::Window
* pParent
, const ResId
& );
342 virtual ~RadioButton();
343 virtual void dispose() SAL_OVERRIDE
;
345 virtual void MouseButtonDown( const MouseEvent
& rMEvt
) SAL_OVERRIDE
;
346 virtual void Tracking( const TrackingEvent
& rTEvt
) SAL_OVERRIDE
;
347 virtual void KeyInput( const KeyEvent
& rKEvt
) SAL_OVERRIDE
;
348 virtual void KeyUp( const KeyEvent
& rKEvt
) SAL_OVERRIDE
;
349 virtual void Paint( vcl::RenderContext
& rRenderContext
, const Rectangle
& rRect
) SAL_OVERRIDE
;
350 virtual void Draw( OutputDevice
* pDev
, const Point
& rPos
, const Size
& rSize
, sal_uLong nFlags
) SAL_OVERRIDE
;
351 virtual void Resize() SAL_OVERRIDE
;
352 virtual void GetFocus() SAL_OVERRIDE
;
353 virtual void LoseFocus() SAL_OVERRIDE
;
354 virtual void StateChanged( StateChangedType nType
) SAL_OVERRIDE
;
355 virtual void DataChanged( const DataChangedEvent
& rDCEvt
) SAL_OVERRIDE
;
356 virtual bool PreNotify( NotifyEvent
& rNEvt
) SAL_OVERRIDE
;
360 bool IsStateChanged() const { return mbStateChanged
; }
362 void EnableRadioCheck( bool bRadioCheck
= true ) { mbRadioCheck
= bRadioCheck
; }
363 bool IsRadioCheckEnabled() const { return mbRadioCheck
; }
365 bool SetModeRadioImage( const Image
& rImage
);
366 const Image
& GetModeRadioImage( ) const { return maImage
;}
368 void SetState( bool bCheck
);
369 void Check( bool bCheck
= true );
370 bool IsChecked() const { return mbChecked
; }
372 void SaveValue() { mbSaveValue
= IsChecked(); }
373 bool GetSavedValue() const { return mbSaveValue
; }
374 bool IsValueChangedFromSaved() const { return mbSaveValue
!= IsChecked(); }
376 static Image
GetRadioImage( const AllSettings
& rSettings
, DrawButtonFlags nFlags
);
378 Size
CalcMinimumSize( long nMaxWidth
= 0 ) const;
379 virtual Size
GetOptimalSize() const SAL_OVERRIDE
;
381 void SetToggleHdl( const Link
<>& rLink
) { maToggleHdl
= rLink
; }
382 const Link
<>& GetToggleHdl() const { return maToggleHdl
; }
384 /** GetRadioButtonGroup returns a list of pointers to <code>RadioButton</code>s in the same group.
386 The pointers in the returned list are valid at the time call returns. However rescheduling
387 or giving up the SolarMutex may mean events get executed that lead to the pointers getting
391 defines whether <code>this</code> is contained in the returned list
394 on return contains the <code>RadioButton</code>s
395 in the same group as this <code>RadioButton</code>.
397 std::vector
<VclPtr
<RadioButton
> > GetRadioButtonGroup(bool bIncludeThis
= true) const;
399 virtual bool set_property(const OString
&rKey
, const OString
&rValue
) SAL_OVERRIDE
;
402 * Group this RadioButton with another
404 void group(RadioButton
&rOther
);
405 virtual void ShowFocus(const Rectangle
& rRect
) SAL_OVERRIDE
;
412 class VCL_DLLPUBLIC CheckBox
: public Button
415 Rectangle maStateRect
;
416 Rectangle maMouseRect
;
418 TriState meSaveValue
;
421 // when mbLegacyNoTextAlign is set then the old behaviour where
422 // the WB_LEFT, WB_RIGHT & WB_CENTER affect the image placement
423 // occurs, otherwise the image ( checkbox box ) is placed
424 // to the left or right ( depending on RTL or LTR settings )
425 bool mbLegacyNoTextAlign
;
426 SAL_DLLPRIVATE
void ImplInitCheckBoxData();
427 SAL_DLLPRIVATE WinBits
ImplInitStyle( const vcl::Window
* pPrevWindow
, WinBits nStyle
);
428 SAL_DLLPRIVATE
void ImplInitSettings( bool bFont
, bool bForeground
, bool bBackground
);
429 SAL_DLLPRIVATE
void ImplDraw( OutputDevice
* pDev
, sal_uLong nDrawFlags
,
430 const Point
& rPos
, const Size
& rSize
,
431 const Size
& rImageSize
, Rectangle
& rStateRect
,
432 Rectangle
& rMouseRect
, bool bLayout
);
433 SAL_DLLPRIVATE
void ImplDrawCheckBox(vcl::RenderContext
& rRenderContext
, bool bLayout
= false );
434 SAL_DLLPRIVATE
long ImplGetImageToTextDistance() const;
435 SAL_DLLPRIVATE Size
ImplGetCheckImageSize() const;
437 CheckBox(const CheckBox
&) SAL_DELETED_FUNCTION
;
438 CheckBox
& operator= (const CheckBox
&) SAL_DELETED_FUNCTION
;
441 using Control::ImplInitSettings
;
442 using Window::ImplInit
;
443 SAL_DLLPRIVATE
void ImplInit( vcl::Window
* pParent
, WinBits nStyle
);
444 SAL_DLLPRIVATE
void ImplLoadRes( const ResId
& rResId
);
445 virtual void FillLayoutData() const SAL_OVERRIDE
;
446 virtual const vcl::Font
& GetCanonicalFont( const StyleSettings
& _rStyle
) const SAL_OVERRIDE
;
447 virtual const Color
& GetCanonicalTextColor( const StyleSettings
& _rStyle
) const SAL_OVERRIDE
;
449 virtual void ImplDrawCheckBoxState(vcl::RenderContext
& rRenderContext
);
450 SAL_DLLPRIVATE
const Rectangle
& GetStateRect() const { return maStateRect
; }
451 SAL_DLLPRIVATE
const Rectangle
& GetMouseRect() const { return maMouseRect
; }
454 SAL_DLLPRIVATE
void ImplCheck();
455 SAL_DLLPRIVATE
void ImplSetMinimumNWFSize();
457 explicit CheckBox( vcl::Window
* pParent
, WinBits nStyle
= 0 );
458 explicit CheckBox( vcl::Window
* pParent
, const ResId
& );
460 virtual void MouseButtonDown( const MouseEvent
& rMEvt
) SAL_OVERRIDE
;
461 virtual void Tracking( const TrackingEvent
& rTEvt
) SAL_OVERRIDE
;
462 virtual void KeyInput( const KeyEvent
& rKEvt
) SAL_OVERRIDE
;
463 virtual void KeyUp( const KeyEvent
& rKEvt
) SAL_OVERRIDE
;
464 virtual void Paint( vcl::RenderContext
& rRenderContext
, const Rectangle
& rRect
) SAL_OVERRIDE
;
465 virtual void Draw( OutputDevice
* pDev
, const Point
& rPos
, const Size
& rSize
, sal_uLong nFlags
) SAL_OVERRIDE
;
466 virtual void Resize() SAL_OVERRIDE
;
467 virtual void GetFocus() SAL_OVERRIDE
;
468 virtual void LoseFocus() SAL_OVERRIDE
;
469 virtual void StateChanged( StateChangedType nType
) SAL_OVERRIDE
;
470 virtual void DataChanged( const DataChangedEvent
& rDCEvt
) SAL_OVERRIDE
;
471 virtual bool PreNotify( NotifyEvent
& rNEvt
) SAL_OVERRIDE
;
475 void SetState( TriState eState
);
476 TriState
GetState() const { return meState
; }
478 void Check( bool bCheck
= true );
479 bool IsChecked() const;
481 void EnableTriState( bool bTriState
= true );
482 bool IsTriStateEnabled() const { return mbTriState
; }
484 void SaveValue() { meSaveValue
= GetState(); }
485 TriState
GetSavedValue() const { return meSaveValue
; }
486 bool IsValueChangedFromSaved() const { return meSaveValue
!= GetState(); }
488 static Image
GetCheckImage( const AllSettings
& rSettings
, DrawButtonFlags nFlags
);
490 Size
CalcMinimumSize( long nMaxWidth
= 0 ) const;
491 virtual Size
GetOptimalSize() const SAL_OVERRIDE
;
493 void SetToggleHdl( const Link
<>& rLink
) { maToggleHdl
= rLink
; }
494 const Link
<>& GetToggleHdl() const { return maToggleHdl
; }
495 bool IsLegacyNoTextAlign() { return mbLegacyNoTextAlign
; }
496 void SetLegacyNoTextAlign( bool bVal
) { mbLegacyNoTextAlign
= bVal
; }
498 virtual bool set_property(const OString
&rKey
, const OString
&rValue
) SAL_OVERRIDE
;
499 virtual void ShowFocus(const Rectangle
& rRect
) SAL_OVERRIDE
;
502 inline void CheckBox::Check( bool bCheck
)
504 SetState( (bCheck
) ? TRISTATE_TRUE
: TRISTATE_FALSE
);
507 inline bool CheckBox::IsChecked() const
509 return (GetState() == TRISTATE_TRUE
);
513 // - Control-Layer fuer alten Code -
516 class VCL_DLLPUBLIC ImageButton
: public PushButton
519 using PushButton::ImplInitStyle
;
521 SAL_DLLPRIVATE
void ImplInitStyle();
523 ImageButton( const ImageButton
& ) SAL_DELETED_FUNCTION
;
524 ImageButton
& operator= ( const ImageButton
& ) SAL_DELETED_FUNCTION
;
527 ImageButton( vcl::Window
* pParent
, WinBits nStyle
= 0 );
528 ImageButton( vcl::Window
* pParent
, const ResId
& rResId
);
531 class VCL_DLLPUBLIC ImageRadioButton
: public RadioButton
533 ImageRadioButton( const ImageRadioButton
& ) SAL_DELETED_FUNCTION
;
534 ImageRadioButton
& operator= ( const ImageRadioButton
& ) SAL_DELETED_FUNCTION
;
537 explicit ImageRadioButton( vcl::Window
* pParent
, WinBits nStyle
= 0 );
540 class VCL_DLLPUBLIC TriStateBox
: public CheckBox
542 TriStateBox( const TriStateBox
& ) SAL_DELETED_FUNCTION
;
543 TriStateBox
& operator= ( const TriStateBox
& ) SAL_DELETED_FUNCTION
;
546 explicit TriStateBox( vcl::Window
* pParent
, WinBits nStyle
= 0 );
549 class VCL_DLLPUBLIC DisclosureButton
: public CheckBox
552 SAL_DLLPRIVATE
virtual void ImplDrawCheckBoxState(vcl::RenderContext
& rRenderContext
) SAL_OVERRIDE
;
554 explicit DisclosureButton( vcl::Window
* pParent
, WinBits nStyle
= 0 );
556 virtual void KeyInput( const KeyEvent
& rKEvt
) SAL_OVERRIDE
;
559 #endif // INCLUDED_VCL_BUTTON_HXX
561 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */