Example #1
0
            ICompletionData ICompletionDataFactory.CreateTypeCompletionData(IType type, bool showFullName, bool isInAttributeContext)
            {
                Lazy <string> displayText = new Lazy <string> (delegate {
                    string name = showFullName ? builder.ConvertType(type).GetText() : type.Name;
                    if (isInAttributeContext && name.EndsWith("Attribute") && name.Length > "Attribute".Length)
                    {
                        name = name.Substring(0, name.Length - "Attribute".Length);
                    }
                    return(name);
                });

                var result = new TypeCompletionData(type, ext,
                                                    displayText,
                                                    type.GetStockIcon());

                return(result);
            }
        public ICompletionData CreateTypeCompletionData(ICSharpCode.NRefactory.TypeSystem.IType type, bool fullName, bool isInAttributeContext, bool addForTypeCreation)
        {
            var cd = new TypeCompletionData(type, fullName, isInAttributeContext, builder, addForTypeCreation);

            return(cd);
        }
 public ICompletionData CreateTypeCompletionData(ICSharpCode.NRefactory.TypeSystem.IType type, bool fullName, bool isInAttributeContext, bool addForTypeCreation)
 {
     var cd = new TypeCompletionData(type, fullName, isInAttributeContext, builder, addForTypeCreation);
     return cd;
 }