|01-06-2011, 03:43 AM||#1|
Join Date: Sep 2010
Device: Kobo aura HD, Kobo Arc, Sony T2, Kindle Fire HDX 8.9 , Kindle for PC
regex to fix up hyphenated words please
i want to auto-remove extra spaces in hyphenated words
i.e. change badly- spaced to badly-spaced.
not sure of the find +replace syntax.
I think I have to find [word boundary]- [wordboundary] then replace what I've found but without the space ?
|01-06-2011, 04:13 AM||#3|
Join Date: Jan 2008
Location: Spaniard in Sweden
Device: Cybook Orizon
Try searching for "\b- \b" and replacing with "-" (no quotes in either case). According to the documentation, \b matches a word boundary, but no character (so you don't have to worry about it when replacing).
But, as Toxaris says, beware of things like "inter- and intramolecular bonds".
|Thread Tools||Search this Thread|
|Thread||Thread Starter||Forum||Replies||Last Post|
|Conversion and Regex Help||thedevilsjester||Calibre||0||07-16-2010 06:10 PM|
|What a regex is||Worldwalker||Calibre||20||05-10-2010 05:51 AM|
|Multiline Regex?||prky||Calibre||25||05-01-2010 09:56 PM|
|Help with a regex||A.T.E.||Calibre||1||04-05-2010 07:50 AM|
|Regex help...||Bobthebass||Workshop||6||04-26-2009 03:54 PM|