LibreOffice Module sc (master) 1
hints.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
20#pragma once
21
22#include "global.hxx"
23#include "address.hxx"
24#include <tools/solar.h>
25#include <svl/hint.hxx>
26
27class SC_DLLPUBLIC ScPaintHint final : public SfxHint
28{
31
32public:
33 ScPaintHint() = delete;
34 ScPaintHint( const ScRange& rRng, PaintPartFlags nPaint );
35 virtual ~ScPaintHint() override;
36
37 SCCOL GetStartCol() const { return aRange.aStart.Col(); }
38 SCROW GetStartRow() const { return aRange.aStart.Row(); }
39 SCTAB GetStartTab() const { return aRange.aStart.Tab(); }
40 SCCOL GetEndCol() const { return aRange.aEnd.Col(); }
41 SCROW GetEndRow() const { return aRange.aEnd.Row(); }
42 SCTAB GetEndTab() const { return aRange.aEnd.Tab(); }
43 PaintPartFlags GetParts() const { return nParts; }
44};
45
46class ScUpdateRefHint final : public SfxHint
47{
53
54public:
55 ScUpdateRefHint( UpdateRefMode eMode, const ScRange& rR,
56 SCCOL nX, SCROW nY, SCTAB nZ );
57 virtual ~ScUpdateRefHint() override;
58
60 const ScRange& GetRange() const { return aRange; }
61 SCCOL GetDx() const { return nDx; }
62 SCROW GetDy() const { return nDy; }
63 SCTAB GetDz() const { return nDz; }
64};
65
67enum class ScLinkRefType {
69};
70
71class ScLinkRefreshedHint final : public SfxHint
72{
74 OUString aUrl; // used for sheet links
75 OUString aDdeAppl; // used for dde links:
76 OUString aDdeTopic;
77 OUString aDdeItem;
78 ScAddress aDestPos; // used to identify area links
80
81public:
83 virtual ~ScLinkRefreshedHint() override;
84
85 void SetSheetLink( const OUString& rSourceUrl );
86 void SetDdeLink( const OUString& rA, const OUString& rT, const OUString& rI );
87 void SetAreaLink( const ScAddress& rPos );
88
90 const OUString& GetUrl() const { return aUrl; }
91 const OUString& GetDdeAppl() const { return aDdeAppl; }
92 const OUString& GetDdeTopic() const { return aDdeTopic; }
93 const OUString& GetDdeItem() const { return aDdeItem; }
94 const ScAddress& GetDestPos() const { return aDestPos; }
95};
96
98
99class ScAutoStyleHint final : public SfxHint
100{
102 OUString aStyle1;
103 OUString aStyle2;
105
106public:
107 ScAutoStyleHint( const ScRange& rR, OUString aSt1,
108 sal_uLong nT, OUString aSt2 );
109 virtual ~ScAutoStyleHint() override;
110
111 const ScRange& GetRange() const { return aRange; }
112 const OUString& GetStyle1() const { return aStyle1; }
113 sal_uInt32 GetTimeout() const { return nTimeout; }
114 const OUString& GetStyle2() const { return aStyle2; }
115};
116
117class ScDBRangeRefreshedHint final : public SfxHint
118{
120
121public:
123 virtual ~ScDBRangeRefreshedHint() override;
124
125 const ScImportParam& GetImportParam() const { return aParam; }
126};
127
129{
130 OUString maName;
131
132public:
133 ScDataPilotModifiedHint( OUString aName );
134 virtual ~ScDataPilotModifiedHint() override;
135
136 const OUString& GetName() const { return maName; }
137};
138
139/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
SCTAB Tab() const
Definition: address.hxx:283
SCROW Row() const
Definition: address.hxx:274
SCCOL Col() const
Definition: address.hxx:279
move ScAutoStyleHint to a different file?
Definition: hints.hxx:100
ScAutoStyleHint(const ScRange &rR, OUString aSt1, sal_uLong nT, OUString aSt2)
Definition: hints.cxx:85
sal_uInt32 GetTimeout() const
Definition: hints.hxx:113
const OUString & GetStyle1() const
Definition: hints.hxx:112
OUString aStyle1
Definition: hints.hxx:102
sal_uLong nTimeout
Definition: hints.hxx:104
const OUString & GetStyle2() const
Definition: hints.hxx:114
ScRange aRange
Definition: hints.hxx:101
virtual ~ScAutoStyleHint() override
Definition: hints.cxx:94
OUString aStyle2
Definition: hints.hxx:103
const ScRange & GetRange() const
Definition: hints.hxx:111
ScImportParam aParam
Definition: hints.hxx:119
const ScImportParam & GetImportParam() const
Definition: hints.hxx:125
virtual ~ScDBRangeRefreshedHint() override
Definition: hints.cxx:102
ScDBRangeRefreshedHint(const ScImportParam &rP)
Definition: hints.cxx:98
ScDataPilotModifiedHint(OUString aName)
Definition: hints.cxx:106
const OUString & GetName() const
Definition: hints.hxx:136
virtual ~ScDataPilotModifiedHint() override
Definition: hints.cxx:110
OUString aUrl
Definition: hints.hxx:74
OUString aDdeItem
Definition: hints.hxx:77
const OUString & GetDdeItem() const
Definition: hints.hxx:93
void SetDdeLink(const OUString &rA, const OUString &rT, const OUString &rI)
Definition: hints.cxx:68
ScAddress aDestPos
Definition: hints.hxx:78
ScLinkRefType GetLinkType() const
Definition: hints.hxx:89
ScLinkRefreshedHint()
also use source data for area links?
Definition: hints.cxx:53
const OUString & GetDdeTopic() const
Definition: hints.hxx:92
OUString aDdeTopic
Definition: hints.hxx:76
void SetSheetLink(const OUString &rSourceUrl)
Definition: hints.cxx:62
virtual ~ScLinkRefreshedHint() override
Definition: hints.cxx:58
const OUString & GetUrl() const
Definition: hints.hxx:90
ScLinkRefType nLinkType
Definition: hints.hxx:73
void SetAreaLink(const ScAddress &rPos)
Definition: hints.cxx:77
OUString aDdeAppl
Definition: hints.hxx:75
const OUString & GetDdeAppl() const
Definition: hints.hxx:91
const ScAddress & GetDestPos() const
Definition: hints.hxx:94
SCROW GetStartRow() const
Definition: hints.hxx:38
SCCOL GetStartCol() const
Definition: hints.hxx:37
ScRange aRange
Definition: hints.hxx:29
PaintPartFlags nParts
Definition: hints.hxx:30
PaintPartFlags GetParts() const
Definition: hints.hxx:43
SCTAB GetStartTab() const
Definition: hints.hxx:39
ScPaintHint()=delete
SCCOL GetEndCol() const
Definition: hints.hxx:40
SCROW GetEndRow() const
Definition: hints.hxx:41
SCTAB GetEndTab() const
Definition: hints.hxx:42
ScAddress aEnd
Definition: address.hxx:498
ScAddress aStart
Definition: address.hxx:497
const ScRange & GetRange() const
Definition: hints.hxx:60
SCCOL GetDx() const
Definition: hints.hxx:61
virtual ~ScUpdateRefHint() override
Definition: hints.cxx:47
SCTAB GetDz() const
Definition: hints.hxx:63
SCROW GetDy() const
Definition: hints.hxx:62
UpdateRefMode GetMode() const
Definition: hints.hxx:59
ScRange aRange
Definition: hints.hxx:49
UpdateRefMode eUpdateRefMode
Definition: hints.hxx:48
ScUpdateRefHint(UpdateRefMode eMode, const ScRange &rR, SCCOL nX, SCROW nY, SCTAB nZ)
Definition: hints.cxx:37
@ SHEET
Definition: document.hxx:272
UpdateRefMode
Definition: global.hxx:301
PaintPartFlags
Definition: global.hxx:109
ScLinkRefType
move ScLinkRefreshedHint to a different file?
Definition: hints.hxx:67
NONE
#define SC_DLLPUBLIC
Definition: scdllapi.h:27
sal_uIntPtr sal_uLong
sal_Int16 SCTAB
Definition: types.hxx:22
sal_Int16 SCCOL
Definition: types.hxx:21
sal_Int32 SCROW
Definition: types.hxx:17