javax.swing.JScrollPane.getCorner()方法的使用及代码示例

x33g5p2x  于2022-01-21 转载在 其他  
字(6.4k)|赞(0)|评价(0)|浏览(191)

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

JScrollPane.getCorner介绍

暂无

代码示例

代码示例来源:origin: com.jidesoft/jide-oss

@Override
public Component getCorner(String key) {
  if (key == null) {
    return null;
  }
  if (key.equals(SUB_UPPER_LEFT)) {
    return _subUpperLeft;
  }
  else if (key.equals(SUB_UPPER_RIGHT)) {
    return _subUpperRight;
  }
  return super.getCorner(key);
}

代码示例来源:origin: com.synaptix/SynaptixWidget

@Override
public Component getCorner(String key) {
  if (LOWER_LEFT_0_CORNER.equals(key)) {
    return lowerLeft0;
  } else if (LOWER_RIGHT_0_CORNER.equals(key)) {
    return lowerRight0;
  } else if (UPPER_RIGHT_0_CORNER.equals(key)) {
    return upperRight0;
  } else {
    return super.getCorner(key);
  }
}

代码示例来源:origin: org.bidib.jbidib.swinglabs.swingx/swingx-core

private void removeColumnControlFromCorners(JScrollPane scrollPane, String... corners) {
  for (String corner : corners) {
    if (scrollPane.getCorner(corner) == getColumnControl()) {
      scrollPane.setCorner(corner, null);
    }
  }
}

代码示例来源:origin: net.sf.squirrel-sql.thirdparty-non-maven/toniclf

/**
 * This method is invoked after the ScrollPaneLayout is set as the
 * LayoutManager of a <code>JScrollPane</code>.
 * It initializes all of the internal fields that
 * are ordinarily set by <code>addLayoutComponent</code>.  For example:
 * <pre>
 * ScrollPaneLayout mySPLayout = new ScrollPanelLayout() {
 *     public void layoutContainer(Container p) {
 *         super.layoutContainer(p);
 *         // do some extra work here ...
 *     }
 * };
 * scrollpane.setLayout(mySPLayout):
 * </pre>
 */
 public void syncWithScrollPane(JScrollPane sp) {
viewport = sp.getViewport();
vsb = sp.getVerticalScrollBar();
hsb = sp.getHorizontalScrollBar();
rowHead = sp.getRowHeader();
colHead = sp.getColumnHeader();
lowerLeft = sp.getCorner(LOWER_LEFT_CORNER);
lowerRight = sp.getCorner(LOWER_RIGHT_CORNER);
upperLeft = sp.getCorner(UPPER_LEFT_CORNER);
upperRight = sp.getCorner(UPPER_RIGHT_CORNER);
vsbPolicy = sp.getVerticalScrollBarPolicy();
hsbPolicy = sp.getHorizontalScrollBarPolicy();
 }

代码示例来源:origin: org.swinglabs.swingx/swingx-core

private void removeColumnControlFromCorners(JScrollPane scrollPane, String... corners) {
  for (String corner : corners) {
    if (scrollPane.getCorner(corner) == getColumnControl()) {
      scrollPane.setCorner(corner, null);
    }
  }
}

代码示例来源:origin: com.haulmont.thirdparty/swingx-core

private void removeColumnControlFromCorners(JScrollPane scrollPane, String... corners) {
  for (String corner : corners) {
    if (scrollPane.getCorner(corner) == getColumnControl()) {
      scrollPane.setCorner(corner, null);
    }
  }
}

代码示例来源:origin: org.swinglabs.swingx/swingx-all

private void removeColumnControlFromCorners(JScrollPane scrollPane, String... corners) {
  for (String corner : corners) {
    if (scrollPane.getCorner(corner) == getColumnControl()) {
      scrollPane.setCorner(corner, null);
    }
  }
}

代码示例来源:origin: com.eas.platypus/platypus-js-forms

/**
 * This method is invoked after the ScrollPaneLayout is set as the
 * LayoutManager of a <code>JScrollPane</code>.
 * It initializes all of the internal fields that
 * are ordinarily set by <code>addLayoutComponent</code>.  For example:
 * <pre>
 * ScrollPaneLayout mySPLayout = new ScrollPanelLayout() {
 *     public void layoutContainer(Container p) {
 *         super.layoutContainer(p);
 *         // do some extra work here ...
 *     }
 * };
 * scrollpane.setLayout(mySPLayout):
 * </pre>
 */
public void syncWithScrollPane(JScrollPane sp) {
  viewport = sp.getViewport();
  vsb = sp.getVerticalScrollBar();
  hsb = sp.getHorizontalScrollBar();
  rowHead = sp.getRowHeader();
  colHead = sp.getColumnHeader();
  lowerLeft = sp.getCorner(LOWER_LEFT_CORNER);
  lowerRight = sp.getCorner(LOWER_RIGHT_CORNER);
  upperLeft = sp.getCorner(UPPER_LEFT_CORNER);
  upperRight = sp.getCorner(UPPER_RIGHT_CORNER);
  vsbPolicy = sp.getVerticalScrollBarPolicy();
  hsbPolicy = sp.getHorizontalScrollBarPolicy();
}

代码示例来源:origin: com.github.insubstantial/substance

@Override
protected void uninstallDefaults(JScrollPane c) {
  Component upperRight = c.getCorner(JScrollPane.UPPER_RIGHT_CORNER);
  if (upperRight instanceof UIResource) {
    c.setCorner(JScrollPane.UPPER_RIGHT_CORNER, null);
  }
  Component upperLeft = c.getCorner(JScrollPane.UPPER_LEFT_CORNER);
  if (upperLeft instanceof UIResource) {
    c.setCorner(JScrollPane.UPPER_LEFT_CORNER, null);
  }
  LayoutManager lm = scrollpane.getLayout();
  if (lm instanceof AdjustedLayout) {
    c.setLayout(((AdjustedLayout) lm).delegate);
  }
  super.uninstallDefaults(c);
}

代码示例来源:origin: org.java.net.substance/substance

@Override
protected void uninstallDefaults(JScrollPane c) {
  Component upperRight = c.getCorner(JScrollPane.UPPER_RIGHT_CORNER);
  if (upperRight instanceof UIResource) {
    c.setCorner(JScrollPane.UPPER_RIGHT_CORNER, null);
  }
  Component upperLeft = c.getCorner(JScrollPane.UPPER_LEFT_CORNER);
  if (upperLeft instanceof UIResource) {
    c.setCorner(JScrollPane.UPPER_LEFT_CORNER, null);
  }
  LayoutManager lm = scrollpane.getLayout();
  if (lm instanceof AdjustedLayout) {
    c.setLayout(((AdjustedLayout) lm).delegate);
  }
  super.uninstallDefaults(c);
}

代码示例来源:origin: com.jidesoft/jide-oss

@Override
public void syncWithScrollPane(JScrollPane sp) {
  super.syncWithScrollPane(sp);
  if (sp instanceof JideScrollPane) {
    _rowFoot = ((JideScrollPane) sp).getRowFooter();
    _colFoot = ((JideScrollPane) sp).getColumnFooter();
    _subColHead = ((JideScrollPane) sp).getSubColumnHeader();
    _hLeft = ((JideScrollPane) sp).getScrollBarCorner(HORIZONTAL_LEFT);
    _hRight = ((JideScrollPane) sp).getScrollBarCorner(HORIZONTAL_RIGHT);
    _vTop = ((JideScrollPane) sp).getScrollBarCorner(VERTICAL_TOP);
    _vBottom = ((JideScrollPane) sp).getScrollBarCorner(VERTICAL_BOTTOM);
    _subUpperLeft = sp.getCorner(SUB_UPPER_LEFT);
    _subUpperRight = sp.getCorner(SUB_UPPER_RIGHT);
  }
}

代码示例来源:origin: org.simplericity.jettyconsole/jetty-console-core

b.add(scroll);
scroll.getViewport().setOpaque(false);
Component corner = scroll.getCorner(JScrollPane.LOWER_RIGHT_CORNER);
if (corner != null) {

代码示例来源:origin: org.netbeans.modules/org-netbeans-modules-dlight-visualizers

tableScroll.setBorder(new javax.swing.border.EmptyBorder(0, 0, 0, 0));
tableScroll.setCorner(JScrollPane.UPPER_RIGHT_CORNER, new JPanel());
tableScroll.getCorner(JScrollPane.UPPER_RIGHT_CORNER).setBackground(Color.WHITE);
viewPort = new CustomTimeLineViewport(this);
viewPort.setView(table);

代码示例来源:origin: org.java.net.substance/substance

String cornerKey = scrollpane.getComponentOrientation().isLeftToRight() ? JScrollPane.UPPER_RIGHT_CORNER
    : JScrollPane.UPPER_LEFT_CORNER;
Component cornerComp = scrollpane.getCorner(cornerKey);

代码示例来源:origin: com.github.insubstantial/substance

String cornerKey = scrollpane.getComponentOrientation().isLeftToRight() ? JScrollPane.UPPER_RIGHT_CORNER
    : JScrollPane.UPPER_LEFT_CORNER;
Component cornerComp = scrollpane.getCorner(cornerKey);

相关文章

JScrollPane类方法