C# Класс AppKit.TextKit.Formatter.LanguageDescriptor

Наследование: NSObject
Показать файл Открыть проект Примеры использования класса

Private Properties

Свойство Тип Описание

Открытые методы

Метод Описание
ClearFormats ( ) : void

Resets all of the AppKit.TextKit.Formatter.FormatDescriptor for this language to their default states of unmacthed and inactive.

This should only be called ba a AppKit.TextKit.Formatter.LanguageFormatter.

Define ( ) : void

Define this instance.

FormatForPreview ( string text ) : string

Formats the passed in string of text for previewing.

LanguageDescriptor ( ) : System

Initializes a new instance of the AppKit.TextKit.Formatter.LanguageDescriptor class.

LoadColor ( string key, NSColor defaultValue ) : NSColor

Loads the requested color from system-wide user defaults.

NSColorFromHexString ( string hexValue ) : NSColor

Converts a web formatted hex string in the form #RRGGBB or #RRGGBBAA into a color.

NSColorToHexString ( NSColor color, bool withAlpha ) : string

Converts the given color into a web style hex string in the form #RRBBGG or optionally #RRBBGGAA.

SaveColor ( string key, NSColor color, bool sync ) : void

Saves the given color to the systwm-wide user defaults with the give keyword.

Описание методов

ClearFormats() публичный Метод

Resets all of the AppKit.TextKit.Formatter.FormatDescriptor for this language to their default states of unmacthed and inactive.
This should only be called ba a AppKit.TextKit.Formatter.LanguageFormatter.
public ClearFormats ( ) : void
Результат void

Define() публичный Метод

Define this instance.
public Define ( ) : void
Результат void

FormatForPreview() публичный Метод

Formats the passed in string of text for previewing.
public FormatForPreview ( string text ) : string
text string Text.
Результат string

LanguageDescriptor() публичный Метод

Initializes a new instance of the AppKit.TextKit.Formatter.LanguageDescriptor class.
public LanguageDescriptor ( ) : System
Результат System

LoadColor() публичный Метод

Loads the requested color from system-wide user defaults.
public LoadColor ( string key, NSColor defaultValue ) : NSColor
key string The user default key for the color.
defaultValue NSColor The default NSColor value.
Результат NSColor

NSColorFromHexString() публичный Метод

Converts a web formatted hex string in the form #RRGGBB or #RRGGBBAA into a color.
public NSColorFromHexString ( string hexValue ) : NSColor
hexValue string The web formatted hex string in the form #RRGGBB or #RRGGBBAA.
Результат NSColor

NSColorToHexString() публичный Метод

Converts the given color into a web style hex string in the form #RRBBGG or optionally #RRBBGGAA.
public NSColorToHexString ( NSColor color, bool withAlpha ) : string
color NSColor The NSColor to convert.
withAlpha bool If set to true with the alpha (transparency) of the color will be /// included.
Результат string

SaveColor() публичный Метод

Saves the given color to the systwm-wide user defaults with the give keyword.
public SaveColor ( string key, NSColor color, bool sync ) : void
key string The user default key to assign the color to.
color NSColor The NSColor to save to the user defaults.
sync bool If set to true sync changes to preferences.
Результат void