[comp.sys.mac.programmer] Invisible Text with DrawText on SE, not on II

aksguest@engrhub (Milt Roselinsky) (09/08/90)

I'm having problems porting an application that I developed on a IIcx to
an SE.  The application opens up a window and displays a lot of text
in a scrolling window.  This works fine on my cx, but when I move
the program to an SE, the text displays fine for a short time (maybe 6 
lines) and then the text no longer shows up.  I'm fairly new to 
MACs, and I'm stumped as to chasing down this bug.

Any pointers would be appreciated.

Milt Roselinsky

holmes@Apple.COM (Richard A. Holmes) (09/11/90)

As I understand, if QuickDraw doesn't have enough stack space, it will choose
not to "drawstring"; this is better than crashing for lack of stack space.  I
suspect that perhaps your app is stack-intensive.  The default stack space can
be different on different machines:  Color quickdraw requires more stack than
B&W.  You could try upping the stack space for your app.  I think the calls woul
d be some combination of "SetApplLimit" and "MaxApplZone", IM II, 7-51 should
explain to some extent.  You can test this theory without changing your code
by changing the low mem global "DefltStack" using a debugger such as MacsBug
or TMON to a larger quantity.  "DefltStack" resides in a long word at location
(Hexadecimal) $322.

I hope it helps:  I had a similar problem once and this cured it.  I was able
to simply reduce my stack usage, and didn't have to increase the stack
allocation at all.

Let me know if this was the problem.
-- (I make no claims as to the truthfulness or lack of truthfulness of any words
contained in this posting....)

--Richard.

emmayche@dhw68k.cts.com (Mark Hartman) (09/15/90)

Make sure you check your transfer mode (you should be in srcCopy) -
transfer modes work differently on the Mac ][ family.  (We got bit
by this a couple of years ago, and reported it, but no changes ever
got made as far as I know.)
-- 
------------
Mark Hartman
uucp: ...{spsd,zardoz,felix}!dhw68k!emmayche  Internet:emmayche@dhw68k.cts.com
CompuServe: >internet:emmayche@dhw68k.cts.com Applelink: N1083