From: poec (Karsten Poeck)

Subject: Nested Window in ACL/WINDOWS 2.0

Date: 1994-11-3 15:23

The following question concerns ACL/WINDOWS 2.0/Common Graphics under
windows 3.1 and wfw 3.11 using 32s.

One main graphical part of our application (diagnostic expert system)  are
dynamic questionaires, that are used to get the symptoms from the user. The
questionaire consists of one and multiple choice questions. For the
graphical realisation of the whole stuff we use a  dialog, the individual
questions are represented each by a group of radio-buttons or check boxes
and a coulpe of static texts. So far so good.

The questionaire is dynamic in that respect, that depending on the answers
the system may ask follow up questions, like in a decision tree. We want to
insert the new questions in the right place, so we have to move all
questions after the question that caused the follow up question 1 step down
and insert the question in the free place. So assume that I have questions
q1, q2, q3, q4 and want to insert q21 after q2, you have to move q3 and q4.
Moving q3 or q4 obviously means that we have to move all widgets that
represent the questions.

Unfortunately moving a whole bunch of widgets may look, very, very funny in
Common Graphics before the window finally is really updated. One can insert
a couple of calls to update-window, to get a better looking widget
movement, but that slows down the whole process. Our questionaires may
consist of up to 150 questions with 5 to 10 one/multiple choice
alternatives per qustion, moving that is really slow, even on a fast 486.

An obvious improvement that we also implemented in Macintosh Common Lisp is
to introduce subwindows for each question in the dialog . The widgets for
the question may then be added to the subwindow, not to the main dialog.
Then moving a qustion only means moving the subwindow and not all
individual widgets. Even the redisplay is acceptable, so this solution
works fine in principle.

But, the  problem is that this solution does not scale up. Each subwindow
seams to consume quite a lot of system resources. I don't know what system
ressources are, but you  can select help/info in the programm manager to
see the amount of free system ressources.

By experimentation I found that one can open about 100- 175 windows before
your system ressources are zero and a call to open-dialog fails and returns
nil.

But more than 100 questions can easily occur in one questionaire, so it may
happen (actually it happened with the knowledge base of our project
partner)

Is there any other way to group the widgets togehter. Are there perhaps
ressorce free subwindows? May I increase the amount of memory used in the
operation system for the resources?

All hints welcome

bye

Karsten Poeck

------------------------------------------------------
 Karsten A. Poeck
 Lehrstuhl fuer Informatik VI
 Universitaet Wuerzburg
 Allesgrundweg 12
 97218 Gerbrunn
 Germany

 E-mail: <informatik.uni-wuerzburg.de at poeck>
 Tel ++ 49  931 70561 18
 Fax ++ 49 931 70561 20
------------------------------------------------------