diff --git a/src/Controls/docs/Microsoft.Maui.Controls/ContentView.xml b/src/Controls/docs/Microsoft.Maui.Controls/ContentView.xml
deleted file mode 100644
index 4325adbae4b4..000000000000
--- a/src/Controls/docs/Microsoft.Maui.Controls/ContentView.xml
+++ /dev/null
@@ -1,137 +0,0 @@
-
-
-
-
-
-
- Microsoft.Maui.Controls.Core
- 0.0.0.0
- 1.0.0.0
- 1.1.0.0
- 1.2.0.0
- 1.3.0.0
- 1.4.0.0
- 1.5.0.0
- 2.0.0.0
-
-
- Microsoft.Maui.Controls.TemplatedView
-
-
-
-
- Microsoft.Maui.Controls.ContentProperty("Content")
-
-
-
- An element that contains a single child element.
-
-
- The following example shows how to construct a new ContentView with a Label inside.
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- Constructor
-
- 0.0.0.0
- 1.0.0.0
- 1.1.0.0
- 1.2.0.0
- 1.3.0.0
- 1.4.0.0
- 1.5.0.0
- 2.0.0.0
- Microsoft.Maui.Controls.Core
-
-
-
- Initializes a new instance of the ContentView class.
-
-
-
-
-
-
-
-
-
- Property
-
- 0.0.0.0
- 1.0.0.0
- 1.1.0.0
- 1.2.0.0
- 1.3.0.0
- 1.4.0.0
- 1.5.0.0
- 2.0.0.0
- Microsoft.Maui.Controls.Core
-
-
- Microsoft.Maui.Controls.View
-
-
- Gets or sets the content of the ContentView.
- A that contains the content.
-
-
-
-
-
-
-
-
-
- Field
-
- 0.0.0.0
- 2.0.0.0
- Microsoft.Maui.Controls.Core
-
-
- Microsoft.Maui.Controls.BindableProperty
-
-
- Backing store for the property.
-
-
-
-
-
-
-
- Method
-
- 0.0.0.0
- 2.0.0.0
- Microsoft.Maui.Controls.Core
-
-
- System.Void
-
-
-
- Method that is called when the binding context changes.
-
-
-
-
diff --git a/src/Controls/docs/Microsoft.Maui.Controls/ProgressBar.xml b/src/Controls/docs/Microsoft.Maui.Controls/ProgressBar.xml
deleted file mode 100644
index 6a725ed7e0b8..000000000000
--- a/src/Controls/docs/Microsoft.Maui.Controls/ProgressBar.xml
+++ /dev/null
@@ -1,249 +0,0 @@
-
-
-
-
-
-
- Microsoft.Maui.Controls.Core
- 0.0.0.0
- 1.0.0.0
- 1.1.0.0
- 1.2.0.0
- 1.3.0.0
- 1.4.0.0
- 1.5.0.0
- 2.0.0.0
-
-
- Microsoft.Maui.Controls.View
-
-
-
- Microsoft.Maui.Controls.IElementConfiguration<Microsoft.Maui.Controls.ProgressBar>
-
-
-
-
- Microsoft.Maui.Controls.RenderWith(typeof(Microsoft.Maui.Controls.Platform._ProgressBarRenderer))
-
-
-
- A control that displays progress.
-
- The following example shows the usage of a ProgressBar.
-
-
-
-
-
-
-
-
-
-
-
-
-
- Constructor
-
- 0.0.0.0
- 1.0.0.0
- 1.1.0.0
- 1.2.0.0
- 1.3.0.0
- 1.4.0.0
- 1.5.0.0
- 2.0.0.0
- Microsoft.Maui.Controls.Core
-
-
-
- Initializes a new instance of the ProgressBar class
-
-
-
-
-
-
-
-
-
- Method
-
- M:Microsoft.Maui.Controls.IElementConfiguration`1.On``1
-
-
- 0.0.0.0
- 2.0.0.0
- Microsoft.Maui.Controls.Core
-
-
- Microsoft.Maui.Controls.IPlatformElementConfiguration<T,Microsoft.Maui.Controls.ProgressBar>
-
-
-
-
- Microsoft.Maui.Controls.IConfigPlatform
-
-
-
-
-
- To be added.
- Returns the platform-specific instance of this , on which a platform-specific method may be called.
-
-
-
-
-
-
-
- Property
-
- 0.0.0.0
- 1.0.0.0
- 1.1.0.0
- 1.2.0.0
- 1.3.0.0
- 1.4.0.0
- 1.5.0.0
- 2.0.0.0
- Microsoft.Maui.Controls.Core
-
-
- System.Double
-
-
- Gets or sets the progress value.
- Gets or sets a value that specifies the fraction of the bar that is colored.
- Values less than 0 or larger than 1 will be clamped to the range [0-1].
-
-
-
-
-
-
-
- Property
-
- Microsoft.Maui.Controls.Core
- 0.0.0.0
- 2.0.0.0
-
-
- Microsoft.Maui.Graphics.Color
-
-
- Get or sets the color of the progress bar.
- The color of the progress bar.
-
-
-
-
-
-
-
- Field
-
- Microsoft.Maui.Controls.Core
- 0.0.0.0
- 2.0.0.0
-
-
- Microsoft.Maui.Controls.BindableProperty
-
-
- Backing store for the property.
-
-
-
-
-
-
-
- Field
-
- 0.0.0.0
- 1.0.0.0
- 1.1.0.0
- 1.2.0.0
- 1.3.0.0
- 1.4.0.0
- 1.5.0.0
- 2.0.0.0
- Microsoft.Maui.Controls.Core
-
-
- Microsoft.Maui.Controls.BindableProperty
-
-
- Backing store for the property.
-
-
-
-
-
-
-
-
-
- Method
-
- 0.0.0.0
- 1.0.0.0
- 1.1.0.0
- 1.2.0.0
- 1.3.0.0
- 1.4.0.0
- 1.5.0.0
- 2.0.0.0
- Microsoft.Maui.Controls.Core
-
-
- System.Threading.Tasks.Task<System.Boolean>
-
-
-
-
-
-
-
- To be added.
- To be added.
- To be added.
- Animate the Progress property to value.
- A Task<bool> you can await on.
-
-
-
-
-
-
-
-
-
- Method
-
- Microsoft.Maui.Controls.Core
- 2.0.0.0
-
-
- System.Boolean
-
-
-
-
-
-
-
diff --git a/src/Controls/src/Core/ActivityIndicator/ActivityIndicator.cs b/src/Controls/src/Core/ActivityIndicator/ActivityIndicator.cs
index 306f27846196..0498db4a2c80 100644
--- a/src/Controls/src/Core/ActivityIndicator/ActivityIndicator.cs
+++ b/src/Controls/src/Core/ActivityIndicator/ActivityIndicator.cs
@@ -6,7 +6,12 @@
namespace Microsoft.Maui.Controls
{
- ///
+ ///
+ /// A visual control used to indicate that something is ongoing.
+ ///
+ ///
+ /// This control gives a visual clue to the user that something is happening, without information about its progress.
+ ///
[DebuggerDisplay("{GetDebuggerDisplay(), nq}")]
public partial class ActivityIndicator : View, IColorElement, IElementConfiguration, IActivityIndicator
{
@@ -18,20 +23,28 @@ public partial class ActivityIndicator : View, IColorElement, IElementConfigurat
readonly Lazy> _platformConfigurationRegistry;
- ///
+ ///
+ /// Initializes a new instance of the ActivityIndicator class.
+ ///
public ActivityIndicator()
{
_platformConfigurationRegistry = new Lazy>(() => new PlatformConfigurationRegistry(this));
}
- ///
+ ///
+ /// Gets or sets the color of the ActivityIndicator. This is a bindable property.
+ ///
+ /// A used to display the ActivityIndicator.
public Color Color
{
get { return (Color)GetValue(ColorElement.ColorProperty); }
set { SetValue(ColorElement.ColorProperty, value); }
}
- ///
+ ///
+ /// Gets or sets a value indicating whether the ActivityIndicator is running (animating). This is a bindable property.
+ ///
+ /// if the indicator is running; otherwise, . The default is .
public bool IsRunning
{
get { return (bool)GetValue(IsRunningProperty); }
diff --git a/src/Controls/src/Core/Border/Border.cs b/src/Controls/src/Core/Border/Border.cs
index 8b9e77ca26e5..eef7d2615adf 100644
--- a/src/Controls/src/Core/Border/Border.cs
+++ b/src/Controls/src/Core/Border/Border.cs
@@ -9,6 +9,13 @@
namespace Microsoft.Maui.Controls
{
+ ///
+ /// A container control that draws a border, background, or both around its child content.
+ ///
+ ///
+ /// Border provides a way to add visual decoration around any content. You can customize the stroke (border),
+ /// background, shape, padding, and more to create visually rich containers.
+ ///
[ContentProperty(nameof(Content))]
public class Border : View, IContentView, IBorderView, IPaddingElement, ISafeAreaElement, ISafeAreaView2
{
@@ -35,12 +42,19 @@ public class Border : View, IContentView, IBorderView, IPaddingElement, ISafeAre
/// Bindable property for .
public static readonly BindableProperty SafeAreaEdgesProperty = SafeAreaElement.SafeAreaEdgesProperty;
+ ///
+ /// Gets or sets the child content that is placed inside the border. This is a bindable property.
+ ///
+ /// A that contains the child content, or if no content is set.
public View? Content
{
get { return (View?)GetValue(ContentProperty); }
set { SetValue(ContentProperty, value); }
}
+ ///
+ /// Gets or sets the padding inside the border. This is a bindable property.
+ ///
public Thickness Padding
{
get => (Thickness)GetValue(PaddingElement.PaddingProperty);
@@ -181,6 +195,14 @@ void StopNotifyingStrokeChanges()
public static readonly BindableProperty StrokeMiterLimitProperty =
BindableProperty.Create(nameof(StrokeMiterLimit), typeof(double), typeof(Border), 10.0);
+ ///
+ /// Gets or sets the shape of the border. This is a bindable property.
+ ///
+ /// An that defines the border shape, or for the default shape.
+ ///
+ /// The default value is a . You can set this to other shapes like ,
+ /// , or any custom implementation to change the border's appearance.
+ ///
[System.ComponentModel.TypeConverter(typeof(StrokeShapeTypeConverter))]
public IShape? StrokeShape
{
@@ -188,42 +210,70 @@ public IShape? StrokeShape
get { return (IShape?)GetValue(StrokeShapeProperty); }
}
+ ///
+ /// Gets or sets the brush used to paint the border stroke. This is a bindable property.
+ ///
+ /// A used for the border stroke, or if no stroke is set.
public Brush? Stroke
{
set { SetValue(StrokeProperty, value); }
get { return (Brush?)GetValue(StrokeProperty); }
}
+ ///
+ /// Gets or sets the thickness of the border stroke. This is a bindable property.
+ ///
+ /// The stroke thickness in device-independent units. The default is 1.0.
public double StrokeThickness
{
set { SetValue(StrokeThicknessProperty, value); }
get { return (double)GetValue(StrokeThicknessProperty); }
}
+ ///
+ /// Gets or sets the pattern of dashes and gaps used to outline the border. This is a bindable property.
+ ///
+ /// A containing the dash pattern, or for a solid line.
public DoubleCollection? StrokeDashArray
{
set { SetValue(StrokeDashArrayProperty, value); }
get { return (DoubleCollection?)GetValue(StrokeDashArrayProperty); }
}
+ ///
+ /// Gets or sets the distance within the dash pattern where a dash begins. This is a bindable property.
+ ///
+ /// A representing the offset in device-independent units. The default is 0.0.
public double StrokeDashOffset
{
set { SetValue(StrokeDashOffsetProperty, value); }
get { return (double)GetValue(StrokeDashOffsetProperty); }
}
+ ///
+ /// Gets or sets the shape at the start and end of the border stroke. This is a bindable property.
+ ///
+ /// A value. The default is .
public PenLineCap StrokeLineCap
{
set { SetValue(StrokeLineCapProperty, value); }
get { return (PenLineCap)GetValue(StrokeLineCapProperty); }
}
+ ///
+ /// Gets or sets the type of join that is used at the vertices of the border stroke. This is a bindable property.
+ ///
+ /// A value. The default is .
public PenLineJoin StrokeLineJoin
{
set { SetValue(StrokeLineJoinProperty, value); }
get { return (PenLineJoin)GetValue(StrokeLineJoinProperty); }
}
+ ///
+ /// Gets or sets the limit on the ratio of the miter length to half the stroke thickness. This is a bindable property.
+ ///
+ /// The default is 10.0.
public double StrokeMiterLimit
{
set { SetValue(StrokeMiterLimitProperty, value); }
@@ -252,6 +302,10 @@ public double StrokeMiterLimit
_ => LineJoin.Round
};
+ ///
+ /// Gets the stroke dash pattern as a float array for platform rendering.
+ ///
+ /// A float array containing the dash pattern values, or for a solid line.
public float[]? StrokeDashPattern
{
get
@@ -277,6 +331,11 @@ public float[]? StrokeDashPattern
IView? IContentView.PresentedContent => Content;
+ ///
+ /// Arranges the child content within the specified bounds, accounting for stroke thickness.
+ ///
+ /// The available bounds for the border.
+ /// The actual size used by the border.
public Size CrossPlatformArrange(Graphics.Rect bounds)
{
var inset = bounds.Inset(StrokeThickness);
@@ -284,12 +343,24 @@ public Size CrossPlatformArrange(Graphics.Rect bounds)
return bounds.Size;
}
+ ///
+ /// Measures the border and its content with the given constraints.
+ ///
+ /// The available width.
+ /// The available height.
+ /// The desired size of the border.
public Size CrossPlatformMeasure(double widthConstraint, double heightConstraint)
{
var inset = Padding + StrokeThickness;
return this.MeasureContent(inset, widthConstraint, heightConstraint);
}
+ ///
+ /// Called when the property changes.
+ ///
+ /// The border instance.
+ /// The old content value.
+ /// The new content value.
public static void ContentChanged(BindableObject bindable, object oldValue, object newValue)
{
if (bindable is Border border)
@@ -308,21 +379,37 @@ public static void ContentChanged(BindableObject bindable, object oldValue, obje
((IBorderView)bindable).InvalidateMeasure();
}
+ ///
+ /// Called when the property changes.
+ ///
+ /// The border instance.
+ /// The old stroke thickness value.
+ /// The new stroke thickness value.
public static void StrokeThicknessChanged(BindableObject bindable, object oldValue, object newValue)
{
((IBorderView)bindable).InvalidateMeasure();
}
+ ///
+ /// Called when the property changes.
+ ///
+ /// The old padding value.
+ /// The new padding value.
public void OnPaddingPropertyChanged(Thickness oldValue, Thickness newValue)
{
(this as IBorderView).InvalidateMeasure();
}
+ ///
+ /// Provides the default value for the property.
+ ///
+ /// The default padding of .
public Thickness PaddingDefaultValueCreator()
{
return Thickness.Zero;
}
+ ///
protected override void OnPropertyChanged([CallerMemberName] string? propertyName = null)
{
base.OnPropertyChanged(propertyName);
@@ -370,6 +457,10 @@ SafeAreaRegions ISafeAreaView2.GetSafeAreaRegionsForEdge(int edge)
///
Thickness ISafeAreaView2.SafeAreaInsets { set { } } // Default no-op implementation for borders
+ ///
+ /// Provides the default value for the property.
+ ///
+ /// The default safe area edges of .
SafeAreaEdges ISafeAreaElement.SafeAreaEdgesDefaultValueCreator()
{
return SafeAreaEdges.None;
diff --git a/src/Controls/src/Core/BoxView/BoxView.cs b/src/Controls/src/Core/BoxView/BoxView.cs
index fdb7a9000bfd..8e802f72a35b 100644
--- a/src/Controls/src/Core/BoxView/BoxView.cs
+++ b/src/Controls/src/Core/BoxView/BoxView.cs
@@ -54,6 +54,12 @@ public IPlatformElementConfiguration On() where T : IConfigPlatfo
return _platformConfigurationRegistry.Value.On();
}
+ ///
+ /// Measures the desired size of the BoxView.
+ ///
+ /// The available width.
+ /// The available height.
+ /// A with a default size of 40x40.
[Obsolete("Use MeasureOverride instead")]
protected override SizeRequest OnMeasure(double widthConstraint, double heightConstraint)
{
@@ -61,7 +67,7 @@ protected override SizeRequest OnMeasure(double widthConstraint, double heightCo
}
#nullable enable
- // Todo these shuold be moved to a mapper
+ ///
protected override void OnPropertyChanged([CallerMemberName] string? propertyName = null)
{
base.OnPropertyChanged(propertyName);
@@ -94,6 +100,11 @@ protected override void OnPropertyChanged([CallerMemberName] string? propertyNam
float IStroke.StrokeMiterLimit => 0;
+ ///
+ /// Creates the path for the BoxView based on its bounds and corner radius.
+ ///
+ /// The bounds of the BoxView.
+ /// A representing the shape of the BoxView.
PathF IShape.PathForBounds(Rect bounds)
{
var path = new PathF();
diff --git a/src/Controls/src/Core/ContentView/ContentView.cs b/src/Controls/src/Core/ContentView/ContentView.cs
index 89c1b7ef31e6..ea256fa81f69 100644
--- a/src/Controls/src/Core/ContentView/ContentView.cs
+++ b/src/Controls/src/Core/ContentView/ContentView.cs
@@ -6,7 +6,13 @@
namespace Microsoft.Maui.Controls
{
- ///
+ ///
+ /// An element that contains a single child element.
+ ///
+ ///
+ /// ContentView is a simple container that hosts a single element through its property.
+ /// It is commonly used as a base class for custom views or to apply templates to content.
+ ///
[ContentProperty("Content")]
[DebuggerDisplay("{GetDebuggerDisplay(), nq}")]
public partial class ContentView : TemplatedView, IContentView, ISafeAreaView2, ISafeAreaElement
@@ -14,7 +20,10 @@ public partial class ContentView : TemplatedView, IContentView, ISafeAreaView2,
/// Bindable property for .
public static readonly BindableProperty ContentProperty = BindableProperty.Create(nameof(Content), typeof(View), typeof(ContentView), null, propertyChanged: TemplateUtilities.OnContentChanged);
- ///
+ ///
+ /// Gets or sets the content of the ContentView. This is a bindable property.
+ ///
+ /// A that contains the content.
public View Content
{
get { return (View)GetValue(ContentProperty); }
diff --git a/src/Controls/src/Core/DatePicker/DatePicker.cs b/src/Controls/src/Core/DatePicker/DatePicker.cs
index 63689bdd5859..a670a250674a 100644
--- a/src/Controls/src/Core/DatePicker/DatePicker.cs
+++ b/src/Controls/src/Core/DatePicker/DatePicker.cs
@@ -7,7 +7,13 @@
namespace Microsoft.Maui.Controls
{
- /// A that allows date picking.
+ ///
+ /// A view control that allows date selection.
+ ///
+ ///
+ /// The DatePicker displays a date selection interface. Users can select a date within the range
+ /// specified by and . The selected date is stored in the property.
+ ///
[DebuggerDisplay("{GetDebuggerDisplay(), nq}")]
public partial class DatePicker : View, IFontElement, ITextElement, IElementConfiguration, IDatePicker
{
@@ -101,7 +107,8 @@ public Color TextColor
set { SetValue(TextElement.TextColorProperty, value); }
}
- ///
+ /// Gets or sets the character spacing for the date picker text. This is a bindable property.
+ /// A representing the spacing between characters.
public double CharacterSpacing
{
get { return (double)GetValue(TextElement.CharacterSpacingProperty); }
@@ -122,7 +129,8 @@ public string FontFamily
set { SetValue(FontFamilyProperty, value); }
}
- /// Gets or sets the size of the font for the text in the picker.
+ /// Gets or sets the size of the font for the text in the picker. This is a bindable property.
+ /// A representing the font size.
[System.ComponentModel.TypeConverter(typeof(FontSizeConverter))]
public double FontSize
{
@@ -140,6 +148,8 @@ public bool FontAutoScalingEnabled
set => SetValue(FontAutoScalingEnabledProperty, value);
}
+ /// Gets or sets a value indicating whether the date picker is open. This is a bindable property.
+ /// if the date picker is open; otherwise, .
public bool IsOpen
{
get => (bool)GetValue(IsOpenProperty);
diff --git a/src/Controls/src/Core/Image/Image.cs b/src/Controls/src/Core/Image/Image.cs
index 41c9b2f68f79..8253c09b6313 100644
--- a/src/Controls/src/Core/Image/Image.cs
+++ b/src/Controls/src/Core/Image/Image.cs
@@ -6,7 +6,13 @@
namespace Microsoft.Maui.Controls
{
- /// that holds an image.
+ ///
+ /// A view control that displays an image.
+ ///
+ ///
+ /// The Image control supports various image sources including files, URIs, streams, and embedded resources.
+ /// Use the property to specify the image, and the property to control how the image is scaled.
+ ///
[DebuggerDisplay("{GetDebuggerDisplay(), nq}")]
public partial class Image : View, IImageController, IElementConfiguration, IViewController, IImageElement, IImage
{
@@ -30,13 +36,13 @@ public partial class Image : View, IImageController, IElementConfiguration> _platformConfigurationRegistry;
/// Initializes a new instance of the Image class.
- /// The following example creates a new image from a file
public Image()
{
_platformConfigurationRegistry = new Lazy>(() => new PlatformConfigurationRegistry(this));
}
/// Gets or sets the scaling mode for the image. This is a bindable property.
+ /// An value that determines how the image is scaled. The default is .
public Aspect Aspect
{
get { return (Aspect)GetValue(AspectProperty); }
@@ -44,23 +50,25 @@ public Aspect Aspect
}
/// Gets the loading status of the image. This is a bindable property.
- /// The following example illustrates running a
+ /// A indicating whether the image is currently loading. The default is .
+ /// This property can be used to show loading indicators while images are being loaded from remote sources.
public bool IsLoading
{
get => (bool)GetValue(IsLoadingProperty);
private set => SetValue(IsLoadingPropertyKey, value);
}
- /// Gets or sets a Boolean value that, if hints to the rendering engine that it may safely omit drawing visual elements behind the image.
- /// When this property is
- /// Setting this property does not change the opacity of the image. Instead, it indicates whether the rendering engine may treat the image as opaque while rendering.
+ /// Gets or sets a Boolean value that hints to the rendering engine that it may safely omit drawing visual elements behind the image. This is a bindable property.
+ /// A that indicates whether the image is opaque. The default is .
+ /// Setting this property does not change the visual opacity of the image. Instead, it provides a hint to the rendering engine that may improve performance by skipping the rendering of elements behind the image.
public bool IsOpaque
{
get { return (bool)GetValue(IsOpaqueProperty); }
set { SetValue(IsOpaqueProperty, value); }
}
- ///
+ /// Gets or sets a value that indicates whether animated images should play. This is a bindable property.
+ /// A that indicates whether animated images (such as GIFs) should play. The default is .
public bool IsAnimationPlaying
{
get { return (bool)GetValue(IsAnimationPlayingProperty); }
diff --git a/src/Controls/src/Core/Label/Label.cs b/src/Controls/src/Core/Label/Label.cs
index 7e68e371bb7e..f05a5071a57b 100644
--- a/src/Controls/src/Core/Label/Label.cs
+++ b/src/Controls/src/Core/Label/Label.cs
@@ -87,7 +87,8 @@ public partial class Label : View, IFontElement, ITextElement, ITextAlignmentEle
label.Text = null;
});
- ///
+ /// Gets or sets the text transformation applied to the label text. This is a bindable property.
+ /// A value that specifies how the text should be transformed.
public TextTransform TextTransform
{
get { return (TextTransform)GetValue(TextTransformProperty); }
@@ -169,7 +170,8 @@ public Color TextColor
set { SetValue(TextElement.TextColorProperty, value); }
}
- ///
+ /// Gets or sets the character spacing for the label text. This is a bindable property.
+ /// A representing the spacing between characters.
public double CharacterSpacing
{
get { return (double)GetValue(TextElement.CharacterSpacingProperty); }
@@ -233,7 +235,8 @@ public int MaxLines
set => SetValue(MaxLinesProperty, value);
}
- ///
+ /// Gets or sets the padding for the label. This is a bindable property.
+ /// A structure that represents the padding around the label content.
public Thickness Padding
{
get { return (Thickness)GetValue(PaddingProperty); }
diff --git a/src/Controls/src/Core/Picker/Picker.cs b/src/Controls/src/Core/Picker/Picker.cs
index 2092f3ec07e8..2b8f363bbf52 100644
--- a/src/Controls/src/Core/Picker/Picker.cs
+++ b/src/Controls/src/Core/Picker/Picker.cs
@@ -14,7 +14,14 @@
namespace Microsoft.Maui.Controls
{
- /// A control for picking an element in a list.
+ ///
+ /// A view control for picking an element from a list.
+ ///
+ ///
+ /// The Picker displays a list of items for the user to select from.
+ /// Users can select a single item, which is stored in the property with its index in .
+ /// The visual representation is similar to an , but displays a picker interface instead of a keyboard.
+ ///
[DebuggerDisplay("{GetDebuggerDisplay(), nq}")]
public partial class Picker : View, IFontElement, ITextElement, ITextAlignmentElement, IElementConfiguration, IPicker
{
@@ -86,13 +93,15 @@ public FontAttributes FontAttributes
}
/// Gets or sets the font family for the picker text. This is a bindable property.
+ /// The name of the font family.
public string FontFamily
{
get { return (string)GetValue(FontFamilyProperty); }
set { SetValue(FontFamilyProperty, value); }
}
- /// Gets or sets the size of the font for the text in the picker.
+ /// Gets or sets the size of the font for the text in the picker. This is a bindable property.
+ /// A representing the font size.
[System.ComponentModel.TypeConverter(typeof(FontSizeConverter))]
public double FontSize
{
@@ -100,6 +109,8 @@ public double FontSize
set { SetValue(FontSizeProperty, value); }
}
+ /// Gets or sets a value indicating whether font auto-scaling is enabled. This is a bindable property.
+ /// if font auto-scaling is enabled; otherwise, .
public bool FontAutoScalingEnabled
{
get => (bool)GetValue(FontAutoScalingEnabledProperty);
@@ -174,7 +185,8 @@ public Color TextColor
set { SetValue(TextElement.TextColorProperty, value); }
}
- ///
+ /// Gets or sets the character spacing for the picker text. This is a bindable property.
+ /// A representing the spacing between characters.
public double CharacterSpacing
{
get { return (double)GetValue(TextElement.CharacterSpacingProperty); }
@@ -189,21 +201,24 @@ public string Title
set { SetValue(TitleProperty, value); }
}
- ///
+ /// Gets or sets the color of the title text. This is a bindable property.
+ /// The of the title text.
public Color TitleColor
{
get { return (Color)GetValue(TitleColorProperty); }
set { SetValue(TitleColorProperty, value); }
}
- ///
+ /// Gets or sets the horizontal text alignment. This is a bindable property.
+ /// A value representing the horizontal alignment.
public TextAlignment HorizontalTextAlignment
{
get { return (TextAlignment)GetValue(TextAlignmentElement.HorizontalTextAlignmentProperty); }
set { SetValue(TextAlignmentElement.HorizontalTextAlignmentProperty, value); }
}
- ///
+ /// Gets or sets the vertical text alignment. This is a bindable property.
+ /// A value representing the vertical alignment.
public TextAlignment VerticalTextAlignment
{
get { return (TextAlignment)GetValue(TextAlignmentElement.VerticalTextAlignmentProperty); }
@@ -229,6 +244,8 @@ public BindingBase ItemDisplayBinding
}
}
+ /// Gets or sets a value indicating whether the picker is open. This is a bindable property.
+ /// if the picker is open; otherwise, .
public bool IsOpen
{
get => (bool)GetValue(IsOpenProperty);
diff --git a/src/Controls/src/Core/ProgressBar/ProgressBar.cs b/src/Controls/src/Core/ProgressBar/ProgressBar.cs
index f57a5817515e..3cc4d6807eaf 100644
--- a/src/Controls/src/Core/ProgressBar/ProgressBar.cs
+++ b/src/Controls/src/Core/ProgressBar/ProgressBar.cs
@@ -8,7 +8,13 @@
namespace Microsoft.Maui.Controls
{
- ///
+ ///
+ /// A view control that displays progress as a partially filled bar.
+ ///
+ ///
+ /// The ProgressBar displays progress as a horizontal bar that is filled to a percentage represented by the property.
+ /// Use the method to animate the progress bar.
+ ///
[DebuggerDisplay("{GetDebuggerDisplay(), nq}")]
public partial class ProgressBar : View, IElementConfiguration, IProgress
{
@@ -20,27 +26,41 @@ public partial class ProgressBar : View, IElementConfiguration, IPr
readonly Lazy> _platformConfigurationRegistry;
- ///
+ ///
+ /// Initializes a new instance of the ProgressBar class.
+ ///
public ProgressBar()
{
_platformConfigurationRegistry = new Lazy>(() => new PlatformConfigurationRegistry(this));
}
- ///
+ ///
+ /// Gets or sets the color of the progress bar. This is a bindable property.
+ ///
+ /// The color of the progress bar.
public Color ProgressColor
{
get { return (Color)GetValue(ProgressColorProperty); }
set { SetValue(ProgressColorProperty, value); }
}
- ///
+ ///
+ /// Gets or sets the progress value. This is a bindable property.
+ ///
+ /// A value between 0.0 and 1.0 that specifies the fraction of the bar that is filled. Values outside this range will be clamped.
public double Progress
{
get { return (double)GetValue(ProgressProperty); }
set { SetValue(ProgressProperty, value); }
}
- ///
+ ///
+ /// Animates the property from its current value to the specified value.
+ ///
+ /// The target progress value (0.0 to 1.0).
+ /// The length of the animation in milliseconds.
+ /// The easing function to use for the animation.
+ /// A task that completes when the animation finishes, with a result indicating whether the animation completed successfully.
public Task ProgressTo(double value, uint length, Easing easing)
{
var tcs = new TaskCompletionSource();
diff --git a/src/Controls/src/Core/TimePicker/TimePicker.cs b/src/Controls/src/Core/TimePicker/TimePicker.cs
index 516c1d3f01de..9cede51b747c 100644
--- a/src/Controls/src/Core/TimePicker/TimePicker.cs
+++ b/src/Controls/src/Core/TimePicker/TimePicker.cs
@@ -7,7 +7,14 @@
namespace Microsoft.Maui.Controls
{
- ///
+ ///
+ /// A view control that provides time selection.
+ ///
+ ///
+ /// The TimePicker displays a time selection interface. Users can select a time of day,
+ /// which is stored in the property as a value.
+ /// The visual representation is similar to an , but displays a time picker interface instead of a keyboard.
+ ///
[DebuggerDisplay("{GetDebuggerDisplay(), nq}")]
public partial class TimePicker : View, IFontElement, ITextElement, IElementConfiguration, ITimePicker
{
@@ -48,55 +55,62 @@ public partial class TimePicker : View, IFontElement, ITextElement, IElementConf
readonly Lazy> _platformConfigurationRegistry;
- ///
+ /// Initializes a new instance of the TimePicker class.
public TimePicker()
{
_platformConfigurationRegistry = new Lazy>(() => new PlatformConfigurationRegistry(this));
}
- ///
+ /// Gets or sets the format string for displaying the time. This is a bindable property.
+ /// A format string compatible with . The default is "t" (short time pattern).
public string Format
{
get { return (string)GetValue(FormatProperty); }
set { SetValue(FormatProperty, value); }
}
- ///
+ /// Gets or sets the text color for the time picker. This is a bindable property.
+ /// The of the text.
public Color TextColor
{
get { return (Color)GetValue(TextElement.TextColorProperty); }
set { SetValue(TextElement.TextColorProperty, value); }
}
- ///
+ /// Gets or sets the character spacing for the time picker text. This is a bindable property.
+ /// A representing the spacing between characters.
public double CharacterSpacing
{
get { return (double)GetValue(TextElement.CharacterSpacingProperty); }
set { SetValue(TextElement.CharacterSpacingProperty, value); }
}
- ///
+ /// Gets or sets the selected time. This is a bindable property.
+ /// A representing the selected time. Valid values are between 0 and 24 hours.
public TimeSpan? Time
{
get { return (TimeSpan?)GetValue(TimeProperty); }
set { SetValue(TimeProperty, value); }
}
- ///
+ /// Gets or sets a value that indicates whether the font for the time picker text is bold, italic, or neither. This is a bindable property.
+ /// A value.
public FontAttributes FontAttributes
{
get { return (FontAttributes)GetValue(FontAttributesProperty); }
set { SetValue(FontAttributesProperty, value); }
}
- ///
+ /// Gets or sets the font family for the time picker text. This is a bindable property.
+ /// The name of the font family.
public string FontFamily
{
get { return (string)GetValue(FontFamilyProperty); }
set { SetValue(FontFamilyProperty, value); }
}
- ///
+ /// Gets or sets the size of the font for the text in the time picker. This is a bindable property.
+ /// A representing the font size.
[System.ComponentModel.TypeConverter(typeof(FontSizeConverter))]
public double FontSize
{
@@ -104,12 +118,16 @@ public double FontSize
set { SetValue(FontSizeProperty, value); }
}
+ /// Gets or sets a value indicating whether font auto-scaling is enabled. This is a bindable property.
+ /// if font auto-scaling is enabled; otherwise, .
public bool FontAutoScalingEnabled
{
get => (bool)GetValue(FontAutoScalingEnabledProperty);
set => SetValue(FontAutoScalingEnabledProperty, value);
}
+ /// Gets or sets a value indicating whether the time picker is open. This is a bindable property.
+ /// if the time picker is open; otherwise, .
public bool IsOpen
{
get => (bool)GetValue(IsOpenProperty);