Skip to content

Commit 0172c11

Browse files
committed
remove model from Series.Render()
1 parent ad4a35b commit 0172c11

29 files changed

Lines changed: 35 additions & 64 deletions

Source/Examples/ExampleLibrary/CustomSeries/ErrorSeries.cs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -62,8 +62,7 @@ public List<ErrorItem> Points
6262
/// Renders the series on the specified render context.
6363
/// </summary>
6464
/// <param name="rc">The rendering context.</param>
65-
/// <param name="model">The model.</param>
66-
public override void Render(IRenderContext rc, PlotModel model)
65+
public override void Render(IRenderContext rc)
6766
{
6867
var points = this.Points;
6968
if (points.Count == 0)

Source/Examples/ExampleLibrary/CustomSeries/FlagSeries.cs

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -122,15 +122,14 @@ public override TrackerHitResult GetNearestPoint(ScreenPoint point, bool interpo
122122
/// Renders the series on the specified render context.
123123
/// </summary>
124124
/// <param name="rc">The rendering context.</param>
125-
/// <param name="model">The model.</param>
126-
public override void Render(IRenderContext rc, PlotModel model)
125+
public override void Render(IRenderContext rc)
127126
{
128127
if (this.XAxis == null)
129128
{
130129
return;
131130
}
132131

133-
this.symbolPosition = model.PlotArea.Bottom;
132+
this.symbolPosition = this.PlotModel.PlotArea.Bottom;
134133
this.symbolSize = rc.MeasureText(this.Symbol, this.ActualFont, this.ActualFontSize);
135134
foreach (var v in this.Values)
136135
{

Source/Examples/ExampleLibrary/CustomSeries/LineSegmentSeries.cs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -45,8 +45,7 @@ public LineSegmentSeries()
4545
/// Renders the series on the specified rendering context.
4646
/// </summary>
4747
/// <param name="rc">The rendering context.</param>
48-
/// <param name="model">The owner plot model.</param>
49-
public override void Render(IRenderContext rc, PlotModel model)
48+
public override void Render(IRenderContext rc)
5049
{
5150
if (Points.Count == 0)
5251
{

Source/Examples/ExampleLibrary/CustomSeries/MatrixSeries.cs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -134,8 +134,7 @@ public override TrackerHitResult GetNearestPoint(ScreenPoint point, bool interpo
134134
/// Renders the series on the specified render context.
135135
/// </summary>
136136
/// <param name="rc">The rendering context.</param>
137-
/// <param name="model">The model.</param>
138-
public override void Render(IRenderContext rc, PlotModel model)
137+
public override void Render(IRenderContext rc)
139138
{
140139
if (this.Matrix == null)
141140
{

Source/Examples/ExampleLibrary/CustomSeries/PolarHeatMapSeries.cs

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -102,8 +102,7 @@ public PolarHeatMapSeries()
102102
/// Renders the series on the specified render context.
103103
/// </summary>
104104
/// <param name="rc">The rendering context.</param>
105-
/// <param name="model">The model.</param>
106-
public override void Render(IRenderContext rc, PlotModel model)
105+
public override void Render(IRenderContext rc)
107106
{
108107
if (this.Data == null)
109108
{
@@ -113,11 +112,11 @@ public override void Render(IRenderContext rc, PlotModel model)
113112

114113
if (this.ImageSize > 0)
115114
{
116-
this.RenderFixed(rc, model);
115+
this.RenderFixed(rc, this.PlotModel);
117116
}
118117
else
119118
{
120-
this.RenderDynamic(rc, model);
119+
this.RenderDynamic(rc, this.PlotModel);
121120
}
122121
}
123122

Source/Examples/ExampleLibrary/Discussions/DiscussionExamples.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -345,7 +345,7 @@ public OxyColor ActualColor
345345
}
346346
}
347347

348-
public override void Render(IRenderContext rc, PlotModel model)
348+
public override void Render(IRenderContext rc)
349349
{
350350
// transform to screen coordinates
351351
var p0 = this.Transform(this.StartPoint);

Source/Examples/ExampleLibrary/Misc/MiscExamples.cs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2229,8 +2229,7 @@ public override TrackerHitResult GetNearestPoint(ScreenPoint point, bool interpo
22292229
/// Renders the series on the specified render context.
22302230
/// </summary>
22312231
/// <param name="rc">The rendering context.</param>
2232-
/// <param name="model">The model.</param>
2233-
public override void Render(IRenderContext rc, PlotModel model)
2232+
public override void Render(IRenderContext rc)
22342233
{
22352234
var p0 = this.Transform(this.XAxis.ActualMinimum, this.YAxis.ActualMinimum);
22362235
var p1 = this.Transform(this.XAxis.ActualMaximum, this.YAxis.ActualMaximum);

Source/OxyPlot/PlotModel/PlotModel.Rendering.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -415,7 +415,7 @@ private void RenderSeries(IRenderContext rc)
415415
foreach (var s in this.Series.Where(s => s.IsVisible))
416416
{
417417
rc.SetToolTip(s.ToolTip);
418-
s.Render(rc, this);
418+
s.Render(rc);
419419
}
420420

421421
rc.SetToolTip(null);

Source/OxyPlot/Series/AreaSeries.cs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -173,8 +173,7 @@ public override TrackerHitResult GetNearestPoint(ScreenPoint point, bool interpo
173173
/// Renders the series on the specified rendering context.
174174
/// </summary>
175175
/// <param name="rc">The rendering context.</param>
176-
/// <param name="model">The owner plot model.</param>
177-
public override void Render(IRenderContext rc, PlotModel model)
176+
public override void Render(IRenderContext rc)
178177
{
179178
var actualPoints = this.ActualPoints;
180179
var actualPoints2 = this.ActualPoints2;

Source/OxyPlot/Series/BarSeries/BarSeriesBase.cs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -181,8 +181,7 @@ public override TrackerHitResult GetNearestPoint(ScreenPoint point, bool interpo
181181
/// Renders the series on the specified rendering context.
182182
/// </summary>
183183
/// <param name="rc">The rendering context.</param>
184-
/// <param name="model">The model.</param>
185-
public override void Render(IRenderContext rc, PlotModel model)
184+
public override void Render(IRenderContext rc)
186185
{
187186
this.ActualBarRectangles = new List<OxyRect>();
188187

0 commit comments

Comments
 (0)