*daps.txt* Plugin for using daps (https://opensuse.github.io/daps) commands inside Vim.

                                                           *daps-installation*
I recommend using a plugin manager such as vim-plug
(https://github.com/junegunn/vim-plug) to install and update vim-daps.  If you
do not want to use a plugin manager, download and uncompress the tarball into
  your ~/.vim/plugin directory.

                                                           *daps-requirements*
You need to have daps (https://opensuse.github.io/daps) installed to use
vim-daps commands in your Vim editor.

Note:
Before using any of vim-daps commands, you first have to specify which DC file
you are going to use in the current buffer with the :DapsSetDCfile <DC-file>
command.

Commands:
:DapsSetDCfile <dc-file>
  Specifies the DC file to be used by the current Vim buffer.

:DapsValidate
  Validates the DocBook XML document specified by the give DC file.

:DapsBuild
  Builds documentation by the specified build target.

:DapsHtml
  Builds HTML from the DocBook XML document in the current buffer.

:DapsPdf
  Builds PDF from the DocBook XML document in the current buffer.

:DapsXmlFormat
  Beautifies the XML source code in the current buffer.

:DapsImportEntites <entity_file>
  Imports XML entities found in the given file for auto-completion
  purposes. If no file is specified, entities are imported from
  the current file's <!ENTITY tag.

:DapsSetDoctype <doctype>
  Set DocType for DocBook documents and import available entities. vim-daps
  ships with 'docbook50' (default), and 'geekodoc5'.

:DapsSetRootId <root_id>
  Specifies the optional --rootid parameter. If the optional parameter is
  missing, unsets the root ID.

:DapsSetBuildTarget <build_target>
  Specifies the build target, 'html' or 'pdf'.

:DapsOpenTarget <xml_id>
  Opens new tabs with files that contain the specified xml:id. You can specify
  the ID in the command line with tab-completion, or place a cursor on a <xref>
  line and the ID will be extracted for you.

:DapsOpenReferers <xml_id>
  Opens new tabs with files that refer to the specified xml:id. If the cursor
  is currently on a line containing xml:id="<xml_id>" and you do not specify
  the XML ID on the command line, it is extracter from the current line
  instead.

:DapsImportXmlIds
  Imports XML IDs from the current book/bookset based on a provided DC file.
  You can then auto complete them inside the '<xref linkend=""/>' tag.

:DapsShiftSectUp :DapsShiftSectDown
  Shifts the visually selected DocBook XML sections' structure up or down
  one level. Useful for refactoring documents.

                                                           *daps-settings*
g:daps_dc_file = <file>
  Specifies the DC file to use by default.

g:daps_root_id = <root_id>
  Specifies the default root ID to build.

g:daps_build_target = <build_target>
  Specifies the default build target, 'html' or 'pdf'.

g:daps_dcfile_glob_pattern = <pattern>
  Set the globbing pattern to be used for DC file autocompletion.

g:daps_entfile_glob_pattern = <pattern>
  Globbing patter for entity file autocompletion. Default is '*'.

g:daps_doctype = <doctype>
  Set the default doctype for DocBook documents. Default is 'docbook50'.

g:daps_html_viewer = <command>
  Set the default application for viewing HTML output. Default is the desktop
  environment's MIME handler.

g:daps_pdf_viewer = <command>
  Set the default application for viewing PDF output. Default is the desktop
  environment's MIME handler.

g:daps_builddir = <directory>
  Set the --builddir directory for the current buffer. Default is the 'build/'
  subdirectory of the current directory.

g:daps_auto_import_xmlids = 0 or 1
  Whether or not import all the XML IDs related for the current DC file
  to XML omnicompletion after a DC file is specified. Default is 1.

g:daps_dapsroot = <directory>
  Use daps from a git checkout directory instead of the default RPM
  installation.  This option is useful if you want to try the development
  version of daps.

g:daps_debug = 0 or 1
  Set this to output debug messages, either to an editor windowm, or a file
  specified with 'g:daps_log_file'

g:daps_log_file = <log_file_name>
  The file name of a file where to output debug messages. Note that
  'g:daps_debug' must be set to '1'

g:daps_xmlformat_script = <path_to_script>
  The file name of the executable script that formats the XML source document.
  Defaults to 'xmlformat' or 'xmlformat.pl' if found in the path.

g:daps_xmlformat_conf = <path_to_conffile>
  The file name of the configuration file for 'xmlformat'. Defaults to the one
  provided by daps.

g:daps_xml_schema_map = { suffix1: doctype1, suffix2: doctype2, ... }
  Specifies the doctype mapping based on the active file name suffix.

    let daps_xml_schema_map = { '.asm.xml': 'assembly', '.xml': 'geekodoc5' }
