Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Sigil

Notices

Reply
 
Thread Tools Search this Thread
Old 02-13-2016, 10:17 PM   #1
turbulent
Member
turbulent began at the beginning.
 
Posts: 14
Karma: 10
Join Date: May 2014
Device: kindle paperwhite
Comments in content.opf with Sigil 0.9.2

Hi,

With Sigil 0.8.x, the file content.opf in the epub from plugin KindleImport contains some comments generated from the metadata of the original mobi/azw3 ebook, as followed:
Code:
    <!-- BEGIN INFORMATION ONLY 
<meta name="Cover ThumbNail Image" content="Images/image00253.jpeg" />
<meta name="Drm Ebookbase Book Id" content="0006002627397" />
<meta name="ASIN" content="B00QLSKYGU" />
......
END INFORMATION ONLY -->
After updated to v0.9.2, these comments seems to be automatically cleaned by Sigil. Is there any convenient way to keep them?
turbulent is offline   Reply With Quote
Old 02-13-2016, 11:12 PM   #2
KevinH
Sigil Developer
KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.
 
Posts: 7,643
Karma: 5433388
Join Date: Nov 2009
Device: many
Hi,
Unfortunately not. The opf is parsed and rebuilt from stored data structures to prevent constant reparsing to speed up performance. Comments are not kept as there is no place in the internal datastructures to keep them as comments can be put just about any place. I guess I could create a comment node for every major tag in the opf and collect them from anyplace inside that tag and store them. It just didn't seem to be worth the effort as the opf was meant to be machine readable (which is how it is used in Sigil). This has been true dince the Sigil 0.8.900 pre-releases if you do any operation that requires changes to the opf.

KevinH

Quote:
Originally Posted by turbulent View Post
Hi,

With Sigil 0.8.x, the file content.opf in the epub from plugin KindleImport contains some comments generated from the metadata of the original mobi/azw3 ebook, as followed:
Code:
    <!-- BEGIN INFORMATION ONLY 
<meta name="Cover ThumbNail Image" content="Images/image00253.jpeg" />
<meta name="Drm Ebookbase Book Id" content="0006002627397" />
<meta name="ASIN" content="B00QLSKYGU" />
......
END INFORMATION ONLY -->
After updated to v0.9.2, these comments seems to be automatically cleaned by Sigil. Is there any convenient way to keep them?
KevinH is offline   Reply With Quote
Old 02-14-2016, 12:45 AM   #3
DiapDealer
Grand Sorcerer
DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.
 
DiapDealer's Avatar
 
Posts: 27,547
Karma: 193191846
Join Date: Jan 2010
Device: Nexus 7, Kindle Fire HD
Weird timing! I'm thinking about adding a configurable option to KindleImport to preserve that KindleUnpack metadata. It would simply remove the html comment tags so all of those individual metas would remain a part of the opf. It would then be up to the user to delete/keep the data.
DiapDealer is offline   Reply With Quote
Old 02-14-2016, 02:02 AM   #4
turbulent
Member
turbulent began at the beginning.
 
Posts: 14
Karma: 10
Join Date: May 2014
Device: kindle paperwhite
Hi, DiapDealer

That's exactly what I need. And I'm just thinking asking you to consider adding this feature to KindleImport! Well, I'll wait for it.
turbulent is offline   Reply With Quote
Old 02-15-2016, 05:29 PM   #5
DiapDealer
Grand Sorcerer
DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.
 
DiapDealer's Avatar
 
Posts: 27,547
Karma: 193191846
Join Date: Jan 2010
Device: Nexus 7, Kindle Fire HD
Quote:
Originally Posted by turbulent View Post
Hi, DiapDealer

That's exactly what I need. And I'm just thinking asking you to consider adding this feature to KindleImport! Well, I'll wait for it.
KindleImport v0.80.6 should now do what you need. Read the instructions in the plugin's thread for changing the "preserve_kindleunpack_meta" preference to "true" (though it occurs to me that it will only work for AZW3/KF8 books and NOT the old-style mobis ... should be able to add that ability in the next version).
DiapDealer is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
avoiding Sigil's meta in content.opf sbin Sigil 25 01-08-2016 03:51 PM
Change opf filename from content.opf to title.opf northstar7 Sigil 3 09-23-2013 12:44 PM
Sigil 0.5.3 keeps rebuilding my content.opf file from scratch mtrahan Sigil 7 04-28-2012 09:10 AM
Sigil corrupting content.opf (0.4, 0.5) cyana Sigil 21 02-11-2012 05:25 PM
Sigil resets edits to content.opf adv_dp_fan Sigil 7 09-28-2011 06:50 PM


All times are GMT -4. The time now is 07:26 AM.


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