blob: 6d32abad4e459ce984af04708291fc0f8f101e39 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
|
// Copyright (c) AlphaSierraPapa for the SharpDevelop Team (for details please see \doc\copyright.txt)
// This code is distributed under the GNU LGPL (for details please see \doc\license.txt)
using System;
namespace Tango.Scripting.Editors.Highlighting.Xshd
{
/// <summary>
/// Specifies the type of the regex.
/// </summary>
public enum XshdRegexType
{
/// <summary>
/// Normal regex. Used when the regex was specified as attribute.
/// </summary>
Default,
/// <summary>
/// Ignore pattern whitespace / allow regex comments. Used when the regex was specified as text element.
/// </summary>
[System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Naming", "CA1702:CompoundWordsShouldBeCasedCorrectly",
Justification = "Using the same case as the RegexOption")]
IgnorePatternWhitespace
}
/// <summary>
/// <Span> element.
/// </summary>
[Serializable]
public class XshdSpan : XshdElement
{
/// <summary>
/// Gets/sets the begin regex.
/// </summary>
public string BeginRegex { get; set; }
/// <summary>
/// Gets/sets the begin regex type.
/// </summary>
public XshdRegexType BeginRegexType { get; set; }
/// <summary>
/// Gets/sets the end regex.
/// </summary>
public string EndRegex { get; set; }
/// <summary>
/// Gets/sets the end regex type.
/// </summary>
public XshdRegexType EndRegexType { get; set; }
/// <summary>
/// Gets/sets whether the span is multiline.
/// </summary>
public bool Multiline { get; set; }
/// <summary>
/// Gets/sets the rule set reference.
/// </summary>
public XshdReference<XshdRuleSet> RuleSetReference { get; set; }
/// <summary>
/// Gets/sets the span color.
/// </summary>
public XshdReference<XshdColor> SpanColorReference { get; set; }
/// <summary>
/// Gets/sets the span begin color.
/// </summary>
public XshdReference<XshdColor> BeginColorReference { get; set; }
/// <summary>
/// Gets/sets the span end color.
/// </summary>
public XshdReference<XshdColor> EndColorReference { get; set; }
/// <inheritdoc/>
public override object AcceptVisitor(IXshdVisitor visitor)
{
return visitor.VisitSpan(this);
}
}
}
|