LibreOffice Module sw (master)  1
optcomp.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_UIBASE_INC_OPTCOMP_HXX
20 #define INCLUDED_SW_SOURCE_UIBASE_INC_OPTCOMP_HXX
21 
22 #include <memory>
23 #include <sfx2/tabdlg.hxx>
24 #include <vcl/fixed.hxx>
25 #include <vcl/layout.hxx>
26 #include <vcl/lstbox.hxx>
29 #include <svx/checklbx.hxx>
30 #include <rtl/ustring.hxx>
31 
32 class SwWrtShell;
34 
36 {
37 private:
38  // controls
46  // config item
48  // config item
50  // text of the user entry
51  OUString m_sUserEntry;
52  // shell of the current document
54  // impl object
55  std::unique_ptr<SwCompatibilityOptPage_Impl> m_pImpl;
56  // saved options after "Reset"; used in "FillItemSet" for comparison
59 
60  // handler
61  DECL_LINK(SelectHdl, ListBox&, void);
62  DECL_LINK(UseAsDefaultHdl, Button*, void);
63 
64  // private methods
65  void InitControls( const SfxItemSet& rSet );
66  void SetCurrentOptions( sal_uLong nOptions );
68  void WriteOptions();
69 
70 public:
71  SwCompatibilityOptPage( vcl::Window* pParent, const SfxItemSet& rSet );
72  virtual ~SwCompatibilityOptPage() override;
73  virtual void dispose() override;
74 
75  static VclPtr<SfxTabPage> Create( TabPageParent pParent, const SfxItemSet* rAttrSet );
76 
77  virtual bool FillItemSet( SfxItemSet* rSet ) override;
78  virtual void Reset( const SfxItemSet* rSet ) override;
79 };
80 
81 #endif
82 
83 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
SvtCompatibilityOptions m_aConfigItem
Definition: optcomp.hxx:47
sal_uLong m_nSavedOptions
Definition: optcomp.hxx:57
sal_uIntPtr sal_uLong
void SetCurrentOptions(sal_uLong nOptions)
Definition: optcomp.cxx:333
virtual ~SwCompatibilityOptPage() override
Definition: optcomp.cxx:129
Used by the UI to modify the document model.
Definition: wrtsh.hxx:88
VclPtr< SvxCheckListBox > m_pGlobalOptionsCLB
Definition: optcomp.hxx:44
virtual void Reset(const SfxItemSet *rSet) override
Definition: optcomp.cxx:495
VclPtr< SvxCheckListBox > m_pOptionsLB
Definition: optcomp.hxx:43
SwCompatibilityOptPage(vcl::Window *pParent, const SfxItemSet &rSet)
Definition: optcomp.cxx:55
DECL_LINK(SelectHdl, ListBox &, void)
VclPtr< PushButton > m_pDefaultPB
Definition: optcomp.hxx:45
bool m_bSavedMSFormsMenuOption
Definition: optcomp.hxx:58
sal_uLong GetDocumentOptions() const
Definition: optcomp.cxx:345
SwWrtShell * m_pWrtShell
Definition: optcomp.hxx:53
void InitControls(const SfxItemSet &rSet)
Definition: optcomp.cxx:217
VclPtr< ListBox > m_pFormattingLB
Definition: optcomp.hxx:41
static VclPtr< SfxTabPage > Create(TabPageParent pParent, const SfxItemSet *rAttrSet)
Definition: optcomp.cxx:378
VclPtr< ListBox > m_pGlobalOptionsLB
Definition: optcomp.hxx:42
std::unique_ptr< SwCompatibilityOptPage_Impl > m_pImpl
Definition: optcomp.hxx:55
VclPtr< VclFrame > m_pMain
Definition: optcomp.hxx:39
VclPtr< VclFrame > m_pGlobalOptionsFrame
Definition: optcomp.hxx:40
virtual bool FillItemSet(SfxItemSet *rSet) override
Definition: optcomp.cxx:383
SvtCompatibilityViewOptions m_aViewConfigItem
Definition: optcomp.hxx:49
virtual void dispose() override
Definition: optcomp.cxx:134