本文整理汇总了C#中RegexWizard.Framework.Scope.GetInnerScopes方法的典型用法代码示例。如果您正苦于以下问题:C# Scope.GetInnerScopes方法的具体用法?C# Scope.GetInnerScopes怎么用?C# Scope.GetInnerScopes使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类RegexWizard.Framework.Scope
的用法示例。
在下文中一共展示了Scope.GetInnerScopes方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: SetInnerScope_IsFlat_CreatesTwoExtraScopesIfScopeIsInTheMiddle2
public void SetInnerScope_IsFlat_CreatesTwoExtraScopesIfScopeIsInTheMiddle2()
{
scope = new Scope("abcd");
Scope inner = scope.DefineInnerScope(1, 2);
Scope[] innerScopes = scope.GetInnerScopes();
Assert.AreEqual(3, innerScopes.Length);
}
示例2: SetInnerScope_IsFlat_CreatesOneExtraScopesIfScopeIsInTheEnd
public void SetInnerScope_IsFlat_CreatesOneExtraScopesIfScopeIsInTheEnd()
{
scope = new Scope("abc");
Scope inner = scope.DefineInnerScope(2, 1);
Scope[] innerScopes = scope.GetInnerScopes();
Assert.AreEqual(2, innerScopes.Length);
}
示例3: GetInnetScopes_Returns0ByDefault
public void GetInnetScopes_Returns0ByDefault()
{
Scope s = new Scope("1");
Assert.AreEqual(0, s.GetInnerScopes().Length);
}
示例4: RemoveInnerScope_leftIsTheOnlyExplicit_AllScopesAreRemoved
public void RemoveInnerScope_leftIsTheOnlyExplicit_AllScopesAreRemoved()
{
scope = new Scope("abc");
Scope inner = scope.DefineInnerScope(0, 1);
scope.RemoveInnerScope(scope.InnerLeftScope);
Assert.AreEqual(0,scope.GetInnerScopes().Length);
}
示例5: DrawScope
private void DrawScope(Scope scopeToDraw)
{
if (!CanDrawScopes || scopeToDraw == null)
return;
VisualScopeMarker visualScopeMarker = GetVisualScopeMarker(scopeToDraw);
if (visualScopeMarker!=null)
{
visualScopeMarker.Redraw(currentGraphics);
}
// makeDebuggerMarker(scopeToDraw).DrawCustomForSingleSurroundingRect(Rectangle.Empty, scopeToDraw);
foreach (Scope innerScope in scopeToDraw.GetInnerScopes())
{
if (innerScope == null)
{
continue;
}
if (!innerScope.IsFlat)
{
DrawScope(innerScope);
}
VisualScopeMarker innerVisual = GetVisualScopeMarker(innerScope);
if(innerVisual!=null)
{
innerVisual.Redraw(currentGraphics);
}
}
}