1 write to _font
System.Drawing.Common.Tests (1)
mono\System.Drawing\GraphicsTests.cs (1)
48_font = new Font("Arial", 12);
86 references to _font
System.Drawing.Common.Tests (86)
mono\System.Drawing\GraphicsTests.cs (86)
57_font?.Dispose(); 1575SizeF size = g.MeasureString(null, _font); 1577size = g.MeasureString(string.Empty, _font); 1579g.MeasureString(string.Empty.AsSpan(), _font); 1605SizeF size = g.MeasureString("a", _font, SizeF.Empty); 1608size = g.MeasureString("a".AsSpan(), _font, SizeF.Empty); 1611size = g.MeasureString(string.Empty, _font, SizeF.Empty); 1614size = g.MeasureString(string.Empty.AsSpan(), _font, SizeF.Empty); 1622SizeF size0 = useSpan ? g.MeasureString(s.AsSpan(), _font, 0) : g.MeasureString(s, _font, 0); 1623SizeF sizeN = useSpan ? g.MeasureString(s.AsSpan(), _font, int.MinValue) : g.MeasureString(s, _font, int.MinValue); 1624SizeF sizeP = useSpan ? g.MeasureString(s.AsSpan(), _font, int.MaxValue) : g.MeasureString(s, _font, int.MaxValue); 1657? g.MeasureString(text.AsSpan(), _font, int.MaxValue, string_format) 1658: g.MeasureString(text, _font, int.MaxValue, string_format); 1662? g.MeasureString(text.AsSpan(), _font, int.MaxValue, string_format) 1663: g.MeasureString(text, _font, int.MaxValue, string_format); 1667? g.MeasureString(text.AsSpan(), _font, int.MaxValue, string_format) 1668: g.MeasureString(text, _font, int.MaxValue, string_format); 1690? g.MeasureString(text.AsSpan(), _font, int.MaxValue, string_format) 1691: g.MeasureString(text, _font, int.MaxValue, string_format); 1695? g.MeasureString(text.AsSpan(), _font, int.MaxValue, string_format) 1696: g.MeasureString(text, _font, int.MaxValue, string_format); 1700? g.MeasureString(text.AsSpan(), _font, int.MaxValue, string_format) 1701: g.MeasureString(text, _font, int.MaxValue, string_format); 1721? g.MeasureString(text.AsSpan(), _font, int.MaxValue, string_format) 1722: g.MeasureString(text, _font, int.MaxValue, string_format); 1726? g.MeasureString(text.AsSpan(), _font, int.MaxValue, string_format) 1727: g.MeasureString(text, _font, int.MaxValue, string_format); 1731? g.MeasureString(text.AsSpan(), _font, int.MaxValue, string_format) 1732: g.MeasureString(text, _font, int.MaxValue, string_format); 1754? g.MeasureString(text.AsSpan(), _font, int.MaxValue, string_format) 1755: g.MeasureString(text, _font, int.MaxValue, string_format); 1759? g.MeasureString(text.AsSpan(), _font, int.MaxValue, string_format) 1760: g.MeasureString(text, _font, int.MaxValue, string_format); 1764? g.MeasureString(text.AsSpan(), _font, int.MaxValue, string_format) 1765: g.MeasureString(text, _font, int.MaxValue, string_format); 1782SizeF size = useSpan ? g.MeasureString(s.AsSpan(), _font) : g.MeasureString(s, _font); 1785? g.MeasureString(s.AsSpan(), _font, new SizeF(80, size.Height), null, out int chars, out int lines) 1786: g.MeasureString(s, _font, new SizeF(80, size.Height), null, out chars, out lines); 1805SizeF size = useSpan ? g.MeasureString(s.AsSpan(), _font) : g.MeasureString(s, _font); 1810SizeF expected = useSpan ? g.MeasureString(s.AsSpan(), _font) : g.MeasureString(s, _font); 1814size = useSpan ? g.MeasureString(s.AsSpan(), _font) : g.MeasureString(s, _font); 1820expected = useSpan ? g.MeasureString(s.AsSpan(), _font) : g.MeasureString(s, _font); 1822size = useSpan ? g.MeasureString(s.AsSpan(), _font) : g.MeasureString(s, _font); 1826size = useSpan ? g.MeasureString(s.AsSpan(), _font) : g.MeasureString(s, _font); 1833expected = useSpan ? g.MeasureString(s.AsSpan(), _font) : g.MeasureString(s, _font); 1837size = useSpan ? g.MeasureString(s.AsSpan(), _font) : g.MeasureString(s, _font); 1848Region[] regions = g.MeasureCharacterRanges(null, _font, default, null); 1851regions = g.MeasureCharacterRanges(string.Empty, _font, default, null); 1853regions = g.MeasureCharacterRanges(string.Empty.AsSpan(), _font, default, null); 1872Region[] regions = g.MeasureCharacterRanges("Mono", _font, default, new StringFormat()); 1875g.MeasureCharacterRanges("Mono".AsSpan(), _font, default, new StringFormat()); 1900SizeF size = g.MeasureString(text, _font, new Point(0, 0), string_format); 1902Region[] regions = g.MeasureCharacterRanges(text, _font, layout_rect, string_format); 1907regions = g.MeasureCharacterRanges(text.AsSpan(), _font, layout_rect, string_format); 1924? g.MeasureString(text.AsSpan(), _font, new Point(0, 0), string_format) 1925: g.MeasureString(text, _font, new Point(0, 0), string_format); 1929g.MeasureCharacterRanges(text.AsSpan(), _font, layout_rect, string_format); 1933g.MeasureCharacterRanges(text, _font, layout_rect, string_format); 1966SizeF size = g.MeasureString(text, _font, new Point(0, 0), string_format); 1971Region[] regions = g.MeasureCharacterRanges(text, _font, layout_rect, string_format); 1976regions = g.MeasureCharacterRanges(text, _font, layout_rect, string_format); 1980regions = g.MeasureCharacterRanges(text.AsSpan(), _font, layout_rect, string_format); 1986regions = g.MeasureCharacterRanges(text, _font, layout_rect, string_format); 1990g.MeasureCharacterRanges(text.AsSpan(), _font, layout_rect, string_format); 2000Assert.Throws<ArgumentException>(() => g.MeasureCharacterRanges("Mono", _font, default, null)); 2001Assert.Throws<ArgumentException>(() => g.MeasureCharacterRanges("Mono".AsSpan(), _font, default, null)); 2093g.DrawString("Test String", _font, Brushes.Black, rect, fmt); 2094g.DrawString("Test String".AsSpan(), _font, Brushes.Black, rect, fmt); 2109g.DrawString("Test String", _font, Brushes.Black, rect, fmt); 2110g.DrawString("Test String".AsSpan(), _font, Brushes.Black, rect, fmt); 2121SizeF sz = g.MeasureString(text, _font, 80, format); 2123Assert.True(sz.Height > _font.Height * 2); 2125sz = g.MeasureString(text.AsSpan(), _font, 80, format); 2127Assert.True(sz.Height > _font.Height * 2);