View Single Post
Old 10-21-2014, 11:21 PM   #1
JoeBloe
Junior Member
JoeBloe began at the beginning.
 
Posts: 6
Karma: 10
Join Date: Sep 2014
Device: Android Cool Reader
Curious problem with find/replace & regex

calibre 2.6
Windows 8.1
In searching for a particular combination
Quote:
find: (’)(\w{3,})
replace: \1 \2
it would find them quite handily, but when trying to replace it would give an error on some examples. When trying to replace
Quote:
‘own ends’—what might those be?”
it would give error
Quote:
calibre, version 2.6.0
ERROR: Cannot replace: Currently selected text does not match the search query. You must first click Find, before trying to replace
Now that I look back, it should not be finding that example at all, as an EM DASH is not a \w.(unless I am mistaken about this flavor of regex???)
JoeBloe is offline   Reply With Quote