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

[REBOL] Re: Which? [Object! Block!]

From: ammoncooke:yaho:o at: 27-Sep-2001 12:29

----- Original Message ----- From: "Andrew Martin" <[Al--Bri--xtra--co--nz]> To: <[rebol-list--rebol--com]> Sent: Thursday, September 27, 2001 2:06 AM Subject: [REBOL] Re: Which? [Object! Block!]
> Ammon asked: > > why doesn't it add the composed block? > > Because this line here: > > > probe compose [(to-set-word first l) (to-word "make lyt[") > (nw-lyt) > > needs to have a set-word! before the 'compose.
Why? It currently returns a perfect make object!. Not to question your knowledge, but to enlargen mine. ;)
> Also: > > > "vls:" fourth l > > should be: > > vls: fourth l > > perhaps?
Yes, & no: nw-lyt: compose/deep[ wrd: [(first l)] tp: [(second l)] spc: [(third l)] (if [length? l > 3] [ vls: fourth l ]) ] returns: ** Script Error: Out of range or past end ** Where: do-boot ** Near: fourth l I guess compose doesn't execute an 'if?
> Also, if you're just storing layouts, why not just store the block of
> For example: > > Layouts: [ > layout1 [text "layout1"] > ] >
because. ;) Well, it is difficult for me to explain... One reason is that I need to be able to handle ALL parameters of a layout. If you look at the object 'lyt which I have defined, make object! [ wrd -- (word) The name of the layout tp -- (type) Maybe I should use a different name, but it contains 'layout + any refinements spc -- (spec) The specs of the layout pr -- (parameters of the refinements) Currently it is not always created, but I will probably change that ] then the other reason is that the layouts get DOne when they are viewed. I need them to not be in the global namespace. Block! maybe better, I am just not sure. Thanks!! Ammon