wiki:Technical/DocCrossReference

Documentation Cross Reference

Now that we're moving the documentation to DocBook, we'll be able to cross-reference documentation from within aegisub. This means:

  • We can reference sections in error messages
  • The Help buttons will be able to open to the correct section in the docs.
  • We can have a context sensitive floating ? so a user can get info on a specific feature.

Design

This section describes how references will work from within aegisub.

Reference file format

It's possible, using the docbook style sheets to create a target file that has the generated list of all sections with all pertinent reference info.

<div element="book" href="#id20476224" number="">
  <ttl>Aegisub User Manual</ttl>
  <xreftext>Aegisub User Manual</xreftext>
  <div element="preface" href="#introduction" number="" targetptr="introduction">
    <ttl>Introduction</ttl>
    <xreftext>Introduction</xreftext>
    <div element="sect1" href="#i-layout" number="1" targetptr="i-layout">
      <ttl>Layout of this document</ttl>
      <xreftext>Section 1, “Layout of this document”</xreftext>
    </div>
  </div>
</div>
  • div - A section from within the document.
    • element= - Tag name.
    • href= - HTML text anchor (these can change on a whim.)
    • number= - Section number, eg 1, 1.1, 1.1.2.
    • targetptr= - Anchor for the section within the document (these will never change their names.)
  • xreftext - The text used to refer to the target.
  • ttl - Title of the section
  • xreftext - Full reference text.

Attachments

  • target.db.xml Download (47.0 KB) - added by verm 3 years ago. Example file, this is NOT the final version it will change drastically