-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Am 06.04.2010 20:05, schrieb Roberto Alsina:

> I can't claim to know LateX but the latest docutils has a different 
> visit_inline than Sphinx:
> 
>     def visit_inline(self, node): # <span>, i.e. custom roles
>         # insert fallback definition
>         self.fallbacks['inline'] = PreambleCmds.inline
>         self.out += [r'\DUrole{%s}{' % cls for cls in node['classes']]
>         self.context.append('}' * (len(node['classes'])))
> 
> As far as I can follow the explanation from 
> http://docutils.sourceforge.net/docs/user/latex.html that means it calls a 
> macro called \DUroleCLASSARGUMENT{} which can then do things like setting a 
> bold font and whatnot.
> 
> If LaTex is capable of setting bold, italic, monospaced font and foreground 
> colour, then a set of such macros could be autogenerated from the pygment 
> stylesheets (I create rst2pdf's stylesheets that way) thus allowing the LaTeX 
> writer to process the output of the proposed codeblock directive.
> 
> Or am I way wrong (it tends to happen with me and LaTeX ;-)

You are right, I would say.  But the fact remains that this would be quite a
few hours of work to get right, and to test that everything works as it did
before, including the somewhat hairy issue of fallback for token types whose
parents are styled.  Therefore, and because I have like seventy-six other
items on my todo and wish list for Sphinx, it is unlikely I will do that
rewrite any time soon :)

No offense intended,
Georg
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.14 (GNU/Linux)

iEYEARECAAYFAku7mHkACgkQN9GcIYhpnLAkcQCdEI/xRQh3L2hZOo0ItVFO3O0a
TjgAn2/LlaYhSlOGnVUEblMrpvTKQ8Rb
=2Mjy
-----END PGP SIGNATURE-----

-- 
You received this message because you are subscribed to the Google Groups 
"sphinx-dev" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/sphinx-dev?hl=en.

Reply via email to