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
I like crop's API and consider using crop in a LSP server, however in LSP offsets can be UTF-8, UTF-16 or UTF-32, and LSP servers must support UTF-16 offsets.
According to crop's README:
crop doesn't currently implement those APIs but adding them would be extremely easy. If you need those features in your application please open an issue describing your use case.
So I open this issue. Hoping you could add UTF-16 and UTF-32 offsets support.
The text was updated successfully, but these errors were encountered:
I'm open to adding some methods on Rope and RopeSlice that allow converting byte offsets to and from UTF-16 code unit offsets. UTF-32 is rarely used and not mandatory according to the LSP spec so I don't think I'll add that.
I've started working on this in #8, I'll ping you when it'll be ready to be merged.
Thanks for your work!
I like crop's API and consider using crop in a LSP server, however in LSP offsets can be UTF-8, UTF-16 or UTF-32, and LSP servers must support UTF-16 offsets.
According to crop's README:
So I open this issue. Hoping you could add UTF-16 and UTF-32 offsets support.
The text was updated successfully, but these errors were encountered: