merged tag ooo/DEV300_m102
[LibreOffice.git] / toolkit / workben / layout / zoom.hxx
blobf0c617a4b4d64651f76ac72e21a7d6879bc3607d
1 /*************************************************************************
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
5 * Copyright 2000, 2010 Oracle and/or its affiliates.
7 * OpenOffice.org - a multi-platform office productivity suite
9 * This file is part of OpenOffice.org.
11 * OpenOffice.org is free software: you can redistribute it and/or modify
12 * it under the terms of the GNU Lesser General Public License version 3
13 * only, as published by the Free Software Foundation.
15 * OpenOffice.org is distributed in the hope that it will be useful,
16 * but WITHOUT ANY WARRANTY; without even the implied warranty of
17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 * GNU Lesser General Public License version 3 for more details
19 * (a copy is included in the LICENSE file that accompanied this code).
21 * You should have received a copy of the GNU Lesser General Public License
22 * version 3 along with OpenOffice.org. If not, see
23 * <http://www.openoffice.org/license.html>
24 * for a copy of the LGPLv3 License.
26 ************************************************************************/
27 #ifndef _SVX_ZOOM_HXX
28 #define _SVX_ZOOM_HXX
30 // include ---------------------------------------------------------------
32 #include <layout/layout.hxx>
33 #include <sfx2/basedlgs.hxx>
34 #ifndef _SV_BUTTON_HXX //autogen wg. Radio-/OK-/Cancel-/HelpButton
35 #include <vcl/button.hxx>
36 #endif
37 #include <vcl/field.hxx>
38 #include <vcl/fixed.hxx>
40 // define ----------------------------------------------------------------
41 /* CHINA001
42 #define ZOOMBTN_OPTIMAL ((USHORT)0x0001)
43 #define ZOOMBTN_PAGEWIDTH ((USHORT)0x0002)
44 #define ZOOMBTN_WHOLEPAGE ((USHORT)0x0004)
46 #ifndef _SVX_ZOOM_HXX
47 #include "zoom_def.hxx"
48 #endif
49 // class SvxZoomDialog ---------------------------------------------------
51 {k:\svx\prototyp\dialog\zoom.bmp}
53 [Beschreibung]
54 Mit diesem Dialog wird ein Zoom-Faktor eingestellt.
56 [Items]
57 SvxZoomItem <SID_ATTR_ZOOM>
60 #include <layout/layout-pre.hxx>
62 class SvxZoomDialog : public SfxModalDialog
64 private:
65 FixedLine aZoomFl;
66 RadioButton aOptimalBtn;
67 RadioButton aWholePageBtn;
68 RadioButton aPageWidthBtn;
69 RadioButton a100Btn;
70 RadioButton aUserBtn;
71 MetricField aUserEdit;
73 FixedLine aViewLayoutFl;
74 RadioButton aAutomaticBtn;
75 RadioButton aSingleBtn;
76 RadioButton aColumnsBtn;
77 MetricField aColumnsEdit;
78 CheckBox aBookModeChk;
80 FixedLine aBottomFl;
81 OKButton aOKBtn;
82 CancelButton aCancelBtn;
83 HelpButton aHelpBtn;
85 #if !TEST_LAYOUT
86 const SfxItemSet& rSet;
87 #endif /* !TEST_LAYOUT */
88 SfxItemSet* pOutSet;
89 BOOL bModified;
91 #ifdef _SVX_ZOOM_CXX
92 DECL_LINK( UserHdl, RadioButton* );
93 DECL_LINK( SpinHdl, MetricField* );
94 DECL_LINK( ViewLayoutUserHdl, RadioButton* );
95 DECL_LINK( ViewLayoutSpinHdl, MetricField* );
96 DECL_LINK( ViewLayoutCheckHdl, CheckBox* );
97 DECL_LINK( OKHdl, Button* );
98 #endif
100 public:
101 #if TEST_LAYOUT
102 SvxZoomDialog( Window* pParent );
103 #else /* !TEST_LAYOUT */
104 SvxZoomDialog( Window* pParent, const SfxItemSet& rCoreSet );
105 #endif /* !TEST_LAYOUT */
106 ~SvxZoomDialog();
108 static USHORT* GetRanges();
109 const SfxItemSet* GetOutputItemSet() const { return pOutSet; }
111 USHORT GetFactor() const;
112 void SetFactor( USHORT nNewFactor, USHORT nBtnId = 0 );
114 void SetButtonText( USHORT nBtnId, const String& aNewTxt );
115 void HideButton( USHORT nBtnId );
116 void SetLimits( USHORT nMin, USHORT nMax );
117 void SetSpinSize( USHORT nNewSpin );
120 #include <layout/layout-post.hxx>
122 #endif