[TextServer] Add function to change font, font size, and OpenType features without invalidating line break points, justification points, or recreating shaped text buffer.
This commit is contained in:
parent
050908626f
commit
215bede6ff
22 changed files with 705 additions and 491 deletions
|
|
@ -343,13 +343,20 @@ public:
|
|||
GDVIRTUAL2(_shaped_text_set_preserve_control, RID, bool);
|
||||
GDVIRTUAL1RC(bool, _shaped_text_get_preserve_control, RID);
|
||||
|
||||
virtual bool shaped_text_add_string(RID p_shaped, const String &p_text, const Vector<RID> &p_fonts, int p_size, const Dictionary &p_opentype_features = Dictionary(), const String &p_language = "") override;
|
||||
virtual bool shaped_text_add_string(RID p_shaped, const String &p_text, const Vector<RID> &p_fonts, int p_size, const Dictionary &p_opentype_features = Dictionary(), const String &p_language = "", const Variant &p_meta = Variant()) override;
|
||||
virtual bool shaped_text_add_object(RID p_shaped, Variant p_key, const Size2 &p_size, InlineAlignment p_inline_align = INLINE_ALIGNMENT_CENTER, int p_length = 1) override;
|
||||
virtual bool shaped_text_resize_object(RID p_shaped, Variant p_key, const Size2 &p_size, InlineAlignment p_inline_align = INLINE_ALIGNMENT_CENTER) override;
|
||||
GDVIRTUAL6R(bool, _shaped_text_add_string, RID, const String &, const Array &, int, const Dictionary &, const String &);
|
||||
GDVIRTUAL7R(bool, _shaped_text_add_string, RID, const String &, const Array &, int, const Dictionary &, const String &, const Variant &);
|
||||
GDVIRTUAL5R(bool, _shaped_text_add_object, RID, Variant, const Size2 &, InlineAlignment, int);
|
||||
GDVIRTUAL4R(bool, _shaped_text_resize_object, RID, Variant, const Size2 &, InlineAlignment);
|
||||
|
||||
virtual int shaped_get_span_count(RID p_shaped) const override;
|
||||
virtual Variant shaped_get_span_meta(RID p_shaped, int p_index) const override;
|
||||
virtual void shaped_set_span_update_font(RID p_shaped, int p_index, const Vector<RID> &p_fonts, int p_size, const Dictionary &p_opentype_features = Dictionary()) override;
|
||||
GDVIRTUAL1RC(int, _shaped_get_span_count, RID);
|
||||
GDVIRTUAL2RC(Variant, _shaped_get_span_meta, RID, int);
|
||||
GDVIRTUAL5(_shaped_set_span_update_font, RID, int, const Array &, int, const Dictionary &);
|
||||
|
||||
virtual RID shaped_text_substr(RID p_shaped, int p_start, int p_length) const override;
|
||||
virtual RID shaped_text_get_parent(RID p_shaped) const override;
|
||||
GDVIRTUAL3RC(RID, _shaped_text_substr, RID, int, int);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue