0
Under review

I have a problem with my real implementation

Ulpiano Carrasco 9 months ago updated by Alexander Shvets 9 months ago 1

Hello!
First of all excuse me for asking here, but I've been trying to solve this for weeks and I'm unable to, I have no one to talk to either....

I want to create a figure editor but I don't know if the squares of the axes should be Graphics or not, since they will not have all the methods.

Image 1128

I have adapted the diagram from your book in this way:

Image 1127


At the beginning I had this diagram:

Image 1129


I also considered the opportunity to include something like this:

Image 1131

The main problem is that I don't know how to define this, because when the figure on which it is to act rotates or is scaled this figure must also do so.

Image 1130

It is a set of figures? but it is an overlay for the figure that is selected, so it is part of the figure? I don't know how to consider it?
how can I know when an object is part of another object or is an independent object? I have a lot of doubts, sorry.

I hope you will consider the possibility of helping me with this, since in general I have a lot of doubts when designing software.

Thanks for everything, hopefully one day you will write a book that will teach me how to design solutions.

Under review

Hi!

It's hard to suggest something specific without knowing a lot more about your code. However, I can suggest you read the Decorator chapter of the GoF book, the example with text editor UI controls might give you some valuable insights.