Page 1 of 1
Free positioning of Reaction Gadgets ?
Posted: Sat Jul 25, 2015 12:51 pm
by Thomas Frieden
Hi,
I'm faced with a problem regarding Reaction: I want to use Reaction for a project of mine, but it requires free positioning of gadgets across the window. As far as I know, Reaction uses container gadgets that always layout the gadgets according to their fixed rules (horiziontal or vertical groups, etc).
Does anyone know if it is possible to simply have gadgets positioned manually ?
Thanks.
Re: Free positioning of Reaction Gadgets ?
Posted: Sat Jul 25, 2015 1:29 pm
by gazelle
Use the gadtools.library functions instead of the reaction layout maybe?
Re: Free positioning of Reaction Gadgets ?
Posted: Sat Jul 25, 2015 2:35 pm
by tonyw
It's probably not enough for all purposes, but I have used specific spacing to position a gadget within a space. Try the LAYOUT_TopSpacing/LeftSpacing/etc. There are lots of tags to try.
If that is not good enough, you can always put a Space Gadget on each side and force them to a specific size.
Re: Free positioning of Reaction Gadgets ?
Posted: Sat Jul 25, 2015 5:10 pm
by tbreeden
tonyw wrote:It's probably not enough for all purposes, but I have used specific spacing to position a gadget within a space. Try the LAYOUT_TopSpacing/LeftSpacing/etc. There are lots of tags to try.
If that is not good enough, you can always put a Space Gadget on each side and force them to a specific size.
To further simply this approach, try using containers that you set to a fixed size. If you can fit the gadgets correctly within the container, then they will stay where they are w/r/t their neighboring gads in that container.
I go to containers within containers. If it is not too complex, that may not get too fuzzy.
Tom
Re: Free positioning of Reaction Gadgets ?
Posted: Sat Jul 25, 2015 5:57 pm
by Belxjander
So you want a BOOPSI compliant ReAction UI but to include a "layout" which is assigned an area of "width:height" and within that area directly assign <X:Y> placed gadgets without the "smart layout" being used?
am I understanding the problem?
Is it possible to declare a "layout" of a fixed size without auto-sizing/placing it's children?
Re: Free positioning of Reaction Gadgets ?
Posted: Sat Jul 25, 2015 8:24 pm
by salass00
There's the LAYOUT_NoLayout tag which at least is supposed to allow doing just that.
Re: Free positioning of Reaction Gadgets ?
Posted: Sat Jul 25, 2015 10:55 pm
by xenic
tbreeden wrote:
To further simply this approach, try using containers that you set to a fixed size.
I haven't used Reaction that much and could not find the term "container" in any of my Reaction examples or docs. Could you be more explicit about Reaction "containers" and perhaps provide an example?
Re: Free positioning of Reaction Gadgets ?
Posted: Sun Jul 26, 2015 8:58 pm
by tbreeden
xenic wrote:tbreeden wrote:
To further simply this approach, try using containers that you set to a fixed size.
I haven't used Reaction that much and could not find the term "container" in any of my Reaction examples or docs. Could you be more explicit about Reaction "containers" and perhaps provide an example?
I mean to say "Layout Gadgets". I tend to think of them as containers.
I think it can sometimes be easier to achieve the desired overall design using one or more, maybe fixed size,
Layout gadgets into which you put the related interface gadgets. Then take these gadgets and put them into
another, higher level, Layout gadget.
You can then layout the layouts as desired. If you've fixed the size of the lower level layouts, what is
in them will not be affected by the higher level layout.
tom
Re: Free positioning of Reaction Gadgets ?
Posted: Mon Jul 27, 2015 12:44 am
by Thomas Frieden
The idea is that I can give a position and size for the gadget. I don't to work with weights or anything, that's going to be too complicated.
salass00 wrote:There's the LAYOUT_NoLayout tag which at least is supposed to allow doing just that.
Thanks, I'll look into that.