diff --git a/laws-modules/pom.xml b/laws-modules/pom.xml index 27d894dc..03233359 100644 --- a/laws-modules/pom.xml +++ b/laws-modules/pom.xml @@ -155,5 +155,10 @@ jdk17 ${project.basedir}/lib/aspose-words-21.1-jdk17-cracked.jar + + jaxen + jaxen + 1.2.0 + \ No newline at end of file diff --git a/laws-modules/src/main/java/com/jero/modules/activiti/controller/ActivitiController.java b/laws-modules/src/main/java/com/jero/modules/activiti/controller/ActivitiController.java index 7dcb64dc..d1ec5026 100644 --- a/laws-modules/src/main/java/com/jero/modules/activiti/controller/ActivitiController.java +++ b/laws-modules/src/main/java/com/jero/modules/activiti/controller/ActivitiController.java @@ -30,6 +30,7 @@ import org.apache.commons.io.IOUtils; import org.apache.commons.lang3.StringUtils; import org.apache.shiro.SecurityUtils; import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.transaction.annotation.Transactional; import org.springframework.util.CollectionUtils; import org.springframework.web.bind.annotation.*; @@ -45,6 +46,7 @@ import java.util.*; * @date 2023-08-02 15:05 */ @Slf4j +@Transactional(rollbackFor = Exception.class) @RestController @Api(tags = "流程控制") @RequestMapping("/modeler") diff --git a/laws-modules/src/main/java/com/jero/modules/split/service/impl/FileSpiltService.java b/laws-modules/src/main/java/com/jero/modules/split/service/impl/FileSpiltService.java index 980c536c..de204861 100644 --- a/laws-modules/src/main/java/com/jero/modules/split/service/impl/FileSpiltService.java +++ b/laws-modules/src/main/java/com/jero/modules/split/service/impl/FileSpiltService.java @@ -18,6 +18,7 @@ import com.jero.modules.split.vo.TitleNumberVO; import lombok.extern.slf4j.Slf4j; import org.apache.commons.collections4.CollectionUtils; import org.apache.commons.lang3.StringUtils; +import org.apache.poi.hwpf.HWPFDocument; import org.apache.poi.openxml4j.opc.PackagePart; import org.apache.poi.openxml4j.util.ZipSecureFile; import org.apache.poi.xwpf.usermodel.*; @@ -128,22 +129,22 @@ public class FileSpiltService { // nowStart.add(String.valueOf(sarFileSplitInfoEO.getStartNumber())); // } // 获取文件地址 -// String fileId = sarFileSplitInfoEO.getFileId(); -// LambdaQueryWrapper queryWrapper = new LambdaQueryWrapper(); -// queryWrapper.eq(OSSFile::getId, fileId); -// queryWrapper.orderByDesc(OSSFile::getCreateTime); -// List ossFileList = iossFileService.list(queryWrapper); -// if (CollectionUtils.isEmpty(ossFileList)) { -// throw new JeroBootException("当前文件未找到,请重新选择!"); -// } -// OSSFile ossFile = ossFileList.get(0); -// String readFilePath = ossFile.getUrl(); -// if (StringUtils.isEmpty(readFilePath) || !MinioUtil.doesObjectExist(readFilePath)) { -// throw new JeroBootException("当前文件未找到,请重新选择!"); -// } -// try (InputStream is = MinioUtil.download(readFilePath);InputStream is1 = MinioUtil.download(readFilePath)) { - String readFilePath = "E:\\Data\\Downloads\\wordtest\\GB7258标准修订test - 表格测试 - 副本.docx"; - try (InputStream is = new FileInputStream(readFilePath); InputStream is1 = new FileInputStream(readFilePath)) {//需要将文件路更改为word文档所在路径。 + String fileId = sarFileSplitInfoEO.getFileId(); + LambdaQueryWrapper queryWrapper = new LambdaQueryWrapper(); + queryWrapper.eq(OSSFile::getId, fileId); + queryWrapper.orderByDesc(OSSFile::getCreateTime); + List ossFileList = iossFileService.list(queryWrapper); + if (CollectionUtils.isEmpty(ossFileList)) { + throw new JeroBootException("当前文件未找到,请重新选择!"); + } + OSSFile ossFile = ossFileList.get(0); + String readFilePath = ossFile.getUrl(); + if (StringUtils.isEmpty(readFilePath) || !MinioUtil.doesObjectExist(readFilePath)) { + throw new JeroBootException("当前文件未找到,请重新选择!"); + } + try (InputStream is = MinioUtil.download(readFilePath);InputStream is1 = MinioUtil.download(readFilePath)) { + //String readFilePath = "E:\\Data\\Downloads\\wordtest\\GB7258标准修订test - 表格测试 - 副本.docx"; + //try (InputStream is = new FileInputStream(readFilePath); InputStream is1 = new FileInputStream(readFilePath)) {//需要将文件路更改为word文档所在路径。 ZipSecureFile.setMinInflateRatio(-1.0d); XWPFDocument doc = new XWPFDocument(is); @@ -173,29 +174,6 @@ public class FileSpiltService { XWPFParagraph p = (XWPFParagraph) element; StringBuilder stringBuilder = new StringBuilder(); - ParagraphChildOrderManager runOrMaths = new ParagraphChildOrderManager(p); - List childList = runOrMaths.getChildList(); - - for (Object child : childList) { - //if (child instanceof XWPFRun) { - // //处理段落中的文本以及图片 - // handleParagraphRun(content, (XWPFRun) child, imageParser); - //} else - if (child instanceof CTOMath) { - // 处理word中存在的公式成mathML格式 - handleParagraphOMath(stringBuilder, (CTOMath) child); - if (messageList.size() > 0) { - addItermsConditionsMath(messageList.get(messageList.size() - 1), itemValList, stringBuilder.toString()); - } - } else if (child instanceof CTOMathPara) { - //处理word中存在的公式 - handleParagraphOMath(stringBuilder, (CTOMathPara) child); - if (messageList.size() > 0) { - addItermsConditionsMath(messageList.get(messageList.size() - 1), itemValList, stringBuilder.toString()); - } - } - } - for (XWPFRun xwrun : p.getRuns()) { VerticalAlign subscript = xwrun.getSubscript(); String smalltext = xwrun.getText(0); diff --git a/laws-modules/src/main/java/com/jero/modules/split/service/impl/SarFileSplitInfoServiceImpl.java b/laws-modules/src/main/java/com/jero/modules/split/service/impl/SarFileSplitInfoServiceImpl.java index 38ce132c..01b4f9e2 100644 --- a/laws-modules/src/main/java/com/jero/modules/split/service/impl/SarFileSplitInfoServiceImpl.java +++ b/laws-modules/src/main/java/com/jero/modules/split/service/impl/SarFileSplitInfoServiceImpl.java @@ -97,7 +97,7 @@ public class SarFileSplitInfoServiceImpl extends ServiceImpl")) { + + //段落文本内容 + sb.append(xwpfParagraph.getParagraphText()); + //段落公式解析 + //得到根节点的值 + SAXReader saxReader = new SAXReader(); + //将String类型的字符串转换成XML文本对象 + Document doc = null; + try { + doc = saxReader.read(new ByteArrayInputStream(xmlText.getBytes())); + } catch (DocumentException e) { + e.printStackTrace(); + } + Element root = doc.getRootElement(); + // 一个段落多个表达式解析 + //用xpath得到OMML节点 + List nodes = root.selectNodes("//m:oMath"); + if (nodes != null && !nodes.isEmpty()) { + for (Node node : nodes) { + /** + * OMML -> MathML -> LaTex + * Office在安装目录中提供了将OMML转为MathML的xsl工具:MML2OMML.XSL + * MathML转LaTex使用网上找到另一个xsl工具mmltex.xsl。 + */ + String xml = node.asXML(); + //xml转 mathml + String mathml = convertOMML2MML(xml); + //mathml转latx + String latex = convertMML2Latex(mathml); + sb.append(latex); + log.info("latex表达式:{}",latex); + } + } + log.info("公式个数:{},解析内容:{}",nodes.size(),sb.toString()); + return sb.toString(); + } + + /** + *

Description: 将mathml转为latx

+ * @param mml mathml字符串 + * @return + */ + public static String convertMML2Latex(String mml){ + mml = mml.substring(mml.indexOf("?>")+2, mml.length()); //去掉xml的头节点 + URIResolver r = new URIResolver(){ //设置xls依赖文件的路径 + @Override + public Source resolve(String href, String base) throws TransformerException { + File f = new File("/conventer/mml2tex/" + href); + InputStream inputStream = WordUtil.class.getResourceAsStream("/conventer/mml2tex/" + href); + return new StreamSource(inputStream); + } + }; + String latex = xslConvert(mml, "/conventer/mml2tex/mmltex.xsl", r); + if(latex != null && latex.length() > 1){ + latex = latex.substring(1, latex.length() - 1); + } + return latex; + } + /** + *

Description: office xml转为mathml

+ * @param xml 公式xml + * @return + */ + public static String convertOMML2MML(String xml){ + // 进行转换的过程中需要借助这个文件,一般来说本机安装office就会有这个文件,找到就可以 + String result = xslConvert(xml, "/conventer/OMML2MML.XSL", null); + return result; + } + + /** + * Description: xsl转换器

+ * @param s 公式xml字符串 + * @param xslpath 转换器路径 + * @param uriResolver xls依赖文件 + * @return + */ + public static String xslConvert(String s, String xslpath, URIResolver uriResolver){ + TransformerFactory tFac = TransformerFactory.newInstance(); + if(uriResolver != null) { + tFac.setURIResolver(uriResolver); + } + StreamSource xslSource = new StreamSource(WordUtil.class.getResourceAsStream(xslpath)); + StringWriter writer = new StringWriter(); + try { + Transformer t = tFac.newTransformer(xslSource); + Source source = new StreamSource(new StringReader(s)); + Result result = new StreamResult(writer); + t.transform(source, result); + } catch (TransformerException e) { + log.error(e.getMessage(), e); + } + return writer.getBuffer().toString(); + } } diff --git a/laws-single-startup/src/main/resources/conventer/OMML2MML.XSL b/laws-single-startup/src/main/resources/conventer/OMML2MML.XSL new file mode 100644 index 00000000..b46ae33b --- /dev/null +++ b/laws-single-startup/src/main/resources/conventer/OMML2MML.XSL @@ -0,0 +1,2068 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + ˘ + + ¸ + + ` + + - + + + + . + + ˙ + + ˝ + + ´ + + ~ + + ˜ + + ¨ + + ˇ + + ^ + + ¯ + + _ + + + + + + + + + + + + + + + true + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + left + + + right + + + + + + + + + + + + + + + + 0 + + + + + + + + + + 0 + + + + + + + + + + 0 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0in + + + 0in + + + 0in + + + + + + + + + 0 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + true + + + false + + + + + + + + + + + + + + + + + + + off + + + + + + + + + + + off + + + + + + + + + + + + + + off + + + + + + + + + 1 + 0 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + / + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + true + + + 0pt + + + + right + + + left + + + + + right + + + left + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1 + 0 + + + + + + + + + + ¯ + + + + + + + + + + _ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0 + + + + + + + + + + + + + + + + + + + + + + 0 + + + + + + + + + + + + + + + + + normal + + + + + + + + monospace + sans-serif-italic + bold-sans-serif + sans-serif-bold-italic + sans-serif + bold-fraktur + fraktur + double-struck + bold-script + script + bold + italic + normal + bold-italic + + + + + + bold + normal + + + + + normal + italic + + + + + + + + + + + + + + + + + + + + + + + + italic + + + bold + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0 + 1 + + + + + + + + + + + + + + + + + + + + + + 1 + 0 + + + + + 1 + 0 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1 + 0 + + + + + 1 + 0 + + + + + + + + + + + + + + + + + + + + + + + 1 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + box + + + + + + + + + + + + + + + + + left right top bottom + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1 + 0 + -1 + + + + + + + + + + + + + 0 + 1 + + + + + + + + + + + + + 1 + 0 + + + diff --git a/laws-single-startup/src/main/resources/conventer/mml2tex/README b/laws-single-startup/src/main/resources/conventer/mml2tex/README new file mode 100644 index 00000000..b5fdf158 --- /dev/null +++ b/laws-single-startup/src/main/resources/conventer/mml2tex/README @@ -0,0 +1,97 @@ +README for the XSLT MathML Library + +XSLT MathML Library is a set of XSLT stylesheets to transform +MathML 2.0 to LaTeX. + +For more information, see +http://www.raleigh.ru/MathML/mmltex/index.php?lang=en + +Manifest +-------- + +README this file +mmltex.xsl +tokens.xsl +glayout.xsl +scripts.xsl +tables.xsl +entities.xsl +cmarkup.xsl + +Use +--- + +There are two ways of using the library: + + * Use a local copy of the library. + + 1. Download the distribution (see below). + + 2. Unpack the distribution, using unzip. + + 3. In your stylesheet import or include either the main + stylesheet, mmltex.xsl, or the stylesheet module you + wish to use, such as tokens.xsl. This example assumes + that the distribution has been extracted into the same + directory as your own stylesheet: + + + + * Import or include either the main stylesheet, or the + stylesheet module you wish to use, directly from the library + website; http://www.raleigh.ru/MathML/mmltex/. For example: + + + +Obtaining The Library +--------------------- + +The XSLT MathML Library is available for download as: + + * Zip file: http://www.raleigh.ru/MathML/mmltex/mmltex.zip + +Copyright +--------- + +Copyright (C) 2001, 2002 Vasil Yaroshevich + +Permission is hereby granted, free of charge, to any person +obtaining a copy of this software and associated documentation +files (the ``Software''), to deal in the Software without +restriction, including without limitation the rights to use, +copy, modify, merge, publish, distribute, sublicense, and/or +sell copies of the Software, and to permit persons to whom the +Software is furnished to do so, subject to the following +conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +Except as contained in this notice, the names of individuals +credited with contribution to this software shall not be used in +advertising or otherwise to promote the sale, use or other +dealings in this Software without prior written authorization +from the individuals in question. + +Any stylesheet derived from this Software that is publically +distributed will be identified with a different name and the +version strings in any derived Software will be changed so that +no possibility of confusion between the derived package and this +Software will exist. + +Warranty +-------- + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES +OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +NONINFRINGEMENT. IN NO EVENT SHALL NORMAN WALSH OR ANY OTHER +CONTRIBUTOR BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, +WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING +FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR +OTHER DEALINGS IN THE SOFTWARE. + +Contacting the Author +--------------------- + +These stylesheets are maintained by Vasil Yaroshevich, . diff --git a/laws-single-startup/src/main/resources/conventer/mml2tex/cmarkup.xsl b/laws-single-startup/src/main/resources/conventer/mml2tex/cmarkup.xsl new file mode 100644 index 00000000..9e72dda7 --- /dev/null +++ b/laws-single-startup/src/main/resources/conventer/mml2tex/cmarkup.xsl @@ -0,0 +1,1093 @@ + + + + + + + + + + + + + + + + i + + + + + / + + + + + + _{} + + + + + e^{i + + } + + + + + E + + + + + + + + \mathrm{} + + + + + + + + + + + + + ( + + + , + + ) + + + + + () + + + + + + + \left( + + \left[ + + + , + + + + \right) + + \right] + + + + + \left\{\right\} + + + + + ^{(-1)} + + + + + + + + \mathrm{lambda}\: + + .\: + + + + + + + + + + \circ + + + + +\mathrm{id} + + + + \mathop{\mathrm{ + + }} + + + + + + + + \begin{cases} + + + \end{cases} + + + + + & \text{if $ + + $} + \\ + + + + + & \text{otherwise} + + + + + \left\lfloor\frac{ + + }{ + + }\right\rfloor + + + + + + + + ! + + + + + + + \left( + \frac{ + + + }{ + + + } + \right) + + + + + \ + + \{ + + + + , + + + + + + , + + + + \} + + + + + - + + + + + + + + + - + + + + + + + + + + ( + + + + + - + + + + + + + + + + + + + + + + + + + + + + + + + + + + ) + + + + + + + + + ^{ + + + + } + + + + + + + \mod + + + + + + + + + + ( + + + + \times + + + + + + + + + + ) + + + + + \sqrt + + [ + + ] + + { + + } + + + +\gcd + + + + + + + + \land + + + + + + + + + + \lor + + + + + + + + + + \mathop{\mathrm{xor}} + + + + + + \neg + + + + + + + + + + \implies + + + + + + + + \ + + + + + , + + + \colon + + + + + + + \left| + + \right| + + + + + \overline{} + + + +\Re + + +\Im + + + + \lfloor + + \rfloor + + + + + \lceil + + \rceil + + + + + + + + + = + + + + + + + + + + \neq + + + + + + + + + + > + + + + + + + + + + < + + + + + + + + + + \ge + + + + + + + + + + \le + + + + + + + + + + \equiv + + + + + + + + + + \approx + + + + + + + + | + + + + + + + + \int + + _{ + + } + + + ^{ + + } + + + + \,d + + + + + + + ^\prime + + + + \frac{ + + + d^{ + + } + + }{d + + ^{ + + } + + + d + + }{d + + } + + + } + + + + + D_{ + + + , + + } + + + + + \frac{\partial^{ + + + + + + + + + + + + + + + + + + + + + } + + }{ + + \partial + + + ^{ + + } + + + } + + + + + + + + + , + + + +\mathop{\mathrm{div}} + + +\nabla^2 + + + + \{\} + + + + + \left[\right] + + + + + + + \colon + + + + + + , + + + + + + + + + + + + \cup + + + + + + + + + + \cap + + + + + + + + \in + + + + + + + + + + \notin + + + + + + + + + + + + \subseteq + + + + + + + + + + \subset + + + + + + + + + + \nsubseteq + + + + + + + + + + \not\subset + + + + + + + + + + \setminus + + + + + + | + + | + + + + + + + + + \times + + + + + + + + ^{ + + } + + + + + \sum + + + + + \prod + + + + + _{ + + + = + + + } + + + ^{ + + } + + + + + + + + \lim_{ + + } + + + + + + \to + + + + + + + + + + + + \searrow + \nearrow + \rightarrow + \to + + + + + + + + \ + + + + + + + + + \ + + + + + + \mathrm{ + + \,} + + + + + + + \mathrm{ + + } + + + + + e^{} + + + + + \lg + + + + + + + \log_{ + + } + + + + + + + + \langle + + + , + + \rangle + + + +\sigma + + + + \sigma( + + )^2 + + + + + \langle + + ^{ + + }\rangle + + _{ + + } + + + + + + + \left(\begin{array}{c} + + + \\ + + \end{array}\right) + + + + + \begin{pmatrix} + + \end{pmatrix} + + + + + + + & + + \\ + + + + + \det + + + + + + + \begin{vmatrix} + + \end{vmatrix} + + + + + + + + ^T + + + + + + + + _{ + + + , + + } + + + + + + + + + \dot + + + + + + + + + + + +\mathbb{Z} + + +\mathbb{R} + + +\mathbb{Q} + + +\mathbb{N} + + +\mathbb{C} + + +\mathbb{P} + + +e + + +i + + +NaN + + +\mbox{true} + + +\mbox{false} + + +\emptyset + + +\pi + + +\gamma + + +\infty + + + + + + + ( + + + + + + + + + ) + + + + + + + ( + + + + + + + + ) + + + \ No newline at end of file diff --git a/laws-single-startup/src/main/resources/conventer/mml2tex/entities.xsl b/laws-single-startup/src/main/resources/conventer/mml2tex/entities.xsl new file mode 100644 index 00000000..d62e9e79 --- /dev/null +++ b/laws-single-startup/src/main/resources/conventer/mml2tex/entities.xsl @@ -0,0 +1,316 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/laws-single-startup/src/main/resources/conventer/mml2tex/glayout.xsl b/laws-single-startup/src/main/resources/conventer/mml2tex/glayout.xsl new file mode 100644 index 00000000..5aaa19d8 --- /dev/null +++ b/laws-single-startup/src/main/resources/conventer/mml2tex/glayout.xsl @@ -0,0 +1,220 @@ + + + + + + + + + + + + + + \genfrac{}{}{ + + + + ex + + + .05ex + + + + .2ex + + + + + + }{}{ + + + \frac{ + + + + \hfill + + + + \hfill + + }{ + + \hfill + + + + \hfill + + } + + + + + + \sqrt[ + + ]{ + + } + + + + exception 25: + \text{exception 25:} + + + + + + \sqrt{ + + } + + + + + + + \left + + + \ + + + + \left( + + + + + + + + + + + , + + + + + + + + + + + + + + + + + + + + + + + + \right + + + \ + + + + \right) + + + + + \phantom{ + + } + + + + + + \overline{ + + \hspace{.2em}|} + + + \sqrt{ + + } + + + \overline{) + + } + + + + + + + + + + + \colorbox[rgb]{ + + + + }{$ + + + \textcolor[rgb]{ + + + + }{ + + + + } + + + $} + + + + + + + + + \ No newline at end of file diff --git a/laws-single-startup/src/main/resources/conventer/mml2tex/mmltex.xsl b/laws-single-startup/src/main/resources/conventer/mml2tex/mmltex.xsl new file mode 100644 index 00000000..45c9e6f1 --- /dev/null +++ b/laws-single-startup/src/main/resources/conventer/mml2tex/mmltex.xsl @@ -0,0 +1,45 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + $ + + $ + + + \ No newline at end of file diff --git a/laws-single-startup/src/main/resources/conventer/mml2tex/scripts.xsl b/laws-single-startup/src/main/resources/conventer/mml2tex/scripts.xsl new file mode 100644 index 00000000..a81909e0 --- /dev/null +++ b/laws-single-startup/src/main/resources/conventer/mml2tex/scripts.xsl @@ -0,0 +1,292 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + \overline{ + + + + + } + + + \overbrace{ + + + + + } + + + \underline{ + + + + + + } + + + \underbrace{ + + + + + + } + + + + + _{ + + }^{ + + } + + + \underset{ + + }{\overset{ + + }{ + + }} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \overline{ + + } + + + \overbrace{ + + } + + + + + ^{ + + } + + + \stackrel{ + + }{ + + } + + + + + + + + + + + \underline{ + + } + + + \underbrace{ + + } + + + + + _{ + + } + + + \underset{ + + }{ + + } + + + + + + { + + }_{ + + }^{ + + } + + + + { + + }^{ + + } + + + + { + + }_{ + + } + + + + + + {}_{ + + } + + + {}^{ + + } + + + + + + {} + + + _{ + + } + + + ^{ + + } + + + + + + + + + + + + + + {} + + + _{ + + } + + + ^{ + + } + + + + + + + \ No newline at end of file diff --git a/laws-single-startup/src/main/resources/conventer/mml2tex/tables.xsl b/laws-single-startup/src/main/resources/conventer/mml2tex/tables.xsl new file mode 100644 index 00000000..e60592aa --- /dev/null +++ b/laws-single-startup/src/main/resources/conventer/mml2tex/tables.xsl @@ -0,0 +1,130 @@ + + + + + + + + + \multicolumn{ + + }{c}{ + + } + + & + + + + + + + \hfill + + + + \hfill + + + + & + + + + + + + \\ + + + + + \begin{array}{ + + | + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + | + + } + + \hline + + + + \\ \hline + + \end{array} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/laws-single-startup/src/main/resources/conventer/mml2tex/tokens.xsl b/laws-single-startup/src/main/resources/conventer/mml2tex/tokens.xsl new file mode 100644 index 00000000..dcf1af12 --- /dev/null +++ b/laws-single-startup/src/main/resources/conventer/mml2tex/tokens.xsl @@ -0,0 +1,296 @@ + + + + + + + + + + + + + + + \mathrm{ + + } + + + + + + + + + + + + + + + + + + + + + + \text{ + + } + + + + \phantom{\rule + + [- + + ] + + { + + 0ex + + + }{ + + 0ex + + + }} + + + + + + " + + + " + + + + + + \colorbox[rgb]{ + + + + }{$ + + + \textcolor[rgb]{ + + + + }{ + + + + + \mathrm{ + + + \mathbf{ + + + \mathit{ + + + \mathbit{ + + + \mathbb{ + + + { + + + \mathcal{ + + + \mathsc{ + + + \mathfrak{ + + + \mathsf{ + + + \mathbsf{ + + + \mathsfit{ + + + \mathbsfit{ + + + \mathtt{ + + + { + + + + + + } + + + } + + + $} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + , + + + + + + , + + + + + + + + + + + + + + + + + + + , + + + + + + + + + + + , + + + + + + + + + + + + + + 0,1,1 + 0,0,0 + 0,0,1 + 1,0,1 + .5,.5,.5 + 0,.5,0 + 0,1,0 + .5,0,0 + 0,0,.5 + .5,.5,0 + .5,0,.5 + 1,0,0 + .75,.75,.75 + 0,.5,.5 + 1,1,1 + 1,1,0 + + Exception at color template + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Exception at Hex2Decimal template + + + + + + + + + + + \ No newline at end of file