mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 15:47:44 +00:00
LibWeb: Pass correct state to TextNode::compute_text_for_rendering()
This is poorly factored. TextNode needs to know whether the most recently inserted fragment on the current line was empty or ended in whitespace. This is used when deciding what to do with leading whitespace in text nodes. Let's keep this working for now, but we should eventually sort this out and make text chunk iteration not depend on this information.
This commit is contained in:
parent
36e2799131
commit
b1fd801436
2 changed files with 7 additions and 6 deletions
|
@ -47,7 +47,7 @@ public:
|
|||
private:
|
||||
void skip_to_next();
|
||||
|
||||
void enter_text_node(Layout::TextNode&);
|
||||
void enter_text_node(Layout::TextNode&, bool previous_is_empty_or_ends_in_whitespace);
|
||||
|
||||
Layout::BlockContainer& m_container;
|
||||
Layout::Node* m_current_node { nullptr };
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue