I would appreciate some help modifying a function!

The aims:
Make an array list of specific characters.
Write a method to remove the characters specified in the arraylist from text JEditorpane.

So Far:
Made an arraylist of characters,
Wrote a function to remove the characters.
made a gui that includes jeditorpane

The issue:
The function works, and remove characters that I println to console via a string.

I am struggling to make the function remove the characters from the text document that i open into JEditorpane.

The code in short:

```
     private static ArrayList<Character> special = new  ArrayList<Character>(Arrays.asList('a','b','h'));

    public class removing implements ActionListener {
    public void actionPerformed(ActionEvent e) {

```

documentpane is the name of my jeditorpane

if I change, document.chatAt, to test.chatAt, (which is printing to console, this works.

```
        Document document = documentpane.getDocument();

        String test = "hello world?";
        String outputText = "";

        for (int i = 0; i < document.getLength(); i++) {
            Character c = new Character(document.charAt(i));
            if (!special.contains(c))
                outputText += c;
            else
                outputText += " ";
        }
        System.out.println(outputText);

```

Thanks for any help in advance.