[Cuis-dev] Renaming several fundamental Morph classes

Hilaire Fernandes hilaire at drgeo.eu
Fri Dec 24 00:30:37 PST 2021


Hi guys,

Le 24/12/2021 à 07:12, Luciano Notarfrancesco a écrit :
> I’ve been thinking about it and I would rename KernelMorph to 
> RectangularMorph, as in the original Morphic, because I think having 
> rectangular bounds is enough to call it “rectangular”. It’s not a 
> rectangle, tho (it wouldn’t make sense to call it RectangleMorph). And 
> about WidgetMorph I’d keep that name and make it subclass of 
> RectangularMorph (it just adds borderWidth and borderColor).

Yes and No.

Yes. The RectangularMorph or maybe just RectMorph will be more 
meaningful than Kernel/SpecialMorph. Some user will read Rectangle and 
be confused, because subclass of KernelMorph can be non rectangle (Think 
about a disc or an ellipse)

In that case I will call it a BoxyMorph or BoxMorph because a 
rectangular, ellipse, or any other shape defined by its -x and -y 
extents are kind of box.

No. Because the intend of Juan is to make Widget not limited to 
Rectangular like widget, but to extend it to widget with any kind of 
shape. So it can't be a sublcass of KernelMorph. In Juan, renaming 
scheme, this is GUIControlMorph which could be a subclass of KernelMorph.

My poor Juan, I think we add a lot of confusion we our opinions ;-)

Reading at your email, we want coherent names for these fundamental 
classes. Here is a distilled proposal from your suggestions:

MovableMorph  -> MorphicWidget   -> *WidgetMorph *(subclass of Morph)
WidgetMorph      -> GUIControlMorph -> *RectWidgetMorph *(subclass of 
WidgetMorph as for now)
KernelMorph       -> SpecialMorph -> *BoxyMorph */*BoxMorph *(subclass 
of WidgetMorph)
**WorldMorph + PasteUpMorph   -> *WorldMorph*

I think having both WidgetMorph and RectWidgetMorph names (or anything 
with the same idea) will help the future users to distinguish these two 
kinds of widget and not be confused as I was.

As Luciano mentioned it, we can wonder why in the current name scheme 
WidgetMoprh is not a subclass of KernelMorph. But maybe we can keep this 
for later and Juan may have some good reason.

Best wishes to all of you!

Hilaire

-- 
GNU Dr. Geo
http://drgeo.eu
http://blog.drgeo.eu

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.cuis.st/mailman/archives/cuis-dev/attachments/20211224/5dff2039/attachment-0001.htm>


More information about the Cuis-dev mailing list