Worst Phobos documentation evar!

Walter Bright via Digitalmars-d digitalmars-d at puremagic.com
Mon Dec 29 18:28:09 PST 2014


On 12/29/2014 3:47 PM, H. S. Teoh via Digitalmars-d wrote:
> 	Returns: A range of dollar amounts -- if the input is $100 or
> 	more, as stated in Dr. Watson's "A One" specs; otherwise an
> 	empty range.
>
> becomes this monstrosity:
>
> 	Returns: A range of dollar amounts$(MDASH)if the input is
> 	$(DOLLAR)100 or more$(COMMA) as stated in Dr$(DOTSPACE)Watson's
> 	$(RDQUO)A$(NBSP)One$(LDQUO) specs; otherwise an empty range.

I'd write it as:

	Returns: A range of dollar amounts $(MDASH) if the input is
	$(DOLLAR)100 or more, as stated in Dr. Watson's $(Q A One) specs;
	otherwise an empty range.

In fact, you don't even need the $(MDASH) if you're willing to insert the 
Unicode character directly. Nor do you need the $(Q ) if you're willing to use " 
", or the Unicode characters directly. The only markup actually needed is the 
$(DOLLAR).

I have just finished doing the markup, 100% in ddoc, for this 650 page book:

   http://www.generalatomic.com/Historians/vol1.pdf

and made it available here:

   http://www.amazon.com/exec/obidos/ASIN/B00REVL4BC/classicempire

(yes, that's an affiliate link!)

Sadly, the ebook format doesn't allow for all the formatting I'd like to have, 
but the html version is pretty nearly identical to the old book layout. It's 
full of strange formatting, weird characters, footnotes, superscripts, multiple 
fonts, tables, 4 languages, etc., and I was able to do it all. Even two 
different layouts, one for HTML and one for Ebook.

I.e. I am a heavy user of Ddoc, and not just for the random Phobos function.

(Doing these old books is a bit of a hobby of mine. Next up is my grandfather's 
book on crystallography.)


More information about the Digitalmars-d mailing list