Browse Source

Add strong-name to NRefactory; small API changes for ICSharpCode.Editor.

newNRvisualizers
Daniel Grunwald 14 years ago
parent
commit
cb70bceece
  1. 4
      ICSharpCode.Editor/ICSharpCode.Editor.csproj
  2. 53
      ICSharpCode.Editor/IDocument.cs
  3. 2
      ICSharpCode.Editor/Properties/AssemblyInfo.cs
  4. 12
      ICSharpCode.Editor/ReadOnlyDocument.cs
  5. BIN
      ICSharpCode.NRefactory.snk
  6. 8
      ICSharpCode.NRefactory/ICSharpCode.NRefactory.csproj

4
ICSharpCode.Editor/ICSharpCode.Editor.csproj

@ -10,7 +10,7 @@ @@ -10,7 +10,7 @@
<TargetFrameworkVersion>v4.0</TargetFrameworkVersion>
<TargetFrameworkProfile>Client</TargetFrameworkProfile>
<AppDesignerFolder>Properties</AppDesignerFolder>
<SignAssembly>False</SignAssembly>
<SignAssembly>True</SignAssembly>
<DelaySign>False</DelaySign>
<RunPostBuildEvent>OnBuildSuccess</RunPostBuildEvent>
<DocumentationFile>bin\Debug\ICSharpCode.Editor.xml</DocumentationFile>
@ -19,6 +19,8 @@ @@ -19,6 +19,8 @@
<WarningLevel>4</WarningLevel>
<TreatWarningsAsErrors>false</TreatWarningsAsErrors>
<RunCodeAnalysis>False</RunCodeAnalysis>
<AssemblyOriginatorKeyFile>..\ICSharpCode.NRefactory.snk</AssemblyOriginatorKeyFile>
<AssemblyOriginatorKeyMode>File</AssemblyOriginatorKeyMode>
</PropertyGroup>
<PropertyGroup Condition=" '$(Platform)' == 'x86' ">
<PlatformTarget>x86</PlatformTarget>

53
ICSharpCode.Editor/IDocument.cs

@ -10,7 +10,7 @@ namespace ICSharpCode.Editor @@ -10,7 +10,7 @@ namespace ICSharpCode.Editor
/// Line and column counting starts at 1.
/// Offset counting starts at 0.
/// </summary>
public interface IDocument : ITextSource, IServiceProvider
public interface IDocument : ITextSource
{
/// <summary>
/// Gets/Sets the text of the whole document..
@ -18,20 +18,41 @@ namespace ICSharpCode.Editor @@ -18,20 +18,41 @@ namespace ICSharpCode.Editor
new string Text { get; set; } // hides TextBuffer.Text to add the setter
/// <summary>
/// Is raised when the Text property changes.
/// This event is called directly before a change is applied to the document.
/// </summary>
/// <remarks>
/// It is invalid to modify the document within this event handler.
/// Aborting the change (by throwing an exception) is likely to cause corruption of data structures
/// that listen to the Changing and Changed events.
/// </remarks>
event EventHandler<TextChangeEventArgs> TextChanging;
/// <summary>
/// This event is called directly after a change is applied to the document.
/// </summary>
/// <remarks>
/// It is invalid to modify the document within this event handler.
/// Aborting the event handler (by throwing an exception) is likely to cause corruption of data structures
/// that listen to the Changing and Changed events.
/// </remarks>
event EventHandler<TextChangeEventArgs> TextChanged;
/// <summary>
/// This event is called after a group of changes is completed.
/// </summary>
event EventHandler TextChanged;
/// <seealso cref="EndUndoableAction"/>
event EventHandler ChangeCompleted;
/// <summary>
/// Gets the total number of lines in the document.
/// Gets the number of lines in the document.
/// </summary>
int TotalNumberOfLines { get; }
int LineCount { get; }
/// <summary>
/// Gets the document line with the specified number.
/// </summary>
/// <param name="lineNumber">The number of the line to retrieve. The first line has number 1.</param>
IDocumentLine GetLine(int lineNumber);
IDocumentLine GetLineByNumber(int lineNumber);
/// <summary>
/// Gets the document line that contains the specified offset.
@ -117,25 +138,5 @@ namespace ICSharpCode.Editor @@ -117,25 +138,5 @@ namespace ICSharpCode.Editor
/// </summary>
/// <inheritdoc cref="ITextAnchor" select="remarks|example"/>
ITextAnchor CreateAnchor(int offset);
/// <summary>
/// This event is called directly before a change is applied to the document.
/// </summary>
/// <remarks>
/// It is invalid to modify the document within this event handler.
/// Aborting the change (by throwing an exception) is likely to cause corruption of data structures
/// that listen to the Changing and Changed events.
/// </remarks>
event EventHandler<TextChangeEventArgs> Changing;
/// <summary>
/// This event is called directly after a change is applied to the document.
/// </summary>
/// <remarks>
/// It is invalid to modify the document within this event handler.
/// Aborting the event handler (by throwing an exception) is likely to cause corruption of data structures
/// that listen to the Changing and Changed events.
/// </remarks>
event EventHandler<TextChangeEventArgs> Changed;
}
}

2
ICSharpCode.Editor/Properties/AssemblyInfo.cs

@ -29,3 +29,5 @@ using System.Runtime.InteropServices; @@ -29,3 +29,5 @@ using System.Runtime.InteropServices;
// You can specify all the values or you can use the default the Revision and
// Build Numbers by using the '*' as shown below:
[assembly: AssemblyVersion("1.0.*")]
[assembly: CLSCompliant(true)]

12
ICSharpCode.Editor/ReadOnlyDocument.cs

@ -48,7 +48,7 @@ namespace ICSharpCode.Editor @@ -48,7 +48,7 @@ namespace ICSharpCode.Editor
}
/// <inheritdoc/>
public IDocumentLine GetLine(int lineNumber)
public IDocumentLine GetLineByNumber(int lineNumber)
{
if (lineNumber < 1 || lineNumber > lines.Length)
throw new ArgumentOutOfRangeException("lineNumber", lineNumber, "Value must be between 1 and " + lines.Length);
@ -121,7 +121,7 @@ namespace ICSharpCode.Editor @@ -121,7 +121,7 @@ namespace ICSharpCode.Editor
/// <inheritdoc/>
public IDocumentLine GetLineByOffset(int offset)
{
return GetLine(GetLineNumberForOffset(offset));
return GetLineByNumber(GetLineNumberForOffset(offset));
}
int GetLineNumberForOffset(int offset)
@ -168,7 +168,7 @@ namespace ICSharpCode.Editor @@ -168,7 +168,7 @@ namespace ICSharpCode.Editor
}
/// <inheritdoc/>
public int TotalNumberOfLines {
public int LineCount {
get { return lines.Length; }
}
@ -181,11 +181,11 @@ namespace ICSharpCode.Editor @@ -181,11 +181,11 @@ namespace ICSharpCode.Editor
get { return textSource.TextLength; }
}
event EventHandler<TextChangeEventArgs> IDocument.Changing { add {} remove {} }
event EventHandler<TextChangeEventArgs> IDocument.TextChanging { add {} remove {} }
event EventHandler<TextChangeEventArgs> IDocument.Changed { add {} remove {} }
event EventHandler<TextChangeEventArgs> IDocument.TextChanged { add {} remove {} }
event EventHandler IDocument.TextChanged { add {} remove {} }
event EventHandler IDocument.ChangeCompleted { add {} remove {} }
void IDocument.Insert(int offset, string text)
{

BIN
ICSharpCode.NRefactory.snk

Binary file not shown.

8
ICSharpCode.NRefactory/ICSharpCode.NRefactory.csproj

@ -17,6 +17,10 @@ @@ -17,6 +17,10 @@
<NoWarn>1591,0618</NoWarn>
<RunCodeAnalysis>False</RunCodeAnalysis>
<CodeAnalysisRules>-Microsoft.Design#CA1026;-Microsoft.Security#CA2104</CodeAnalysisRules>
<SignAssembly>True</SignAssembly>
<AssemblyOriginatorKeyFile>..\ICSharpCode.NRefactory.snk</AssemblyOriginatorKeyFile>
<DelaySign>False</DelaySign>
<AssemblyOriginatorKeyMode>File</AssemblyOriginatorKeyMode>
</PropertyGroup>
<PropertyGroup Condition=" '$(Platform)' == 'AnyCPU' ">
<PlatformTarget>AnyCPU</PlatformTarget>
@ -407,10 +411,6 @@ @@ -407,10 +411,6 @@
<Project>{D68133BD-1E63-496E-9EDE-4FBDBF77B486}</Project>
<Name>Mono.Cecil</Name>
</ProjectReference>
<ProjectReference Include="..\ICSharpCode.Editor\ICSharpCode.Editor.csproj">
<Project>{F054A788-B591-4561-A8BA-AE745BBEB817}</Project>
<Name>ICSharpCode.Editor</Name>
</ProjectReference>
</ItemGroup>
<Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" />
</Project>
Loading…
Cancel
Save