LibreOffice Module sw (master) 1
|
#include <SwGrammarMarkUp.hxx>
Public Member Functions | |
SwGrammarMarkUp () | |
virtual | ~SwGrammarMarkUp () override |
virtual SwWrongList * | Clone () override |
virtual void | CopyFrom (const SwWrongList &rCopy) override |
void | MoveGrammar (sal_Int32 nPos, sal_Int32 nDiff) |
std::unique_ptr< SwGrammarMarkUp > | SplitGrammarList (sal_Int32 nSplitPos) |
void | JoinGrammarList (SwGrammarMarkUp *pNext, sal_Int32 nInsertPos) |
void | ClearGrammarList (sal_Int32 nSentenceEnd=COMPLETE_STRING) |
void | setSentence (sal_Int32 nStart) |
sal_Int32 | getSentenceStart (sal_Int32 nPos) |
sal_Int32 | getSentenceEnd (sal_Int32 nPos) |
Public Member Functions inherited from SwWrongList | |
SwWrongList (WrongListType eType) | |
virtual | ~SwWrongList () |
virtual SwWrongList * | Clone () |
virtual void | CopyFrom (const SwWrongList &rCopy) |
WrongListType | GetWrongListType () const |
sal_Int32 | GetBeginInv () const |
sal_Int32 | GetEndInv () const |
void | SetInvalid (sal_Int32 nBegin, sal_Int32 nEnd) |
void | Validate () |
void | Invalidate (sal_Int32 nBegin, sal_Int32 nEnd) |
bool | InvalidateWrong () |
FreshState | Fresh (sal_Int32 &rStart, sal_Int32 &rEnd, sal_Int32 nPos, sal_Int32 nLen, sal_uInt16 nIndex, sal_Int32 nCursorPos) |
Remove given range of entries. More... | |
sal_uInt16 | GetWrongPos (sal_Int32 nValue) const |
Find the first position that is greater or equal to the given value. More... | |
bool | Check (sal_Int32 &rChk, sal_Int32 &rLn) const |
Calculate first incorrectly selected area. More... | |
bool | InWrongWord (sal_Int32 &rChk, sal_Int32 &rLn) const |
If a word is incorrectly selected, this method returns begin and length of it. More... | |
sal_Int32 | NextWrong (sal_Int32 nChk) const |
Find next incorrectly selected position. More... | |
void | Move (sal_Int32 nPos, sal_Int32 nDiff) |
Change all values after the given position. More... | |
void | ClearList () |
std::unique_ptr< SwWrongList > | SplitList (sal_Int32 nSplitPos) |
void | JoinList (SwWrongList *pNext, sal_Int32 nInsertPos) |
sal_Int32 | Len (sal_uInt16 nIdx) const |
sal_Int32 | Pos (sal_uInt16 nIdx) const |
sal_uInt16 | Count () const |
void | Insert (const OUString &rType, css::uno::Reference< css::container::XStringKeyMap > const &xPropertyBag, sal_Int32 nNewPos, sal_Int32 nNewLen, sal_uInt16 nWhere) |
void | Insert (const OUString &rType, css::uno::Reference< css::container::XStringKeyMap > const &xPropertyBag, sal_Int32 nNewPos, sal_Int32 nNewLen) |
SwWrongList * | SubList (sal_uInt16 nIdx) const |
void | InsertSubList (sal_Int32 nNewPos, sal_Int32 nNewLen, sal_uInt16 nWhere, SwWrongList *pSubList) |
const SwWrongArea * | GetElement (sal_uInt16 nIdx) const |
void | RemoveEntry (sal_Int32 nBegin, sal_Int32 nEnd) |
bool | LookForEntry (sal_Int32 nBegin, sal_Int32 nEnd) |
Private Attributes | |
std::vector< sal_Int32 > | maSentence |
Additional Inherited Members | |
Public Types inherited from SwWrongList | |
enum class | FreshState { FRESH , CURSOR , NOTHING } |
Definition at line 36 of file SwGrammarMarkUp.hxx.
|
inline |
Definition at line 41 of file SwGrammarMarkUp.hxx.
Referenced by Clone(), and SplitGrammarList().
|
overridevirtual |
Definition at line 22 of file SwGrammarMarkUp.cxx.
void SwGrammarMarkUp::ClearGrammarList | ( | sal_Int32 | nSentenceEnd = COMPLETE_STRING | ) |
Definition at line 91 of file SwGrammarMarkUp.cxx.
References SwWrongList::ClearList(), COMPLETE_STRING, SwWrongList::GetBeginInv(), maSentence, SwWrongList::RemoveEntry(), SwWrongList::SetInvalid(), and SwWrongList::Validate().
Referenced by SwXTextMarkup::commitMultiTextMarkup().
|
overridevirtual |
Reimplemented from SwWrongList.
Definition at line 26 of file SwGrammarMarkUp.cxx.
References SwWrongList::CopyFrom(), and SwGrammarMarkUp().
Referenced by sw::GrammarContact::getGrammarCheck().
|
overridevirtual |
Reimplemented from SwWrongList.
Definition at line 33 of file SwGrammarMarkUp.cxx.
References SwWrongList::CopyFrom(), and maSentence.
sal_Int32 SwGrammarMarkUp::getSentenceEnd | ( | sal_Int32 | nPos | ) |
Definition at line 134 of file SwGrammarMarkUp.cxx.
References COMPLETE_STRING, maSentence, and nPos.
Referenced by SwEditShell::GetGrammarCorrection().
sal_Int32 SwGrammarMarkUp::getSentenceStart | ( | sal_Int32 | nPos | ) |
Definition at line 121 of file SwGrammarMarkUp.cxx.
References maSentence, and nPos.
Referenced by SwEditShell::GetGrammarCorrection().
void SwGrammarMarkUp::JoinGrammarList | ( | SwGrammarMarkUp * | pNext, |
sal_Int32 | nInsertPos | ||
) |
Definition at line 76 of file SwGrammarMarkUp.cxx.
References SwWrongList::JoinList(), and maSentence.
void SwGrammarMarkUp::MoveGrammar | ( | sal_Int32 | nPos, |
sal_Int32 | nDiff | ||
) |
Definition at line 39 of file SwGrammarMarkUp.cxx.
References maSentence, SwWrongList::Move(), and nPos.
Referenced by lcl_SetWrong().
void SwGrammarMarkUp::setSentence | ( | sal_Int32 | nStart | ) |
Definition at line 113 of file SwGrammarMarkUp.cxx.
References maSentence.
Referenced by lcl_commitGrammarMarkUp().
std::unique_ptr< SwGrammarMarkUp > SwGrammarMarkUp::SplitGrammarList | ( | sal_Int32 | nSplitPos | ) |
Definition at line 57 of file SwGrammarMarkUp.cxx.
References COMPLETE_STRING, maSentence, SwWrongList::SplitList(), and SwGrammarMarkUp().
|
private |
Definition at line 38 of file SwGrammarMarkUp.hxx.
Referenced by ClearGrammarList(), CopyFrom(), getSentenceEnd(), getSentenceStart(), JoinGrammarList(), MoveGrammar(), setSentence(), and SplitGrammarList().