# trainmap.cwl
# TeXstudio / TeXworks completion word list for the `trainmap' package.
# Placing this file where the editor looks for completion files makes it
# recognise the trainmap commands, so they are no longer underlined/coloured
# as "unknown". See the README for installation instructions.
#
# Environment
\begin{trainmap}
\begin{trainmap}[options%keyvals]
\end{trainmap}
#
# Trunk definition
\settrunk{y/color, y/color, ...}
#
# Stations
\addstation{name}
\addstation[options%keyvals]{name}
\addterminal{name}{line}
\addterminal[options%keyvals]{name}{line}
\addinterchange{name}
\addinterchange[options%keyvals]{name}
#
# Tracks, branches and forks
\track{from}{to}{color}
\track[options%keyvals]{from}{to}{color}
\branch{from}{to}{color}
\branch[options%keyvals]{from}{to}{color}
\forkup{from}{to}{color}
\forkup[options%keyvals]{from}{to}{color}
\forkline{from}{to}{color}
\forkline[options%keyvals]{from}{to}{color}
\forkdown{from}{to}{color}
\forkdown[options%keyvals]{from}{to}{color}
\joinline{from}{to}{color}
\joinline[options%keyvals]{from}{to}{color}
#
# Exposed macros (position of the last placed station)
\tmlastx
\tmlasty
#
# Configuration keys (used inside [ ... ])
#keyvals:\begin{trainmap},\addstation,\addterminal,\addinterchange
mode=fgc,rodalies
line code=#%<code%>
line color=#%<color%>
track width=#%<dim%>
station color=#%<color%>
station width=#%<dim%>
terminal size=#%<dim%>
terminal border=#%<dim%>
badge color=#%<color%>
capsule width=#%<dim%>
capsule inner=#%<dim%>
capsule color=#%<color%>
station step=#%<num%>
track sep=#%<num%>
max width=#%<num%>
row sep=#%<num%>
label angle=#%<num%>
label position=above,below
corr=#%<CODE/color,...%>
name=#%<id%>
#endkeyvals
