World: r3wp
[!REBOL3 GUI]
older newer | first last |
shadwolf 25-Aug-2010 [2814] | ladislav i foresee what i want and this R3 gui have not better reason to succeed than the previous intents since it's based on the same main problems to it's achievement in time you will get it. I have no reason to shut my mouth when i see things so wrong. I exposed what i though of this process now please don't fuel me anymore do as i was far and in january 2011 remember i said this was going to a faillure. |
Henrik 26-Aug-2010 [2815] | graham, don't know if it's useful, but I think PAD can serve as a filler. |
Graham 26-Aug-2010 [2816] | pad .. what does it do the object? |
Henrik 26-Aug-2010 [2817] | PAD is a style, so it produces an object which then moves the next faces one grid place forward, just like any other style. This layout: view [panel 2 [button pad pad button]] ...produces this: http://rebol.hmkdesign.dk/files/r3/gui/235.png |
Graham 26-Aug-2010 [2818x6] | yes, that's what I meant .. it adds an unnecessary object to the main object |
I'm looking for a no-op which does not the graphic object created | |
alte | |
r | |
it's just a dialect syntactic artifice | |
eg. condition: either boolean [ button ] [ no-ope ] view compose/deep [ button (condition) button ] | |
Henrik 26-Aug-2010 [2824] | I'll pass it on. |
Robert 26-Aug-2010 [2825x2] | Why can we use just an IF? |
can=can't | |
BrianH 26-Aug-2010 [2827] | That behavior would be consistent with R3's Parse dialect. The actual behavior would only be comparable to Parse, since there is no failure and backtracking. |
Graham 26-Aug-2010 [2828] | Robert, how? |
BrianH 26-Aug-2010 [2829] | That behavior = Robert's suggestion |
Graham 26-Aug-2010 [2830] | Where are you going to use the IF robert? |
Robert 26-Aug-2010 [2831] | view compose/deep [ button (IF condition [button]) button ] |
Graham 26-Aug-2010 [2832] | >> condition: false == false >> probe compose/deep [ button (if condition [button]) button ] [button none button] == [button none button] |
BrianH 26-Aug-2010 [2833] | >> compose/deep [ button (either false [[button]] [()]) button ] == [button button] |
Robert 26-Aug-2010 [2834] | Yes, and this none could be skipped by the layout parser. |
Graham 26-Aug-2010 [2835] | yes, that's what I'm asking for .. a no-op |
Robert 26-Aug-2010 [2836] | I wanted to have this implicit NONE skipping for a long time. I'm not a fan of using an either just to return "nothing". IMO an if that doesn't return anything at all makes a lot of sense if used with COMPOSE. |
Graham 26-Aug-2010 [2837] | if no-op is served by none, then fine |
BrianH 26-Aug-2010 [2838] | I misunderstood your suggestion, Robert. I thought you were talking about adding an IF command to the layout dialect, not to the code in the (). |
Graham 26-Aug-2010 [2839x2] | Robert, this implicit none is not possible ...with Rebol |
We discussed this recently | |
Robert 26-Aug-2010 [2841] | Brian, no that was the idea. |
Graham 26-Aug-2010 [2842] | but since none can be used sometimes for part of the layout I thought it would be easier to parse if we used something else |
BrianH 26-Aug-2010 [2843x2] | The IF command in the dialect would get rid of the COMPOSE and do this: view [button if (condition) button button] That is what I meant by a Parse-like IF. Possibly not doable in the layout dialect, due to overhead. |
Putting the IF in the paren and using COMPOSE would be something different. | |
Graham 26-Aug-2010 [2845x2] | I don't see why.... it just adds more clutter to the dialect |
I'd vote against that idea | |
BrianH 26-Aug-2010 [2847] | Like I said, too much overhead. But that is what I thought Robert was suggesting (until he demonstrated otherwise). |
Graham 26-Aug-2010 [2848] | unless we start adding conditions to the whole vid dialect ... |
BrianH 26-Aug-2010 [2849x2] | That would be the suggestion, yes. |
I don't like it though. It you add conditions to the dialect it will make it too easy to put semantic code into a layout that is just supposed to be for display. | |
Graham 26-Aug-2010 [2851x2] | In fact why don't we consider using parens to switch out of the layout dialect instead of making us use compose'deep |
nah... too complicated | |
BrianH 26-Aug-2010 [2853] | Again, there should be no DO dialect code in the layout dialect. Unless actions are called, the layout dialect should be declarative, not procedural. That is what makes it safe. |
Graham 26-Aug-2010 [2854] | we already have a do in the vid dialect |
BrianH 26-Aug-2010 [2855] | It's a DO action. The code in its argument only gets called as a result of the action, not at layout time. |
Graham 26-Aug-2010 [2856] | view layout [ button do [ this at layout time [ ] |
BrianH 26-Aug-2010 [2857x3] | That code doesn't make sense, even with the missing ]. Are you thinking VID or the R3 GUI? |
Oh, you meant do [ this at layout time ]. It doesn't do it at layout time, only when the button is clicked. | |
The DO [ ... ] is an action modifier to the button declaration. | |
Graham 26-Aug-2010 [2860] | Brian, I take it you have never done any Vid work ? |
BrianH 26-Aug-2010 [2861x2] | Very little. Most of my VID knowledge comes from DevBase 2 and the VID resize project. Aside from that, very little GUI work in REBOL, just (many) other languages. Most of my REBOL code has a web or batch UI, or no UI at all. |
I had to learn a lot of VID's internals to do the resize project. But I don't really need to make GUIs much. | |
Graham 26-Aug-2010 [2863] | the dialect word 'do switches the layout parser to the do dialect |
older newer | first last |