public static string GetDocumentation(ProcScope mi)
 {
     try
     {
         if (mi.declaringUnit != null)
         {
             CodeCompletionTools.XmlDoc xdoc = (CodeCompletionTools.XmlDoc)ht[mi.declaringUnit];
             if (xdoc != null)
             {
                 string s = "";
                 if (mi.declaringType != null)
                 {
                     if (!mi.is_constructor)
                     {
                         s = GetNormalHint(xdoc.GetDocumentation("M:" + mi.declaringType.si.name + "." + mi.si.name + GetParamNames(mi), true));
                     }
                     else
                     {
                         s = GetNormalHint(xdoc.GetDocumentation("M:" + mi.declaringType.si.name + ".#ctor" + GetParamNames(mi), true));
                     }
                 }
                 else
                 {
                     s = GetNormalHint(xdoc.GetDocumentation("M:" + mi.name + GetParamNames(mi), true));
                 }
                 return(s);
             }
         }
     }
     catch (Exception e)
     {
     }
     return("");
 }
        public static string GetDocumentation(ElementScope es)
        {
            try
            {
                if (es.declaringUnit == null)
                {
                    return("");
                }
                CodeCompletionTools.XmlDoc xdoc = (CodeCompletionTools.XmlDoc)ht[es.declaringUnit];
                if (xdoc != null)
                {
                    string s = "";
                    switch (es.si.kind)
                    {
                    case SymbolKind.Variable: s = GetNormalHint(xdoc.GetDocumentation("V:" + es.si.name, true)); break;

                    case SymbolKind.Field: s = GetNormalHint(xdoc.GetDocumentation("F:" + es.topScope.si.name + "." + es.si.name, true)); break;

                    case SymbolKind.Property: s = GetNormalHint(xdoc.GetDocumentation("P:" + es.topScope.si.name + "." + es.si.name, true)); break;

                    case SymbolKind.Event: s = GetNormalHint(xdoc.GetDocumentation("E:" + es.topScope.si.name + "." + es.si.name, true)); break;

                    case SymbolKind.Constant: s = GetNormalHint(xdoc.GetDocumentation("C:" + es.si.name, true)); break;
                    }
                    return(s);
                }
            }
            catch (Exception e)
            {
            }
            return("");
        }
        public static void LoadWithSources(SymScope unit, string fileName)
        {
            if (ht[unit] != null)
            {
                return;
            }
            string xml_loc = CodeCompletionTools.XmlDoc.LookupLocalizedXmlDocForUnitWithSources(fileName, CodeCompletionController.currentLanguageISO);

            if (xml_loc != null)
            {
                CodeCompletionTools.XmlDoc xdoc = CodeCompletionTools.XmlDoc.Load(xml_loc, Environment.GetEnvironmentVariable("TEMP"), false);
                ht[unit] = xdoc;
            }
        }
 public static string GetDocumentation(InterfaceUnitScope mi)
 {
     try
     {
         CodeCompletionTools.XmlDoc xdoc = (CodeCompletionTools.XmlDoc)ht[mi];
         if (xdoc != null)
         {
             return(GetNormalHint(xdoc.GetDocumentation(mi.si.name, true)));
         }
     }
     catch (Exception e)
     {
     }
     return("");
 }
 public static string GetDocumentation(SymScope unit, string descr)
 {
     try
     {
         CodeCompletionTools.XmlDoc xdoc = (CodeCompletionTools.XmlDoc)ht[unit];
         if (xdoc != null)
         {
             string s = GetNormalHint(xdoc.GetDocumentation(descr, false));
             return(s);
         }
     }
     catch (Exception e)
     {
     }
     return("");
 }
 public static string GetDocumentation(TypeScope t)
 {
     try
     {
         if (t.declaringUnit != null)
         {
             CodeCompletionTools.XmlDoc xdoc = (CodeCompletionTools.XmlDoc)ht[t.declaringUnit];
             if (xdoc != null)
             {
                 string s = GetNormalHint(xdoc.GetDocumentation("T:" + t.si.name, true));
                 return(s);
             }
         }
     }
     catch (Exception e)
     {
     }
     return("");
 }