Would this be a solution?

Upon starting program, Call;
FontPtr oldFontP = NULL;
FontID oldFontID = FntGetFont();
FntSetFont(128);  // sets to stdFont if no 128 defined (as per Palm
References)
if (FntGetFont() == 128)
    oldFontP = FntGetFontPtr();


and upon exiting program;
FntSetFont (stdFont);  // so that we shouldn't interfere with the active
font
if (oldFontP)
    FntDefineFont(128, oldFontP);
FntSetFont(oldFontID);

LionScribe

"Ben Combee" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> At 10:07 AM 8/12/2004, you wrote:
> >I am developing a program which is launched by other programs. It uses
it's
> >own defined font #128. I am wondering what will happen if the calling
> >program has also defined font#128, then my program redefines it, and then
> >returns to the calling program. What will font #128 be referring to?
>
> This is a problem; if you redefine a font while in the context of another
> program, you can really mess up the caller.  The font definitions are only
> reset during application switches, not during subcalls or sublaunches.
>



-- 
For information on using the Palm Developer Forums, or to unsubscribe, please see 
http://www.palmos.com/dev/support/forums/

Reply via email to