java.awt.FlowLayout.setAlignOnBaseline()方法的使用及代码示例

x33g5p2x  于2022-01-19 转载在 其他  
字(3.7k)|赞(0)|评价(0)|浏览(119)

本文整理了Java中java.awt.FlowLayout.setAlignOnBaseline()方法的一些代码示例,展示了FlowLayout.setAlignOnBaseline()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。FlowLayout.setAlignOnBaseline()方法的具体详情如下:
包路径:java.awt.FlowLayout
类名称:FlowLayout
方法名:setAlignOnBaseline

FlowLayout.setAlignOnBaseline介绍

暂无

代码示例

代码示例来源:origin: stackoverflow.com

FlowLayout flow = new FlowLayout();
flow.setAlignOnBaseline(true);
panel.setLayout(flow);

代码示例来源:origin: stackoverflow.com

flowLayout1.setAlignOnBaseline(true);
pnlContent.setLayout(flowLayout1);
add(pnlContent, java.awt.BorderLayout.CENTER);

代码示例来源:origin: UNIVALI-LITE/Portugol-Studio

cabecalhosContainer.setMaximumSize(new java.awt.Dimension(32767, 40));
java.awt.FlowLayout flowLayout1 = new java.awt.FlowLayout(java.awt.FlowLayout.LEADING, 0, 0);
flowLayout1.setAlignOnBaseline(true);
cabecalhosContainer.setLayout(flowLayout1);
jPanel1.add(cabecalhosContainer, java.awt.BorderLayout.CENTER);

代码示例来源:origin: datacleaner/DataCleaner

public DCBannerPanel(final Image leftImage, final Image bgImage, final Image rightImage, final String title) {
  _leftImage = adjuster.scale(leftImage);
  _bgImage = adjuster.scale(bgImage);
  _rightImage = adjuster.scale(rightImage);
  if (title == null) {
    _title1 = null;
    _title2 = null;
  } else {
    final int linebreak = title.indexOf('\n');
    if (linebreak == -1) {
      _title1 = title;
      _title2 = null;
    } else {
      _title1 = title.substring(0, linebreak);
      _title2 = title.substring(linebreak + 1);
    }
  }
  if (leftImage == null) {
    _titleIndent = 0;
  } else {
    _titleIndent = _leftImage.getWidth(this);
  }
  setOpaque(false);
  final FlowLayout layout = new FlowLayout(Alignment.RIGHT.getFlowLayoutAlignment(), 4, 38);
  layout.setAlignOnBaseline(true);
  setLayout(layout);
}

代码示例来源:origin: org.openbase.bco/dal.visual

flowLayout1.setAlignOnBaseline(true);
jPanel5.setLayout(flowLayout1);

代码示例来源:origin: robward-scisys/sldeditor

/**
 * Instantiates a new tool panel.
 *
 * @param parentObj the parent obj
 * @param toolMap the tool map
 */
public ToolPanel(ToolSelectionInterface parentObj, Map<Class<?>, List<ToolInterface>> toolMap) {
  this.toolSelection = parentObj;
  theToolPanel = new JPanel();
  FlowLayout flowLayout = (FlowLayout) theToolPanel.getLayout();
  flowLayout.setAlignOnBaseline(true);
  flowLayout.setVgap(1);
  flowLayout.setHgap(1);
  setLayout(new BoxLayout(this, BoxLayout.Y_AXIS));
  this.add(theToolPanel);
  this.toolMap = toolMap;
  JPanel optionsPanel = new JPanel();
  add(optionsPanel);
  JCheckBox chckbxRecursive =
      new JCheckBox(Localisation.getString(ToolPanel.class, "ToolPanel.recursive"));
  chckbxRecursive.addActionListener(
      new ActionListener() {
        public void actionPerformed(ActionEvent e) {
          toolSelection.setRecursiveFlag(chckbxRecursive.isSelected());
        }
      });
  optionsPanel.add(chckbxRecursive);
  this.setPreferredSize(new Dimension(50, EMPTY_TOOL_PANEL_HEIGHT));
}

代码示例来源:origin: stackoverflow.com

((FlowLayout) bg.getLayout()).setAlignOnBaseline(true);
frame.add(bg);
JPanel left = new JPanel();

代码示例来源:origin: com.io7m.jcamera/com.io7m.jcamera.examples.jogl

CameraLabWindow()
{
 final Container content = this.getContentPane();
 this.setJMenuBar(menu(this));
 final ExecutorService background_workers =
  NullCheck.notNull(Executors.newFixedThreadPool(1));
 final GLProfile profile = GLProfile.get(GLProfile.GL3);
 final GLCapabilities caps = new GLCapabilities(profile);
 final GLWindow window = GLWindow.create(caps);
 window.setSize(512, 512);
 final NewtCanvasAWT canvas = new NewtCanvasAWT(window);
 canvas.requestFocus();
 final JPanel canvas_panel = new JPanel();
 canvas_panel.add(canvas);
 final ExampleRenderer renderer = new ExampleRenderer();
 final Panel controls =
  new Panel(background_workers, renderer, canvas_panel, window);
 final FlowLayout layout = new FlowLayout(FlowLayout.LEADING, 8, 8);
 layout.setAlignOnBaseline(true);
 content.setLayout(layout);
 content.add(canvas_panel);
 content.add(controls);
 final Animator anim = new Animator();
 anim.add(window);
 anim.start();
}

相关文章