HavenDV / H.NotifyIcon

TrayIcon for WPF/WinUI/Uno/MAUI

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

TrayToolTip doesn't work on Windows 11

PikeUK opened this issue · comments

Describe the bug

Using TrayToolTip to create a rich tooltip works on Windows 10 but on Windows 11 the XAML is ignored, instead hovering over the tray icon shows a tooltip that says "ToolTip".

Steps to reproduce the bug

Add a tb:TaskbarIcon.TrayToolTip to your tb:TaskbarIcon, e.g.:

<tb:TaskbarIcon.TrayToolTip>
    <ToolTip>
        <StackPanel>
            <Label Content="Header"
                   FontWeight="Bold" />
            <TextBlock Text="Body"
                       HorizontalAlignment="Center"
                       VerticalAlignment="Center" />
        </StackPanel>
    </ToolTip>
</tb:TaskbarIcon.TrayToolTip>

Expected behavior

A rich tooltip should appear (and does on Windows 10 but not Windows 11). Using the example above a tooltip should appear with a bolded line saying Header followed by a regular line saying Body.

Screenshots

Bug

NuGet package version

2.0.68

Platform

No response

IDE

Visual Studio 2022

Windows Version

Windows 11

WindowsAppSDK Version

No response

WindowsAppSDK Type

No response

Manifest

No response

Additional context

tb:TaskbarIcon.TooltipText works correctly in Windows 11.