ability to specify index in form fields

This commit is contained in:
kepler155c@gmail.com 2019-07-22 22:21:41 -06:00
parent ae98aaf9d5
commit c18945467f
1 changed files with 2 additions and 2 deletions

View File

@ -60,14 +60,14 @@ function UI.Form:createForm()
end
if child.formLabel then
child.x = self.labelWidth + self.margin - 1
child.y = y
child.y = child.formIndex and (child.formIndex + self.margin - 1) or y
if not child.width and not child.ex then
child.ex = -self.margin
end
table.insert(self.children, UI.Text {
x = self.margin,
y = y,
y = child.y,
textColor = colors.black,
width = #child.formLabel,
value = child.formLabel,