1*cdf0e10cSrcweir /************************************************************************* 2*cdf0e10cSrcweir * 3*cdf0e10cSrcweir * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4*cdf0e10cSrcweir * 5*cdf0e10cSrcweir * Copyright 2000, 2010 Oracle and/or its affiliates. 6*cdf0e10cSrcweir * 7*cdf0e10cSrcweir * OpenOffice.org - a multi-platform office productivity suite 8*cdf0e10cSrcweir * 9*cdf0e10cSrcweir * This file is part of OpenOffice.org. 10*cdf0e10cSrcweir * 11*cdf0e10cSrcweir * OpenOffice.org is free software: you can redistribute it and/or modify 12*cdf0e10cSrcweir * it under the terms of the GNU Lesser General Public License version 3 13*cdf0e10cSrcweir * only, as published by the Free Software Foundation. 14*cdf0e10cSrcweir * 15*cdf0e10cSrcweir * OpenOffice.org is distributed in the hope that it will be useful, 16*cdf0e10cSrcweir * but WITHOUT ANY WARRANTY; without even the implied warranty of 17*cdf0e10cSrcweir * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 18*cdf0e10cSrcweir * GNU Lesser General Public License version 3 for more details 19*cdf0e10cSrcweir * (a copy is included in the LICENSE file that accompanied this code). 20*cdf0e10cSrcweir * 21*cdf0e10cSrcweir * You should have received a copy of the GNU Lesser General Public License 22*cdf0e10cSrcweir * version 3 along with OpenOffice.org. If not, see 23*cdf0e10cSrcweir * <http://www.openoffice.org/license.html> 24*cdf0e10cSrcweir * for a copy of the LGPLv3 License. 25*cdf0e10cSrcweir * 26*cdf0e10cSrcweir ************************************************************************/ 27*cdf0e10cSrcweir #ifndef SW_CRSRSH_HXX 28*cdf0e10cSrcweir #define SW_CRSRSH_HXX 29*cdf0e10cSrcweir 30*cdf0e10cSrcweir #include <com/sun/star/i18n/WordType.hpp> 31*cdf0e10cSrcweir 32*cdf0e10cSrcweir #include <tools/string.hxx> 33*cdf0e10cSrcweir #include <tools/link.hxx> 34*cdf0e10cSrcweir #include <tools/rtti.hxx> 35*cdf0e10cSrcweir 36*cdf0e10cSrcweir #include <IShellCursorSupplier.hxx> 37*cdf0e10cSrcweir #include "swdllapi.h" 38*cdf0e10cSrcweir #include <swtypes.hxx> // fuer SWPOSDOC 39*cdf0e10cSrcweir #include <viewsh.hxx> // fuer ViewShell 40*cdf0e10cSrcweir #include <calbck.hxx> // fuer SwClient 41*cdf0e10cSrcweir #include <cshtyp.hxx> // fuer die CursorShell Typen 42*cdf0e10cSrcweir #include <crstate.hxx> // fuer die CursorMove-Staties 43*cdf0e10cSrcweir #include <toxe.hxx> // SwTOXSearchDir 44*cdf0e10cSrcweir #include <tblsel.hxx> //SwTblSearchType 45*cdf0e10cSrcweir #include <viscrs.hxx> 46*cdf0e10cSrcweir #include <node.hxx> 47*cdf0e10cSrcweir #include <tblsel.hxx> 48*cdf0e10cSrcweir #include <IDocumentMarkAccess.hxx> 49*cdf0e10cSrcweir 50*cdf0e10cSrcweir 51*cdf0e10cSrcweir // einige Forward Deklarationen 52*cdf0e10cSrcweir 53*cdf0e10cSrcweir class KeyCode; 54*cdf0e10cSrcweir class SfxItemSet; 55*cdf0e10cSrcweir class SfxPoolItem; 56*cdf0e10cSrcweir class SwCntntFrm; 57*cdf0e10cSrcweir class SwCrsrShell; 58*cdf0e10cSrcweir class SwCursor; 59*cdf0e10cSrcweir class SwField; 60*cdf0e10cSrcweir class SwFieldType; 61*cdf0e10cSrcweir class SwFmt; 62*cdf0e10cSrcweir class SwFmtFld; 63*cdf0e10cSrcweir class SwNodeIndex; 64*cdf0e10cSrcweir class SwPaM; 65*cdf0e10cSrcweir class SwShellCrsr; 66*cdf0e10cSrcweir class SwShellTableCrsr; 67*cdf0e10cSrcweir class SwTableNode; 68*cdf0e10cSrcweir class SwTxtFmtColl; 69*cdf0e10cSrcweir class SwVisCrsr; 70*cdf0e10cSrcweir class SwTxtINetFmt; 71*cdf0e10cSrcweir class SwFmtINetFmt; 72*cdf0e10cSrcweir class SwTxtAttr; 73*cdf0e10cSrcweir class SwTableBox; 74*cdf0e10cSrcweir class SwCellFrms; 75*cdf0e10cSrcweir class SwTOXMark; 76*cdf0e10cSrcweir class SwRedline; 77*cdf0e10cSrcweir class IBlockCursor; 78*cdf0e10cSrcweir class SwCntntNode; // #i23726# 79*cdf0e10cSrcweir // --> OD 2008-06-19 #i90516# 80*cdf0e10cSrcweir class SwPostItField; 81*cdf0e10cSrcweir // <-- 82*cdf0e10cSrcweir struct SwPosition; 83*cdf0e10cSrcweir 84*cdf0e10cSrcweir namespace com { namespace sun { namespace star { namespace util { 85*cdf0e10cSrcweir struct SearchOptions; 86*cdf0e10cSrcweir } } } } 87*cdf0e10cSrcweir 88*cdf0e10cSrcweir namespace com { namespace sun { namespace star { namespace text { 89*cdf0e10cSrcweir class XTextRange; 90*cdf0e10cSrcweir }}}} 91*cdf0e10cSrcweir 92*cdf0e10cSrcweir namespace com { namespace sun { namespace star { namespace container { 93*cdf0e10cSrcweir class XStringKeyMap; 94*cdf0e10cSrcweir }}}} 95*cdf0e10cSrcweir 96*cdf0e10cSrcweir // enum und struktur, um ueber die Doc-Position Informationen zu erfragen 97*cdf0e10cSrcweir 98*cdf0e10cSrcweir struct SwContentAtPos 99*cdf0e10cSrcweir { 100*cdf0e10cSrcweir enum IsAttrAtPos 101*cdf0e10cSrcweir { 102*cdf0e10cSrcweir SW_NOTHING = 0x0000, 103*cdf0e10cSrcweir SW_FIELD = 0x0001, 104*cdf0e10cSrcweir SW_CLICKFIELD = 0x0002, 105*cdf0e10cSrcweir SW_FTN = 0x0004, 106*cdf0e10cSrcweir SW_INETATTR = 0x0008, 107*cdf0e10cSrcweir SW_TABLEBOXFML = 0x0010, 108*cdf0e10cSrcweir SW_REDLINE = 0x0020, 109*cdf0e10cSrcweir SW_OUTLINE = 0x0040, 110*cdf0e10cSrcweir SW_TOXMARK = 0x0080, 111*cdf0e10cSrcweir SW_REFMARK = 0x0100, 112*cdf0e10cSrcweir SW_NUMLABEL = 0x0200, // #i23726# 113*cdf0e10cSrcweir SW_CONTENT_CHECK = 0x0400, // --> FME 2005-05-13 #i43742# <-- 114*cdf0e10cSrcweir SW_SMARTTAG = 0x0800, 115*cdf0e10cSrcweir SW_FORMCTRL = 0x1000 116*cdf0e10cSrcweir #ifndef PRODUCT 117*cdf0e10cSrcweir ,SW_CURR_ATTRS = 0x4000 // nur zum Debuggen 118*cdf0e10cSrcweir ,SW_TABLEBOXVALUE = 0x8000 // nur zum Debuggen 119*cdf0e10cSrcweir #endif 120*cdf0e10cSrcweir } eCntntAtPos; 121*cdf0e10cSrcweir 122*cdf0e10cSrcweir union { 123*cdf0e10cSrcweir const SwField* pFld; 124*cdf0e10cSrcweir const SfxPoolItem* pAttr; 125*cdf0e10cSrcweir const SwRedline* pRedl; 126*cdf0e10cSrcweir SwCntntNode * pNode; // #i23726# 127*cdf0e10cSrcweir const sw::mark::IFieldmark* pFldmark; 128*cdf0e10cSrcweir } aFnd; 129*cdf0e10cSrcweir 130*cdf0e10cSrcweir int nDist; // #i23726# 131*cdf0e10cSrcweir 132*cdf0e10cSrcweir String sStr; 133*cdf0e10cSrcweir const SwTxtAttr* pFndTxtAttr; 134*cdf0e10cSrcweir 135*cdf0e10cSrcweir SwContentAtPos( int eGetAtPos = 0xffff ) 136*cdf0e10cSrcweir : eCntntAtPos( (IsAttrAtPos)eGetAtPos ) 137*cdf0e10cSrcweir { 138*cdf0e10cSrcweir aFnd.pFld = 0; 139*cdf0e10cSrcweir pFndTxtAttr = 0; 140*cdf0e10cSrcweir nDist = 0; // #i23726# 141*cdf0e10cSrcweir } 142*cdf0e10cSrcweir 143*cdf0e10cSrcweir // befindet sich der Node in einem geschuetzten Bereich? 144*cdf0e10cSrcweir sal_Bool IsInProtectSect() const; 145*cdf0e10cSrcweir bool IsInRTLText()const; 146*cdf0e10cSrcweir }; 147*cdf0e10cSrcweir 148*cdf0e10cSrcweir // ReturnWerte von SetCrsr (werden verodert) 149*cdf0e10cSrcweir const int CRSR_POSOLD = 0x01, // Cursor bleibt an alter Doc-Position 150*cdf0e10cSrcweir CRSR_POSCHG = 0x02; // Position vom Layout veraendert 151*cdf0e10cSrcweir 152*cdf0e10cSrcweir // Helperfunction to resolve backward references in regular expressions 153*cdf0e10cSrcweir 154*cdf0e10cSrcweir String *ReplaceBackReferences( const com::sun::star::util::SearchOptions& rSearchOpt, SwPaM* pPam ); 155*cdf0e10cSrcweir 156*cdf0e10cSrcweir // die Cursor - Shell 157*cdf0e10cSrcweir class SW_DLLPUBLIC SwCrsrShell 158*cdf0e10cSrcweir : public ViewShell 159*cdf0e10cSrcweir , public SwModify 160*cdf0e10cSrcweir , public ::sw::IShellCursorSupplier 161*cdf0e10cSrcweir { 162*cdf0e10cSrcweir friend class SwCallLink; 163*cdf0e10cSrcweir friend class SwVisCrsr; 164*cdf0e10cSrcweir friend class SwSelPaintRects; 165*cdf0e10cSrcweir friend class SwChgLinkFlag; 166*cdf0e10cSrcweir 167*cdf0e10cSrcweir //Braucht den Crsr als IntrnlCrsr. 168*cdf0e10cSrcweir friend sal_Bool GetAutoSumSel( const SwCrsrShell&, SwCellFrms& ); 169*cdf0e10cSrcweir 170*cdf0e10cSrcweir public: // public, damit defaultet werden kann !! 171*cdf0e10cSrcweir 172*cdf0e10cSrcweir /* ein enum fuer den Aufruf von UpdateCrsr */ 173*cdf0e10cSrcweir enum CrsrFlag { 174*cdf0e10cSrcweir UPDOWN = (1 << 0), // Up/Down auf Spalte halten 175*cdf0e10cSrcweir SCROLLWIN = (1 << 1), // Window Scrollen 176*cdf0e10cSrcweir CHKRANGE = (1 << 2), // ueberpruefen von ueberlappenden PaM's 177*cdf0e10cSrcweir NOCALRECT = (1 << 3), // CharRect nicht neu berechnen 178*cdf0e10cSrcweir READONLY = (1 << 4) // Sichtbar machen trotz Readonly 179*cdf0e10cSrcweir }; 180*cdf0e10cSrcweir 181*cdf0e10cSrcweir private: 182*cdf0e10cSrcweir 183*cdf0e10cSrcweir SwRect aCharRect; // Char-SRectangle auf dem der Cursor steht 184*cdf0e10cSrcweir Point aCrsrHeight; // Hohe&Offset von sichtbaren Cursor 185*cdf0e10cSrcweir Point aOldRBPos; // Right/Bottom von letzter VisArea 186*cdf0e10cSrcweir // (wird im Invalidate vom Cursor benutzt) 187*cdf0e10cSrcweir 188*cdf0e10cSrcweir 189*cdf0e10cSrcweir // um event. Macro was anhaengt auszufuehren. 190*cdf0e10cSrcweir Link aFlyMacroLnk; // Link will be called, if the Crsr is set 191*cdf0e10cSrcweir // into a fly. A macro can be then becalled 192*cdf0e10cSrcweir Link aChgLnk; // link will be called by every attribut/ 193*cdf0e10cSrcweir // format changes at cursor position. 194*cdf0e10cSrcweir Link aGrfArrivedLnk; // Link calls to UI if a grafik is arrived 195*cdf0e10cSrcweir 196*cdf0e10cSrcweir 197*cdf0e10cSrcweir SwShellCrsr* pCurCrsr; // der aktuelle Cursor 198*cdf0e10cSrcweir SwShellCrsr* pCrsrStk; // Stack fuer den Cursor 199*cdf0e10cSrcweir SwVisCrsr *pVisCrsr; // der Sichtbare-Cursor 200*cdf0e10cSrcweir 201*cdf0e10cSrcweir IBlockCursor *pBlockCrsr; // interface of cursor for block (=rectangular) selection 202*cdf0e10cSrcweir 203*cdf0e10cSrcweir SwShellTableCrsr* pTblCrsr; // Tabellen-Crsr; nur in Tabellen, wenn 204*cdf0e10cSrcweir // die Selection ueber 2 Spalten liegt 205*cdf0e10cSrcweir 206*cdf0e10cSrcweir SwNodeIndex* pBoxIdx; // fuers erkennen der veraenderten 207*cdf0e10cSrcweir SwTableBox* pBoxPtr; // Tabellen-Zelle 208*cdf0e10cSrcweir 209*cdf0e10cSrcweir long nUpDownX; // versuche den Cursor bei Up/Down immer in 210*cdf0e10cSrcweir // der gleichen Spalte zu bewegen 211*cdf0e10cSrcweir long nLeftFrmPos; 212*cdf0e10cSrcweir sal_uLong nAktNode; // save CursorPos at Start-Action 213*cdf0e10cSrcweir xub_StrLen nAktCntnt; 214*cdf0e10cSrcweir sal_uInt16 nAktNdTyp; 215*cdf0e10cSrcweir bool bAktSelection; 216*cdf0e10cSrcweir 217*cdf0e10cSrcweir /* 218*cdf0e10cSrcweir * Mit den Methoden SttCrsrMove und EndCrsrMove wird dieser Zaehler 219*cdf0e10cSrcweir * Inc-/Decrementiert. Solange der Zaehler ungleich 0 ist, erfolgt 220*cdf0e10cSrcweir * auf den akt. Cursor kein Update. Dadurch koennen "komplizierte" 221*cdf0e10cSrcweir * Cursorbewegungen (ueber Find()) realisiert werden. 222*cdf0e10cSrcweir */ 223*cdf0e10cSrcweir sal_uInt16 nCrsrMove; 224*cdf0e10cSrcweir sal_uInt16 nBasicActionCnt; // Actions, die vom Basic geklammert wurden 225*cdf0e10cSrcweir CrsrMoveState eMvState; // Status fuers Crsr-Travelling - GetCrsrOfst 226*cdf0e10cSrcweir 227*cdf0e10cSrcweir // --> OD 2008-04-02 #refactorlists# 228*cdf0e10cSrcweir String sMarkedListId; 229*cdf0e10cSrcweir int nMarkedListLevel; 230*cdf0e10cSrcweir // <-- 231*cdf0e10cSrcweir 232*cdf0e10cSrcweir sal_Bool bHasFocus : 1; // Shell ist in einem Window "aktiv" 233*cdf0e10cSrcweir sal_Bool bSVCrsrVis : 1; // SV-Cursor Un-/Sichtbar 234*cdf0e10cSrcweir sal_Bool bChgCallFlag : 1; // Attributaenderung innerhalb von 235*cdf0e10cSrcweir // Start- und EndAction 236*cdf0e10cSrcweir sal_Bool bVisPortChgd : 1; // befindet sich im VisPortChg-Aufruf 237*cdf0e10cSrcweir // (wird im Invalidate vom Cursor benutzt) 238*cdf0e10cSrcweir 239*cdf0e10cSrcweir sal_Bool bCallChgLnk : 1; // Flag fuer abgeleitete Klassen: 240*cdf0e10cSrcweir // sal_True -> ChgLnk callen 241*cdf0e10cSrcweir // Zugriff nur ueber SwChgLinkFlag 242*cdf0e10cSrcweir sal_Bool bAllProtect : 1; // Flag fuer Bereiche 243*cdf0e10cSrcweir // sal_True -> alles geschuetzt / versteckt 244*cdf0e10cSrcweir sal_Bool bInCMvVisportChgd : 1; // Flag fuer CrsrMoves 245*cdf0e10cSrcweir // sal_True -> die Sicht wurde verschoben 246*cdf0e10cSrcweir sal_Bool bGCAttr : 1; // sal_True -> es existieren nichtaufgespannte Attr. 247*cdf0e10cSrcweir sal_Bool bIgnoreReadonly : 1; // sal_True -> Beim naechsten EndAction trotz 248*cdf0e10cSrcweir // Readonly den Crsr sichtbar machen. 249*cdf0e10cSrcweir sal_Bool bSelTblCells : 1; // sal_True -> Zellen uebers InputWin selektieren 250*cdf0e10cSrcweir sal_Bool bAutoUpdateCells : 1; // sal_True -> Zellen werden autoformatiert 251*cdf0e10cSrcweir sal_Bool bBasicHideCrsr : 1; // sal_True -> HideCrsr vom Basic 252*cdf0e10cSrcweir sal_Bool bSetCrsrInReadOnly : 1;// sal_True -> Cursor darf in ReadOnly-Bereiche 253*cdf0e10cSrcweir sal_Bool bOverwriteCrsr : 1; // sal_True -> show Overwrite Crsr 254*cdf0e10cSrcweir 255*cdf0e10cSrcweir // OD 11.02.2003 #100556# - flag to allow/avoid execution of marcos (default: true) 256*cdf0e10cSrcweir bool mbMacroExecAllowed : 1; 257*cdf0e10cSrcweir 258*cdf0e10cSrcweir SW_DLLPRIVATE void UpdateCrsr( sal_uInt16 eFlags 259*cdf0e10cSrcweir =SwCrsrShell::SCROLLWIN|SwCrsrShell::CHKRANGE, 260*cdf0e10cSrcweir sal_Bool bIdleEnd = sal_False ); 261*cdf0e10cSrcweir 262*cdf0e10cSrcweir SW_DLLPRIVATE void _ParkPams( SwPaM* pDelRg, SwShellCrsr** ppDelRing ); 263*cdf0e10cSrcweir 264*cdf0e10cSrcweir // -> #i27615# 265*cdf0e10cSrcweir 266*cdf0e10cSrcweir /** Mark a certain list level of a certain list 267*cdf0e10cSrcweir 268*cdf0e10cSrcweir OD 2008-04-02 #refactorlists# 269*cdf0e10cSrcweir levels of a certain lists are marked now 270*cdf0e10cSrcweir 271*cdf0e10cSrcweir @param sListId list Id of the list whose level is marked 272*cdf0e10cSrcweir @param nLevel to be marked list level 273*cdf0e10cSrcweir 274*cdf0e10cSrcweir An empty sListId denotes that no level of a list is marked. 275*cdf0e10cSrcweir */ 276*cdf0e10cSrcweir SW_DLLPRIVATE void MarkListLevel( const String& sListId, 277*cdf0e10cSrcweir const int nLevel ); 278*cdf0e10cSrcweir // <- #i27615# 279*cdf0e10cSrcweir 280*cdf0e10cSrcweir // private method(s) accessed from public inline method(s) must be exported. 281*cdf0e10cSrcweir sal_Bool LeftRight( sal_Bool, sal_uInt16, sal_uInt16, sal_Bool ); 282*cdf0e10cSrcweir SW_DLLPRIVATE sal_Bool UpDown( sal_Bool, sal_uInt16 ); 283*cdf0e10cSrcweir SW_DLLPRIVATE sal_Bool LRMargin( sal_Bool, sal_Bool bAPI = sal_False ); 284*cdf0e10cSrcweir SW_DLLPRIVATE sal_Bool IsAtLRMargin( sal_Bool, sal_Bool bAPI = sal_False ) const; 285*cdf0e10cSrcweir 286*cdf0e10cSrcweir SW_DLLPRIVATE short GetTextDirection( const Point* pPt = 0 ) const; 287*cdf0e10cSrcweir 288*cdf0e10cSrcweir typedef sal_Bool (SwCursor:: *FNCrsr)(); 289*cdf0e10cSrcweir SW_DLLPRIVATE sal_Bool CallCrsrFN( FNCrsr ); 290*cdf0e10cSrcweir 291*cdf0e10cSrcweir SW_DLLPRIVATE const SwRedline* _GotoRedline( sal_uInt16 nArrPos, sal_Bool bSelect ); 292*cdf0e10cSrcweir 293*cdf0e10cSrcweir protected: 294*cdf0e10cSrcweir 295*cdf0e10cSrcweir inline SwMoveFnCollection* MakeFindRange( sal_uInt16, sal_uInt16, SwPaM* ) const; 296*cdf0e10cSrcweir 297*cdf0e10cSrcweir /* 298*cdf0e10cSrcweir * Compare-Methode for the StackCursor and the current Cursor. 299*cdf0e10cSrcweir * The Methods return -1, 0, 1 for lower, equal, greater. The enum 300*cdf0e10cSrcweir * CrsrCompareType says which position is compared. 301*cdf0e10cSrcweir */ 302*cdf0e10cSrcweir enum CrsrCompareType { 303*cdf0e10cSrcweir StackPtStackMk, 304*cdf0e10cSrcweir StackPtCurrPt, 305*cdf0e10cSrcweir StackPtCurrMk, 306*cdf0e10cSrcweir StackMkCurrPt, 307*cdf0e10cSrcweir StackMkCurrMk, 308*cdf0e10cSrcweir CurrPtCurrMk 309*cdf0e10cSrcweir }; 310*cdf0e10cSrcweir int CompareCursor( CrsrCompareType eType ) const; 311*cdf0e10cSrcweir 312*cdf0e10cSrcweir // Setzt alle PaMs in OldNode auf NewPos + Offset 313*cdf0e10cSrcweir void PaMCorrAbs(const SwNodeIndex &rOldNode, const SwPosition &rNewPos, 314*cdf0e10cSrcweir const xub_StrLen nOffset = 0 ); 315*cdf0e10cSrcweir 316*cdf0e10cSrcweir // --> FME 2004-07-30 #i32329# Enhanced table selection 317*cdf0e10cSrcweir sal_Bool _SelTblRowOrCol( bool bRow, bool bRowSimple = false ); 318*cdf0e10cSrcweir // <-- 319*cdf0e10cSrcweir 320*cdf0e10cSrcweir // --> FME 2005-01-31 #i41424# Only update the marked number levels if necessary 321*cdf0e10cSrcweir bool SetInFrontOfLabel( sal_Bool bNew ); 322*cdf0e10cSrcweir // <-- 323*cdf0e10cSrcweir 324*cdf0e10cSrcweir void RefreshBlockCursor(); 325*cdf0e10cSrcweir 326*cdf0e10cSrcweir /** Updates the marked list level according to the cursor. 327*cdf0e10cSrcweir */ 328*cdf0e10cSrcweir SW_DLLPRIVATE void UpdateMarkedListLevel(); 329*cdf0e10cSrcweir 330*cdf0e10cSrcweir protected: 331*cdf0e10cSrcweir virtual void Modify( const SfxPoolItem* pOld, const SfxPoolItem *pNew); 332*cdf0e10cSrcweir 333*cdf0e10cSrcweir public: 334*cdf0e10cSrcweir TYPEINFO(); 335*cdf0e10cSrcweir SwCrsrShell( SwDoc& rDoc, Window *pWin, const SwViewOption *pOpt = 0 ); 336*cdf0e10cSrcweir // verkleideter Copy-Constructor 337*cdf0e10cSrcweir SwCrsrShell( SwCrsrShell& rShell, Window *pWin ); 338*cdf0e10cSrcweir virtual ~SwCrsrShell(); 339*cdf0e10cSrcweir 340*cdf0e10cSrcweir // IShellCursorSupplier 341*cdf0e10cSrcweir virtual SwPaM & CreateNewShellCursor(); 342*cdf0e10cSrcweir virtual SwPaM & GetCurrentShellCursor(); 343*cdf0e10cSrcweir 344*cdf0e10cSrcweir // neuen Cusror erzeugen und den alten anhaengen 345*cdf0e10cSrcweir SwPaM * CreateCrsr(); 346*cdf0e10cSrcweir // loesche den aktuellen Cursor und der folgende wird zum Aktuellen 347*cdf0e10cSrcweir sal_Bool DestroyCrsr(); 348*cdf0e10cSrcweir // TableCursor in normale Cursor verwandeln, Tablemode aufheben 349*cdf0e10cSrcweir void TblCrsrToCursor(); 350*cdf0e10cSrcweir // enter block mode, change normal cursor into block cursor 351*cdf0e10cSrcweir void CrsrToBlockCrsr(); 352*cdf0e10cSrcweir // leave block mode, change block cursor into normal cursor 353*cdf0e10cSrcweir void BlockCrsrToCrsr(); 354*cdf0e10cSrcweir 355*cdf0e10cSrcweir // SelAll() selects the document body content 356*cdf0e10cSrcweir // if ExtendedSelect() is called afterwards, the whole nodes array is selected 357*cdf0e10cSrcweir // only for usage in special cases allowed! 358*cdf0e10cSrcweir void ExtendedSelectAll(); 359*cdf0e10cSrcweir 360*cdf0e10cSrcweir SwPaM* GetCrsr( sal_Bool bMakeTblCrsr = sal_True ) const; 361*cdf0e10cSrcweir inline SwCursor* GetSwCrsr( sal_Bool bMakeTblCrsr = sal_True ) const; 362*cdf0e10cSrcweir // nur den akt. Cursor returnen 363*cdf0e10cSrcweir SwShellCrsr* _GetCrsr() { return pCurCrsr; } 364*cdf0e10cSrcweir const SwShellCrsr* _GetCrsr() const { return pCurCrsr; } 365*cdf0e10cSrcweir 366*cdf0e10cSrcweir // uebergebenen Cursor anzeigen - fuer UNO 367*cdf0e10cSrcweir void SetSelection(const SwPaM& rCrsr); 368*cdf0e10cSrcweir 369*cdf0e10cSrcweir // alle Cursor aus den ContentNodes entfernen und auf 0 setzen. 370*cdf0e10cSrcweir // Wurde aus der FEShell hierher verschoben. 371*cdf0e10cSrcweir void ParkCrsr( const SwNodeIndex &rIdx ); 372*cdf0e10cSrcweir 373*cdf0e10cSrcweir // gebe den akt. Cursor-Stack zurueck. 374*cdf0e10cSrcweir // ( Wird in der EditShell beim Loeschen von Inhalten benoetigt! ) 375*cdf0e10cSrcweir inline SwPaM* GetStkCrsr() const; 376*cdf0e10cSrcweir 377*cdf0e10cSrcweir // Start der Klammerung, SV-Cursor und selektierte Bereiche hiden 378*cdf0e10cSrcweir void StartAction(); 379*cdf0e10cSrcweir // Ende der Klammerung, SV-Cursor und selektierte Bereiche anzeigen 380*cdf0e10cSrcweir void EndAction( const sal_Bool bIdleEnd = sal_False ); 381*cdf0e10cSrcweir 382*cdf0e10cSrcweir // Basiscursortravelling 383*cdf0e10cSrcweir long GetUpDownX() const { return nUpDownX; } 384*cdf0e10cSrcweir 385*cdf0e10cSrcweir sal_Bool Left( sal_uInt16 nCnt, sal_uInt16 nMode, sal_Bool bAllowVisual = sal_False ) 386*cdf0e10cSrcweir { return LeftRight( sal_True, nCnt, nMode, bAllowVisual ); } 387*cdf0e10cSrcweir sal_Bool Right( sal_uInt16 nCnt, sal_uInt16 nMode, sal_Bool bAllowVisual = sal_False ) 388*cdf0e10cSrcweir { return LeftRight( sal_False, nCnt, nMode, bAllowVisual ); } 389*cdf0e10cSrcweir sal_Bool Up( sal_uInt16 nCnt = 1 ) { return UpDown( sal_True, nCnt ); } 390*cdf0e10cSrcweir sal_Bool Down( sal_uInt16 nCnt = 1 ) { return UpDown( sal_False, nCnt ); } 391*cdf0e10cSrcweir sal_Bool LeftMargin() { return LRMargin( sal_True ); } 392*cdf0e10cSrcweir sal_Bool RightMargin(sal_Bool bAPI = sal_False) { return LRMargin( sal_False, bAPI ); } 393*cdf0e10cSrcweir sal_Bool SttEndDoc( sal_Bool bStt ); 394*cdf0e10cSrcweir 395*cdf0e10cSrcweir sal_Bool MovePage( SwWhichPage, SwPosPage ); 396*cdf0e10cSrcweir sal_Bool MovePara( SwWhichPara, SwPosPara ); 397*cdf0e10cSrcweir sal_Bool MoveSection( SwWhichSection, SwPosSection ); 398*cdf0e10cSrcweir sal_Bool MoveTable( SwWhichTable, SwPosTable ); 399*cdf0e10cSrcweir sal_Bool MoveColumn( SwWhichColumn, SwPosColumn ); 400*cdf0e10cSrcweir sal_Bool MoveRegion( SwWhichRegion, SwPosRegion ); 401*cdf0e10cSrcweir 402*cdf0e10cSrcweir // die Suchfunktionen 403*cdf0e10cSrcweir sal_uLong Find( const com::sun::star::util::SearchOptions& rSearchOpt, 404*cdf0e10cSrcweir sal_Bool bSearchInNotes, 405*cdf0e10cSrcweir SwDocPositions eStart, SwDocPositions eEnde, 406*cdf0e10cSrcweir sal_Bool& bCancel, 407*cdf0e10cSrcweir FindRanges eRng, int bReplace = sal_False ); 408*cdf0e10cSrcweir 409*cdf0e10cSrcweir sal_uLong Find( const SwTxtFmtColl& rFmtColl, 410*cdf0e10cSrcweir SwDocPositions eStart, SwDocPositions eEnde, 411*cdf0e10cSrcweir sal_Bool& bCancel, 412*cdf0e10cSrcweir FindRanges eRng, const SwTxtFmtColl* pReplFmt = 0 ); 413*cdf0e10cSrcweir 414*cdf0e10cSrcweir sal_uLong Find( const SfxItemSet& rSet, sal_Bool bNoCollections, 415*cdf0e10cSrcweir SwDocPositions eStart, SwDocPositions eEnde, 416*cdf0e10cSrcweir sal_Bool& bCancel, 417*cdf0e10cSrcweir FindRanges eRng, 418*cdf0e10cSrcweir const com::sun::star::util::SearchOptions* pSearchOpt = 0, 419*cdf0e10cSrcweir const SfxItemSet* rReplSet = 0 ); 420*cdf0e10cSrcweir 421*cdf0e10cSrcweir // Positionieren des Cursors 422*cdf0e10cSrcweir // returnt 423*cdf0e10cSrcweir // CRSR_POSCHG: wenn der ob der SPoint vom Layout korrigiert wurde. 424*cdf0e10cSrcweir // CRSR_POSOLD: wenn der Crsr nicht veraendert wurde 425*cdf0e10cSrcweir int SetCrsr( const Point &rPt, sal_Bool bOnlyText = sal_False, bool bBlock = true ); 426*cdf0e10cSrcweir 427*cdf0e10cSrcweir 428*cdf0e10cSrcweir /* 429*cdf0e10cSrcweir * Benachrichtung, dass der sichtbare Bereich sich geaendert 430*cdf0e10cSrcweir * hat. aVisArea wird neu gesetzt, anschliessend wird 431*cdf0e10cSrcweir * gescrollt. Das uebergebene Rectangle liegt auf 432*cdf0e10cSrcweir * Pixelgrenzen, um Pixelfehler beim Scrollen zu vermeiden. 433*cdf0e10cSrcweir */ 434*cdf0e10cSrcweir virtual void VisPortChgd( const SwRect & ); 435*cdf0e10cSrcweir 436*cdf0e10cSrcweir /* 437*cdf0e10cSrcweir * Virtuelle PaintMethode, damit die Selection nach dem Paint wieder 438*cdf0e10cSrcweir * sichtbar wird. 439*cdf0e10cSrcweir */ 440*cdf0e10cSrcweir void Paint( const Rectangle & rRect ); 441*cdf0e10cSrcweir 442*cdf0e10cSrcweir // Bereiche 443*cdf0e10cSrcweir inline void SetMark(); 444*cdf0e10cSrcweir inline sal_Bool HasMark(); 445*cdf0e10cSrcweir 446*cdf0e10cSrcweir void ClearMark(); 447*cdf0e10cSrcweir 448*cdf0e10cSrcweir /** 449*cdf0e10cSrcweir Ensure point and mark of the current PaM are in a specific order. 450*cdf0e10cSrcweir 451*cdf0e10cSrcweir @param bPointFirst TRUE: If the point is behind the mark then 452*cdf0e10cSrcweir swap the PaM. FALSE: If the mark is behind the point then swap 453*cdf0e10cSrcweir the PaM. 454*cdf0e10cSrcweir */ 455*cdf0e10cSrcweir void NormalizePam(sal_Bool bPointFirst = sal_True); 456*cdf0e10cSrcweir 457*cdf0e10cSrcweir void SwapPam(); 458*cdf0e10cSrcweir sal_Bool ChgCurrPam( const Point & rPt, 459*cdf0e10cSrcweir sal_Bool bTstOnly = sal_True, //Nur testen, nicht setzen 460*cdf0e10cSrcweir sal_Bool bTstHit = sal_False ); //Nur genaue Treffer 461*cdf0e10cSrcweir void KillPams(); 462*cdf0e10cSrcweir 463*cdf0e10cSrcweir // erzeuge eine Kopie vom Cursor und speicher diese im Stack 464*cdf0e10cSrcweir void Push(); 465*cdf0e10cSrcweir /* 466*cdf0e10cSrcweir * Loescht einen Cursor (gesteuert durch bOldCrsr) 467*cdf0e10cSrcweir * - vom Stack oder ( bOldCrsr = sal_True ) 468*cdf0e10cSrcweir * - den aktuellen und der auf dem Stack stehende wird zum aktuellen 469*cdf0e10cSrcweir * 470*cdf0e10cSrcweir * Return: es war auf dem Stack noch einer vorhanden 471*cdf0e10cSrcweir */ 472*cdf0e10cSrcweir sal_Bool Pop( sal_Bool bOldCrsr = sal_True ); 473*cdf0e10cSrcweir /* 474*cdf0e10cSrcweir * Verbinde zwei Cursor miteinander. 475*cdf0e10cSrcweir * Loesche vom Stack den obersten und setzen dessen Mark im Aktuellen. 476*cdf0e10cSrcweir */ 477*cdf0e10cSrcweir void Combine(); 478*cdf0e10cSrcweir 479*cdf0e10cSrcweir #if !defined(DBG_UTIL) 480*cdf0e10cSrcweir void SttCrsrMove() { ++nCrsrMove; StartAction(); } 481*cdf0e10cSrcweir void EndCrsrMove( const sal_Bool bIdleEnd = sal_False ) 482*cdf0e10cSrcweir { EndAction( bIdleEnd ); --nCrsrMove; } 483*cdf0e10cSrcweir #else 484*cdf0e10cSrcweir void SttCrsrMove(); 485*cdf0e10cSrcweir void EndCrsrMove( const sal_Bool bIdleEnd = sal_False ); 486*cdf0e10cSrcweir #endif 487*cdf0e10cSrcweir 488*cdf0e10cSrcweir /* 489*cdf0e10cSrcweir * Beim Abgeben des Focuses werden die selektierten Bereiche nicht mehr 490*cdf0e10cSrcweir * angezeigt; andererseits beim Erhalten des Focuses, werden alle selek- 491*cdf0e10cSrcweir * tierten Bereiche wieder angezeigt. (Bereiche muessen neu berechnet 492*cdf0e10cSrcweir * werden!) 493*cdf0e10cSrcweir */ 494*cdf0e10cSrcweir sal_Bool HasShFcs() const { return bHasFocus; } 495*cdf0e10cSrcweir void ShLooseFcs(); 496*cdf0e10cSrcweir void ShGetFcs( sal_Bool bUpdate = sal_True ); 497*cdf0e10cSrcweir 498*cdf0e10cSrcweir // Methoden zum Anzeigen bzw. Verstecken des sichtbaren Text-Cursors 499*cdf0e10cSrcweir void ShowCrsr(); 500*cdf0e10cSrcweir void HideCrsr(); 501*cdf0e10cSrcweir // Methoden zum Anzeigen bzw. Verstecken der selektierten Bereiche mit 502*cdf0e10cSrcweir // dem sichtbaren Cursor 503*cdf0e10cSrcweir void ShowCrsrs( sal_Bool bCrsrVis ); 504*cdf0e10cSrcweir void HideCrsrs(); 505*cdf0e10cSrcweir 506*cdf0e10cSrcweir sal_Bool IsOverwriteCrsr() const { return bOverwriteCrsr; } 507*cdf0e10cSrcweir void SetOverwriteCrsr( sal_Bool bFlag ) { bOverwriteCrsr = bFlag; } 508*cdf0e10cSrcweir 509*cdf0e10cSrcweir // gebe den aktuellen Frame, in dem der Cursor steht, zurueck 510*cdf0e10cSrcweir SwCntntFrm *GetCurrFrm( const sal_Bool bCalcFrm = sal_True ) const; 511*cdf0e10cSrcweir 512*cdf0e10cSrcweir //sal_True wenn der Crsr wenn der Crsr wegen Readonly gehidet ist, 513*cdf0e10cSrcweir //sal_False wenn der arbeitet (trotz Readonly). 514*cdf0e10cSrcweir sal_Bool IsCrsrReadonly() const; 515*cdf0e10cSrcweir // Cursor steht in etwas geschuetztem oder in die Selektion umspannt 516*cdf0e10cSrcweir // etwas geschuetztes. 517*cdf0e10cSrcweir sal_Bool HasReadonlySel() const; 518*cdf0e10cSrcweir // darf der Cursor in ReadOnlyBereiche? 519*cdf0e10cSrcweir sal_Bool IsReadOnlyAvailable() const { return bSetCrsrInReadOnly; } 520*cdf0e10cSrcweir void SetReadOnlyAvailable( sal_Bool bFlag ); 521*cdf0e10cSrcweir sal_Bool IsOverReadOnlyPos( const Point& rPt ) const; 522*cdf0e10cSrcweir 523*cdf0e10cSrcweir // Methoden fuer aFlyMacroLnk 524*cdf0e10cSrcweir void SetFlyMacroLnk( const Link& rLnk ) { aFlyMacroLnk = rLnk; } 525*cdf0e10cSrcweir const Link& GetFlyMacroLnk() const { return aFlyMacroLnk; } 526*cdf0e10cSrcweir 527*cdf0e10cSrcweir // Methoden geben/aendern den Link fuer die Attribut/Format-Aenderungen 528*cdf0e10cSrcweir void SetChgLnk( const Link &rLnk ) { aChgLnk = rLnk; } 529*cdf0e10cSrcweir const Link& GetChgLnk() const { return aChgLnk; } 530*cdf0e10cSrcweir 531*cdf0e10cSrcweir // Methoden geben/aendern den Link fuers "Grafik vollstaendig geladen" 532*cdf0e10cSrcweir void SetGrfArrivedLnk( const Link &rLnk ) { aGrfArrivedLnk = rLnk; } 533*cdf0e10cSrcweir const Link& GetGrfArrivedLnk() const { return aGrfArrivedLnk; } 534*cdf0e10cSrcweir 535*cdf0e10cSrcweir //ChgLink callen, innerhalb einer Action wird der Ruf verzoegert. 536*cdf0e10cSrcweir void CallChgLnk(); 537*cdf0e10cSrcweir 538*cdf0e10cSrcweir // Abfrage, ob der aktuelle Cursor eine Selektion aufspannt, 539*cdf0e10cSrcweir // also, ob Mark gesetzt und SPoint und Mark unterschiedlich sind. 540*cdf0e10cSrcweir sal_Bool HasSelection() const; 541*cdf0e10cSrcweir 542*cdf0e10cSrcweir // Abfrage, ob ueberhaupt eine Selektion existiert, sprich der akt. Cursor 543*cdf0e10cSrcweir // aufgespannt oder nicht der einzigste ist. 544*cdf0e10cSrcweir inline sal_Bool IsSelection() const; 545*cdf0e10cSrcweir // returns if multiple cursors are available 546*cdf0e10cSrcweir inline sal_Bool IsMultiSelection() const; 547*cdf0e10cSrcweir 548*cdf0e10cSrcweir // Abfrage, ob ein kompletter Absatz selektiert wurde 549*cdf0e10cSrcweir sal_Bool IsSelFullPara() const; 550*cdf0e10cSrcweir // Abfrage, ob die Selektion in einem Absatz ist 551*cdf0e10cSrcweir inline sal_Bool IsSelOnePara() const; 552*cdf0e10cSrcweir 553*cdf0e10cSrcweir //Sollte fuer das Clipboard der WaitPtr geschaltet werden. 554*cdf0e10cSrcweir sal_Bool ShouldWait() const; 555*cdf0e10cSrcweir 556*cdf0e10cSrcweir /* 557*cdf0e10cSrcweir * liefert das SRectangle, auf dem der Cursor steht. 558*cdf0e10cSrcweir */ 559*cdf0e10cSrcweir const SwRect &GetCharRect() const { return aCharRect; } 560*cdf0e10cSrcweir /* 561*cdf0e10cSrcweir * liefert zurueck, ob der Cursor sich ganz oder teilweise im 562*cdf0e10cSrcweir * sichtbaren Bereich befindet. 563*cdf0e10cSrcweir */ 564*cdf0e10cSrcweir sal_Bool IsCrsrVisible() const { return VisArea().IsOver( GetCharRect() ); } 565*cdf0e10cSrcweir 566*cdf0e10cSrcweir // gebe die aktuelle Seitennummer zurueck: 567*cdf0e10cSrcweir // sal_True: in der der Cursor steht 568*cdf0e10cSrcweir // sal_False: die am oberen Rand sichtbar ist 569*cdf0e10cSrcweir void GetPageNum( sal_uInt16 &rnPhyNum, sal_uInt16 &rnVirtNum, 570*cdf0e10cSrcweir sal_Bool bAtCrsrPos = sal_True, const sal_Bool bCalcFrm = sal_True ); 571*cdf0e10cSrcweir // bestimme in welche Richtung "leere Seiten" behandelt werden! 572*cdf0e10cSrcweir // (wird benutzt im PhyPage.. ) 573*cdf0e10cSrcweir sal_uInt16 GetNextPrevPageNum( sal_Bool bNext = sal_True ); 574*cdf0e10cSrcweir 575*cdf0e10cSrcweir // setze den Cursor auf die Seite "nPage" an den Anfang 576*cdf0e10cSrcweir sal_Bool GotoPage( sal_uInt16 nPage ); 577*cdf0e10cSrcweir 578*cdf0e10cSrcweir // gebe alle Dokumentseiten zurueck 579*cdf0e10cSrcweir sal_uInt16 GetPageCnt(); 580*cdf0e10cSrcweir 581*cdf0e10cSrcweir // Gehe zur naechsten Selection 582*cdf0e10cSrcweir sal_Bool GoNextCrsr(); 583*cdf0e10cSrcweir // gehe zur vorherigen Selection 584*cdf0e10cSrcweir sal_Bool GoPrevCrsr(); 585*cdf0e10cSrcweir 586*cdf0e10cSrcweir // at CurCrsr.SPoint 587*cdf0e10cSrcweir ::sw::mark::IMark* SetBookmark( 588*cdf0e10cSrcweir const KeyCode&, 589*cdf0e10cSrcweir const ::rtl::OUString& rName, 590*cdf0e10cSrcweir const ::rtl::OUString& rShortName, 591*cdf0e10cSrcweir IDocumentMarkAccess::MarkType eMark = IDocumentMarkAccess::BOOKMARK); 592*cdf0e10cSrcweir bool GotoMark( const ::sw::mark::IMark* const pMark ); // sets CurCrsr.SPoint 593*cdf0e10cSrcweir bool GotoMark( const ::sw::mark::IMark* const pMark, bool bAtStart ); 594*cdf0e10cSrcweir bool GoNextBookmark(); // true, if there was one 595*cdf0e10cSrcweir bool GoPrevBookmark(); 596*cdf0e10cSrcweir 597*cdf0e10cSrcweir bool IsFormProtected(); 598*cdf0e10cSrcweir ::sw::mark::IFieldmark* GetCurrentFieldmark(); 599*cdf0e10cSrcweir ::sw::mark::IFieldmark* GetFieldmarkAfter(); 600*cdf0e10cSrcweir ::sw::mark::IFieldmark* GetFieldmarkBefore(); 601*cdf0e10cSrcweir bool GotoFieldmark( const ::sw::mark::IFieldmark* const pMark ); 602*cdf0e10cSrcweir 603*cdf0e10cSrcweir // aktualisiere den Crsrs, d.H. setze ihn wieder in den Content. 604*cdf0e10cSrcweir // Das sollte nur aufgerufen werden, wenn der Cursor z.B. beim 605*cdf0e10cSrcweir // Loeschen von Rahmen irgendwohin gesetzt wurde. Die Position 606*cdf0e10cSrcweir // ergibt sich aus seiner aktuellen Position im Layout !! 607*cdf0e10cSrcweir void UpdateCrsrPos(); 608*cdf0e10cSrcweir 609*cdf0e10cSrcweir // returne den am akt. Cursor selektierten Text. Dieser wird mit 610*cdf0e10cSrcweir // Felder etc. aufgefuellt!! 611*cdf0e10cSrcweir String GetSelTxt() const; 612*cdf0e10cSrcweir // gebe nur den Text ab der akt. Cursor Position zurueck (bis zum NodeEnde) 613*cdf0e10cSrcweir String GetText() const; 614*cdf0e10cSrcweir 615*cdf0e10cSrcweir // pruefe ob vom aktuellen Crsr der SPoint/Mark in einer Tabelle stehen 616*cdf0e10cSrcweir inline const SwTableNode* IsCrsrInTbl( sal_Bool bIsPtInTbl = sal_True ) const; 617*cdf0e10cSrcweir // erfrage die Document - Layout - Position vom akt. Crsr 618*cdf0e10cSrcweir inline Point& GetCrsrDocPos( sal_Bool bPoint = sal_True ) const; 619*cdf0e10cSrcweir inline sal_Bool IsCrsrPtAtEnd() const; 620*cdf0e10cSrcweir 621*cdf0e10cSrcweir inline const SwPaM* GetTblCrs() const; 622*cdf0e10cSrcweir inline SwPaM* GetTblCrs(); 623*cdf0e10cSrcweir 624*cdf0e10cSrcweir sal_Bool IsTblComplex() const; 625*cdf0e10cSrcweir sal_Bool IsTblComplexForChart(); 626*cdf0e10cSrcweir // erfrage die akt. TabellenSelektion als Text 627*cdf0e10cSrcweir String GetBoxNms() const; 628*cdf0e10cSrcweir 629*cdf0e10cSrcweir // setze Crsr in die naechsten/vorherigen Celle 630*cdf0e10cSrcweir sal_Bool GoNextCell( sal_Bool bAppendLine = sal_True ); 631*cdf0e10cSrcweir sal_Bool GoPrevCell(); 632*cdf0e10cSrcweir // gehe zu dieser Box (wenn vorhanden und in Tabelle!) 633*cdf0e10cSrcweir sal_Bool GotoTable( const String& rName ); 634*cdf0e10cSrcweir 635*cdf0e10cSrcweir // select a table row, column or box (based on the current cursor) 636*cdf0e10cSrcweir sal_Bool SelTblRow() { return _SelTblRowOrCol( true ); } 637*cdf0e10cSrcweir sal_Bool SelTblCol() { return _SelTblRowOrCol( false ); } 638*cdf0e10cSrcweir sal_Bool SelTblBox(); 639*cdf0e10cSrcweir // --> FME 2004-07-30 #i32329# Enhanced table selection 640*cdf0e10cSrcweir sal_Bool SelTbl(); 641*cdf0e10cSrcweir // <-- 642*cdf0e10cSrcweir 643*cdf0e10cSrcweir // zum naechsten/vorhergehenden Punkt auf gleicher Ebene 644*cdf0e10cSrcweir sal_Bool GotoNextNum(); 645*cdf0e10cSrcweir sal_Bool GotoPrevNum(); 646*cdf0e10cSrcweir 647*cdf0e10cSrcweir // zu diesem Gliederungspunkt 648*cdf0e10cSrcweir sal_Bool GotoOutline( const String& rName ); 649*cdf0e10cSrcweir // zum naechsten/vorhergehenden oder angegebenen OultineNode 650*cdf0e10cSrcweir void GotoOutline( sal_uInt16 nIdx ); 651*cdf0e10cSrcweir // suche die "Outline-Position" im Nodes-Array vom akt. Kaiptel 652*cdf0e10cSrcweir sal_uInt16 GetOutlinePos( sal_uInt8 nLevel = UCHAR_MAX ); 653*cdf0e10cSrcweir // selektiere den angeben Bereich von OutlineNodes. Optional 654*cdf0e10cSrcweir // inclusive der Childs. Die sal_uInt16 sind die Positionen im 655*cdf0e10cSrcweir // OutlineNds-Array!! (EditShell) 656*cdf0e10cSrcweir sal_Bool MakeOutlineSel( sal_uInt16 nSttPos, sal_uInt16 nEndPos, 657*cdf0e10cSrcweir sal_Bool bWithChilds = sal_False ); 658*cdf0e10cSrcweir 659*cdf0e10cSrcweir sal_Bool GotoNextOutline(); // naechster Node mit Outline-Num. 660*cdf0e10cSrcweir sal_Bool GotoPrevOutline(); // vorheriger Node mit Outline-Num. 661*cdf0e10cSrcweir 662*cdf0e10cSrcweir /** Delivers the current shell cursor 663*cdf0e10cSrcweir 664*cdf0e10cSrcweir Some operations have to run on the current cursor ring, 665*cdf0e10cSrcweir some on the pTblCrsr (if exist) or the current cursor ring and 666*cdf0e10cSrcweir some on the pTblCrsr or pBlockCrsr or the current cursor ring. 667*cdf0e10cSrcweir This small function checks the existence and delivers the wished cursor. 668*cdf0e10cSrcweir 669*cdf0e10cSrcweir @param bBlock [bool] 670*cdf0e10cSrcweir if the block cursor is of interest or not 671*cdf0e10cSrcweir 672*cdf0e10cSrcweir @return pTblCrsr if exist, 673*cdf0e10cSrcweir pBlockCrsr if exist and of interest (param bBlock) 674*cdf0e10cSrcweir otherwise pCurCrsr 675*cdf0e10cSrcweir */ 676*cdf0e10cSrcweir SwShellCrsr* getShellCrsr( bool bBlock ); 677*cdf0e10cSrcweir const SwShellCrsr* getShellCrsr( bool bBlock ) const 678*cdf0e10cSrcweir { return (const_cast<SwCrsrShell*>(this))->getShellCrsr( bBlock ); } 679*cdf0e10cSrcweir 680*cdf0e10cSrcweir FASTBOOL IsBlockMode() const { return 0 != pBlockCrsr; } 681*cdf0e10cSrcweir const IBlockCursor* GetBlockCrsr() const { return pBlockCrsr; } 682*cdf0e10cSrcweir IBlockCursor* GetBlockCrsr() { return pBlockCrsr; } 683*cdf0e10cSrcweir 684*cdf0e10cSrcweir // ist der Crsr in einer Tabelle und ist die Selection ueber 685*cdf0e10cSrcweir // zwei Spalten 686*cdf0e10cSrcweir sal_Bool IsTableMode() const { return 0 != pTblCrsr; } 687*cdf0e10cSrcweir 688*cdf0e10cSrcweir // erfrage den Tabellen Crsr; ausserhalb von Tabellen immer 0 689*cdf0e10cSrcweir const SwShellTableCrsr* GetTableCrsr() const { return pTblCrsr; } 690*cdf0e10cSrcweir SwShellTableCrsr* GetTableCrsr() { return pTblCrsr; } 691*cdf0e10cSrcweir sal_uInt16 UpdateTblSelBoxes(); 692*cdf0e10cSrcweir 693*cdf0e10cSrcweir sal_Bool GotoFtnTxt(); // springe aus dem Content zur Fussnote 694*cdf0e10cSrcweir sal_Bool GotoFtnAnchor(); // springe aus der Fussnote zum Anker 695*cdf0e10cSrcweir sal_Bool GotoPrevFtnAnchor(); 696*cdf0e10cSrcweir sal_Bool GotoNextFtnAnchor(); 697*cdf0e10cSrcweir 698*cdf0e10cSrcweir sal_Bool GotoFlyAnchor(); // springe aus dem Rahmen zum Anker 699*cdf0e10cSrcweir sal_Bool GotoHeaderTxt(); // springe aus dem Content zum Header 700*cdf0e10cSrcweir sal_Bool GotoFooterTxt(); // springe aus dem Content zum Footer 701*cdf0e10cSrcweir // springe in den Header/Footer des angegebenen oder akt. PageDesc 702*cdf0e10cSrcweir sal_Bool SetCrsrInHdFt( sal_uInt16 nDescNo = USHRT_MAX, 703*cdf0e10cSrcweir sal_Bool bInHeader = sal_True ); 704*cdf0e10cSrcweir // is point of cursor in header/footer. pbInHeader return sal_True if it is 705*cdf0e10cSrcweir // in a headerframe otherwise in a footerframe 706*cdf0e10cSrcweir sal_Bool IsInHeaderFooter( sal_Bool* pbInHeader = 0 ) const; 707*cdf0e10cSrcweir 708*cdf0e10cSrcweir // springe zum naechsten Verzeichnis [mit dem Namen] 709*cdf0e10cSrcweir sal_Bool GotoNextTOXBase( const String* = 0 ); 710*cdf0e10cSrcweir // springe zum vorherigen Verzeichnis [mit dem Namen] 711*cdf0e10cSrcweir sal_Bool GotoPrevTOXBase( const String* = 0 ); 712*cdf0e10cSrcweir sal_Bool GotoTOXMarkBase(); // springe zum Verzeichnis vom TOXMark 713*cdf0e10cSrcweir // springe zum naechsten (vorherigen) Verzeichniseintrag 714*cdf0e10cSrcweir sal_Bool GotoNxtPrvTOXMark( sal_Bool bNext = sal_True ); 715*cdf0e10cSrcweir // Zur naechsten/ vorherigen Verzeichnismarke dieses Typs traveln 716*cdf0e10cSrcweir const SwTOXMark& GotoTOXMark( const SwTOXMark& rStart, SwTOXSearch eDir ); 717*cdf0e10cSrcweir 718*cdf0e10cSrcweir // springe zum naechsten (vorherigen) Tabellenformel 719*cdf0e10cSrcweir // optional auch nur zu kaputten Formeln springen 720*cdf0e10cSrcweir sal_Bool GotoNxtPrvTblFormula( sal_Bool bNext = sal_True, 721*cdf0e10cSrcweir sal_Bool bOnlyErrors = sal_False ); 722*cdf0e10cSrcweir // jump to the next / previous hyperlink - inside text and also 723*cdf0e10cSrcweir // on graphics 724*cdf0e10cSrcweir sal_Bool SelectNxtPrvHyperlink( sal_Bool bNext = sal_True ); 725*cdf0e10cSrcweir 726*cdf0e10cSrcweir // springe zu dieser Refmark 727*cdf0e10cSrcweir sal_Bool GotoRefMark( const String& rRefMark, sal_uInt16 nSubType = 0, 728*cdf0e10cSrcweir sal_uInt16 nSeqNo = 0 ); 729*cdf0e10cSrcweir 730*cdf0e10cSrcweir // hole vom Start/Ende der akt. Selection das nte Zeichen 731*cdf0e10cSrcweir sal_Unicode GetChar( sal_Bool bEnd = sal_True, long nOffset = 0 ); 732*cdf0e10cSrcweir // erweiter die akt. Selection am Anfang/Ende um n Zeichen 733*cdf0e10cSrcweir sal_Bool ExtendSelection( sal_Bool bEnd = sal_True, xub_StrLen nCount = 1 ); 734*cdf0e10cSrcweir // setze nur den sichtbaren Cursor an die angegebene Dokument-Pos. 735*cdf0e10cSrcweir // returnt sal_False: wenn der ob der SPoint vom Layout korrigiert wurde. 736*cdf0e10cSrcweir // (wird zum Anzeigen von Drag&Drop/Copy-Cursor benoetigt) 737*cdf0e10cSrcweir sal_Bool SetVisCrsr( const Point &rPt ); 738*cdf0e10cSrcweir inline void UnSetVisCrsr(); 739*cdf0e10cSrcweir 740*cdf0e10cSrcweir // springe zum nachsten/vorherigen Feld des entsprechenden Types 741*cdf0e10cSrcweir sal_Bool MoveFldType( const SwFieldType* pFldType, sal_Bool bNext, 742*cdf0e10cSrcweir sal_uInt16 nSubType = USHRT_MAX, 743*cdf0e10cSrcweir sal_uInt16 nResType = USHRT_MAX ); 744*cdf0e10cSrcweir // springe genau zu diesem Feld 745*cdf0e10cSrcweir sal_Bool GotoFld( const SwFmtFld& rFld ); 746*cdf0e10cSrcweir 747*cdf0e10cSrcweir // returne die Anzahl der Cursor im Ring (Flag besagt ob man nur 748*cdf0e10cSrcweir // aufgepspannte haben will - sprich etwas selektiert ist (Basic)) 749*cdf0e10cSrcweir sal_uInt16 GetCrsrCnt( sal_Bool bAll = sal_True ) const; 750*cdf0e10cSrcweir 751*cdf0e10cSrcweir // Char Travelling - Methoden (in crstrvl1.cxx) 752*cdf0e10cSrcweir sal_Bool GoStartWord(); 753*cdf0e10cSrcweir sal_Bool GoEndWord(); 754*cdf0e10cSrcweir sal_Bool GoNextWord(); 755*cdf0e10cSrcweir sal_Bool GoPrevWord(); 756*cdf0e10cSrcweir sal_Bool GoNextSentence(); 757*cdf0e10cSrcweir sal_Bool GoPrevSentence(); 758*cdf0e10cSrcweir sal_Bool GoStartSentence(); 759*cdf0e10cSrcweir sal_Bool GoEndSentence(); 760*cdf0e10cSrcweir sal_Bool SelectWord( const Point* pPt = 0 ); 761*cdf0e10cSrcweir sal_Bool ExpandToSentenceBorders(); 762*cdf0e10cSrcweir 763*cdf0e10cSrcweir // Position vom akt. Cursor erfragen 764*cdf0e10cSrcweir sal_Bool IsStartWord( sal_Int16 nWordType = com::sun::star::i18n::WordType::ANYWORD_IGNOREWHITESPACES )const; 765*cdf0e10cSrcweir sal_Bool IsEndWord( sal_Int16 nWordType = com::sun::star::i18n::WordType::ANYWORD_IGNOREWHITESPACES ) const; 766*cdf0e10cSrcweir sal_Bool IsInWord( sal_Int16 nWordType = com::sun::star::i18n::WordType::ANYWORD_IGNOREWHITESPACES ) const; 767*cdf0e10cSrcweir sal_Bool IsStartSentence() const; 768*cdf0e10cSrcweir sal_Bool IsEndSentence() const; 769*cdf0e10cSrcweir sal_Bool IsSttPara() const; 770*cdf0e10cSrcweir sal_Bool IsEndPara() const; 771*cdf0e10cSrcweir sal_Bool IsStartOfDoc() const; 772*cdf0e10cSrcweir sal_Bool IsEndOfDoc() const; 773*cdf0e10cSrcweir sal_Bool IsInFrontOfLabel() const; 774*cdf0e10cSrcweir sal_Bool IsAtLeftMargin() const { return IsAtLRMargin( sal_True ); } 775*cdf0e10cSrcweir sal_Bool IsAtRightMargin(sal_Bool bAPI = sal_False) const { return IsAtLRMargin( sal_False, bAPI ); } 776*cdf0e10cSrcweir 777*cdf0e10cSrcweir // loesche alle erzeugten Crsr, setze den Tabellen-Crsr und den letzten 778*cdf0e10cSrcweir // Cursor auf seinen TextNode (oder StartNode?). 779*cdf0e10cSrcweir // Beim naechsten ::GetCrsr werden sie wieder alle erzeugt. 780*cdf0e10cSrcweir // Wird fuers Drag&Drop/ClipBorad-Paste in Tabellen benoetigt. 781*cdf0e10cSrcweir sal_Bool ParkTblCrsr(); 782*cdf0e10cSrcweir 783*cdf0e10cSrcweir // gibt es nicht aufgespannte Attribute? 784*cdf0e10cSrcweir sal_Bool IsGCAttr() const { return bGCAttr; } 785*cdf0e10cSrcweir void ClearGCAttr() { bGCAttr = sal_False; } 786*cdf0e10cSrcweir void UpdateAttr() { bGCAttr = sal_True; } 787*cdf0e10cSrcweir 788*cdf0e10cSrcweir // ist das gesamte Dokument geschuetzt/versteckt?? (fuer UI,..) 789*cdf0e10cSrcweir sal_Bool IsAllProtect() const { return bAllProtect; } 790*cdf0e10cSrcweir 791*cdf0e10cSrcweir #ifdef SW_CRSR_TIMER 792*cdf0e10cSrcweir // setze das Flag am VisCrsr, ob dieser ueber Timer getriggert (sal_True) 793*cdf0e10cSrcweir // oder direkt (sal_False) angezeigt wird. (default ist Timer getriggert) 794*cdf0e10cSrcweir sal_Bool ChgCrsrTimerFlag( sal_Bool bTimerOn = sal_True ); 795*cdf0e10cSrcweir #endif 796*cdf0e10cSrcweir 797*cdf0e10cSrcweir sal_Bool BasicActionPend() const { return nBasicActionCnt != nStartAction; } 798*cdf0e10cSrcweir 799*cdf0e10cSrcweir // springe zum benannten Bereich 800*cdf0e10cSrcweir sal_Bool GotoRegion( const String& rName ); 801*cdf0e10cSrcweir 802*cdf0e10cSrcweir // zeige die aktuelle Selektion an 803*cdf0e10cSrcweir virtual void MakeSelVisible(); 804*cdf0e10cSrcweir 805*cdf0e10cSrcweir // setzte den Cursor auf einen NICHT geschuetzten/versteckten Node 806*cdf0e10cSrcweir sal_Bool FindValidCntntNode( sal_Bool bOnlyText = sal_False ); 807*cdf0e10cSrcweir 808*cdf0e10cSrcweir sal_Bool GetContentAtPos( const Point& rPt, 809*cdf0e10cSrcweir SwContentAtPos& rCntntAtPos, 810*cdf0e10cSrcweir sal_Bool bSetCrsr = sal_False, 811*cdf0e10cSrcweir SwRect* pFldRect = 0 ); 812*cdf0e10cSrcweir 813*cdf0e10cSrcweir // --> OD 2008-06-19 #i90516# 814*cdf0e10cSrcweir const SwPostItField* GetPostItFieldAtCursor() const; 815*cdf0e10cSrcweir // <-- 816*cdf0e10cSrcweir 817*cdf0e10cSrcweir // get smart tags at point position 818*cdf0e10cSrcweir void GetSmartTagTerm( const Point& rPt, 819*cdf0e10cSrcweir SwRect& rSelectRect, 820*cdf0e10cSrcweir ::com::sun::star::uno::Sequence< rtl::OUString >& rSmartTagTypes, 821*cdf0e10cSrcweir ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Reference< ::com::sun::star::container::XStringKeyMap > >& rStringKeyMaps, 822*cdf0e10cSrcweir ::com::sun::star::uno::Reference<com::sun::star::text::XTextRange>& rRange ); 823*cdf0e10cSrcweir 824*cdf0e10cSrcweir // get smart tags at current cursor position 825*cdf0e10cSrcweir void GetSmartTagTerm( ::com::sun::star::uno::Sequence< rtl::OUString >& rSmartTagTypes, 826*cdf0e10cSrcweir ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Reference< ::com::sun::star::container::XStringKeyMap > >& rStringKeyMaps, 827*cdf0e10cSrcweir ::com::sun::star::uno::Reference<com::sun::star::text::XTextRange>& rRange ) const; 828*cdf0e10cSrcweir 829*cdf0e10cSrcweir sal_Bool IsPageAtPos( const Point &rPt ) const; 830*cdf0e10cSrcweir 831*cdf0e10cSrcweir // Attribut selelktieren 832*cdf0e10cSrcweir sal_Bool SelectTxtAttr( sal_uInt16 nWhich, sal_Bool bExpand, const SwTxtAttr* pAttr = 0 ); 833*cdf0e10cSrcweir sal_Bool GotoINetAttr( const SwTxtINetFmt& rAttr ); 834*cdf0e10cSrcweir const SwFmtINetFmt* FindINetAttr( const String& rName ) const; 835*cdf0e10cSrcweir 836*cdf0e10cSrcweir sal_Bool CheckTblBoxCntnt( const SwPosition* pPos = 0 ); 837*cdf0e10cSrcweir void SaveTblBoxCntnt( const SwPosition* pPos = 0 ); 838*cdf0e10cSrcweir void ClearTblBoxCntnt(); 839*cdf0e10cSrcweir sal_Bool EndAllTblBoxEdit(); 840*cdf0e10cSrcweir 841*cdf0e10cSrcweir // wird gerufen, wenn eine Tabellenselektion im UpdateCrsr erzeugt wird, 842*cdf0e10cSrcweir // ohne das die UI davon etaws weiss 843*cdf0e10cSrcweir virtual void NewCoreSelection(); 844*cdf0e10cSrcweir 845*cdf0e10cSrcweir void SetSelTblCells( sal_Bool bFlag ) { bSelTblCells = bFlag; } 846*cdf0e10cSrcweir sal_Bool IsSelTblCells() const { return bSelTblCells; } 847*cdf0e10cSrcweir 848*cdf0e10cSrcweir sal_Bool IsAutoUpdateCells() const { return bAutoUpdateCells; } 849*cdf0e10cSrcweir void SetAutoUpdateCells( sal_Bool bFlag ) { bAutoUpdateCells = bFlag; } 850*cdf0e10cSrcweir 851*cdf0e10cSrcweir sal_Bool GetShadowCrsrPos( const Point& rPt, SwFillMode eFillMode, 852*cdf0e10cSrcweir SwRect& rRect, short& rOrient ); 853*cdf0e10cSrcweir sal_Bool SetShadowCrsrPos( const Point& rPt, SwFillMode eFillMode ); 854*cdf0e10cSrcweir 855*cdf0e10cSrcweir const SwRedline* SelNextRedline(); 856*cdf0e10cSrcweir const SwRedline* SelPrevRedline(); 857*cdf0e10cSrcweir const SwRedline* GotoRedline( sal_uInt16 nArrPos, sal_Bool bSelect = sal_False ); 858*cdf0e10cSrcweir 859*cdf0e10cSrcweir // is cursor or the point in/over a vertical formatted text? 860*cdf0e10cSrcweir sal_Bool IsInVerticalText( const Point* pPt = 0 ) const; 861*cdf0e10cSrcweir // is cursor or the point in/over a right to left formatted text? 862*cdf0e10cSrcweir sal_Bool IsInRightToLeftText( const Point* pPt = 0 ) const; 863*cdf0e10cSrcweir 864*cdf0e10cSrcweir // If the current cursor position is inside a hidden range, the hidden range 865*cdf0e10cSrcweir // is selected and true is returned: 866*cdf0e10cSrcweir bool SelectHiddenRange(); 867*cdf0e10cSrcweir 868*cdf0e10cSrcweir // remove all invalid cursors 869*cdf0e10cSrcweir void ClearUpCrsrs(); 870*cdf0e10cSrcweir 871*cdf0e10cSrcweir // OD 11.02.2003 #100556# - set/get flag to allow/avoid execution of macros 872*cdf0e10cSrcweir inline void SetMacroExecAllowed( const bool _bMacroExecAllowed ) 873*cdf0e10cSrcweir { 874*cdf0e10cSrcweir mbMacroExecAllowed = _bMacroExecAllowed; 875*cdf0e10cSrcweir } 876*cdf0e10cSrcweir inline bool IsMacroExecAllowed() 877*cdf0e10cSrcweir { 878*cdf0e10cSrcweir return mbMacroExecAllowed; 879*cdf0e10cSrcweir } 880*cdf0e10cSrcweir 881*cdf0e10cSrcweir // #111827# 882*cdf0e10cSrcweir /** 883*cdf0e10cSrcweir Returns textual description of the current selection. 884*cdf0e10cSrcweir 885*cdf0e10cSrcweir - If the current selection is a multi-selection the result is 886*cdf0e10cSrcweir STR_MULTISEL. 887*cdf0e10cSrcweir - Else the result is the text of the selection. 888*cdf0e10cSrcweir 889*cdf0e10cSrcweir @return the textual description of the current selection 890*cdf0e10cSrcweir */ 891*cdf0e10cSrcweir String GetCrsrDescr() const; 892*cdf0e10cSrcweir 893*cdf0e10cSrcweir SwRect GetRectOfCurrentChar(); 894*cdf0e10cSrcweir }; 895*cdf0e10cSrcweir 896*cdf0e10cSrcweir 897*cdf0e10cSrcweir // Cursor Inlines: 898*cdf0e10cSrcweir inline SwMoveFnCollection* SwCrsrShell::MakeFindRange( 899*cdf0e10cSrcweir sal_uInt16 nStt, sal_uInt16 nEnd, SwPaM* pPam ) const 900*cdf0e10cSrcweir { 901*cdf0e10cSrcweir return pCurCrsr->MakeFindRange( (SwDocPositions)nStt, (SwDocPositions)nEnd, pPam ); 902*cdf0e10cSrcweir } 903*cdf0e10cSrcweir 904*cdf0e10cSrcweir inline SwCursor* SwCrsrShell::GetSwCrsr( sal_Bool bMakeTblCrsr ) const 905*cdf0e10cSrcweir { 906*cdf0e10cSrcweir return (SwCursor*)GetCrsr( bMakeTblCrsr ); 907*cdf0e10cSrcweir } 908*cdf0e10cSrcweir 909*cdf0e10cSrcweir inline SwPaM* SwCrsrShell::GetStkCrsr() const { return pCrsrStk; } 910*cdf0e10cSrcweir 911*cdf0e10cSrcweir inline void SwCrsrShell::SetMark() { pCurCrsr->SetMark(); } 912*cdf0e10cSrcweir 913*cdf0e10cSrcweir inline sal_Bool SwCrsrShell::HasMark() { return( pCurCrsr->HasMark() ); } 914*cdf0e10cSrcweir 915*cdf0e10cSrcweir inline sal_Bool SwCrsrShell::IsSelection() const 916*cdf0e10cSrcweir { 917*cdf0e10cSrcweir return IsTableMode() || pCurCrsr->HasMark() || 918*cdf0e10cSrcweir pCurCrsr->GetNext() != pCurCrsr; 919*cdf0e10cSrcweir } 920*cdf0e10cSrcweir inline sal_Bool SwCrsrShell::IsMultiSelection() const 921*cdf0e10cSrcweir { 922*cdf0e10cSrcweir return pCurCrsr->GetNext() != pCurCrsr; 923*cdf0e10cSrcweir } 924*cdf0e10cSrcweir 925*cdf0e10cSrcweir inline sal_Bool SwCrsrShell::IsSelOnePara() const 926*cdf0e10cSrcweir { 927*cdf0e10cSrcweir return pCurCrsr == pCurCrsr->GetNext() && 928*cdf0e10cSrcweir pCurCrsr->GetPoint()->nNode == pCurCrsr->GetMark()->nNode; 929*cdf0e10cSrcweir } 930*cdf0e10cSrcweir 931*cdf0e10cSrcweir inline const SwTableNode* SwCrsrShell::IsCrsrInTbl( sal_Bool bIsPtInTbl ) const 932*cdf0e10cSrcweir { 933*cdf0e10cSrcweir return pCurCrsr->GetNode( bIsPtInTbl )->FindTableNode(); 934*cdf0e10cSrcweir } 935*cdf0e10cSrcweir 936*cdf0e10cSrcweir inline sal_Bool SwCrsrShell::IsCrsrPtAtEnd() const 937*cdf0e10cSrcweir { 938*cdf0e10cSrcweir return pCurCrsr->End() == pCurCrsr->GetPoint(); 939*cdf0e10cSrcweir } 940*cdf0e10cSrcweir 941*cdf0e10cSrcweir inline Point& SwCrsrShell::GetCrsrDocPos( sal_Bool bPoint ) const 942*cdf0e10cSrcweir { 943*cdf0e10cSrcweir return bPoint ? pCurCrsr->GetPtPos() : pCurCrsr->GetMkPos(); 944*cdf0e10cSrcweir } 945*cdf0e10cSrcweir 946*cdf0e10cSrcweir inline const SwPaM* SwCrsrShell::GetTblCrs() const 947*cdf0e10cSrcweir { 948*cdf0e10cSrcweir return pTblCrsr; 949*cdf0e10cSrcweir } 950*cdf0e10cSrcweir 951*cdf0e10cSrcweir inline SwPaM* SwCrsrShell::GetTblCrs() 952*cdf0e10cSrcweir { 953*cdf0e10cSrcweir return pTblCrsr; 954*cdf0e10cSrcweir } 955*cdf0e10cSrcweir 956*cdf0e10cSrcweir inline void SwCrsrShell::UnSetVisCrsr() 957*cdf0e10cSrcweir { 958*cdf0e10cSrcweir pVisCrsr->Hide(); 959*cdf0e10cSrcweir pVisCrsr->SetDragCrsr( sal_False ); 960*cdf0e10cSrcweir } 961*cdf0e10cSrcweir 962*cdf0e10cSrcweir #endif // _CRSRSH_HXX 963