#389 Get methods for AWTDrawVisitor to access fields

closed
nobody
cdk-1.4.x (181)
5
2012-10-08
2011-07-17
No

... fields needed to allow extension of the class. The 1.4.0 version dropped a method to draw arrows, which I am adding now in a new class, but I need access to these three fields to make it work.

Discussion

  • gilleain maclean torrance

    No, this breaks the design. The visitor interface is meant to act as a common way to draw across toolkits, and exposing the Graphics object is breaks this independence.

    Can the arrow drawer (generator?) be patched instead?

     
  • Egon Willighagen

    No, don't think that is possible... extending classes need access to those fields, one war or another.

    Then I think we just have to move the ArrowElement to renderbasic... I guess that makes more sense.

    Gilleain, agreed?

    I'll check if that is easy, or if there was a reason ArrowElement was in renderextra.

     
  • gilleain maclean torrance

    Oh right, now I understand. This is for some sort of ExtendedVisitor? Probably protected methods would be better. Or just make the graphics object protected, then you don't need a get method.

     

Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:

JavaScript is required for this form.





No, thanks