当前位置: 首页>>代码示例>>C#>>正文


C# Scope.GetInnerScopes方法代码示例

本文整理汇总了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);
 }
开发者ID:FelicePollano,项目名称:dotnet-regex-tools,代码行数:7,代码来源:ScopeTests.cs

示例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);
 }
开发者ID:FelicePollano,项目名称:dotnet-regex-tools,代码行数:7,代码来源:ScopeTests.cs

示例3: GetInnetScopes_Returns0ByDefault

 public void GetInnetScopes_Returns0ByDefault()
 {
     Scope s = new Scope("1");
     Assert.AreEqual(0, s.GetInnerScopes().Length);
 }
开发者ID:FelicePollano,项目名称:dotnet-regex-tools,代码行数:5,代码来源:ScopeTests.cs

示例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);
 }
开发者ID:FelicePollano,项目名称:dotnet-regex-tools,代码行数:7,代码来源:ScopeTests.cs

示例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);
                }
            }
        }
开发者ID:Nullstr1ng,项目名称:dotnet-regex-tools,代码行数:30,代码来源:ScopeAwareRichTextBox.cs


注:本文中的RegexWizard.Framework.Scope.GetInnerScopes方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。