summaryrefslogtreecommitdiff
path: root/servers/text_server.h
diff options
context:
space:
mode:
authorRĂ©mi Verschelde <remi@verschelde.fr>2021-08-09 00:59:35 +0200
committerGitHub <noreply@github.com>2021-08-09 00:59:35 +0200
commit2df1765fc28052f25a6a12f3f5c5a974a88b9134 (patch)
tree8beebed7d2f3f26c40c5bd5d5905a80acd214dc9 /servers/text_server.h
parent7fc570b5ac4527e10a394da578f649b1f577b4dc (diff)
parent7c3c5603d0a3208d6bee186f50857b15a02419d6 (diff)
Merge pull request #49587 from bruvzg/text_server_inline_align
[Text Server] Improve object (image/table) inline alignment.
Diffstat (limited to 'servers/text_server.h')
-rw-r--r--servers/text_server.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/servers/text_server.h b/servers/text_server.h
index 4c2ada7fc9..d824504bf4 100644
--- a/servers/text_server.h
+++ b/servers/text_server.h
@@ -181,7 +181,7 @@ public:
struct EmbeddedObject {
int pos = 0;
- VAlign inline_align = VALIGN_TOP;
+ InlineAlign inline_align = INLINE_ALIGN_CENTER;
Rect2 rect;
};
Map<Variant, EmbeddedObject> objects;
@@ -332,8 +332,8 @@ public:
virtual bool shaped_text_get_preserve_control(RID p_shaped) const = 0;
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 = "") = 0;
- virtual bool shaped_text_add_object(RID p_shaped, Variant p_key, const Size2 &p_size, VAlign p_inline_align = VALIGN_CENTER, int p_length = 1) = 0;
- virtual bool shaped_text_resize_object(RID p_shaped, Variant p_key, const Size2 &p_size, VAlign p_inline_align = VALIGN_CENTER) = 0;
+ virtual bool shaped_text_add_object(RID p_shaped, Variant p_key, const Size2 &p_size, InlineAlign p_inline_align = INLINE_ALIGN_CENTER, int p_length = 1) = 0;
+ virtual bool shaped_text_resize_object(RID p_shaped, Variant p_key, const Size2 &p_size, InlineAlign p_inline_align = INLINE_ALIGN_CENTER) = 0;
virtual RID shaped_text_substr(RID p_shaped, int p_start, int p_length) const = 0; // Copy shaped substring (e.g. line break) without reshaping, but correctly reordered, preservers range.
virtual RID shaped_text_get_parent(RID p_shaped) const = 0;