diff options
author | Thorsten Behrens <tbehrens@suse.com> | 2012-10-01 19:33:34 +0200 |
---|---|---|
committer | Thorsten Behrens <tbehrens@suse.com> | 2012-10-01 19:33:34 +0200 |
commit | f3f706274172879324884e845629ef74b2e2e443 (patch) | |
tree | 05fd570ddf3639e029f3c3c62ebab6e22c6c7886 /editeng | |
parent | 6fe5360e0b8876c5e7a5d1465e7772a1d84f4065 (diff) |
Outline methods with conditionals in editeng
Diffstat (limited to 'editeng')
-rw-r--r-- | editeng/source/editeng/editdoc.cxx | 15 | ||||
-rw-r--r-- | editeng/source/editeng/editdoc.hxx | 9 |
2 files changed, 17 insertions, 7 deletions
diff --git a/editeng/source/editeng/editdoc.cxx b/editeng/source/editeng/editdoc.cxx index cb13c9128972..560d7cac5a09 100644 --- a/editeng/source/editeng/editdoc.cxx +++ b/editeng/source/editeng/editdoc.cxx @@ -1034,6 +1034,21 @@ sal_Bool operator != ( const EditLine& r1, const EditLine& r2 ) return !( r1 == r2 ); } +void EditLine::SetHeight( sal_uInt16 nH, sal_uInt16 nTxtH, sal_uInt16 nCrsrH ) +{ + nHeight = nH; + nTxtHeight = ( nTxtH ? nTxtH : nH ); + nCrsrHeight = ( nCrsrH ? nCrsrH : nTxtHeight ); +} + +void EditLine::SetStartPosX( long start ) +{ + if (start > 0) + nStartPosX = start; + else + nStartPosX = 0; +} + Size EditLine::CalcTextSize( ParaPortion& rParaPortion ) { Size aSz; diff --git a/editeng/source/editeng/editdoc.hxx b/editeng/source/editeng/editdoc.hxx index c595ea86889e..2c303eed2093 100644 --- a/editeng/source/editeng/editdoc.hxx +++ b/editeng/source/editeng/editdoc.hxx @@ -513,11 +513,7 @@ public: sal_uInt16 GetEndPortion() const { return nEndPortion; } sal_uInt16& GetEndPortion() { return nEndPortion; } - void SetHeight( sal_uInt16 nH, sal_uInt16 nTxtH = 0, sal_uInt16 nCrsrH = 0 ) - { nHeight = nH; - nTxtHeight = ( nTxtH ? nTxtH : nH ); - nCrsrHeight = ( nCrsrH ? nCrsrH : nTxtHeight ); - } + void SetHeight( sal_uInt16 nH, sal_uInt16 nTxtH = 0, sal_uInt16 nCrsrH = 0 ); sal_uInt16 GetHeight() const { return nHeight; } sal_uInt16 GetTxtHeight() const { return nTxtHeight; } sal_uInt16 GetCrsrHeight() const { return nCrsrHeight; } @@ -534,8 +530,7 @@ public: sal_uInt16 GetLen() const { return nEnd - nStart; } sal_uInt16 GetStartPosX() const { return nStartPosX; } - void SetStartPosX( long start ) { if (start > 0) nStartPosX = start; else nStartPosX = 0; } - + void SetStartPosX( long start ); Size CalcTextSize( ParaPortion& rParaPortion ); bool IsInvalid() const { return bInvalid; } |