mirror of
https://github.com/RGBCube/serenity
synced 2025-05-19 00:55:08 +00:00
GTextEditor: Relayout when the line-wrapping setting is changed
This commit is contained in:
parent
453ca65a96
commit
5aac652b4b
2 changed files with 12 additions and 1 deletions
|
@ -1405,3 +1405,14 @@ void GTextEditor::Line::for_each_visual_line(Callback callback) const
|
|||
++line_index;
|
||||
}
|
||||
}
|
||||
|
||||
void GTextEditor::set_line_wrapping_enabled(bool enabled)
|
||||
{
|
||||
if (m_line_wrapping_enabled == enabled)
|
||||
return;
|
||||
|
||||
m_line_wrapping_enabled = enabled;
|
||||
update_content_size();
|
||||
recompute_all_visual_lines();
|
||||
update();
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue