The base Component class has a padding trait which is a Property that can take a number of different values, but TextBoxOverlay which is a subclass of Component, overrides this as an Int.
This is used as a margin around all sides of the text inside the component's rectangle, rather than the padding outside the rectangle.
A simple fix would be to re-name the trait on TextBoxOverlay to something else (eg. text_padding or margin).
Problem Description
The base
Component
class has apadding
trait which is aProperty
that can take a number of different values, butTextBoxOverlay
which is a subclass ofComponent
, overrides this as anInt
.This is used as a margin around all sides of the text inside the component's rectangle, rather than the padding outside the rectangle.
A simple fix would be to re-name the trait on
TextBoxOverlay
to something else (eg.text_padding
ormargin
).