[view] fixes
This commit is contained in:
@@ -26,7 +26,7 @@ class InputView extends TextView {
|
|||||||
|
|
||||||
hintTextField = buildHintTextField();
|
hintTextField = buildHintTextField();
|
||||||
content.addChild(hintTextField);
|
content.addChild(hintTextField);
|
||||||
textFormat.align = TextFormatAlign.LEFT;
|
font.align = TextFormatAlign.LEFT;
|
||||||
}
|
}
|
||||||
|
|
||||||
private function set_hint(value:String):String {
|
private function set_hint(value:String):String {
|
||||||
|
|||||||
@@ -16,6 +16,18 @@ class GeometryStyle implements IStyle<IView<Dynamic>> {
|
|||||||
view.geometry.padding = geometry.padding.clone();
|
view.geometry.padding = geometry.padding.clone();
|
||||||
update = true;
|
update = true;
|
||||||
}
|
}
|
||||||
|
if (!geometry.margin.empty) {
|
||||||
|
view.geometry.margin = geometry.margin.clone();
|
||||||
|
update = true;
|
||||||
|
}
|
||||||
|
if (geometry.width.value > 0) {
|
||||||
|
view.geometry.width = geometry.width;
|
||||||
|
update = true;
|
||||||
|
}
|
||||||
|
if (geometry.height.value > 0) {
|
||||||
|
view.geometry.height = geometry.height;
|
||||||
|
update = true;
|
||||||
|
}
|
||||||
if (update) {
|
if (update) {
|
||||||
view.toUpdateParent();
|
view.toUpdateParent();
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -125,12 +125,15 @@ class Theme implements ITheme {
|
|||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|
||||||
public function text(?color:Color):StyleSet {
|
public function text(?color:Color, ?size:Null<Int>):StyleSet {
|
||||||
if (color == null) {
|
if (color == null) {
|
||||||
color = colors.text;
|
color = colors.text;
|
||||||
}
|
}
|
||||||
|
if (size == null) {
|
||||||
|
size = baseFontSize;
|
||||||
|
}
|
||||||
return [
|
return [
|
||||||
new FontStyle(new FontPreset(font.name, font.embed, color, baseFontSize)),
|
new FontStyle(new FontPreset(font.name, font.embed, color, size)),
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user