Technitribe

interesting problems (and a few solutions, too)

Technitribe
  • About the Authors
  • Log In
  • Log Out
  • Lost Password
  • Register
  • Reset Password
    • 23 Jun 2013

      Update: Using TTF Fonts with DocBook and Dblatex

      Written by Tim Bielawa

      This is an update to a previous blog post where I described how I was able to use custom fonts in my docbook -> dblatex -> pdf toolchain by switching to the XeTeX backend.

      I closed that blog post with a few caveats:

      • remark elements no longer appear in PDF output
      • The DRAFT watermark no longer appears
      • screen elements no longer show a ‘wrapping character’ in long lines

      I’m pleased to say that I’ve recently revisited my publishing toolchain and two of those three caveats are no longer an issue.

      Through a series of unexpected clicks on the dblatex releases page I found myself looking at links to download newer versions of dblatex than I was presently using. Though the updates are not scheduled for inclusion in Fedora 17, they are (going to be) available in Fedora 18 and Fedora 19. I quickly skimmed over the changelogs and found some interesting bug fixes. Such as:

      dblatex 0.3.3:

      • Remove hard-coded paper size and add some parameters for page layout setup:
        • Parameters to define page sizes and margins.
        • Parameters to have crop marks for pre-press PDF output.
      • Fix Debian bug #629514 to have draft watermark with XeTeX backend.

      Because I’m targeting smaller book dimensions for the Virtual Disk Guide I was most interested in the first fix mentioned: the removal of hard-coded paper sizes. Unfortunately, the documentation on the official dblatex site has not been updated in quite some time. It seems that they’re still displaying an early 0.3.x release of the docs.

      Wouldn’t you know it… Some kind souls out there on the Internets have actually built and host the most recent version of the dblatex documentation online! Now I’m able to get a smaller page format which is suitable for the dimension options on lulu.com without having to directly hack any of the dblatex styles. All it takes now is: <xsl:param name=”paper.type”>a5paper</xsl:param> Header and footer content receive appropriate margins automatically, too. No more fussing around!

      Other notes

      • The draft watermark works in PDF output once again.
      • Hyphenation in examples works correctly again.
      • Tags »

    One Comment on “Update: Using TTF Fonts with DocBook and Dblatex”

    • Using TTF fonts with DocBook and dblatex | Technitribe | not at all like a diatribe

      23 Jun 2013 01:06 pm

      […] Update: Using TTF Fonts with DocBook and Dblatex […]

    Leave a Reply Cancel reply

    Your email address will not be published. Required fields are marked *

    • The Authors
    • Virtual Disk Guide

      Interested in virtualization? Do QCOWs rule your filesystem? Are you a libvirt or KVM+QEMU wizard? I wrote a book about virtual disk management. Check out the The Linux Sysadmin's Guide to Virtual Disks online for free at ScribesGuides.com.


      Consider supporting the author by purchasing a hard copy of the first edition for just $10.00 on Lulu.com.

    • bitmath

      bitmath is a Python library for dealing with file size units (GiB's, kB's, etc) in a sane way. bitmath supports arithmetic, rich comparison, conversion, automatic best human-readable representation, and many other utility functions. Read some examples on the docs site or check out the source on GitHub.

    • latest posts

      • Querying block device sizes in Python on Linux and Mac OS X February 4, 2023
      • Using jq to filter an array of objects from JSON September 9, 2019
      • Two Year Break — And we’re back! November 16, 2018
    • tags

      bitmath blog conference css dblatex DNS DocBook eclipse Emacs Erlang Fedora fedora 22 filter GNU Screen Haiku Introduction java jboss LCSEE Linux locale locales fix slicehost ubuntu Macports module nist nXML-Mode opengl open source OS X package packaging pki prefix units presentation project pypi Python scholarship si summit Tutorial ubuntu xcode XML XMPP
    • h4ck teh world

      tbielawatbielawa
      • Issue Comment
        bitmath
        February 6, 2023 - 12:55 am UTC
      • Issue Comment
        bitmath
        February 6, 2023 - 12:54 am UTC
      • Push
        bitmath
        February 6, 2023 - 12:51 am UTC
      • Issue Comment
        bitmath
        February 6, 2023 - 12:36 am UTC
      • Push
        bitmath
        February 6, 2023 - 12:30 am UTC

Creative Commons License
Technitribe by Tim Bielawa is licensed under a Creative Commons Attribution-ShareAlike 4.0 International License.