Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Sigil

Notices

Reply
 
Thread Tools Search this Thread
Old 11-25-2010, 01:59 AM   #1
jhempel24
Wizard
jhempel24 ought to be getting tired of karma fortunes by now.jhempel24 ought to be getting tired of karma fortunes by now.jhempel24 ought to be getting tired of karma fortunes by now.jhempel24 ought to be getting tired of karma fortunes by now.jhempel24 ought to be getting tired of karma fortunes by now.jhempel24 ought to be getting tired of karma fortunes by now.jhempel24 ought to be getting tired of karma fortunes by now.jhempel24 ought to be getting tired of karma fortunes by now.jhempel24 ought to be getting tired of karma fortunes by now.jhempel24 ought to be getting tired of karma fortunes by now.jhempel24 ought to be getting tired of karma fortunes by now.
 
jhempel24's Avatar
 
Posts: 2,157
Karma: 7068605
Join Date: Dec 2007
Device: Amazon Kindle Paperwhite, B&N Nook Colro
yet another heading question

I want to turn this

<p class="calibre10"><span class="calibre8 bold calibre11 calibre8">2</span></p>

Into this:

<H2>Chapter 2</H2>

But there are 100 chapters and I'd rather not do it one by one, is there a way to do that?

I've tried the \d+ thing from earlier, but maybe I'm not using it right....any help would be great!

Thanks!
jhempel24 is offline   Reply With Quote
Old 11-25-2010, 06:40 AM   #2
Perkin
Guru
Perkin calls his or her ebook reader Vera.Perkin calls his or her ebook reader Vera.Perkin calls his or her ebook reader Vera.Perkin calls his or her ebook reader Vera.Perkin calls his or her ebook reader Vera.Perkin calls his or her ebook reader Vera.Perkin calls his or her ebook reader Vera.Perkin calls his or her ebook reader Vera.Perkin calls his or her ebook reader Vera.Perkin calls his or her ebook reader Vera.Perkin calls his or her ebook reader Vera.
 
Perkin's Avatar
 
Posts: 655
Karma: 64171
Join Date: Sep 2010
Location: Kent, England, Sol 3, ZZ9 plural Z Alpha
Device: Sony PRS-300, Kobo Aura HD, iPad (Marvin)
If all of the chapters contain exactly the same
Code:
<p class="calibre10"><span class="calibre8 bold calibre11 calibre8">
and then the chapter number followed by
Code:
</span></p>
then search for (regex, minimal)
Code:
<p class="calibre10"><span class="calibre8 bold calibre11 calibre8">(\d+)</span></p>
replace
Code:
<h2>Chapter \1</h2>
Perkin is offline   Reply With Quote
Advert
Old 11-25-2010, 06:45 AM   #3
jhempel24
Wizard
jhempel24 ought to be getting tired of karma fortunes by now.jhempel24 ought to be getting tired of karma fortunes by now.jhempel24 ought to be getting tired of karma fortunes by now.jhempel24 ought to be getting tired of karma fortunes by now.jhempel24 ought to be getting tired of karma fortunes by now.jhempel24 ought to be getting tired of karma fortunes by now.jhempel24 ought to be getting tired of karma fortunes by now.jhempel24 ought to be getting tired of karma fortunes by now.jhempel24 ought to be getting tired of karma fortunes by now.jhempel24 ought to be getting tired of karma fortunes by now.jhempel24 ought to be getting tired of karma fortunes by now.
 
jhempel24's Avatar
 
Posts: 2,157
Karma: 7068605
Join Date: Dec 2007
Device: Amazon Kindle Paperwhite, B&N Nook Colro
use the parentheses as well is that right?
jhempel24 is offline   Reply With Quote
Old 11-25-2010, 07:58 AM   #4
Perkin
Guru
Perkin calls his or her ebook reader Vera.Perkin calls his or her ebook reader Vera.Perkin calls his or her ebook reader Vera.Perkin calls his or her ebook reader Vera.Perkin calls his or her ebook reader Vera.Perkin calls his or her ebook reader Vera.Perkin calls his or her ebook reader Vera.Perkin calls his or her ebook reader Vera.Perkin calls his or her ebook reader Vera.Perkin calls his or her ebook reader Vera.Perkin calls his or her ebook reader Vera.
 
Perkin's Avatar
 
Posts: 655
Karma: 64171
Join Date: Sep 2010
Location: Kent, England, Sol 3, ZZ9 plural Z Alpha
Device: Sony PRS-300, Kobo Aura HD, iPad (Marvin)
Yes, the parenthesis, means to store that as a group, which can be inserted in the replace, hence the \1 in the replace (meaning the first saved group, and in this case our only saved group)
Edit: we're storing the chapter number to be used in the replace
Perkin is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Keyboard shortcuts for heading styles? Tryphan Sigil 4 09-26-2011 06:54 AM
Recomendation about Heading in Sigil sergiodongala Sigil 6 07-06-2011 08:12 PM
Kindle Heading to Best Buy kindle79 Amazon Kindle 2 09-09-2010 04:22 PM
How to avoid page break after heading/chapter tkirke ePub 6 01-22-2010 02:12 PM
Controlling chapter heading sizes? Djehuty Calibre 3 04-27-2009 08:02 PM


All times are GMT -4. The time now is 11:29 PM.


MobileRead.com is a privately owned, operated and funded community.