UToolKit 0.0.8.1-alpha
.NET 5.0
This package targets .NET 5.0. The package is compatible with this framework or higher.
.NET Core 3.0
This package targets .NET Core 3.0. The package is compatible with this framework or higher.
.NET Framework 4.5
This package targets .NET Framework 4.5. The package is compatible with this framework or higher.
This is a prerelease version of UToolKit.
There is a newer version of this package available.
See the version list below for details.
See the version list below for details.
dotnet add package UToolKit --version 0.0.8.1-alpha
NuGet\Install-Package UToolKit -Version 0.0.8.1-alpha
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="UToolKit" Version="0.0.8.1-alpha" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add UToolKit --version 0.0.8.1-alpha
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
#r "nuget: UToolKit, 0.0.8.1-alpha"
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
// Install UToolKit as a Cake Addin #addin nuget:?package=UToolKit&version=0.0.8.1-alpha&prerelease // Install UToolKit as a Cake Tool #tool nuget:?package=UToolKit&version=0.0.8.1-alpha&prerelease
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
UToolKit
Library that contains useful tools for WPF application.
It is recommended to use this library with Fody.PropertyChanged.
Release notes:
- Added
RelaySingleTaskAsyncCommand
. - Added
DesignModeVerifier
. - Added more documentation.
Main features:
- ObservableObject (
INotifyPropertyChanged
implementation) - IRefreshableCommand (inherits
ICommand
, allows to callICommand.CanExecuteChanged
manually) - RelayCommand (
IRefreshableCommand
implementation) - RelayAsyncCommand (
IRefreshableCommand
async implementation) - RelaySingleTaskAsyncCommand (
IRefreshableCommand
async implementation, designed for single task execution)
Converters:
- InverseBooleanConverter
- BooleanToVisibilityConverter
- BooleanToHiddenVisibilityConverter
- InverseBooleanToHiddenVisibilityConverter
- InverseBooleanToVisibilityConverter
Extensions:
- HyperlinkExtensions
IsExternal
- iftrue
Hyperlink will executeProcess.Start
usingHyperlink.NavigateUri
after click.
- WindowExtensions
CloseCommand
- command which executes on windows closing. IfICommand.CanExecute()
returns false - window closing will be cancalled.CloseCommandParameter
- parameter forCloseCommand
.PlacementStorageStrategy
- window placement storage strategy. There are 2 different implemented strategies,RegistryStorage
andSettingsStorage
. It is possible to implement custom strategy usingIWindowPlacementStorage
.
- RoutedCommand bindings - allows to bind
ICommand
toRoutedCommand
.
Services:
- IWindowService - (implementation: WindowService)
IsActive
- indicates whether the window is active.IsVisible
- indicates whether the window is visible.Activate()
- attempts to brind the window to the foreground and activates it.Close()
- closes window.Close(bool dialogResult)
- closes window with specified dialog result.Hide()
- hides window.Show()
- shows window.
- ITextBoxService - (implementation: TextBoxService)
- event
TextChanged
- informs that the text has changed. - event
SelectionChanged
- informs that the selection has changed. Text
- allows to get or set text toTextBox
(will not break bindings).CaretIndex
- gets current caret index.SelectionLength
- gets selected text length.SelectedText
- gets or sets selected text in text box (will not break bindings).Select(int start, int length)
- selects a range of text in text box.SelectAll()
- selects all text in text box.
- event
- IPasswordSupplier - (implementation: PasswordSupplier)
- event
PasswordChanged
- occurs when the password of thePasswordBox
changes. Password
- allows to get or set password from/toPasswordBox
.SecurePassword
- gets secure password fromPasswordBox
.Clear()
- clears all password.
- event
Getting started.
First you need to include namespace to your code or markup.
For XAML it can look like:
<Window xmlns:tk="https://github.com/nullsoftware/UToolKit" />
And for C#:
using NullSoftware;
using NullSoftware.Services;
using NullSoftware.ToolKit;
using NullSoftware.ToolKit.Converters;
using NullSoftware.ToolKit.Extensions;
How to set PlacementStorageStrategy
:
<Window xmlns:tk="https://github.com/nullsoftware/UToolKit"
xmlns:prop="clr-namespace:ExampleProject.Properties"
tk:WindowExtensions.PlacementStorageStrategy="{tk:RegistryStorage}" />
or
<Window xmlns:tk="https://github.com/nullsoftware/UToolKit"
xmlns:prop="clr-namespace:ExampleProject.Properties"
tk:WindowExtensions.PlacementStorageStrategy="{tk:SettingsStorage Settings={x:Static prop:Settings.Default}}" />
How to use RoutedCommandHandlers
:
<Window xmlns:tk="https://github.com/nullsoftware/UToolKit">
<tk:RoutedCommandHandlers.Commands>
<tk:RoutedCommandHandler RoutedCommand="ApplicationCommands.Create" Command="{Binding CreateCommand}"/>
<tk:RoutedCommandHandler RoutedCommand="ApplicationCommands.Open" Command="{Binding OpenCommand}"/>
</tk:RoutedCommandHandlers.Commands>
<Grid>
<Grid.RowDefinitions>
<RowDefinition Height="Auto"/>
<RowDefinition/>
</Grid.RowDefinitions>
<Menu Grid.Row="0">
<MenuItem Header="_File">
<MenuItem Header="_New" Command="ApplicationCommands.Create" />
<MenuItem Header="_Open" Command="ApplicationCommands.Open" />
</MenuItem>
</Menu>
</Grid>
</Window>
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | net5.0 was computed. net5.0-windows was computed. net5.0-windows7.0 is compatible. net6.0 was computed. net6.0-android was computed. net6.0-ios was computed. net6.0-maccatalyst was computed. net6.0-macos was computed. net6.0-tvos was computed. net6.0-windows was computed. net7.0 was computed. net7.0-android was computed. net7.0-ios was computed. net7.0-maccatalyst was computed. net7.0-macos was computed. net7.0-tvos was computed. net7.0-windows was computed. net8.0 was computed. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. |
.NET Core | netcoreapp3.0 is compatible. netcoreapp3.1 is compatible. |
.NET Framework | net45 is compatible. net451 is compatible. net452 is compatible. net46 is compatible. net461 is compatible. net462 is compatible. net463 was computed. net47 is compatible. net471 is compatible. net472 is compatible. net48 is compatible. net481 was computed. |
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
-
.NETCoreApp 3.0
- No dependencies.
-
.NETCoreApp 3.1
- No dependencies.
-
.NETFramework 4.5
- No dependencies.
-
.NETFramework 4.5.1
- No dependencies.
-
.NETFramework 4.5.2
- No dependencies.
-
.NETFramework 4.6
- No dependencies.
-
.NETFramework 4.6.1
- No dependencies.
-
.NETFramework 4.6.2
- No dependencies.
-
.NETFramework 4.7
- No dependencies.
-
.NETFramework 4.7.1
- No dependencies.
-
.NETFramework 4.7.2
- No dependencies.
-
.NETFramework 4.8
- No dependencies.
-
net5.0-windows7.0
- No dependencies.
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
Version | Downloads | Last updated |
---|---|---|
1.1.1 | 216 | 5/17/2023 |
1.1.0.1 | 270 | 2/25/2023 |
1.1.0 | 249 | 2/24/2023 |
1.0.2 | 262 | 2/24/2023 |
1.0.1.1 | 302 | 1/28/2023 |
1.0.0.1 | 331 | 12/18/2022 |
1.0.0 | 325 | 12/16/2022 |
0.0.8.1-alpha | 169 | 12/16/2022 |
0.0.8-alpha | 170 | 12/16/2022 |
0.0.7.8-alpha | 172 | 11/12/2022 |
0.0.7.4-alpha | 199 | 8/12/2022 |
0.0.7.2-alpha | 208 | 5/11/2022 |
0.0.7.1-alpha | 184 | 5/10/2022 |
0.0.7-alpha | 192 | 5/10/2022 |
0.0.6-alpha | 200 | 4/27/2022 |
0.0.4-preview | 204 | 4/7/2022 |
0.0.3-preview | 188 | 4/7/2022 |
0.0.2-preview | 188 | 4/2/2022 |
0.0.1-preview | 194 | 4/1/2022 |
Hot fix.