mirror of
https://github.com/tfussell/xlnt.git
synced 2024-03-22 13:11:17 +08:00
fix frozen first rows/columns for #369
This commit is contained in:
parent
be7a91f7be
commit
cc88c4829b
|
@ -552,7 +552,10 @@ std::string xlsx_consumer::read_worksheet_begin(const std::string &rel_id)
|
|||
current_selection.sqref(sqref);
|
||||
}
|
||||
|
||||
current_selection.pane(pane_corner::top_left);
|
||||
if (parser().attribute_present("pane"))
|
||||
{
|
||||
current_selection.pane(parser().attribute<pane_corner>("pane"));
|
||||
}
|
||||
|
||||
new_view.add_selection(current_selection);
|
||||
|
||||
|
|
|
@ -2326,8 +2326,15 @@ void xlsx_producer::write_worksheet(const relationship &rel)
|
|||
write_attribute("topLeftCell", current_pane.top_left_cell.get().to_string());
|
||||
}
|
||||
|
||||
write_attribute("xSplit", current_pane.x_split.index);
|
||||
write_attribute("ySplit", current_pane.y_split);
|
||||
if (current_pane.x_split + 1 == current_pane.top_left_cell.get().column())
|
||||
{
|
||||
write_attribute("xSplit", current_pane.x_split.index);
|
||||
}
|
||||
|
||||
if (current_pane.y_split + 1 == current_pane.top_left_cell.get().row())
|
||||
{
|
||||
write_attribute("ySplit", current_pane.y_split);
|
||||
}
|
||||
|
||||
if (current_pane.active_pane != pane_corner::top_left)
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue
Block a user