Closed GoogleCodeExporter closed 8 years ago
I can't reproduce this bug, can you create a very simple example that shows it
and attach?
Original comment by micmath
on 8 Nov 2009 at 8:47
I'll try to put together a simple example later this week. In the mean time, it
might be easy to just look at a zip of the js files where this turned up. The
GridView.js file has red font styling in its first annotations to indicate
deprecation. The Message.js file has black font styling in its first
annotations to
make sure that the red styling from GridView.js actually gets turned off in the
class
list.
You can see the final results here (with linked source code, thanks to the
jsdoc-toolkit!):
https://www.labkey.org/download/clientapi_docs/javascript-api-9.3-draft/index.ht
ml
Thanks very much for taking a look.
Original comment by ekaynel...@gmail.com
on 8 Nov 2009 at 10:05
Attachments:
The template that generates the "Class Index" is jsdoc/index.tmpl. If you take
a look at that you'll see that the
class descriptions are passed through summarize(), which is defined in
publish.js. The summarize method
trims away all the text after the first sentence. You are writing descriptions
that have an opening FONT tag,
but the closing FONT tag is *after* the end of the sentence, therefore
summarize() trims away the closing tag.
You can solve this a few ways. Most easily you can move the FONT closing tag so
that it is before the end of
the first sentence.
A better solution would be to add a @deprecated tag to the classes that are
deprecated, then modify
jsdoc/index.tmpl so that it has the following:
<for each="thisClass" in="data">
<div>
<h2>{+(new Link().toSymbol(thisClass.alias))+}</h2>
<span{! if (thisClass.comment.getTag("deprecated").length) {output += " style='color: red'";}
!}>{+resolveLinks(summarize(thisClass.classDesc))+}</span>
</div>
<hr />
</for>
Original comment by micmath
on 8 Nov 2009 at 10:54
Sigh. So clear in retrospect. Thank you for your sleuthing -- I forgot about
the
limitation on the first sentence.
Thank you very much for the suggested alteration to the index.tmpl. That's
definitely the right way to do this.
Original comment by ekaynel...@gmail.com
on 9 Nov 2009 at 1:12
Original issue reported on code.google.com by
ekaynel...@gmail.com
on 16 Oct 2009 at 1:41