RELEASE NOTES - 12/08/96 This is the first release of the AmigaOberon interface for BGUI V41.7. Although all attempts have been made to ensure accuracy, I'm sure there are latent bugs that will appear with more extensive usage. Please submit any bug reports to the email address listed below so they may be incorporated in future releases. Bgui.mod ======== This module contains the Oberon equivalents to all constants, structures and functions for the BGUI library. All method structures are defined as a sub class of . This enables easy type casting of method structures in all dispatched procedures. For example: From interfaces/Intuition.mod ==> structure Msg is defined: Msg *= STRUCT methodID : LONGINT; END; From Bgui.mod ==> structure mDragPoint is defined mDragPoint *= STRUCT( msg *: i.Msg ) (* BASE_DRAGQUERY *) gInfo *: i.GadgetInfoPtr; (* GadgetInfo *) source *: Object; (* Object querying. *) mouse *: mdpMouse; (* Mouse coords. *) END; In a dispatched procedure defined: PROCEDURE mAny * ( cl : i.IClassPtr; obj : b.Object; msg : i.MsgPtr ):LONGINT The actual data structure passed via the MsgPtr would be msg = STRUCT methodID : LONGINT; gInfo : i.GadgetInfoPtr; source : Object; mouse : mdpMouse; END; All fields then can be referenced by simple casting msg(b.mDragPoint)).gInfo, msg(b.mDragPoint).source, etc. Demo "FieldListH.mod" is a custom listview class that can be used as a reference. I have added some hook definitions to facilitate similar type casting for hook procedures. Most non-method structures have been defined as a sub-class of Bgui.ArgsDesc (an empty structure), to simplify type casting in hook procedures. See demo programs "BGUIScrollWindow.mod" and "Hscroll.mod" for examples of hook usage. NOTE: The normal Oberon reduction of C data names to their simplest form was not done for this library. There would have been too many duplicate names, so the naming reduction was done ONLY for the above mentioned structures definitions. BguiMacro.mod ============= This module includes most of the "C" macros converted to procedures that perform the same functionality. Note the word "most". Oberon does not include a macro preprocesser nor does AmigaOberon allow passing non-builtin functions as varargs, so short of programming some sort of push-pop stack and then creating the overall object structure from this stack, using macros as a single long definition can not be used. Rather, following a method used by MUIBuilder (oops), each object must be created individually and then added to their appropriate group. The demo programs should provide adequate examples of this method. I'm hoping to create a manual macro processor that will enable the insertion of the BGUI conversions through an Arexx port to your editor. i.e. C MACRO Oberon BGUI CODE ------- ---------------------------------------------- Startmember, ==> b.groupMember (* Startmember *) FixMinSize, ==> b.lgoFixMinWidth, e.true, (* FixMinSize *) b.lgoFixMinHeight, e.true, . . etc. BGUI uses free vertical and free horizontal for creation of it's objects. In the macro definitions for the objects listed below, a sizing macro is included after the object creation. I discovered that the sizing attributes had to be applied as the object was added to a group: Original C macros from list below: StartMember, obj, EndMember, Modified C Macros: StartMember, obj, , EndMember, ^ ^ | | Object macro below ----+ +---- add sizing macro here I tried "SetAttrs" and "SetGadgetAttrs" in the macro procedures but neither worked. If anyone knows of a workaround for this, please let me know so I can update the macro procedures. MACRO POCEDURE SIZING MACRO ------------------ ------------ PrefCheckBox FixMinSize CheckBox FixMinSize KeyCheckBox FixMinSize XenCheckBox FixMinSize XenKeyCheckBox FixMinSize RightMx FixMinSize LeftMx FixMinSize RightMxKey FixMinSize LeftMxKey FixMinSize Tabs FixMinHeight TabsKey FixMinHeight TabsEqual FixMinHeight TabsEqualKey FixMinHeight USDTabs FixMinHeight USDTabsKey FixMinHeight USDTabsEqual FixMinHeight USDTabsEqualKey FixMinHeight VertSeparator FixMinWidth VertThinSeparator FixMinWidth HorizSeparator FixMinHeight TitleSeparator FixMinHeight HTitleSeparator FixMinHeight CTitleSeparator FixMinHeight CHTitleSeparator FixMinHeight TitleSeparatorLeft FixMinHeight HTitleSeparatorLeft FixMinHeight CTitleSeparatorLeft FixMinHeight CHTitleSeparatorLeft FixMinHeight DemoCode.mod ============ This module provides the "Tell" function used by the BGUI demo programs for user notification. All notifications are done through the use of a BGUI requester as opposed to a console window. It's somewhat surprising that a library for creating GUI applications still uses a console window for notification :-). The "C" initialization code was removed as this is handled automatically in Oberon. Demo Programs: ============= A cross section of demo programs is included. Examples of drag'n'drop, border gadgets, scrolling bitmaps, a horizontal scrolling listview, custom class usage, etc. can be found in the demos. Bugs: BguiDemo - The bitmap backfill does not display properly. I suspect my definition of the bgui.Pattern structure to be the culprit. I'll keep trying. BGUIScrollWindow - The window is not properly refreshed after resizing the window. Any following action, click on the sizing gadget, horizontal scroll, vertical scroll, etc., properly refreshes the display. This also occurs in the original C version by Reinhard Katzmann (scrwin06.lha). I must admit, I was absolutely in shock when this program worked successfully the first time after I got a clean compile. Bugs, Comments, Suggestions: =========================== Direct any bug reports, comment and suggestions to: Larry Kuhns email: lakuhns@cis.cisnet.com (preferred) or lakuhns@theonramp.net Credits: ======= MUIBuilder Copyright © 1994 by Eric Totel Albert Weinert for his masterful work on the MUI Oberon Interface that was used as a pattern for the BGUI inteface. All demo programs were converted from examples included in the BGUI distribution or from the BGUI ftp sites. The original authors names (if available) have been retained as part of the program source. P.S. Please excuse any mis-spelling of words. My 'R' and 'T' keys are somewhat tempermental.