Branch data Line data Source code
1 : : /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 : : /*************************************************************************
3 : : *
4 : : * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
5 : : *
6 : : * Copyright 2000, 2010 Oracle and/or its affiliates.
7 : : *
8 : : * OpenOffice.org - a multi-platform office productivity suite
9 : : *
10 : : * This file is part of OpenOffice.org.
11 : : *
12 : : * OpenOffice.org is free software: you can redistribute it and/or modify
13 : : * it under the terms of the GNU Lesser General Public License version 3
14 : : * only, as published by the Free Software Foundation.
15 : : *
16 : : * OpenOffice.org is distributed in the hope that it will be useful,
17 : : * but WITHOUT ANY WARRANTY; without even the implied warranty of
18 : : * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19 : : * GNU Lesser General Public License version 3 for more details
20 : : * (a copy is included in the LICENSE file that accompanied this code).
21 : : *
22 : : * You should have received a copy of the GNU Lesser General Public License
23 : : * version 3 along with OpenOffice.org. If not, see
24 : : * <http://www.openoffice.org/license.html>
25 : : * for a copy of the LGPLv3 License.
26 : : *
27 : : ************************************************************************/
28 : : #ifndef _SVX_MEASURE_HXX
29 : : #define _SVX_MEASURE_HXX
30 : :
31 : : #include <vcl/fixed.hxx>
32 : : #include <vcl/group.hxx>
33 : : #include <sfx2/basedlgs.hxx>
34 : : #include <svx/dlgctrl.hxx>
35 : : #include <svx/measctrl.hxx>
36 : :
37 : : class SdrView;
38 : :
39 : : /// Dialog for changing TextAtrributes
40 : : class SvxMeasurePage : public SvxTabPage
41 : : {
42 : : private:
43 : :
44 : : FixedLine aFlLine;
45 : : FixedText aFtLineDist;
46 : : MetricField aMtrFldLineDist;
47 : : FixedText aFtHelplineOverhang;
48 : : MetricField aMtrFldHelplineOverhang;
49 : : FixedText aFtHelplineDist;
50 : : MetricField aMtrFldHelplineDist;
51 : : FixedText aFtHelpline1Len;
52 : : MetricField aMtrFldHelpline1Len;
53 : : FixedText aFtHelpline2Len;
54 : : MetricField aMtrFldHelpline2Len;
55 : : TriStateBox aTsbBelowRefEdge;
56 : : FixedText aFtDecimalPlaces;
57 : : MetricField aMtrFldDecimalPlaces;
58 : :
59 : : FixedLine aFlLabel;
60 : : FixedText aFtPosition;
61 : : SvxRectCtl aCtlPosition;
62 : : TriStateBox aTsbAutoPosV;
63 : : TriStateBox aTsbAutoPosH;
64 : : TriStateBox aTsbShowUnit;
65 : : ListBox aLbUnit;
66 : : TriStateBox aTsbParallel;
67 : :
68 : : SvxXMeasurePreview aCtlPreview;
69 : :
70 : : FixedLine aFlVert;
71 : :
72 : : const SfxItemSet& rOutAttrs;
73 : : SfxItemSet aAttrSet;
74 : : const SdrView* pView;
75 : : SfxMapUnit eUnit;
76 : :
77 : : sal_Bool bPositionModified;
78 : :
79 : : #ifdef _SVX_MEASURE_CXX
80 : : void FillUnitLB();
81 : :
82 : : DECL_LINK( ClickAutoPosHdl_Impl, void * );
83 : : DECL_LINK( ChangeAttrHdl_Impl, void * );
84 : : #endif
85 : :
86 : : public:
87 : :
88 : : SvxMeasurePage( Window* pWindow, const SfxItemSet& rInAttrs );
89 : : ~SvxMeasurePage();
90 : :
91 : : static SfxTabPage* Create( Window*, const SfxItemSet& );
92 : : static sal_uInt16* GetRanges();
93 : :
94 : : virtual sal_Bool FillItemSet( SfxItemSet& );
95 : : virtual void Reset( const SfxItemSet & );
96 : :
97 : : virtual void PointChanged( Window* pWindow, RECT_POINT eRP );
98 : :
99 : : void Construct();
100 : 0 : void SetView( const SdrView* pSdrView ) { pView = pSdrView; }
101 : : virtual void PageCreated (SfxAllItemSet aSet);
102 : : };
103 : :
104 : : /* Derived from SfxSingleTabDialog, in order to be able to be
105 : : informed about virtual methods by the control. */
106 : : class SvxMeasureDialog : public SfxSingleTabDialog
107 : : {
108 : : public:
109 : : SvxMeasureDialog( Window* pParent, const SfxItemSet& rAttr,
110 : : const SdrView* pView );
111 : : ~SvxMeasureDialog();
112 : : };
113 : :
114 : :
115 : : #endif // _SVX_MEASURE_HXX
116 : :
117 : : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
|