Package java.awt

Examples of java.awt.Component.doLayout()


    if (beanClass != null) {
      try {
        Component comp = (Component) beanClass.newInstance();
        Dimension size = comp.getPreferredSize();
        comp.setSize(size);
        comp.doLayout();
        comp.validate();
        return comp;
      } catch (Exception e) {
        WidgetPlugin.getLogger().error(e);
      }
View Full Code Here


      w = min.width;
    if (h <= min.height)
      h = min.height;
    adaptable.setMascotLocation(hotspot);
    beResized.setSize(w, h);
    beResized.doLayout();
  }

  @Override
  public boolean drop(Point p) {
    if (isDroppingPopup() || isDroppingMenuItem() || isDroppingMenuBar())
View Full Code Here

   
    public void run() {
      if (!adapter.isRoot()) {
        CompositeAdapter parent = adapter.getParentAdapter();
        Component widget = parent.getWidget();
        widget.doLayout();
        widget.validate();
      } else {
        Component widget = adapter.getWidget();
        widget.doLayout();
        widget.validate();
View Full Code Here

        Component widget = parent.getWidget();
        widget.doLayout();
        widget.validate();
      } else {
        Component widget = adapter.getWidget();
        widget.doLayout();
        widget.validate();
      }
      adapter.repaintDesigner();
    }
  }
View Full Code Here

      Font f = adapter.getWidget().getFont();
      if (f != null) {
        comp.setFont(f);
      }
      comp.setBounds(bounds);
      comp.doLayout();
      glassPlane.add(comp);
      comp.addFocusListener(this);
      glassPlane.validate();
      glassPlane.repaint();
      comp.repaint();
View Full Code Here

            public void actionPerformed(ActionEvent e) {
                TreePath path = tree.getSelectionPath();
                if (path != null) {
                    DefaultMutableTreeNode node = (DefaultMutableTreeNode)path.getLastPathComponent();
                    Component c = (Component)node.getUserObject();
                    c.doLayout();
                }
            }
        });
       
        contextMenu.add(layoutRequest);
View Full Code Here

            public void actionPerformed(ActionEvent e) {
                TreePath path = tree.getSelectionPath();
                if (path != null) {
                    DefaultMutableTreeNode node = (DefaultMutableTreeNode)path.getLastPathComponent();
                    Component c = (Component)node.getUserObject();
                    c.doLayout();
                }
            }
        });
       
        contextMenu.add(layoutRequest);
View Full Code Here

            public void actionPerformed(ActionEvent e) {
                TreePath path = tree.getSelectionPath();
                if (path != null) {
                    DefaultMutableTreeNode node = (DefaultMutableTreeNode)path.getLastPathComponent();
                    Component c = (Component)node.getUserObject();
                    c.doLayout();
                }
            }
        });
       
        contextMenu.add(layoutRequest);
View Full Code Here

    if ( renderHeight != contentHeight ) {
      Component parent = getParent().getParent();
      contentHeight = renderHeight;
      if ( parent instanceof ScrollPane ) {
        setSize( getParent().getSize().width - 12, contentHeight );
        parent.doLayout();
      }
      else
        repaint();
    }
  }
View Full Code Here

    if ( renderHeight != contentHeight ) {
      Component parent = getParent();
      contentHeight = renderHeight;
      if ( parent instanceof ScrollPane ) {
        setSize( getSize().width - 40, contentHeight );
        parent.doLayout();
      }
      else
        repaint();
    }
   
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.