Hi bawolff,
I'm trying the following. Looking for example at http://math-test.instance-proxy.wmflabs.org/wiki/Summation
The equations denoted with \n:<math e.g. :<math>\sum_a^b</math> should be rendered in displaystyle, whereas inline equations e.g. Let <math>\sum_i 2^{-i}</math> should be rendered normal.
Best Moritz
On Sun, Apr 28, 2013 at 8:32 PM, Brian Wolff bawolff@gmail.com wrote:
On 2013-04-28 6:01 AM, "Moritz Schubotz" physik@physikerwelt.de wrote:
Hi,
how can I figure out in a tag extension callback e.g.
function wfSampleRender( $input, array $args, Parser $parser, PPFrame
$frame )
if the parser is inside a block mode or not? With block mode I mean something like :<mytag></mytag> or #<mytag></mytag> or
<mytag></mytag>
but not blindtext <mytag></mytag> more text
If there is an extension that uses ways to dermine the "block" a link would help a lot.
Best regards physikerwelt
Wikitech-l mailing list Wikitech-l@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/wikitech-l
What are you trying to do that requires that knowledge? Off the top of my head (so could be wrong) block level-ness is determined entirely after parser tags are replaced.
If you are woried about doBlockLevels messing up the output of your extension, you can return an array with certain structure to tell the parser to protect your output from doBlockLevels messing with it. (Which is for example how <nowiki> is implemented internally I believe)
-bawolff _______________________________________________ Wikitech-l mailing list Wikitech-l@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/wikitech-l