A new version of Graphics was added to project The Inbox: http://source.squeak.org/inbox/Graphics-ct.419.mcz
==================== Summary ====================
Name: Graphics-ct.419 Author: ct Time: 20 September 2019, 7:45:53.388726 pm UUID: 5deebfce-0321-9645-aebd-0b4bfb428259 Ancestors: Graphics-nice.417
Add Rectangle>>#pointAtFraction:
Example: [(5@5 rect: 10@20) pointAtFraction: 0.5@1] will give you 7.5 @ 20.
dep:feat-ol
=============== Diff against Graphics-nice.417 ===============
Item was added: + ----- Method: Rectangle>>pointAtFraction: (in category 'rectangle functions') ----- + pointAtFraction: relativePoint + + ^ self origin + (self extent * relativePoint)!
Be careful about using non Integers with Rectangles, too. As with Intervals, I think I remember that some of the API will break.
On Fri, Sep 20, 2019 at 12:46 PM commits@source.squeak.org wrote:
A new version of Graphics was added to project The Inbox: http://source.squeak.org/inbox/Graphics-ct.419.mcz
==================== Summary ====================
Name: Graphics-ct.419 Author: ct Time: 20 September 2019, 7:45:53.388726 pm UUID: 5deebfce-0321-9645-aebd-0b4bfb428259 Ancestors: Graphics-nice.417
Add Rectangle>>#pointAtFraction:
Example: [(5@5 rect: 10@20) pointAtFraction: 0.5@1] will give you 7.5 @ 20.
dep:feat-ol
=============== Diff against Graphics-nice.417 ===============
Item was added:
- ----- Method: Rectangle>>pointAtFraction: (in category 'rectangle
functions') -----
- pointAtFraction: relativePoint
^ self origin + (self extent * relativePoint)!
Do you talk abound rounding effects? I remember some flickering effects myself when setting float bounds to the SystemWindowMorph, but I could not reproduce it; apparently, someone has added a check.
Also, Morphic is not the only client of Rectangles, is it? For example, LayoutFrames explicitly depend on floats.
Or what issue are you talking about else? :)
Christoph
________________________________ Von: Squeak-dev squeak-dev-bounces@lists.squeakfoundation.org im Auftrag von Chris Muller asqueaker@gmail.com Gesendet: Donnerstag, 26. September 2019 03:58:44 An: squeak dev Betreff: Re: [squeak-dev] The Inbox: Graphics-ct.419.mcz
Be careful about using non Integers with Rectangles, too. As with Intervals, I think I remember that some of the API will break.
On Fri, Sep 20, 2019 at 12:46 PM <commits@source.squeak.orgmailto:commits@source.squeak.org> wrote: A new version of Graphics was added to project The Inbox: http://source.squeak.org/inbox/Graphics-ct.419.mcz
==================== Summary ====================
Name: Graphics-ct.419 Author: ct Time: 20 September 2019, 7:45:53.388726 pm UUID: 5deebfce-0321-9645-aebd-0b4bfb428259 Ancestors: Graphics-nice.417
Add Rectangle>>#pointAtFraction:
Example: [(5@5 rect: 10@20) pointAtFraction: 0.5@1] will give you 7.5 @ 20.
dep:feat-ol
=============== Diff against Graphics-nice.417 ===============
Item was added: + ----- Method: Rectangle>>pointAtFraction: (in category 'rectangle functions') ----- + pointAtFraction: relativePoint + + ^ self origin + (self extent * relativePoint)!
On Sat, Sep 28, 2019 at 12:44 PM Thiede, Christoph < Christoph.Thiede@student.hpi.uni-potsdam.de> wrote:
Do you talk abound rounding effects?
That may have been it.
I remember some flickering effects myself when setting float bounds to the
SystemWindowMorph, but I could not reproduce it; apparently, someone has added a check.
Also, Morphic is not the only client of Rectangles, is it?
Actually, I believe it is. Sure, other domains can and do use it but, IIRC, it has a distinct "screen" layout, where "topLeft" is 0,0 instead of bottom left as in Cartesia. Accidentally swapping the two points; (e.g., as in, bottomRightPoint corner: topLeftPoint) will also break things.
For example, LayoutFrames explicitly depend on floats.
Or what issue are you talking about else? :)
I don't recall, sorry.
- Chris
Christoph
*Von:* Squeak-dev squeak-dev-bounces@lists.squeakfoundation.org im Auftrag von Chris Muller asqueaker@gmail.com *Gesendet:* Donnerstag, 26. September 2019 03:58:44 *An:* squeak dev *Betreff:* Re: [squeak-dev] The Inbox: Graphics-ct.419.mcz
Be careful about using non Integers with Rectangles, too. As with Intervals, I think I remember that some of the API will break.
On Fri, Sep 20, 2019 at 12:46 PM commits@source.squeak.org wrote:
A new version of Graphics was added to project The Inbox: http://source.squeak.org/inbox/Graphics-ct.419.mcz
==================== Summary ====================
Name: Graphics-ct.419 Author: ct Time: 20 September 2019, 7:45:53.388726 pm UUID: 5deebfce-0321-9645-aebd-0b4bfb428259 Ancestors: Graphics-nice.417
Add Rectangle>>#pointAtFraction:
Example: [(5@5 rect: 10@20) pointAtFraction: 0.5@1] will give you 7.5 @ 20.
dep:feat-ol
=============== Diff against Graphics-nice.417 ===============
Item was added:
- ----- Method: Rectangle>>pointAtFraction: (in category 'rectangle
functions') -----
- pointAtFraction: relativePoint
^ self origin + (self extent * relativePoint)!
Hi Chris, hi all,
I'd like to bring this topic up again. Personally, this tool has helped me in two projects until now. In particular, I plan to use it for the reconstruction of Objectland. Do you see any chance to merge this as is, or should we introduce a second version #exactPointAtFraction: or something similar?
See also Graphics-ct.437 http://forum.world.st/The-Inbox-Graphics-ct-437-mcz-td5120840.html for nearly the same discussion. I did not meet a use case where rounding is important, but if you like so, we can implement two versions for this one, too.
Best, Christoph
-- Sent from: http://forum.world.st/Squeak-Dev-f45488.html
squeak-dev@lists.squeakfoundation.org