protected override void OnRender(DrawingContext dc) { var pen = Caches.GetDashedPen( new ByteColor(0xFF, 0x41, 0x69, 0xE1), this.RoundLayoutValue(2)); dc.DrawLine( pen, new Point(0, 0), _isVertical ? new Point(ActualWidth, 0) : new Point(0, ActualHeight)); }