AvalonHelpers.LineBackgroundRenderer.Draw C# (CSharp) Метод

Draw() публичный Метод

public Draw ( TextView textView, System.Windows.Media.DrawingContext drawingContext ) : void
textView TextView
drawingContext System.Windows.Media.DrawingContext
Результат void
        public void Draw(TextView textView, DrawingContext drawingContext)
        {
            if (_editor.Document == null)
                return;

            textView.EnsureVisualLines();
            var currentLine = _editor.Document.GetLineByOffset(_editor.CaretOffset);
            foreach (var rect in BackgroundGeometryBuilder.GetRectsForSegment(textView, currentLine))
            {
                drawingContext.DrawRectangle(
                    new SolidColorBrush(Color.FromArgb(0x40, 0, 0, 0xFF)), null,
                    new Rect(rect.Location, new Size(textView.ActualWidth - 32, rect.Height)));
            }
        }