Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added SMIL schematron check to report when @clipBegin==@clipEnd // refs
- Loading branch information
Showing
3 changed files
with
34 additions
and
7 deletions.
There are no files selected for viewing
21 changes: 14 additions & 7 deletions
21
src/main/resources/com/adobe/epubcheck/schema/30/media-overlay-30.sch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,16 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<schema xmlns="http://purl.oclc.org/dsdl/schematron"> | ||
|
||
<ns uri="http://www.idpf.org/2007/ops" prefix="epub"/> | ||
<ns uri="http://www.w3.org/ns/SMIL" prefix="s"/> | ||
|
||
<include href="./mod/id-unique.sch"/> | ||
|
||
</schema> | ||
|
||
<ns uri="http://www.idpf.org/2007/ops" prefix="epub"/> | ||
<ns uri="http://www.w3.org/ns/SMIL" prefix="s"/> | ||
|
||
<include href="./mod/id-unique.sch"/> | ||
|
||
<pattern id="clip-attribute-checks"> | ||
<rule context="s:audio[@clipBegin and @clipEnd]"> | ||
<!-- #568 check @clipBegin==@clipEnd --> | ||
<assert test="@clipBegin != @clipEnd">Attributes 'clipBegin' and 'clipEnd' must not be equal!</assert> | ||
</rule> | ||
</pattern> | ||
|
||
</schema> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
13 changes: 13 additions & 0 deletions
13
src/test/resources/30/single/overlays/invalid/overlay-008.smil
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<?oxygen RNGSchema="../../../src/schema/media-overlay-30.rnc" type="compact"?> | ||
<?oxygen SCHSchema="../../../src/schema/media-overlay-30.sch"?> | ||
<smil xmlns="http://www.w3.org/ns/SMIL" version="3.0" xmlns:epub="http://www.idpf.org/2007/ops"> | ||
<body> | ||
<seq id="id1" epub:textref="chapter1.xhtml#sectionstart" epub:type="chapter"> | ||
<par id="id2"> | ||
<text src="chapter1.xhtml#text1"/> | ||
<audio src="chapter1_audio.mp3" clipBegin="0:23:34.221" clipEnd="0:23:34.221"/> | ||
</par> | ||
</seq> | ||
</body> | ||
</smil> |