Skip to content

Commit

Permalink
Merge branch 'release/v23.1.1' into main
Browse files Browse the repository at this point in the history
  • Loading branch information
billhenn committed Nov 14, 2023
2 parents 081550f + d30756f commit 606271e
Show file tree
Hide file tree
Showing 59 changed files with 1,665 additions and 158 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/integration-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ jobs:
with:
fetch-depth: 0
- name: Run build project
run: dotnet run --project ./Build/Build.csproj -- --target IntegrationBuild"
run: dotnet run --project ./Build/Build.csproj -- --target IntegrationBuild
- name: Notify Slack
if: always()
uses: act10ns/slack@v2
Expand Down
8 changes: 6 additions & 2 deletions .nuke/build.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -65,9 +65,13 @@
"type": "string",
"description": "Root directory during build execution"
},
"SampleBrowserSolution": {
"SampleBrowserDesktopSolution": {
"type": "string",
"description": "Path to a solution file that is automatically loaded. Default is Samples/SampleBrowser/SampleBrowser.sln"
"description": "Path to a solution file that is automatically loaded. Default is Samples/SampleBrowser/SampleBrowser.Desktop.sln"
},
"SampleBrowserWebSolution": {
"type": "string",
"description": "Path to a solution file that is automatically loaded. Default is Samples/SampleBrowser/SampleBrowser.Web.sln"
},
"Skip": {
"type": "array",
Expand Down
9 changes: 6 additions & 3 deletions Build/Build.cs
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,13 @@ public partial class Build : NukeBuild {

#region Solutions

[Solution("Samples/SampleBrowser/SampleBrowser.sln")]
readonly Solution SampleBrowserSolution;
[Solution("Samples/SampleBrowser/SampleBrowser.Desktop.sln")]
readonly Solution SampleBrowserDesktopSolution;

[Solution("Samples/SampleBrowser/SampleBrowser.Web.sln")]
readonly Solution SampleBrowserWebSolution;

Solution[] SampleSolutions => new Solution[] { SampleBrowserSolution }; // MSBuild
Solution[] SampleSolutions => new Solution[] { SampleBrowserDesktopSolution, SampleBrowserWebSolution }; // MSBuild

#endregion

Expand Down
8 changes: 8 additions & 0 deletions Documentation/api-filter.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,13 @@
apiRules:

# Include EditorBrowsableState.Never in Actipro namespaces (excluded by default)
- include:
uidRegex: ^ActiproSoftware\.
hasAttribute:
uid: System.ComponentModel.EditorBrowsableAttribute
ctorArguments:
- System.ComponentModel.EditorBrowsableState.Never

# Exclude compatibility and core product code
- exclude:
uidRegex: ^ActiproSoftware\.Compatibility$
Expand Down
2 changes: 1 addition & 1 deletion Documentation/docfx.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
{
"src": [
{
"src": "../../Source/bin/Release/net6.0",
"src": "../../Deploy/Build/AssembliesDocFX",
"files": [
// Actipro assemblies
"ActiproSoftware.*.dll"
Expand Down
2 changes: 2 additions & 0 deletions Documentation/topics/conversion/.toc-generator.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
title: "Conversion Notes"
order: 42
24 changes: 24 additions & 0 deletions Documentation/topics/conversion/converting-to-v23-1.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
---
title: "Converting to v23.1"
page-title: "Converting to v23.1 - Conversion Notes"
order: 10
---
# Converting to v23.1

While v23.1.0 was the first public release version, some updates were made in maintenance releases that are described below.

## User Interface Density Changes

v23.1.1 introduced the concept of user interface density, a configurable way to set how spacious a user interface layout should appear. v23.1.0 shipped with what is effectively now the `Spacious` density option, which is very touch friendly. v23.1.1 has updated the default to be the `Normal` density option, resulting in a slightly more compact layout out of the box.

The [User Interface Density](../themes/user-interface-density.md) topic discusses the density feature in detail and how to change it both initially and at any point later at run-time. Use code in that topic to adjust the density if you prefer the old `Spacious` density option or the even more dense desktop-oriented `Compact` density option for your application.

## Theme Definition Changes

### ScrollBar Thumbs

v23.1.0 used to have a `ScrollBarThumbMargin` property on [ThemeDefinition](xref:@ActiproUIRoot.Themes.Generation.ThemeDefinition) that would keep the thumb ascent relative to the containing scrollbar track size. Scrollbar thumb sizing has been refactored in v23.1.1 and is much more flexible. The new design allows for fixed thumb thicknesses, or alternatively having the thumb size relative to the containing track size. Thumbs now default to a slightly thinner fixed `4.0` thickness instead of the previous effective value of `6.0`. Set both the [ScrollBarThumbMinAscent](xref:@ActiproUIRoot.Themes.Generation.ThemeDefinition.ScrollBarThumbMinAscent) and [ScrollBarThumbMaxAscent](xref:@ActiproUIRoot.Themes.Generation.ThemeDefinition.ScrollBarThumbMaxAscent) properties to `6.0` if the previous appearance is desired.

### MenuItem Padding

v23.1.0 used to have a `MenuItemPadding` property on [ThemeDefinition](xref:@ActiproUIRoot.Themes.Generation.ThemeDefinition), but that property was removed in v23.1.1 since the padding applied to menu items now automatically scales based on UI density.
12 changes: 12 additions & 0 deletions Documentation/topics/conversion/index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
---
title: "Overview"
page-title: "Conversion Notes"
order: 1
---
# Overview

Occasionally during large updates to a product, some breaking changes are necessary to either add enhanced functionality or improve the overall design of the various products.

Read the following topics that are appropriate for your scenario if you are converting from an older version to the latest version.

- [Converting to v23.1](converting-to-v23-1.md)
72 changes: 71 additions & 1 deletion Documentation/topics/fundamentals/user-prompt/appearance.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,16 +17,24 @@ When either the [HeaderBackground](xref:@ActiproUIRoot.Controls.UserPromptContro

## Images

@if (avalonia) {
Any `IImage` can be set to the [StatusImage](xref:@ActiproUIRoot.Controls.UserPromptControl.StatusImage) or [FooterImage](xref:@ActiproUIRoot.Controls.UserPromptControl.FooterImage) properties for a custom look. When using the [builder pattern](builder-pattern.md), set the `IImage` using [WithStatusImage](xref:@ActiproUIRoot.Controls.UserPromptBuilder.WithStatusImage*) or [WithFooterImage](xref:@ActiproUIRoot.Controls.UserPromptBuilder.WithFooterImage*).

The images used by [MessageBoxImage](xref:@ActiproUIRoot.Controls.MessageBoxImage) can also be customized by assigning a custom [ImageProvider](xref:@ActiproUIRoot.Media.ImageProvider) to the [ImageProvider](xref:@ActiproUIRoot.Media.ImageProvider).[Default](xref:@ActiproUIRoot.Media.ImageProvider.Default) property. Each value for [MessageBoxImage](xref:@ActiproUIRoot.Controls.MessageBoxImage) corresponds to a key of the same name defined by [SharedImageKeys](xref:@ActiproUIRoot.Media.SharedImageKeys). For example, the image [MessageBoxImage](xref:@ActiproUIRoot.Controls.MessageBoxImage).[Warning](xref:@ActiproUIRoot.Controls.MessageBoxImage.Warning) corresponds to the key [SharedImageKeys](xref:@ActiproUIRoot.Media.SharedImageKeys).[Warning](xref:@ActiproUIRoot.Media.SharedImageKeys.Warning). A custom class which derives from [ImageProvider](xref:@ActiproUIRoot.Media.ImageProvider) can override the [ImageProvider](xref:@ActiproUIRoot.Media.ImageProvider).[GetImageSource](xref:@ActiproUIRoot.Media.ImageProvider.GetImageSource*) method to return a custom `IImage` for one or more of those keys.
}
@if (wpf) {
Any `ImageSource` can be set to the [StatusImageSource](xref:@ActiproUIRoot.Controls.UserPromptControl.StatusImageSource) or [FooterImageSource](xref:@ActiproUIRoot.Controls.UserPromptControl.FooterImageSource) properties for a custom look. When using the [builder pattern](builder-pattern.md), set the `ImageSource` using [WithStatusImage](xref:@ActiproUIRoot.Controls.UserPromptBuilder.WithStatusImage*) or [WithFooterImage](xref:@ActiproUIRoot.Controls.UserPromptBuilder.WithFooterImage*).

The images used by [UserPromptStandardImage](xref:@ActiproUIRoot.Controls.UserPromptStandardImage) can also be customized by assigning a custom [ImageProvider](xref:@ActiproUIRoot.Media.ImageProvider) to the [ImageProvider](xref:@ActiproUIRoot.Media.ImageProvider).[Default](xref:@ActiproUIRoot.Media.ImageProvider.Default) property. Each value for [UserPromptStandardImage](xref:@ActiproUIRoot.Controls.UserPromptStandardImage) corresponds to a key of the same name defined by [SharedImageKeys](xref:@ActiproUIRoot.Media.SharedImageSourceKeys). For example, the image [UserPromptStandardImage](xref:@ActiproUIRoot.Controls.UserPromptStandardImage).[Warning](xref:@ActiproUIRoot.Controls.UserPromptStandardImage.Warning) corresponds to the key [SharedImageSourceKeys](xref:@ActiproUIRoot.Media.SharedImageSourceKeys).[Warning](xref:@ActiproUIRoot.Media.SharedImageSourceKeys.Warning). A custom class which derives from [ImageProvider](xref:@ActiproUIRoot.Media.ImageProvider) can override the [ImageProvider](xref:@ActiproUIRoot.Media.ImageProvider).[GetImageSource](xref:@ActiproUIRoot.Media.ImageProvider.GetImageSource*) method to return a custom `ImageSource` for one or more of those keys.
}

## Customize UserPromptWindow

The [UserPromptWindow](xref:@ActiproUIRoot.Controls.UserPromptWindow) does not have a public constructor and is only created by the [UserPromptWindow](xref:@ActiproUIRoot.Controls.UserPromptWindow).[ShowDialog](xref:@ActiproUIRoot.Controls.UserPromptWindow.ShowDialog*) method. One of the arguments for [ShowDialog](xref:@ActiproUIRoot.Controls.UserPromptWindow.ShowDialog*) allows you to pass an `Action<UserPromptWindow>` which is invoked with a reference to the [UserPromptWindow](xref:@ActiproUIRoot.Controls.UserPromptWindow) after it is configured, but before it is shown. This callback allows the [UserPromptWindow](xref:@ActiproUIRoot.Controls.UserPromptWindow) to be customized.

The following code demonstrates using the callback to customize the flow direction of the window:

@if (avalonia) {
```csharp
var userPromptControl = new UserPromptControl() { ... };
Window owner = null; // Use default
Expand All @@ -39,9 +47,25 @@ await UserPromptWindow.ShowDialog(
window.FlowDirection = FlowDirection.RightToLeft;
});
```
}
@if (wpf) {
```csharp
var userPromptControl = new UserPromptControl() { ... };
Window owner = null; // Use default
UserPromptWindow.ShowDialog(
userPromptControl,
"Window Title",
owner,
window => {
window.FlowDirection = FlowDirection.RightToLeft;
});
```
}

The [builder pattern](builder-pattern.md) exposes the same customization using the [AfterInitializeWindow](xref:@ActiproUIRoot.Controls.UserPromptBuilder.AfterInitializeWindow*) callback as shown in the following example:

@if (avalonia) {
```csharp
await UserPromptBuilder.Configure()
// ... other configuration options here
Expand All @@ -50,7 +74,19 @@ await UserPromptBuilder.Configure()
})
.Show();
```
}
@if (wpf) {
```csharp
UserPromptBuilder.Configure()
// ... other configuration options here
.AfterInitializeWindow(window => {
window.FlowDirection = FlowDirection.RightToLeft;
})
.Show();
```
}

@if (avalonia) {
Finally, an advanced configuration of [MessageBox](message-box.md) also allows access to the [builder pattern](builder-pattern.md) as shown below:

```csharp
Expand All @@ -61,4 +97,38 @@ await MessageBox.Show(
window.FlowDirection = FlowDirection.RightToLeft;
})
);
```
```
}
@if (wpf) {
Finally, an advanced configuration of [ThemedMessageBox](message-box.md) also allows access to the [builder pattern](builder-pattern.md) as shown below:

```csharp
ThemedMessageBox.Show(
"Use the optional 'configure' parameter to access the UserPromptBuilder."
configure: builder => builder
.AfterInitializeWindow(window => {
window.FlowDirection = FlowDirection.RightToLeft;
})
);
```
}

@if (wpf) {
## Theme Assets

See the [Theme Reusable Assets](../../../themes/reusable-assets.md) topic for more details on using and customizing theme assets. The following reusable assets are used by [UserPromptControl](xref:@ActiproUIRoot.Controls.UserPromptControl):

| Asset Resource Key | Description |
|-----|-----|
| [ContainerForegroundLowestNormalBrushKey](xref:@ActiproUIRoot.Themes.AssetResourceKeys.ContainerForegroundLowestNormalBrushKey) | Assigned to the following properties: `Foreground`. |
| [ContainerBackgroundLowestBrushKey](xref:@ActiproUIRoot.Themes.AssetResourceKeys.ContainerBackgroundLowestBrushKey) | Assigned to the following properties: `Background`. |
| [ContainerForegroundLowNormalBrushKey](xref:@ActiproUIRoot.Themes.AssetResourceKeys.ContainerForegroundLowNormalBrushKey) | Assigned to the following properties: [TrayForeground](xref:@ActiproUIRoot.Controls.UserPromptControl.TrayForeground). |
| [ContainerBackgroundLowBrushKey](xref:@ActiproUIRoot.Themes.AssetResourceKeys.ContainerBackgroundLowBrushKey) | Assigned to the following properties: [TrayBackground](xref:@ActiproUIRoot.Controls.UserPromptControl.TrayBackground). |
| [ContainerBorderLowBrushKey](xref:@ActiproUIRoot.Themes.AssetResourceKeys.ContainerBorderLowBrushKey) | Assigned to the following properties: `BorderBrush`. |
| [PrimaryAccentForegroundLowestNormalBrushKey](xref:@ActiproUIRoot.Themes.AssetResourceKeys.PrimaryAccentForegroundLowestNormalBrushKey) | Assigned to the following properties: [HeaderForeground](xref:@ActiproUIRoot.Controls.UserPromptControl.HeaderForeground). |
| [ExtraLargeFontSizeDoubleKey](xref:@ActiproUIRoot.Themes.AssetResourceKeys.ExtraLargeFontSizeDoubleKey) | Assigned to the following properties: [HeaderFontSize](xref:@ActiproUIRoot.Controls.UserPromptControl.HeaderFontSize). |
| [ContainerForegroundLowDisabledBrushKey](xref:@ActiproUIRoot.Themes.AssetResourceKeys.ContainerForegroundLowDisabledBrushKey) | Used for the focus rectangle of the **Expanded Information** toggle. |
| [ButtonForegroundHoverBrushKey](xref:@ActiproUIRoot.Themes.AssetResourceKeys.ButtonForegroundHoverBrushKey) | Assigned to the following properties of the **Expanded Information** toggle when the mouse is over the control: `Foreground`. |
| [ButtonForegroundPressedBrushKey](xref:@ActiproUIRoot.Themes.AssetResourceKeys.ButtonForegroundPressedBrushKey) | Assigned to the following properties of the **Expanded Information** toggle when pressed: `Foreground`. |
| [ContainerForegroundLowDisabledBrushKey](xref:@ActiproUIRoot.Themes.AssetResourceKeys.ContainerForegroundLowDisabledBrushKey) | Assigned to the following properties of the **Expanded Information** toggle when disabled: `Foreground`. |
}
Loading

0 comments on commit 606271e

Please sign in to comment.