>>>>> "VH" == Vincent Hardy <[EMAIL PROTECTED]> writes:

>>> getBounds - for GraphicsNode.getGeometryBounds() 
>>> getDecoratedShape - for GraphicsNode.getBounds()

VH> You meant TextNode.getGeometryBounds() and TextNode.getOutline(),
VH> right?

>>  They are the same methods, TextNode derives off GraphicsNode (I
>> reference them as GraphicsNode methods since GraphicsNode is the
>> external interface).

VH> OK, I thought you wanted to point to the code where TextPainter
VH> was used. However, I do not understand why you are saying that
VH> TextNode.getOutline() is the same as GraphicsNode.getBounds(). 

    Sorry I missed that you had changed the second method (from
getBounds to getOutline).

VH> The GraphicsNode.getBounds() method builds on
VH> GraphicsNode.getPrimitiveBounds() which uses the TextPainter's
VH> getPaintedBounds method.

    Yes you are correct, however it is all beside the (rather trivial)
point I was trying to make.  The confustion is that
TextPainter.getBounds() does not return a value usable as the return
value from GraphicsNode.getBounds().  This is bad.  This is something
I would like to fix.

    I would also like to remove the 'get[Decorated]Shape' methods and
replace them with just 'getOutline' (same as getDecoratedShape).

Summary:

Remove:
    Shape getShape(TextNode node);
    Shape getDecoratedShape(TextNode node);
    Rectangle2D getBounds(TextNode node);
    Rectangle2D getDecoratedBounds(TextNode node);
    Rectangle2D getPaintedBounds(TextNode node);

Add:

    Shape getOutline(TextNode node);  // ~ current getDecoratedShape.
    Rectangle2D getBounds[2D](TextNode node);  // ~ current getPaintedBounds
    Rectangle2D getGeometryBounds(TextNode node);  // ~ current getBounds    

---

    The implementations would also be changed to defer calls to the
contained GlyphVector's methods (some of which will need to be fixed -
AWTGVTGlyphVector.getVisualBounds does not include stroke info).

---
   Also a slew of related protected methods would dissapper in
BasicTextPainter (and hence StrokingTextPainter).

>> My preference is actually to rationalize the TextPainter interface

VH> If we do what you have done for the method name change 

    See my other message on this...

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to