medit/moo/mooedit/menu.cfg
2007-11-27 02:08:47 -06:00

172 lines
2.9 KiB
INI

# -%- strip: false; indent-width: 2 -%-
#[tool]
#id = ShellCommand
#name = _Shell Command
#os = unix
#type = moo-script
#options = need-doc
# cmd = HistoryEntry("", "ShellCommand");
# if cmd then
# Insert(Exec(cmd), "\n");
# fi;
[tool]
id = SortLines
name = Sort Lines
type = exe
os = unix
options = need-doc
input = lines
output = insert
sort
[tool]
id=Yacc
langs=yacc
type=exe
os=unix
name=Bison
filter=bison
options=need-save
output=pane
bison $DOC
[tool]
id=LaTeX
file-filter=*.tex
type=exe
os=unix
name=LaTeX
filter=latex
options=need-save
output=pane
accel=<shift><ctrl>L
[ -f medit-env.sh ] && . medit-env.sh
doc="${LATEX_MASTER:-$DOC}"
latex --src-specials "$doc"
[tool]
id=Make_PDF
file-filter=*.tex
type=exe
os=unix
name=Make PDF
filter=latex
options=need-save
output=pane
[ -f medit-env.sh ] && . medit-env.sh
doc="${LATEX_MASTER:-$DOC}"
doc_base=`basename "$doc" .tex`
latex --src-specials "$doc" && \
dvips "$doc_base.dvi" && \
ps2pdf "$doc_base.ps"
[tool]
id=Bibtex
file-filter=*.tex
type=exe
os=unix
name=Bibtex
options=need-doc
output=pane
accel=<shift><ctrl>B
[ -f medit-env.sh ] && . medit-env.sh
doc="${LATEX_MASTER:-$DOC}"
doc_base=`basename "$doc" .tex`
bibtex "$doc_base"
[tool]
id=PdfLaTeX
file-filter=*.tex
type=exe
os=unix
name=PdfLaTeX
filter=latex
options=need-save
output=pane
[ -f medit-env.sh ] && . medit-env.sh
doc="${LATEX_MASTER:-$DOC}"
pdflatex "$doc"
[tool]
id=View_DVI
file-filter=*.tex
type=exe
os=unix
name=View DVI
options=need-doc
output=async
accel=<shift><ctrl>V
[ -f medit-env.sh ] && . medit-env.sh
doc="${LATEX_MASTER:-$DOC}"
doc_base=`basename "$doc" .tex`
if (which kdvi > /dev/null); then
kdvi --unique "$doc_base.dvi" && \
dcop `dcopfind -a 'kviewshell-*'` kdvi-mainwindow#1 hide && \
dcop `dcopfind -a 'kviewshell-*'` kdvi-mainwindow#1 show
else
xdg-open "$doc_base.dvi"
fi
[tool]
id=View_PDF
file-filter=*.tex
type=exe
os=unix
name=View PDF
options=need-doc
output=async
[ -f medit-env.sh ] && . medit-env.sh
doc="${LATEX_MASTER:-$DOC}"
doc_base=`basename "$doc" .tex`
if (which kpdf > /dev/null); then
kpdf=`dcopfind -a 'kpdf-*'`
if [ -z "$kpdf" ]; then
kpdf "$doc_base.pdf"
kpdf=`dcopfind -a 'kpdf-*'`
else
dcop "$kpdf" kpdf openDocument "$doc_base.pdf"
fi
dcop "$kpdf" kpdf-mainwindow#1 hide
dcop "$kpdf" kpdf-mainwindow#1 show
else
xdg-open "$doc_base.pdf"
fi
[tool]
id=Math
file-filter=*.tex
type=lua
name=Math
options=need-doc
accel=<alt>M
selection = Selection()
if selection then
Insert("$", selection, "$")
else
Insert("$ $")
Left()
Select(-1)
end
[tool]
id=InsertDateAndTime
type=python
name=Insert Date and Time
options=need-doc
# insert_date_and_time.py is installed in
# $prefix/lib/moo/plugins/lib
from insert_date_and_time import get_format
import time
fmt = get_format(window)
if fmt is not None:
buffer.insert_at_cursor(time.strftime(fmt))