Warning: file_get_contents(/data/phpspider/zhask/data//catemap/0/performance/5.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Xsl fo 如何在xsl fo中堆叠下标和上标(没有MathML)_Xsl Fo - Fatal编程技术网

Xsl fo 如何在xsl fo中堆叠下标和上标(没有MathML)

Xsl fo 如何在xsl fo中堆叠下标和上标(没有MathML),xsl-fo,Xsl Fo,是否有一种方法可以使用xsl fo来堆叠附加到同一字符的下标和上标(但不使用MathML),例如索引为i的x-square: x<sup>2</sup><sub>i</sub> x2i 我试过这个: <fo:block>... x<fo:inline-container writing-mode="tb-rl" font-size="smaller"> <fo:block-container gly

是否有一种方法可以使用xsl fo来堆叠附加到同一字符的下标和上标(但不使用MathML),例如索引为i的x-square:

x<sup>2</sup><sub>i</sub>
x2i
我试过这个:

<fo:block>... x<fo:inline-container writing-mode="tb-rl" font-size="smaller">
        <fo:block-container glyph-orientation-vertical="0deg" >
           <fo:block>2i</fo:block>
        </fo:block-container>
    </fo:inline-container>
</fo:block>
。。。x
2i

但是结果在间距等方面并不令人满意。我想除了MathML之外,对于这类东西没有好的解决方案-对吗?

你要的是解决方案还是好的解决方案?当然有一个解决方案,但它需要了解字体和字符以及所有的可能性

鉴于你的问题,我将其格式化:

        <fo:block>X<fo:inline vertical-align="sub" font-size="8pt">2</fo:inline><fo:inline
                vertical-align="sup" padding-left="-3pt" baseline-shift="8pt" font-size="8pt"
                >i</fo:inline>
        </fo:block>
X2i
我明白了:


谢谢Kevin-这可能会帮我完成这项工作(即使这只是一个解决方案/变通办法,而不是一个“好的解决方案”)。