Package nextapp.echo2.app

Examples of nextapp.echo2.app.Extent


        assertNotNull(imageReference);
        assertTrue(imageReference instanceof ResourceImageReference);
        assertEquals("nextapp/echo2/test/componentxml/BackgroundImage.png",
                ((ResourceImageReference) imageReference).getResource());
        assertEquals(FillImage.REPEAT_HORIZONTAL, topLeftFillImage.getRepeat());
        assertEquals(new Extent(50), topLeftFillImage.getHorizontalOffset());
        assertEquals(new Extent(-30, Extent.PERCENT), topLeftFillImage.getVerticalOffset());
    }
View Full Code Here


        Label titleLabel = new Label("NextApp Echo2 Test Application");
        titleLabel.setStyleName("TitleLabel");
        verticalPane.add(titleLabel);
       
        horizontalPane = new SplitPane(SplitPane.ORIENTATION_HORIZONTAL, new Extent(215));
        horizontalPane.setStyleName("DefaultResizable");
        verticalPane.add(horizontalPane);
       
        Column controlsColumn = new Column();
        controlsColumn.setStyleName("ApplicationControlsColumn");
        controlsColumn.setCellSpacing(new Extent(5));
       
        horizontalPane.add(controlsColumn);
       
        testLaunchButtonsColumn = new Column();
        controlsColumn.add(testLaunchButtonsColumn);
View Full Code Here

        loginWindow.setTitle("Welcome to the NextApp Echo2 Test Application");
        loginWindow.setStyleName("WelcomePane");
        loginWindow.setClosable(false);
        add(loginWindow);
       
        SplitPane splitPane = new SplitPane(SplitPane.ORIENTATION_VERTICAL_BOTTOM_TOP, new Extent(32));
        loginWindow.add(splitPane);
       
        Row controlRow = new Row();
        controlRow.setStyleName("ControlPane");
        splitPane.add(controlRow);
       
        Button button = new Button("Continue", Styles.ICON_24_YES);
        button.setRenderId("WelcomePaneEnter");
        button.setId("EnterTestApplication");
        button.setStyleName("ControlPane.Button");
        button.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent e) {
                InteractiveApp.getApp().displayTestPane();
            }
        });
        controlRow.add(button);
       
        Column infoColumn = new Column();
        infoColumn.setInsets(new Insets(20, 5));
        infoColumn.setCellSpacing(new Extent(10));
        splitPane.add(infoColumn);
       
        label = new Label("Please read the following before using the test application:");
        label.setFont(new Font(null, Font.BOLD, null));
        infoColumn.add(label);
View Full Code Here

     * fixed or percentile units.
     *
     * @param newValue the new width
     */
    public void setWidth(Extent newValue) {
        Extent oldValue = width;
        width = newValue;
        pcs.firePropertyChange(WIDTH_CHANGED_PROPERTY, oldValue, newValue);
    }
View Full Code Here

     * Test primary constructor.
     */
    public void testPrimaryConstructor() {
        TextField textField = new TextField(new StringDocument(), "text", 30);
        assertEquals("text", textField.getDocument().getText());
        assertEquals(new Extent(30, Extent.EX), textField.getWidth());
    }
View Full Code Here

                public void actionPerformed(ActionEvent e) {
                    if (testPane.getComponentCount() < paneNumber + 1) {
                        return;
                    }
                    SplitPaneLayoutData splitPaneLayoutData = getLayoutData(paneNumber);
                    splitPaneLayoutData.setMinimumSize(new Extent(30));
                    testPane.getComponent(paneNumber).setLayoutData(splitPaneLayoutData);
                }
            });
            addButton("MAX Size = Default", new ActionListener() {
                public void actionPerformed(ActionEvent e) {
                    if (testPane.getComponentCount() < paneNumber + 1) {
                        return;
                    }
                    SplitPaneLayoutData splitPaneLayoutData = getLayoutData(paneNumber);
                    splitPaneLayoutData.setMaximumSize(null);
                    testPane.getComponent(paneNumber).setLayoutData(splitPaneLayoutData);
                }
            });
            addButton("MAX Size = 120", new ActionListener() {
                public void actionPerformed(ActionEvent e) {
                    if (testPane.getComponentCount() < paneNumber + 1) {
                        return;
                    }
                    SplitPaneLayoutData splitPaneLayoutData = getLayoutData(paneNumber);
                    splitPaneLayoutData.setMaximumSize(new Extent(120));
                    testPane.getComponent(paneNumber).setLayoutData(splitPaneLayoutData);
                }
            });
            addButton("Toggle Background Image", new ActionListener() {
                public void actionPerformed(ActionEvent e) {
View Full Code Here

public class VisibilityTest extends SplitPane {

    final Column testColumn;
   
    public VisibilityTest() {
        super(SplitPane.ORIENTATION_HORIZONTAL, new Extent(250, Extent.PX));
        setStyleName("DefaultResizable");
       
        ButtonColumn controlsColumn = new ButtonColumn();
        controlsColumn.setStyleName("TestControlsColumn");
        add(controlsColumn);

        controlsColumn.addButton("Visible = True", new ActionListener() {
            public void actionPerformed(ActionEvent e) {
                adjustVisibility(true);
            }
        });
        controlsColumn.addButton("Visible = False", new ActionListener() {
            public void actionPerformed(ActionEvent e) {
                adjustVisibility(false);
            }
        });

        testColumn = new Column();
        testColumn.setCellSpacing(new Extent(5));
        SplitPaneLayoutData splitPaneLayoutData = new SplitPaneLayoutData();
        splitPaneLayoutData.setInsets(new Insets(10));
        testColumn.setLayoutData(splitPaneLayoutData);
        add(testColumn);
       
View Full Code Here

    }

    public ContainerContextTest() {
        super();
       
        setCellSpacing(new Extent(10));
       
        SplitPaneLayoutData splitPaneLayoutData = new SplitPaneLayoutData();
        splitPaneLayoutData.setInsets(new Insets(10));
        setLayoutData(splitPaneLayoutData);
       
View Full Code Here

            String resource = resourceImageReferenceElement.getAttribute("resource");
            String contentType = null;
            if (resourceImageReferenceElement.hasAttribute("content-type")) {
                contentType = resourceImageReferenceElement.getAttribute("content-type");
            }
            Extent width = null;
            if (resourceImageReferenceElement.hasAttribute("width")) {
                width = ExtentPeer.toExtent(resourceImageReferenceElement.getAttribute("width"));
            }
            Extent height = null;
            if (resourceImageReferenceElement.hasAttribute("height")) {
                height = ExtentPeer.toExtent(resourceImageReferenceElement.getAttribute("height"));
            }
            return new ResourceImageReference(resource, contentType, width, height);
        }
View Full Code Here

     */
    public MessagePane() {
        super();
        setVisible(false);
       
        setCellSpacing(new Extent(10));
        setInsets(new Insets(3));
       
        Grid headerGrid = new Grid();
        headerGrid.setStyleName("Message.HeaderGrid");
        add(headerGrid);
View Full Code Here

TOP

Related Classes of nextapp.echo2.app.Extent

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.