简体   繁体   中英

paste AuthorDocumentFragment (Oxygen) into TextArea (Java swing)

I want to paste AuthorDocumentFragment (Oxygen) into TextArea (Java swing) of my modal dialog. But the element AuthorDocumentFragment is not supported for textarea. What do I do with this?

My code:

public void doOperation(final AuthorAccess authorAccess, final ArgumentsMap args)
        throws IllegalArgumentException, AuthorOperationException {
   AuthorNode[] nodeList2 = authorAccess.getDocumentController().findNodesByXPath("//*[@id]/child::node()", true, true, true);

    ArrayList<AuthorDocumentFragment> arrayList = new ArrayList<AuthorDocumentFragment>();

    for (AuthorNode i : nodeList2) {
        AuthorDocumentFragment newFragText = null;
        try {
            newFragText = authorAccess.getDocumentController().createDocumentFragment(i, true);
        } catch (BadLocationException e) {
            e.printStackTrace();
        }
        arrayList.add(newFragText);
    }
}

void jList1MouseClicked(java.awt.event.MouseEvent evt) {
    textAreaRefs.setText(???);
}

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM