TweetFollow Us on Twitter

DeeMaker
Volume Number:8
Issue Number:2
Column Tag:Tools of the Trade

Related Info: Dialog Manager Window Manager

DeeMaker for DeeManager

A new refreshing way to create human interfaces

By Dave Kelly, MacTutor Regular Contributing Author Don Bresee, MacTutor Technical Editor

If you’re tired of dealing with the Dialog Manager and wish that it would do more than it does, Dees are the answer. With Dees, you get all the functionality of the Dialog Manager and much more. DeeMaker for DeeManager version 1.0.4 enhances the standard Macintosh user interface without sacrificing the standard. [As of print time, n Dimensions is now shipping DeeMaker Version 1.1. - Ed.]

DeeMaker is a unique dialog creation tool designed to quickly develop robust, professional fixed layout windows. The three fixed layout constructs of the human interface are: modal, modeless and floating windows (windoids). DeeMaker has taken a big step forward in providing you with a MacDraw-like interface and the power of the best draw applications. Each data type has been crafted carefully so that runtime calls are minimized as you specify your intention with this high level tool. What’s really neat is that you’ve got a transparent way to substantially modify your human interface, without affecting your code and its recompilation.

DeeManager is designed from scratch to work with an object-driven model. Each item is an instance of an object. As objects, all items share several important attributes. One of these attributes is the item method interface.

Each Dee item is completely customizable because DeeManager has a full-range messaging system. With DeeMaker you specify the messages that your method wants to receive and install (or engage) the method by calling the DeeManager function EngageMethod(ProcPtr theMethod; id: Integer). All methods are of the form: MyMethod(Var DeeMessages: msg). This allows creation of just about any human interface effect you could want.

The on_Action message is especially important because it allows you to create modeless windows whose entire action code resides in a separate method. You would never need to fix your main event loop. This and other design factors of DeeManager will let you create very clean and maintainable programs.

Each item has an optional member list. The simplest member list is a string list, such as a STR# resource. Suppose you had a check box that could have one of three titles. You would just assign three members and change the items current member to change the title. The member list is part of the item object itself and thus all the data that could ever appear on the screen will reside in one place. You may have buttons, static text items, or windows with several titles.

Member list elements are objects too, by default they contain a string, but could have other data. This is how DeeManager implements the Alert mechanism for you. You assign an “alert meaning” to each string of a member list associated with a static text item. The meaning being, Note, Stop or Caution Alert. Then, with a single call to DeeManager: DeeAlert(deeId: Integer; member: Integer), an alert is displayed with the appropriate alert icon. Changing later the type of an alert is done with DeeMaker and is transparent to the program.

Parameter substitution capabilities are far and above the Dialog Manager also. DeeManager allows 26 parameters instead of 4. Button, CheckBox, Radio, and Window titles, as well as static text items are analyzed by DeeManager for parameter substitution. The key sequence being “=a” thru “=z” (instead of “^0” thru “^3”). Any of the built-in 26 params can be loaded at runtime with one of several DeeManager parameter loader functions.

Figure 1: Method Interface Editor

Another feature of each item object is its ShineThrough™ property. This is perhaps the most profound feature of this development tool. You have seen conventional Draw/CAD applications that give multiple views. The interface paradigm there is the creation of layers without addressing the physical aspect of space. DeeMaker’s paradigm is the use of a view space. You don’t have to create layers - as each Dee is automatically postulated to have a view space (currently 32 views). This presupposed space allows for the ShineThrough™ phenomena to occur and for the easiest most intuitive way we have ever seen of addressing the problem of superimposition of human interface elements. With DeeMaker you simply assign a ShineThrough™ vector to an item, to allow the item to be active through every view it shines through.

Figure 2: Member Editor

What’s really great about DeeMaker is that it was actually created with itself, and it uses ShineThrough™ to implement its elegant type editors. For example, the Text editor has another view for setting edit type attributes. When the EditTypes button is pressed, some 40 elements swiftly change position. In conventional tools you would have to write 40 calls in your program to physically move the items. Here, you just call DeeManager SetView(2) and what you saw in the DeeMaker editing environment is what you get at runtime: all items which either belong to view 2 or shine through to view 2 from view 1 are presented, all others are hidden. No item is physically moved anywhere; rather, you, the observer, moves to another view or dimension. There is a tremendous time saving here. Using DeeMaker, a non-programmer could easily stupefy an experienced developer who could spend hours to implement, in hard coded sweat, the movement of items.

Here is a small example of view usage. This is the modeless handler method of DeeMaker’s ShortCuts taken from its manual. Such a handler would process any number of shortcut views (up to 32) without any change to code.

{1}

Procedure ShortCutsHandler(Var Msg: DeeMessage);
CONST
 bNext  = OK;
 bPrev  = 2;

VAR
 whichView: Integer;
 whichIsBold: Integer;

BEGIN
 WITH Msg, dResult DO
 CASE dMessage OF
 on_Activate:
 BEGIN
 IF LastDeeView(whichView) THEN
 whichIsBold := bPrev
 ELSE
 whichIsBold := bNext;
 DimItem(Not dActivate, whichIsBold)
 END;

 On_Action:
 CASE Id OF
 bPrev:
 BEGIN
 whichView := TheDeeView;
 {previous button belongs to view 2}
 IF whichView = 2 THEN  
 SetDeeKey(Char(13), bNext);
 SetView(whichView - 1);
 END;
 
 bNext:
 BEGIN
 whichView := TheDeeView;
 SetView(whichView + 1);
 IF LastDeeView(whichView) THEN
 SetDeeKey(Char(13), bPrev);
 END
 END
 END
END; {of ShortCutsHandler}

Figure 3: DeeMaker Tool Palette

DeeManager includes support for windoids. These windoids are defined with DeeMaker to have a windoid frame and otherwise are Dees with all the benefits of being a Dee. n Dimensions has solved a very sticky problem here for the entire developer community: how to implement easily any number of floating windows that might be either modeless (such as DeeMaker’s tool palette) or appear in modal contexts (being removed when the modal window is removed from the screen). A brilliant idea was implemented here to allow your code to be orderly and modular. A windoid may be linked with the DeeManager function Link_Windoid(theWindoid, theDee: DeePtr). After this function call, the windoid is linked to a Dee owner, and actions in the windoids are reported to the controlling code of the owner. Not only that, any windoid can be torn off any menu by calling Link_Menu(theWindoid: DeePtr; theMenu: MenuHandle). DeeManager tears off the windoid palette for you and when MenuSelect returns -1, you call Tear_Windoid() to physically move the windoid to a new place.

All the sticky problems of having another floating window layer on top of regular windows are seamlessly handled by DeeManager. You only need to substitute in your event loop at the critical places, old window manager calls with matching DeeManager calls. Thus HideWindow, SelectWindow, DragWindow are replaced with Hide_Window, Select_Window and Drag_Window. Once you write a “DeeManager compatible event loop” (Examples are provided) - any number of windoids and modeless windows can be added to your interface as your project develops. Consider that you can change a modeless window to be floating without affecting your program. This change that would otherwise result in hundreds of source line changes, is entirely transparent using the DeeMaker development tool.

At the heart of DeeMaker is a powerful toolkit called DeeManager (25K). This is the runtime package which supports your Dee dialogs. You almost can’t tell that DeeManager wasn’t originally a part of the Macintosh Toolbox, because DeeManager has A-Trap interface. This is the first commercial product to come with such an interface. All DeeManager functions are inline substituted for A-Trap code. (To do that only a single patch is performed. The original Dialog/Window managers are untouched and are fully operable.)

You will gain access to DeeManager through a small object file, DeeLib.o (1K), which is linked to your modules. DeeLib.o contains the glue functions, OpenDeeMgr and CloseDeeMgr, to establish communication between DeeManager which resides in a ‘DeeM’ resource and your code. DeeManager was written entirely in 68000 macro assembly language. Efficiency was designed into it from the very start.

DeeManager was designed with System 7.0 in mind. Balloon help is provided by adding a help member to your item object. The developers of DeeMaker for DeeManager have kept up with the latest and greatest System developments. Many of the concepts you see in DeeMaker were taken from observing how the HyperCard interface works. In the manual, n Dimensions formally acknowledges HyperCard as a great source of inspiration.

However inspirational, regretfully, DeeManager 1.0.4 doesn’t yet work with HyperCard 2.0. (Previous versions such as HyperCard 1.x.x use DeeManager correctly.) This is not because anything is wrong with DeeManager, but rather the architects of HyperCard have limited the freedom of external windows. Hopefully, someday Claris will rectify this.

DeeMaker moves far beyond the limits of the Dialog Manager that we are familiar with (including all the prototypers which generate code for it). You still have the traditional tools, but now you use them in a new way. DeeMaker allows you to choose flow of control, dimming, hiding, edit types, styles, window frames, grouping, command keys, initializers, ornamentation, automated edit sorting, fixed item identities, Extended List Format™, accurate alignments and other capabilities. In addition, you can easily assign key equivalents to any radio button, check box or button.

DeeMaker’s Group command permits all the necessary grouping you will need. You simply select the items and choose the Group command. Thus, Radios, Buttons, Edit Texts, CheckBoxes, PopUp and EditText items, can be grouped. Each group has its own distinct meaning implemented by DeeManager and your methods.

The following Dee is presented by DeeMaker when you select the GetInfo command for a Dee resource. The Attributes are implemented by grouping the CheckBoxes and assigning to each (with DeeMaker CheckBox editor) its InsideMac (Resource Manager chapter) bit value. The program need only have 2 lines of code to create the proper program interchange. theAttrs := GetCGroup(cResAttr); or SetCGroup(theAttrs , cResAttr). The synopsis was created with parameter substitution and member lists.

Figure 4: Dee Info

And if you wonder what is Extended List Format (ELF). It is DeeMaker’s concept of having its List items extend the familiar List Manager to create many types of Lists without having to write LDEFs. Lists are also part of a Dee’s TabTrail™ (System 7.0 feature) and receive keyboard events just like Editable text items. ELF format has allowed DeeManager to be able to integrate the Menu Manager and List Manager, supplying Menu2List and List2Menu which preserve all information. This is another way DeeManager has become like a master manager on top of the old toolbox, uniting distant formats into harmony.

DeeMaker has many features and we could not possibly cover all of them here. Each data type gives you more power than you would ever expect to get. All of these add tremendous savings in time and effort and return your investment in the product very quickly.

There is one problem that you will encounter if you use QuicKeys (and I hate not having my QuicKeys). DeeManager does not use the Control Manager for buttons (push buttons, check boxes and radio buttons). This means the “Buttons” feature in QuicKeys will not work with any Dee. You can sometimes overcome this by using the “Click” feature but not in most cases. All other features of QuicKeys seem to work fine with Dees. I did discover that floating windows cause a general confusion problem with QuicKeys, this is not due to Dees but instead will happen with any application that uses floating windows. This is due to the fact that the active window, whether it is a dialog (modal or modeless) or a document window, will not be the first window in the window list if floating windows are present. QuicKeys usually locates the desired window by counting windows starting with the frontmost. However, QuicKeys can also locate the desired window by title. This is only useful if the title never changes.

The package comes in an expensive customized three ring notebook. Pascal, C and Motorola 68000, are the preferred environments. But you could easily adapt DeeManager to work in any environment that uses A-Trap interface, such as Common Lisp or Fortran. The manual has three major sections: (1) Touring Dee Dialogs which covers all Dee human interface concepts as an introduction to Dee dialogs; (2) DeeMaker tutorial which describes the attributes of Dees and their capabilities, and (3) Inside DeeManager - a description of all DeeManager resources, data types and functions. A summary of all DeeManager functions and procedures is given for 68000, Pascal, and C. Unfortunatly, no index is provided and as with many programming tool manuals, some sections or statements don’t make a great deal of sense until you have actually played with the code. A few additional examples in other languages (e.g. Pascal) would be extremely helpful and at least one should be in an old fashioned procedural environment (for us dummies who are still a bit inexperienced with objects).

A few examples are provided in the manual but the DeeMaker bundle comes with a complete C++ example, DeeApp™, and all the source code that is necessary to immediately start deriving professional programs. This collection of classes demonstrates very clearly the usage of DeeManager. It also includes a very useful MPW tool MenuRez for allowing DeeApp applications to have menu command numbers independent of menu id and item position.

A final note about the screen shots in this article. DeeManager has a very convenient function SnapDee(theDee: DeePtr): PictHandle. DeeMaker implements its snapshot commands by calling this DeeManager function which takes any Dee and translates it to QuickDraw PICT format. Instead of taking screen snapshots which are bitmaps, DeeMaker’s RedSnapper (Cmd-Shift-7), provides the same effect only with PICT opcodes which take 1/10 of the space of the picture as bits, allowing you to print to a PostScript printer any Dee window (SnapDee snaps window frames too) with laser quality. This is how we generated the above snapshots for this article.

Bottom Line

DeeManager is a very powerful development tool with a well thought out design. The tool is set up in a logical manner allowing for easy customization of the basic behavior of Dees. DeeMaker is an effective design tool that allows even the novice programmer to quickly and easily design a full-featured, working interface in almost no time. It is complete and it is fast. The product’s only drawbacks are that buttons won’t work with utilities such as QuicKeys because controls are not always implemented using the Control Manager. In fairness, n Dimensions is aware of this and will be working on the problem. Overall, two thumbs up!

DeeMaker for DeeManager includes a license to make 100 copies of DeeManager. A flat fee is available for unlimited copies per end user. DeeMaker is licensed for use on one computer just as most commercial software is. Site licenses may be purchased for additional copies.

n Dimensions has a permanent folder on AppleLink at location: “Software Sampler:3rd Party Demos/Updates:Software Updates:n Dimensions.” You may download from that location an unabridged copy of DeeMaker.

 

Community Search:
MacTech Search:

Software Updates via MacUpdate

Latest Forum Discussions

See All

Tokkun Studio unveils alpha trailer for...
We are back on the MMORPG news train, and this time it comes from the sort of international developers Tokkun Studio. They are based in France and Japan, so it counts. Anyway, semantics aside, they have released an alpha trailer for the upcoming... | Read more »
Win a host of exclusive in-game Honor of...
To celebrate its latest Jujutsu Kaisen crossover event, Honor of Kings is offering a bounty of login and achievement rewards kicking off the holiday season early. [Read more] | Read more »
Miraibo GO comes out swinging hard as it...
Having just launched what feels like yesterday, Dreamcube Studio is wasting no time adding events to their open-world survival Miraibo GO. Abyssal Souls arrives relatively in time for the spooky season and brings with it horrifying new partners to... | Read more »
Ditch the heavy binders and high price t...
As fun as the real-world equivalent and the very old Game Boy version are, the Pokemon Trading Card games have historically been received poorly on mobile. It is a very strange and confusing trend, but one that The Pokemon Company is determined to... | Read more »
Peace amongst mobile gamers is now shatt...
Some of the crazy folk tales from gaming have undoubtedly come from the EVE universe. Stories of spying, betrayal, and epic battles have entered history, and now the franchise expands as CCP Games launches EVE Galaxy Conquest, a free-to-play 4x... | Read more »
Lord of Nazarick, the turn-based RPG bas...
Crunchyroll and A PLUS JAPAN have just confirmed that Lord of Nazarick, their turn-based RPG based on the popular OVERLORD anime, is now available for iOS and Android. Starting today at 2PM CET, fans can download the game from Google Play and the... | Read more »
Digital Extremes' recent Devstream...
If you are anything like me you are impatiently waiting for Warframe: 1999 whilst simultaneously cursing the fact Excalibur Prime is permanently Vault locked. To keep us fed during our wait, Digital Extremes hosted a Double Devstream to dish out a... | Read more »
The Frozen Canvas adds a splash of colou...
It is time to grab your gloves and layer up, as Torchlight: Infinite is diving into the frozen tundra in its sixth season. The Frozen Canvas is a colourful new update that brings a stylish flair to the Netherrealm and puts creativity in the... | Read more »
Back When AOL WAS the Internet – The Tou...
In Episode 606 of The TouchArcade Show we kick things off talking about my plans for this weekend, which has resulted in this week’s show being a bit shorter than normal. We also go over some more updates on our Patreon situation, which has been... | Read more »
Creative Assembly's latest mobile p...
The Total War series has been slowly trickling onto mobile, which is a fantastic thing because most, if not all, of them are incredibly great fun. Creative Assembly's latest to get the Feral Interactive treatment into portable form is Total War:... | Read more »

Price Scanner via MacPrices.net

Early Black Friday Deal: Apple’s newly upgrad...
Amazon has Apple 13″ MacBook Airs with M2 CPUs and 16GB of RAM on early Black Friday sale for $200 off MSRP, only $799. Their prices are the lowest currently available for these newly upgraded 13″ M2... Read more
13-inch 8GB M2 MacBook Airs for $749, $250 of...
Best Buy has Apple 13″ MacBook Airs with M2 CPUs and 8GB of RAM in stock and on sale on their online store for $250 off MSRP. Prices start at $749. Their prices are the lowest currently available for... Read more
Amazon is offering an early Black Friday $100...
Amazon is offering early Black Friday discounts on Apple’s new 2024 WiFi iPad minis ranging up to $100 off MSRP, each with free shipping. These are the lowest prices available for new minis anywhere... Read more
Price Drop! Clearance 14-inch M3 MacBook Pros...
Best Buy is offering a $500 discount on clearance 14″ M3 MacBook Pros on their online store this week with prices available starting at only $1099. Prices valid for online orders only, in-store... Read more
Apple AirPods Pro with USB-C on early Black F...
A couple of Apple retailers are offering $70 (28%) discounts on Apple’s AirPods Pro with USB-C (and hearing aid capabilities) this weekend. These are early AirPods Black Friday discounts if you’re... Read more
Price drop! 13-inch M3 MacBook Airs now avail...
With yesterday’s across-the-board MacBook Air upgrade to 16GB of RAM standard, Apple has dropped prices on clearance 13″ 8GB M3 MacBook Airs, Certified Refurbished, to a new low starting at only $829... Read more
Price drop! Apple 15-inch M3 MacBook Airs now...
With yesterday’s release of 15-inch M3 MacBook Airs with 16GB of RAM standard, Apple has dropped prices on clearance Certified Refurbished 15″ 8GB M3 MacBook Airs to a new low starting at only $999.... Read more
Apple has clearance 15-inch M2 MacBook Airs a...
Apple has clearance, Certified Refurbished, 15″ M2 MacBook Airs now available starting at $929 and ranging up to $410 off original MSRP. These are the cheapest 15″ MacBook Airs for sale today at... Read more
Apple drops prices on 13-inch M2 MacBook Airs...
Apple has dropped prices on 13″ M2 MacBook Airs to a new low of only $749 in their Certified Refurbished store. These are the cheapest M2-powered MacBooks for sale at Apple. Apple’s one-year warranty... Read more
Clearance 13-inch M1 MacBook Airs available a...
Apple has clearance 13″ M1 MacBook Airs, Certified Refurbished, now available for $679 for 8-Core CPU/7-Core GPU/256GB models. Apple’s one-year warranty is included, shipping is free, and each... Read more

Jobs Board

Seasonal Cashier - *Apple* Blossom Mall - J...
Seasonal Cashier - Apple Blossom Mall Location:Winchester, VA, United States (https://jobs.jcp.com/jobs/location/191170/winchester-va-united-states) - Apple Read more
Seasonal Fine Jewelry Commission Associate -...
…Fine Jewelry Commission Associate - Apple Blossom Mall Location:Winchester, VA, United States (https://jobs.jcp.com/jobs/location/191170/winchester-va-united-states) Read more
Seasonal Operations Associate - *Apple* Blo...
Seasonal Operations Associate - Apple Blossom Mall Location:Winchester, VA, United States (https://jobs.jcp.com/jobs/location/191170/winchester-va-united-states) - Read more
Hair Stylist - *Apple* Blossom Mall - JCPen...
Hair Stylist - Apple Blossom Mall Location:Winchester, VA, United States (https://jobs.jcp.com/jobs/location/191170/winchester-va-united-states) - Apple Blossom Read more
Cashier - *Apple* Blossom Mall - JCPenney (...
Cashier - Apple Blossom Mall Location:Winchester, VA, United States (https://jobs.jcp.com/jobs/location/191170/winchester-va-united-states) - Apple Blossom Mall Read more
All contents are Copyright 1984-2011 by Xplain Corporation. All rights reserved. Theme designed by Icreon.