I wouldn’t have known either :) — You are running outside of the intended context and I am sure you know that 2htdp/image is built on top of the GUI infrastructure — If you look at the image teachpack, you will see section 2.2 "Image Interoperability” — there you will see that an image is “pict convertible” (satisfies the predicate) — if you click thru, you are in the Pict library (specifically the predicate section) — on the left, in the ToC, you will see the ‘rendering’ subsection for Picts — click on that one and peruse the functions supported out of there
Would you be able to do this in 15minutes? It depends on how far you’re willing to click and scroll. It’s really raco doc 2htdp/image scroll down to section 2.2 (see ToC) click on pict convertible scroll up to see ToC (and notice ‘rendering’) Perhaps this helps someone in the future — Matthias > On Mar 16, 2019, at 11:28 AM, Marc Kaufmann <marc.kaufman...@gmail.com> wrote: > > Yep, that works. > > How could I have googled this or found this solution? Or did you simply know > this before? I tried for 15 minutes without success, trying 'display image > repl' and variations on it (canvas, cli, repl). > > On Saturday, March 16, 2019 at 3:59:02 PM UTC+1, Philip McGrath wrote: > Here's one way: > > Welcome to Racket v7.2. > > (require 2htdp/image racket/gui/base (only-in pict show-pict)) > > (show-pict (empty-scene 100 100)) > > (The require of racket/gui/base seems to be needed for side-effect only, to > prevent a "racket/gui/base is not available" error. That seems like it might > be a bug.) > > -Philip > > > On Sat, Mar 16, 2019 at 10:48 AM Marc Kaufmann <marc.ka...@gmail.com <>> > wrote: > Hi, > > I am playing around with big-bang in 2htdp/universe and images in > 2htdp/image. When I launch big-bang from racket on the cli (not DrRacket), it > does somehow call a window and display the images with my render function. > However, when I want to test the render functions, I want to run them > separately in the cli, but can't figure out how to display images there. All > I get is: > > > (require 2htdp/image) > > (empty-scene 100 100) > > (object:image% ...) > > How do I open a window from the repl on which I either continuously render > again and again, or for each image a new such window is opened? How does > big-bang do it - that is maybe the way I should do it too? > > Thanks, > Marc > > -- > You received this message because you are subscribed to the Google Groups > "Racket Users" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to racket-users...@googlegroups.com <>. > For more options, visit https://groups.google.com/d/optout > <https://groups.google.com/d/optout>. > > -- > You received this message because you are subscribed to the Google Groups > "Racket Users" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to racket-users+unsubscr...@googlegroups.com > <mailto:racket-users+unsubscr...@googlegroups.com>. > For more options, visit https://groups.google.com/d/optout > <https://groups.google.com/d/optout>. -- You received this message because you are subscribed to the Google Groups "Racket Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to racket-users+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.