static { // compute primitives/primitiveMap/primitiveToWrapper for (Class<?> c : primitiveWrappers) { try { Field f = c.getField("TYPE"); Class<?> p = (Class<?>) f.get(null); primitives.add(p); primitiveMap.put(p.getName(), p); primitiveToWrapper.put(p.getName(), c); } catch (Exception e) { throw new AssertionError(e); } } // compute editableTypes for (Class<?> c : primitives) { editableTypes.add(c.getName()); } for (Class<?> c : primitiveWrappers) { editableTypes.add(c.getName()); } for (Class<?> c : extraEditableClasses) { editableTypes.add(c.getName()); } // compute numericalTypes for (Class<?> c : primitives) { String name = c.getName(); if (!name.equals(Boolean.TYPE.getName())) { numericalTypes.add(name); } } for (Class<?> c : primitiveWrappers) { String name = c.getName(); if (!name.equals(Boolean.class.getName())) { numericalTypes.add(name); } } }
// Here's where the font is set on the editor pane, and we also keep // track of the panes in use for future font updates. public void install(JEditorPane pane) { if (Settings.debug) System.err.println("Installing kit into pane"); delegate.install(pane); panes.add(pane); pane.setFont(Settings.font); }