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

Change Output Format

Topics: Developer Forum, User Forum
Apr 17, 2008 at 8:14 PM
I have a custom attribute that I have decorated on my classes. When I use SHFB, the attibute appears on the property's page. I would like the attribute to also appear in the table that is on the class level properties tab. Oh, BTW, I am using Hana style.

Does anyone know how to change the output to make this happen?


Apr 17, 2008 at 8:29 PM
Are you talking about the attributes decorating the member in the Syntax sections (i.e. the C# and VB.NET syntax tabs)? As long as you've got the DocumentAttributes project property set to True, they should appear by default.

Apr 17, 2008 at 9:55 PM
No, I am referring to the Members area on the Properties tab. The columns are Member and Description.
Apr 17, 2008 at 10:38 PM
You'll have to modify the Hana presentation style transformation file to do that. You could probably modify the Description column's content to add a list of attributes. You'll find it in Presentation\Hana\transforms\utilities_reference.xsl. The <xsl:template match="element" mode="member"> template controls the member list. You'll have to add the extra XSL transformation to get the attribute information into the final cell. Something like this might work (untested):

<xsl:if test="attributes/attribute">
    <xsl:for-each select("attributes/attribute/type")>
        <xsl:value-of select="substring-after(@api, ':')" />

Apr 25, 2008 at 8:16 PM

That is a step in the right direction. What I actually want is the format of:

Where the attribute is my attibute.


Apr 28, 2008 at 10:08 PM
You do get parameter info but I don't think you get parameter names in the reflection info. That aside, my XSL skills aren't up to the task of doing much more. If you want to pursue this, I'd suggest posting a message over on the Sandcastle forum where you will get a wider audience.