Class SkiaScrollLooped
Cycles content, so the scroll never ands but cycles from the start
public class SkiaScrollLooped : SkiaScroll, INotifyPropertyChanged, IEffectControlProvider, IToolTipElement, IContextFlyoutElement, IAnimatable, IVisualElementController, IElementController, IView, ITransform, IElement, IVisualTreeElement, IContainer, IList<IView>, ICollection<IView>, IEnumerable<IView>, IEnumerable, IHasAfterEffects, ISkiaControl, IDrawnBase, ICanBeUpdatedWithContext, ICanBeUpdated, ISkiaDisposable, IDisposable, ISkiaGestureListener, IDefinesViewport, IWithContent
- Inheritance
-
SkiaScrollLooped
- Implements
- Inherited Members
- Extension Methods
Constructors
SkiaScrollLooped()
public SkiaScrollLooped()
Fields
CycleSpaceProperty
public static readonly BindableProperty CycleSpaceProperty
Field Value
Debug
public static bool Debug
Field Value
IsBannerProperty
public static readonly BindableProperty IsBannerProperty
Field Value
Properties
CycleSpace
Space between cycles, pixels
public double CycleSpace { get; set; }
Property Value
IsBanner
Whether this should look like an infinite scrolling text banner. So then the END doesn't glue with START directly, new START appears only when when previous END gows out of the screen.
public bool IsBanner { get; set; }
Property Value
ShouldInvalidateByChildren
public override bool ShouldInvalidateByChildren { get; }
Property Value
Methods
CalculateVisibleIndex(RelativePositionType)
Calculates CurrentIndex
public override ContainsPointResult CalculateVisibleIndex(RelativePositionType option = RelativePositionType.Start)
Parameters
optionRelativePositionType
Returns
ClampOffset(float, float, SKRect, bool)
public override Vector2 ClampOffset(float x, float y, SKRect contentOffsetBounds, bool strict = false)
Parameters
Returns
GetItemIndex(SkiaLayout, float, float, RelativePositionType)
public override ContainsPointResult GetItemIndex(SkiaLayout layout, float pixelsOffsetX, float pixelsOffsetY, RelativePositionType option)
Parameters
layoutSkiaLayoutpixelsOffsetXfloatpixelsOffsetYfloatoptionRelativePositionType
Returns
InitializeScroller(float)
protected override void InitializeScroller(float scale)
Parameters
scalefloat
ModifyViewportOffset(SKRect, SKPoint, float)
protected virtual SKPoint ModifyViewportOffset(SKRect destination, SKPoint offsetPixels, float scale)
Parameters
Returns
OffsetOk(Vector2)
Whether the scrolling offset in inside scrollable bounds or not
protected override bool OffsetOk(Vector2 offset)
Parameters
offsetVector2
Returns
OnDrawn(DrawingContext)
protected override void OnDrawn(DrawingContext context)
Parameters
contextDrawingContext
PositionViewport(SKRect, SKPoint, float, float, bool)
Input offset parameters in PIXELS. This is called inside Draw, only if need reposition viewport. Here we can construct anything according current offset before painting. Creates a valid ViewportRect inside.
protected override bool PositionViewport(SKRect destination, SKPoint offsetPixels, float viewportScale, float scale, bool forceSyncOffsets)
Parameters
Returns
- bool
Whether we changed viewport and cache changed
Snap(float)
public override void Snap(float maxTimeSecs)
Parameters
maxTimeSecsfloat
UpdateVisibleIndex()
public override void UpdateVisibleIndex()