[Mono-docs-list] [PATCH] Generics Support for monodoc/tools
Joshua Tauberer
jit at occams.info
Thu Oct 5 08:51:58 EDT 2006
I had to make a few changes to get monodocs2html to work.
In stylesheet.xsl, an instance of $type should have been, I think,
$fullname, here:
<xsl:variable name="escaped-type">
<xsl:call-template name="GetEscapedTypeName">
<xsl:with-param name="typename" select="$fullname" />
</xsl:call-template>
</xsl:variable>
In monodocs2html.cs, it didn't fall back to using Name if File wasn't
found when getting a file name, so I added:
if (typefilebase == "") typefilebase = typename;
And there were other fallback issues...
Jonathan Pryor wrote:
> (i.e. should I send out a patch with the CanonicalName change, or
> should I just commit after making that change?)
Feel free to commit, no need to send a patch for CanonicalName.
> So perhaps we should split the difference, as it were: rename the
> current Name attribute to DisplayName, and add a new Name attribute
> which holds the generic name:
>
> <Type Name="NonGeneric" DisplayName="NonGeneric" />
> <Type Name="Generic`1" DisplayName="Generic<T>" />
I like that a lot. There's the added benefit that there doesn't have to
be any falling back from File to Name in the tricky filename-creation
and cref-comparison code, since Name was and will continue to be the
attribute used for that. Only the code that displays the name of a type
will have to fall back to Name if DisplayName is not there, which seems
a lot simpler.
--
- Joshua Tauberer
http://razor.occams.info
"Strike up the klezmer and start acting like a man. You're
about to have a truth-mitzvah." -- The Colbert Report
Jonathan Pryor wrote:
> On Wed, 2006-10-04 at 08:55 -0400, Jonathan Pryor wrote:
>> On Tue, 2006-10-03 at 21:03 -0400, Jonathan Pryor wrote: Attached
>> are patches to monodocer.cs (replaces previous patch) and to
>> monodoc/engine. The monodocs2html patch is not currently included
>> (I'm still working on it.
>
> And now is attached the patches for monodocs2html.exe.
>
> This does not take care of the @File => @CanonicalName change
> suggested previously.
>
> So...
>
> Permission to commit these three patches (monodocs/engine,
> monodocs/tools/monodocer, and monodocs/tools/monodocs2html) after
> making the attribute name change of File to CanonicalName?
>
> (i.e. should I send out a patch with the CanonicalName change, or
> should I just commit after making that change?)
>
> Once this is committed, I'll start looking into <version/> support
> and compiled ecma help docs. The fact that this currently works for
> uncompiled help docs & monodocs2html gives me some confidence that
> this is functional code.
>
> Thanks, - Jon
>
More information about the Mono-docs-list
mailing list