aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/html.h
Commit message (Collapse)AuthorAgeFilesLines
* Implement the roff(7) font-escape sequence \f(BI "bold+italic".Ingo Schwarze2013-08-081-1/+2
| | | | | This improves the formatting of about 40 base manuals and reduces groff-mandoc formatting differences in base by about 5%.
* Implement the roff \z escape sequence, intended to output the nextIngo Schwarze2012-05-311-1/+2
| | | | | | | | | | | | | | | | | | character without advancing the cursor position; implement it to simply skip the next character, as it will usually be overwritten. With this change, the pod2man(1) preamble user-defined string \*:, intended to render as a diaeresis or umlaut diacritic above the preceding character, is rendered in a slightly less ugly way, though still not correctly. It was rendered as "z.." and is now rendered as ".". Given that the definition of \*: uses elaborate manual \h positioning, there is little chance for mandoc(1) to ever render it correctly, but at least we can refrain from printing out a spurious "z", and we can make the \z do something semi-reasonable for easier cases. "just commit" kristaps@
* Add the -Ofragment option to -T[]x]html. This accomodates for embeddingKristaps Dzonsons2011-10-051-4/+6
| | | | | manual output in existing HTML or XHTML documents, e.g., when invoking mandoc from an SSI or CGI.
* forgotten Copyright bumps; no code changeIngo Schwarze2011-09-181-2/+2
| | | | found while syncing to OpenBSD
* Flip on equation printing for -T[x]html.Kristaps Dzonsons2011-07-231-1/+2
|
* Cleanups in -T[x]html: make html_idcat() use the buffer and be calledKristaps Dzonsons2011-05-171-7/+7
| | | | | | bufcat_id(), then collapse it into a little function without so much crap. Next, make bufinit() only be called when we really need to do so, and not simply before pre/post calls.
* Clean-ups in -T[x]html: inline print_num(), as it was just a singleKristaps Dzonsons2011-05-171-3/+2
| | | | | | | | | | conditional; same for print_xmltype() and print_doctype(), same reason; make bufncat() be static, as it was only being called from html.c; have bufcat() simply call through to strlcat(). Finally, assert() whenever we truncate. Also rename buffmt() -> bufcat_fmt() to differentiate from buffmt_man et al., which do not concatenate.
* Give -Thtml and -Txhtml the gift of recognising escapes when calculatingKristaps Dzonsons2011-05-141-1/+2
| | | | | widths (e.g., `Bl -tag -width "\s[blahblah]bar"). This has long since been done for -Tascii but escaped noticed with -T[x]html.
* Move "chars" interface out of out.h and into mandoc.h. This doesn'tKristaps Dzonsons2011-04-291-2/+2
| | | | | | | | | | change any code but for renaming functions and types to be consistent with other mandoc.h stuff. The reason for moving into libmandoc is that the rendering of special characters is part of mandoc itself---not an external part. From mandoc(1)'s perspective, this changes nothing, but for other utilities, it's important to have these part of libmandoc. Note this isn't documented [yet] in mandoc.3 because there are some parts I'd like to change around beforehand.
* When in a <PRE>, don't print out the <BR> before lines that have leadingKristaps Dzonsons2011-01-291-3/+4
| | | | whitespace.
* Change how -Thtml behaves with tables: use multiple rows, with widthsKristaps Dzonsons2011-01-131-1/+4
| | | | | | | | | set by COL, until an external macro is encountered. At this point in time, close out the table and process the macro. When the first table row is again re-encountered, re-start the table. This requires a bit of tracking added to "struct html", but the change is very small and follows the logic of meta-fonts. This all follows a bug-report by joerg@.
* Make -T[x]html for tables structure cells with a width. I don'tKristaps Dzonsons2011-01-061-10/+8
| | | | | | | anticipate doing much more than this for the coming release. Also, remove "base" part of struct html (not used anywhere) and put some comments in struct html.h.
* Add skeleton for -T[x]html tbl stuff. Also start to put in some bits aboutKristaps Dzonsons2011-01-041-1/+2
| | | | the up-coming version, although we're not quite there yet.
* Apparently the U tag is deprecated, so use a SPAN instead (blah). BumpKristaps Dzonsons2010-12-241-2/+1
| | | | version date for release.
* Drastically fix -T[x]html's handling of font-escape mode changes (i.e.,Kristaps Dzonsons2010-12-241-5/+5
| | | | | | | | | | | | | | | using \fI or \fP). Now, using these modes will cause a font to be rendered for each word; furthermore, setting mode within a word will do the correct thing. Second, make -man use real font tags (B, I, SMALL) to set its font instead of using font modes and fix up the pre-macro unsetting of the current mode. This fixes how roff.7 wasn't validating (<P> closing out a font mode) and has been checked against gcc.1 (more will come). I considered failure to validate OUR manual to be a show-stopper for the up-coming release.
* Implement reference-counted version of original union mdoc_data. ThisKristaps Dzonsons2010-12-221-1/+2
| | | | | | | simplifies clean-up and allows for more types without extra hassle. Also made in-line literal types in -T[x]html use CODE instead of SPAN to match how literal blocks use PRE.
* More use default tags, this time I and U. Also fix a stack overflowKristaps Dzonsons2010-12-201-1/+3
| | | | segfault in the last commit.
* Give header and footer table cells default widths (using WIDTH and ALIGNKristaps Dzonsons2010-12-201-3/+3
| | | | | | | | | atttributes) if no style is specified. Give the default-bold elements a B tag instead of a SPAN tag, as this can be overriden in the stylesheet. Prune some unused attributes from html.h.
* Make literal `Bd' use a PRE in -Thtml. Make `Bd' output in general useKristaps Dzonsons2010-12-171-1/+2
| | | | only a single DIV or PRE. Tag all displays with display class.
* Use a single P tag for paragraph breaks (which can be configured forKristaps Dzonsons2010-12-151-1/+2
| | | | | | | paragraph breaking in CSS). Use -man's handling of `sp' and `br', which accomodates for scaling widths (-mdoc wasn't).
* Remove stupid outer DIV tag in favour of regular BODY and HTML that canKristaps Dzonsons2010-12-151-1/+2
| | | | | | | | be handled in CSS. Clarified "lit" tag (will be the subject of future clarification). Removed CSS2 note in mandoc.1, which is no longer the case.
* In-progress move from -T[x]html using DIVs for its lists to using DL,Kristaps Dzonsons2010-12-151-11/+5
| | | | | OL, and UL. Issue raised by Will Backman, solution proposed by schwarze@.
* Add support for `Sm' in -T[x]html -mdoc.Kristaps Dzonsons2010-07-231-1/+2
|
* correct lots of copyright notices;Ingo Schwarze2010-07-131-2/+2
| | | | ok kristaps@
* Give -T[x]html `Bk -words' capability.Kristaps Dzonsons2010-07-061-2/+4
|
* Churn as I finish email address migration kth.se -> bsd.lv.Kristaps Dzonsons2010-06-191-2/+2
|
* Fix in `Mt' mailto from a patch by Tim van der Molen.Kristaps Dzonsons2010-04-051-13/+12
| | | | | Fixed PAIR_xxx_INIT macros -- this are to be unified. Have `Vt', `Fn', `Ft', and `Fo' print whitespace afterward, instead of before.
* Fixed Makefile for `make lint' dep. on config.hKristaps Dzonsons2010-01-291-4/+8
| | | | Added -Txhtml for XHTML output (minimal increase to programme logic). Because groff has it and it bothers me that we don't.
* Abstraction of -Thtml -man font setting (still experimental).Kristaps Dzonsons2009-11-161-1/+11
|
* Removed superfluous HTML_NEWLINE.Kristaps Dzonsons2009-11-141-2/+1
|
* Fixed \c handling in -Thtml.Kristaps Dzonsons2009-11-141-5/+2
|
* (Forgot to update html.h with metafonts. Build will puke on check-out.)Kristaps Dzonsons2009-11-101-1/+5
|
* Fixed `sp', `br', `Pp', etc. so as not to have an empty div (-Thtml, -man, ↵Kristaps Dzonsons2009-10-281-2/+1
| | | | | | | | -mdoc). Made html_idcat be completely correct (messy standard) (-Thtml). Fixed warnings about -ohang and -item lists (-Thtml, -mdoc). Fixed typo in index.sgml.
* Fixed un-reset buffer in `.In', -Thtml, -mdoc.Kristaps Dzonsons2009-10-281-1/+4
| | | | Added html_id[cat,cpy] for transforming id's into well-formed attribute strings (no %s, etc.).
* Added "summary" tag to tables in order to silence HTML-tidy's complaints.Kristaps Dzonsons2009-10-271-1/+5
|
* Portability: replaced queue macros in html.c (Joerg Sonnenberger).Kristaps Dzonsons2009-10-261-6/+10
| | | | | Fixed "-o" residue. Added "-O" to usage() (-o didn't appear there either).
* Clean up consts (noted by Joerg Sonnenberger and Ulrich Sporlein).Kristaps Dzonsons2009-10-131-2/+2
|
* Additions to -Tman -Thtml: all structural components tested & in place.Kristaps Dzonsons2009-10-071-2/+19
| | | | Fitted both -Thtml with handling of arbitrary vertical and horizontal scaling units (see groff(7)). Undocumented until fitted into -Tascii (next release).
* Example style-sheet reflecting modified section/subsection style tags.Kristaps Dzonsons2009-10-041-1/+2
| | | | Added ATTR_ID and so forth to attrs.
* Fixed mandoc.1 examples (new -Thtml options).Kristaps Dzonsons2009-10-031-1/+8
| | | | | Fixed manuals to use `In', not `Fd'. Moved buf* functions into html.c.
* Added the -oincludes=FMT option.Kristaps Dzonsons2009-10-031-1/+3
| | | | | The `In' handler now decorates with a hyperlink. If no -oman= or -oincludes= is stipulated, no link is printed (but the text is still style-decorated).
* Element tag buffer is now part of struct html.Kristaps Dzonsons2009-10-031-1/+4
| | | | | | | buffmt() can be called in sequence. Noted BUFSIZ-sized buffer in CAVEATS (attribute length for link formats). Added -oman=FMT -Thtml option for `Xr' manual links. Removed -obase=URI -Thtml option (obsolete).
* Added Bf, Pf, etc. to -Thtml.Kristaps Dzonsons2009-09-241-1/+2
| | | | Fixed Rs in -Tascii to behave properly when not in "SEE ALSO" section.
* Split html.c into html.h, mdoc_html.c, man_html.c.Kristaps Dzonsons2009-09-211-0/+102
|
* Purged all old files in favour of new design. Selective reintegration.Kristaps Dzonsons2008-12-151-86/+0
|
* Prettier HTML.Kristaps Dzonsons2008-12-101-2/+4
|
* Linted on NetBSD side.Kristaps Dzonsons2008-12-101-3/+3
|
* *** empty log message ***Kristaps Dzonsons2008-12-101-1/+2
|
* *** empty log message ***Kristaps Dzonsons2008-12-101-0/+83