[Cuis-dev] Question on Morphic coordinates and transforms

ken.dickey at whidbey.com ken.dickey at whidbey.com
Sun Dec 22 08:12:37 PST 2019


> Or is that the Morphic API does not properly isolate the programmer
> from the specifics of the coordinate system used? The API should take
> care of all the internalize/externalize, right?

One usually hides non-trivial "relative vs world/screen" mechanics in 
some aptly named method.

Since "everyone does this", you should find examples.

I would suggest looking at the code in:

'MenuMorph>> popUpAt: aPoint forHand: hand in: aWorld allowKeyboard: 
aBoolean'

which uses

'self fitInWorld'

another interesting method.

A more complex example might be

'RealEstateAgent>> strictlyStaggeredInitialFrameFor: aStandardSystemView 
initialExtent: initialExtent world: aWorld'

HTH,
-KenD


More information about the Cuis-dev mailing list