C# Класс PurplePen.Symbol

Represents a graphical symbol that can be drawn into a text box.
Показать файл Открыть проект Примеры использования класса

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

Метод Описание
ContainsLanguage ( List texts, string language ) : bool
CreateSymdef ( Map map, SymColor color, float boxSize ) : PointSymDef
Draw ( Graphics g, Color color, RectangleF rect ) : void

Draw the given symbol to fill the rectange in that graphics.

GetBestSymbolText ( SymbolDB symbolDB, List texts, string language, bool plural, string gender, string nounCase ) : string
GetGender ( string language ) : string
GetModifiedCase ( SymbolDB symbolDB, List texts, string language ) : string
GetModifiedCase ( string language ) : string
GetName ( string language ) : string
GetPluralText ( string language, string gender = null, string nounCase = "" ) : string

Get the plural text for the symbol to use in text descriptions. If no plural text is defined, the singular text is used instead.

GetSymbolGender ( SymbolDB symbolDB, List texts, string language ) : string
GetText ( string language ) : string

Get the text for the symbol to use in text descriptions.

GetText ( string language, string gender, string nounCase = "" ) : string
ReadXml ( XmlInput xmlinput ) : void

Read the state of this symbol from XML. The xmlinput must be on a symbol node.

Symbol ( SymbolDB symbolDB ) : System

Приватные методы

Метод Описание
FindBestText ( SymbolDB symbolDB, List texts, string language, bool plural, string gender, string nounCase ) : SymbolText
ReadPoints ( XmlInput xmlinput ) : System.Drawing.PointF[]

Read points array from XML.

ToLineCap ( string s, XmlInput xmlinput ) : LineCap

Convert attribute of line cap from a string.

ToLineJoin ( string s, XmlInput xmlinput ) : LineJoin

Convert attribute of line join from a string.

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

ContainsLanguage() публичный статический Метод

public static ContainsLanguage ( List texts, string language ) : bool
texts List
language string
Результат bool

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

public CreateSymdef ( Map map, SymColor color, float boxSize ) : PointSymDef
map Map
color SymColor
boxSize float
Результат PointSymDef

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

Draw the given symbol to fill the rectange in that graphics.
public Draw ( Graphics g, Color color, RectangleF rect ) : void
g System.Drawing.Graphics Graphics to draw in.
color Color Color to use for drawing.
rect System.Drawing.RectangleF The rectange to fill.
Результат void

GetBestSymbolText() публичный статический Метод

public static GetBestSymbolText ( SymbolDB symbolDB, List texts, string language, bool plural, string gender, string nounCase ) : string
symbolDB SymbolDB
texts List
language string
plural bool
gender string
nounCase string
Результат string

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

public GetGender ( string language ) : string
language string
Результат string

GetModifiedCase() публичный статический Метод

public static GetModifiedCase ( SymbolDB symbolDB, List texts, string language ) : string
symbolDB SymbolDB
texts List
language string
Результат string

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

public GetModifiedCase ( string language ) : string
language string
Результат string

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

public GetName ( string language ) : string
language string
Результат string

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

Get the plural text for the symbol to use in text descriptions. If no plural text is defined, the singular text is used instead.
public GetPluralText ( string language, string gender = null, string nounCase = "" ) : string
language string The language to use.
gender string
nounCase string
Результат string

GetSymbolGender() публичный статический Метод

public static GetSymbolGender ( SymbolDB symbolDB, List texts, string language ) : string
symbolDB SymbolDB
texts List
language string
Результат string

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

Get the text for the symbol to use in text descriptions.
public GetText ( string language ) : string
language string The language to use.
Результат string

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

public GetText ( string language, string gender, string nounCase = "" ) : string
language string
gender string
nounCase string
Результат string

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

Read the state of this symbol from XML. The xmlinput must be on a symbol node.
public ReadXml ( XmlInput xmlinput ) : void
xmlinput XmlInput
Результат void

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

public Symbol ( SymbolDB symbolDB ) : System
symbolDB SymbolDB
Результат System