The
format
of
the
files
generated
by
Dump
and
read
by
Load
in
acme(1)
is
not
formally
documented,
but
this
does
a
reasonable
job
of
describing
it.
HEADER
Dump
files
all
start
with
three
lines
describing
the
global
state
of
the
Acme
instance:
-
Working
directory
-
Default
font
(like
-f)
-
Alternate
font
(like
-F)
The
line
following
this
describes
the
position
for
each
column
as
a
percentage
offset
from
the
left
edge
of
the
window,
as
a
list
of
11-character
space-separated
numbers.
For
example,
the
line
0 30 85
describes
a
three-column
window
with
columns
starting
at
the
left
edge,
30%
in,
and
85%
in.
GLOBAL DESCRIPTION
Two
types
of
lines
are
newer
additions.
They
are
optional
in
current
dump
files,
and
not
found
in
older
ones.
If
these
lines
exist,
they
must
come
before
row/window
descriptors,
described
below.
-
w
Tag
A
line
starting
with
"w"
will
treat
the
remainder
of
the
line
(after
the
first
two
characters,
typically
"w
")
as
the
tag
for
the
top-level
window.
-
c
colnum
tag
A
line
starting
with
"c",
followed
by
a
space-padded
11-digit
number,
followed
by
a
space,
and
then
a
tag.
The
number
is
the
internal
column
ID,
and
the
tag
sets
the
tag
for
that
column.
ROW DESCRIPTORS
Subsequent
lines
define
window
("rows"
in
acme's
terminology).
They
come
in
sets
of
two
or
more
lines
each,
depending
on
the
type.
The
first
two
lines
are
common
to
all
window
types,
with
one
exception.
-
First
line
A
single
character
type
specifier
(see
below),
5-6
11-character
numeric
fields,
and
an
optional
font
name.
Each
field
is
space-separated.
The
numeric
fields:
Column
number,
from
above
Internal,
unique
window
ID
(t->file->dumpid)
Selection
("dot")
start
(w->body.q0)
Selection
("dot")
end
(w->body.q1)
Position
in
column,
%
from
top
(100.0*(w->r.min.y-c->r.min.y)/Dy(c->r))
F
windows
only:
buffer
size
(w->body.file->b.nc)
-
Second
line
("ctl
line")
The
first
5
fields
from
the
window's
ctl
file
(see
acme(4)
and
wind.c:/^winctlprint),
followed
by
a
space,
then
the
tag
for
that
window.
These
first
five
fields
are:
Window
ID;
tag
size
in
runes;
body
size
in
runes;
1
if
the
window
is
a
directory,
0
otherwise,
1
if
modified
(dirty),
0
otherwise.
ROW TYPES
-
f
Internal
file
or
directory
window.
-
F
Regular
file,
dirty.
Subsequent
lines
are
the
contents
of
the
window,
which
must
match
the
buffer
length
specified
in
the
first
line.
-
x
Zerox
windows.
Treated
like
f
windows,
with
dumpid
set.
-
e
Window
for
an
external
command.
Fields
for
dot
are
always
0
on
creation,
and
the
second
line
("ctl
line")
is
ignored.
"e"
window
definitions
must
be
followed
by
two
additional
lines.
The
third
line
is
working
directory.
If
this
is
blank,
it
will
be
set
to
$home,
or
"./"
if
$home
is
not
set.
The
fourth
line
is
the
command
to
run,
via
exec.c:/^run\(.*\).