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

поправлены стили

git-svn-id: svn://fileserver/activex/AVS/Sources/TeamlabOffice/trunk/ServerComponents@55537 954022d7-b5bf-4e40-9824-e11837661b57
parent 4ccd3d22
......@@ -107,13 +107,14 @@ void odf_style_context::process_office(office_element_ptr root )
root->add_child_element(style_state_list_[i].odf_style_);
}
}
std::wstring odf_style_context::find_odf_style_name(int oox_id_style, const style_family family)
std::wstring odf_style_context::find_odf_style_name(int oox_id_style, const style_family family, bool root)
{
for (long i =0; i < style_state_list_.size(); i++)
{
if (style_state_list_[i].odf_style_)
{
if (style_state_list_[i].style_family_ == family)
if (style_state_list_[i].style_family_ == family &&
style_state_list_[i].root_ == root)
{
if (oox_id_style >=0 && style_state_list_[i].style_oox_id_ == oox_id_style) return style_state_list_[i].get_name();
}
......
......@@ -37,7 +37,7 @@ public:
void reset_defaults();
void add_default(odf_style_state & state) {default_styles_.push_back(state);}
std::wstring find_odf_style_name (int oox_id_style, const style_family family);
std::wstring find_odf_style_name (int oox_id_style, const style_family family, bool root = false);
office_element_ptr find_odf_style (int oox_id_style, const style_family family, bool root = false);
std::wstring find_odf_style_name_default(const style_family family);
......
......@@ -893,7 +893,7 @@ void XlsxConverter::convert(OOX::Spreadsheet::CCellStyle * cell_style, int oox_i
int parent_id = cell_style->m_oXfId.IsInit() ? cell_style->m_oXfId->GetValue() : -1;
if (parent_id >=0)
style->style_parent_style_name_ = ods_context->styles_context().find_odf_style_name(parent_id, odf::style_family::TableCell);
style->style_parent_style_name_ = ods_context->styles_context().find_odf_style_name(parent_id, odf::style_family::TableCell,true);
//m_oBuiltinId, m_oCustomBuiltin, m_oHidden, m_oILevel; ???????
}
......
......@@ -2,6 +2,6 @@
//1
//2
//0
//11
#define INTVER 1,2,0,11
#define STRVER "1,2,0,11\0"
//13
#define INTVER 1,2,0,13
#define STRVER "1,2,0,13\0"
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