⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 mathmlstring.java

📁 基于web的数学公式编辑器
💻 JAVA
字号:

package webmath;

import org.w3c.dom.*;

public class MathmlString
{

	Panel1 panel1;

	MathmlString(Panel1 panel1)
	{

		this.panel1 = panel1;
	}

	public String getmathmlcode()
	{

		String math;
		math = panel1.getXML(panel1.root);
		return math;
	}

	public void setNameSpace(String nameSpace)
	{

		panel1.nameSpace = nameSpace;
	}

	void deletenodeattributes()
	{

		deleteattribute(panel1.root);
	}

	void deleteattribute(Node node)
	{

		if (node.getNodeType() == Node.ELEMENT_NODE)
		{
			((Element) node).removeAttribute("x1");
			((Element) node).removeAttribute("x2");
			((Element) node).removeAttribute("y1");
			((Element) node).removeAttribute("y2");
			((Element) node).removeAttribute("baseliney");
		}
		NodeList nodes = node.getChildNodes();
		for (int i = 0; i < nodes.getLength(); i++)
		{
			Node childnode = nodes.item(i);
			deleteattribute(childnode);
		}
	}
}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -