Update of /project/climacs/cvsroot/papers/ilc2005/syntax In directory common-lisp.net:/tmp/cvs-serv7313
Modified Files: climacssyntax.bib climacssyntax.tex Added Files: barley.eps barley.pdf Log Message: Add a couple of editor references
Rearrange the introduction a little bit
add another figure of more complex tablature
Date: Fri May 20 13:48:41 2005 Author: crhodes
Index: papers/ilc2005/syntax/climacssyntax.bib diff -u papers/ilc2005/syntax/climacssyntax.bib:1.2 papers/ilc2005/syntax/climacssyntax.bib:1.3 --- papers/ilc2005/syntax/climacssyntax.bib:1.2 Tue May 17 14:56:23 2005 +++ papers/ilc2005/syntax/climacssyntax.bib Fri May 20 13:48:40 2005 @@ -117,3 +117,23 @@ OPTannote = {} }
+@inproceedings{greenberg, + author = {Bernard S. Greenberg}, + title = "{Multics Emacs (Prose and Cons): A commercial text-processing system in Lisp}", + booktitle = {LFP '80: Proceedings of the 1980 ACM conference on LISP and functional programming}, + year = {1980}, + pages = {6--12}, + location = {Stanford University, California, United States}, + publisher = {ACM Press}, + address = {New York, NY, USA}, +} + +@inproceedings{woodZ, + author = {Steven R. Wood}, + title = "{Z -- the 95% program editor}", + booktitle = {Proceedings of the ACM SIGPLAN SIGOA symposium on Text manipulation}, + year = {1981}, + isbn = {0-89791-050-8}, + pages = {1--7}, + location = {Portland, Oregon, United States}}, + } \ No newline at end of file
Index: papers/ilc2005/syntax/climacssyntax.tex diff -u papers/ilc2005/syntax/climacssyntax.tex:1.6 papers/ilc2005/syntax/climacssyntax.tex:1.7 --- papers/ilc2005/syntax/climacssyntax.tex:1.6 Fri May 20 10:18:33 2005 +++ papers/ilc2005/syntax/climacssyntax.tex Fri May 20 13:48:41 2005 @@ -55,21 +55,55 @@
\keywords{Editors, Parsing, Tablature}
-\section{Overview} +\section{Introduction} + +The field of advanced text editors is a crowded one, with a long +history and an apparent ability to cause passionate argument. + +[ Does anyone know enough about the history of editors? ] + +\begin{itemize} +\item ed +\item vi (vim) +\item emacs (Zmacs) (emacs time line) \cite{greenberg} +\item some kind of interlispy/smalltalky structure editor? +\item Z -- the 95% text editor \cite{woodZ}. Note that WiB didn't + win! +\end{itemize} + +Discuss lameness of emacs-like regexoid analysis in e.g. CL mode; +maybe mention how it falls over dramatically in perl mode (where +context starts really mattering) +\begin{itemize} +\item non-locality leading to confusion in \verb+#| |#+ +\item paren-in-column-1 hack (and its workaround in docstrings: + \verb+(+) +\end{itemize}
The Climacs text editor is a combination of frameworks for buffer representation and buffer contents parsing with a CLIM-based display -engine. The Flexichain library \cite{flexichain} provides an editable -sequence representation and mark (cursor) management based on a -circular gap buffer. This library is used by the buffer protocol, -which provides a standard interface to common text editor buffer -operations. The syntax protocol provides a method for interfacing a -lexical analyzer and parser with the text editor. An implementation of -the Earley parsing algorithm is provided to simplify the creation of -syntaxes for common context-free grammars. Syntax modules also define -methods to draw syntax objects in the Climacs window. +engine. It includes the Flexichain library \cite{flexichain}, which +provides an editable sequence representation and mark (cursor) +management based on a circular gap buffer; and an implementation of a +slight modification of the Earley parsing algorithm \cite{earley}, to +assist in the creation of syntax-aware editing modes. + +The Climacs buffer protocol, which provides a standard interface to +common text editor buffer operations, uses the Flexichain library; we +discuss this protocol in more detail in section \ref{sec:buffer}. The +syntax protocol, which we discuss in section \ref{sec:syntax}, +provides a method for interfacing a lexical analyzer and parser with +the text editor, and provides for defining methods to draw syntax +objects in the Climacs window. In section \ref{sec:syntaxes} we +discuss the implementation of syntactic analysis for various +programming languages, including Common Lisp; in section +\ref{sec:tabeditor}, we discuss an application with Climacs at its +core to support editing a textual representation of lute tablature. +We discuss avenues for further development in section +\ref{sec:conclusions}.
\section{Buffer Protocol} +\label{sec:buffer}
The buffer protocol provides a set of methods for modifying and reading the contents of a buffer which can contain arbitrary objects. @@ -87,6 +121,7 @@ unspecialized.
\section{Syntax Protocol} +\label{sec:syntax}
A syntax in Climacs is an incremental parser which creates and updates a parse tree of a buffer's contents, and provides a mechanism for @@ -103,16 +138,20 @@ other display or analysis of the text in the buffer.
Earley parser: discussion of generality and asymptotic efficiency (in -general and for usual cases). +general and for usual cases). Possibility of replacement in case of +complicated grammars? (What was that parsing algorithm that someone +mentioned on \verb+#lisp+?)
\section{Syntaxes} +\label{sec:syntaxes}
We describe two different approaches to syntax analysis in the Climacs editor. Per-window parsing is used by the provided modes for HTML, Common Lisp, Prolog, and TTCN3. Each of these syntaxes is implemented with the provided Earley parser \cite{earley}. The lute tablature editor uses a per-buffer function for its syntax analysis and -implements a simple recursive-descent parsing algorithm. +implements a simple recursive-descent parsing algorithm. (FIXME: is +this true? I don't know enough about parsing)
\subsection{Per-Window Syntaxes}
@@ -157,7 +196,8 @@ macro defines basic display functions for the syntax objects produced by the parser, with language keywords appearing in a separate color.
-\subsection{Per-Buffer Syntax} +\subsection{Per-Buffer Syntax: a tablature editor} +\label{sec:tabeditor}
\begin{figure*} \begin{center} @@ -178,6 +218,26 @@ \end{center} \end{figure*}
+\begin{figure*} + \begin{center} + \parbox{0.45\linewidth}{\includegraphics{barley}} + \parbox{0.25\linewidth}{\texttt{\ [1cm]\noindent + Sa1(E)d5(C5:8)\ + a2.\ + d3\ + b3.\ + d3\ + a2.\ + a1:\ + d3.(C-5:4)\ + |}} + \caption{An extract from `Lachrime by I. D.' from \textit{A New + Booke of Tabliture}, published by William Barley (London, + 1596), E1r, and its \TabCode\ encoding.} + \label{fig:barley} + \end{center} +\end{figure*} + \TabCode\ is a textual format for description of lute tablature. In its simplest form, it is a sequence of whitespace-delimited independent words, where each word represents either a set of frets to @@ -186,7 +246,8 @@ demonstrates a fragment of manuscript, and its \TabCode encoding. It is also possible to encode more complex elements of lute tablature notation in \TabCode: ornaments, beaming, connecting lines and other -complex elements can all be accommodated. +complex elements can all be accommodated (see figure \ref{fig:barley} +for examples of more these more complex elements).
\TabCode\ has been used to produce scholarly editions of lute works \cite{Weiss} and to computer-based musicological studies (as in @@ -216,9 +277,11 @@ MIDI feedback. At present, based on Apple's extremely badly documented CoreMIDI framework; a port to alsalib is on the cards.
-\section{Conclusion} +\section{Future Work and Conclusions} +\label{sec:conclusions}
-I like Jello. Jello is good. +I like Jello. Jello is good. We should enable people to make better +Jello.
\nocite{*}