Skip to content

Commit

Permalink
ingest changes from parz-team
Browse files Browse the repository at this point in the history
  • Loading branch information
Sebastian Flick committed Nov 4, 2024
1 parent cdbcd32 commit 0a93a95
Show file tree
Hide file tree
Showing 22 changed files with 2,401 additions and 107 deletions.
2 changes: 1 addition & 1 deletion src/teipb/odd/parzival-verse.odd
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
</teiHeader>
<text>
<body>
<schemaSpec start="TEI teiCorpus" ident="parzival-verse"> <elementSpec ident="l" mode="change">
<schemaSpec start="TEI teiCorpus" ident="parzival-verse" source="parzival.odd"> <elementSpec ident="l" mode="change">
<model behaviour="block" cssClass="line" useSourceRendition="true">
<param name="id" value="substring-after(@xml:id,'_')"/>
<param name="content" value="."/>
Expand Down
94 changes: 90 additions & 4 deletions src/teipb/odd/parzival.odd
Original file line number Diff line number Diff line change
Expand Up @@ -39,11 +39,42 @@
<schemaSpec start="TEI teiCorpus" ident="parzival" source="teipublisher.odd"> <elementSpec ident="lem" mode="add"/>
<elementSpec ident="l" mode="change"/>
<elementSpec ident="seg" mode="change">
<model behaviour="inline" cssClass="not-executed">
<param name="subtype" value="nicht_ausgeführt"/>
<param name="type" value="Initiale"/>
</model>
<model behaviour="inline" cssClass="verse -change">
<param name="type" value="Versumstellung"/>
</model>
<model behaviour="inline" cssClass="small-variant">
<param name="type" value="kleine_Variante"/>
</model>
<model behaviour="inline" cssClass="singular-reading">
<param name="type" value="singuläre_Lesart"/>
</model>
<model behaviour="inline" cssClass="large-variant">
<param name="type" value="große_Variante"/>
</model>
<model behaviour="inline" cssClass="capital-initial">
<param name="type" value="Initiale"/>
<param name="subtype" value="Großinitiale"/>
</model>
<model behaviour="inline" cssClass="majuscule">
<param name="subtype" value="Majuskel"/>
<param name="type" value="Initiale"/>
</model>
<model behaviour="inline" cssClass="glory-initial">
<param name="subtype" value="Prachtinitiale"/>
<param name="type" value="Initiale"/>
<outputRendition xml:space="preserve">

</outputRendition>
</model>
<model behaviour="inline" cssClass="initial" useSourceRendition="true">
<param name="type" value="Initiale"/>
<outputRendition xml:space="preserve">

</outputRendition>
</model>
</elementSpec>
<elementSpec ident="name" mode="add">
Expand All @@ -52,10 +83,65 @@
<param name="content" value="(given-names,surname)"/>
</model>
</elementSpec>
<elementSpec ident="cb" mode="change">
<model behaviour="block">
<param name="type" value="'column'"/>
<param name="label" value="@xml:id"/>
<elementSpec ident="reg" mode="add">
<model behaviour="inline" cssClass="syncope">
<param name="type" value="Synkope"/>
</model>
</elementSpec>
<elementSpec ident="milestone" mode="add">
<model behaviour="inline" cssClass="verse -change">
<param name="unit" value="Versumstellung"/>
</model>
</elementSpec>
<elementSpec ident="subst" mode="add">
<model behaviour="inline">
<param name="hand" value="#ls1"/>
</model>
<model behaviour="inline">
<param name="hand" value="#sr"/>
</model>
</elementSpec>
<elementSpec ident="add" mode="change">
<model behaviour="inline">
<param name="hand" value="#sr"/>
</model>
<model behaviour="inline">
<outputRendition xml:space="preserve">
color: green; text-decoration: underline;
</outputRendition>
</model>
</elementSpec>
<elementSpec ident="del" mode="change">
<model behaviour="inline" cssClass="deleted"/>
<model behaviour="inline">
<outputRendition xml:space="preserve">
text-decoration: line-through;
</outputRendition>
</model>
</elementSpec>
<elementSpec ident="note" mode="change">
<model behaviour="inline" cssClass="note">
<param name="type" value="Notiz"/>
</model>
<model behaviour="inline" cssClass="marginalia">
<param name="type" value="marginalie"/>
</model>
<model behaviour="note">
<param name="place" value="@place"/>
<param name="label" value="@n"/>
</model>
</elementSpec>
<elementSpec ident="hi" mode="change">
<model behaviour="inline" cssClass="underline">
<param name="rend" value="unterstrichen"/>
</model>
<model behaviour="inline" cssClass="rasure">
<param name="rend" value="rasur"/>
</model>
<model behaviour="inline" useSourceRendition="true">
<outputRendition xml:space="preserve">
font-style: italic;
</outputRendition>
</model>
</elementSpec>
</schemaSpec>
Expand Down
18 changes: 12 additions & 6 deletions src/teipb/transform/parzival-epub.xql
Original file line number Diff line number Diff line change
Expand Up @@ -218,9 +218,9 @@ declare function model:apply($config as map(*), $input as node()*) {
case element(role) return
epub:block($config, ., ("tei-role", css:map-rend-to-class(.)), .)
case element(hi) return
html:inline($config, ., css:get-rendition(., ("tei-hi", css:map-rend-to-class(.))), .)
html:inline($config, ., ("tei-hi1", "underline", css:map-rend-to-class(.)), .)
case element(note) return
epub:note($config, ., ("tei-note", css:map-rend-to-class(.)), ., @place, @n)
html:inline($config, ., ("tei-note1", "note", css:map-rend-to-class(.)), .)
case element(code) return
html:inline($config, ., ("tei-code", css:map-rend-to-class(.)), .)
case element(postscript) return
Expand All @@ -235,7 +235,7 @@ declare function model:apply($config as map(*), $input as node()*) {
else
$config?apply($config, ./node())
case element(del) return
html:inline($config, ., ("tei-del", css:map-rend-to-class(.)), .)
html:inline($config, ., ("tei-del1", "deleted", css:map-rend-to-class(.)), .)
case element(cell) return
(: Insert table cell. :)
html:cell($config, ., ("tei-cell", css:map-rend-to-class(.)), ., ())
Expand Down Expand Up @@ -264,7 +264,7 @@ declare function model:apply($config as map(*), $input as node()*) {
case element(ab) return
html:paragraph($config, ., ("tei-ab", css:map-rend-to-class(.)), .)
case element(add) return
html:inline($config, ., ("tei-add", css:map-rend-to-class(.)), .)
html:inline($config, ., ("tei-add1", css:map-rend-to-class(.)), .)
case element(revisionDesc) return
html:omit($config, ., ("tei-revisionDesc", css:map-rend-to-class(.)), .)
case element(head) return
Expand Down Expand Up @@ -457,7 +457,7 @@ declare function model:apply($config as map(*), $input as node()*) {
else
html:inline($config, ., ("tei-gap3", css:map-rend-to-class(.)), .)
case element(seg) return
html:inline($config, ., ("tei-seg1", "glory-initial", css:map-rend-to-class(.)), .)
html:inline($config, ., ("tei-seg1", "not-executed", css:map-rend-to-class(.)), .)
case element(notatedMusic) return
html:figure($config, ., ("tei-notatedMusic", css:map-rend-to-class(.)), (ptr, mei:mdiv), label)
case element(profileDesc) return
Expand All @@ -481,10 +481,16 @@ declare function model:apply($config as map(*), $input as node()*) {
case element(group) return
epub:block($config, ., ("tei-group", css:map-rend-to-class(.)), .)
case element(cb) return
epub:block($config, ., ("tei-cb", css:map-rend-to-class(.)), .)
epub:break($config, ., ("tei-cb", css:map-rend-to-class(.)), ., 'column', @n)
case element(name) return
(: delete me after testing :)
html:inline($config, ., ("tei-name", css:map-rend-to-class(.)), (given-names,surname))
case element(reg) return
html:inline($config, ., ("tei-reg", "syncope", css:map-rend-to-class(.)), .)
case element(milestone) return
html:inline($config, ., ("tei-milestone", "verse", "-change", css:map-rend-to-class(.)), .)
case element(subst) return
html:inline($config, ., ("tei-subst1", css:map-rend-to-class(.)), .)
case element(exist:match) return
html:match($config, ., .)
case element() return
Expand Down
18 changes: 12 additions & 6 deletions src/teipb/transform/parzival-fo.xql
Original file line number Diff line number Diff line change
Expand Up @@ -212,9 +212,9 @@ declare function model:apply($config as map(*), $input as node()*) {
case element(role) return
fo:block($config, ., ("tei-role", css:map-rend-to-class(.)), .)
case element(hi) return
fo:inline($config, ., css:get-rendition(., ("tei-hi", css:map-rend-to-class(.))), .)
fo:inline($config, ., ("tei-hi1", "underline", css:map-rend-to-class(.)), .)
case element(note) return
fo:note($config, ., ("tei-note", css:map-rend-to-class(.)), ., @place, @n)
fo:inline($config, ., ("tei-note1", "note", css:map-rend-to-class(.)), .)
case element(code) return
fo:inline($config, ., ("tei-code", css:map-rend-to-class(.)), .)
case element(postscript) return
Expand All @@ -229,7 +229,7 @@ declare function model:apply($config as map(*), $input as node()*) {
else
$config?apply($config, ./node())
case element(del) return
fo:inline($config, ., ("tei-del", css:map-rend-to-class(.)), .)
fo:inline($config, ., ("tei-del1", "deleted", css:map-rend-to-class(.)), .)
case element(cell) return
(: Insert table cell. :)
fo:cell($config, ., ("tei-cell", css:map-rend-to-class(.)), ., ())
Expand Down Expand Up @@ -258,7 +258,7 @@ declare function model:apply($config as map(*), $input as node()*) {
case element(ab) return
fo:paragraph($config, ., ("tei-ab", css:map-rend-to-class(.)), .)
case element(add) return
fo:inline($config, ., ("tei-add", css:map-rend-to-class(.)), .)
fo:inline($config, ., ("tei-add1", css:map-rend-to-class(.)), .)
case element(revisionDesc) return
fo:omit($config, ., ("tei-revisionDesc", css:map-rend-to-class(.)), .)
case element(head) return
Expand Down Expand Up @@ -437,7 +437,7 @@ declare function model:apply($config as map(*), $input as node()*) {
else
fo:inline($config, ., ("tei-gap3", css:map-rend-to-class(.)), .)
case element(seg) return
fo:inline($config, ., ("tei-seg1", "glory-initial", css:map-rend-to-class(.)), .)
fo:inline($config, ., ("tei-seg1", "not-executed", css:map-rend-to-class(.)), .)
case element(notatedMusic) return
fo:figure($config, ., ("tei-notatedMusic", css:map-rend-to-class(.)), (ptr, mei:mdiv), label)
case element(profileDesc) return
Expand All @@ -461,10 +461,16 @@ declare function model:apply($config as map(*), $input as node()*) {
case element(group) return
fo:block($config, ., ("tei-group", css:map-rend-to-class(.)), .)
case element(cb) return
fo:block($config, ., ("tei-cb", css:map-rend-to-class(.)), .)
fo:break($config, ., ("tei-cb", css:map-rend-to-class(.)), ., 'column', @n)
case element(name) return
(: delete me after testing :)
fo:inline($config, ., ("tei-name", css:map-rend-to-class(.)), (given-names,surname))
case element(reg) return
fo:inline($config, ., ("tei-reg", "syncope", css:map-rend-to-class(.)), .)
case element(milestone) return
fo:inline($config, ., ("tei-milestone", "verse", "-change", css:map-rend-to-class(.)), .)
case element(subst) return
fo:inline($config, ., ("tei-subst1", css:map-rend-to-class(.)), .)
case element() return
if (namespace-uri(.) = 'http://www.tei-c.org/ns/1.0') then
$config?apply($config, ./node())
Expand Down
3 changes: 0 additions & 3 deletions src/teipb/transform/parzival-latex-main.xql
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,6 @@ declare variable $xml external;
declare variable $parameters external;

let $options := map {
"class": "article",
"section-numbers": false(),
"font-size": "11pt",
"styles": ["transform/parzival.css"],
"collection": "/db/apps/parzival/transform",
"parameters": if (exists($parameters)) then $parameters else map {}
Expand Down
3 changes: 0 additions & 3 deletions src/teipb/transform/parzival-latex-module.xql
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,6 @@ import module namespace m='http://www.tei-c.org/pm/models/parzival/latex' at 'pa
declare function pml:transform($xml as node()*, $parameters as map(*)?) {

let $options := map {
"class": "article",
"section-numbers": false(),
"font-size": "11pt",
"styles": ["transform/parzival.css"],
"collection": "/db/apps/parzival/transform",
"parameters": if (exists($parameters)) then $parameters else map {}
Expand Down
18 changes: 12 additions & 6 deletions src/teipb/transform/parzival-latex.xql
Original file line number Diff line number Diff line change
Expand Up @@ -239,9 +239,9 @@ declare function model:apply($config as map(*), $input as node()*) {
case element(role) return
latex:block($config, ., ("tei-role", css:map-rend-to-class(.)), .)
case element(hi) return
latex:inline($config, ., css:get-rendition(., ("tei-hi", css:map-rend-to-class(.))), .)
latex:inline($config, ., ("tei-hi1", "underline", css:map-rend-to-class(.)), .)
case element(note) return
latex:note($config, ., ("tei-note", css:map-rend-to-class(.)), ., @place, @n)
latex:inline($config, ., ("tei-note1", "note", css:map-rend-to-class(.)), .)
case element(code) return
latex:inline($config, ., ("tei-code", css:map-rend-to-class(.)), .)
case element(postscript) return
Expand All @@ -256,7 +256,7 @@ declare function model:apply($config as map(*), $input as node()*) {
else
$config?apply($config, ./node())
case element(del) return
latex:inline($config, ., ("tei-del", css:map-rend-to-class(.)), .)
latex:inline($config, ., ("tei-del1", "deleted", css:map-rend-to-class(.)), .)
case element(cell) return
(: Insert table cell. :)
latex:cell($config, ., ("tei-cell", css:map-rend-to-class(.)), ., ())
Expand Down Expand Up @@ -285,7 +285,7 @@ declare function model:apply($config as map(*), $input as node()*) {
case element(ab) return
latex:paragraph($config, ., ("tei-ab", css:map-rend-to-class(.)), .)
case element(add) return
latex:inline($config, ., ("tei-add", css:map-rend-to-class(.)), .)
latex:inline($config, ., ("tei-add1", css:map-rend-to-class(.)), .)
case element(revisionDesc) return
latex:omit($config, ., ("tei-revisionDesc", css:map-rend-to-class(.)), .)
case element(head) return
Expand Down Expand Up @@ -465,7 +465,7 @@ declare function model:apply($config as map(*), $input as node()*) {
else
latex:inline($config, ., ("tei-gap3", css:map-rend-to-class(.)), .)
case element(seg) return
latex:inline($config, ., ("tei-seg1", "glory-initial", css:map-rend-to-class(.)), .)
latex:inline($config, ., ("tei-seg1", "not-executed", css:map-rend-to-class(.)), .)
case element(notatedMusic) return
latex:figure($config, ., ("tei-notatedMusic", css:map-rend-to-class(.)), (ptr, mei:mdiv), label)
case element(profileDesc) return
Expand All @@ -489,10 +489,16 @@ declare function model:apply($config as map(*), $input as node()*) {
case element(group) return
latex:block($config, ., ("tei-group", css:map-rend-to-class(.)), .)
case element(cb) return
latex:block($config, ., ("tei-cb", css:map-rend-to-class(.)), .)
latex:break($config, ., ("tei-cb", css:map-rend-to-class(.)), ., 'column', @n)
case element(name) return
(: delete me after testing :)
latex:inline($config, ., ("tei-name", css:map-rend-to-class(.)), (given-names,surname))
case element(reg) return
latex:inline($config, ., ("tei-reg", "syncope", css:map-rend-to-class(.)), .)
case element(milestone) return
latex:inline($config, ., ("tei-milestone", "verse", "-change", css:map-rend-to-class(.)), .)
case element(subst) return
latex:inline($config, ., ("tei-subst1", css:map-rend-to-class(.)), .)
case element() return
if (namespace-uri(.) = 'http://www.tei-c.org/ns/1.0') then
$config?apply($config, ./node())
Expand Down
Loading

0 comments on commit 0a93a95

Please sign in to comment.