简体   繁体   English

禁用XAML UI设计器

[英]Disable XAML UI designer

How to disable XAML designer in VS 2011. 如何在VS 2011中禁用XAML设计器。

I have checked following links possible to default-disable XAML designer in VS 2008? 在VS 2008中检查了以下可能的默认禁用XAML设计器链接

http://www.dolittle.com/blogs/einar/archive/2008/04/24/quot-disable-quot-xaml-designer-in-visual-studio-2008.aspx http://www.dolittle.com/blogs/einar/archive/2008/04/24/quot-disable-quot-xaml-designer-in-visual-studio-2008.aspx

http://weblogs.asp.net/alexeyzakharov/archive/2010/01/27/disable-visual-studio-xaml-designer-better-way.aspx http://weblogs.asp.net/alexeyzakharov/archive/2010/01/27/disable-visual-studio-xaml-designer-better-way.aspx

Problem with above is that intellisense also goes away with setting different text editor. 上面的问题是intellisense也随着设置不同的文本编辑器而消失。

In Visual Studio 2015 you can completely turn off the XAML designer in: 在Visual Studio 2015中,您可以完全关闭XAML设计器:

Tools->Options->XAML Designer\\Enable XAML Designer

XAML Designer在Visual Studio 2015中切换位置

For Visual Studio 2012 the Link "user1007074" provided ( http://blog.spinthemoose.com/2013/03/24/disable-the-xaml-designer-in-visual-studio/ ) tells: 对于Visual Studio 2012 ,提供的链接“user1007074”( http://blog.spinthemoose.com/2013/03/24/disable-the-xaml-designer-in-visual-studio/ )告诉:

In the Tools –> Options menu, open the Text Editor node, then the XAML node, then select the Miscellaneous node; 在工具 - >选项菜单中,打开文本编辑器节点,然后打开XAML节点,然后选择其他节点; make sure that under the Default View heading there is a checkbox beside Always open documents in full XAML view. 确保在“ 默认视图”标题下,“在完全XAML视图中始终打开文档”旁边有一个复选框。

also he suggest 他也建议

Right-click on any .xaml file in your solution explorer and select Open With… 右键单击解决方案资源管理器中的任何.xaml文件,然后选择打开方式...

Choose editor and click "Set as Default". 选择编辑器,然后单击“设为默认值”。 Many Thanks to David Alpert! 非常感谢David Alpert!

In Visual Studio 2015/2017 : 在Visual Studio 2015/2017中

  • In the Tools -> Otions menu, open the XAML Designer node, then uncheck "Enable XAML Designer" 在Tools - > Otions菜单中,打开XAML Designer节点,然后取消选中“Enable XAML Designer”

VS 2017选项对话框,用于将默认文档视图设置为源视图或禁用XAML Designer

As Mark Bell pointed out, it can be enough to set the Default document view to Source View, and leave XAML Designer enabled. 正如Mark Bell指出的那样,将Default文档视图设置为Source View就足够了,并且启用了XAML Designer。

This applies for VS2012, maybe also other versions: 这适用于VS2012,也许还有其他版本:

In VS Installation rename XDesProc.exe to XDesProc.exe.bak 在VS安装中,将XDesProc.exe重命名为XDesProc.exe.bak

For me it was: C:\\Program Files (x86)\\Microsoft Visual Studio 11.0\\Common7\\IDE\\XDesProc.exe 对我来说它是:C:\\ Program Files(x86)\\ Microsoft Visual Studio 11.0 \\ Common7 \\ IDE \\ XDesProc.exe

This way it has the best performance gain. 这样它可以获得最佳性能。 The process won't start and VisualStudio will show an undisturbing exception window instead of the designer. 该过程将无法启动,VisualStudio将显示一个不受干扰的异常窗口而不是设计器。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM