Mobile SVG Profiles: SVG Tiny and SVG Basic

W3C Working Draft 30 October 2001

This version:
Latest version:
Tolga Capin (Nokia) <Tolga.Capin@nokia.com>


This document defines two mobile profiles of SVG. The first profile, SVG Tiny, is defined to be suitable for cellphones and low-end PDAs; and the second profile, SVG Basic, is suitable for PDAs.

Status of this document

This document is the first public draft version of the mobile profiles of SVG 1.1.

It is possible to use this document as a basis for implementation. However, no guarantee is given of stability, and the SVG Working Group will not use the existance of implementations conforming to this draft as a reason for not changing future drafts.

This document has been produced by the W3C SVG Working Group as part of the Graphics Activity within the W3C Document Formats Domain. The goals of the W3C SVG Working Group are discussed in the W3C SVG Charter (W3C members only). The W3C SVG Working Group has maintained a public Web page http://www.w3.org/Graphics/SVG/ which contains further background information. The authors of this document are the SVG Working Group members.

We explicitly invite comments on this document. Please send them to svg-comments@w3.org. Public discussion of issues related to vector graphics on the Web and SVG in particular takes place on the public mailing list of the SVG Working Group (list archives). To subscribe send an email to www-svg-request@w3.org with the word subscribe in the subject line.

A list of current W3C Recommendations and other technical documents can be found at http://www.w3.org/TR/. W3C publications may be updated, replaced, or obsoleted by other documents at any time. In particular it is inappropriate to use W3C Working Drafts as reference material or to cite them as other than work in progress.

Table of contents

1. Introduction

There is one area that has been identified as lacking in the SVG 1.0 Specification. It has been established by industry demand, overwhelming support in the SVG working group and requests from the SVG developer community that some form of SVG suited to displaying vector graphics on small devices is required. Moreover, the mission statement of SVG 1.0 specifically addresses small devices as a target area for vector graphics display. In order to meet these demands the SVG Working Group has committed to a concerted effort to create a profile specification that addresses mobile devices.

A single profile is not sufficient to deal with the variety of mobile devices, because each mobile device has different characteristics in terms of CPU speed, memory size, and color support. To address different device families, two profiles are defined. The first low-level profile, SVG Tiny (SVGT) is suitable for highly restricted mobile devices; while the second profile, SVG Basic (SVGB) is targeted for higher level mobile devices.

Because of the low memory, low CPU power and limited display of mobile devices, Mobile SVG profiles introduce constraints on content, attribute types, properties, and user agent behaviour. This section describes these constraints and design rationale behind them.

  1. Two profiles are designed to allow SVG to render on mobile devices with limited memory, CPU power, and bandwidth.
  2. Mobile SVG profiles attempt to maximize compatibility with SVG 1.0 to display existing content.
  3. A true subset of the SVG 1.0 imaging model is maintained.
  4. Mobile SVG is designed to facilitate authoring tools.
  5. Mobile SVG is designed so that SVG 1.1 can be transcoded into SVGB and SVGT preserving as much scalability as possible.

2. Overview of Mobile SVG

SVGT and SVGB consist of the following SVG 1.1 modules:

SVG Tiny

Tiny Structure Module
desc, title, metadata, svg, g, defs
Image Module
Conditional Processing Module
Hyperlinking Module
Shape Module
rect, circle, line, ellipse, polyline, polygon, path
Tiny Text Module
Tiny Animation Module
animate, set, animateMotion, animateTransform, animateColor
Tiny Font Module
font, fontface, glyph, missing-glyph, hkern, vkern
Presentation attribute modules:
Tiny Paint Attribute Module
Tiny Graphics Attribute Module
Tiny Font Attribute Module

SVG Basic

Structure Module
desc, title, metadata, svg, g, defs, use, symbol
Container Attribute Module
'enable-background' attribute
Viewport Attribute Module
'clip','overflow' attributes
Image Module
Image Attribute Module
'color-profile' attribute
Conditional Processing Module
Hyperlinking Module
Style Module
Shape Module
rect, circle, line, ellipse, polyline, polygon, path
Basic Text Module
text, tspan, tref, textPath
Animation Module
animate, set, animateMotion, animateTransform, animateColor, mpath
Font Module
font, fontface, glyph, missing-glyph, hkern, vkern
Extensibility Module
Script Module
Clip Module
Basic Mask Module
Gradient Module
linearGradient, radialGradient, stop
Pattern Module
View Module
Presentation attribute modules:
Text Attribute Module
Filter Attribute Module
Filter Interpolation Attribute Module
FeFlood Attribute Module
FeLighting Attribute Module
Paint Attribute Module
Opacity Attribute Module
Graphics Attribute Module
Font Attribute Module
Clip Attribute Module
Mask Attribute Module
Gradient Attribute Module
Color Attribute Module

3. Data Types

Data Type Description
Number SVGT and SVGB content may contain numbers as defined in SVG1.1, but Mobile SVG implementations are only required to represent numbers by 15.16 fixed point values internally. Scientific notation is not supported.
Length SVGT only supports user units (i.e., CSS units are not supported), with the one exception that the 'width' and 'height' attributes on the outermost 'svg' element can specify values in any of the following CSS units: in, cm, mm, pt, pc, and %. SVGB supports lengths in user coordinate space and in CSS units.
Coordinate SVGT and SVGB support the coordinate data type, represented with a <length> value.
List of XXX (where XXX represents a value of some type): SVGT and SVGB support the list specification.
Angle SVGT only supports angles if specified with no CSS unit identifiers (which means all angles are in degrees). SVGB supports angles with CSS unit identifiers.
Color SVGT and SVGB support <color> in the CSS2-compatible specification for a color in the sRGB color space, and system colors. Additionally, SVGB supports 16 original color keywords from XHTML.
Paint SVGB supports paint specification for fill and stroke operations, as well as linear and radial gradients. SVGT does not support the more general notion of paint specification and thus only supports solid color fills and strokes.
Percentage SVGB supports percentages. SVGT does not support percentage values except for the 'width' and 'height' attributes on the outermost 'svg' element.
Transform List SVGB and SVGT support transform lists.
URI SVGB and SVGT support the URI datatype.
Frequency SVGB and SVGT do not support frequency values.
Time SVGB and SVGT support time values, with unit identifiers (ms, s).;

4. Document Structure

Mobile SVG Document Fragment

SVGB and SVGT content can be in the form of stand-alone SVG Documents or document fragments embedded within a parent XML document. The following is an example of an SVG document fragment embedded within an XHTML Basic document:

	<?xml version="1.0"?>
	<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML Basic 1.0//EN"
	<html xmlns = "http://www.w3.org/1999/xhtml"
	An example XHTML Basic document
	<link type="text/css" rel="stylesheet" href="mystyle.css" />
	<svg:svg version="1.1" profile="tiny" width="4cm" height="8cm" 
                    viewBox="0 0 4 8">
	<svg:ellipse cx="2" cy="4" rx="2" ry="1" />

The 'title', 'desc', 'metadata' Elements

SVGB and SVGT support the 'title', 'desc' and 'metadata' elements as defined in SVG 1.1.

The 'svg' Element

Attributes of 'svg' elements that appear in the middle of SVGT content cannot be specified in CSS unit identifiers.

The 'profile' attribute on the outermost 'svg' element must have the value "tiny" for SVG Tiny content, and "basic" for SVG Basic content. The 'profile' attribute on nested child 'svg' elements is ignored. The SVG 1.1 specification states that the 'version' attribute of the outermost 'svg' element in SVG 1.1 content must have the value "1.1".

References and the 'defs' Element

SVGB and SVGT support hyperlinking targets using the 'a' element.

For SVGT and SVGB, all referenced objects, except hyperlinking through the 'a' element, must be internal. URI references may be in either of the two XPointer forms (i.e., #<elementID> and #xpointer(id(<elementID>).

In SVGB, for images and fonts, embedding can be accomplished using the data: protocol and base64 encoding. SVGT supports base64 encoding only.

The 'symbol' Element

In SVGB and SVGT, symbols cannot define a new viewport, thus 'viewBox' and 'preserveAspectRatio' are not used.

The 'use' Element

In SVGB and SVGT, animations on a referenced element will not cause the instance to be animated.

The 'image' Element

SVGB allows the JPEG, PNG and WBMP raster formats and the SVG format on the image element. SVGT supports only WBMP as the raster format.

The 'switch' Element

The following feature set is used:

5. Styling

SVGB and SVGT support subsets of SVG 1.1's presentation attributes. SVGB and SVGT allow optional support of a subset of CSS attribute selectors.

SVGB and SVGT introduce constraints on style properties. Allowed values for style properties are listed in Appendix C.

SVGB and SVGT support the 'class' attribute to refer to styles defined within the <defs> element. Specifying multiple classes within the same 'class' attribute is supported.

6. Coordinate Systems, Transformations and Units

SVGB and SVGT support SVG 1.1's notion of viewports.

SVGB and SVGT support nesting of transformations. The types of transformations that are allowed are generic transformation matrices, or simple operations such as rotation, scaling, skewing, and translation.

The 'transform' Attribute

SVGB and SVGT support the transform attribute. The following transform definition types are supported:

The 'viewBox' Attribute

SVGB and SVGT support the 'viewBox' attribute.

The 'preserveAspectRatio' Attribute

SVGB and SVGT support the 'preserveAspectRatio' attribute for adapting the content to terminals with different display aspect ratios.

In SVGT,  the <align> parameter can only be either 'none' or 'XMidYMid', the <meetOrSlice> parameter can be 'meet'.

In SVGB, the values of this parameter can be the same as in SVG 1.1.

Establishing a New Viewport

SVGB and SVGT support establishing a new viewport via additional embedded 'svg' elements.


SVGT supports user units only, except for the 'width' and 'height' attributes on the outermost 'svg' element. SVGB supports user units and CSS user identifiers.

Object Bounding Box Units

SVGB and SVGT do not support bounding box unit specification.

7. Shapes


The path element data is animatable, as defined in SVG 1.1 specification. Path data animation is only possible when each path data specification within an animation specification has exactly the same list of path data commands as the d attribute.

SVGB and SVGT support:

SVGB and SVGT do not support the elliptical arc curve command ("A"(absolute) and "a"(relative)).

Basic Shapes

SVGT and SVGB support the basic shapes (rectangles, circles, ellipses, lines, polylines, and polygons) as defined in SVG1.1.

8. Text

SVGB and SVGT support representing text with Unicode characters. Mobile SVG user agents are not required to allow text selection and clipboard operations.

SVGT supports only the 'text' element, and does not support text on a path, 'tspan' and 'tref', and 'altGlyph' elements. SVGB does not support 'altGylph'.

9. Painting: Filling, Stroking and Marker Symbols

SVGB and SVGT support filling and stroking 'path' elements and basic shapes with solid colors.

SVGB supports stroked text for terminal fonts, but SVGT does not.

10. Color

SVGB and SVGT support colors defined by 'color' property in sRGB color space and color keywords. Specifying colors using an ICC profile is not supported.

SVGB supports solid colors and gradient paints, patterns and custom paints. SVGT only supports solid color painting.

11. Gradients and Patterns

SVGB supports a subset of gradients and does not support patterns. SVGT supports neither gradients nor patterns.

12. Clipping, Masking and Compositing

SVGB supports clipping, masking and compositing. SVGB does not support additive clipping paths.

SVGT does not support clipping, masking, group opacity or alpha compositing into the parent.

13. Filter Effects

SVGB supports a subset of filter effects. SVGT does not support filter effects.

14. Interactivity

SVGB and SVGT support a subset of the SVG 1.1 interactivity feature set. The subset will be defined in the next working draft.

15. Linking

SVGB and SVGT support hyperlink activation from SVG content to other Web resources through the 'a' element.

SVGB supports hyperlink into particular views of SVG content. SVGT does not support this feature.

16. Scripting

SVGB includes all of the language features from SVG 1.1 to support scripting. SVGB allows optional support of the EcmaScript, WMLScript languages.

SVGT does not support scripting.

17. Animation

Both SVGB and SVGT support subset of SVG 1.1's declarative animation features. The language features to support animation through scripting and DOM are available in SVGB but not SVGT.

SVGB and SVGT allow targeting only those elements, which belong to the same SVG Document fragment, through 'xlink:href' attribute.

SVGB supports linear, spline, paced and discrete animations. SVGT only supports linear, paced and discrete animations.

The timing of animations must be defined in seconds or milliseconds, and be specified with the unit identifiers.

18. Fonts

SVGB and SVGT support a subset of SVG fonts where only the 'd' attribute on the 'glyph' element is available. Arbitrary SVG within a 'glyph' is not supported.

19. Metadata

Both SVGB and SVGT support embedded metadata.

SVGB and SVGT allow inclusion of elements and attributes from foreign namespaces within the SVG content.

20. Extensibility

SVGB allows inclusion of elements and attributes from foreign namespaces within the SVG content. SVGT is not expected to be able to process namespace declarations.



[MOBILE SVG Requirements]
SVG Mobile Requirements Rick Graham, Tolga K. Capin, editors, W3C, 3 August 2001 (Working Draft) See http://www.w3.org/TR/SVGMobileReqs
Multimedia systems and equipment - Colour measurement and management - Part 2-1: Colour management - Default RGB colour space - sRGB. See http://www.iec.ch/nr1899.htm
[SVG 1.0]
Scalable Vector Graphics (SVG) 1.0 Specification, Jon Ferraiolo, editor, W3C, 19 July 2001 (Proposed Recommendation). See http://www.w3.org/TR/2001/PR-SVG-20010719/
[SVG 1.1/2.0 Requirements]
SVG 1.1/2.0 Requirements Document, Dean Jackson, editor, W3C, 3 August 2001. See http://www.w3.org/TR/SVG2Reqs
[SVG 1.1]
Scalable Vector Graphics (SVG) Version 1.1 Working Draft, Dean Jackson, editor, W3C, 30 October 2001. See http://www.w3.org/TR/2001/WD-SVG11-20011030/

Author List

The authors of this specification are the members of the W3C SVG Working Group, whose members are listed:

Appendix A. Element Index

The next Working Draft will include list of elements in SVGB and SVGT.

Appendix B. Attribute Index

The next Working Draft will include the list of attributes in SVGB and SVGT, with limitations on allowed values.

Appendix C. Style Property Index

The next Working Draft will include the list of style properties in SVGB and SVGT, with limitations on allowed values.

Appendix D. Issues Under Consideration

Coordinate Reference Systems for Location Based Applications

In order to allow interoperability between SVG content generators and user agents dealing with maps, the SVG Working Group encourages the use of a common metadata definition to describe an SVG file that is a map. The next working draft will describe in more detail how these metadata should be used in the SVG content and how they will allow to describe the Coordinate Reference System used for the coordinates in the SVG file.

Limited Clipping Path Support in SVGT

The SVG Working Group is investigating the extra requirements of supporting a subset of clipping paths of SVGT. If the extra overhead, in terms of UA size, computational complexity, and memory usage, proves small, the SVG Working Group will consider supporting a subset of clipping paths.

'stroke-width' Support in SVGT

Supporting stroke-width requires additional features than supporting hairwidth lines. Line joins and line caps may require additional computational resources. Additionally, converting stroke of a shape to a path would substantially increase computational overhead for stroking. The next version of this working draft will address this issue.

Subsetting of System Color Support in SVGT

Some of the system colors, as defined in SVG 1.1, are not applicable to mobile SVG. In order to decrease memory requirements, the SVG Working Group will consider defining a subset of system colors for SVGT.

Appendix E. XML Schema

The next draft of this document will contain normative XML Schemas for SVG Basic and SVG Tiny.

Appendix F. DTD

The next draft of this document will contain non-normative DTDs for SVG Basic and SVG Tiny.