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


Java Cell.pad方法代码示例

本文整理汇总了Java中com.badlogic.gdx.scenes.scene2d.ui.Cell.pad方法的典型用法代码示例。如果您正苦于以下问题:Java Cell.pad方法的具体用法?Java Cell.pad怎么用?Java Cell.pad使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在com.badlogic.gdx.scenes.scene2d.ui.Cell的用法示例。


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

示例1: process

import com.badlogic.gdx.scenes.scene2d.ui.Cell; //导入方法依赖的package包/类
@Override
public void process(final LmlParser parser, final LmlTag tag, final Actor actor, final Cell<?> cell,
        final String rawAttributeData) {
    final Value horizontalValue = LmlUtilities.parseHorizontalValue(parser, tag.getParent(), actor,
            rawAttributeData);
    final Value verticalValue = LmlUtilities.parseVerticalValue(parser, tag.getParent(), actor, rawAttributeData);
    cell.pad(verticalValue, horizontalValue, verticalValue, horizontalValue);
}
 
开发者ID:czyzby,项目名称:gdx-lml,代码行数:9,代码来源:CellPadLmlAttribute.java

示例2: fillTable

import com.badlogic.gdx.scenes.scene2d.ui.Cell; //导入方法依赖的package包/类
public void fillTable() {
  this.table.clear();
  Widgets _widgets = this.getWidgets();
  Label _createLabel = _widgets.createLabel("IP");
  Cell<Label> _add = this.table.<Label>add(_createLabel);
  _add.pad(LocalScreen.CELLPAD);
  Widgets _widgets_1 = this.getWidgets();
  Label _createLabel_1 = _widgets_1.createLabel("Name");
  Cell<Label> _add_1 = this.table.<Label>add(_createLabel_1);
  _add_1.pad(LocalScreen.CELLPAD);
  Widgets _widgets_2 = this.getWidgets();
  Label _createLabel_2 = _widgets_2.createLabel(" # / # ");
  Cell<Label> _add_2 = this.table.<Label>add(_createLabel_2);
  _add_2.pad(LocalScreen.CELLPAD);
  Widgets _widgets_3 = this.getWidgets();
  Label _createLabel_3 = _widgets_3.createLabel("");
  Cell<Label> _add_3 = this.table.<Label>add(_createLabel_3);
  _add_3.pad(LocalScreen.CELLPAD);
  this.table.row();
  for (final NetworkGameInfo game : this.games) {
    {
      Widgets _widgets_4 = this.getWidgets();
      InetAddress _ipAddr = game.getIpAddr();
      String _hostAddress = _ipAddr.getHostAddress();
      Label _createLabel_4 = _widgets_4.createLabel(_hostAddress);
      Cell<Label> _add_4 = this.table.<Label>add(_createLabel_4);
      _add_4.pad(LocalScreen.CELLPAD);
      Widgets _widgets_5 = this.getWidgets();
      String _gameName = game.getGameName();
      Label _createLabel_5 = _widgets_5.createLabel(_gameName);
      Cell<Label> _add_5 = this.table.<Label>add(_createLabel_5);
      _add_5.pad(LocalScreen.CELLPAD);
      Widgets _widgets_6 = this.getWidgets();
      int _currentPlayer = game.getCurrentPlayer();
      String _plus = (" " + Integer.valueOf(_currentPlayer));
      String _plus_1 = (_plus + " / ");
      int _maxPlayer = game.getMaxPlayer();
      String _plus_2 = (_plus_1 + Integer.valueOf(_maxPlayer));
      String _plus_3 = (_plus_2 + " ");
      Label _createLabel_6 = _widgets_6.createLabel(_plus_3);
      Cell<Label> _add_6 = this.table.<Label>add(_createLabel_6);
      _add_6.pad(LocalScreen.CELLPAD);
      Widgets _widgets_7 = this.getWidgets();
      Icons _xifexpression = null;
      int _gameId = game.getGameId();
      boolean _equals = (_gameId == (-1));
      if (_equals) {
        _xifexpression = Icons.Join;
      } else {
        _xifexpression = Icons.JoinActivate;
      }
      final Procedure0 _function = new Procedure0() {
        @Override
        public void apply() {
          LocalScreen.this.startGame(game);
        }
      };
      boolean _xifexpression_1 = false;
      int _gameId_1 = game.getGameId();
      boolean _equals_1 = (_gameId_1 == (-1));
      if (_equals_1) {
        _xifexpression_1 = true;
      } else {
        _xifexpression_1 = false;
      }
      MyTextButton _createButton = _widgets_7.createButton(_xifexpression, _function, _xifexpression_1);
      Cell<MyTextButton> _add_7 = this.table.<MyTextButton>add(_createButton);
      _add_7.pad(LocalScreen.CELLPAD);
      this.table.row();
    }
  }
}
 
开发者ID:CymricNPG,项目名称:abattle,代码行数:73,代码来源:LocalScreen.java

示例3: defaultCellOptions

import com.badlogic.gdx.scenes.scene2d.ui.Cell; //导入方法依赖的package包/类
private Cell defaultCellOptions(final Cell cell) {
  Cell _pad = cell.pad(OptionTable.CELLPAD);
  return _pad.align(Align.left);
}
 
开发者ID:CymricNPG,项目名称:abattle,代码行数:5,代码来源:OptionTable.java

示例4: applyPadding

import com.badlogic.gdx.scenes.scene2d.ui.Cell; //导入方法依赖的package包/类
/** Allows to set Cell's padding with the Padding object, which has be done externally, as it's not part of the
 * standard libGDX API.
 *
 * @param cell will have the padding set according to the this object's data.
 * @return the given cell for chaining. */
public Cell<?> applyPadding(final Cell<?> cell) {
    cell.pad(top, left, bottom, right);
    return cell;
}
 
开发者ID:gdx-libs,项目名称:gdx-kiwi,代码行数:10,代码来源:Padding.java

示例5: setPadding

import com.badlogic.gdx.scenes.scene2d.ui.Cell; //导入方法依赖的package包/类
/** Allows to set Cell's padding with the Padding object, which has be done externally, as it's not part of the
 * standard libGDX API.
 *
 * @param padding contains data of padding sizes.
 * @param cell will have the padding set according to the given data.
 * @return the given cell for chaining. */
public static Cell<?> setPadding(final Padding padding, final Cell<?> cell) {
    return cell.pad(padding.getTop(), padding.getLeft(), padding.getBottom(), padding.getRight());
}
 
开发者ID:gdx-libs,项目名称:gdx-kiwi,代码行数:10,代码来源:Padding.java


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