Hi,
I want to add to my editor the option to convert all tabs in a document to spaces. Say my tab-width is 8 spaces, I just tried something like replace_all(text, "\t", " ");.
However, this doesn't work as expected, because not all tabs might have an actual length of 8. I want to replace each tab with exactly as many whitespaces, as it occupies in the document.
So, is there a way to get the effective length of a tab in whitespaces?