summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authordeva <deva>2008-12-09 11:16:00 +0000
committerdeva <deva>2008-12-09 11:16:00 +0000
commit2d53f43441e22352ded6413e349131fdb8b4f3bf (patch)
treee87ce4269b97e1c7bb575646150e7abb825ab0bb
parentc18428aa59e693af9debf9f760f52e4c40d2fa47 (diff)
Added syntax highlighting fr the pracro xml language.
-rw-r--r--design/Makefile3
-rw-r--r--design/pml.tex38
-rw-r--r--design/preamble.tex10
3 files changed, 49 insertions, 2 deletions
diff --git a/design/Makefile b/design/Makefile
index 267be51..15b078a 100644
--- a/design/Makefile
+++ b/design/Makefile
@@ -21,7 +21,8 @@ $(TARGET).ps: $(TARGET).dvi
dvips -t a4 $(TARGET).dvi -o
$(TARGET).pdf: $(TARGET).ps
- ps2pdf14 $(TARGET).ps $(TARGET).pdf
+# ps2pdf14 $(TARGET).ps $(TARGET).pdf
+ pdflatex $(FLAGS) -jobname $(TARGET) $(SOURCE)
clean:
rm -f \#*
diff --git a/design/pml.tex b/design/pml.tex
new file mode 100644
index 0000000..6357a8f
--- /dev/null
+++ b/design/pml.tex
@@ -0,0 +1,38 @@
+%
+% Set colours for syntax highlighting
+%
+\usepackage{color}
+\definecolor{commentcolour}{rgb}{0.69, 0.13, 0.13}
+\definecolor{tagcolour}{rgb}{0.0, 0.0, 1.0}
+\definecolor{keywordcolour}{rgb}{0.72, 0.52, 0.04}
+\definecolor{stringcolour}{rgb}{0.73, 0.56, 0.56}
+\definecolor{identifiercolour}{rgb}{0.0, 0.0, 0.0}
+
+\usepackage{listings}
+\lstset{
+ basicstyle=\ttfamily\small,
+ keywordstyle=[0]\color{tagcolour},
+ keywordstyle=[1]\color{keywordcolour},
+ identifierstyle=\color{identifiercolour},
+ commentstyle=\color{commentcolour},
+ stringstyle=\color{stringcolour},
+ showstringspaces=false
+}
+
+\lstdefinelanguage{PML}{
+ morekeywords=[0]{window,frame,spacer,label,lineedit,textedit,button,%
+ checkbox,togglebutton,radiobuttons,combobox,listbox,multilist}, %
+ morekeywords=[1]{name,value,caption}, %
+ tag=**[s]<>,%
+ sensitive=f,%
+ morestring=[d]",% ??? doubled
+ MoreSelectCharTable=%
+ \lst@CArgX--\relax\lst@DefDelimB{}{}%
+ {\ifnum\lst@mode=\lst@tagmode\else
+ \expandafter\@gobblethree
+ \fi}%
+ \lst@BeginComment\lst@commentmode{{\lst@commentstyle}}%
+ \lst@CArgX--\relax\lst@DefDelimE{}{}{}%
+ \lst@EndComment\lst@commentmode
+}[keywords,comments,strings,html]%
+\lstset{language=PML}
diff --git a/design/preamble.tex b/design/preamble.tex
index 7096db5..17d4ecf 100644
--- a/design/preamble.tex
+++ b/design/preamble.tex
@@ -119,8 +119,10 @@
%\underlineheadings
+\input{pml}
+
\title{\Huge{}\textbf{Pracro}\\\Large{}Design dokument\\\vspace{1cm}PC-Praxis macrosystem}
-%
+
\author{Bent Bisballe Nyeng\\deva@aasimon.org\\Aasimon.org}
\markboth{}{}
@@ -130,6 +132,12 @@
%*********************************************
\begin{document}
\maketitle
+
+\begin{lstlisting}
+<!-- dims -->
+<label caption="dims"/>
+\end{lstlisting}
+
\tableofcontents
\input{xmlformat}