LibreOffice Module sw (master)  1
mmlayoutpage.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 #ifndef INCLUDED_SW_SOURCE_UI_DBUI_MMLAYOUTPAGE_HXX
20 #define INCLUDED_SW_SOURCE_UI_DBUI_MMLAYOUTPAGE_HXX
21 
22 #include <vcl/wizardmachine.hxx>
23 #include <mailmergehelper.hxx>
24 #include <com/sun/star/uno/Reference.h>
25 
26 class SwMailMergeWizard;
27 class SwFrameFormat;
28 class SwOneExampleFrame;
29 class SwWrtShell;
30 class SwView;
31 
32 namespace com{ namespace sun{ namespace star{ namespace beans{ class XPropertySet;}}}}
33 
35 {
37 
38  OUString m_sExampleURL;
40 
42 
44 
45  css::uno::Reference< css::beans::XPropertySet > m_xViewProperties;
46 
47  std::unique_ptr<weld::Container> m_xPosition;
48  std::unique_ptr<weld::CheckButton> m_xAlignToBodyCB;
49  std::unique_ptr<weld::Label> m_xLeftFT;
50  std::unique_ptr<weld::MetricSpinButton> m_xLeftMF;
51  std::unique_ptr<weld::MetricSpinButton> m_xTopMF;
52  std::unique_ptr<weld::Container> m_xGreetingLine;
53  std::unique_ptr<weld::Button> m_xUpPB;
54  std::unique_ptr<weld::Button> m_xDownPB;
55  std::unique_ptr<weld::ComboBox> m_xZoomLB;
56  std::unique_ptr<SwOneExampleFrame> m_xExampleFrame;
57  std::unique_ptr<weld::CustomWeld> m_xExampleContainerWIN;
58 
59  DECL_LINK(PreviewLoadedHdl_Impl, SwOneExampleFrame&, void);
60  DECL_LINK(ZoomHdl_Impl, weld::ComboBox&, void);
61  DECL_LINK(ChangeAddressHdl_Impl, weld::MetricSpinButton&, void);
62  DECL_LINK(GreetingsHdl_Impl, weld::Button&, void);
63  DECL_LINK(AlignToTextHdl_Impl, weld::ToggleButton&, void);
64 
66  SwWrtShell& rShell,
67  SwMailMergeConfigItem const & rConfigItem,
68  const Point& rDestination,
69  bool bAlignToBody,
70  bool bExample);
71  static void InsertGreeting(SwWrtShell& rShell, SwMailMergeConfigItem const & rConfigItem, bool bExample);
72 
73  virtual void ActivatePage() override;
74  virtual bool commitPage(::vcl::WizardTypes::CommitPageReason _eReason) override;
75 public:
77  virtual ~SwMailMergeLayoutPage() override;
78  virtual void dispose() override;
79 
80  static SwFrameFormat* InsertAddressAndGreeting(SwView const * pView,
81  SwMailMergeConfigItem& rConfigItem,
82  const Point& rAddressPos,
83  bool bAlignToBody);
84 };
85 
86 #endif
87 
88 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
std::unique_ptr< weld::Button > m_xUpPB
std::unique_ptr< SwOneExampleFrame > m_xExampleFrame
std::unique_ptr< weld::MetricSpinButton > m_xLeftMF
std::unique_ptr< weld::ComboBox > m_xZoomLB
DECL_LINK(PreviewLoadedHdl_Impl, SwOneExampleFrame &, void)
Used by the UI to modify the document model.
Definition: wrtsh.hxx:88
static SwFrameFormat * InsertAddressFrame(SwWrtShell &rShell, SwMailMergeConfigItem const &rConfigItem, const Point &rDestination, bool bAlignToBody, bool bExample)
static SwFrameFormat * InsertAddressAndGreeting(SwView const *pView, SwMailMergeConfigItem &rConfigItem, const Point &rAddressPos, bool bAlignToBody)
static void InsertGreeting(SwWrtShell &rShell, SwMailMergeConfigItem const &rConfigItem, bool bExample)
SwMailMergeLayoutPage(SwMailMergeWizard *pWizard, TabPageParent pParent)
std::unique_ptr< weld::CustomWeld > m_xExampleContainerWIN
Style of a layout element.
Definition: frmfmt.hxx:57
class SAL_NO_VTABLE XPropertySet
std::unique_ptr< weld::Button > m_xDownPB
std::unique_ptr< weld::Container > m_xPosition
virtual ~SwMailMergeLayoutPage() override
virtual void ActivatePage() override
std::unique_ptr< weld::CheckButton > m_xAlignToBodyCB
std::unique_ptr< weld::MetricSpinButton > m_xTopMF
std::unique_ptr< weld::Label > m_xLeftFT
SwMailMergeWizard * m_pWizard
css::uno::Reference< css::beans::XPropertySet > m_xViewProperties
virtual bool commitPage(::vcl::WizardTypes::CommitPageReason _eReason) override
std::unique_ptr< weld::Container > m_xGreetingLine
SwWrtShell * m_pExampleWrtShell
virtual void dispose() override
Definition: view.hxx:146
SwFrameFormat * m_pAddressBlockFormat