This commit is contained in:
Kirill Polyakov
2025-11-07 13:22:07 +03:00
parent 61b55c9230
commit 76b5bd594d
4 changed files with 11 additions and 7 deletions

View File

@ -69,7 +69,8 @@ namespace NSCSS
R_Highlight, R_Highlight,
R_Shd, R_Shd,
R_SmallCaps, R_SmallCaps,
R_Kern R_Kern,
R_Vanish
} RunnerProperties; } RunnerProperties;
typedef enum typedef enum

View File

@ -509,6 +509,9 @@ namespace NSCSS
else if (L"serif" == wsFontFamily) else if (L"serif" == wsFontFamily)
wsFontFamily = L"Times New Roman"; wsFontFamily = L"Times New Roman";
if (oStyle.m_oDisplay.GetDisplay() == L"none")
oXmlElement.AddPropertiesInR(RProperties::R_Vanish, L"true");
oXmlElement.AddPropertiesInR(RProperties::R_RFonts, oStyle.m_oFont.GetFamily().ToWString()); oXmlElement.AddPropertiesInR(RProperties::R_RFonts, oStyle.m_oFont.GetFamily().ToWString());
oXmlElement.AddPropertiesInR(RProperties::R_I, oStyle.m_oFont.GetStyle().ToWString()); oXmlElement.AddPropertiesInR(RProperties::R_I, oStyle.m_oFont.GetStyle().ToWString());
oXmlElement.AddPropertiesInR(RProperties::R_B, oStyle.m_oFont.GetWeight().ToWString()); oXmlElement.AddPropertiesInR(RProperties::R_B, oStyle.m_oFont.GetWeight().ToWString());

View File

@ -473,6 +473,12 @@ std::wstring CXmlElement::ConvertRStyle(bool bIsLite) const
sRStyle += L"<w:kern w:val=\"" + oItem.second + L"\"/>"; sRStyle += L"<w:kern w:val=\"" + oItem.second + L"\"/>";
break; break;
} }
case CSSProperties::RunnerProperties::R_Vanish:
{
if (oItem.second == L"true")
sRStyle += L"<w:vanish/>";
break;
}
default: default:
break; break;
} }

View File

@ -3059,12 +3059,6 @@ private:
std::wstring sNote = GetSubClass(oXml, sSelectors); std::wstring sNote = GetSubClass(oXml, sSelectors);
if (NULL != sSelectors.back().m_pCompiledStyle && L"none" == sSelectors.back().m_pCompiledStyle->m_oDisplay.GetDisplay().ToWString())
{
sSelectors.pop_back();
return false;
}
bool bResult = true; bool bResult = true;
const HtmlTag eHtmlTag{GetHtmlTag(sName)}; const HtmlTag eHtmlTag{GetHtmlTag(sName)};