Skip site navigation (1)Skip section navigation (2)

FreeBSD Manual Pages

  
 
  

home | help
SOLDOUT_RENDERERS(3)   FreeBSD Library Functions Manual	  SOLDOUT_RENDERERS(3)

NAME
     soldout_renderers,	lus_attr_escape, lus_body_escape -- various markdown
     to	HTML renderers for soldout

SYNOPSIS
     #include <renderers.h>

     void
     lus_attr_escape(struct buf	*ob, const char	*str, size_t len);

     void
     lus_body_escape(struct buf	*ob, const char	*str, size_t len);

     extern const struct mkd_renderer mkd_html;
     extern const struct mkd_renderer mkd_xhtml;
     extern const struct mkd_renderer discount_html;
     extern const struct mkd_renderer discount_xhtml;
     extern const struct mkd_renderer nat_html;
     extern const struct mkd_renderer nat_xhtml;

DESCRIPTION
     The lus_attr_escape() and lus_body_escape() functions escape all problem-
     atic characters in	(X)HTML: `<', `>', `&',	`"'; and `<', `>', `&' respec-
     tively.  They accept a string str of the length len and output into ob
     buffer.

     All provided renderers come with two flavors, _html producing HTML	code
     (self-closing tags	are rendered like this:	<hr>), and _xhtml producing
     XHTML code	(self-closing tags like	<hr />).

     mkd_html and mkd_xhtml implement standard markdown	to (X)HTML translation
     without any extension.

     discount_html and discount_xhtml implement	on top of the standard mark-
     down some of the extensions found in Discount and PHP-Markdown-like ta-
     bles.  Here is a list of all extensions included in these renderers:

     +o	image size specification, by appending "=(width)x(height)" to the link

     +o	pseudo-protocols in links:

	+o  abbr:description for	<abbr title="description">...</abbr>

	+o  class:name for <span	class="name">...</span>

	+o  id:name for <span id="name">...</span>

	+o  raw:text for	verbatim unprocessed text inclusion

     +o	class blocks: blockquotes beginning with %class% will be rendered as a
	div of the given class(es)

     nat_html and nat_xhtml implement on top of	Discount extensions and
     Natasha's own extensions.	Here is	a list of these	extensions:

     +o	id attribute for headers, using	the syntax id#Header text

     +o	class attribute	for paragraphs,	by putting class name(s) between
	parenthesis at the very	beginning of the paragraph

     +o	<ins> and <del>	spans, using respectively ++ and -- as delimiters
	(with emphasis-like restrictions, i.e. an opening delimiter cannot be
	followed by a whitespace, and a	closing	delimiter cannot be preceded
	by a whitespace)

     +o	plain <span> without attribute,	using emphasis-like delimiter |

RETURN VALUES
     The lus_attr_escape() and lus_body_escape() functions do not return a
     value.

SEE ALSO
     soldout(3), soldout_buffer(3), soldout_markdown(3)

AUTHORS
     The soldout library was written by	Natasha	"Kerensikova" Porte
     <natacha@instinctive.eu>.	Manual page was	originally written by Massimo
     Manghi <mxmanghi@apache.org>, and rewritten to mdoc format	by Svyatoslav
     Mishyn <juef@openmailbox.org>.

FreeBSD	13.0			April 13, 2016			  FreeBSD 13.0

NAME | SYNOPSIS | DESCRIPTION | RETURN VALUES | SEE ALSO | AUTHORS

Want to link to this manual page? Use this URL:
<https://www.freebsd.org/cgi/man.cgi?query=soldout_renderers&sektion=3&manpath=FreeBSD+13.0-RELEASE+and+Ports>

home | help