diff --git a/Doc/Sd1/CoreClasses/coreClasses.xml b/Doc/Sd1/CoreClasses/coreClasses.xml index 465a6dd41e537d371329e46a90f990ddac02d19c..cacd2d633d78aeeae26655a56cea57c339366759 100644 --- a/Doc/Sd1/CoreClasses/coreClasses.xml +++ b/Doc/Sd1/CoreClasses/coreClasses.xml @@ -15,7 +15,8 @@ <abstract> <para>Working with class <classname>String</classname>.</para> - <para>Operator <code language="java">==</code> pitfalls</para> + <para>Pitfalls when using operator <code language="java">==</code> + </para> <para>Using <methodname>equals(...)</methodname>.</para> </abstract> diff --git a/Doc/Sd1/GettingStarted/gettingStarted.xml b/Doc/Sd1/GettingStarted/gettingStarted.xml index 0cbe490851551f2e68004da8d504af877b127a67..e67b023f9609eec8edd9ed496ba9bfd7051aa5eb 100644 --- a/Doc/Sd1/GettingStarted/gettingStarted.xml +++ b/Doc/Sd1/GettingStarted/gettingStarted.xml @@ -745,7 +745,7 @@ </figure> <figure xml:id="sd1_fig_seminarRules"> - <title>Seminar rules / bonus points</title> + <title>Seminar rules and bonus points</title> <itemizedlist> <listitem> @@ -766,29 +766,30 @@ <para>Presenting <emphasis role="bold">at least three exercise</emphasis> solutions of <uri xlink:href="https://freedocs.mi.hdm-stuttgart.de/apb.html">https://freedocs.mi.hdm-stuttgart.de/apb.html</uri>.</para> + </listitem> + </orderedlist> + </listitem> + </itemizedlist> + </figure> - <itemizedlist> - <listitem> - <para>Give a brief account on the exercise in - question.</para> - </listitem> + <figure xml:id="sd1_fig_seminarRulesExercises"> + <title>Presenting exercise solutions</title> - <listitem> - <para>Explain your solution's concept and present your - code.</para> - </listitem> + <itemizedlist> + <listitem> + <para>Give a brief account of the exercise in question.</para> + </listitem> - <listitem> - <para>Explain possible problems / pitfalls.</para> - </listitem> + <listitem> + <para>Explain your solution's concept and present your code.</para> + </listitem> - <listitem> - <para>Ask your tutor for exercises to avoid thematic - clashes</para> - </listitem> - </itemizedlist> - </listitem> - </orderedlist> + <listitem> + <para>Explain possible problems / pitfalls.</para> + </listitem> + + <listitem> + <para>Ask your tutor for exercises to avoid thematic clashes</para> </listitem> </itemizedlist> </figure> diff --git a/Doc/Sd1/LanguageFundamentals/languageFundamentals.xml b/Doc/Sd1/LanguageFundamentals/languageFundamentals.xml index dd2e9fd48d82957e3e7e3e7bb0b942c8089325c2..a983d40d732ab8b63b651bb72fa17d0c83f20fba 100644 --- a/Doc/Sd1/LanguageFundamentals/languageFundamentals.xml +++ b/Doc/Sd1/LanguageFundamentals/languageFundamentals.xml @@ -92,8 +92,8 @@ <para>Following technological advances processors have been categorized by the length the so called address- and data-bus:</para> - <figure xml:id="sd1_fig_adressDataBus"> - <title>Progress in hardware</title> + <figure xml:id="sd1_fig_hardwareProgress1"> + <title>Progress in hardware 1</title> <informaltable border="1"> <col width="40%"/> @@ -153,6 +153,34 @@ <td>12.5 MHz</td> </tr> + </informaltable> + </figure> + + <figure xml:id="sd1_fig_hardwareProgress2"> + <title>Progress in hardware 2</title> + + <informaltable border="1"> + <col width="40%"/> + + <col width="5%"/> + + <col width="15%"/> + + <col width="20%"/> + + <col width="20%"/> + + <tr> + <th>Processor</th> + + <th>Year</th> + + <th>Address/ data bus</th> + + <th>Transistors</th> + + <th>Clock rate</th> + </tr> <tr> <td>Six-core Opteron</td> @@ -177,6 +205,18 @@ <td>3.6 GHz</td> </tr> + + <tr> + <td> Apple's ARM M1 Ultra</td> + + <td>2022</td> + + <td>64 / 64</td> + + <td align="right">114,000,000,000</td> + + <td>3.2 GHz</td> + </tr> </informaltable> </figure> diff --git a/ws/Docbook/CustomLayer/slide/reveal.css.patch b/ws/Docbook/CustomLayer/slide/patch/reveal.css.patch similarity index 100% rename from ws/Docbook/CustomLayer/slide/reveal.css.patch rename to ws/Docbook/CustomLayer/slide/patch/reveal.css.patch diff --git a/ws/Docbook/CustomLayer/slide/slideAssets/css/positioning.css b/ws/Docbook/CustomLayer/slide/slideAssets/css/positioning.css new file mode 100644 index 0000000000000000000000000000000000000000..947f632e25fb96f8d754bf377a958ab3bf60e394 --- /dev/null +++ b/ws/Docbook/CustomLayer/slide/slideAssets/css/positioning.css @@ -0,0 +1,535 @@ +/* + * patched by: /usr/share/hdm-docbook-xsl/CustomLayer/webhelp/positioning.css.patch + * source file: /usr/share/hdm-docbook-xsl/docbook-xsl-1.79.2/webhelp/template/common/css/positioning.css + */ + +tr th .added { color: #E6E6FA; } +tr th .changed {color: #99ff99; } +div.added tr, div.added { background-color: #E6E6FA; } +div.deleted tr, div.deleted { text-decoration: line-through; + background-color: #FF7F7F; } +div.changed tr, div.changed { background-color: #99ff99; } +div.off { } + +span.added { background-color: #E6E6FA; } +span.deleted { text-decoration: line-through; + background-color: #FF7F7F; } +span.changed { background-color: #99ff99; } +span.off { } + + +body { font: 12px Verdana, Geneva, sans-serif; } + +h1 { font: 15pt Arial, Helvetica, geneva; + color: black!important; +} +h2 { font: normal 12pt Arial, Helvetica, geneva; } + +#header { + background: url("../images/header-bg.png") scroll top left repeat-x #4d8c83; + position: fixed; + width: 100%; + height: 50px !important; + top: 0; + right: 0; + bottom: auto; + left: 0; + border-bottom: 1px solid #bbc4c5; + z-index: 2000; +} + +#header h1 { + margin-left: 310px; + position: fixed; + top: 10px; + left: -15px; + color: #404040 !important; +} + + +#header h1 { + margin-top: 2px; +} + + +p.breadcrumbs { + margin-top: 30px; + margin-left: 310px; +} + +#header img { + float: left; + margin-left: 20px; + margin-top: 12px; +} + +#header p.breadcrumbs a { + color: #bbb; +} + +#leftnavigation { + overflow: auto; + position: fixed; + height: auto; + top:100px; + /*right:10px;*/ + /*left:10px;*/ + bottom: 0; + left: 0; + width:inherit; + z-index: 1500; + border-right:2px solid #bbc4c5; + padding:1px; + background-color: #ededed!important; +} + +#treeDiv { + overflow: auto; + /* position: fixed;*/ + height: auto; + top: 136px; + bottom: 0; + left: 0; + /* width: 18%;*/ + z-index: 1500; + /* border-right:2px solid #CCCCCC; + background-color: #f0f0f0!important;*/ +} + +/*#searchDiv { + overflow: auto; + position: fixed; + height: auto; + top: 138px; + bottom: 0; + left: 0; + width: 243px; + z-index: 1500; + border-right:2px solid #CCCCCC; + background-color: #f0f0f0!important; +}*/ + +#content { + position: relative; + top: 90px; /*left: 240px;*/ + right: auto; bottom: 20px; + /*margin: 0px 0px 0px 280px;*/ + width: auto; + height: inherit; + padding-left: 5px; + padding-right: 30px; + border-left: 1px solid #cccccc; + overflow :scroll; + overflow-x:hidden; + z-index: 1000; + +} + +#navheader { + position: fixed; + background: #DCDCDC; + padding-left: 10px; + right: 0px; + top: 10px; + text-align: right; +} + +#content h1, #content h2 { +color: #404040 !important; +font-size: 170%; +font-weight: normal; +} +.navfooter { bottom: 2%; } +.highlight { background-color: #c5d3c3; } +.highlightButton{ font-size: 0; } + +/* Show Hide TOC tree */ +.pointLeft { + padding-right: 15px; + display: block; + cursor: pointer; +} +.pointRight { + padding-right: 15px; + display: block; + cursor: pointer; +} + +/* Search results Styling */ +.searchExpression { + color: #0050A0; + background-color: #EBEFF8; + font-size: 12pt; +} +.searchresult li a { + text-decoration: none; + color: #0050A0; +} +.searchresult li { color: #0050A0; } +.shortdesclink { color: gray; font-size: 9pt; } +.searchText { float:left;width:150px; } +.searchButton { + padding: 2px 12px 2px 12px; + background-color:#bbb; + border:#bbb solid 1pt; + font-weight: bold; + font-size: 10pt +} +.searchButton:hover{ + background-color: #cccccc; +} +.searchFieldSet {} + +.title, div.toc>p{ font-weight: bold; } + +p.breadcrumbs { + display: inline; + margin-bottom: 0px; + margin-top: 33px; +} + +p.breadcrumbs a { + padding-right: 12px; + margin-right: 5px; + text-decoration: none; + color: #575757; + text-transform: uppercase; + font-size: 10px; +} + +p.breadcrumbs a:first-child {background: url(../images/breadcrumb-arrow-white.png) no-repeat right center;} + +p.breadcrumbs a:hover {text-decoration: underline;} + +#star ul.star { + LIST-STYLE: none; + MARGIN: 0; + PADDING: 0; + WIDTH: 85px; + /* was 100 */ + HEIGHT: 20px; + LEFT: 1px; + TOP: -5px; + POSITION: relative; + FLOAT: right; + BACKGROUND: url('../images/starsSmall.png') repeat-x 0 -25px; +} +#star li { + PADDING: 0; + MARGIN: 0; + FLOAT: right; + DISPLAY: block; + WIDTH: 85px; + /* was 100 */ + HEIGHT: 20px; + TEXT-DECORATION: none; + text-indent: -9000px; + Z-INDEX: 20; + POSITION: absolute; + PADDING: 0; +} +#star li.curr { + BACKGROUND: url('../images/starsSmall.png') left 25px; + FONT-SIZE: 1px; +} + +table.navLinks {margin-right: 20px;} + +table.navLinks td a { + text-decoration: none; + text-transform: uppercase; + color: black; + font-size: 11px; +} + +a.navLinkPrevious { + padding-left: 12px; + background: url(../images/previous-arrow.png) no-repeat left center; +} + +a.navLinkNext { + padding-right: 12px; + background: url(../images/next-arrow.png) no-repeat right center; +} + +a#showHideButton { + padding-left: 20px; + background: url(../images/sidebar.png) no-repeat left center; +} + + +.filetree li span a { color: #777; } + +#treediv { -webkit-box-shadow: #CCC 0px 1px 2px 0px inset; } + +.legal, .legal *{ + color: #555; + text-align: center; + padding-bottom: 10px; +} + +.internal { color : #0000CC;} + +.writeronly {color : red;} + +.remark, .remark .added, .remark .changed, .remark .deleted{ background: yellow;} + +tr th, tr th .internal, tr th .added, tr th .changed { + background: black; + color: white; + font-weight: bold; + text-align: left; +} + +.statustext{ + position:fixed; + top:105px; + width: 0%; + height: 0%; + opacity: .3; + -webkit-transform: rotate(90deg); + -moz-transform: rotate(90deg); + -o-transform: rotate(90deg); + white-space: nowrap; + color: red; + font-weight: bold; + font-size: 2em; + margin-top: 30px; +} + +#toolbar { + width: 100%; + height: 33px; + position: fixed; + top: 93px; + z-index: 99; + left: 280px; + color: #333; + line-height: 28px; + padding-left: 10px; +} + +#toolbar-left { + position: relative; + left: 0px; +} + +body p.breadcrumbs { + margin: 0px; + padding: 0px; + line-height: 28px; +} + +/*body #content { + position: static; + margin-top: 126px; + top: 0px; +}*/ + +body.sidebar #toolbar{left: 0px;} + +body.sidebar #toolbar-left{left: 0px;} + +div#toolbar-left img {vertical-align: text-top;} + +div.note *, div.caution *, div.important *, div.tip *, div.warning * { + width: fit-content; + color: inherit !important; + /* border: inherit !important; */ +} + +div.note, div.caution, div.important, div.tip, div.warning { + width: fit-content; + background: var(--admonitionBackgroundColor) !important; + border-radius: 10px; + padding: 5px; + border-style: solid; + border-color: #AAAAAA; + border-width: 1px; +} + + + +#content table thead, #content table th{ + background: gray; + color: white; + font-weight: bold; +} + +#content table caption{font-weight: bold;} + +#content table[border='1'] td, #content table[border='1'] {border: 1px solid black !important;} + +#content table td, #content table th { padding: 5px;} + +#content table {margin-bottom: 20px;} + +*[align = 'center']{ text-align: center;} + +#content .calloutlist>table[border='0'], #content .calloutlist>table[border='0'] td, +#content .informaltable>table[border='0'], #content .informaltable>table[border='0'] td, +#content .qandaset>table, #content .qandaset>table td, #content .calloutlist table, #content .calloutlist table td, #content .navfooter table, #content .navfooter table td { + border: 0px solid; +} + +#sidebar { display: none } + +@media print { + + body * { + visibility: hidden; + } + + #content, #content * { + visibility: visible; + } + + #sidebar, .navfooter { + display: none; + } + + #content { + margin: 0 0 0 0; + } + +} + +/* + * HdM supplements + * + */ +:root { + --screenBackgroundColor: #ECFAFB; /* Background of <screen> */ + --programlistingBackgroundColor: #EEF5FA; /* Background of <programlisting> */ + --admonitionBackgroundColor: #EFFFEF; /* Background <tip>, <caution>, ... */ +} + +.screen { + width: fit-content; + border-radius: 10px; + padding: 5px; + background-color: var(--screenBackgroundColor); + border-style: solid; + border-color: #AAAAAA; + border-width: 1px; + +} + +.programlisting { + width: fit-content; + border-radius: 10px; + padding: 5px; + background-color: var(--programlistingBackgroundColor); + border-style: solid; + border-color: #AAAAAA; + border-width: 1px; +} + +table { + border-collapse: collapse; +} + +#content .informaltable>table:not[border='0'], #content .informaltable>table:not[border='0'] td, +#content .table-contents>table:not[border='0'], #content .table-contents>table:not[border='0'] td { + border: 1px solid; +} + +/* ------------------------------------------------------------------------ + | Syntax highlighting + +------------------------------------------------------------------------- */ + +.hl-keyword { + font-weight: bold; + color: #602060; +} + +.hl-string { + color: #A00000; +} + +.hl-number { + color: #B08000; +} + +.hl-comment { + font-style: italic; + color: #808080; +} + +.hl-doccomment { + color: #008080; +} + +.hl-directive { + color: #00A000; +} + +.hl-annotation { + font-weight: bold; + color: #808080; +} + +/* + * XML + */ + +.hl-tag { + font-weight: bold; + color: #602060; +} + +.hl-attribute { + color: #0050A0; +} + +.hl-value { + color: #A00000; +} + +.hl-doctype { + color: #008080; +} + +/* NodeBB forum support */ +div.bbForum > p:before { + background-image: url("../images/comment.svg"); + opacity: 0.5; + background-repeat: no-repeat; + display: inline-block; + width: 30px; + height: 20px; + content:""; +} + +/* Highlight link target, credits to + https://stackoverflow.com/questions/11142125/css-highlight-a-div-when-the-id-is-linked-to-using-an-anchor +*/ + +:target { + background-color: #ffa; +} + +/* inline emphasis role based extensions */ +.red { + color: red; + font-weight: bold !important; +} + +/* figure frame */ +.figure, .qandaset { + border-width: 0.5ex; + border-style: solid; + border-color: grey; + padding: 1ex; + border-radius: 2ex; +} + +.slideSectionOverview { + background-color: #FCFFCD; + border-radius: 25px; + padding-left: 10px; +} + +a:hover { + color: LightSkyBlue; +} diff --git a/ws/Docbook/CustomLayer/slide/slideAssets/css/tooltips.css b/ws/Docbook/CustomLayer/slide/slideAssets/css/tooltips.css new file mode 100644 index 0000000000000000000000000000000000000000..dd7f801f546f3b3fb16fdd1594da40cf1cad30b7 --- /dev/null +++ b/ws/Docbook/CustomLayer/slide/slideAssets/css/tooltips.css @@ -0,0 +1,63 @@ +.header-left { + position: absolute; + top: 0%; + left: 0%; +} + +.header-right { + position: absolute; + top: 0%; + right: 0%; +} + +.footer-center { + position: absolute; + bottom: 0%; + left: 40%; +} + +/* Tooltip container */ +.tooltip { + position: relative; + display: inline-block; + border-bottom: 1px dotted black; /* If you want dots under the hoverable text */ +} + +/* Tooltip text */ +.tooltip .tooltiptext { + visibility: hidden; + width: 600px; + background-color: #555; + color: #fff; + padding: 50px; + border-radius: 6px; + + /* Position the tooltip text */ + position: absolute; + z-index: 1; + bottom: 110%; + left: 0%; + margin-left: -300px; + + /* Fade in tooltip */ + opacity: 0; + transition: opacity 0.3s; +} + +/* Tooltip arrow */ +.tooltip .tooltiptext::after { + content: ""; + position: absolute; + top: 100%; + left: 50%; + margin-left: -5px; + border-width: 5px; + border-style: solid; + border-color: #555 transparent transparent transparent; +} + +/* Show the tooltip text when you mouse over the tooltip container */ +.tooltip:hover .tooltiptext { + visibility: visible; + opacity: 1; +} diff --git a/ws/Docbook/CustomLayer/slide/slideAssets/js/docbookSupp.js b/ws/Docbook/CustomLayer/slide/slideAssets/js/docbookSupp.js new file mode 100644 index 0000000000000000000000000000000000000000..b0f136bdc032c978e49617207581ed2c99353c5a --- /dev/null +++ b/ws/Docbook/CustomLayer/slide/slideAssets/js/docbookSupp.js @@ -0,0 +1,28 @@ +Reveal.initialize({ + center: true, + history: true, + width: '100%', + height: '100%', + plugins: [ RevealHighlight ], + // transition: 'slide', + // transitionSpeed: 'slow', + // backgroundTransition: 'slide' +}); + + + +Reveal.addEventListener('slidechanged', function (event) { + $.currHeaderId = '#__HEADER_' + event.currentSlide.getAttribute("id"); + $.previusHeaderId = '#__HEADER_' + event.previousSlide.getAttribute("id"); + + $($.previusHeaderId).attr("style", "display:none;"); + $($.currHeaderId).attr("style", "display:block;"); + + //$('#myShow').text($.previusHeaderId + ":" + $.currHeaderId); +}); + +Reveal.addEventListener('ready', function (event) { + $.currHeaderId = '#__HEADER_' + event.currentSlide.getAttribute("id"); + $($.currHeaderId).attr("style", "display:block;"); + //$('#myShow').text($.currHeaderId); +}); diff --git a/ws/Docbook/CustomLayer/slide/slideHdm.xsl b/ws/Docbook/CustomLayer/slide/xsl/slideHdm.xsl similarity index 72% rename from ws/Docbook/CustomLayer/slide/slideHdm.xsl rename to ws/Docbook/CustomLayer/slide/xsl/slideHdm.xsl index c58b618c637685d1a97e83aebf3876beea26d87b..084645625fd28dfd96cd2371c462ca6e8ada29db 100644 --- a/ws/Docbook/CustomLayer/slide/slideHdm.xsl +++ b/ws/Docbook/CustomLayer/slide/xsl/slideHdm.xsl @@ -3,13 +3,13 @@ xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:d="http://docbook.org/ns/docbook" xmlns="http://www.w3.org/1999/xhtml"> - <xsl:import href="../../docbook-xsl/xhtml/chunk.xsl"/> - <xsl:import href="../../docbook-xsl/xhtml/highlight.xsl"/> - <xsl:import href="../../docbook-xsl/webhelp/xsl/webhelp-common.xsl"/> - <xsl:import href="../../docbook-xsl/webhelp/xsl/titlepage.templates.xsl"/> + <xsl:import href="/usr/share/hdm-docbook-xsl/docbook-xsl/xhtml/chunk.xsl"/> + <xsl:import href="/usr/share/hdm-docbook-xsl/docbook-xsl/xhtml/highlight.xsl"/> + <xsl:import href="/usr/share/hdm-docbook-xsl/docbook-xsl/webhelp/xsl/webhelp-common.xsl"/> + <xsl:import href="/usr/share/hdm-docbook-xsl/docbook-xsl/webhelp/xsl/titlepage.templates.xsl"/> - <xsl:import href="../Common/common.xsl"/> - <xsl:import href="../../Preprocess/Xsl/slideReference.xsl"/> + <xsl:import href="/usr/share/hdm-docbook-xsl/CustomLayer/Common/common.xsl"/> + <xsl:import href="/usr/share/hdm-docbook-xsl/Preprocess/Xsl/slideReference.xsl"/> <xsl:variable name="topicLookup" select="document('topics.tid.xml', .)"/> @@ -89,86 +89,33 @@ </xsl:variable> <!-- Writing slide series --> + <xsl:document href="{$slideFileName}" method="html" encoding="utf-8" indent="yes" doctype-system="none"> - <html lang="en"> + <html> <head> + <meta charset="utf-8"/> <title> <xsl:value-of select="d:title"/> </title> - <link rel="shortcut icon" href="favicon.ico" type="image/x-icon"/> - <link href="common/css/positioning.css" rel="stylesheet"/> - <link href="reveal.js/css/reveal.css" rel="stylesheet"/> - <link href="reveal.js/css/theme/serif.css" id="theme" rel="stylesheet"/> - - <!-- Code syntax highlighting --> - <link href="reveal.js/lib/css/zenburn.css" rel="stylesheet"/> - - <style> - /* Tooltip container */ - .tooltip { - position: relative; - display: inline-block; - border-bottom: 1px dotted black; /* If you want dots under the hoverable text */ - } - - /* Tooltip text */ - .tooltip .tooltiptext { - visibility: hidden; - width: 600px; - background-color: #555; - color: #fff; - padding: 50px; - border-radius: 6px; - - /* Position the tooltip text */ - position: absolute; - z-index: 1; - bottom: 110%; - left: 0%; - margin-left: -300px; - - /* Fade in tooltip */ - opacity: 0; - transition: opacity 0.3s; - } - - /* Tooltip arrow */ - .tooltip .tooltiptext::after { - content: ""; - position: absolute; - top: 100%; - left: 50%; - margin-left: -5px; - border-width: 5px; - border-style: solid; - border-color: #555 transparent transparent transparent; - } - - /* Show the tooltip text when you mouse over the tooltip container */ - .tooltip:hover .tooltiptext { - visibility: visible; - opacity: 1; - }</style> - - <!-- Using free header and footer zones --> - <style type="text/css"> - .header-left { - position: absolute; - top: 0%; - left: 0%; + <link rel="stylesheet" href="reveal.js/css/reveal.css"></link> + <link rel="stylesheet" href="reveal.js/css/theme/white.css" id="theme"></link> + + <style media="screen"> + .slides section.has-dark-background, + .slides section.has-dark-background h3 { + color: #fff; } - .header-right { - position: absolute; - top: 0%; - right: 0%; + + .slides section.has-light-background, + .slides section.has-light-background h3 { + color: #222; } - .footer-center { - position: absolute; - bottom: 0%; - left: 40%; - }</style> + </style> + + <link href="slideAssets/css/positioning.css" rel="stylesheet"/> + <link href="slideAssets/css/tooltips.css" rel="stylesheet"/> </head> <body> @@ -193,54 +140,15 @@ </div> <script src="reveal.js/js/reveal.js"/> - <link rel="stylesheet" - href="https://freedocs.mi.hdm-stuttgart.de/lib/highlight.js/styles/idea.css"/> - <script>/*<![CDATA[*/ - - Reveal.initialize({ - controls: true, - progress: true, - history: true, - center: true, - width: '70%', - margin: 0.0, - - transition: 'none', // none/fade/slide/convex/concave/zoom - - math: { - mathjax: 'mathjax/MathJax.js', - config: 'TeX-AMS-MML_HTMLorMML', // See http://docs.mathjax.org/en/latest/config-files.html - }, - // Optional reveal.js plugins - dependencies: [ - { src: 'reveal.js/lib/js/classList.js', condition: function() { return !document.body.classList; } }, - { src: 'reveal.js/plugin/markdown/marked.js', condition: function() { return !!document.querySelector( '[data-markdown]' ); } }, - { src: 'reveal.js/plugin/markdown/markdown.js', condition: function() { return !!document.querySelector( '[data-markdown]' ); } }, - { src: 'https://freedocs.mi.hdm-stuttgart.de/lib/highlight.js/highlight.js', async: true, callback: function() { hljs.initHighlightingOnLoad(); } }, - { src: 'reveal.js/plugin/zoom-js/zoom.js', async: true }, - { src: 'reveal.js/plugin/notes/notes.js', async: true }, - { src: 'reveal.js/plugin/math/math.js', async: true } - ] - }); - /*]]>*/</script> + <script src="reveal.js/plugin/highlight/highlight.js"/> + <link rel="stylesheet" href="reveal.js/lib/css/idea.min.css"/> + <!-- + <link rel="stylesheet" href="reveal.js/plugin/highlight/monokai.css"/> + <link rel="stylesheet" href="https://freedocs.mi.hdm-stuttgart.de/lib/highlight.js/styles/idea.css"/> + --> <script src="common/jquery/jquery-1.7.2.min.js"/> - <script type="text/javascript"> - Reveal.addEventListener('slidechanged', function (event) { - $.currHeaderId = '#__HEADER_' + event.currentSlide.getAttribute("id"); - $.previusHeaderId = '#__HEADER_' + event.previousSlide.getAttribute("id"); - - $($.previusHeaderId).attr("style", "display:none;"); - $($.currHeaderId).attr("style", "display:block;"); - - //$('#myShow').text($.previusHeaderId + ":" + $.currHeaderId); - }); - - Reveal.addEventListener('ready', function (event) { - $.currHeaderId = '#__HEADER_' + event.currentSlide.getAttribute("id"); - $($.currHeaderId).attr("style", "display:block;"); - //$('#myShow').text($.currHeaderId); - });</script> + <script src="slideAssets/js/docbookSupp.js"/> </body> </html> @@ -316,29 +224,55 @@ <xsl:variable name="currentFigure" as="element()*" select="."/> - <xsl:variable name="figBasename"> - <xsl:call-template name="hdm.get.leftmost.of.separator"> - <xsl:with-param name="path" select="d:mediaobject/d:imageobject/d:imagedata/@fileref"/> - <xsl:with-param name="separator" select="'.fig.svg'"/> - </xsl:call-template> + <xsl:variable name="figureTitle"> + <xsl:apply-templates select="d:title"/> + </xsl:variable> + + <xsl:variable name="imgFilerefValue"> + <xsl:value-of select="d:mediaobject/d:imageobject/d:imagedata/@fileref"/> + </xsl:variable> + + <xsl:variable name="imgPath"> <xsl:call-template name="hdm.get.leftmost.of.separator"> - <xsl:with-param name="path" select="d:mediaobject/d:imageobject/d:imagedata/@fileref"/> - <xsl:with-param name="separator" select="'.multi.svg'"/> + <xsl:with-param name="path" select="$imgFilerefValue"/> + <xsl:with-param name="separator" select="'/'"/> </xsl:call-template> </xsl:variable> - <xsl:variable name="figSet" as="element()*"> - <xsl:if test="0 < string-length($figBasename)"> - <xsl:copy-of select="document(concat($figBasename, '.filenames'), .)/start/file"/> - </xsl:if> + <xsl:variable name="imgName"> + <xsl:value-of select="substring-after($imgFilerefValue, concat($imgPath, '/'))"/> </xsl:variable> - <xsl:choose> + <xsl:variable name="imgStem"> + <xsl:value-of select="substring-before($imgName, '.')"/> + </xsl:variable> - <xsl:when test="1 < count($figSet/*)"> - <!-- Image series --> + <xsl:variable name="imgExtension"> + <xsl:value-of select="substring-after($imgName, concat($imgStem, '.'))"/> + </xsl:variable> - <xsl:for-each select="$figSet/*"> + <xsl:variable name="moduleRootPath"> + <xsl:for-each select="ancestor::*/@xml:base"> + <xsl:call-template name="hdm.get.leftmost.of.separator"> + <xsl:with-param name="path" select="."/> + <xsl:with-param name="separator" select="'/'"/> + </xsl:call-template> + <xsl:text>/</xsl:text> + </xsl:for-each> + </xsl:variable> + + <xsl:variable name="fullStemPathname"> + <xsl:value-of select="concat($moduleRootPath, '/', $imgPath, '/', $imgStem)"/> + </xsl:variable> + + <xsl:choose> + <xsl:when test="$imgExtension = 'multi.svg'"> + + <xsl:variable name="imgLayerSet" as="element()*"> + <xsl:copy-of + select="document(concat($fullStemPathname, '.filenames'), /)/start/file"/> + </xsl:variable> + <xsl:for-each select="$imgLayerSet/*"> <xsl:variable name="currentAnimationId"> <xsl:choose> @@ -350,19 +284,21 @@ <xsl:otherwise> <xsl:value-of select="concat($primarySectionId, '-', position() - 1)"/> </xsl:otherwise> - </xsl:choose> </xsl:variable> <div id="__HEADER_{$currentAnimationId}" style="display: none;"> - <div class="header-left" style="z-index: 1000;"> + <div class="header-left" style="z-index: 1000;" > <xsl:apply-templates select="$currentFigure/d:title"/> </div> <div class="footer-center" style="z-index: 1000;"> - <xsl:apply-templates select="$currentFigure" mode="footer"/> + <xsl:apply-templates select="$currentFigure" mode="footer"> + <xsl:with-param name="index" select="position()"/> + <xsl:with-param name="length" select="last()"/> + </xsl:apply-templates> </div> </div> @@ -370,8 +306,6 @@ </xsl:when> <xsl:otherwise> - <!-- Just a single image or other content --> - <div id="__HEADER_{$primarySectionId}" style="display: none;"> <div class="header-left" style="z-index: 1000;"> @@ -383,8 +317,8 @@ </div> </div> - </xsl:otherwise> + </xsl:choose> <xsl:call-template name="generateFollowupQandasetHeaders"/> @@ -419,43 +353,52 @@ <xsl:apply-templates select="d:title"/> </xsl:variable> - <xsl:variable name="baseSupplementDir"> - <xsl:if test="ancestor::*/@xml:base"> - <xsl:call-template name="hdm.get.leftmost.of.separator"> - <xsl:with-param name="path" select="ancestor::*/@xml:base"/> - <xsl:with-param name="separator" select="'/'"/> - </xsl:call-template> - <xsl:text>/</xsl:text> - </xsl:if> + <xsl:variable name="imgFilerefValue"> + <xsl:value-of select="d:mediaobject/d:imageobject/d:imagedata/@fileref"/> </xsl:variable> - <xsl:variable name="figBasename"> + <xsl:variable name="imgPath"> <xsl:call-template name="hdm.get.leftmost.of.separator"> - <xsl:with-param name="path" select="d:mediaobject/d:imageobject/d:imagedata/@fileref"/> - <xsl:with-param name="separator" select="'.fig.svg'"/> - </xsl:call-template> - <xsl:call-template name="hdm.get.leftmost.of.separator"> - <xsl:with-param name="path" select="d:mediaobject/d:imageobject/d:imagedata/@fileref"/> - <xsl:with-param name="separator" select="'.multi.svg'"/> + <xsl:with-param name="path" select="$imgFilerefValue"/> + <xsl:with-param name="separator" select="'/'"/> </xsl:call-template> </xsl:variable> - <xsl:variable name="figSet" as="element()*"> - <xsl:if test="0 < string-length($figBasename)"> - <xsl:copy-of select="document(concat($figBasename, '.filenames'), .)/start/file"/> - </xsl:if> + <xsl:variable name="imgName"> + <xsl:value-of select="substring-after($imgFilerefValue, concat($imgPath, '/'))"/> </xsl:variable> - <xsl:variable name="currentFigureFooter"> - <xsl:apply-templates select="." mode="footer"/> + <xsl:variable name="imgStem"> + <xsl:value-of select="substring-before($imgName, '.')"/> </xsl:variable> - <xsl:choose> + <xsl:variable name="imgExtension"> + <xsl:value-of select="substring-after($imgName, concat($imgStem, '.'))"/> + </xsl:variable> + + <xsl:variable name="moduleRootPath"> + <xsl:for-each select="ancestor::*/@xml:base"> + <xsl:call-template name="hdm.get.leftmost.of.separator"> + <xsl:with-param name="path" select="."/> + <xsl:with-param name="separator" select="'/'"/> + </xsl:call-template> + <xsl:text>/</xsl:text> + </xsl:for-each> + </xsl:variable> - <xsl:when test="1 < count($figSet/*)"> - <!-- Image series --> + <xsl:variable name="fullStemPathname"> + <xsl:value-of select="concat($moduleRootPath, '/', $imgPath, '/', $imgStem)"/> + </xsl:variable> + + <xsl:choose> + <xsl:when test="$imgExtension = 'multi.svg'"> + <xsl:variable name="imgLayerSet" as="element()*"> + <xsl:copy-of + select="document(concat($fullStemPathname, '.filenames'), /)/start/file"/> + </xsl:variable> <section> - <xsl:for-each select="$figSet/*"> + <xsl:for-each select="$imgLayerSet/*"> + <section> <xsl:choose> @@ -474,40 +417,40 @@ <div class="mediaobject"> <img width="95%" - src="{concat($baseSupplementDir, $figBasename, '-', position() - 1, '.svg')}" - alt="layered SVG image"/> + src="{concat($fullStemPathname, '-', position() - 1, '.svg')}" + alt="Image layer {position()}"/> </div> - </section> </xsl:for-each> </section> + </xsl:when> <xsl:otherwise> - <!-- Just a single image or other content --> - <section id="{$primarySectionId}"> - <xsl:apply-templates select="*[not(self::d:title)]"/> - </section> - </xsl:otherwise> + </xsl:choose> + <xsl:variable name="currentFigureFooter"> + <xsl:apply-templates select="." mode="footer"/> + </xsl:variable> + <xsl:call-template name="generateFollowupQandasets"/> </xsl:template> <xsl:template match="d:imagedata"> <xsl:variable name="baseSupplementDir"> - <xsl:if test="ancestor::*/@xml:base"> + <xsl:for-each select="ancestor::*/@xml:base"> <xsl:call-template name="hdm.get.leftmost.of.separator"> - <xsl:with-param name="path" select="ancestor::*/@xml:base"/> + <xsl:with-param name="path" select="."/> <xsl:with-param name="separator" select="'/'"/> </xsl:call-template> <xsl:text>/</xsl:text> - </xsl:if> + </xsl:for-each> </xsl:variable> <img width="95%" src="{concat($baseSupplementDir, @fileref)}" alt="{ancestor::d:figure/d:title}" @@ -561,7 +504,8 @@ </xsl:template> <xsl:template match="d:figure" mode="footer"> - + <xsl:param name="index"/> + <xsl:param name="length"/> <div class="hdmfooter"> <table> <tr> @@ -582,7 +526,6 @@ style="border: 0mm; margin-top: 0mm; margin-bottom: 0mm;"/> <p class="tooltiptext">Pdf slides</p> </a> - </td> <td class="tooltip"> @@ -590,6 +533,7 @@ <img src="common/images/compass.svg" width="60" style="border: 0mm; margin-top: 0mm; margin-bottom: 0mm;"/> </a> + <xsl:call-template name="createTooltipBreadcrumbHierarchy"> <xsl:with-param name="nodes" @@ -602,8 +546,15 @@ </xsl:call-template> </td> - - + <td> + <xsl:if test="$index"> + <xsl:text> (#</xsl:text> + <xsl:value-of select="$index"/> + <xsl:text> of </xsl:text> + <xsl:value-of select="$length"/> + <xsl:text>)</xsl:text> + </xsl:if> + </td> <xsl:variable name="qandaId" select="@xml:id"/> <xsl:if test="$topicLookup/map/entry[@id = $qandaId]"> @@ -697,13 +648,13 @@ <xsl:template match="d:mediaobject[d:imageobject/d:imagedata[@valign]]"> <img> <xsl:attribute name="src"> - <xsl:if test="ancestor::*/@xml:base"> + <xsl:for-each select="ancestor::*/@xml:base"> <xsl:call-template name="hdm.get.leftmost.of.separator"> - <xsl:with-param name="path" select="ancestor::*/@xml:base"/> + <xsl:with-param name="path" select="."/> <xsl:with-param name="separator" select="'/'"/> </xsl:call-template> <xsl:text>/</xsl:text> - </xsl:if> + </xsl:for-each> <xsl:value-of select="d:imageobject/d:imagedata/@fileref"/> </xsl:attribute> diff --git a/ws/Docbook/Extensions/Tdata/ImgXinclude/Other/doc.xml b/ws/Docbook/Extensions/Tdata/ImgXinclude/Other/doc.xml index 4b63e516b5366b37d3d2522158e12c6c6d098ca5..56f8c93bb10787658c0fc16a271dbaae764fc92b 100644 --- a/ws/Docbook/Extensions/Tdata/ImgXinclude/Other/doc.xml +++ b/ws/Docbook/Extensions/Tdata/ImgXinclude/Other/doc.xml @@ -9,15 +9,23 @@ xmlns:ns="http://docbook.org/ns/docbook"> <title>Other images</title> - <mediaobject> - <imageobject> - <imagedata fileref="Fig/stayclear.png"/> - </imageobject> - </mediaobject> + <figure xml:id="figCrabs"> + <title>Lobstermaniacs</title> - <mediaobject> - <imageobject> - <imagedata fileref="Fig/implement.multi.svg"/> - </imageobject> - </mediaobject> + <mediaobject> + <imageobject> + <imagedata annotations="slide" fileref="Fig/stayclear.png"/> + </imageobject> + </mediaobject> + </figure> + + <figure xml:id="figExamPoints"> + <title>Examination strategy</title> + + <mediaobject> + <imageobject> + <imagedata fileref="Fig/implement.multi.svg"/> + </imageobject> + </mediaobject> + </figure> </chapter> diff --git a/ws/Docbook/Extensions/Tdata/ImgXinclude/Some/Sub/More/doc.xml b/ws/Docbook/Extensions/Tdata/ImgXinclude/Some/Sub/More/doc.xml index d458e6afd12c3c9e1c0aca086141112c7cbacdea..21d75e4ee9ff1ed72393b451585b862a230aa3d3 100644 --- a/ws/Docbook/Extensions/Tdata/ImgXinclude/Some/Sub/More/doc.xml +++ b/ws/Docbook/Extensions/Tdata/ImgXinclude/Some/Sub/More/doc.xml @@ -9,23 +9,33 @@ xmlns:ns="http://docbook.org/ns/docbook"> <title>More stuff ...</title> - <mediaobject> - <imageobject> - <imagedata fileref="Images/Test/rectangleObjects.svg"/> - </imageobject> - </mediaobject> + <figure xml:id="figRectangleAttribs"> + <title>Rectangle's attributes</title> - <mediaobject> - <imageobject> - <imagedata fileref="Images/Test/scaleRectangle.multi.svg"/> - </imageobject> - </mediaobject> + <mediaobject> + <imageobject> + <imagedata fileref="Images/Test/rectangleObjects.svg"/> + </imageobject> + </mediaobject> + </figure> + <figure xml:id="rectangleScale"> + <title>Scaling an <emphasis role="bold">important</emphasis> + rectangle</title> + + <mediaobject> + <imageobject> + <imagedata fileref="Images/Test/scaleRectangle.multi.svg"/> + </imageobject> + </mediaobject> + </figure> <section xml:id="sd1_exam_2020_winter_1_task3"> <title>Weird subtraction</title> <qandaset defaultlabel="qanda" xml:id="sd1_exam_2020_winter_1_task3Qanda"> + <title>Strange results</title> + <qandadiv> <qandaentry> <question> @@ -54,8 +64,8 @@ System.out.println("cc == " + cc);</programlisting></td> </question> <answer> - <para>A <code language="java">char</code> ranges from 0 to 5</para> - + <para>A <code language="java">char</code> ranges from 0 to + 5</para> </answer> </qandaentry> </qandadiv> diff --git a/ws/Docbook/Extensions/Tdata/ImgXinclude/Some/doc.xml b/ws/Docbook/Extensions/Tdata/ImgXinclude/Some/doc.xml index ac2dce5e643a3227137e46de6bd7599861aa4a42..034b32ffc527451085ea81fc751d2f0604a41591 100644 --- a/ws/Docbook/Extensions/Tdata/ImgXinclude/Some/doc.xml +++ b/ws/Docbook/Extensions/Tdata/ImgXinclude/Some/doc.xml @@ -1,5 +1,6 @@ <?xml version="1.0" encoding="UTF-8"?> -<chapter version="5.1" xml:id="some" xmlns="http://docbook.org/ns/docbook" +<chapter annotations="slide" version="5.1" xml:id="some" + xmlns="http://docbook.org/ns/docbook" xmlns:xi="http://www.w3.org/2001/XInclude" xmlns:ns62="http://www.w3.org/1999/xhtml" xmlns:ns6="http://docbook.org/ns/transclusion" @@ -9,14 +10,15 @@ xmlns:ns="http://docbook.org/ns/docbook"> <title>Some</title> - <mediaobject> - <imageobject> - <imagedata fileref="Pic/pascal.svg"/> - </imageobject> - </mediaobject> + <figure xml:id="figPascal"> + <title>Pascal's triangle</title> + <mediaobject> + <imageobject> + <imagedata fileref="Pic/pascal.svg"/> + </imageobject> + </mediaobject> + </figure> <xi:include href="Sub/More/doc.xml" xpointer="element(/1)"/> - - </chapter> diff --git a/ws/Docbook/Preprocess/Xsl/docbook2docbook.xsl b/ws/Docbook/Preprocess/Xsl/docbook2docbook.xsl index 95d056a8d9eed899b569d8ba8433538fbfd8cfa2..d4c12c1a3576df434dca07c2ad2f6a0bac2626f2 100644 --- a/ws/Docbook/Preprocess/Xsl/docbook2docbook.xsl +++ b/ws/Docbook/Preprocess/Xsl/docbook2docbook.xsl @@ -35,9 +35,25 @@ <xsl:value-of select="$nl"/> </xsl:for-each> </xsl:result-document> - </xsl:template> - - <xsl:template match="node() | @*"> + + <!-- Create list of external links --> + <xsl:result-document href="target/externalLinkList.txt" method="text"> + <xsl:for-each select="//*/@xlink:href"> + <xsl:for-each select="ancestor::*/@xml:base"> + <xsl:call-template name="hdm.get.leftmost.of.separator"> + <xsl:with-param name="path" select="."/> + <xsl:with-param name="separator" select="'/'"/> + </xsl:call-template> + <xsl:text>/</xsl:text> + </xsl:for-each> + <xsl:value-of select="."/> + <xsl:value-of select="$nl"/> + </xsl:for-each> + </xsl:result-document> + +</xsl:template> + +<xsl:template match="node() | @*"> <xsl:copy> <xsl:apply-templates select="node()| @*"/> </xsl:copy> diff --git a/ws/Docbook/Preprocess/Xsl/docbook2html.xsl b/ws/Docbook/Preprocess/Xsl/docbook2html.xsl index c646c03105c02efef23ad4bf303d71e0e38193c3..71857a9fd19baff255e4c7fa2b204d8406f7385b 100644 --- a/ws/Docbook/Preprocess/Xsl/docbook2html.xsl +++ b/ws/Docbook/Preprocess/Xsl/docbook2html.xsl @@ -54,11 +54,6 @@ <xsl:value-of select="$htmlPresentationForumFileBasename"/> </xsl:variable> - <xsl:message> - <xsl:text>figure------------------------</xsl:text> - <xsl:value-of select="$htmlPresentationForumFilename"/> - </xsl:message> - <!-- Hack circumventing docbook XSL bug https://sourceforge.net/p/docbook/bugs/1399 preventing nesting of <inlinemediaobject> descendants inside <figure>/<title>. @@ -157,11 +152,6 @@ <xsl:value-of select="$htmlPresentationForumFileBasename"/> </xsl:variable> - <xsl:message> - <xsl:text>qandaset------------------------</xsl:text> - <xsl:value-of select="$htmlPresentationForumFilename"/> - </xsl:message> - <!-- Hack circumventing docbook XSL bug https://sourceforge.net/p/docbook/bugs/1399 preventing nesting of <inlinemediaobject> descendants inside <figure>/<title>. diff --git a/ws/Docbook/Preprocess/make.rules b/ws/Docbook/Preprocess/make.rules index 26e15073c6399e4979351746eefe19cd14c0b8c9..56ecef1cbebe331a099b4bf8aa4d5c52c80f71fb 100644 --- a/ws/Docbook/Preprocess/make.rules +++ b/ws/Docbook/Preprocess/make.rules @@ -145,9 +145,10 @@ SAXONCMD=java -cp "${DBOOK_XSL}/tools/lib/saxon9he.jar:/usr/share/java/xercesImp zip -qrX ${*}.epub mimetype META-INF OEBPS mathjax %.slide: %.slide.xml - ${SAXON6CMD} $< ${DBOOK_XSL_CUSTOM}/slide/slideHdm.xsl ${dbookXslSlideParam} + ${SAXON6CMD} $< ${DBOOK_XSL_CUSTOM}/slide/xsl/slideHdm.xsl ${dbookXslSlideParam} rsync -a --exclude .git /usr/share/reveal.js . - cd reveal.js; patch -p1 < ${DBOOK_XSL_CUSTOM}/slide/reveal.css.patch + #cd reveal.js; patch -p1 < ${DBOOK_XSL_CUSTOM}/slide/patch/reveal.css.patch + rsync -a ${DBOOK_XSL_CUSTOM}/slide/slideAssets . touch $*.slide %.present: %.slide.xml