25#include <config_global.h>
39#include <editeng/editrids.hrc>
67#include <rtl/strbuf.hxx>
71#include <com/sun/star/datatransfer/clipboard/XClipboard.hpp>
72#include <com/sun/star/frame/Desktop.hpp>
74#if OSL_DEBUG_LEVEL > 1
84#if (OSL_DEBUG_LEVEL > 1) || defined ( DBG_UTIL )
206 Draw( rOutDev, rOutRect,
Point( 0, 0 ) );
213 tools::Rectangle aBigRect( -0x3FFFFFFF, -0x3FFFFFFF, 0x3FFFFFFF, 0x3FFFFFFF );
216 Point aStartPos( rStartPos );
222 pImpEditEngine->Paint(rOutDev, aBigRect, aStartPos,
false, nOrientation);
229 Draw( rOutDev, rOutRect, rStartDocPos,
true );
234#if defined( DBG_UTIL ) || (OSL_DEBUG_LEVEL > 1)
247 aStartPos.
setX( aOutRect.
Left() - rStartDocPos.
X() );
248 aStartPos.
setY( aOutRect.
Top() - rStartDocPos.
Y() );
252 aStartPos.
setX( aOutRect.
Right() + rStartDocPos.
Y() );
253 aStartPos.
setY( aOutRect.
Top() - rStartDocPos.
X() );
269 if ( rStartDocPos.
X() || rStartDocPos.
Y() ||
291 else if ( bClipRegion )
304 rViews.insert(rViews.begin()+
nIndex, pEditView);
320 ImpEditEngine::ViewsType::iterator it = std::find(rViews.begin(), rViews.end(), pView);
322 DBG_ASSERT( it != rViews.end(),
"RemoveView with invalid index" );
323 if (it != rViews.end())
341 if (
nIndex >= rViews.size())
362 return std::find(rViews.begin(), rViews.end(), pView) != rViews.end();
393 if ( !(bAutoPageSize || ( aNewSize.
Width() != aOldSize.
Width() )) )
403 pView->
pImpEditView->GetOutputArea().TopLeft(), aNewSize ) );
490 DBG_ASSERT( pNode,
"GetLanguage - nPara is invalid!" );
502 return pImpEditEngine->TransliterateText(rSelection, nTransliterationMode);
529 if(pLinePolyPolygon && 1 == rPolyPolygon.
count())
538 TextRanger* pRanger =
new TextRanger( rPolyPolygon, pLinePolyPolygon, 30, 2, 2, bSimple,
true );
539 pImpEditEngine->SetTextRanger( std::unique_ptr<TextRanger>(pRanger) );
612 return pImpEditEngine->GetLineBoundaries( rStart, rEnd, nParagraph, nLine );
640 sal_Int32 nParaWidth =
pImpEditEngine->CalcParaWidth( nPara,
true );
643 return tools::Rectangle( nTextHeight - aPnt.
Y() - nParaHeight, 0, nTextHeight - aPnt.
Y(), nParaWidth );
647 sal_Int32 nParaWidth =
pImpEditEngine->CalcParaWidth( nPara,
true );
677 aSel =
pE->pImpEditEngine->SelectWord( aSel, nWordType );
678 return pE->pImpEditEngine->CreateESel( aSel );
733 pImpEditEngine->aDeletedNodes.push_back(std::unique_ptr<DeletedNodeInfo>(pInfo));
763 return pImpEditEngine->MoveParagraphs(rParagraphs, nNewPos,
nullptr);
768 pImpEditEngine->RemoveCharAttribs(nPara, nWhich, bRemoveFeatures);
832 return pImpEditEngine->ImpConnectParagraphs(pLeft, pRight, bBackward);
851 uno::Reference<datatransfer::XTransferable >
const & rxDataObj,
852 const OUString& rBaseURL,
const EditPaM& rPaM,
bool bUseSpecial)
854 return pImpEditEngine->PasteText(rxDataObj, rBaseURL, rPaM, bUseSpecial);
874 const ParaPortion* pParaPortion,
const EditLine* pLine, sal_Int32 nIndex,
bool bPreferPortionStart)
const
1002 DBG_ASSERT( pEditView,
"no View - no cookie !" );
1006 bool bModified =
false;
1007 bool bMoved =
false;
1008 bool bAllowIdle =
true;
1012 bool bSetCursorFlags =
true;
1023 if ( eFunc != KeyFuncType::DONTKNOW )
1027 case KeyFuncType::UNDO:
1033 case KeyFuncType::REDO:
1041 eFunc = KeyFuncType::DONTKNOW;
1045 if ( eFunc == KeyFuncType::DONTKNOW )
1049#if defined( DBG_UTIL ) || (OSL_DEBUG_LEVEL > 1)
1058 for ( sal_Int32
n = 0;
n < nParas;
n++ )
1061 Point P1( aViewStart.
X() + n20 + n20*(
n%2), aViewStart.
Y() + aPos.
Y() );
1079 OStringBuffer aInfo(
"DebugPaint: ");
1082 VclMessageType::Info, VclButtonsType::Ok,
1083 OStringToOUString(aInfo, RTL_TEXTENCODING_ASCII_US)));
1106 case css::awt::Key::MOVE_WORD_FORWARD:
1107 case css::awt::Key::SELECT_WORD_FORWARD:
1108 case css::awt::Key::MOVE_WORD_BACKWARD:
1109 case css::awt::Key::SELECT_WORD_BACKWARD:
1110 case css::awt::Key::MOVE_TO_BEGIN_OF_LINE:
1111 case css::awt::Key::MOVE_TO_END_OF_LINE:
1112 case css::awt::Key::SELECT_TO_BEGIN_OF_LINE:
1113 case css::awt::Key::SELECT_TO_END_OF_LINE:
1114 case css::awt::Key::MOVE_TO_BEGIN_OF_PARAGRAPH:
1115 case css::awt::Key::MOVE_TO_END_OF_PARAGRAPH:
1116 case css::awt::Key::SELECT_TO_BEGIN_OF_PARAGRAPH:
1117 case css::awt::Key::SELECT_TO_END_OF_PARAGRAPH:
1118 case css::awt::Key::MOVE_TO_BEGIN_OF_DOCUMENT:
1119 case css::awt::Key::MOVE_TO_END_OF_DOCUMENT:
1120 case css::awt::Key::SELECT_TO_BEGIN_OF_DOCUMENT:
1121 case css::awt::Key::SELECT_TO_END_OF_DOCUMENT:
1126 bSetCursorFlags =
false;
1142#if OSL_DEBUG_LEVEL > 1
1149 case css::awt::Key::DELETE_WORD_BACKWARD:
1150 case css::awt::Key::DELETE_WORD_FORWARD:
1151 case css::awt::Key::DELETE_TO_BEGIN_OF_PARAGRAPH:
1152 case css::awt::Key::DELETE_TO_END_OF_PARAGRAPH:
1174 aSet.
Put( aBulletState );
1191 case css::awt::Key::DELETE_WORD_BACKWARD:
1195 case css::awt::Key::DELETE_WORD_FORWARD:
1199 case css::awt::Key::DELETE_TO_BEGIN_OF_PARAGRAPH:
1203 case css::awt::Key::DELETE_TO_END_OF_PARAGRAPH:
1217 aCurSel =
pImpEditEngine->DeleteLeftOrRight( aCurSel, nDel, nMode );
1261 if (aAutoText.isEmpty())
1290 #if (OSL_DEBUG_LEVEL > 1) && defined(DBG_UTIL)
1298 aAttribs.
Put( aNewItem );
1312 aCurSel, nCharCode, !pEditView->
IsInsertMode(), pFrameWin );
1319 if (
pImpEditEngine->GetStatus().DoAutoComplete() && ( nCharCode !=
' ' ) )
1328 if ( aWord.getLength() >= 3 )
1345 const ::utl::TransliterationWrapper* pTransliteration =
pImpEditEngine->xTransliterationWrapper.get();
1346 Sequence< i18n::CalendarItem2 > xItem =
pImpEditEngine->xLocaleDataWrapper->getDefaultCalendarDays();
1347 sal_Int32
nCount = xItem.getLength();
1348 const i18n::CalendarItem2* pArr = xItem.getConstArray();
1349 for( sal_Int32
n = 0;
n <=
nCount; ++
n )
1351 const OUString& rDay = pArr[
n].FullName;
1352 if( pTransliteration->isMatch( aWord, rDay) )
1359 if ( aComplete.isEmpty() )
1361 xItem =
pImpEditEngine->xLocaleDataWrapper->getDefaultCalendarMonths();
1362 sal_Int32 nMonthCount = xItem.getLength();
1363 const i18n::CalendarItem2* pMonthArr = xItem.getConstArray();
1364 for( sal_Int32
n = 0;
n <= nMonthCount; ++
n )
1366 const OUString& rMon = pMonthArr[
n].FullName;
1367 if( pTransliteration->isMatch( aWord, rMon) )
1375 if( !aComplete.isEmpty() && ( ( aWord.getLength() + 1 ) < aComplete.getLength() ) )
1380 aPos = pEditView->
pImpEditView->GetWindow()->LogicToPixel( aPos );
1416 if ( bSetCursorFlags )
1417 pEditView->
pImpEditView->nExtraCursorFlags = nNewCursorFlags;
1423 if ( bAllowIdle &&
pImpEditEngine->GetStatus().UseIdleFormatter()
1431 bool bGotoCursor = pEditView->
pImpEditView->DoAutoScroll();
1432 pEditView->
pImpEditView->ShowCursor( bGotoCursor,
true );
1473 bool bPrevUpdateLayout =
pImpEditEngine->SetUpdateLayout( bUpdate );
1477 pImpEditEngine->pActiveView->ShowCursor(
false,
false, !bRestoring);
1479 return bPrevUpdateLayout;
1613 DBG_ASSERT( pStartNode,
"Start-Paragraph does not exist: CreateTextObject" );
1614 DBG_ASSERT( pEndNode,
"End-Paragraph does not exist: CreateTextObject" );
1616 if ( pStartNode && pEndNode )
1634 DBG_ASSERT( pPortion && pNode,
"Paragraph not found: RemoveParagraph" );
1635 if ( pNode && pPortion )
1649 DBG_ASSERT( pNode,
"Paragraph not found: GetTextLen" );
1651 return pNode->
Len();
1706 if ( bAppend && nPara )
1736 std::optional<EditSelection> pSel =
pImpEditEngine->SelectParagraph( nPara );
1793 return pImpEditEngine->GetAttribs( nPara, nStart, nEnd, nFlags );
1830 aBigRect.
SetLeft( -0x7FFFFFFF );
1834 aBigRect.
SetTop( -0x7FFFFFFF );
1851 for ( sal_Int32
n = 0;
n < nTextPortions;
n++ )
1854 rList.push_back( nEnd );
1912 if ( !bSpellingChanged )
1920 for ( sal_Int32
n = 0;
n < nNodes;
n++ )
1932 for ( sal_Int32
n = 0;
n < nNodes;
n++ )
1936 bool bWrongs =
false;
1976 Point aDocPos( rPaperPos );
1981 aDocPos.
setX( rPaperPos.
Y() );
1986 aDocPos.
setX( rPaperPos.
Y() );
1987 aDocPos.
setY( rPaperPos.
X() );
1996 DBG_ASSERT( pPPortion,
"Paragraph not found: GetWindowPosTopLeft" );
2014 sal_Int32 nSpaceBefore = 0;
2016 short nX =
static_cast<short>(rLRItem.
GetTextLeft()
2255 pImpEditEngine->ApplyChangedSentence( rEditView, rNewPortions, bRecheck );
2275 pImpEditEngine->setScale(fFontScaleX, fFontScaleY, fSpacingScaleX, fSpacingScaleY);
2311 sal_Int32 nTextPortions = 0;
2313 for ( sal_Int32 nPara = 0; nPara < nParas; nPara++ )
2323 sal_uInt16 nFields = 0;
2342 sal_uInt16 nCurrentField = 0;
2348 if ( nCurrentField == nField )
2382 for ( sal_Int32 nPara = 0; nPara < nParas; nPara++ )
2386 for (
size_t nAttr = rAttrs.size(); nAttr; )
2392 if ( pFldData && ( isFieldData( pFldData ) ) )
2407 for ( sal_Int32
n = 0;
n < nNodes;
n++ )
2430 return pImpEditEngine->GetParaPortions().FindParagraph( nDocPosY );
2452 if ( pNode && ( rPos.
nIndex < pNode->
Len() ) )
2475 &pParaPortion->
GetLines()[0] :
nullptr;
2476 DBG_ASSERT( pParaPortion && pLine,
"GetParagraphInfos - Paragraph out of range" );
2477 if ( pParaPortion && pLine )
2487css::uno::Reference< css::datatransfer::XTransferable >
2501 const css::lang::Locale*,
const Color&,
const Color&)
2507 const OUString& ,
const SvxFont& ,
2509 bool ,
const Color& ,
2579 aComment =
EditResId(RID_EDITUNDO_MOVE);
2587 aComment =
EditResId(RID_EDITUNDO_INSERT);
2590 aComment =
EditResId(RID_EDITUNDO_REPLACE);
2594 aComment =
EditResId(RID_EDITUNDO_SETATTRIBS);
2597 aComment =
EditResId(RID_EDITUNDO_RESETATTRIBS);
2600 aComment =
EditResId(RID_EDITUNDO_SETSTYLE);
2603 aComment =
EditResId(RID_EDITUNDO_TRANSLITERATE);
2607 aComment =
EditResId(RID_EDITUNDO_INDENT);
2620 return OUString(
' ');
2640class TerminateListener :
public ::cppu::WeakImplHelper< css::frame::XTerminateListener >
2642 void SAL_CALL queryTermination(
const lang::EventObject& )
override
2644 void SAL_CALL notifyTermination(
const lang::EventObject& )
override
2648 virtual void SAL_CALL disposing( const ::css::lang::EventObject& )
override
2658#if defined(FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION)
2663 uno::Reference< frame::XTerminateListener > xListener(
new TerminateListener );
2664 xDesktop->addTerminateListener( xListener );
2704 CreateFont( aFont, rItemSet,
true, nScriptType );
2708 return std::move(aFont);
2721 bool bDoesMove =
false;
2744 bool bDoesChange =
false;
2747 if ( eFunc != KeyFuncType::DONTKNOW )
2751 case KeyFuncType::UNDO:
2752 case KeyFuncType::REDO:
2753 case KeyFuncType::CUT:
2754 case KeyFuncType::PASTE: bDoesChange =
true;
2757 eFunc = KeyFuncType::DONTKNOW;
2760 if ( eFunc == KeyFuncType::DONTKNOW )
2792 bool bValidData =
false;
2797 if ( rTransferable.is() )
2800 datatransfer::DataFlavor aFlavor;
2802 bValidData = rTransferable->isDataFlavorSupported( aFlavor );
2837 pImpEditEngine->SetReplaceLeadingSingleQuotationMark( bReplace );
2918 aPosition( nPara,
nPos )
2933 if(
this == &rFldInfo )
static weld::MessageDialog * CreateMessageDialog(weld::Widget *pParent, VclMessageType eMessageType, VclButtonsType eButtonType, const OUString &rPrimaryMessage, const ILibreOfficeKitNotifier *pNotifier=nullptr)
static bool AnyInput(VclInputFlags nType=VCL_INPUT_ANY)
AttribsType & GetAttribs()
std::vector< std::unique_ptr< EditCharAttrib > > AttribsType
CharAttribList & GetCharAttribs()
sal_Unicode GetChar(sal_Int32 nPos) const
WrongList * GetWrongList()
const SfxPoolItem * GetItem() const
Point GetDocPos(const Point &rPaperPos) const
void EraseVirtualDevice()
const SfxItemSet & GetBaseParaAttribs(sal_Int32 nPara) const
void RemoveParagraph(sal_Int32 nPara)
Color const & GetBackgroundColor() const
ViewsType & GetEditViews()
void setRoundFontSizeToPt(bool bRound) const
EDITENG_DLLPRIVATE tools::Long GetXPos(const ParaPortion *pParaPortion, const EditLine *pLine, sal_Int32 nIndex, bool bPreferPortionStart=false) const
void GetPortions(sal_Int32 nPara, std::vector< sal_Int32 > &rList)
bool HasConvertibleTextPortion(LanguageType nLang)
void SetMaxAutoPaperSize(const Size &rSz)
void SetPolygon(const basegfx::B2DPolyPolygon &rPolyPolygon)
OUString GetWord(sal_Int32 nPara, sal_Int32 nIndex)
bool IsTextPos(const Point &rPaperPos, sal_uInt16 nBorder)
EDITENG_DLLPRIVATE InternalEditStatus & GetInternalEditStatus()
virtual void PaintingFirstLine(sal_Int32 nPara, const Point &rStartPos, const Point &rOrigin, Degree10 nOrientation, OutputDevice &rOutDev)
void QuickFormatDoc(bool bFull=false)
ESelection CreateESelection(const EditSelection &rSel) const
static bool IsPrintable(sal_Unicode c)
OUString GetText(LineEnd eEnd=LINEEND_LF) const
void RemoveParaPortion(sal_Int32 nNode)
const Size & GetMinAutoPaperSize() const
void SetWordDelimiters(const OUString &rDelimiters)
virtual OUString CalcFieldValue(const SvxFieldItem &rField, sal_Int32 nPara, sal_Int32 nPos, std::optional< Color > &rTxtColor, std::optional< Color > &rFldColor, std::optional< FontLineStyle > &rFldLineStyle)
EditSelection MoveParagraphs(const Range &rParagraphs, sal_Int32 nNewPos)
void QuickMarkInvalid(const ESelection &rSel)
void GetAllMisspellRanges(std::vector< editeng::MisspellRanges > &rRanges) const
TextRotation GetRotation() const
EditPaM CursorRight(const EditPaM &rPaM, sal_uInt16 nCharacterIteratorMode=css::i18n::CharacterIteratorMode::SKIPCELL)
void PutSpellingToSentenceStart(EditView const &rEditView)
EDITENG_DLLPRIVATE const ParaPortion * GetPrevVisPortion(const ParaPortion *pCurPortion) const
virtual OUString GetUndoComment(sal_uInt16 nUndoId) const
void CallHtmlImportHandler(HtmlImportInfo &rInfo)
EditPaM DeleteSelection(const EditSelection &rSel)
std::unique_ptr< EditTextObject > CreateTextObject()
void SetBeginDropHdl(const Link< EditView *, void > &rLink)
sets a link that is called at the beginning of a drag operation at an edit view
void SetText(const OUString &rStr)
void RemoveCharAttribs(sal_Int32 nPara, sal_uInt16 nWhich=0, bool bRemoveFeatures=false)
bool IsRtfImportHandlerSet() const
EditEngine(const EditEngine &)=delete
EDITENG_DLLPRIVATE const EditSelectionEngine & GetSelectionEngine() const
bool IsHtmlImportHandlerSet() const
static void DumpData(const EditEngine *pEE, bool bInfoBox)
void SetCharAttribs(sal_Int32 nPara, const SfxItemSet &rSet)
Set attributes from rSet an all characters of nPara.
const Size & GetMaxAutoPaperSize() const
EDITENG_DLLPRIVATE void HandleEndPasteOrDrop(PasteOrDropInfos &rInfos)
void SetAddExtLeading(bool b)
EditPaM CursorLeft(const EditPaM &rPaM, sal_uInt16 nCharacterIteratorMode=css::i18n::CharacterIteratorMode::SKIPCELL)
void EnableAutoColor(bool b)
EDITENG_DLLPRIVATE css::uno::Reference< css::datatransfer::XTransferable > CreateTransferable(const EditSelection &rSelection)
virtual void DrawingText(const Point &rStartPos, const OUString &rText, sal_Int32 nTextStart, sal_Int32 nTextLen, o3tl::span< const sal_Int32 > pDXArray, o3tl::span< const sal_Bool > pKashidaArray, const SvxFont &rFont, sal_Int32 nPara, sal_uInt8 nRightToLeft, const EEngineData::WrongSpellVector *pWrongSpellVector, const SvxFieldData *pFieldData, bool bEndOfLine, bool bEndOfParagraph, const css::lang::Locale *pLocale, const Color &rOverlineColor, const Color &rTextLineColor)
EditPaM InsertField(const EditSelection &rEditSelection, const SvxFieldItem &rFld)
SfxItemPool * GetEditTextObjectPool() const
bool SetUpdateLayout(bool bUpdate, bool bRestoring=false)
Change the update mode per bUpdate and potentially trigger FormatAndUpdate.
virtual void StyleSheetChanged(SfxStyleSheet *pStyle)
ErrCode Read(SvStream &rInput, const OUString &rBaseURL, EETextFormat, SvKeyValueIterator *pHTTPHeaderAttrs=nullptr)
EPosition FindDocPosition(const Point &rDocPos) const
void Redo(EditView *pView)
basegfx::B2DTuple getGlobalFontScale() const
bool HasView(EditView *pView) const
void SetEditTextObjectPool(SfxItemPool *pPool)
void ShowParagraph(sal_Int32 nParagraph, bool bShow)
sal_Int32 FindParagraph(tools::Long nDocPosY)
editeng::LanguageSpan GetLanguage(const EditPaM &rPaM) const
EEControlBits GetControlWord() const
EditPaM DeleteSelected(const EditSelection &rSel)
virtual const SvxNumberFormat * GetNumberFormat(sal_Int32 nPara) const
void QuickInsertLineBreak(const ESelection &rSel)
sal_Int32 GetParagraphCount() const
tools::Long GetFirstLineStartX(sal_Int32 nParagraph)
MapMode const & GetRefMapMode() const
OutputDevice * GetRefDevice() const
bool IsTopToBottom() const
void SetSingleLine(bool bValue)
EDITENG_DLLPRIVATE void SetInSelectionMode(bool b)
void EnableUndo(bool bEnable)
const Size & GetPaperSize() const
void DisableAttributeExpanding()
void EnableSkipOutsideFormat(bool set)
void RemoveAttribs(const ESelection &rSelection, bool bRemoveParaAttribs, sal_uInt16 nWhich)
virtual void ParagraphDeleted(sal_Int32 nDeletedParagraph)
Link< EENotify &, void > const & GetNotifyHdl() const
void SetParaAttribsOnly(sal_Int32 nPara, const SfxItemSet &rSet)
EditPaM ConnectContents(sal_Int32 nLeftNode, bool bBackward)
void SeekCursor(ContentNode *pNode, sal_Int32 nPos, SvxFont &rFont)
void QuickInsertField(const SvxFieldItem &rFld, const ESelection &rSel)
void SetKernAsianPunctuation(bool bEnabled)
EditView * RemoveView(EditView *pEditView)
sal_uInt32 GetTextHeight() const
void SetHyphenator(css::uno::Reference< css::linguistic2::XHyphenator > const &xHyph)
void Undo(EditView *pView)
void QuickDelete(const ESelection &rSel)
bool IsUndoEnabled() const
EditView * GetView(size_t nIndex=0) const
SfxItemSet GetAttribs(sal_Int32 nPara, sal_Int32 nStart, sal_Int32 nEnd, GetAttribsFlags nFlags=GetAttribsFlags::ALL) const
ParagraphInfos GetParagraphInfos(sal_Int32 nPara)
EFieldInfo GetFieldInfo(sal_Int32 nPara, sal_uInt16 nField) const
size_t GetViewCount() const
sal_Int32 GetTextLen() const
void AppendDeletedNodeInfo(DeletedNodeInfo *pInfo)
void SetAsianCompressionMode(CharCompressType nCompression)
void SetRefMapMode(const MapMode &rMapMode)
void SetBeginPasteOrDropHdl(const Link< PasteOrDropInfos &, void > &rLink)
EditSelection CreateSelection(const ESelection &rSel)
void InsertParagraph(sal_Int32 nPara, const EditTextObject &rTxtObj, const bool bAppend=false)
EditView * GetActiveView() const
vcl::Font GetStandardFont(sal_Int32 nPara)
virtual void ParaAttribsChanged(sal_Int32 nParagraph)
void SetVertical(bool bVertical)
bool IsEffectivelyVertical() const
void SetAllMisspellRanges(const std::vector< editeng::MisspellRanges > &rRanges)
void SetDefaultHorizontalTextDirection(EEHorizontalTextDirection eHTextDir)
void SetEndDropHdl(const Link< EditView *, void > &rLink)
sets a link that is called at the end of a drag operation at an edit view
virtual tools::Rectangle GetBulletArea(sal_Int32 nPara)
void SetEndMovingParagraphsHdl(const Link< MoveParagraphsInfo &, void > &rLink)
css::uno::Reference< css::linguistic2::XSpellChecker1 > const & GetSpeller()
void ClearOverflowingParaNum()
void SetHtmlImportHdl(const Link< HtmlImportInfo &, void > &rLink)
virtual void ParagraphConnected(sal_Int32 nLeftParagraph, sal_Int32 nRightParagraph)
EditSelection InsertText(css::uno::Reference< css::datatransfer::XTransferable > const &rxDataObj, const OUString &rBaseURL, const EditPaM &rPaM, bool bUseSpecial)
bool ShouldCreateBigTextObject() const
void SetRotation(TextRotation nRotation)
virtual bool SpellNextDocument()
const Link< RtfImportInfo &, void > & GetRtfImportHdl() const
bool HasParaAttrib(sal_Int32 nPara, sal_uInt16 nWhich) const
EDITENG_DLLPRIVATE bool IsIdleFormatterActive() const
void SetStyleSheet(const EditSelection &aSel, SfxStyleSheet *pStyle)
void SetRtfImportHdl(const Link< RtfImportInfo &, void > &rLink)
static void SetForbiddenCharsTable(const std::shared_ptr< SvxForbiddenCharactersTable > &xForbiddenChars)
tools::Rectangle GetCharacterBounds(const EPosition &rPos) const
sal_Int32 GetLineNumberAtIndex(sal_Int32 nPara, sal_Int32 nIndex) const
static rtl::Reference< SfxItemPool > CreatePool()
virtual bool FieldClicked(const SvxFieldItem &rField)
static SfxItemPool & GetGlobalItemPool()
tools::Rectangle GetParaBounds(sal_Int32 nPara)
void CompleteOnlineSpelling()
void SetBeginMovingParagraphsHdl(const Link< MoveParagraphsInfo &, void > &rLink)
void SetMinAutoPaperSize(const Size &rSz)
void SetMinColumnWrapHeight(tools::Long nVal)
EDITENG_DLLPRIVATE ParaPortion * FindParaPortion(ContentNode const *pNode)
void SetRefDevice(OutputDevice *pRefDef)
Link< EditView *, void > const & GetEndDropHdl() const
sal_Int32 GetLineLen(sal_Int32 nParagraph, sal_Int32 nLine) const
void InsertContent(ContentNode *pNode, sal_Int32 nPos)
bool HasTriedMergeOnLastAddUndo() const
returns the value last used for bTryMerge while calling ImpEditEngine::InsertUndo This is currently u...
SvtScriptType GetScriptType(const ESelection &rSelection) const
bool IsRightToLeft(sal_Int32 nPara) const
bool IsImportRTFStyleSheetsSet() const
sal_uInt32 CalcTextWidth()
static bool DoesKeyMoveCursor(const KeyEvent &rKeyEvent)
const SfxPoolItem & GetParaAttrib(sal_Int32 nPara, sal_uInt16 nWhich) const
SfxUndoManager * SetUndoManager(SfxUndoManager *pNew)
EDITENG_DLLPRIVATE void HandleBeginPasteOrDrop(PasteOrDropInfos &rInfos)
void InsertFeature(const EditSelection &rEditSelection, const SfxPoolItem &rItem)
void RemoveFields(const std::function< bool(const SvxFieldData *)> &isFieldData=[](const SvxFieldData *){return true;})
void SetTextColumns(sal_Int16 nColumns, sal_Int32 nSpacing)
EditPaM CreateEditPaM(const EPaM &rEPaM)
bool IsUpdateLayout() const
Link< EditView *, void > const & GetBeginDropHdl() const
void SetFlatMode(bool bFlat)
const SfxItemSet & GetEmptyItemSet() const
EDITENG_DLLPRIVATE void CheckIdleFormatter()
void GetLineBoundaries(sal_Int32 &rStart, sal_Int32 &rEnd, sal_Int32 nParagraph, sal_Int32 nLine) const
std::unique_ptr< EditTextObject > GetEmptyTextObject() const
sal_uInt32 GetLineHeight(sal_Int32 nParagraph)
virtual void ParagraphInserted(sal_Int32 nNewParagraph)
EESpellState HasSpellErrors()
OUString GetSelected(const EditSelection &rSel) const
std::vector< EditView * > ViewsType
void ForceAutoColor(bool b)
void SetControlWord(EEControlBits nWord)
SfxStyleSheetPool * GetStyleSheetPool()
sal_Int32 GetLineCount(sal_Int32 nParagraph) const
void ApplyChangedSentence(EditView const &rEditView, const svx::SpellPortions &rNewPortions, bool bRecheck)
void Draw(OutputDevice &rOutDev, const tools::Rectangle &rOutRect)
void QuickMarkToBeRepainted(sal_Int32 nPara)
sal_uInt32 GetTextHeightNTP() const
bool IsCallParaInsertedOrDeleted() const
EDITENG_DLLPRIVATE void CursorMoved(const ContentNode *pPrevNode)
void SetDefaultLanguage(LanguageType eLang)
ParaPortionList & GetParaPortions()
sal_uInt16 GetFieldCount(sal_Int32 nPara) const
EDITENG_DLLPRIVATE bool PostKeyEvent(const KeyEvent &rKeyEvent, EditView *pView, vcl::Window const *pFrameWin)
void SetStatusEventHdl(const Link< EditStatus &, void > &rLink)
EditPaM SplitContent(sal_Int32 nNode, sal_Int32 nSepPos)
void SetPaperSize(const Size &rSize)
void SetStyleSheetPool(SfxStyleSheetPool *pSPool)
void QuickSetAttribs(const SfxItemSet &rSet, const ESelection &rSel)
void CallRtfImportHandler(RtfImportInfo &rInfo)
sal_Int32 GetOverflowingParaNum() const
void QuickInsertText(const OUString &rText, const ESelection &rSel)
void UndoActionStart(sal_uInt16 nId)
const Link< HtmlImportInfo &, void > & GetHtmlImportHdl() const
void FormatAndLayout(EditView *pCurView, bool bCalledFromUndo=false)
Color GetAutoColor() const
void SetLOKSpecialPaperSize(const Size &rSize)
bool HasOnlineSpellErrors() const
void SetBackgroundColor(const Color &rColor)
EditPaM InsertParaBreak(const EditSelection &rEditSelection)
EDITENG_DLLPRIVATE EditPaM GetPaM(const Point &aDocPos, bool bSmart=true)
static bool IsSimpleCharInput(const KeyEvent &rKeyEvent)
EDITENG_DLLPRIVATE EditPaM EndOfWord(const EditPaM &rPaM)
virtual void DrawingTab(const Point &rStartPos, tools::Long nWidth, const OUString &rChar, const SvxFont &rFont, sal_Int32 nPara, sal_uInt8 nRightToLeft, bool bEndOfLine, bool bEndOfParagraph, const Color &rOverlineColor, const Color &rTextLineColor)
static vcl::Font CreateFontFromItemSet(const SfxItemSet &rItemSet, SvtScriptType nScriptType)
void SetNotifyHdl(const Link< EENotify &, void > &rLink)
void SetDefTab(sal_uInt16 nDefTab)
void SetSpeller(css::uno::Reference< css::linguistic2::XSpellChecker1 > const &xSpeller)
std::unique_ptr< ImpEditEngine > pImpEditEngine
LanguageType GetDefaultLanguage() const
void InsertView(EditView *pEditView, size_t nIndex=EE_APPEND)
static SvxFont CreateSvxFontFromItemSet(const SfxItemSet &rItemSet)
virtual bool ConvertNextDocument()
EDITENG_DLLPRIVATE bool HasText() const
const OUString & GetWordDelimiters() const
void SetFixedCellHeight(bool bUseFixedCellHeight)
bool SpellSentence(EditView const &rEditView, svx::SpellPortions &rToFill)
void SetEndPasteOrDropHdl(const Link< PasteOrDropInfos &, void > &rLink)
sal_Int32 GetOverflowingLineNum() const
SvxFont GetStandardSvxFont(sal_Int32 nPara)
EDITENG_DLLPRIVATE EditSelection SelectWord(const EditSelection &rCurSelection, sal_Int16 nWordType=css::i18n::WordType::ANYWORD_IGNOREWHITESPACES)
void ParagraphHeightChanged(sal_Int32 nPara)
static bool HasValidData(const css::uno::Reference< css::datatransfer::XTransferable > &rTransferable)
const Size & GetLOKSpecialPaperSize() const
const SfxStyleSheet * GetStyleSheet(sal_Int32 nPara) const
void SetModifyHdl(const Link< LinkParamNone *, void > &rLink)
void Write(SvStream &rOutput, EETextFormat)
void setGlobalScale(double fFontScaleX, double fFontScaleY, double fSpacingScaleX, double fSpacingScaleY)
void dumpAsXmlEditDoc(xmlTextWriterPtr pWriter) const
void ParaAttribsToCharAttribs(ContentNode *pNode)
EEHorizontalTextDirection GetDefaultHorizontalTextDirection() const
void SetFirstWordCapitalization(bool bCapitalize)
specifies if auto-correction should capitalize the first word or not (default is on)
void SetCallParaInsertedOrDeleted(bool b)
void SetAttribs(const EditSelection &rSel, const SfxItemSet &rSet, SetAttribsMode nSpecial=SetAttribsMode::NONE)
bool IsForceAutoColor() const
void TransliterateText(const ESelection &rSelection, TransliterationFlags nTransliterationMode)
basegfx::B2DTuple getGlobalSpacingScale() const
virtual void SetParaAttribs(sal_Int32 nPara, const SfxItemSet &rSet)
void SetActiveView(EditView *pView)
void GetCharAttribs(sal_Int32 nPara, std::vector< EECharAttrib > &rLst) const
SfxUndoManager & GetUndoManager()
Link< EditStatus &, void > const & GetStatusEventHdl() const
static void SetFontInfoInItemSet(SfxItemSet &rItemSet, const vcl::Font &rFont)
const SfxItemSet & GetParaAttribs(sal_Int32 nPara) const
void SetReplaceLeadingSingleQuotationMark(bool bReplace)
specifies if auto-correction should replace a leading single quotation mark (apostrophe) or not (defa...
static bool DoesKeyChangeText(const KeyEvent &rKeyEvent)
EditPaM InsertLineBreak(const EditSelection &rEditSelection)
EditPaM ConnectParagraphs(ContentNode *pLeft, ContentNode *pRight, bool bBackward)
Point GetDocPosTopLeft(sal_Int32 nParagraph)
EDITENG_DLLPRIVATE Range GetLineXPosStartEnd(const ParaPortion *pParaPortion, const EditLine *pLine) const
bool IsInSelectionMode() const
sal_uInt16 GetHeight() const
sal_uInt16 GetTxtHeight() const
sal_uInt16 GetMaxAscent() const
sal_Int32 GetStartPosX() const
const ContentNode * GetNode() const
sal_Int32 GetIndex() const
void HideCursor(bool bDeactivate=false)
bool IsInsertMode() const
bool HasSelection() const
vcl::Window * GetWindow() const
const tools::Rectangle & GetOutputArea() const
void SetInsertMode(bool bInsert)
void SetAttribs(const SfxItemSet &rSet)
std::unique_ptr< ImpEditView > pImpEditView
static void ShowQuickHelp(vcl::Window *pParent, const tools::Rectangle &rScreenRect, const OUString &rHelpText, QuickHelpFlags nStyle=QuickHelpFlags::NONE)
EditEngine::ViewsType ViewsType
static void SetForbiddenCharsTable(const std::shared_ptr< SvxForbiddenCharactersTable > &xForbiddenChars)
static bool DoVisualCursorTraveling()
sal_Unicode GetCharCode() const
const vcl::KeyCode & GetKeyCode() const
GDIMetaFile * GetConnectMetaFile() const
vcl::Region GetClipRegion() const
SAL_WARN_UNUSED_RESULT Point PixelToLogic(const Point &rDevicePt) const
void DrawRect(const tools::Rectangle &rRect)
bool IsClipRegion() const
SAL_WARN_UNUSED_RESULT Point LogicToPixel(const Point &rLogicPt) const
void Push(vcl::PushFlags nFlags=vcl::PushFlags::ALL)
OutDevType GetOutDevType() const
void IntersectClipRegion(const tools::Rectangle &rRect)
TextPortionList & GetTextPortions()
tools::Long GetHeight() const
void SetMustRepaint(bool bRP)
ContentNode * GetNode() const
EditLineList & GetLines()
void MarkSelectionInvalid(sal_Int32 nStart)
constexpr tools::Long Y() const
void setX(tools::Long nX)
void RotateAround(tools::Long &rX, tools::Long &rY, Degree10 nOrientation) const
void setY(tools::Long nY)
tools::Long AdjustY(tools::Long nVertMove)
tools::Long AdjustX(tools::Long nHorzMove)
constexpr tools::Long X() const
void SetValue(bool const bTheValue)
void SetValue(EnumT nTheValue)
const SfxPoolItem * Put(const SfxPoolItem &rItem, sal_uInt16 nWhich)
const SfxPoolItem & Get(sal_uInt16 nWhich, bool bSrchInParent=true) const
constexpr tools::Long Height() const
constexpr tools::Long Width() const
static bool GetFormatDataFlavor(SotClipboardFormatId nFormat, css::datatransfer::DataFlavor &rFlavor)
static bool IsAutoCorrectChar(sal_Unicode cChar)
SvxColorItem item describes a color.
This item stores a field (SvxFieldData).
This item describes a Font.
sal_uInt8 GetPropr() const
SvxCaseMap GetCaseMap() const
short GetEscapement() const
short GetTextFirstLineOffset() const
tools::Long GetTextLeft() const
B2DPolygon const & getB2DPolygon(sal_uInt32 nIndex) const
FontFamily GetFamilyType()
FontStrikeout GetStrikeout() const
FontLineStyle GetOverline() const
FontRelief GetRelief() const
FontEmphasisMark GetEmphasisMark() const
const OUString & GetFamilyName() const
const Size & GetFontSize() const
LanguageType GetLanguage() const
const Color & GetColor() const
FontLineStyle GetUnderline() const
rtl_TextEncoding GetCharSet() const
bool IsWordLineMode() const
short GetFixKerning() const
const Color & GetFillColor() const
sal_uInt16 GetCode() const
sal_uInt16 GetModifier() const
KeyFuncType GetFunction() const
Point OutputToScreenPixel(const Point &rPos) const
::OutputDevice const * GetOutDev() const
weld::Window * GetFrameWeld() const
constexpr ::Color COL_YELLOW(0xFF, 0xFF, 0x00)
constexpr ::Color COL_LIGHTGREEN(0x00, 0xFF, 0x00)
#define DBG_ASSERT(sCon, aError)
#define EDITUNDO_PARAATTRIBS
@ EE_NOTIFY_PARAGRAPHREMOVED
A paragraph was removed from the EditEngine.
@ EE_NOTIFY_PARAGRAPHINSERTED
A paragraph was inserted into the EditEngine.
@ EE_NOTIFY_TextHeightChanged
The height of at least one paragraph has changed.
#define EDITUNDO_INSERTFEATURE
#define EDITUNDO_MOVEPARAS
#define EDITUNDO_REPLACEALL
#define EDITUNDO_DRAGANDDROP
#define EDITUNDO_INDENTBLOCK
#define EDITUNDO_RESETATTRIBS
#define EDITUNDO_MOVEPARAGRAPHS
#define EDITUNDO_DELCONTENT
#define EDITUNDO_INSERTCHARS
#define EDITUNDO_REMOVECHARS
#define EDITUNDO_SPLITPARA
#define EDITUNDO_STYLESHEET
#define EDITUNDO_UNINDENTBLOCK
#define EDITUNDO_TRANSLITERATE
#define EDITUNDO_CONNECTPARAS
EEHorizontalTextDirection
void CreateFont(SvxFont &rFont, const SfxItemSet &rSet, bool bSearchInParent, SvtScriptType nScriptType)
static rtl::Reference< SfxItemPool > pGlobalPool
constexpr TypedWhichId< SvxContourItem > EE_CHAR_OUTLINE(EE_CHAR_START+8)
constexpr TypedWhichId< SvxKerningItem > EE_CHAR_KERNING(EE_CHAR_START+12)
constexpr TypedWhichId< SvxFieldItem > EE_FEATURE_FIELD(EE_FEATURE_NOTCONV+1)
constexpr TypedWhichId< SfxBoolItem > EE_PARA_BULLETSTATE(EE_PARA_START+9)
constexpr TypedWhichId< SvxUnderlineItem > EE_CHAR_UNDERLINE(EE_CHAR_START+5)
constexpr TypedWhichId< SvxFontHeightItem > EE_CHAR_FONTHEIGHT(EE_CHAR_START+2)
constexpr TypedWhichId< SvxAutoKernItem > EE_CHAR_PAIRKERNING(EE_CHAR_START+11)
constexpr TypedWhichId< SvxShadowedItem > EE_CHAR_SHADOW(EE_CHAR_START+9)
constexpr TypedWhichId< SvxOverlineItem > EE_CHAR_OVERLINE(EE_CHAR_START+29)
constexpr TypedWhichId< SvxWeightItem > EE_CHAR_WEIGHT(EE_CHAR_START+4)
constexpr TypedWhichId< SvxColorItem > EE_CHAR_COLOR(EE_CHAR_START+0)
constexpr TypedWhichId< SvxCrossedOutItem > EE_CHAR_STRIKEOUT(EE_CHAR_START+6)
constexpr TypedWhichId< SvxPostureItem > EE_CHAR_ITALIC(EE_CHAR_START+7)
constexpr TypedWhichId< SvxEmphasisMarkItem > EE_CHAR_EMPHASISMARK(EE_CHAR_START+25)
constexpr TypedWhichId< SvxEscapementItem > EE_CHAR_ESCAPEMENT(EE_CHAR_START+10)
constexpr TypedWhichId< SvxFrameDirectionItem > EE_PARA_WRITINGDIR(EE_PARA_START+0)
constexpr TypedWhichId< SvxCaseMapItem > EE_CHAR_CASEMAP(EE_CHAR_START+30)
constexpr TypedWhichId< SvxColorItem > EE_CHAR_BKGCOLOR(EE_CHAR_START+32)
constexpr TypedWhichId< SvxCharScaleWidthItem > EE_CHAR_FONTWIDTH(EE_CHAR_START+3)
constexpr TypedWhichId< SvxLanguageItem > EE_CHAR_LANGUAGE(EE_CHAR_START+14)
constexpr TypedWhichId< SvxWordLineModeItem > EE_CHAR_WLM(EE_CHAR_START+13)
constexpr TypedWhichId< SvxCharReliefItem > EE_CHAR_RELIEF(EE_CHAR_START+26)
constexpr TypedWhichId< SvxFontItem > EE_CHAR_FONTINFO(EE_CHAR_START+1)
OUString EditResId(TranslateId aId)
struct _xmlTextWriter * xmlTextWriterPtr
@ Horizontal_RL_TB
Horizontal, from right to left, from top to bottom (typical for arabic/hebrew languages).
@ Horizontal_LR_TB
Horizontal, from left to right, from top to bottom (typical for western languages).
#define TRAVEL_X_DONTKNOW
#define CURSOR_BIDILEVEL_DONTKNOW
GetAttribsFlags
values for: SfxItemSet GetAttribs( sal_Int32 nPara, sal_Int32 nStart, sal_Int32 nEnd,...
EditEngineAttribs
values for: SfxItemSet GetAttribs( const ESelection& rSel, EditEngineAttribs nOnlyHardAttrib = EditEn...
constexpr sal_uInt16 KEY_RETURN
constexpr sal_uInt16 KEY_MOD2
constexpr sal_uInt16 KEY_MOD1
constexpr sal_uInt16 KEY_HOME
constexpr sal_uInt16 KEY_LEFT
constexpr sal_uInt16 KEY_PAGEDOWN
constexpr sal_uInt16 KEY_TAB
constexpr sal_uInt16 KEY_UP
constexpr sal_uInt16 KEY_F1
constexpr sal_uInt16 KEY_RIGHT
constexpr sal_uInt16 KEY_DELETE
constexpr sal_uInt16 KEY_F12
constexpr sal_uInt16 KEY_DOWN
constexpr sal_uInt16 KEY_PAGEUP
constexpr sal_uInt16 KEY_F11
constexpr sal_uInt16 KEY_W
constexpr sal_uInt16 KEY_INSERT
constexpr sal_uInt16 KEY_BACKSPACE
constexpr sal_uInt16 KEY_END
#define SAL_WARN_IF(condition, area, stream)
std::vector< WrongSpellClass > WrongSpellVector
tools::Long const nBorder
void set(css::uno::UnoInterfaceReference const &value)
Reference< XComponentContext > getProcessComponentContext()
Reference< XComponentContext > getComponentContext(Reference< XMultiServiceFactory > const &factory)
constexpr std::enable_if_t< std::is_signed_v< T >, std::make_unsigned_t< T > > make_unsigned(T value)
std::vector< SpellPortion > SpellPortions
const LocaleDataWrapper & GetLocaleData()
Sequence< Property > aInfos
std::unique_ptr< SvxFieldItem > pFieldItem
EFieldInfo & operator=(const EFieldInfo &)
css::uno::Reference< css::datatransfer::clipboard::XClipboard > VCL_DLLPUBLIC GetSystemPrimarySelection()