您的位置:首页 > 其它

WPF 升级 .NET Core 的理由

2020-04-15 14:39 585 查看

本文列举一些让 WPF 升级 .NET Core 的理由

提供更多的 API 同时提升运行性能

为了支持 Win7 系统,限制了 .NET Framework 升级版本

当前我团队的 .NET Framework 使用 4.5 但是如果使用 dotnet core 能使用更多的 API 同时这些 API 都优化了大部分性能

启动性能优化

在 dotnet core 2.2 提供的阶梯编译,可以提升启动过程的 JIT 编译速度

环境问题

可以全添加所有依赖的包,可以解决 .NET Framework 环境问题

修复 D3D Compile47 问题

Adding d3d_compiler dependency to known issues by rladuca · Pull Request #190 · dotnet/wpf

WPF Applications require crash with System.TypeLoadException when VC++ redistributables are not present · Issue #37 · dotnet/wpf

更多关于 D3D Compile47 问题,请看 win7 无法启动 WPF 程序 D3Dcompiler_47.dll 丢失

触摸问题修复

修复特定硬件带崩软件

修复特定硬件带崩软件,需要在 .NET 4.7.1 和 Win10 系统才能生效

dotnet/481090-WPF Touch generates NullReferenceException in ProcessInputReport.md at master · Microsoft/dotnet

This issue is fixed for all supported OS platforms prior to Windows 10 Fall Creators Update. The fix for Windows 10 Fall Creators Update is expected in a future servicing update.

 System.Windows.Input.StylusWisp.WispLogic.ProcessInputReport(RawStylusInputReport inputReport)
System.Windows.Input.PenContext.FirePackets(Int32 stylusPointerId, Int32[] data, Int32 timestamp)
System.Windows.Input.PenThreadWorker.FlushCache(Boolean goingOutOfRange)
System.Windows.Input.PenThreadWorker.ThreadProc()
System.Threading.ThreadHelper.ThreadStart_Context(Object state)
System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
System.Threading.ThreadHelper.ThreadStart()

书写索引超出了数组界限

此问题已经报告微软 Throw IndexOutOfRangeException in WispLogic.CoalesceAndQueueStylusEvent · Issue #935 · dotnet/wpf

在 System.Collections.Generic.Dictionary`2.Insert(TKey key, TValue value, Boolean add)
在 System.Windows.Input.StylusWisp.WispLogic.CoalesceAndQueueStylusEvent(RawStylusInputReport inputReport)
在 System.Windows.Input.StylusWisp.WispLogic.ProcessInputReport(RawStylusInputReport inputReport)
在 System.Windows.Input.PenContext.FirePackets(Int32 stylusPointerId, Int32[] data, Int32 timestamp)
在 System.Windows.Input.PenThreadWorker.FlushCache(Boolean goingOutOfRange)
在 System.Windows.Input.PenThreadWorker.FireEvent(PenContext penContext, Int32 evt, Int32 stylusPointerId, Int32 cPackets, Int32 cbPacket, IntPtr pPackets)
在 System.Windows.Input.PenThreadWorker.ThreadProc()
在 System.Threading.ThreadHelper.ThreadStart_Context(Object state)
在 System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
在 System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
在 System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
在 System.Threading.ThreadHelper.ThreadStart()

ExceptionType: System.IndexOutOfRangeException
ExceptionMessage: 索引超出了数组界限

触摸事件

在 .NET Core 和 .NET Framework 4.8 修复了在 StylusUp 抛异常等让下次触摸失效

Popup 修复

Popup 触摸问题

修复 Popup 触摸失效,需要在 .NET 4.7.1 和 Win10 系统才能生效

dotnet/479874-WPF Touch Stops Working After Prolonged Use of Popups.md at master · Microsoft/dotnet

我搭建了自己的博客 https://blog.lindexi.com/ 欢迎大家访问,里面有很多新的博客。只有在我看到博客写成熟之后才会放在csdn或博客园,但是一旦发布了就不再更新

如果在博客看到有任何不懂的,欢迎交流,我搭建了 dotnet 职业技术学院 欢迎大家加入

如有不方便在博客评论的问题,可以加我 QQ 2844808902 交流


本作品采用知识共享署名-非商业性使用-相同方式共享 4.0 国际许可协议进行许可。欢迎转载、使用、重新发布,但务必保留文章署名林德熙(包含链接:http://blog.csdn.net/lindexi_gd ),不得用于商业目的,基于本文修改后的作品务必以相同的许可发布。如有任何疑问,请与我联系

  • 点赞
  • 收藏
  • 分享
  • 文章举报
lindexi_gd 博客专家 发布了1439 篇原创文章 · 获赞 1001 · 访问量 137万+ 他的留言板 关注
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签:  .net framework