Changeset 11722
- Timestamp:
- 12/23/14 13:39:27 (10 years ago)
- Location:
- branches/CodeEditor/HeuristicLab.CodeEditor/3.4
- Files:
-
- 1 added
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/CodeEditor/HeuristicLab.CodeEditor/3.4/HeuristicLab.CodeEditor-3.4.csproj
r11700 r11722 192 192 </Page> 193 193 </ItemGroup> 194 <ItemGroup />195 194 <ItemGroup> 196 195 <Resource Include="LanguageFeatures\CodeCompletion\CSharp\CompletionData\Images\Class.png" /> … … 218 217 <Resource Include="LanguageFeatures\CodeCompletion\CSharp\CompletionData\Images\StaticClass.png" /> 219 218 <Resource Include="LanguageFeatures\CodeCompletion\CSharp\CompletionData\Images\Struct.png" /> 219 <Resource Include="LanguageFeatures\CodeCompletion\CSharp\CompletionData\Images\Template.png" /> 220 220 <Resource Include="LanguageFeatures\CodeCompletion\CSharp\CompletionData\Images\VirtualMethod.png" /> 221 221 </ItemGroup> -
branches/CodeEditor/HeuristicLab.CodeEditor/3.4/LanguageFeatures/CodeCompletion/CSharp/CSharpCodeCompletionDataFactory.cs
r11700 r11722 71 71 72 72 public ICompletionData CreateXmlDocCompletionData(string title, string description = null, string insertText = null) { 73 return new CompletionData("TODO: xml doc creation"); 73 return new CompletionData(title) { 74 Description = description, 75 CompletionText = insertText ?? title, 76 Image = CompletionImage.Template.BaseImage, 77 }; 74 78 } 75 79 … … 87 91 88 92 public ICompletionData CreateEventCreationCompletionData(string varName, IType delegateType, IEvent evt, string parameterDefinition, IUnresolvedMember currentMember, IUnresolvedTypeDefinition currentType) { 89 return new CompletionData( "TODO: event creation");93 return new CompletionData(varName); 90 94 } 91 95 92 96 public ICompletionData CreateNewOverrideCompletionData(int declarationBegin, IUnresolvedTypeDefinition type, IMember m) { 93 return new CompletionData( "TODO: override creation");97 return new CompletionData(m.Name); 94 98 } 95 99 96 100 public ICompletionData CreateNewPartialCompletionData(int declarationBegin, IUnresolvedTypeDefinition type, IUnresolvedMember m) { 97 return new CompletionData( "TODO: partial creation");101 return new CompletionData(m.Name); 98 102 } 99 103 100 104 public ICompletionData CreateImportCompletionData(IType type, bool useFullName, bool addForTypeCreation) { 101 105 var typeDef = type.GetDefinition(); 102 if (typeDef != null) return new ImportCompletionData(typeDef, context.TypeResolveContextAtCaret, useFullName); 103 throw new InvalidOperationException("Should never happen"); 106 return new ImportCompletionData(typeDef, context.TypeResolveContextAtCaret, useFullName); 104 107 } 105 108 106 109 public IEnumerable<ICompletionData> CreateCodeTemplateCompletionData() { 107 yield return new CompletionData("TODO: code template creation");;110 yield break; 108 111 } 109 112 110 113 public ICompletionData CreateFormatItemCompletionData(string format, string description, object example) { 111 return n ew CompletionData("TODO: format item creation");114 return null; 112 115 } 113 116 114 117 public IEnumerable<ICompletionData> CreatePreProcessorDefinesCompletionData() { 115 yield return new CompletionData("TODO: pre processor creation");;118 yield break; 116 119 } 117 120 #endregion … … 131 134 132 135 public IParameterDataProvider CreateIndexerParameterDataProvider(int startOffset, IType type, IEnumerable<IProperty> accessibleIndexers, ICSharpCode.NRefactory.CSharp.AstNode resolvedNode) { 133 throw new NotImplementedException();136 return null; 134 137 } 135 138 -
branches/CodeEditor/HeuristicLab.CodeEditor/3.4/LanguageFeatures/CodeCompletion/CSharp/CompletionData/Images/CompletionImage.cs
r11700 r11722 1 #region License 1 #region License Information 2 2 // Copyright (c) AlphaSierraPapa for the SharpDevelop Team (for details please see \doc\copyright.txt) 3 3 // This code is distributed under the GNU LGPL (for details please see \doc\license.txt) 4 #endregion 5 6 #region License Information 4 7 5 /* HeuristicLab 8 6 * Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL) … … 84 82 static readonly CompletionImage imageLiteral = new CompletionImage("Literal", false); 85 83 static readonly CompletionImage imageEnumValue = new CompletionImage("EnumValue", false); 84 static readonly CompletionImage imageTemplate = new CompletionImage("Template", false); 86 85 87 86 /// <summary>Gets the image used for non-static classes.</summary> … … 96 95 /// <summary>Gets the image used for enum values.</summary> 97 96 public static CompletionImage EnumValue { get { return imageEnumValue; } } 97 98 /// <summary>Gets the image used for templates.</summary> 99 public static CompletionImage Template { get { return imageTemplate; } } 98 100 99 101 static readonly CompletionImage imageMethod = new CompletionImage("Method", true); -
branches/CodeEditor/HeuristicLab.CodeEditor/3.4/LanguageFeatures/CodeFolding/CSharp/CSharpCodeFoldingStrategy.cs
r11700 r11722 47 47 v.document = foldingContext.Document; 48 48 foldingContext.SyntaxTree.AcceptVisitor(v); 49 result.FoldingData = v.foldings ;49 result.FoldingData = v.foldings.OrderBy(x => x.StartOffset).ToList(); 50 50 51 51 var firstError = foldingContext.SyntaxTree.Errors.FirstOrDefault();
Note: See TracChangeset
for help on using the changeset viewer.