我使用了粗体 ttf 字体,它可以工作,但只能看到一半的字母。
Code:
public void start() {
if (current != null) {
current.show();
return;
}
Label testLabel = new Label("Bold Font Not Working");
testLabel.setUIID("smallBold");
Form splashForm = new Form(new BorderLayout());
splashForm.add(BorderLayout.CENTER, BoxLayout.encloseY(testLabel));
splashForm.show();
splashForm.revalidate();
}
主题中的 UIID 用于未选择、选择和按下的样式
现在看起来怎么样
但是,如果不将其包装在 boxlayout 或 flowlayout 中,而是直接将其添加到具有 borderlayout 的表单中,则可以。 P.S 如果表单位于 boxlayout 中,则不起作用
Code:
public void start() {
if (current != null) {
current.show();
return;
}
Label testLabel = new Label("Bold Font Not Working");
testLabel.setUIID("smallBold");
Form splashForm = new Form(new BorderLayout());
splashForm.add(BorderLayout.CENTER, testLabel);// this works
splashForm.show();
splashForm.revalidate();
}
标签未包裹在其他容器中时的图像
None
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)