21 instantiations of CharacterRange
System.Drawing.Common.Tests (19)
mono\System.Drawing\GraphicsTests.cs (4)
1892
CharacterRange[] ranges = [new
CharacterRange
(0, 5), new
CharacterRange
(5, 9)];
1915
CharacterRange[] ranges = [new
CharacterRange
(first, length)];
1959
CharacterRange[] ranges = [new
CharacterRange
(5, 4)];
mono\System.Imaging\MetafileTest.cs (2)
306
CharacterRange[] ranges = [new
CharacterRange
(0, 5), new
CharacterRange
(5, 9)];
System\Drawing\CharacterRangeTests.cs (11)
22
CharacterRange range =
new
(First, Length);
33
CharacterRange range =
new
()
50
CharacterRange range =
new
()
63
yield return new object[] { new
CharacterRange
(1, 2), new
CharacterRange
(1, 2), true };
64
yield return new object[] { new
CharacterRange
(1, 2), new
CharacterRange
(2, 2), false };
65
yield return new object[] { new
CharacterRange
(1, 2), new
CharacterRange
(1, 1), false };
66
yield return new object[] { new
CharacterRange
(1, 2), new(), false };
71
yield return new object[] { new
CharacterRange
(1, 2), null, false };
System\Drawing\StringFormatTests.cs (2)
201
yield return new object[] { new CharacterRange[] {
new
(1, 2) } };
202
yield return new object[] { new CharacterRange[] {
new
(-1, -1) } };
System.Windows.Forms (2)
System\Windows\Forms\Controls\Labels\LinkLabel.cs (2)
638
ranges.Add(new
CharacterRange
(charStart, ConvertToCharIndex(link.Start + length, text) - charStart));
642
ranges.Add(new
CharacterRange
(0, text.Length));
26 references to CharacterRange
System.Drawing (1)
System.Drawing.cs (1)
12
[assembly: System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Drawing.
CharacterRange
))]
System.Drawing.Common (5)
Special\NotSupported.cs (5)
248
public static bool operator ==(System.Drawing.
CharacterRange
cr1, System.Drawing.
CharacterRange
cr2) { throw new System.PlatformNotSupportedException(System.SR.SystemDrawingCommon_PlatformNotSupported); }
249
public static bool operator !=(System.Drawing.
CharacterRange
cr1, System.Drawing.
CharacterRange
cr2) { throw new System.PlatformNotSupportedException(System.SR.SystemDrawingCommon_PlatformNotSupported); }
1149
public void SetMeasurableCharacterRanges(System.Drawing.
CharacterRange
[] ranges) { throw new System.PlatformNotSupportedException(System.SR.SystemDrawingCommon_PlatformNotSupported); }
System.Drawing.Common.Tests (17)
mono\System.Drawing\GraphicsTests.cs (4)
1892
CharacterRange
[] ranges = [new CharacterRange(0, 5), new CharacterRange(5, 9)];
1915
CharacterRange
[] ranges = [new CharacterRange(first, length)];
1959
CharacterRange
[] ranges = [new CharacterRange(5, 4)];
2004
private static readonly
CharacterRange
[] s_ranges = [new(0, 1), new(1, 1), new(2, 1)];
mono\System.Imaging\MetafileTest.cs (1)
306
CharacterRange
[] ranges = [new CharacterRange(0, 5), new CharacterRange(5, 9)];
System\Drawing\CharacterRangeTests.cs (6)
11
CharacterRange
range = default;
22
CharacterRange
range = new(First, Length);
33
CharacterRange
range = new()
50
CharacterRange
range = new()
77
public void Equals_Invoke_ReturnsExpected(
CharacterRange
range, object obj, bool expected)
80
if (obj is
CharacterRange
otherRange)
System\Drawing\StringFormatTests.cs (6)
200
yield return new object[] { Array.Empty<
CharacterRange
>() };
201
yield return new object[] { new
CharacterRange
[] { new(1, 2) } };
202
yield return new object[] { new
CharacterRange
[] { new(-1, -1) } };
203
yield return new object[] { new
CharacterRange
[32] };
208
public void SetMeasurableCharacterRanges_Valid_Success(
CharacterRange
[] ranges)
225
Assert.Throws<OverflowException>(() => format.SetMeasurableCharacterRanges(new
CharacterRange
[33]));
System.Windows.Forms (3)
System\Windows\Forms\Controls\Labels\LinkLabel.cs (3)
609
CharacterRange
[] regions = AdjustCharacterRangesForSurrogateChars();
618
private
CharacterRange
[] AdjustCharacterRangesForSurrogateChars()
629
List<
CharacterRange
> ranges = new(Links.Count + 1);