Browse Source

updated WinFX templates for WinFX CTP May 2006

git-svn-id: svn://svn.sharpdevelop.net/sharpdevelop/branches/2.0@1454 1ccf3a8d-04fe-1044-b7c0-cef0b8235c61
shortcuts
Mathias Simmack 19 years ago
parent
commit
b53af54b3e
  1. 2
      data/templates/file/CSharp/CSharp.WPFFlowDocument.xft
  2. 10
      data/templates/file/CSharp/CSharp.WPFPage.xft
  3. 26
      data/templates/file/CSharp/CSharp.WPFPageFunction.xft
  4. 4
      data/templates/file/CSharp/CSharp.WPFResourceDictionary.xft
  5. 26
      data/templates/file/CSharp/CSharp.WPFUserControl.xft
  6. 18
      data/templates/file/CSharp/CSharp.WPFWindow.xft
  7. 56
      data/templates/project/CSharp/WPFApplication.xpt
  8. 88
      data/templates/project/CSharp/WPFNavigationApplication.xpt

2
data/templates/file/CSharp/CSharp.WPFFlowDocument.xft

@ -21,7 +21,7 @@ @@ -21,7 +21,7 @@
${Path} -> Full path of the file
-->
<Files>
<File name="${FullName}" language="XML" buildAction="Page"><![CDATA[<FlowDocument xmlns="http://schemas.microsoft.com/winfx/avalon/2005"
<File name="${FullName}" language="XML" buildAction="Page"><![CDATA[<FlowDocument xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
ColumnWidth="400" FontSize="14" FontFamily="Georgia"
>
<Paragraph>

10
data/templates/file/CSharp/CSharp.WPFPage.xft

@ -22,8 +22,8 @@ @@ -22,8 +22,8 @@
-->
<Files>
<File name="${FullName}" language="XML" buildAction="Page"><![CDATA[<Page x:Class="${StandardNamespace}.${FileNameWithoutExtension}"
xmlns="http://schemas.microsoft.com/winfx/avalon/2005"
xmlns:x="http://schemas.microsoft.com/winfx/xaml/2005"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
Title="${FileNameWithoutExtension}"
>
<Grid>
@ -31,18 +31,22 @@ @@ -31,18 +31,22 @@
</Grid>
</Page>]]></File>
<File name="${FullName}.cs" language="C#" dependentUpon="${FileName}" subType="Code"><![CDATA[using System;
using System.Collections.Generic;
using System.Text;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Navigation;
using System.Windows.Shapes;
namespace ${StandardNamespace}
{
/// <summary>
/// Interaction logic for ${FileName}
/// Interaction logic for ${FullName}
/// </summary>
public partial class ${FileNameWithoutExtension} : Page

26
data/templates/file/CSharp/CSharp.WPFPageFunction.xft

@ -21,25 +21,31 @@ @@ -21,25 +21,31 @@
${Path} -> Full path of the file
-->
<Files>
<File name="${FullName}" language="XML" buildAction="Page"><![CDATA[<PageFunction x:Class="${StandardNamespace}.${FileNameWithoutExtension}" x:TypeArguments="String"
xmlns="http://schemas.microsoft.com/winfx/avalon/2005"
xmlns:x="http://schemas.microsoft.com/winfx/xaml/2005"
Title="${FileNameWithoutExtension}"
>
<Grid>
</Grid>
<File name="${FullName}" language="XML" buildAction="Page"><![CDATA[<PageFunction
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:sys="clr-namespace:System;assembly=mscorlib"
x:Class="${StandardNamespace}.${FileNameWithoutExtension}"
x:TypeArguments="sys:String"
Title="${FileNameWithoutExtension}">
<Grid>
</Grid>
</PageFunction>]]></File>
<File name="${FullName}.cs" language="C#" dependentUpon="${FileName}" subType="Code">
<![CDATA[using System;
<File name="${FullName}.cs" language="C#" dependentUpon="${FileName}" subType="Code"><![CDATA[using System;
using System.Collections.Generic;
using System.Text;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Navigation;
using System.Windows.Shapes;
namespace ${StandardNamespace}
{
/// <summary>

4
data/templates/file/CSharp/CSharp.WPFResourceDictionary.xft

@ -21,8 +21,8 @@ @@ -21,8 +21,8 @@
${Path} -> Full path of the file
-->
<Files>
<File name="${FullName}" language="XML" buildAction="Page"><![CDATA[<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/avalon/2005"
xmlns:x="http://schemas.microsoft.com/winfx/xaml/2005"
<File name="${FullName}" language="XML" buildAction="Page"><![CDATA[<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
>
</ResourceDictionary>]]></File>

26
data/templates/file/CSharp/CSharp.WPFUserControl.xft

@ -7,9 +7,9 @@ @@ -7,9 +7,9 @@
category = "C#"
subcategory = "WinFX"
defaultname = "UserControl${Number}.xaml"
language = "XML"/>
language = "C#"/>
<Description>A WinFX User Control</Description>
<Description>A WinFX Custom Control</Description>
<!--
Special new file templates:
@ -21,22 +21,23 @@ @@ -21,22 +21,23 @@
${Path} -> Full path of the file
-->
<Files>
<File name="${FullName}" language="XML" buildAction="Page"><![CDATA[<UserControl x:Class="${StandardNamespace}.${FileNameWithoutExtension}"
xmlns="http://schemas.microsoft.com/winfx/avalon/2005"
xmlns:x="http://schemas.microsoft.com/winfx/xaml/2005"
>
<UserControl.FixedTemplate>
<Grid>
<File name="${FullName}" language="C#"><![CDATA[<UserControl x:Class="${StandardNamespace}.${FileNameWithoutExtension}"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
<Grid>
</Grid>
</UserControl.FixedTemplate>
</Grid>
</UserControl>]]></File>
<File name="${FullName}.cs" language="C#" dependentUpon="${FileName}" subType="Code"><![CDATA[using System;
using System.Collections.Generic;
using System.Text;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Navigation;
using System.Windows.Shapes;
@ -53,11 +54,6 @@ namespace ${StandardNamespace} @@ -53,11 +54,6 @@ namespace ${StandardNamespace}
InitializeComponent();
}
// To use this handler put Loaded="UserControlLoaded" in root element of .xaml file.
// private void UserControlLoaded(object sender, RoutedEventArgs e) {}
// Sample event handler:
// private void ButtonClick(object sender, RoutedEventArgs e) {}
}
}]]></File>
</Files>

18
data/templates/file/CSharp/CSharp.WPFWindow.xft

@ -22,22 +22,27 @@ @@ -22,22 +22,27 @@
-->
<Files>
<File name="${FullName}" language="XML" buildAction="Page"><![CDATA[<Window x:Class="${StandardNamespace}.${FileNameWithoutExtension}"
xmlns="http://schemas.microsoft.com/winfx/avalon/2005"
xmlns:x="http://schemas.microsoft.com/winfx/xaml/2005"
Title="${StandardNamespace}"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
Title="${StandardNamespace}" Height="300" Width="300"
>
<Grid>
</Grid>
</Window>]]></File>
<File name="${FullName}.cs" language="C#" dependentUpon="${FileName}" subType="Code"><![CDATA[using System;
using System.Collections.Generic;
using System.Text;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Shapes;
namespace ${StandardNamespace}
{
/// <summary>
@ -46,17 +51,12 @@ namespace ${StandardNamespace} @@ -46,17 +51,12 @@ namespace ${StandardNamespace}
public partial class ${FileNameWithoutExtension} : Window
{
public ${FileNameWithoutExtension}()
{
InitializeComponent();
}
// To use Loaded event put Loaded="WindowLoaded" attribute in root element of .xaml file.
// private void WindowLoaded(object sender, RoutedEventArgs e) {}
// Sample event handler:
// private void ButtonClick(object sender, RoutedEventArgs e) {}
}
}]]></File>
</Files>

56
data/templates/project/CSharp/WPFApplication.xpt

@ -1,7 +1,7 @@ @@ -1,7 +1,7 @@
<?xml version="1.0"?>
<Template originator = "Mathias Simmack"
created = "26/10/2005"
lastModified = "11/01/2006">
lastModified = "02/06/2006">
<!-- Template Header -->
<TemplateConfiguration>
@ -28,17 +28,17 @@ @@ -28,17 +28,17 @@
<ProjectItems>
<Reference Include="System" />
<Reference Include="System.Data" />
<Reference Include="System.Printing"/>
<Reference Include="System.Runtime.Serialization"/>
<Reference Include="System.Security.Authorization"/>
<!-- Reference Include="System.ServiceModel"/ -->
<Reference Include="System.Xml" />
<Reference Include="WindowsBase" />
<Reference Include="PresentationCore" />
<Reference Include="PresentationFramework" />
<Reference Include="ReachFramework" />
<Reference Include="UIAutomationProvider" />
<Reference Include="UIAutomationTypes" />
<Reference Include="ReachFramework" />
<Reference Include="System.Printing" />
<Reference Include="System.ServiceModel" />
<Reference Include="System.Runtime.Serialization" />
<Reference Include="System.IdentityModel" />
</ProjectItems>
<Imports>
@ -46,16 +46,16 @@ @@ -46,16 +46,16 @@
</Imports>
<Files>
<File name="MyApp.xaml" buildAction="ApplicationDefinition" language="XML"><![CDATA[<Application x:Class="${StandardNamespace}.MyApp"
xmlns="http://schemas.microsoft.com/winfx/avalon/2005"
xmlns:x="http://schemas.microsoft.com/winfx/xaml/2005"
Startup="AppStartup"
<File name="App.xaml" buildAction="ApplicationDefinition" language="XML"><![CDATA[<Application x:Class="${StandardNamespace}.App"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
StartupUri="Window1.xaml"
>
<Application.Resources>
</Application.Resources>
</Application>]]></File>
<File name="MyApp.xaml.cs" subType="Code" dependentUpon="MyApp.xaml"><![CDATA[using System;
<File name="App.xaml.cs" subType="Code" dependentUpon="App.xaml"><![CDATA[using System;
using System.Windows;
using System.Data;
using System.Xml;
@ -64,35 +64,38 @@ using System.Configuration; @@ -64,35 +64,38 @@ using System.Configuration;
namespace ${StandardNamespace}
{
/// <summary>
/// Interaction logic for MyApp.xaml
/// Interaction logic for App.xaml
/// </summary>
public partial class MyApp : Application
public partial class App : Application
{
void AppStartup(object sender, StartupEventArgs args)
public App()
{
Window1 mainWindow = new Window1();
mainWindow.Show();
InitializeComponent();
}
}
}]]></File>
<File name="Window1.xaml" buildAction="Page" language="XML"><![CDATA[<Window x:Class="${StandardNamespace}.Window1"
xmlns="http://schemas.microsoft.com/winfx/avalon/2005"
xmlns:x="http://schemas.microsoft.com/winfx/xaml/2005"
Title="Window1"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
Title="${StandardNamespace}" Height="300" Width="300"
>
<Grid>
</Grid>
</Window>]]></File>
<File name="Window1.xaml.cs" subType="Code" dependentUpon="Window1.xaml"><![CDATA[using System;
using System.Collections.Generic;
using System.Text;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Shapes;
@ -104,17 +107,12 @@ namespace ${StandardNamespace} @@ -104,17 +107,12 @@ namespace ${StandardNamespace}
public partial class Window1 : Window
{
public Window1()
{
InitializeComponent();
}
// To use Loaded event put Loaded="WindowLoaded" attribute in root element of .xaml file.
// private void WindowLoaded(object sender, RoutedEventArgs e) {}
// Sample event handler:
// private void ButtonClick(object sender, RoutedEventArgs e) {}
}
}]]></File>
<File name="AssemblyInfo.cs"><![CDATA[#region Using directives
@ -131,12 +129,12 @@ using System.Runtime.InteropServices; @@ -131,12 +129,12 @@ using System.Runtime.InteropServices;
// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
[assembly: AssemblyTitle("${ProjectName}")]
[assembly: AssemblyTitle("${StandardNamespace}")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("${USER}")]
[assembly: AssemblyProduct("${ProjectName}")]
[assembly: AssemblyCopyright("Copyright @ ${USER} ${DATE}")]
[assembly: AssemblyCompany("")]
[assembly: AssemblyProduct("${StandardNamespace}")]
[assembly: AssemblyCopyright("")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]
[assembly: ComVisible(false)]

88
data/templates/project/CSharp/WPFNavigationApplication.xpt

@ -1,7 +1,7 @@ @@ -1,7 +1,7 @@
<?xml version="1.0"?>
<Template originator = "Mathias Simmack"
created = "26/10/2005"
lastModified = "11/01/2006">
lastModified = "02/06/2006">
<!-- Template Header -->
<TemplateConfiguration>
@ -28,17 +28,17 @@ @@ -28,17 +28,17 @@
<ProjectItems>
<Reference Include="System" />
<Reference Include="System.Data" />
<Reference Include="System.Printing"/>
<Reference Include="System.Runtime.Serialization"/>
<Reference Include="System.Security.Authorization"/>
<!-- Reference Include="System.ServiceModel"/ -->
<Reference Include="System.Xml" />
<Reference Include="WindowsBase" />
<Reference Include="PresentationCore" />
<Reference Include="PresentationFramework" />
<Reference Include="ReachFramework" />
<Reference Include="UIAutomationProvider" />
<Reference Include="UIAutomationTypes" />
<Reference Include="ReachFramework" />
<Reference Include="System.Printing" />
<Reference Include="System.ServiceModel" />
<Reference Include="System.Runtime.Serialization" />
<Reference Include="System.IdentityModel" />
</ProjectItems>
<Imports>
@ -46,55 +46,73 @@ @@ -46,55 +46,73 @@
</Imports>
<Files>
<File name="MyApp.xaml" buildAction="ApplicationDefinition" language="XML"><![CDATA[<Application xmlns="http://schemas.microsoft.com/winfx/avalon/2005"
xmlns:x="http://schemas.microsoft.com/winfx/xaml/2005"
x:Class="${StandardNamespace}.MyApp"
StartupUri="Page1.xaml">
<File name="App.xaml" buildAction="ApplicationDefinition" language="XML"><![CDATA[<Application x:Class="${StandardNamespace}.App"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
StartupUri="Page1.xaml"
>
<Application.Resources>
</Application.Resources>
</Application>]]></File>
<File name="MyApp.xaml.cs" subType="Code" dependentUpon="MyApp.xaml"><![CDATA[using System;
<File name="App.xaml.cs" subType="Code" dependentUpon="App.xaml"><![CDATA[using System;
using System.Windows;
using System.Windows.Navigation;
using System.Data;
using System.Xml;
using System.Configuration;
namespace ${StandardNamespace}
{
/// <summary>
/// Interaction logic for MyApp.xaml
/// Interaction logic for App.xaml
/// </summary>
public partial class MyApp : Application
public partial class App : Application
{
public App()
{
InitializeComponent();
}
}
}]]></File>
<File name="Page1.xaml" buildAction="Page"><![CDATA[<Page xmlns="http://schemas.microsoft.com/winfx/avalon/2005"
xmlns:x="http://schemas.microsoft.com/winfx/xaml/2005"
x:Class="${StandardNamespace}.Page1">
<StackPanel>
</StackPanel>
<File name="Page1.xaml" language="XML" buildAction="Page"><![CDATA[<Page x:Class="${StandardNamespace}.Page1"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
Title="Page1"
>
<StackPanel>
</StackPanel>
</Page>]]></File>
<File name="Page1.xaml.cs" subType="Code" dependentUpon="Page1.xaml"><![CDATA[using System;
<File name="Page1.xaml.cs" language="C#" dependentUpon="Page1.xaml" subType="Code"><![CDATA[using System;
using System.Collections.Generic;
using System.Text;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Navigation;
using System.ComponentModel;
using System.Windows.Shapes;
namespace ${StandardNamespace}
{
public partial class Page1 : Page
{
public Page1()
{
InitializeComponent();
}
}
/// <summary>
/// Interaction logic for Page1.xaml
/// </summary>
public partial class Page1 : Page
{
public Page1()
{
InitializeComponent();
}
}
}]]></File>
<File name="AssemblyInfo.cs"><![CDATA[#region Using directives
@ -110,12 +128,12 @@ using System.Runtime.InteropServices; @@ -110,12 +128,12 @@ using System.Runtime.InteropServices;
// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
[assembly: AssemblyTitle("${ProjectName}")]
[assembly: AssemblyTitle("${StandardNamespace}")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("${USER}")]
[assembly: AssemblyProduct("${ProjectName}")]
[assembly: AssemblyCopyright("Copyright @ ${USER} ${DATE}")]
[assembly: AssemblyCompany("")]
[assembly: AssemblyProduct("${StandardNamespace}")]
[assembly: AssemblyCopyright("")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]
[assembly: ComVisible(false)]

Loading…
Cancel
Save