diff options
author | Eike Rathke <erack@redhat.com> | 2015-06-26 20:05:54 +0200 |
---|---|---|
committer | Eike Rathke <erack@redhat.com> | 2015-06-26 20:07:27 +0200 |
commit | dcbceb945b7a282c1a1309cf07e62ecc925e98f6 (patch) | |
tree | 9540b62a32c22deb8b3606e259558c598ec4c699 /sc/inc/refdata.hxx | |
parent | eeea41e2e726dd5d69cd323909e1666efb9de472 (diff) |
use ScComplexRefData::IsEntireCol() and IsEntireRow()
Change-Id: I4287019f5492825f6d295c4e364405f0d7329eb7
Diffstat (limited to 'sc/inc/refdata.hxx')
-rw-r--r-- | sc/inc/refdata.hxx | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/sc/inc/refdata.hxx b/sc/inc/refdata.hxx index e0d9b807a78b..c49682f67534 100644 --- a/sc/inc/refdata.hxx +++ b/sc/inc/refdata.hxx @@ -146,6 +146,20 @@ struct ScComplexRefData tab if one sheet, or >=0 if more than one sheets. */ bool ValidExternal() const; + /** Whether this references entire columns, A:A */ + inline bool IsEntireCol() const + { + // Both row anchors must be absolute. + return Ref1.Row() == 0 && Ref2.Row() == MAXROW && !Ref1.IsRowRel() && !Ref2.IsRowRel(); + } + + /** Whether this references entire rows, 1:1 */ + inline bool IsEntireRow() const + { + // Both column anchors must be absolute. + return Ref1.Col() == 0 && Ref2.Col() == MAXCOL && !Ref1.IsColRel() && !Ref2.IsColRel(); + } + SC_DLLPUBLIC ScRange toAbs( const ScAddress& rPos ) const; void SetRange( const ScRange& rRange, const ScAddress& rPos ); |