mirror of
https://github.com/cyberarm/cyberarm_engine.git
synced 2025-12-16 13:12:34 +00:00
Fix Text height returning 0 if @text is blank
This commit is contained in:
@@ -72,7 +72,7 @@ module CyberarmEngine
|
|||||||
end
|
end
|
||||||
|
|
||||||
def height
|
def height
|
||||||
(@text.lines.count) * textobject.height
|
@text.lines.count > 0 ? (@text.lines.count) * textobject.height : @textobject.height
|
||||||
end
|
end
|
||||||
|
|
||||||
def draw
|
def draw
|
||||||
|
|||||||
Reference in New Issue
Block a user