1 instantiation of ScreenDcScope
System.Windows.Forms (1)
System\Windows\Forms\Rendering\ScreenDcCache.cs (1)
51return new ScreenDcScope(this, (HDC)item);
22 references to ScreenDcScope
System.Windows.Forms (17)
System\Windows\Forms\Controls\Buttons\ButtonInternal\ButtonBaseAdapter.cs (1)
51using (var screen = GdiCache.GetScreenHdc())
System\Windows\Forms\Controls\Buttons\ButtonInternal\CheckableControlBaseAdapter.cs (1)
30using (var screen = GdiCache.GetScreenHdc())
System\Windows\Forms\Controls\Buttons\ButtonInternal\CheckBoxStandardAdapter.cs (2)
98using (var screen = GdiCache.GetScreenHdc()) 120using var screen = GdiCache.GetScreenHdc();
System\Windows\Forms\Controls\Buttons\ButtonInternal\RadioButtonStandardAdapter.cs (1)
66using var screen = GdiCache.GetScreenHdc();
System\Windows\Forms\Controls\ComboBox\ComboBox.cs (1)
819using (var screen = GdiCache.GetScreenHdc())
System\Windows\Forms\Controls\Labels\Label.cs (1)
1066using var screen = GdiCache.GetScreenHdc();
System\Windows\Forms\Controls\MonthCalendar\MonthCalendar.cs (1)
1193using (var screen = GdiCache.GetScreenHdc())
System\Windows\Forms\Rendering\FontCache.Data.cs (1)
38using var screenDC = GdiCache.GetScreenHdc();
System\Windows\Forms\Rendering\GdiCache.cs (2)
33public static ScreenDcCache.ScreenDcScope GetScreenHdc() => (s_dcCache ??= new ScreenDcCache()).Acquire(); 51ScreenDcCache.ScreenDcScope scope = GetScreenHdc();
System\Windows\Forms\Rendering\GdiCache.ScreenGraphicsScope.cs (3)
11/// Scope that creates a wrapping <see cref="Drawing.Graphics"/> for a <see cref="ScreenDcCache.ScreenDcScope"/> 20private readonly ScreenDcCache.ScreenDcScope _dcScope; 23public ScreenGraphicsScope(scoped ref ScreenDcCache.ScreenDcScope scope)
System\Windows\Forms\Rendering\ScreenDcCache.cs (1)
42public ScreenDcScope Acquire()
System\Windows\Forms\Rendering\ScreenDcCache.ScreenDcScope.cs (1)
26public static implicit operator HDC(in ScreenDcScope scope) => scope.HDC;
System\Windows\Forms\Rendering\TextRenderer.cs (1)
520using var screen = GdiCache.GetScreenHdc();
System.Windows.Forms.Tests (5)
System\Windows\Forms\PaintEventArgsTests.cs (1)
62using var hdc = GdiCache.GetScreenHdc();
System\Windows\Forms\ScreenDcCacheTests.cs (1)
19using var screen = cache.Acquire();
Text\FontMetrics.cs (3)
66using var screen = GdiCache.GetScreenHdc(); 84using var screen = GdiCache.GetScreenHdc(); 141using var screen = GdiCache.GetScreenHdc();