View Single Post
Old 04-03-2017, 02:07 AM   #16
GrannyGrump
Obsessively Dedicated...
GrannyGrump ought to be getting tired of karma fortunes by now.GrannyGrump ought to be getting tired of karma fortunes by now.GrannyGrump ought to be getting tired of karma fortunes by now.GrannyGrump ought to be getting tired of karma fortunes by now.GrannyGrump ought to be getting tired of karma fortunes by now.GrannyGrump ought to be getting tired of karma fortunes by now.GrannyGrump ought to be getting tired of karma fortunes by now.GrannyGrump ought to be getting tired of karma fortunes by now.GrannyGrump ought to be getting tired of karma fortunes by now.GrannyGrump ought to be getting tired of karma fortunes by now.GrannyGrump ought to be getting tired of karma fortunes by now.
 
GrannyGrump's Avatar
 
Posts: 3,233
Karma: 35158061
Join Date: May 2011
Location: PA {back in the usa!}
Device: Sony PRS-T2, ADE on PC
Hi all. I didn't mean to raise SUCH a kerfuffle!

—Kevin, DiapDealer -- I am not/was not asking for Sigil to change its default behavior. (Who got the impression that I would even think such a thing???) I was only looking for a workaround to use sometimes, to force it to use the IDs that occur at the top of the files. I think Doitsu's suggestion, combined with TheDucks tip, will work well for what I need.

Just to clarify what I am doing here ---
I have an omnibus collection of 25 books, with almost 600 short stories. These are located in about 45 to 50 xhtml files (using "page-break-after: always" to force page-breaks inside those files).

I am making an alphabetical Index of Titles, with each index entry linking to its story.
I used the automatic TOC generation & Create Html ToC to create a complete list of links to all 600 stories. (This huge ToC will not be used for the final product, but instead a ToC that lists only the 25 Book Titles that comprise the collection.)

But the auto-ToC does not include the ID from the first title on each of the 50 individual files. If I were to use these particular links as they stand, they would fail if the stories are re-arranged -- I would need to manually edit to add the ID. (Not only talking about split & merge here, but re-arranging the sequence.) Granted, it is only 50 entries, but if avoidable, so much the better. Besides, this situation will be happening again, I am sure.

So I use Doitsu's suggestion to add a dummy heading at the top of each file, using S&R, then generate the huge Toc, and "create html Toc" from that. Use the html ToC data to create my Index. Then delete the dummy headings. Then generate my "Real ToC.ncx" using only the 25 book titles from the higher-level headings. Delete the html ToC with the 600 entries, and All Is Good.

[@DiapDealer ---I think I may have been the one that yipped about the broken links upon merge / split --- I still thank you for the fix, and the saving of my sanity!]

JSWolf said:
Quote:
So why not have links that go to the top of the flow not use an ID and all the rest use an ID? Some Readers/apps do slow down when the ToC uses IDs. So the less IDs you can use, the better
As I said before, These IDs are NOT needed for the NCX. They are needed for an Index, a html file, a list of links, if you will.

=============
My workflow might be unusual, but it works.

Last edited by GrannyGrump; 04-03-2017 at 02:15 AM.
GrannyGrump is offline   Reply With Quote