using Scripts with GUIKit (bug?)
- To: mathgroup at smc.vnet.net
- Subject: [mg57436] using Scripts with GUIKit (bug?)
- From: "Brett Patterson" <muckle.moose at gmail.com>
- Date: Sat, 28 May 2005 05:38:59 -0400 (EDT)
- Sender: owner-wri-mathgroup at wolfram.com
Hi, When should a Script[...] be use in a GUIKit Widget expression? For example, in the documentation for the ComboBox widget there is ambiguity about whether "items" -> {"one", "two"} or "items" -> Script[{"one", "two"}] is correct. I've tried both and they both seem to work. Also, is the scope (context) of ALL Script blocks the same in a Widget expression, even if there are Dialog widgets that are shown/disposed during operation of the GUI? Finally, this all relates to an infuriating bug I have. I have a main Panel widget that contains a Dialog widget that is shown when a Button in the Panel is clicked. The Dialog has a ComboBox called "sPlotCombo". In the main Panel widget definition, I have a function definition in a Script that uses the expression PropertyValue[{"sPlotCombo", "selectedItem"}]. However, this is causing the evaluation of the Panel to hang. If I comment out all such expressions, the Panel evaluates and displays, but if I include those expressions, the then evaluation just hangs and no GUI is displayed and I have to Quit the Kernel. Any clues as to the cause and solution of this bug would be warmly welcomed! Regards, Brett Patterson