【发布时间】:2020-04-20 09:13:10
【问题描述】:
如何添加扩展名为 .xaml 的 Resharper 模板?
例如,我正在尝试添加一个 Window.xaml,问题出在这一行
<Window x:Class="ADONET_Samples.UserControls.Window1" 如何在“Window1”中输入 XAML 表单的名称。
<Window x:Class="ADONET_Samples.UserControls.Window1"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:local="clr-namespace:ADONET_Samples.UserControls"
mc:Ignorable="d"
Title="Window1" Height="450" Width="800">
<Grid>
</Grid>
【问题讨论】:
-
你能更详细地解释一下你的问题吗?你想简单地输入一个字符串吗?你可以用这样的变量来做到这一点:
<Window x:Class="$Class$" -
我喜欢使用热键,在 ReSharper - ctrl+Insert 让我可以使用各种模板来自动创建类、接口等,但没有任何用于创建 Windows1.xaml 表单的各种模板。你的答案 -
标签: c# wpf visual-studio xaml