LibreOffice Module sw (master)  1
ww8graf2.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 <iterator>
21 #include <numeric>
22 #include <hintids.hxx>
23 #include <svl/urihelper.hxx>
24 #include <svx/svdpage.hxx>
25 #include <svx/svdmodel.hxx>
26 #include <svx/svdograf.hxx>
27 #include <svx/svdoole2.hxx>
28 #include <editeng/opaqitem.hxx>
30 #include <sfx2/app.hxx>
31 #include <sfx2/docfile.hxx>
32 #include <sfx2/fcontnr.hxx>
33 #include <unotools/configmgr.hxx>
34 #include <grfatr.hxx>
35 #include <fmtanchr.hxx>
36 #include <fmtcntnt.hxx>
37 #include <fmtflcnt.hxx>
38 #include <frmfmt.hxx>
39 #include <fltshell.hxx>
40 #include <pam.hxx>
41 #include <doc.hxx>
43 #include <ndtxt.hxx>
44 #include <mdiexp.hxx>
45 #include "writerwordglue.hxx"
46 #include "ww8struc.hxx"
47 #include "ww8scan.hxx"
48 #include "ww8par.hxx"
49 #include "ww8par2.hxx"
50 #include "ww8graf.hxx"
51 #include <vcl/graphicfilter.hxx>
52 #include <vcl/wmf.hxx>
53 
54 using namespace ::com::sun::star;
55 using namespace sw::types;
56 
58  const SvxMSDffShapeOrders *pShapeOrders)
59  : maSetLayer(rSetLayer), mnInlines(0), mpDrawPg(pDrawPg),
60  mpShapeOrders(pShapeOrders)
61 {
63  OSL_ENSURE(mpDrawPg,"Missing draw page impossible!");
64 }
65 
67 {
68  maIndexes.push(GetEscherObjectIdx(nSpId));
69 }
70 
72 {
73  maIndexes.pop();
74 }
75 
76 // consider new parameter <_bInHeaderFooter>
78  sal_uLong nSpId,
79  const bool _bInHeaderFooter )
80 {
81  sal_uLong nInsertPos = GetEscherObjectPos( nSpId, _bInHeaderFooter );
82  InsertObject(pObject, nInsertPos + mnNoInitialObjects + mnInlines);
83 }
84 
86 {
87  return std::find_if(maEscherLayer.begin(), maEscherLayer.end(),
88  [nIdx](const EscherShape& rShape) { return rShape.mnEscherShapeOrder == nIdx; });
89 }
90 
92 {
93  sal_uInt16 nFound=0;
94  sal_uInt16 nShapeCount = mpShapeOrders ? mpShapeOrders->size() : 0;
95  // First, find out what position this shape is in the Escher order.
96  for (sal_uInt16 nShapePos=0; nShapePos < nShapeCount; nShapePos++)
97  {
98  const SvxMSDffShapeOrder& rOrder = *(*mpShapeOrders)[nShapePos];
99  if (rOrder.nShapeId == nSpId)
100  {
101  nFound = nShapePos;
102  break;
103  }
104  }
105  return nFound;
106 }
107 
108 // consider new parameter <_bInHeaderFooter>
110  const bool _bInHeaderFooter )
111 {
112  /*
113  EscherObjects have their own ordering which needs to be matched to
114  the actual ordering that should be used when inserting them into the
115  document.
116  */
117  sal_uInt16 nFound = GetEscherObjectIdx(nSpId);
118  // Match the ordering position from the ShapeOrders to the ordering of all
119  // objects in the document, there is a complexity when escherobjects
120  // contain inlines objects, we need to consider those as part of the
121  // escher count
122  sal_uLong nRet=0;
123  myeiter aIter = maEscherLayer.begin();
124  myeiter aEnd = maEscherLayer.end();
125  // skip objects in page header|footer,
126  // if current object isn't in page header|footer
127  if ( !_bInHeaderFooter )
128  {
129  while ( aIter != aEnd )
130  {
131  if ( !aIter->mbInHeaderFooter )
132  {
133  break;
134  }
135  nRet += aIter->mnNoInlines + 1;
136  ++aIter;
137  }
138  }
139  while (aIter != aEnd)
140  {
141  // insert object in page header|footer
142  // before objects in page body
143  if ( _bInHeaderFooter && !aIter->mbInHeaderFooter )
144  {
145  break;
146  }
147  if ( aIter->mnEscherShapeOrder > nFound )
148  break;
149  nRet += aIter->mnNoInlines+1;
150  ++aIter;
151  }
152  maEscherLayer.insert(aIter, EscherShape( nFound, _bInHeaderFooter ) );
153  return nRet;
154 }
155 
156 // InsertObj() adds the object into the Sw-Page and memorize the Z-position
157 // in a VarArr
158 void wwZOrderer::InsertDrawingObject(SdrObject* pObj, short nWwHeight)
159 {
160  sal_uLong nPos = GetDrawingObjectPos(nWwHeight);
161  if (nWwHeight & 0x2000) // Heaven ?
163  else
165 
166  InsertObject(pObj, nPos + mnNoInitialObjects + mnInlines);
167 }
168 
170 {
171  maSetLayer.SendObjectToHeaven(*pObject);
172  if (maIndexes.empty())
173  {
175  ++mnInlines;
176  }
177  else
178  {
179  //If we are inside an escher objects, place us just after that
180  //escher obj, and increment its inline count
181  sal_uInt16 nIdx = maIndexes.top();
182  myeiter aEnd = MapEscherIdxToIter(nIdx);
183 
184  sal_uLong nInsertPos = std::accumulate(maEscherLayer.begin(), aEnd, sal_uLong(0),
185  [](const sal_uLong nPos, const EscherShape& rShape) { return nPos + rShape.mnNoInlines + 1; });
186 
187  OSL_ENSURE(aEnd != maEscherLayer.end(), "Something very wrong here");
188  if (aEnd != maEscherLayer.end())
189  {
190  aEnd->mnNoInlines++;
191  nInsertPos += aEnd->mnNoInlines;
192  }
193 
194  InsertObject(pObject, mnNoInitialObjects + mnInlines + nInsertPos);
195  }
196 }
197 
198 /* Parallel to the Obj-array in the document I also build an array which
199  * contains the Ww-height (-> what covers what).
200  * Based on this VARARR the position where the insertion happens is
201  * determined.
202  * When inserting the offset in an existing document with a graphic layer the
203  * caller has to increment the index by mnNoInitialObjects, so that the new
204  * objects are added at the end (inserting is faster then)
205  */
207 {
208  auto aIter = std::find_if(
209  maDrawHeight.begin(), maDrawHeight.end(),
210  [nWwHeight](short aHeight){ return (aHeight & 0x1fff) > (nWwHeight & 0x1fff); });
211 
212  aIter = maDrawHeight.insert(aIter, nWwHeight);
213  return std::distance(maDrawHeight.begin(), aIter);
214 }
215 
217 {
218  if (!pObject->IsInserted())
219  {
220  mpDrawPg->InsertObject(pObject, nPos);
221  }
222 }
223 
224 static void WW8PicShadowToReal( WW8_PIC_SHADOW const * pPicS, WW8_PIC* pPic );
225 
227 {
228  return ERRCODE_NONE == GraphicFilter::GetGraphicFilter().ImportGraphic(rGraphic, OUString(), rSrc);
229 }
230 
231 bool SwWW8ImplReader::ReadGrafFile(OUString& rFileName, std::unique_ptr<Graphic>& rpGraphic,
232  const WW8_PIC& rPic, SvStream* pSt, sal_uLong nFilePos, bool* pbInDoc)
233 { // Write the graphic to the file
234  *pbInDoc = true; // default
235 
236  sal_uLong nPosFc = nFilePos + rPic.cbHeader;
237 
238  switch (rPic.MFP.mm)
239  {
240  case 94: // BMP-file ( not embedded ) or GIF
241  case 99: // TIFF-file ( not embedded )
242  pSt->Seek(nPosFc);
243  // read name as P-string
244  rFileName = read_uInt8_PascalString(*pSt, m_eStructCharSet);
245  if (!rFileName.isEmpty())
246  rFileName = URIHelper::SmartRel2Abs(
247  INetURLObject(m_sBaseURL), rFileName,
249  *pbInDoc = false; // Don't delete the file afterwards
250  return !rFileName.isEmpty(); // read was successful
251  }
252 
253  GDIMetaFile aWMF;
254  bool bOk = checkSeek(*pSt, nPosFc) && ReadWindowMetafile( *pSt, aWMF );
255 
256  if (!bOk || pSt->GetError() || !aWMF.GetActionSize())
257  return false;
258 
259  //skip duplicate graphics when fuzzing
261  {
262  if (!m_aGrafPosSet.insert(nPosFc).second)
263  return false;
264  }
265 
266  if (m_xWwFib->m_envr != 1) // !MAC as creator
267  {
268  rpGraphic.reset(new Graphic(aWMF));
269  return true;
270  }
271 
272  // MAC - word as creator
273  // The WMF only says "Please use Word 6.0c" and Mac-Pict follows but without
274  // the first 512 Bytes which are not relevant in a MAC-PICT (they are not
275  // interpreted)
276  bOk = false;
277  long nData = rPic.lcb - ( pSt->Tell() - nPosFc );
278  if (nData > 0)
279  {
280  rpGraphic.reset(new Graphic());
281  bOk = SwWW8ImplReader::GetPictGrafFromStream(*rpGraphic, *pSt);
282  if (!bOk)
283  rpGraphic.reset();
284  }
285  return bOk; // Contains graphic
286 }
287 
289 {
290  sal_Int16 nCL, nCR, nCT, nCB;
292 
293  explicit WW8PicDesc( const WW8_PIC& rPic );
294 };
295 
297 {
298  //See #i21190# before fiddling with this method
299  long nOriWidth = rPic.dxaGoal; //Size in 1/100 mm before crop
300  long nOriHeight = rPic.dyaGoal;
301 
302  nCL = rPic.dxaCropLeft;
303  nCR = rPic.dxaCropRight;
304  nCT = rPic.dyaCropTop;
305  nCB = rPic.dyaCropBottom;
306 
307  long nCurrentWidth = nOriWidth - (nCL + nCR); // Size after crop
308  long nCurrentHeight = nOriHeight - (nCT + nCB);
309  if (!nCurrentWidth)
310  nCurrentWidth = 1;
311  if (!nCurrentHeight)
312  nCurrentHeight = 1;
313  nWidth = nCurrentWidth * rPic.mx / 1000; // Writer Size
314  nHeight = nCurrentHeight * rPic.my / 1000;
315 }
316 
317 void SwWW8ImplReader::ReplaceObj(const SdrObject &rReplaceObj,
318  SdrObject &rSubObj)
319 {
320  // Insert SdrGrafObj instead of SdrTextObj into this group
321  if (SdrObject* pGroupObject = rReplaceObj.getParentSdrObjectFromSdrObject())
322  {
323  SdrObjList* pObjectList = pGroupObject->GetSubList();
324 
325  rSubObj.SetLogicRect(rReplaceObj.GetCurrentBoundRect());
326  rSubObj.SetLayer(rReplaceObj.GetLayer());
327 
328  // remove old object from group-list and add new one
329  // (this also exchanges it in the drawing page)
330  pObjectList->ReplaceObject(&rSubObj, rReplaceObj.GetOrdNum());
331  }
332  else
333  {
334  OSL_ENSURE( false, "Impossible!");
335  }
336 }
337 
338 // MakeGrafNotInContent inserts a non character bound graphic
339 // ( bGrafApo == true)
341  const Graphic* pGraph, const OUString& rFileName, const SfxItemSet& rGrfSet)
342 {
343 
344  sal_uInt32 nWidth = rPD.nWidth;
345  sal_uInt32 nHeight = rPD.nHeight;
346 
347  // Vertical shift through line spacing
348  sal_Int32 nNetHeight = nHeight + rPD.nCT + rPD.nCB;
349  if (m_xSFlyPara->nLineSpace && m_xSFlyPara->nLineSpace > nNetHeight)
350  m_xSFlyPara->nYPos =
351  static_cast<sal_uInt16>( m_xSFlyPara->nYPos + m_xSFlyPara->nLineSpace - nNetHeight );
352 
353  WW8FlySet aFlySet(*this, m_xWFlyPara.get(), m_xSFlyPara.get(), true);
354 
356  aAnchor.SetAnchor(m_pPaM->GetPoint());
357  aFlySet.Put(aAnchor);
358 
359  aFlySet.Put( SwFormatFrameSize( ATT_FIX_SIZE, nWidth, nHeight ) );
360 
361  SwFlyFrameFormat *const pFlyFormat =
363  *m_pPaM, rFileName, OUString(), pGraph,
364  &aFlySet, &rGrfSet, nullptr);
365 
366  // So the frames are generated when inserted in an existing doc:
368  (RndStdIds::FLY_AT_PARA == pFlyFormat->GetAnchor().GetAnchorId()))
369  {
370  pFlyFormat->MakeFrames();
371  }
372  return pFlyFormat;
373 }
374 
375 // MakeGrafInContent inserts a character bound graphic
377  const WW8PicDesc& rPD, const Graphic* pGraph, const OUString& rFileName,
378  const SfxItemSet& rGrfSet)
379 {
380  WW8FlySet aFlySet(*this, m_pPaM, rPic, rPD.nWidth, rPD.nHeight);
381 
382  SwFrameFormat* pFlyFormat = nullptr;
383 
384  if (rFileName.isEmpty() && m_nObjLocFc) // then it should be a OLE-Object
385  pFlyFormat = ImportOle(pGraph, &aFlySet, &rGrfSet);
386 
387  if( !pFlyFormat ) // then just as graphic
388  {
389 
391  *m_pPaM, rFileName, OUString(), pGraph, &aFlySet,
392  &rGrfSet, nullptr);
393  }
394 
395  // Resize the frame to the size of the picture if graphic is inside a frame
396  // (only if auto-width)
397  if (m_xSFlyPara)
398  m_xSFlyPara->BoxUpWidth( rPD.nWidth );
399  return pFlyFormat;
400 }
401 
403  sal_uLong nFilePos )
404 {
405  SwFrameFormat* pRet = nullptr;
406  if( pSt->eof() || rPic.fError || rPic.MFP.mm == 99 )
407  return nullptr;
408 
409  OUString aFileName;
410  bool bInDoc;
411  std::unique_ptr<Graphic> pGraph;
412  bool bOk = ReadGrafFile(aFileName, pGraph, rPic, pSt, nFilePos, &bInDoc);
413 
414  if (!bOk)
415  {
416  return nullptr; // Graphic could not be read correctly
417  }
418 
419  WW8PicDesc aPD( rPic );
420 
422  if( aPD.nCL || aPD.nCR || aPD.nCT || aPD.nCB )
423  {
424  SwCropGrf aCrop( aPD.nCL, aPD.nCR, aPD.nCT, aPD.nCB) ;
425  aGrfSet.Put( aCrop );
426  }
427 
428  if (m_xWFlyPara && m_xWFlyPara->bGrafApo)
429  pRet = MakeGrafNotInContent(aPD, pGraph.get(), aFileName, aGrfSet);
430  else
431  pRet = MakeGrafInContent(rPic, aPD, pGraph.get(), aFileName, aGrfSet);
432  return pRet;
433 }
434 
435 void SwWW8ImplReader::PicRead(SvStream *pDataStream, WW8_PIC *pPic,
436  bool bVer67)
437 {
438  //Only the first 0x2e bytes are the same between version 6/7 and 8+
439  WW8_PIC_SHADOW aPicS;
440  pDataStream->ReadBytes( &aPicS, sizeof( aPicS ) );
441  WW8PicShadowToReal( &aPicS, pPic );
442  for (WW8_BRC & i : pPic->rgbrc)
443  pDataStream->ReadBytes(&i, bVer67 ? 2 : 4);
444  pDataStream->ReadInt16( pPic->dxaOrigin );
445  pDataStream->ReadInt16( pPic->dyaOrigin );
446  if (!bVer67)
447  pDataStream->SeekRel(2); //cProps
448 }
449 
450 namespace
451 {
452  SwNodeType GetNodeType(SwFrameFormat const &rSource)
453  {
454  const SwNodeIndex* pNodeIndex = rSource.GetContent().GetContentIdx();
455  if (!pNodeIndex)
456  return SwNodeType::NONE;
457  const SwNode& rCSttNd = pNodeIndex->GetNode();
458  SwNodeRange aRg(rCSttNd, 1, *rCSttNd.EndOfSectionNode());
459  return aRg.aStart.GetNode().GetNodeType();
460  }
461 }
462 
464  SwFrameFormat const * pOldFlyFormat)
465 {
466  SwFrameFormat* pRet = nullptr;
467  if (
468  ((m_pStrm == m_pDataStream ) && !m_nPicLocFc) ||
470  )
471  {
472  return nullptr;
473  }
474 
476 
477  GrafikCtor();
478 
479  /*
480  * Little joke from Microsoft: sometimes a stream named DATA exists. This
481  * stream then contains the PICF and the corresponding graphic!
482  * We otherwise map the variable pDataStream to pStream.
483  */
484  auto nOldPos = m_pDataStream->Tell();
485  WW8_PIC aPic;
486  bool bValid = checkSeek(*m_pDataStream, m_nPicLocFc);
487 
488  if (bValid)
489  PicRead( m_pDataStream, &aPic, m_bVer67);
490 
491  // Sanity check is needed because for example check boxes in field results
492  // contain a WMF-like struct
493  if (bValid && m_pDataStream->good() && (aPic.lcb >= 58))
494  {
496  {
497  // We just added a graphic-link into the doc. Now we need to set
498  // its position and scale it.
499  WW8PicDesc aPD( aPic );
500 
501  WW8FlySet aFlySet( *this, m_pPaM, aPic, aPD.nWidth, aPD.nHeight );
502 
503  // the correct anchor is set in Read_F_IncludePicture and the
504  // current PaM point is after the position if it is anchored in
505  // content; because this anchor add a character into the textnode.
506  // #i2806#
507  if (RndStdIds::FLY_AS_CHAR ==
509  {
510  aFlySet.ClearItem( RES_ANCHOR );
511  }
512 
514 
516  }
517  else if((0x64 == aPic.MFP.mm) || (0x66 == aPic.MFP.mm))
518  {
519  // linked graphic in ESCHER-Object
520  SdrObject* pObject = nullptr;
521 
522  WW8PicDesc aPD( aPic );
523  if (!m_xMSDffManager)
524  m_xMSDffManager.reset(new SwMSDffManager(*this, m_bSkipImages));
525  /* ##835##
526  * Disable use of main stream as fallback stream for inline direct
527  * blips as it is known that they are directly after the record
528  * header, testing for existence in main stream may lead to an
529  * incorrect fallback graphic being found if other escher graphics
530  * have been inserted in the document
531  */
532  m_xMSDffManager->DisableFallbackStream();
533  if (!m_xMSDffManager->GetModel())
534  m_xMSDffManager->SetModel(m_pDrawModel, 1440);
535 
536  if (0x66 == aPic.MFP.mm)
537  {
538  //These ones have names prepended
539  sal_uInt8 nNameLen=0;
540  m_pDataStream->ReadUChar( nNameLen );
541  m_pDataStream->SeekRel( nNameLen );
542  }
543 
544  tools::Rectangle aClientRect( 0,0, aPD.nWidth, aPD.nHeight);
545  SvxMSDffImportData aData( aClientRect );
546  pObject = m_xMSDffManager->ImportObj(*m_pDataStream, aData, aClientRect, tools::Rectangle(), /*nCalledByGroup*/0, /*pShapeId*/nullptr );
547  if (pObject)
548  {
549  // for the frame
551  RES_FRMATR_END-1>{} );
552 
553  SvxMSDffImportRec const*const pRecord = (1 == aData.size())
554  ? aData.begin()->get() : nullptr;
555 
556  if( pRecord )
557  {
558 
559  // Horizontal rule may have its width given as % of page
560  // width (-1 is used if not given, 0 means the object has
561  // fixed width).
562  // Additionally, if it's a horizontal rule without width
563  // given, assume 100.0% width.
564  int relativeWidth = pRecord->relativeHorizontalWidth;
565  if( relativeWidth == -1 )
566  relativeWidth = pRecord->isHorizontalRule ? 1000 : 0;
567  if( relativeWidth != 0 )
568  {
569  const sal_Int16 nScale = aPic.dxaGoal ? aPic.dxaGoal : 1000;
570  aPic.mx = msword_cast<sal_uInt16>(
573  m_aSectionManager.GetPageLeft()) * relativeWidth / nScale;
574  aPD = WW8PicDesc( aPic );
575  // This SetSnapRect() call adjusts the size of the
576  // object itself, no idea why it's this call (or even
577  // what the call actually does), but that's what
578  // ImportGraf() (called by ImportObj()) uses.
579  pObject->SetSnapRect( tools::Rectangle( 0, 0, aPD.nWidth, aPD.nHeight ));
580  }
581 
582  // A graphic of this type in this location is always
583  // inline, and uses the pic in the same module as ww6
584  // graphics.
585  if (m_xWFlyPara && m_xWFlyPara->bGrafApo)
586  {
587  WW8FlySet aFlySet(*this, m_xWFlyPara.get(), m_xSFlyPara.get(), true);
588 
590  aAnchor.SetAnchor(m_pPaM->GetPoint());
591  aFlySet.Put(aAnchor);
592 
593  aAttrSet.Put(aFlySet);
594  }
595  else
596  {
597  WW8FlySet aFlySet( *this, m_pPaM, aPic, aPD.nWidth,
598  aPD.nHeight );
599 
600  aAttrSet.Put(aFlySet);
601  }
602  // Modified for i120716,for graf importing from MS Word 2003
603  // binary format, there is no border distance.
604  tools::Rectangle aInnerDist(0,0,0,0);
605  MatchSdrItemsIntoFlySet( pObject, aAttrSet,
606  pRecord->eLineStyle, pRecord->eLineDashing,
607  pRecord->eShapeType, aInnerDist );
608 
609  // Set the size from the WinWord PIC-structure as graphic
610  // size
611  aAttrSet.Put( SwFormatFrameSize( ATT_FIX_SIZE, aPD.nWidth,
612  aPD.nHeight ) );
613  }
614 
615  // for the graphic
617  RES_GRFATR_END-1>{} );
618 
619  if( aPD.nCL || aPD.nCR || aPD.nCT || aPD.nCB )
620  {
621  SwCropGrf aCrop( aPD.nCL, aPD.nCR, aPD.nCT, aPD.nCB );
622  aGrSet.Put( aCrop );
623  }
624 
625  if (pRecord)
626  MatchEscherMirrorIntoFlySet(*pRecord, aGrSet);
627 
628  // if necessary adopt old AttrSet and correct horizontal
629  // positioning relation
630  if( pOldFlyFormat )
631  {
632  aAttrSet.Put( pOldFlyFormat->GetAttrSet() );
633  const SwFormatHoriOrient &rHori = pOldFlyFormat->GetHoriOrient();
634  if( text::RelOrientation::FRAME == rHori.GetRelationOrient() )
635  {
636  aAttrSet.Put( SwFormatHoriOrient( rHori.GetPos(),
637  text::HoriOrientation::NONE, text::RelOrientation::PAGE_PRINT_AREA ) );
638  }
639  }
640 
641  bool bTextObjWasGrouped = false;
642  if (pOldFlyFormat && pTextObj && pTextObj->getParentSdrObjectFromSdrObject())
643  bTextObjWasGrouped = true;
644 
645  if (bTextObjWasGrouped)
646  ReplaceObj(*pTextObj, *pObject);
647  else
648  {
649  if (sal_uInt16(OBJ_OLE2) == pObject->GetObjIdentifier())
650  {
651  // the size from BLIP, if there is any, should be already set
652  pRet = InsertOle(*static_cast<SdrOle2Obj*>(pObject), aAttrSet, &aGrSet);
653  }
654  else
655  {
656  if (SdrGrafObj* pGraphObject = dynamic_cast<SdrGrafObj*>( pObject) )
657  {
658  // Now add the link or rather the graphic to the doc
659  const Graphic& rGraph = pGraphObject->GetGraphic();
660 
661  if (m_nObjLocFc) // is it a OLE-Object?
662  pRet = ImportOle(&rGraph, &aAttrSet, &aGrSet, pObject->GetBLIPSizeRectangle());
663 
664  if (!pRet)
665  {
667  *m_pPaM, OUString(), OUString(),
668  &rGraph, &aAttrSet, &aGrSet, nullptr );
669  }
670  }
671  else
672  pRet = m_rDoc.getIDocumentContentOperations().InsertDrawObj(*m_pPaM, *pObject, aAttrSet );
673  }
674  }
675 
676  // only if we made an *Insert*
677  if (pRet)
678  {
679  if (pRecord)
680  SetAttributesAtGrfNode(pRecord, pRet, nullptr);
681 
682  OUString aObjectName(pObject->GetName());
683  if (aObjectName.isEmpty() || !m_rDoc.FindFlyByName(aObjectName, GetNodeType(*pRet)))
684  pRet->SetName(aObjectName);
685  else
686  m_aGrfNameGenerator.SetUniqueGraphName(pRet, aObjectName);
687 
688  // determine the pointer to the new object and update
689  // Z-order-list accordingly (or delete entry)
690  if (SdrObject* pOurNewObject = CreateContactObject(pRet))
691  {
692  if (pOurNewObject != pObject)
693  {
694  m_xMSDffManager->ExchangeInShapeOrder( pObject, 0,
695  pOurNewObject );
696 
697  // delete and destroy old SdrGrafObj from page
698  if (pObject->getSdrPageFromSdrObject())
699  m_pDrawPg->RemoveObject(pObject->GetOrdNum());
700  SdrObject::Free( pObject );
701  }
702  }
703  else
704  m_xMSDffManager->RemoveFromShapeOrder( pObject );
705  }
706  else
707  m_xMSDffManager->RemoveFromShapeOrder( pObject );
708 
709  // also delete this from the page if not grouped
710  if (pTextObj && !bTextObjWasGrouped && pTextObj->getSdrPageFromSdrObject())
711  m_pDrawPg->RemoveObject( pTextObj->GetOrdNum() );
712  }
713  m_xMSDffManager->EnableFallbackStream();
714  }
715  else if (aPic.lcb >= 58)
716  pRet = ImportGraf1(aPic, m_pDataStream, m_nPicLocFc);
717  }
718  m_pDataStream->Seek( nOldPos );
719 
720  if (pRet)
721  {
722  SdrObject* pOurNewObject = CreateContactObject(pRet);
723  m_xWWZOrder->InsertTextLayerObject(pOurNewObject);
724  }
725 
726  return AddAutoAnchor(pRet);
727 }
728 
729 void WW8PicShadowToReal( WW8_PIC_SHADOW const * pPicS, WW8_PIC * pPic )
730 {
731  pPic->lcb = SVBT32ToUInt32( pPicS->lcb );
732  pPic->cbHeader = SVBT16ToUInt16( pPicS->cbHeader );
733  pPic->MFP.mm = SVBT16ToUInt16( pPicS->MFP.mm );
734  pPic->MFP.xExt = SVBT16ToUInt16( pPicS->MFP.xExt );
735  pPic->MFP.yExt = SVBT16ToUInt16( pPicS->MFP.yExt );
736  pPic->MFP.hMF = SVBT16ToUInt16( pPicS->MFP.hMF );
737  for( sal_uInt16 i = 0; i < 14 ; i++ )
738  pPic->rcWinMF[i] = pPicS->rcWinMF[i];
739  pPic->dxaGoal = SVBT16ToUInt16( pPicS->dxaGoal );
740  pPic->dyaGoal = SVBT16ToUInt16( pPicS->dyaGoal );
741  pPic->mx = SVBT16ToUInt16( pPicS->mx );
742  pPic->my = SVBT16ToUInt16( pPicS->my );
743  pPic->dxaCropLeft = SVBT16ToUInt16( pPicS->dxaCropLeft );
744  pPic->dyaCropTop = SVBT16ToUInt16( pPicS->dyaCropTop );
745  pPic->dxaCropRight = SVBT16ToUInt16( pPicS->dxaCropRight );
746  pPic->dyaCropBottom = SVBT16ToUInt16( pPicS->dyaCropBottom );
747  pPic->brcl = pPicS->aBits1 & 0x0f;
748  pPic->fFrameEmpty = (pPicS->aBits1 & 0x10) >> 4;
749  pPic->fBitmap = (pPicS->aBits1 & 0x20) >> 5;
750  pPic->fDrawHatch = (pPicS->aBits1 & 0x40) >> 6;
751  pPic->fError = (pPicS->aBits1 & 0x80) >> 7;
752  pPic->bpp = pPicS->aBits2;
753 }
754 
755 void WW8FSPAShadowToReal( WW8_FSPA_SHADOW const * pFSPAS, WW8_FSPA * pFSPA )
756 {
757  pFSPA->nSpId = SVBT32ToUInt32( pFSPAS->nSpId );
758  pFSPA->nXaLeft = SVBT32ToUInt32( pFSPAS->nXaLeft );
759  pFSPA->nYaTop = SVBT32ToUInt32( pFSPAS->nYaTop );
760  pFSPA->nXaRight = SVBT32ToUInt32( pFSPAS->nXaRight );
761  pFSPA->nYaBottom = SVBT32ToUInt32( pFSPAS->nYaBottom );
762 
763  sal_uInt16 nBits = SVBT16ToUInt16( pFSPAS->aBits1 );
764 
765  pFSPA->bHdr = sal_uInt16(0 != ( nBits & 0x0001 ));
766  pFSPA->nbx = ( nBits & 0x0006 ) >> 1;
767  pFSPA->nby = ( nBits & 0x0018 ) >> 3;
768  pFSPA->nwr = ( nBits & 0x01E0 ) >> 5;
769  pFSPA->nwrk = ( nBits & 0x1E00 ) >> 9;
770  pFSPA->bRcaSimple = sal_uInt16(0 != ( nBits & 0x2000 ));
771  pFSPA->bBelowText = sal_uInt16(0 != ( nBits & 0x4000 ));
772  pFSPA->bAnchorLock = sal_uInt16(0 != ( nBits & 0x8000 ));
773  pFSPA->nTxbx = SVBT32ToUInt32( pFSPAS->nTxbx );
774 }
775 
776 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
const SwEndNode * EndOfSectionNode() const
Definition: node.hxx:682
sal_Int32 nXaRight
Definition: ww8struc.hxx:903
SwFrameFormat * ImportGraf1(WW8_PIC const &rPic, SvStream *pSt, sal_uLong nFilePos)
Definition: ww8graf2.cxx:402
SvStream & ReadInt16(sal_Int16 &rInt16)
void OutsideEscher()
Definition: ww8graf2.cxx:71
WW8_BRC rgbrc[4]
Definition: ww8struc.hxx:470
sal_uInt16 nby
Definition: ww8struc.hxx:913
#define RES_GRFATR_END
Definition: hintids.hxx:258
sal_uInt32 GetPageLeft() const
Definition: ww8par2.cxx:149
static constexpr RndStdIds eAnchor
Definition: ww8par2.hxx:61
SVBT16 dxaGoal
Definition: ww8struc.hxx:493
rtl_TextEncoding m_eStructCharSet
Definition: ww8par.hxx:1284
virtual const tools::Rectangle & GetCurrentBoundRect() const
ErrCode ImportGraphic(Graphic &rGraphic, const INetURLObject &rPath, sal_uInt16 nFormat=GRFILTER_FORMAT_DONTKNOW, sal_uInt16 *pDeterminedFormat=nullptr, GraphicFilterImportFlags nImportFlags=GraphicFilterImportFlags::NONE)
SwFlyFrameFormat * m_pFlyFormatOfJustInsertedGraphic
Definition: ww8par.hxx:1198
OBJ_OLE2
const SvxMSDffShapeOrders * mpShapeOrders
Definition: ww8graf.hxx:62
sal_Int16 dyaCropBottom
Definition: ww8struc.hxx:463
sal_uInt16 bBelowText
Definition: ww8struc.hxx:935
sal_Int16 nCL
Definition: ww8graf2.cxx:290
virtual SwFlyFrameFormat * InsertGraphic(const SwPaM &rRg, const OUString &rGrfName, const OUString &rFltName, const Graphic *pGraphic, const SfxItemSet *pFlyAttrSet, const SfxItemSet *pGrfAttrSet, SwFrameFormat *)=0
Insert graphic or formula.
#define WW8FL_NO_GRAF
Definition: ww8par.hxx:119
bool ReadWindowMetafile(SvStream &rStream, GDIMetaFile &rMTF)
sal_uInt16 m_nProgress
Definition: ww8par.hxx:1286
sal_uInt8 aBits1
Definition: ww8struc.hxx:501
sal_uInt16 nbx
Definition: ww8struc.hxx:907
void MatchSdrItemsIntoFlySet(SdrObject const *pSdrObj, SfxItemSet &aFlySet, MSO_LineStyle eLineStyle, MSO_LineDashing eDashing, MSO_SPT eShapeType, tools::Rectangle &rInnerDist)
Definition: ww8graf.cxx:1662
void InsertTextLayerObject(SdrObject *pObject)
Definition: ww8graf2.cxx:169
SVBT16 cbHeader
Definition: ww8struc.hxx:483
SwTwips GetPos() const
Definition: fmtornt.hxx:92
sal_uIntPtr sal_uLong
wwFrameNamer m_aGrfNameGenerator
Definition: ww8par.hxx:1177
struct WW8_PIC::@17 MFP
#define RES_FRMATR_END
Definition: hintids.hxx:236
void SetAttributesAtGrfNode(SvxMSDffImportRec const *pRecord, SwFrameFormat const *pFlyFormat, WW8_FSPA const *pF)
Definition: ww8graf.cxx:2100
bool IsInserted() const
SVBT32 nYaBottom
Definition: ww8struc.hxx:953
size_t GetObjCount() const
std::unique_ptr< WW8FlyPara > m_xWFlyPara
Definition: ww8par.hxx:1240
std::shared_ptr< WW8Fib > m_xWwFib
Definition: ww8par.hxx:1218
std::vector< std::unique_ptr< SvxMSDffShapeOrder > > SvxMSDffShapeOrders
std::vector< EscherShape >::iterator myeiter
Definition: ww8graf.hxx:51
sal_uInt64 Seek(sal_uInt64 nPos)
void WW8FSPAShadowToReal(WW8_FSPA_SHADOW const *pFSPAS, WW8_FSPA *pFSPA)
Definition: ww8graf2.cxx:755
SwNode & GetNode() const
Definition: ndindex.hxx:118
SdrPage * m_pDrawPg
Definition: ww8par.hxx:1251
std::vector< short > maDrawHeight
Definition: ww8graf.hxx:53
sal_uInt32 m_nIniFlags
Definition: ww8par.hxx:1267
std::unique_ptr< SwMSDffManager > m_xMSDffManager
Definition: ww8par.hxx:1257
sal_Int32 lcb
Definition: ww8struc.hxx:445
sal_Int16 bpp
Definition: ww8struc.hxx:469
bool const m_bSkipImages
Definition: ww8par.hxx:1305
long nWidth
Definition: ww8graf2.cxx:291
sal_Int32 nXaLeft
Definition: ww8struc.hxx:901
static void Free(SdrObject *&_rpObject)
sal_Int32 nSpId
Definition: ww8struc.hxx:900
IDocumentContentOperations const & getIDocumentContentOperations() const
Definition: doc.cxx:347
virtual void InsertObject(SdrObject *pObj, size_t nPos=SAL_MAX_SIZE)
Frame cannot be moved in Var-direction.
Definition: fmtfsize.hxx:38
sal_uInt16 GetEscherObjectIdx(sal_uLong nSpId)
Definition: ww8graf2.cxx:91
SwFrameFormat * ImportOle(const Graphic *=nullptr, const SfxItemSet *pFlySet=nullptr, const SfxItemSet *pGrfSet=nullptr, const tools::Rectangle &aVisArea=tools::Rectangle())
Definition: ww8par4.cxx:246
sal_uInt64 SeekRel(sal_Int64 nPos)
sal_Int16 nCT
Definition: ww8graf2.cxx:290
Make setting a drawing object's layer in a Writer document easy.
struct WW8_PIC_SHADOW::@18 MFP
SwFlyFrameFormat * InsertOle(SdrOle2Obj &rObject, const SfxItemSet &rFlySet, const SfxItemSet *rGrfSet)
Definition: ww8par4.cxx:202
sal_uInt8 rcWinMF[14]
Definition: ww8struc.hxx:454
myeiter MapEscherIdxToIter(sal_uLong nIdx)
Definition: ww8graf2.cxx:85
ErrCode GetError() const
SwNodeType GetNodeType() const
Definition: node.hxx:144
bool eof() const
SdrPage * getSdrPageFromSdrObject() const
SwNodeIndex aStart
Definition: ndindex.hxx:131
static bool IsFuzzing()
SvStream * m_pStrm
Definition: ww8par.hxx:1088
virtual void SetName(const OUString &rNewName, bool bBroadcast=false) override
Definition: atrfrm.cxx:2464
sal_Int16 fBitmap
Definition: ww8struc.hxx:466
MSDffImportRecords::const_iterator begin() const
sal_Int16 dxaCropLeft
Definition: ww8struc.hxx:460
Ret msword_cast(Param in)
A static_cast style cast for conversion of writer types to word's.
sal_uLong GetEscherObjectPos(sal_uLong nSpId, const bool _bInHeaderFooter)
Definition: ww8graf2.cxx:109
static bool GetPictGrafFromStream(Graphic &rGraphic, SvStream &rSrc)
Definition: ww8graf2.cxx:226
void GrafikCtor()
Definition: ww8graf.cxx:3164
void SetUniqueGraphName(SwFrameFormat *pFrameFormat, const OUString &rFixedPart)
Definition: ww8graf.cxx:179
sal_uInt16 bAnchorLock
Definition: ww8struc.hxx:939
OUString const m_sBaseURL
Definition: ww8par.hxx:1264
const tools::Rectangle & GetBLIPSizeRectangle() const
sal_Int16 dxaGoal
Definition: ww8struc.hxx:456
void SetProgressState(long nPosition, SwDocShell const *pDocShell)
Definition: mainwn.cxx:78
void SendObjectToHeaven(SdrObject &rObject) const
Make Object lives in the top layer.
SVBT16 dyaCropTop
Definition: ww8struc.hxx:498
std::unique_ptr< wwZOrderer > m_xWWZOrder
Definition: ww8par.hxx:1253
virtual void SetLayer(SdrLayerID nLayer)
sal_Int16 mm
Definition: ww8struc.hxx:448
sal_uInt16 ClearItem(sal_uInt16 nWhich=0)
const SwFlyFrameFormat * FindFlyByName(const OUString &rName, SwNodeType nNdTyp=SwNodeType::NONE) const
Definition: doclay.cxx:1397
void InsertObject(SdrObject *pObject, sal_uLong nPos)
Definition: ww8graf2.cxx:216
Style of a layout element.
Definition: frmfmt.hxx:57
bool checkSeek(SvStream &rSt, sal_uInt64 nOffset)
sal_Int16 fDrawHatch
Definition: ww8struc.hxx:467
SwNodeType
Definition: ndtyp.hxx:28
#define RES_ANCHOR
Definition: hintids.hxx:209
sw::util::SetLayer const maSetLayer
Definition: ww8graf.hxx:57
wwSectionManager m_aSectionManager
Definition: ww8par.hxx:1149
const SwFormatAnchor & GetAnchor(bool=true) const
Definition: fmtanchr.hxx:81
SwDoc & m_rDoc
Definition: ww8par.hxx:1093
OUString read_uInt8_PascalString(SvStream &rStrm, rtl_TextEncoding eEnc)
Definition: ww8scan.hxx:162
sal_uInt8 rcWinMF[14]
Definition: ww8struc.hxx:491
sal_Int16 yExt
Definition: ww8struc.hxx:450
const SwPosition * GetPoint() const
Definition: pam.hxx:207
virtual sal_uInt16 GetObjIdentifier() const
RndStdIds GetAnchorId() const
Definition: fmtanchr.hxx:65
const SwFormatHoriOrient & GetHoriOrient(bool=true) const
Definition: fmtornt.hxx:108
SVL_DLLPUBLIC Link< OUString *, bool > const & GetMaybeFileHdl()
sal_Int16 xExt
Definition: ww8struc.hxx:449
void InsertEscherObject(SdrObject *pObject, sal_uLong nSpId, const bool _bInHeaderFooter)
Definition: ww8graf2.cxx:77
sal_Int16 nCB
Definition: ww8graf2.cxx:290
SwFrameFormat * AddAutoAnchor(SwFrameFormat *pFormat)
Definition: ww8graf.cxx:2824
sal_Int16 fFrameEmpty
Definition: ww8struc.hxx:465
int i
FlyAnchors.
Definition: fmtanchr.hxx:34
wwZOrderer(const sw::util::SetLayer &rSetLayer, SdrPage *pDrawPg, const SvxMSDffShapeOrders *pShapeOrders)
Definition: ww8graf2.cxx:57
void MatchEscherMirrorIntoFlySet(const SvxMSDffImportRec &rRecord, SfxItemSet &rFlySet)
Definition: ww8graf.cxx:3040
void InsertDrawingObject(SdrObject *pObj, short nWwHeight)
Definition: ww8graf2.cxx:158
sal_uInt32 GetOrdNum() const
std::set< sal_uLong > m_aGrafPosSet
Definition: ww8par.hxx:1214
SwDocShell * m_pDocShell
Definition: ww8par.hxx:1072
virtual void SetLogicRect(const tools::Rectangle &rRect)
Marks a node in the document model.
Definition: ndindex.hxx:31
sal_Int16 dyaGoal
Definition: ww8struc.hxx:457
long nHeight
Definition: ww8graf2.cxx:291
sal_uInt16 mx
Definition: ww8struc.hxx:458
SvStream & ReadUChar(unsigned char &rChar)
GUIDCNamePair const aData
sal_Int16 dxaOrigin
Definition: ww8struc.hxx:475
sal_Int16 dyaOrigin
Definition: ww8struc.hxx:476
virtual SdrObject * RemoveObject(size_t nObjNum)
sal_uLong GetDrawingObjectPos(short nWwHeight)
Definition: ww8graf2.cxx:206
SwFlyFrameFormat * MakeGrafNotInContent(const WW8PicDesc &rPD, const Graphic *pGraph, const OUString &rFileName, const SfxItemSet &rGrfSet)
Definition: ww8graf2.cxx:340
IDocumentLayoutAccess const & getIDocumentLayoutAccess() const
Definition: doc.cxx:437
OUString GetName() const
size_t size() const
#define RES_GRFATR_BEGIN
Definition: hintids.hxx:238
sal_uInt32 GetPageRight() const
Definition: ww8par2.cxx:154
virtual SdrLayerID GetLayer() const
const SwNodeIndex * GetContentIdx() const
Definition: fmtcntnt.hxx:46
SdrPage * mpDrawPg
Definition: ww8graf.hxx:61
std::size_t ReadBytes(void *pData, std::size_t nSize)
sal_uInt16 nwrk
Definition: ww8struc.hxx:927
sal_uInt8 aBits2
Definition: ww8struc.hxx:502
virtual bool SetFormatAttr(const SfxPoolItem &rAttr)
Definition: format.cxx:460
sal_Int16 dyaCropTop
Definition: ww8struc.hxx:461
sal_uLong mnInlines
Definition: ww8graf.hxx:60
virtual void MakeFrames() override
Creates the views.
Definition: atrfrm.cxx:2845
sal_uInt16 bRcaSimple
Definition: ww8struc.hxx:933
virtual SwDrawFrameFormat * InsertDrawObj(const SwPaM &rRg, SdrObject &rDrawObj, const SfxItemSet &rFlyAttrSet)=0
Insert a DrawObject.
SVBT16 dyaCropBottom
Definition: ww8struc.hxx:500
virtual SdrObject * ReplaceObject(SdrObject *pNewObj, size_t nObjNum)
friend class SwMSDffManager
Definition: ww8par.hxx:1080
sal_Int16 GetRelationOrient() const
Definition: fmtornt.hxx:88
#define ERRCODE_NONE
virtual const SwViewShell * GetCurrentViewShell() const =0
Returns the layout set at the document.
unsigned char sal_uInt8
void InsideEscher(sal_uLong nIndex)
Definition: ww8graf2.cxx:66
SVBT16 dyaGoal
Definition: ww8struc.hxx:494
sal_Int16 dxaCropRight
Definition: ww8struc.hxx:462
static void PicRead(SvStream *pDataStream, WW8_PIC *pPic, bool bVer67)
Definition: ww8graf2.cxx:435
SVBT16 dxaCropRight
Definition: ww8struc.hxx:499
sal_uInt64 Tell() const
size_t GetActionSize() const
SdrObject * CreateContactObject(SwFrameFormat *pFlyFormat)
Definition: ww8graf.cxx:2201
sal_uLong mnNoInitialObjects
Definition: ww8graf.hxx:59
sal_Int32 nTxbx
Definition: ww8struc.hxx:942
std::stack< sal_uInt16 > maIndexes
Definition: ww8graf.hxx:55
SwFrameFormat * ImportGraf(SdrTextObj const *pTextObj=nullptr, SwFrameFormat const *pFlyFormat=nullptr)
Definition: ww8graf2.cxx:463
SdrObject * getParentSdrObjectFromSdrObject() const
const SwFormatContent & GetContent(bool=true) const
Definition: fmtcntnt.hxx:55
sal_Int16 hMF
Definition: ww8struc.hxx:451
bool good() const
virtual void SetSnapRect(const tools::Rectangle &rRect)
sal_Int16 fError
Definition: ww8struc.hxx:468
static GraphicFilter & GetGraphicFilter()
sal_uInt16 bHdr
Definition: ww8struc.hxx:905
sal_uInt32 GetPageWidth() const
Definition: ww8par2.cxx:159
std::unique_ptr< WW8SwFlyPara > m_xSFlyPara
Definition: ww8par.hxx:1241
void SendObjectToHell(SdrObject &rObject) const
Make Object live in the bottom drawing layer.
sal_uLong m_nObjLocFc
Definition: ww8par.hxx:1278
static void WW8PicShadowToReal(WW8_PIC_SHADOW const *pPicS, WW8_PIC *pPic)
Definition: ww8graf2.cxx:729
SdrModel * m_pDrawModel
Definition: ww8par.hxx:1250
SvStream * m_pDataStream
Definition: ww8par.hxx:1090
sal_uInt16 nwr
Definition: ww8struc.hxx:918
const SwAttrSet & GetAttrSet() const
For querying the attribute array.
Definition: format.hxx:116
SwFrameFormat * MakeGrafInContent(const WW8_PIC &rPic, const WW8PicDesc &rPD, const Graphic *pGraph, const OUString &rFileName, const SfxItemSet &rGrfSet)
Definition: ww8graf2.cxx:376
sal_uLong m_nPicLocFc
Definition: ww8par.hxx:1277
bool ReadGrafFile(OUString &rFileName, std::unique_ptr< Graphic > &rpGraphic, const WW8_PIC &rPic, SvStream *pSt, sal_uLong nFilePos, bool *pDelIt)
Definition: ww8graf2.cxx:231
static void ReplaceObj(const SdrObject &rReplaceTextObj, SdrObject &rSubObj)
Definition: ww8graf2.cxx:317
sal_Int32 nYaBottom
Definition: ww8struc.hxx:904
sal_Int16 brcl
Definition: ww8struc.hxx:464
sal_Int32 nPos
sal_Int16 nCR
Definition: ww8graf2.cxx:290
std::vector< EscherShape > maEscherLayer
Definition: ww8graf.hxx:50
#define RES_FRMATR_BEGIN
Definition: hintids.hxx:192
sal_uInt16 cbHeader
Definition: ww8struc.hxx:446
sal_Int32 nYaTop
Definition: ww8struc.hxx:902
SwPaM * m_pPaM
Definition: ww8par.hxx:1095
SVBT16 dxaCropLeft
Definition: ww8struc.hxx:497
WW8PicDesc(const WW8_PIC &rPic)
Definition: ww8graf2.cxx:296
const SwAttrPool & GetAttrPool() const
Definition: doc.hxx:1307
sal_uInt16 my
Definition: ww8struc.hxx:459
SVL_DLLPUBLIC OUString SmartRel2Abs(INetURLObject const &rTheBaseURIRef, OUString const &rTheRelURIRef, Link< OUString *, bool > const &rMaybeFileHdl=Link< OUString *, bool >(), bool bCheckFileExists=true, bool bIgnoreFragment=false, INetURLObject::EncodeMechanism eEncodeMechanism=INetURLObject::EncodeMechanism::WasEncoded, INetURLObject::DecodeMechanism eDecodeMechanism=INetURLObject::DecodeMechanism::ToIUri, rtl_TextEncoding eCharset=RTL_TEXTENCODING_UTF8, FSysStyle eStyle=FSysStyle::Detect)
Base class of the Writer document model elements.
Definition: node.hxx:79