I believe I've found a lightning charts rendering bug in WPF.
To demonstrate the issue I've made a smal change to one of your projects to see if I can replicate a bug we have in our application, and was able to replicate the issue in ViewXY custom GDI+ Rendering Chart, in C# WPF .net framework 4.8
My change is to set label placement to manual
The pixel distances specified are not automatically scaling when the UI scale changes
Code: Select all
private void CreateChart()
{
// Create a new chart.
_chart = new LightningChart
{
ChartName = "ViewXY custom GDI+ rendering chart"
};
//begin change
_chart.ViewXY.AxisLayout.YAxisTitleAutoPlacement = false;
_chart.ViewXY.AxisLayout.XAxisTitleAutoPlacement = false;
_chart.ViewXY.AxisLayout.AutoAdjustMargins = false;
_chart.ViewXY.Margins = new System.Windows.Thickness(100, 100, 100, 100);
_chart.ViewXY.XAxes[0].Title.DistanceToAxis = 50;
_chart.ViewXY.YAxes[0].Title.DistanceToAxis = 50;
// end change
thanks
Mat
EDIT: here's the full chart at different scalings, the custom rendering position is erratic too,
but notice if I select the executable in file manager and set the properties :
compatibiilty > change hidpi settings > override hidpi scaling behaviour > system (enhanced) and run at 200% the text position is corrected but the custom rendering is different again.