		TextEdit v1.0
                -------------

TextEdit is a primitive text editor, based on Motif's XmText widget,
which makes use of its XmNsource resource to allow multiple views
on the same undserlying text.  This version of TextEdit will work
with both Motif 1.1 and Motif 1.2.

The View menu includes

   Split Pane -- to add a new independently scrollable view of the text

   Remove Pane -- to remove a designated pane

   One Pane -- to remove all panes except the designated pane

The designated pane is determined in the following way:

   -- Using an explicit focus policy, it is the last view which had focus
   -- Using a pointer focus policy, it is the last view which the
         user interacted with.

The designated pane is also the one into which the clipboard contents are
pasted when Paste is selected from the Edit Menu.

TextEdit is also an example of how to write code that is as independent
of other layers as possible.  The various files have the following roles:

	file.c -- code to read, write, and remove files.  Hides
                  any OS/filesystem dependencies

	app.c -- Uses file.c to provide all the code to manipulate
                 files and their related buffers.
                 This is all toolkit-dependent.

	tk.c --  Isolates dependencies on the Xm toolkit.

                 The first half of the file provides utility routines
                 and a toolkit-independent (but application-specific)
                 interface that can be used by the toolkit-independent
                 dialogue layer of the application

                 The second half of the file defines all the callback
                 routines.  Many of these simply update state internal
                 to this layer; others perform additional actions.  Where
                 those actions unambiguously correspond to toolkit-specific
                 action, routines defined in the first half of the file are
                 called.  Otherwise, an upcall is made to the toolkit-
                 independent dialogue layer to decide what to do.

	dlg.c -- This code manages the dialogue with the user.  By
                 using tk.c, it is toolkit-independent.
 
	textedit.c -- Used to initialize the application and instantiates
                 widget hierarchies.  Hides the use of UIL and Mrm from the
                 rest of the application.

Known Bugs
----------

   Moving and removing files is not currently implemented.

Additional Translations
-----------------------

   Users familiar with emacs may want to add the following translations
   to their .Xdefaults files:

*XmText.translations: #override\n\
    Mod1<Btn3Down>:	scroll-cursor-vertically()\n\
  Mod1<Btn3Motion>:	scroll-cursor-vertically()\n\
	Ctrl<Key>a:	beginning-of-line()\n\
	Ctrl<Key>b:	backward-character()\n\
	Ctrl<Key>d:	delete-next-character()\n\
	Ctrl<Key>e:	end-of-line()\n\
	Ctrl<Key>f:	forward-character()\n\
	Ctrl<Key>g:	beep()\n\
	Ctrl<Key>h:	delete-previous-character()\n\
	Ctrl<Key>i:	cut-primary()\n\
	Ctrl<Key>j:	newline-and-indent()\n\
	Ctrl<Key>k:	set-anchor() end-of-line() key-select() cut-clipboard()\n\
	Ctrl<Key>l:	redraw-display()\n\
	Ctrl<Key>m:	newline()\n\
	Ctrl<Key>n:	next-line()\n\
	Ctrl<Key>o:	newline-and-backup()\n\
	Ctrl<Key>p:	previous-line()\n\
	Ctrl<Key>v:	next-page()\n\
	Ctrl<Key>w:	cut-clipboard()\n\
	Ctrl<Key>y:	paste-clipboard()\n\
	Ctrl<Key>z:	scroll-one-line-up()\n\
	Mod1<Key>b:	backward-word()\n\
	Mod1<Key>d:	delete-next-word()\n\
	Mod1<Key>f:	forward-word()\n\
	Mod1<Key>h:	delete-previous-word()\n\
	Mod1<Key>i:	copy-primary()\n\
	Mod1<Key>k:	delete-to-end-of-line()\n\
	Mod1<Key>v:	previous-page()\n\
	Mod1<Key>w:	copy-clipboard()\n\
	Mod1<Key>z:	scroll-one-line-down()\n\
	Mod1 Shift<Key>greater:	end-of-file()\n\
	Mod1<Key>less:	beginning-of-file()\n\
	Mod1<Key>]:	forward-paragraph()\n\
	Mod1<Key>[:	backward-paragraph()

Missing Features
----------------

Zillions of features could be added (and would need to be added)
to make this a truly usable text editor rather than a demo.
If you're interested in adding code, and sending it back to me,
it's possible that it can get into the next release.

Share and Enjoy,

  -- Ellis S. Cohen
     ellis@osf.org


