You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Screenshots
In the second screenshot the x values are translated of 5 but the side titles are placed differently. I was expecting side titles to be placed at the postion (5, 15, 25, 35) in the second second screenshot.
Versions
Flutter 3.19.3
FL Chart 0.66.2
The text was updated successfully, but these errors were encountered:
julien4215
changed the title
Side titles are not placed the same way when translated
Side titles are not placed the same way when values are translated
Mar 12, 2024
There is a complicated logic to handle these titles. So the point is that we try to show round values such as 10, 20, 30, 50, 100, 200, 300, 500, 1k, 2k, 3k, 5k...
And we use these values based on the baseline that we have. The default value for baselineX and baselineY is zero, and if you change the baselineX to offset, your issue is fixed.
Add this line of code baselineX: offset.toDouble(), in line 34 of your sample.
Describe the bug
The sides titles are not placed the same way if I translate the x values (see both screenshot).
To Reproduce
Try with
offset=0
first. Then withoffset=5
.Screenshots
![](https://private-user-images.githubusercontent.com/120588494/312172527-230a7044-7a88-4d08-92f9-6c6183b47833.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MTk5MTIwOTUsIm5iZiI6MTcxOTkxMTc5NSwicGF0aCI6Ii8xMjA1ODg0OTQvMzEyMTcyNTI3LTIzMGE3MDQ0LTdhODgtNGQwOC05MmY5LTZjNjE4M2I0NzgzMy5wbmc_WC1BbXotQWxnb3JpdGhtPUFXUzQtSE1BQy1TSEEyNTYmWC1BbXotQ3JlZGVudGlhbD1BS0lBVkNPRFlMU0E1M1BRSzRaQSUyRjIwMjQwNzAyJTJGdXMtZWFzdC0xJTJGczMlMkZhd3M0X3JlcXVlc3QmWC1BbXotRGF0ZT0yMDI0MDcwMlQwOTE2MzVaJlgtQW16LUV4cGlyZXM9MzAwJlgtQW16LVNpZ25hdHVyZT00NDQ5NDQzYjkxYWVkZTBhZDk5OTFhNDFmMDQ1MTM3ZWQ4MWUyMGY1NDlkODAzZWQ3NzEwNmYwYzE4MjEwYzM3JlgtQW16LVNpZ25lZEhlYWRlcnM9aG9zdCZhY3Rvcl9pZD0wJmtleV9pZD0wJnJlcG9faWQ9MCJ9.-HwXSMHzfImLGzVlQqLfNqziEHLnTgt_Khm085GZFxY)
![](https://private-user-images.githubusercontent.com/120588494/312172526-256db9ac-09ce-454b-aa49-1508eae314f1.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MTk5MTIwOTUsIm5iZiI6MTcxOTkxMTc5NSwicGF0aCI6Ii8xMjA1ODg0OTQvMzEyMTcyNTI2LTI1NmRiOWFjLTA5Y2UtNDU0Yi1hYTQ5LTE1MDhlYWUzMTRmMS5wbmc_WC1BbXotQWxnb3JpdGhtPUFXUzQtSE1BQy1TSEEyNTYmWC1BbXotQ3JlZGVudGlhbD1BS0lBVkNPRFlMU0E1M1BRSzRaQSUyRjIwMjQwNzAyJTJGdXMtZWFzdC0xJTJGczMlMkZhd3M0X3JlcXVlc3QmWC1BbXotRGF0ZT0yMDI0MDcwMlQwOTE2MzVaJlgtQW16LUV4cGlyZXM9MzAwJlgtQW16LVNpZ25hdHVyZT05M2Q2Y2NiYjY0YWJjODAyODRiODFhOGQxOGVjMmJmN2VlZjQyMDc4ZjY4NmQyNWZmMjYxZjJmYjU0OWY2NDdjJlgtQW16LVNpZ25lZEhlYWRlcnM9aG9zdCZhY3Rvcl9pZD0wJmtleV9pZD0wJnJlcG9faWQ9MCJ9.9eurDdNs1OScAzJzk0gn-E7YgtWI1v1nwXKT0GILpA8)
In the second screenshot the x values are translated of 5 but the side titles are placed differently. I was expecting side titles to be placed at the postion (5, 15, 25, 35) in the second second screenshot.
Versions
The text was updated successfully, but these errors were encountered: