Skip to content

KStringHandler: insert ZWSP between camelCase sub-words in preProcessWrap

ivan tkachenko requested to merge (removed):camelCase-wrap into master

Dolphin file manager wraps long sourceCodeFilenames letter-by-letter, which is not pretty. Microsoft/.NET docs website uses word breaks in the middle of camelCased identifiers to give them a nice look. While many of us here write in C++/Qt where filenames are usually all in lowercase, some other languages and ecosystems might still greatly benefit from this patch, especially Java and C#.

Regarding implementation details, there are sure many ways to write down equivalent boolean expressions, some of which might look more optimized than the others, but I'd rather choose readability over micro-optimizations and leave the rest to a compiler.


Before After
Before: QML After: QML
Before: Java After: Java
Edited by ivan tkachenko

Merge request reports