Hello, I need to start all segments with upper case. Just the first word of each segment. Is there a regular expression one can use? Thanks in advance!
Hello, I need to start all segments with upper case. Just the first word of each segment. Is there a regular expression one can use? Thanks in advance!
Hi Olaf Tonn,
I got your private message after you couldn't reply my post.
I'm afraid you can't find and replace the case in Studio, because as far as I know, .Net (the regex engine behind Studio), won't allow you to replace the case (other regex engines, like PERL, can handle case conversions). Maybe a regex guru like Anthony Rudd can confirm or not this point.
Anyway, I couldn't make this simple regex ^[a-z] work in my Studio 2019 (it matches the 2nd, 3rd… lower case characters as well), so you won't be able to even find the lower case characters at the start of the segment:
I guess this is wrong, ?
So I'm afraid, filtering is the way to go.
you won't be able to even find the lower case characters at the start of the segment
Try ^[a-z]+ with Case Sensitive selected.
you won't be able to even find the lower case characters at the start of the segment
Try ^[a-z]+ with Case Sensitive selected.
Try ^[a-z]+ with Case Sensitive selected.
This works only for Latin - will not catch Polish diacritics. ^\p{Ll} should catch these too.
^\p{Ll} should catch these too.
It won't work with Ctrl+F. To include diacritics, just replace z with ž: ^[a-ž]+ (with Case Sensitive selected)
Oh, \p{Ll} works just fine with Search, tested in this very moment.
\p{Ll} works just fine
It catches each next lowercase letter anywhere as shown in the GIF file above.
^\p{Ll} finds segments starting with a lowercase word but it also cycles through all lowercase letters in this word.
Thanks for that! In the end I filtered the segments with ^[a-z] and changed it manually to upper case. There are just around 100 segments. The workaround of Jerzy sounds good, but in this case it is not worth as too time consuming and maybe some other errors occur exporting and importing. Thanks to all!