America Online APPLE II DEVELOPMENT FORUM CONFERENCE LOG Tuesday, December 29, 1992 10:00 p.m. Eastern Time Topic: Open Topic Forum Leader: Gary Jacobson (AFL GaryJ) AFL GaryJ Welcome to the Apple II Development Forum! Tonight, we have an open topic. We can discuss AFL GaryJ what ever is on your mind (which is what we do normally anyway, so nobody should be hindered AFL GaryJ by the "open topic" format :) AFL Marty I was wondering if anyone saw the question I posted... AFL Marty more to the point, does anyone have an answer :) AFL Marty The one I posted in Let's Discuss. AFC DYAJim Marty- I don't really know Pascal, but it looks like you can access any AFC DYAJim longint as the following structure: AFC DYAJim longint.msw (word) AFC DYAJim longint.lsw (word) AFC DYAJim (or actually, switch the two) AFC DYAJim msw=most significant word, lsw=least significant word AFL Marty I understand what's being done. I just don't understand the mechanism AFL Marty by which it's accomplished. AFC DYAJim oh.. AFA Jay It is strange, Marty...the true/false thing throws me. AFL Marty Precisely. AFA Jay case boolean of ... strange. AFL Marty It works though. I copied it verbatim, put it into a program, and it works. AFC DYAJim yeah.. bizarre :) AFA Jay the rest of it makes sense, but what it checks for the true or false, I dunno. AFL Marty Thanks anyway. Maybe someone will post an answer soon. AFL Marty Basically the problem is to split a longint up into two numbers... AFL Marty the Pascal code looks like AFL Marty type AFL Marty long = record AFL Marty case boolean of AFL Marty true : (long: longint); AFL Marty false: (lsw,msw: integer); AFL Marty end; AFL Marty ... AFL Marty the main procedure in the program does this... AFL Marty menuID := long(myEvent.taskData).msw; AFL Marty menuItemID := long(myEvent.taskData).lsw; AFL Marty I don't understand how the type casting allows you to split the longint AFL Marty up into msw and lsw. AFL GaryJ Hmm... I have never seen that kind of thing done - my Pascal is not that good either. AFC DYAJim my only idea is that maybe the boolean case is looking at the msb of the AFC DYAJim longint and reacting upon that. AFL Marty I don't feel so bad anymore now that I've stumped three of you :) DanP18 I'm fuzzy. exactly what part of the code don't you get? AFL Marty The code splits a longint into lsw and msw. AFL Marty I don't understand how that happens. DanP18 Do you know what pascal variant records are? AFL Marty Nope DanP18 how about unions in C? AFL Marty I don't know anything about C. DanP18 ok. (bear with me, this will take a second...) AFL GaryJ (No wonder Dan is fuzzy, he's got a bear with him :) DanP18 The code you've printed is a variant record. basically, the TRUE and FALSE DanP18 are labels. They just denote different parts of the variant. The parts DanP18 after them are the interesting bits. It makes the 'long' part and the DanP18 'msb,lsb' part occupy the same space in memory. so, once the variable is DanP18 typecast to the long type, it can be accessed as 1 longint called long, or DanP18 2 ints called lsb and msb, at the same time, interchangably. ga. AFL Marty I see (sorta). AFL Marty What do the true and false have to do with it? DanP18 nothing. they are just constant identifiers used as placeholders. AFL Marty Thanks... Looks like I have to study a bit more I guess. DanP18 what pascal are you using? AFL Marty Orca/Pascal AFL Marty Thanks for the help Dan... you did shed some light on this for me. DanP18 can you put 2 apple scsi cards in a IIGS? Matt DTS I don't know why not. AFL GaryJ I believe that you can. (A hardware question). DanP18 when i tried it, gsos hung while booting. AFL GaryJ Is there a particular reason that you *need* two cards? DanP18 I purchased a 2nd mac transportable 90 meg drive. They have to be DanP18 the last device on the scsi chain. AFL GaryJ (But, it should still work - perhaps nobody has ever tested such a configuration) Matt DTS You can't have two RamFAST cards in the system (the driver only holds information for one RF slot), bu AFL GaryJ Oh, I see. (Not very user friendly to force as a last device) Matt DTS but the SCSI Manager has code to deal with all that stuff for multiple SCSI cards. I've done it Matt DTS before myself, without problems. DanP18 does it matter if one is a hi speed scsi card and the other is a low speed DanP18 card? Matt DTS That's how my system was. Using 6.0, right? DanP18 yes. DanP18 maybe a zipIIgs problem? Matt DTS I did it long ago without any hitches. Try booting the system with the second card but nothing Matt DTS connected to it, to narrow things down. DanP18 I did that. It didn't help. Matt DTS Dunno. There's no reason it shouldn't work. Matt DTS (As there is for the RF card) DanP18 it would get to just before the point where my 3.5" flicks on, then hang DanP18 with the thermometer marching across. AFA Jay Ok...I've got a question about a TextEdit control. AFA Jay I have said control in a window opened by a Finder Extension AFA Jay from the Extras menu... AFA Jay in any case...when I type in the control, it seems incredibly slow... AFA Jay I can type and it'll take a few seconds for the characters to come out... AFA Jay It's not my taskmaster loop, I checked it and it's going nice and fast. AFA Jay It's just strangely slow...and the little cursor doesn't blink either... AFA Jay I DO have the idle bit set too. Matt DTS Is this a _modal_ window? AFA Jay yes Matt DTS We had this in A2Pro a while back, and the answer was something really simple, but I can't remember Matt DTS what it is. :( AFA Jay figures :) AFL GaryJ Ok, maybe you could post some code or something, Jay. (Not sure if that would help Matt remember or AFL GaryJ not :) ACMguest1 Don't hold your breath for C 2.0.. DanP18 why not? Airship Ouch! Doesn't sound promising. ACMguest1 It'll be a couple of weeks at least.. Seems there's a stack overrun somewhere ACMguest1 and it hasn't been found yet.. Shouldn't take too long though.. AFC SteveB Is there a niftylist command/module available that, apon passing it a toolset number, will dump all AFC SteveB the pointers to all the functions in the toolset? Just want to know before I write my own hack :) AFA Jay t :) Matt DTS Yeah, Steve. It's called "t". It's always been there. Thanks for paying attention. Matt DTS Dump window manager pointers: "et" AFL GaryJ Anyone working on programming projects over the holidays? AFC SteveB I wrote something real stupid... AFL GaryJ What? :) Airship Ground Track v3.0 is near beta, for what it's worth... TSGS v4.3(?), the first Airship Pascal version is coming along nicely. AFC SteveB ...you select this extension from the extras menu, and it brings up a window with a lineedit cntrl... AFC SteveB ...and you enter the pathname of the folder you want to open. AFC SteveB My HD being so nested, it makes things faster for me... it's probably useless to everyone else, tho :) DanP18 Im still working on a port of vi. AFC DYAJim Yes, T2 is going great so far with all this extra time@! AFC DYAJim But i've got SO many projects due when vacation is over :-( AFC DYAJim v1.0.1 (the CDev part) is about 95% done! Airship GT v3.0 will _definitely_ be the last 8-bit version before I tackle the GS Airship version. DanP18 whats T2? AFC DYAJim T2=Twilight II AFC DYAJim I am also working on finishing up most of the modules.. the end number will AFC DYAJim probably come out at around 33.. AFC DYAJim Is there any way to find out from LETextBox2 if you gave it enough room to AFC DYAJim draw all your text? Matt DTS I don't think so. Matt DTS It word-wraps horizontally but just clips vertically. AFC DYAJim Because we were planning on using LETextBox2 to draw the headlines to the AFC DYAJim screen, and we'd like to have the headlines move around from one to the AFC DYAJim next, but we don't know what size rect to pass to it to display the headline, AFC DYAJim so the headlines will probably all be displayed in the same space (or very AFC DYAJim close) AFC SteveB Question... how does one build a list of real font sizes for a particular font? Matt DTS Steve: There's some font manager call that tells you if it's a real font or not. Matt DTS "FindFonFamBitSpecFontFindThings" or something like that. AFC DYAJim findFontStats? AFC SteveB I see... thanks :) Matt DTS Yeah, that's the routine. It does it all, so you'll have to wade through a bit of it. AFC DYAJim Anyone know if there is any way to abort opening a control panel? AFC DYAJim (from software.. like if you incur an error in doCreate or doInit) AFC SteveB Command-Control-Reset :) AFC DYAJim Other than posting an OA-W event, that is. Matt DTS I don't know; I'd guess you just change the control list or something. The AppleShare control panel Matt DTS opens even when you don't have AppleShare installed; it just changes to a static message that Matt DTS says "You don't have AppleShare installed, nyah nyah nyah." AFC DYAJim Yeah, currently T2 draws a statText message and stop icon with no other AFC DYAJim controls, too. But I'd rather just open up an alert and then forgo opening AFC DYAJim the CDev window. Matt DTS You may not get the choice. AFC DYAJim In some cases I open an alert and then the CDev gets opened with an addn'l AFC DYAJim error string. oh well :) AFC DYAJim anyone remember where the joystick read routine discussion took place? AFC DYAJim someone wants to read the joystick from a T2 module, and I told them I'd AFC DYAJim give them a better joystick read routine (because the one the person was using AFC DYAJim took different delays when the joystick was read on the left than right :) AFL GaryJ That was in the Assembly Language area,if I remember correctly, Jim. AFL GaryJ Yeah, it's better to read them both at the same time. AFL GaryJ (Less of a slow-up) AFC DYAJim I really have next to NIL experience in this arena personally :) AFL GaryJ I know that the routine that I provided can be improved upon. AFL GaryJ (the joystick read) AFC DYAJim it's much better than what he's got now, Gary :)