CommunityToolkit / WindowsCommunityToolkit

The Windows Community Toolkit is a collection of helpers, extensions, and custom controls. It simplifies and demonstrates common developer tasks building .NET apps with UWP and the Windows App SDK / WinUI 3 for Windows 10 and Windows 11. The toolkit is part of the .NET Foundation.
https://docs.microsoft.com/windows/communitytoolkit/
Other
5.87k stars 1.37k forks source link

MarkdownTextBlock - Python not supported? #4928

Open TRadigk opened 1 year ago

TRadigk commented 1 year ago

Describe the bug

When creating a MarkdownTextBlock and setting python content, the syntax highlighting is not visible. The font is set to consolas.

Regression

No response

Reproducible in sample app?

Steps to reproduce

1. Use CommunityToolkit Sample App
2. add some python syntax (see screenshot)

Expected behavior

Python syntax highlighting is shown (e.g. print is highlighted as python syntax)

Screenshots

grafik

Windows Build Number

Other Windows Build number

Win 11 22H2 (Build 22621.2134)

App minimum and target SDK version

Other SDK version

No response

Visual Studio Version

2022

Visual Studio Build Number

17.7.1

Device form factor

Desktop

Nuget packages

<PackageReference Include="CommunityToolkit.Mvvm" Version="8.0.0" />
<PackageReference Include="CommunityToolkit.WinUI.UI.Controls.Markdown" Version="7.1.2" />
<PackageReference Include="Microsoft.WindowsAppSDK" Version="1.3.230502000" />
<PackageReference Include="Microsoft.Windows.SDK.BuildTools" Version="10.0.22621.756" />
<PackageReference Include="System.IO.Abstractions" Version="19.2.51" />
<PackageReference Include="System.IO.Ports" Version="7.0.0" />
<PackageReference Include="System.Management" Version="7.0.2" />
<PackageReference Include="System.Reactive" Version="6.0.0" />
<PackageReference Include="WinUIEx" Version="2.2.0" />

Additional context

A list of supported languages is not found, thus expected to have same language support as like on e.g. github.

Help us help you

No.

ghost commented 1 year ago

Hello TRadigk, thank you for opening an issue with us!

I have automatically added a "needs triage" label to help get things started. Our team will analyze and investigate the issue, and escalate it to the relevant team if possible. Other community members may also look into the issue and provide feedback 🙌

michael-hawker commented 1 year ago

Python was added to the underlying ColorCode library here - https://github.com/CommunityToolkit/ColorCode-Universal/pull/15

We just haven't updated this control since. This control won't ship in 8.0 though, a replacement is still being worked on in Windows Community Toolkit Labs here: https://github.com/CommunityToolkit/Labs-Windows/pull/480

That should hopefully get merged in after we release 8.0 and update Labs infrastructure with the improvements we've made for our new release.

TRadigk commented 6 months ago

@michael-hawker Any news? I found a merged PR of a possible successor but no chance to test it. It is not included when I start the sample app for the browser.