Skip to content

Correct the default value for Label.LineBreakMode property#3168

Merged
jfversluis merged 2 commits intodotnet:mainfrom
Tamilarasan-Paranthaman:Label-Default-LineBreakMode
Jan 13, 2026
Merged

Correct the default value for Label.LineBreakMode property#3168
jfversluis merged 2 commits intodotnet:mainfrom
Tamilarasan-Paranthaman:Label-Default-LineBreakMode

Conversation

@Tamilarasan-Paranthaman
Copy link
Member

@Tamilarasan-Paranthaman Tamilarasan-Paranthaman commented Jan 13, 2026

Description of Change:

  • The default value of the Label.LineBreakMode property has been updated from NoWrap to WordWrap to align with the actual MAUI behavior.

  • Maui actual default value in source: LineBreakMode

  • Maui Documentation Link: LineBreakMode

  • Xamarin API Reference: LineBreakMode

Issues Fixed

Fixes #3167

@learn-build-service-prod
Copy link
Contributor

PoliCheck Scan Report

The following report lists PoliCheck issues in PR files. Before you merge the PR, you must fix all severity-1 and severity-2 issues. The AI Review Details column lists suggestions for either removing or replacing the terms. If you find a false positive result, mention it in a PR comment and include this text: #policheck-false-positive. This feedback helps reduce false positives in future scans.

✅ No issues found

More information about PoliCheck

Information: PoliCheck | Severity Guidance | Term
For any questions: Try searching the learn.microsoft.com contributor guides or post your question in the Learn support channel.

@learn-build-service-prod
Copy link
Contributor

Learn Build status updates of commit 6cfceb4:

✅ Validation status: passed

File Status Preview URL Details
docs/user-interface/controls/label.md ✅Succeeded View (>=net-maui-8.0)

For more details, please refer to the build report.

@learn-build-service-prod
Copy link
Contributor

PoliCheck Scan Report

The following report lists PoliCheck issues in PR files. Before you merge the PR, you must fix all severity-1 and severity-2 issues. The AI Review Details column lists suggestions for either removing or replacing the terms. If you find a false positive result, mention it in a PR comment and include this text: #policheck-false-positive. This feedback helps reduce false positives in future scans.

✅ No issues found

More information about PoliCheck

Information: PoliCheck | Severity Guidance | Term
For any questions: Try searching the learn.microsoft.com contributor guides or post your question in the Learn support channel.

@learn-build-service-prod
Copy link
Contributor

Learn Build status updates of commit f26bb06:

✅ Validation status: passed

File Status Preview URL Details
docs/user-interface/controls/label.md ✅Succeeded View (>=net-maui-8.0)

For more details, please refer to the build report.

@jfversluis jfversluis merged commit a7f3da5 into dotnet:main Jan 13, 2026
6 checks passed
rmarinho pushed a commit to dotnet/maui that referenced this pull request Jan 13, 2026
)

The XML API documentation for `Label.LineBreakMode` was missing the
default value, creating inconsistency with the [documentation
site](dotnet/docs-maui#3168) which now correctly
specifies `WordWrap` as the default.

### Changes
- Added default value documentation to `LineBreakMode` property in
`Label.cs`
- Follows existing documentation pattern used for other bindable
properties (e.g., `Button.CommandParameter`, `Border.SafeAreaEdges`)

```csharp
/// <summary>
/// Gets or sets the LineBreakMode for the Label.
/// The default value is <see cref="LineBreakMode.WordWrap"/>. This is a bindable property.
/// </summary>
public LineBreakMode LineBreakMode
```

The default value `LineBreakMode.WordWrap` is confirmed in the
`BindableProperty.Create` definition at line 104.

<!-- START COPILOT CODING AGENT SUFFIX -->



<!-- START COPILOT ORIGINAL PROMPT -->



<details>

<summary>Original prompt</summary>

> For LineBreakMode in src/Controls/src/Core/Label/Label.cs can you
specify the default value on the API docs as also indicated here:
dotnet/docs-maui#3168


</details>



<!-- START COPILOT CODING AGENT TIPS -->
---

💡 You can make Copilot smarter by setting up custom instructions,
customizing its development environment and configuring Model Context
Protocol (MCP) servers. Learn more [Copilot coding agent
tips](https://gh.io/copilot-coding-agent-tips) in the docs.

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: jfversluis <939291+jfversluis@users.noreply.github.com>
kubaflo pushed a commit to kubaflo/maui that referenced this pull request Jan 16, 2026
…net#33490)

The XML API documentation for `Label.LineBreakMode` was missing the
default value, creating inconsistency with the [documentation
site](dotnet/docs-maui#3168) which now correctly
specifies `WordWrap` as the default.

### Changes
- Added default value documentation to `LineBreakMode` property in
`Label.cs`
- Follows existing documentation pattern used for other bindable
properties (e.g., `Button.CommandParameter`, `Border.SafeAreaEdges`)

```csharp
/// <summary>
/// Gets or sets the LineBreakMode for the Label.
/// The default value is <see cref="LineBreakMode.WordWrap"/>. This is a bindable property.
/// </summary>
public LineBreakMode LineBreakMode
```

The default value `LineBreakMode.WordWrap` is confirmed in the
`BindableProperty.Create` definition at line 104.

<!-- START COPILOT CODING AGENT SUFFIX -->



<!-- START COPILOT ORIGINAL PROMPT -->



<details>

<summary>Original prompt</summary>

> For LineBreakMode in src/Controls/src/Core/Label/Label.cs can you
specify the default value on the API docs as also indicated here:
dotnet/docs-maui#3168


</details>



<!-- START COPILOT CODING AGENT TIPS -->
---

💡 You can make Copilot smarter by setting up custom instructions,
customizing its development environment and configuring Model Context
Protocol (MCP) servers. Learn more [Copilot coding agent
tips](https://gh.io/copilot-coding-agent-tips) in the docs.

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: jfversluis <939291+jfversluis@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Label has incorrect default value for LineBreakMode

2 participants