Fri Nov 12 17:55:05 PST 1999 Michael Jennings <mej@eterm.org>

This should bring the technical reference up-to-date.  Eterm IPC is
	now documented for the first time.


SVN revision: 1290
This commit is contained in:
Michael Jennings 1999-11-13 01:29:53 +00:00
parent 7035351b3f
commit e6e0a230e6
3 changed files with 73 additions and 210 deletions

View File

@ -2762,3 +2762,9 @@ Thu Nov 11 18:25:07 PST 1999 Michael Jennings <mej@eterm.org>
to make sure. :-) I also fixed a few minor nits here.
-------------------------------------------------------------------------------
Fri Nov 12 17:55:05 PST 1999 Michael Jennings <mej@eterm.org>
This should bring the technical reference up-to-date. Eterm IPC is
now documented for the first time.
-------------------------------------------------------------------------------

View File

@ -16,8 +16,8 @@ Portions of this document were taken from the XTerm documentation.</P>
<LI><A HREF="#symbols">Symbols</A>
<LI><A HREF="#escape">Escape Sequences</A>
<UL>
<LI><A HREF="#menubar">Menubar Escape Sequences</A>
<LI><A HREF="#pixmap">Pixmap Escape Sequences</A>
<LI><A HREF="#codes">Escape Codes Eterm Knows</A>
<LI><A HREF="#image">Image Escape Sequences</A>
<LI><A HREF="#mouse">Mouse Reporting</A>
</UL>
<LI><A HREF="#keys">Key Sequences</A>
@ -391,7 +391,6 @@ Portions of this document were taken from the XTerm documentation.</P>
<LI><I>n</I> == 7: Wraparound mode on/off (DECAWM)
<LI><I>n</I> == 9: (X10 Xterm mouse reporting) Do/Don't send mouse
coords on button press (see <A HREF="#mouse">below</A>)
<LI><I>n</I> == 10: Toggle menubar on/off (rxvt/Eterm extension)
<LI><I>n</I> == 25: Visible/invisible cursor
<LI><I>n</I> == 30: Toggle scrollbar on/off (rxvt/Eterm extension)
<LI><I>n</I> == 35: Allow/Disallow xterm shift+key sequences (rxvt/Eterm extension)
@ -438,13 +437,12 @@ Portions of this document were taken from the XTerm documentation.</P>
</TR>
<TR>
<TD><TT>ESC <B>]</B> <I>n</I> <B>;</B> <I>string</I> BEL</TT></TD>
<TD>Set Text Parameters
<TD>Set X Terminal Parameters
<UL>
<LI><I>n</I> == 0: Change icon name and window title to <I>string</I>
<LI><I>n</I> == 1: Change icon name to <I>string</I>
<LI><I>n</I> == 2: Change window title to <I>string</I>
<LI><I>n</I> == 10: Menubar commands (see <A HREF="#menubar">below</A>)
<LI><I>n</I> == 20: Pixmap commands (see <A HREF="#pixmap">below</A>)
<LI><I>n</I> == 20: Image commands (see <A HREF="#image">below</A>)
<LI><I>n</I> == 39: Set the default foreground color to <I>string</I>
<LI><I>n</I> == 49: Set the default background color to <I>string</I>
<LI><I>n</I> == 50: Set font to <I>string</I>. rxvt/Eterm extensions:
@ -480,171 +478,7 @@ Portions of this document were taken from the XTerm documentation.</P>
</TR>
</TABLE>
<H3><A NAME="menubar">Menubar Escape Sequences</A></H3>
<P>
The menubar system in Eterm is probably the most complex, convoluted,
complicated, and poorly-implemented feature of Eterm. The code, though
modified somewhat, is still almost entirely derived from rxvt. It will be
rewritten from scratch as part of
<A HREF="http://ganja.tky.hut.fi/Resurrection/">Project Resurrection</A>, but
for now, here are the basics. You'll probably want to look at the menubar
files that come with Eterm; they're pretty good samples.</P>
<P>
First, let's discuss the paradigm used by the menubar system. Like so many
things these days, the menubar uses a filesystem analogy, with the menubar
itself comprising the top level (root) and each menu and submenu is a
"directory" or "subdirectory" thereof. You manipulate the contents of the
menubar by adding and removing menus, menu items, and submenus via their
respective "paths." You even have a "working directory" and can add/remove
several items at a time by changing to the directory you want.</P>
<P>
The following table shows the commands which are recognized by the menubar
system. These commands can be supplied as <I>string</I> in the menubar escape
sequence, or they can be lines in a menubar file.</P>
<TABLE BORDER=2 CELLSPACING=2 CELLPADDING=5>
<TR>
<TD BGCOLOR="#999999"><FONT SIZE=+1 COLOR="#000000"><B>Command</B></FONT></TD>
<TD BGCOLOR="#999999"><FONT SIZE=+1 COLOR="#000000"><B>Action</B></FONT></TD>
</TR>
<TR>
<TD><TT><B>=</B> <I>title</I></TT></TD>
<TD>Set the menubar title to <I>title</I>. Note that the menubar title is
entirely separate from Eterm's titlebar text. Any occurance of
<TT><B>%v</B></TT> in <I>title</I> is replaced by the Eterm version.
<TT><B>%n</B></TT> is replaced by the resource name (as specified by the
<TT>-n</TT> option. <TT><B>%%</B></TT> inserts a literal '%'.
</TD>
</TR>
<TR>
<TD><TT>[ <B>+</B> ] <I>path</I></TT></TD>
<TD>Change directories to <I>path</I>. If <I>path</I> doesn't exist, it is
created. <TT><B>/</B></TT> represents the menubar itself.
<TT><B>/</B><I>some_menu</I><B>/</B></TT> represents a primary menu in the
menubar. <TT><B>/</B><I>some_menu</I><B>/</B><I>submenu</I><B>/</B></TT>
represents a submenu underneath that menu. And so on.... You can also
use "." and ".." just like you would on a UNIX filesystem.
</TD>
</TR>
<TR>
<TD><TT><B>-</B><I>path</I></TT></TD>
<TD>Removes the menu at <I>path</I>. All submenus and menu items are
automatically removed.
</TD>
</TR>
<TR>
<TD><TT>[ <B>+</B> ] [ <I>path</I> ] <B>{</B> <I>menuitem</I> <B>}</B> [
<B>{</B> <I>rtext</I> <B>}</B> ] [ <B>{</B> <I>action</I> <B>}</B> ] </TT>
</TD>
<TD>Add a menu item at <I>path</I>. The label (<I>menuitem</I>) is required
but can be hidden by using a dot ('<TT><B>.</B></TT>') as the first
character of <I>menuitem</I>, or by using the same text for <I>rtext</I>.
The optional string <I>rtext</I> will be right-justified; this is
generally used to note the key sequence bound to a particular menu item.
If <I>action</I> is not specified, the contents of <I>rtext</I> are
used.</P>
<P>
<I>action</I> is the string which is bound to the menuitem. It is parsed
for escape sequences, control characters, etc. See the table below for a
list of valid encodings. If <I>action</I> begins with a NUL character
(<TT><B>^@</B></TT>), the string is sent to Eterm instead of to the
application. (To send a string beginning with a NUL to the application,
simply prefix the string with two NUL's. The first one will be stripped
and the remainder send to the application.) So any escape sequences you
want Eterm to parse should begin with <TT><B>^@</B></TT>.</P>
<P>
As mentioned in the table below, <TT><B>M-</B></TT> can be used as a
substitute for <TT>ESC</TT> in an action string, with one difference:
a carriage return (<TT><B>\r</B></TT>) is appending automatically to
any string that begins with <TT><B>M-</B></TT> and does not already have
the trailing <TT>CR</TT>.</P>
<P>
To add a separator bar, specify <TT><B>-</B></TT> as <I>menuitem</I>.</P>
</TD>
</TR>
<TR>
<TD><TT><B>-</B> [ <I>path</I> ] <B>{</B> <I>menuitem</I> <B>}</B></TT></TD>
<TD>Removes <I>menuitem</I>.</TD>
</TR>
<TR>
<TD><TT><B>[apptitle:</B> <I>title</I> <B>]</B></TT></TD>
<TD>Sets Eterm's titlebar title to <I>title</I>. Not to be confused with the
<TT><B>[title:]</B></TT> command, which sets the menubar title.
</TD>
</TR>
<TR>
<TD><TT><B>[clear]</B></TT></TD>
<TD>Clears the menubar of all menus. Equivalent to <TT><B>rm -rf /</B></TT>
on a UNIX filesystem.
</TD>
</TR>
<TR>
<TD><TT><B>[done</B> [ <B>:</B> <I>tag</I> ] <B>]</B></TT></TD>
<TD>Sets the current menubar to read-only. No modification attempts will be
accepted (unless they are enclosed in <TT><B>[::]</B></TT>; see below).
</TD>
</TR>
<TR>
<TD><TT><B>[dump]</B></TT></TD>
<TD>Dumps the current menubars out to a file. The path of this file is placed
in the Eterm titlebar. The menubars are dumped so that the resulting file
is a valid Eterm menubar file which can be parsed by Eterm in the future
to restore the current menubar settings.
</TD>
</TR>
<TR>
<TD><TT><B>[echo:</B> <I>text</I> <B>]</B></TT></TD>
<TD>Sends <I>text</I> to the application running in the Eterm window.</TD>
</TR>
<TR>
<TD><TT><B>[hide]</B></TT></TD>
<TD>Hides (toggles off) the menubar and sets it to read-only.</TD>
</TR>
<TR>
<TD><TT><B>[menu</B> [ <B>:</B> <I>name</I> ] <B>]</B></TT></TD>
<TD>Begin addition/modification of the <I>name</I> menubar. If <I>name</I> is
not given, "<TT><B>default</B></TT>" is used. This command sets the
menubar to read-write.</TD>
</TR>
<TR>
<TD><TT><B>[pixmap:</B> <I>string</I> <B>]</B></TT></TD>
<TD>A convenience command. <I>string</I> should follow the syntax shown in
the <B>Pixmap Escape Sequences</B> section below.
</TD>
</TR>
<TR>
<TD><TT><B>[read:</B> <I>file</I> <B>]</B></TT></TD>
<TD>Reads the menubar file <I>file</I> and parses the commands it contains. A
menubar file consists of commands shown in this table. Lines beginning
with '<TT><B>#</B></TT>' and blank lines are ignored.
</TD>
</TR>
<TR>
<TD><TT><B>[rm</B> [ <B>:</B> ] [ <I>spec</I> ] <B>]</B></TT></TD>
<TD>Removes part or all of the contents of a menubar. <I>spec</I> can be a
path, a menu item, or '<TT><B>*</B></TT>', or empty. The latter two
remove all menus in the menubar.
</TD>
</TR>
<TR>
<TD><TT><B>[show]</B></TT></TD>
<TD>Shows (toggles on) the menubar and sets it to read-only.</TD>
</TR>
<TR>
<TD><TT><B>[title:</B> <I>title</I> <B>]</B></TT></TD>
<TD>Sets the menubar title to <I>title</I></TD>
</TR>
<TR>
<TD><TT><B>[:</B><I>command</I><B>:]</B></TT></TD>
<TD>Specifies that the current menu's read-only status should be ignored in
order to parse <I>command</I>. <I>command</I> should be one of the above
commands.
</TD>
</TR>
</TABLE>
<H2><A NAME="codes">Escape Codes Eterm Knows</A></H2>
<TABLE BORDER=2 CELLSPACING=2 CELLPADDING=5>
<TR>
@ -719,13 +553,13 @@ sequence, or they can be lines in a menubar file.</P>
</TR>
</TABLE>
<H3><A NAME="pixmap">Pixmap Escape Sequences</A></H3>
<H3><A NAME="image">Image Escape Sequences</A></H3>
<P>
The <I>string</I> supplied to the pixmap escape sequence (above) consists of a
The <I>string</I> supplied to the image escape sequence (above) consists of a
filename (which can be empty) followed by a semicolon, then one or more
geometry strings. The following table shows the valid geometry strings and
their affects on the background pixmap:</P>
their affects on the background image:</P>
<TABLE BORDER=2 CELLSPACING=2 CELLPADDING=5>
<TR>
@ -744,7 +578,7 @@ their affects on the background pixmap:</P>
<TD>Set scaling to <I>W</I>% by <I>H</I>%, and position to <I>X</I>% by
<I>Y</I>%. <I>W</I> and <I>H</I> are percentages of the original image
size. The position is a percentage, where <B>+50+50</B> centers the
pixmap in the window.</TD>
image in the window.</TD>
</TR>
<TR>
<TD><TT><I>W</I><B>x</B><I>H</I><B>+</B><I>X</I></TT></TD>
@ -752,7 +586,7 @@ their affects on the background pixmap:</P>
</TR>
<TR>
<TD><TT><I>W</I><B>x</B><I>H</I></TT></TD>
<TD>Assumes <I>Y</I> == <I>X</I> == 50 (centers the pixmap)</TD>
<TD>Assumes <I>Y</I> == <I>X</I> == 50 (centers the image)</TD>
</TR>
<TR>
<TD><TT><I>W</I><B>+</B><I>X</I><B>+</B><I>Y</I></TT></TD>
@ -1240,8 +1074,9 @@ are: <TT><B>1</B></TT>, <TT><B>on</B></TT>, <TT><B>yes</B></TT>, or (of course)
<TD><TT>ESC <B>[ 9 n</B></TT></TD>
<TD>Titlebar Status. This places Eterm's current status in the titlebar. The
status information includes the application name and version number, as
well as the shading/tinting state if transparent, the pixmap path if their
is a background pixmap, or "No Pixmap" if neither of these is true.
well as the shading/tinting state if transparent, the path to the
background image if there is one, or "No Pixmap" if neither of these is
true.
</TD>
</TR>
<TR>
@ -1254,36 +1089,24 @@ are: <TT><B>1</B></TT>, <TT><B>on</B></TT>, <TT><B>yes</B></TT>, or (of course)
</TR>
<TR>
<TD><TT>ESC <B>] 6 ; 0 </B> [ <B>;</B> <I>boolean</I> ] BEL</TT></TD>
<TD>Set/toggle transparency state.</TD>
<TD>Set/toggle transparency state. This affects all images for which
transparency is an allowed mode.</TD>
</TR>
<TR>
<TD><TT>ESC <B>] 6 ; 1 ;</B> <I>pct</I> BEL</TT></TD>
<TD>Set shading percentage to <I>pct</I>.</TD>
</TR>
<TR>
<TD><TT>ESC <B>] 6 ; 2 ;</B> <I>mask</I> BEL</TT></TD>
<TD>Set tint mask to <I>mask</I>. As a favor to keebler, I left support for
the old text aliases in the escape sequence parser. Thus, the following
are supported as alternative values for <I>mask</I>:
<UL>
<LI><TT><B>none</B></TT>: <TT>0xffffff</TT>
<LI><TT><B>red</B></TT>: <TT>0xff8080</TT>
<LI><TT><B>green</B></TT>: <TT>0x80ff80</TT>
<LI><TT><B>blue</B></TT>: <TT>0x8080ff</TT>
<LI><TT><B>cyan</B></TT>: <TT>0x80ffff</TT>
<LI><TT><B>magenta</B></TT>: <TT>0xff80ff</TT>
<LI><TT><B>yellow</B></TT>: <TT>0xffff80</TT>
</UL>
</TD>
<TD><TT>ESC <B>] 6 ; 1 ;</B> [ <I>class</I> <B>;</B> ] <I>color</I> <B>;</B> <I>attribute</I> <B>;</B> <I>value</I> BEL</TT></TD>
<TD>Adjusts a color modifier. <I>class</I> determines which image class will
have its color modifier altered, <B>bg</B> (background, the default),
<B>sb</B> (scrollbar trough), <B>sa</B> (scrollbar anchor), <B>up</B>
(up arrow), or <B>down</B> (down arrow). Next comes the <I>color</I>
which determines how pixels are modified. This is either
<B>image</B>, <B>red</B>, <B>green</B>, or <B>blue</B>.
<I>attribute</I> is one of <B>brightness</B>, <B>contrast</B>, or
<B>gamma</B>, and <I>value</I> is the actual integer value (>= 0).</TD>
</TR>
<TR>
<TD><TT>ESC <B>] 6 ; 3 ;</B> BEL</TT></TD>
<TD>Force an update the of transparency background.</TD>
</TR>
<TR>
<TD><TT>ESC <B>] 6 ; 4 </B> [ <B>;</B> <I>boolean</I> ] BEL</TT></TD>
<TD>Set/toggle desktop watching.</TD>
</TR>
<TR>
<TD><TT>ESC <B>] 6 ; 10 ;</B> [ <I>type</I> ] [ <B>;</B> <I>width</I> ] BEL</TT></TD>
<TD>Set scrollbar style to <I>type</I> and scrollbar width to <I>width</I>.
@ -1309,10 +1132,6 @@ are: <TT><B>1</B></TT>, <TT><B>on</B></TT>, <TT><B>yes</B></TT>, or (of course)
focus and disappears when it does not).
</TD>
</TR>
<TR>
<TD><TT>ESC <B>] 6 ; 15 </B> [ <B>;</B> <I>boolean</I> ] BEL</TT></TD>
<TD>Set/toggle menubar move.</TD>
</TR>
<TR>
<TD><TT>ESC <B>] 6 ; 20 </B> [ <B>;</B> <I>boolean</I> ] BEL</TT></TD>
<TD>Set/toggle visual bell.</TD>
@ -1331,12 +1150,17 @@ are: <TT><B>1</B></TT>, <TT><B>on</B></TT>, <TT><B>yes</B></TT>, or (of course)
</TR>
<TR>
<TD><TT>ESC <B>] 6 ; 24 </B> [ <B>;</B> <I>boolean</I> ] BEL</TT></TD>
<TD>Set/toggle viewport mode.</TD>
<TD>Set/toggle viewport mode for all images that have allowed viewport
mode.</TD>
</TR>
<TR>
<TD><TT>ESC <B>] 6 ; 25 </B> [ <B>;</B> <I>boolean</I> ] BEL</TT></TD>
<TD>Set/toggle selection trailing spaces.</TD>
</TR>
<TR>
<TD><TT>ESC <B>] 6 ; 26 </B> [ <B>;</B> <I>boolean</I> ] BEL</TT></TD>
<TD>Set/toggle reporting as keysyms See the man page for details.</TD>
</TR>
<TR>
<TD><TT>ESC <B>] 6 ; 50 ;</B> <I>desktop</I> BEL</TT></TD>
<TD>Move Eterm to desktop <I>desktop</I> and make it the current desktop.
@ -1346,7 +1170,7 @@ are: <TT><B>1</B></TT>, <TT><B>on</B></TT>, <TT><B>yes</B></TT>, or (of course)
</TR>
<TR>
<TD><TT>ESC <B>] 6 ; 70 </B> BEL</TT></TD>
<TD>Exit Eterm (most useful from a menubar).</TD>
<TD>Exit Eterm (most useful from a menu).</TD>
</TR>
<TR>
<TD><TT>ESC <B>] 6 ; 71</B> [ ;</B> <I>path</I> ] BEL</TT></TD>
@ -1356,14 +1180,47 @@ are: <TT><B>1</B></TT>, <TT><B>on</B></TT>, <TT><B>yes</B></TT>, or (of course)
<TT><I>YYYYMMDD.HHMMSS</I></TT> is the current system time).
</TD>
</TR>
<TR>
<TD><TT>ESC <B>] 6 ; 80 ;</B> <I>level</I> BEL</TT></TD>
<TD>Set the debugging level to <I>level</I>.</TD>
</TR>
<TR>
<TD><TT>ESC <B>] 7 ; </B> { <B>echo</B> | <B>tty_write</B> } <B>:</B> <I>params</I> BEL</TT></TD>
<TD>Eterm IPC: Sends the string <I>params</I> to the client application.</TD>
</TR>
<TR>
<TD><TT>ESC <B>] 7 ; parse :</B> <I>params</I> BEL</TT></TD>
<TD>Eterm IPC: Causes Eterm to parse <I>params</I> itself.</TD>
</TR>
<TR>
<TD><TT>ESC <B>] 7 ; enl_send :</B> <I>params</I> BEL</TT></TD>
<TD>Eterm IPC: Sends an IPC command to Enlightenment. Does not wait for a
reply.</TD>
</TR>
<TR>
<TD><TT>ESC <B>] 7 ; enl_query :</B> <I>params</I> BEL</TT></TD>
<TD>Eterm IPC: Sends an IPC command to Enlightenment and waits for a reply.</TD>
</TR>
<TR>
<TD><TT>ESC <B>] 7 ; winop :</B> <I>op</I> [ <I>windowid</I> ] BEL</TT></TD>
<TD>Eterm IPC: Performs a window operation on the window given by
<I>windowid</I>. Valid window operations are <B>raise</B>,
<B>lower</B>, <B>map</B>, <B>unmap</B>, <B>kill</B>, and
<B>iconify</B>. The operation should be separated from the
window ID by a space. The default window is the Eterm window itself.</TD>
</TR>
<TR>
<TD><TT>ESC <B>] 7 ; exit BEL</TT></TD>
<TD>Eterm IPC: Exits Eterm.</TD>
</TR>
</TABLE>
<H3><A NAME="trans">Transparency</A></H3>
<P>
The standard for implementing transparency was a mutual effort between myself,
Carsten Haitzler <raster@redhat.com>, Gerald Britton <gbritton@mit.edu>, and
Nat Friedman <nat@nat.org>, based off of an original idea by Nat. First I'll
Carsten Haitzler &lt;raster@redhat.com&gt;, Gerald Britton &lt;gbritton@mit.edu&gt;, and
Nat Friedman &lt;nat@nat.org&gt;, based off of an original idea by Nat. First I'll
define the standard, then I'll discuss its justification.</P>
<P>

View File

@ -3092,7 +3092,7 @@ init_defaults(void)
}
#endif
Options = (Opt_scrollBar);
Options = (Opt_scrollBar | Opt_select_trailing_spaces);
Xdisplay = NULL;
display_name = NULL;
rs_term_name = NULL;