View element that knows how to hide and show stacked items depending on available space.
상속: ComponentFactory.Krypton.Toolkit.ViewLayoutScrollViewport
예제 #1
0
        /// <summary>
        /// Creates and returns the view element that laysout the main client area.
        /// </summary>
        /// <returns></returns>
        protected override ViewBase CreateMainLayout()
        {
            // Layout contains all the stack elements
            _viewLayout = new ViewLayoutDocker();
            _viewLayout.PreferredSizeAll = true;

            // Cache the border edge palette to use
            PaletteBorderEdge buttonEdgePalette = (Navigator.Enabled ? Navigator.StateNormal.BorderEdge :
                                                   Navigator.StateDisabled.BorderEdge);

            // Create the scrolling viewport and pass in the _viewLayout as the content to scroll
            _viewOutlook = new ViewLayoutOutlookFull(this, Navigator, _viewLayout, buttonEdgePalette, null, PaletteMetricPadding.None,
                                                     PaletteMetricInt.None, VisualOrientation.Top, RelativePositionAlign.Near, false,
                                                     (Navigator.Outlook.Orientation == Orientation.Vertical), NeedPaintDelegate);

            // Reparent the child panel that contains the actual pages, into the child control
            _viewOutlook.MakeParent(Navigator.ChildPanel);

            return(_viewOutlook);
        }
예제 #2
0
        /// <summary>
        /// Creates and returns the view element that laysout the main client area.
        /// </summary>
        /// <returns></returns>
        protected override ViewBase CreateMainLayout()
        {
            // Layout contains all the stack elements
            _viewLayout = new ViewLayoutDocker();
            _viewLayout.PreferredSizeAll = true;

            // Cache the border edge palette to use
            PaletteBorderEdge buttonEdgePalette = (Navigator.Enabled ? Navigator.StateNormal.BorderEdge :
                                                                       Navigator.StateDisabled.BorderEdge);

            // Create the scrolling viewport and pass in the _viewLayout as the content to scroll
            _viewOutlook = new ViewLayoutOutlookFull(this, Navigator, _viewLayout, buttonEdgePalette, null, PaletteMetricPadding.None,
                                                     PaletteMetricInt.None, VisualOrientation.Top, RelativePositionAlign.Near, false,
                                                     (Navigator.Outlook.Orientation == Orientation.Vertical), NeedPaintDelegate);

            // Reparent the child panel that contains the actual pages, into the child control
            _viewOutlook.MakeParent(Navigator.ChildPanel);

            return _viewOutlook;
        }