本文整理汇总了C#中TextPosition类的典型用法代码示例。如果您正苦于以下问题:C# TextPosition类的具体用法?C# TextPosition怎么用?C# TextPosition使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
TextPosition类属于命名空间,在下文中一共展示了TextPosition类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: ScopeGuardStatement
public ScopeGuardStatement(TextPosition tp, ScopeGuardType type, ProgramContext block)
: base(tp)
{
ScopeGuardType = type;
Block = block;
AppendChild(Block);
}
示例2: XmlDeclarationToken
/// <summary>
/// Creates a new XML declaration token.
/// </summary>
public XmlDeclarationToken(TextPosition position)
: base(XmlTokenType.Declaration, position)
{
_version = String.Empty;
_encoding = null;
_standalone = false;
}
示例3: WithExpression
public WithExpression(TextPosition cp, Element access, ProgramContext block)
{
Access = access;
Block = block;
AppendChild(Block);
AppendChild(Access);
}
示例4: EnumSymbol
protected EnumSymbol(TextPosition tp, string name, ProgramContext block)
: base(tp)
{
Name = name;
Block = block;
AppendChild(Block);
}
示例5: HtmlDoctypeToken
/// <summary>
/// Creates a new DOCTYPE token with the quirks mode set initially.
/// </summary>
/// <param name="quirksForced">The state of the force-quirks flag.</param>
/// <param name="position">The token's position.</param>
public HtmlDoctypeToken(Boolean quirksForced, TextPosition position)
: base(HtmlTokenType.Doctype, position)
{
_publicIdentifier = null;
_systemIdentifier = null;
_quirks = quirksForced;
}
示例6: Location
public Location(ISourceText file, TextPosition position)
{
Requires.NotNull(file, nameof(file));
File = file;
Position = position;
}
示例7: InsertTextCommand
public InsertTextCommand(
TextPosition textPosition,
string text)
: base(textPosition)
{
Text = text;
}
示例8: MemberAccess
public MemberAccess(TextPosition tp, Element acs, string member)
: base(tp)
{
Access = acs;
Member = member;
AppendChild(Access);
}
示例9: CssRangeToken
/// <summary>
/// Creates a new CSS range token.
/// </summary>
/// <param name="range">The selected range string.</param>
/// <param name="position">The token's position.</param>
public CssRangeToken(String range, TextPosition position)
: base(CssTokenType.Range, range, position)
{
_start = range.Replace(Symbols.QuestionMark, '0');
_end = range.Replace(Symbols.QuestionMark, 'F');
_range = GetRange();
}
示例10: AliasDeclaration
public AliasDeclaration(TextPosition tp, Identifier from, Identifier to)
: base(tp)
{
From = from;
To = to;
Name = To == null ? string.Empty : To.Value;
}
示例11: MonadicExpression
protected MonadicExpression(TextPosition tp, TokenType op, Element exp)
: base(tp)
{
Operator = op;
Exp = exp;
AppendChild(Exp);
}
示例12: VerticalUpPoint
public void VerticalUpPoint(TickBarPlacement placement, string expected)
{
var textPositionOptions = new TextPositionOptions( placement, TextOrientation.VerticalUp);
var textSize = new Size(this.text.Width, this.text.Height);
var textPosition = new TextPosition(textSize,textPositionOptions, new Point(0, 0), 0);
Assert.AreEqual(expected, textPosition.Point.ToString("F0"));
}
示例13: XmlDoctypeToken
/// <summary>
/// Creates a new DOCTYPE token.
/// </summary>
public XmlDoctypeToken(TextPosition position)
: base(XmlTokenType.Doctype, position)
{
_name = null;
_publicIdentifier = null;
_systemIdentifier = null;
}
示例14: XmlEntityToken
/// <summary>
/// Creates a new entity token.
/// </summary>
public XmlEntityToken(TextPosition position, String value, Boolean numeric = false, Boolean hex = false)
: base(XmlTokenType.Entity, position)
{
_numeric = numeric;
_hex = hex;
_value = value;
}
示例15: AssociatePair
public AssociatePair(TextPosition tp, Element left, Element right)
: base(tp)
{
Left = left;
Right = right;
AppendChild(Left);
AppendChild(Right);
}