|
Subject: string->quantity ? From: David Carlisle <davidc@xxxxxxxxx> Date: Thu, 23 Jul 1998 17:09:06 +0100 |
dsssl provides a string->number function to convert a string to a
number, but what I need is conversion to a length.
Mainly because I want to get ``3pt''
from here:
<mspace width="3pt">
to here:
(make line-field
field-width: 3pt)
by way of attribute-string.
I did find something that would work, namely the function
measurement-to-length
in the docbook library (Ever a life saver!), in the file dblib.dsl but
that works by parsing the string `by hand' in dsssl code, to extract the
digits, and then looking up the remaining characters in a dsssl alist of
unit conversions eg "mm" -> 1mm.
Not that I want to cast doubt on Norm's code but is that really the only
way?
David
DSSSList info and archive: http://www.mulberrytech.com/dsssl/dssslist
| Current Thread |
|---|
|
| <- Previous | Index | Next -> |
|---|---|---|
| FOTBuilder symbolBevel, Frank A. Christoph | Thread | jade SGML output, Louis-Dominique Dube |
| FOTBuilder symbolBevel, Frank A. Christoph | Date | jade SGML output, Louis-Dominique Dube |
| Month |