本文整理汇总了Java中com.badlogic.gdx.scenes.scene2d.ui.ProgressBar.ProgressBarStyle类的典型用法代码示例。如果您正苦于以下问题:Java ProgressBarStyle类的具体用法?Java ProgressBarStyle怎么用?Java ProgressBarStyle使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
ProgressBarStyle类属于com.badlogic.gdx.scenes.scene2d.ui.ProgressBar包,在下文中一共展示了ProgressBarStyle类的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。
示例1: createSkin
import com.badlogic.gdx.scenes.scene2d.ui.ProgressBar.ProgressBarStyle; //导入依赖的package包/类
private Skin createSkin() {
Skin returnValue = new Skin();
returnValue.add("bg", createDrawable(20, 20, Color.DARK_GRAY), Drawable.class);
returnValue.add("progress-bar-back", createDrawable(20, 20, Color.BLACK), Drawable.class);
returnValue.add("progress-bar", createDrawable(1, 20, Color.BLUE), Drawable.class);
ProgressBarStyle progressBarStyle = new ProgressBarStyle();
progressBarStyle.background = returnValue.getDrawable("progress-bar-back");
progressBarStyle.knobBefore = returnValue.getDrawable("progress-bar");
returnValue.add("default-horizontal", progressBarStyle);
return returnValue;
}
开发者ID:raeleus,项目名称:bobbybird,代码行数:16,代码来源:LoadingState.java
示例2: resetProperties
import com.badlogic.gdx.scenes.scene2d.ui.ProgressBar.ProgressBarStyle; //导入依赖的package包/类
public void resetProperties() {
properties.clear();
if (clazz.equals(Button.class)) {
newStyleProperties(ButtonStyle.class);
} else if (clazz.equals(CheckBox.class)) {
newStyleProperties(CheckBoxStyle.class);
properties.get("checkboxOn").optional = false;
properties.get("checkboxOff").optional = false;
properties.get("font").optional = false;
} else if (clazz.equals(ImageButton.class)) {
newStyleProperties(ImageButtonStyle.class);
} else if (clazz.equals(ImageTextButton.class)) {
newStyleProperties(ImageTextButtonStyle.class);
properties.get("font").optional = false;
} else if (clazz.equals(Label.class)) {
newStyleProperties(LabelStyle.class);
properties.get("font").optional = false;
} else if (clazz.equals(List.class)) {
newStyleProperties(ListStyle.class);
properties.get("font").optional = false;
properties.get("fontColorSelected").optional = false;
properties.get("fontColorUnselected").optional = false;
properties.get("selection").optional = false;
} else if (clazz.equals(ProgressBar.class)) {
newStyleProperties(ProgressBarStyle.class);
//Though specified as optional in the doc, there are bugs without "background" being mandatory
properties.get("background").optional = false;
} else if (clazz.equals(ScrollPane.class)) {
newStyleProperties(ScrollPaneStyle.class);
} else if (clazz.equals(SelectBox.class)) {
newStyleProperties(SelectBoxStyle.class);
properties.get("font").optional = false;
properties.get("fontColor").optional = false;
properties.get("scrollStyle").optional = false;
properties.get("scrollStyle").value = "default";
properties.get("listStyle").optional = false;
properties.get("listStyle").value = "default";
} else if (clazz.equals(Slider.class)) {
newStyleProperties(SliderStyle.class);
//Though specified as optional in the doc, there are bugs without "background" being mandatory
properties.get("background").optional = false;
} else if (clazz.equals(SplitPane.class)) {
newStyleProperties(SplitPaneStyle.class);
properties.get("handle").optional = false;
} else if (clazz.equals(TextButton.class)) {
newStyleProperties(TextButtonStyle.class);
properties.get("font").optional = false;
} else if (clazz.equals(TextField.class)) {
newStyleProperties(TextFieldStyle.class);
properties.get("font").optional = false;
properties.get("fontColor").optional = false;
} else if (clazz.equals(TextTooltip.class)) {
newStyleProperties(TextTooltipStyle.class);
properties.get("label").optional = false;
properties.get("label").value = "default";
} else if (clazz.equals(Touchpad.class)) {
newStyleProperties(TouchpadStyle.class);
} else if (clazz.equals(Tree.class)) {
newStyleProperties(TreeStyle.class);
properties.get("plus").optional = false;
properties.get("minus").optional = false;
} else if (clazz.equals(Window.class)) {
newStyleProperties(WindowStyle.class);
properties.get("titleFont").optional = false;
}
}
开发者ID:raeleus,项目名称:skin-composer,代码行数:70,代码来源:StyleData.java
注:本文中的com.badlogic.gdx.scenes.scene2d.ui.ProgressBar.ProgressBarStyle类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论