Modify

Opened 10 years ago

Closed 9 years ago

Last modified 9 years ago

#1166 closed Feature Requests (fixed)

[boostbook] paths relative to boost.root

Reported by: Steven Watanabe Owned by: Daniel James
Milestone: Boost 1.39.0 Component: Documentation
Version: Boost 1.35.0 Severity: Problem
Keywords: Cc:

Description

One of the thing that I find most annoying about the documentation tool chain is that I cannot write links that work both for builds of all of boost and builds of just one library. If boost://libs/mpl/index.html or something similar worked then I would be a lot happier. I am attaching a patch that allows this syntax.

Attachments (5)

relative-href.xsl.patch (1.1 KB) - added by Steven Watanabe 10 years ago.
xref.xsl.patch (621 bytes) - added by Steven Watanabe 10 years ago.
links.patch (2.1 KB) - added by Daniel James 10 years ago.
Updated implementation, that uses 'boost:/libs..' instead of 'boost://libs..', and works for links from sub-directories.
boost-links-1.patch (1.2 KB) - added by Daniel James 9 years ago.
New implementation, which transforms the links in the boostbook to docbook stage. Currently only translates ulinks, not other links such as images.
boost-links-2.patch (6.9 KB) - added by Daniel James 9 years ago.
Some examples of using the 'boost:/' style links.

Download all attachments as: .zip

Change History (12)

Changed 10 years ago by Steven Watanabe

Attachment: relative-href.xsl.patch added

Changed 10 years ago by Steven Watanabe

Attachment: xref.xsl.patch added

comment:1 Changed 10 years ago by Marshall Clow

Component: NoneBuilding Boost

comment:2 Changed 10 years ago by Daniel James

Component: Building BoostDocumentation
Owner: set to Daniel James
Severity: Not ApplicableProblem
Status: newassigned
Version: Boost 1.34.1Boost 1.35.0

Yes, this is definitely needed.

boost://libs/mpl/index.html is probably wrong, as the :// usually indicates that the first past part of the path is a server name. boost:/libs/mpl/index.html or perhaps boost:libs/mpl/index.html is better.

Another possibility is to just do this for paths starting with '/', as that does suggest the root of the distribution. I like this, as I'm not keen on inventing our own protocol name. But 'boost:' will work very well if $boost.root == 'http://www.boost.org' - so it'll be ideal for candidate libraries.

I'll attach an updated patch which implements what I described, and also fixes a small bug when the link is from a sub-directory.

I'll bring this up on the Boost Docs list soon, as someone might have a better idea.

Changed 10 years ago by Daniel James

Attachment: links.patch added

Updated implementation, that uses 'boost:/libs..' instead of 'boost://libs..', and works for links from sub-directories.

comment:3 Changed 9 years ago by Daniel James

Milestone: To Be DeterminedBoost 1.37.0

I've been trying something like this in the doc branch, but it still doesn't completely work. Beacuse it's done as part of the chunking mechanism it only works for chunked output (ie. html/xhtml) but not for other types such as fo (for generating pdfs) and html-single. The links should be dealt with in the initial boostbook to docbook conversion. I'll get back to this.

comment:4 Changed 9 years ago by Steven Watanabe

Another thing, Would it be better to have a generic mechanism for specifying the root of a path as using an xsl parameter. so that this would become $(boost.root)/... Is this evan possible in xsl?

I'd also like to be able to specify the root of relative paths so that I can just specify paths relative to my quickbook sources rather than specifying the paths relative to the destination directory, since this is different for the standalone docs vs. the global boost doc build.

Changed 9 years ago by Daniel James

Attachment: boost-links-1.patch added

New implementation, which transforms the links in the boostbook to docbook stage. Currently only translates ulinks, not other links such as images.

Changed 9 years ago by Daniel James

Attachment: boost-links-2.patch added

Some examples of using the 'boost:/' style links.

comment:5 Changed 9 years ago by Daniel James

Resolution: fixed
Status: assignedclosed

(In [51261]) Implement the 'boost:' for links relative to boost root. Also, optionally replace links within the boost distribution with links to the the boost site, which is useful for generating pdfs and standalone documentation.

Implemented with John Maddock. Fixes #1166.

comment:6 Changed 9 years ago by Daniel James

(In [51739]) Record another previous change:

Recorded merge of revisions 51261 via svnmerge from https://svn.boost.org/svn/boost/trunk

........

r51261 | danieljames | 2009-02-15 19:31:37 +0000 (Sun, 15 Feb 2009) | 5 lines

Implement the 'boost:' for links relative to boost root. Also, optionally replace links within the boost distribution with links to the the boost site, which is useful for generating pdfs and standalone documentation.

Implemented with John Maddock. Fixes #1166.

........

comment:7 Changed 9 years ago by Daniel James

Milestone: Boost 1.37.0Boost 1.39.0

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain Daniel James.
The resolution will be deleted.

Add Comment


E-mail address and name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.