Package com.alee.laf.scroll

Examples of com.alee.laf.scroll.WebScrollPane


                            {
                                final String license = FileUtils.readToString ( structure.getEntryInputStream ( child ) );
                                final WebPopup licensePopup = new WebPopup ();
                                final WebTextArea textArea = new WebTextArea ( license );
                                textArea.setEditable ( false );
                                licensePopup.add ( new WebScrollPane ( textArea, false ) );
                                licensePopup.showPopupAsModal ( fileLink, true, true );
                                HotkeyManager.registerHotkey ( textArea, Hotkey.ESCAPE, new HotkeyRunnable ()
                                {
                                    @Override
                                    public void run ( final KeyEvent e )
                                    {
                                        licensePopup.hidePopup ();
                                    }
                                } );
                            }
                            catch ( final IOException e )
                            {
                                Log.error ( this, e );
                            }
                        }
                    } );
                    final WebLabel licenseLabel = new WebLabel ();
                    licenseLabel.setLanguage ( "weblaf.info.libraries.license" );
                    final GroupPanel fileLinkPanel = new GroupPanel ( 5, licenseLabel, fileLink );

                    // Library site URL
                    final WebLinkLabel urlLink = new WebLinkLabel ( url );
                    urlLink.setLink ( url, false );
                    final WebLabel siteLabel = new WebLabel ();
                    siteLabel.setLanguage ( "weblaf.info.libraries.site" );
                    final GroupPanel urlLinkPanel = new GroupPanel ( 5, siteLabel, urlLink );

                    // Single library panel
                    final GroupPanel libraryPanel = new GroupPanel ( false, nameLabel, fileLinkPanel, urlLinkPanel );
                    libraryPanel.setUndecorated ( false );
                    libraryPanel.setMargin ( 5 );
                    libraryPanel.setPreferredWidth ( 0 );
                    librariesPanel.add ( libraryPanel );
                }
            }

            // Libraries panel scroll
            final WebScrollPane scrollPane = new WebScrollPane ( librariesPanel, false );
            scrollPane.setPreferredHeight ( 0 );
            return scrollPane;
        }
        catch ( final Throwable e )
        {
            Log.error ( this, e );
View Full Code Here


                {
                    propertiesTable.addRowSelectionInterval ( s, s );
                }
            }
        } );
        return new WebScrollPane ( propertiesTable, false );
    }
View Full Code Here

     *
     * @return new scroll pane with fixed preferred size that fits file list settings
     */
    public WebScrollPane createScrollView ()
    {
        return new WebScrollPane ( WebFileList.this )
        {
            @Override
            public Dimension getPreferredSize ()
            {
                final Dimension ps = super.getPreferredSize ();
View Full Code Here

                        updateHistoryState ( historyList.getSelectedIndex () );
                        historyPopup.setVisible ( false );
                    }
                } );

                final WebScrollPane scrollPane = new WebScrollPane ( historyList, false, false );
                scrollPane.setOpaque ( false );
                scrollPane.getViewport ().setOpaque ( false );
                scrollPane.setShadeWidth ( 0 );

                final WebScrollBar vsb = scrollPane.getWebVerticalScrollBar ();
                vsb.setMargin ( WebComboBoxStyle.scrollBarMargin );
                vsb.setPaintButtons ( WebComboBoxStyle.scrollBarButtonsVisible );
                vsb.setPaintTrack ( WebComboBoxStyle.scrollBarTrackVisible );

                LafUtils.setScrollBarStyleId ( scrollPane, "combo-box" );
View Full Code Here

                }
            }
        };
        fileTree.addTreeSelectionListener ( fileTreeListener );

        treeScroll = new WebScrollPane ( fileTree, true );
        treeScroll.setPreferredSize ( new Dimension ( 160, 1 ) );
    }
View Full Code Here

            {
                // Do nothing
            }
        } );

        fileTableScroll = new WebScrollPane ( fileTable, true );
        fileTableScroll.getViewport ().setOpaque ( true );
        fileTableScroll.getViewport ().setBackground ( Color.WHITE );
        fileTableScroll.setHorizontalScrollBarPolicy ( WebScrollPane.HORIZONTAL_SCROLLBAR_NEVER );
        fileTableScroll.setVerticalScrollBarPolicy ( WebScrollPane.VERTICAL_SCROLLBAR_ALWAYS );
    }
View Full Code Here

        deleteFilesPanel.setBackground ( Color.WHITE );
        for ( final File file : files )
        {
            deleteFilesPanel.add ( new WebLabel ( file.getName (), FileUtils.getFileIcon ( file ), WebLabel.LEFT ) );
        }
        final WebScrollPane scroll = new WebScrollPane ( deleteFilesPanel )
        {
            @Override
            public Dimension getPreferredSize ()
            {
                final Dimension ps = super.getPreferredSize ();
View Full Code Here

            {
                return fileTree.getSelectionCount () > 0 ? new StringSelection ( fileTree.getSelectedFile ().getAbsolutePath () ) : null;
            }
        } );

        final WebScrollPane filesView = new WebScrollPane ( fileTree, false );
        filesView.setMinimumWidth ( 200 );
        filesView.setPreferredHeight ( 0 );
        //        filesView.setBorder ( BorderFactory.createMatteBorder ( 0, 0, 0, 1, WebToolBarStyle.borderColor ) );

        final WebSplitPane previewSplit = new WebSplitPane ( WebSplitPane.HORIZONTAL_SPLIT );
        previewSplit.setLeftComponent ( createEditorPanel () );
        previewSplit.setRightComponent ( createPreviewPanel () );
View Full Code Here

TOP

Related Classes of com.alee.laf.scroll.WebScrollPane

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.