I have started using OxyPlot for a simple graph, but I have a problem regarding setting the background color. It apparently doesn't seem to work ?
The plotAreaBackground is changed correctly.
Even setting it to red, it continues to be white. What I have done is the below:
plotModel = new PlotModel();
plotModel.PlotAreaBackground = BackgroundBaseColor.ToOxyColor();
plotModel.Background = OxyColors.Red;
DateTimeAxis dateTimeAxis = new DateTimeAxis(AxisPosition.Bottom, "Date", CultureInfo.CurrentCulture.DateTimeFormat.ShortDatePattern);
dateTimeAxis.Maximum = DateTimeAxis.ToDouble(DateTime.Today);
OxyPlot.MinWidth = ActualWidth;
OxyPlot.MaxHeight = ActualHeight;
OxyPlot.Model = plotModel;
I have tried having ContainerPanel both as a stackpanel and grid...
Hope somebody can help.