farmer@titan.tsd.arlut.utexas.edu (Gary Farmer) (12/19/90)
Am I correct in believing the following? 1. UIL does not require recompilation when widget attributes are changed. Recompilation with the application is only necessary when widgets are actually added or deleted. 2. Wcl does not require recompilation in either case. A user could conceivably start an application, create a window with a new format, and read in the new resource file. The application would only need to obtain the file name from the user and call WcResFile() with it. Thank you in advance, Gary Farmer farmer@titan.tsd.arlut.utexas.edu
colin@nbc1.ge.com (Colin Rafferty) (12/20/90)
In article <FARMER.90Dec18140736@calliope.titan.tsd.arlut.utexas.edu> farmer@titan.tsd.arlut.utexas.edu (Gary Farmer) writes: > > Am I correct in believing the following? > > 1. UIL does not require recompilation when widget attributes are changed. Correct. > Recompilation with the application is only necessary when widgets are > actually added or deleted. Not quite. Recompilation is only necessary when top-level widgets are added or deleted. If you add/delete/change any widgets other than the one that you actually say "XtRealizeWidget()" to, there is no C recompilation needed. In fact, when I prototype my displays, I use a standard program that I haven't changed since I first wrote it. All I have to do is make sure that my top level widget is called "TopLevel" and all my "*.uil" files are listed on the command line. > 2. Wcl does not require recompilation in either case.... Dunno. Please note that I am not speaking for NBC. I leave that to Bryant Gumbel. //=====================================\/==============================\\ || Colin Owen Rafferty || "Life is so complex, parts || || colin@nbc1.ge.com || of it must be imaginary." || || {philabs,crdgw1,ge-dab}!nbc1!colin || -Tim Thiel || \\=====================================/\==============================//
david@jpl-devvax.JPL.NASA.GOV (David E. Smyth) (12/21/90)
farmer@titan.tsd.arlut.utexas.edu (Gary Farmer) writes: > >Am I correct in believing the following? > >1. UIL does not require recompilation when widget attributes are changed. > Recompilation with the application is only necessary when widgets are > actually added or deleted. > >2. Wcl does not require recompilation in either case. A user could conceivably > start an application, create a window with a new format, and read in the new > resource file. The application would only need to obtain the file name from > the user and call WcResFile() with it. Almost. You can certainly *restart* the program and have all sorts of new interface stuff come up without ever re-compiling. Very handy for tailoring the UI. You can also add *new* sections of the widget hierarchy very easily during program execution by loading additional resource files by invoking WcLoadResFileCB(). I do this all the time. However, you can't necessarily *change* things simply by loading changed or new resource files. Changed files will never be loaded: WcLoadResFileCB keeps track of resource files it has loaded, and only loads them once. Also, remember that widgets only fetch things from the resource database when they are created. Therefore, changing the database won't affect existing widgets. That's why I figured its reasonable to just keep restarting the application when you are developing and tailoring the interface. And, you can't DELETE things from the resource database. You can only overwrite resource values. This can be an advantage, or a disadvantage, depending on how you use it. This definately works using Wcl: 0. XtInitialize reads an initial resource file. 1. Create a buch of widgets (your basic UI). 2. Read another resource file. 3. Create some more widgets which will have attributes specified in both (reall, all) resource files read so far. Last resource value specified wins, of course.