HypernovaDesktop Components · docs
Binarymission
WPF › Virtualizing Wrap Panel › BinaryVirtualizingWrapPanel

BinaryVirtualizingWrapPanel

class.NET 6 / 8 / 10.NET Framework 4.8Binarymission.WPF.Controls.Panels

A class that behaves like a WrapPanel control, with additional ability out-of-the-box scrolling and being able to automatically virtualize/realize the content.

public partial class BinaryVirtualizingWrapPanel : VirtualizingPanel, IScrollInfo, ISupportTransactionalUpdates

Inherits from / implements: VirtualizingPanel, IScrollInfo, ISupportTransactionalUpdates

Remarks

How this control works. The panel is its own scroll owner: it implements IScrollInfo, so the ScrollViewer around its items control asks it for the extent and the offsets instead of measuring everything. In MeasureOverride it works out, from the offset and the viewport, which items can be seen (plus a margin of ReRenderVisibilityRangeMaxCount either side), asks the items control's generator for containers for those only, and removes the containers that have gone out of range. Everything else exists only as data. Two layouts. With every item the size of ItemDimension (the default), a line holds a fixed number of cells and an item's position is arithmetic on its index - which is what makes scrolling straight to any index cheap (DesiredChildIndexToScrollTo). ItemPositioningMode decides how many cells a line takes. With IsVariableItemSizeEnabled or IsDataSourceGrouped, the flow layout takes over: items wrap at their own measured size, and a size not yet measured is estimated as ItemDimension. Grouping. The panel does not see WPF's group items. Bind the items control to a VirtualizingCollectionView , which presents each group's header as a row of the flat list, and set IsDataSourceGrouped; the panel then starts a new line for each header and virtualises the headers with the items. Margins. The panel sets its own Margin from RendertimeMargin (and IsExtraMarginAtStartupRequired) when it joins the visual tree; set those rather than Margin . It needs a bounded viewport. Virtualisation is only possible when the items control is given a finite size along the scrolling direction. Inside a StackPanel (or any parent that measures its children with unlimited space that way), there is no viewport to fill; give the items control a height or width, or put it in a Grid or DockPanel. Virtualisation applies to items that come from data binding.

Members at a glance

BinaryVirtualizingWrapPanelInitializes a new instance of the BinaryVirtualizingWrapPanel class.
AutoUpdateViewportOnDetectingTransactionalUpdatesToDataSourceGets or sets a value indicating whether [automatic update viewport on detecting transactional updates to data source].
CanHorizontallyScrollGets or sets a value that indicates whether scrolling on the horizontal axis is possible.
CanVerticallyScrollGets or sets a value that indicates whether scrolling on the vertical axis is possible.
CustomExtraSpacingBetweenGroupHeaderRowAndDataItemRowGets or sets a custom extra spacing to render between the group header row and the data item row.
CustomExtraSpacingBetweenGroupRenderingCompletionAndGroupHeaderRowRenderingBeginsGets or sets the custom extra spacing to render between where a group rendering completes and the next group header row rendering begins.
DesiredChildIndexScrollingIsDataContextSynchronizedGets or sets whether the control's DesiredChildIndexToScrollTo is set to be synchronized with the current item in the data context.
DesiredChildIndexToScrollToGets or sets the desired child index to scroll to.
ExtentHeightGets the vertical size of the extent.
ExtentWidthGets the horizontal size of the extent.
GroupHeaderItemCustomHeightGets or sets a custom height when rendering the group header using a custom Datatemplate.
GroupVirtualizationModeGets or sets the virtualization mode when grouping is enabled on the data source.
HorizontalOffsetGets the horizontal offset of the scrolled content.
IsAnimationEnabledGets or sets a value indicating whether this instance is animation enabled.
IsAnimationEnabledWhenScrollToASpecificChildIndexGets or sets a value indicating whether this instance is animation enabled for deterministically scrolling to a specific child index.
IsDataSourceGroupedGets or sets whether the data source of the items control is set up with grouping information.
IsDynamicConstructionCapabilityEnabledGets or sets a value indicating whether this instance is dynamic construction capability enabled.
IsExtraMarginAtStartupRequiredGets or sets a value indicating whether this instance is extra margin at startup required.
IsRenderItemDimensionHeightSpacingBetweenGroupHeaderAndDataItemRowEnabledGets or sets whether to render spacing between the group header and data item row.
IsTrimExtraLinkbreakForLeadingRowWithOneChildEnabledGets or sets whether to automatically trim the extra leading space between header and row data if there is only one child per row that is being rendered.
IsVariableItemSizeEnabledGets or sets a value indicating whether items may each be a different size.
ItemDimensionGets or sets the size of the content items.
ItemPositioningModeGets or sets the item positioning mode.
OrientationGets or sets the orientation for laying-out the children items.
PanelAnimationEffectGets or sets the panel animation effect.
ReRenderVisibilityRangeMaxCountGets or sets the maximum number of items that the control has to prepare when about to re-render the viewport due to a trigger to the view invalidation.
RendertimeMarginGets or sets the rendertime margin.
ScrollOwnerGets or sets a ScrollViewer element that controls scrolling behavior.
ShouldAdjustRightHorizontalAlignmentSetupConsideringScrollInfoGets or sets a value indicating whether the control should adjust right horizontal alignment margin setup considering the host ItemsControl scrollbar visual.
ShouldAutoAdjustParentItemsControlInternalPaddingGets or sets whether the component should automatically adjust the internal padding setup in the Control styles of the owner ItemsControl.
ShouldRecomputeViewportExtentSpacingUponAlignmentGets or sets a value indicating whether the control should recompute the viewport vis-a-vis extent spacing upon alignment.
ShouldRenderExtraLineBeforeHeaderGets or sets a value indicating whether the control should render an extra line before header in standalone line rendering mode.
ShouldRenderItemHeightSpacingAfterAGroupHasBeenRenderedGets or sets a value indicating whether the control should render an item height worth of spacing after a group has been rendered.
ShouldShareUnusedSpaceEquallyOnHorizontalAlignmentGets or sets a value indicating whether the control should share unused space equally on horizontal alignment.
ShouldUseRenderTimeMarginValuesWhenRecomputingViewPortExtentSpacingAdjustmentGets or sets a value indicating whether the control should use the value set for RendertimeMargin relevant values when recomputing view port extent spacing adjustment for the property ShouldRecomputeViewportExtentSpacingUponAlignment.
VerticalOffsetGets the vertical offset of the scrolled content.
ViewportHeightGets the vertical size of the viewport for this content.
ViewportWidthGets the horizontal size of the viewport for this content.
VirtualizationSchemeOptionGets or sets the virtualization scheme.
VirtualizationSchemeWhenScrollingToASpecificChildIndexGets or sets the VirtualizationScheme to use, when scrolling to a specific child.
ArrangeOverrideWhen overridden in a derived class, positions child elements and determines a size for a FrameworkElement derived class.
LineDownScrolls down within content by one logical unit.
LineLeftScrolls left within content by one logical unit.
LineRightScrolls right within content by one logical unit.
LineUpScrolls up within content by one logical unit.
MakeVisibleThis method is not available in the Virtualization scenario.
MeasureOverrideWhen overridden in a derived class, measures the size in layout required for child elements and determines a size for the FrameworkElement-derived class.
MouseWheelDownScrolls down within content after a user clicks the wheel button on a mouse.
MouseWheelLeftScrolls left within content after a user clicks the wheel button on a mouse.
MouseWheelRightScrolls right within content after a user clicks the wheel button on a mouse.
MouseWheelUpScrolls up within content after a user clicks the wheel button on a mouse.
OnIsItemsHostChangedMeasures again when the panel becomes an items host, which on a page's first show happens after the panel's first measure pass.
OnItemsChangedCalled when the Items collection that is associated with the ItemsControl for this Panel changes.
OnKeyDownInvoked when an unhandled KeyDown attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event.
OnRenderSizeChangedRaises the SizeChanged event, using the specified information as part of the eventual event data.
PageDownScrolls down within content by one page.
PageLeftScrolls left within content by one page.
PageRightScrolls right within content by one page.
PageUpScrolls up within content by one page.
RefreshPerforms deterministic update of the virtualized viewport data. An implementation for Refresh.
ScrollToTheDesiredChildScrolls to the desired child.
SetHorizontalOffsetSets the amount of horizontal offset.
SetVerticalOffsetSets the amount of vertical offset.
AboutToRenderChildItemsRaised when the control is about to render / display the items in the viewport.
CustomExtraSpacingBetweenGroupHeaderRowAndDataItemRowPropertyThe custom extra spacing between group header row and data item row property
CustomExtraSpacingBetweenGroupRenderingCompletionAndGroupHeaderRowRenderingBeginsPropertyThe custom extra spacing between group rendering completion and group header row rendering begins property
DesiredChildIndexScrollingIsDataContextSynchronizedPropertyThe desired child index scrolling is data context synchronized property
DesiredChildIndexToScrollToPropertyDesiredChildIndexToScrollToProperty property.
GroupHeaderItemCustomHeightPropertyThe group header item custom height property
GroupVirtualizationModePropertyGets or sets the virtualization mode when grouping is enabled on the data source.
IsAnimationEnabledPropertyIsAnimationEnabledProperty property.
IsAnimationEnabledWhenScrollToASpecificChildIndexPropertyIsAnimationEnabledForDeterministicScrollToASpecificChildIndexProperty property.
IsDataSourceGroupedPropertyGets or sets whether the data source of the items control is set up with grouping information.
IsDynamicConstructionCapabilityEnabledPropertyThe is dynamic construction capability enabled property
IsExtraMarginAtStartupRequiredPropertyThe is extra margin at startup required property
IsRenderItemDimensionHeightSpacingBetweenGroupHeaderAndDataItemRowEnabledPropertyThe is render item dimension height spacing between group header and data item row enabled property
IsTrimExtraLinkbreakForFirstRowEnabledPropertyThe is trim extra linkbreak for first row enabled property
IsVariableItemSizeEnabledPropertyIdentifies the IsVariableItemSizeEnabled dependency property.
ItemDimensionPropertyItemDimensionProperty property.
ItemPositioningModePropertyThe item positioning mode property
OrientationPropertyOrientationProperty property.
PanelAnimationEffectPropertyPanelAnimationEffectProperty property.
ReRenderVisibilityRangeMaxCountPropertyThe re render visibility range maximum count property
RendertimeMarginPropertyThe rendertime margin property
ShouldAutoAdjustParentItemsControlInternalPaddingPropertyIdentifies the ShouldAutoAdjustParentItemsControlInternalPadding dependency property.
ShouldRenderExtraLineBeforeHeaderPropertyGets or sets a value indicating whether the control should render an extra line before header in standalone line rendering mode.
ShouldRenderItemHeightSpacingAfterAGroupHasBeenRenderedPropertyThe should render item height spacing after a group has been rendered property
VirtualizationSchemeOptionPropertyVirtualizationSchemeOptionProperty property.
VirtualizationSchemeWhenScrollingToASpecificChildIndexPropertyVirtualizationSchemeWhenScrollingToASpecificChildIndexProperty property.

Constructors

BinaryVirtualizingWrapPanel

public BinaryVirtualizingWrapPanel()

Initializes a new instance of the BinaryVirtualizingWrapPanel class.

Properties

AutoUpdateViewportOnDetectingTransactionalUpdatesToDataSource

public bool AutoUpdateViewportOnDetectingTransactionalUpdatesToDataSource

Gets or sets a value indicating whether [automatic update viewport on detecting transactional updates to data source].

Value. true if [automatic update viewport on detecting transactional updates to data source]; otherwise, false .

CanHorizontallyScroll

public bool CanHorizontallyScroll

Gets or sets a value that indicates whether scrolling on the horizontal axis is possible.

Value. true if this instance can horizontally scroll; otherwise, false .

The scroll owner writes this, and the horizontal offset setter honours it: an offset asked for on an axis the owner has switched off is refused rather than applied.

CanVerticallyScroll

public bool CanVerticallyScroll

Gets or sets a value that indicates whether scrolling on the vertical axis is possible.

Value. true if this instance can vertically scroll; otherwise, false .

The scroll owner writes this, and the vertical offset setter honours it. See CanHorizontallyScroll.

CustomExtraSpacingBetweenGroupHeaderRowAndDataItemRow

public double CustomExtraSpacingBetweenGroupHeaderRowAndDataItemRow

Gets or sets a custom extra spacing to render between the group header row and the data item row.

Value. The custom extra spacing between group header row and data item row.

By default, the spacing is rendered automatically to a size value of the ItemDimension.Height value. But if you set the IsRenderItemDimensionHeightSpacingBetweenGroupHeaderAndDataItemRowEnabled to false, then this automatic spacing will not be rendered.
In that case, the control renders this property's spacing between the group header row and the data item row instead - 8 units by default.

CustomExtraSpacingBetweenGroupRenderingCompletionAndGroupHeaderRowRenderingBegins

public double CustomExtraSpacingBetweenGroupRenderingCompletionAndGroupHeaderRowRenderingBegins

Gets or sets the custom extra spacing to render between where a group rendering completes and the next group header row rendering begins.

Value. The custom extra spacing between group rendering completion and group header row rendering begins.

This property has effect only when the property ShouldRenderItemHeightSpacingAfterAGroupHasBeenRendered is set to false.
By default the value of this property is set to 48.0.
Note that the maximum value this property can be set to is 80% of the ItemDimension's Height value.

DesiredChildIndexScrollingIsDataContextSynchronized

public bool DesiredChildIndexScrollingIsDataContextSynchronized

Gets or sets whether the control's DesiredChildIndexToScrollTo is set to be synchronized with the current item in the data context.

Value. true if [desired child index scrolling is data context synchronized]; otherwise, false .

DesiredChildIndexToScrollTo

public int DesiredChildIndexToScrollTo

Gets or sets the desired child index to scroll to.

Value. The desired child index to scroll to.

Minus one, the default, means no particular index is wanted and the panel scrolls normally. Any value from zero upward puts it into deterministic-scroll mode, where the measure pass works out where that index falls and moves the viewport to it.

ExtentHeight

public double ExtentHeight

Gets the vertical size of the extent.

Value. The height of the extent.

ExtentWidth

public double ExtentWidth

Gets the horizontal size of the extent.

Value. The width of the extent.

GroupHeaderItemCustomHeight

public double GroupHeaderItemCustomHeight

Gets or sets a custom height when rendering the group header using a custom Datatemplate.

Value. The height of the group header item custom.

GroupVirtualizationMode

public GroupVirtualizationMode GroupVirtualizationMode

Gets or sets the virtualization mode when grouping is enabled on the data source.

Value. The group virtualization mode.

HorizontalOffset

public double HorizontalOffset

Gets the horizontal offset of the scrolled content.

Value. The horizontal offset.

IsAnimationEnabled

public bool IsAnimationEnabled

Gets or sets a value indicating whether this instance is animation enabled.

Value. true if this instance is animation enabled; otherwise, false .

IsAnimationEnabledWhenScrollToASpecificChildIndex

public bool IsAnimationEnabledWhenScrollToASpecificChildIndex

Gets or sets a value indicating whether this instance is animation enabled for deterministically scrolling to a specific child index.

Value. true if this instance is animation enabled when scroll to a specific child index; otherwise, false .

The default value is false.

IsDataSourceGrouped

public bool IsDataSourceGrouped

Gets or sets whether the data source of the items control is set up with grouping information.

Value. true if this instance is data source grouped; otherwise, false .

IsDynamicConstructionCapabilityEnabled

public bool IsDynamicConstructionCapabilityEnabled

Gets or sets a value indicating whether this instance is dynamic construction capability enabled.

Value. true if this instance is dynamic construction capability enabled; otherwise, false .

IsExtraMarginAtStartupRequired

public bool IsExtraMarginAtStartupRequired

Gets or sets a value indicating whether this instance is extra margin at startup required.

Value. true if for this instance, the extra margin at startup is required; otherwise, false .

False by default. Set it to true to have ten units added to each side of RendertimeMargin when the panel sets its margin: when it joins the visual tree, and at once if it already has.

IsRenderItemDimensionHeightSpacingBetweenGroupHeaderAndDataItemRowEnabled

public bool IsRenderItemDimensionHeightSpacingBetweenGroupHeaderAndDataItemRowEnabled

Gets or sets whether to render spacing between the group header and data item row.

Value. true if this instance is render item dimension height spacing between group header and data item row enabled; otherwise, false .

By default this property is set to true, and the spacing between the group header row and the data item row is equal to the height value of the row as set in the ItemDimension property.

IsTrimExtraLinkbreakForLeadingRowWithOneChildEnabled

public bool IsTrimExtraLinkbreakForLeadingRowWithOneChildEnabled

Gets or sets whether to automatically trim the extra leading space between header and row data if there is only one child per row that is being rendered.

Value. true if this instance is trim extra linkbreak for leading row with one child enabled; otherwise, false .

IsVariableItemSizeEnabled

public bool IsVariableItemSizeEnabled

Gets or sets a value indicating whether items may each be a different size.

Value. false , the default, to lay every item out in a cell of ItemDimension; true to give each item the size it asks for.

With variable sizes, items flow along each line at their own width (their own height in Vertical) and wrap when the line is full; a line is as tall as its tallest item. An item is measured when it first comes into view, and its size is remembered; until then ItemDimension is used as its estimate, so set it to a typical item size. Grouping works with variable sizes too.

ItemDimension

public Size ItemDimension

Gets or sets the size of the content items.

Value. The size of the item.

Every item is laid out in a cell of this size, and the panel works out which items are in view from their index alone - which is what lets it virtualise very large lists without measuring them. Items of differing sizes are each arranged within one cell, so set this to the largest size your items need.

ItemPositioningMode

public ItemPositioningMode ItemPositioningMode

Gets or sets the item positioning mode.

Value. The item positioning mode. The default is Safe.

The mode decides how many items a line holds when the viewport is not an exact number of items wide (or tall, in a vertical orientation).

Safe holds whole items only: what is left over at the end of the line stays empty, and every item the user can see is complete.

Greedy takes one more item when the space left at the end of the line is at least 85 per cent of an item, so a line that would otherwise waste most of an item's width uses it. The last item on such a line is clipped, by at most fifteen per cent of its own width.

With a grouped source, Safe also keeps one item's width (or height) of each line for the group's own furniture; Greedy does not.

Orientation

public Orientation Orientation

Gets or sets the orientation for laying-out the children items.

Value. The orientation.

PanelAnimationEffect

public AnimationEffect PanelAnimationEffect

Gets or sets the panel animation effect.

Value. The AnimationEffect.

ReRenderVisibilityRangeMaxCount

public int ReRenderVisibilityRangeMaxCount

Gets or sets the maximum number of items that the control has to prepare when about to re-render the viewport due to a trigger to the view invalidation.

Value. The re render visibility range maximum count.

By default this is set to 100. You can set a desired limit, but do not set this to too low or too large. A recommended low range would 15, and a high range would be 175.

RendertimeMargin

public Thickness RendertimeMargin

Gets or sets the rendertime margin.

Value. The rendertime margin.

ScrollOwner

public ScrollViewer ScrollOwner

Gets or sets a ScrollViewer element that controls scrolling behavior.

Value. The scroll owner.

ShouldAdjustRightHorizontalAlignmentSetupConsideringScrollInfo

public bool ShouldAdjustRightHorizontalAlignmentSetupConsideringScrollInfo

Gets or sets a value indicating whether the control should adjust right horizontal alignment margin setup considering the host ItemsControl scrollbar visual.

Value. true if [should adjust right horizontal alignment setup considering scroll information]; otherwise, false .

ShouldAutoAdjustParentItemsControlInternalPadding

public bool ShouldAutoAdjustParentItemsControlInternalPadding

Gets or sets whether the component should automatically adjust the internal padding setup in the Control styles of the owner ItemsControl.

The default is false. When set, the owner's padding loses three units on the left and nine at the top, so the left-most item's border is not cut off and no extra space appears above the first line; setting it back to false gives them back.

ShouldRecomputeViewportExtentSpacingUponAlignment

public bool ShouldRecomputeViewportExtentSpacingUponAlignment

Gets or sets a value indicating whether the control should recompute the viewport vis-a-vis extent spacing upon alignment.

Value. true if [should recompute viewport extent spacing upon alignment]; otherwise, false .

ShouldRenderExtraLineBeforeHeader

public bool ShouldRenderExtraLineBeforeHeader

Gets or sets a value indicating whether the control should render an extra line before header in standalone line rendering mode.

Value. true if [should render extra line before header]; otherwise, false .

ShouldRenderItemHeightSpacingAfterAGroupHasBeenRendered

public bool ShouldRenderItemHeightSpacingAfterAGroupHasBeenRendered

Gets or sets a value indicating whether the control should render an item height worth of spacing after a group has been rendered.

Value. true if [should render item height spacing after a group has been rendered]; otherwise, false .

False by default. Set it to true and the control renders an ItemDimension Height value worth of spacing between where a group's rendering completes and where the next header row begins.
Left false - the default - that spacing comes from CustomExtraSpacingBetweenGroupRenderingCompletionAndGroupHeaderRowRenderingBegins instead, which is 48.0 unless you set it.

ShouldShareUnusedSpaceEquallyOnHorizontalAlignment

public bool ShouldShareUnusedSpaceEquallyOnHorizontalAlignment

Gets or sets a value indicating whether the control should share unused space equally on horizontal alignment.

Value. true if [should share unused space equally on horizontal alignment]; otherwise, false .

ShouldUseRenderTimeMarginValuesWhenRecomputingViewPortExtentSpacingAdjustment

public bool ShouldUseRenderTimeMarginValuesWhenRecomputingViewPortExtentSpacingAdjustment

Gets or sets a value indicating whether the control should use the value set for RendertimeMargin relevant values when recomputing view port extent spacing adjustment for the property ShouldRecomputeViewportExtentSpacingUponAlignment.

Value. true if [should use render time margin values when recomputing view port extent spacing adjustment]; otherwise, false .

VerticalOffset

public double VerticalOffset

Gets the vertical offset of the scrolled content.

Value. The vertical offset.

ViewportHeight

public double ViewportHeight

Gets the vertical size of the viewport for this content.

Value. The height of the viewport.

ViewportWidth

public double ViewportWidth

Gets the horizontal size of the viewport for this content.

Value. The width of the viewport.

VirtualizationSchemeOption

public VirtualizationScheme VirtualizationSchemeOption

Gets or sets the virtualization scheme.

Value. The virtualization scheme.

When the control is in grouping mode - i.e. the property IsDataSourceGrouped is set to true, the only VirtualizationScheme value you can use is VirtualizationScheme.LightWeightCache.

VirtualizationSchemeWhenScrollingToASpecificChildIndex

public VirtualizationScheme VirtualizationSchemeWhenScrollingToASpecificChildIndex

Gets or sets the VirtualizationScheme to use, when scrolling to a specific child.

Value. The index of the virtualization scheme when scrolling to a specific child.

Methods

ArrangeOverride

protected override Size ArrangeOverride(Size finalSize)

When overridden in a derived class, positions child elements and determines a size for a FrameworkElement derived class.

finalSize
The final area within the parent that this element should use to arrange itself and its children.

Returns. The actual size used.

LineDown

public void LineDown()

Scrolls down within content by one logical unit.

LineLeft

public void LineLeft()

Scrolls left within content by one logical unit.

LineRight

public void LineRight()

Scrolls right within content by one logical unit.

LineUp

public void LineUp()

Scrolls up within content by one logical unit.

MakeVisible

public Rect MakeVisible(Visual visual, Rect rectangle)

This method is not available in the Virtualization scenario.

visual
A Visual that becomes visible.
rectangle
A bounding rectangle that identifies the coordinate space to make visible.

Returns. A Rect that is visible.

MeasureOverride

protected override Size MeasureOverride(Size availableSize)

When overridden in a derived class, measures the size in layout required for child elements and determines a size for the FrameworkElement-derived class.

availableSize
The available size that this element can give to child elements. Infinity can be specified as a value to indicate that the element will size to whatever content is available.

Returns. The size that this element determines it needs during layout, based on its calculations of child element sizes.

MouseWheelDown

public void MouseWheelDown()

Scrolls down within content after a user clicks the wheel button on a mouse.

MouseWheelLeft

public void MouseWheelLeft()

Scrolls left within content after a user clicks the wheel button on a mouse.

MouseWheelRight

public void MouseWheelRight()

Scrolls right within content after a user clicks the wheel button on a mouse.

MouseWheelUp

public void MouseWheelUp()

Scrolls up within content after a user clicks the wheel button on a mouse.

OnIsItemsHostChanged

protected override void OnIsItemsHostChanged(bool oldIsItemsHost, bool newIsItemsHost)

Measures again when the panel becomes an items host, which on a page's first show happens after the panel's first measure pass.

oldIsItemsHost
The old value.
newIsItemsHost
The new value.

OnItemsChanged

protected override void OnItemsChanged(object sender, ItemsChangedEventArgs args)

Called when the Items collection that is associated with the ItemsControl for this Panel changes.

sender
The Object that raised the event.
args
Provides data for the ItemsChanged event.

OnKeyDown

protected override void OnKeyDown(System.Windows.Input.KeyEventArgs e)

Invoked when an unhandled KeyDown attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event.

e
The KeyEventArgs that contains the event data.

OnRenderSizeChanged

protected override void OnRenderSizeChanged(SizeChangedInfo sizeInfo)

Raises the SizeChanged event, using the specified information as part of the eventual event data.

sizeInfo
Details of the old and new size involved in the change.

PageDown

public void PageDown()

Scrolls down within content by one page.

PageLeft

public void PageLeft()

Scrolls left within content by one page.

PageRight

public void PageRight()

Scrolls right within content by one page.

PageUp

public void PageUp()

Scrolls up within content by one page.

Refresh

public void Refresh()

Performs deterministic update of the virtualized viewport data. An implementation for Refresh.

ScrollToTheDesiredChild

public void ScrollToTheDesiredChild(int desiredChildIndexToScrollTo, bool performAnimation, VirtualizationScheme virtualizationScheme)

Scrolls to the desired child.

desiredChildIndexToScrollTo
The desired child index to scroll to.
performAnimation
if set to true [perform animation].
virtualizationScheme
The desired VirtualizationScheme.

SetHorizontalOffset

public void SetHorizontalOffset(double offset)

Sets the amount of horizontal offset.

offset
The degree to which content is horizontally offset from the containing viewport.

SetVerticalOffset

public void SetVerticalOffset(double offset)

Sets the amount of vertical offset.

offset
The degree to which content is vertically offset from the containing viewport.

Events

AboutToRenderChildItems

public event EventHandler<AboutToRenderChildItemsEventArgs> AboutToRenderChildItems

Raised when the control is about to render / display the items in the viewport.

Subscribe to this event to reset the ItemDimension property value dynamically, so that you can achieve differing child item sizing as is appropriate, when the user scrolls through the control's extent.

Fields

CustomExtraSpacingBetweenGroupHeaderRowAndDataItemRowProperty

public static readonly DependencyProperty CustomExtraSpacingBetweenGroupHeaderRowAndDataItemRowProperty

The custom extra spacing between group header row and data item row property

CustomExtraSpacingBetweenGroupRenderingCompletionAndGroupHeaderRowRenderingBeginsProperty

public static readonly DependencyProperty CustomExtraSpacingBetweenGroupRenderingCompletionAndGroupHeaderRowRenderingBeginsProperty

The custom extra spacing between group rendering completion and group header row rendering begins property

DesiredChildIndexScrollingIsDataContextSynchronizedProperty

public static readonly DependencyProperty DesiredChildIndexScrollingIsDataContextSynchronizedProperty

The desired child index scrolling is data context synchronized property

DesiredChildIndexToScrollToProperty

public static readonly DependencyProperty DesiredChildIndexToScrollToProperty

DesiredChildIndexToScrollToProperty property.

GroupHeaderItemCustomHeightProperty

public static readonly DependencyProperty GroupHeaderItemCustomHeightProperty

The group header item custom height property

GroupVirtualizationModeProperty

public static readonly DependencyProperty GroupVirtualizationModeProperty

Gets or sets the virtualization mode when grouping is enabled on the data source.

IsAnimationEnabledProperty

public static readonly DependencyProperty IsAnimationEnabledProperty

IsAnimationEnabledProperty property.

IsAnimationEnabledWhenScrollToASpecificChildIndexProperty

public static readonly DependencyProperty IsAnimationEnabledWhenScrollToASpecificChildIndexProperty

IsAnimationEnabledForDeterministicScrollToASpecificChildIndexProperty property.

IsDataSourceGroupedProperty

public static readonly DependencyProperty IsDataSourceGroupedProperty

Gets or sets whether the data source of the items control is set up with grouping information.

IsDynamicConstructionCapabilityEnabledProperty

public static readonly DependencyProperty IsDynamicConstructionCapabilityEnabledProperty

The is dynamic construction capability enabled property

IsExtraMarginAtStartupRequiredProperty

public static readonly DependencyProperty IsExtraMarginAtStartupRequiredProperty = DependencyProperty.Register("IsExtraMarginAtStartupRequired", typeof(bool), typeof(BinaryVirtualizingWrapPanel), new UIPropertyMetadata(false, (o, e)

The is extra margin at startup required property

IsRenderItemDimensionHeightSpacingBetweenGroupHeaderAndDataItemRowEnabledProperty

public static readonly DependencyProperty IsRenderItemDimensionHeightSpacingBetweenGroupHeaderAndDataItemRowEnabledProperty

The is render item dimension height spacing between group header and data item row enabled property

IsTrimExtraLinkbreakForFirstRowEnabledProperty

public static readonly DependencyProperty IsTrimExtraLinkbreakForFirstRowEnabledProperty

The is trim extra linkbreak for first row enabled property

IsVariableItemSizeEnabledProperty

public static readonly DependencyProperty IsVariableItemSizeEnabledProperty

Identifies the IsVariableItemSizeEnabled dependency property.

ItemDimensionProperty

public static readonly DependencyProperty ItemDimensionProperty

ItemDimensionProperty property.

Value. The size of the item.

ItemPositioningModeProperty

public static DependencyProperty ItemPositioningModeProperty

The item positioning mode property

OrientationProperty

public static readonly DependencyProperty OrientationProperty

OrientationProperty property.

PanelAnimationEffectProperty

public static readonly DependencyProperty PanelAnimationEffectProperty

PanelAnimationEffectProperty property.

ReRenderVisibilityRangeMaxCountProperty

public static readonly DependencyProperty ReRenderVisibilityRangeMaxCountProperty

The re render visibility range maximum count property

RendertimeMarginProperty

public static readonly DependencyProperty RendertimeMarginProperty

The rendertime margin property

ShouldAutoAdjustParentItemsControlInternalPaddingProperty

public static readonly DependencyProperty ShouldAutoAdjustParentItemsControlInternalPaddingProperty = DependencyProperty.Register("ShouldAutoAdjustParentItemsControlInternalPadding", typeof(bool), typeof(BinaryVirtualizingWrapPanel), new UIPropertyMetadata(false, (o, e)

Identifies the ShouldAutoAdjustParentItemsControlInternalPadding dependency property.

ShouldRenderExtraLineBeforeHeaderProperty

public static DependencyProperty ShouldRenderExtraLineBeforeHeaderProperty

Gets or sets a value indicating whether the control should render an extra line before header in standalone line rendering mode.

ShouldRenderItemHeightSpacingAfterAGroupHasBeenRenderedProperty

public static readonly DependencyProperty ShouldRenderItemHeightSpacingAfterAGroupHasBeenRenderedProperty

The should render item height spacing after a group has been rendered property

VirtualizationSchemeOptionProperty

public static readonly DependencyProperty VirtualizationSchemeOptionProperty

VirtualizationSchemeOptionProperty property.

VirtualizationSchemeWhenScrollingToASpecificChildIndexProperty

public static readonly DependencyProperty VirtualizationSchemeWhenScrollingToASpecificChildIndexProperty

VirtualizationSchemeWhenScrollingToASpecificChildIndexProperty property.