Mailing List Archive: 49091 messages
  • Home
  • Script library
  • AltME Archive
  • Mailing list
  • Articles Index
  • Site search
 

[REBOL] Some other questions

From: WisD00M::gmx::net at: 22-Nov-2003 5:47

I hope you guys don't mind me asking some other questions I have come up with meanwhile. 1) If I have an object - how do I create an array of objects with it ? for example chicken: make object! [ tasty: "wings" ] now I would want to have an array of objects of that type. I tried it like that: chickenfarm: make chicken [] array 10 It doesn't seem to work that way, though ? I've read all stuff available about objects and array on the REBOL pages, but either I'm blind or there isn't anything about creating an array of objects ? 2) How do you create custom types ? I am talking of a way to emulate the typedef behavour in C ? How would you go to create an "enum" type in REBOL ? 3) Back on objects: objects seem to be pretty neat in REBOL - but I didn't find anything about implementing and using constructor/destructors ? I know I could manually add a function that serves as constructor each time I create an object, but is that the way REBOL requires it ? 4) In the same context: how do I actually 'free' memory/variables ? 5) On the webpage about objects one passage mentioned that "sub-objects" don't get cloned- what does that mean ? Reading that I would expect that all objects within an object aren't available when I create an object on the basis of that object. But I seem to be able to use it anyway. Maybe I am getting something wrong here ? 6) in VIEW/VID: How do you open/create several windows simultaneously ? I am also talking of being able to refresh each window. 7) Trying to find a solution to the problem above I looked around the REBOL webpages and searched for a possibility to create threads - there doesn't seem to be anything like that - how is "parallel processing" achieved in REBOL ? How would you update a dialog but also keep a timer running as well as rotating an image ? 8) On image rotation: is there any simple way to overcome the 90° restriction - I am not tallking of bitshifting manually ;-) What's the reason for this restriction ? 9) Image creation/processing I read it would be possible to create images on the fly and work with these then - is it possible to store an entire (view) layout within such an image ? Could you for example draw a line on a "virtual" view and save this then to an image file ? Or would you rather simply take the coordinates of the line and create the image with that data ? 10) Image processing Is it possible to create new images (in memory) by adding other images to the original image at certain coordinates ? Having tried to overlay transparent GIFs in a VIEW layout, I noticed the transparency attribute doesn't seem to be preserved ? At least transparent areas of my GIF didn't show the image below that one, but rather a WHITE area. IF transparent GIFs are supported: what do you need to do to really display them properly ? 11) VID controls If I need certain additional features for a basic control - like a progress bar or slider, how do I add these ? Do I need to edit the dialect ? For example, I want a progress bar with tic-marks as well as a non-continous filling of the bar. So, is there any way to "sub-class" controls easily to enhace their functionality/appearance without having to re-write everything from scratch? 12) Is there any really thorough information available on ACTIONS and EVENTS with REBOL/VIEW ? They documentation on the REBOL pages seems a bit 'poor' on that matter. I don't know yet, how these things are really done behind the scenes. 13) I didn't see any designated function to set pixels at certain coordinates in a layout- my workaround was using the line word - with 1 width/height. How is this really done ? 14) How do I catch mouse events - such as a mouseover event ? I read about 'over' - it seems to do exactly what I need - I want to display controls in a certain area only when the mouse cursor is in that said area. Also, that functionality could be used to add tooltip-like behaviour to buttons and menus. Again: thanks for your help and patience folks - it's really appreciated !! -- regards _________________ --------- Mike NEU FÜR ALLE - GMX MediaCenter - für Fotos, Musik, Dateien... Fotoalbum, File Sharing, MMS, Multimedia-Gruß, GMX FotoService Jetzt kostenlos anmelden unter http://www.gmx.net +++ GMX - die erste Adresse für Mail, Message, More! +++