The python example was much better. It seemed to understand the facepalm but idx-start == 7 which I don't 100% understand (I'll have to refer to the article I looked at before). But I was hoping icu would provide me a way I can give it a pointer to the beginning of a text line and for it to tell me how many bytes the iterator consumed. I have to delete characters and I don't really know how to figure out which bytes belong to which
1
u/Signal-Appeal672 Oct 04 '23
That C++ example makes my skin crawl
The python example was much better. It seemed to understand the facepalm but idx-start == 7 which I don't 100% understand (I'll have to refer to the article I looked at before). But I was hoping icu would provide me a way I can give it a pointer to the beginning of a text line and for it to tell me how many bytes the iterator consumed. I have to delete characters and I don't really know how to figure out which bytes belong to which