use of io.anuke.ucore.scene.ui.Label.LabelStyle in project Mindustry by Anuken.
the class ChatFragment method setup.
private void setup() {
fieldlabel.setStyle(new LabelStyle(fieldlabel.getStyle()));
fieldlabel.getStyle().font = font;
fieldlabel.setStyle(fieldlabel.getStyle());
chatfield = new TextField("", new TextField.TextFieldStyle(skin.get(TextField.TextFieldStyle.class)));
chatfield.setTextFieldFilter((field, c) -> field.getText().length() < maxLength);
chatfield.getStyle().background = null;
chatfield.getStyle().fontColor = Color.WHITE;
chatfield.getStyle().font = skin.getFont("default-font-chat");
chatfield.setStyle(chatfield.getStyle());
Platform.instance.addDialog(chatfield, maxLength);
bottom().left().marginBottom(offsety).marginLeft(offsetx * 2).add(fieldlabel).padBottom(4f);
add(chatfield).padBottom(offsety).padLeft(offsetx).growX().padRight(offsetx).height(28);
if (Vars.android) {
marginBottom(105f);
marginRight(240f);
}
if (Vars.android) {
addImageButton("icon-arrow-right", 14 * 2, this::toggle).size(46f, 51f).visible(() -> chatOpen).pad(2f);
}
}
Aggregations