Exemple #1
0
 /// <summary>
 /// Gets the expression category.
 /// </summary>
 /// <param name="key">The key.</param>
 /// <returns></returns>
 public static KeyValuePair <string, string> GetExpressionCategory(CategoryKey key)
 {
     if (Categories.ContainsKey(key.ToString().ToLower()))
     {
         return(new KeyValuePair <string, string>(key.ToString().ToLower(), Categories[key.ToString().ToLower()]));
     }
     else
     {
         return(new KeyValuePair <string, string>(String.Empty, String.Empty));
     }
 }
Exemple #2
0
 /// <summary>
 /// Returns value under specified CategoryKey in Categories collection
 /// </summary>
 /// <param name="key">The key.</param>
 /// <returns></returns>
 public static string GetExpressionCategoryValue(CategoryKey key)
 {
     if (Categories.ContainsKey(key.ToString().ToLower()))
     {
         return(Categories[key.ToString().ToLower()]);
     }
     else
     {
         return(null);
     }
 }
Exemple #3
0
        public PatternImage GetImage(PatternImageSize size)
        {
            Contract.Ensures(Contract.Result <PatternImage>() != null);

            return(PatternImage.Create(DesignerKey.ToString(), CategoryKey.ToString(), Reference, Variant, size));
        }