WPF开发中最常见的错误有哪些? [英] What are the most common mistakes made in WPF development?

查看:23
本文介绍了WPF开发中最常见的错误有哪些?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

此问题旨在提供针对开发 WPF 应用程序时常见陷阱、陷阱"或设计问题的解决方案列表.这也可以包括适当的设计模式,只要有关于它为什么效果最好的解释.应根据问题类型的普遍程度对回复进行投票赞成或反对.规则如下:

This question intends to provide a list of solutions to common pitfalls, "gotcha's", or design issues when developing WPF applications. This can also include proper design-patterns as long as there is an explanation as to why it works best. Responses should be voted up or down based on how common the type of issue is. Here are the rules:

  • 每个帖子一个回复.这显然会为最常见的问题提供最高排名.
  • 最好提供指向已在 SO 土地上某处的相关帖子或解决方案的链接.

推荐答案

问题:到目前为止,我看到的主要问题是人们开始在 WPF 中编码时考虑到了 winform UI 模型.

Problem : The major issue I have seen so far is that people start coding in WPF with the winform UI model in mind.

解决方案:WPF 不是 WinForms/MFC/Win32 所以忘记你在过去 20 多年开发基于 Windows 的 UI 时使用和学习的所有 UI 方面的假设和规范年.

Solution: WPF is not WinForms/MFC/Win32 So Forget all the UI side assumptions and norms you have used and learned while developing Windows based UI for last 20+ years.

了解这个平台背后的核心思想非常重要,这个链接- 新 WPF 平台中的主要 UI 开发突破将深入介绍 WPF.其中列出了以下几点.突出显示的是我最喜欢这个平台的功能.

It is very important to understand the core ideas behind this platform, This link- Major UI Development Breakthroughs in the new WPF platform will give an in depth view of WPF. Which lists out the following points. The highlighted ones are my favorite features of this platform.

  1. 高级图形
  2. 绘图对象模型
  3. 丰富的应用文本
  4. 自适应 UI 布局
  5. 灵活的内容模型
  6. Lookless Controls
  7. 数据驱动的用户界面
  8. 风格一致
  9. 触发器
  10. 声明式编程

这篇关于WPF开发中最常见的错误有哪些?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆