Movatterモバイル変換


[0]ホーム

URL:


Up to cover page |Back to Application configuration

WebCGM 2.1 — Appendixes


Contents


A.Acknowledgements


In addition to thelisted editors ofthis specification, the following individuals have contributed significantly tothe present WebCGM 2.1 specification:

Additionally, the following individuals made signficant contributions topredecessor versions, WebCGM 2.0 and WebCGM 1.0:


B. What's new in WebCGM2.1


This section is informative (non-normative).

WebCGM 2.1 builds uponWebCGM2.0 and adds these new features:

  1. Geometric transform definition and inquiry for objects is defined viaDOM facilities.
  2. getStyleProperty() inquiry method added to DOMWebCGMPicture interface andWebCGMAppStructure interface.
  3. A number ofnew Style Properties are added to the list of those settable via thesetStyleProperty() method.
  4. Application configurable items are added, to improve predictability of WebCGM viewing: font mapping; defaults setting.
  5. G-zip compression of whole metafiles.
  6. NewsetRedraw() method onWebCGMMetafile interface allows postponement / control of when redraws happen.
  7. NewsetView() method andcreateWebCGMRect() convenience method onWebCGMPicture interface enable the picture view to be defined via the DOM.
  8. NewgetObjectExtent() method on theWebCGMAppStructure interface facilitates getting the bounding extent of one or more objects, for example to use with new setView()

In addition, the WebCGM 2.1 makes these clarifications and other changes toWebCGM 2.0:

  1. Transparency clarifications, detailing how the various WebCGM 2.0 transparency facilities interact.
  2. A number of 2.0-deprecated items were madeobsolete for 2.1.
  3. IncreasedProfile limits: the number of octets allowed in datatype SF; and number of dash-gap elements in Line and Edge Type Definition (to 64).

A complete listing of all text changes since WebCGM 2.0 can be found in the"Change log" section.

Note: Throughout the previous published versions of this specification (20080917 and20090130), the newfeatures that WebCGM 2.1 added to WebCGM 2.0 were highlighted. In this version,only the differences from the previous Last Call Working Draft (20080917) arehighlighted, in a style similar to the item #11 above.


C. Glossary


API, Application Programming Interface
An Application Programming Interface (API) is a set of functions or methods used to access some functionality.
Application Structure, APS
The CGM structure for grouping other elements and assigning them a unique identifier, a type, and attaching attributes. WebCGM contains five valid APS types: grobject, layer, para, subpara, grnode.
APS Attribute, Application Structure Attribute
The CGM element that is used to define and associate an attribute with an APS. WebCGM contains ten valid APS Attribute types: region, viewcontext, linkuri, layername, layerdesc, screentip, name, content, visibility, interactivity.
Cascading profile
A method by which closely related profiles can be expressed efficiently, by only enumerating the differences between a given profile and a base profile such as WebCGM.
CGM, Computer Graphics Metafile
ISO/IEC standard 8632:1999 (CGM:1999), CGM is a metafile format consisting of composite raster and scalable vector graphics information.
DOM, Document Object Model
A Document Object Model is a platform- and language-neutral interface that allows programs and scripts to dynamically access and manipulate the content, structure and style of documents. WebCGM defines a DOM of limited scope, allowing discovery and navigation of the WebCGM structure tree, transient manipulation of styles and standardized metadata, and discovery and manipulation of application-specific metadata. The WebCGM DOM is based upon and borrows from the principles the W3C DOM Level 2 and DOM Level 3 Recommendations.
EBNF, Extended Bauer Normal Form
A formal specification technique used in WebCGM to express pieces of grammar and syntax such as the IRI fragment syntax.
fragment (IRI fragment)
As standardized in RFC 3986 and RFC 3987, the fragment is a part of a IRI that is separated from the path/file name by a "#" character, and provides information that is reserved for processing by agents that are invoked by the browser to handle the resource information type of the IRI. WebCGM standardizes the syntax and semantics of such fragments, for transmitting object and picture selection and behavior information to WebCGM viewers.
handler, event handler
An event handler is a method called by the WebCGM DOM implementation whenever a specified event occurs. Users register the event types they are interested in by calling the addEventListener() method of the WebCGMMetafile object.
host application
The user agent, typically is a script that controls the behavior of a web page. In the context of WebCGM the host application controls the behavior of the WebCGM renderer through the DOM.
host document
The web page, contains a combination of both HTML and WebCGM content.
host environment
The combination of the host application and the host document
inheritance
The determination of values of APS Attributes and Style Properties for objects in the WebCGM hierarchical object tree, when all aspects have not been explicitly specified for all objects in the tree. WebCGM defines an inheritance model that is closely based on CSS (Cascading Style Sheets, a W3C Recommendation).
interactive region
the effective geometric region for the purposes of all interactive cursor and mouse operations, such as picking and mouseover. By default, thedrawn graphical primitives of the object define the interactive region. For filled-area primitives this includes: the edge, if edge visibility is 'on'; the interior, if the interior style is other than 'empty' or 'hollow'; and, the boundary, for interior style 'hollow'. For all graphical primitive types,drawn graphical primitives exclude any that are fully transparent (so a fully transparent object is equivalent to an empty object, for purposes of interactive region definition). If the object contains a'region' APS Attribute, then that region area is the interactive region.
listener, event listener
The event listener specifies the interface via which users register event handlers with the WebCGM DOM implementation. This interface consists of a single method, handleEvent(), which the WebCGM DOM implementation calls whenever specified events occur. Users pass WebCGMEventListener objects as arguments to the addEventListener() method of the WebCGMMetafile object to register a specific event handler with the WebCGM DOM implementation.
locus
A general definition from the Oxford dictionary defineslocus as: "Curve formed by all points satisfying particular equation of relation between coordinates, or by point, line, or surface, moving according to mathematically defined conditions." In the WebCGM specification, locus refers to the set of points that comprise the path or shape of a Graphical Primitive element, or in the appropriate context, the combined shapes or paths collectively of all of the Graphical Primitive elements in an Application Structure (APS). I.e., the locus of an APS comprises the combined loci of all of the graphical primitives in the APS. Locus does not include defining data that are not part of the shape or path of the graphical primitive, such as control points of Bezier primitives, or the center point of a Circular Arc Center primitive.
metadata
Non graphical information contained within or associated with standard graphical files, in WebCGM metadata supports such ancilliary functions as hierarchical picture structuring, object identification and navigation, and association of application-specific non-graphical data with graphical objects.
metafile
A mechanism for retraining and transporting graphical data and control information, containing a device independent description of one or more pictures.
namespace, NS
A method devised and standardized by theXML Namespaces standard, namespace provides a way to distinguish to which specification and grammar elements and attributes belong, when information from distinct XML languages is mixed in the same document. WebCGM uses namespaces to separate standardized WebCGM XCF elements and attributes from embedded and intermingled application-specific metadata.
Normalized Device Coordinates, NVDC
The coordinate system that is used to communicate coordinate data through the WebCGM DOM, NVDC is VDC normalized so that the origin is lower-left and units are millimeters.
object
An Application Structure (grobject, para, subpara) or Picture in a WebCGM.
object behavior
One of a set of (thirteen) ways in which the view of an object or collection of objects is presented following the execution of a hyperlink to the object(s). WebCGM standardizes a number of objects that give complete control over the zoom, pan, and highlight aspects of the view.
picture behavior
One of a set of ways in which the view of a picture (CGM) or document (HTML) is handled following the execution of a hyperlink to the content. Based on the 'target' attribute of the HTML 'a' tag, picture behaviors allow the specification of the new view to occur in a new window, to overwrite the whole contents of the source window, to overwrite the parent window, etc.
PPF, Profile Proforma
A method of expressing profiles standardized in CGM:1999 (clause 9), the PPF presents a profile as a single table covering all aspects of the CGM standard, with a reference column (enumerating a Model Profile or other base profile), and a column to define the target profile by comparison to the reference column.
Style Property
A graphical attributes that may be applied and manipulated at the APS or picture level, transiently, by WebCGM DOM and WebCGM XCF. WebCGM 2.0 defines nine style properties.
target rectangle
A rectangular region around the target object(s) that is used for the application of object behaviors following hyperlink execution. The target region is defined by APS Attributes and/or target geometry, and for example provides the area to be encompassed by a zoomed view.
WDOM, WebCGM DOM
The WebCGM Document Object Model, this terminology is used when it is needed to unambiguously distinguish the WebCGM DOM from the generalized W3C DOM specifications.
XCF, XML Companion File
An XML file format defined by WebCGM, that can be used to externalize metadata from WebCGM instances and bind it to objects in the metafile.


D. Change log


This section is informative (non-normative).

Note: The following subsections document all significant changes appliedto the WebCGM 2.0 specification to derive this draft of the WebCGM 2.1specification.

D.1 Changes withinW3C since W3C Proposed Recommendation

This Recommendation includes the below editorialcorrections to theProposedRecommendation version.

D.2 Changes withinW3C and OASIS since WebCGM 2.0

A complete listing of all prior text changes since WebCGM 2.0 can be foundin thePRversion's "Change log" section.


E. WebCGMaccessibility


This section and its subsections are informative(non-normative).

E.1Introduction

Topics such as internationalization and accessibility have been addressed byW3C in other Recommendations available on theTechnical Reports page.  The relationshipbetween the specifications of technology modules, such as this one, and thosecross-cutting recommendations is discussed in theSpecificationGuidelines.  As suggested in the Specification Guidelines, this sectionidentifies some relationships between the capabilities afforded by WebCGMfeatures and accessibility requirements established by otherRecommendations.

Although a WebCGM metafile is a binary file format, it has systematicgrouping and annotation features that foster accessibility of WebCGM metafilecontent. For example, graphical text is ideally stored as Unicode text stringswithin the metafile, but to handle cases where graphical text images areactually the result of other vector (e.g. stroking) or raster (e.g., bitmaps)graphics in the metafile, WebCGM has the attribute 'content' on the para and subparaobjects, that gives the text-string equivalent of the rendered graphicaltext.

Features that are in the binary metafile itself will, unlike clear-textformats such as HTML, XML, and SVG, require the cooperation and intervention ofthe WebCGM authoring tools and viewers. As described in[Essential Components of WebAccessibility], several components such as authoring tools, media viewersand developers, have to work together to improve Web accessibility. Therefore,the discussions in the following sections are recommendations to contentdevelopers, and builders of authoring tools and viewers.

E.2Navigation

By Guideline 9 "Provide navigation mechanisms" of [UAAG10] a WebCGM viewer is expected tolet users interact with 'enabled' and significant objects in the image.'Enabled' objects are those which accept user input, such as on screen buttons.By the structure of WebCGM, each APS should be treated as a significant objectand be reachable by navigation techniques. By Guideline 1 "Support input andoutput device independence" the reach of keyboard-actuated navigation shouldcover this whole set of navigation destinations.

Some notion of forward and backward motion among peer nodes in the WebCGMimage should be provided. This should by default move among paragraphs andsub-paragraphs in the order in which they appear in the metafile. The creatorsof WebCGM instances should ensure that this results in a sensible readingorder. However, efficient motion as called for in [UAAG10]Checkpoint9.9, is not likely to result from one global list or loop of all theplausible navigation destinations. Exploiting the structure of the metafile,structured navigation could take hierarchical or categorical forms. Inhierarchical navigation, forward and back motion moves among peer nodes at thesame level in the layers-and-objects nesting tree. In categorical navigation,the sequential navigation could exhibit navigation modes which visit only'grobject' nodes, or only the 'gropbject' nodes with a common 'name.' Anexample of hierarchical navigation is provided by the player behavior for the[DAISY] standard digital talking book. An example of categorical structurednavigation is provided by the diverse navigation modes of the Opera browser.The creators of WebCGM instances should ensure that the layers-and-objectsnesting forms a plausible table of contents as annotated with the textualproperties (see E.3 below) of the affected nodes, and that collecting nodes oflike 'name' forms meaningful slices of what is in the scene.

In this version of WebCGM, there are no intra-metafile controls to alter thenavigation graph. In a scenario where such capability is desired, theprivate-namespace extension feature ofthe XCF can be used to introduce further intelligence associated with thecontents of the metafile proper.

E.3 Required text content

Web Content Accessibility Guidelines such as [WCAG10] require that essentialinformation be available in text form.  Some key examples are:

WebCGM contains attributes that associate text with things in the depictedscene, and can be used to meet these requirements.

This essential content, if not always presented to the user, must beconsidered 'conditional content' in the sense of [UAAG10],Checkpoint2.3.  That checkpoint gives some latitude to the viewer as to whether topresent these attributes globally through view-mode controls or locally inresponse to focus and inspect actions of the user.

WebCGM viewers should also make this textual information available to assistivetechnology through the accessibility API appropriate to the programmingplatform, following [UAAG10],Guideline6.

Note. It might be thought that the 'name' APS attribute could or shouldbe used in a manner like 'alt' on 'img' in HTML. This is not the design intentof the 'name' attribute. It has well-defined category, not instance, semanticsand associated categorical navigation behavior.

E.4Styling

WebCGM versions 2.0 and higher support transient, display-time control ofa number of display properties ofobjects. These can be manipulated via the WebCGM DOM, and are also availablevia the XCF mechanism. Although WebCGM does not supportconventional styling, an (external) XCF canfunction similarly to an external style sheet. For improved accessibility,WebCGM viewers should provide some user control of rendering. Use of thesemechanisms partially supports the recommendations of [WCAG10],Checkpoint 3.3 and[UAAG10],Guideline4.

E.5Visibility and navigation

By default, WebCGM viewers allow the user to navigate to and interact withonly enabled elements (i.e. element whose 'visibility' attribute is 'on').Objects which are not visible do not display tooltips (the 'screentip' APSattribute), may not be highlighted without making them visible, and may not benavigated to via the picture behaviors (whether in picture fragments or DOM srcparameter).

In addition, WebCGM viewers can offer a mode where, at user option, the 'visibility' attribute is ignored,for accessibility or debugging support. It meets a requirement of [UAAG10],CheckPoint9.3.


F. Regexsearch


This section is informative (non-normative).

The advanced example in this section shows how the functionality of theWebCGMAppStructure interface can be used tobuild useful convenience functions, in this case a function to search a WebCGMinstance for all APS that contain an APS Attribute of a given type, whose valuematches a given regular expression (regex).

EXAMPLE:

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"><html><head>  <meta http-equiv="content-type" content="text/html; charset=utf-8">  <title>WebCGM 2.0 regex example</title>  <script type="text/ecmascript">    var cgm;    var pic;    var mydiv;    var o;    var nl;     var res;    function loadCGM(fname) {      try {var obj = document.getElementById('image');obj.innerHTML = "<object id='cgm' type='image/cgm;Version=4;ProfileId=WebCGM' width='400' height='300' src='"+fname+"'>";document.getElementById('cgm').getWebCGMDocument().src = fname;cgm = document.getElementById('cgm').getWebCGMDocument();pic = cgm.firstPicture;mydiv = '<h2>Looking at file '+fname+'</h2>\n';mydiv += '<p>Enter an attribute and regular expression then click the Submit button.</p>\n';        mydiv += '<form name="myform">\n';          mydiv += '<select name="attr">\n';            mydiv += '<option value="content">content</option>\n';            mydiv += '<option value="interactivity">interactivity</option>\n';            mydiv += '<option value="layerdesc">layerdesc</option>\n';            mydiv += '<option value="layername">layername</option>\n';            mydiv += '<option value="linkuri">linkuri</option>\n';            mydiv += '<option value="name">name</option>\n';            mydiv += '<option value="region">region</option>\n';            mydiv += '<option value="screentip">screentip</option>\n';            mydiv += '<option value="viewcontext">viewcontext</option>\n';            mydiv += '<option value="visibility">visibility</option>\n';    mydiv += '</select>\n';  mydiv += '<input type="text" name="regex" size="20"></input>\n';  mydiv += '<input type="button" value="Submit"></input>\n';        mydiv += '</form>\n';var t =  document.getElementById('attinput');t.innerHTML = mydiv;      } catch (e) {        alert("loadCGM error " + e);      }    }     function processAttr(att, val) {      try {o = '<p>Searching APS for attribute '+att + ' containing '+val+'</p>\n';// Create a list of nodes and print out the attribute// This part is not really needed it is mostly here as // a sanity check.nl = listNodes(pic.firstChild);o+='<p>List of all nodes in the DOM tree.  A "" implies normally means the attribute was not specified.</p><ul>';for(i=0; i< nl.length; i++){  o+='<li>'+nl[i].apsId+' ('+att+'="'+nl[i].getAppStructureAttr(att)+'")</li>';}o+='</ul>';// Now we just run through the list and remove nodes that do not matchres = new Array();for(i=0; i<nl.length;i++) {  attVal = nl[i].getAppStructureAttr(att);  if(attVal.match(val)) {    res.push(nl[i]);  }}if( res.length < 1) {  o += '<p>No nodes found matching that regular expression</p>\n';} else {  o+= '<p>The following nodes match the regular expression</p><ul>';  for(i=0; i< res.length; i++){    o+='<li>'+res[i].apsId+' ('+att+'="'+res[i].getAppStructureAttr(att)+'")</li>';  }  o+='</ul>';}var t = document.getElementById('attout');t.innerHTML = o;      } catch(e) {alert("processAttr error " + e);      }     }// These are helper functions that I found on the web // http://www.ibm.com/developerworks/xml/library/x-matters41.html// // They are needed because you need to walk the tree to // create a list of all of the nodes in the tree.// return next node in document orderfunction nextNode(node) {    if (!node) return null;    if (node.firstChild){        return node.firstChild;    } else {        return nextWide(node);    }}// helper function for nextNode()function nextWide(node) {    if (!node) return null;    if (node.nextSibling) {        return node.nextSibling;    } else {        return nextWide(node.parentNode);    }}// return an WebCGMNodeList of all nodes, starting at startNode and// continuing through the rest of the DOM treefunction listNodes(startNode) {    var node = startNode;    var list = new Array();    while(node) {        list[list.length] =node;        node = nextNode(node);    }    return list;}  </script></head><body><h1>WebCGM 2.0 regex example</h1><table>  <tr>    <td>Select a CGM image...</td>  </tr></table><br><input size="60" type="file" name="cgmfile" onChange="loadCGM(this.value)"/><div></div><div></div></body></html>

Viewthis example as HTML-CGM (WebCGM-DOM-enabled browsers only.)


Back to top of Appendixes



[8]ページ先頭

©2009-2025 Movatter.jp