<HTML><BODY style="word-wrap: break-word; -khtml-nbsp-mode: space; -khtml-line-break: after-white-space; "><DIV>I'm working on my VisualWorks Smalltalk interface to Cairo. In that environment, I have easy access to any NSWindow I open, and the ability to send objective-c messages. So what I do is basically:</DIV><DIV><BR class="khtml-block-placeholder"></DIV><DIV>1) fetch the class named NSGraphicsContext</DIV><DIV>2) id nsGC = [NSGraphicsContext graphicsContextWithWindow: myNSWindow];</DIV><DIV>3) cgCtx = [nsGC graphicPort];</DIV><DIV>4) cairo_nquartz_surface_create_for_cg_context (cgCtx, 200, 200, 1); </DIV><DIV><BR class="khtml-block-placeholder"></DIV><DIV>But when I do drawing ops on that surface, nothing happens. :( Am I doing this right at all? Or is there a better/different way to do it? Do I need to send additional messages to the NSGraphicsContext or to the CGGraphicsContext (this is just a struct pointer,right?)?</DIV><DIV><BR class="khtml-block-placeholder"></DIV><DIV>I'm using 1.2.6 (I think). I'm confused about the recent sent of messages regarding osx apis and stability thereof. Should I upgrade to the new snapshots for cairo?</DIV><DIV><BR class="khtml-block-placeholder"></DIV><DIV>TIA</DIV><BR><DIV> <SPAN class="Apple-style-span" style="border-collapse: separate; border-spacing: 0px 0px; color: rgb(0, 0, 0); font-family: Helvetica; font-size: 18px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-align: auto; -khtml-text-decorations-in-effect: none; text-indent: 0px; -apple-text-size-adjust: auto; text-transform: none; orphans: 2; white-space: normal; widows: 2; word-spacing: 0px; "><DIV>--</DIV><DIV>Travis Griggs</DIV><DIV>Objologist</DIV><DIV>My Other Machine runs OSX. But then... so does this one.</DIV><BR class="Apple-interchange-newline"></SPAN> </DIV><BR></BODY></HTML>