Add properties to configure space trimming on line break.

This commit is contained in:
Pāvels Nadtočajevs 2025-03-16 13:57:01 +02:00
parent fde0616a0e
commit 2bbf0f2317
No known key found for this signature in database
GPG key ID: 8413210218EF35D2
18 changed files with 171 additions and 30 deletions

View file

@ -472,6 +472,7 @@ private:
VScrollBar *vscroll = nullptr;
TextServer::AutowrapMode autowrap_mode = TextServer::AUTOWRAP_WORD_SMART;
BitField<TextServer::LineBreakFlag> autowrap_flags_trim = TextServer::BREAK_TRIM_START_EDGE_SPACES | TextServer::BREAK_TRIM_END_EDGE_SPACES;
bool scroll_visible = false;
bool scroll_follow = false;
@ -858,6 +859,9 @@ public:
void set_autowrap_mode(TextServer::AutowrapMode p_mode);
TextServer::AutowrapMode get_autowrap_mode() const;
void set_autowrap_trim_flags(BitField<TextServer::LineBreakFlag> p_flags);
BitField<TextServer::LineBreakFlag> get_autowrap_trim_flags() const;
void set_structured_text_bidi_override(TextServer::StructuredTextParser p_parser);
TextServer::StructuredTextParser get_structured_text_bidi_override() const;