diff options
author | Norbert Thiebaud <nthiebaud@gmail.com> | 2014-02-02 22:16:48 -0600 |
---|---|---|
committer | Norbert Thiebaud <nthiebaud@gmail.com> | 2014-02-03 07:44:28 +0000 |
commit | 3cbfcee36dd16e451d76c561eaaaee0ff29b01a5 (patch) | |
tree | 7377a9e1d8cd56279104429abce73aec334569d5 /include/editeng/unoedsrc.hxx | |
parent | 5c39b6b997ddc85e6848efc230a427a124b97264 (diff) |
xub_StrLen and tools/string.hxx final straw
Thre is still some 0xffff limit left and possibly some
less than gracefully handled overflow/error cases
Change-Id: I00957ee3a30b02f73918ea49d7353056263dc638
Reviewed-on: https://gerrit.libreoffice.org/7787
Reviewed-by: Norbert Thiebaud <nthiebaud@gmail.com>
Tested-by: Norbert Thiebaud <nthiebaud@gmail.com>
Diffstat (limited to 'include/editeng/unoedsrc.hxx')
-rw-r--r-- | include/editeng/unoedsrc.hxx | 36 |
1 files changed, 18 insertions, 18 deletions
diff --git a/include/editeng/unoedsrc.hxx b/include/editeng/unoedsrc.hxx index d99f532eec4e..1b89fccb16d2 100644 --- a/include/editeng/unoedsrc.hxx +++ b/include/editeng/unoedsrc.hxx @@ -140,13 +140,13 @@ public: virtual ~SvxTextForwarder(); virtual sal_Int32 GetParagraphCount() const = 0; - virtual sal_uInt16 GetTextLen( sal_Int32 nParagraph ) const = 0; + virtual sal_Int32 GetTextLen( sal_Int32 nParagraph ) const = 0; virtual OUString GetText( const ESelection& rSel ) const = 0; virtual SfxItemSet GetAttribs( const ESelection& rSel, sal_Bool bOnlyHardAttrib = 0 ) const = 0; virtual SfxItemSet GetParaAttribs( sal_Int32 nPara ) const = 0; virtual void SetParaAttribs( sal_Int32 nPara, const SfxItemSet& rSet ) = 0; virtual void RemoveAttribs( const ESelection& rSelection, sal_Bool bRemoveParaAttribs, sal_uInt16 nWhich ) = 0; - virtual void GetPortions( sal_Int32 nPara, std::vector<sal_uInt16>& rList ) const = 0; + virtual void GetPortions( sal_Int32 nPara, std::vector<sal_Int32>& rList ) const = 0; virtual sal_uInt16 GetItemState( const ESelection& rSel, sal_uInt16 nWhich ) const = 0; virtual sal_uInt16 GetItemState( sal_Int32 nPara, sal_uInt16 nWhich ) const = 0; @@ -156,8 +156,8 @@ public: virtual void QuickSetAttribs( const SfxItemSet& rSet, const ESelection& rSel ) = 0; virtual void QuickInsertLineBreak( const ESelection& rSel ) = 0; - virtual OUString CalcFieldValue( const SvxFieldItem& rField, sal_Int32 nPara, sal_uInt16 nPos, Color*& rpTxtColor, Color*& rpFldColor ) = 0; - virtual void FieldClicked( const SvxFieldItem& rField, sal_Int32 nPara, xub_StrLen nPos ) = 0; + virtual OUString CalcFieldValue( const SvxFieldItem& rField, sal_Int32 nPara, sal_Int32 nPos, Color*& rpTxtColor, Color*& rpFldColor ) = 0; + virtual void FieldClicked( const SvxFieldItem& rField, sal_Int32 nPara, sal_Int32 nPos ) = 0; virtual SfxItemPool* GetPool() const = 0; @@ -165,7 +165,7 @@ public: // implementation functions for XParagraphAppend and XTextPortionAppend virtual void AppendParagraph() = 0; - virtual sal_uInt16 AppendTextPortion( sal_Int32 nPara, const OUString &rText, const SfxItemSet &rSet ) = 0; + virtual sal_Int32 AppendTextPortion( sal_Int32 nPara, const OUString &rText, const SfxItemSet &rSet ) = 0; // XTextCopy virtual void CopyText(const SvxTextForwarder& rSource) = 0; @@ -184,14 +184,14 @@ public: @param nIndex[0 .. m-1] Index of character to query language of */ - virtual LanguageType GetLanguage( sal_Int32 nPara, sal_uInt16 nIndex ) const = 0; + virtual LanguageType GetLanguage( sal_Int32 nPara, sal_Int32 nIndex ) const = 0; /** Query number of fields in the underlying edit engine @param nPara[0 .. n-1] Index of paragraph to query field number in */ - virtual sal_uInt16 GetFieldCount( sal_Int32 nPara ) const = 0; + virtual sal_Int32 GetFieldCount( sal_Int32 nPara ) const = 0; /** Query information for given field number in the underlying edit engine @@ -235,7 +235,7 @@ public: left corner of text. The coordinates returned here are to be interpreted in the map mode given by GetMapMode(). */ - virtual Rectangle GetCharBounds( sal_Int32 nPara, sal_uInt16 nIndex ) const = 0; + virtual Rectangle GetCharBounds( sal_Int32 nPara, sal_Int32 nIndex ) const = 0; /** Query the bounding rectangle of the given paragraph @@ -283,7 +283,7 @@ public: @return sal_True, if the point is over any text and both rPara and rIndex are valid */ - virtual sal_Bool GetIndexAtPoint( const Point& rPoint, sal_Int32& rPara, sal_uInt16& rIndex ) const = 0; + virtual sal_Bool GetIndexAtPoint( const Point& rPoint, sal_Int32& rPara, sal_Int32& rIndex ) const = 0; /** Get the start and the end index of the word at the given index @@ -308,7 +308,7 @@ public: @return sal_True, if the result is non-empty */ - virtual sal_Bool GetWordIndices( sal_Int32 nPara, sal_uInt16 nIndex, sal_uInt16& rStart, sal_uInt16& rEnd ) const = 0; + virtual sal_Bool GetWordIndices( sal_Int32 nPara, sal_Int32 nIndex, sal_Int32& rStart, sal_Int32& rEnd ) const = 0; /** Query range of similar attributes @@ -325,7 +325,7 @@ public: @return sal_True, if the range has been successfully determined */ - virtual sal_Bool GetAttributeRun( sal_uInt16& nStartIndex, sal_uInt16& nEndIndex, sal_Int32 nPara, sal_uInt16 nIndex, sal_Bool bInCell = sal_False ) const = 0; + virtual sal_Bool GetAttributeRun( sal_Int32& nStartIndex, sal_Int32& nEndIndex, sal_Int32 nPara, sal_Int32 nIndex, sal_Bool bInCell = sal_False ) const = 0; /** Query number of lines in the formatted paragraph @@ -335,7 +335,7 @@ public: @return number of lines in given paragraph */ - virtual sal_uInt16 GetLineCount( sal_Int32 nPara ) const = 0; + virtual sal_Int32 GetLineCount( sal_Int32 nPara ) const = 0; /** Query line length @@ -346,7 +346,7 @@ public: Index of line in paragraph to query line length of */ - virtual sal_uInt16 GetLineLen( sal_Int32 nPara, sal_uInt16 nLine ) const = 0; + virtual sal_Int32 GetLineLen( sal_Int32 nPara, sal_Int32 nLine ) const = 0; /** Query bounds of line in paragraph @@ -363,7 +363,7 @@ public: Index of line in paragraph to query line length of */ - virtual void GetLineBoundaries( /*out*/sal_uInt16 &rStart, /*out*/sal_uInt16 &rEnd, sal_Int32 nParagraph, sal_uInt16 nLine ) const = 0; + virtual void GetLineBoundaries( /*out*/sal_Int32 &rStart, /*out*/sal_Int32 &rEnd, sal_Int32 nParagraph, sal_Int32 nLine ) const = 0; /** Query the line number for a index in the paragraphs text @@ -376,7 +376,7 @@ public: @returns [0 .. k-1] The line number of the chara in the paragraph */ - virtual sal_uInt16 GetLineNumberAtIndex( sal_Int32 nPara, sal_uInt16 nIndex ) const = 0; + virtual sal_Int32 GetLineNumberAtIndex( sal_Int32 nPara, sal_Int32 nIndex ) const = 0; /** Delete given text range and reformat text @@ -432,8 +432,8 @@ public: */ virtual sal_Bool SetDepth( sal_Int32 nPara, sal_Int16 nNewDepth ) = 0; - virtual sal_Int16 GetNumberingStartValue( sal_Int32 nPara ); - virtual void SetNumberingStartValue( sal_Int32 nPara, sal_Int16 nNumberingStartValue ); + virtual sal_Int32 GetNumberingStartValue( sal_Int32 nPara ); + virtual void SetNumberingStartValue( sal_Int32 nPara, sal_Int32 nNumberingStartValue ); virtual sal_Bool IsParaIsNumberingRestart( sal_Int32 nPara ); virtual void SetParaIsNumberingRestart( sal_Int32 nPara, sal_Bool bParaIsNumberingRestart ); @@ -538,7 +538,7 @@ public: virtual sal_Bool IsWrongSpelledWordAtPos( sal_Int32, sal_Int32 ) { return sal_False; }; virtual sal_Bool IsShapeParaFocusable( ) { return sal_True; }; - virtual sal_Bool BreakParaWrongList(sal_Int32, sal_uInt16&, sal_uInt16&, sal_Int32){ return sal_False; }; + virtual sal_Bool BreakParaWrongList(sal_Int32, sal_Int32&, sal_Int32&, sal_Int32){ return sal_False; }; }; #endif |