42#include <osl/diagnose.h>
98 OSL_ENSURE( rName[0] !=
'#',
"FindImageMap: name begins with '#'!" );
123 SwNode *pNd = rNds[nIdx + 1];
125 if(
nullptr != pGrfNd )
136 aURL.SetMap( pNewIMap );
147 nIdx = rNds[nIdx]->EndOfSectionIndex() + 1;
164 rFrameItemSet.
Put( *pCntnrItemSet );
183 bool bMoveBackward =
false;
185 sal_Int16 eVertRel = text::RelOrientation::FRAME;
190 sal_uInt16 nLeftSpace = 0, nRightSpace = 0;
196 css::text::WrapTextMode eSurround;
199 case text::HoriOrientation::LEFT:
200 eHoriRel = nLeftSpace ? text::RelOrientation::PRINT_AREA : text::RelOrientation::FRAME;
201 eSurround = css::text::WrapTextMode_RIGHT;
203 case text::HoriOrientation::RIGHT:
204 eHoriRel = nRightSpace ? text::RelOrientation::PRINT_AREA : text::RelOrientation::FRAME;
205 eSurround = css::text::WrapTextMode_LEFT;
207 case text::HoriOrientation::CENTER:
208 eHoriRel = text::RelOrientation::FRAME;
209 eSurround = css::text::WrapTextMode_NONE;
212 eHoriRel = text::RelOrientation::FRAME;
213 eSurround = css::text::WrapTextMode_PARALLEL;
225 sal_uInt16 nUpper=0, nLower=0;
243 aAnchor.
SetType( RndStdIds::FLY_AT_CHAR );
244 bMoveBackward =
true;
245 eVertOri = text::VertOrientation::CHAR_BOTTOM;
246 eVertRel = text::RelOrientation::CHAR;
250 aAnchor.
SetType( RndStdIds::FLY_AT_PARA );
251 eVertOri = text::VertOrientation::TOP;
252 eVertRel = text::RelOrientation::PRINT_AREA;
266 eState = SvParserState::Error;
275 rFrameSet.
Put( aAnchor );
285 m_aMoveFlyFrames.emplace_back(std::make_unique<SwHTMLFrameFormatListener>(pFlyFormat));
293 OUString& rTypeStr )
const
304 bool allowAccessLink(
const SwDoc& rDoc)
308 if (sh !=
nullptr && sh->
HasName())
321 OUString sAltNm, aId, aClass, aStyle,
aMap, sHTMLGrfName;
323 OUString aGraphicData;
324 sal_Int16 eVertOri = text::VertOrientation::TOP;
326 bool bWidthProvided=
false, bHeightProvided=
false;
332 bool bPercentWidth =
false;
333 bool bPercentHeight =
false;
334 OUString sWidthAsString, sHeightAsString;
338 OUString sDfltScriptType;
342 for (
size_t i = rHTMLOptions.size();
i; )
349 case HtmlOptionId::ID:
352 case HtmlOptionId::STYLE:
355 case HtmlOptionId::CLASS:
358 case HtmlOptionId::SRC:
360 if( !InternalImgToPrivateURL(sGrfNm) )
363 case HtmlOptionId::DATA:
365 if (!InternalImgToPrivateURL(aGraphicData))
369 case HtmlOptionId::ALIGN:
372 text::VertOrientation::TOP );
376 case HtmlOptionId::WIDTH:
380 bPercentWidth = (sWidthAsString.indexOf(
'%') != -1);
381 if( bPercentWidth && nWidth>100 )
385 bWidthProvided = (sWidthAsString !=
"auto");
387 case HtmlOptionId::HEIGHT:
391 bPercentHeight = (sHeightAsString.indexOf(
'%') != -1);
392 if( bPercentHeight && nHeight>100 )
395 bHeightProvided = (sHeightAsString !=
"auto");
397 case HtmlOptionId::VSPACE:
400 case HtmlOptionId::HSPACE:
403 case HtmlOptionId::ALT:
406 case HtmlOptionId::BORDER:
409 case HtmlOptionId::ISMAP:
412 case HtmlOptionId::USEMAP:
415 case HtmlOptionId::NAME:
419 case HtmlOptionId::SDONLOAD:
422 case HtmlOptionId::ONLOAD:
423 nEvent = SvMacroItemId::OnImageLoadDone;
426 case HtmlOptionId::SDONABORT:
429 case HtmlOptionId::ONABORT:
430 nEvent = SvMacroItemId::OnImageLoadCancel;
433 case HtmlOptionId::SDONERROR:
436 case HtmlOptionId::ONERROR:
437 nEvent = SvMacroItemId::OnImageLoadError;
442 if( !sTmp.isEmpty() )
445 OUString sScriptType;
447 sScriptType = sDfltScriptType;
449 SvxMacro( sTmp, sScriptType, eScriptType2 ));
457 if (sGrfNm.isEmpty() && !aGraphicData.isEmpty())
458 sGrfNm = aGraphicData;
460 if( sGrfNm.isEmpty() )
475 "Numbering level is wrong" );
493 if( aGraphicURL.
GetProtocol() == INetProtocol::Data )
495 std::unique_ptr<SvMemoryStream>
const pStream(aGraphicURL.
getData());
502 if (!sGrfNm.isEmpty())
509 else if (
m_sBaseURL.isEmpty() || !aGraphicData.isEmpty())
517 if (!sGrfNm.isEmpty())
522 if (!nHeight || !nWidth)
526 nWidth = aPixelSize.
Width();
527 if (!bHeightProvided)
528 nHeight = aPixelSize.
Height();
530 if (bWidthProvided && !bHeightProvided && aPixelSize.
Width())
535 bPercentHeight =
true;
539 nHeight = nWidth * aPixelSize.
Height() / aPixelSize.
Width();
542 else if (!bWidthProvided && bHeightProvided && aPixelSize.
Height())
547 bPercentWidth =
true;
551 nWidth = nHeight * aPixelSize.
Width() / aPixelSize.
Height();
578 const OUString& rURL =
582 sal_uInt16 nPoolId =
static_cast< sal_uInt16
>(
m_xDoc->IsVisitedURL( rURL )
599 aBoxItem.
SetLine( &aHBorderLine, SvxBoxItemLine::TOP );
600 aBoxItem.
SetLine( &aHBorderLine, SvxBoxItemLine::BOTTOM );
601 aBoxItem.
SetLine( &aVBorderLine, SvxBoxItemLine::LEFT );
602 aBoxItem.
SetLine( &aVBorderLine, SvxBoxItemLine::RIGHT );
603 aFrameSet.Put( aBoxItem );
608 SetSpace(
Size( nHSpace, nVSpace), aItemSet, aPropInfo, aFrameSet );
613 Size aTwipSz( bPercentWidth ? 0 : nWidth, bPercentHeight ? 0 : nHeight );
616 if (bWidthProvided || bHeightProvided ||
636 bPercentWidth =
false;
641 bPercentWidth =
true;
651 bPercentHeight =
false;
656 bPercentHeight =
true;
663 bool bSetTwipSize =
true;
664 bool bChangeFrameSize =
false;
665 bool bRequestGrfNow =
false;
666 bool bSetScaleImageMap =
false;
667 sal_uInt8 nPercentWidth = 0, nPercentHeight = 0;
672 bool bNeedWidth = (!bPercentWidth && !nWidth) || bRelWidthScale;
674 bool bNeedHeight = (!bPercentHeight && !nHeight) || bRelHeightScale;
675 if ((bNeedWidth || bNeedHeight) && !bFuzzing && allowAccessLink(*
m_xDoc))
678 if (aDescriptor.
Detect(
true))
684 if (!bPercentWidth && !nWidth)
688 if (!bPercentHeight && !nHeight)
695 if( !(nWidth && !bRelWidthScale) || !(nHeight && !bRelHeightScale) )
701 bRequestGrfNow =
true;
706 bChangeFrameSize =
true;
708 if( !nWidth && !nHeight )
718 nPercentWidth =
static_cast<sal_uInt8>(nWidth);
719 nPercentHeight = 255;
730 nPercentHeight =
static_cast<sal_uInt8>(nHeight);
742 bSetTwipSize =
false;
745 nPercentWidth =
static_cast<sal_uInt8>(nWidth);
748 nPercentHeight =
static_cast<sal_uInt8>(nHeight);
753 if( !
aMap.isEmpty() )
757 sal_Int32
nPos =
aMap.indexOf(
'#' );
769 bSetScaleImageMap = !nPercentWidth || !nPercentHeight;
770 aFrameSet.Put(
aURL );
776 aFrameSet.Put(
aURL );
781 bSetScaleImageMap =
true;
786 bool bRelSizeScale = bRelWidthScale || bRelHeightScale;
789 OSL_ENSURE( !aTwipSz.
Width() || bRelSizeScale,
790 "Why is a width set if we already have percentage value?" );
802 OSL_ENSURE( !aTwipSz.
Height() || bRelSizeScale,
803 "Why is a height set if we already have percentage value?" );
817 aFrameSet.Put( aFrameSize );
825 m_xDoc->getIDocumentContentOperations().InsertGraphic(
826 *
m_pPam, sGrfNm, OUString(), &aGraphic,
827 &aFrameSet,
nullptr,
nullptr);
831 if( !sHTMLGrfName.isEmpty() )
845 if( !sAltNm.isEmpty() )
853 if( bSetScaleImageMap )
871 SvMacroItemId::OnMouseOver,
872 SvMacroItemId::OnClick,
873 SvMacroItemId::OnMouseOut };
878 if(
nullptr != pMacro )
884 m_xAttrTab->pINetFormat->GetStartParagraph() ==
896 if( !rINetFormat.
GetName().isEmpty() )
924 if (bRequestGrfNow && pGrfNd)
927 SAL_WARN_IF(!aUpdatedSize.
Width() || !aUpdatedSize.
Height(),
"sw.html",
"html image with no width or height");
944 OUString aBackGround, aId, aStyle, aLang, aDir;
945 Color aBGColor, aTextColor, aLinkColor, aVLinkColor;
946 bool bBGColor=
false, bTextColor=
false;
947 bool bLinkColor=
false, bVLinkColor=
false;
950 OUString sDfltScriptType;
954 for (
size_t i = rHTMLOptions.size();
i; )
959 bool bSetEvent =
false;
963 case HtmlOptionId::ID:
966 case HtmlOptionId::BACKGROUND:
969 case HtmlOptionId::BGCOLOR:
973 case HtmlOptionId::TEXT:
977 case HtmlOptionId::LINK:
981 case HtmlOptionId::VLINK:
986 case HtmlOptionId::SDONLOAD:
989 case HtmlOptionId::ONLOAD:
994 case HtmlOptionId::SDONUNLOAD:
997 case HtmlOptionId::ONUNLOAD:
1002 case HtmlOptionId::SDONFOCUS:
1005 case HtmlOptionId::ONFOCUS:
1010 case HtmlOptionId::SDONBLUR:
1013 case HtmlOptionId::ONBLUR:
1018 case HtmlOptionId::ONERROR:
1021 case HtmlOptionId::STYLE:
1025 case HtmlOptionId::LANG:
1028 case HtmlOptionId::DIR:
1036 const OUString& rEvent = rOption.
GetString();
1037 if( !rEvent.isEmpty() )
1053 std::unique_ptr<SvxBrushItem> aBrushItem(
m_pCSS1Parser->makePageDescBackground() );
1054 bool bSetBrush =
false;
1060 if( !aBrushItem->GetGraphicLink().isEmpty() )
1061 aLink = aBrushItem->GetGraphicLink();
1064 aBrushItem->SetColor( aBGColor );
1066 if( !aLink.isEmpty() )
1068 aBrushItem->SetGraphicLink( aLink );
1069 aBrushItem->SetGraphicPos(
ePos );
1075 if( !aBackGround.isEmpty() && !
m_pCSS1Parser->IsBodyBackgroundSet() )
1084 if( !aStyle.isEmpty() || !aDir.isEmpty() )
1089 ParseStyleOptions( aStyle, aDummy, aDummy, aItemSet, aPropInfo,
nullptr, &aDir );
1093 m_pCSS1Parser->SetPageDescAttrs( bSetBrush ? aBrushItem.get() :
nullptr,
1099 for(
auto const &
i : aWhichIds)
1102 if( pItem && pItem->
GetProp() != 100)
1104 sal_uInt32 nHeight =
1107 aItemSet.
Put( aNewItem );
1113 ->SetFormatAttr( aItemSet );
1115 else if( bSetBrush )
1134 if( !aLang.isEmpty() )
1139 sal_uInt16 nWhich = 0;
1142 case SvtScriptType::LATIN:
1145 case SvtScriptType::ASIAN:
1148 case SvtScriptType::COMPLEX:
1156 aLanguage.SetWhich( nWhich );
1157 m_xDoc->SetDefault( aLanguage );
1162 if( !aId.isEmpty() )
1171 std::unique_ptr<HTMLAttrContext> xOldCntxt(
PopContext(HtmlTokenId::ANCHOR_ON));
1179 OUString sHRef,
aName, sTarget;
1180 OUString aId, aStyle, aClass, aLang, aDir;
1181 bool bHasHRef =
false, bFixed =
false;
1184 OUString sDfltScriptType;
1188 for (
size_t i = rHTMLOptions.size();
i; )
1195 case HtmlOptionId::NAME:
1199 case HtmlOptionId::HREF:
1203 case HtmlOptionId::TARGET:
1207 case HtmlOptionId::STYLE:
1210 case HtmlOptionId::ID:
1213 case HtmlOptionId::CLASS:
1216 case HtmlOptionId::SDFIXED:
1219 case HtmlOptionId::LANG:
1222 case HtmlOptionId::DIR:
1226 case HtmlOptionId::SDONCLICK:
1229 case HtmlOptionId::ONCLICK:
1230 nEvent = SvMacroItemId::OnClick;
1231 goto ANCHOR_SETEVENT;
1233 case HtmlOptionId::SDONMOUSEOVER:
1236 case HtmlOptionId::ONMOUSEOVER:
1237 nEvent = SvMacroItemId::OnMouseOver;
1238 goto ANCHOR_SETEVENT;
1240 case HtmlOptionId::SDONMOUSEOUT:
1243 case HtmlOptionId::ONMOUSEOUT:
1244 nEvent = SvMacroItemId::OnMouseOut;
1245 goto ANCHOR_SETEVENT;
1249 if( !sTmp.isEmpty() )
1252 OUString sScriptType;
1254 sScriptType = sDfltScriptType;
1255 aMacroTable.
Insert( nEvent,
SvxMacro( sTmp, sScriptType, eScriptType2 ));
1265 if( !
aName.isEmpty() )
1272 OUString sCmp= sDecoded.copy(
nPos+1).replaceAll(
" ",
"");
1273 if( !sCmp.isEmpty() )
1275 sCmp = sCmp.toAsciiLowerCase();
1276 if( sCmp ==
"region" ||
1278 sCmp ==
"graphic" ||
1281 sCmp ==
"outline" ||
1291 std::unique_ptr<HTMLAttrContext> xCntxt(
new HTMLAttrContext(HtmlTokenId::ANCHOR_ON));
1293 bool bEnAnchor =
false, bFootnoteAnchor =
false, bFootnoteEnSymbol =
false;
1294 OUString aFootnoteName;
1295 OUString aStrippedClass( aClass );
1297 if( aStrippedClass.getLength() >=9 && bHasHRef && sHRef.getLength() > 1 &&
1298 (
's' == aStrippedClass[0] ||
'S' == aStrippedClass[0]) &&
1299 (
'd' == aStrippedClass[1] ||
'D' == aStrippedClass[1]) )
1304 bFootnoteAnchor =
true;
1307 bFootnoteEnSymbol =
true;
1308 if( bEnAnchor || bFootnoteAnchor || bFootnoteEnSymbol )
1310 aFootnoteName = sHRef.copy( 1 );
1312 aStrippedClass.clear();
1324 if(
ParseStyleOptions( aStyle, aId, aClass, aItemSet, aPropInfo, &aLang, &aDir ) )
1327 InsertAttrs(aItemSet, aPropInfo, xCntxt.get(),
true);
1333 if( !sHRef.isEmpty() )
1348 if( !aMacroTable.
empty() )
1357 else if( !
aName.isEmpty() )
1362 if( bEnAnchor || bFootnoteAnchor )
1367 else if( bFootnoteEnSymbol )
1388 EndTag( HtmlTokenId::ANCHOR_OFF );
1402 bool bHasMarks =
false;
1430 const ::sw::mark::IMark* pBookmark = *ppMark;
1432 const SwNodeOffset nBookNdIdx = pBookmark->GetMarkPos().GetNodeIndex();
1433 if( nBookNdIdx==nNodeIdx )
1438 else if( nBookNdIdx > nNodeIdx )
1450 bool bSetSmallFont =
false;
1465 ((RndStdIds::FLY_AT_PARA == pAnchor->
GetAnchorId()) ||
1466 (RndStdIds::FLY_AT_CHAR == pAnchor->
GetAnchorId())) &&
1467 pAnchorNode->
GetIndex() == nNodeIdx )
1497 if(nBookNdIdx==nNodeIdx)
1503 OSL_ENSURE(
false,
"Oops, where is my predecessor node?");
1509 const SwPaM aPaM(*pNd, pNd->
Len());
1513 else if( nBookNdIdx > nNodeIdx )
1521 m_xDoc->GetNodes().Delete( rDelNode );
1527 bSetSmallFont =
true;
1536 bSetSmallFont =
true;
1540 while( bSetSmallFont &&
nPos>0 )
1555 pCNd->
SetAttr( aFontHeightCJK );
1557 pCNd->
SetAttr( aFontHeightCTL );
css::chart::ChartAxisLabelPosition ePos
static OutputDevice * GetDefaultDevice()
static OUString GetEventName(GlobalEventId nID)
bool Detect(bool bExtendedInfo=false)
const Size & GetSizePixel() const
Graphic ImportUnloadedGraphic(SvStream &rIStream, sal_uInt64 sizeLimit=0, const Size *pSizeHint=nullptr)
static GraphicFilter & GetGraphicFilter()
ErrCode ImportGraphic(Graphic &rGraphic, const INetURLObject &rPath, sal_uInt16 nFormat=GRFILTER_FORMAT_DONTKNOW, sal_uInt16 *pDeterminedFormat=nullptr, GraphicFilterImportFlags nImportFlags=GraphicFilterImportFlags::NONE)
MapMode GetPrefMapMode() const
Size GetSizePixel(const OutputDevice *pRefDevice=nullptr) const
SwNodeOffset GetStartParagraphIdx() const
std::unique_ptr< SfxPoolItem > m_pItem
HtmlOptionId GetToken() const
const OUString & GetString() const
EnumT GetEnum(const HTMLOptionEnum< EnumT > *pOptEnums, EnumT nDflt=static_cast< EnumT >(0)) const
void GetColor(Color &) const
sal_uInt32 GetNumber() const
wrapper iterator: wraps iterator of implementation while hiding MarkBase class; only IMark instances ...
Provides access to the marks of a document.
virtual const_iterator_t getAllMarksEnd() const =0
returns a STL-like random access iterator to the end of the sequence of marks.
virtual void repositionMark(::sw::mark::IMark *io_pMark, const SwPaM &rPaM)=0
Moves an existing mark to a new selection and performs needed updates.
virtual const_iterator_t getAllMarksBegin() const =0
returns a STL-like random access iterator to the begin of the sequence of marks.
static OUString decode(std::u16string_view rText, DecodeMechanism eMechanism, rtl_TextEncoding eCharset=RTL_TEXTENCODING_UTF8)
std::unique_ptr< SvMemoryStream > getData() const
OUString GetPartBeforeLastName() const
static OUString GetAbsURL(std::u16string_view rTheBaseURIRef, OUString const &rTheRelURIRef, EncodeMechanism eEncodeMechanism=EncodeMechanism::WasEncoded, DecodeMechanism eDecodeMechanism=DecodeMechanism::ToIUri, rtl_TextEncoding eCharset=RTL_TEXTENCODING_UTF8)
INetProtocol GetProtocol() const
const OUString & GetName() const
size_t GetIMapObjectCount() const
static LanguageType convertToLanguageTypeWithFallback(const OUString &rBcp47)
MapUnit GetMapUnit() const
SAL_WARN_UNUSED_RESULT Point PixelToLogic(const Point &rDevicePt) const
SAL_WARN_UNUSED_RESULT Point LogicToLogic(const Point &rPtSource, const MapMode *pMapModeSource, const MapMode *pMapModeDest) const
static void ResetFrameFormatAttrs(SfxItemSet &rFrameSet)
ScriptType GetScriptType(SvKeyValueIterator *) const
const OUString & GetScriptTypeString(SvKeyValueIterator *) const
const T * GetItemIfSet(TypedWhichId< T > nWhich, bool bSrchInParent=true) const
const SfxPoolItem * Put(const SfxPoolItem &rItem, sal_uInt16 nWhich)
const OUString & GetName() const
SvKeyValueIterator * GetHeaderAttributes()
SfxMedium * GetMedium() const
css::uno::Reference< css::frame::XModel3 > GetBaseModel() const
constexpr tools::Long getHeight() const
constexpr tools::Long Height() const
tools::Long AdjustHeight(tools::Long n)
constexpr tools::Long getWidth() const
void setWidth(tools::Long nWidth)
tools::Long AdjustWidth(tools::Long n)
void setHeight(tools::Long nHeight)
constexpr tools::Long Width() const
void SetLine(const editeng::SvxBorderLine *pNew, SvxBoxItemLine nLine)
static void PixelToTwip(tools::Long &nWidth, tools::Long &nHeight)
SvxCSS1LengthType m_eHeightType
SvxCSS1LengthType m_eWidthType
const Color & GetValue() const
sal_uInt16 GetProp() const
const SvxMacroTableDtor & GetMacroTable() const
void SetMacro(SvMacroItemId nEvent, const SvxMacro &)
SvxMacro & Insert(SvMacroItemId nEvent, const SvxMacro &rMacro)
static Css1ScriptFlags GetScriptFromClass(OUString &rClass, bool bSubClassOnly=true)
static bool MayBePositioned(const SvxCSS1PropertyInfo &rPropInfo, bool bAutoWidth=false)
Marks a character position inside a document model content node (SwContentNode)
virtual bool SetAttr(const SfxPoolItem &)
made virtual
virtual sal_Int32 Len() const
SfxObjectShell * GetPersist() const
const SwNodeIndex * GetContentIdx() const
void SetChgTwipSize(bool b)
void ScaleImageMap()
Scale an image-map: the image-map becomes zoomed in / out by factor between graphic-size and border-s...
virtual Size GetTwipSize() const override
void SetTwipSize(const Size &rSz)
void SetScaleImageMap(bool b)
bool IsScaleImageMap() const
std::shared_ptr< HTMLTable > m_xTable
void InsertFootEndNote(const OUString &rName, bool bEndNote, bool bFixed)
void PushContext(std::unique_ptr< HTMLAttrContext > &rCntxt)
bool CanRemoveNode(SwNodeOffset nNodeIdx) const
std::unique_ptr< HTMLAttrContext > PopContext(HtmlTokenId nToken=HtmlTokenId::NONE)
static OUString StripQueryFromPath(std::u16string_view rBase, const OUString &rPath)
Strips query and fragment from a URL path if base URL is a file:// one.
void SetAnchorAndAdjustment(sal_Int16 eVertOri, sal_Int16 eHoriOri, const SvxCSS1PropertyInfo &rPropInfo, SfxItemSet &rFrameSet)
void InsertAttrs(std::deque< std::unique_ptr< HTMLAttr > > rAttrs)
void InsertBookmark(const OUString &rName)
bool m_bNotifyMacroEventRead
HTMLAttrContexts m_aContexts
void InsertAttr(const SfxPoolItem &rItem, bool bInsAtStart)
static void SetSpace(const Size &rPixSpace, SfxItemSet &rItemSet, SvxCSS1PropertyInfo &rPropInfo, SfxItemSet &rFlyItemSet)
sal_uInt16 m_nMissingImgMaps
std::shared_ptr< HTMLAttrTable > m_xAttrTab
void SetAttr(bool bChkEnd=true, bool bBeforeTable=false, std::deque< std::unique_ptr< HTMLAttr > > *pPostIts=nullptr)
sal_uInt32 m_aFontHeights[7]
void EndTag(HtmlTokenId nToken)
OUString m_aBulletGrfs[MAXLEVEL]
bool DoPositioning(SfxItemSet &rItemSet, SvxCSS1PropertyInfo &rPropInfo, HTMLAttrContext *pContext)
static bool HasStyleOptions(std::u16string_view rStyle, std::u16string_view rId, std::u16string_view rClass, const OUString *pLang=nullptr, const OUString *pDir=nullptr)
void GetDefaultScriptType(ScriptType &rType, OUString &rTypeStr) const
SwHTMLNumRuleInfo & GetNumInfo()
void SetTextCollAttrs(HTMLAttrContext *pContext=nullptr)
void NewAttr(const std::shared_ptr< HTMLAttrTable > &rAttrTab, HTMLAttr **ppAttr, const SfxPoolItem &rItem)
rtl::Reference< SwDoc > m_xDoc
bool ParseStyleOptions(const OUString &rStyle, const OUString &rId, const OUString &rClass, SfxItemSet &rItemSet, SvxCSS1PropertyInfo &rPropInfo, const OUString *pLang=nullptr, const OUString *pDir=nullptr)
std::unique_ptr< SwCSS1Parser > m_pCSS1Parser
void NotifyMacroEventRead()
std::unique_ptr< ImageMaps > m_pImageMaps
all Image-Maps that have been read
bool AppendTextNode(SwHTMLAppendMode eMode=AM_NORMAL, bool bUpdateNum=true)
ImageMap * FindImageMap(std::u16string_view rURL) const
void RegisterFlyFrame(SwFrameFormat *pFlyFrame)
void EndContext(HTMLAttrContext *pContext)
void GetMarginsFromContextWithNumberBullet(sal_uInt16 &nLeft, sal_uInt16 &nRight, short &nIndent) const
bool m_bInFootEndNoteAnchor
sal_uInt16 IncGrfsThatResizeTable()
bool HasCurrentParaBookmarks(bool bIgnoreStack=false) const
bool m_bInFootEndNoteSymbol
static void SetFrameFormatAttrs(SfxItemSet &rItemSet, HtmlFrameFormatFlags nFlags, SfxItemSet &rFrameItemSet)
std::vector< std::unique_ptr< SwHTMLFrameFormatListener > > m_aMoveFlyFrames
bool EndAttr(HTMLAttr *pAttr, bool bChkEmpty=true)
void GetULSpaceFromContext(sal_uInt16 &rUpper, sal_uInt16 &rLower) const
void InsertBasicDocEvent(const OUString &aEventName, const OUString &rName, ScriptType eScrType, const OUString &rScrType)
std::deque< sal_Int32 > m_aMoveFlyCnts
bool HasCurrentParaFlys(bool bNoSurroundOnly=false, bool bSurroundOnly=false) const
OUString m_aEmbedURL
This is the URL of the outer <object> data if it's not OLE2 or an image.
void SetTitle(const OUString &rTitle)
Marks a node in the document model.
SwNodeOffset GetIndex() const
Base class of the Writer document model elements.
SwFrameFormat * GetFlyFormat() const
If node is in a fly return the respective format.
SwTextNode * GetTextNode()
Inline methods from Node.hxx.
SwNodeOffset GetIndex() const
SwNodeOffset StartOfSectionIndex() const
SwNodeOffset EndOfSectionIndex() const
SwNodeType GetNodeType() const
SwNode & GetEndOfAutotext() const
Section for all Flys/Header/Footers.
static SwContentNode * GoPrevious(SwNodeIndex *)
void SetInvalidRule(bool bFlag)
PaM is Point and Mark: a selection of the document model.
SwNode & GetPointNode() const
virtual void SetMark()
Unless this is called, the getter method of Mark will return Point.
SwContentNode * GetPointContentNode() const
bool Move(SwMoveFnCollection const &fnMove=fnMoveForward, SwGoInDoc fnGo=GoInContent)
Movement of cursor.
const SwPosition * GetPoint() const
SwTextNode is a paragraph in the document model.
void CutText(SwTextNode *const pDest, const SwContentIndex &rStart, const sal_Int32 nLen)
bool IsCountedInList() const
void SetCountedInList(bool bCounted)
int GetActualListLevel(SwListRedlineType eRedline=SwListRedlineType::SHOW) const
Returns the actual list level of this text node, when it is a list item.
const OUString & GetText() const
SwTextAttr * GetTextAttrForCharAt(const sal_Int32 nIndex, const sal_uInt16 nWhich=RES_TXTATR_END) const
get the text attribute at position nIndex which owns the dummy character CH_TXTATR_* at that position...
void SetColor(const Color &rColor)
const Color & GetColor() const
virtual const SwPosition & GetMarkPos() const =0
@ Fixed
Frame cannot be moved in Var-direction.
constexpr sal_uInt16 RES_FRMATR_BEGIN(RES_PARATR_LIST_END)
constexpr TypedWhichId< SvxFontHeightItem > RES_CHRATR_CTL_FONTSIZE(28)
constexpr TypedWhichId< SvxFontHeightItem > RES_CHRATR_FONTSIZE(8)
constexpr TypedWhichId< SvxLanguageItem > RES_CHRATR_LANGUAGE(10)
constexpr TypedWhichId< SvxLanguageItem > RES_CHRATR_CTL_LANGUAGE(29)
constexpr TypedWhichId< SvxFontHeightItem > RES_CHRATR_CJK_FONTSIZE(23)
constexpr sal_uInt16 RES_FRMATR_END(141)
constexpr TypedWhichId< SvxLanguageItem > RES_CHRATR_CJK_LANGUAGE(24)
constexpr TypedWhichId< SfxStringItem > RES_FLTR_BOOKMARK(RES_FLTRATTR_BEGIN)
constexpr TypedWhichId< SvxMacroItem > RES_FRMMACRO(114)
constexpr TypedWhichId< SwDrawFrameFormat > RES_DRAWFRMFMT(165)
constexpr TypedWhichId< SwFormatFlyCnt > RES_TXTATR_FLYCNT(58)
constexpr TypedWhichId< SvxBoxItem > RES_BOX(112)
constexpr TypedWhichId< SvxColorItem > RES_CHRATR_COLOR(3)
constexpr TypedWhichId< SvxULSpaceItem > RES_UL_SPACE(98)
#define CH_TXTATR_BREAKWORD
HTMLOptionEnum< sal_Int16 > const aHTMLImgVAlignTable[]
HTMLOptionEnum< sal_Int16 > const aHTMLImgHAlignTable[]
#define OOO_STRING_SVTOOLS_HTML_AL_left
#define OOO_STRING_SVTOOLS_HTML_VA_baseline
#define OOO_STRING_SVTOOLS_HTML_VA_middle
#define OOO_STRING_SVTOOLS_HTML_VA_absmiddle
#define OOO_STRING_SVTOOLS_HTML_sdendnote_sym
#define OOO_STRING_SVTOOLS_HTML_VA_bottom
#define OOO_STRING_SVTOOLS_HTML_sdendnote_anc
#define OOO_STRING_SVTOOLS_HTML_VA_absbottom
#define OOO_STRING_SVTOOLS_HTML_AL_center
#define OOO_STRING_SVTOOLS_HTML_VA_top
#define OOO_STRING_SVTOOLS_HTML_sdfootnote_anc
#define OOO_STRING_SVTOOLS_HTML_VA_texttop
#define OOO_STRING_SVTOOLS_HTML_AL_right
#define OOO_STRING_SVTOOLS_HTML_sdfootnote_sym
#define LANGUAGE_DONTKNOW
LineEnd GetSystemLineEnd()
TOOLS_DLLPUBLIC OString convertLineEnd(const OString &rIn, LineEnd eLineEnd)
#define SAL_WARN_IF(condition, area, stream)
SvtScriptType GetScriptTypeOfLanguage(LanguageType nLang)
bool isUntrustedReferer(OUString const &referer)
SwNumRule * GetNumRule(SwTextFormatColl &rTextFormatColl)
determines the list style, which directly set at the given paragraph style
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)
tools::Long const nBorder
COMPHELPER_DLLPUBLIC void notifyMacroEventRead(const css::uno::Reference< css::frame::XModel > &_rxDocument)
OString stripEnd(const OString &rIn, char c)
bool equalsIgnoreAsciiCase(std::u16string_view s1, std::u16string_view s2)
HashMap_OWString_Interface aMap
@ Table
SwTableNode is derived from SwStartNode.
bool GoInNode(SwPaM &rPam, SwMoveFnCollection const &fnMove)
SwMoveFnCollection const & fnMoveBackward
SwMoveFnCollection const & fnMoveForward
SwPam::Move()/Find() default argument.
::std::vector< HTMLOption > HTMLOptions
@ RES_POOLCOLL_TEXT
Text body.
@ RES_POOLCOLL_STANDARD
Standard.
@ RES_POOLCHR_INET_VISIT
Internet visited.
@ RES_POOLCHR_INET_NORMAL
Internet normal.
SwNodeOffset GetNodeIndex() const
sal_Int32 GetContentIndex() const
Reference< XModel > xModel
@ SVX_CSS1_LTYPE_PERCENTAGE
constexpr tools::Long HTML_DFLT_IMG_HEIGHT
constexpr tools::Long HTML_DFLT_IMG_WIDTH
const sal_Unicode cMarkSeparator
constexpr sal_uInt8 MAXLEVEL