LibreOffice Module sw (master) 1
xmldump.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
10#include <frame.hxx>
11#include <frmfmt.hxx>
12#include <ftnfrm.hxx>
13#include <sectfrm.hxx>
14#include <tabfrm.hxx>
15#include <pagefrm.hxx>
16#include <txtfrm.hxx>
17#include <cellfrm.hxx>
18#include <flyfrm.hxx>
19#include <hffrm.hxx>
20#include <rootfrm.hxx>
21#include <ndtxt.hxx>
22#include <sortedobjs.hxx>
23#include <swfont.hxx>
24#include <txttypes.hxx>
25#include <anchoredobject.hxx>
26#include <libxml/xmlwriter.h>
27#include <SwPortionHandler.hxx>
28#include <view.hxx>
29#include <svx/svdobj.hxx>
30
31#include "porlay.hxx"
32
34{
35 switch (nType)
36 {
38 return "PortionType::NONE";
40 return "PortionType::FlyCnt";
41
43 return "PortionType::Hole";
45 return "PortionType::TempEnd";
47 return "PortionType::Break";
49 return "PortionType::Kern";
51 return "PortionType::Arrow";
53 return "PortionType::Multi";
55 return "PortionType::HiddenText";
57 return "PortionType::ControlChar";
59 return "PortionType::Bookmark";
60
62 return "PortionType::Text";
64 return "PortionType::Lay";
66 return "PortionType::Para";
68 return "PortionType::Hanging";
69
71 return "PortionType::Drop";
73 return "PortionType::Tox";
75 return "PortionType::IsoTox";
77 return "PortionType::Ref";
79 return "PortionType::IsoRef";
81 return "PortionType::Meta";
83 return "PortionType::ContentControl";
85 return "PortionType::FieldMark";
87 return "PortionType::FieldFormCheckbox";
89 return "PortionType::InputField";
90
92 return "PortionType::Expand";
94 return "PortionType::Blank";
96 return "PortionType::PostIts";
97
99 return "PortionType::Hyphen";
101 return "PortionType::HyphenStr";
103 return "PortionType::SoftHyphen";
105 return "PortionType::SoftHyphenStr";
107 return "PortionType::SoftHyphenComp";
108
110 return "PortionType::Field";
112 return "PortionType::Hidden";
114 return "PortionType::QuoVadis";
116 return "PortionType::ErgoSum";
118 return "PortionType::Combined";
120 return "PortionType::Footnote";
121
123 return "PortionType::FootnoteNum";
125 return "PortionType::Number";
127 return "PortionType::Bullet";
129 return "PortionType::GrfNum";
130
132 return "PortionType::Glue";
133
135 return "PortionType::Margin";
136
137 case PortionType::Fix:
138 return "PortionType::Fix";
139 case PortionType::Fly:
140 return "PortionType::Fly";
141
142 case PortionType::Tab:
143 return "PortionType::Tab";
144
146 return "PortionType::TabRight";
148 return "PortionType::TabCenter";
150 return "PortionType::TabDecimal";
151
153 return "PortionType::TabLeft";
154 default:
155 return "Unknown";
156 }
157}
158
159namespace {
160 xmlTextWriterPtr lcl_createDefaultWriter()
161 {
162 xmlTextWriterPtr writer = xmlNewTextWriterFilename( "layout.xml", 0 );
163 xmlTextWriterSetIndent(writer,1);
164 (void)xmlTextWriterSetIndentString(writer, BAD_CAST(" "));
165 (void)xmlTextWriterStartDocument( writer, nullptr, nullptr, nullptr );
166 return writer;
167 }
168
169 void lcl_freeWriter( xmlTextWriterPtr writer )
170 {
171 (void)xmlTextWriterEndDocument( writer );
172 xmlFreeTextWriter( writer );
173 }
174}
175
177{
178 const SwFrame* pFrame = this;
179 while (pFrame->GetUpper())
180 {
181 pFrame = pFrame->GetUpper();
182 }
183
184 pFrame->dumpAsXml(writer);
185}
186
188{
189 bool bCreateWriter = ( nullptr == writer );
190 if ( bCreateWriter )
191 writer = lcl_createDefaultWriter();
192
193 const char *name = nullptr;
194
195 switch ( GetType( ) )
196 {
198 name = "root";
199 break;
201 name = "page";
202 break;
204 name = "column";
205 break;
207 name = "header";
208 break;
210 name = "footer";
211 break;
213 name = "ftncont";
214 break;
215 case SwFrameType::Ftn:
216 name = "ftn";
217 break;
219 name = "body";
220 break;
221 case SwFrameType::Fly:
222 name = "fly";
223 break;
225 name = "section";
226 break;
227 case SwFrameType::Tab:
228 name = "tab";
229 break;
230 case SwFrameType::Row:
231 name = "row";
232 break;
234 name = "cell";
235 break;
236 case SwFrameType::Txt:
237 name = "txt";
238 break;
240 name = "notxt";
241 break;
242 default: break;
243 }
244
245 if ( name != nullptr )
246 {
247 (void)xmlTextWriterStartElement( writer, reinterpret_cast<const xmlChar *>(name) );
248
249 dumpAsXmlAttributes( writer );
250
251 if (IsRootFrame())
252 {
253 const SwRootFrame* pRootFrame = static_cast<const SwRootFrame*>(this);
254 (void)xmlTextWriterStartElement(writer, BAD_CAST("sfxViewShells"));
255 SwView* pView = static_cast<SwView*>(SfxViewShell::GetFirst(true, checkSfxViewShell<SwView>));
256 while (pView)
257 {
258 if (pRootFrame->GetCurrShell()->GetSfxViewShell() && pView->GetObjectShell() == pRootFrame->GetCurrShell()->GetSfxViewShell()->GetObjectShell())
259 pView->dumpAsXml(writer);
260 pView = static_cast<SwView*>(SfxViewShell::GetNext(*pView, true, checkSfxViewShell<SwView>));
261 }
262 (void)xmlTextWriterEndElement(writer);
263 }
264
265 if (IsPageFrame())
266 {
267 const SwPageFrame* pPageFrame = static_cast<const SwPageFrame*>(this);
268 (void)xmlTextWriterStartElement(writer, BAD_CAST("page_status"));
269 (void)xmlTextWriterWriteAttribute(writer, BAD_CAST("ValidFlyLayout"), BAD_CAST(OString::boolean(!pPageFrame->IsInvalidFlyLayout()).getStr()));
270 (void)xmlTextWriterWriteAttribute(writer, BAD_CAST("ValidFlyContent"), BAD_CAST(OString::boolean(!pPageFrame->IsInvalidFlyContent()).getStr()));
271 (void)xmlTextWriterWriteAttribute(writer, BAD_CAST("ValidFlyInCnt"), BAD_CAST(OString::boolean(!pPageFrame->IsInvalidFlyInCnt()).getStr()));
272 (void)xmlTextWriterWriteAttribute(writer, BAD_CAST("ValidLayout"), BAD_CAST(OString::boolean(!pPageFrame->IsInvalidLayout()).getStr()));
273 (void)xmlTextWriterWriteAttribute(writer, BAD_CAST("ValidContent"), BAD_CAST(OString::boolean(!pPageFrame->IsInvalidContent()).getStr()));
274 (void)xmlTextWriterEndElement(writer);
275 (void)xmlTextWriterStartElement(writer, BAD_CAST("page_info"));
276 (void)xmlTextWriterWriteFormatAttribute(writer, BAD_CAST("phyNum"), "%d", pPageFrame->GetPhyPageNum());
277 (void)xmlTextWriterWriteFormatAttribute(writer, BAD_CAST("virtNum"), "%d", pPageFrame->GetVirtPageNum());
278 OUString aFormatName = pPageFrame->GetPageDesc()->GetName();
279 (void)xmlTextWriterWriteFormatAttribute( writer, BAD_CAST("pageDesc"), "%s", BAD_CAST(OUStringToOString(aFormatName, RTL_TEXTENCODING_UTF8).getStr()));
280 (void)xmlTextWriterEndElement(writer);
281 if (auto const* pObjs = pPageFrame->GetSortedObjs())
282 {
283 (void)xmlTextWriterStartElement(writer, BAD_CAST("sorted_objs"));
284 for (SwAnchoredObject const*const pObj : *pObjs)
285 { // just print pointer, full details will be printed on its anchor frame
286 // this nonsense is needed because of multiple inheritance
287 if (SwFlyFrame const* pFly = pObj->DynCastFlyFrame())
288 {
289 (void)xmlTextWriterStartElement(writer, BAD_CAST("fly"));
290 (void)xmlTextWriterWriteFormatAttribute(writer, BAD_CAST("ptr"), "%p", pFly);
291 }
292 else
293 {
294 (void)xmlTextWriterStartElement(writer, BAD_CAST(pObj->getElementName()));
295 (void)xmlTextWriterWriteFormatAttribute(writer, BAD_CAST("ptr"), "%p", pObj);
296 }
297 (void)xmlTextWriterEndElement(writer);
298 }
299 (void)xmlTextWriterEndElement(writer);
300 }
301 }
302
303 if (IsTextFrame())
304 {
305 const SwTextFrame *pTextFrame = static_cast<const SwTextFrame *>(this);
306 sw::MergedPara const*const pMerged(pTextFrame->GetMergedPara());
307 if (pMerged)
308 {
309 (void)xmlTextWriterStartElement( writer, BAD_CAST( "merged" ) );
310 (void)xmlTextWriterWriteFormatAttribute( writer, BAD_CAST( "paraPropsNodeIndex" ), "%" SAL_PRIdINT32, sal_Int32(pMerged->pParaPropsNode->GetIndex()) );
311 for (auto const& e : pMerged->extents)
312 {
313 (void)xmlTextWriterStartElement( writer, BAD_CAST( "extent" ) );
314 (void)xmlTextWriterWriteFormatAttribute( writer, BAD_CAST( "txtNodeIndex" ), "%" SAL_PRIdINT32, sal_Int32(e.pNode->GetIndex()) );
315 (void)xmlTextWriterWriteFormatAttribute( writer, BAD_CAST( "start" ), "%" SAL_PRIdINT32, e.nStart );
316 (void)xmlTextWriterWriteFormatAttribute( writer, BAD_CAST( "end" ), "%" SAL_PRIdINT32, e.nEnd );
317 (void)xmlTextWriterEndElement( writer );
318 }
319 (void)xmlTextWriterEndElement( writer );
320 }
321 }
322
323 if (IsCellFrame())
324 {
325 SwCellFrame const* pCellFrame(static_cast<SwCellFrame const*>(this));
326 (void)xmlTextWriterWriteFormatAttribute( writer, BAD_CAST( "rowspan" ), "%ld", pCellFrame->GetLayoutRowSpan() );
327 }
328
329 (void)xmlTextWriterStartElement( writer, BAD_CAST( "infos" ) );
330 dumpInfosAsXml( writer );
331 (void)xmlTextWriterEndElement( writer );
332
333 // Dump Anchored objects if any
334 const SwSortedObjs* pAnchored = GetDrawObjs();
335 if ( pAnchored && pAnchored->size() > 0 )
336 {
337 (void)xmlTextWriterStartElement( writer, BAD_CAST( "anchored" ) );
338
339 for (SwAnchoredObject* pObject : *pAnchored)
340 {
341 pObject->dumpAsXml( writer );
342 }
343
344 (void)xmlTextWriterEndElement( writer );
345 }
346
347 // Dump the children
348 if ( IsTextFrame( ) )
349 {
350 const SwTextFrame *pTextFrame = static_cast<const SwTextFrame *>(this);
351 OUString aText = pTextFrame->GetText( );
352 for ( int i = 0; i < 32; i++ )
353 {
354 aText = aText.replace( i, '*' );
355 }
356 OString aText8 =OUStringToOString( aText,
357 RTL_TEXTENCODING_UTF8 );
358 (void)xmlTextWriterWriteString( writer,
359 reinterpret_cast<const xmlChar *>(aText8.getStr( )) );
360 if (const SwParaPortion* pPara = pTextFrame->GetPara())
361 {
362 (void)xmlTextWriterStartElement(writer, BAD_CAST("SwParaPortion"));
363 TextFrameIndex nOffset(0);
364 const OUString& rText = pTextFrame->GetText();
365 pPara->dumpAsXmlAttributes(writer, rText, nOffset);
366 const SwLineLayout* pLine = pPara;
367 if (pTextFrame->IsFollow())
368 {
369 nOffset += pTextFrame->GetOffset();
370 }
371 while (pLine)
372 {
373 (void)xmlTextWriterStartElement(writer, BAD_CAST("SwLineLayout"));
374 pLine->dumpAsXmlAttributes(writer, rText, nOffset);
375 const SwLinePortion* pPor = pLine->GetFirstPortion();
376 while (pPor)
377 {
378 pPor->dumpAsXml(writer, rText, nOffset);
379 pPor = pPor->GetNextPortion();
380 }
381 (void)xmlTextWriterEndElement(writer);
382 pLine = pLine->GetNext();
383 }
384 (void)xmlTextWriterEndElement(writer);
385 }
386
387 }
388 else
389 {
390 dumpChildrenAsXml( writer );
391 }
392 (void)xmlTextWriterEndElement( writer );
393 }
394
395 if ( bCreateWriter )
396 lcl_freeWriter( writer );
397}
398
400{
401 // output the Frame
402 (void)xmlTextWriterStartElement( writer, BAD_CAST( "bounds" ) );
404 (void)xmlTextWriterWriteAttribute(writer, BAD_CAST("mbFixSize"), BAD_CAST(OString::boolean(HasFixSize()).getStr()));
405 (void)xmlTextWriterWriteAttribute(writer, BAD_CAST("mbFrameAreaPositionValid"), BAD_CAST(OString::boolean(isFrameAreaPositionValid()).getStr()));
406 (void)xmlTextWriterWriteAttribute(writer, BAD_CAST("mbFrameAreaSizeValid"), BAD_CAST(OString::boolean(isFrameAreaSizeValid()).getStr()));
407 (void)xmlTextWriterWriteAttribute(writer, BAD_CAST("mbFramePrintAreaValid"), BAD_CAST(OString::boolean(isFramePrintAreaValid()).getStr()));
408 (void)xmlTextWriterEndElement( writer );
409
410 // output the print area
411 (void)xmlTextWriterStartElement( writer, BAD_CAST( "prtBounds" ) );
413 (void)xmlTextWriterEndElement( writer );
414}
415
417{
418 (void)xmlTextWriterWriteFormatAttribute( writer, BAD_CAST( "ptr" ), "%p", this );
419 (void)xmlTextWriterWriteFormatAttribute( writer, BAD_CAST( "id" ), "%" SAL_PRIuUINT32, GetFrameId() );
420 (void)xmlTextWriterWriteFormatAttribute( writer, BAD_CAST( "symbol" ), "%s", BAD_CAST( typeid( *this ).name( ) ) );
421 if ( GetNext( ) )
422 (void)xmlTextWriterWriteFormatAttribute( writer, BAD_CAST( "next" ), "%" SAL_PRIuUINT32, GetNext()->GetFrameId() );
423 if ( GetPrev( ) )
424 (void)xmlTextWriterWriteFormatAttribute( writer, BAD_CAST( "prev" ), "%" SAL_PRIuUINT32, GetPrev()->GetFrameId() );
425 if ( GetUpper( ) )
426 (void)xmlTextWriterWriteFormatAttribute( writer, BAD_CAST( "upper" ), "%" SAL_PRIuUINT32, GetUpper()->GetFrameId() );
427 if ( GetLower( ) )
428 (void)xmlTextWriterWriteFormatAttribute( writer, BAD_CAST( "lower" ), "%" SAL_PRIuUINT32, GetLower()->GetFrameId() );
429 if (IsFootnoteFrame())
430 {
431 SwFootnoteFrame const*const pFF(static_cast<SwFootnoteFrame const*>(this));
432 (void)xmlTextWriterWriteFormatAttribute( writer, BAD_CAST("ref"), "%" SAL_PRIuUINT32, pFF->GetRef()->GetFrameId() );
433 if (pFF->GetMaster())
434 (void)xmlTextWriterWriteFormatAttribute( writer, BAD_CAST("master"), "%" SAL_PRIuUINT32, pFF->GetMaster()->GetFrameId() );
435 if (pFF->GetFollow())
436 (void)xmlTextWriterWriteFormatAttribute( writer, BAD_CAST("follow"), "%" SAL_PRIuUINT32, pFF->GetFollow()->GetFrameId() );
437 }
438 if (IsSctFrame())
439 {
440 SwSectionFrame const*const pFrame(static_cast<SwSectionFrame const*>(this));
441 SwSectionNode const*const pNode(pFrame->GetSection() ? pFrame->GetSection()->GetFormat()->GetSectionNode() : nullptr);
442 (void)xmlTextWriterWriteFormatAttribute(writer, BAD_CAST("sectionNodeIndex"), "%" SAL_PRIdINT32, pNode ? sal_Int32(pNode->GetIndex()) : -1);
443 }
444 if ( IsTextFrame( ) )
445 {
446 const SwTextFrame *pTextFrame = static_cast<const SwTextFrame *>(this);
447 const SwTextNode *pTextNode = pTextFrame->GetTextNodeFirst();
448 (void)xmlTextWriterWriteFormatAttribute( writer, BAD_CAST( "txtNodeIndex" ), "%" SAL_PRIdINT32, sal_Int32(pTextNode->GetIndex()) );
449
450 OString aMode = "Horizontal";
451 if (IsVertLRBT())
452 {
453 aMode = "VertBTLR";
454 }
455 else if (IsVertLR())
456 {
457 aMode = "VertLR";
458 }
459 else if (IsVertical())
460 {
461 aMode = "Vertical";
462 }
463 (void)xmlTextWriterWriteAttribute(writer, BAD_CAST("WritingMode"), BAD_CAST(aMode.getStr()));
464 }
465 if (IsHeaderFrame() || IsFooterFrame())
466 {
467 const SwHeadFootFrame *pHeadFootFrame = static_cast<const SwHeadFootFrame*>(this);
468 OUString aFormatName = pHeadFootFrame->GetFormat()->GetName();
469 (void)xmlTextWriterWriteFormatAttribute( writer, BAD_CAST( "fmtName" ), "%s", BAD_CAST(OUStringToOString(aFormatName, RTL_TEXTENCODING_UTF8).getStr()));
470 (void)xmlTextWriterWriteFormatAttribute( writer, BAD_CAST( "fmtPtr" ), "%p", pHeadFootFrame->GetFormat());
471 }
472}
473
475{
476 const SwFrame *pFrame = GetLower( );
477 for ( ; pFrame != nullptr; pFrame = pFrame->GetNext( ) )
478 {
479 pFrame->dumpAsXml( writer );
480 }
481}
482
484{
485 bool bCreateWriter = ( nullptr == writer );
486 if ( bCreateWriter )
487 writer = lcl_createDefaultWriter();
488
489 (void)xmlTextWriterStartElement( writer, BAD_CAST( getElementName() ) );
490 (void)xmlTextWriterWriteFormatAttribute( writer, BAD_CAST( "ptr" ), "%p", this );
491
492 (void)xmlTextWriterStartElement( writer, BAD_CAST( "bounds" ) );
493 // don't call GetObjBoundRect(), it modifies the layout
494 SwRect(GetDrawObj()->GetLastBoundRect()).dumpAsXmlAttributes(writer);
495 (void)xmlTextWriterEndElement( writer );
496
497 if (const SdrObject* pObject = GetDrawObj())
498 pObject->dumpAsXml(writer);
499
500 (void)xmlTextWriterEndElement( writer );
501
502 if ( bCreateWriter )
503 lcl_freeWriter( writer );
504}
505
507{
508 (void)xmlTextWriterStartElement(writer, BAD_CAST("SwFont"));
509 (void)xmlTextWriterWriteFormatAttribute(writer, BAD_CAST("ptr"), "%p", this);
510 // do not use Color::AsRGBHexString() as that omits the transparency
511 (void)xmlTextWriterWriteFormatAttribute(writer, BAD_CAST("color"), "%08" SAL_PRIxUINT32, sal_uInt32(GetColor()));
512 (void)xmlTextWriterEndElement(writer);
513}
514
516{
518 if ( HasFollow() )
519 (void)xmlTextWriterWriteFormatAttribute( writer, BAD_CAST( "follow" ), "%" SAL_PRIuUINT32, GetFollow()->GetFrameId() );
520
521 if (m_pPrecede != nullptr)
522 (void)xmlTextWriterWriteFormatAttribute( writer, BAD_CAST( "precede" ), "%" SAL_PRIuUINT32, static_cast<SwTextFrame*>(m_pPrecede)->GetFrameId() );
523}
524
526{
528 if ( HasFollow() )
529 (void)xmlTextWriterWriteFormatAttribute( writer, BAD_CAST( "follow" ), "%" SAL_PRIuUINT32, GetFollow()->GetFrameId() );
530
531 if (m_pPrecede != nullptr)
532 (void)xmlTextWriterWriteFormatAttribute( writer, BAD_CAST( "precede" ), "%" SAL_PRIuUINT32, static_cast<SwSectionFrame*>( m_pPrecede )->GetFrameId() );
533}
534
536{
538 if ( HasFollow() )
539 (void)xmlTextWriterWriteFormatAttribute( writer, BAD_CAST( "follow" ), "%" SAL_PRIuUINT32, GetFollow()->GetFrameId() );
540
541 if (m_pPrecede != nullptr)
542 (void)xmlTextWriterWriteFormatAttribute( writer, BAD_CAST( "precede" ), "%" SAL_PRIuUINT32, static_cast<SwTabFrame*>( m_pPrecede )->GetFrameId() );
543}
544
545/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
struct _xmlTextWriter * xmlTextWriterPtr
static SfxViewShell * GetNext(const SfxViewShell &rPrev, bool bOnlyVisible=true, const std::function< bool(const SfxViewShell *)> &isViewShell=nullptr)
static SfxViewShell * GetFirst(bool bOnlyVisible=true, const std::function< bool(const SfxViewShell *)> &isViewShell=nullptr)
virtual SfxObjectShell * GetObjectShell() override
wrapper class for the positioning of Writer fly frames and drawing objects
virtual const char * getElementName() const
The element name to show in the XML dump.
virtual void dumpAsXml(xmlTextWriterPtr pWriter) const
Dump a bunch of useful data to an XML representation to ease layout understanding,...
Definition: xmldump.cxx:483
const SdrObject * GetDrawObj() const
SwCellFrame is one table cell in the document layout.
Definition: cellfrm.hxx:31
tools::Long GetLayoutRowSpan() const
Definition: tabfrm.cxx:5638
SwFlowFrame * m_pPrecede
Definition: flowfrm.hxx:119
bool HasFollow() const
Definition: flowfrm.hxx:166
bool IsFollow() const
Definition: flowfrm.hxx:167
general base class for all free-flowing frames
Definition: flyfrm.hxx:79
virtual const SwFlyFrame * DynCastFlyFrame() const override
Definition: fly.cxx:2989
void dumpAsXml(xmlTextWriterPtr writer) const
Definition: xmldump.cxx:506
const Color & GetColor() const
Definition: swfont.hxx:277
const SwFootnoteFrame * GetFollow() const
Definition: ftnfrm.hxx:116
const SwFootnoteFrame * GetMaster() const
Definition: ftnfrm.hxx:119
const SwContentFrame * GetRef() const
Definition: ftnfrm.cxx:2906
const OUString & GetName() const
Definition: format.hxx:131
const SwRect & getFrameArea() const
Definition: frame.hxx:179
bool isFrameAreaPositionValid() const
Definition: frame.hxx:166
const SwRect & getFramePrintArea() const
Definition: frame.hxx:180
bool isFramePrintAreaValid() const
Definition: frame.hxx:168
bool isFrameAreaSizeValid() const
Definition: frame.hxx:167
sal_uInt32 GetFrameId() const
Definition: frame.hxx:174
Base class of the Writer layout elements.
Definition: frame.hxx:315
bool IsCellFrame() const
Definition: frame.hxx:1226
bool IsTextFrame() const
Definition: frame.hxx:1234
sal_uInt16 GetVirtPageNum() const
Definition: trvlfrm.cxx:1817
SwFrame * GetNext()
Definition: frame.hxx:676
bool HasFixSize() const
Definition: frame.hxx:670
bool IsPageFrame() const
Definition: frame.hxx:1178
bool IsVertLRBT() const
Definition: frame.hxx:983
virtual void dumpAsXml(xmlTextWriterPtr writer=nullptr) const
Definition: xmldump.cxx:187
SwFrameType GetType() const
Definition: frame.hxx:519
bool IsHeaderFrame() const
Definition: frame.hxx:1190
const SwSortedObjs * GetDrawObjs() const
Definition: frame.hxx:564
SwFrame * GetLower()
Definition: findfrm.cxx:194
void dumpInfosAsXml(xmlTextWriterPtr writer) const
Definition: xmldump.cxx:399
bool IsRootFrame() const
Definition: frame.hxx:1174
bool IsFooterFrame() const
Definition: frame.hxx:1194
bool IsFootnoteFrame() const
Definition: frame.hxx:1202
SwLayoutFrame * GetUpper()
Definition: frame.hxx:678
virtual void dumpAsXmlAttributes(xmlTextWriterPtr writer) const
Definition: xmldump.cxx:416
bool IsVertical() const
Definition: frame.hxx:973
void dumpTopMostAsXml(xmlTextWriterPtr writer=nullptr) const
Definition: xmldump.cxx:176
SwFrame * GetPrev()
Definition: frame.hxx:677
bool IsSctFrame() const
Definition: frame.hxx:1214
bool IsVertLR() const
Definition: frame.hxx:979
void dumpChildrenAsXml(xmlTextWriterPtr writer) const
Definition: xmldump.cxx:474
virtual const SwFrameFormat * GetFormat() const
Definition: ssfrm.cxx:399
Collection of SwLinePortion instances, representing one line of text.
Definition: porlay.hxx:79
SwLineLayout * GetNext()
Definition: porlay.hxx:159
SwLinePortion * GetFirstPortion() const
Definition: porlay.cxx:841
Base class for anything that can be part of a line in the Writer layout.
Definition: porlin.hxx:52
void dumpAsXmlAttributes(xmlTextWriterPtr writer, std::u16string_view rText, TextFrameIndex nOffset) const
Definition: porlin.cxx:330
SwLinePortion * GetNextPortion() const
Definition: porlin.hxx:75
virtual void dumpAsXml(xmlTextWriterPtr pWriter, const OUString &rText, TextFrameIndex &rOffset) const
Definition: porlin.cxx:321
SwNodeOffset GetIndex() const
Definition: node.hxx:312
const OUString & GetName() const
Definition: pagedesc.hxx:196
A page of the document layout.
Definition: pagefrm.hxx:58
sal_uInt16 GetPhyPageNum() const
Definition: pagefrm.hxx:204
bool IsInvalidFlyContent() const
Definition: pagefrm.hxx:232
const SwSortedObjs * GetSortedObjs() const
Definition: pagefrm.hxx:132
bool IsInvalidFlyLayout() const
Definition: pagefrm.hxx:231
bool IsInvalidContent() const
Definition: pagefrm.hxx:235
SwPageDesc * GetPageDesc()
Definition: pagefrm.hxx:143
bool IsInvalidFlyInCnt() const
Definition: pagefrm.hxx:233
bool IsInvalidLayout() const
Definition: pagefrm.hxx:234
Collection of SwLineLayout instances, represents the paragraph text in Writer layout.
Definition: porlay.hxx:251
Of course Writer needs its own rectangles.
Definition: swrect.hxx:35
void dumpAsXmlAttributes(xmlTextWriterPtr writer) const
Definition: swrect.cxx:178
The root element of a Writer document layout.
Definition: rootfrm.hxx:82
SwViewShell * GetCurrShell() const
Definition: rootfrm.hxx:206
SwSectionNode * GetSectionNode()
Definition: section.cxx:923
SwSection * GetSection()
Definition: sectfrm.hxx:97
virtual void dumpAsXmlAttributes(xmlTextWriterPtr writer) const override
Definition: xmldump.cxx:525
const SwSectionFrame * GetFollow() const
Definition: sectfrm.hxx:173
SwSectionFormat * GetFormat()
Definition: section.hxx:337
class for collecting anchored objects
Definition: sortedobjs.hxx:49
size_t size() const
Definition: sortedobjs.cxx:43
SwTabFrame is one table in the document layout, containing rows (which contain cells).
Definition: tabfrm.hxx:47
const SwTabFrame * GetFollow() const
Definition: tabfrm.hxx:250
virtual void dumpAsXmlAttributes(xmlTextWriterPtr writer) const override
Definition: xmldump.cxx:535
Represents the visualization of a paragraph.
Definition: txtfrm.hxx:165
SwTextFrame * GetFollow()
Definition: txtfrm.hxx:861
TextFrameIndex GetOffset() const
Definition: txtfrm.hxx:444
virtual void dumpAsXmlAttributes(xmlTextWriterPtr writer) const override
Definition: xmldump.cxx:515
sw::MergedPara * GetMergedPara()
Definition: txtfrm.hxx:456
SwParaPortion * GetPara()
Definition: txtcache.cxx:90
SwTextNode * GetTextNodeFirst()
Definition: txtfrm.hxx:463
const OUString & GetText() const
Returns the text portion we want to edit (for inline see underneath)
Definition: txtfrm.cxx:1293
SwTextNode is a paragraph in the document model.
Definition: ndtxt.hxx:111
SfxViewShell * GetSfxViewShell() const
Definition: viewsh.hxx:451
Definition: view.hxx:146
void dumpAsXml(xmlTextWriterPtr pWriter) const override
See SfxViewShell::dumpAsXml().
Definition: viewprt.cxx:268
EmbeddedObjectRef * pObject
const char * name
int i
OString OUStringToOString(std::u16string_view str, ConnectionSettings const *settings)
const char * PortionTypeToString(PortionType nType)
Definition: xmldump.cxx:33
QPRO_FUNC_TYPE nType
Describes parts of multiple text nodes, which will form a text frame, even when redlines are hidden a...
Definition: txtfrm.hxx:963
SwTextNode * pParaPropsNode
most paragraph properties are taken from the first non-empty node
Definition: txtfrm.hxx:970
std::vector< Extent > extents
Definition: txtfrm.hxx:965
PortionType
Definition: txttypes.hxx:24