javax.swing.JPopupMenu.setOpaque()方法的使用及代码示例

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

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

JPopupMenu.setOpaque介绍

暂无

代码示例

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

/**
 * Description of the Method
 */
protected void uninstallDefaults() {
 super.uninstallDefaults();
 popupMenu.setOpaque(true);
}

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

@ScriptFunction
@Override
public void setOpaque(boolean aValue) {
  super.setOpaque(aValue);
}

代码示例来源:origin: senbox-org/snap-desktop

public InputOptionsPanel(JTextArea parent) {
  popupMenu = new JPopupMenu();
  popupMenu.setOpaque(false);
  popupMenu.setBorder(null);
  textArea = parent;
}

代码示例来源:origin: com.github.cfparser/cfml.parsing

private void createTree() {
  tree = new JTree(new DefaultMutableTreeNode("Choose a java source file."));
  tree.getSelectionModel().setSelectionMode(TreeSelectionModel.SINGLE_TREE_SELECTION);
  popup = new JPopupMenu();
  JMenuItem mi = new JMenuItem("Expand all children");
  mi.addActionListener(this);
  mi.setActionCommand("expand");
  popup.add(mi);
  
  mi = new JMenuItem("Collapse all children");
  mi.addActionListener(this);
  mi.setActionCommand("collapse");
  popup.add(mi);
  popup.setOpaque(true);
  popup.setLightWeightPopupEnabled(true);
  tree.addMouseListener(this);
}

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

/**
 * Description of the Method
 */
public void installDefaults() {
 super.installDefaults();
 skin.getPersonality().installSkin(popupMenu);
 if (Boolean.TRUE.equals(UIManager.get("PopupMenu.animation"))) {
  popupMenu.setOpaque(false);
 }
}

代码示例来源:origin: net.sf.nimrod/nimrod-laf

public void uninstallDefaults() {
 super.uninstallDefaults();
 
 LookAndFeel.installBorder( popupMenu, "PopupMenu.border");
 popupMenu.setOpaque( true);
}

代码示例来源:origin: net.sf.nimrod/nimrod-laf

public void installDefaults() {
 super.installDefaults();
 
 popupMenu.setBorder( NimRODBorders.getPopupMenuBorder());
 popupMenu.setOpaque( false);
}

代码示例来源:origin: net.sourceforge.ondex.apps/ovtk2

createItem(popup, "Upgrade");
createItem(popup, "Downgrade");
popup.setOpaque(true);
popup.setLightWeightPopupEnabled(true);

代码示例来源:origin: khuxtable/seaglass

public void installDefaults() {
  if (popupMenu.getLayout() == null || popupMenu.getLayout() instanceof UIResource) {
    popupMenu.setLayout(new DefaultMenuLayout(popupMenu, BoxLayout.Y_AXIS));
    popupMenu.setOpaque(false);
  }
  updateStyle(popupMenu);
}

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

jTextField2.addKeyListener(new java.awt.event.KeyAdapter() {
   public void keyReleased(java.awt.event.KeyEvent evt) {
     showPopup(evt);
   }
 });
void showPopup(java.awt.event.KeyEvent evt) {
   JPopupMenu popup = new JPopupMenu();
   popup.setLightWeightPopupEnabled(false);
   popup.setBorder(BorderFactory.createLineBorder(Color.black));
   popup.setLayout(new BorderLayout());
   popup.setSize(this.getPreferredSize());
   popup.setPreferredSize(this.getPreferredSize());
   popup.pack();
   popup.setOpaque(false);
   // create panel that contains the search result 
   popup.add(BorderLayout.CENTER, <YOUR PANEL WITH THE RESULT>);
   popup.setPreferredSize(new Dimension(jTextField2.getWidth(),250));
   <SEARCH PANEL>.setPreferredSize(new Dimension(jTextField2.getWidth(),250));
   popup.show(jTextField2, 0, jTextField2.getHeight());
  }

代码示例来源:origin: org.gosu-lang.gosu/gosu-lab

splash.setOpaque( false );
splash.setBackground( new Color( 0, 0, 0, 0 ) );
splash.add( imagePanel );

代码示例来源:origin: net.java.dev.laf-widget/laf-widget

iconPopupMenu.setOpaque(false);
JLabel iconLabel = new JLabel(getAutoScrollIcon());
iconLabel.addMouseWheelListener(new MouseWheelListener() {

相关文章

JPopupMenu类方法