finish the intention of the previous commit, correctly this time
[ardour2.git] / manual / config / dbhelper.vim
blobce328750eab424e8446429b1d542d0945036b5a9
1 " Tim Mayberry's .vimrc mappings for use with DocBook 4.3. This has been 
2 " revised from Vivek Venugopalan's .vimrc which was revised from Dan York's .vimrc 
3 " Revised: August 23, 2006
4 " Used with vim 7.0
5 " email : mojofunk@gmail.com
7 " MAPPINGS
8 " Like the .vimrc file shown at http://www.vim.org/ I decided to
9 " start all my mappings with a comma. Since I do pretty much all
10 " my work in DocBook, I just started with the letter after the 
11 " comma for a DB tag, rather than using something like 'd' to 
12 " indicate it was a DB tag (i.e. ',dp' instead of ',p'). If you 
13 " want to use other mappings, you may want to change this.
14 " My mappings are currently primarily for easy of entering DB
15 " tags. I haven't yet gotten into changing existing text with mappings.
17 " A side effect of using the comma for mappings is that when you type
18 " a comma in vim, it will now pause and wait for input. If you just hit
19 " the spacebar, you should see a regular old comma appear.
21 " Note: 'imap' = a mapping for 'insert' mode of vim
22 " All of these commands work ONLY when you are in Insert mode
24 " <CR> will put a line return in the file. This is purely my style of
25 " entering certain DocBook tags.  You may wish to remove some.
27 " After typing the DocBook tag, many of these macros then switch to 
28 " vim command mode, reposition the cursor to where I want it to be, 
29 " and then re-inter insert mode. You may wish to change where it ends.
31 let mapleader = ","
33 " header and setup info for a book
34 imap<leader>dtbk <!DOCTYPE BOOK PUBLIC "-//OASIS//DTD DocBook V4.2//EN">
35 imap<leader>bk <book><CR><bookinfo><CR><title></title><CR><author><CR><firstname></firstname><CR><surname></surname><CR></author><CR><address><email></email></address><CR><copyright><CR><year></year><CR><holder></holder><CR></copyright><CR><revhistory><CR></revhistory><CR></bookinfo><CR><CR></book><esc>12k$bba
36 "Internal subset declaration
37 imap<leader>et <!ENTITY TODO-key "TODO-value"><CR>
38 imap<leader>rev <revision><CR><revnumber></revnumber><CR><date></date><CR><authorinitials></authorinitials><CR><revremark></revremark><CR></revision><esc>4k$bba
40 "header and setup info for an article.
41 imap<leader>dtart <!DOCTYPE ARTICLE PUBLIC "-//OASIS//DTD DocBook V4.1//EN">
42 imap<leader>art <article><CR><title></title><CR><CR><artheader><CR><CR><author><CR><firstname></firstname><CR><surname></surname><CR><affiliation><CR><address><email></email></address></affiliation><CR></author><CR><CR><revhistory><CR></revhistory><CR><CR></artheader><CR><abstract><CR><indexterm><CR><primary></primary><CR></indexterm><CR><para><CR><para><CR></abstract><CR><CR></article><esc>16k$bba
44 "Paragraph formatting
45 imap<leader>p <para><CR></para><esc>k$a
47 " character formatting
48 imap<leader>em <emphasis></emphasis><esc>bba
49 imap<leader>es <emphasis role="strong"></emphasis><esc>bbla
51 "Special characters
52 imap<leader>> &gt;
53 imap<leader>< &lt;
55 " links
56 imap<leader>ul <ulink url=""></ulink><esc>bb3la
57 imap<leader>lk <link linkend=""></link><esc>bb3la
58 imap<leader>x <xref linkend=""/><esc>bla
60 " lists
61 " note that '<leader>l2' was created solely to fit into<leader>il and<leader>ol
62 imap<leader>li <listitem><CR><para><CR></para><CR></listitem><esc>kk$a
63 imap<leader>l2 <listitem><CR><para><CR></para><CR></listitem>
64 imap<leader>il <itemizedlist><CR><leader>l2<CR></itemizedlist><esc>kkk$a
65 imap<leader>ol <orderedlist><CR><leader>l2<CR></orderedlist><esc>kkk$a
66 imap<leader>ve <varlistentry><CR><term></term><CR><leader>l2<CR></varlistentry>
67 imap<leader>vl <variablelist><CR><title></title><CR><leader>ve<CR></variablelist>
69 " sections
70 imap<leader>sn <section id=""><CR><title></title><CR><para><CR></para><CR></section><esc>kkkk$bla
71 "imap<leader>s1 <sect1 id=""><CR><title></title><CR><para><CR></para><CR></sect1><esc>kkkk$bla
72 "imap<leader>s2 <sect2 id=""><CR><title></title><CR><para><CR></para><CR></sect2><esc>kkkk$bla
73 "imap<leader>s3 <sect3 id=""><CR><title></title><CR><para><CR></para><CR></sect3><esc>kkkk$bla
74 imap<leader>ch <chapter id=""><CR><title></title><CR><para><CR></para><CR></chapter><esc>kkkk$bla
76 " media related
77 imap<leader>fig <figure><CR><title></title><CR></figure><esc>k$bba
78 imap<leader>img <mediaobject><CR><imageobject><CR><imagedata fileref=""/><CR></imageobject><CR></mediaobject><esc>kk$bla
79 imap<leader>oi <objectinfo><CR></objectinfo><esc>k$a
81 " other objects
82 imap<leader>ti <title></title><esc>bba
83 imap<leader>fo <footnote><CR><para><CR></para><CR></footnote><esc>kk$a
84 imap<leader>sb <sidebar><CR><title></title><CR><para></para><CR></sidebar>
85 imap<leader>co <!--  --><esc>bhi
86 imap<leader>qt <blockquote><CR><attribution></attribution><CR><literallayout><CR></literallayout><CR></blockquote>
87 imap<leader>l <literal></literal><esc>bba
89 " glossary
90 imap<leader>ge <glossentry id=""><CR><glossterm></glossterm><CR><glossdef><CR><para><CR></para><CR></glossdef><CR></glossentry><esc>6k$bla
91 imap<leader>gt <glossterm linkend=""></glossterm><esc>bb3la
92 imap<leader>gs <glossseealso></glossseealso><esc>bba
94 " index
95 imap<leader>it <indexterm><CR><primary></primary><CR></indexterm><esc>k$bba
96 imap<leader>is <secondary></secondary><esc>bba
98 " admonitions
99 imap<leader>no <note><CR><para></para><CR></note><esc>k$bba
100 imap<leader>tp <tip><CR><para></para><CR></tip><esc>k$bba
101 imap<leader>imp <important><CR><para></para><CR></important><esc>k$bba
102 "imap<leader>ca <caution><CR><para></para><CR></caution><esc>k$bba
103 imap<leader>w <warning><CR><para></para><CR></warning><esc>k$bba
105 " computer stuff
106 imap<leader>app <application></application><esc>bba
107 imap<leader>cm <command></command><esc>bba
108 imap<leader>sc <screen><CR></screen><esc>k$a
109 imap<leader>fn <filename></filename><esc>bba
110 imap<leader>gb <guibutton></guibutton><esc>bba
111 imap<leader>gl <guilabel></guilabel><esc>bba
112 imap<leader>gm <guimenuitem></guimenuitem><esc>bba
113 imap<leader>mb <mousebutton></mousebutton><esc>bba
114 imap<leader>mc <menuchoice><guimenu></guimenu><guisubmenu></guisubmenu></menuchoice><esc>8ba
115 imap<leader>kc <keycombo><keycap></keycap><keycap></keycap></keycombo><esc>8ba
116 imap<leader>kk <keycap></keycap><esc>bba
118 imap<leader>row <row><CR><entry><CR></entry><CR></row><esc>kk$a
119 imap<leader>en <entry><CR></entry><esc>k$a
121 " examples
122 imap<leader>ex <example id=""><CR><title></title><CR></example><ESC>$kkba
124 "For preparing FAQs
125 imap<leader>faq <article class=faq><CR><title>Frequently asked questions</title><CR><CR><articleinfo><CR><CR><author><CR><firstname></firstname><CR><surname></surname><CR><affiliation><CR><address><email></email></address></affiliation><CR></author><CR><CR><revhistory><CR></revhistory><CR><CR></articleinfo><CR><abstract><CR><indexterm><CR><primary></primary><CR></indexterm><CR><para><CR><para><CR></abstract><CR><CR><qandaset><CR><qandadiv><CR><title></title><CR><qandaentry><CR><question><CR><para></para><CR></question><CR><answer><CR><para></para><CR></answer><CR></qandaentry><CR><qandadiv><CR><qandaset><CR><CR></article><esc>16k$bba
127 imap<leader>qd <qandaset><CR><qandadiv><CR><title></title><CR><qandaentry><CR><question><CR><para></para><CR></question><CR><answer><CR><para></para><CR></answer><CR></qandaentry><CR><qandadiv><esc>9k$bba
129 imap<leader>qa <qandaentry><CR><question><CR><para></para><CR></question><CR><answer><CR><para></para><CR></answer><CR></qandaentry><esc>5k$bba