Who's Online
69 user(s) are online (
28 user(s) are browsing
Forums )
Members: 1
Guests: 68
salass00 ,
more...
Headlines
aurafly.lha - audio/misc
Feb 16, 2026
amiarcadia.lha - emulation/gamesystem
Feb 16, 2026
amigadiskbench.lha - utility/benchmark
Feb 16, 2026
autodocviewer.lha - development/utility
Feb 12, 2026
libsdl3_mixer.lha - development/library/audio
Feb 11, 2026
iconecta.lha - network/misc
Feb 11, 2026
yt.lha - video/misc
Feb 11, 2026
rave.lha - audio/edit
Feb 8, 2026
libxmp.lha - development/library/audio
Feb 8, 2026
videovortex.lha - video/play
Feb 8, 2026
Topic options
View mode
Newest First
New tutorial online
Posted on:
2011/8/5 6:57
#1
Amigans Defender
Joined: 2009/5/1 17:57Last Login
: Today 9:41
From Czech Republic
Group:
Registered Users Staff members Moderators
A new instalment in my loose series of tutorials on OS4 user interface programming can now be found
on OS4coding.net , this time with a full working C code example. Enjoy!
The
Rear Window blog
AmigaOne X5000 @ 2GHz / 4GB RAM / Radeon RX 560 / ESI Juli@ / AmigaOS 4.1 Final Edition
SAM440ep-flex @ 667MHz / 1GB RAM / Radeon 9250 / AmigaOS 4.1 Final Edition
Re: New tutorial online
Posted on:
2011/8/5 8:08
#2
Just can't stay away
Joined: 2009/2/9 19:32Last Login
: 2020/12/21 15:57
From Brussels Belgium
Group:
Registered Users
Thank you very much,
very instructive tutorial.
We sure do need good C programmers, i could not resist though:
a Gui4 Cli look alike
G4C
WINBIG - 1 - 1 315 200 "Gui4Cli AppWindow"
WINTYPE 11110001
xONLOAD
GuiOpen #this
xONCLOSE
GuiQuit #this
xAPPWINDOW File_
ChangeGad #this 1 0 0 315 200 $File_
GadRedraw #this 1 0 0 0 0
xBUTTON 0 0 315 200 "Drop a file icon here!"
GadID 1
Attr frame 31
Edited by JosDuchIt on 2011/8/5 8:50:16
Re: New tutorial online
Posted on:
2011/8/5 9:21
#3
Home away from home
Joined: 2007/9/11 11:31Last Login
: Today 10:29
From Russia
Group:
Registered Users
@Trixie New article also pretty interesting. Few more articles of this kind, and we can make a os4-progamming-book at last
Re: New tutorial online
Posted on:
2011/8/5 9:44
#4
Amigans Defender
Joined: 2009/5/1 17:57Last Login
: Today 9:41
From Czech Republic
Group:
Registered Users Staff members Moderators
@ kas1e
Quote:
Few more articles of this kind, and we can make a os4-progamming-book at lastActually, the material for my articles comes from the sketches I wrote for the OS4 Programmer's Guide (which unfortunately never took off).
The
Rear Window blog
AmigaOne X5000 @ 2GHz / 4GB RAM / Radeon RX 560 / ESI Juli@ / AmigaOS 4.1 Final Edition
SAM440ep-flex @ 667MHz / 1GB RAM / Radeon 9250 / AmigaOS 4.1 Final Edition
Re: New tutorial online
Posted on:
2011/8/5 10:12
#5
Quite a regular
Joined: 2006/11/22 17:57Last Login
: 2025/8/13 10:03
From Italy, Rome
Group:
Registered Users
Thank you. Tutorial are always welcome. Keep up with the good work.
Retired
Re: New tutorial online
Posted on:
2011/8/5 20:58
#6
Just popping in
Joined: 2007/9/5 21:15Last Login
: 2025/5/23 6:03
Group:
Registered Users
Really a pitty. Any chance to release some pre-version of your tutorial to public?
Re: New tutorial online
Posted on:
2011/8/5 21:46
#7
Just can't stay away
Joined: 2006/12/1 18:01Last Login
: Yesterday 22:59
From Copenhagen, Denmark
Group:
Registered Users
Good job, Trixie, keep 'em coming!
Quote:
Reth wrote: Really a pitty. Any chance to release some pre-version of your tutorial to public? Isn't that what he is doing already?
Best regards,
Niels
Re: New tutorial online
Posted on:
2011/8/9 10:11
#8
Just can't stay away
Joined: 2009/2/9 19:32Last Login
: 2020/12/21 15:57
From Brussels Belgium
Group:
Registered Users
I have been studying the example and have some questions about declaring structures and opeing libraries; - at line 40/41 i read ( not in 'main') struct Library *IntuitionBase, *UtilityBase; struct IntuitionIFace *IIntuition; Why is it not needed to declare *IUtility here ? - more generally: why not declare all used structures (in a one-file source) at the beginning? Seems easier to maintain using such a standard, or are there reasons not to ?
Re: New tutorial online
Posted on:
2011/8/9 11:48
#9
Amigans Defender
Joined: 2009/5/1 17:57Last Login
: Today 9:41
From Czech Republic
Group:
Registered Users Staff members Moderators
@JosDuchIt
Quote:
Why is it not needed to declare *IUtility here ?Because the example does not call any Utility Library functions. The library is opened to provide the hook functionality but you don't need the interface unless you want to use the library's functions yourself.
Quote:
why not declare all used structures (in a one-file source) at the beginning?What exactly do you mean?
The
Rear Window blog
AmigaOne X5000 @ 2GHz / 4GB RAM / Radeon RX 560 / ESI Juli@ / AmigaOS 4.1 Final Edition
SAM440ep-flex @ 667MHz / 1GB RAM / Radeon 9250 / AmigaOS 4.1 Final Edition
Re: New tutorial online
Posted on:
2011/8/9 12:07
#10
Home away from home
Joined: 2006/11/20 16:26Last Login
: Yesterday 22:23
From Norway
Group:
Registered Users
@JosDuchIt Depending on how you compile your program. You don't need to open and close libraries and you don't need to declare the interfaces, Just include the proto types. Compile your program whit GCC myapp.c -o myapp.exe -lauto if you don't like to type IExec/IDOS in front of every exec command, you can typeGCC myapp.c -o myapp.exe -lauto -D__USE_INLINE__
(NutsAboutAmiga) Basilisk II for AmigaOS4 AmigaInputAnywhere Excalibur and other tools and apps.
Re: New tutorial online
Posted on:
2011/8/9 12:48
#11
Amigans Defender
Joined: 2009/5/1 17:57Last Login
: Today 9:41
From Czech Republic
Group:
Registered Users Staff members Moderators
Quote:
LiveForIt wrote: Compile your program whit GCC myapp.c -o myapp.exe -lauto No, don't do that when using ReAction for GUI. Read
the first tutorial , section 2.3.
The
Rear Window blog
AmigaOne X5000 @ 2GHz / 4GB RAM / Radeon RX 560 / ESI Juli@ / AmigaOS 4.1 Final Edition
SAM440ep-flex @ 667MHz / 1GB RAM / Radeon 9250 / AmigaOS 4.1 Final Edition
Re: New tutorial online
Posted on:
2011/8/9 13:56
#12
Just can't stay away
Joined: 2009/2/9 19:32Last Login
: 2020/12/21 15:57
From Brussels Belgium
Group:
Registered Users
@trixie
Quote:
Quote: Quote:why not declare all used structures (in a one-file source) at the beginning? What exactly do you mean? I think an erroneous read of your source made me miss some declarations (besides IIntuition) As i missed IIntuition and thought others were only declared in main or in the functions, i was wondering in which cases there is an advantage to do that. I did not see one, but then some parts of C are really puzzling to me.
Re: New tutorial online
Posted on:
2011/8/9 14:36
#13
Amigans Defender
Joined: 2009/5/1 17:57Last Login
: Today 9:41
From Czech Republic
Group:
Registered Users Staff members Moderators
@JosDuchIt
I always prefer declaring local variables for data that is not needed throughout the entire lifetime of the program. A good example is the pointer to the Intuition window: you'll see in
the tutorial example that instead of declaring and keeping one global variable, the struct Window pointer is declared three times locally (inside the functions) and is obtained from the window object when it is needed. It does not have any particular advantage in this example but avoiding globals is good coding practice because it is generally safer.
The
Rear Window blog
AmigaOne X5000 @ 2GHz / 4GB RAM / Radeon RX 560 / ESI Juli@ / AmigaOS 4.1 Final Edition
SAM440ep-flex @ 667MHz / 1GB RAM / Radeon 9250 / AmigaOS 4.1 Final Edition
Currently Active Users Viewing This Thread:
1
(
0 members
and 1 Anonymous Users
)