multiple winopen()'s with different gconfig()'s?

Kurt Akeley kurt at cashew.asd.sgi.com
Tue Apr 30 01:06:11 AEST 1991


In article <1991Apr28.115605.2164 at agate.berkeley.edu>, dwallach at soda.berkeley.edu (Dan Wallach) writes:
|> While I was working on the sperm program (posted a couple hours ago) I ran
|> into one nasty bug that I just threw my hands up at.
|> 
|> There are times when I have two windows open, and I'd like them to have
|> different drawmode()'s and different color modes (RGBmode vs. cmode).
|> 
|> I tried effectively saying....
|> 
|>     win1 = winopen("Win 1");
|>     drawmode(OVERDRAW);
|>     gconfig();
|>     win2 = winopen("Win 2");
|>     winset(win2);  /* probably not necessary */
|>     drawmode(NORMALDRAW);
|>     RGBmode();
|>     gconfig();
|> 
|> And that just didn't work.  The NORMALDRAW business stuck.

Drawmode is not a gconfig command.  In other words, drawmode takes effect
immediately, rather than the next time that gconfig is called.  I'd guess
that the gconfig implementation on your Personal Iris is reseting drawmode
as a part of its operation.  Try the sequence

	win1 = winopen("Win 1");
	drawmode(OVERDRAW);

	win2 = winopen("Win 2");
	RGBmode();
	gconfig();

This should be all that is necessary.

-- Kurt



More information about the Comp.sys.sgi mailing list