https://kotlinlang.org logo
#compose-android
Title
# compose-android
t

Travis Griggs

09/22/2023, 5:53 PM
I don't know how long this has been going on, but when I'm editing code in the Split view mode, the editor likes to gobble/eat white space characters if I don't keep typing quickly, so I end up with undented code lines that look like:
Copy code
valfoo=42
Is this a recent IDE regression? I'm running Android Studio Giraffe | 2022.3.1 Patch 1. Or maybe some evil combination of settings that I haven't sussed out? It's driving me nuts.
e

ephemient

09/22/2023, 5:54 PM
if you have your editor set to trim trailing whitespace on save, then that has happened since forever
s

Stylianos Gakis

09/22/2023, 5:55 PM
Do you only experience this when split view mode is on? I’ve exprienced this from time to time but never figured out what was it that triggered it
e

ephemient

09/22/2023, 5:56 PM
in my experience it's something like preview triggering autosave triggering space removal
s

Stylianos Gakis

09/22/2023, 5:57 PM
That sounds plausible, yes. Since I don’t often get it, but when I do it’s very persistent. It probably goes away as I go to other files without previews and I never noticed it!
t

Travis Griggs

09/22/2023, 6:05 PM
Yeah, only in split mode. I'm grateful I figured that much out. I just use split mode to see my previews selectively now. I miss the old, but this works, i guess
e

ephemient

09/22/2023, 6:07 PM
you can disable preview live updates or you can disable whitespace-removal
c

Chris Sinco [G]

09/23/2023, 4:43 AM
Hmm not sure Preview should trigger the auto save. It’s more the reverse where auto save triggers Preview to rebuild. I can try to repro next week if you file a bug.