feat: Allow to clear every horizontal lines (#52)

This commit is contained in:
2023-02-14 15:54:40 +01:00
committed by GitHub
parent b2c51f7be1
commit dd023f96cc
3 changed files with 12 additions and 9 deletions

View File

@ -237,6 +237,10 @@ class YAxis(
lines.remove(y)
}
override fun clearLines() {
lines.clear()
}
@Deprecated("use the new global function", ReplaceWith("YAxisInterface.addLine"))
override fun setGoalLine(height: Float?) {
if (height != null) {

View File

@ -121,6 +121,11 @@ sealed interface YAxisInterface {
*/
fun removeLine(y: Float)
/**
* Remove every lines
*/
fun clearLines()
/**
* get the position of an [entry] Y position in the [drawableSpace]
*