This document describes how you can create a qlscribe template for printing labels with CDDB information embedded. So let's start.

1 Materials used.

qlscribe version 0.9 or later is used. If you have older version please update

I downloaded label images from lightScribe design center

Music album "Aphex Twin / Girl Boy EP" I used just as an example, I do not actually have this disc nor copy of it.

cddbcmd utility is part of package cddb and on Ubuntu can be downloaded from standard repository:

	sudo apt-get install cddb

2 Create new label and load image

Start qlscribe, hit File -> New Label -> Full. You should see something like this:

Insert image Edit -> Insert -> Image then on dialog click "Load image.." select image "MixTape.jpg" downloaded from lightScribe design center Here how my label is looking now:

3 Create text placeholders

Now select Edit -> Insert -> Text and on dialog put text "?DTITLE?". Question marks around name will make this text disapear in qlscribe console mode print. This could be not necessary for disk title as it usually set in CDDB data anyway, but would not harm. We should put question marks on song names, as number of placeholders of title names should be at least not less than songs on the disk. Adjust font size, so when printed it would fit in white area. Now move your text box in the place:

First we would create a placeholder for the first song, adjust font properly and then copy/paste it for others. So Edit -> Insert -> Text and put "?TTITLE0?". Again if we would not put question marks around name it will still work, but unused placeholders will be printed as ugly TTITLEN... strings. Move the text box to the proper position and press Ctrl-C or from menu Edit -> Copy. Press Ctrl-V and move the text box to the new postion for TTITLE1. Right click, then "edit..." and change text to "?TTITLE1?". Repeat until you have enough titles. Your label could look like this one now:

Hit menu File -> Save, save it for example as "tape.qlx" and exit qlscribe.

4 Download CDDB data

If you do not have audio disk in cd-rom you can lookup your disk id from http://www.freedb.org/ or similar. Copy it and run this command:

		cddbcmd cddb read rock 4d03a706 > girlboy.txt

In my case disk id is rock/4d03a706.

Check that file have proper data, it should look similar to this:

# xmcd CD database file
#^M

# Track frame offsets:
#       182
#       22097
#       40767
#       47095
#       55912
#       62745
#^M

# Disc length: 937 seconds
#^M

# Revision: 0
# Processed by: cddbd v1.5.2PL0 Copyright (c) Steve Scherf et al.
# Submitted via: IdiotJukebox 1.0 (Emacs 19.34.1)
#^M

DISCID=4d03a706
DTITLE=Aphex Twin / Girl Boy EP
TTITLE0=Girl Boy (nls mix)
TTITLE1=Milk Man
TTITLE2=Inkey$
TTITLE3=Girl Boy (Snarerushmix)
TTITLE4=Beetles
TTITLE5=Girl Boy (Redruthmix)
EXTD=
EXTT0=
EXTT1=
EXTT2=
EXTT3=
EXTT4=
EXTT5=
PLAYORDER=

5 Test you template

Now we can test how our created at step 2-3 template works with the data. Run qlscribe in console mode to print label as an image:

		qlscribe --image girlboy.jpg --file girlboy.txt tape.qlx

If everything fine you should now see file girlboy.jpg in the current directory. Here is what I got for mine:

6 Print label

Now if you are happy with the result at step 5 you can print label directly:

		qlscribe --print --file girlboy.txt tape.qlx

Enjoy!

Please send comments, suggestions or noticed errors directly to mailto:vyacheslav@kononenko.net or visit http://qlscribe.sourceforge.net and create an item in the Bug tracker.