Microsoft Office 2010 使用 WPF 还是普通的旧式 MFC?

发布于 2024-11-06 00:56:55 字数 243 浏览 4 评论 0原文

我已经使用 WPF 一段时间了,我正在尝试重现他们的办公套件的一些漂亮的 UI 功能。虽然在 WPF 中非常简单,但我想知道如何使用 MFC 功能包来完成它(我可能不得不使用它,因为我的公司尚未批准使用 WPF)。由于 Fluent UI 是在 Office 2007 中引入的,我想知道 Microsoft 是否真的在 VS2010 或 Expression Blend 之外的其他应用中使用 WPF,特别是在 Office 2010 中。 我希望这个问题不是偏离主题。

I have been using WPF for some time now and I am trying to reproduce some of the nifty UI features of their office suite. Although very easy in WPF, I am wondering how it could be done using MFC feature packs (I might have to use it instead, since my company has not yet approved the use of WPF). Since the Fluent UI was introduced with Office 2007, I am wondering if Microsoft actually uses WPF in anything else than VS2010 or Expression Blend and particularly in Office 2010.
I hope that this question is not off topic.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(3

薄凉少年不暖心 2024-11-13 00:56:55

Office 2010 不使用 WPF。事实上,它也不使用MFC。 Office 传统上使用自定义 UI 工具包,甚至在功能区出现之前也是如此。但是,您只需要一个主要的第一方应用程序即可确保 WPF 作为 UI 平台的可行性。当该应用程序恰好是 Visual Studio 时尤其如此,因为每天都有数以万计的 Microsoft 员工使用 Visual Studio。

但这并不意味着 WPF 是与功能区一起使用的最佳 UI 技术。 Microsoft WPF 功能区无法正确处理许多极端情况,我测试过的所有主要商业托管代码功能区(WPF 或 Winforms)也是如此。复制 Office 功能区非常困难 - 有很多难以预料的微妙之处,只有在用户遇到极端情况时才会出现。

Office Ribbon 花费了超过 200 个人年的工作,并由数万名 Beta 测试人员使用。 (Jensen Harris 在 UX09 上估计,Office UI 团队约有 15 名 PM、30 名开发人员、30 名测试人员,以及六名设计师和 UI 研究人员。)这是经过最好测试的功能区,但不幸的是,它是 Microsoft 以外的开发人员使用的功能区不能使用。

第二最可靠的功能区框架可能是 Windows 7 功能区,Paint 和 WordPad 使用它。此功能可在 Windows 7 SDK 中使用,并已向后移植到 Vista。本机代码和 GDI,因此它面向 C++ 开发人员。请注意,它也没有绑定到 MFC。

Office 2010 does not use WPF. In fact, it doesn't use MFC either. Office has traditionally used a custom UI toolkit, and this was true even before the Ribbon came into being. However, you only need one major first-party application to secure the viability of WPF as a UI platform. This is especially true when that application happens to be Visual Studio, since tens of thousands of Microsoft employees use Visual Studio every day.

But that doesn't mean that WPF is the best UI technology to use with the Ribbon. The Microsoft WPF Ribbon handles a lot of corner cases incorrectly, as do all the major commercial managed-code Ribbons that I've tested (WPF or Winforms). It is very hard to duplicate the Office Ribbon -- there are a lot of subtleties that are difficult to anticipate and only turn up when users run into corner cases.

The Office Ribbon took over 200 man-years of work and was exercised by tens of thousands of beta testers. (Jensen Harris estimated at UX09 that the Office UI team numbered some 15 PMs, 30 developers, 30 testers, along with half a dozen designers and UI researchers.) It's the best-tested Ribbon out there, but unfortunately it's one that developers outside Microsoft can't use.

The second most reliable ribbon framework is probably the Windows 7 ribbon, which is used by Paint and WordPad. This one is available in the Windows 7 SDK, and has been backported to Vista. Native code and GDI, so it's targeted towards C++ developers. Note that it's also not tied into MFC.

少跟Wǒ拽 2024-11-13 00:56:55

据我所知它不以任何方式使用 WPF。事实上,其中大部分内容仍然是用 C++ 编写的。实际上,Microsoft 在 WPF 中发布的唯一“大型”应用程序是 Visual Studio 2010 和 Expression Blend。

As far as I know it does not use WPF in any way. In fact much of it is still written in C++. Really the only "big" applications Microsoft has released in WPF are Visual Studio 2010 and Expression Blend.

迎风吟唱 2024-11-13 00:56:55

您确实意识到 WPF(带有 .NET 框架)只是 win32 和 com(direct2d 等)之上的一层,所有这些都可以从普通的旧 C++ 访问,更不用说 MFC 了。从 2007 年起,他们就已经拥有了 C++ 的所有功能区代码,因此制作 2010 年的界面并不困难。

要回答您认为您所问的问题,不,Office 不使用 WPF。只有 Visual Studio 使用它。

You do realize WPF (with the .NET framework) is just a layer over win32 and com (direct2d, etc), all of which can be accessed from plain old C++, not to mention MFC. They already had all their ribbon code in C++ from 2007, so making the 2010 interface isn't hard.

To answer the question you think you're asking, no, Office doesn't use WPF. Only Visual Studio uses it.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文