xlnt/source/style_writer.cpp

34 lines
693 B
C++

#include "writer/style_writer.hpp"
#include "workbook/workbook.hpp"
#include "worksheet/worksheet.hpp"
#include "worksheet/range.hpp"
#include "cell/cell.hpp"
namespace xlnt {
style_writer::style_writer(xlnt::workbook &wb) : wb_(wb)
{
}
std::unordered_map<std::size_t, std::string> style_writer::get_style_by_hash() const
{
std::unordered_map<std::size_t, std::string> styles;
for(auto ws : wb_)
{
for(auto row : ws.rows())
{
for(auto cell : row)
{
if(cell.has_style())
{
styles[1] = "style";
}
}
}
}
return styles;
}
} // namespace xlnt