since LazyColumn doesn't support Long for indices ...
# compose
t
since LazyColumn doesn't support Long for indices (sad)... what's the recommended way to get something that does, if I wanted to?
1
i
I am scared to ask why you think you need 2^31 indices
2
t
not that I "need" it as such but I'm writing a hex viewer component
so I dunno, the file is potentially that large, what would you suggest as a suitable index for "somewhere inside a file"?
the same question came up 10-15 years ago when I did the same component for Swing
people were like "why do you need an index so large for a scrollbar?"
I was like, I don't really, but I'm writing a hex viewer and the user wants to scroll it
so of course I'm going to look to the available components to do what I want first, and if something that can render rows like a table doesn't support long, I'm going to ask them what decade they were living in when they wrote that API
so here, I would ask Google what decade they were living in when they wrote this API, because personally, I learned this mistake when I saw it in Swing, and wouldn't have implemented an API restricted to Int if I wrote it after seeing the pain I saw getting this to work in Swing. I also thought it was stupid when JavaFX came out with exactly the same limitation after we thought the world had already learned from this mistake the first time.
so what's the alternative here, have LazyColumn but each row is actually multiple rows and then Column{} inside each row?
I still want things like selection to work consistently across multiple columns too
i.e. I can select whatever range of data I want in the hex column, or in the ASCII column, without that selection bleeding across