W3C

Standard slides for the SVG Slidemaker

$Date: 2002/02/20 13:46:30 $

This version:
http://www.w3.org/2001/svgSlidemaker/Docs/
Code and documentation download:
Available for download as a gzipped tar file. The documentation is part of the package in the Docs directory.
Author:
Ivan Herman <ivan@w3.org>.

Table of contents

  1. Introduction
  2. Standard slide content

Introduction

This document describe the format for the standard slide format (SDS), used by the svgSlidemaker tool. For details on how to use the svg slidemaker tool, the reader should refer to its documentation.

Note: although the documentation below uses an XML Schema formalism, correctness of the schema definition in the text has some time been sacrificed for a better readability of the documentation. The distribution contains the proper XML Schema files.

Standard slide content

Because a large percentage of presentation slides consist of a list of text items only (bulleted or not), a separate XML application has been defined to create such slides. Such "standard" slides may also include an image, positioned to the left, right, top, or bottom, with the textual content filling the other "half". The svgSlidemaker tool recognizes those files, and incorporates them into the final slide set. For the sake of this documentation, we will refer to this XML application as "SDS". (If the reader uses a schema-aware editor, the application has been defined with its own XML Schema with a detailed online documentation.)

The (simplified) schema definition for the top level slide element of SDS is:

<xsd:element name="slide" type="slideType>
<xsd:complexType name="slideType">
  <xsd:element name="img" minOccurs="0" type="imgType"/>
  <xsd:choice maxOccurs="unbounded">
    <xsd:element name="li-1">
    <xsd:element name="li-2">
    <xsd:element name="li-3">
    <xsd:element name="p">
    <xsd:element name="dt">
    <xsd:element name="dd">      
  </xsd:choice>
  <xsd:attribute name="space" use="optional" default="preserve"/>
</xsd:complexType>

Attribute:

space = "preserve"
is equivalent to the xml:preserve attribute and its usage in SVG.

Textual content

The three li elements have an identical structure, they represent three different level of indentation in the text:

<xsd:element name="li-1" mixed="true">
  <xsd:choice maxOccurs="unbounded">
    <xsd:element name="em">
    <xsd:element name="code">
    <xsd:element name="span">
    <xsd:element name="a">
  </xsd:choice>
  <xsd:attribute name="href" use="optional" type="xsd:anyURI"/>
  <xsd:attribute name="cont" use="optional" type="xsd:boolean"/>
</xsd:element>

Attributes:

href="<URI>"
the line becomes an active link referring to the value of the attribute as a target
cont="true|false"
by default, these lines are preceded by a bullet; if the value of the attribute is true, the bullet is omitted. Default value is false.

The elements p, dl, dt have an identical structure to the li-s, except that they don't use the cont attribute. p is used to display a line, the dt and dd have an identical usage as in XHTML.

The em and code elements can enclose a text, typically used for emphasis and code; more generally, the span can be used with a class attribute to assigned a specific class to the enclosed text.

The a can enclose any text to turn the latter into a hyperlink. It uses the href attribute (with a URI value). This element can be used when only a portion of the text should be an active link, instead of the whole item.

svgSlidemaker converts a SDS file into an SVG file, which is then treated similarly to all other SVG files. Some features of this conversion are worth noting:

Here is a simple example for a SDS file:

<slide>
  <li-1>Contact W3C through the Web</li-1>
  <li-2>You can also try the phone but people travel <em>a lot</em></li-2>
  <li-2 cont="true">so you might not find them this way...</li-2>
  <dt>More information about W3C:</dt>
  <dd href="http://www.w3.org/Consortium/">http://www.w3.org/Consortium/</dd>
  <dt>Local W3C offices:</dt>
  <dd href="http://www.w3.org/Consortium/Offices/">http://www.w3.org/Consortium/Offices/</dd>
  <dt>W3C home page:</dt>
  <dd href="http://www.w3.org">http://www.w3.org</dd>
</slide>

Image inclusion

A very frequent, albeit simple pattern for slides is to have one image taking roughly half of the slide, with the text covering the rest. The SDS format also includes this possibility through the img element. The definition is as follows:

<xsd:element name="img" type="imgType">
<xsd:complexType name="imgType">
  <xsd:attribute name="href" type="xsd:anyURI" use="required"/>
  <xsd:attribute name="height" type="xsd:double" use="optional"/>
  <xsd:attribute name="width" type="xsd:double" use="optional"/>
  <xsd:attribute name="offset" type="xsd:double" use="optional"/>
  <xsd:attribute name="position" use="optional">
</xsd:complexType>

Attribute:

href="<URI>"
Reference to the image. If the image refers to an svg file (has the suffix .svg), the content of the svg file will be copied into the target file; otherwise, an image element will be generated.
position="top|bottom|left|right"
Position of the image. The text will occupy the other "half" of the slide. If this attribute is missing, the text will be put on top of the image.
height
width
offset
These attributes control the position and size of the image; the exact semantics depends on the value of the position attribute:
position="top|bottom"
The height attribute determines the height of the image and its presence is required. The width is used to set the width of the image; if it is missing, the full slide width is used. offset sets a translation in horizontal direction (from left to right).
position="left|right"
The width attribute determines the width of the image and its presence is required. The height is used to set the height of the image; if it is missing, the full slide height is used. offset sets a translation in vertical direction (downwards).

The reason for svg image content being copied (instead of referred to) into the generated svg file is that the result becomes "self-contained", if published, whereas a reference in the slide would add a dependency on the referred image.