From: rogerr@netcom.com (roger reynolds)
Newsgroups: fj.mail-lists.x-window
Subject: Re: Wcl novice requests help
Date: 11 Dec 92 21:34:00 GMT
Distribution: fj
Organization: Netcom - Online Communication Services (408 241-9760 guest)

Date: Fri, 11 Dec 1992 17:55:35 GMT
Message-Id: <1992Dec11.175535.4335@netcom.com>
Newsgroups: comp.windows.x

In article <1992Dec9.221603.757@rwwa.COM> witr@rwwa.com writes:
>In article <1g5b3rINN6v6@horus.ap.mchp.sni.de>,
> david@breslau.ap.mchp.sni.de (David Smyth) writes:
>
>| mitzel@caldera.usc.edu (Danny Mitzel) writes:
>| >I was wondering if someone could point me to a simple program to look
>| >at the code side of initializing/interacting with the Wcl created
>| >widgets.
>| 
>| Here is exactly how I do it.
>
>[... excellent narrative deleted ...]

[ ... more good commentary deleted ...]


The only thing that I have to add to this discussion is the 
introduction of my resource file preprocessor RIL.
Here is the README file for RIL, version 2.1.

What is RIL?
	RIL - "Roger's Interface Language", is basically a "preprocessor" 
	for Resource files.  At a minimum, RIL allows you to write resource
	files in a clean, easy to read and edit style, as "source code"
	for the generation of a true "app-defaults" file.  

	Taken to extremes, RIL allows you to use conditional statements,
	flow control constructs, user-definable procedures and variables,
	and a whole lotta other neat stuff, to specify your interface.
	
	RIL is based on TCL.  If you do not have TCL, you need to get it.
	TCL can be FTP'd from sprite.berkely.edu, among other places.
	TCL is really the guts behind RIL, and it comes with reasonable
	documentation on the details of the language.
	If you already use TCL, you can use the version that you already have
	with some minor edits in the Imakefile.

	RIL has about 3 "modes" of operation:
	1. Write ril scripts and "compile" them to app-defaults files
	   These app-defaults files can be used any place an ordinary
	   resource file can be used. (as app-defaults, fallbacks, Mri...)

	2. Use the program "ril" to run an application from its ril source(s).
	   This is analagous to using Mri on a plain resource file, and is
	   an excellent way to quickly prototype an interface.
	
	3. Link libril.a with an application, and use ril source instead
	   of resource files.  This is most useful if you are already using
	   WCL.  This is how I build all my Motif apps these days.
	   This provides a very convenient cycle for developing interfaces,
	   there is no "compiling" of the ril files.  They are read each
	   time the program runs.

	This is the second general release of RIL.  I'm still a bit
	short on examples, but the guts of RIL is now pretty solid
	and reliable, and is substantially improved over the first release.
	Still, I WELCOME your comments and suggestions as to how to
	to improve RIL and make it more useful.  I'm still learning
	too...

Who should use RIL?
	Anybody that generates complex resource files can benefit from 
	using RIL.  In particular,  users of WCL will find RIL an
	invaluable tool,  because WCL allows/demands "complete" resource
	files, which can get really large and ugly.

	Also, you can think of RIL as a kind of substitute for UIL.
	This is may especially interesting for OLIT and ATHENA users.

What do I need to get to use RIL, and where do I get it?
	The latest version of ril is always available for anonymous
	ftp from my site  netcom.com in the /pub/rogerr directory.
	There is an older version on export, but I prefer to keep
	it at netcom since I have more control over what is there.
	If you can't get it from netcom, drop me a line and we can
	make other arrangements.

	RIL requires TCL 6.3 or greator. If you already have it, you can
	use that. Otherwise, get it from sprite.berkely.edu.

	RIL works best in conjunction with WCL, though WCL is not required.
	If you don't have WCL you should get it, whether you use RIL or not!
	The most recent version of WCL is available on export.

How do I learn to use RIL?
	There are some demo "programs" in the distribution which should
	serve as a guide to using RIL, and the basics of TCL.
	For a more complete description of the full potential of RIL,
	you can read the TCL documentation included in the TCL distribution.
	If you already use WCL, you should be able to get quite a long 
	way very quickly just by looking over the examples.

	The file ril_main.c is a demonstration of how you would incorporate
	the use of ril into an application, as suggested in method 3 above.


What is the future of RIL?
	Well, thats a good question.  RIL is only a few months old, and
	I myself have not had a chance to try all of the things which I
	have tried to provide hooks to do.

	Some things that sould be possible with RIL, but I have not yet
	tried, or don't have examples of, are:
		Building a library of re-usable high-level interface components.
		Defining and using resource "styles".
		
	Some features that I had envisioned, but have not yet implemented
	are:
		Genereate C-code from ril source.
		Error checking on resource specifications.
		Additional language features.
		Suggestions from the world...

---------------------------------------------------

Enjoy,
rogerr@netcom.com