LibreOffice Module cui (master) 1
labdlg.hxx
Go to the documentation of this file.
1/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2/*
3 * This file is part of the LibreOffice project.
4 *
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/.
8 *
9 * This file incorporates work covered by the following license notice:
10 *
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 .
18 */
19#pragma once
20
21#include <svtools/valueset.hxx>
22#include <sfx2/tabdlg.hxx>
23#include <svx/sxctitm.hxx>
24#include <svx/sxcecitm.hxx>
25#include <svx/anchorid.hxx>
26#include <vcl/image.hxx>
27
28class SdrView;
29
30// class SvxCaptionTabPage -----------------------------------------------
31
32const sal_uInt16 CAPTYPE_BITMAPS_COUNT = 3;
33
35{
36private:
38
40
41 std::vector<OUString> m_aStrHorzList;
42 std::vector<OUString> m_aStrVertList;
43
45 sal_Int32 nGap;
47 bool bEscRel;
48 sal_Int32 nEscAbs;
49 sal_Int32 nEscRel;
50 sal_Int32 nLineLen;
52
53 sal_uInt16 nPosition;
54 sal_uInt16 nExtension;
55
57 const SdrView* pView;
58
59 std::unique_ptr<weld::MetricSpinButton> m_xMF_SPACING;
60 std::unique_ptr<weld::ComboBox> m_xLB_EXTENSION;
61 std::unique_ptr<weld::Label> m_xFT_BYFT;
62 std::unique_ptr<weld::MetricSpinButton> m_xMF_BY;
63 std::unique_ptr<weld::Label> m_xFT_POSITIONFT;
64 std::unique_ptr<weld::ComboBox> m_xLB_POSITION;
65 std::unique_ptr<weld::ComboBox> m_xLineTypes;
66 std::unique_ptr<weld::Label> m_xFT_LENGTHFT;
67 std::unique_ptr<weld::MetricSpinButton> m_xMF_LENGTH;
68 std::unique_ptr<weld::CheckButton> m_xCB_OPTIMAL;
69 std::unique_ptr<ValueSet> m_xCT_CAPTTYPE;
70 std::unique_ptr<weld::CustomWeld> m_xCT_CAPTTYPEWin;
71
72 void SetupExtension_Impl( sal_uInt16 nType );
73 void SetupType_Impl( SdrCaptionType nType );
74 DECL_LINK(ExtensionSelectHdl_Impl, weld::ComboBox&, void);
75 DECL_LINK(PositionSelectHdl_Impl, weld::ComboBox&, void);
76 DECL_LINK(LineOptHdl_Impl, weld::Toggleable&, void);
77 DECL_LINK(SelectCaptTypeHdl_Impl, ValueSet*, void);
78
79public:
80 SvxCaptionTabPage(weld::Container* pPage, weld::DialogController* pController, const SfxItemSet& rInAttrs);
81 virtual ~SvxCaptionTabPage() override;
82
83 static std::unique_ptr<SfxTabPage> Create( weld::Container* pPage, weld::DialogController* pController, const SfxItemSet* );
85
86 virtual bool FillItemSet( SfxItemSet* ) override;
87 virtual void Reset( const SfxItemSet * ) override;
88 void Construct();
89 void SetView( const SdrView* pSdrView )
90 { pView = pSdrView; }
91
92 void FillValueSet();
93};
94
95// class SvxCaptionTabDialog ---------------------------------------------
98{
99private:
102
104
105 virtual void PageCreated(const OUString& rId, SfxTabPage &rPage) override;
106
107public:
109 SvxAnchorIds nAnchorTypes);
110
113};
114
115
116/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
SvxAnchorIds
SvxAnchorIds nAnchorCtrls
Definition: labdlg.hxx:101
Link< SvxSwFrameValidation &, void > aValidateLink
Definition: labdlg.hxx:103
const SdrView * pView
Definition: labdlg.hxx:100
SvxCaptionTabDialog(weld::Window *pParent, const SdrView *pView, SvxAnchorIds nAnchorTypes)
Definition: labdlg.cxx:452
virtual void PageCreated(const OUString &rId, SfxTabPage &rPage) override
Definition: labdlg.cxx:477
void SetValidateFramePosLink(const Link< SvxSwFrameValidation &, void > &rLink)
link for the Writer to validate positions
Definition: labdlg.cxx:502
sal_uInt16 nExtension
Definition: labdlg.hxx:54
void Construct()
Definition: labdlg.cxx:132
void SetupType_Impl(SdrCaptionType nType)
Definition: labdlg.cxx:426
virtual bool FillItemSet(SfxItemSet *) override
Definition: labdlg.cxx:138
std::unique_ptr< weld::MetricSpinButton > m_xMF_LENGTH
Definition: labdlg.hxx:67
DECL_LINK(ExtensionSelectHdl_Impl, weld::ComboBox &, void)
static std::unique_ptr< SfxTabPage > Create(weld::Container *pPage, weld::DialogController *pController, const SfxItemSet *)
Definition: labdlg.cxx:326
std::unique_ptr< weld::MetricSpinButton > m_xMF_SPACING
Definition: labdlg.hxx:59
std::unique_ptr< weld::MetricSpinButton > m_xMF_BY
Definition: labdlg.hxx:62
void SetupExtension_Impl(sal_uInt16 nType)
Definition: labdlg.cxx:332
std::unique_ptr< weld::Label > m_xFT_POSITIONFT
Definition: labdlg.hxx:63
std::unique_ptr< weld::ComboBox > m_xLB_EXTENSION
Definition: labdlg.hxx:60
SvxCaptionTabPage(weld::Container *pPage, weld::DialogController *pController, const SfxItemSet &rInAttrs)
Definition: labdlg.cxx:60
std::unique_ptr< weld::Label > m_xFT_BYFT
Definition: labdlg.hxx:61
std::unique_ptr< ValueSet > m_xCT_CAPTTYPE
Definition: labdlg.hxx:69
void FillValueSet()
Definition: labdlg.cxx:445
std::unique_ptr< weld::CustomWeld > m_xCT_CAPTTYPEWin
Definition: labdlg.hxx:70
DECL_LINK(SelectCaptTypeHdl_Impl, ValueSet *, void)
const SdrView * pView
Definition: labdlg.hxx:57
const SfxItemSet & rOutAttrs
Definition: labdlg.hxx:56
sal_Int32 nGap
Definition: labdlg.hxx:45
sal_Int32 nEscRel
Definition: labdlg.hxx:49
sal_uInt16 nPosition
Definition: labdlg.hxx:53
virtual void Reset(const SfxItemSet *) override
Definition: labdlg.cxx:209
DECL_LINK(LineOptHdl_Impl, weld::Toggleable &, void)
SdrCaptionType nCaptionType
Definition: labdlg.hxx:44
sal_Int32 nLineLen
Definition: labdlg.hxx:50
DECL_LINK(PositionSelectHdl_Impl, weld::ComboBox &, void)
Image m_aBmpCapTypes[CAPTYPE_BITMAPS_COUNT]
Definition: labdlg.hxx:39
sal_Int32 nEscAbs
Definition: labdlg.hxx:48
std::unique_ptr< weld::CheckButton > m_xCB_OPTIMAL
Definition: labdlg.hxx:68
std::unique_ptr< weld::ComboBox > m_xLB_POSITION
Definition: labdlg.hxx:64
std::unique_ptr< weld::ComboBox > m_xLineTypes
Definition: labdlg.hxx:65
static WhichRangesContainer GetRanges()
Definition: labdlg.hxx:84
std::unique_ptr< weld::Label > m_xFT_LENGTHFT
Definition: labdlg.hxx:66
void SetView(const SdrView *pSdrView)
Definition: labdlg.hxx:89
std::vector< OUString > m_aStrHorzList
Definition: labdlg.hxx:41
std::vector< OUString > m_aStrVertList
Definition: labdlg.hxx:42
SdrCaptionEscDir nEscDir
Definition: labdlg.hxx:46
static const WhichRangesContainer pCaptionRanges
Definition: labdlg.hxx:37
virtual ~SvxCaptionTabPage() override
Definition: labdlg.cxx:126
const sal_uInt16 CAPTYPE_BITMAPS_COUNT
Definition: labdlg.hxx:32
SdrCaptionEscDir
SdrCaptionType