LibreOffice Module sc (master) 1
defaultsoptions.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
10#pragma once
11
12#include <svl/poolitem.hxx>
14#include <config_features.h>
15#include "scdllapi.h"
16#include "types.hxx"
17
19{
20private:
21 SCTAB nInitTabCount; // number of Tabs for new Spreadsheet doc
22 OUString aInitTabPrefix; // The Tab prefix name in new Spreadsheet doc
24
25public:
27
28 void SetDefaults();
29
30 SCTAB GetInitTabCount() const { return nInitTabCount; }
31 void SetInitTabCount( SCTAB nTabs) { nInitTabCount = nTabs; }
32 void SetInitTabPrefix(const OUString& aPrefix) { aInitTabPrefix = aPrefix; }
33 const OUString& GetInitTabPrefix() const { return aInitTabPrefix; }
34 bool GetInitJumboSheets() const { return bJumboSheets; }
35#if HAVE_FEATURE_JUMBO_SHEETS
36 void SetInitJumboSheets( bool b) { bJumboSheets = b; }
37#endif
38 bool operator== ( const ScDefaultsOptions& rOpt ) const;
39
40};
41
42// item for the dialog / options page
43
45{
46public:
48 virtual ~ScTpDefaultsItem() override;
49
52 ScTpDefaultsItem & operator =(ScTpDefaultsItem const &) = delete; // due to SfxPoolItem
53 ScTpDefaultsItem & operator =(ScTpDefaultsItem &&) = delete; // due to SfxPoolItem
54
55 virtual bool operator==( const SfxPoolItem& ) const override;
56 virtual ScTpDefaultsItem* Clone( SfxItemPool *pPool = nullptr ) const override;
57
58 const ScDefaultsOptions& GetDefaultsOptions() const { return theOptions; }
59
60private:
62};
63
64// config item
65
67{
68private:
69 static css::uno::Sequence<OUString> GetPropertyNames();
70 virtual void ImplCommit() override;
71
72public:
74
75 void SetOptions( const ScDefaultsOptions& rNew );
76
77 virtual void Notify( const css::uno::Sequence< OUString >& aPropertyNames ) override;
78};
79
80/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
static css::uno::Sequence< OUString > GetPropertyNames()
virtual void ImplCommit() override
virtual void Notify(const css::uno::Sequence< OUString > &aPropertyNames) override
void SetOptions(const ScDefaultsOptions &rNew)
bool GetInitJumboSheets() const
void SetInitTabCount(SCTAB nTabs)
SCTAB GetInitTabCount() const
void SetInitTabPrefix(const OUString &aPrefix)
const OUString & GetInitTabPrefix() const
ScDefaultsOptions theOptions
ScTpDefaultsItem(ScTpDefaultsItem &&)=default
ScTpDefaultsItem(ScTpDefaultsItem const &)=default
const ScDefaultsOptions & GetDefaultsOptions() const
css::uno::Reference< css::animations::XAnimationNode > Clone(const css::uno::Reference< css::animations::XAnimationNode > &xSourceNode, const SdPage *pSource=nullptr, const SdPage *pTarget=nullptr)
#define SC_DLLPUBLIC
Definition: scdllapi.h:27
sal_Int16 SCTAB
Definition: types.hxx:22
bool operator==(const XclFontData &rLeft, const XclFontData &rRight)
Definition: xlstyle.cxx:518