RE: Ruby annotation

I did consider this option but using visual design to create the rubies is not a perfect solution. 

 

Rubies can move around when the text layout changes. For example, consider a one line of text that is presented in a window and the last word has a ruby above it. If the window changes shape and needs to be re-rendered, but this time wrapping the text into a two line subtitle, the ruby will need to go under the last word of the second line. Other rules apply when changing horizontal text to vertical.

 

Applying the ruby positioning logic by inferring a ruby is a ruby by font-size and position is not possible.

 

Including both is possible like you have shown, although we will need to add in the <ruby> span a reference to the <p> element that it should substitute.

 

We will wait to the next version.   

 

 

Gur S.

 

From: Sean Hayes [mailto:Sean.Hayes@microsoft.com] 
Sent: Wednesday, July 01, 2009 16:09
To: Gur Shlapobersky; Glenn Adams
Cc: public-tt@w3.org
Subject: RE: Ruby annotation

 

The TTWG recognises the importance of Ruby as well as horizontal-in-vertical text and other formatting issues for Asian scripts. We did debate adding direct support for Ruby on a number of occasions, but in the end we took the view that the visual effect of Ruby could be simulated using the existing features of Timed Text, and the semantics could be incorporated using a foreign namespace, thus we decided to not add Ruby markup in a timed text namespace.

 

As Glenn points out, one can include W3C ruby markup in a foreign namespace, but a standard dfxp renderer would not do anything with it. To achieve the semantic notation, and also have the rendering, one could write something like the following:

 

<?xml version="1.0" encoding="utf-8" ?>

<tt xml:lang="en" xmlns="http://www.w3.org/2006/10/ttaf1" xmlns:tts="http://www.w3.org/2006/10/ttaf1#style" xmlns:ttm="http://www.w3.org/2006/10/ttaf1#metadata">

  <head>

    <metadata>

      <ttm:title>Ruby Test</ttm:title>

      <ttm:desc>Example of how to apply ruby</ttm:desc>

      <ttm:copyright>Copyright (C) 2007 W3C (MIT, ERIM, Keio). All Rights Reserved.</ttm:copyright>

    </metadata>

    <styling>

      <style xml:id="base" tts:color="yellow" tts:fontSize="14px" tts:fontFamily="MS Gothic" tts:textAlign="center" />

      <style xml:id="textStyle" style="base" tts:fontSize="32px" />

      <style xml:id="rubyStyle" style="base" tts:fontSize="18px" />

    </styling>

    <layout>

      <region xml:id="r1">

        <style tts:origin="0px 30px" />

        <style tts:extent="440px 32px" />

        <style tts:zIndex="1" />

      </region>

      <region xml:id="r2">

        <style tts:origin="80px 12px" />

        <style tts:extent="60px 22px" />

        <style tts:zIndex="1" />

      </region>

    </layout>

  </head>

  <body >

     <div>

      <p region="r2" style="rubyStyle">また</p>

      <p region="r1" style="textStyle">頭を<span>

        <ruby xmlns="http://www.w3.org/TR/ruby">

          <rb>また</rb>

          <rt>股</rt>

        </ruby>

      </span>股に突つ込んで祈るわ</p>

    </div>

  </body>

</tt>

 

Which should produce something like:

 

 

This approach does have its limitations, and so if Timed Text starts to see a lot of adoption for Asian scripts, then this may well be something we will revisit should we be chartered to look at a version 2.

 

Sean Hayes

From: public-tt-request@w3.org [mailto:public-tt-request@w3.org] On Behalf Of Gur Shlapobersky
Sent: 01 July 2009 4:56 PM
To: Glenn Adams
Cc: public-tt@w3.org
Subject: RE: Ruby annotation

 

Thanks for the explanation. 

Yes, I would like the TTWG to consider adding ruby annotation to the standard. The need for ruby annotations is common in Japanese subtitles and other languages.  

 

Sincerely,

 

Gur S.

 

From: Glenn Adams [mailto:gadams@xfsi.com] 
Sent: Wednesday, July 01, 2009 02:00
To: Gur Shlapobersky
Cc: public-tt@w3.org
Subject: Re: Ruby annotation

 

 

Assuming for a moment (without checking) that you are using the W3C ruby vocabulary as defined by the W3C ruby specification, then, since DFXP permits the arbitrary use of elements and attributes in foreign (i.e., non TT) namespaces, this is certainly legitimate. However, a compliant DFXP processor should be expected to ignore such foreign vocabulary unless the author includes a required extension designator in a profile element, where that extension designator would mandate semantic support for the foreign vocabulary (in this case, the W3C ruby vocabulary).

 

For example, one might have the following:

 

<tt xmlns="http://www.w3.org/2006/10/ttaf1" >

<head>

<profile ttp:xmlns="http://www.w3.org/2006/10/ttaf1" use="dfxp-presentation">

<!-- require support for a "ruby" extension as defined by the following third party -->

<extensions xml:base="http://www.example.org/ttaf1/extension/">

<extension>#ruby</extension>

</extensions>

</profile>

...

</head>

<body>

<div>

<p>

<ruby xmlns="http://www.w3.org/TR/ruby">

...

</ruby>

</p>

</div>

</body>

</tt>

 

Note well that all extension designations are 3rd party defined and interpreted, and there are no standard extension designations defined (yet) by the TTWG for use with DFXP. Consequently, such a use of ruby is effectively a private extension between two third parties, the author and the processor.

 

While it is possible that the TTWG could define some standard designations for such extensions, we have had no requests to do so. Is that what you are requesting here?

 

Regards,

Glenn

 

On Wed, Jul 1, 2009 at 2:55 AM, Gur Shlapobersky <Gur@captionsinc.com> wrote:

Is this the proper syntax for ruby annotation as part of a <p> element? 

Should the TT Full profile assume support for ruby annotation?   

 

<p>

  <rub:ruby xmlns:rub="http://www.w3.org/TR/ruby">

    <rub:rb>WWW</rub:rb>

      <rub:rt>World Wide Web</rub:rt>

  </rub:ruby>  

</p>

 

* http://www.w3.org/TR/ruby/


 

Thanks,

 

Gur Shlapobersky

Software Development Manager

 

Captions, Inc.

640 South Glenwood Place.

Burbank, CA 91506

818.260.2722

www.captionsinc.com

 

 

Received on Thursday, 2 July 2009 06:14:51 UTC