This is the mail archive of the docbook@lists.oasis-open.org mailing list for the DocBook project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: What DocBook element for name of a programming langauge?


On Tue, 12 Dec 2000, Michael Smith wrote:

> Trevor Jenkins <trevor@suneidesis.com> writes:
> 
> > ..., I can't find anything
> > appropriate for the name of the programming language itself. :-( It would
> > not be correct to use either the Application ...
> 
> As a workaround, maybe edit the ATTLIST declaration for the
> <application> element so that <application class="language"> is valid?

Strictly speaking then it ceases to be DocBook. 

> Also, processing apps won't typically render <application>-tagged
> words in any special way (e.g. bold, italic, monospace), which is just
> how you want it to be -- should have no special character formatting.

Nope, I would say processing apps may need to render progamming languages
name differently from the text of an enclosing element. I've come to
expect Cobol to be set as COBOL and Fortran to be set as Fortran; both in
whatever the current font attributes are. I prefer to see C as C and C++
as C++ but with the latter in a monospaced font such as Courier. Then
javascript as JavaScript and Java as coffee.

> Alternatives you might consider -- <wordasword>, <command>, others --
> all those are typically rendered with special character formatting.

There is a vast difference between C as the name of a programming language
and gcc as the name of specific compiler for that language. The former
(implicitly) refers to the ISO/ANSI or other standard defintion; the
latter refers to a computer program that supposedly follows that
definition so as to translate programming texts into a machine executable
equivalent.

> It would be nice to have a <programminglanguage> element, though. Did
> you know you can file DocBook enhancement requests?
> ...whoops, although I think you could file RFEs before, now I notice
> the "Create a new RFE" option says "Temporarily disabled." Looks like
> you may need to wait if you want to request an enhancement.

Says it all.

> Anyway -- just my opinion of course -- but I think that for now, the
> <application class="language"> customization seems a relatively
> painless solution in terms of DTD tweaking required to make the
> change, compatibility concerns, and rendering considerations.

As you can see I disagree. But at least you tried to provide an answer
thank you.

Regards, Trevor

British Sign Language is not inarticulate handwaving; it's a living language.
Support the campaign for formal recognition by the British government now!

-- 

<>< Re: deemed!


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]