Re: [Boost-docs] [quickbook][boostbook] CSS & image files

Subject: Re: [Boost-docs] [quickbook][boostbook] CSS & image files
From: John Maddock (boost.regex_at_[hidden])
Date: 2010-07-10 10:00:15


>> When I've needed an absolute path, I've always used the path-constant
>> rule,
>> for example in the Boost.Math docs we use:
>> path-constant images_location : html ;
>
> OK I've tried this, and echoing it says
>
> images_location
> I:\boost-sandbox\tools\quick_auto_dox_index\libs\quick_auto_dox_index\doc\html
>
> as expected.
>

> So in my jamfile I have (to get the location of my images for both html
> and pdf)
>
> <xsl:param>img.src.path=$(images_location)/
>
> In my Quickbook I have
>
> [$my_image.jpg]
>
> but I don't get the image displayed and the image info (split to avoid
> word wrap) is
>
> i:%5Cboost-sandbox%5Ctools%5Cquick_auto_dox_index%5Clibs%5Cquick_auto_dox_index
>
> %5C doc%5Chtml/
>
> ../my_image.jpg
>
> There seems to be a (to me) unexpected (and unwanted) ../ before
> my_image.png
>
> (and of course the confusing %C is caused by nasty Windows backslashing
> :-( )
>
> So it doesn't display the image even if my_image.png is at /doc/html
> and/or /doc/ :-(
>
> Is this a valid file specification? Windows explorer says "The file name
> is not valid."
>
> So what am I doing wrong? Or is the Quickbook call causing this?

OK, first things first... you can't use the same path for PDF and html
generation: PDF's will want absolute paths so that regardless of where the
PDF actually gets built (in some deep directory known only to Boost.Build)
the FO processor will still be able to find the images. HTML files will
want a relative path with all forward /'s so they act as relative URL's.

I'm not sure where the extra .. is coming from in your paths - probably from
the xslt stylesheets - according to their docs you should set img.src.path
to be relative to the location of the html files (by default ./html).

John.


This archive was generated by hypermail 2.1.7 : 2017-11-11 08:50:41 UTC