LibreOffice Module sw (master)  1
toxmgr.cxx
Go to the documentation of this file.
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*
3  * This file is part of the LibreOffice project.
4  *
5  * This Source Code Form is subject to the terms of the Mozilla Public
6  * License, v. 2.0. If a copy of the MPL was not distributed with this
7  * file, You can obtain one at http://mozilla.org/MPL/2.0/.
8  *
9  * This file incorporates work covered by the following license notice:
10  *
11  * Licensed to the Apache Software Foundation (ASF) under one or more
12  * contributor license agreements. See the NOTICE file distributed
13  * with this work for additional information regarding copyright
14  * ownership. The ASF licenses this file to you under the Apache
15  * License, Version 2.0 (the "License"); you may not use this file
16  * except in compliance with the License. You may obtain a copy of
17  * the License at http://www.apache.org/licenses/LICENSE-2.0 .
18  */
19 
20 #include <wrtsh.hxx>
21 #include <swwait.hxx>
22 #include <view.hxx>
23 #include <toxmgr.hxx>
24 #include <doc.hxx>
25 #include <IDocumentUndoRedo.hxx>
26 #include <swundo.hxx>
27 
28 // handle indexes with TOXMgr
30  pSh(pShell)
31 {
33  SetCurTOXMark(0);
34 }
35 
37 {
38  if(!aCurMarks.empty())
39  return aCurMarks[nId];
40  return nullptr;
41 }
42 
44 {
45  SwTOXMark* pNext = nullptr;
46  if( pCurTOXMark )
47  {
48  pNext = const_cast<SwTOXMark*>(&pSh->GotoTOXMark( *pCurTOXMark, TOX_NXT ));
49  if( pNext == pCurTOXMark )
50  pNext = nullptr;
51 
53  pSh->SetModified();
54  }
55  // go to next one
56  pCurTOXMark = pNext;
57 }
58 
60 {
61  SwTOXMark* pMark = nullptr;
62  switch(rDesc.GetTOXType())
63  {
64  case TOX_CONTENT:
65  {
66  OSL_ENSURE(rDesc.GetLevel() > 0 && rDesc.GetLevel() <= MAXLEVEL,
67  "invalid InsertTOCMark level");
68  pMark = new SwTOXMark(pSh->GetTOXType(TOX_CONTENT, 0));
69  pMark->SetLevel( static_cast< sal_uInt16 >(rDesc.GetLevel()) );
70 
71  if(rDesc.GetAltStr())
72  pMark->SetAlternativeText(*rDesc.GetAltStr());
73  }
74  break;
75  case TOX_INDEX:
76  {
77  pMark = new SwTOXMark(pSh->GetTOXType(TOX_INDEX, 0));
78 
79  if( rDesc.GetPrimKey() && !rDesc.GetPrimKey()->isEmpty() )
80  {
81  pMark->SetPrimaryKey( *rDesc.GetPrimKey() );
82  if(rDesc.GetPhoneticReadingOfPrimKey())
84 
85  if( rDesc.GetSecKey() && !rDesc.GetSecKey()->isEmpty() )
86  {
87  pMark->SetSecondaryKey( *rDesc.GetSecKey() );
88  if(rDesc.GetPhoneticReadingOfSecKey())
90  }
91  }
92  if(rDesc.GetAltStr())
93  pMark->SetAlternativeText(*rDesc.GetAltStr());
94  if(rDesc.GetPhoneticReadingOfAltStr())
95  pMark->SetTextReading( *rDesc.GetPhoneticReadingOfAltStr() );
96  pMark->SetMainEntry(rDesc.IsMainEntry());
97  }
98  break;
99  case TOX_USER:
100  {
101  OSL_ENSURE(rDesc.GetLevel() > 0 && rDesc.GetLevel() <= MAXLEVEL,
102  "invalid InsertTOCMark level");
103  sal_uInt16 nId = rDesc.GetTOUName() ?
104  GetUserTypeID(*rDesc.GetTOUName()) : 0;
105  pMark = new SwTOXMark(pSh->GetTOXType(TOX_USER, nId));
106  pMark->SetLevel( static_cast< sal_uInt16 >(rDesc.GetLevel()) );
107 
108  if(rDesc.GetAltStr())
109  pMark->SetAlternativeText(*rDesc.GetAltStr());
110  }
111  break;
112  case TOX_BIBLIOGRAPHY:
113  {
114  pMark = new SwTOXMark(pSh->GetTOXType(TOX_BIBLIOGRAPHY, 0));
115 
116  if( rDesc.GetPrimKey() && !rDesc.GetPrimKey()->isEmpty() )
117  {
118  pMark->SetPrimaryKey( *rDesc.GetPrimKey() );
119  if(rDesc.GetPhoneticReadingOfPrimKey())
121 
122  if( rDesc.GetSecKey() && !rDesc.GetSecKey()->isEmpty() )
123  {
124  pMark->SetSecondaryKey( *rDesc.GetSecKey() );
125  if(rDesc.GetPhoneticReadingOfSecKey())
127  }
128  }
129  if(rDesc.GetAltStr())
130  pMark->SetAlternativeText(*rDesc.GetAltStr());
131  if(rDesc.GetPhoneticReadingOfAltStr())
132  pMark->SetTextReading( *rDesc.GetPhoneticReadingOfAltStr() );
133  pMark->SetMainEntry(rDesc.IsMainEntry());
134  }
135  break;
136  default:; //prevent warning
137  }
138 
139  if (!pMark)
140  return;
141 
142  pSh->StartAllAction();
143  pSh->SwEditShell::Insert(*pMark);
144  pSh->EndAllAction();
145 }
146 
147 // Update of TOXMarks
149 {
150  assert(pCurTOXMark && "no current TOXMark");
151  pSh->StartAllAction();
153  {
154  if(rDesc.GetPrimKey() && !rDesc.GetPrimKey()->isEmpty() )
155  {
156  pCurTOXMark->SetPrimaryKey( *rDesc.GetPrimKey() );
157  if(rDesc.GetPhoneticReadingOfPrimKey())
159  else
160  pCurTOXMark->SetPrimaryKeyReading(OUString());
161 
162  if( rDesc.GetSecKey() && !rDesc.GetSecKey()->isEmpty() )
163  {
165  if(rDesc.GetPhoneticReadingOfSecKey())
167  else
168  pCurTOXMark->SetSecondaryKeyReading(OUString());
169  }
170  else
171  {
172  pCurTOXMark->SetSecondaryKey(OUString());
173  pCurTOXMark->SetSecondaryKeyReading(OUString());
174  }
175  }
176  else
177  {
178  pCurTOXMark->SetPrimaryKey(OUString());
179  pCurTOXMark->SetPrimaryKeyReading(OUString());
180  pCurTOXMark->SetSecondaryKey(OUString());
181  pCurTOXMark->SetSecondaryKeyReading(OUString());
182  }
183  if(rDesc.GetPhoneticReadingOfAltStr())
185  else
186  pCurTOXMark->SetTextReading(OUString());
188  }
189  else
190  pCurTOXMark->SetLevel( static_cast< sal_uInt16 >(rDesc.GetLevel()) );
191 
192  if(rDesc.GetAltStr())
193  {
194  // JP 26.08.96: Bug 30344 - either the text of a Doc or an alternative test,
195  // not both!
196  bool bReplace = pCurTOXMark->IsAlternativeText();
197  if( bReplace )
199  else
200  {
201  SwTOXMark aCpy( *pCurTOXMark );
202  aCurMarks.clear();
204  aCpy.SetAlternativeText( *rDesc.GetAltStr() );
205  pSh->SwEditShell::Insert( aCpy );
206  pCurTOXMark = nullptr;
207  }
208  }
209  pSh->SetModified();
210  pSh->EndAllAction();
211  // Bug 36207 pCurTOXMark points nowhere here!
212  if(!pCurTOXMark)
213  {
214  pSh->Left(CRSR_SKIP_CHARS, false, 1, false );
216  SetCurTOXMark(0);
217  }
218 }
219 
220 // determine UserTypeID
221 sal_uInt16 SwTOXMgr::GetUserTypeID(const OUString& rStr)
222 {
223  sal_uInt16 nSize = pSh->GetTOXTypeCount(TOX_USER);
224  for(sal_uInt16 i=0; i < nSize; ++i)
225  {
226  const SwTOXType* pTmp = pSh->GetTOXType(TOX_USER, i);
227  if(pTmp && pTmp->GetTypeName() == rStr)
228  return i;
229  }
230  SwTOXType aUserType(*pSh->GetDoc(), TOX_USER, rStr);
231  pSh->InsertTOXType(aUserType);
232  return nSize;
233 }
234 
235 // traveling between TOXMarks
236 void SwTOXMgr::NextTOXMark(bool bSame)
237 {
238  OSL_ENSURE(pCurTOXMark, "no current TOXMark");
239  if( pCurTOXMark )
240  {
241  SwTOXSearch eDir = bSame ? TOX_SAME_NXT : TOX_NXT;
242  pCurTOXMark = const_cast<SwTOXMark*>(&pSh->GotoTOXMark( *pCurTOXMark, eDir ));
243  }
244 }
245 
246 void SwTOXMgr::PrevTOXMark(bool bSame)
247 {
248  OSL_ENSURE(pCurTOXMark, "no current TOXMark");
249  if( pCurTOXMark )
250  {
251  SwTOXSearch eDir = bSame ? TOX_SAME_PRV : TOX_PRV;
252  pCurTOXMark = const_cast<SwTOXMark*>(&pSh->GotoTOXMark(*pCurTOXMark, eDir ));
253  }
254 }
255 
257 {
258  return pSh->GetTOXType(eTyp, 0);
259 }
260 
261 void SwTOXMgr::SetCurTOXMark(sal_uInt16 nId)
262 {
263  pCurTOXMark = (nId < aCurMarks.size()) ? aCurMarks[nId] : nullptr;
264 }
265 
267  SwTOXBase** ppBase,
268  const SfxItemSet* pSet)
269 {
270  SwWait aWait( *pSh->GetView().GetDocShell(), true );
271  bool bRet = true;
272  const SwTOXBase *const pCurTOX = ppBase && *ppBase ? *ppBase : pSh->GetCurTOX();
273 
274  SwTOXBase * pNewTOX = pCurTOX ? new SwTOXBase(*pCurTOX) : nullptr;
275 
276  TOXTypes eCurTOXType = rDesc.GetTOXType();
277  if(pCurTOX && !ppBase && pSh->HasSelection())
278  pSh->EnterStdMode();
279 
280  switch(eCurTOXType)
281  {
282  case TOX_INDEX :
283  {
284  if(!pCurTOX || (ppBase && !(*ppBase)))
285  {
286  const SwTOXType* pType = pSh->GetTOXType(eCurTOXType, 0);
287  SwForm aForm(eCurTOXType);
288  pNewTOX = new SwTOXBase(pType, aForm, SwTOXElement::Mark, pType->GetTypeName());
289  }
290  pNewTOX->SetOptions(rDesc.GetIndexOptions());
293  pSh->ApplyAutoMark();
294  }
295  break;
296  case TOX_CONTENT :
297  {
298  if(!pCurTOX || (ppBase && !(*ppBase)))
299  {
300  const SwTOXType* pType = pSh->GetTOXType(eCurTOXType, 0);
301  SwForm aForm(eCurTOXType);
302  pNewTOX = new SwTOXBase(pType, aForm, rDesc.GetContentOptions(), pType->GetTypeName());
303  }
304  pNewTOX->SetCreate(rDesc.GetContentOptions());
305  pNewTOX->SetLevel(rDesc.GetLevel());
306  }
307  break;
308  case TOX_USER :
309  {
310  if(!pCurTOX || (ppBase && !(*ppBase)))
311  {
312  sal_uInt16 nPos = 0;
313  sal_uInt16 nSize = pSh->GetTOXTypeCount(eCurTOXType);
314  for(sal_uInt16 i=0; rDesc.GetTOUName() && i < nSize; ++i)
315  { const SwTOXType* pType = pSh->GetTOXType(TOX_USER, i);
316  if(pType->GetTypeName() == *rDesc.GetTOUName())
317  { nPos = i;
318  break;
319  }
320  }
321  const SwTOXType* pType = pSh->GetTOXType(eCurTOXType, nPos);
322 
323  SwForm aForm(eCurTOXType);
324  pNewTOX = new SwTOXBase(pType, aForm, rDesc.GetContentOptions(), pType->GetTypeName());
325 
326  }
327  else
328  {
329  pNewTOX->SetCreate(rDesc.GetContentOptions());
330  }
331  pNewTOX->SetLevelFromChapter(rDesc.IsLevelFromChapter());
332  }
333  break;
334  case TOX_CITATION: break;
335  case TOX_OBJECTS:
336  case TOX_TABLES:
337  case TOX_AUTHORITIES:
338  case TOX_BIBLIOGRAPHY:
339  case TOX_ILLUSTRATIONS:
340  {
341  //Special handling for TOX_AUTHORITY
342  if(TOX_AUTHORITIES == eCurTOXType)
343  {
344  SwAuthorityFieldType* pFType = static_cast<SwAuthorityFieldType*>(
346  if (!pFType)
347  {
349  pFType = static_cast<SwAuthorityFieldType*>(
351  }
352  OUString const& rBrackets(rDesc.GetAuthBrackets());
353  if (rBrackets.isEmpty())
354  {
355  pFType->SetPreSuffix('\0', '\0');
356  }
357  else
358  {
359  assert(rBrackets.getLength() == 2);
360  pFType->SetPreSuffix(rBrackets[0], rBrackets[1]);
361  }
362  pFType->SetSequence(rDesc.IsAuthSequence());
363  SwTOXSortKey rArr[3];
364  rArr[0] = rDesc.GetSortKey1();
365  rArr[1] = rDesc.GetSortKey2();
366  rArr[2] = rDesc.GetSortKey3();
367  pFType->SetSortKeys(3, rArr);
368  pFType->SetSortByDocument(rDesc.IsSortByDocument());
369  pFType->SetLanguage(rDesc.GetLanguage());
370  pFType->SetSortAlgorithm(rDesc.GetSortAlgorithm());
371 
372  pFType->UpdateFields();
373  }
374  // TODO: consider properties of the current TOXType
375  if(!pCurTOX || (ppBase && !(*ppBase)))
376  {
377  const SwTOXType* pType = pSh->GetTOXType(eCurTOXType, 0);
378  SwForm aForm(eCurTOXType);
379  pNewTOX = new SwTOXBase(
380  pType, aForm,
382  pType->GetTypeName());
383  }
385  pNewTOX->SetOLEOptions(rDesc.GetOLEOptions());
386  }
387  break;
388  }
389 
390  OSL_ENSURE(pNewTOX, "no TOXBase created!" );
391  if(!pNewTOX)
392  return false;
393 
394  pNewTOX->SetFromChapter(rDesc.IsFromChapter());
395  pNewTOX->SetSequenceName(rDesc.GetSequenceName());
396  pNewTOX->SetCaptionDisplay(rDesc.GetCaptionDisplay());
397  pNewTOX->SetProtected(rDesc.IsReadonly());
398 
399  for(sal_uInt16 nLevel = 0; nLevel < MAXLEVEL; nLevel++)
400  pNewTOX->SetStyleNames(rDesc.GetStyleNames(nLevel), nLevel);
401 
402  if(rDesc.GetTitle())
403  pNewTOX->SetTitle(*rDesc.GetTitle());
404  if(rDesc.GetForm())
405  pNewTOX->SetTOXForm(*rDesc.GetForm());
406  pNewTOX->SetLanguage(rDesc.GetLanguage());
407  pNewTOX->SetSortAlgorithm(rDesc.GetSortAlgorithm());
408 
409  if(!pCurTOX || (ppBase && !(*ppBase)) )
410  {
411  // when ppBase is passed over, TOXBase is only created here
412  // and then inserted in a global document by the dialog
413  if(ppBase)
414  (*ppBase) = pNewTOX;
415  else
416  {
417  pSh->InsertTableOf(*pNewTOX, pSet);
418  delete pNewTOX;
419  }
420  }
421  else
422  {
423  SwDoc * pDoc = pSh->GetDoc();
424 
425  if (pDoc->GetIDocumentUndoRedo().DoesUndo())
426  {
428  }
429 
430  SwTOXBase *const pTOX = const_cast<SwTOXBase*>(pCurTOX);
431  pDoc->ChangeTOX(*pTOX, *pNewTOX);
432 
433  pTOX->DisableKeepExpression();
434  pSh->UpdateTableOf(*pTOX, pSet);
435  bRet = false;
436  pTOX->EnableKeepExpression();
437 
438  if (pDoc->GetIDocumentUndoRedo().DoesUndo())
439  {
441  }
442  }
443 
444  return bRet;
445 }
446 
448  SwTOXSortKey eKey2,
449  SwTOXSortKey eKey3)
450 {
451  SwTOXSortKey aArr[3];
452  sal_uInt16 nPos = 0;
453  if(AUTH_FIELD_END > eKey1.eField)
454  aArr[nPos++] = eKey1;
455  if(AUTH_FIELD_END > eKey2.eField)
456  aArr[nPos++] = eKey2;
457  if(AUTH_FIELD_END > eKey3.eField)
458  aArr[nPos++] = eKey3;
459 
460  m_eSortKey1 = aArr[0];
461  m_eSortKey2 = aArr[1];
462  m_eSortKey3 = aArr[2];
463 }
464 
466 {
467  for(sal_uInt16 i = 0; i < MAXLEVEL; i++)
468  rTOXBase.SetStyleNames(GetStyleNames(i), i);
469  rTOXBase.SetTitle(GetTitle() ? *GetTitle() : OUString());
470  rTOXBase.SetCreate(GetContentOptions());
471 
472  if(GetTOXType() == TOX_INDEX)
473  rTOXBase.SetOptions(GetIndexOptions());
474  if(GetTOXType() != TOX_INDEX)
475  rTOXBase.SetLevel(GetLevel());
477  rTOXBase.SetSequenceName(GetSequenceName());
479  rTOXBase.SetFromChapter(IsFromChapter());
480  rTOXBase.SetProtected(IsReadonly());
481  rTOXBase.SetOLEOptions(GetOLEOptions());
483  rTOXBase.SetLanguage(m_eLanguage);
485 
486 }
487 
488 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
SwFieldType * GetFieldType(size_t nField, SwFieldIds nResId=SwFieldIds::Unknown) const
get field types with a ResId, if 0 get all
Definition: edfld.cxx:64
void SetLevelFromChapter(bool bSet)
Definition: tox.hxx:544
TOXTypes
Definition: toxe.hxx:39
void SetLanguage(LanguageType nLang)
Definition: tox.hxx:561
bool IsAlternativeText() const
Definition: tox.hxx:590
SwTOXElement GetContentOptions() const
Definition: toxmgr.hxx:110
std::optional< OUString > const & GetTOUName() const
Definition: toxmgr.hxx:104
void DisableKeepExpression()
Definition: tox.hxx:492
SAL_DLLPRIVATE sal_uInt16 GetUserTypeID(const OUString &rStr)
Definition: toxmgr.cxx:221
bool IsMainEntry() const
Definition: toxmgr.hxx:202
Definition: toxe.hxx:25
std::optional< OUString > const & GetPhoneticReadingOfSecKey() const
Definition: toxmgr.hxx:223
const SwTOXSortKey & GetSortKey2() const
Definition: toxmgr.hxx:156
void NextTOXMark(bool bSame=false)
Definition: toxmgr.cxx:236
void SetLevel(sal_uInt16 nLevel)
Definition: tox.hxx:607
Definition: tox.hxx:315
const OUString & GetSequenceName() const
Definition: toxmgr.hxx:124
TOXTypes GetTOXType() const
Definition: toxmgr.hxx:90
void SetSortAlgorithm(const OUString &rSet)
Definition: authfld.hxx:140
void SetTitle(const OUString &rTitle)
Definition: tox.cxx:621
LanguageType m_eLanguage
Definition: toxmgr.hxx:50
virtual SwUndoId EndUndo(SwUndoId const eUndoId, SwRewriter const *const pRewriter)=0
Closes undo block.
Definition: doc.hxx:187
void SetTOIAutoMarkURL(const OUString &rSet)
Definition: edtox.cxx:259
sal_Int16 nId
std::optional< OUString > const & GetSecKey() const
Definition: toxmgr.hxx:208
void EnterStdMode()
Definition: select.cxx:550
IDocumentUndoRedo & GetIDocumentUndoRedo()
Definition: doc.cxx:144
const SwTOXType * GetTOXType(TOXTypes eTyp) const
Definition: toxmgr.cxx:256
const SwTOXType * GetTOXType() const
Definition: tox.hxx:587
void SetModified()
Definition: edws.cxx:70
void UpdateTOXMark(const SwTOXMarkDescription &rDesc)
Definition: toxmgr.cxx:148
void EndAllAction()
Definition: edws.cxx:97
void SetOptions(SwTOIOptions nOpt)
Definition: tox.hxx:761
void SetOLEOptions(SwTOOElements nOpt)
Definition: tox.hxx:523
sal_uInt16 GetTOXTypeCount(TOXTypes eTyp) const
Manage types of content tables.
Definition: edws.cxx:190
void UpdateFields() const
Definition: fldbas.cxx:148
Used by the UI to modify the document model.
Definition: wrtsh.hxx:91
void SetCreate(SwTOXElement)
Definition: tox.hxx:734
void SetPreSuffix(sal_Unicode cPre, sal_Unicode cSuf)
Definition: authfld.hxx:113
SwCaptionDisplay GetCaptionDisplay() const
Definition: toxmgr.hxx:127
std::optional< OUString > const & GetPhoneticReadingOfPrimKey() const
Definition: toxmgr.hxx:220
const SwView & GetView() const
Definition: wrtsh.hxx:429
void DeleteTOXMark(SwTOXMark const *pMark)
Definition: edtox.cxx:75
SwTOIOptions GetIndexOptions() const
Definition: toxmgr.hxx:113
TOXTypes GetTOXType() const
Definition: toxmgr.hxx:196
const BorderLinePrimitive2D *pCandidateB assert(pCandidateA)
SwTOXSearch
Definition: toxe.hxx:22
bool IsCreateFromObjectNames() const
Definition: toxmgr.hxx:122
bool IsLevelFromChapter() const
Definition: toxmgr.hxx:139
const sal_uInt8 MAXLEVEL
Definition: swtypes.hxx:95
void SetSortByDocument(bool bSet)
Definition: authfld.hxx:122
SwTOXMarks aCurMarks
Definition: toxmgr.hxx:230
SwTOXMgr(SwWrtShell *pShell)
Definition: toxmgr.cxx:29
void SetSortAlgorithm(const OUString &rSet)
Definition: tox.hxx:564
SwDoc * GetDoc() const
Definition: viewsh.hxx:281
const SwTOXBase * GetCurTOX() const
Get current listing before or at the Cursor.
Definition: edtox.cxx:187
void PrevTOXMark(bool bSame=false)
Definition: toxmgr.cxx:246
void SetAlternativeText(const OUString &rAlt)
Definition: tox.hxx:593
virtual bool DoesUndo() const =0
Is Undo enabled?
void UpdateTableOf(const SwTOXBase &rTOX, const SfxItemSet *pSet=nullptr)
Definition: wrtsh2.cxx:326
bool IsAuthSequence() const
Definition: toxmgr.hxx:145
bool IsFromChapter() const
Definition: toxmgr.hxx:131
const SwTOXSortKey & GetSortKey3() const
Definition: toxmgr.hxx:157
void SetSequence(bool bSet)
Definition: authfld.hxx:107
virtual SwUndoId StartUndo(SwUndoId const eUndoId, SwRewriter const *const pRewriter)=0
Opens undo block.
bool HasSelection() const
Definition: wrtsh.hxx:142
sal_uInt8 GetLevel() const
Definition: toxmgr.hxx:119
int i
SwFieldType * InsertFieldType(const SwFieldType &)
insert field type
Definition: edfld.cxx:341
void SetPrimaryKey(const OUString &rStr)
Definition: tox.hxx:613
const OUString & GetSortAlgorithm() const
Definition: toxmgr.hxx:162
void SetTextReading(const OUString &rStr)
Definition: tox.hxx:625
SwTOXSortKey m_eSortKey3
Definition: toxmgr.hxx:57
SwTOOElements GetOLEOptions() const
Definition: toxmgr.hxx:136
SwTOXMark * GetTOXMark(sal_uInt16 nId)
Definition: toxmgr.cxx:36
void InsertTableOf(const SwTOXBase &rTOX, const SfxItemSet *pSet=nullptr)
Definition: wrtsh2.cxx:313
void SetSequenceName(const OUString &rSet)
Definition: tox.hxx:550
void SetMainEntryCharStyle(const OUString &rSet)
Definition: tox.hxx:507
const SvxPageUsage aArr[]
const OUString & GetAutoMarkURL() const
Definition: toxmgr.hxx:97
void SetCaptionDisplay(SwCaptionDisplay eSet)
Definition: tox.hxx:553
void SetPrimaryKeyReading(const OUString &rStr)
Definition: tox.hxx:631
void SetFromChapter(bool bSet)
Definition: tox.hxx:538
bool IsReadonly() const
Definition: toxmgr.hxx:134
const OUString & GetTypeName() const
Definition: tox.hxx:705
Definition: toxe.hxx:24
std::optional< OUString > const & GetPhoneticReadingOfAltStr() const
Definition: toxmgr.hxx:217
SwWrtShell * pSh
Definition: toxmgr.hxx:228
void ChangeTOX(SwTOXBase &rTOX, const SwTOXBase &rNew)
Definition: doc.cxx:1725
void SetLanguage(LanguageType nLang)
Definition: authfld.hxx:137
SwDocShell * GetDocShell()
Definition: view.cxx:1110
int GetLevel() const
Definition: toxmgr.hxx:199
void SetTOXForm(const SwForm &rForm)
Definition: tox.hxx:737
void SetCurTOXMark(sal_uInt16 nId)
Definition: toxmgr.cxx:261
void InsertTOXType(const SwTOXType &rTyp)
Definition: edws.cxx:195
const OUString & GetMainEntryCharStyle() const
Definition: toxmgr.hxx:115
const SwForm * GetForm() const
Definition: toxmgr.hxx:107
ToxAuthorityField eField
Definition: authfld.hxx:51
std::optional< OUString > const & GetTitle() const
Definition: toxmgr.hxx:101
LanguageType GetLanguage() const
Definition: toxmgr.hxx:159
bool Left(sal_uInt16 nMode, bool bSelect, sal_uInt16 nCount, bool bBasicCall, bool bVisual=false)
Definition: move.cxx:110
const SwTOXSortKey & GetSortKey1() const
Definition: toxmgr.hxx:155
void ApplyTo(SwTOXBase &rTOXBase)
Definition: toxmgr.cxx:465
void SetStyleNames(const OUString &rSet, sal_uInt16 nLevel)
Definition: tox.hxx:532
void SetSortKeys(SwTOXSortKey eKey1, SwTOXSortKey eKey2, SwTOXSortKey eKey3)
Definition: toxmgr.cxx:447
SwTOXSortKey m_eSortKey1
Definition: toxmgr.hxx:55
void EnableKeepExpression()
Definition: tox.hxx:491
std::optional< OUString > const & GetAltStr() const
Definition: toxmgr.hxx:211
void SetSecondaryKey(const OUString &rStr)
Definition: tox.hxx:619
const SwTOXType * GetTOXType(TOXTypes eTyp, sal_uInt16 nId) const
Definition: edtox.cxx:199
TOXTypes GetType() const
Definition: tox.hxx:708
const SwTOXMark & GotoTOXMark(const SwTOXMark &rStart, SwTOXSearch eDir)
traveling between marks
Definition: crstrvl.cxx:602
void GetCurTOXMarks(SwTOXMarks &rMarks) const
Get all marks at current SPoint.
Definition: edtox.cxx:86
std::optional< OUString > const & GetTOUName() const
Definition: toxmgr.hxx:214
void SetProtected(bool bSet)
Definition: tox.hxx:547
const sal_uInt16 CRSR_SKIP_CHARS
Definition: swcrsr.hxx:65
SwTOXMark * pCurTOXMark
Definition: toxmgr.hxx:229
ResultType type
void InsertTOXMark(const SwTOXMarkDescription &rDesc)
Definition: toxmgr.cxx:59
OUString m_sSortAlgorithm
Definition: toxmgr.hxx:51
void ApplyAutoMark()
Definition: edtox.cxx:264
const OUString & GetStyleNames(sal_uInt16 nLvl) const
Definition: toxmgr.hxx:92
void SetLevel(sal_uInt16)
Definition: tox.hxx:743
void DeleteTOXMark()
Definition: toxmgr.cxx:43
void StartAllAction()
For all views of this document.
Definition: edws.cxx:86
void SetSecondaryKeyReading(const OUString &rStr)
Definition: tox.hxx:637
void SetMainEntry(bool bSet)
Definition: tox.hxx:158
SwTOXSortKey m_eSortKey2
Definition: toxmgr.hxx:56
void SetFromObjectNames(bool bSet)
Definition: tox.hxx:541
bool IsSortByDocument() const
Definition: toxmgr.hxx:148
void SetSortKeys(sal_uInt16 nKeyCount, SwTOXSortKey const nKeys[])
Definition: authfld.cxx:439
sal_uInt16 nPos
bool UpdateOrInsertTOX(const SwTOXDescription &rDesc, SwTOXBase **ppBase, const SfxItemSet *pSet)
Definition: toxmgr.cxx:266
std::optional< OUString > const & GetPrimKey() const
Definition: toxmgr.hxx:205
const OUString & GetAuthBrackets() const
Definition: toxmgr.hxx:142