OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

office-accessibility message

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]


Subject: Fw: intra-document hyperlink



I will attach Ishihara-san's investigation on the intra-document link issue.

Malte,
Is there any documentation for the rule of fragment identifier in OpenOffice.org?

---------------------
Hironobu Takagi, PhD.
User Experience and Accessibility Technology
Tokyo Research Laboratory, IBM Research
+81-46-215-4557
E-mail: takagih@jp.ibm.com


----- Forwarded by Hironobu Takagi/Japan/IBM on 2007/04/24 10:49 -----
---
Tatsuya Ishihara
IBM Tokyo Research Laboratory (Mail Code: LAB-S77)
E-mail : tisihara@jp.ibm.com
Tel: +81-46(215)4978     Fax: +81-46(274)4282


-----
Summary
------------------

Current ODF documents have an interoperability issue for hyperlink which refers to ODF elements within same document (intra-document links).
This issue is caused by two reasons.

1. URI syntax of intra-document link is not defined in ODF spec.

2. In OpenOffice, a URI of intra-document link to a heading element involves text content of the heading element.
        e.g. "#5. Introduction|outline"
       denotes "5th heading in this document, and the text contents is 'Introduction' "

  This implementation will cause interoperability issues, since this type of use of fragment identifier (notation after # in URI) is not popular among office editors and browsers.  

Intra-document link is important for improving accessibility of documents, since it allows users to jump to intended part of document directly. (e.g. table of contents)
We propose to define syntax of intra-document links ("fragment" part in URI) in the ODF spec, in order to point unique ODF element without ambiguity.


Detail
------------------

There is a interoperability problem that implementation of hyperlink for headings or graphics within same document is different in office applications.

Blind users access documents by using screen readers. They move cursor by keyboard command and reads the line where cursor is located.
To find out what they need in the text document, they have to move through the cursor
and read the contents from the top of the documents. If intra-document links are inserted, screen readers can skip the contents and jump to intended part of document.
This function is often used in "Table of Contents" function. So hyperlinks within same document is necessary to improve accessibility.


This is an example file created by OpenOffice.org v2.2.


Hyperlink URI is shown by moving the mouse pointer over text link.
An example of hyperlink URI for heading area is like this.

"#5.Introduction|outline"

It means that "5th heading in this document, and the text contents is 'Introduction' ".

This URI is ambiguous. If a heading with same text content is inserted before the heading referred by this hyperlink,
this hyperlink refer to the new heading.

The URI should point one ODF element clearly, and ODF should define this specification for
ensuring the interoperability.

In ODF 1.1 specification, URI of hyperlink is defined by "xlink:href" attribute of <text:a> element.
ODF 1.1 defines hyperlink URI as follows.

-----------------------
ODF 1.1 page 91
Link Location
The xlink:href attribute specifies the URL for the target location of the link.
-----------------------

Current XLink specification is here.
http://www.w3.org/TR/xlink/

"xlink:href" attribute in XLink specification is defined as follows.
This attribute should have URI value.

-------------------------------
5.4 Locator Attribute (href)
The value of the href attribute must be a URI reference as defined in [IETF RFC 2396], or must result in a URI reference
after the escaping procedure described below is applied. The procedure is applied when passing the URI reference to a URI resolver.
-------------------------------

RFC 2396 is obsoleted by latest URI specification.
Latest specification of URI (RFC 3986) is here.
http://www.ietf.org/rfc/rfc3986.txt

URI specification says that the subset of resource is specified by "fragment".
"fragment" and "same-document reference" is defined as follows.
It says that fragment's format is dependent on each media type.

---------------------------
3.5.  Fragment

 Fragment identifier semantics are independent of the URI scheme and
thus cannot be redefined by scheme specifications. Individual media
types may define their own restrictions on or structures within the
fragment identifier syntax for specifying different types of subsets,
views, or external references that are identifiable as secondary resources by that media type.

4.4.  Same-Document Reference

  When a URI reference refers to a URI that is, aside from its fragment
  component (if any), identical to the base URI (Section 5.1), that
  reference is called a "same-document" reference.  The most frequent
  examples of same-document references are relative references that are
  empty or include only the number sign ("#") separator followed by a
  fragment identifier.

---------------------------

So ODF should define syntax of hyperlink URI for same document area.

ODF specification has id functions like "draw:name", or "text:name".
We had better use these attribute for this purpose.

----------------------------
OpenOffice 2.2 implementation

<text:a xlink:href=""#5.Introduction|outline">jump" to title</text:a>
....
<text:h>Introduction</text:h>

<text:a xlink:href=""#graphics1|graphics">jump" to image</text:a>
...
<draw:frame draw:style-name="fr1" draw:name="graphics1" text:anchor-type="paragraph" svg:x="0.268cm" svg:y="0.721cm" svg:width="3.394cm" svg:height="2.545cm" draw:z-index="0">
  <draw:image xlink:href=""Pictures/1000000000000A6B000007D0BBB2CD79.jpg"" xlink:type="simple" xlink:show="embed" xlink:actuate="onLoad"/>
</draw:frame>
----------------------------

----------------------------
Proposal

<text:a xlink:href=""#heading1">jump" to title</text:a>
....
<text:h text:name="heading1">Title Contents</text:h>

<text:a xlink:href=""#graphics1">jump" to image</text:a>
....
<draw:frame draw:style-name="fr1" draw:name="graphics1" text:anchor-type="paragraph" svg:x="0.268cm" svg:y="0.721cm" svg:width="3.394cm" svg:height="2.545cm" draw:z-index="0">
  <draw:image xlink:href=""Pictures/1000000000000A6B000007D0BBB2CD79.jpg"" xlink:type="simple" xlink:show="embed" xlink:actuate="onLoad"/>
</draw:frame>
----------------------------

HeadingLinkOOo.odt



[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]