-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On 28/05/12 07:51, Viktor Haag wrote: > It's just that maybe that design wasn't communicated effectively when > the features were described to end-users. 'ifconfig' and 'only' don't > exclude/include stuff entirely as one might expect:
http://sphinx.pocoo.org/ext/ifconfig.html Include content of the directive only if the Python expression given as an argument is True ... That text is completely unambiguous. An accurate description would appear to be: Always include the content for some processing (eg excludes, toctree, refs) but exclude when the expression evaluates to False for other processing. The behaviour is unpredictable and you won't know exactly what happens for non-trivial cases until you try it. The next bit says: The second argument is the default value, the third should always be True for such values (it selects if Sphinx re-reads the documents if the value changes). And should add: Some processing occurs before the document is re-read and some is done after the document is re-read. Good luck. I'm busy writing code now that reads the document, processes the ifconfig and either omits it completely or dedents it if True. That is really the effect ifconfig should have had in the first place. Roger -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.11 (GNU/Linux) iEYEARECAAYFAk/D1K8ACgkQmOOfHg372QSOawCfSuHc1pPGBeHZu4zOliujvvGn /q8An1osSAW3x//eKlddutJJvBFgJaIV =q7TH -----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.
