当前位置: 首页>>代码示例>>Java>>正文


Java Container类代码示例

本文整理汇总了Java中com.simsilica.lemur.Container的典型用法代码示例。如果您正苦于以下问题:Java Container类的具体用法?Java Container怎么用?Java Container使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


Container类属于com.simsilica.lemur包,在下文中一共展示了Container类的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: PropertyPanel

import com.simsilica.lemur.Container; //导入依赖的package包/类
protected PropertyPanel( boolean applyStyles, ElementId elementId, String style ) {
    super(false, elementId, style);

    this.layout = new BorderLayout();
    getControl(GuiControl.class).setLayout(layout);
 
    this.container = new Container(new SpringGridLayout(Axis.Y, Axis.X, FillMode.Even, FillMode.Last), 
                                   elementId.child("container"), style);
    layout.addChild(container, BorderLayout.Position.Center);       

    
    if( applyStyles ) {
        Styles styles = GuiGlobals.getInstance().getStyles();
        styles.applyStyles(this, elementId, style);
    }
}
 
开发者ID:jMonkeyEngine-Contributions,项目名称:Lemur,代码行数:17,代码来源:PropertyPanel.java

示例2: initialize

import com.simsilica.lemur.Container; //导入依赖的package包/类
@Override
public void initialize( Container container ) {
    label = new Label(getDisplayName() + ":", getElementId().child("float.label"), getStyle());
    label.setTextHAlignment(HAlignment.Right); 
    slider = new Slider( model, Axis.X, getElementId().child("float.slider"), getStyle());
    slider.setDelta(step);
    //Float current = getValue();
    //model.setValue(current);
    refresh();
    valueText = new Label("", getElementId().child("value.label"), getStyle());
    updateText();
                
    value = slider.getModel().createReference();
    container.addChild(label);
    container.addChild(valueText, 1); 
    container.addChild(slider, 2); 
}
 
开发者ID:jMonkeyEngine-Contributions,项目名称:Lemur,代码行数:18,代码来源:PropertyPanel.java

示例3: initialize

import com.simsilica.lemur.Container; //导入依赖的package包/类
@Override
protected void initialize( Application app ) {
    
    screen = new Container(new BorderLayout(), SCREEN_ID);
    screen.setBackground(null);
 
    ElementId containerId = CONTAINER_ID;       
    top = screen.addChild(new Container(new SpringGridLayout(Axis.X, Axis.Y), containerId), 
                          BorderLayout.Position.North);
    bottom = screen.addChild(new Container(new SpringGridLayout(Axis.X, Axis.Y), containerId), 
                            BorderLayout.Position.South);
 
    // For now we'll just do this but I think we need a sub container to 
    // really make things lay out right
    left = screen.addChild(new Container(new SpringGridLayout(Axis.Y, Axis.X, FillMode.None, FillMode.Last), containerId), BorderLayout.Position.West);        
    right = screen.addChild(new Container(new SpringGridLayout(Axis.Y, Axis.X, FillMode.None, FillMode.Last), containerId), BorderLayout.Position.East);        
}
 
开发者ID:Simsilica,项目名称:SiO2,代码行数:18,代码来源:DebugHudState.java

示例4: getContainer

import com.simsilica.lemur.Container; //导入依赖的package包/类
/**
 *  Returns the raw container within which the property
 *  editors are added.
 */
public Container getContainer() {
    return container;
}
 
开发者ID:jMonkeyEngine-Contributions,项目名称:Lemur,代码行数:8,代码来源:PropertyPanel.java


注:本文中的com.simsilica.lemur.Container类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。