Package org.apache.pivot.wtk.ScrollPane

Examples of org.apache.pivot.wtk.ScrollPane.ScrollBarPolicy


            Component columnHeader = scrollPane.getColumnHeader();
            if (columnHeader != null) {
                preferredColumnHeaderHeight = columnHeader.getPreferredHeight(-1);
            }

            ScrollBarPolicy verticalPolicy = scrollPane.getVerticalScrollBarPolicy();

            if (verticalPolicy != ScrollBarPolicy.FILL) {
                // Get the unconstrained preferred size of the view
                Dimensions preferredViewSize = view.getPreferredSize();
View Full Code Here


            Component columnHeader = scrollPane.getColumnHeader();
            if (columnHeader != null) {
                preferredColumnHeaderHeight = columnHeader.getPreferredHeight(-1);
            }

            ScrollBarPolicy horizontalPolicy = scrollPane.getHorizontalScrollBarPolicy();

            if (horizontalPolicy != ScrollBarPolicy.FILL) {
                // Get the unconstrained preferred size of the view
                Dimensions preferredViewSize = view.getPreferredSize();
View Full Code Here

    @Override
    public void layout() {
        ScrollPane scrollPane = (ScrollPane)getComponent();

        ScrollBarPolicy horizontalPolicy = scrollPane.getHorizontalScrollBarPolicy();
        ScrollBarPolicy verticalPolicy = scrollPane.getVerticalScrollBarPolicy();

        boolean fillWidthToCapacity = false;
        boolean fillHeightToCapacity = false;

        // The FILL_TO_CAPACITY policy means that we try to use AUTO, and only
View Full Code Here

        horizontalScrollBarPolicyGroup.getButtonGroupListeners().add(new ButtonGroupListener.Adapter() {
            @Override
            public void selectionChanged(ButtonGroup buttonGroup, Button previousSelection) {
                Button button = buttonGroup.getSelection();

                ScrollBarPolicy horizontalScrollBarPolicy = null;

                if (button == horizontalAutoButton) {
                    horizontalScrollBarPolicy = ScrollBarPolicy.AUTO;
                } else if (button == horizontalFillButton) {
                    horizontalScrollBarPolicy = ScrollBarPolicy.FILL;
                } else if (button == horizontalFillToCapacityButton) {
                    horizontalScrollBarPolicy = ScrollBarPolicy.FILL_TO_CAPACITY;
                } else if (button == horizontalNeverButton) {
                    horizontalScrollBarPolicy = ScrollBarPolicy.NEVER;
                } else if (button == horizontalAlwaysButton) {
                    horizontalScrollBarPolicy = ScrollBarPolicy.ALWAYS;
                }

                if (horizontalScrollBarPolicy != null) {
                    contentScrollPane.setHorizontalScrollBarPolicy(horizontalScrollBarPolicy);
                }
            }
        });

        verticalScrollBarPolicyGroup.getButtonGroupListeners().add(new ButtonGroupListener.Adapter() {
            @Override
            public void selectionChanged(ButtonGroup buttonGroup, Button previousSelection) {
                Button button = buttonGroup.getSelection();

                ScrollBarPolicy verticalScrollBarPolicy = null;

                if (button == verticalAutoButton) {
                    verticalScrollBarPolicy = ScrollBarPolicy.AUTO;
                } else if (button == verticalFillButton) {
                    verticalScrollBarPolicy = ScrollBarPolicy.FILL;
View Full Code Here

            Component columnHeader = scrollPane.getColumnHeader();
            if (columnHeader != null) {
                preferredColumnHeaderHeight = columnHeader.getPreferredHeight(-1);
            }

            ScrollBarPolicy verticalPolicy = scrollPane.getVerticalScrollBarPolicy();

            if (verticalPolicy != ScrollBarPolicy.FILL) {
                // Get the unconstrained preferred size of the view
                Dimensions preferredViewSize = view.getPreferredSize();
View Full Code Here

            Component columnHeader = scrollPane.getColumnHeader();
            if (columnHeader != null) {
                preferredColumnHeaderHeight = columnHeader.getPreferredHeight(-1);
            }

            ScrollBarPolicy horizontalPolicy = scrollPane.getHorizontalScrollBarPolicy();

            if (horizontalPolicy != ScrollBarPolicy.FILL) {
                // Get the unconstrained preferred size of the view
                Dimensions preferredViewSize = view.getPreferredSize();
View Full Code Here

    @Override
    public void layout() {
        ScrollPane scrollPane = (ScrollPane)getComponent();

        ScrollBarPolicy horizontalPolicy = scrollPane.getHorizontalScrollBarPolicy();
        ScrollBarPolicy verticalPolicy = scrollPane.getVerticalScrollBarPolicy();

        boolean fillWidthToCapacity = false;
        boolean fillHeightToCapacity = false;

        // The FILL_TO_CAPACITY policy means that we try to use AUTO, and only
View Full Code Here

        horizontalScrollBarPolicyGroup.getButtonGroupListeners().add(new ButtonGroupListener.Adapter() {
            @Override
            public void selectionChanged(ButtonGroup buttonGroup, Button previousSelection) {
                Button button = buttonGroup.getSelection();

                ScrollBarPolicy horizontalScrollBarPolicy = null;

                if (button == horizontalAutoButton) {
                    horizontalScrollBarPolicy = ScrollBarPolicy.AUTO;
                } else if (button == horizontalFillButton) {
                    horizontalScrollBarPolicy = ScrollBarPolicy.FILL;
                } else if (button == horizontalFillToCapacityButton) {
                    horizontalScrollBarPolicy = ScrollBarPolicy.FILL_TO_CAPACITY;
                } else if (button == horizontalNeverButton) {
                    horizontalScrollBarPolicy = ScrollBarPolicy.NEVER;
                } else if (button == horizontalAlwaysButton) {
                    horizontalScrollBarPolicy = ScrollBarPolicy.ALWAYS;
                }

                if (horizontalScrollBarPolicy != null) {
                    contentScrollPane.setHorizontalScrollBarPolicy(horizontalScrollBarPolicy);
                }
            }
        });

        verticalScrollBarPolicyGroup.getButtonGroupListeners().add(new ButtonGroupListener.Adapter() {
            @Override
            public void selectionChanged(ButtonGroup buttonGroup, Button previousSelection) {
                Button button = buttonGroup.getSelection();

                ScrollBarPolicy verticalScrollBarPolicy = null;

                if (button == verticalAutoButton) {
                    verticalScrollBarPolicy = ScrollBarPolicy.AUTO;
                } else if (button == verticalFillButton) {
                    verticalScrollBarPolicy = ScrollBarPolicy.FILL;
View Full Code Here

            Component columnHeader = scrollPane.getColumnHeader();
            if (columnHeader != null) {
                preferredColumnHeaderHeight = columnHeader.getPreferredHeight(-1);
            }

            ScrollBarPolicy verticalPolicy = scrollPane.getVerticalScrollBarPolicy();

            if (verticalPolicy != ScrollBarPolicy.FILL) {
                // Get the unconstrained preferred size of the view
                Dimensions preferredViewSize = view.getPreferredSize();
View Full Code Here

            Component columnHeader = scrollPane.getColumnHeader();
            if (columnHeader != null) {
                preferredColumnHeaderHeight = columnHeader.getPreferredHeight(-1);
            }

            ScrollBarPolicy horizontalPolicy = scrollPane.getHorizontalScrollBarPolicy();

            if (horizontalPolicy != ScrollBarPolicy.FILL) {
                // Get the unconstrained preferred size of the view
                Dimensions preferredViewSize = view.getPreferredSize();
View Full Code Here

TOP

Related Classes of org.apache.pivot.wtk.ScrollPane.ScrollBarPolicy

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.