本文整理了Java中javax.swing.JToolBar.getComponentOrientation()
方法的一些代码示例,展示了JToolBar.getComponentOrientation()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。JToolBar.getComponentOrientation()
方法的具体详情如下:
包路径:javax.swing.JToolBar
类名称:JToolBar
方法名:getComponentOrientation
暂无
代码示例来源:origin: org.opentcs.thirdparty.jhotdraw/jhotdraw
int hx = x, hy = y, hw = w, hh = h;
if (c.getOrientation() == HORIZONTAL) {
if (c.getComponentOrientation().isLeftToRight()) {
int barW = 18;
int barH = h;
代码示例来源:origin: org.opentcs.thirdparty.jhotdraw/jhotdraw
public void setOrientation(int o) {
if (isShowing()) {
if (o == this.orientation) {
return;
}
this.orientation = o;
Dimension size = getSize();
setSize(new Dimension(size.height, size.width));
if (offset != null) {
if (toolBar.getComponentOrientation().isLeftToRight()) {
setOffset(new Point(offset.y, offset.x));
} else if (o == JToolBar.HORIZONTAL) {
setOffset(new Point(size.height - offset.y, offset.x));
} else {
setOffset(new Point(offset.y, size.width - offset.x));
}
}
repaint();
}
}
代码示例来源:origin: khuxtable/seaglass
flip = !toolbar.getComponentOrientation().isLeftToRight();
Object o = SeaGlassLookAndFeel.resolveToolbarConstraint(toolbar);
代码示例来源:origin: khuxtable/seaglass
protected void paint(SeaGlassContext context, Graphics g) {
if (handleIcon != null && toolBar.isFloatable()) {
int startX = toolBar.getComponentOrientation().isLeftToRight() ? 0 : toolBar.getWidth()
- SeaGlassIcon.getIconWidth(handleIcon, context);
SeaGlassIcon.paintIcon(handleIcon, context, g, startX, 0, SeaGlassIcon.getIconWidth(handleIcon, context), SeaGlassIcon.getIconHeight(
handleIcon, context));
}
SeaGlassContext subcontext = getContext(toolBar, Region.TOOL_BAR_CONTENT, contentStyle);
// paintContent(subcontext, g, contentRect);
subcontext.dispose();
}
代码示例来源:origin: com.github.insubstantial/substance
.getComponentFontSize(c));
if (toolbar.getOrientation() == SwingConstants.HORIZONTAL) {
if (toolbar.getComponentOrientation().isLeftToRight()) {
newInsets.left = dragInset;
} else {
代码示例来源:origin: org.java.net.substance/substance
.getComponentFontSize(c));
if (toolbar.getOrientation() == SwingConstants.HORIZONTAL) {
if (toolbar.getComponentOrientation().isLeftToRight()) {
newInsets.left = dragInset;
} else {
代码示例来源:origin: khuxtable/seaglass
public void layoutContainer(Container parent) {
JToolBar tb = (JToolBar) parent;
Insets insets = tb.getInsets();
boolean ltr = tb.getComponentOrientation().isLeftToRight();
SeaGlassContext context = getContext(tb);
内容来源于网络,如有侵权,请联系作者删除!