Package org.jdesktop.swingx

Examples of org.jdesktop.swingx.JXTitledPanel


     * @see javax.swing.JComponent#updateUI
     */
    @Override
    public void installUI(JComponent c) {
        assert c instanceof JXTitledPanel;
        JXTitledPanel titledPanel = (JXTitledPanel)c;
        installDefaults(titledPanel);
       
        caption = createAndConfigureCaption(titledPanel);
        topPanel = createAndConfigureTopPanel(titledPanel);
       
View Full Code Here


     * @see javax.swing.JComponent#updateUI
     */
    @Override
    public void uninstallUI(JComponent c) {
        assert c instanceof JXTitledPanel;
        JXTitledPanel titledPanel = (JXTitledPanel) c;
        uninstallListeners(titledPanel);
        // JW: this is needed to make the gradient paint work correctly...
        // LF changes will remove the left/right components...
        topPanel.removeAll();
        titledPanel.remove(topPanel);
        titledPanel.putClientProperty(JXTitledPanel.LEFT_DECORATION, left);
        titledPanel.putClientProperty(JXTitledPanel.RIGHT_DECORATION, right);
        caption =  null;
        topPanel = null;
        titledPanel = null;
        left = null;
        right = null;
View Full Code Here

    /**
     * Initialize the main panel
     */
    protected void init() {
        navigatorPanel = new JXTitledPanel("Navigation");


        JPanel jPanel = new JPanel();
        double size[][] = {{TableLayoutConstants.FILL}, // Columns
                {25, 25, 25, 25, TableLayoutConstants.FILL}}; // Rows
        jPanel.setLayout(new TableLayout(size));
        jPanel.add(new JTextField("textfield1"), "0,0");
        jPanel.add(new JTextField("textfield2"), "0,1");
        jPanel.add(new JTextField("textfield3"), "0,2");
        jPanel.add(new JTextField("textfield4"), "0,3");
        infoPanel = new JXTitledPanel("Information", jPanel);


        JSplitPane mainSP = createSplitPane(200, JSplitPane.HORIZONTAL_SPLIT);
        mainSP.setLeftComponent(navigatorPanel);
        mainSP.setRightComponent(infoPanel);
View Full Code Here

    }

    private void initComponents() {

        setLayout(new BorderLayout());
        titledPanel = new JXTitledPanel() {

            /**
             * @inherited <p>
             *
             * Overridden to adjust to size requirements of invisible cards.
View Full Code Here

  public static JXTitledPanel addHeader(final String title, final String icon, final JComponent comp) {

    // visible fix
    comp.setBorder(BorderFactory.createEmptyBorder());

    final JXTitledPanel j = new JXTitledPanel(title, comp);
    if (icon != null) {
      j.setLeftDecoration(new JLabel(IconCache.get(icon)));
    }
    j.setBorder(BorderFactory.createEmptyBorder());

    return j;
  }
View Full Code Here

                final int record = key;
                final SortedMap<Integer, SpritesCacheManager<Integer, List<Rectangle>>> collisionsDef_map = (SortedMap<Integer, SpritesCacheManager<Integer, List<Rectangle>>>) model.getAttribute(ModelAnimBrowser.COLLISIONSDEF);
                final SortedMap<Integer, SpritesCacheManager<Integer, List<Rectangle>>> collisionsAtk_map = (SortedMap<Integer, SpritesCacheManager<Integer, List<Rectangle>>>) model.getAttribute(ModelAnimBrowser.COLLISIONSATK);
                JPanel ctrlPan = new JPanel(true);
                ctrlPan.setLayout(new BorderLayout());
                final JXTitledPanel titlePanel = new JXTitledPanel("animation box", ctrlPan);
                add(titlePanel);
                if ((n % width) == (width - 1)) {
                    ((GridBagLayout) getLayout()).setConstraints(titlePanel, c);
                }
                final ModelAnimBrowser comp = new ModelAnimBrowser(this, record, titlePanel, sw_state);
View Full Code Here

    /**
     * create components we need access to.
     *
     */
    private void initComponents() {
        descriptionContainer = new JXTitledPanel();
        descriptionPane = new JXEditorPane();
        mainContainer = new JXTitledPanel();
        mainList = new JXList();
    }
View Full Code Here

    }

    private void build() {
        build(descriptionContainer, descriptionPane, false, "Dashboard");
        JXTitledPanel listContainer = new JXTitledPanel();
        build(listContainer, mainList, true, "Descriptor");
        build(mainContainer, null, true, "Main");
        // this is a hack - components should have "nice" borders
        // by default
        descriptionPane.setBorder(descriptionBorder);
View Full Code Here

        getContentPane().setLayout(new java.awt.GridBagLayout());

        setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);
        jSplitPane1.setBorder(null);
        jSplitPane1.setDividerLocation(150);
        JXTitledPanel tp = new JXTitledPanel("Sources");
        tp.setContentContainer(jScrollPane1);
        jSplitPane1.setLeftComponent(tp);
        tp = new JXTitledPanel("Editor");
        tp.setContentContainer(jScrollPane2);
        jSplitPane1.setRightComponent(tp);
        gridBagConstraints = new java.awt.GridBagConstraints();
        gridBagConstraints.fill = java.awt.GridBagConstraints.BOTH;
        gridBagConstraints.weightx = 1.0;
        gridBagConstraints.weighty = 1.0;
View Full Code Here

        setPanelSize();
    }

  private void initComponents() {
    setLayout(new MigLayout("", "[91.00][grow]", "[72.00][grow]"));
    mainCont = new JXTitledPanel();
    {
      ImageIcon im = null;
      prop = SpringUtil.getProperties("config/inventory.properties");

      try {
        im = new ImageIcon(SpringUtil.getURL("images/"+prop.getProperty("inventory.banner.image")));
      } catch (IOException e) {
        e.printStackTrace();
      }

      lblBanner = new JLabel("");
      lblBanner.setHorizontalAlignment(SwingConstants.CENTER);
      //lblBanner.setBorder(border);
      lblBanner.setIcon(im);
      add(lblBanner, "cell 0 0,grow");
    }
    {
      tpDesc = new JXTitledPanel();
      tpDesc.getContentContainer().setLayout(new MigLayout("", "[17.00px][grow]", "[102px]"));
      {
        lblDesc = new JLabel("");
        tpDesc.getContentContainer().add(lblDesc, "cell 1 0,grow");
      }
View Full Code Here

TOP

Related Classes of org.jdesktop.swingx.JXTitledPanel

Copyright © 2018 www.massapicom. 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.