I am using HTMLDocument to display some simple HTML in a JTextPane. I am also using a few simple CSS rules in the HTMLEditorKit style sheet.

Changing the H1 font style, and changing the list bullet style work OK. I can't seem to change the indentation of a <ul> list though. Currently the list is displayed too far to the right (well, in my opinion). I can't seem to change it. Here is the code which sets up the style sheet:

Java Code:
    protected StyleSheet setupStyleSheet(HTMLEditorKit kit) {
        StyleSheet styleSheet = kit.getStyleSheet();
        styleSheet.addRule("h1 {font-family:Arial, Helvetica, sans-serif; font-size: 1.2em; margin-top: 20px; margin-bottom: 0px;}");
        styleSheet.addRule("ul {list-style-type: circle; margin-left: 3em; padding-left: 3em; text-indent: 0em;}");
        return styleSheet;
I have tried every combination of margins and padding, things which work in a browser. The list won't move.

Is this a limitation of the document class, or is there a specific way you need to define the CSS to make it work?