This project has moved and is read-only. For the latest updates, please go here.

How to add "Other Variations" to method page?

Topics: Developer Forum, User Forum
Jan 12, 2013 at 1:04 AM

Hey guys

I am using the "Prototype" presentation which has been customised in a number of ways to meet my needs. When there are overloaded methods a sort of "Table of Content" page appears allowing the user to choose the signature that they are interested in. This is great.

I would like to add the same listing at the top of each method page to make it easier for people to navigate between overloaded signatures.

Take the following page ( for example, I would like to display the following at the start of the page:

<h1>GetChunkFromTileIndex Method (row, column)</h1>
    <li><a href="">GetChunkFromTileIndex Method (index)</a></li>
<div class="summary">
Gets chunk component from a tile index.

Where the current page is shown as the H1 and the other related pages are shown in an unordered list.

Is there a relatively straightforward way to modify the stylesheet enumerate these?

Many thanks

Jan 12, 2013 at 8:36 PM

As I recall, the See Also section renders a link back to the Overloads topic so you should be able to find the same info in the metadata for the topic.  It would just be a matter of rendering the section if such information was present.



Jan 13, 2013 at 4:57 PM
Edited Jan 13, 2013 at 4:57 PM

The overloads page doesn't appear to be added to the "See Also" section (at least not for the Prototype presentation).

I changed the entry template to dump the root document:

<xsl:copy-of select="/document"/>

And looking through here the only hint is the following:

<overload api="Overload:Rotorz.Tile.TileSystem.GetChunkFromTileIndex" />

So it seems that if I wanted to do this I would need to somehow alter the output of "/document".

Out of interest, which XSLT 2.0 processor does SandCastle use? I didn't think that .NET supported XSLT 2.0.

Jan 13, 2013 at 7:10 PM

Sandcastle uses the stuff built into .NET.  Earlier versions may not have supported XSLT 2.0 but .NET 4.0 does.  I had to update the templates to use it since the 1.0 implementation in .NET 4.0 has a bug that prevents sorts from working properly.