Skip to content

Instantly share code, notes, and snippets.

@PiotrPrus
Created December 31, 2021 13:25
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save PiotrPrus/2e2d703632b6014e7ad14a0b11340d9f to your computer and use it in GitHub Desktop.
Save PiotrPrus/2e2d703632b6014e7ad14a0b11340d9f to your computer and use it in GitHub Desktop.
val barAreas = list.mapIndexed { index, item ->
BarArea(
index = index,
data = item,
xStart = horizontalPadding + distance.times(index) - distance.div(2),
xEnd = horizontalPadding + distance.times(index) + distance.div(2)
)
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment