javax.swing.JButton.getHeight()方法的使用及代码示例

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

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

JButton.getHeight介绍

暂无

代码示例

代码示例来源:origin: tomighty/tomighty

@Override
  public void actionPerformed(ActionEvent e) {
    menu.show(button, 0, button.getHeight());
  }
});

代码示例来源:origin: org.netbeans.api/org-openide-awt

private void displayOverflow() {
  int x = getOrientation() == HORIZONTAL ? overflowButton.getLocationOnScreen().x : overflowButton.getLocationOnScreen().x + overflowButton.getWidth();
  int y = getOrientation() == HORIZONTAL ? overflowButton.getLocationOnScreen().y + overflowButton.getHeight() : overflowButton.getLocationOnScreen().y;
  popup.setLocation(x, y);
  popup.setVisible(true);
}

代码示例来源:origin: sc.fiji/Simple_Neurite_Tracer

@Override
  public void actionPerformed(final ActionEvent e) {
    swcTypesMenu.show(swcTypesButton, 0, swcTypesButton.getHeight());
  }
});

代码示例来源:origin: edu.toronto.cs.medsavant/medsavant-client

@Override
  public void actionPerformed(ActionEvent ae) {
    getRegionSetsMenu(finalGene).show(addToRegionListButton, 0, addToRegionListButton.getHeight());
  }
});

代码示例来源:origin: net.java.dev.jets3t/jets3t

public void actionPerformed(ActionEvent e) {
    JButton sourceButton = (JButton) e.getSource();
    bucketActionMenu.show(sourceButton, 0, sourceButton.getHeight());
  }
});

代码示例来源:origin: net.java.dev.jets3t/jets3t

public void actionPerformed(ActionEvent e) {
    JButton sourceButton = (JButton) e.getSource();
    objectActionMenu.show(sourceButton, 0, sourceButton.getHeight());
  }
});

代码示例来源:origin: net.java.dev.jets3t/jets3t

public void actionPerformed(ActionEvent e) {
    JButton sourceButton = (JButton) e.getSource();
    objectActionMenu.show(sourceButton, 0, sourceButton.getHeight());
  }
});

代码示例来源:origin: org.apache.servicemix.bundles/org.apache.servicemix.bundles.jets3t

public void actionPerformed(ActionEvent e) {
    JButton sourceButton = (JButton) e.getSource();
    objectActionMenu.show(sourceButton, 0, sourceButton.getHeight());
  }
});

代码示例来源:origin: org.apache.servicemix.bundles/org.apache.servicemix.bundles.jets3t

public void actionPerformed(ActionEvent e) {
    JButton sourceButton = (JButton) e.getSource();
    bucketActionMenu.show(sourceButton, 0, sourceButton.getHeight());
  }
});

代码示例来源:origin: org.apache.servicemix.bundles/org.apache.servicemix.bundles.jets3t

public void actionPerformed(ActionEvent e) {
    JButton sourceButton = (JButton) e.getSource();
    objectActionMenu.show(sourceButton, 0, sourceButton.getHeight());
  }
});

代码示例来源:origin: org.scijava/scijava-ui-swing

private JButton initVisibilityButton() {
  JButton button = new JButton("visibility");
  button.addActionListener(a -> menu.show(button, 0, button.getHeight()));
  return button;
}

代码示例来源:origin: freeplane/freeplane

public void actionPerformed(final ActionEvent e) {
    if(showEditorBtn.isShowing())
      calendarPopupMenu.show(showEditorBtn, 0, showEditorBtn.getHeight());
  }
}

代码示例来源:origin: openpnp/openpnp

@Override
  public void mousePressed(MouseEvent e) {
    JPopupMenu menu = new JPopupMenu();
    menu.add(new JMenuItem(addNewBoardAction));
    menu.add(new JMenuItem(addExistingBoardAction));
    menu.show(btnAddBoard, (int) btnAddBoard.getWidth(), (int) btnAddBoard.getHeight());
  }
});

代码示例来源:origin: org.netbeans.api/org-openide-awt

: minX + overflowButton.getWidth() + popup.getWidth();
int minY = overflowButton.getLocationOnScreen().y;
int maxY_ob = minY + overflowButton.getHeight();
int maxY = getOrientation() == HORIZONTAL ? minY + overflowButton.getHeight() + popup.getHeight()
    : minY + popup.getHeight();
if (e.getXOnScreen() < minX || e.getYOnScreen() < minY || e.getXOnScreen() > maxX || e.getYOnScreen() > maxY

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

@ScriptFunction(jsDoc = HEIGHT_JSDOC)
@Override
public int getHeight() {
  return super.getHeight();
}

代码示例来源:origin: org.netbeans.api/org-netbeans-modules-bugtracking

@Override
  public void mouseClicked(MouseEvent e) {
    if (btnRecently.isEnabled()) {
      recentlyPopup.show(e.getComponent(), btnRecently.getX(), btnRecently.getY() + btnRecently.getHeight());
    }
  }
});

代码示例来源:origin: org.netbeans.api/org-netbeans-modules-bugtracking

@Override
  public void mouseClicked(MouseEvent e) {
    if (btnFilter.isEnabled()) {
      filterPopup.show(e.getComponent(), btnFilter.getX(), btnFilter.getY() + btnFilter.getHeight());
    }
  }
});

代码示例来源:origin: org.netbeans.modules/org-netbeans-lib-profiler-ui

private void showColumnSelectionPopup(final JPopupMenu headerPopup, final JButton cornerButton) {
    initColumnSelectorItems();
    headerPopup.show(cornerButton, cornerButton.getWidth() - headerPopup.getPreferredSize().width, cornerButton.getHeight());
  }
}

代码示例来源:origin: sc.fiji/Simple_Neurite_Tracer

@Override
  public void actionPerformed(final ActionEvent e) {
    if (!swcTypesMenu.isVisible()) {
      final Point p = swcTypesButton.getLocationOnScreen();
      swcTypesMenu.setInvoker(swcTypesButton);
      swcTypesMenu.setLocation((int) p.getX(), (int) p.getY() + swcTypesButton.getHeight());
      swcTypesMenu.setVisible(true);
    } else {
      swcTypesMenu.setVisible(false);
    }
  }
});

代码示例来源:origin: org.apache.cayenne.modeler/cayenne-modeler

@Override
public void performAction(ActionEvent e) {
  JButton source = (JButton)e.getSource();
  if(filterDialog == null) {
    filterDialog = new FilterDialog(getApplication().getFrameController().getEditorView().getFilterController());
  }
  filterDialog.pack();
  filterDialog.show(source, 0, source.getHeight());
}

相关文章

JButton类方法