home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Fresh Fish 8
/
FreshFishVol8-CD1.bin
/
new
/
util
/
edit
/
jade
/
man
/
jade.info-7
(
.txt
)
< prev
next >
Wrap
GNU Info File
|
1994-10-16
|
50KB
|
981 lines
This is Info file jade.info, produced by Makeinfo-1.55 from the input
file jade.texi.
START-INFO-DIR-ENTRY
* Jade: (jade). An editor for X11 and AmigaDOS
END-INFO-DIR-ENTRY
This is Edition 1.3, last updated 7 October 1994, of `The Jade
Manual', for Jade, Version 3.2.
Jade is a text editor for X11 (on Unix) and the Amiga.
Copyright 1993, 1994 John Harper.
Permission is granted to make and distribute verbatim copies of this
manual provided the copyright notice and this permission notice are
preserved on all copies.
Permission is granted to copy and distribute modified versions of
this manual under the conditions for verbatim copying, provided that
the entire resulting derived work is distributed under the terms of a
permission notice identical to this one.
File: jade.info, Node: The Current Buffer, Prev: The Buffer List, Up: Buffers
The Current Buffer
------------------
The "current buffer" is the buffer being displayed in the current
window (*note Windows::.), all functions which take an optional BUFFER
argument will operate on the current buffer if this argument is
undefined. Similarly if a WINDOW argument to a function is left
undefined the current window will be used.
- Function: current-buffer &optional WINDOW
Returns the buffer being displayed by the window WINDOW (or the
current window).
(current-buffer)
=> #<buffer programmer.texi>
The `set-current-buffer' function sets the current buffer of a
window. If, when the window is next redisplayed (i.e. after each
command), the current buffer is different to what it was at the last
redisplay the new buffer will be displayed in the window.
- Function: set-current-buffer BUFFER &optional WINDOW
Sets the buffer that the window is displaying.
Usually a window's current buffer will be the buffer which is at
the head of the window's `buffer-list'. The function `goto-buffer'
can be used to set both of these at once.
- Function: goto-buffer BUFFER
Set the current buffer to BUFFER which is either a buffer or a
string naming a buffer. The selected buffer is moved to the head
of the window's `buffer-list'.
If BUFFER is a string and no buffer exists of that name a new one
is created.
Often you will want to temporarily switch to a different current
buffer, that is what the `with-buffer' special form is for.
- Special Form: with-buffer BUFFER FORMS...
Temporarily sets the current buffer to the value of evaluating
BUFFER, then evaluates the FORMS in sequence. The old value of the
current buffer is reinstated and the structure returns the value
of the last of the FORMS to be evaluated.
If the implicit progn evaluating FORMS is exited abnormally the
old value of the current buffer will still be reinstated.
If the window is redisplayed while the FORMS are being evaluated
(i.e. in a recursive edit) the new buffer will be drawn into the
window.
(with-buffer new-buffer ;Enter a recursive edit in
(recursive-edit)) ; the buffer `new-buffer'.
File: jade.info, Node: Windows, Next: Positions, Prev: Buffers, Up: Programming Jade
Windows
=======
A "window" is a Lisp object representing a window (a rectangular
section of the display) open in the windowing-system you are running
Jade in.
Windows have two main functions, firstly to provide a means of seeing
the contents of a buffer and secondly to receive input events. For more
details about event handling see *Note Event Loop::.
A window *always* displays a buffer and there is *always* at least
one window open. The editor remembers which of the open windows is the
"current window", this is normally the window it last received an input
event from, though it can be set by programs.
For some basic details about using windows see *Note Using Windows::.
- Function: windowp OBJECT
This function returns `t' if its argument is a window.
- Variable: window-list
This variable's value is a list of all the currently open windows.
The order of the elements in the list is insignificant.
window-list
=> (#<window 20971528 *Info*> #<window 20971524 *jade*>)
* Menu:
* Opening Windows:: Creating new windows
* Closing Windows:: Deleting windows
* Iconifying Windows:: Temporarily removing windows
* Displaying Messages:: Messages to the user
* The Current Window:: The activated window, used by default
* Window Font:: Each window may use a different font
* Window Information:: Details of a window's current state
* Rendering:: How buffers are drawn in windows
* Block Marking:: Highlighting a region of a window
File: jade.info, Node: Opening Windows, Next: Closing Windows, Up: Windows
Opening Windows
---------------
- Function: open-window &optional BUFFER X Y WIDTH HEIGHT
Opens a new window and returns it. If BUFFER is defined it is the
buffer to display in the new window, otherwise the current buffer
is displayed.
The X and Y arguments are the pixel coordinates of the new window's
top left corner in the display. The WIDTH and HEIGHT arguments are
the size of the window in columns and rows of characters
respectively.
What happens when the position and size of the window is undefined
will depend on the underlying window system, on the Amiga the
window will probably be the same as the current window, in X11 the
window manager will probably let the user size it interactively.
The new window will have its `buffer-list' variable initialised
suitably and it will be added to the head of the `window-list'
variable.
The `make-window' function is the lowest level of creating a new
window, `open-window' uses it to open the window.
- Function: make-window &optional X Y WIDTH HEIGHT
Creates a new window and returns it, the arguments are similar to
those of the same name in the `open-window' function. The window
will display the current buffer.
After the window is created the `make-window-hook' will be called
with the window as its argument.
- Hook: make-window-hook
Hook called each time a new window is created. It has one
argument, the new window.
- Variable: pub-screen
This window-local variable is only used on the Amiga version of
Jade; it holds the name of the public screen which windows are
opened on. By default this is the Workbench screen.
When a window is opened it inherits this value from the current
window at the time.
File: jade.info, Node: Closing Windows, Next: Iconifying Windows, Prev: Opening Windows, Up: Windows
Closing Windows
---------------
Unlike buffers, window objects don't have indefinite extent, even
when a window is incapable of being referenced the object will not be
destroyed by the garbage collector; count the user looking at the window
as a reference!
When the window is closed (by the `destroy-window' function) the
object loses its `window-ness' and the garbage collector is free to
reclaim its memory.
- Function: close-window &optional WINDOW
This function closes the window WINDOW (or the current window) and
deletes its entry from the `window-list' variable.
If this window is the only one the editor has open the user is
asked if it's okay to lose any modified buffers before the window
is closed.
- Function: close-other-windows &optional WINDOW
Uses `close-window' to close all windows except WINDOW (or the
current window).
- Function: destroy-window WINDOW
Closes the window WINDOW. After a window object has been closed it
is no longer a member of the type `window'.
Before closing the window the `destroy-window-hook' is evaluated
with the window being destroyed as an argument.
When the last window is closed the editor will exit automatically.
Like the `destroy-buffer' function, this function is dangerous if
used carelessly.
Both `close-window' and `close-other-windows' eventually call this