nss: upgrade to release 3.73
[LibreOffice.git] / sw / source / ui / envelp / envfmt.hxx
blob610f595133a0f7fb5f0de2bb713ee826f9e0912f
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*
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 .
19 #ifndef INCLUDED_SW_SOURCE_UI_ENVELP_ENVFMT_HXX
20 #define INCLUDED_SW_SOURCE_UI_ENVELP_ENVFMT_HXX
22 #include <vcl/weld.hxx>
23 #include <envlop.hxx>
25 class SwTextFormatColl;
27 class SwEnvFormatPage : public SfxTabPage
29 SwEnvDlg* m_pDialog;
30 std::vector<sal_uInt16> m_aIDs;
32 SwEnvPreview m_aPreview;
33 std::unique_ptr<weld::MetricSpinButton> m_xAddrLeftField;
34 std::unique_ptr<weld::MetricSpinButton> m_xAddrTopField;
35 std::unique_ptr<weld::MenuButton> m_xAddrEditButton;
36 std::unique_ptr<weld::MetricSpinButton> m_xSendLeftField;
37 std::unique_ptr<weld::MetricSpinButton> m_xSendTopField;
38 std::unique_ptr<weld::MenuButton> m_xSendEditButton;
39 std::unique_ptr<weld::ComboBox> m_xSizeFormatBox;
40 std::unique_ptr<weld::MetricSpinButton> m_xSizeWidthField;
41 std::unique_ptr<weld::MetricSpinButton> m_xSizeHeightField;
42 std::unique_ptr<weld::CustomWeld> m_xPreview;
44 DECL_LINK(ModifyHdl, weld::MetricSpinButton&, void);
45 DECL_LINK(AddrEditHdl, const OString&, void);
46 DECL_LINK(SendEditHdl, const OString&, void);
47 DECL_LINK(FormatHdl, weld::ComboBox&, void);
49 void SetMinMax();
51 SfxItemSet* GetCollItemSet(SwTextFormatColl const* pColl, bool bSender);
53 void Edit(const OString& rIdent, bool bSender);
55 SwEnvDlg* GetParentSwEnvDlg() { return m_pDialog; }
57 public:
58 SwEnvFormatPage(weld::Container* pPage, weld::DialogController* pController,
59 const SfxItemSet& rSet);
60 void Init(SwEnvDlg* pDialog);
61 virtual ~SwEnvFormatPage() override;
63 static std::unique_ptr<SfxTabPage>
64 Create(weld::Container* pPage, weld::DialogController* pController, const SfxItemSet* rSet);
66 virtual void ActivatePage(const SfxItemSet& rSet) override;
67 virtual DeactivateRC DeactivatePage(SfxItemSet* pSet) override;
68 void FillItem(SwEnvItem& rItem);
69 virtual bool FillItemSet(SfxItemSet* rSet) override;
70 virtual void Reset(const SfxItemSet* rSet) override;
73 #endif
75 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */