Package com.alee.laf.combobox

Examples of com.alee.laf.combobox.WebComboBox


     * {@inheritDoc}
     */
    @Override
    public Component getPreview ( final WebLookAndFeelDemo owner )
    {
        type = new WebComboBox ( DynamicMenuType.values (), DynamicMenuType.shutter );
        final GroupPanel tg = new GroupPanel ( 5, new WebLabel ( "Display animation:" ), type );

        hidingType = new WebComboBox ( DynamicMenuType.values (), DynamicMenuType.star );
        final GroupPanel htg = new GroupPanel ( 5, new WebLabel ( "Hide animation:" ), hidingType );

        radius = new WebTextField ( new IntTextDocument (), "70", 4 );
        final GroupPanel rg = new GroupPanel ( 5, new WebLabel ( "Menu radius:" ), radius );

View Full Code Here


        // Panel with focusable combobox
        final WebPanel panel3 = new WebPanel ( true );
        panel3.setPaintFocus ( true );
        panel3.setMargin ( 10 );
        panel3.add ( new WebLabel ( "Some combo:", WebLabel.CENTER ), BorderLayout.NORTH );
        panel3.add ( new WebComboBox ( new String[]{ "ComboBox" } ), BorderLayout.CENTER );

        // Equalizing panel widths
        SwingUtils.equalizeComponentsWidths ( panel1, panel2, panel3 );

        return new GroupPanel ( 4, panel1, panel2, panel3 );
View Full Code Here

    @Override
    public Component getPreview ( WebLookAndFeelDemo owner )
    {
        String[] items = { "Edit me 1", "Edit me 2", "Edit me 3", "Edit me 4", "Edit me 5" };
        WebComboBox comboBox = new WebComboBox ( items );
        comboBox.setEditable ( true );
        comboBox.setEditorColumns ( 6 );
        return new GroupPanel ( comboBox );
    }
View Full Code Here

    }

    @Override
    public Component getPreview ( final WebLookAndFeelDemo owner )
    {
        final WebComboBox styled = new WebComboBox ( GlobalConstants.DEFAULT_FILTERS.toArray () );
        styled.setSelectedIndex ( 0 );
        styled.setRenderer ( new WebComboBoxCellRenderer ()
        {
            @Override
            public Component getListCellRendererComponent ( final JList list, final Object value, final int index, final boolean isSelected,
                                                            final boolean cellHasFocus )
            {
View Full Code Here

    @Override
    public Component getPreview ( WebLookAndFeelDemo owner )
    {
        String[] items = { "Element 1", "Element 2", "Element 3", "Element 4", "Element 5" };
        WebComboBox comboBox = new WebComboBox ( items );
        return new GroupPanel ( comboBox );
    }
View Full Code Here

        // Popup invoker button
        final WebButton showPopup = new WebButton ( "Show simple popup" );

        // Popup style chooser
        final WebComboBox popupStyle = new WebComboBox ( PopupStyle.values () );
        popupStyle.setSelectedItem ( PopupManager.getDefaultPopupStyle () );
        popupStyle.setRenderer ( new WebComboBoxCellRenderer ()
        {
            @Override
            public Component getListCellRendererComponent ( final JList list, final Object value, final int index, final boolean isSelected,
                                                            final boolean cellHasFocus )
            {
                return super.getListCellRendererComponent ( list, "Style: " + value, index, isSelected, cellHasFocus );
            }
        } );
        popupStyle.addActionListener ( new ActionListener ()
        {
            @Override
            public void actionPerformed ( final ActionEvent e )
            {
                popup.setPopupStyle ( ( PopupStyle ) popupStyle.getSelectedItem () );
                popup.packPopup ();
            }
        } );

        // Popup show/hide action
View Full Code Here

                                    ExampleFrame.this.pack ();
                                }
                            } );
                        }
                    };
                    add ( new GroupPanel ( 10, showMenuBar, new WebComboBox ( new String[]{ "undecorated", "attached", "standalone" } )
                    {
                        {
                            addActionListener ( new ActionListener ()
                            {
                                @Override
View Full Code Here

        final WebPanel popupContent = new WebPanel ( new VerticalFlowLayout ( 5, 5 ) );
        popupContent.setMargin ( 5 );
        popupContent.setOpaque ( false );
        wbp.setContent ( popupContent );

        theme = new WebComboBox ( EditorTheme.values () );
        theme.registerSettings ( SETTINGS_PREFIX + "theme", 0 );
        theme.setRenderer ( new WebComboBoxCellRenderer ()
        {
            @Override
            public Component getListCellRendererComponent ( final JList list, final Object value, final int index, final boolean isSelected,
View Full Code Here

        //

        final String[] comboData =
                new String[]{ "Mikle Garin", "Lilly Stewart", "Alex Jackson", "Joshua Martin", "Mark Einsberg", "Joe Phillips",
                        "Alice Manson", "Nancy Drew", "John Linderman", "Trisha Mathew" };
        final WebComboBox cb = new WebComboBox ( comboData );
        addViewComponent ( "JScrollBar in JComboBox", cb, cb, true );

        //

        final WebPopupMenu popupMenu = new WebPopupMenu ();
View Full Code Here

        } );

        selectedFilesPanel = new WebPanel ( chooserType == FileChooserType.save ? selectedFilesTextField : selectedFilesViewField );
        southPanel.add ( selectedFilesPanel, ToolbarLayout.FILL );

        fileFilters = new WebComboBox ();
        fileFilters.setRenderer ( new DefaultFileFilterListCellRenderer () );
        fileFilters.addActionListener ( new ActionListener ()
        {
            @Override
            public void actionPerformed ( final ActionEvent e )
View Full Code Here

TOP

Related Classes of com.alee.laf.combobox.WebComboBox

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.