Proposal: Remove restriction to only allow event triggers in FrameworkElement.Triggers collection
- Dominant language
- C#
- Stars
- 7.7k
- Forks
- 1.3k
- Avg merge
- 1d 11h
- Merged PRs (30d)
- 61
Description
# Current Situation
Currently, property triggers are only available by takting the detour using the [`FrameworkElement.Style`](https://learn.microsoft.com/en-us/dotnet/api/system.windows.frameworkelement.style) property and its [`Style.Triggers`](https://learn.microsoft.com/en-us/dotnet/api/system.windows.style.triggers) collection. Assigning a property trigger immediately to the [`FrameworkElement.Triggers`](https://learn.microsoft.com/en-us/dotnet/api/system.windows.frameworkelement.triggers) collection raises an error.
This restriction makes no sense and is a quirk that's repeatedly causing confusion and unneccessary ado.
# Desired Situation
I propose to remove the current artificial restriction for the `FrameworkElement.Triggers` collection that's constraining it to only accept event triggers and to harmonize the `FrameworkElement.Triggers` collection's feature set with the `Style.Triggers` feature set.
Contributor guide
Assessment
This issue has not been assessed yet.