Matthias Bläsing created NETBEANS-619:

             Summary: Check/Consolidate manipulation of HTMLEditorKit stylesheet
                 Key: NETBEANS-619
             Project: NetBeans
          Issue Type: Improvement
    Affects Versions: 9.0
            Reporter: Matthias Bläsing

There are various places in the netbeans code base, that make use of the 
HTMLEditorKit to visualize HTML content. In many cases the stylesheet backing 
the HTMLEditorKit is manipulated. This is the case at least in:
 * autoupdate.ui/src/org/netbeans/modules/autoupdate/ui/
 * editor.completion/src/org/netbeans/modules/editor/completion/
 * java.navigation/src/org/netbeans/modules/java/navigation/
 * openide.dialogs/src/org/openide/
 * openide.loaders/src/org/openide/loaders/
 * projectui/src/org/netbeans/modules/project/ui/


This is problematic (as also mentioned in several places in the files above), 
as the stylesheet is shared by all HTMLEditorKits (think of it as a client 
style sheet). As a reference this is the implemenation of 

    public void setStyleSheet(StyleSheet s) {
        if (s == null) {
        } else {
            AppContext.getAppContext().put(DEFAULT_STYLES_KEY, s);

Other users manipulate the document stylesheet and not the global stylesheet:
 * subversion/src/org/netbeans/modules/subversion/util/
 * subversion/src/org/netbeans/modules/subversion/options/
 * subversion/src/org/netbeans/modules/subversion/client/
 * openide.awt/src/org/openide/awt/


It should be checked if it would be feasible to centralize the modification of 
the global stylesheet for example in the {{org.netbeans.swing.plaf}} (Look & 
Feel Customization Library) module.

This message was sent by Atlassian JIRA

To unsubscribe, e-mail:
For additional commands, e-mail:

For further information about the NetBeans mailing lists, visit:

Reply via email to