RegEx: Split String at Capitalized Letters and Non-capitalized letters to Create Small Cap Fonts
Posted
by Otaku
on Stack Overflow
See other posts from Stack Overflow
or by Otaku
Published on 2010-03-27T06:55:45Z
Indexed on
2010/03/27
7:03 UTC
Read the original article
Hit count: 450
So i've purposefully stayed away from RegEx as just looking at it kills me...ugh. But now I need it and could really use some help to do this in .NET (C# or VB.NET). I need to split a string based on capitalization or lack thereof. For example:
I'm not upPercase
- "I"
- "'m not up"
- "P"
- "ercase"
or
FBI Agent Winters
- "FBI A"
- "gent "
- "W"
- "inters"
The reason I'm doing this is to manually create small caps, in which non-capitalized strings will be sent to uppercase and their font size made 80% of the original font size. Appreciate any help that could be provided here.
© Stack Overflow or respective owner