21#include <com/sun/star/embed/Aspects.hpp>
25#include <officecfg/Office/Common.hxx>
27#include <com/sun/star/drawing/XShape.hpp>
73#include <com/sun/star/i18n/XBreakIterator.hpp>
74#include <com/sun/star/lang/XServiceInfo.hpp>
82#include <com/sun/star/beans/XPropertySet.hpp>
83#include <com/sun/star/form/XFormComponent.hpp>
88#include <sfx2/sfxsids.hrc>
96using ::editeng::SvxBorderLine;
100using ::com::sun::star::beans::XPropertySet;
101using ::com::sun::star::drawing::XShape;
105 bool bRelUrl =
false;
125 return sDocUrl.copy(0, sDocUrl.lastIndexOf(
'/') + 1);
130 OUString aDosName(
INetURLObject( rUrl ).getFSysPath( FSysStyle::Dos ) );
137 OUString aTmpName( aDosName );
147 else if (aDosName.startsWith(
"./"))
149 aDosName = aDosName.copy(2);
153 while (aDosName.startsWith(
"../"))
156 aDosName = aDosName.copy(3);
165 if ( !pINetFormatArg )
return;
168 0xD0, 0xC9, 0xEA, 0x79, 0xF9, 0xBA, 0xCE, 0x11, 0x8C, 0x82, 0x00, 0xAA, 0x00, 0x4B, 0xA9, 0x0B };
169 const sal_uInt8 aGuidUrlMoniker[ 16 ] = {
170 0xE0, 0xC9, 0xEA, 0x79, 0xF9, 0xBA, 0xCE, 0x11, 0x8C, 0x82, 0x00, 0xAA, 0x00, 0x4B, 0xA9, 0x0B };
172 const sal_uInt8 aGuidFileMoniker[ 16 ] = {
173 0x03, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xC0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x46 };
175 0xFF, 0xFF, 0xAD, 0xDE, 0x00, 0x00, 0x00, 0x00,
176 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
177 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
180 constexpr sal_uInt32 WW8_HLINK_BODY = 0x00000001;
181 constexpr sal_uInt32 WW8_HLINK_ABS = 0x00000002;
183 constexpr sal_uInt32 WW8_HLINK_MARK = 0x00000008;
184 constexpr sal_uInt32 WW8_HLINK_FRAME = 0x00000080;
187 OUString tmpTextMark;
189 OUString rUrl = pINetFormatArg->
GetURL();
191 sal_uInt32 nFlags = 0;
197 if (!rTarFrame.isEmpty())
204 nFlags |= WW8_HLINK_FRAME;
208 if (eProtocol == INetProtocol::File || (eProtocol == INetProtocol::NotValid && rUrl[0] !=
'#'))
215 nFlags |= WW8_HLINK_ABS;
217 nFlags |= WW8_HLINK_BODY;
219 tmpStrm.
WriteBytes(aGuidFileMoniker,
sizeof(aGuidFileMoniker));
223 tmpStrm.
WriteBytes(aGuidFileTail,
sizeof(aGuidFileTail));
231 else if( eProtocol != INetProtocol::NotValid )
233 tmpStrm.
WriteBytes(aGuidUrlMoniker,
sizeof(aGuidUrlMoniker));
237 nFlags |= WW8_HLINK_BODY | WW8_HLINK_ABS;
239 else if (rUrl[0] ==
'#' )
241 OUString aTextMark(rUrl.copy( 1 ));
242 aTextMark = aTextMark.replaceFirst(
".",
"!");
243 tmpTextMark = aTextMark;
246 if (tmpTextMark.isEmpty() && aUrlObj.
HasMark())
248 tmpTextMark = aUrlObj.
GetMark();
251 if (!tmpTextMark.isEmpty())
256 nFlags |= WW8_HLINK_MARK;
266 std::unique_ptr<sal_uInt8[]> pBuffer(
new sal_uInt8[ nLen ] );
275 if (!pINetFormat || pINetFormat->
GetURL().isEmpty())
282 OUString aNamestr = pINetFormat->
GetName();
283 if (!aNamestr.isEmpty())
309 class CompareDrawObjs
315 explicit CompareDrawObjs(
const WW8Export& rWrt) : m_rWrt(rWrt) {};
318 sal_uLong aSort = lcl_getSdrOrderNumber(m_rWrt, a);
319 sal_uLong bSort = lcl_getSdrOrderNumber(m_rWrt, b);
320 return aSort < bSort;
328 void lcl_makeZOrderArray(
const WW8Export& rWrt,
329 std::vector<DrawObj> &rSrcArr,
330 std::vector<DrawObj*> &rDstArr)
333 rDstArr.reserve(rSrcArr.size());
336 rDstArr.push_back( &i );
338 std::sort(rDstArr.begin(), rDstArr.end(), CompareDrawObjs(rWrt));
354 uno::Reference< awt::XControlModel > xControlModel =
356 uno::Reference< lang::XServiceInfo > xInfo(xControlModel,
358 uno::Reference<beans::XPropertySet> xPropSet(xControlModel, uno::UNO_QUERY);
362 if (xInfo->supportsService(
"com.sun.star.form.component.ComboBox"))
374 uno::Sequence<OUString> aListItems;
375 xPropSet->getPropertyValue(
"StringItemList") >>= aListItems;
376 if (aListItems.hasElements())
378 uno::Any aTmp = xPropSet->getPropertyValue(
"DefaultText");
379 auto pStr = o3tl::tryAccess<OUString>(aTmp);
386 uno::Any aTmp = xPropSet->getPropertyValue(
"Name");
387 auto pStr = o3tl::tryAccess<OUString>(aTmp);
397 uno::Any aTmp = xPropSet->getPropertyValue(
"HelpText");
398 auto pStr = o3tl::tryAccess<OUString>(aTmp);
402 catch(
const uno::Exception& )
408 uno::Any aTmp = xPropSet->getPropertyValue(
"Name");
409 auto pStr = o3tl::tryAccess<OUString>(aTmp);
414 DoComboBox(sName, sHelp, sToolTip, sSelected, aListItems);
418 const OUString &rHelp,
419 const OUString &rToolTip,
420 const OUString &rSelected,
421 const uno::Sequence<OUString> &rListItems)
441 m_pChpPlc->AppendFkpEntry(
Strm().Tell(),
sizeof(aArr1), aArr1);
453 sal_uInt32 nListItems = rListItems.getLength();
455 for (sal_uInt32 i = 0;
i < nListItems;
i++)
457 if (i < 0x20 && rSelected == rListItems[i])
458 aFFData.
setResult(::sal::static_int_cast<sal_uInt8>(i));
485 sizeof( aArr1 ), aArr1 );
497 const OUString fieldStr( pField->
ExpandField(
true,
nullptr) );
505 pDataAdr = aArr2 + 2;
508 sizeof( aArr2 ), aArr2 );
522sal_Int16 eHoriOri, sal_Int16 eHoriRel,
SwTwips nPageLeft,
528 if (eHoriRel == text::RelOrientation::PAGE_FRAME)
530 rLeft = nPageSize - rLeft;
534 (eHoriRel == text::RelOrientation::PAGE_PRINT_AREA) ||
535 (eHoriRel == text::RelOrientation::FRAME) ||
536 (eHoriRel == text::RelOrientation::PRINT_AREA)
539 rLeft = nPageSize - nPageLeft - nPageRight - rLeft;
549 sal_Int16 eHoriOri, sal_Int16 eHoriRel,
SwTwips nPageLeft,
555 if (eHoriRel == text::RelOrientation::PAGE_FRAME)
557 rLeft = nPageSize + rLeft;
561 (eHoriRel == text::RelOrientation::PAGE_PRINT_AREA) ||
562 (eHoriRel == text::RelOrientation::FRAME) ||
563 (eHoriRel == text::RelOrientation::PRINT_AREA)
566 rLeft = nPageSize - nPageLeft - nPageRight + rLeft;
580 SwTwips nWidth = rRight - rLeft;
605 rRight = rLeft + nWidth;
610 if (8 > rWrt.
m_pFib->m_nVersion)
631 const ww8::Frame &rFrameFormat = rDrawObj.maContent;
640 const bool bPosConverted =
644 bool bHasHeightWidthSwapped(
false);
661 aRect = aLayRect.
SVRect();
666 OSL_ENSURE(pObj,
"Where is the SDR-Object?");
674 if ( bAllowSwap && (( nAngle > 4500_deg100 && nAngle <= 13500_deg100 ) || ( nAngle > 22500_deg100 && nAngle <= 31500_deg100 )) )
680 bHasHeightWidthSwapped =
true;
694 aRect -= rDrawObj.maParentPos;
700 if (eOri == text::RelOrientation::CHAR || eOri == text::RelOrientation::TEXT_LINE)
710 sal_Int32 nThick = rDrawObj.mnThick;
732 if (nTop == 0 && !rFrameFormat.
IsInline() &&
754 if(bHasHeightWidthSwapped)
756 nXOff = (nSnapWidth - nLogicHeight + 1) / 2;
757 nYOff = (nSnapHeight - nLogicWidth + 1) / 2;
761 nXOff = (nSnapWidth - nLogicWidth + 1) / 2;
762 nYOff = (nSnapHeight - nLogicHeight + 1) / 2;
787 sal_uInt16 nContour = rSurr.
IsContour() ? 0x0080 : 0x0040;
788 css::text::WrapTextMode eSurround = rSurr.
GetSurround();
797 eSurround = css::text::WrapTextMode_THROUGH;
801 case css::text::WrapTextMode_NONE:
804 case css::text::WrapTextMode_THROUGH:
807 case css::text::WrapTextMode_PARALLEL:
808 nFlags |= 0x0000 | nContour;
810 case css::text::WrapTextMode_DYNAMIC:
811 nFlags |= 0x0600 | nContour;
813 case css::text::WrapTextMode_LEFT:
814 nFlags |= 0x0200 | nContour;
816 case css::text::WrapTextMode_RIGHT:
817 nFlags |= 0x0400 | nContour;
820 OSL_ENSURE(
false,
"Unsupported surround type for export");
846 sal_uInt32 nLen)
const
858 sal_uInt32 nLen)
const
870 const Point& rNdTopLeft )
962 const Point& rNdTopLeft)
964 OSL_ENSURE(!
m_pEscher,
"the EscherStream was already written!");
980 bool bSuccess = pDrwO->
Append(*
this, nCP, rFrameFormat, rNdTopLeft);
981 OSL_ENSURE(bSuccess,
"Couldn't export a graphical element!");
987 0x03, 0x6a, 0, 0, 0, 0,
996 m_pChpPlc->AppendFkpEntry(
Strm().Tell(),
sizeof( aSpec8 ), aSpec8 );
1009 :
MSWordAttrIter( rWr ), m_pEditObj(&rEditObj), m_pEditPool(nullptr), mnTyp(nTyp)
1047 sal_Int32
nPos = rTextAtr.nStart;
1048 if(
nPos >= nStartPos &&
nPos <= nMinPos )
1054 nPos = rTextAtr.nEnd;
1055 if(
nPos >= nStartPos &&
nPos < nMinPos )
1074 rtl_TextEncoding eChrSet =
static_cast<const SvxFontItem&
>(rItem).GetCharSet();
1080 std::vector<const EECharAttrib*>::iterator it =
1094 if (
auto pURL =
dynamic_cast< const SvxURLField *
>( pField ))
1100 const OUString &rStr = pURL->GetRepresentation();
1115 std::set<sal_uInt16> aUsedRunWhichs;
1118 if (nSwPos >= rTextAtr.nStart && nSwPos < rTextAtr.nEnd)
1120 sal_uInt16 nWhich = rTextAtr.pAttr->Which();
1121 aUsedRunWhichs.insert(nWhich);
1124 if( nSwPos < rTextAtr.nStart )
1144 if (nSwPos >= rTextAtr.nStart && nSwPos < rTextAtr.nEnd)
1146 sal_uInt16 nWhich = rTextAtr.pAttr->Which();
1164 const sal_uInt16 nSlotId = pSrcPool->
GetSlotId(nWhich);
1165 if (nSlotId && nWhich != nSlotId)
1167 nWhich = rDstPool.
GetWhich(nSlotId);
1168 if (nWhich && nWhich != nSlotId &&
1173 std::unique_ptr<SfxPoolItem> pI(rTextAtr.pAttr->Clone());
1174 pI->SetWhich( nWhich );
1185 if( nSwPos < rTextAtr.nStart )
1198 return (nSwPos >= rTextAtr.nStart && nSwPos < rTextAtr.nEnd) &&
1199 (rTextAtr.pAttr->Which() == EE_FEATURE_FIELD ||
1200 rTextAtr.pAttr->Which() == EE_FEATURE_TAB);
1219 return rTextAtr.pAttr;
1235 OSL_ENSURE(nWhich,
"Impossible, catastrophic failure imminent");
1236 pRet = &aSet.
Get(nWhich);
1250 for (sal_uInt16 nEEWhich = aWhichIter.
FirstWhich(); nEEWhich; nEEWhich = aWhichIter.
NextWhich())
1252 if (SfxItemState::SET != aWhichIter.
GetItemState(
false))
1265 if (rDrawItem != rStandardItem)
1291 sal_uInt16 nWhich = pItem->
Which();
1292 if (pWhichsToIgnore && pWhichsToIgnore->find(nWhich) != pWhichsToIgnore->end())
1295 sal_uInt16 nSlotId = pSrcPool->
GetSlotId(nWhich);
1297 if ( nSlotId && nWhich != nSlotId &&
1298 0 != ( nWhich = pDstPool->GetWhich( nSlotId ) ) &&
1299 nWhich != nSlotId &&
1304 std::unique_ptr<SfxPoolItem> pI(pItem->
Clone());
1305 pI->SetWhich( nWhich );
1309 }
while ((pItem = aIter.
NextItem()));
1339 bool bAnyWrite =
false;
1345 for( sal_Int32
n = 0;
n < nPara; ++
n )
1350 OSL_ENSURE(
m_pO->empty(),
" pO is not empty at start of line" );
1353 sal_Int32 nCurrentPos = 0;
1354 const sal_Int32 nEnd =
aStr.getLength();
1357 bool bIsRTLPara =
false;
1361 bIsRTLPara = SvxFrameDirection::Horizontal_RL_TB == nDir;
1367 bool bTextAtr = aAttrIter.
IsTextAttr( nCurrentPos );
1373 if( nNextAttr == nEnd && !bTextAtr )
1377 aAttrIter.
OutAttr( nCurrentPos );
1394 if( nNextAttr == nEnd && bTextAtr )
1396 nCurrentPos = nNextAttr;
1399 while( nCurrentPos < nEnd );
1401 OSL_ENSURE(
m_pO->empty(),
" pO is not empty at start of line" );
1403 m_pO->push_back( bNul );
1404 m_pO->push_back( bNul );
1415 bAnyWrite = 0 != nPara;
1459 OSL_ENSURE( !
m_pEscher,
"Who did not deleted the pointer?" );
1461 pEscherStrm->
SetEndian(SvStreamEndian::LITTLE);
1475 m_pFib->m_fcDggInfo = nStart;
1488 mxGlobal->SetNewBlipStreamOffset( nEndPos );
1490 pPicStrm->Seek( 0 );
1509 mxPicStrm = std::make_shared<SvMemoryStream>();
1510 mxPicStrm->SetEndian(SvStreamEndian::LITTLE);
1551 nFlags |= ShapeFlag::FlipH;
1554 nFlags |= ShapeFlag::FlipV;
1557 nFlags |= ShapeFlag::FlipH | ShapeFlag::FlipV;
1571 if ( !aUniqueId.isEmpty() )
1573 sal_uInt32 nBlibId =
mxGlobal->GetBlibID( *(
mxGlobal->QueryPictureStream()), aGraphicObject );
1588 std::shared_ptr<SvxBrushItem> aBrush(std::make_shared<SvxBrushItem>(aTmpColor,
RES_BACKGROUND));
1591 aBrush.reset(pRet->
Clone());
1603 sal_Int32 nBorderThick=0;
1606 OSL_ENSURE(pGrfNd,
"No SwGrfNode ?, suspicious");
1608 return nBorderThick;
1614 AddMirrorFlags(ShapeFlag::HaveAnchor | ShapeFlag::HaveShapeProperty, rMirror),
1640 if (!aUniqueId.isEmpty())
1658 return nBorderThick;
1665 sal_Int32 nContrast = 0;
1666 sal_Int16 nBrightness = 0;
1670 nContrast = pItem->GetValue();
1675 nBrightness = pItem->GetValue();
1681 if (nMode == GraphicDrawMode::Watermark)
1691 if (nBrightness > 100)
1694 if (nContrast < -100)
1696 nMode = GraphicDrawMode::Standard;
1700 sal_uInt32 nPictureMode;
1701 if (nMode == GraphicDrawMode::Greys)
1702 nPictureMode = 0x40004;
1703 else if (nMode == GraphicDrawMode::Mono)
1704 nPictureMode = 0x60006;
1712 if (nContrast == 100)
1713 nContrast = 0x10000;
1714 else if (nContrast < 100)
1716 nContrast *= 0x10000;
1719 else if (nContrast < 200)
1720 nContrast = (100 * 0x10000) / (200-nContrast);
1722 nContrast = 0x7fffffff;
1726 if (nBrightness != 0)
1729 sal_Int32 nCropL = 0;
1730 sal_Int32 nCropR = 0;
1731 sal_Int32 nCropT = 0;
1732 sal_Int32 nCropB = 0;
1735 nCropL += pCropItem->GetLeft();
1736 nCropR += pCropItem->GetRight();
1737 nCropT += pCropItem->GetTop();
1738 nCropB += pCropItem->GetBottom();
1744 nCropL -= pBoxItem->GetDistance( SvxBoxItemLine::LEFT );
1745 nCropR -= pBoxItem->GetDistance( SvxBoxItemLine::RIGHT );
1746 nCropT -= pBoxItem->GetDistance( SvxBoxItemLine::TOP );
1747 nCropB -= pBoxItem->GetDistance( SvxBoxItemLine::BOTTOM );
1777 sal_Int32 nBorderThick = 0;
1789 awt::Rectangle aRect;
1790 bool bRectIsSet =
false;
1793 if ( xObj.is() && nAspect != embed::Aspects::MSOLE_ICON )
1797 awt::Size aSize = xObj->getVisualAreaSize( nAspect );
1798 aRect.Width = aSize.Width;
1799 aRect.Height = aSize.Height;
1802 catch(
const uno::Exception& )
1811#ifdef OLE_PREVIEW_AS_EMF
1819 AddMirrorFlags(ShapeFlag::HaveAnchor | ShapeFlag::HaveShapeProperty | ShapeFlag::OLEShape, rMirror),
1820 pGraphic ? *pGraphic :
Graphic(), *pSdrObj, nShapeId, bRectIsSet ? &aRect :
nullptr );
1831 return nBorderThick;
1837 bool bSetOpacity =
false;
1838 sal_uInt32 nOpaque = 0;
1841 OString aUniqueId = pGraphicObject->GetUniqueID();
1842 if (!aUniqueId.isEmpty())
1849 nOpaque = 255 - pGraphicObject->GetAttr().GetAlpha();
1871 nOpaque = (nOpaque * 100) / 0xFE;
1872 nOpaque = ((100 - nOpaque) << 16) / 100;
1881 bool bFirstLine =
true;
1889 const SvxBorderLine* pLine;
1893 pLine = pItem->GetLine(
n );
1894 if(
nullptr != pLine )
1898 sal_uInt32 nLineColor =
GetColor(pLine->GetColor());
1901 nLineColor ^ 0xffffff );
1904 if( pLine->isDouble() )
1908 if( pLine->GetInWidth() == pLine->GetOutWidth() )
1910 else if( pLine->GetInWidth() < pLine->GetOutWidth() )
1927 switch (pLine->GetBorderLineStyle())
1929 case SvxBorderLineStyle::DASHED:
1932 case SvxBorderLineStyle::DOTTED:
1935 case SvxBorderLineStyle::SOLID:
1949 pItem->GetDistance(
n ) ));
1972 constexpr sal_uInt32 nShadowType = 131074;
1974 Color nColor = pSI->GetColor();
1981 if( (eLocation!=SvxShadowLocation::NONE) && (pSI->GetWidth()!=0) )
1985 case SvxShadowLocation::TopLeft:
1991 case SvxShadowLocation::TopRight:
1996 case SvxShadowLocation::BottomLeft:
2001 case SvxShadowLocation::BottomRight:
2018 const bool bIsThrough = rFormat.
GetSurround().
GetValue() == css::text::WrapTextMode_THROUGH;
2022 if (bIsInHeader || bIsThrough)
2089 if (pPolyPoly && pPolyPoly->
Count())
2093 aPolyDump.
SetEndian(SvStreamEndian::LITTLE);
2095 sal_uInt16 nLen = aPoly.
GetSize();
2099 for (sal_uInt16 nI = 0; nI < nLen; ++nI)
2117 MapUnit eMap = MapUnit::MapTwip;
2122 eMap = pModel->GetScaleUnit();
2140 sal_Int32 nMSVal = (nVal / 65536) * nMax;
2141 nMSVal += (nVal * 65536) / nMax;
2146 sal_Int32
const nDiv = (nVal / sal_Int32(nMax)) - 1;
2147 sal_uInt32 nMSVal = (sal_uInt32(nDiv) << 16) & 0xffff0000;
2148 nMSVal += (nVal * 65536) / sal_Int32(nMax) + (-nDiv * 65536);
2165 sal_Int32 nEndPos = pPicStrm->Tell();
2180 sal_uInt16 nColorCount = 4;
2196 if (!pSdrObjs->
size())
2218 sal_uInt32 nShapeId=0;
2219 for (
auto& pObj : aSorted)
2221 sal_Int32 nBorderThick=0;
2222 OSL_ENSURE(pObj,
"impossible");
2247#if OSL_DEBUG_LEVEL > 0
2249 OSL_ENSURE(
false,
"Where is the SDR-Object?" );
2267 if( nSecondShapeId )
2272 ShapeFlag::HaveAnchor | ShapeFlag::HaveShapeProperty | ShapeFlag::Background,
2295 aPropOpt.
Commit( *pStrm );
2321 template<
typename OrientType>
2322 void lcl_SetRelationOrient(OrientType& rOrient,
const sw::WW8AnchorConv eConv,
const std::function<
void()>& fDefault)
2328 rOrient.SetRelationOrient(text::RelOrientation::PAGE_PRINT_AREA);
2331 rOrient.SetRelationOrient(text::RelOrientation::PAGE_FRAME);
2334 rOrient.SetRelationOrient(text::RelOrientation::FRAME);
2337 rOrient.SetRelationOrient(text::RelOrientation::CHAR);
2340 rOrient.SetRelationOrient(text::RelOrientation::TEXT_LINE);
2378 if ( (RndStdIds::FLY_AS_CHAR == eAnchor) || (RndStdIds::FLY_AT_FLY == eAnchor) )
2391 bool bConvDueToAnchoredAtColBreakPara(
false );
2392 if ( ( (eAnchor == RndStdIds::FLY_AT_PARA) || (eAnchor == RndStdIds::FLY_AT_CHAR) ) &&
2399 if (rBreak.
GetBreak() == SvxBreak::ColumnBefore)
2401 bConvDueToAnchoredAtColBreakPara =
true;
2411 bool bConvDueToOrientation(
false );
2414 bConvDueToOrientation = eHOri == text::HoriOrientation::LEFT || eHOri == text::HoriOrientation::RIGHT ||
2415 eHOri == text::HoriOrientation::INSIDE || eHOri == text::HoriOrientation::OUTSIDE ||
2416 ( eHOri != text::HoriOrientation::CENTER && _iorHoriOri.
IsPosToggle() );
2420 if ( bConvDueToAnchoredAtColBreakPara )
2425 && _iorHoriOri.
GetHoriOrient() == text::HoriOrientation::RIGHT )
2428 _iorHoriOri.
SetHoriOrient( text::HoriOrientation::OUTSIDE );
2434 case text::RelOrientation::PAGE_FRAME:
2435 case text::RelOrientation::PAGE_PRINT_AREA:
2437 if ( bConvDueToOrientation || bFollowTextFlow )
2441 case text::RelOrientation::PAGE_LEFT:
2442 case text::RelOrientation::PAGE_RIGHT:
2448 case text::RelOrientation::FRAME:
2450 if ( bConvDueToOrientation )
2454 case text::RelOrientation::PRINT_AREA:
2455 case text::RelOrientation::FRAME_LEFT:
2456 case text::RelOrientation::FRAME_RIGHT:
2462 case text::RelOrientation::CHAR:
2464 if ( bConvDueToOrientation )
2469 OSL_FAIL(
"<WinwordAnchoring::ConvertPosition(..)> - unknown horizontal relation" );
2478 bool bConvDueToOrientation(
false );
2481 bConvDueToOrientation = ( eVOri == text::VertOrientation::TOP ||
2482 eVOri == text::VertOrientation::BOTTOM ||
2483 eVOri == text::VertOrientation::CHAR_TOP ||
2484 eVOri == text::VertOrientation::CHAR_BOTTOM ||
2485 eVOri == text::VertOrientation::CHAR_CENTER ||
2486 eVOri == text::VertOrientation::LINE_TOP ||
2487 eVOri == text::VertOrientation::LINE_BOTTOM ||
2488 eVOri == text::VertOrientation::LINE_CENTER );
2492 if ( bConvDueToAnchoredAtColBreakPara )
2500 case text::RelOrientation::PAGE_FRAME:
2501 case text::RelOrientation::PAGE_PRINT_AREA:
2503 if ( bConvDueToOrientation || bFollowTextFlow )
2507 case text::RelOrientation::FRAME:
2509 if ( bConvDueToOrientation ||
2510 _iorVertOri.
GetVertOrient() == text::VertOrientation::CENTER )
2516 case text::RelOrientation::PRINT_AREA:
2522 case text::RelOrientation::CHAR:
2528 case text::RelOrientation::TEXT_LINE:
2530 if ( bConvDueToOrientation ||
2537 case text::RelOrientation::PAGE_LEFT:
2538 case text::RelOrientation::PAGE_RIGHT:
2539 case text::RelOrientation::FRAME_LEFT:
2540 case text::RelOrientation::FRAME_RIGHT:
2542 OSL_FAIL(
"<WinwordAnchoring::ConvertPosition(..)> - unknown vertical relation" );
2571 mbInline = (eAnchor == RndStdIds::FLY_AS_CHAR);
2585 const bool bPosConverted =
ConvertPosition( rHoriOri, rVertOri, rFormat );
2600 case text::HoriOrientation::LEFT:
2603 case text::HoriOrientation::CENTER:
2606 case text::HoriOrientation::RIGHT:
2609 case text::HoriOrientation::INSIDE:
2612 case text::HoriOrientation::OUTSIDE:
2621 const bool bVertSwap = !bPosConverted &&
2622 ( (eVRel == text::RelOrientation::CHAR) ||
2623 (eVRel == text::RelOrientation::TEXT_LINE) );
2630 case text::VertOrientation::TOP:
2631 case text::VertOrientation::LINE_TOP:
2632 case text::VertOrientation::CHAR_TOP:
2635 case text::VertOrientation::CENTER:
2636 case text::VertOrientation::LINE_CENTER:
2639 case text::VertOrientation::BOTTOM:
2640 case text::VertOrientation::LINE_BOTTOM:
2641 case text::VertOrientation::CHAR_BOTTOM:
2649 case text::RelOrientation::PAGE_PRINT_AREA:
2652 case text::RelOrientation::PAGE_FRAME:
2653 case text::RelOrientation::PAGE_LEFT:
2654 case text::RelOrientation::PAGE_RIGHT:
2657 case text::RelOrientation::FRAME:
2658 case text::RelOrientation::FRAME_LEFT:
2659 case text::RelOrientation::FRAME_RIGHT:
2660 if (eAnchor == RndStdIds::FLY_AT_PAGE)
2665 case text::RelOrientation::PRINT_AREA:
2666 if (eAnchor == RndStdIds::FLY_AT_PAGE)
2671 case text::RelOrientation::CHAR:
2674 case text::RelOrientation::TEXT_LINE:
2681 case text::RelOrientation::PAGE_PRINT_AREA:
2684 case text::RelOrientation::PAGE_FRAME:
2687 case text::RelOrientation::PRINT_AREA:
2688 if (eAnchor == RndStdIds::FLY_AT_PAGE)
2693 case text::RelOrientation::FRAME:
2694 if (eAnchor == RndStdIds::FLY_AT_PAGE)
2699 case text::RelOrientation::CHAR:
2700 case text::RelOrientation::TEXT_LINE:
2701 case text::RelOrientation::PAGE_LEFT:
2702 case text::RelOrientation::PAGE_RIGHT:
2703 case text::RelOrientation::FRAME_LEFT:
2704 case text::RelOrientation::FRAME_RIGHT:
2728 sal_Int32 nBorderThick = 0;
2748 sal_uInt16 nOff = 0;
2760 if( USHRT_MAX == nTextId )
2772 if( USHRT_MAX == nTextId )
2774 sal_uInt32 nPrevShapeId =
2792 if( bBrowseMode && rFormat.
GetDoc())
2807 return nBorderThick;
2813 auto aIter = std::find_if(rPVec.begin(), rPVec.end(),
2814 [&rFormat, nHdFtIndex](
const DrawObj* pObj) {
2815 OSL_ENSURE(pObj,
"Impossible");
2817 nHdFtIndex == pObj->mnHdFtIndex &&
2818 &rFormat == (&pObj->maContent.GetFrameFormat());
2820 if (aIter != rPVec.end())
2821 return static_cast< sal_uInt16
>(aIter - rPVec.begin());
2831 sal_Int32 nBorderThick=0;
2850 OSL_ENSURE(
false,
"unknown direction type");
2852 case SvxFrameDirection::Horizontal_LR_TB:
2855 case SvxFrameDirection::Horizontal_RL_TB:
2858 case SvxFrameDirection::Vertical_LR_TB:
2859 case SvxFrameDirection::Vertical_RL_TB:
2862 case SvxFrameDirection::Vertical_LR_BT:
2876 return nBorderThick;
2881 sal_uInt32 nShapeId,
const awt::Rectangle* pVisArea )
2896 SetPicId(rObj, nShapeId, rPropOpt);
2910 OSL_ENSURE(pModel && pDevice,
"no model or device");
2914 SdrView aExchange(*pModel, pDevice);
2918 ShapeFlag::HaveAnchor | ShapeFlag::HaveShapeProperty | ShapeFlag::OLEShape, aGraphic,
2919 *pSdrObj, nShapeId,
nullptr );
2934 ::lcl_makeZOrderArray(
mrWrt, rSrcArr, rDstArr);
2942 bool bNeedsShapeId =
false;
2948 bNeedsShapeId =
true;
2960 sal_uInt16
nPos =
FindPos(rFormat, nHdFtIndex, rpVec);
2961 sal_uInt32 nShapeId;
2962 if (USHRT_MAX !=
nPos)
2977 const uno::Reference< drawing::XShape>& xXShapeRef, sal_uInt32 nShapeId )
2990::ole::MSConvertOCXControls( pDSh ? pDSh->GetModel() : nullptr ), m_pPaM( pP ), mnObjectId(0)
2998 css::uno::Reference< css::drawing::XShape > *pShapeRef,
2999 bool bFloatingCtrl )
3001 uno::Reference< form::XFormComponent > xFComp;
3003 if ( bRes && xFComp.is() )
3013 const uno::Reference< awt::XControlModel >& xControlModel =
3031 OUString sStorageName =
"_" + OUString::number(
static_cast<sal_Int64
>( nObjId ));
3043 0x03, 0x6a, 0xFF, 0xFF, 0xFF, 0xFF,
css::chart::ChartAxisLabelPosition ePos
css::uno::Reference< css::frame::XModel2 > mxModel
Fraction conversionFract(o3tl::Length from, o3tl::Length to)
constexpr auto convertTwipToMm100(N n)
static OutputDevice * GetDefaultDevice()
virtual void RawText(const OUString &rText, rtl_TextEncoding eCharSet)=0
Output text (without markup).
virtual bool EndURL(bool isAtEndOfParagraph)=0
Output URL end.
virtual bool StartURL(const OUString &rUrl, const OUString &rTarget)=0
Output URL start.
void OutputItem(const SfxPoolItem &rHt)
Call the right virtual function according to the type of the item.
const OUString & GetValue() const
sal_uInt8 GetAlpha() const
SvxFrameDirection mnDirection
void SetShapeDetails(sal_uInt32 nId, sal_Int32 nThick)
virtual sal_Int32 GetParagraphCount() const=0
virtual OUString GetText(sal_Int32 nPara) const=0
virtual const SfxItemSet & GetParaAttribs(sal_Int32 nPara) const=0
virtual void GetCharAttribs(sal_Int32 nPara, std::vector< EECharAttrib > &rLst) const=0
SvStream * GetPictureStream()
void SetClientData(EscherExClientRecord_Base *p)
virtual sal_uInt32 EnterGroup(const OUString &rShapeName, const tools::Rectangle *pBoundRect)
SdrLayerID GetHellLayerId() const
sal_uInt32 AddDummyShape()
sal_uInt32 AddSdrObject(const SdrObject &rObj, bool ooxmlExport=false, sal_uInt32 nId=0)
virtual void AddShape(sal_uInt32 nShpInstance, ShapeFlag nFlagIds, sal_uInt32 nShapeID=0)
void AddAtom(sal_uInt32 nAtomSitze, sal_uInt16 nRecType, int nRecVersion=0, int nRecInstance=0)
void SetHellLayerId(SdrLayerID nId)
static sal_uInt32 GetColor(const sal_uInt32 nColor)
virtual sal_uInt32 GenerateShapeId()
std::shared_ptr< EscherExGlobal > mxGlobal
virtual void OpenContainer(sal_uInt16 nEscherContainer, int nRecInstance=0)
void Flush(SvStream *pPicStreamMergeBSE=nullptr)
SvStream & GetStream() const
SvStream * QueryPictureStream()
sal_uInt32 GetGroupLevel() const
virtual void CloseContainer()
void AddOpt(sal_uInt16 nPropID, bool bBlib, sal_uInt32 nSizeReduction, SvMemoryStream &rStream)
bool GetOpt(sal_uInt16 nPropertyID, sal_uInt32 &rPropValue) const
void Commit(SvStream &rSt, sal_uInt16 nVersion=3, sal_uInt16 nRecType=ESCHER_OPT)
const Fraction & X() const
sal_Int32 GetNumerator() const
sal_Int32 GetDenominator() const
OString GetUniqueID() const
virtual void RegisterWithFib(WW8Fib &rFib, sal_uInt32 nStart, sal_uInt32 nLen) const override
virtual WW8_CP GetCpOffset(const WW8Fib &rFib) const override
virtual SdrLayerID GetHellId() const =0
virtual SdrLayerID GetInvisibleHellId() const =0
virtual const SwDrawModel * GetDrawModel() const =0
Draw Model and id accessors.
virtual bool get(DocumentSettingId id) const =0
Return the specified document setting.
virtual SwTextFormatColl * GetTextCollFromPool(sal_uInt16 nId, bool bRegardLanguage=true)=0
Return "Auto-Collection with ID.
OUString GetMark(DecodeMechanism eMechanism=DecodeMechanism::ToIUri, rtl_TextEncoding eCharset=RTL_TEXTENCODING_UTF8) const
static OUString GetRelURL(std::u16string_view rTheBaseURIRef, OUString const &rTheAbsURIRef, EncodeMechanism eEncodeMechanism=EncodeMechanism::WasEncoded, DecodeMechanism eDecodeMechanism=DecodeMechanism::ToIUri, rtl_TextEncoding eCharset=RTL_TEXTENCODING_UTF8, FSysStyle eStyle=FSysStyle::Detect)
INetProtocol GetProtocol() const
The class MSWordAttrIter is a helper class to build the Fkp.chpx.
MSWordExportBase & m_rExport
Base class for WW8Export and DocxExport.
SvxFrameDirection TrueFrameDirection(const SwFrameFormat &rFlyFormat) const
Right to left?
const SfxItemSet * GetCurItemSet() const
Getter for pISet.
virtual bool CollapseScriptsforWordOk(sal_uInt16 nScript, sal_uInt16 nWhich)=0
Guess the script (asian/western).
virtual void WriteChar(sal_Unicode c)=0
const sw::BroadcastingModify * m_pOutFormatNode
std::unique_ptr< MainTextPlcDrawObj > m_pSdrObjs
std::unique_ptr< WW8_WrPlcTextBoxes > m_pHFTextBxs
std::unique_ptr< WW8_WrPlcField > m_pFieldTextBxs
bool m_bFontSizeWritten
Is font size written already as part of the current character properties?
std::unique_ptr< WW8_WrPlcField > m_pFieldHFTextBxs
virtual AttributeOutputBase & AttrOutput() const =0
Access to the attribute output class.
void SetCurItemSet(const SfxItemSet *pS)
Setter for pISet.
std::unique_ptr< WW8_WrPlcPn > m_pPapPlc
std::unique_ptr< HdFtPlcDrawObj > m_pHFSdrObjs
std::unique_ptr< WW8_WrPlcTextBoxes > m_pTextBxs
std::unique_ptr< WW8_WrPlcPn > m_pChpPlc
Used to export formatted text associated to drawings.
virtual const SfxPoolItem & GetItem(sal_uInt16 nWhich) const override
void SetCharSet(const EECharAttrib &rTextAttr, bool bStart)
void OutAttr(sal_Int32 nSwPos)
rtl_TextEncoding GetNextCharSet() const
void OutParaAttr(bool bCharAttr, const std::set< sal_uInt16 > *pWhichsToIgnore=nullptr)
rtl_TextEncoding GetNodeCharSet() const
MSWord_SdrAttrIter(const MSWord_SdrAttrIter &)=delete
virtual const SfxPoolItem * HasTextItem(sal_uInt16 nWhich) const override
std::vector< EECharAttrib > m_aTextAtrArr
sal_Int32 SearchNext(sal_Int32 nStartPos)
sal_Int32 m_nCurrentSwPos
std::vector< const EECharAttrib * > m_aChrTextAtrArr
std::vector< rtl_TextEncoding > m_aChrSetArr
void NextPara(sal_Int32 nPar)
bool IsTextAttr(sal_Int32 nSwPos)
void SetItemsThatDifferFromStandard(bool bCharAttr, SfxItemSet &rSet)
void OutEEField(const SfxPoolItem &rHt)
sal_Int32 WhereNext() const
const SfxItemPool * m_pEditPool
const EditTextObject * m_pEditObj
rtl_TextEncoding m_eNdChrSet
virtual WW8_CP GetCpOffset(const WW8Fib &) const override
virtual void RegisterWithFib(WW8Fib &rFib, sal_uInt32 nStart, sal_uInt32 nLen) const override
const EditTextObject & GetTextObject() const
DrawObjVector & GetObjArr()
virtual void RegisterWithFib(WW8Fib &rFib, sal_uInt32 nStart, sal_uInt32 nLen) const =0
virtual WW8_CP GetCpOffset(const WW8Fib &rFib) const =0
void WritePlc(WW8Export &rWrt) const
bool Append(WW8Export const &, WW8_CP nCp, const ww8::Frame &rFormat, const Point &rNdTopLeft)
constexpr tools::Long Y() const
void setX(tools::Long nX)
void setY(tools::Long nY)
constexpr tools::Long X() const
static Graphic GetObjGraphic(const SdrObject &rSdrObject, bool bSVG=false)
const SdrPage * GetPage(sal_uInt16 nPgNum) const
size_t GetObjCount() const
static SdrObject * getSdrObjectFromXShape(const css::uno::Reference< css::uno::XInterface > &xInt)
virtual Degree100 GetRotateAngle() const
sal_uInt32 GetOrdNum() const
virtual const tools::Rectangle & GetSnapRect() const
virtual SdrObjKind GetObjIdentifier() const
virtual SdrLayerID GetLayer() const
virtual const tools::Rectangle & GetLogicRect() const
bool IsTextEditActive() const
virtual OutlinerParaObject * GetOutlinerParaObject() const override
std::optional< OutlinerParaObject > CreateEditOutlinerParaObject() const
virtual const tools::Rectangle & GetLogicRect() const override
const css::uno::Reference< css::awt::XControlModel > & GetUnoControlModel() const
const SfxPoolItem * GetCurItem() const
const SfxPoolItem * NextItem()
sal_uInt16 GetWhich(sal_uInt16 nSlot, bool bDeep=true) const
sal_uInt16 GetSlotId(sal_uInt16 nWhich) const
SfxItemPool * GetPool() const
const T * GetItemIfSet(TypedWhichId< T > nWhich, bool bSrchInParent=true) const
const SfxPoolItem * GetItem(sal_uInt16 nWhich, bool bSearchInParent=true) const
const SfxPoolItem * Put(const SfxPoolItem &rItem, sal_uInt16 nWhich)
const SfxPoolItem & Get(sal_uInt16 nWhich, bool bSrchInParent=true) const
SfxItemSet & GetItemSet() const
virtual SfxPoolItem * Clone(SfxItemPool *pPool=nullptr) const=0
SfxItemState GetItemState(bool bSrchInParent=true, const SfxPoolItem **ppItem=nullptr) const
constexpr tools::Long Height() const
constexpr tools::Long Width() const
SotStorage * OpenSotStorage(const OUString &rEleName, StreamMode=StreamMode::STD_READWRITE, bool transacted=true)
SotStorage & GetStorage() const
SvStream & WriteInt32(sal_Int32 nInt32)
void SetEndian(SvStreamEndian SvStreamEndian)
std::size_t WriteBytes(const void *pData, std::size_t nSize)
SvStream & WriteUInt16(sal_uInt16 nUInt16)
SvStream & WriteUInt32(sal_uInt32 nUInt32)
sal_uInt64 Seek(sal_uInt64 nPos)
SvStream & WriteChar(char nChar)
std::size_t ReadBytes(void *pData, std::size_t nSize)
sal_uInt64 remainingSize()
SvStream & WriteStream(SvStream &rStream)
const GraphicObject * GetGraphicObject(OUString const &referer=OUString()) const
const Color & GetColor() const
const Graphic * GetGraphic(OUString const &referer=OUString()) const
virtual SvxBrushItem * Clone(SfxItemPool *pPool=nullptr) const override
const Color & GetValue() const
const SvxFieldData * GetField() const
const Size & GetSize() const
const SwMirrorGrf & GetMirrorGrf(bool=true) const
virtual void WritePictures()
sal_Int32 WriteOLEFlyFrame(const SwFrameFormat &rFormat, sal_uInt32 nShapeId)
void WriteHyperlinkWithinFly(SvMemoryStream &rStrm, const SwFormatURL *pINetFormatArg)
void WriteOLEPicture(EscherPropertyContainer &rPropOpt, ShapeFlag nShapeFlags, const Graphic &rGraphic, const SdrObject &rObj, sal_uInt32 nShapeId, const css::awt::Rectangle *pVisArea)
virtual void SetPicId(const SdrObject &, sal_uInt32, EscherPropertyContainer &)
void WriteEmptyFlyFrame(const SwFrameFormat &rFormat, sal_uInt32 nShapeId)
SdrLayerID GetInvisibleHellId() const
static sal_Int32 ToFract16(sal_Int32 nVal, sal_uInt32 nMax)
sal_Int32 DrawModelToEmu(sal_Int32 nVal) const
SwBasicEscherEx(SvStream *pStrm, WW8Export &rWrt)
OUString BuildFileName(sal_uInt16 &rnLevel, bool &rbRel, const OUString &rUrl)
sal_Int32 WriteGrfFlyFrame(const SwFrameFormat &rFormat, sal_uInt32 nShapeId)
virtual ~SwBasicEscherEx() override
void WriteBrushAttr(const SvxBrushItem &rBrush, EscherPropertyContainer &rPropOpt)
static void WriteGrfAttr(const SwNoTextNode &rNd, const SwFrameFormat &rFormat, EscherPropertyContainer &rPropOpt)
virtual sal_Int32 WriteFlyFrameAttr(const SwFrameFormat &rFormat, MSO_SPT eShapeType, EscherPropertyContainer &rPropOpt)
virtual void WriteFrameExtraData(const SwFrameFormat &)
OUString GetBasePath() const
void PreWriteHyperlinkWithinFly(const SwFrameFormat &rFormat, EscherPropertyContainer &rPropOpt)
void WriteGrfBullet(const Graphic &)
css::uno::Reference< css::i18n::XBreakIterator > const & GetBreakIter() const
const SwAttrSet & GetSwAttrSet() const
Does node has already its own auto-attributes? Access to SwAttrSet.
IDocumentStylePoolAccess const & getIDocumentStylePoolAccess() const
const SwAttrPool & GetAttrPool() const
IDocumentDrawModelAccess const & getIDocumentDrawModelAccess() const
const sw::FrameFormats< sw::SpzFrameFormat * > * GetSpzFrameFormats() const
const SwPageDesc & GetPageDesc(const size_t i) const
SvxFrameDirection GetTextDirection(const SwPosition &rPos, const Point *pPt=nullptr) const
virtual SvStream * ImplQueryPictureStream() override
Override to create a new memory stream for picture data.
std::shared_ptr< SvStream > mxPicStrm
virtual ~SwEscherExGlobal() override
virtual void SetPicId(const SdrObject &rSdrObj, sal_uInt32 nShapeId, EscherPropertyContainer &rPropOpt) override
void WriteOCXControl(const SwFrameFormat &rFormat, sal_uInt32 nShapeId)
EscherExHostAppData m_aHostData
virtual ~SwEscherEx() override
sal_uInt32 GetFlyShapeId(const SwFrameFormat &rFormat, unsigned int nHdFtIndex, DrawObjPointerVector &rPVec)
virtual sal_Int32 WriteFlyFrameAttr(const SwFrameFormat &rFormat, MSO_SPT eShapeType, EscherPropertyContainer &rPropOpt) override
SwEscherEx(SvStream *pStrm, WW8Export &rWW8Wrt)
std::vector< sal_uLong > m_aFollowShpIds
sal_Int32 WriteTextFlyFrame(const DrawObj &rObj, sal_uInt32 nShapeId, sal_uInt32 nTextBox, DrawObjPointerVector &rPVec)
virtual void WritePictures() override
sal_Int32 WriteFlyFrame(const DrawObj &rObj, sal_uInt32 &rShapeId, DrawObjPointerVector &rPVec)
WinwordAnchoring m_aWinwordAnchoring
virtual void WriteFrameExtraData(const SwFrameFormat &rFormat) override
virtual sal_uInt32 QueryTextID(const css::uno::Reference< css::drawing::XShape > &, sal_uInt32) override
void MakeZOrderArrAndFollowIds(std::vector< DrawObj > &rSrcArr, DrawObjPointerVector &rDstArr)
WW8_WrPlcTextBoxes * m_pTextBxs
OUString ExpandField(bool bCached, SwRootFrame const *pLayout) const
expand the field.
const SwNodeIndex * GetContentIdx() const
bool IsLinkedFile() const
const Graphic & GetGrf(bool bWait=false) const
bool GetFileFilterNms(OUString *pFileNm, OUString *pFilterNm) const
virtual bool InsertControl(const css::uno::Reference< css::form::XFormComponent > &rFComp, const css::awt::Size &rSize, css::uno::Reference< css::drawing::XShape > *pShape, bool bFloatingCtrl) override
bool ReadOCXStream(tools::SvRef< SotStorage > const &rSrc1, css::uno::Reference< css::drawing::XShape > *pShapeRef, bool bFloatingCtrl=false)
SwMSConvertControls(SfxObjectShell const *pDSh, SwPaM *pP)
void ExportControl(WW8Export &rWrt, const SdrUnoObj &rFormObj)
static sal_Int32 GetEscherLineMatch(MSO_LineStyle eStyle, MSO_SPT eShapeType, sal_Int32 &rThick)
Layout frame for SwNoTextNode, i.e. graphics and OLE nodes (including charts).
virtual Size GetTwipSize() const =0
Marks a node in the document model.
SwOLENode * GetOLENode()
Inline methods from Node.hxx.
SwNodeType GetNodeType() const
sal_Int64 GetAspect() const
const SwOLEObj & GetOLEObj() const
const Graphic * GetGraphic()
css::uno::Reference< css::embed::XEmbeddedObject > const & GetOleRef()
PaM is Point and Mark: a selection of the document model.
SwFrameFormat & GetMaster()
Of course Writer needs its own rectangles.
tools::Rectangle SVRect() const
void Width(tools::Long nNew)
Represents the style of a paragraph.
SwTextNode is a paragraph in the document model.
const SfxPoolItem & GetAttr(sal_uInt16 nWhich, bool bInParent=true) const
End: Data collected during idle time.
static void WriteString8(SvStream &rStrm, std::u16string_view rStr, bool bAddZero, rtl_TextEncoding eCodeSet)
static void InsAsString16(ww::bytes &rO, const OUString &rStr)
static void InsUInt16(ww::bytes &rO, sal_uInt16 n)
static void WriteLong(SvStream &rStrm, sal_Int32 nVal)
static void WriteString16(SvStream &rStrm, const OUString &rStr, bool bAddZero)
static void WriteShort(SvStream &rStrm, sal_Int16 nVal)
Exporter of the binary Word file formats.
virtual void OutputField(const SwField *pField, ww::eField eFieldType, const OUString &rFieldCmd, FieldFlags nMode=FieldFlags::All) override
Write the field.
void WriteSdrTextObj(const SdrTextObj &rObj, sal_uInt8 nTyp)
void DoComboBox(css::uno::Reference< css::beans::XPropertySet > const &xPropSet)
void WriteStringAsPara(const OUString &rText)
void OutGrf(const ww8::Frame &rFrame)
void WriteOutliner(const OutlinerParaObject &rOutliner, sal_uInt8 nTyp)
void WriteChar(sal_Unicode c) override
SvStream * m_pDataStrm
Streams for WW97 Export.
void MiserableRTLFrameFormatHack(SwTwips &rLeft, SwTwips &rRight, const ww8::Frame &rFrameFormat)
Nasty swap for bidi if necessary.
bool MiserableFormFieldExportHack(const SwFrameFormat &rFrameFormat)
const SvxBrushItem * GetCurrentPageBgBrush() const
void AppendFlyInFlys(const ww8::Frame &rFrameFormat, const Point &rNdTopLeft)
unsigned int GetHdFtIndex() const
std::unique_ptr< WW8Fib > m_pFib
File Information Block.
std::shared_ptr< SvxBrushItem > TrueFrameBgBrush(const SwFrameFormat &rFlyFormat) const
SwTwips CurrentPageWidth(SwTwips &rLeft, SwTwips &rRight) const
virtual AttributeOutputBase & AttrOutput() const override
memory leak #i120098#, to hold the reference to unnamed SotStorage obj
sal_uInt32 GetSdrOrdNum(const SwFrameFormat &rFormat) const
virtual void DoFormText(const SwInputField *pField) override
WW8_CP Fc2Cp(sal_uLong nFc) const
SwWW8Writer & GetWriter() const
std::unique_ptr< ww::bytes > m_pO
Buffer.
virtual void WriteCR(ww8::WW8TableNodeInfoInner::Pointer_t pTableTextNodeInfoInner=ww8::WW8TableNodeInfoInner::Pointer_t()) override
void OutSwString(const OUString &, sal_Int32 nStt, sal_Int32 nLen)
FIB - the File Information Block.
sal_Int32 m_lcbPlcfspaHdr
sal_Int32 m_lcbPlcfspaMom
std::vector< const void * > m_aContent
std::vector< const SwFrameFormat * > m_aSpareFormats
bool WriteGenericText(WW8Export &rWrt, sal_uInt8 nTTyp, WW8_CP &rCount)
void Append(const SdrObject &rObj, sal_uInt32 nShapeId)
std::vector< sal_uInt32 > m_aShapeIds
sal_uInt16 GetPos(const void *p) const
bool WriteText(WW8Export &rWrt)
virtual const std::vector< sal_uInt32 > * GetShapeIdArr() const override
static bool ConvertPosition(SwFormatHoriOrient &_iorHoriOri, SwFormatVertOrient &_iorVertOri, const SwFrameFormat &_rFrameFormat)
method to perform conversion of positioning attributes with the help of corresponding layout informat...
void SetAnchoring(const SwFrameFormat &rFormat)
sal_uInt32 mnGroupShapeBooleanProperties
void WriteData(EscherEx &rEx) const override
static bool WriteOCXStream(const css::uno::Reference< css::frame::XModel > &rxModel, tools::SvRef< SotStorage > const &rSrc1, const css::uno::Reference< css::awt::XControlModel > &rControlModel, const css::awt::Size &rSize, OUString &rName)
bool ReadOCXStorage(tools::SvRef< SotStorage > const &rSrc1, css::uno::Reference< css::form::XFormComponent > &rxFormComp)
void addListboxEntry(const OUString &rEntry)
void setStatus(const OUString &rStatus)
void setName(const OUString &rName)
void setType(sal_uInt8 nType)
void setResult(sal_uInt8 nResult)
void setHelp(const OUString &rHelp)
void Write(SvStream *pDataStrm)
Make exporting a Writer Frame easy.
WriterSource GetWriterType() const
Get the type of frame that this wraps.
const SwFrameFormat & GetFrameFormat() const
Get the writer SwFrameFormat that this object describes.
bool IsInline() const
Is this frame inline (as character)
const SwPosition & GetPosition() const
Get the position this frame is anchored at.
constexpr ::Color COL_WHITE(0xFF, 0xFF, 0xFF)
constexpr ::Color COL_TRANSPARENT(ColorTransparency, 0xFF, 0xFF, 0xFF, 0xFF)
constexpr TypedWhichId< SvxFieldItem > EE_FEATURE_FIELD(EE_FEATURE_NOTCONV+1)
constexpr TypedWhichId< SvxFrameDirectionItem > EE_PARA_WRITINGDIR(EE_PARA_START+0)
constexpr sal_uInt16 EE_FEATURE_TAB(EE_FEATURE_START+0)
constexpr TypedWhichId< SvxColorItem > EE_CHAR_BKGCOLOR(EE_CHAR_START+32)
constexpr TypedWhichId< SvxFontItem > EE_CHAR_FONTINFO(EE_CHAR_START+1)
EmbeddedObjectRef * pObject
const sal_uInt32 nInlineHack
#define ESCHER_Prop_cropFromRight
#define ESCHER_Prop_pictureActive
#define ESCHER_Prop_lineColor
#define ESCHER_Prop_dyWrapDistTop
#define ESCHER_Prop_pibName
#define ESCHER_SplitMenuColors
#define ESCHER_Prop_fNoFillHitTest
#define ESCHER_ClientData
#define ESCHER_Prop_fNoLineDrawDash
#define ESCHER_Prop_wzName
#define ESCHER_Prop_lineStyle
#define ESCHER_Prop_shadowColor
ESCHER_BlipFlagLinkToFile
#define ESCHER_Prop_txflTextFlow
#define ESCHER_ShpInst_TextBox
#define ESCHER_DgContainer
#define ESCHER_Prop_dyWrapDistBottom
#define ESCHER_Prop_cropFromTop
#define ESCHER_Prop_dxWrapDistLeft
#define ESCHER_Prop_pictureBrightness
#define ESCHER_Prop_hspNext
#define ESCHER_Prop_lineBackColor
#define ESCHER_Prop_dxWrapDistRight
#define ESCHER_Prop_dxTextLeft
#define ESCHER_ClientAnchor
#define ESCHER_Prop_lineWidth
#define ESCHER_Prop_pibFlags
#define ESCHER_Prop_dyTextTop
#define ESCHER_Prop_cropFromLeft
#define ESCHER_Prop_fillBackColor
#define ESCHER_Prop_fillBlip
#define ESCHER_Prop_pictureId
#define ESCHER_Prop_cropFromBottom
#define ESCHER_Prop_dyTextBottom
#define ESCHER_Prop_fPrint
#define ESCHER_Prop_lTxid
#define ESCHER_ShpInst_Rectangle
#define ESCHER_Prop_fBackground
#define ESCHER_Prop_pihlShape
#define ESCHER_Prop_fillType
#define ESCHER_Prop_fillOpacity
#define ESCHER_Prop_pictureContrast
#define ESCHER_SpContainer
#define ESCHER_ClientTextbox
#define ESCHER_Prop_dxTextRight
#define ESCHER_DggContainer
#define ESCHER_Prop_fillColor
#define ESCHER_Prop_lineDashing
#define ESCHER_ShpInst_PictureFrame
constexpr TypedWhichId< SwFormatURL > RES_URL(117)
constexpr TypedWhichId< SwLuminanceGrf > RES_GRFATR_LUMINANCE(144)
constexpr TypedWhichId< SvxFontHeightItem > RES_CHRATR_FONTSIZE(8)
constexpr sal_uInt16 RES_PARATR_BEGIN(RES_TXTATR_END)
constexpr TypedWhichId< SvxFontHeightItem > RES_CHRATR_CJK_FONTSIZE(23)
constexpr TypedWhichId< SvxShadowItem > RES_SHADOW(113)
constexpr TypedWhichId< SwContrastGrf > RES_GRFATR_CONTRAST(145)
constexpr sal_uInt16 RES_FRMATR_END(141)
constexpr TypedWhichId< SfxInt16Item > RES_CHRATR_BIDIRTL(44)
constexpr TypedWhichId< SvxBrushItem > RES_BACKGROUND(111)
constexpr TypedWhichId< SwDrawModeGrf > RES_GRFATR_DRAWMODE(152)
constexpr TypedWhichId< SvxBrushItem > RES_CHRATR_BACKGROUND(21)
constexpr TypedWhichId< SwFlyFrameFormat > RES_FLYFRMFMT(162)
constexpr sal_uInt16 RES_CHRATR_BEGIN(HINT_BEGIN)
constexpr sal_uInt16 RES_UNKNOWNATR_BEGIN(RES_BOXATR_END)
constexpr TypedWhichId< SvxBoxItem > RES_BOX(112)
constexpr TypedWhichId< SvxFormatBreakItem > RES_BREAK(100)
constexpr TypedWhichId< SwCropGrf > RES_GRFATR_CROPGRF(142)
constexpr sal_uInt16 RES_TXTATR_END(RES_TXTATR_NOEND_END)
constexpr TypedWhichId< SvxLRSpaceItem > RES_LR_SPACE(97)
constexpr TypedWhichId< SvxULSpaceItem > RES_UL_SPACE(98)
std::unique_ptr< sal_Int32[]> pData
#define DFF_Prop_shadowOffsetY
#define DFF_Prop_fshadowObscured
#define DFF_Prop_pWrapPolygonVertices
#define DFF_Prop_shadowOffsetX
#define DFF_msofbtUDefProp
#define DFF_Prop_shadowColor
constexpr OUStringLiteral aObjectPool
std::shared_ptr< T > make_shared(Args &&... args)
constexpr Point convert(const Point &rPoint, o3tl::Length eFrom, o3tl::Length eTo)
sal_uInt16 TransformWhichBetweenPools(const SfxItemPool &rDestPool, const SfxItemPool &rSrcPool, sal_uInt16 nWhich)
Map an ID valid in one SfxItemPool to its equivalent in another.
sal_uInt16 GetSetWhichFromSwDocWhich(const SfxItemSet &rSet, const SwDoc &rDoc, sal_uInt16 nWhich)
Map a SwDoc WhichId to the equivalent Id for a given SfxItemSet.
css::uno::Reference< css::linguistic2::XProofreadingIterator > get(css::uno::Reference< css::uno::XComponentContext > const &context)
SwNoTextNode * GetNoTextNodeFromSwFrameFormat(const SwFrameFormat &rFormat)
Get the SwNoTextNode associated with a SwFrameFormat if here is one.
tools::Polygon CorrectWordWrapPolygonForExport(const tools::PolyPolygon &rPolyPoly, const SwNoTextNode *pNd, bool bCorrectCrop)
Undo all scaling / move tricks of the wrap polygon done during import.
bool IsFlyFrameFormatInHeader(const SwFrameFormat &rFormat)
sal_uInt32 RGBToBGR(::Color nColour)
std::vector< sal_uInt8 > bytes
SwNodeOffset min(const SwNodeOffset &a, const SwNodeOffset &b)
@ RES_POOLCOLL_STANDARD
Standard.
#define STREAM_SEEK_TO_BEGIN
const SfxPoolItem * pAttr
SVXCORE_DLLPUBLIC FrPair GetMapFactor(MapUnit eS, MapUnit eD)
SVXCORE_DLLPUBLIC Degree100 NormAngle36000(Degree100 a)
constexpr OUStringLiteral INET_FILE_SCHEME
bool RTLGraphicsHack(SwTwips &rLeft, SwTwips nWidth, sal_Int16 eHoriOri, sal_Int16 eHoriRel, SwTwips nPageLeft, SwTwips nPageRight, SwTwips nPageSize)
static sal_uInt16 FindPos(const SwFrameFormat &rFormat, unsigned int nHdFtIndex, DrawObjPointerVector &rPVec)
static ShapeFlag AddMirrorFlags(ShapeFlag nFlags, const SwMirrorGrf &rMirror)
static bool RTLDrawingsHack(SwTwips &rLeft, sal_Int16 eHoriOri, sal_Int16 eHoriRel, SwTwips nPageLeft, SwTwips nPageRight, SwTwips nPageSize)
std::vector< DrawObj * > DrawObjPointerVector
OUString FieldString(ww::eField eIndex)
void Set_UInt32(sal_uInt8 *&p, sal_uInt32 n)