Hello forum. |
On Nov 23, 2010, at 5:42 AM, Gruenewald, Tom wrote:
VisualWorks has a 32x32 cursor limit, due to xplatform limits. -- Travis Griggs Objologist I multiply all time estimates by pi, to account for running around in circles. _______________________________________________ vwnc mailing list [hidden email] http://lists.cs.uiuc.edu/mailman/listinfo/vwnc |
Sorry Mr. Griggs.
On Nov 23, 2010, at 5:42 AM, Gruenewald, Tom wrote: Hello forum. I like to create a custom cursor (for a drag&drop event) which exceeds the size of 16x16 pixels. Why does the following procedure fail? | anImage aMaskImage cursor | anImage := self loadCustomImage. "anImage = Depth24Image(extent: 48 @ 48 depth: 24)" aMaskImage := Image extent: anImage depth: 1 bitsPerPixel: 1 palette: (CoveragePalette maxPixelValue: 1). aMaskImage pixelsDo: [:x :y | aMaskImage atX: x y: y put: 1]. cursor := Cursor new. cursor setImage: anImage mask: aMaskImage hotSpot: 0@0 name: 'CustomCursor'. cursor showWhile: [(Delay forSeconds: 1) wait] Unhandled exception: a primitive has failed HandleRegistry>>evaluateWithFullProtection: HandleRegistry>>registerValueOf: Cursor class(OSHandle class)>>registerValueOf: optimized [] in OSHandle>>handleValue: BlockClosure>>ifCurtailed: Cursor(OSHandle)>>handleValue: Cursor>>privateInstall Cursor>>beCursor Cursor class>>currentCursor: Cursor>>show Cursor>>showWhile: UndefinedObject>>unboundMethod [...] Best regards, Tom Grünewald VisualWorks has a 32x32 cursor limit, due to xplatform limits. -- Travis Griggs Objologist I multiply all time estimates by pi, to account for running around in circles. ---------------------------------------- This message is intended for a particular addressee only and may contain business or company secrets. If you have received this email in error, please contact the sender and delete the message immediately. Any use of this email, including saving, publishing, copying, replication or forwarding of the message or the contents is not permitted. _______________________________________________ vwnc mailing list [hidden email] http://lists.cs.uiuc.edu/mailman/listinfo/vwnc pic02173.gif (1K) Download Attachment |
On Nov 23, 2010, at 6:48 AM, Gruenewald, Tom wrote: Er, uh, yes, I didn't look at your example enough. You're limited to two colors as well. I wish neither restriction were in place, but I guess that's the limits imposed by the cross-platform story. A better architecture (IMO), would probably be to A) lift the cursor handling out of the VM completely B) write the Smalltalk code that can query the platform's maximum depth and or extents C) write the Smalltalk code that would take your candidate graphic, and make sure it fits within the current platforms abilities, adjusting by either downsampling the colors or scaling the size While I was at it, I'd put in the prototype we have for separating "busy state" cursors from "spatial" cursors. Back to my little dream cloud. -- Travis Griggs Objologist "I did not have time to write you a short program, so I wrote you a long one instead." _______________________________________________ vwnc mailing list [hidden email] http://lists.cs.uiuc.edu/mailman/listinfo/vwnc |
Free forum by Nabble | Edit this page |