Font size in textfield libgdx

▼魔方 西西 提交于 2019-12-01 14:13:44
Aiman Batul

There are various builtin methods you can call to set size. If you just want to set the size of textfield you can call

UserNameTextField.setWidth(float width) Or UserNameTextField.setHeight(float width) or UserNameTextField.setMaxLength(maxLength)

And if you only want to set size of font then do it like `

TextField.TextFieldStyle textFieldStyle = skin.get(TextField.TextFieldStyle.class);
textFieldStyle.font.scale(1.6f);

`

You can check all methods , just need to take a look at API.

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!