public FontAndColorsResourceKey( Guid category, string name, FontAndColorsResourceKeyType keyType) { var isFontKey = keyType == FontAndColorsResourceKeyType.FontFamily || keyType == FontAndColorsResourceKeyType.FontSize; if (!isFontKey && name == null) { throw new ArgumentNullException(nameof(name)); } Category = category; Name = name; KeyType = keyType; }
private static bool IsBrushKeyType(FontAndColorsResourceKeyType keyType) { return (keyType == FontAndColorsResourceKeyType.BackgroundBrush || keyType == FontAndColorsResourceKeyType.ForegroundBrush); }