Fix RTL min/max line width calculation.
(cherry picked from commit 33b26e5cdc
)
This commit is contained in:
parent
97404dc612
commit
552feba40b
|
@ -271,8 +271,8 @@ int RichTextLabel::_process_line(ItemFrame *p_frame, const Vector2 &p_ofs, int &
|
||||||
|
|
||||||
#define ENSURE_WIDTH(m_width) \
|
#define ENSURE_WIDTH(m_width) \
|
||||||
if (p_mode == PROCESS_CACHE) { \
|
if (p_mode == PROCESS_CACHE) { \
|
||||||
l.maximum_width = MAX(l.maximum_width, MIN(p_width, wofs + m_width)); \
|
l.maximum_width = MAX(l.maximum_width, MIN(p_width, Math::ceil(wofs + m_width))); \
|
||||||
l.minimum_width = MAX(l.minimum_width, m_width); \
|
l.minimum_width = MAX(l.minimum_width, Math::ceil(m_width)); \
|
||||||
} \
|
} \
|
||||||
if (wofs - backtrack + m_width > p_width) { \
|
if (wofs - backtrack + m_width > p_width) { \
|
||||||
line_wrapped = true; \
|
line_wrapped = true; \
|
||||||
|
|
Loading…
Reference in New Issue