Mobileread
Sigil 0.9.17 and Epub 3.0 Metadata
#1  z537815 08-23-2019, 05:33 PM
I'm running Sigil 0.9.17 and have a problem with the metadata of Epub 3.0-books.

If I open the Metadata-editor, I only see the "Dublin Core"-elements, while at least 1 book had a content.opf with an entry that definitely lookes like a non-DC element: "Sigil Version" (value "0.9.16"). Yet it doesn't show up in the editor. Why?

If I try to add an element: Add Metadata > Custom element, it seems to go Ok. A "Custom Element" appears in the list of metadata-elements, and I can fill in the values. I then exit with an "Ok".

But when I then re-enter the Metadata editor, this custom element has disappeared! It's not in the content.opf either.

So...what gives? Is it a bug or a feature?
Reply 

#2  KevinH 08-23-2019, 06:10 PM
Was your custom element syntax correct for epub3? Meta tags in epub3 have content and are not self-closed. Did you properly save it? Does it appear in your content.opf in the metadata segment?

What exactly did you the in the custom entry?
Reply 

#3  KevinH 08-23-2019, 07:43 PM
I looked and Yes pure meta tags are explicitly excluded in epub3. Your best bet to workaround this is to carefully edit any pure meta tags (not refines) in the metadata section of the content.opf section. I will work to remove this restriction in the next release.
Reply 

#4  KevinH 08-23-2019, 08:25 PM
Okay, I just pushed some changes to master that allow the epub3 metadata editor to allow editing and creation of unrecognized (primary) meta tags. Those are meta tags whose whose property attributes do not match any of the elements/properties the editor recognizes.

The fix will appear in the next release of Sigil. Until then open the content.opf tab in Sigil and directly edit any metadata meta tags that do not involve refines (ie. are primary).

Thank you for your bug report.

Quote
I'm running Sigil 0.9.17 and have a problem with the metadata of Epub 3.0-books.

If I open the Metadata-editor, I only see the "Dublin Core"-elements, while at least 1 book had a content.opf with an entry that definitely lookes like a non-DC element: "Sigil Version" (value "0.9.16"). Yet it doesn't show up in the editor. Why?

If I try to add an element: Add Metadata > Custom element, it seems to go Ok. A "Custom Element" appears in the list of metadata-elements, and I can fill in the values. I then exit with an "Ok".

But when I then re-enter the Metadata editor, this custom element has disappeared! It's not in the content.opf either.

So...what gives? Is it a bug or a feature?
Reply 

#5  z537815 08-24-2019, 05:24 AM
Thanks. Looking forward to trying out your fix.

Just another question, though, and it may very well be a dense newbie-question. What exactly do you mean by "metadata meta tags that do not involve refines (ie. are primary)"?
Reply 

#6  Doitsu 08-24-2019, 05:54 AM
Quote z537815
Just another question, though, and it may very well be a dense newbie-question. What exactly do you mean by "metadata meta tags that do not involve refines (ie. are primary)"?
In epub3 books, metadata entries are primarily used as refines. Here's a typical example:

Code
<dc:creator id="create1">John Doe</dc:creator>
<meta scheme="marc:relators" property="role" refines="#create1">aut</meta>
<meta property="file-as" refines="#create1">Doe, John</meta>
The first refine defines the creator as an author and the second refine defines the author sort order.

The epub2 equivalent is:

Code
<dc:creator opf:file-as="Doe, John" opf:role="aut">John Doe</dc:creator>
As you can see, the epub3 version is a bit more verbose.
Reply 

#7  z537815 08-24-2019, 06:08 AM
I see. Thank you. That seems clear and straightforward enough.
Reply 

#8  KevinH 08-24-2019, 08:50 AM
And to complete things, generic non-dc meta data that uses the meta tag with only a property attribute (no refines) is sometimes referred to as a primary meta tag. For example:

Code
<meta property="createdwith">Sigil 0.9.17</meta>
which is used in place of the epub2 style meta tag
<meta name="createdwith" content="Sigil 0.9.17" />
Reply 

Today's Posts | Search this Thread | Login | Register