1

For a view, I need to define a size, a drop-down with data, set its size and get the chosen value for input in some function.

loadGui: func [] [
    unview/all

    view layout [
        Dropd_urls: drop-down (getUrlsEnd Urls)
  ]
]

What is a logic behind a style or a facet? Define a word, than the facet then the size, alignment and other properties, then a block for on-action? And what about the (getUrlsEnd Urls) that gets evaluated, where should it be placed? If someone could provide a thorough example on the drop-down, it would be great.

And another question. I'm aware of the help system/..., but cannot get useful information about the logic of how to accomplish what was stated above. Where do you go to get to know how to build the view constructs? A howto? Normally, I read the howtos provided by Nick Antonnacio, but there's more to view than what is shown in his documents.

Luis
  • 1,236
  • 5
  • 22
  • 31

1 Answers1

2

the demo on atronixengineering.com/r3/demo.r has also a dropdown list under widgets. You could generate your dropdown list with compose/deep.

view layout compose/deep [
    Dropd_urls: drop-down  [
       (getUrlsEnd Urls) 
    ]
]

or with different actions depending of the choice of the dropdown list

view layout [
   Dropd_urls: drop-down  [
     "1"
     "2"
  ] on-action [print face/facets/text]
]

did you read Cross Platform App Development with Rebol 3 Saphir ?

sqlab
  • 6,412
  • 1
  • 14
  • 29
  • The demo only show a `drop-down`, doesn't answer my questions. – Luis Jul 14 '15 at 10:42
  • sorry; I did not realize what you meant with getUrlsEnd Urls. I thought you wanted to generate a dynamic dropdown list. In case you want an action depending of your choice I will add a second example – sqlab Jul 14 '15 at 11:32