New to Reaction

New to reaction programming and I am having a bit of trouble understanding a couple concepts. One thing I am trying to do is completely control positioning of gadgets utilizing LAYOUT_NoLayout
1. Without using GIMMIEZEROZERO on the window attribute how do you get the proper metrics for the borders and other gadgets?
2. The label image class.
How do you control the size and position of label in a layout if you are using so you have manual control over placement like you can with gadgets.
Hopefully some of you can point me in right direction. I have been reading all the articles here and have gleaned much but I am really trying to wrap my head around some of the conceptual differences from other GUI APIs. ie. no child windows, labels are not gadgets etc...
Thanks
Doug

Welcome!
You have chosen a challenge.
As I understand it, ReAction is all about managing the GUI in a "standard" way so the programmer does not have to. It can get a bit tricky, but choosing "complete control of position" is going to be a wrestling match at best.
Back in the pre-reaction days, programmers had complete control over the GUI, and all those gadgets and such are still available. Reading any early AmigaDOS Intuition references would be the quickest way to get there.
As far as ReAction goes, there were some early macros that have since been deprecated. One unfortunate result is that a lot of the examples out there are not as useful, nor as clear as they ought to be.
Trixie took a trip through all of this, and wrote a really excellent guide to ReAction programming. It is hosted on this site, titled "Beginner's Guide to Programming ReAction". It is the best reference on what to do, and what to avoid doing, that I have seen yet.
I am no expert, but I started by absorbing as much from his guide as I could, and I continue to add to my abilities as need arises.
Good Luck!
LyleHaze

What kind of (ReAction) GUI have you in mind to create? Maybe you can post here a sketch of your GUI designed or part of code.
I will suggest start with
http://www.os4depot.net/share/development/example/reaction_examples.lha
and with
http://www.os4depot.net/share/development/example/reaction_dn.lha
and as LyleHaze http://www.os4depot.net/share/document/development/reactionguide.lha
There are some small programs I made on os4depot that have sources and you can see the GUI/Reaction code (POff, DateTime, KeymapSwitcher,...) and maybe inside the SDK there are other examples.

Hi,
Thanks for feedback been reading through all those documents but non really document enough of behaviors and interactions of the various options.
The UI is not a specific design. I am working on porting a GUI API like (WxWidget but not that) to support the Amiga and trying to deal with the complexities of mapping the functionality of the generic API to Amiga Widgets. I was hoping to be able to use the high level constructs of Reaction with out having to dive deeper into intuition. The API wants to control alignment/layout hence my completely disabling the layout control. My challenge is understanding labels in unlike most other platforms they are a widget too. I can move gadgets around fine but not labels.
Thanks
Doug

If you mean labels as the text that shows (normally) before the gadget (sorry for poor/ASCII art):
Label [ @ | options ]
Label: [string_gadget]
Label [ x ]
[ x ] Label
You can "make" the label a button without bevel (BUTTON_BevelStyle,BVS_NONE) and transparency (BUTTON_Transparent,TRUE) so it looks like a normal label.

New to Reaction
New to reaction programming and I am having a bit of trouble understanding a couple concepts. One thing I am trying to do is completely control positioning of gadgets utilizing LAYOUT_NoLayout

You probably shouldn't? The whole point of layout gadget is that is lays out stuff. Using LAYOUT_NoLayout is for extreme exceptions.
I've used it exactly once in my SnakeEyes.py image view when I needed to place a bitmap image so it centred in the display window.
I don't if this will give you a clue or not as it's python code , for my ProAction GUIServer, which is a fairly thin wrapper arround the underlying BOOPSI code.

Notice I get the bounds of the parent layout by querying it's GA_Top/GA_Left/GA_height/GA_Width parameters, calculate the image parameters accordingly and set the IA_Left,IA_Top etc
It works but is quite clunky and when I came to working on MultiViewer I used a custom image display gadget to disply the images using compositing or manual scaling.
The full script is here: http://os4depot.net/index.php?function=showfile&file=graphics/viewer/snakeeyes.lha

The UI is not a specific design. I am working on porting a GUI API like (WxWidget but not that) to support the Amiga and trying to deal with the complexities of mapping the functionality of the generic API to Amiga Widgets. I was hoping to be able to use the high level constructs of Reaction with out having to dive deeper into intuition. The API wants to control alignment/layout hence my completely disabling the layout control. My challenge is understanding labels in unlike most other platforms they are a widget too. I can move gadgets around fine but not labels.

Lables are BOOPIS objects just like Gadgets, but they are based in imageclass not gadgetclass. There is quite a lot in common between the two, but images don't accept input.
Sounds to me like you may need to devise you own layout gadget if the standard one doesn't map well to the alien GUI. That will require lowlevl BOOPSI class coding and is ot a trivial undertaking for someone new the concepts.
It doesn't that there is a fair amount of private stuff going on between window.class and the layout gadgets.
You might need to drop window.class and use a plain Intuition window.

Sounds to me like you may need to devise you own layout gadget if the standard one doesn't map well to the alien GUI. That will require lowlevl BOOPSI class coding and is ot a trivial undertaking for someone new the concepts.

I have considered this approach but as you point out that is bigger under taking. I am starting to consider not supporting the foreign GUI API and providing an Amiga specific implementation. I will work on getting my github repo up so you guys can see more clearly what I am attempting.
Thanks for feedback
Doug

Hi dbstastny. Just wanted to add some comments. As belated as I am. :-)
I tend to agree with LyleHaze here. If you need more control then Intuition is one way to go about it. As that will give you control over position and size. And also images which is useful. Which, if you wanted, could be used to customise your font rendering.
But how much control do you need? Do you also need to render custom border images and fonts? Or can you leave it up to the GUI engine?
If you wanted full control you could use Intuition. However, if all you really need is the ability to specify size and position, then you should consider GadTools. This uses the building blocks of Intuition to create the gadgets but simplifies the creation process and also generates a standard look. It doesn't layout for you but does allow you to specify position and size. You just need to calculate the width of any text inside so size fits. Which is easy enough.
Under the shadow of ReAction, with no gadget auto layout, GadTools has been relegated to being a menu generator. Since it allows fairly simple menu generation. In fact, one thing it does layout is menus, so it left a funny legacy there. :-)

I know this is quite old as I had been working getting my Blitzmax compiler issues PPC ABI sorted out and writing AHI sound driver interfacing with MiniGL. I got back to looking at this. And dumb as it was I figured it out. Not sure if its a bug with image derived objects like labels but when under NOLAYOUT layout(Say that fast) it does not respect initial coordinates. After creating the window I can move and control the image objects no problem location wise. So on to implementing a BlitzMax GUI. Just a little more effort on my part dealing with labels. Is there any sort of RTF control or am I going to have to write a texteditor that has colors as I cant seem to make a Textcontrol work at all respecting escape codes regardless of what the Documentation says.

And dumb as it was I figured it out. Not sure if its a bug with image derived objects like labels but when under NOLAYOUT layout(Say that fast) it does not respect initial coordinates.

LAYOUT_NoLayout means exatly that, you have to do all the work yuourself. Images don't behave like gadgets, the don't really have specific location, the same image can be drawn in different places in the GUI (and so shared between gadgets).

Is there any sort of RTF control or am I going to have to write a texteditor that has colors as I cant seem to make a Textcontrol work at all respecting escape codes regardless of what the Documentation says.

If you are refering o texteditor.gadget then no there is no full colour support. Even the escape code approach was pretty minimal, and less so in the AmigaOS 4 version.

Highlighting certain lines is the limit (see AutDoc Viewer as an example. of what I mean).

There is richeditor.gadget in use by codebench, but the API is not public. Not sure if there is any plans for it to be.

@Broadblues Yes I am looking at syntax highlighting. As for reason for no layout is BlitzMax GUI has a Layout mechanism built into its API for cross platform development. So if I can fulfill the various contracts of the maxguidriver. As for coloring of editor yes it is for syntax highlighting. I need a rudimentary html control as well I know there is a datatype but don't think its supports any hyperlinking. I have idea of some code that I can use to maybe build out support for hmtl control. Not full browser but good enough for help files.

Yes sir that is how I got it to work but I found it did not respect the coordinates when I create the object. I had to set them after I open the window. If curious I will post a simple example of what works and what didnt.

Thread Necro! Was this Beginner's Guide the one Jim Tubbs wrote, which Trixie followed up with "No don't do that. This is the best way" blog?

Never done any multi-tasking/GUI stuff before, so I need to learn a lot. I'm especially lost with how Wait() works. I have many questions, but want to learn as much as I can by reading docs/code before I start asking a torrent of questions.