[prev in list] [next in list] [prev in thread] [next in thread] 

List:       batik-users
Subject:    dominant-baseline question
From:       "Michael Bierman" <mbier () yahoo ! com>
Date:       2002-05-19 6:41:07
[Download RAW message or body]

The 1.0 DTD reads:

dominant-baseline (auto | autosense-script | no-change | reset | ideographic
| lower | hanging | mathematical | inherit ) #IMPLIED

The 1.0 spec reads:
Value: auto | use-script | no-change | reset-size | alphabetic | hanging |
ideographic | mathematical | central | middle | text-after-edge |
text-before-edge | text-top | textbottom | inherit


The 1.1 DTD reads:
dominant-baseline (auto | autosense-script | no-change | reset | ideographic
| lower | hanging | mathematical | inherit ) #IMPLIED

1.1 spec reads:

Value: auto | use-script | no-change | reset-size | ideographic | alphabetic
| hanging | |mathematical | central | middle | text-after-edge |
text-before-edge | inherit


My questions are:

1. I take it that "text-top" and "textbottom"  were removed from 1.1 ?

2. Why do the DTDs read "autosense-script" but the specs read, "use-script"
(both 1.0 and 1.1)?  Is this an error or is there a reason for this?  If one
is right and one is wrong, which is right?

3. The order has changed of some of the attributes.  Is there any meaning to
this, or was it some purely aesthetic change?

4. "alphabetic" is mentioned in both 1.0 and 1.1 specs, but not the DTDs.

I created a test file:

<?xml version="1.0" encoding="iso-8859-1" standalone="no"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.0//EN"
 "http://www.w3.org/TR/2001/REC-SVG-20010904/DTD/svg10.dtd">
<svg xml:space="preserve" viewBox="0 0 600 600" width="600" height="600">

<g id="example1">
<text font-size="40" x="20" y="40">
<tspan dominant-baseline="ideographic">Some Text</tspan><tspan fill="red"
dominant-baseline="hanging">Some Text</tspan></text>
 <line stroke="green" stroke-width="3" x1="0" y1="40" x2="500" y2="40"/>
</g>

<g id="example2">
<text fill="red" font-size="40" x="20" y="80"
dominant-baseline="mathematical">Some Text</text>
<text fill="yellow" font-size="40" x="220" y="80"
dominant-baseline="hanging">Some Text</text>
<line stroke="midnightblue" stroke-width="3" x1="0" y1="80" x2="500"
y2="80"/>
</g>

</svg>


This renders differently in ASV 3 than Batik 1.1.1 or 1.5b2.  In Batik all
text is on the same baseline.  In ASV 3, "example2" renders as expected, but
not "example1" even though as far as I can tell, tspans can have the
dominant-baseline attribute.  Am I mistaken on that?

Thanks very much.

Michael

[Attachment #3 (text/html)]

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=iso-8859-1">
<META content="MSHTML 5.50.4913.1100" name=GENERATOR></HEAD>
<BODY>
<DIV><SPAN class=335232502-19052002><FONT face=Arial size=2><SPAN 
class=335232502-19052002>The 1.0 DTD reads:</SPAN></FONT></DIV>
<DIV>
<DIV><FONT face=Arial size=2><SPAN 
class=335232502-19052002></SPAN></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2><SPAN class=335232502-19052002>dominant-baseline 
(auto | autosense-script | no-change | reset |&nbsp;ideographic | lower | 
hanging | mathematical | inherit ) #IMPLIED</SPAN></FONT></DIV>
<DIV><FONT face=Arial size=2><SPAN 
class=335232502-19052002></SPAN></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2><SPAN class=335232502-19052002>The 1.0 spec 
reads:</SPAN></FONT></DIV>
<DIV><FONT face=Arial size=2><SPAN class=335232502-19052002><FONT face=Arial 
size=2><EM>Value:</EM> </FONT><FONT size=2><FONT face=Arial>auto | use-script | 
no-change | reset-size | alphabetic | hanging | ideographic |<SPAN 
class=335232502-19052002>&nbsp;</SPAN></FONT></FONT><FONT size=2><FONT 
face=Arial>mathematical | central | middle | text-after-edge | text-before-edge 
> text-top | textbottom<SPAN class=335232502-19052002> </SPAN>| </FONT><FONT 
color=#0000ff><FONT face=Arial>inherit</FONT></FONT></FONT></SPAN></FONT><SPAN 
class=335232502-19052002></DIV>
<DIV><FONT face=Arial size=2></FONT></SPAN>&nbsp;</DIV>
<DIV><FONT face=Arial><FONT size=2><SPAN 
class=335232502-19052002></SPAN></FONT></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial><FONT size=2><SPAN class=335232502-19052002>The </SPAN>1.1 
DTD reads:</FONT></FONT></SPAN></DIV>
<DIV><FONT face=Arial size=2><SPAN class=335232502-19052002>dominant-baseline 
(auto | autosense-script | no-change | reset | ideographic | lower | hanging | 
mathematical | inherit ) #IMPLIED</SPAN></FONT></DIV>
<DIV><FONT face=Arial size=2><SPAN 
class=335232502-19052002></SPAN></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2><SPAN class=335232502-19052002>1.1 spec 
reads:</SPAN></FONT></DIV>
<DIV><SPAN class=335232502-19052002><I><FONT face=Arial 
size=2></FONT></I></SPAN>&nbsp;</DIV>
<DIV><SPAN class=335232502-19052002><I><FONT face=Arial size=2>Value: 
</FONT></I><FONT size=2><FONT face=Arial>auto | use-script | no-change | 
reset-size | ideographic | alphabetic | hanging | |mathematical | central | 
middle | text-after-edge | text-before-edge | <FONT 
color=#0000ff>inherit</FONT></FONT></FONT></SPAN></DIV>
<DIV><SPAN class=335232502-19052002><FONT size=2><FONT face=Arial><FONT 
color=#0000ff></FONT></FONT></FONT></SPAN>&nbsp;</DIV>
<DIV><SPAN class=335232502-19052002><FONT size=2><FONT face=Arial><FONT 
color=#0000ff><FONT 
color=#000000></FONT></FONT></FONT></FONT></SPAN>&nbsp;</DIV>
<DIV><SPAN class=335232502-19052002><FONT size=2><FONT face=Arial>My questions 
are: </FONT></FONT></SPAN></DIV>
<DIV><SPAN class=335232502-19052002><FONT size=2><FONT 
face=Arial></FONT></FONT></SPAN>&nbsp;</DIV>
<DIV><SPAN class=335232502-19052002><FONT size=2><FONT face=Arial>1. I take it 
that "text-top" and "textbottom"<SPAN class=335232502-19052002>&nbsp; were 
removed from 1.1 ?</SPAN></FONT></FONT></SPAN></DIV>
<DIV><SPAN class=335232502-19052002><FONT size=2><FONT face=Arial><SPAN 
class=335232502-19052002></SPAN></FONT></FONT></SPAN>&nbsp;</DIV>
<DIV><SPAN class=335232502-19052002><FONT size=2><FONT face=Arial><SPAN 
class=335232502-19052002>2. Why do the DTDs read "autosense-script" but the 
specs read, "use-script" (both 1.0 and 1.1)?&nbsp; Is this an error or is there 
a reason for this?&nbsp; If one is right and one is wrong, which is 
right?</SPAN></FONT></FONT></SPAN></DIV>
<DIV><SPAN class=335232502-19052002><FONT size=2><FONT face=Arial><SPAN 
class=335232502-19052002></SPAN></FONT></FONT></SPAN>&nbsp;</DIV>
<DIV><SPAN class=335232502-19052002><FONT face=Arial size=2><SPAN 
class=335232502-19052002>3. The order has changed of some of the&nbsp;<SPAN 
class=956140406-19052002>attributes</SPAN>.&nbsp; Is there any meaning to this, 
or was it some purely aesthetic change?&nbsp;</SPAN></FONT></SPAN></DIV>
<DIV><SPAN class=335232502-19052002><FONT size=2><FONT face=Arial><SPAN 
class=335232502-19052002></SPAN></FONT></FONT></SPAN>&nbsp;</DIV>
<DIV><SPAN class=335232502-19052002><FONT face=Arial size=2><SPAN 
class=335232502-19052002><SPAN class=956140406-19052002>4.<SPAN 
class=862535102-19052002><FONT size=2><FONT face=Arial>&nbsp;"alphabetic" is 
mentioned in both 1.0 and 1.1 specs, but not the 
DTDs.</FONT></FONT></SPAN></SPAN></SPAN></FONT></SPAN></DIV>
<DIV><SPAN class=335232502-19052002><FONT face=Arial size=2><SPAN 
class=335232502-19052002><SPAN class=956140406-19052002><SPAN 
class=862535102-19052002></SPAN></SPAN></SPAN></FONT></SPAN>&nbsp;</DIV>
<DIV><SPAN class=335232502-19052002><SPAN class=335232502-19052002><SPAN 
class=956140406-19052002><SPAN class=862535102-19052002>
<DIV><FONT face=Arial size=2><SPAN class=956140406-19052002>I created a test 
file:</SPAN></FONT></DIV>
<DIV><FONT face=Arial size=2><SPAN 
class=956140406-19052002></SPAN></FONT>&nbsp;</DIV>
<DIV><SPAN class=956140406-19052002></SPAN><FONT face=Arial size=2>&lt;?xml 
version="1.0" encoding="iso-8859-1" standalone="no"?&gt;<BR>&lt;!DOCTYPE svg 
PUBLIC "-//W3C//DTD SVG 1.0//EN"<BR>&nbsp;"<A 
href="http://www.w3.org/TR/2001/REC-SVG-20010904/DTD/svg10.dtd">http://www.w3.org/TR/2001/REC-SVG-20010904/DTD/svg10.dtd</A>"&gt;<BR>&lt;svg \
 xml:space="preserve" viewBox="0 0 600 600" width="600" 
height="600"&gt;<BR>&nbsp;<BR>&lt;g id="example1"&gt;<BR>&lt;text font-size="40" 
x="20" y="40"&gt;<BR>&lt;tspan dominant-baseline="ideographic"&gt;Some 
Text&lt;/tspan&gt;&lt;tspan fill="red" dominant-baseline="hanging"&gt;Some 
Text&lt;/tspan&gt;&lt;/text&gt;<BR>&nbsp;&lt;line stroke="green" 
stroke-width="3" x1="0" y1="40" x2="500" y2="40"/&gt;<BR>&lt;/g&gt;</FONT></DIV>
<DIV>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>&lt;g id="example2"&gt;<BR>&lt;text fill="red" 
font-size="40" x="20" y="80" dominant-baseline="mathematical"&gt;Some 
Text&lt;/text&gt;<BR>&lt;text fill="yellow" font-size="40" x="220" y="80" 
dominant-baseline="hanging"&gt;Some Text&lt;/text&gt;<BR>&lt;line 
stroke="midnightblue" stroke-width="3" x1="0" y1="80" x2="500" 
y2="80"/&gt;<BR>&lt;/g&gt;</FONT></DIV>
<DIV>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>&lt;/svg&gt;</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><SPAN class=956140406-19052002><FONT face=Arial size=2>This renders 
differently in ASV 3 than Batik 1.1.1 or 1.5b2.&nbsp; In Batik all text is on 
the same baseline.&nbsp; In ASV 3, "example2" renders as expected, but not 
"example1" even though as far as I can tell, tspans can have the 
dominant-baseline attribute.&nbsp; Am I mistaken on 
that?</FONT></SPAN></DIV></SPAN></SPAN></SPAN></SPAN></DIV>
<DIV><SPAN class=335232502-19052002><FONT size=2><FONT face=Arial><SPAN 
class=335232502-19052002></SPAN></FONT></FONT></SPAN>&nbsp;</DIV>
<DIV><SPAN class=335232502-19052002><FONT size=2><FONT face=Arial><SPAN 
class=335232502-19052002>Thanks very much.</SPAN></FONT></FONT></SPAN></DIV>
<DIV><SPAN class=335232502-19052002><FONT size=2><FONT face=Arial><SPAN 
class=335232502-19052002></SPAN></FONT></FONT></SPAN>&nbsp;</DIV>
<DIV><SPAN class=335232502-19052002><FONT size=2><FONT face=Arial><SPAN 
class=335232502-19052002>Michael</SPAN></DIV></FONT></FONT></SPAN></DIV></BODY></HTML>




[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic