Microsoft.Maui.Graphics Namespace
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Provides interfaces, classes and supporting types for .NET MAUI Graphics; the abstracted, unified drawing APIs that work cross-platform.
Classes
AbstractCanvas<TState> |
Provides an abstract base implementation of the ICanvas interface. |
AbstractPattern |
Provides a base implementation for pattern types that can be used to fill shapes. |
BitmapExportContext |
Provides an abstract base class for bitmap export operations. |
BitmapExportContextExtensions |
Provides extension methods for the BitmapExportContext class. |
CanvasDefaults |
Provides default values for canvas-related properties. |
CanvasExtensions |
Provides extension methods for the ICanvas interface. |
CanvasState |
Represents the state of a canvas, including transformation and stroke properties. |
Color |
Represents an RGBA color with floating-point components in the range of 0.0 to 1.0. |
Colors |
Represents all the system-defined colors. |
FontWeights |
Defines constant values for standard font weights. |
GeometryUtil |
Provides utility methods for geometric calculations. |
GradientPaint |
Represents an abstract base class for gradient paints that transition between multiple colors. |
IFontExtensions |
Provides extension methods for the IFont interface. |
ImageExtensions |
Provides extension methods for the IImage interface. |
ImageLoadingServiceExtensions |
Provides extension methods for the IImageLoadingService interface. |
ImagePaint |
Represents a paint that uses an image to fill shapes. |
Insets |
Represents inset distances from the four edges of a rectangle. |
InsetsF |
Represents inset distances from the four edges of a rectangle using single-precision floating-point values. |
LinearGradientPaint |
Represents a linear gradient paint that transitions colors along a line defined by start and end points. |
Paint |
Represents an abstract base class for different types of paints that can be used to fill shapes. |
PaintExtensions | |
PaintGradientStop |
Represents a color stop in a gradient paint. |
PaintPattern |
Represents a pattern that applies a paint to a wrapped pattern for filling shapes. |
PathArcExtensions |
Provides extension methods for adding SVG-compatible arcs to a PathF. |
PathBuilder |
Provides functionality for constructing path objects from string definitions. |
PathExtensions |
Provides extension methods for working with PathF objects. |
PathF |
Represents a geometric path consisting of lines, curves, and shapes using single-precision floating-point coordinates. |
PatternExtensions |
Provides extension methods for the IPattern interface. |
PatternPaint |
Represents a paint that fills shapes with a repeating pattern. |
PdfPageExtensions |
Provides extension methods for the IPdfPage interface. |
PictureCanvas |
A canvas implementation that records drawing commands into a picture for later playback. |
PictureExtensions |
Provides extension methods for the IPicture interface. |
PicturePattern |
Represents a pattern that draws a picture repeatedly. |
PictureReaderExtensions |
Provides extension methods for the IPictureReader interface. |
PictureWriterExtensions |
Provides extension methods for the IPictureWriter interface. |
RadialGradientPaint |
Represents a radial gradient paint that transitions colors outward from a center point. |
ScalingCanvas |
A canvas implementation that applies scaling to drawing operations before delegating to a wrapped canvas. |
ShapeDrawable | |
SolidPaint |
Represents a paint that fills shapes with a solid color. |
StandardPicture |
Provides a standard implementation of the IPicture interface using drawing commands. |
StandardTextAttributes |
Provides a standard implementation of the ITextAttributes interface for styling text. |
XmlnsPrefixAttribute |
Structs
Font |
Represents a font with a name, weight, and style. |
FontSource |
Represents a font source with name, weight, and style information. |
Point |
Represents a point in 2D space using double-precision floating-point coordinates. |
PointF |
Represents a point in 2D space using single-precision floating-point coordinates. |
Rect |
Represents a rectangle with double-precision floating-point x, y coordinates and width and height. |
RectF |
Represents a rectangle with single-precision floating-point x, y coordinates and width and height. |
Size |
Represents a size with double-precision floating-point width and height. |
SizeF |
Represents a size with single-precision floating-point width and height. |
Interfaces
IBitmapExportService |
Defines a service for exporting graphics content as bitmaps. |
IBlurrableCanvas |
Defines a canvas that supports blur effects. |
ICanvas |
Represents a platform-agnostic canvas on which 2D graphics can be drawn using types from the Microsoft.Maui.Graphics namespace. |
ICanvasStateService<TState> |
Defines a service for creating and managing canvas state objects. |
IDrawable |
Defines an object that can be drawn onto a canvas. |
IFont |
Defines a font with name, weight, and style properties for text rendering. |
IImage |
Defines an interface for an image that can be drawn onto a canvas and manipulated. |
IImageLoadingService |
Defines a service for loading images from streams. |
IPattern |
Defines a pattern that can be used to fill shapes on a canvas. |
IPdfPage |
Represents a PDF page that can be drawn upon and saved to a stream. |
IPdfRenderService |
Defines a service for rendering PDF pages. |
IPicture |
Defines an interface for a picture, which is a collection of drawing commands that can be replayed on a canvas. |
IPictureReader |
Defines an interface for reading picture data from a byte array. |
IPictureWriter |
Defines an interface for saving picture objects to streams. |
IPlatformFonts |
Defines an interface for accessing and managing platform-specific fonts. |
IShape |
Provides a base definition class for shape elements, such as Ellipse, Polygon, or Rectangle. |
IStringSizeService |
Defines a service for calculating the size of text strings with different fonts and alignments. |
ITextAttributes |
Defines attributes for styling and positioning text in a graphics context. |
Enums
BlendMode |
Specifies the blend mode to use when compositing images or drawings. |
FontStyleType |
Specifies the style of a font. |
HorizontalAlignment |
Specifies the horizontal alignment of text or elements. |
ImageFormat |
Specifies the format of an image. |
LineCap |
Specifies the style of line cap (ending) to use at the end of lines when drawing. |
LineJoin |
Specifies the style used to join two line segments where they meet. |
PathOperation |
Specifies the types of operations that can be performed on a path. |
PictureCommand |
Specifies the type of commands that can be recorded and played back in a picture. |
ResizeMode |
Specifies how an image should be resized to fit a target area. |
TextFlow |
Specifies how text should flow when it exceeds the bounds of its container. |
VerticalAlignment |
Specifies the vertical alignment of text or elements. |
WindingMode |
Specifies the algorithm used to determine which regions are inside or outside a path for filling. |
Delegates
DrawingCommand |
Represents a method that performs drawing operations on a canvas. |
LayoutLine |
Represents a callback method that handles the layout of a line of text. |