google-code-export / tatami

Automatically exported from code.google.com/p/tatami
1 stars 1 forks source link

Tananmi Dojox.gfx Text issues #28

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
I have found several issue with the Text class

1) Text displayed in small size (e.g.8 pt) is unreadable because, by
default, the stroke width is set 1.
Setting the stroke with to 0 solves the problem in Firefox and Chrome but
not in IE 8.

I would suggest that by default, the stroke with should be 0 and there
would be no stroke at all, as it is in Dojo.

2) There are no methods to set x (as double) and y (as double) of the text.

3) There are no methods to set align.

What steps will reproduce the problem?
1. Create a Text instance
2. Set the font size to 8
3. Look at the output on a browser

What is the expected output? What do you see instead?
Expected output: readable text
Output obtained: almost unreadable text

What version of the product are you using? On what operating system?
Tanami 1.4

Please provide any additional information below.

As a work around, I created a subclass of Text. This ExtendedText class has
a new constructor (for x, y, and align parameters). Also, the show()member
function is overidden in order to remove the stroke if the strokewith was
set 0.
I don't claim this is a good solution or that I wrote good Java code (I am
new in Java). I just hope that it might be useful.
The ExtendedText.java file is attached to this post.

Original issue reported on code.google.com by bruno...@googlemail.com on 25 Nov 2009 at 10:24

Attachments: