Thread: Regex Question
View Single Post
Old 01-26-2011, 08:34 AM   #5
ldolse
Wizard
ldolse is an accomplished Snipe hunter.ldolse is an accomplished Snipe hunter.ldolse is an accomplished Snipe hunter.ldolse is an accomplished Snipe hunter.ldolse is an accomplished Snipe hunter.ldolse is an accomplished Snipe hunter.ldolse is an accomplished Snipe hunter.ldolse is an accomplished Snipe hunter.ldolse is an accomplished Snipe hunter.ldolse is an accomplished Snipe hunter.ldolse is an accomplished Snipe hunter.
 
Posts: 1,337
Karma: 123455
Join Date: Apr 2009
Location: Malaysia
Device: PRS-650, iPhone
Generally people on these forums don't do a lot of work with formats that aren't text based. If you convert from rtf to epub using Calibre you can take advantages of Calibre's search and replace feature, which uses the syntax I suggested, as rtf is already converted to basic html at that stage. You can also take advantage of the italicize feature I mentioned and numerous other features designed to make your life easier.

Once it's converted to epub you can do your final edits in Sigil, which is a dedicated ebook editor. It uses a similar regex syntax, and has another sub-forum here on mobileread with users who can help you.

If your final format is intended to be mobi, then you can use Calibre to do one last epub to mobi conversion. This is what a lot of other kindle users are doing.

p.s. - didn't really understand your comment about multiple words - the regex I proposed should work based on the examples you put in your first post - if I'm missing something maybe you need to elaborate. Switching to '\w+?' instead of '.+' which was in your original regex should cause the engine to just match 'words' instead of other characters which I believe may have been tripping you up.

Last edited by ldolse; 01-26-2011 at 08:36 AM.
ldolse is offline   Reply With Quote