ImageBrush Class

Summary

Paints an area with an IBitmap.
graph BT Type-->Base0["TileBrush"] click Base0 "/api/Avalonia.Media/TileBrush" Base0-->Base1["Brush"] click Base1 "/api/Avalonia.Media/Brush" Base1-->Base2["Animatable"] click Base2 "/api/Avalonia.Animation/Animatable" Base2-->Base3["AvaloniaObject"] click Base3 "/api/Avalonia/AvaloniaObject" Base3-->Base4["object"] Type-.->Interface0["IAvaloniaObject"] click Interface0 "/api/Avalonia/IAvaloniaObject" Type-.->Interface1["IAvaloniaObjectDebug"] click Interface1 "/api/Avalonia.Diagnostics/IAvaloniaObjectDebug" Type-.->Interface2["INotifyPropertyChanged"] Type-.->Interface3["IValueSink"] Type-.->Interface4["IMutableBrush"] click Interface4 "/api/Avalonia.Media/IMutableBrush" Type-.->Interface5["IAffectsRender"] click Interface5 "/api/Avalonia.Media/IAffectsRender" Type-.->Interface6["IImageBrush"] click Interface6 "/api/Avalonia.Media/IImageBrush" Type-.->Interface7["ITileBrush"] click Interface7 "/api/Avalonia.Media/ITileBrush" Type-.->Interface8["IBrush"] click Interface8 "/api/Avalonia.Media/IBrush" Type["ImageBrush"] class Type type-node

Syntax

public class ImageBrush : TileBrush, IAvaloniaObject, IAvaloniaObjectDebug, INotifyPropertyChanged, 
    IValueSink, IMutableBrush, IAffectsRender, IImageBrush, ITileBrush, IBrush

Constructors

Name Summary
ImageBrush() Initializes a new instance of the ImageBrush class.
ImageBrush(IBitmap) Initializes a new instance of the ImageBrush class.

Events

Name Type Summary
Invalidated EventHandler
Raised when the resource changes visually.
Inherited from Brush
PropertyChanged EventHandler<AvaloniaPropertyChangedEventArgs>
Raised when a AvaloniaProperty value changes on this object.
Inherited from AvaloniaObject

Fields

Name Constant Value Summary
AlignmentXProperty
Defines the AlignmentX property.
Inherited from TileBrush
static
AlignmentYProperty
Defines the AlignmentY property.
Inherited from TileBrush
static
ClockProperty
Defines the Clock property.
Inherited from Animatable
static
DestinationRectProperty
Defines the DestinationRect property.
Inherited from TileBrush
static
OpacityProperty
Defines the Opacity property.
Inherited from Brush
static
SourceProperty
Defines the Visual property.
static
SourceRectProperty
Defines the SourceRect property.
Inherited from TileBrush
static
StretchProperty
Defines the Stretch property.
Inherited from TileBrush
static
TileModeProperty
Defines the TileMode property.
Inherited from TileBrush
static
TransitionsProperty
Defines the Transitions property.
Inherited from Animatable
static

Properties

Name Value Summary
AlignmentX AlignmentX
Gets or sets the horizontal alignment of a tile in the destination.
Inherited from TileBrush
AlignmentY AlignmentY
Gets or sets the horizontal alignment of a tile in the destination.
Inherited from TileBrush
BitmapInterpolationMode BitmapInterpolationMode
Gets or sets the bitmap interpolation mode.
Inherited from TileBrush
Clock IClock
Gets or sets the clock which controls the animations on the control.
Inherited from Animatable
DestinationRect RelativeRect
Gets or sets the rectangle on the destination in which to paint a tile.
Inherited from TileBrush
InheritanceParent IAvaloniaObject
Gets or sets the parent object that inherited AvaloniaProperty values are inherited from.
Inherited from AvaloniaObject
Opacity double
Gets or sets the opacity of the brush.
Inherited from Brush
Source IBitmap
Gets or sets the image to draw.
SourceRect RelativeRect
Gets or sets the rectangle of the source image that will be displayed.
Inherited from TileBrush
Stretch Stretch
Gets or sets a value controlling how the source rectangle will be stretched to fill the destination rect.
Inherited from TileBrush
this[AvaloniaProperty] object
Gets or sets the value of a AvaloniaProperty.
Inherited from AvaloniaObject
this[IndexerDescriptor] IBinding
Gets or sets a binding for a AvaloniaProperty.
Inherited from AvaloniaObject
TileMode TileMode
Gets or sets the brush's tile mode.
Inherited from TileBrush
Transitions Transitions?
Gets or sets the property transitions for the control.
Inherited from Animatable

Methods

Name Value Summary
AffectsRender<T>(AvaloniaProperty[]) void
Marks a property as affecting the brush's visual representation.
Inherited from Brush
static
BeginBatchUpdate() void
Inherited from AvaloniaObject
Bind<T>(DirectPropertyBase<T>, IObservable<BindingValue<T>>) IDisposable
Binds a AvaloniaProperty to an observable.
Inherited from AvaloniaObject
Bind<T>(StyledPropertyBase<T>, IObservable<BindingValue<T>>, BindingPriority) IDisposable
Binds a AvaloniaProperty to an observable.
Inherited from AvaloniaObject
CheckAccess() bool
Inherited from AvaloniaObject
ClearValue(AvaloniaProperty) void
Clears a AvaloniaProperty's local value.
Inherited from AvaloniaObject
ClearValue<T>(AvaloniaProperty<T>) void
Clears a AvaloniaProperty's local value.
Inherited from AvaloniaObject
ClearValue<T>(DirectPropertyBase<T>) void
Clears a AvaloniaProperty's local value.
Inherited from AvaloniaObject
ClearValue<T>(StyledPropertyBase<T>) void
Clears a AvaloniaProperty's local value.
Inherited from AvaloniaObject
CoerceValue<T>(StyledPropertyBase<T>) void
Coerces the specified AvaloniaProperty.
Inherited from AvaloniaObject
DisableTransitions() void
Disables transitions for the control.
Inherited from Animatable
EnableTransitions() void
Enables transitions for the control.
Inherited from Animatable
EndBatchUpdate() void
Inherited from AvaloniaObject
Equals(object) bool
Compares two objects using reference equality.
Inherited from AvaloniaObject
GetBaseValue<T>(StyledPropertyBase<T>, BindingPriority) Optional<T>
Gets an AvaloniaProperty base value.
Inherited from AvaloniaObject
GetHashCode() int
Gets the hash code for the object.
Inherited from AvaloniaObject
GetValue(AvaloniaProperty) object
Gets a AvaloniaProperty value.
Inherited from AvaloniaObject
GetValue<T>(DirectPropertyBase<T>) T
Gets a AvaloniaProperty value.
Inherited from AvaloniaObject
GetValue<T>(StyledPropertyBase<T>) T
Gets a AvaloniaProperty value.
Inherited from AvaloniaObject
IsAnimating(AvaloniaProperty) bool
Checks whether a AvaloniaProperty is animating.
Inherited from AvaloniaObject
IsSet(AvaloniaProperty) bool
Checks whether a AvaloniaProperty is set on this object.
Inherited from AvaloniaObject
OnPropertyChangedCore<T>(AvaloniaPropertyChangedEventArgs<T>) void
Inherited from Animatable
Parse(string) IBrush
Parses a brush string.
Inherited from Brush
static
RaiseInvalidated(EventArgs) void
Raises the Invalidated event.
Inherited from Brush
SetValue(AvaloniaProperty, object, BindingPriority) void
Sets a AvaloniaProperty value.
Inherited from AvaloniaObject
SetValue<T>(DirectPropertyBase<T>, T) void
Sets a AvaloniaProperty value.
Inherited from AvaloniaObject
SetValue<T>(StyledPropertyBase<T>, T, BindingPriority) IDisposable
Sets a AvaloniaProperty value.
Inherited from AvaloniaObject
ToImmutable() IBrush
Creates an immutable clone of the brush.
VerifyAccess() void
Inherited from AvaloniaObject

Extension Methods

Name Value Summary
Bind(AvaloniaProperty, IObservable<BindingValue<object>>, BindingPriority) IDisposable
Binds a AvaloniaProperty to an observable.
Bind<T>(AvaloniaProperty<T>, IObservable<BindingValue<T>>, BindingPriority) IDisposable
Binds a AvaloniaProperty to an observable.
GetBindingObservable(AvaloniaProperty) IObservable<BindingValue<object>>
Gets an observable for a AvaloniaProperty.
GetBindingObservable<T>(AvaloniaProperty<T>) IObservable<BindingValue<T>>
Gets an observable for a AvaloniaProperty.
GetBindingSubject(AvaloniaProperty, BindingPriority) ISubject<BindingValue<object>>
Gets a subject for a AvaloniaProperty.
GetBindingSubject<T>(AvaloniaProperty<T>, BindingPriority) ISubject<BindingValue<T>>
Gets a subject for a AvaloniaProperty.
GetDiagnostic(AvaloniaProperty) AvaloniaPropertyValue
Gets a diagnostic for a AvaloniaProperty on a AvaloniaObject.
GetObservable(AvaloniaProperty) IObservable<object>
Gets an observable for a AvaloniaProperty.
GetObservable<T>(AvaloniaProperty<T>) IObservable<T>
Gets an observable for a AvaloniaProperty.
GetPropertyChangedObservable(AvaloniaProperty) IObservable<AvaloniaPropertyChangedEventArgs>
Gets an observable that listens for property changed events for an AvaloniaProperty.
GetSubject(AvaloniaProperty, BindingPriority) ISubject<object>
Gets a subject for a AvaloniaProperty.
GetSubject<T>(AvaloniaProperty<T>, BindingPriority) ISubject<T>
Gets a subject for a AvaloniaProperty.
ToImmutable() IBrush
Converts a brush to an immutable brush.