tdf#108673 XLSX: Don't export invalid sheet references in cell validation
[LibreOffice.git] / sc / inc / clipparam.hxx
blob575a04526763e4f397a0f4e188e029dd9f24fb4b
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 .
20 #ifndef INCLUDED_SC_INC_CLIPPARAM_HXX
21 #define INCLUDED_SC_INC_CLIPPARAM_HXX
23 #include "rangelst.hxx"
24 #include "charthelper.hxx"
26 /**
27 * This struct stores general clipboard parameters associated with a
28 * ScDocument instance created in clipboard mode.
30 struct SC_DLLPUBLIC ScClipParam
32 enum Direction { Unspecified, Column, Row };
34 ScRangeList maRanges;
35 Direction meDirection;
36 bool mbCutMode;
37 sal_uInt32 mnSourceDocID;
38 ScRangeListVector maProtectedChartRangesVector;
40 ScClipParam();
41 ScClipParam(const ScRange& rRange, bool bCutMode);
43 bool isMultiRange() const;
45 /**
46 * Get the column size of a pasted range. Note that when the range is
47 * non-contiguous, we first compress all individual ranges into a single
48 * range, and the size of that compressed range is returned.
50 SCCOL getPasteColSize();
52 /**
53 * Same as the above method, but returns the row size of the compressed
54 * range.
56 SCROW getPasteRowSize();
58 /**
59 * Return a single range that encompasses all individual ranges.
61 ScRange getWholeRange() const;
63 void transpose();
65 sal_uInt32 getSourceDocID() const { return mnSourceDocID; }
66 void setSourceDocID( sal_uInt32 nVal ) { mnSourceDocID = nVal; }
69 #endif
71 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */