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

(1.2.0.82): ASCOfficeOdfFileW


git-svn-id: svn://fileserver/activex/AVS/Sources/TeamlabOffice/trunk/ServerComponents@56729 954022d7-b5bf-4e40-9824-e11837661b57
parent d07934df
......@@ -267,7 +267,13 @@ void ods_table_state::set_column_optimal_width(bool val)
column_properties->style_table_column_properties_attlist_.style_use_optimal_column_width_ = val;
}
void ods_table_state::set_column_hidden(bool val)
{
table_table_column* column = dynamic_cast<table_table_column*>(columns_.back().elm.get());
if (column == NULL)return;
column->table_table_column_attlist_.table_visibility_ = table_visibility(table_visibility::Collapse);
}
void ods_table_state::set_table_dimension(__int32 col, __int32 row)
{
if (col<1 || row <1 )return;
......@@ -594,8 +600,13 @@ void ods_table_state::set_cell_formula(std::wstring & formula)
if (formula.length() < 1)return;
//test external link
int res = formula.find(L"[");
if (res == 0)return; //todoooo
{
boost::wregex re(L"(\[\\d+\])");
boost::wsmatch result;
bool b = boost::regex_search(formula, result, re);
if (b) return; //todoooo
}
std::wstring odfFormula = formulas_converter.convert_formula(formula);
......
......@@ -184,7 +184,9 @@ public:
void add_column(office_element_ptr & elm, __int16 repeated ,office_element_ptr & style);
void set_column_width(double width);
void set_column_optimal_width(bool val);
void set_column_hidden(bool val);
void set_column_default_cell_style(std::wstring & style_name);
std::wstring get_column_default_cell_style(__int32 column);
void start_group(office_element_ptr & elm);
......
......@@ -659,8 +659,14 @@ void XlsxConverter::convert(OOX::Spreadsheet::CCol *oox_column)
if (oox_column->m_oHidden.IsInit() && oox_column->m_oHidden->ToBool()) width = 0;
if (width > 0 ) width = ods_context->convert_symbol_width(width);
if (width >= 0 ) ods_context->current_table().set_column_width(width);
if (width <0.01)
{
width = 0;
ods_context->current_table().set_column_hidden(true);
}
width = ods_context->convert_symbol_width(width);
ods_context->current_table().set_column_width(width);
std::wstring style_cell_name;
if (oox_column->m_oStyle.IsInit())
......
......@@ -2,6 +2,6 @@
//1
//2
//0
//80
#define INTVER 1,2,0,80
#define STRVER "1,2,0,80\0"
//82
#define INTVER 1,2,0,82
#define STRVER "1,2,0,82\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