Browse Source

Fixed project template options.

git-svn-id: svn://svn.sharpdevelop.net/sharpdevelop/trunk@106 1ccf3a8d-04fe-1044-b7c0-cef0b8235c61
shortcuts
Daniel Grunwald 21 years ago
parent
commit
2bb8881add
  1. 8
      data/templates/project/CSharp/ConsoleProject.xpt
  2. 14
      data/templates/project/CSharp/ControlLibrary.xpt
  3. 11
      data/templates/project/CSharp/Direct3DProject.xpt
  4. 11
      data/templates/project/CSharp/FormsProject.xpt
  5. 13
      data/templates/project/CSharp/Library.xpt
  6. 18
      data/templates/project/CSharp/Service.xpt
  7. 5
      data/templates/project/VBNet/ConsoleProject.xpt
  8. 12
      data/templates/project/VBNet/ControlLibrary.xpt
  9. 5
      data/templates/project/VBNet/Direct3DProject.xpt
  10. 14
      data/templates/project/VBNet/FormsProject.xpt
  11. 9
      data/templates/project/VBNet/Library.xpt
  12. 13
      data/templates/project/VBNet/Service.xpt
  13. 52
      src/AddIns/BackendBindings/CSharpBinding/Project/Resources/Signing.xfrm
  14. 4
      src/AddIns/BackendBindings/CSharpBinding/Project/Src/CSharpLanguageBinding.cs
  15. 3
      src/AddIns/BackendBindings/CSharpBinding/Project/Src/OptionPanels/Signing.cs
  16. 4
      src/AddIns/BackendBindings/VBNetBinding/Project/Resources/Signing.xfrm
  17. 3
      src/AddIns/BackendBindings/VBNetBinding/Project/Src/OptionPanels/Signing.cs
  18. 4
      src/AddIns/BackendBindings/VBNetBinding/Project/Src/VBNetLanguageBinding.cs
  19. 4
      src/Libraries/NRefactory/Project/Src/Lexer/AbstractLexer.cs
  20. 6
      src/Libraries/NRefactory/Project/Src/Lexer/CSharp/Lexer.cs
  21. 33
      src/Main/Base/Project/Src/Gui/Pads/CompilerMessageView/CompilerMessageView.cs
  22. 1
      src/Main/Base/Project/Src/Gui/XmlForms/Lib/DefaultObjectCreator.cs
  23. 18
      src/Main/Base/Project/Src/Project/AbstractProject.cs
  24. 14
      src/Main/Core/Project/Src/Services/MessageService/MessageService.cs

8
data/templates/project/CSharp/ConsoleProject.xpt

@ -1,7 +1,7 @@
<?xml version="1.0"?> <?xml version="1.0"?>
<Template originator = "Mike Krueger" <Template originator = "Mike Krueger"
created = "06/10/2001" created = "06/10/2001"
lastModified = "02/01/2003"> lastModified = "23/04/2005">
<!-- Template Header --> <!-- Template Header -->
<TemplateConfiguration> <TemplateConfiguration>
@ -28,6 +28,7 @@
<Files> <Files>
<File name="Main.cs"><![CDATA[${StandardHeader.C#} <File name="Main.cs"><![CDATA[${StandardHeader.C#}
using System; using System;
using System.Collections.Generic;
namespace ${StandardNamespace} namespace ${StandardNamespace}
{ {
@ -66,11 +67,6 @@ using System.Runtime.CompilerServices;
[assembly: AssemblyVersion("1.0.*")] [assembly: AssemblyVersion("1.0.*")]
// The following attributes specify the key for the sign of your assembly. See the
// .NET Framework documentation for more information about signing.
// This is not required, if you don't want signing let these attributes like they're.
[assembly: AssemblyDelaySign(false)]
[assembly: AssemblyKeyFile("")]
]]></File> ]]></File>
</Files> </Files>
</Project> </Project>

14
data/templates/project/CSharp/ControlLibrary.xpt

@ -1,7 +1,7 @@
<?xml version="1.0"?> <?xml version="1.0"?>
<Template originator = "Mike Krueger" <Template originator = "Mike Krueger"
created = "06/10/2001" created = "06/10/2001"
lastModified = "02/01/2003"> lastModified = "23/04/2005">
<!-- Template Header --> <!-- Template Header -->
<TemplateConfiguration> <TemplateConfiguration>
@ -23,7 +23,7 @@
</Options> </Options>
<Project name = "${ProjectName}" directory = "."> <Project name = "${ProjectName}" directory = ".">
<Options Target = "Library" PauseConsoleOutput = "False" /> <Options OutputType = "Library" />
<References> <References>
<Reference type="Gac" refto="System" /> <Reference type="Gac" refto="System" />
@ -36,14 +36,15 @@
<Files> <Files>
<File name="UserControl1.cs"><![CDATA[${StandardHeader.C#} <File name="UserControl1.cs"><![CDATA[${StandardHeader.C#}
using System; using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Drawing; using System.Drawing;
using System.Windows.Forms; using System.Windows.Forms;
using System.ComponentModel;
namespace ${StandardNamespace} namespace ${StandardNamespace}
{ {
/// <summary> /// <summary>
/// Description of UserControl1. /// Description of UserControl1.
/// </summary> /// </summary>
public class UserControl1 : System.Windows.Forms.UserControl public class UserControl1 : System.Windows.Forms.UserControl
{ {
@ -104,11 +105,6 @@ using System.Runtime.CompilerServices;
[assembly: AssemblyVersion("1.0.*")] [assembly: AssemblyVersion("1.0.*")]
// The following attributes specify the key for the sign of your assembly. See the
// .NET Framework documentation for more information about signing.
// This is not required, if you don't want signing let these attributes like they're.
[assembly: AssemblyDelaySign(false)]
[assembly: AssemblyKeyFile("")]
]]></File> ]]></File>
</Files> </Files>
</Project> </Project>

11
data/templates/project/CSharp/Direct3DProject.xpt

@ -1,7 +1,7 @@
<?xml version="1.0"?> <?xml version="1.0"?>
<Template originator = "Mike Krueger" <Template originator = "Mike Krueger"
created = "22/01/2003" created = "22/01/2003"
lastModified = "20/10/2004"> lastModified = "23/04/2005">
<!-- Template Header --> <!-- Template Header -->
<TemplateConfiguration> <TemplateConfiguration>
@ -38,7 +38,7 @@
<Files> <Files>
<File name="MainClass.cs"><![CDATA[using System; <File name="MainClass.cs"><![CDATA[using System;
using System.Collections; using System.Collections.Generic;
using System.ComponentModel; using System.ComponentModel;
using System.Drawing; using System.Drawing;
using System.Windows.Forms; using System.Windows.Forms;
@ -134,7 +134,7 @@ namespace ${StandardNamespace}
{ {
// While the form is still valid, render and process messages // While the form is still valid, render and process messages
while (Created) { while (Created) {
FrameMove(); FrameMove();
Render(); Render();
Application.DoEvents(); Application.DoEvents();
} }
@ -197,11 +197,6 @@ using System.Runtime.CompilerServices;
[assembly: AssemblyVersion("1.0.*")] [assembly: AssemblyVersion("1.0.*")]
// The following attributes specify the key for the sign of your assembly. See the
// .NET Framework documentation for more information about signing.
// This is not required, if you don't want signing let these attributes like they're.
[assembly: AssemblyDelaySign(false)]
[assembly: AssemblyKeyFile("")]
]]></File> ]]></File>
</Files> </Files>
</Project> </Project>

11
data/templates/project/CSharp/FormsProject.xpt

@ -1,7 +1,7 @@
<?xml version="1.0"?> <?xml version="1.0"?>
<Template originator = "Mike Krueger" <Template originator = "Mike Krueger"
created = "06/10/2001" created = "06/10/2001"
lastModified = "02/01/2003"> lastModified = "23/04/2005">
<!-- Template Header --> <!-- Template Header -->
<TemplateConfiguration> <TemplateConfiguration>
@ -23,8 +23,7 @@
</Options> </Options>
<Project name = "${ProjectName}" directory = "."> <Project name = "${ProjectName}" directory = ".">
<Options OutputType = "WinExe" />
<Options Target = "WinExe" PauseConsoleOutput = "False" />
<References> <References>
<Reference type="Gac" refto="System" /> <Reference type="Gac" refto="System" />
@ -37,6 +36,7 @@
<Files> <Files>
<File name="MainForm.cs"><![CDATA[${StandardHeader.C#} <File name="MainForm.cs"><![CDATA[${StandardHeader.C#}
using System; using System;
using System.Collections.Generic;
using System.Drawing; using System.Drawing;
using System.Windows.Forms; using System.Windows.Forms;
@ -112,11 +112,6 @@ using System.Runtime.CompilerServices;
[assembly: AssemblyVersion("1.0.*")] [assembly: AssemblyVersion("1.0.*")]
// The following attributes specify the key for the sign of your assembly. See the
// .NET Framework documentation for more information about signing.
// This is not required, if you don't want signing let these attributes like they're.
[assembly: AssemblyDelaySign(false)]
[assembly: AssemblyKeyFile("")]
]]></File> ]]></File>
</Files> </Files>
</Project> </Project>

13
data/templates/project/CSharp/Library.xpt

@ -1,7 +1,7 @@
<?xml version="1.0"?> <?xml version="1.0"?>
<Template originator = "Mike Krueger" <Template originator = "Mike Krueger"
created = "02/01/2003" created = "02/01/2003"
lastModified = "02/01/2003"> lastModified = "23/04/2005">
<!-- Template Header --> <!-- Template Header -->
<TemplateConfiguration> <TemplateConfiguration>
@ -24,11 +24,13 @@
</Options> </Options>
<Project name = "${ProjectName}" directory = "."> <Project name = "${ProjectName}" directory = ".">
<Options Target = "Library" PauseConsoleOutput = "False" /> <Options OutputType = "Library" />
<Files> <Files>
<File name="MyClass.cs"><![CDATA[${StandardHeader.C#} <File name="MyClass.cs"><![CDATA[${StandardHeader.C#}
using System; using System;
using System.Collections.Generic;
namespace ${StandardNamespace} namespace ${StandardNamespace}
{ {
/// <summary> /// <summary>
@ -36,7 +38,7 @@ namespace ${StandardNamespace}
/// </summary> /// </summary>
public class MyClass public class MyClass
{ {
} }
}]]></File> }]]></File>
<File name="AssemblyInfo.cs"> <File name="AssemblyInfo.cs">
@ -67,11 +69,6 @@ using System.Runtime.CompilerServices;
[assembly: AssemblyVersion("1.0.*")] [assembly: AssemblyVersion("1.0.*")]
// The following attributes specify the key for the sign of your assembly. See the
// .NET Framework documentation for more information about signing.
// This is not required, if you don't want signing let these attributes like they're.
[assembly: AssemblyDelaySign(false)]
[assembly: AssemblyKeyFile("")]
]]></File> ]]></File>
</Files> </Files>
</Project> </Project>

18
data/templates/project/CSharp/Service.xpt

@ -1,7 +1,7 @@
<?xml version="1.0"?> <?xml version="1.0"?>
<Template originator = "Mike Krueger" <Template originator = "Mike Krueger"
created = "02/01/2003" created = "02/01/2003"
lastModified = "02/01/2003"> lastModified = "23/04/2005">
<!-- Template Header --> <!-- Template Header -->
<TemplateConfiguration> <TemplateConfiguration>
@ -24,13 +24,12 @@
</Options> </Options>
<Project name = "${ProjectName}" directory = "."> <Project name = "${ProjectName}" directory = ".">
<Options />
<Options Target = "Library" PauseConsoleOutput = "False" />
<Files> <Files>
<File name="MyService.cs"><![CDATA[${StandardHeader.C#} <File name="MyService.cs"><![CDATA[${StandardHeader.C#}
using System; using System;
using System.Collections; using System.Collections.Generic;
using System.ComponentModel; using System.ComponentModel;
using System.Data; using System.Data;
using System.Diagnostics; using System.Diagnostics;
@ -47,10 +46,10 @@ namespace ${StandardNamespace}
public MyService() public MyService()
{ {
InitializeComponents(); InitializeComponents();
// TODO: Add any further initialization code // TODO: Add any further initialization code
} }
private void InitializeComponents() private void InitializeComponents()
{ {
this.ServiceName = "MyService"; this.ServiceName = "MyService";
@ -137,11 +136,6 @@ using System.Runtime.CompilerServices;
[assembly: AssemblyVersion("1.0.*")] [assembly: AssemblyVersion("1.0.*")]
// The following attributes specify the key for the sign of your assembly. See the
// .NET Framework documentation for more information about signing.
// This is not required, if you don't want signing let these attributes like they're.
[assembly: AssemblyDelaySign(false)]
[assembly: AssemblyKeyFile("")]
]]></File> ]]></File>
</Files> </Files>
</Project> </Project>

5
data/templates/project/VBNet/ConsoleProject.xpt

@ -25,8 +25,7 @@
</Options> </Options>
<Project name = "${ProjectName}" directory = "."> <Project name = "${ProjectName}" directory = ".">
<Options />
<Options Target = "Exe" PauseConsoleOutput = "True"/>
<References> <References>
<Reference type="Gac" refto="System" /> <Reference type="Gac" refto="System" />
@ -39,6 +38,8 @@
<File name="Main.vb"> <File name="Main.vb">
<![CDATA[${StandardHeader.VBNET} <![CDATA[${StandardHeader.VBNET}
Imports System Imports System
Imports System.Collections.Generic
Module Main Module Main
Sub Main() Sub Main()
Console.WriteLine("Hello World!") Console.WriteLine("Hello World!")

12
data/templates/project/VBNet/ControlLibrary.xpt

@ -23,7 +23,7 @@
</Options> </Options>
<Project name = "${ProjectName}" directory = "."> <Project name = "${ProjectName}" directory = ".">
<Options Target = "Library" PauseConsoleOutput = "False"/> <Options OutputType = "Library" />
<References> <References>
@ -37,12 +37,12 @@
<Files> <Files>
<File name="UserControl1.vb"><![CDATA[${StandardHeader.VBNET} <File name="UserControl1.vb"><![CDATA[${StandardHeader.VBNET}
Imports System Imports System
Imports System.Collections.Generic
Imports System.ComponentModel
Imports System.Drawing Imports System.Drawing
Imports System.Windows.Forms Imports System.Windows.Forms
Imports System.ComponentModel
Namespace ${StandardNamespace} Namespace ${StandardNamespace}
Public Class UserControl1 Public Class UserControl1
Inherits System.Windows.Forms.UserControl Inherits System.Windows.Forms.UserControl
@ -98,11 +98,7 @@ Imports System.Runtime.CompilerServices
<assembly: AssemblyVersion("1.0.*")> <assembly: AssemblyVersion("1.0.*")>
' The following attributes specify the key for the sign of your assembly. See the ]]></File>
' .NET Framework documentation for more information about signing.
' This is not required, if you don't want signing let these attributes like they're.
<assembly: AssemblyDelaySign(false)>
<assembly: AssemblyKeyFile("")>]]></File>
</Files> </Files>
</Project> </Project>
</Combine> </Combine>

5
data/templates/project/VBNet/Direct3DProject.xpt

@ -181,11 +181,6 @@ Imports System.Runtime.CompilerServices
<assembly: AssemblyVersion("1.0.*")> <assembly: AssemblyVersion("1.0.*")>
' The following attributes specify the key for the sign of your assembly. See the
' .NET Framework documentation for more information about signing.
' This is not required, if you don't want signing let these attributes like they're.
<assembly: AssemblyDelaySign(false)>
<assembly: AssemblyKeyFile("")>]]>
</File> </File>
</Files> </Files>
</Project> </Project>

14
data/templates/project/VBNet/FormsProject.xpt

@ -24,8 +24,7 @@
</Options> </Options>
<Project name = "${ProjectName}" directory = "."> <Project name = "${ProjectName}" directory = ".">
<Options OutputType = "WinExe" />
<Options Target = "WinExe" PauseConsoleOutput = "False"/>
<References> <References>
<Reference type="Gac" refto="System" /> <Reference type="Gac" refto="System" />
@ -40,6 +39,7 @@
<File name="MainForm.vb"> <File name="MainForm.vb">
<![CDATA[${StandardHeader.VBNET} <![CDATA[${StandardHeader.VBNET}
Imports System Imports System
Imports System.Collections.Generic
Imports System.Drawing Imports System.Drawing
Imports System.Windows.Forms Imports System.Windows.Forms
@ -49,8 +49,7 @@ Namespace ${StandardNamespace}
Inherits System.Windows.Forms.Form Inherits System.Windows.Forms.Form
Public Shared Sub Main Public Shared Sub Main
Dim fMainForm As New MainForm Application.Run(New MainForm())
fMainForm.ShowDialog()
End Sub End Sub
Public Sub New() Public Sub New()
@ -109,12 +108,7 @@ Imports System.Runtime.CompilerServices
' numbers with the '*' character (the default): ' numbers with the '*' character (the default):
<assembly: AssemblyVersion("1.0.*")> <assembly: AssemblyVersion("1.0.*")>
]]></File>
' The following attributes specify the key for the sign of your assembly. See the
' .NET Framework documentation for more information about signing.
' This is not required, if you don't want signing let these attributes like they're.
<assembly: AssemblyDelaySign(false)>
<assembly: AssemblyKeyFile("")>]]></File>
</Files> </Files>
</Project> </Project>
</Combine> </Combine>

9
data/templates/project/VBNet/Library.xpt

@ -24,7 +24,7 @@
<Project name = "${ProjectName}" directory = "."> <Project name = "${ProjectName}" directory = ".">
<Options Target = "Library" PauseConsoleOutput = "False"/> <Options OutputType = "Library" />
<References> <References>
<Reference type="Gac" refto="System" /> <Reference type="Gac" refto="System" />
@ -68,12 +68,7 @@ Imports System.Runtime.CompilerServices
' numbers with the '*' character (the default): ' numbers with the '*' character (the default):
<assembly: AssemblyVersion("1.0.*")> <assembly: AssemblyVersion("1.0.*")>
]]></File>
' The following attributes specify the key for the sign of your assembly. See the
' .NET Framework documentation for more information about signing.
' This is not required, if you don't want signing let these attributes like they're.
<assembly: AssemblyDelaySign(false)>
<assembly: AssemblyKeyFile("")>]]></File>
</Files> </Files>
</Project> </Project>
</Combine> </Combine>

13
data/templates/project/VBNet/Service.xpt

@ -22,10 +22,8 @@
<StartupProject>${ProjectName}</StartupProject> <StartupProject>${ProjectName}</StartupProject>
</Options> </Options>
<Project name = "${ProjectName}" directory = "."> <Project name = "${ProjectName}" directory = ".">
<Options />
<Options Target = "Library" PauseConsoleOutput = "False"/>
<References> <References>
<Reference type="Gac" refto="System" /> <Reference type="Gac" refto="System" />
<Reference type="Gac" refto="System.Data" /> <Reference type="Gac" refto="System.Data" />
@ -37,7 +35,7 @@
<Files> <Files>
<File name="MyService.vb"><![CDATA[${StandardHeader.VBNET} <File name="MyService.vb"><![CDATA[${StandardHeader.VBNET}
Imports System Imports System
Imports System.Collections Imports System.Collections.Generic
Imports System.ComponentModel Imports System.ComponentModel
Imports System.Data Imports System.Data
Imports System.Diagnostics Imports System.Diagnostics
@ -129,12 +127,7 @@ Imports System.Runtime.CompilerServices
' numbers with the '*' character (the default): ' numbers with the '*' character (the default):
<assembly: AssemblyVersion("1.0.*")> <assembly: AssemblyVersion("1.0.*")>
]]></File>
' The following attributes specify the key for the sign of your assembly. See the
' .NET Framework documentation for more information about signing.
' This is not required, if you don't want signing let these attributes like they're.
<assembly: AssemblyDelaySign(false)>
<assembly: AssemblyKeyFile("")>]]></File>
</Files> </Files>
</Project> </Project>
</Combine> </Combine>

52
src/AddIns/BackendBindings/CSharpBinding/Project/Resources/Signing.xfrm

@ -1,82 +1,91 @@
<?xml version="1.0" encoding="utf-8"?>
<Components version="1.0"> <Components version="1.0">
<System.Windows.Forms.UserControl> <System.Windows.Forms.UserControl>
<Name value="XmlUserControl1" /> <Name value="XmlUserControl1" />
<DockPadding value="" />
<ClientSize value="{Width=392, Height=312}" /> <ClientSize value="{Width=392, Height=312}" />
<Controls> <Controls>
<System.Windows.Forms.GroupBox> <System.Windows.Forms.GroupBox>
<Name value="groupBox1" /> <Name value="signingGroupBox" />
<TabIndex value="1" />
<Location value="{X=8,Y=28}" /> <Location value="{X=8,Y=28}" />
<Anchor value="Top, Left, Right" />
<Size value="{Width=368, Height=196}" />
<Text value="Key Selection" /> <Text value="Key Selection" />
<Size value="{Width=368, Height=196}" />
<TabIndex value="1" />
<Anchor value="Top, Left, Right" />
<Controls> <Controls>
<System.Windows.Forms.CheckBox> <System.Windows.Forms.CheckBox>
<Name value="delaySignOnlyCheckBox" /> <Name value="delaySignOnlyCheckBox" />
<Location value="{X=4,Y=169}" /> <Location value="{X=4,Y=169}" />
<Size value="{Width=356, Height=24}" /> <FlatAppearance value="System.Windows.Forms.FlatButtonAppearance" />
<Text value="Dela&amp;y Sign only" /> <Text value="Dela&amp;y Sign only" />
<Anchor value="Top, Left, Right" />
<TabIndex value="8" /> <TabIndex value="8" />
<Size value="{Width=356, Height=24}" />
<Anchor value="Top, Left, Right" />
</System.Windows.Forms.CheckBox> </System.Windows.Forms.CheckBox>
<System.Windows.Forms.ComboBox> <System.Windows.Forms.ComboBox>
<Name value="containerComboBox" /> <Name value="containerComboBox" />
<Anchor value="Top, Left, Right" />
<TabIndex value="7" /> <TabIndex value="7" />
<Location value="{X=108,Y=133}" /> <Anchor value="Top, Left, Right" />
<Size value="{Width=252, Height=21}" /> <Size value="{Width=252, Height=21}" />
<FormattingEnabled value="True" />
<Location value="{X=108,Y=133}" />
</System.Windows.Forms.ComboBox> </System.Windows.Forms.ComboBox>
<System.Windows.Forms.Label> <System.Windows.Forms.Label>
<Name value="label2" /> <Name value="label2" />
<Location value="{X=8,Y=128}" />
<Text value="&amp;Container:" /> <Text value="&amp;Container:" />
<TextAlign value="MiddleRight" /> <TextAlign value="MiddleRight" />
<Size value="{Width=100, Height=23}" />
<TabIndex value="6" /> <TabIndex value="6" />
<Location value="{X=8,Y=128}" />
</System.Windows.Forms.Label> </System.Windows.Forms.Label>
<System.Windows.Forms.ComboBox> <System.Windows.Forms.ComboBox>
<Name value="providerNameComboBox" /> <Name value="providerNameComboBox" />
<Anchor value="Top, Left, Right" />
<TabIndex value="5" /> <TabIndex value="5" />
<Location value="{X=108,Y=105}" /> <Anchor value="Top, Left, Right" />
<Size value="{Width=252, Height=21}" /> <Size value="{Width=252, Height=21}" />
<FormattingEnabled value="True" />
<Location value="{X=108,Y=105}" />
</System.Windows.Forms.ComboBox> </System.Windows.Forms.ComboBox>
<System.Windows.Forms.Label> <System.Windows.Forms.Label>
<Name value="label1" /> <Name value="label1" />
<Location value="{X=8,Y=100}" />
<Text value="Provider &amp;name:" /> <Text value="Provider &amp;name:" />
<TextAlign value="MiddleRight" /> <TextAlign value="MiddleRight" />
<Size value="{Width=100, Height=23}" />
<TabIndex value="4" /> <TabIndex value="4" />
<Location value="{X=8,Y=100}" />
</System.Windows.Forms.Label> </System.Windows.Forms.Label>
<System.Windows.Forms.RadioButton> <System.Windows.Forms.RadioButton>
<Name value="useKeyProviderRadioButton" /> <Name value="useKeyProviderRadioButton" />
<Location value="{X=4,Y=77}" /> <Location value="{X=4,Y=77}" />
<Size value="{Width=356, Height=24}" />
<Text value="Use this key &amp;provider:" /> <Text value="Use this key &amp;provider:" />
<Size value="{Width=356, Height=24}" />
<Anchor value="Top, Left, Right" /> <Anchor value="Top, Left, Right" />
<FlatAppearance value="System.Windows.Forms.FlatButtonAppearance" />
<TabIndex value="3" /> <TabIndex value="3" />
</System.Windows.Forms.RadioButton> </System.Windows.Forms.RadioButton>
<System.Windows.Forms.ComboBox> <System.Windows.Forms.ComboBox>
<Name value="keyFileComboBox" /> <Name value="keyFileComboBox" />
<Anchor value="Top, Left, Right" />
<TabIndex value="1" /> <TabIndex value="1" />
<Location value="{X=20,Y=49}" /> <Anchor value="Top, Left, Right" />
<Size value="{Width=184, Height=21}" /> <Size value="{Width=184, Height=21}" />
<FormattingEnabled value="True" />
<Location value="{X=20,Y=49}" />
</System.Windows.Forms.ComboBox> </System.Windows.Forms.ComboBox>
<System.Windows.Forms.Button> <System.Windows.Forms.Button>
<Name value="changePasswordButton" /> <Name value="changePasswordButton" />
<Location value="{X=212,Y=49}" /> <Location value="{X=212,Y=49}" />
<Size value="{Width=148, Height=21}" />
<Text value="Change Pass&amp;word..." /> <Text value="Change Pass&amp;word..." />
<Size value="{Width=148, Height=21}" />
<Anchor value="Top, Right" /> <Anchor value="Top, Right" />
<FlatAppearance value="System.Windows.Forms.FlatButtonAppearance" />
<TabIndex value="2" /> <TabIndex value="2" />
</System.Windows.Forms.Button> </System.Windows.Forms.Button>
<System.Windows.Forms.RadioButton> <System.Windows.Forms.RadioButton>
<Name value="useKeyFileRadioButton" /> <Name value="useKeyFileRadioButton" />
<Location value="{X=4,Y=25}" /> <Location value="{X=4,Y=25}" />
<Size value="{Width=356, Height=24}" />
<Text value="Use a key &amp;file:" /> <Text value="Use a key &amp;file:" />
<Size value="{Width=356, Height=24}" />
<Anchor value="Top, Left, Right" /> <Anchor value="Top, Left, Right" />
<FlatAppearance value="System.Windows.Forms.FlatButtonAppearance" />
<TabIndex value="0" /> <TabIndex value="0" />
</System.Windows.Forms.RadioButton> </System.Windows.Forms.RadioButton>
</Controls> </Controls>
@ -84,11 +93,12 @@
<System.Windows.Forms.CheckBox> <System.Windows.Forms.CheckBox>
<Name value="signAssemblyCheckBox" /> <Name value="signAssemblyCheckBox" />
<Location value="{X=8,Y=4}" /> <Location value="{X=8,Y=4}" />
<Size value="{Width=376, Height=24}" /> <FlatAppearance value="System.Windows.Forms.FlatButtonAppearance" />
<Text value="Sign the &amp;assembly" /> <Text value="Sign the &amp;assembly" />
<Anchor value="Top, Left, Right" />
<TabIndex value="0" /> <TabIndex value="0" />
<Size value="{Width=376, Height=24}" />
<Anchor value="Top, Left, Right" />
</System.Windows.Forms.CheckBox> </System.Windows.Forms.CheckBox>
</Controls> </Controls>
</System.Windows.Forms.UserControl> </System.Windows.Forms.UserControl>
</Components> </Components>

4
src/AddIns/BackendBindings/CSharpBinding/Project/Src/CSharpLanguageBinding.cs

@ -84,7 +84,9 @@ namespace CSharpBinding
public IProject CreateProject(ProjectCreateInformation info, XmlElement projectOptions) public IProject CreateProject(ProjectCreateInformation info, XmlElement projectOptions)
{ {
return new CSharpProject(info); CSharpProject p = new CSharpProject(info);
p.ImportOptions(projectOptions.Attributes);
return p;
} }
} }
} }

3
src/AddIns/BackendBindings/CSharpBinding/Project/Src/OptionPanels/Signing.cs

@ -17,6 +17,7 @@ namespace CSharpBinding.OptionPanels
this.project = (CSharpProject)((Properties)CustomizationObject).Get("Project"); this.project = (CSharpProject)((Properties)CustomizationObject).Get("Project");
Get<CheckBox>("signAssembly").Checked = project.SignAssembly; Get<CheckBox>("signAssembly").Checked = project.SignAssembly;
Get<CheckBox>("signAssembly").CheckedChanged += new EventHandler(UpdateEnabledStates);
Get<CheckBox>("signAssembly").CheckedChanged += new EventHandler(Save); Get<CheckBox>("signAssembly").CheckedChanged += new EventHandler(Save);
Get<RadioButton>("useKeyFile").Checked = project.AssemblyOriginatorKeyMode == AssemblyOriginatorKeyMode.File; Get<RadioButton>("useKeyFile").Checked = project.AssemblyOriginatorKeyMode == AssemblyOriginatorKeyMode.File;
@ -57,7 +58,7 @@ namespace CSharpBinding.OptionPanels
Get<ComboBox>("providerName").Enabled = Get<ComboBox>("container").Enabled = Get<RadioButton>("useKeyProvider").Checked; Get<ComboBox>("providerName").Enabled = Get<ComboBox>("container").Enabled = Get<RadioButton>("useKeyProvider").Checked;
Get<ComboBox>("keyFile").Enabled = Get<RadioButton>("useKeyFile").Checked; Get<ComboBox>("keyFile").Enabled = Get<RadioButton>("useKeyFile").Checked;
Get<CheckBox>("signAssembly").Enabled = Get<RadioButton>("useKeyFile").Checked; Get<GroupBox>("signing").Enabled = Get<CheckBox>("signAssembly").Checked;
} }
public override bool StorePanelContents() public override bool StorePanelContents()

4
src/AddIns/BackendBindings/VBNetBinding/Project/Resources/Signing.xfrm

@ -5,7 +5,7 @@
<ClientSize value="{Width=392, Height=312}" /> <ClientSize value="{Width=392, Height=312}" />
<Controls> <Controls>
<System.Windows.Forms.GroupBox> <System.Windows.Forms.GroupBox>
<Name value="groupBox1" /> <Name value="signingGroupBox" />
<TabIndex value="1" /> <TabIndex value="1" />
<Location value="{X=8,Y=28}" /> <Location value="{X=8,Y=28}" />
<Anchor value="Top, Left, Right" /> <Anchor value="Top, Left, Right" />
@ -91,4 +91,4 @@
</System.Windows.Forms.CheckBox> </System.Windows.Forms.CheckBox>
</Controls> </Controls>
</System.Windows.Forms.UserControl> </System.Windows.Forms.UserControl>
</Components> </Components>

3
src/AddIns/BackendBindings/VBNetBinding/Project/Src/OptionPanels/Signing.cs

@ -17,6 +17,7 @@ namespace VBNetBinding.OptionPanels
this.project = (VBNetProject)((Properties)CustomizationObject).Get("Project"); this.project = (VBNetProject)((Properties)CustomizationObject).Get("Project");
Get<CheckBox>("signAssembly").Checked = project.SignAssembly; Get<CheckBox>("signAssembly").Checked = project.SignAssembly;
Get<CheckBox>("signAssembly").CheckedChanged += new EventHandler(UpdateEnabledStates);
Get<CheckBox>("signAssembly").CheckedChanged += new EventHandler(Save); Get<CheckBox>("signAssembly").CheckedChanged += new EventHandler(Save);
Get<RadioButton>("useKeyFile").Checked = project.AssemblyOriginatorKeyMode == AssemblyOriginatorKeyMode.File; Get<RadioButton>("useKeyFile").Checked = project.AssemblyOriginatorKeyMode == AssemblyOriginatorKeyMode.File;
@ -57,7 +58,7 @@ namespace VBNetBinding.OptionPanels
Get<ComboBox>("providerName").Enabled = Get<ComboBox>("container").Enabled = Get<RadioButton>("useKeyProvider").Checked; Get<ComboBox>("providerName").Enabled = Get<ComboBox>("container").Enabled = Get<RadioButton>("useKeyProvider").Checked;
Get<ComboBox>("keyFile").Enabled = Get<RadioButton>("useKeyFile").Checked; Get<ComboBox>("keyFile").Enabled = Get<RadioButton>("useKeyFile").Checked;
Get<CheckBox>("signAssembly").Enabled = Get<RadioButton>("useKeyFile").Checked; Get<GroupBox>("signing").Enabled = Get<CheckBox>("signAssembly").Checked;
} }
public override bool StorePanelContents() public override bool StorePanelContents()

4
src/AddIns/BackendBindings/VBNetBinding/Project/Src/VBNetLanguageBinding.cs

@ -84,7 +84,9 @@ namespace VBNetBinding
public IProject CreateProject(ProjectCreateInformation info, XmlElement projectOptions) public IProject CreateProject(ProjectCreateInformation info, XmlElement projectOptions)
{ {
return new VBNetProject(info); VBNetProject p = new VBNetProject(info);
p.ImportOptions(projectOptions.Attributes);
return p;
} }
} }
} }

4
src/Libraries/NRefactory/Project/Src/Lexer/AbstractLexer.cs

@ -157,7 +157,9 @@ namespace ICSharpCode.NRefactory.Parser
if (curToken.next == null) { if (curToken.next == null) {
curToken.next = Next(); curToken.next = Next();
specialTracker.InformToken(curToken.next.kind); if (curToken.next != null) {
specialTracker.InformToken(curToken.next.kind);
}
} }
curToken = curToken.next; curToken = curToken.next;

6
src/Libraries/NRefactory/Project/Src/Lexer/CSharp/Lexer.cs

@ -511,8 +511,10 @@ namespace ICSharpCode.NRefactory.Parser.CSharp
escapeSequence = ReadEscapeSequence(out chValue); escapeSequence = ReadEscapeSequence(out chValue);
} }
if ((char)reader.Read() != '\'') { unchecked {
errors.Error(y, x, String.Format("Char not terminated")); if ((char)reader.Read() != '\'') {
errors.Error(y, x, String.Format("Char not terminated"));
}
} }
return new Token(Tokens.Literal, x, y, "'" + ch + escapeSequence + "'", chValue); return new Token(Tokens.Literal, x, y, "'" + ch + escapeSequence + "'", chValue);
} }

33
src/Main/Base/Project/Src/Gui/Pads/CompilerMessageView/CompilerMessageView.cs

@ -109,7 +109,7 @@ namespace ICSharpCode.SharpDevelop.Gui
textEditorControl.ShowEOLMarkers = false; textEditorControl.ShowEOLMarkers = false;
textEditorControl.ContextMenuStrip = MenuService.CreateContextMenu(this, "/SharpDevelop/Pads/CompilerMessageView/ContextMenu"); textEditorControl.ContextMenuStrip = MenuService.CreateContextMenu(this, "/SharpDevelop/Pads/CompilerMessageView/ContextMenu");
properties = (Properties)PropertyService.Get(OutputWindowOptionsPanel.OutputWindowsProperty, new Properties()); properties = (Properties)PropertyService.Get(OutputWindowOptionsPanel.OutputWindowsProperty, new Properties());
textEditorControl.Font = FontSelectionPanel.ParseFont(properties.Get("DefaultFont", new Font("Courier New", 10).ToString()).ToString()); textEditorControl.Font = FontSelectionPanel.ParseFont(properties.Get("DefaultFont", new Font("Courier New", 10).ToString()).ToString());
@ -117,7 +117,7 @@ namespace ICSharpCode.SharpDevelop.Gui
textEditorControl.MouseDown += new MouseEventHandler(TextEditorControlMouseDown); textEditorControl.MouseDown += new MouseEventHandler(TextEditorControlMouseDown);
textEditorControl.BackColor = SystemColors.Window; textEditorControl.BackColor = SystemColors.Window;
ToolStrip toolStrip = ToolbarService.CreateToolStrip(this, "/SharpDevelop/Pads/CompilerMessageView/Toolbar"); ToolStrip toolStrip = ToolbarService.CreateToolStrip(this, "/SharpDevelop/Pads/CompilerMessageView/Toolbar");
toolStrip.Stretch = true; toolStrip.Stretch = true;
toolStrip.GripStyle = System.Windows.Forms.ToolStripGripStyle.Hidden; toolStrip.GripStyle = System.Windows.Forms.ToolStripGripStyle.Hidden;
@ -167,7 +167,7 @@ namespace ICSharpCode.SharpDevelop.Gui
} }
void ClearText() void ClearText()
{ {
textEditorControl.Document.TextContent = ""; textEditorControl.Text = "";
} }
void CategoryTextSet(object sender, TextEventArgs e) void CategoryTextSet(object sender, TextEventArgs e)
@ -204,13 +204,13 @@ namespace ICSharpCode.SharpDevelop.Gui
if (text == null) { if (text == null) {
text = String.Empty; text = String.Empty;
} }
textEditorControl.Document.TextContent = text; textEditorControl.Text = text;
// textEditorControl.Select(text.Length , 0); // textEditorControl.Select(text.Length , 0);
// textEditorControl.Select(); // textEditorControl.Select();
// textEditorControl.ScrollToCaret(); // textEditorControl.ScrollToCaret();
} }
public void SelectCategory(string categoryName) public void SelectCategory(string categoryName)
{ {
for (int i = 0; i < messageCategories.Count; ++i) { for (int i = 0; i < messageCategories.Count; ++i) {
@ -250,7 +250,7 @@ namespace ICSharpCode.SharpDevelop.Gui
} }
/// <summary> /// <summary>
/// Occurs when the mouse pointer is over the control and a /// Occurs when the mouse pointer is over the control and a
/// mouse button is pressed. /// mouse button is pressed.
/// </summary> /// </summary>
void TextEditorControlMouseDown(object sender, MouseEventArgs e) void TextEditorControlMouseDown(object sender, MouseEventArgs e)
@ -259,18 +259,18 @@ namespace ICSharpCode.SharpDevelop.Gui
// if (e.Clicks == 2) { // if (e.Clicks == 2) {
// // Any text? // // Any text?
// if (textEditorControl.Text.Length > 0) { // if (textEditorControl.Text.Length > 0) {
// //
// // Parse text line double clicked. // // Parse text line double clicked.
// Point point = new Point(e.X, e.Y); // Point point = new Point(e.X, e.Y);
// //
// int charIndex = textEditorControl.GetCharIndexFromPosition(point); // int charIndex = textEditorControl.GetCharIndexFromPosition(point);
// string textLine = GetTextLine(charIndex, textEditorControl.Text); // string textLine = GetTextLine(charIndex, textEditorControl.Text);
// //
// FileLineReference lineReference = OutputTextLineParser.GetFileLineReference(textLine); // FileLineReference lineReference = OutputTextLineParser.GetFileLineReference(textLine);
// if (lineReference != null) { // if (lineReference != null) {
// // Open matching file. // // Open matching file.
// JumpToFilePosition(Path.GetFullPath(lineReference.FileName), // JumpToFilePosition(Path.GetFullPath(lineReference.FileName),
// lineReference.Line, // lineReference.Line,
// lineReference.Column); // lineReference.Column);
// } // }
// } // }
@ -289,12 +289,12 @@ namespace ICSharpCode.SharpDevelop.Gui
Debug.Assert(charIndex < textLines.Length, String.Concat("CharIndex out of range. charIndex=", charIndex, ", textLines.Length=", textLines.Length)); Debug.Assert(charIndex < textLines.Length, String.Concat("CharIndex out of range. charIndex=", charIndex, ", textLines.Length=", textLines.Length));
string textLine = String.Empty; string textLine = String.Empty;
int lineStartIndex = 0; int lineStartIndex = 0;
int lineLength = 0; int lineLength = 0;
bool wasFound = false; bool wasFound = false;
for (int i = 0; i < textLines.Length; ++i) { for (int i = 0; i < textLines.Length; ++i) {
char ch = textLines[i]; char ch = textLines[i];
if (ch == '\r' || ch == '\n') { if (ch == '\r' || ch == '\n') {
@ -304,8 +304,7 @@ namespace ICSharpCode.SharpDevelop.Gui
textLine = textLines.Substring(lineStartIndex, lineLength); textLine = textLines.Substring(lineStartIndex, lineLength);
wasFound = true; wasFound = true;
break; break;
} } else {
else {
lineStartIndex = i + 1; lineStartIndex = i + 1;
lineLength = 0; lineLength = 0;
} }
@ -362,7 +361,7 @@ namespace ICSharpCode.SharpDevelop.Gui
public event EventHandler MessageCategoryAdded; public event EventHandler MessageCategoryAdded;
public event EventHandler SelectedCategoryIndexChanged; public event EventHandler SelectedCategoryIndexChanged;
#region ICSharpCode.SharpDevelop.Gui.IClipboardHandler interface implementation #region ICSharpCode.SharpDevelop.Gui.IClipboardHandler interface implementation
public bool EnableCut { public bool EnableCut {
get { get {
return false; return false;
@ -416,6 +415,6 @@ namespace ICSharpCode.SharpDevelop.Gui
// textEditorControl.SelectAll(); // textEditorControl.SelectAll();
} }
#endregion #endregion
} }
} }

1
src/Main/Base/Project/Src/Gui/XmlForms/Lib/DefaultObjectCreator.cs

@ -33,7 +33,6 @@ namespace ICSharpCode.SharpDevelop.Gui.XmlForms
t = typeof(String).Assembly.GetType(name); t = typeof(String).Assembly.GetType(name);
} }
// try to create the object from some assembly which is currently // try to create the object from some assembly which is currently
// loaded by the running application. // loaded by the running application.
if (t == null) { if (t == null) {

18
src/Main/Base/Project/Src/Project/AbstractProject.cs

@ -5,6 +5,7 @@ using System.Diagnostics;
using System.IO; using System.IO;
using System.Globalization; using System.Globalization;
using System.Collections.Generic; using System.Collections.Generic;
using System.Reflection;
using System.Text; using System.Text;
using System.Text.RegularExpressions; using System.Text.RegularExpressions;
using System.Xml; using System.Xml;
@ -24,6 +25,23 @@ namespace ICSharpCode.SharpDevelop.Project
protected string fileName; protected string fileName;
protected string language; protected string language;
/// <summary>
/// Import options from an attribute collection. This is used to read the template options.
/// </summary>
public void ImportOptions(XmlAttributeCollection attributes)
{
Type t = GetType();
foreach (XmlAttribute attr in attributes) {
PropertyInfo prop = t.GetProperty(attr.Name, BindingFlags.IgnoreCase | BindingFlags.Instance | BindingFlags.Public);
if (prop == null) {
MessageService.ShowError("Property '" + attr.Name + "' does not exist!");
} else {
TypeConverter desc = TypeDescriptor.GetConverter(prop.PropertyType);
prop.SetValue(this, desc.ConvertFromInvariantString(attr.Value), null);
}
}
}
protected bool isDirty = false; protected bool isDirty = false;
[Browsable(false)] [Browsable(false)]

14
src/Main/Core/Project/Src/Services/MessageService/MessageService.cs

@ -53,11 +53,14 @@ namespace ICSharpCode.Core
{ {
#if DEBUG #if DEBUG
Console.WriteLine(); Console.WriteLine();
if (message != null) if (message != null)
Console.WriteLine(message); Console.WriteLine(message);
Console.WriteLine(ex); if (ex != null) {
Console.Beep(); Console.WriteLine(ex);
#else Console.Beep();
return;
}
#endif
string msg = String.Empty; string msg = String.Empty;
if (message != null) { if (message != null) {
@ -73,7 +76,6 @@ namespace ICSharpCode.Core
} }
MessageBox.Show(MessageService.MainForm, StringParser.Parse(msg), StringParser.Parse("${res:Global.ErrorText}"), MessageBoxButtons.OK, MessageBoxIcon.Error); MessageBox.Show(MessageService.MainForm, StringParser.Parse(msg), StringParser.Parse("${res:Global.ErrorText}"), MessageBoxButtons.OK, MessageBoxIcon.Error);
#endif
} }
public static void ShowWarning(string message) public static void ShowWarning(string message)

Loading…
Cancel
Save