View previous topic :: View next topic |
Author |
Message |
Hypatia
Joined: 15 Jan 2009 Posts: 1
|
Posted: Thu Jan 15, 2009 6:13 pm Post subject: Insert space before Caps |
|
|
Sample:
Quote: | FileNameWithTileCase.ext |
I am trying to find a "short" way to insert a space *before* any Capitals. (without 26 lines of code)
Quote: | File Name With Title Case.ext |
Considerations:
Names with apostrophes may be an issue for some but I would follow with a simple find pattern and replace to fix those instances.
Quote: | D'Arc, L'Rae ----> D' Arc , L' Rae |
Hyp. |
|
Back to top |
|
 |
admin Site Admin
Joined: 09 Mar 2007 Posts: 448 Location: Canada
|
Posted: Thu Jan 15, 2009 8:46 pm Post subject: |
|
|
Insert the following regular expression (do not include the single quotes):
Row: 1
Search: '([A-Z])'
Replace: ' \1'
This will insert a space before any upper case letter.
As you mentioned, you can follow this with another row to get rid of multiple spaces or spaces after single quotes.
Peter. |
|
Back to top |
|
 |
|