This commit is contained in:
Elena Subbotina
2025-11-14 10:46:48 +03:00
parent e653442b8c
commit 12083905dc
3 changed files with 15 additions and 1 deletions

View File

@ -159,7 +159,17 @@ void serialize_wrap(std::wostream & strm, _docx_drawing const & val)
case odf_types::style_wrap::None:
serialize_wrap_top_bottom(strm, val);
break;
case odf_types::style_wrap::Dynamic: //Présentation_de_tib.odt
case odf_types::style_wrap::Dynamic:
{
//if (val.styleWrapContour && *val.styleWrapContour == false)
//{
// CP_XML_NODE(L"wp:wrapTopAndBottom");
//}
//else
{
serialize_wrap_square(strm, val);
}
}break;
default:
CP_XML_NODE(L"wp:wrapTopAndBottom");
break;

View File

@ -59,6 +59,7 @@ public:
_CP_OPT(odf_types::vertical_rel) styleVerticalRel;
_CP_OPT(odf_types::style_wrap) styleWrap;
_CP_OPT(bool) styleWrapContour;
int number_wrapped_paragraphs;

View File

@ -191,6 +191,7 @@ int ComputeMarginX(const style_page_layout_properties * pagePropertiesNode,
_CP_OPT(horizontal_rel) styleHorizontalRel;
_CP_OPT(horizontal_pos) styleHorizontalPos;
_CP_OPT(style_wrap) styleWrap;
_CP_OPT(bool) styleWrapContour;
_CP_OPT(length) frameMarginLeft;
_CP_OPT(length) frameMarginRight;
@ -199,6 +200,7 @@ int ComputeMarginX(const style_page_layout_properties * pagePropertiesNode,
styleHorizontalRel = graphicProperties->common_horizontal_rel_attlist_.style_horizontal_rel_;
styleHorizontalPos = graphicProperties->common_horizontal_pos_attlist_.style_horizontal_pos_;
styleWrap = graphicProperties->style_wrap_;
styleWrapContour = graphicProperties->style_wrap_contour_;
frameMarginLeft = GetOnlyLength(graphicProperties->common_horizontal_margin_attlist_.fo_margin_left_);
frameMarginRight = GetOnlyLength(graphicProperties->common_horizontal_margin_attlist_.fo_margin_right_);
}
@ -837,6 +839,7 @@ void common_draw_docx_convert(oox::docx_conversion_context & Context, union_comm
if (graphicProperties)
{
drawing->styleWrap = graphicProperties->style_wrap_;
drawing->styleWrapContour = graphicProperties->style_wrap_contour_;
if (drawing->styleWrap && drawing->styleWrap->get_type() == style_wrap::Parallel)
{