Commit 1a082e2b authored by Elen.Subbotina's avatar Elen.Subbotina Committed by Alexander Trofimov

git-svn-id:...

git-svn-id: svn://fileserver/activex/AVS/Sources/TeamlabOffice/trunk/ServerComponents@54944 954022d7-b5bf-4e40-9824-e11837661b57
parent eca905ac
......@@ -42,7 +42,7 @@ namespace odf {
class text_format_properties_content
{
public:
void serialize(std::wostream & strm);
void serialize(std::wostream & strm){}
void apply_from(const text_format_properties_content & Other);
......@@ -280,7 +280,7 @@ public:
virtual void create_child_element(const ::std::wstring & Ns, const ::std::wstring & Name);
virtual void add_child_element(office_element_ptr & child){}
virtual void serialize(std::wostream & strm);
virtual void serialize(std::wostream & strm){}
const text_format_properties_content & content() const { return text_format_properties_content_; } ;
text_format_properties_content & content() { return text_format_properties_content_; } ;
......
......@@ -130,21 +130,20 @@ void XlsxConverter::convert_styles()
//ods_context->styles_context().current_style().set_hidden(xlsx_styles->m_oCellStyles->m_arrItems[i]->m_oHidden->ToBool())
//ods_context->styles_context().current_style().set_level(xlsx_styles->m_oCellStyles->m_arrItems[i]->m_oILevel->GetValue())
//
ods_context->styles_context().end_style();
}
}
void XlsxConverter::convert(OOX::Spreadsheet::CFont * font, odf::office_element_ptr & odf_style_)
{
odf::style* style_ = dynamic_cast<style*>(odf_style_.get());
if (!style_)return;
odf::style* style = dynamic_cast<odf::style*>(odf_style_.get());
if (!style)return;
odf::style_text_properties * text_properties = style->style_content_.get_style_text_properties();// -
if (text_properties == NULL)
{
style->style_content_.add_child(L"style", L"text-properties", ods_context);
style->create_child_element(L"style", L"text-properties");
text_properties = style->style_content_.get_style_text_properties();
if (text_properties == NULL) return;
}
......@@ -153,15 +152,15 @@ void XlsxConverter::convert(OOX::Spreadsheet::CFont * font, odf::office_element_
}
void XlsxConverter::convert(OOX::Spreadsheet::CFill * fill, odf::office_element_ptr & odf_style_)
{
odf::style* style_ = dynamic_cast<odf::style*>(odf_style_.get());
if (!style_)return;
odf::style* style = dynamic_cast<odf::style*>(odf_style_.get());
if (!style)return;
odf::style_table_cell_properties * cell_properties = style->style_content_.get_style_table_cell_properties();// -
if (cell_properties == NULL)
{
style->style_content_.add_child(L"style", L"table-cell-properties", ods_context);
style->style_content_.get_style_table_cell_properties();
style->create_child_element(L"style", L"table-cell-properties");
cell_properties = style->style_content_.get_style_table_cell_properties();
if (cell_properties == NULL) return;
}
......@@ -170,6 +169,8 @@ void XlsxConverter::convert(OOX::Spreadsheet::CFill * fill, odf::office_element_
odf::office_element_ptr XlsxConverter::convert(OOX::Spreadsheet::CXfs * cell_style, int oox_id)
{
OOX::Spreadsheet::CStyles * xlsx_styles = xlsx_document->GetStyles();
int id_parent = cell_style->m_oXfId->GetValue(); //parent
int fill_id = cell_style->m_oFillId->GetValue();
int numFmt_id = cell_style->m_oNumFmtId->GetValue();
......@@ -185,12 +186,12 @@ odf::office_element_ptr XlsxConverter::convert(OOX::Spreadsheet::CXfs * cell_sty
odf::style* style = dynamic_cast<odf::style*>(elm_style.get());
if (!style_)return;
if (!style)return elm_style;
odf::style_table_cell_properties * cell_properties = get_style_table_cell_properties();
odf::style_table_cell_properties * cell_properties = style->style_content_.get_style_table_cell_properties();
return style;
return elm_style;
}
} // namespace Docx2Odt
\ No newline at end of file
......@@ -48,5 +48,7 @@ namespace Oox2Odf
void convert(OOX::Spreadsheet::CFill * fill, cpdoccore::odf::office_element_ptr & odf_style_);
void convert(OOX::Spreadsheet::CFont * font, cpdoccore::odf::office_element_ptr & odf_style_);
cpdoccore::odf::office_element_ptr convert(OOX::Spreadsheet::CXfs * cell_style, int oox_id);
};
}
\ No newline at end of file
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment