Package com.alee.laf.text

Examples of com.alee.laf.text.WebPasswordField


        // Text field
        final WebTextField textField = new WebTextField ( "Styled text field" );
        textField.setPainter ( npfbp );

        // Password field
        final WebPasswordField passwordField = new WebPasswordField ( "Styled password field" );
        passwordField.setPainter ( npfbp );

        // Field with leading component
        final WebTextField componentField = new WebTextField ( "Styled text field with leading component" );
        componentField.setLeadingComponent ( new WebImage ( loadIcon ( "search.png" ) ) );
        componentField.setFieldMargin ( 0, 6, 0, 0 );
View Full Code Here


    @Override
    public Component getPreview ( WebLookAndFeelDemo owner )
    {
        // Simple password field
        WebPasswordField pf1 = new WebPasswordField ( "password", 15 );

        // Non-editable password field
        WebPasswordField pf2 = new WebPasswordField ( "password", 15 );
        pf2.setEditable ( false );

        return new GroupPanel ( false, pf1, pf2 );
    }
View Full Code Here

        final WebTextField textField = new WebTextField ( 15 );
        textField.setInputPrompt ( "Enter text..." );
        textField.setInputPromptFont ( textField.getFont ().deriveFont ( Font.ITALIC ) );

        // Password field input prompt
        final WebPasswordField passwordField = new WebPasswordField ( 15 );
        passwordField.setInputPrompt ( "Enter pass..." );
        passwordField.setHideInputPromptOnFocus ( false );

        // Date field input prompt
        final WebDateField dateField = new WebDateField ();
        dateField.setInputPrompt ( "Enter date..." );
        dateField.setInputPromptPosition ( SwingConstants.CENTER );
View Full Code Here

        WebTextField trailing = new WebTextField ( "Trailing", 10 );
        trailing.setMargin ( 0, 0, 0, 2 );
        trailing.setTrailingComponent ( new WebImage ( loadIcon ( "search.png" ) ) );

        // Password field with image as leading component
        WebPasswordField leading2 = new WebPasswordField ( "Leading", 10 );
        leading2.setLeadingComponent ( new WebImage ( loadIcon ( "key.png" ) ) );

        // Password field with image as trailing component
        WebPasswordField trailing2 = new WebPasswordField ( "Trailing", 10 );
        trailing2.setTrailingComponent ( new WebImage ( loadIcon ( "key.png" ) ) );

        // Text field with image as leading and trailing components
        WebTextField both = new WebTextField ( "Both", 10 );
        both.setHorizontalAlignment ( WebTextField.CENTER );
        both.setMargin ( 0, 2, 0, 2 );
View Full Code Here

        final WebTextField textField = new WebTextField ( "Styled text field" );
        textField.setPainter ( painter1 );
        textField.setForeground ( Color.WHITE );

        // Password field
        final WebPasswordField passwordField = new WebPasswordField ( "Styled password field" );
        passwordField.setPainter ( painter1 );
        passwordField.setForeground ( Color.WHITE );

        // Field with trailing component
        final WebTextField componentField = new WebTextField ( "Styled text field with leading component" );
        componentField.setFieldMargin ( 0, 0, 0, 6 );
        componentField.setPainter ( NinePatchUtils.loadNinePatchStatePainter ( getResource ( "sfield.xml" ) ) );
View Full Code Here

            content.add ( new WebLabel ( "Login", WebLabel.TRAILING ), "0,0" );
            content.add ( new WebTextField ( 15 ), "1,0" );

            content.add ( new WebLabel ( "Password", WebLabel.TRAILING ), "0,1" );
            content.add ( new WebPasswordField ( 15 ), "1,1" );

            WebButton login = new WebButton ( "Login" );
            WebButton cancel = new WebButton ( "Cancel" );
            ActionListener listener = new ActionListener ()
            {
View Full Code Here

            final WebLabel passLabel = new WebLabel ();
            passLabel.setLanguage ( "weblaf.proxy.auth.pass" );
            passLabel.setHorizontalAlignment ( WebLabel.RIGHT );
            authPanel.add ( passLabel, "0,3" );

            passwordField = new WebPasswordField ( 12 );
            authPanel.add ( passwordField, "1,3" );


            HotkeyManager.registerHotkey ( authPanel, authPanel, Hotkey.ENTER, new HotkeyRunnable ()
            {
View Full Code Here

TOP

Related Classes of com.alee.laf.text.WebPasswordField

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.