Jump to content
IGNORED

Diamond in the Rough - Diamond GOS Dialog Reference Sheet


RSS Bot

Recommended Posts

When starting a Diamond project, I have a tendency to utilize a lot more design time before sitting down in front of a computer. Sketching out displays, icons and menus seem to consume a lot of time but having this all worked out before committing it to code helps.

(Random Thought - Remember going into the office supply store and finding a whole section of graph paper. This time I had to ask the clerk where it was. He pointed me toward the paper section and said, "Its next to the carbon paper." I found one - 5 squares to the inch spiral binder.)

Probably the first thing that I design is the title dialog box (sometimes called "about" or "Info…" in the drop down menu. It holds important information about the title, version #, author and the date. It kind of represents the big picture and helps solidify a commitment to the project.

And…. Each time I start coding a project I seem to be spending a day or two trying to make the screen look like the sketches. And… I always say that I'm going to take notes on the process so I don't have relearn it each time. And…. Each time I didn't.

So this time, I made this reference sheet on how to define a dialog box, put a text object into it and define the hole box as a touch area. All the information I need to create a simple info box. Its definitely not a substitute for the manual.



All the information is in the Diamond Develop Manual but scattered on several pages though out the manual. My biggest problem was figuring out the reference points. Where the 0,0 reference point is seems to change. I concluded that the touch areas are located using the upper left corner on the outer edge of the boarder. The text is place in reference to the upper left-corner inside the boarder and is calculated using the lower left corner of the first print character.

The other thing to keep straight is the count units. Are you counting bytes, characters, color clocks, pixels or scan lines?

I did the rough draft of the reference sheet and tested it by designing the HELLO WORLD dialog box. I found one misconception on the reference sheet and 3 mistakes in math. I believe those have been corrected. I hope to be running more tests before the end of the year. I'll up date with any refinements in the comment area, so check back here if you should ever be in need of a simple text dialog box.

This HELLO WORD Dialog box was programed using M65 and the Diamond macro library from the Diamond Develop Kit.

0100 ;HELLO WORLD dialog example
0110 ;
0120 .OPT NO LIST
0130 *= $4000
0140 ;
0150 .INCLUDE #D:DMACROS1.M65
0160 ;
0170 HELLOOBJ
0180 .BYTE 1 ;TEXT OBJECT
0190 .WORD HELLOSTRING ;ADDRESS
0200 .WORD 0 ;START X
0210 .WORD 8 ;BOTTOM OF FIRST LINE OF TEXT
0220 .BYTE 8 ;SCAN LINES/LINE FEED
0230 .BYTE 255 ;END OF LIST
0235 ;
0240 HELLOSTRING ; TEXT
0250 .BYTE "HELLO",13 ;LINE FEED
0260 .BYTE "WORLD"
0270 .BYTE 0 :END STRING
0275 ;
0280 HELLOTOUCH
0290 .BYTE 0,28,0,36 ;WHOLE BOX
0300 .BYTE 255 ;END OF LIST
0310 ;
0320 ;
0330 START ; DIAMOND MACROS
0340 INIT 0
0350 DODIALOG 7,32,HELLOOBJ,HELLOTOUCH
0360 EVENTDIALOG
0370 RELEASEDIALOG
0380 EXIT
0390 EXECDESKTOP
0400 ;
0410 *= $02E0
0420 .WORD START

Attached File(s)


http://atariage.com/forums/blog/556/entry-14627-diamond-gos-dialog-reference-sheet/
Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...