将自定义形状添加到 JTextpane 并保存到新的 Word 文档 [英] Adding custom shapes to JTextpane and saved to new Word document

查看:29
本文介绍了将自定义形状添加到 JTextpane 并保存到新的 Word 文档的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如果我将 Word 文档加载到 JTextPane 中,是否可以将自定义形状放入其中,然后将其另存为新的 Word 文档?

If I load a Word document into a JTextPane, is there a way I could drop a custom shape in it, then save it as a new Word document?

我正在寻找的结果就像在 MS Word 中使用 Insert-> Shapes 将一个形状放到文档的任意位置.

The results I'm looking for are just like dropping a shape anywhere onto the document using Insert-> Shapes in MS Word.

推荐答案

docx4all 是一个基于 Swing 的 docx 编辑器.

docx4all is a Swing-based docx editor.

与 DocxEditorKit 一样,它建立在 docx4j 之上.

Like DocxEditorKit, it is built on top of docx4j.

您需要对其进行扩展以支持您所描述的功能.

You'd need to extend it to support the functionality you are describing.

这篇关于将自定义形状添加到 JTextpane 并保存到新的 Word 文档的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆