mirror of
https://github.com/tfussell/xlnt.git
synced 2024-03-22 13:11:17 +08:00
skip codeName attribute for #83
This commit is contained in:
parent
ec6a010f8a
commit
2bfd909684
|
@ -1032,7 +1032,7 @@ void cell::comment(const class comment &new_comment)
|
||||||
// todo: make this cell_position.first += get_width() instead
|
// todo: make this cell_position.first += get_width() instead
|
||||||
if (get_worksheet().has_column_properties(get_column()))
|
if (get_worksheet().has_column_properties(get_column()))
|
||||||
{
|
{
|
||||||
cell_position.first += get_worksheet().get_column_properties(get_column()).width;
|
cell_position.first += static_cast<int>(get_worksheet().get_column_properties(get_column()).width);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|
|
@ -792,26 +792,11 @@ void xlsx_consumer::read_workbook()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (parser().attribute_present("defaultThemeVersion"))
|
skip_attribute("codeName");
|
||||||
{
|
skip_attribute("defaultThemeVersion");
|
||||||
parser().attribute("defaultThemeVersion");
|
skip_attribute("backupFile");
|
||||||
}
|
skip_attribute("showObjects");
|
||||||
|
skip_attribute("filterPrivacy");
|
||||||
// todo: turn these structures into a method like skip_attribute(string name, bool optional)
|
|
||||||
if (parser().attribute_present("backupFile"))
|
|
||||||
{
|
|
||||||
parser().attribute("backupFile");
|
|
||||||
}
|
|
||||||
|
|
||||||
if (parser().attribute_present("showObjects"))
|
|
||||||
{
|
|
||||||
parser().attribute("showObjects");
|
|
||||||
}
|
|
||||||
|
|
||||||
if (parser().attribute_present("filterPrivacy"))
|
|
||||||
{
|
|
||||||
parser().attribute("filterPrivacy");
|
|
||||||
}
|
|
||||||
|
|
||||||
parser().next_expect(xml::parser::event_type::end_element, xmlns, "workbookPr");
|
parser().next_expect(xml::parser::event_type::end_element, xmlns, "workbookPr");
|
||||||
}
|
}
|
||||||
|
@ -2403,5 +2388,13 @@ void xlsx_consumer::read_block(const std::unordered_map<xml::qname, std::functio
|
||||||
parser().next_expect(xml::parser::event_type::end_element, parent_block);
|
parser().next_expect(xml::parser::event_type::end_element, parent_block);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void xlsx_consumer::skip_attribute(const std::string &name)
|
||||||
|
{
|
||||||
|
if (parser().attribute_present(name))
|
||||||
|
{
|
||||||
|
parser().attribute(name);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
} // namespace detail
|
} // namespace detail
|
||||||
} // namepsace xlnt
|
} // namepsace xlnt
|
||||||
|
|
|
@ -226,6 +226,8 @@ private:
|
||||||
|
|
||||||
void read_part(const std::vector<relationship> &rel_chain);
|
void read_part(const std::vector<relationship> &rel_chain);
|
||||||
|
|
||||||
|
void skip_attribute(const std::string &name);
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// The ZIP file containing the files that make up the OOXML package.
|
/// The ZIP file containing the files that make up the OOXML package.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
|
|
@ -28,7 +28,7 @@
|
||||||
#include <functional>
|
#include <functional>
|
||||||
#include <set>
|
#include <set>
|
||||||
|
|
||||||
#ifdef WIN32
|
#ifdef _MSC_VER
|
||||||
#include <codecvt> // utf-8 -> utf-16 conversion
|
#include <codecvt> // utf-8 -> utf-16 conversion
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
2
third-party/botan
vendored
2
third-party/botan
vendored
|
@ -1 +1 @@
|
||||||
Subproject commit 923a95d546df5b6d31f39b0af900d0361fb2e6a6
|
Subproject commit 523b2a4ca48fa5cf04ea371aabe7167ce2e5cd13
|
Loading…
Reference in New Issue
Block a user