rem
stringlengths
0
477k
add
stringlengths
0
313k
context
stringlengths
6
599k
return null;
NumberFormatter formatter = (NumberFormatter) ftf.getFormatter(); return (DecimalFormat) formatter.getFormat();
public DecimalFormat getFormat() { return null; }
else if (model instanceof SpinnerListModel) return new ListEditor(this);
protected JComponent createEditor(SpinnerModel model) { if (model instanceof SpinnerDateModel) return new DateEditor(this); else if (model instanceof SpinnerNumberModel) return new NumberEditor(this); else return new DefaultEditor(this); }
if (this.editor instanceof DefaultEditor) ((DefaultEditor) editor).dismiss(this); else if (this.editor instanceof ChangeListener) removeChangeListener((ChangeListener) this.editor); if (editor instanceof ChangeListener) addChangeListener((ChangeListener) editor);
JComponent oldEditor = this.editor; if (oldEditor instanceof DefaultEditor) ((DefaultEditor) oldEditor).dismiss(this); else if (oldEditor instanceof ChangeListener) removeChangeListener((ChangeListener) oldEditor);
public void setEditor(JComponent editor) { if (editor == null) throw new IllegalArgumentException("editor may not be null"); if (this.editor instanceof DefaultEditor) ((DefaultEditor) editor).dismiss(this); else if (this.editor instanceof ChangeListener) removeChangeListener((ChangeListener) this.editor); if (editor instanceof ChangeListener) addChangeListener((ChangeListener) editor); this.editor = editor; }
firePropertyChange("editor", oldEditor, editor);
public void setEditor(JComponent editor) { if (editor == null) throw new IllegalArgumentException("editor may not be null"); if (this.editor instanceof DefaultEditor) ((DefaultEditor) editor).dismiss(this); else if (this.editor instanceof ChangeListener) removeChangeListener((ChangeListener) this.editor); if (editor instanceof ChangeListener) addChangeListener((ChangeListener) editor); this.editor = editor; }
if (editor == null)
public void setModel(SpinnerModel newModel) { if (newModel == null) throw new IllegalArgumentException(); if (model == newModel) return; SpinnerModel oldModel = model; model = newModel; firePropertyChange("model", oldModel, newModel); if (editor == null) setEditor(createEditor(model)); }
public synchronized void draw(Shape shape, AffineTransform tx, Color color, int mode) {
public synchronized void draw(Shape shape, Shape clip, AffineTransform tx, Color color, int mode) {
public synchronized void draw(Shape shape, AffineTransform tx, Color color, int mode) { vgaIO.setGRAF(0, convertColor(color)); vgaIO.setGRAF(3, (mode == PAINT_MODE) ? LOGOP_NONE : LOGOP_XOR); draw(shape, tx, 0, mode); }
draw(shape, tx, 0, mode);
draw(shape, clip, tx, 0, mode);
public synchronized void draw(Shape shape, AffineTransform tx, Color color, int mode) { vgaIO.setGRAF(0, convertColor(color)); vgaIO.setGRAF(3, (mode == PAINT_MODE) ? LOGOP_NONE : LOGOP_XOR); draw(shape, tx, 0, mode); }
try { if (parent != null) checkExpandParents(parent); } catch (ExpandVetoException e) { return; }
protected void setExpandedState(TreePath path, boolean state) { if (path == null) return; TreePath parent = path.getParentPath(); try { if (parent != null) checkExpandParents(parent); } catch (ExpandVetoException e) { // Expansion vetoed. return; } doExpandParents(path, state); }
if (treeModelListener == null) treeModelListener = createTreeModelListener(); model.addTreeModelListener(treeModelListener);
public void setModel(TreeModel model) { if (treeModel == model) return; TreeModel oldValue = treeModel; treeModel = model; firePropertyChange(TREE_MODEL_PROPERTY, oldValue, model); // add treeModelListener to the new model if (treeModelListener == null) treeModelListener = createTreeModelListener(); model.addTreeModelListener(treeModelListener); }
return maxSize;
return new Dimension(Short.MAX_VALUE, Short.MAX_VALUE);
public Dimension getMaximumSize(JComponent c) { return maxSize; }
return minSize;
return new Dimension(0, 0);
public Dimension getMinimumSize(JComponent c) { return minSize; }
Dimension pref = verticalPrefSize;
Dimension pref = new Dimension(2, 0);
public Dimension getPreferredSize(JComponent c) { Dimension pref = verticalPrefSize; if (c instanceof JSeparator) { JSeparator s = (JSeparator) c; if (s.getOrientation() == JSeparator.HORIZONTAL) pref = horizontalPrefSize; } return pref; }
pref = horizontalPrefSize;
pref = new Dimension(0, 2);
public Dimension getPreferredSize(JComponent c) { Dimension pref = verticalPrefSize; if (c instanceof JSeparator) { JSeparator s = (JSeparator) c; if (s.getOrientation() == JSeparator.HORIZONTAL) pref = horizontalPrefSize; } return pref; }
try { FileInputStream in = new FileInputStream(settingsDirectory() + getConfigurationResource()); sesProps.load(in); if (sesProps.size() == 0) loadDefaults(); } catch (IOException ioe) { System.out.println("Information Message: Properties file is being " + "created for first time use: File name " + getConfigurationResource());
if (configurationResource == null || configurationResource == "") { configurationResource = "TN5250JDefaults.props"; usingDefaults = true;
private void loadConfigurationResource() { sesProps = new Properties(); try { FileInputStream in = new FileInputStream(settingsDirectory() + getConfigurationResource()); sesProps.load(in); if (sesProps.size() == 0) loadDefaults(); } catch (IOException ioe) { System.out.println("Information Message: Properties file is being " + "created for first time use: File name " + getConfigurationResource()); loadDefaults(); } catch (SecurityException se) { System.out.println(se.getMessage()); } }
catch (SecurityException se) { System.out.println(se.getMessage());
else { try { FileInputStream in = new FileInputStream(settingsDirectory() + getConfigurationResource()); sesProps.load(in); if (sesProps.size() == 0) loadDefaults(); } catch (IOException ioe) { System.out.println("Information Message: Properties file is being " + "created for first time use: File name " + getConfigurationResource()); loadDefaults(); } catch (SecurityException se) { System.out.println(se.getMessage()); }
private void loadConfigurationResource() { sesProps = new Properties(); try { FileInputStream in = new FileInputStream(settingsDirectory() + getConfigurationResource()); sesProps.load(in); if (sesProps.size() == 0) loadDefaults(); } catch (IOException ioe) { System.out.println("Information Message: Properties file is being " + "created for first time use: File name " + getConfigurationResource()); loadDefaults(); } catch (SecurityException se) { System.out.println(se.getMessage()); } }
String moreIndent = indent + sPrettyXDFOutputIndentation;
String moreIndent = indent + Specification.getInstance().getPrettyXDFOutputIndentation();
protected void specificIOStyleToXDF( OutputStream outputstream,String indent) { //open the code writeOut(outputstream, "<" + classXDFNodeName); writeOut(outputstream, " count=\"" + getCount() + "\""); writeOut(outputstream, ">"); //write out nodes in formatCommandList synchronized (formatCommandList) { int stop = formatCommandList.size(); String moreIndent = indent + sPrettyXDFOutputIndentation; for (int i = 0; i <stop; i++) { if (sPrettyXDFOutput) { writeOut(outputstream, Constants.NEW_LINE); writeOut(outputstream, moreIndent); } ((XMLDataIOStyle) formatCommandList.get(i)).specificIOStyleToXDF(outputstream, moreIndent); } } //close the node if (sPrettyXDFOutput) { writeOut(outputstream, Constants.NEW_LINE); writeOut(outputstream, indent); } writeOut(outputstream, "</" + classXDFNodeName + ">"); }
if (sPrettyXDFOutput) {
if (Specification.getInstance().isPrettyXDFOutput()) {
protected void specificIOStyleToXDF( OutputStream outputstream,String indent) { //open the code writeOut(outputstream, "<" + classXDFNodeName); writeOut(outputstream, " count=\"" + getCount() + "\""); writeOut(outputstream, ">"); //write out nodes in formatCommandList synchronized (formatCommandList) { int stop = formatCommandList.size(); String moreIndent = indent + sPrettyXDFOutputIndentation; for (int i = 0; i <stop; i++) { if (sPrettyXDFOutput) { writeOut(outputstream, Constants.NEW_LINE); writeOut(outputstream, moreIndent); } ((XMLDataIOStyle) formatCommandList.get(i)).specificIOStyleToXDF(outputstream, moreIndent); } } //close the node if (sPrettyXDFOutput) { writeOut(outputstream, Constants.NEW_LINE); writeOut(outputstream, indent); } writeOut(outputstream, "</" + classXDFNodeName + ">"); }
splash.setVisible(false);
private String getConnectSession () { Connect sc = new Connect(frame1,LangTool.getString("ss.title"),sessions); // load the new session information from the session property file loadSessions(); return sc.getConnectKey(); }
m.splash.setVisible(false);
static public void main(String[] args) { if (isSpecified("-MDI",args)) { useMDIFrames = true; } if (!isSpecified("-nc",args)) { if (!checkBootStrapper(args)) { // if we did not find a running instance and the -d options is // specified start up the bootstrap deamon to allow checking // for running instances if (isSpecified("-d",args)) { strapper = new BootStrapper(); strapper.start(); } } else { System.exit(0); } } My5250 m = new My5250(); if (strapper != null) strapper.addBootListener(m); if (args.length > 0) { if (isSpecified("-width",args) || isSpecified("-height",args)) { int width = m.frame1.getWidth(); int height = m.frame1.getHeight(); if (isSpecified("-width",args)) { width = Integer.parseInt(My5250.getParm("-width",args)); } if (isSpecified("-height",args)) { height = Integer.parseInt(My5250.getParm("-height",args)); } m.frame1.setSize(width,height); m.frame1.centerFrame(); } /** * @todo this crap needs to be rewritten it is a mess */ if (args[0].startsWith("-")) { // check if a session parameter is specified on the command line if (isSpecified("-s",args)) { String sd = getParm("-s",args); if (sessions.containsKey(sd)) { sessions.setProperty("emul.default",sd); } else { args = null; } } // check if a locale parameter is specified on the command line if (isSpecified("-L",args)) { Locale.setDefault(parseLocal(getParm("-L",args))); } LangTool.init(); if (isSpecified("-s",args)) m.sessionArgs = args; else m.sessionArgs = null;// } } else { LangTool.init(); m.sessionArgs = args; } } else { LangTool.init(); m.sessionArgs = null; } if (m.sessionArgs != null) { // BEGIN // 2001/09/19 natural computing MR Vector os400_sessions = new Vector(); Vector session_params = new Vector(); for (int x = 0; x < args.length; x++) { if (args[x].equals("-s")) { x++; if (args[x] != null && sessions.containsKey(args[x])) { os400_sessions.addElement(args[x]); }else{ x--; session_params.addElement(args[x]); } }else{ session_params.addElement(args[x]); } } for (int x = 0; x < session_params.size(); x++) m.sessionArgs[x] = session_params.elementAt(x).toString(); m.startNewSession(); for (int x = 1; x < os400_sessions.size(); x++ ) { String sel = os400_sessions.elementAt(x).toString(); if (!m.frame1.isVisible()) { m.splash.updateProgress(++m.step); m.frame1.setVisible(true); m.splash.setVisible(false); m.frame1.setCursor(Cursor.getPredefinedCursor(Cursor.DEFAULT_CURSOR)); } m.sessionArgs = new String[NUM_PARMS]; m.parseArgs(sessions.getProperty(sel),m.sessionArgs); m.newSession(sel,m.sessionArgs); } // 2001/09/19 natural computing MR // END } else { m.startNewSession(); } }
splash.setVisible(false);
synchronized void newSession(String sel,String[] args) { Properties sesProps = new Properties(); String propFileName = null; String session = args[0]; // Start loading properties sesProps.put(SESSION_HOST,session); if (isSpecified("-e",args)) sesProps.put(SESSION_TN_ENHANCED,"1"); if (isSpecified("-p",args)) { sesProps.put(SESSION_HOST_PORT,getParm("-p",args)); } if (isSpecified("-f",args)) propFileName = getParm("-f",args); if (isSpecified("-cp",args)) sesProps.put(SESSION_CODE_PAGE ,getParm("-cp",args)); if (isSpecified("-gui",args)) sesProps.put(SESSION_USE_GUI,"1"); if (isSpecified("-132",args)) sesProps.put(SESSION_SCREEN_SIZE,SCREEN_SIZE_27X132_STR); else sesProps.put(SESSION_SCREEN_SIZE,SCREEN_SIZE_24X80_STR); // are we to use a socks proxy if (isSpecified("-usp",args)) { // socks proxy host argument if (isSpecified("-sph",args)) { sesProps.put(SESSION_PROXY_HOST ,getParm("-sph",args)); } // socks proxy port argument if (isSpecified("-spp",args)) sesProps.put(SESSION_PROXY_PORT ,getParm("-spp",args)); } // are we to use a ssl and if we are what type if (isSpecified("-sslType",args)) { sesProps.put(SSL_TYPE,getParm("-sslType",args)); } // check if device name is specified if (isSpecified("-dn=hostname",args)){ String dnParam; // use IP address as device name try{ dnParam = InetAddress.getLocalHost().getHostName(); } catch(UnknownHostException uhe){ dnParam = "UNKNOWN_HOST"; } sesProps.put(SESSION_DEVICE_NAME ,dnParam); } else if (isSpecified("-dn",args)){ sesProps.put(SESSION_DEVICE_NAME ,getParm("-dn",args)); } if (isSpecified("-hb",args)) sesProps.put(SESSION_HEART_BEAT,"1"); int sessionCount = manager.getSessions().getCount(); Session5250 s2 = manager.openSession(sesProps,propFileName,sel); SessionGUI s = new SessionGUI(s2); if (!frame1.isVisible()) { splash.updateProgress(++step); // Here we check if this is the first session created in the system. // We have to create a frame on initialization for use in other scenarios // so if this is the first session being added in the system then we // use the frame that is created and skip the part of creating a new // view which would increment the count and leave us with an unused // frame. if (isSpecified("-noembed",args) && sessionCount > 0) { newView(); } frame1.setVisible(true); splash.setVisible(false); frame1.setCursor(Cursor.getPredefinedCursor(Cursor.DEFAULT_CURSOR)); } else { if (isSpecified("-noembed",args)) { splash.updateProgress(++step); newView(); frame1.setVisible(true); splash.setVisible(false); frame1.setCursor(Cursor.getPredefinedCursor(Cursor.DEFAULT_CURSOR)); } } if (isSpecified("-t",args)) frame1.addSessionView(sel,s); else frame1.addSessionView(session,s); s.connect(); s.addEmulatorActionListener(this); }
throw new BAD_OPERATION(0, CompletionStatus.COMPLETED_MAYBE);
throw new BAD_OPERATION(Minor.Method, CompletionStatus.COMPLETED_MAYBE);
public OutputStream _invoke(String method, InputStream in, ResponseHandler rh) { OutputStream out = null; Integer call_method = (Integer) _NamingContextImplBase.methods.get(method); if (call_method == null) throw new BAD_OPERATION(0, CompletionStatus.COMPLETED_MAYBE); switch (call_method.intValue()) { case 0: // bind { try { NameComponent[] a_name = NameHelper.read(in); org.omg.CORBA.Object an_object = ObjectHelper.read(in); bind(a_name, an_object); out = rh.createReply(); } catch (NotFound ex) { out = rh.createExceptionReply(); NotFoundHelper.write(out, ex); } catch (CannotProceed ex) { out = rh.createExceptionReply(); CannotProceedHelper.write(out, ex); } catch (InvalidName ex) { out = rh.createExceptionReply(); InvalidNameHelper.write(out, ex); } catch (AlreadyBound ex) { out = rh.createExceptionReply(); AlreadyBoundHelper.write(out, ex); } break; } case 1: // rebind { try { NameComponent[] a_name = NameHelper.read(in); org.omg.CORBA.Object an_object = ObjectHelper.read(in); rebind(a_name, an_object); out = rh.createReply(); } catch (NotFound ex) { out = rh.createExceptionReply(); NotFoundHelper.write(out, ex); } catch (CannotProceed ex) { out = rh.createExceptionReply(); CannotProceedHelper.write(out, ex); } catch (InvalidName ex) { out = rh.createExceptionReply(); InvalidNameHelper.write(out, ex); } break; } case 2: // bind_context { try { NameComponent[] a_name = NameHelper.read(in); NamingContext a_context = NamingContextHelper.read(in); bind_context(a_name, a_context); out = rh.createReply(); } catch (NotFound ex) { out = rh.createExceptionReply(); NotFoundHelper.write(out, ex); } catch (CannotProceed ex) { out = rh.createExceptionReply(); CannotProceedHelper.write(out, ex); } catch (InvalidName ex) { out = rh.createExceptionReply(); InvalidNameHelper.write(out, ex); } catch (AlreadyBound ex) { out = rh.createExceptionReply(); AlreadyBoundHelper.write(out, ex); } break; } case 3: // rebind_context { try { NameComponent[] a_name = NameHelper.read(in); NamingContext a_context = NamingContextHelper.read(in); rebind_context(a_name, a_context); out = rh.createReply(); } catch (NotFound ex) { out = rh.createExceptionReply(); NotFoundHelper.write(out, ex); } catch (CannotProceed ex) { out = rh.createExceptionReply(); CannotProceedHelper.write(out, ex); } catch (InvalidName ex) { out = rh.createExceptionReply(); InvalidNameHelper.write(out, ex); } break; } case 4: // resolve { try { NameComponent[] a_name = NameHelper.read(in); org.omg.CORBA.Object __result = null; __result = resolve(a_name); out = rh.createReply(); ObjectHelper.write(out, __result); } catch (NotFound ex) { out = rh.createExceptionReply(); NotFoundHelper.write(out, ex); } catch (CannotProceed ex) { out = rh.createExceptionReply(); CannotProceedHelper.write(out, ex); } catch (InvalidName ex) { out = rh.createExceptionReply(); InvalidNameHelper.write(out, ex); } break; } case 5: // unbind { try { NameComponent[] a_name = NameHelper.read(in); unbind(a_name); out = rh.createReply(); } catch (NotFound ex) { out = rh.createExceptionReply(); NotFoundHelper.write(out, ex); } catch (CannotProceed ex) { out = rh.createExceptionReply(); CannotProceedHelper.write(out, ex); } catch (InvalidName ex) { out = rh.createExceptionReply(); InvalidNameHelper.write(out, ex); } break; } case 6: // new_context { NamingContext __result = null; __result = new_context(); out = rh.createReply(); NamingContextHelper.write(out, __result); break; } case 7: // bind_new_context { try { NameComponent[] a_name = NameHelper.read(in); NamingContext __result = null; __result = bind_new_context(a_name); out = rh.createReply(); NamingContextHelper.write(out, __result); } catch (NotFound ex) { out = rh.createExceptionReply(); NotFoundHelper.write(out, ex); } catch (AlreadyBound ex) { out = rh.createExceptionReply(); AlreadyBoundHelper.write(out, ex); } catch (CannotProceed ex) { out = rh.createExceptionReply(); CannotProceedHelper.write(out, ex); } catch (InvalidName ex) { out = rh.createExceptionReply(); InvalidNameHelper.write(out, ex); } break; } case 8: // destroy { try { destroy(); out = rh.createReply(); } catch (NotEmpty ex) { out = rh.createExceptionReply(); NotEmptyHelper.write(out, ex); } break; } case 9: // list { int amount = in.read_ulong(); BindingListHolder a_list = new BindingListHolder(); BindingIteratorHolder an_iter = new BindingIteratorHolder(); list(amount, a_list, an_iter); out = rh.createReply(); BindingListHelper.write(out, a_list.value); BindingIteratorHelper.write(out, an_iter.value); break; } default: throw new BAD_OPERATION(0, CompletionStatus.COMPLETED_MAYBE); } return out; }
public synchronized void registerFileSystem(FileSystem fs) { filesystems.put(fs.getDevice(), fs);
public void registerFileSystem(FileSystem fs) { final Device device = fs.getDevice(); synchronized (this) { filesystems.put(device, fs); }
public synchronized void registerFileSystem(FileSystem fs) { filesystems.put(fs.getDevice(), fs); }
return "JMenuBar";
StringBuffer sb = new StringBuffer(); sb.append(super.paramString()); sb.append(",margin="); if (getMargin() != null) sb.append(getMargin()); sb.append(",paintBorder=").append(isBorderPainted()); return sb.toString();
protected String paramString() { return "JMenuBar"; }
if (b != old) { firePropertyChange(BORDER_PAINTED_CHANGED_PROPERTY, old, b);
firePropertyChange("borderPainted", old, b);
public void setBorderPainted(boolean b) { boolean old = borderPainted; borderPainted = b; if (b != old) { firePropertyChange(BORDER_PAINTED_CHANGED_PROPERTY, old, b); revalidate(); repaint(); } }
if (m.equals(this.margin))
if (m != margin)
public void setMargin(Insets m) { if (m.equals(this.margin)) { Insets oldMargin = this.margin; this.margin = m; firePropertyChange(MARGIN_CHANGED_PROPERTY, oldMargin, margin); } this.margin = m; }
Insets oldMargin = this.margin; this.margin = m; firePropertyChange(MARGIN_CHANGED_PROPERTY, oldMargin, margin);
Insets oldMargin = margin; margin = m; firePropertyChange("margin", oldMargin, margin);
public void setMargin(Insets m) { if (m.equals(this.margin)) { Insets oldMargin = this.margin; this.margin = m; firePropertyChange(MARGIN_CHANGED_PROPERTY, oldMargin, margin); } this.margin = m; }
this.margin = m;
public void setMargin(Insets m) { if (m.equals(this.margin)) { Insets oldMargin = this.margin; this.margin = m; firePropertyChange(MARGIN_CHANGED_PROPERTY, oldMargin, margin); } this.margin = m; }
selectionModel = model;
public void setSelectionModel(SingleSelectionModel model) { selectionModel = model; if (selectionModel != model) { SingleSelectionModel oldModel = selectionModel; selectionModel = model; firePropertyChange(MODEL_CHANGED_PROPERTY, oldModel, this.selectionModel); } }
firePropertyChange(MODEL_CHANGED_PROPERTY, oldModel, this.selectionModel);
firePropertyChange("model", oldModel, selectionModel);
public void setSelectionModel(SingleSelectionModel model) { selectionModel = model; if (selectionModel != model) { SingleSelectionModel oldModel = selectionModel; selectionModel = model; firePropertyChange(MODEL_CHANGED_PROPERTY, oldModel, this.selectionModel); } }
ArcIterator(Arc2D a, AffineTransform xform)
public ArcIterator(Arc2D a, AffineTransform xform)
ArcIterator(Arc2D a, AffineTransform xform) { this.xform = xform; x = a.getX(); y = a.getY(); w = a.getWidth(); h = a.getHeight(); start = a.getAngleStart() * (Math.PI / 180); extent = a.getAngleExtent() * (Math.PI / 180); type = a.type; double e = extent < 0 ? -extent : extent; if (w < 0 || h < 0) limit = -1; else if (e == 0) limit = type; else if (e <= Math.PI / 2.0) limit = type + 1; else if (e <= Math.PI) limit = type + 2; else if (e <= 3.0 * (Math.PI / 2.0)) limit = type + 3; else limit = type + 4; }
start = a.getAngleStart() * (Math.PI / 180); extent = a.getAngleExtent() * (Math.PI / 180);
double start = a.getAngleStart() * (Math.PI / 180); double extent = a.getAngleExtent() * (Math.PI / 180); if (extent < 0) { extent = -extent; start = 2 * Math.PI - extent + start; } this.start = start; this.extent = extent;
ArcIterator(Arc2D a, AffineTransform xform) { this.xform = xform; x = a.getX(); y = a.getY(); w = a.getWidth(); h = a.getHeight(); start = a.getAngleStart() * (Math.PI / 180); extent = a.getAngleExtent() * (Math.PI / 180); type = a.type; double e = extent < 0 ? -extent : extent; if (w < 0 || h < 0) limit = -1; else if (e == 0) limit = type; else if (e <= Math.PI / 2.0) limit = type + 1; else if (e <= Math.PI) limit = type + 2; else if (e <= 3.0 * (Math.PI / 2.0)) limit = type + 3; else limit = type + 4; }
double e = extent < 0 ? -extent : extent;
ArcIterator(Arc2D a, AffineTransform xform) { this.xform = xform; x = a.getX(); y = a.getY(); w = a.getWidth(); h = a.getHeight(); start = a.getAngleStart() * (Math.PI / 180); extent = a.getAngleExtent() * (Math.PI / 180); type = a.type; double e = extent < 0 ? -extent : extent; if (w < 0 || h < 0) limit = -1; else if (e == 0) limit = type; else if (e <= Math.PI / 2.0) limit = type + 1; else if (e <= Math.PI) limit = type + 2; else if (e <= 3.0 * (Math.PI / 2.0)) limit = type + 3; else limit = type + 4; }
else if (e == 0)
else if (extent == 0)
ArcIterator(Arc2D a, AffineTransform xform) { this.xform = xform; x = a.getX(); y = a.getY(); w = a.getWidth(); h = a.getHeight(); start = a.getAngleStart() * (Math.PI / 180); extent = a.getAngleExtent() * (Math.PI / 180); type = a.type; double e = extent < 0 ? -extent : extent; if (w < 0 || h < 0) limit = -1; else if (e == 0) limit = type; else if (e <= Math.PI / 2.0) limit = type + 1; else if (e <= Math.PI) limit = type + 2; else if (e <= 3.0 * (Math.PI / 2.0)) limit = type + 3; else limit = type + 4; }
else if (e <= Math.PI / 2.0)
else if (extent <= Math.PI / 2.0)
ArcIterator(Arc2D a, AffineTransform xform) { this.xform = xform; x = a.getX(); y = a.getY(); w = a.getWidth(); h = a.getHeight(); start = a.getAngleStart() * (Math.PI / 180); extent = a.getAngleExtent() * (Math.PI / 180); type = a.type; double e = extent < 0 ? -extent : extent; if (w < 0 || h < 0) limit = -1; else if (e == 0) limit = type; else if (e <= Math.PI / 2.0) limit = type + 1; else if (e <= Math.PI) limit = type + 2; else if (e <= 3.0 * (Math.PI / 2.0)) limit = type + 3; else limit = type + 4; }
else if (e <= Math.PI)
else if (extent <= Math.PI)
ArcIterator(Arc2D a, AffineTransform xform) { this.xform = xform; x = a.getX(); y = a.getY(); w = a.getWidth(); h = a.getHeight(); start = a.getAngleStart() * (Math.PI / 180); extent = a.getAngleExtent() * (Math.PI / 180); type = a.type; double e = extent < 0 ? -extent : extent; if (w < 0 || h < 0) limit = -1; else if (e == 0) limit = type; else if (e <= Math.PI / 2.0) limit = type + 1; else if (e <= Math.PI) limit = type + 2; else if (e <= 3.0 * (Math.PI / 2.0)) limit = type + 3; else limit = type + 4; }
else if (e <= 3.0 * (Math.PI / 2.0))
else if (extent <= 3.0 * (Math.PI / 2.0))
ArcIterator(Arc2D a, AffineTransform xform) { this.xform = xform; x = a.getX(); y = a.getY(); w = a.getWidth(); h = a.getHeight(); start = a.getAngleStart() * (Math.PI / 180); extent = a.getAngleExtent() * (Math.PI / 180); type = a.type; double e = extent < 0 ? -extent : extent; if (w < 0 || h < 0) limit = -1; else if (e == 0) limit = type; else if (e <= Math.PI / 2.0) limit = type + 1; else if (e <= Math.PI) limit = type + 2; else if (e <= 3.0 * (Math.PI / 2.0)) limit = type + 3; else limit = type + 4; }
if (w <= 0 || h <= 0)
double extent = getAngleExtent(); if (w <= 0 || h <= 0 || extent == 0) return false; double mx = getX() + w / 2; double my = getY() + h / 2; double dx = (x - mx) * 2 / w; double dy = (y - my) * 2 / h; if ((dx * dx + dy * dy) >= 1.0) return false; double angle = Math.toDegrees(Math.atan2(-dy, dx)); if (getArcType() != CHORD) return containsAngle(angle); double a1 = Math.toRadians(getAngleStart()); double a2 = Math.toRadians(getAngleStart() + extent); double x1 = mx + getWidth() * Math.cos(a1) / 2; double y1 = my - getHeight() * Math.sin(a1) / 2; double x2 = mx + getWidth() * Math.cos(a2) / 2; double y2 = my - getHeight() * Math.sin(a2) / 2; double sgn = ((x2 - x1) * (my - y1) - (mx - x1) * (y2 - y1)) * ((x2 - x1) * (y - y1) - (x - x1) * (y2 - y1)); if (Math.abs(extent) > 180) { if (containsAngle(angle)) return true; return sgn > 0; } else { if (! containsAngle(angle))
public boolean contains(double x, double y) { double w = getWidth(); double h = getHeight(); if (w <= 0 || h <= 0) return false; // XXX Finish implementing. throw new Error("not implemented"); }
throw new Error("not implemented");
return sgn < 0; }
public boolean contains(double x, double y) { double w = getWidth(); double h = getHeight(); if (w <= 0 || h <= 0) return false; // XXX Finish implementing. throw new Error("not implemented"); }
double end = start + getAngleExtent();
double extent = getAngleExtent(); double end = start + extent; if (extent >= 360 || extent <= -360) return true; if (extent < 0) { end = start; start += extent; }
public boolean containsAngle(double a) { double start = getAngleStart(); double end = start + getAngleExtent(); start %= 360; if (start < 0) start += 360; end %= 360; if (end < 0) end += 360; a %= 360; if (a < 0) a += 360; return a >= start && a <= end; }
if (start < 0)
while (start < 0)
public boolean containsAngle(double a) { double start = getAngleStart(); double end = start + getAngleExtent(); start %= 360; if (start < 0) start += 360; end %= 360; if (end < 0) end += 360; a %= 360; if (a < 0) a += 360; return a >= start && a <= end; }
if (end < 0)
while (end < start)
public boolean containsAngle(double a) { double start = getAngleStart(); double end = start + getAngleExtent(); start %= 360; if (start < 0) start += 360; end %= 360; if (end < 0) end += 360; a %= 360; if (a < 0) a += 360; return a >= start && a <= end; }
if (a < 0)
while (a < start)
public boolean containsAngle(double a) { double start = getAngleStart(); double end = start + getAngleExtent(); start %= 360; if (start < 0) start += 360; end %= 360; if (end < 0) end += 360; a %= 360; if (a < 0) a += 360; return a >= start && a <= end; }
double mw = getWidth(); double mh = getHeight(); if (mw <= 0 || mh <= 0 || w <= 0 || h <= 0)
double extent = getAngleExtent(); if (extent == 0) return false; if (contains(x, y) || contains(x, y + h) || contains(x + w, y) || contains(x + w, y + h)) return true; Rectangle2D rect = new Rectangle2D.Double(x, y, w, h); double a = getWidth() / 2.0; double b = getHeight() / 2.0; double mx = getX() + a; double my = getY() + b; double x1 = mx + a * Math.cos(Math.toRadians(getAngleStart())); double y1 = my - b * Math.sin(Math.toRadians(getAngleStart())); double x2 = mx + a * Math.cos(Math.toRadians(getAngleStart() + extent)); double y2 = my - b * Math.sin(Math.toRadians(getAngleStart() + extent)); if (getArcType() != CHORD) { if (rect.intersectsLine(mx, my, x1, y1)) return true; if (rect.intersectsLine(mx, my, x2, y2)) return true; } else if (rect.intersectsLine(x1, y1, x2, y2)) return true; double dx; double dy; dy = y - my; dx = a * Math.sqrt(1 - ((dy * dy) / (b * b))); if (! java.lang.Double.isNaN(dx)) { if (mx + dx >= x && mx + dx <= x + w && containsAngle(Math.toDegrees(Math.atan2(-dy, dx)))) return true; if (mx - dx >= x && mx - dx <= x + w && containsAngle(Math.toDegrees(Math.atan2(-dy, -dx)))) return true; } dy = (y + h) - my; dx = a * Math.sqrt(1 - ((dy * dy) / (b * b))); if (! java.lang.Double.isNaN(dx)) { if (mx + dx >= x && mx + dx <= x + w && containsAngle(Math.toDegrees(Math.atan2(-dy, dx)))) return true; if (mx - dx >= x && mx - dx <= x + w && containsAngle(Math.toDegrees(Math.atan2(-dy, -dx)))) return true; } dx = x - mx; dy = b * Math.sqrt(1 - ((dx * dx) / (a * a))); if (! java.lang.Double.isNaN(dy)) { if (my + dy >= y && my + dy <= y + h && containsAngle(Math.toDegrees(Math.atan2(-dy, dx)))) return true; if (my - dy >= y && my - dy <= y + h && containsAngle(Math.toDegrees(Math.atan2(dy, dx)))) return true; } dx = (x + w) - mx; dy = b * Math.sqrt(1 - ((dx * dx) / (a * a))); if (! java.lang.Double.isNaN(dy)) { if (my + dy >= y && my + dy <= y + h && containsAngle(Math.toDegrees(Math.atan2(-dy, dx)))) return true; if (my - dy >= y && my - dy <= y + h && containsAngle(Math.toDegrees(Math.atan2(dy, dx)))) return true; } if (rect.contains(mx, my)) return true;
public boolean intersects(double x, double y, double w, double h) { double mw = getWidth(); double mh = getHeight(); if (mw <= 0 || mh <= 0 || w <= 0 || h <= 0) return false; // XXX Finish implementing. throw new Error("not implemented"); }
throw new Error("not implemented");
public boolean intersects(double x, double y, double w, double h) { double mw = getWidth(); double mh = getHeight(); if (mw <= 0 || mh <= 0 || w <= 0 || h <= 0) return false; // XXX Finish implementing. throw new Error("not implemented"); }
throw new Error("not implemented");
if ((p2.getX() - p1.getX()) * (p3.getY() - p1.getY()) - (p3.getX() - p1.getX()) * (p2.getY() - p1.getY()) > 0) { Point2D p = p3; p3 = p1; p1 = p; } double dx1 = (p1.getX() - p2.getX()) / p1.distance(p2); double dy1 = (p1.getY() - p2.getY()) / p1.distance(p2); double dx2 = (p2.getX() - p3.getX()) / p3.distance(p2); double dy2 = (p2.getY() - p3.getY()) / p3.distance(p2); double theta1 = Math.atan2(dx1, dy1); double theta2 = Math.atan2(dx2, dy2); double dx = r * Math.cos(theta2) - r * Math.cos(theta1); double dy = -r * Math.sin(theta2) + r * Math.sin(theta1); if (theta1 < 0) theta1 += 2 * Math.PI; if (theta2 < 0) theta2 += 2 * Math.PI; if (theta2 < theta1) theta2 += 2 * Math.PI; dx1 = p1.getX() - p2.getX(); dy1 = p1.getY() - p2.getY(); dx2 = p3.getX() - p2.getX(); dy2 = p3.getY() - p2.getY(); double t2 = -(dx1 * dy - dy1 * dx) / (dx2 * dy1 - dx1 * dy2); double x2 = t2 * (p3.getX() - p2.getX()) + p2.getX(); double y2 = t2 * (p3.getY() - p2.getY()) + p2.getY(); double x = x2 - r * Math.cos(theta2); double y = y2 + r * Math.sin(theta2); setArc(x - r, y - r, 2 * r, 2 * r, Math.toDegrees(theta1), Math.toDegrees(theta2 - theta1), getArcType());
public void setArcByTangent(Point2D p1, Point2D p2, Point2D p3, double r) { // XXX Implement. throw new Error("not implemented"); }
(BranchElement) createBranchElement(null, SimpleAttributeSet.EMPTY);
(BranchElement) createBranchElement(null, null);
protected AbstractDocument.AbstractElement createDefaultRoot() { BranchElement root = (BranchElement) createBranchElement(null, SimpleAttributeSet.EMPTY); Element[] array = new Element[1]; array[0] = createLeafElement(root, SimpleAttributeSet.EMPTY, 0, 1); root.replace(0, 0, array); return root; }
array[0] = createLeafElement(root, SimpleAttributeSet.EMPTY, 0, 1);
array[0] = createLeafElement(root, null, 0, 1);
protected AbstractDocument.AbstractElement createDefaultRoot() { BranchElement root = (BranchElement) createBranchElement(null, SimpleAttributeSet.EMPTY); Element[] array = new Element[1]; array[0] = createLeafElement(root, SimpleAttributeSet.EMPTY, 0, 1); root.replace(0, 0, array); return root; }
int eventLength = event.getLength(); int end = offset + event.getLength(); int oldElementIndex, elementIndex = rootElement.getElementIndex(offset); Element firstElement = rootElement.getElement(elementIndex); oldElementIndex = elementIndex; if (offset > 0 && firstElement.getStartOffset() != offset) {
int length = event.getLength();
protected void insertUpdate(DefaultDocumentEvent event, AttributeSet attributes) { int offset = event.getOffset(); int eventLength = event.getLength(); int end = offset + event.getLength(); int oldElementIndex, elementIndex = rootElement.getElementIndex(offset); Element firstElement = rootElement.getElement(elementIndex); oldElementIndex = elementIndex; // If we're inserting immediately after a newline we have to fix the // Element structure (but only if we are dealing with a line which // has not existed as Element before). if (offset > 0 && firstElement.getStartOffset() != offset) { try { String s = getText(offset - 1, 1); if (s.equals("\n") ) { int newEl2EndOffset = end; boolean replaceNext = false; if (rootElement.getElementCount() > elementIndex + 1) { replaceNext = true; newEl2EndOffset = rootElement.getElement(elementIndex + 1).getEndOffset(); } Element newEl1 = createLeafElement(rootElement, firstElement.getAttributes(), firstElement.getStartOffset(), offset); Element newEl2 = createLeafElement (rootElement, firstElement.getAttributes(), offset, newEl2EndOffset); if (replaceNext) rootElement.replace(elementIndex, 2, new Element[] { newEl1, newEl2 }); else rootElement.replace(elementIndex, 1, new Element[] { newEl1, newEl2 }); firstElement = newEl2; elementIndex ++; } } catch (BadLocationException ble) { // This shouldn't happen. AssertionError ae = new AssertionError(); ae.initCause(ble); throw ae; } } // added and removed are Element arrays used to add an ElementEdit // to the DocumentEvent if there were entire lines added or removed. Element[] removed = new Element[1]; Element[] added; try { String str = content.getString(offset, eventLength); ArrayList elts = new ArrayList(); // Determine how many NEW lines were added by finding the newline // characters within the newly inserted text int j = firstElement.getStartOffset(); int i = str.indexOf('\n', 0); int contentLength = content.length(); while (i != -1 && i <= eventLength) { // For each new line, create a new element elts.add(createLeafElement(rootElement, SimpleAttributeSet.EMPTY, j, offset + i + 1)); j = offset + i + 1; if (j >= contentLength) break; i = str.indexOf('\n', i + 1); } // If there were new lines added we have to add an ElementEdit to // the DocumentEvent and we have to call rootElement.replace to // insert the new lines if (elts.size() != 0) { // If we have created new lines test whether there are remaining // characters in firstElement after the inserted text and if so // create a new element for them. if (j < firstElement.getEndOffset()) elts.add(createLeafElement(rootElement, SimpleAttributeSet.EMPTY, j, firstElement.getEndOffset())); // Set up the ElementEdit by filling the added and removed // arrays with the proper Elements added = new Element[elts.size()]; elts.toArray(added); removed[0] = firstElement; // Now create and add the ElementEdit ElementEdit e = new ElementEdit(rootElement, elementIndex, removed, added); event.addEdit(e); // And call replace to actually make the changes ((BranchElement) rootElement).replace(elementIndex, 1, added); } } catch (BadLocationException e) { // This shouldn't happen so we throw an AssertionError AssertionError ae = new AssertionError(); ae.initCause(e); throw ae; } super.insertUpdate(event, attributes); }
String s = getText(offset - 1, 1); if (s.equals("\n") )
text = getText(offset, length); } catch (BadLocationException ex)
protected void insertUpdate(DefaultDocumentEvent event, AttributeSet attributes) { int offset = event.getOffset(); int eventLength = event.getLength(); int end = offset + event.getLength(); int oldElementIndex, elementIndex = rootElement.getElementIndex(offset); Element firstElement = rootElement.getElement(elementIndex); oldElementIndex = elementIndex; // If we're inserting immediately after a newline we have to fix the // Element structure (but only if we are dealing with a line which // has not existed as Element before). if (offset > 0 && firstElement.getStartOffset() != offset) { try { String s = getText(offset - 1, 1); if (s.equals("\n") ) { int newEl2EndOffset = end; boolean replaceNext = false; if (rootElement.getElementCount() > elementIndex + 1) { replaceNext = true; newEl2EndOffset = rootElement.getElement(elementIndex + 1).getEndOffset(); } Element newEl1 = createLeafElement(rootElement, firstElement.getAttributes(), firstElement.getStartOffset(), offset); Element newEl2 = createLeafElement (rootElement, firstElement.getAttributes(), offset, newEl2EndOffset); if (replaceNext) rootElement.replace(elementIndex, 2, new Element[] { newEl1, newEl2 }); else rootElement.replace(elementIndex, 1, new Element[] { newEl1, newEl2 }); firstElement = newEl2; elementIndex ++; } } catch (BadLocationException ble) { // This shouldn't happen. AssertionError ae = new AssertionError(); ae.initCause(ble); throw ae; } } // added and removed are Element arrays used to add an ElementEdit // to the DocumentEvent if there were entire lines added or removed. Element[] removed = new Element[1]; Element[] added; try { String str = content.getString(offset, eventLength); ArrayList elts = new ArrayList(); // Determine how many NEW lines were added by finding the newline // characters within the newly inserted text int j = firstElement.getStartOffset(); int i = str.indexOf('\n', 0); int contentLength = content.length(); while (i != -1 && i <= eventLength) { // For each new line, create a new element elts.add(createLeafElement(rootElement, SimpleAttributeSet.EMPTY, j, offset + i + 1)); j = offset + i + 1; if (j >= contentLength) break; i = str.indexOf('\n', i + 1); } // If there were new lines added we have to add an ElementEdit to // the DocumentEvent and we have to call rootElement.replace to // insert the new lines if (elts.size() != 0) { // If we have created new lines test whether there are remaining // characters in firstElement after the inserted text and if so // create a new element for them. if (j < firstElement.getEndOffset()) elts.add(createLeafElement(rootElement, SimpleAttributeSet.EMPTY, j, firstElement.getEndOffset())); // Set up the ElementEdit by filling the added and removed // arrays with the proper Elements added = new Element[elts.size()]; elts.toArray(added); removed[0] = firstElement; // Now create and add the ElementEdit ElementEdit e = new ElementEdit(rootElement, elementIndex, removed, added); event.addEdit(e); // And call replace to actually make the changes ((BranchElement) rootElement).replace(elementIndex, 1, added); } } catch (BadLocationException e) { // This shouldn't happen so we throw an AssertionError AssertionError ae = new AssertionError(); ae.initCause(e); throw ae; } super.insertUpdate(event, attributes); }
int newEl2EndOffset = end; boolean replaceNext = false; if (rootElement.getElementCount() > elementIndex + 1) { replaceNext = true; newEl2EndOffset = rootElement.getElement(elementIndex + 1).getEndOffset(); } Element newEl1 = createLeafElement(rootElement, firstElement.getAttributes(), firstElement.getStartOffset(), offset); Element newEl2 = createLeafElement (rootElement, firstElement.getAttributes(), offset, newEl2EndOffset); if (replaceNext) rootElement.replace(elementIndex, 2, new Element[] { newEl1, newEl2 }); else rootElement.replace(elementIndex, 1, new Element[] { newEl1, newEl2 }); firstElement = newEl2; elementIndex ++;
AssertionError err = new AssertionError(); err.initCause(ex); throw err;
protected void insertUpdate(DefaultDocumentEvent event, AttributeSet attributes) { int offset = event.getOffset(); int eventLength = event.getLength(); int end = offset + event.getLength(); int oldElementIndex, elementIndex = rootElement.getElementIndex(offset); Element firstElement = rootElement.getElement(elementIndex); oldElementIndex = elementIndex; // If we're inserting immediately after a newline we have to fix the // Element structure (but only if we are dealing with a line which // has not existed as Element before). if (offset > 0 && firstElement.getStartOffset() != offset) { try { String s = getText(offset - 1, 1); if (s.equals("\n") ) { int newEl2EndOffset = end; boolean replaceNext = false; if (rootElement.getElementCount() > elementIndex + 1) { replaceNext = true; newEl2EndOffset = rootElement.getElement(elementIndex + 1).getEndOffset(); } Element newEl1 = createLeafElement(rootElement, firstElement.getAttributes(), firstElement.getStartOffset(), offset); Element newEl2 = createLeafElement (rootElement, firstElement.getAttributes(), offset, newEl2EndOffset); if (replaceNext) rootElement.replace(elementIndex, 2, new Element[] { newEl1, newEl2 }); else rootElement.replace(elementIndex, 1, new Element[] { newEl1, newEl2 }); firstElement = newEl2; elementIndex ++; } } catch (BadLocationException ble) { // This shouldn't happen. AssertionError ae = new AssertionError(); ae.initCause(ble); throw ae; } } // added and removed are Element arrays used to add an ElementEdit // to the DocumentEvent if there were entire lines added or removed. Element[] removed = new Element[1]; Element[] added; try { String str = content.getString(offset, eventLength); ArrayList elts = new ArrayList(); // Determine how many NEW lines were added by finding the newline // characters within the newly inserted text int j = firstElement.getStartOffset(); int i = str.indexOf('\n', 0); int contentLength = content.length(); while (i != -1 && i <= eventLength) { // For each new line, create a new element elts.add(createLeafElement(rootElement, SimpleAttributeSet.EMPTY, j, offset + i + 1)); j = offset + i + 1; if (j >= contentLength) break; i = str.indexOf('\n', i + 1); } // If there were new lines added we have to add an ElementEdit to // the DocumentEvent and we have to call rootElement.replace to // insert the new lines if (elts.size() != 0) { // If we have created new lines test whether there are remaining // characters in firstElement after the inserted text and if so // create a new element for them. if (j < firstElement.getEndOffset()) elts.add(createLeafElement(rootElement, SimpleAttributeSet.EMPTY, j, firstElement.getEndOffset())); // Set up the ElementEdit by filling the added and removed // arrays with the proper Elements added = new Element[elts.size()]; elts.toArray(added); removed[0] = firstElement; // Now create and add the ElementEdit ElementEdit e = new ElementEdit(rootElement, elementIndex, removed, added); event.addEdit(e); // And call replace to actually make the changes ((BranchElement) rootElement).replace(elementIndex, 1, added); } } catch (BadLocationException e) { // This shouldn't happen so we throw an AssertionError AssertionError ae = new AssertionError(); ae.initCause(e); throw ae; } super.insertUpdate(event, attributes); }
catch (BadLocationException ble)
catch (BadLocationException ex)
protected void insertUpdate(DefaultDocumentEvent event, AttributeSet attributes) { int offset = event.getOffset(); int eventLength = event.getLength(); int end = offset + event.getLength(); int oldElementIndex, elementIndex = rootElement.getElementIndex(offset); Element firstElement = rootElement.getElement(elementIndex); oldElementIndex = elementIndex; // If we're inserting immediately after a newline we have to fix the // Element structure (but only if we are dealing with a line which // has not existed as Element before). if (offset > 0 && firstElement.getStartOffset() != offset) { try { String s = getText(offset - 1, 1); if (s.equals("\n") ) { int newEl2EndOffset = end; boolean replaceNext = false; if (rootElement.getElementCount() > elementIndex + 1) { replaceNext = true; newEl2EndOffset = rootElement.getElement(elementIndex + 1).getEndOffset(); } Element newEl1 = createLeafElement(rootElement, firstElement.getAttributes(), firstElement.getStartOffset(), offset); Element newEl2 = createLeafElement (rootElement, firstElement.getAttributes(), offset, newEl2EndOffset); if (replaceNext) rootElement.replace(elementIndex, 2, new Element[] { newEl1, newEl2 }); else rootElement.replace(elementIndex, 1, new Element[] { newEl1, newEl2 }); firstElement = newEl2; elementIndex ++; } } catch (BadLocationException ble) { // This shouldn't happen. AssertionError ae = new AssertionError(); ae.initCause(ble); throw ae; } } // added and removed are Element arrays used to add an ElementEdit // to the DocumentEvent if there were entire lines added or removed. Element[] removed = new Element[1]; Element[] added; try { String str = content.getString(offset, eventLength); ArrayList elts = new ArrayList(); // Determine how many NEW lines were added by finding the newline // characters within the newly inserted text int j = firstElement.getStartOffset(); int i = str.indexOf('\n', 0); int contentLength = content.length(); while (i != -1 && i <= eventLength) { // For each new line, create a new element elts.add(createLeafElement(rootElement, SimpleAttributeSet.EMPTY, j, offset + i + 1)); j = offset + i + 1; if (j >= contentLength) break; i = str.indexOf('\n', i + 1); } // If there were new lines added we have to add an ElementEdit to // the DocumentEvent and we have to call rootElement.replace to // insert the new lines if (elts.size() != 0) { // If we have created new lines test whether there are remaining // characters in firstElement after the inserted text and if so // create a new element for them. if (j < firstElement.getEndOffset()) elts.add(createLeafElement(rootElement, SimpleAttributeSet.EMPTY, j, firstElement.getEndOffset())); // Set up the ElementEdit by filling the added and removed // arrays with the proper Elements added = new Element[elts.size()]; elts.toArray(added); removed[0] = firstElement; // Now create and add the ElementEdit ElementEdit e = new ElementEdit(rootElement, elementIndex, removed, added); event.addEdit(e); // And call replace to actually make the changes ((BranchElement) rootElement).replace(elementIndex, 1, added); } } catch (BadLocationException e) { // This shouldn't happen so we throw an AssertionError AssertionError ae = new AssertionError(); ae.initCause(e); throw ae; } super.insertUpdate(event, attributes); }
AssertionError ae = new AssertionError(); ae.initCause(ble); throw ae;
AssertionError err = new AssertionError(); err.initCause(ex); throw err; } boolean lastCharIsLineBreak = text.charAt(text.length() - 1) == '\n'; int lineIndex = -1; int lineStart = -1; int lineEnd = -1; Element[] removed = null; BranchElement root = (BranchElement) rootElement; boolean updateStructure = true; if (prevCharIsLineBreak && ! lastCharIsLineBreak) { lineIndex = root.getElementIndex(offset - 1); Element prevLine = root.getElement(lineIndex); Element nextLine = root.getElement(lineIndex + 1); lineStart = prevLine.getStartOffset(); lineEnd = nextLine.getEndOffset(); removed = new Element[]{ prevLine, nextLine }; } else if (hasLineBreak) { lineIndex = root.getElementIndex(offset); Element line = root.getElement(lineIndex); lineStart = line.getStartOffset(); lineEnd = line.getEndOffset(); removed = new Element[]{ line };
protected void insertUpdate(DefaultDocumentEvent event, AttributeSet attributes) { int offset = event.getOffset(); int eventLength = event.getLength(); int end = offset + event.getLength(); int oldElementIndex, elementIndex = rootElement.getElementIndex(offset); Element firstElement = rootElement.getElement(elementIndex); oldElementIndex = elementIndex; // If we're inserting immediately after a newline we have to fix the // Element structure (but only if we are dealing with a line which // has not existed as Element before). if (offset > 0 && firstElement.getStartOffset() != offset) { try { String s = getText(offset - 1, 1); if (s.equals("\n") ) { int newEl2EndOffset = end; boolean replaceNext = false; if (rootElement.getElementCount() > elementIndex + 1) { replaceNext = true; newEl2EndOffset = rootElement.getElement(elementIndex + 1).getEndOffset(); } Element newEl1 = createLeafElement(rootElement, firstElement.getAttributes(), firstElement.getStartOffset(), offset); Element newEl2 = createLeafElement (rootElement, firstElement.getAttributes(), offset, newEl2EndOffset); if (replaceNext) rootElement.replace(elementIndex, 2, new Element[] { newEl1, newEl2 }); else rootElement.replace(elementIndex, 1, new Element[] { newEl1, newEl2 }); firstElement = newEl2; elementIndex ++; } } catch (BadLocationException ble) { // This shouldn't happen. AssertionError ae = new AssertionError(); ae.initCause(ble); throw ae; } } // added and removed are Element arrays used to add an ElementEdit // to the DocumentEvent if there were entire lines added or removed. Element[] removed = new Element[1]; Element[] added; try { String str = content.getString(offset, eventLength); ArrayList elts = new ArrayList(); // Determine how many NEW lines were added by finding the newline // characters within the newly inserted text int j = firstElement.getStartOffset(); int i = str.indexOf('\n', 0); int contentLength = content.length(); while (i != -1 && i <= eventLength) { // For each new line, create a new element elts.add(createLeafElement(rootElement, SimpleAttributeSet.EMPTY, j, offset + i + 1)); j = offset + i + 1; if (j >= contentLength) break; i = str.indexOf('\n', i + 1); } // If there were new lines added we have to add an ElementEdit to // the DocumentEvent and we have to call rootElement.replace to // insert the new lines if (elts.size() != 0) { // If we have created new lines test whether there are remaining // characters in firstElement after the inserted text and if so // create a new element for them. if (j < firstElement.getEndOffset()) elts.add(createLeafElement(rootElement, SimpleAttributeSet.EMPTY, j, firstElement.getEndOffset())); // Set up the ElementEdit by filling the added and removed // arrays with the proper Elements added = new Element[elts.size()]; elts.toArray(added); removed[0] = firstElement; // Now create and add the ElementEdit ElementEdit e = new ElementEdit(rootElement, elementIndex, removed, added); event.addEdit(e); // And call replace to actually make the changes ((BranchElement) rootElement).replace(elementIndex, 1, added); } } catch (BadLocationException e) { // This shouldn't happen so we throw an AssertionError AssertionError ae = new AssertionError(); ae.initCause(e); throw ae; } super.insertUpdate(event, attributes); }
Element[] removed = new Element[1]; Element[] added;
if (updateStructure) { ArrayList lines = new ArrayList(); int len = lineEnd - lineStart;
protected void insertUpdate(DefaultDocumentEvent event, AttributeSet attributes) { int offset = event.getOffset(); int eventLength = event.getLength(); int end = offset + event.getLength(); int oldElementIndex, elementIndex = rootElement.getElementIndex(offset); Element firstElement = rootElement.getElement(elementIndex); oldElementIndex = elementIndex; // If we're inserting immediately after a newline we have to fix the // Element structure (but only if we are dealing with a line which // has not existed as Element before). if (offset > 0 && firstElement.getStartOffset() != offset) { try { String s = getText(offset - 1, 1); if (s.equals("\n") ) { int newEl2EndOffset = end; boolean replaceNext = false; if (rootElement.getElementCount() > elementIndex + 1) { replaceNext = true; newEl2EndOffset = rootElement.getElement(elementIndex + 1).getEndOffset(); } Element newEl1 = createLeafElement(rootElement, firstElement.getAttributes(), firstElement.getStartOffset(), offset); Element newEl2 = createLeafElement (rootElement, firstElement.getAttributes(), offset, newEl2EndOffset); if (replaceNext) rootElement.replace(elementIndex, 2, new Element[] { newEl1, newEl2 }); else rootElement.replace(elementIndex, 1, new Element[] { newEl1, newEl2 }); firstElement = newEl2; elementIndex ++; } } catch (BadLocationException ble) { // This shouldn't happen. AssertionError ae = new AssertionError(); ae.initCause(ble); throw ae; } } // added and removed are Element arrays used to add an ElementEdit // to the DocumentEvent if there were entire lines added or removed. Element[] removed = new Element[1]; Element[] added; try { String str = content.getString(offset, eventLength); ArrayList elts = new ArrayList(); // Determine how many NEW lines were added by finding the newline // characters within the newly inserted text int j = firstElement.getStartOffset(); int i = str.indexOf('\n', 0); int contentLength = content.length(); while (i != -1 && i <= eventLength) { // For each new line, create a new element elts.add(createLeafElement(rootElement, SimpleAttributeSet.EMPTY, j, offset + i + 1)); j = offset + i + 1; if (j >= contentLength) break; i = str.indexOf('\n', i + 1); } // If there were new lines added we have to add an ElementEdit to // the DocumentEvent and we have to call rootElement.replace to // insert the new lines if (elts.size() != 0) { // If we have created new lines test whether there are remaining // characters in firstElement after the inserted text and if so // create a new element for them. if (j < firstElement.getEndOffset()) elts.add(createLeafElement(rootElement, SimpleAttributeSet.EMPTY, j, firstElement.getEndOffset())); // Set up the ElementEdit by filling the added and removed // arrays with the proper Elements added = new Element[elts.size()]; elts.toArray(added); removed[0] = firstElement; // Now create and add the ElementEdit ElementEdit e = new ElementEdit(rootElement, elementIndex, removed, added); event.addEdit(e); // And call replace to actually make the changes ((BranchElement) rootElement).replace(elementIndex, 1, added); } } catch (BadLocationException e) { // This shouldn't happen so we throw an AssertionError AssertionError ae = new AssertionError(); ae.initCause(e); throw ae; } super.insertUpdate(event, attributes); }
String str = content.getString(offset, eventLength); ArrayList elts = new ArrayList();
text = getText(lineStart, len); } catch (BadLocationException ex) { AssertionError err = new AssertionError(); err.initCause(ex); throw err; } int prevLineBreak = 0; int lineBreak = text.indexOf('\n'); do { lineBreak++; lines.add(createLeafElement(root, null, lineStart + prevLineBreak, lineStart + lineBreak)); prevLineBreak = lineBreak; lineBreak = text.indexOf('\n', prevLineBreak); } while (prevLineBreak < len);
protected void insertUpdate(DefaultDocumentEvent event, AttributeSet attributes) { int offset = event.getOffset(); int eventLength = event.getLength(); int end = offset + event.getLength(); int oldElementIndex, elementIndex = rootElement.getElementIndex(offset); Element firstElement = rootElement.getElement(elementIndex); oldElementIndex = elementIndex; // If we're inserting immediately after a newline we have to fix the // Element structure (but only if we are dealing with a line which // has not existed as Element before). if (offset > 0 && firstElement.getStartOffset() != offset) { try { String s = getText(offset - 1, 1); if (s.equals("\n") ) { int newEl2EndOffset = end; boolean replaceNext = false; if (rootElement.getElementCount() > elementIndex + 1) { replaceNext = true; newEl2EndOffset = rootElement.getElement(elementIndex + 1).getEndOffset(); } Element newEl1 = createLeafElement(rootElement, firstElement.getAttributes(), firstElement.getStartOffset(), offset); Element newEl2 = createLeafElement (rootElement, firstElement.getAttributes(), offset, newEl2EndOffset); if (replaceNext) rootElement.replace(elementIndex, 2, new Element[] { newEl1, newEl2 }); else rootElement.replace(elementIndex, 1, new Element[] { newEl1, newEl2 }); firstElement = newEl2; elementIndex ++; } } catch (BadLocationException ble) { // This shouldn't happen. AssertionError ae = new AssertionError(); ae.initCause(ble); throw ae; } } // added and removed are Element arrays used to add an ElementEdit // to the DocumentEvent if there were entire lines added or removed. Element[] removed = new Element[1]; Element[] added; try { String str = content.getString(offset, eventLength); ArrayList elts = new ArrayList(); // Determine how many NEW lines were added by finding the newline // characters within the newly inserted text int j = firstElement.getStartOffset(); int i = str.indexOf('\n', 0); int contentLength = content.length(); while (i != -1 && i <= eventLength) { // For each new line, create a new element elts.add(createLeafElement(rootElement, SimpleAttributeSet.EMPTY, j, offset + i + 1)); j = offset + i + 1; if (j >= contentLength) break; i = str.indexOf('\n', i + 1); } // If there were new lines added we have to add an ElementEdit to // the DocumentEvent and we have to call rootElement.replace to // insert the new lines if (elts.size() != 0) { // If we have created new lines test whether there are remaining // characters in firstElement after the inserted text and if so // create a new element for them. if (j < firstElement.getEndOffset()) elts.add(createLeafElement(rootElement, SimpleAttributeSet.EMPTY, j, firstElement.getEndOffset())); // Set up the ElementEdit by filling the added and removed // arrays with the proper Elements added = new Element[elts.size()]; elts.toArray(added); removed[0] = firstElement; // Now create and add the ElementEdit ElementEdit e = new ElementEdit(rootElement, elementIndex, removed, added); event.addEdit(e); // And call replace to actually make the changes ((BranchElement) rootElement).replace(elementIndex, 1, added); } } catch (BadLocationException e) { // This shouldn't happen so we throw an AssertionError AssertionError ae = new AssertionError(); ae.initCause(e); throw ae; } super.insertUpdate(event, attributes); }
int j = firstElement.getStartOffset(); int i = str.indexOf('\n', 0); int contentLength = content.length(); while (i != -1 && i <= eventLength) { elts.add(createLeafElement(rootElement, SimpleAttributeSet.EMPTY, j, offset + i + 1)); j = offset + i + 1; if (j >= contentLength) break; i = str.indexOf('\n', i + 1); } if (elts.size() != 0) { if (j < firstElement.getEndOffset()) elts.add(createLeafElement(rootElement, SimpleAttributeSet.EMPTY, j, firstElement.getEndOffset())); added = new Element[elts.size()]; elts.toArray(added); removed[0] = firstElement; ElementEdit e = new ElementEdit(rootElement, elementIndex, removed, added); event.addEdit(e); ((BranchElement) rootElement).replace(elementIndex, 1, added); }
Element[] added = (Element[]) lines.toArray(new Element[lines.size()]); event.addEdit(new ElementEdit(root, lineIndex, removed, added)); root.replace(lineIndex, removed.length, added);
protected void insertUpdate(DefaultDocumentEvent event, AttributeSet attributes) { int offset = event.getOffset(); int eventLength = event.getLength(); int end = offset + event.getLength(); int oldElementIndex, elementIndex = rootElement.getElementIndex(offset); Element firstElement = rootElement.getElement(elementIndex); oldElementIndex = elementIndex; // If we're inserting immediately after a newline we have to fix the // Element structure (but only if we are dealing with a line which // has not existed as Element before). if (offset > 0 && firstElement.getStartOffset() != offset) { try { String s = getText(offset - 1, 1); if (s.equals("\n") ) { int newEl2EndOffset = end; boolean replaceNext = false; if (rootElement.getElementCount() > elementIndex + 1) { replaceNext = true; newEl2EndOffset = rootElement.getElement(elementIndex + 1).getEndOffset(); } Element newEl1 = createLeafElement(rootElement, firstElement.getAttributes(), firstElement.getStartOffset(), offset); Element newEl2 = createLeafElement (rootElement, firstElement.getAttributes(), offset, newEl2EndOffset); if (replaceNext) rootElement.replace(elementIndex, 2, new Element[] { newEl1, newEl2 }); else rootElement.replace(elementIndex, 1, new Element[] { newEl1, newEl2 }); firstElement = newEl2; elementIndex ++; } } catch (BadLocationException ble) { // This shouldn't happen. AssertionError ae = new AssertionError(); ae.initCause(ble); throw ae; } } // added and removed are Element arrays used to add an ElementEdit // to the DocumentEvent if there were entire lines added or removed. Element[] removed = new Element[1]; Element[] added; try { String str = content.getString(offset, eventLength); ArrayList elts = new ArrayList(); // Determine how many NEW lines were added by finding the newline // characters within the newly inserted text int j = firstElement.getStartOffset(); int i = str.indexOf('\n', 0); int contentLength = content.length(); while (i != -1 && i <= eventLength) { // For each new line, create a new element elts.add(createLeafElement(rootElement, SimpleAttributeSet.EMPTY, j, offset + i + 1)); j = offset + i + 1; if (j >= contentLength) break; i = str.indexOf('\n', i + 1); } // If there were new lines added we have to add an ElementEdit to // the DocumentEvent and we have to call rootElement.replace to // insert the new lines if (elts.size() != 0) { // If we have created new lines test whether there are remaining // characters in firstElement after the inserted text and if so // create a new element for them. if (j < firstElement.getEndOffset()) elts.add(createLeafElement(rootElement, SimpleAttributeSet.EMPTY, j, firstElement.getEndOffset())); // Set up the ElementEdit by filling the added and removed // arrays with the proper Elements added = new Element[elts.size()]; elts.toArray(added); removed[0] = firstElement; // Now create and add the ElementEdit ElementEdit e = new ElementEdit(rootElement, elementIndex, removed, added); event.addEdit(e); // And call replace to actually make the changes ((BranchElement) rootElement).replace(elementIndex, 1, added); } } catch (BadLocationException e) { // This shouldn't happen so we throw an AssertionError AssertionError ae = new AssertionError(); ae.initCause(e); throw ae; } super.insertUpdate(event, attributes); }
catch (BadLocationException e) { AssertionError ae = new AssertionError(); ae.initCause(e); throw ae; }
protected void insertUpdate(DefaultDocumentEvent event, AttributeSet attributes) { int offset = event.getOffset(); int eventLength = event.getLength(); int end = offset + event.getLength(); int oldElementIndex, elementIndex = rootElement.getElementIndex(offset); Element firstElement = rootElement.getElement(elementIndex); oldElementIndex = elementIndex; // If we're inserting immediately after a newline we have to fix the // Element structure (but only if we are dealing with a line which // has not existed as Element before). if (offset > 0 && firstElement.getStartOffset() != offset) { try { String s = getText(offset - 1, 1); if (s.equals("\n") ) { int newEl2EndOffset = end; boolean replaceNext = false; if (rootElement.getElementCount() > elementIndex + 1) { replaceNext = true; newEl2EndOffset = rootElement.getElement(elementIndex + 1).getEndOffset(); } Element newEl1 = createLeafElement(rootElement, firstElement.getAttributes(), firstElement.getStartOffset(), offset); Element newEl2 = createLeafElement (rootElement, firstElement.getAttributes(), offset, newEl2EndOffset); if (replaceNext) rootElement.replace(elementIndex, 2, new Element[] { newEl1, newEl2 }); else rootElement.replace(elementIndex, 1, new Element[] { newEl1, newEl2 }); firstElement = newEl2; elementIndex ++; } } catch (BadLocationException ble) { // This shouldn't happen. AssertionError ae = new AssertionError(); ae.initCause(ble); throw ae; } } // added and removed are Element arrays used to add an ElementEdit // to the DocumentEvent if there were entire lines added or removed. Element[] removed = new Element[1]; Element[] added; try { String str = content.getString(offset, eventLength); ArrayList elts = new ArrayList(); // Determine how many NEW lines were added by finding the newline // characters within the newly inserted text int j = firstElement.getStartOffset(); int i = str.indexOf('\n', 0); int contentLength = content.length(); while (i != -1 && i <= eventLength) { // For each new line, create a new element elts.add(createLeafElement(rootElement, SimpleAttributeSet.EMPTY, j, offset + i + 1)); j = offset + i + 1; if (j >= contentLength) break; i = str.indexOf('\n', i + 1); } // If there were new lines added we have to add an ElementEdit to // the DocumentEvent and we have to call rootElement.replace to // insert the new lines if (elts.size() != 0) { // If we have created new lines test whether there are remaining // characters in firstElement after the inserted text and if so // create a new element for them. if (j < firstElement.getEndOffset()) elts.add(createLeafElement(rootElement, SimpleAttributeSet.EMPTY, j, firstElement.getEndOffset())); // Set up the ElementEdit by filling the added and removed // arrays with the proper Elements added = new Element[elts.size()]; elts.toArray(added); removed[0] = firstElement; // Now create and add the ElementEdit ElementEdit e = new ElementEdit(rootElement, elementIndex, removed, added); event.addEdit(e); // And call replace to actually make the changes ((BranchElement) rootElement).replace(elementIndex, 1, added); } } catch (BadLocationException e) { // This shouldn't happen so we throw an AssertionError AssertionError ae = new AssertionError(); ae.initCause(e); throw ae; } super.insertUpdate(event, attributes); }
rootElement.replace(i1, i2 - i1 + 1, added);
((BranchElement) rootElement).replace(i1, i2 - i1 + 1, added);
protected void removeUpdate(DefaultDocumentEvent event) { super.removeUpdate(event); // added and removed are Element arrays used to add an ElementEdit // to the DocumentEvent if there were entire lines added or removed // from the Document Element[] added = new Element[1]; Element[] removed; int p0 = event.getOffset(); // check if we must collapse some elements int i1 = rootElement.getElementIndex(p0); int i2 = rootElement.getElementIndex(p0 + event.getLength()); if (i1 != i2) { // If there were lines removed then we have to add an ElementEdit // to the DocumentEvent so we set it up now by filling the Element // arrays "removed" and "added" appropriately removed = new Element [i2 - i1 + 1]; for (int i = i1; i <= i2; i++) removed[i-i1] = rootElement.getElement(i); int start = rootElement.getElement(i1).getStartOffset(); int end = rootElement.getElement(i2).getEndOffset(); added[0] = createLeafElement(rootElement, SimpleAttributeSet.EMPTY, start, end); // Now create and add the ElementEdit ElementEdit e = new ElementEdit(rootElement, i1, removed, added); event.addEdit(e); // collapse elements if the removal spans more than 1 line rootElement.replace(i1, i2 - i1 + 1, added); } }
ProtectionDomain protDomain) { ByteBuffer buffer = ByteBuffer.wrap(data, offset, length); VmType<?> vmType = LoadCompileService.defineClass(name, buffer, protDomain, loader.getVmClassLoader()); return vmType.asClass();
ProtectionDomain protDomain) { return loader.defineClass(name, data, offset, length, protDomain);
static Class defineClass(ClassLoader loader, String name, byte[] data, int offset, int length, ProtectionDomain protDomain) { ByteBuffer buffer = ByteBuffer.wrap(data, offset, length); VmType<?> vmType = LoadCompileService.defineClass(name, buffer, protDomain, loader.getVmClassLoader()); return vmType.asClass(); }
this.stackOffset = -1;
public IRBasicBlock( int startPC, int endPC, boolean startOfExceptionHandler) { super(startPC, endPC, startOfExceptionHandler); this.predecessors = new BootableArrayList(); this.successors = new BootableArrayList(); this.phiReferences = new BootableArrayList(); }
attribOrder.add(0,"align"); attribOrder.add(0,"axisUnits"); attribOrder.add(0,"axisDatatype");
private void init() { classXDFNodeName = "axis"; // order matters! these are in *reverse* order of their // occurence in the XDF DTD attribOrder.add(0,"valueList"); attribOrder.add(0,"axisIdRef"); attribOrder.add(0,"axisId"); attribOrder.add(0,"align"); //not sure what it is??? attribOrder.add(0,"axisUnits"); attribOrder.add(0,"axisDatatype"); attribOrder.add(0,"description"); attribOrder.add(0,"name"); //set up the attribute hashtable key with the default initial value //set the minimum array size(essentially the size of the axis) attribHash.put("valueList", new XMLAttribute(Collections.synchronizedList(new ArrayList(super.sDefaultDataArraySize)), Constants.LIST_TYPE)); attribHash.put("axisIdRef", new XMLAttribute(null, Constants.STRING_TYPE)); attribHash.put("axisId", new XMLAttribute(null, Constants.STRING_TYPE)); attribHash.put("aligh", new XMLAttribute(null, Constants.STRING_TYPE)); //double check??? //set up the axisUnits attribute Units unitsObj = new Units(); attribHash.put("axisUnits", new XMLAttribute(unitsObj, Constants.OBJECT_TYPE)); unitsObj.setXDFNodeName("axisUnits"); attribHash.put("axisDatatype",new XMLAttribute(null, Constants.STRING_TYPE)); attribHash.put("description", new XMLAttribute(null, Constants.STRING_TYPE)); attribHash.put("name", new XMLAttribute(null, Constants.STRING_TYPE)); length = 0; }
attribHash.put("aligh", new XMLAttribute(null, Constants.STRING_TYPE));
attribHash.put("align", new XMLAttribute(null, Constants.STRING_TYPE));
private void init() { classXDFNodeName = "axis"; // order matters! these are in *reverse* order of their // occurence in the XDF DTD attribOrder.add(0,"valueList"); attribOrder.add(0,"axisIdRef"); attribOrder.add(0,"axisId"); attribOrder.add(0,"align"); //not sure what it is??? attribOrder.add(0,"axisUnits"); attribOrder.add(0,"axisDatatype"); attribOrder.add(0,"description"); attribOrder.add(0,"name"); //set up the attribute hashtable key with the default initial value //set the minimum array size(essentially the size of the axis) attribHash.put("valueList", new XMLAttribute(Collections.synchronizedList(new ArrayList(super.sDefaultDataArraySize)), Constants.LIST_TYPE)); attribHash.put("axisIdRef", new XMLAttribute(null, Constants.STRING_TYPE)); attribHash.put("axisId", new XMLAttribute(null, Constants.STRING_TYPE)); attribHash.put("aligh", new XMLAttribute(null, Constants.STRING_TYPE)); //double check??? //set up the axisUnits attribute Units unitsObj = new Units(); attribHash.put("axisUnits", new XMLAttribute(unitsObj, Constants.OBJECT_TYPE)); unitsObj.setXDFNodeName("axisUnits"); attribHash.put("axisDatatype",new XMLAttribute(null, Constants.STRING_TYPE)); attribHash.put("description", new XMLAttribute(null, Constants.STRING_TYPE)); attribHash.put("name", new XMLAttribute(null, Constants.STRING_TYPE)); length = 0; }
throw new BAD_OPERATION("Invalid enumeration code " + code);
BAD_OPERATION bad = new BAD_OPERATION("Invalid policy code " + code); bad.minor = Minor.PolicyType; throw bad;
public static ImplicitActivationPolicyValue from_int(int code) { try { return enume [ code ]; } catch (ArrayIndexOutOfBoundsException ex) { throw new BAD_OPERATION("Invalid enumeration code " + code); } }
if (axis instanceof FieldAxis) { setFieldAxis((FieldAxis) axis); } else if (canAddAxisObjToArray((Axis) axis)) { getAxes().add((Axis) axis); updateChildLocators((Axis) axis, "add"); updateNotesLocationOrder();
if (canAddAxisObjToArray(axis)) { if (axis instanceof FieldAxis) { setFieldAxis((FieldAxis) axis); } else { getAxes().add((Axis) axis); updateChildLocators((Axis) axis, "add"); updateNotesLocationOrder(); getXMLDataIOStyle().getIOAxesOrder().add(axis); } getXMLDataIOStyle().getIOAxesOrder().add(axis);
public AxisInterface addAxis(AxisInterface axis) { if (axis instanceof FieldAxis) { setFieldAxis((FieldAxis) axis); } else if (canAddAxisObjToArray((Axis) axis)) { //check if the axis can be added// getDataCube().incrementDimension((Axis) axis); //increment the DataCube dimension by 1 getAxes().add((Axis) axis); updateChildLocators((Axis) axis, "add"); updateNotesLocationOrder(); // reset to the current order of the axes } else { return null; } return axis; }
List axisList = getAxes(); if (axisList.size() == 0 || !this.hasFieldAxis() ){ return null; } Object axisObj = axisList.get(0); if (axisObj instanceof FieldAxis) return (FieldAxis) axisObj; else return null;
FieldAxis fieldAxis = null; if (hasFieldAxis) { List axisList = getAxes(); Iterator iter = axisList.iterator(); while (iter.hasNext()) { Object axis = (Object) iter.next(); if (axis instanceof FieldAxis) { return (FieldAxis) axis; } } } return fieldAxis;
public FieldAxis getFieldAxis() { List axisList = getAxes(); if (axisList.size() == 0 || !this.hasFieldAxis() ){ //empty axisList or lacks field Axis return null; } Object axisObj = axisList.get(0); if (axisObj instanceof FieldAxis) return (FieldAxis) axisObj; else return null; }
attribHash.put(AXISLIST_XML_ATTRIBUTE_NAME, new XMLAttribute(Collections.synchronizedList(new ArrayList()), Constants.LIST_TYPE));
protected void init() { super.init(); classXDFNodeName = "array"; // order matters! these are in *reverse* order of their // occurence in the XDF DTD attribOrder.add(0, NOTES_XML_ATTRIBUTE_NAME); attribOrder.add(0, DATACUBE_XML_ATTRIBUTE_NAME); attribOrder.add(0, XMLDATAIOSTYLE_XML_ATTRIBUTE_NAME); attribOrder.add(0, AXISLIST_XML_ATTRIBUTE_NAME); attribOrder.add(0, DATAFORMAT_XML_ATTRIBUTE_NAME); attribOrder.add(0, UNITS_XML_ATTRIBUTE_NAME); attribOrder.add(0, PARAMETERLIST_XML_ATTRIBUTE_NAME); attribOrder.add(0, NODATAVALUE_XML_ATTRIBUTE_NAME); attribOrder.add(0, INFINITENEGATIVEVALUE_XML_ATTRIBUTE_NAME); attribOrder.add(0, INFINITEVALUE_XML_ATTRIBUTE_NAME); attribOrder.add(0, GREATERTHANOREQUALVALUE_XML_ATTRIBUTE_NAME); attribOrder.add(0, GREATERTHANVALUE_XML_ATTRIBUTE_NAME); attribOrder.add(0, LESSTHANOREQUALVALUE_XML_ATTRIBUTE_NAME); attribOrder.add(0, LESSTHANVALUE_XML_ATTRIBUTE_NAME); attribOrder.add(0, APPENDTO_XML_ATTRIBUTE_NAME); attribOrder.add(0, ID_XML_ATTRIBUTE_NAME); attribOrder.add(0, DESCRIPTION_XML_ATTRIBUTE_NAME); attribOrder.add(0, NAME_XML_ATTRIBUTE_NAME); //set up the attribute hashtable key with the default initial value attribHash.put(NOTES_XML_ATTRIBUTE_NAME, new XMLAttribute(new Notes(), Constants.OBJECT_TYPE)); attribHash.put(DATACUBE_XML_ATTRIBUTE_NAME, new XMLAttribute(new DataCube(this), Constants.OBJECT_TYPE)); //default is TaggedXMLDataIOStyle attribHash.put(XMLDATAIOSTYLE_XML_ATTRIBUTE_NAME, new XMLAttribute(new TaggedXMLDataIOStyle(this), Constants.OBJECT_TYPE)); attribHash.put(AXISLIST_XML_ATTRIBUTE_NAME, new XMLAttribute(Collections.synchronizedList(new ArrayList()), Constants.LIST_TYPE)); attribHash.put(DATAFORMAT_XML_ATTRIBUTE_NAME, new XMLAttribute(null, Constants.OBJECT_TYPE)); attribHash.put(UNITS_XML_ATTRIBUTE_NAME, new XMLAttribute(null, Constants.OBJECT_TYPE)); attribHash.put(PARAMETERLIST_XML_ATTRIBUTE_NAME, new XMLAttribute(Collections.synchronizedList(new ArrayList()), Constants.LIST_TYPE)); attribHash.put(NODATAVALUE_XML_ATTRIBUTE_NAME, new XMLAttribute(null, Constants.STRING_TYPE)); attribHash.put(INFINITENEGATIVEVALUE_XML_ATTRIBUTE_NAME, new XMLAttribute(null, Constants.STRING_TYPE)); attribHash.put(INFINITEVALUE_XML_ATTRIBUTE_NAME, new XMLAttribute(null, Constants.STRING_TYPE)); attribHash.put(GREATERTHANOREQUALVALUE_XML_ATTRIBUTE_NAME, new XMLAttribute(null, Constants.STRING_TYPE)); attribHash.put(GREATERTHANVALUE_XML_ATTRIBUTE_NAME, new XMLAttribute(null, Constants.STRING_TYPE)); attribHash.put(LESSTHANOREQUALVALUE_XML_ATTRIBUTE_NAME, new XMLAttribute(null, Constants.STRING_TYPE)); attribHash.put(LESSTHANVALUE_XML_ATTRIBUTE_NAME, new XMLAttribute(null, Constants.STRING_TYPE)); attribHash.put(APPENDTO_XML_ATTRIBUTE_NAME, new XMLAttribute(null, Constants.STRING_TYPE)); attribHash.put(ID_XML_ATTRIBUTE_NAME, new XMLAttribute(null, Constants.STRING_TYPE)); attribHash.put(DESCRIPTION_XML_ATTRIBUTE_NAME, new XMLAttribute(null, Constants.STRING_TYPE)); attribHash.put(NAME_XML_ATTRIBUTE_NAME, new XMLAttribute(null, Constants.STRING_TYPE)); };
boolean isRemoveSuccess = removeFromList(axisObj, getAxes(), AXISLIST_XML_ATTRIBUTE_NAME); if (isRemoveSuccess) { getDataCube().reset(); updateChildLocators(axisObj, "remove");
boolean isRemoveSuccess = false; if (axisObj instanceof FieldAxis) { isRemoveSuccess = setFieldAxis(null); } else { isRemoveSuccess = removeFromList(axisObj, getAxes(), AXISLIST_XML_ATTRIBUTE_NAME); if (isRemoveSuccess) { getDataCube().reset(); updateChildLocators(axisObj, "remove"); getXMLDataIOStyle().setIOAxesOrder(getAxes()); }
public boolean removeAxis (AxisInterface axisObj) { boolean isRemoveSuccess = removeFromList(axisObj, getAxes(), AXISLIST_XML_ATTRIBUTE_NAME); if (isRemoveSuccess) { //remove successful getDataCube().reset(); // reset data within the datacube updateChildLocators(axisObj, "remove"); } return isRemoveSuccess; }
addAxis((AxisInterface) iter.next());
{ AxisInterface axis = (AxisInterface) iter.next(); addAxis(axis); }
public void setAxisList (List axisList) { // remove the existing axes List oldAxisList = getAxes(); int lastindex = oldAxisList.size()-1; for (int i = lastindex; i >= 0; i--) { removeAxis(i); } //add new axes if (axisList != null && axisList.size() > 0) { Iterator iter = axisList.iterator(); while (iter.hasNext()) addAxis((AxisInterface) iter.next()); } }
if (!canAddAxisObjToArray(fieldAxis))
if (fieldAxis != null && !canAddAxisObjToArray(fieldAxis))
public boolean setFieldAxis (FieldAxis fieldAxis) { if (!canAddAxisObjToArray(fieldAxis)) return false; hasFieldAxis = false; if (getFieldAxis() != null) { // replace or removal List axisList = getAxes(); axisList.remove(0); if (fieldAxis != null) { axisList.add(0, fieldAxis); //replace the old fieldAxis with the new one hasFieldAxis = true; } } else { //add a fieldAxis where none prev existed. if (fieldAxis != null) { // only if we have something to add getAxes().add(0, fieldAxis);// getDataCube().incrementDimension(fieldAxis); // increment dimension hasFieldAxis = true; getDataCube().reset(); // reset data within the datacube // since we no longer can guarente internal ordering // as the field axis goes in slot "0". } } // IF we had an object, update the locators if (fieldAxis != null) { updateChildLocators(fieldAxis, "add"); } updateNotesLocationOrder(); // reset to the current order of the axes // may not be needed, but we do for all cases anyways //array doenst hold a dataformat anymore //each field along the fieldAxis should have dataformat // IF fieldAxis exists if (hasFieldAxis) { setDataFormat(null); } return true; }
hasFieldAxis = false;
public boolean setFieldAxis (FieldAxis fieldAxis) { if (!canAddAxisObjToArray(fieldAxis)) return false; hasFieldAxis = false; if (getFieldAxis() != null) { // replace or removal List axisList = getAxes(); axisList.remove(0); if (fieldAxis != null) { axisList.add(0, fieldAxis); //replace the old fieldAxis with the new one hasFieldAxis = true; } } else { //add a fieldAxis where none prev existed. if (fieldAxis != null) { // only if we have something to add getAxes().add(0, fieldAxis);// getDataCube().incrementDimension(fieldAxis); // increment dimension hasFieldAxis = true; getDataCube().reset(); // reset data within the datacube // since we no longer can guarente internal ordering // as the field axis goes in slot "0". } } // IF we had an object, update the locators if (fieldAxis != null) { updateChildLocators(fieldAxis, "add"); } updateNotesLocationOrder(); // reset to the current order of the axes // may not be needed, but we do for all cases anyways //array doenst hold a dataformat anymore //each field along the fieldAxis should have dataformat // IF fieldAxis exists if (hasFieldAxis) { setDataFormat(null); } return true; }
if (getFieldAxis() != null) { List axisList = getAxes(); axisList.remove(0); if (fieldAxis != null) { axisList.add(0, fieldAxis); hasFieldAxis = true; } } else { if (fieldAxis != null) { getAxes().add(0, fieldAxis); hasFieldAxis = true; getDataCube().reset(); }
if (hasFieldAxis) { FieldAxis removeAxis = null; if (fieldAxis != null) { removeAxis = (FieldAxis) getAxes().get(0); getAxes().set(0, fieldAxis); } else { removeAxis = (FieldAxis) getAxes().remove(0); hasFieldAxis = false; } int removeIndex = getXMLDataIOStyle().getIOAxesOrder().lastIndexOf(removeAxis); getXMLDataIOStyle().getIOAxesOrder().remove(removeIndex); if (fieldAxis != null) getXMLDataIOStyle().getIOAxesOrder().add(removeIndex, fieldAxis); } else { hasFieldAxis = true; getAxes().add(0, fieldAxis); getXMLDataIOStyle().getIOAxesOrder().add(fieldAxis);
public boolean setFieldAxis (FieldAxis fieldAxis) { if (!canAddAxisObjToArray(fieldAxis)) return false; hasFieldAxis = false; if (getFieldAxis() != null) { // replace or removal List axisList = getAxes(); axisList.remove(0); if (fieldAxis != null) { axisList.add(0, fieldAxis); //replace the old fieldAxis with the new one hasFieldAxis = true; } } else { //add a fieldAxis where none prev existed. if (fieldAxis != null) { // only if we have something to add getAxes().add(0, fieldAxis);// getDataCube().incrementDimension(fieldAxis); // increment dimension hasFieldAxis = true; getDataCube().reset(); // reset data within the datacube // since we no longer can guarente internal ordering // as the field axis goes in slot "0". } } // IF we had an object, update the locators if (fieldAxis != null) { updateChildLocators(fieldAxis, "add"); } updateNotesLocationOrder(); // reset to the current order of the axes // may not be needed, but we do for all cases anyways //array doenst hold a dataformat anymore //each field along the fieldAxis should have dataformat // IF fieldAxis exists if (hasFieldAxis) { setDataFormat(null); } return true; }
public String[] getAxisTags() { List axisList = getParentArray().getAxes(); int stop = axisList.size(); String[] tags = new String[stop]; String tag; String axisId; String tempTag;
public String[] getAxisTags () {
public String[] getAxisTags() { List axisList = getParentArray().getAxes(); int stop = axisList.size(); String[] tags = new String[stop]; String tag; String axisId; String tempTag; int counter = stop; for (int i = 0; i < stop; i++) { axisId = ((AxisInterface)axisList.get(i)).getAxisId(); counter--; tag = "d" + counter; //the default tag //should it exist, we use whats in the tag hash //otherwise we go with the default as singed above tempTag = (String) tagHash.get(axisId); if (tempTag!=null) tag = tempTag; tags[i] = tag; } return tags; }
int counter = stop; for (int i = 0; i < stop; i++) { axisId = ((AxisInterface)axisList.get(i)).getAxisId(); counter--; tag = "d" + counter; tempTag = (String) tagHash.get(axisId); if (tempTag!=null) tag = tempTag; tags[i] = tag; } return tags;
for (int i = 0; i < stop; i++) { tags[i] = "d" + i; } return tags;
public String[] getAxisTags() { List axisList = getParentArray().getAxes(); int stop = axisList.size(); String[] tags = new String[stop]; String tag; String axisId; String tempTag; int counter = stop; for (int i = 0; i < stop; i++) { axisId = ((AxisInterface)axisList.get(i)).getAxisId(); counter--; tag = "d" + counter; //the default tag //should it exist, we use whats in the tag hash //otherwise we go with the default as singed above tempTag = (String) tagHash.get(axisId); if (tempTag!=null) tag = tempTag; tags[i] = tag; } return tags; }
protected String removeAxisTag(String axisId) { return (String) getTagHash().remove(axisId);
protected String removeAxisTag (String axisId) { String tagName = (String) tagHash.remove(axisId); if (tagName != null) axisIdHash.remove(tagName); needToCheckAxisOrder = true; return tagName;
protected String removeAxisTag(String axisId) { return (String) getTagHash().remove(axisId); }
tagHash.put(axisId, tag); }
if (tag != null && tag.length() > 1 && tag.startsWith("d") ) { tagHash.put(axisId, tag); axisIdHash.put(tag, axisId); needToCheckAxisOrder = true; } else { Log.errorln("setAxisTag() got mal-formed tag string:"+tag+", cannot set."); } }
public void setAxisTag(String tag, String axisId) { //insert in hash table, return tag value tagHash.put(axisId, tag); }
"ctrl shift PAGE_UP", "scrollRightExtendSelection",
"ctrl shift PAGE_UP", "scrollLeftExtendSelection",
protected void initComponentDefaults(UIDefaults defaults) { Object[] uiDefaults; Color highLight = new Color(249, 247, 246); Color light = new Color(239, 235, 231); Color shadow = new Color(139, 136, 134); Color darkShadow = new Color(16, 16, 16); uiDefaults = new Object[] { "AbstractUndoableEdit.undoText", "Undo", "AbstractUndoableEdit.redoText", "Redo", "Button.background", new ColorUIResource(Color.LIGHT_GRAY), "Button.border", new UIDefaults.LazyValue() { public Object createValue(UIDefaults table) { return BasicBorders.getButtonBorder(); } }, "Button.darkShadow", new ColorUIResource(Color.BLACK), "Button.focusInputMap", new UIDefaults.LazyInputMap(new Object[] { "SPACE", "pressed", "released SPACE", "released" }), "Button.font", new FontUIResource("Dialog", Font.PLAIN, 12), "Button.foreground", new ColorUIResource(Color.BLACK), "Button.highlight", new ColorUIResource(Color.WHITE), "Button.light", new ColorUIResource(Color.LIGHT_GRAY), "Button.margin", new InsetsUIResource(2, 2, 2, 2), "Button.shadow", new ColorUIResource(Color.GRAY), "Button.textIconGap", new Integer(4), "Button.textShiftOffset", new Integer(0), "CheckBox.background", new ColorUIResource(new Color(204, 204, 204)), "CheckBox.border", new BorderUIResource.CompoundBorderUIResource(null, null), "CheckBox.focusInputMap", new UIDefaults.LazyInputMap(new Object[] { "SPACE", "pressed", "released SPACE", "released" }), "CheckBox.font", new FontUIResource("Dialog", Font.PLAIN, 12), "CheckBox.foreground", new ColorUIResource(darkShadow), "CheckBox.icon", new UIDefaults.LazyValue() { public Object createValue(UIDefaults def) { return BasicIconFactory.getCheckBoxIcon(); } }, "CheckBox.checkIcon", new UIDefaults.LazyValue() { public Object createValue(UIDefaults def) { return BasicIconFactory.getMenuItemCheckIcon(); } }, "CheckBox.margin",new InsetsUIResource(2, 2, 2, 2), "CheckBox.textIconGap", new Integer(4), "CheckBox.textShiftOffset", new Integer(0), "CheckBoxMenuItem.icon", new UIDefaults.LazyValue() { public Object createValue(UIDefaults def) { return BasicIconFactory.getCheckBoxIcon(); } }, "CheckBoxMenuItem.acceleratorFont", new FontUIResource("Dialog", Font.PLAIN, 12), "CheckBoxMenuItem.acceleratorForeground", new ColorUIResource(new Color(16, 16, 16)), "CheckBoxMenuItem.acceleratorSelectionForeground", new ColorUIResource(Color.white), "CheckBoxMenuItem.arrowIcon", BasicIconFactory.getMenuItemArrowIcon(), "CheckBoxMenuItem.background", new ColorUIResource(light), "CheckBoxMenuItem.border", new BasicBorders.MarginBorder(), "CheckBoxMenuItem.borderPainted", Boolean.FALSE, "CheckBoxMenuItem.checkIcon", new UIDefaults.LazyValue() { public Object createValue(UIDefaults def) { return BasicIconFactory.getMenuItemCheckIcon(); } }, "CheckBoxMenuItem.font", new FontUIResource("Dialog", Font.PLAIN, 12), "CheckBoxMenuItem.foreground", new ColorUIResource(darkShadow), "CheckBoxMenuItem.margin", new InsetsUIResource(2, 2, 2, 2), "CheckBoxMenuItem.selectionBackground", new ColorUIResource(Color.black), "CheckBoxMenuItem.selectionForeground", new ColorUIResource(Color.white), "ColorChooser.background", new ColorUIResource(light), "ColorChooser.cancelText", "Cancel", "ColorChooser.font", new FontUIResource("Dialog", Font.PLAIN, 12), "ColorChooser.foreground", new ColorUIResource(darkShadow), "ColorChooser.hsbBlueText", "B", "ColorChooser.hsbBrightnessText", "B", "ColorChooser.hsbGreenText", "G", "ColorChooser.hsbHueText", "H", "ColorChooser.hsbNameText", "HSB", "ColorChooser.hsbRedText", "R", "ColorChooser.hsbSaturationText", "S", "ColorChooser.okText", "OK", "ColorChooser.previewText", "Preview", "ColorChooser.resetText", "Reset", "ColorChooser.rgbBlueMnemonic", new Integer(66), "ColorChooser.rgbBlueText", "Blue", "ColorChooser.rgbGreenMnemonic", new Integer(71), "ColorChooser.rgbGreenText", "Green", "ColorChooser.rgbNameText", "RGB", "ColorChooser.rgbRedMnemonic", new Integer(82), "ColorChooser.rgbRedText", "Red", "ColorChooser.sampleText", "Sample Text Sample Text", "ColorChooser.swatchesDefaultRecentColor", new ColorUIResource(light), "ColorChooser.swatchesNameText", "Swatches", "ColorChooser.swatchesRecentSwatchSize", new Dimension(10, 10), "ColorChooser.swatchesRecentText", "Recent:", "ColorChooser.swatchesSwatchSize", new Dimension(10, 10), "ComboBox.ancestorInputMap", new UIDefaults.LazyInputMap(new Object[] { "ESCAPE", "hidePopup", "PAGE_UP", "pageUpPassThrough", "PAGE_DOWN", "pageDownPassThrough", "HOME", "homePassThrough", "END", "endPassThrough" }), "ComboBox.background", new ColorUIResource(light), "ComboBox.buttonBackground", new ColorUIResource(light), "ComboBox.buttonDarkShadow", new ColorUIResource(shadow), "ComboBox.buttonHighlight", new ColorUIResource(highLight), "ComboBox.buttonShadow", new ColorUIResource(shadow), "ComboBox.disabledBackground", new ColorUIResource(light), "ComboBox.disabledForeground", new ColorUIResource(Color.gray), "ComboBox.font", new FontUIResource("SansSerif", Font.PLAIN, 12), "ComboBox.foreground", new ColorUIResource(Color.black), "ComboBox.selectionBackground", new ColorUIResource(Color.black), "ComboBox.selectionForeground", new ColorUIResource(Color.white), "Desktop.ancestorInputMap", new UIDefaults.LazyInputMap(new Object[] { "KP_LEFT", "left", "KP_RIGHT", "right", "ctrl F5", "restore", "LEFT", "left", "ctrl alt F6", "selectNextFrame", "UP", "up", "ctrl F6", "selectNextFrame", "RIGHT", "right", "DOWN", "down", "ctrl F7", "move", "ctrl F8", "resize", "ESCAPE", "escape", "ctrl TAB", "selectNextFrame", "ctrl F9", "minimize", "KP_UP", "up", "ctrl F4", "close", "KP_DOWN", "down", "ctrl F10", "maximize", "ctrl alt shift F6","selectPreviousFrame" }), "Desktop.background", new ColorUIResource(0, 92, 92), "DesktopIcon.border", new BorderUIResource.CompoundBorderUIResource(null, null), "EditorPane.background", new ColorUIResource(Color.white), "EditorPane.border", new BasicBorders.MarginBorder(), "EditorPane.caretBlinkRate", new Integer(500), "EditorPane.caretForeground", new ColorUIResource(Color.black), "EditorPane.font", new FontUIResource("Serif", Font.PLAIN, 12), "EditorPane.foreground", new ColorUIResource(Color.black), "EditorPane.inactiveForeground", new ColorUIResource(Color.gray), "EditorPane.keyBindings", new JTextComponent.KeyBinding[] { new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_UP, 0), "caret-up"), new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_DOWN, 0), "caret-down"), new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_PAGE_UP, 0), "page-up"), new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_PAGE_DOWN, 0), "page-down"), new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_ENTER, 0), "insert-break"), new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_TAB, 0), "insert-tab") }, "EditorPane.margin", new InsetsUIResource(3, 3, 3, 3), "EditorPane.selectionBackground", new ColorUIResource(Color.black), "EditorPane.selectionForeground", new ColorUIResource(Color.white), "FileChooser.acceptAllFileFilterText", "All Files (*.*)", "FileChooser.ancestorInputMap", new UIDefaults.LazyInputMap(new Object[] { "ESCAPE", "cancelSelection" }), "FileChooser.cancelButtonMnemonic", new Integer(67), "FileChooser.cancelButtonText", "Cancel", "FileChooser.cancelButtonToolTipText", "Abort file chooser dialog", // XXX Don't use gif// "FileChooser.detailsViewIcon", new IconUIResource(new ImageIcon("icons/DetailsView.gif")), "FileChooser.directoryDescriptionText", "Directory", "FileChooser.fileDescriptionText", "Generic File", "FileChooser.helpButtonMnemonic", new Integer(72), "FileChooser.helpButtonText", "Help", "FileChooser.helpButtonToolTipText", "FileChooser help", // XXX Don't use gif// "FileChooser.homeFolderIcon", new IconUIResource(new ImageIcon("icons/HomeFolder.gif")), // XXX Don't use gif// "FileChooser.listViewIcon", new IconUIResource(new ImageIcon("icons/ListView.gif")), "FileChooser.newFolderErrorSeparator", ":", "FileChooser.newFolderErrorText", "Error creating new folder", // XXX Don't use gif// "FileChooser.newFolderIcon", new IconUIResource(new ImageIcon("icons/NewFolder.gif")), "FileChooser.openButtonMnemonic", new Integer(79), "FileChooser.openButtonText", "Open", "FileChooser.openButtonToolTipText", "Open selected file", "FileChooser.saveButtonMnemonic", new Integer(83), "FileChooser.saveButtonText", "Save", "FileChooser.saveButtonToolTipText", "Save selected file", // XXX Don't use gif// "FileChooser.upFolderIcon", new IconUIResource(new ImageIcon("icons/UpFolder.gif")), "FileChooser.updateButtonMnemonic", new Integer(85), "FileChooser.updateButtonText", "Update", "FileChooser.updateButtonToolTipText", "Update directory listing", // XXX Don't use gif// "FileView.computerIcon", new IconUIResource(new ImageIcon("icons/Computer.gif")), // XXX Don't use gif// "FileView.directoryIcon", new IconUIResource(new ImageIcon("icons/Directory.gif")), // XXX Don't use gif// "FileView.fileIcon", new IconUIResource(new ImageIcon("icons/File.gif")), // XXX Don't use gif// "FileView.floppyDriveIcon", new IconUIResource(new ImageIcon("icons/Floppy.gif")), // XXX Don't use gif// "FileView.hardDriveIcon", new IconUIResource(new ImageIcon("icons/HardDrive.gif")), "FocusManagerClassName", "TODO", "FormattedTextField.background", new ColorUIResource(light), "FormattedTextField.caretForeground", new ColorUIResource(Color.black), "FormattedTextField.foreground", new ColorUIResource(Color.black), "FormattedTextField.inactiveBackground", new ColorUIResource(light), "FormattedTextField.inactiveForeground", new ColorUIResource(Color.gray), "FormattedTextField.selectionBackground", new ColorUIResource(Color.black), "FormattedTextField.selectionForeground", new ColorUIResource(Color.white), "FormView.resetButtonText", "Reset", "FormView.submitButtonText", "Submit Query", "InternalFrame.activeTitleBackground", new ColorUIResource(0, 0, 128), "InternalFrame.activeTitleForeground", new ColorUIResource(Color.white), "InternalFrame.border", new UIDefaults.LazyValue() { public Object createValue(UIDefaults table) { Color lineColor = new Color(238, 238, 238); Border inner = BorderFactory.createLineBorder(lineColor, 1); Color shadowInner = new Color(184, 207, 229); Color shadowOuter = new Color(122, 138, 153); Border outer = BorderFactory.createBevelBorder(BevelBorder.RAISED, Color.WHITE, Color.WHITE, shadowOuter, shadowInner); Border border = new BorderUIResource.CompoundBorderUIResource(outer, inner); return border; } }, "InternalFrame.borderColor", new ColorUIResource(light), "InternalFrame.borderDarkShadow", new ColorUIResource(Color.BLACK), "InternalFrame.borderHighlight", new ColorUIResource(Color.WHITE), "InternalFrame.borderLight", new ColorUIResource(Color.LIGHT_GRAY), "InternalFrame.borderShadow", new ColorUIResource(Color.GRAY), "InternalFrame.closeIcon", BasicIconFactory.createEmptyFrameIcon(), // FIXME: Set a nice icon for InternalFrames here. "InternalFrame.icon", new UIDefaults.LazyValue() { public Object createValue(UIDefaults def) { return new IconUIResource(BasicIconFactory.createEmptyFrameIcon()); } }, "InternalFrame.iconifyIcon", BasicIconFactory.createEmptyFrameIcon(), "InternalFrame.inactiveTitleBackground", new ColorUIResource(Color.gray), "InternalFrame.inactiveTitleForeground", new ColorUIResource(Color.lightGray), "InternalFrame.maximizeIcon", BasicIconFactory.createEmptyFrameIcon(), "InternalFrame.minimizeIcon", BasicIconFactory.createEmptyFrameIcon(), "InternalFrame.titleFont", new FontUIResource("Dialog", Font.PLAIN, 12), "InternalFrame.windowBindings", new Object[] { "shift ESCAPE", "showSystemMenu", "ctrl SPACE", "showSystemMenu", "ESCAPE", "showSystemMenu" }, "Label.background", new ColorUIResource(light), "Label.disabledForeground", new ColorUIResource(Color.white), "Label.disabledShadow", new ColorUIResource(shadow), "Label.font", new FontUIResource("Dialog", Font.PLAIN, 12), "Label.foreground", new ColorUIResource(darkShadow), "List.background", new ColorUIResource(light), "List.border", new BasicBorders.MarginBorder(), "List.focusInputMap", new UIDefaults.LazyInputMap(new Object[] { "PAGE_UP", "scrollUp", "ctrl \\", "clearSelection", "PAGE_DOWN", "scrollDown", "shift PAGE_DOWN","scrollDownExtendSelection", "END", "selectLastRow", "HOME", "selectFirstRow", "shift END", "selectLastRowExtendSelection", "shift HOME", "selectFirstRowExtendSelection", "UP", "selectPreviousRow", "ctrl /", "selectAll", "ctrl A", "selectAll", "DOWN", "selectNextRow", "shift UP", "selectPreviousRowExtendSelection", "ctrl SPACE", "selectNextRowExtendSelection", "shift DOWN", "selectNextRowExtendSelection", "KP_UP", "selectPreviousRow", "shift PAGE_UP","scrollUpExtendSelection", "KP_DOWN", "selectNextRow" }), "List.foreground", new ColorUIResource(darkShadow), "List.selectionBackground", new ColorUIResource(Color.black), "List.selectionForeground", new ColorUIResource(Color.white), "List.focusCellHighlightBorder", new BorderUIResource. LineBorderUIResource(new ColorUIResource(Color.yellow)), "Menu.acceleratorFont", new FontUIResource("Dialog", Font.PLAIN, 12), "Menu.acceleratorForeground", new ColorUIResource(darkShadow), "Menu.acceleratorSelectionForeground", new ColorUIResource(Color.white), "Menu.arrowIcon", BasicIconFactory.getMenuArrowIcon(), "Menu.background", new ColorUIResource(light), "Menu.border", new BasicBorders.MarginBorder(), "Menu.borderPainted", Boolean.FALSE, "Menu.checkIcon", BasicIconFactory.getMenuItemCheckIcon(), "Menu.consumesTabs", Boolean.TRUE, "Menu.font", new FontUIResource("Dialog", Font.PLAIN, 12), "Menu.foreground", new ColorUIResource(darkShadow), "Menu.margin", new InsetsUIResource(2, 2, 2, 2), "Menu.selectedWindowInputMapBindings", new Object[] { "ESCAPE", "cancel", "DOWN", "selectNext", "KP_DOWN", "selectNext", "UP", "selectPrevious", "KP_UP", "selectPrevious", "LEFT", "selectParent", "KP_LEFT", "selectParent", "RIGHT", "selectChild", "KP_RIGHT", "selectChild", "ENTER", "return", "SPACE", "return" }, "Menu.selectionBackground", new ColorUIResource(Color.black), "Menu.selectionForeground", new ColorUIResource(Color.white), "MenuBar.background", new ColorUIResource(light), "MenuBar.border", new BasicBorders.MenuBarBorder(null, null), "MenuBar.font", new FontUIResource("Dialog", Font.PLAIN, 12), "MenuBar.foreground", new ColorUIResource(darkShadow), "MenuBar.highlight", new ColorUIResource(highLight), "MenuBar.shadow", new ColorUIResource(shadow), "MenuBar.windowBindings", new Object[] { "F10", "takeFocus" }, "MenuItem.acceleratorDelimiter", "-", "MenuItem.acceleratorFont", new FontUIResource("Dialog", Font.PLAIN, 12), "MenuItem.acceleratorForeground", new ColorUIResource(darkShadow), "MenuItem.acceleratorSelectionForeground", new ColorUIResource(Color.white), "MenuItem.arrowIcon", BasicIconFactory.getMenuItemArrowIcon(), "MenuItem.background", new ColorUIResource(light), "MenuItem.border", new BasicBorders.MarginBorder(), "MenuItem.borderPainted", Boolean.FALSE, "MenuItem.checkIcon", BasicIconFactory.getMenuItemCheckIcon(), "MenuItem.font", new FontUIResource("Dialog", Font.PLAIN, 12), "MenuItem.foreground", new ColorUIResource(darkShadow), "MenuItem.margin", new InsetsUIResource(2, 2, 2, 2), "MenuItem.selectionBackground", new ColorUIResource(Color.black), "MenuItem.selectionForeground", new ColorUIResource(Color.white), "OptionPane.background", new ColorUIResource(light), "OptionPane.border", new BorderUIResource.EmptyBorderUIResource(0, 0, 0, 0), "OptionPane.buttonAreaBorder", new BorderUIResource.EmptyBorderUIResource(0, 0, 0, 0), "OptionPane.cancelButtonText", "Cancel", // XXX Don't use gif// "OptionPane.errorIcon",// new IconUIResource(new ImageIcon("icons/Error.gif")), "OptionPane.font", new FontUIResource("Dialog", Font.PLAIN, 12), "OptionPane.foreground", new ColorUIResource(darkShadow), // XXX Don't use gif// "OptionPane.informationIcon",// new IconUIResource(new ImageIcon("icons/Inform.gif")), "OptionPane.messageAreaBorder", new BorderUIResource.EmptyBorderUIResource(0, 0, 0, 0), "OptionPane.messageForeground", new ColorUIResource(darkShadow), "OptionPane.minimumSize", new DimensionUIResource(262, 90), "OptionPane.noButtonText", "No", "OptionPane.okButtonText", "OK", // XXX Don't use gif// "OptionPane.questionIcon",// new IconUIResource(new ImageIcon("icons/Question.gif")), // XXX Don't use gif// "OptionPane.warningIcon",// new IconUIResource(new ImageIcon("icons/Warn.gif")), "OptionPane.windowBindings", new Object[] { "ESCAPE", "close" }, "OptionPane.yesButtonText", "Yes", "Panel.background", new ColorUIResource(light), "Panel.font", new FontUIResource("Dialog", Font.PLAIN, 12), "Panel.foreground", new ColorUIResource(Color.black), "PasswordField.background", new ColorUIResource(light), "PasswordField.border", new BasicBorders.FieldBorder(null, null, null, null), "PasswordField.caretBlinkRate", new Integer(500), "PasswordField.caretForeground", new ColorUIResource(Color.black), "PasswordField.font", new FontUIResource("MonoSpaced", Font.PLAIN, 12), "PasswordField.foreground", new ColorUIResource(Color.black), "PasswordField.inactiveBackground", new ColorUIResource(light), "PasswordField.inactiveForeground", new ColorUIResource(Color.gray), "PasswordField.keyBindings", new JTextComponent.KeyBinding[] { new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_ENTER, 0), "notify-field-accept")}, "PasswordField.margin", new InsetsUIResource(0, 0, 0, 0), "PasswordField.selectionBackground", new ColorUIResource(Color.black), "PasswordField.selectionForeground", new ColorUIResource(Color.white), "PopupMenu.background", new ColorUIResource(light), "PopupMenu.border", new BorderUIResource.BevelBorderUIResource(0), "PopupMenu.font", new FontUIResource("Dialog", Font.PLAIN, 12), "PopupMenu.foreground", new ColorUIResource(darkShadow), "ProgressBar.background", new ColorUIResource(light), "ProgressBar.border", new BorderUIResource.LineBorderUIResource(Color.darkGray), "ProgressBar.cellLength", new Integer(1), "ProgressBar.cellSpacing", new Integer(0), "ProgressBar.font", new FontUIResource("Dialog", Font.PLAIN, 12), "ProgressBar.foreground", new ColorUIResource(Color.black), "ProgressBar.selectionBackground", new ColorUIResource(Color.black), "ProgressBar.selectionForeground", new ColorUIResource(light), "ProgressBar.repaintInterval", new Integer(250), "ProgressBar.cycleTime", new Integer(6000), "RadioButton.background", new ColorUIResource(light), "RadioButton.border", new BorderUIResource.CompoundBorderUIResource(null, null), "RadioButton.darkShadow", new ColorUIResource(shadow), "RadioButton.focusInputMap", new UIDefaults.LazyInputMap(new Object[] { "SPACE", "pressed", "released SPACE", "released" }), "RadioButton.font", new FontUIResource("Dialog", Font.PLAIN, 12), "RadioButton.foreground", new ColorUIResource(darkShadow), "RadioButton.highlight", new ColorUIResource(highLight), "RadioButton.icon", new UIDefaults.LazyValue() { public Object createValue(UIDefaults def) { return BasicIconFactory.getRadioButtonIcon(); } }, "RadioButton.light", new ColorUIResource(highLight), "RadioButton.margin", new InsetsUIResource(2, 2, 2, 2), "RadioButton.shadow", new ColorUIResource(shadow), "RadioButton.textIconGap", new Integer(4), "RadioButton.textShiftOffset", new Integer(0), "RadioButtonMenuItem.acceleratorFont", new FontUIResource("Dialog", Font.PLAIN, 12), "RadioButtonMenuItem.acceleratorForeground", new ColorUIResource(darkShadow), "RadioButtonMenuItem.acceleratorSelectionForeground", new ColorUIResource(Color.white), "RadioButtonMenuItem.arrowIcon", BasicIconFactory.getMenuItemArrowIcon(), "RadioButtonMenuItem.background", new ColorUIResource(light), "RadioButtonMenuItem.border", new BasicBorders.MarginBorder(), "RadioButtonMenuItem.borderPainted", Boolean.FALSE, "RadioButtonMenuItem.checkIcon", BasicIconFactory.getRadioButtonMenuItemIcon(), "RadioButtonMenuItem.font", new FontUIResource("Dialog", Font.PLAIN, 12), "RadioButtonMenuItem.foreground", new ColorUIResource(darkShadow), "RadioButtonMenuItem.margin", new InsetsUIResource(2, 2, 2, 2), "RadioButtonMenuItem.selectionBackground", new ColorUIResource(Color.black), "RadioButtonMenuItem.selectionForeground", new ColorUIResource(Color.white), "RootPane.defaultButtonWindowKeyBindings", new Object[] { "ENTER", "press", "released ENTER", "release", "ctrl ENTER", "press", "ctrl released ENTER", "release" }, "ScrollBar.background", new ColorUIResource(224, 224, 224), "ScrollBar.focusInputMap", new UIDefaults.LazyInputMap(new Object[] { "PAGE_UP", "negativeBlockIncrement", "PAGE_DOWN", "positiveBlockIncrement", "END", "maxScroll", "HOME", "minScroll", "LEFT", "positiveUnitIncrement", "KP_UP", "negativeUnitIncrement", "KP_DOWN", "positiveUnitIncrement", "UP", "negativeUnitIncrement", "RIGHT", "negativeUnitIncrement", "KP_LEFT", "positiveUnitIncrement", "DOWN", "positiveUnitIncrement", "KP_RIGHT", "negativeUnitIncrement" }), "ScrollBar.foreground", new ColorUIResource(light), "ScrollBar.maximumThumbSize", new DimensionUIResource(4096, 4096), "ScrollBar.minimumThumbSize", new DimensionUIResource(8, 8), "ScrollBar.thumb", new ColorUIResource(light), "ScrollBar.thumbDarkShadow", new ColorUIResource(shadow), "ScrollBar.thumbHighlight", new ColorUIResource(highLight), "ScrollBar.thumbShadow", new ColorUIResource(shadow), "ScrollBar.track", new ColorUIResource(light), "ScrollBar.trackHighlight", new ColorUIResource(shadow), "ScrollPane.ancestorInputMap", new UIDefaults.LazyInputMap(new Object[] { "PAGE_UP", "scrollUp", "KP_LEFT", "unitScrollLeft", "ctrl PAGE_DOWN","scrollRight", "PAGE_DOWN", "scrollDown", "KP_RIGHT", "unitScrollRight", "LEFT", "unitScrollLeft", "ctrl END", "scrollEnd", "UP", "unitScrollUp", "RIGHT", "unitScrollRight", "DOWN", "unitScrollDown", "ctrl HOME", "scrollHome", "ctrl PAGE_UP", "scrollLeft", "KP_UP", "unitScrollUp", "KP_DOWN", "unitScrollDown" }), "ScrollPane.background", new ColorUIResource(light), "ScrollPane.border", new BorderUIResource.EtchedBorderUIResource(), "ScrollPane.font", new FontUIResource("Dialog", Font.PLAIN, 12), "ScrollPane.foreground", new ColorUIResource(darkShadow), "Separator.background", new ColorUIResource(highLight), "Separator.foreground", new ColorUIResource(shadow), "Separator.highlight", new ColorUIResource(highLight), "Separator.shadow", new ColorUIResource(shadow), "Slider.background", new ColorUIResource(light), "Slider.focus", new ColorUIResource(shadow), "Slider.focusInputMap", new UIDefaults.LazyInputMap(new Object[] { "PAGE_UP", "positiveBlockIncrement", "PAGE_DOWN", "negativeBlockIncrement", "END", "maxScroll", "HOME", "minScroll", "LEFT", "negativeUnitIncrement", "KP_UP", "positiveUnitIncrement", "KP_DOWN", "negativeUnitIncrement", "UP", "positiveUnitIncrement", "RIGHT", "positiveUnitIncrement", "KP_LEFT", "negativeUnitIncrement", "DOWN", "negativeUnitIncrement", "KP_RIGHT", "positiveUnitIncrement" }), "Slider.focusInsets", new InsetsUIResource(2, 2, 2, 2), "Slider.foreground", new ColorUIResource(light), "Slider.highlight", new ColorUIResource(highLight), "Slider.shadow", new ColorUIResource(shadow), "Slider.thumbHeight", new Integer(20), "Slider.thumbWidth", new Integer(11), "Slider.tickHeight", new Integer(12), "Spinner.background", new ColorUIResource(light), "Spinner.foreground", new ColorUIResource(light), "SplitPane.ancestorInputMap", new UIDefaults.LazyInputMap(new Object[] { "F6", "toggleFocus", "F8", "startResize", "END", "selectMax", "HOME", "selectMin", "LEFT", "negativeIncremnent", "KP_UP", "negativeIncrement", "KP_DOWN", "positiveIncrement", "UP", "negativeIncrement", "RIGHT", "positiveIncrement", "KP_LEFT", "negativeIncrement", "DOWN", "positiveIncrement", "KP_RIGHT", "positiveIncrement" }), "SplitPane.background", new ColorUIResource(light), "SplitPane.border", new BasicBorders.SplitPaneBorder(null, null), "SplitPane.darkShadow", new ColorUIResource(shadow), "SplitPane.dividerSize", new Integer(10), "SplitPane.highlight", new ColorUIResource(highLight), "SplitPane.shadow", new ColorUIResource(shadow), "TabbedPane.ancestorInputMap", new UIDefaults.LazyInputMap(new Object[] { "ctrl PAGE_DOWN","navigatePageDown", "ctrl PAGE_UP", "navigatePageUp", "ctrl UP", "requestFocus", "ctrl KP_UP", "requestFocus" }), "TabbedPane.background", new ColorUIResource(light), "TabbedPane.contentBorderInsets", new InsetsUIResource(2, 2, 3, 3), "TabbedPane.darkShadow", new ColorUIResource(shadow), "TabbedPane.focus", new ColorUIResource(darkShadow), "TabbedPane.focusInputMap", new UIDefaults.LazyInputMap(new Object[] { "LEFT", "navigateLeft", "KP_UP", "navigateUp", "ctrl DOWN", "requestFocusForVisibleComponent", "UP", "navigateUp", "KP_DOWN", "navigateDown", "RIGHT", "navigateRight", "KP_LEFT", "navigateLeft", "ctrl KP_DOWN", "requestFocusForVisibleComponent", "KP_RIGHT", "navigateRight", "DOWN", "navigateDown" }), "TabbedPane.font", new FontUIResource("Dialog", Font.PLAIN, 12), "TabbedPane.foreground", new ColorUIResource(darkShadow), "TabbedPane.highlight", new ColorUIResource(highLight), "TabbedPane.light", new ColorUIResource(highLight), "TabbedPane.selectedTabPadInsets", new InsetsUIResource(2, 2, 2, 1), "TabbedPane.shadow", new ColorUIResource(shadow), "TabbedPane.tabbedPaneTabAreaInsets", new InsetsUIResource(3, 2, 1, 2), "TabbedPane.tabbedPaneTabInsets", new InsetsUIResource(1, 4, 1, 4), "TabbedPane.tabbedPaneContentBorderInsets", new InsetsUIResource(3, 2, 1, 2), "TabbedPane.tabbedPaneTabPadInsets", new InsetsUIResource(1, 1, 1, 1), "TabbedPane.tabRunOverlay", new Integer(2), "TabbedPane.textIconGap", new Integer(4), "Table.ancestorInputMap", new UIDefaults.LazyInputMap(new Object[] { "shift PAGE_DOWN","scrollDownExtendSelection", "PAGE_DOWN", "scrollDownChangeSelection", "END", "selectLastColumn", "shift END", "selectLastColumnExtendSelection", "HOME", "selectFirstColumn", "ctrl END", "selectLastRow", "ctrl shift END","selectLastRowExtendSelection", "LEFT", "selectPreviousColumn", "shift HOME", "selectFirstColumnExtendSelection", "UP", "selectPreviousRow", "RIGHT", "selectNextColumn", "ctrl HOME", "selectFirstRow", "shift LEFT", "selectPreviousColumnExtendSelection", "DOWN", "selectNextRow", "ctrl shift HOME","selectFirstRowExtendSelection", "shift UP", "selectPreviousRowExtendSelection", "F2", "startEditing", "shift RIGHT", "selectNextColumnExtendSelection", "TAB", "selectNextColumnCell", "shift DOWN", "selectNextRowExtendSelection", "ENTER", "selectNextRowCell", "KP_UP", "selectPreviousRow", "KP_DOWN", "selectNextRow", "KP_LEFT", "selectPreviousColumn", "KP_RIGHT", "selectNextColumn", "shift TAB", "selectPreviousColumnCell", "ctrl A", "selectAll", "shift ENTER", "selectPreviousRowCell", "shift KP_DOWN", "selectNextRowExtendSelection", "shift KP_LEFT", "selectPreviousColumnExtendSelection", "ESCAPE", "cancel", "ctrl shift PAGE_UP", "scrollRightExtendSelection", "shift KP_RIGHT", " selectNextColumnExtendSelection", "ctrl PAGE_UP", "scrollLeftChangeSelection", "shift PAGE_UP", "scrollUpExtendSelection", "ctrl shift PAGE_DOWN", "scrollLeftExtendSelection", "ctrl PAGE_DOWN", "scrollRightChangeSelection", "PAGE_UP", "scrollUpChangeSelection" }), "Table.background", new ColorUIResource(light), "Table.focusCellBackground", new ColorUIResource(light), "Table.focusCellForeground", new ColorUIResource(darkShadow), "Table.focusCellHighlightBorder", new BorderUIResource.LineBorderUIResource( new ColorUIResource(255, 255, 0)), "Table.font", new FontUIResource("Dialog", Font.PLAIN, 12), "Table.foreground", new ColorUIResource(darkShadow), "Table.gridColor", new ColorUIResource(Color.gray), "Table.scrollPaneBorder", new BorderUIResource.BevelBorderUIResource(0), "Table.selectionBackground", new ColorUIResource(Color.black), "Table.selectionForeground", new ColorUIResource(Color.white), "TableHeader.background", new ColorUIResource(light), "TableHeader.cellBorder", new BorderUIResource.BevelBorderUIResource(0), "TableHeader.font", new FontUIResource("Dialog", Font.PLAIN, 12), "TableHeader.foreground", new ColorUIResource(darkShadow), "TextArea.background", new ColorUIResource(light), "TextArea.border", new BasicBorders.MarginBorder(), "TextArea.caretBlinkRate", new Integer(500), "TextArea.caretForeground", new ColorUIResource(Color.black), "TextArea.font", new FontUIResource("MonoSpaced", Font.PLAIN, 12), "TextArea.foreground", new ColorUIResource(Color.black), "TextArea.inactiveForeground", new ColorUIResource(Color.gray), "TextArea.keyBindings", new JTextComponent.KeyBinding[] { new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_UP, 0), "caret-up"), new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_DOWN, 0), "caret-down"), new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_PAGE_UP, 0), "page-up"), new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_PAGE_DOWN, 0), "page-down"), new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_ENTER, 0), "insert-break"), new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_TAB, 0), "insert-tab") }, "TextArea.margin", new InsetsUIResource(0, 0, 0, 0), "TextArea.selectionBackground", new ColorUIResource(Color.black), "TextArea.selectionForeground", new ColorUIResource(Color.white), "TextField.background", new ColorUIResource(light), "TextField.border", new BasicBorders.FieldBorder(null, null, null, null), "TextField.caretBlinkRate", new Integer(500), "TextField.caretForeground", new ColorUIResource(Color.black), "TextField.darkShadow", new ColorUIResource(shadow), "TextField.font", new FontUIResource("SansSerif", Font.PLAIN, 12), "TextField.foreground", new ColorUIResource(Color.black), "TextField.highlight", new ColorUIResource(highLight), "TextField.inactiveBackground", new ColorUIResource(light), "TextField.inactiveForeground", new ColorUIResource(Color.gray), "TextField.light", new ColorUIResource(highLight), "TextField.highlight", new ColorUIResource(light), "TextField.keyBindings", new JTextComponent.KeyBinding[] { new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_ENTER, 0), "notify-field-accept"), new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_LEFT, InputEvent.SHIFT_DOWN_MASK), "selection-backward"), new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_RIGHT, InputEvent.SHIFT_DOWN_MASK), "selection-forward"), }, "TextField.margin", new InsetsUIResource(0, 0, 0, 0), "TextField.selectionBackground", new ColorUIResource(Color.black), "TextField.selectionForeground", new ColorUIResource(Color.white), "TextPane.background", new ColorUIResource(Color.white), "TextPane.border", new BasicBorders.MarginBorder(), "TextPane.caretBlinkRate", new Integer(500), "TextPane.caretForeground", new ColorUIResource(Color.black), "TextPane.font", new FontUIResource("Serif", Font.PLAIN, 12), "TextPane.foreground", new ColorUIResource(Color.black), "TextPane.inactiveForeground", new ColorUIResource(Color.gray), "TextPane.keyBindings", new JTextComponent.KeyBinding[] { new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_UP, 0), "caret-up"), new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_DOWN, 0), "caret-down"), new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_PAGE_UP, 0), "page-up"), new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_PAGE_DOWN, 0), "page-down"), new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_ENTER, 0), "insert-break"), new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_TAB, 0), "insert-tab") }, "TextPane.margin", new InsetsUIResource(3, 3, 3, 3), "TextPane.selectionBackground", new ColorUIResource(Color.black), "TextPane.selectionForeground", new ColorUIResource(Color.white), "TitledBorder.border", new BorderUIResource.EtchedBorderUIResource(), "TitledBorder.font", new FontUIResource("Dialog", Font.PLAIN, 12), "TitledBorder.titleColor", new ColorUIResource(darkShadow), "ToggleButton.background", new ColorUIResource(light), "ToggleButton.border", new BorderUIResource.CompoundBorderUIResource(null, null), "ToggleButton.darkShadow", new ColorUIResource(shadow), "ToggleButton.focusInputMap", new UIDefaults.LazyInputMap(new Object[] { "SPACE", "pressed", "released SPACE", "released" }), "ToggleButton.font", new FontUIResource("Dialog", Font.PLAIN, 12), "ToggleButton.foreground", new ColorUIResource(darkShadow), "ToggleButton.highlight", new ColorUIResource(highLight), "ToggleButton.light", new ColorUIResource(light), "ToggleButton.margin", new InsetsUIResource(2, 14, 2, 14), "ToggleButton.shadow", new ColorUIResource(shadow), "ToggleButton.textIconGap", new Integer(4), "ToggleButton.textShiftOffset", new Integer(0), "ToolBar.ancestorInputMap", new UIDefaults.LazyInputMap(new Object[] { "UP", "navigateUp", "KP_UP", "navigateUp", "DOWN", "navigateDown", "KP_DOWN", "navigateDown", "LEFT", "navigateLeft", "KP_LEFT", "navigateLeft", "RIGHT", "navigateRight", "KP_RIGHT", "navigateRight" }), "ToolBar.background", new ColorUIResource(light), "ToolBar.border", new BorderUIResource.EtchedBorderUIResource(), "ToolBar.darkShadow", new ColorUIResource(shadow), "ToolBar.dockingBackground", new ColorUIResource(light), "ToolBar.dockingForeground", new ColorUIResource(Color.red), "ToolBar.floatingBackground", new ColorUIResource(light), "ToolBar.floatingForeground", new ColorUIResource(Color.darkGray), "ToolBar.font", new FontUIResource("Dialog", Font.PLAIN, 12), "ToolBar.foreground", new ColorUIResource(darkShadow), "ToolBar.highlight", new ColorUIResource(highLight), "ToolBar.light", new ColorUIResource(highLight), "ToolBar.separatorSize", new DimensionUIResource(20, 20), "ToolBar.shadow", new ColorUIResource(shadow), "ToolTip.background", new ColorUIResource(light), "ToolTip.border", new BorderUIResource.LineBorderUIResource(Color.lightGray), "ToolTip.font", new FontUIResource("SansSerif", Font.PLAIN, 12), "ToolTip.foreground", new ColorUIResource(darkShadow), "Tree.ancestorInputMap", new UIDefaults.LazyInputMap(new Object[] { "ESCAPE", "cancel" }), "Tree.background", new ColorUIResource(light), "Tree.changeSelectionWithFocus", Boolean.TRUE,// "Tree.closedIcon", new IconUIResource(new ImageIcon("icons/TreeClosed.png")),// "Tree.collapsedIcon", new IconUIResource(new ImageIcon("icons/TreeCollapsed.png")), "Tree.drawsFocusBorderAroundIcon", Boolean.FALSE, "Tree.editorBorder", new BorderUIResource.LineBorderUIResource(Color.lightGray), "Tree.focusInputMap", new UIDefaults.LazyInputMap(new Object[] { "shift PAGE_DOWN", "scrollDownExtendSelection", "PAGE_DOWN", "scrollDownChangeSelection", "END", "selectLast", "ctrl KP_UP", "selectPreviousChangeLead", "shift END", "selectLastExtendSelection", "HOME", "selectFirst", "ctrl END", "selectLastChangeLead", "ctrl /", "selectAll", "LEFT", "selectParent", "shift HOME", "selectFirstExtendSelection", "UP", "selectPrevious", "ctrl KP_DOWN", "selectNextChangeLead", "RIGHT", "selectChild", "ctrl HOME", "selectFirstChangeLead", "DOWN", "selectNext", "ctrl KP_LEFT", "scrollLeft", "shift UP", "selectPreviousExtendSelection", "F2", "startEditing", "ctrl LEFT", "scrollLeft", "ctrl KP_RIGHT","scrollRight", "ctrl UP", "selectPreviousChangeLead", "shift DOWN", "selectNextExtendSelection", "ENTER", "toggle", "KP_UP", "selectPrevious", "KP_DOWN", "selectNext", "ctrl RIGHT", "scrollRight", "KP_LEFT", "selectParent", "KP_RIGHT", "selectChild", "ctrl DOWN", "selectNextChangeLead", "ctrl A", "selectAll", "shift KP_UP", "selectPreviousExtendSelection", "shift KP_DOWN","selectNextExtendSelection", "ctrl SPACE", "toggleSelectionPreserveAnchor", "ctrl shift PAGE_UP", "scrollUpExtendSelection", "ctrl \\", "clearSelection", "shift SPACE", "extendSelection", "ctrl PAGE_UP", "scrollUpChangeLead", "shift PAGE_UP","scrollUpExtendSelection", "SPACE", "toggleSelectionPreserveAnchor", "ctrl shift PAGE_DOWN", "scrollDownExtendSelection", "PAGE_UP", "scrollUpChangeSelection", "ctrl PAGE_DOWN", "scrollDownChangeLead" }), "Tree.font", new FontUIResource(new Font("Helvetica", Font.PLAIN, 12)), "Tree.foreground", new ColorUIResource(Color.black), "Tree.hash", new ColorUIResource(new Color(128, 128, 128)), "Tree.leftChildIndent", new Integer(7), "Tree.rightChildIndent", new Integer(13), "Tree.rowHeight", new Integer(20), // FIXME "Tree.scrollsOnExpand", Boolean.TRUE, "Tree.selectionBackground", new ColorUIResource(Color.black), "Tree.nonSelectionBackground", new ColorUIResource(new Color(239, 235, 231)), "Tree.selectionBorderColor", new ColorUIResource(Color.black), "Tree.selectionForeground", new ColorUIResource(new Color(255, 255, 255)), "Tree.textBackground", new ColorUIResource(new Color(255, 255, 255)), "Tree.textForeground", new ColorUIResource(Color.black), "Viewport.background", new ColorUIResource(light), "Viewport.foreground", new ColorUIResource(Color.black), "Viewport.font", new FontUIResource("Dialog", Font.PLAIN, 12) }; defaults.putDefaults(uiDefaults); }
"ctrl shift PAGE_DOWN", "scrollLeftExtendSelection",
"ctrl shift PAGE_DOWN", "scrollRightExtendSelection",
protected void initComponentDefaults(UIDefaults defaults) { Object[] uiDefaults; Color highLight = new Color(249, 247, 246); Color light = new Color(239, 235, 231); Color shadow = new Color(139, 136, 134); Color darkShadow = new Color(16, 16, 16); uiDefaults = new Object[] { "AbstractUndoableEdit.undoText", "Undo", "AbstractUndoableEdit.redoText", "Redo", "Button.background", new ColorUIResource(Color.LIGHT_GRAY), "Button.border", new UIDefaults.LazyValue() { public Object createValue(UIDefaults table) { return BasicBorders.getButtonBorder(); } }, "Button.darkShadow", new ColorUIResource(Color.BLACK), "Button.focusInputMap", new UIDefaults.LazyInputMap(new Object[] { "SPACE", "pressed", "released SPACE", "released" }), "Button.font", new FontUIResource("Dialog", Font.PLAIN, 12), "Button.foreground", new ColorUIResource(Color.BLACK), "Button.highlight", new ColorUIResource(Color.WHITE), "Button.light", new ColorUIResource(Color.LIGHT_GRAY), "Button.margin", new InsetsUIResource(2, 2, 2, 2), "Button.shadow", new ColorUIResource(Color.GRAY), "Button.textIconGap", new Integer(4), "Button.textShiftOffset", new Integer(0), "CheckBox.background", new ColorUIResource(new Color(204, 204, 204)), "CheckBox.border", new BorderUIResource.CompoundBorderUIResource(null, null), "CheckBox.focusInputMap", new UIDefaults.LazyInputMap(new Object[] { "SPACE", "pressed", "released SPACE", "released" }), "CheckBox.font", new FontUIResource("Dialog", Font.PLAIN, 12), "CheckBox.foreground", new ColorUIResource(darkShadow), "CheckBox.icon", new UIDefaults.LazyValue() { public Object createValue(UIDefaults def) { return BasicIconFactory.getCheckBoxIcon(); } }, "CheckBox.checkIcon", new UIDefaults.LazyValue() { public Object createValue(UIDefaults def) { return BasicIconFactory.getMenuItemCheckIcon(); } }, "CheckBox.margin",new InsetsUIResource(2, 2, 2, 2), "CheckBox.textIconGap", new Integer(4), "CheckBox.textShiftOffset", new Integer(0), "CheckBoxMenuItem.icon", new UIDefaults.LazyValue() { public Object createValue(UIDefaults def) { return BasicIconFactory.getCheckBoxIcon(); } }, "CheckBoxMenuItem.acceleratorFont", new FontUIResource("Dialog", Font.PLAIN, 12), "CheckBoxMenuItem.acceleratorForeground", new ColorUIResource(new Color(16, 16, 16)), "CheckBoxMenuItem.acceleratorSelectionForeground", new ColorUIResource(Color.white), "CheckBoxMenuItem.arrowIcon", BasicIconFactory.getMenuItemArrowIcon(), "CheckBoxMenuItem.background", new ColorUIResource(light), "CheckBoxMenuItem.border", new BasicBorders.MarginBorder(), "CheckBoxMenuItem.borderPainted", Boolean.FALSE, "CheckBoxMenuItem.checkIcon", new UIDefaults.LazyValue() { public Object createValue(UIDefaults def) { return BasicIconFactory.getMenuItemCheckIcon(); } }, "CheckBoxMenuItem.font", new FontUIResource("Dialog", Font.PLAIN, 12), "CheckBoxMenuItem.foreground", new ColorUIResource(darkShadow), "CheckBoxMenuItem.margin", new InsetsUIResource(2, 2, 2, 2), "CheckBoxMenuItem.selectionBackground", new ColorUIResource(Color.black), "CheckBoxMenuItem.selectionForeground", new ColorUIResource(Color.white), "ColorChooser.background", new ColorUIResource(light), "ColorChooser.cancelText", "Cancel", "ColorChooser.font", new FontUIResource("Dialog", Font.PLAIN, 12), "ColorChooser.foreground", new ColorUIResource(darkShadow), "ColorChooser.hsbBlueText", "B", "ColorChooser.hsbBrightnessText", "B", "ColorChooser.hsbGreenText", "G", "ColorChooser.hsbHueText", "H", "ColorChooser.hsbNameText", "HSB", "ColorChooser.hsbRedText", "R", "ColorChooser.hsbSaturationText", "S", "ColorChooser.okText", "OK", "ColorChooser.previewText", "Preview", "ColorChooser.resetText", "Reset", "ColorChooser.rgbBlueMnemonic", new Integer(66), "ColorChooser.rgbBlueText", "Blue", "ColorChooser.rgbGreenMnemonic", new Integer(71), "ColorChooser.rgbGreenText", "Green", "ColorChooser.rgbNameText", "RGB", "ColorChooser.rgbRedMnemonic", new Integer(82), "ColorChooser.rgbRedText", "Red", "ColorChooser.sampleText", "Sample Text Sample Text", "ColorChooser.swatchesDefaultRecentColor", new ColorUIResource(light), "ColorChooser.swatchesNameText", "Swatches", "ColorChooser.swatchesRecentSwatchSize", new Dimension(10, 10), "ColorChooser.swatchesRecentText", "Recent:", "ColorChooser.swatchesSwatchSize", new Dimension(10, 10), "ComboBox.ancestorInputMap", new UIDefaults.LazyInputMap(new Object[] { "ESCAPE", "hidePopup", "PAGE_UP", "pageUpPassThrough", "PAGE_DOWN", "pageDownPassThrough", "HOME", "homePassThrough", "END", "endPassThrough" }), "ComboBox.background", new ColorUIResource(light), "ComboBox.buttonBackground", new ColorUIResource(light), "ComboBox.buttonDarkShadow", new ColorUIResource(shadow), "ComboBox.buttonHighlight", new ColorUIResource(highLight), "ComboBox.buttonShadow", new ColorUIResource(shadow), "ComboBox.disabledBackground", new ColorUIResource(light), "ComboBox.disabledForeground", new ColorUIResource(Color.gray), "ComboBox.font", new FontUIResource("SansSerif", Font.PLAIN, 12), "ComboBox.foreground", new ColorUIResource(Color.black), "ComboBox.selectionBackground", new ColorUIResource(Color.black), "ComboBox.selectionForeground", new ColorUIResource(Color.white), "Desktop.ancestorInputMap", new UIDefaults.LazyInputMap(new Object[] { "KP_LEFT", "left", "KP_RIGHT", "right", "ctrl F5", "restore", "LEFT", "left", "ctrl alt F6", "selectNextFrame", "UP", "up", "ctrl F6", "selectNextFrame", "RIGHT", "right", "DOWN", "down", "ctrl F7", "move", "ctrl F8", "resize", "ESCAPE", "escape", "ctrl TAB", "selectNextFrame", "ctrl F9", "minimize", "KP_UP", "up", "ctrl F4", "close", "KP_DOWN", "down", "ctrl F10", "maximize", "ctrl alt shift F6","selectPreviousFrame" }), "Desktop.background", new ColorUIResource(0, 92, 92), "DesktopIcon.border", new BorderUIResource.CompoundBorderUIResource(null, null), "EditorPane.background", new ColorUIResource(Color.white), "EditorPane.border", new BasicBorders.MarginBorder(), "EditorPane.caretBlinkRate", new Integer(500), "EditorPane.caretForeground", new ColorUIResource(Color.black), "EditorPane.font", new FontUIResource("Serif", Font.PLAIN, 12), "EditorPane.foreground", new ColorUIResource(Color.black), "EditorPane.inactiveForeground", new ColorUIResource(Color.gray), "EditorPane.keyBindings", new JTextComponent.KeyBinding[] { new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_UP, 0), "caret-up"), new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_DOWN, 0), "caret-down"), new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_PAGE_UP, 0), "page-up"), new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_PAGE_DOWN, 0), "page-down"), new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_ENTER, 0), "insert-break"), new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_TAB, 0), "insert-tab") }, "EditorPane.margin", new InsetsUIResource(3, 3, 3, 3), "EditorPane.selectionBackground", new ColorUIResource(Color.black), "EditorPane.selectionForeground", new ColorUIResource(Color.white), "FileChooser.acceptAllFileFilterText", "All Files (*.*)", "FileChooser.ancestorInputMap", new UIDefaults.LazyInputMap(new Object[] { "ESCAPE", "cancelSelection" }), "FileChooser.cancelButtonMnemonic", new Integer(67), "FileChooser.cancelButtonText", "Cancel", "FileChooser.cancelButtonToolTipText", "Abort file chooser dialog", // XXX Don't use gif// "FileChooser.detailsViewIcon", new IconUIResource(new ImageIcon("icons/DetailsView.gif")), "FileChooser.directoryDescriptionText", "Directory", "FileChooser.fileDescriptionText", "Generic File", "FileChooser.helpButtonMnemonic", new Integer(72), "FileChooser.helpButtonText", "Help", "FileChooser.helpButtonToolTipText", "FileChooser help", // XXX Don't use gif// "FileChooser.homeFolderIcon", new IconUIResource(new ImageIcon("icons/HomeFolder.gif")), // XXX Don't use gif// "FileChooser.listViewIcon", new IconUIResource(new ImageIcon("icons/ListView.gif")), "FileChooser.newFolderErrorSeparator", ":", "FileChooser.newFolderErrorText", "Error creating new folder", // XXX Don't use gif// "FileChooser.newFolderIcon", new IconUIResource(new ImageIcon("icons/NewFolder.gif")), "FileChooser.openButtonMnemonic", new Integer(79), "FileChooser.openButtonText", "Open", "FileChooser.openButtonToolTipText", "Open selected file", "FileChooser.saveButtonMnemonic", new Integer(83), "FileChooser.saveButtonText", "Save", "FileChooser.saveButtonToolTipText", "Save selected file", // XXX Don't use gif// "FileChooser.upFolderIcon", new IconUIResource(new ImageIcon("icons/UpFolder.gif")), "FileChooser.updateButtonMnemonic", new Integer(85), "FileChooser.updateButtonText", "Update", "FileChooser.updateButtonToolTipText", "Update directory listing", // XXX Don't use gif// "FileView.computerIcon", new IconUIResource(new ImageIcon("icons/Computer.gif")), // XXX Don't use gif// "FileView.directoryIcon", new IconUIResource(new ImageIcon("icons/Directory.gif")), // XXX Don't use gif// "FileView.fileIcon", new IconUIResource(new ImageIcon("icons/File.gif")), // XXX Don't use gif// "FileView.floppyDriveIcon", new IconUIResource(new ImageIcon("icons/Floppy.gif")), // XXX Don't use gif// "FileView.hardDriveIcon", new IconUIResource(new ImageIcon("icons/HardDrive.gif")), "FocusManagerClassName", "TODO", "FormattedTextField.background", new ColorUIResource(light), "FormattedTextField.caretForeground", new ColorUIResource(Color.black), "FormattedTextField.foreground", new ColorUIResource(Color.black), "FormattedTextField.inactiveBackground", new ColorUIResource(light), "FormattedTextField.inactiveForeground", new ColorUIResource(Color.gray), "FormattedTextField.selectionBackground", new ColorUIResource(Color.black), "FormattedTextField.selectionForeground", new ColorUIResource(Color.white), "FormView.resetButtonText", "Reset", "FormView.submitButtonText", "Submit Query", "InternalFrame.activeTitleBackground", new ColorUIResource(0, 0, 128), "InternalFrame.activeTitleForeground", new ColorUIResource(Color.white), "InternalFrame.border", new UIDefaults.LazyValue() { public Object createValue(UIDefaults table) { Color lineColor = new Color(238, 238, 238); Border inner = BorderFactory.createLineBorder(lineColor, 1); Color shadowInner = new Color(184, 207, 229); Color shadowOuter = new Color(122, 138, 153); Border outer = BorderFactory.createBevelBorder(BevelBorder.RAISED, Color.WHITE, Color.WHITE, shadowOuter, shadowInner); Border border = new BorderUIResource.CompoundBorderUIResource(outer, inner); return border; } }, "InternalFrame.borderColor", new ColorUIResource(light), "InternalFrame.borderDarkShadow", new ColorUIResource(Color.BLACK), "InternalFrame.borderHighlight", new ColorUIResource(Color.WHITE), "InternalFrame.borderLight", new ColorUIResource(Color.LIGHT_GRAY), "InternalFrame.borderShadow", new ColorUIResource(Color.GRAY), "InternalFrame.closeIcon", BasicIconFactory.createEmptyFrameIcon(), // FIXME: Set a nice icon for InternalFrames here. "InternalFrame.icon", new UIDefaults.LazyValue() { public Object createValue(UIDefaults def) { return new IconUIResource(BasicIconFactory.createEmptyFrameIcon()); } }, "InternalFrame.iconifyIcon", BasicIconFactory.createEmptyFrameIcon(), "InternalFrame.inactiveTitleBackground", new ColorUIResource(Color.gray), "InternalFrame.inactiveTitleForeground", new ColorUIResource(Color.lightGray), "InternalFrame.maximizeIcon", BasicIconFactory.createEmptyFrameIcon(), "InternalFrame.minimizeIcon", BasicIconFactory.createEmptyFrameIcon(), "InternalFrame.titleFont", new FontUIResource("Dialog", Font.PLAIN, 12), "InternalFrame.windowBindings", new Object[] { "shift ESCAPE", "showSystemMenu", "ctrl SPACE", "showSystemMenu", "ESCAPE", "showSystemMenu" }, "Label.background", new ColorUIResource(light), "Label.disabledForeground", new ColorUIResource(Color.white), "Label.disabledShadow", new ColorUIResource(shadow), "Label.font", new FontUIResource("Dialog", Font.PLAIN, 12), "Label.foreground", new ColorUIResource(darkShadow), "List.background", new ColorUIResource(light), "List.border", new BasicBorders.MarginBorder(), "List.focusInputMap", new UIDefaults.LazyInputMap(new Object[] { "PAGE_UP", "scrollUp", "ctrl \\", "clearSelection", "PAGE_DOWN", "scrollDown", "shift PAGE_DOWN","scrollDownExtendSelection", "END", "selectLastRow", "HOME", "selectFirstRow", "shift END", "selectLastRowExtendSelection", "shift HOME", "selectFirstRowExtendSelection", "UP", "selectPreviousRow", "ctrl /", "selectAll", "ctrl A", "selectAll", "DOWN", "selectNextRow", "shift UP", "selectPreviousRowExtendSelection", "ctrl SPACE", "selectNextRowExtendSelection", "shift DOWN", "selectNextRowExtendSelection", "KP_UP", "selectPreviousRow", "shift PAGE_UP","scrollUpExtendSelection", "KP_DOWN", "selectNextRow" }), "List.foreground", new ColorUIResource(darkShadow), "List.selectionBackground", new ColorUIResource(Color.black), "List.selectionForeground", new ColorUIResource(Color.white), "List.focusCellHighlightBorder", new BorderUIResource. LineBorderUIResource(new ColorUIResource(Color.yellow)), "Menu.acceleratorFont", new FontUIResource("Dialog", Font.PLAIN, 12), "Menu.acceleratorForeground", new ColorUIResource(darkShadow), "Menu.acceleratorSelectionForeground", new ColorUIResource(Color.white), "Menu.arrowIcon", BasicIconFactory.getMenuArrowIcon(), "Menu.background", new ColorUIResource(light), "Menu.border", new BasicBorders.MarginBorder(), "Menu.borderPainted", Boolean.FALSE, "Menu.checkIcon", BasicIconFactory.getMenuItemCheckIcon(), "Menu.consumesTabs", Boolean.TRUE, "Menu.font", new FontUIResource("Dialog", Font.PLAIN, 12), "Menu.foreground", new ColorUIResource(darkShadow), "Menu.margin", new InsetsUIResource(2, 2, 2, 2), "Menu.selectedWindowInputMapBindings", new Object[] { "ESCAPE", "cancel", "DOWN", "selectNext", "KP_DOWN", "selectNext", "UP", "selectPrevious", "KP_UP", "selectPrevious", "LEFT", "selectParent", "KP_LEFT", "selectParent", "RIGHT", "selectChild", "KP_RIGHT", "selectChild", "ENTER", "return", "SPACE", "return" }, "Menu.selectionBackground", new ColorUIResource(Color.black), "Menu.selectionForeground", new ColorUIResource(Color.white), "MenuBar.background", new ColorUIResource(light), "MenuBar.border", new BasicBorders.MenuBarBorder(null, null), "MenuBar.font", new FontUIResource("Dialog", Font.PLAIN, 12), "MenuBar.foreground", new ColorUIResource(darkShadow), "MenuBar.highlight", new ColorUIResource(highLight), "MenuBar.shadow", new ColorUIResource(shadow), "MenuBar.windowBindings", new Object[] { "F10", "takeFocus" }, "MenuItem.acceleratorDelimiter", "-", "MenuItem.acceleratorFont", new FontUIResource("Dialog", Font.PLAIN, 12), "MenuItem.acceleratorForeground", new ColorUIResource(darkShadow), "MenuItem.acceleratorSelectionForeground", new ColorUIResource(Color.white), "MenuItem.arrowIcon", BasicIconFactory.getMenuItemArrowIcon(), "MenuItem.background", new ColorUIResource(light), "MenuItem.border", new BasicBorders.MarginBorder(), "MenuItem.borderPainted", Boolean.FALSE, "MenuItem.checkIcon", BasicIconFactory.getMenuItemCheckIcon(), "MenuItem.font", new FontUIResource("Dialog", Font.PLAIN, 12), "MenuItem.foreground", new ColorUIResource(darkShadow), "MenuItem.margin", new InsetsUIResource(2, 2, 2, 2), "MenuItem.selectionBackground", new ColorUIResource(Color.black), "MenuItem.selectionForeground", new ColorUIResource(Color.white), "OptionPane.background", new ColorUIResource(light), "OptionPane.border", new BorderUIResource.EmptyBorderUIResource(0, 0, 0, 0), "OptionPane.buttonAreaBorder", new BorderUIResource.EmptyBorderUIResource(0, 0, 0, 0), "OptionPane.cancelButtonText", "Cancel", // XXX Don't use gif// "OptionPane.errorIcon",// new IconUIResource(new ImageIcon("icons/Error.gif")), "OptionPane.font", new FontUIResource("Dialog", Font.PLAIN, 12), "OptionPane.foreground", new ColorUIResource(darkShadow), // XXX Don't use gif// "OptionPane.informationIcon",// new IconUIResource(new ImageIcon("icons/Inform.gif")), "OptionPane.messageAreaBorder", new BorderUIResource.EmptyBorderUIResource(0, 0, 0, 0), "OptionPane.messageForeground", new ColorUIResource(darkShadow), "OptionPane.minimumSize", new DimensionUIResource(262, 90), "OptionPane.noButtonText", "No", "OptionPane.okButtonText", "OK", // XXX Don't use gif// "OptionPane.questionIcon",// new IconUIResource(new ImageIcon("icons/Question.gif")), // XXX Don't use gif// "OptionPane.warningIcon",// new IconUIResource(new ImageIcon("icons/Warn.gif")), "OptionPane.windowBindings", new Object[] { "ESCAPE", "close" }, "OptionPane.yesButtonText", "Yes", "Panel.background", new ColorUIResource(light), "Panel.font", new FontUIResource("Dialog", Font.PLAIN, 12), "Panel.foreground", new ColorUIResource(Color.black), "PasswordField.background", new ColorUIResource(light), "PasswordField.border", new BasicBorders.FieldBorder(null, null, null, null), "PasswordField.caretBlinkRate", new Integer(500), "PasswordField.caretForeground", new ColorUIResource(Color.black), "PasswordField.font", new FontUIResource("MonoSpaced", Font.PLAIN, 12), "PasswordField.foreground", new ColorUIResource(Color.black), "PasswordField.inactiveBackground", new ColorUIResource(light), "PasswordField.inactiveForeground", new ColorUIResource(Color.gray), "PasswordField.keyBindings", new JTextComponent.KeyBinding[] { new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_ENTER, 0), "notify-field-accept")}, "PasswordField.margin", new InsetsUIResource(0, 0, 0, 0), "PasswordField.selectionBackground", new ColorUIResource(Color.black), "PasswordField.selectionForeground", new ColorUIResource(Color.white), "PopupMenu.background", new ColorUIResource(light), "PopupMenu.border", new BorderUIResource.BevelBorderUIResource(0), "PopupMenu.font", new FontUIResource("Dialog", Font.PLAIN, 12), "PopupMenu.foreground", new ColorUIResource(darkShadow), "ProgressBar.background", new ColorUIResource(light), "ProgressBar.border", new BorderUIResource.LineBorderUIResource(Color.darkGray), "ProgressBar.cellLength", new Integer(1), "ProgressBar.cellSpacing", new Integer(0), "ProgressBar.font", new FontUIResource("Dialog", Font.PLAIN, 12), "ProgressBar.foreground", new ColorUIResource(Color.black), "ProgressBar.selectionBackground", new ColorUIResource(Color.black), "ProgressBar.selectionForeground", new ColorUIResource(light), "ProgressBar.repaintInterval", new Integer(250), "ProgressBar.cycleTime", new Integer(6000), "RadioButton.background", new ColorUIResource(light), "RadioButton.border", new BorderUIResource.CompoundBorderUIResource(null, null), "RadioButton.darkShadow", new ColorUIResource(shadow), "RadioButton.focusInputMap", new UIDefaults.LazyInputMap(new Object[] { "SPACE", "pressed", "released SPACE", "released" }), "RadioButton.font", new FontUIResource("Dialog", Font.PLAIN, 12), "RadioButton.foreground", new ColorUIResource(darkShadow), "RadioButton.highlight", new ColorUIResource(highLight), "RadioButton.icon", new UIDefaults.LazyValue() { public Object createValue(UIDefaults def) { return BasicIconFactory.getRadioButtonIcon(); } }, "RadioButton.light", new ColorUIResource(highLight), "RadioButton.margin", new InsetsUIResource(2, 2, 2, 2), "RadioButton.shadow", new ColorUIResource(shadow), "RadioButton.textIconGap", new Integer(4), "RadioButton.textShiftOffset", new Integer(0), "RadioButtonMenuItem.acceleratorFont", new FontUIResource("Dialog", Font.PLAIN, 12), "RadioButtonMenuItem.acceleratorForeground", new ColorUIResource(darkShadow), "RadioButtonMenuItem.acceleratorSelectionForeground", new ColorUIResource(Color.white), "RadioButtonMenuItem.arrowIcon", BasicIconFactory.getMenuItemArrowIcon(), "RadioButtonMenuItem.background", new ColorUIResource(light), "RadioButtonMenuItem.border", new BasicBorders.MarginBorder(), "RadioButtonMenuItem.borderPainted", Boolean.FALSE, "RadioButtonMenuItem.checkIcon", BasicIconFactory.getRadioButtonMenuItemIcon(), "RadioButtonMenuItem.font", new FontUIResource("Dialog", Font.PLAIN, 12), "RadioButtonMenuItem.foreground", new ColorUIResource(darkShadow), "RadioButtonMenuItem.margin", new InsetsUIResource(2, 2, 2, 2), "RadioButtonMenuItem.selectionBackground", new ColorUIResource(Color.black), "RadioButtonMenuItem.selectionForeground", new ColorUIResource(Color.white), "RootPane.defaultButtonWindowKeyBindings", new Object[] { "ENTER", "press", "released ENTER", "release", "ctrl ENTER", "press", "ctrl released ENTER", "release" }, "ScrollBar.background", new ColorUIResource(224, 224, 224), "ScrollBar.focusInputMap", new UIDefaults.LazyInputMap(new Object[] { "PAGE_UP", "negativeBlockIncrement", "PAGE_DOWN", "positiveBlockIncrement", "END", "maxScroll", "HOME", "minScroll", "LEFT", "positiveUnitIncrement", "KP_UP", "negativeUnitIncrement", "KP_DOWN", "positiveUnitIncrement", "UP", "negativeUnitIncrement", "RIGHT", "negativeUnitIncrement", "KP_LEFT", "positiveUnitIncrement", "DOWN", "positiveUnitIncrement", "KP_RIGHT", "negativeUnitIncrement" }), "ScrollBar.foreground", new ColorUIResource(light), "ScrollBar.maximumThumbSize", new DimensionUIResource(4096, 4096), "ScrollBar.minimumThumbSize", new DimensionUIResource(8, 8), "ScrollBar.thumb", new ColorUIResource(light), "ScrollBar.thumbDarkShadow", new ColorUIResource(shadow), "ScrollBar.thumbHighlight", new ColorUIResource(highLight), "ScrollBar.thumbShadow", new ColorUIResource(shadow), "ScrollBar.track", new ColorUIResource(light), "ScrollBar.trackHighlight", new ColorUIResource(shadow), "ScrollPane.ancestorInputMap", new UIDefaults.LazyInputMap(new Object[] { "PAGE_UP", "scrollUp", "KP_LEFT", "unitScrollLeft", "ctrl PAGE_DOWN","scrollRight", "PAGE_DOWN", "scrollDown", "KP_RIGHT", "unitScrollRight", "LEFT", "unitScrollLeft", "ctrl END", "scrollEnd", "UP", "unitScrollUp", "RIGHT", "unitScrollRight", "DOWN", "unitScrollDown", "ctrl HOME", "scrollHome", "ctrl PAGE_UP", "scrollLeft", "KP_UP", "unitScrollUp", "KP_DOWN", "unitScrollDown" }), "ScrollPane.background", new ColorUIResource(light), "ScrollPane.border", new BorderUIResource.EtchedBorderUIResource(), "ScrollPane.font", new FontUIResource("Dialog", Font.PLAIN, 12), "ScrollPane.foreground", new ColorUIResource(darkShadow), "Separator.background", new ColorUIResource(highLight), "Separator.foreground", new ColorUIResource(shadow), "Separator.highlight", new ColorUIResource(highLight), "Separator.shadow", new ColorUIResource(shadow), "Slider.background", new ColorUIResource(light), "Slider.focus", new ColorUIResource(shadow), "Slider.focusInputMap", new UIDefaults.LazyInputMap(new Object[] { "PAGE_UP", "positiveBlockIncrement", "PAGE_DOWN", "negativeBlockIncrement", "END", "maxScroll", "HOME", "minScroll", "LEFT", "negativeUnitIncrement", "KP_UP", "positiveUnitIncrement", "KP_DOWN", "negativeUnitIncrement", "UP", "positiveUnitIncrement", "RIGHT", "positiveUnitIncrement", "KP_LEFT", "negativeUnitIncrement", "DOWN", "negativeUnitIncrement", "KP_RIGHT", "positiveUnitIncrement" }), "Slider.focusInsets", new InsetsUIResource(2, 2, 2, 2), "Slider.foreground", new ColorUIResource(light), "Slider.highlight", new ColorUIResource(highLight), "Slider.shadow", new ColorUIResource(shadow), "Slider.thumbHeight", new Integer(20), "Slider.thumbWidth", new Integer(11), "Slider.tickHeight", new Integer(12), "Spinner.background", new ColorUIResource(light), "Spinner.foreground", new ColorUIResource(light), "SplitPane.ancestorInputMap", new UIDefaults.LazyInputMap(new Object[] { "F6", "toggleFocus", "F8", "startResize", "END", "selectMax", "HOME", "selectMin", "LEFT", "negativeIncremnent", "KP_UP", "negativeIncrement", "KP_DOWN", "positiveIncrement", "UP", "negativeIncrement", "RIGHT", "positiveIncrement", "KP_LEFT", "negativeIncrement", "DOWN", "positiveIncrement", "KP_RIGHT", "positiveIncrement" }), "SplitPane.background", new ColorUIResource(light), "SplitPane.border", new BasicBorders.SplitPaneBorder(null, null), "SplitPane.darkShadow", new ColorUIResource(shadow), "SplitPane.dividerSize", new Integer(10), "SplitPane.highlight", new ColorUIResource(highLight), "SplitPane.shadow", new ColorUIResource(shadow), "TabbedPane.ancestorInputMap", new UIDefaults.LazyInputMap(new Object[] { "ctrl PAGE_DOWN","navigatePageDown", "ctrl PAGE_UP", "navigatePageUp", "ctrl UP", "requestFocus", "ctrl KP_UP", "requestFocus" }), "TabbedPane.background", new ColorUIResource(light), "TabbedPane.contentBorderInsets", new InsetsUIResource(2, 2, 3, 3), "TabbedPane.darkShadow", new ColorUIResource(shadow), "TabbedPane.focus", new ColorUIResource(darkShadow), "TabbedPane.focusInputMap", new UIDefaults.LazyInputMap(new Object[] { "LEFT", "navigateLeft", "KP_UP", "navigateUp", "ctrl DOWN", "requestFocusForVisibleComponent", "UP", "navigateUp", "KP_DOWN", "navigateDown", "RIGHT", "navigateRight", "KP_LEFT", "navigateLeft", "ctrl KP_DOWN", "requestFocusForVisibleComponent", "KP_RIGHT", "navigateRight", "DOWN", "navigateDown" }), "TabbedPane.font", new FontUIResource("Dialog", Font.PLAIN, 12), "TabbedPane.foreground", new ColorUIResource(darkShadow), "TabbedPane.highlight", new ColorUIResource(highLight), "TabbedPane.light", new ColorUIResource(highLight), "TabbedPane.selectedTabPadInsets", new InsetsUIResource(2, 2, 2, 1), "TabbedPane.shadow", new ColorUIResource(shadow), "TabbedPane.tabbedPaneTabAreaInsets", new InsetsUIResource(3, 2, 1, 2), "TabbedPane.tabbedPaneTabInsets", new InsetsUIResource(1, 4, 1, 4), "TabbedPane.tabbedPaneContentBorderInsets", new InsetsUIResource(3, 2, 1, 2), "TabbedPane.tabbedPaneTabPadInsets", new InsetsUIResource(1, 1, 1, 1), "TabbedPane.tabRunOverlay", new Integer(2), "TabbedPane.textIconGap", new Integer(4), "Table.ancestorInputMap", new UIDefaults.LazyInputMap(new Object[] { "shift PAGE_DOWN","scrollDownExtendSelection", "PAGE_DOWN", "scrollDownChangeSelection", "END", "selectLastColumn", "shift END", "selectLastColumnExtendSelection", "HOME", "selectFirstColumn", "ctrl END", "selectLastRow", "ctrl shift END","selectLastRowExtendSelection", "LEFT", "selectPreviousColumn", "shift HOME", "selectFirstColumnExtendSelection", "UP", "selectPreviousRow", "RIGHT", "selectNextColumn", "ctrl HOME", "selectFirstRow", "shift LEFT", "selectPreviousColumnExtendSelection", "DOWN", "selectNextRow", "ctrl shift HOME","selectFirstRowExtendSelection", "shift UP", "selectPreviousRowExtendSelection", "F2", "startEditing", "shift RIGHT", "selectNextColumnExtendSelection", "TAB", "selectNextColumnCell", "shift DOWN", "selectNextRowExtendSelection", "ENTER", "selectNextRowCell", "KP_UP", "selectPreviousRow", "KP_DOWN", "selectNextRow", "KP_LEFT", "selectPreviousColumn", "KP_RIGHT", "selectNextColumn", "shift TAB", "selectPreviousColumnCell", "ctrl A", "selectAll", "shift ENTER", "selectPreviousRowCell", "shift KP_DOWN", "selectNextRowExtendSelection", "shift KP_LEFT", "selectPreviousColumnExtendSelection", "ESCAPE", "cancel", "ctrl shift PAGE_UP", "scrollRightExtendSelection", "shift KP_RIGHT", " selectNextColumnExtendSelection", "ctrl PAGE_UP", "scrollLeftChangeSelection", "shift PAGE_UP", "scrollUpExtendSelection", "ctrl shift PAGE_DOWN", "scrollLeftExtendSelection", "ctrl PAGE_DOWN", "scrollRightChangeSelection", "PAGE_UP", "scrollUpChangeSelection" }), "Table.background", new ColorUIResource(light), "Table.focusCellBackground", new ColorUIResource(light), "Table.focusCellForeground", new ColorUIResource(darkShadow), "Table.focusCellHighlightBorder", new BorderUIResource.LineBorderUIResource( new ColorUIResource(255, 255, 0)), "Table.font", new FontUIResource("Dialog", Font.PLAIN, 12), "Table.foreground", new ColorUIResource(darkShadow), "Table.gridColor", new ColorUIResource(Color.gray), "Table.scrollPaneBorder", new BorderUIResource.BevelBorderUIResource(0), "Table.selectionBackground", new ColorUIResource(Color.black), "Table.selectionForeground", new ColorUIResource(Color.white), "TableHeader.background", new ColorUIResource(light), "TableHeader.cellBorder", new BorderUIResource.BevelBorderUIResource(0), "TableHeader.font", new FontUIResource("Dialog", Font.PLAIN, 12), "TableHeader.foreground", new ColorUIResource(darkShadow), "TextArea.background", new ColorUIResource(light), "TextArea.border", new BasicBorders.MarginBorder(), "TextArea.caretBlinkRate", new Integer(500), "TextArea.caretForeground", new ColorUIResource(Color.black), "TextArea.font", new FontUIResource("MonoSpaced", Font.PLAIN, 12), "TextArea.foreground", new ColorUIResource(Color.black), "TextArea.inactiveForeground", new ColorUIResource(Color.gray), "TextArea.keyBindings", new JTextComponent.KeyBinding[] { new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_UP, 0), "caret-up"), new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_DOWN, 0), "caret-down"), new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_PAGE_UP, 0), "page-up"), new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_PAGE_DOWN, 0), "page-down"), new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_ENTER, 0), "insert-break"), new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_TAB, 0), "insert-tab") }, "TextArea.margin", new InsetsUIResource(0, 0, 0, 0), "TextArea.selectionBackground", new ColorUIResource(Color.black), "TextArea.selectionForeground", new ColorUIResource(Color.white), "TextField.background", new ColorUIResource(light), "TextField.border", new BasicBorders.FieldBorder(null, null, null, null), "TextField.caretBlinkRate", new Integer(500), "TextField.caretForeground", new ColorUIResource(Color.black), "TextField.darkShadow", new ColorUIResource(shadow), "TextField.font", new FontUIResource("SansSerif", Font.PLAIN, 12), "TextField.foreground", new ColorUIResource(Color.black), "TextField.highlight", new ColorUIResource(highLight), "TextField.inactiveBackground", new ColorUIResource(light), "TextField.inactiveForeground", new ColorUIResource(Color.gray), "TextField.light", new ColorUIResource(highLight), "TextField.highlight", new ColorUIResource(light), "TextField.keyBindings", new JTextComponent.KeyBinding[] { new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_ENTER, 0), "notify-field-accept"), new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_LEFT, InputEvent.SHIFT_DOWN_MASK), "selection-backward"), new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_RIGHT, InputEvent.SHIFT_DOWN_MASK), "selection-forward"), }, "TextField.margin", new InsetsUIResource(0, 0, 0, 0), "TextField.selectionBackground", new ColorUIResource(Color.black), "TextField.selectionForeground", new ColorUIResource(Color.white), "TextPane.background", new ColorUIResource(Color.white), "TextPane.border", new BasicBorders.MarginBorder(), "TextPane.caretBlinkRate", new Integer(500), "TextPane.caretForeground", new ColorUIResource(Color.black), "TextPane.font", new FontUIResource("Serif", Font.PLAIN, 12), "TextPane.foreground", new ColorUIResource(Color.black), "TextPane.inactiveForeground", new ColorUIResource(Color.gray), "TextPane.keyBindings", new JTextComponent.KeyBinding[] { new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_UP, 0), "caret-up"), new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_DOWN, 0), "caret-down"), new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_PAGE_UP, 0), "page-up"), new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_PAGE_DOWN, 0), "page-down"), new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_ENTER, 0), "insert-break"), new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_TAB, 0), "insert-tab") }, "TextPane.margin", new InsetsUIResource(3, 3, 3, 3), "TextPane.selectionBackground", new ColorUIResource(Color.black), "TextPane.selectionForeground", new ColorUIResource(Color.white), "TitledBorder.border", new BorderUIResource.EtchedBorderUIResource(), "TitledBorder.font", new FontUIResource("Dialog", Font.PLAIN, 12), "TitledBorder.titleColor", new ColorUIResource(darkShadow), "ToggleButton.background", new ColorUIResource(light), "ToggleButton.border", new BorderUIResource.CompoundBorderUIResource(null, null), "ToggleButton.darkShadow", new ColorUIResource(shadow), "ToggleButton.focusInputMap", new UIDefaults.LazyInputMap(new Object[] { "SPACE", "pressed", "released SPACE", "released" }), "ToggleButton.font", new FontUIResource("Dialog", Font.PLAIN, 12), "ToggleButton.foreground", new ColorUIResource(darkShadow), "ToggleButton.highlight", new ColorUIResource(highLight), "ToggleButton.light", new ColorUIResource(light), "ToggleButton.margin", new InsetsUIResource(2, 14, 2, 14), "ToggleButton.shadow", new ColorUIResource(shadow), "ToggleButton.textIconGap", new Integer(4), "ToggleButton.textShiftOffset", new Integer(0), "ToolBar.ancestorInputMap", new UIDefaults.LazyInputMap(new Object[] { "UP", "navigateUp", "KP_UP", "navigateUp", "DOWN", "navigateDown", "KP_DOWN", "navigateDown", "LEFT", "navigateLeft", "KP_LEFT", "navigateLeft", "RIGHT", "navigateRight", "KP_RIGHT", "navigateRight" }), "ToolBar.background", new ColorUIResource(light), "ToolBar.border", new BorderUIResource.EtchedBorderUIResource(), "ToolBar.darkShadow", new ColorUIResource(shadow), "ToolBar.dockingBackground", new ColorUIResource(light), "ToolBar.dockingForeground", new ColorUIResource(Color.red), "ToolBar.floatingBackground", new ColorUIResource(light), "ToolBar.floatingForeground", new ColorUIResource(Color.darkGray), "ToolBar.font", new FontUIResource("Dialog", Font.PLAIN, 12), "ToolBar.foreground", new ColorUIResource(darkShadow), "ToolBar.highlight", new ColorUIResource(highLight), "ToolBar.light", new ColorUIResource(highLight), "ToolBar.separatorSize", new DimensionUIResource(20, 20), "ToolBar.shadow", new ColorUIResource(shadow), "ToolTip.background", new ColorUIResource(light), "ToolTip.border", new BorderUIResource.LineBorderUIResource(Color.lightGray), "ToolTip.font", new FontUIResource("SansSerif", Font.PLAIN, 12), "ToolTip.foreground", new ColorUIResource(darkShadow), "Tree.ancestorInputMap", new UIDefaults.LazyInputMap(new Object[] { "ESCAPE", "cancel" }), "Tree.background", new ColorUIResource(light), "Tree.changeSelectionWithFocus", Boolean.TRUE,// "Tree.closedIcon", new IconUIResource(new ImageIcon("icons/TreeClosed.png")),// "Tree.collapsedIcon", new IconUIResource(new ImageIcon("icons/TreeCollapsed.png")), "Tree.drawsFocusBorderAroundIcon", Boolean.FALSE, "Tree.editorBorder", new BorderUIResource.LineBorderUIResource(Color.lightGray), "Tree.focusInputMap", new UIDefaults.LazyInputMap(new Object[] { "shift PAGE_DOWN", "scrollDownExtendSelection", "PAGE_DOWN", "scrollDownChangeSelection", "END", "selectLast", "ctrl KP_UP", "selectPreviousChangeLead", "shift END", "selectLastExtendSelection", "HOME", "selectFirst", "ctrl END", "selectLastChangeLead", "ctrl /", "selectAll", "LEFT", "selectParent", "shift HOME", "selectFirstExtendSelection", "UP", "selectPrevious", "ctrl KP_DOWN", "selectNextChangeLead", "RIGHT", "selectChild", "ctrl HOME", "selectFirstChangeLead", "DOWN", "selectNext", "ctrl KP_LEFT", "scrollLeft", "shift UP", "selectPreviousExtendSelection", "F2", "startEditing", "ctrl LEFT", "scrollLeft", "ctrl KP_RIGHT","scrollRight", "ctrl UP", "selectPreviousChangeLead", "shift DOWN", "selectNextExtendSelection", "ENTER", "toggle", "KP_UP", "selectPrevious", "KP_DOWN", "selectNext", "ctrl RIGHT", "scrollRight", "KP_LEFT", "selectParent", "KP_RIGHT", "selectChild", "ctrl DOWN", "selectNextChangeLead", "ctrl A", "selectAll", "shift KP_UP", "selectPreviousExtendSelection", "shift KP_DOWN","selectNextExtendSelection", "ctrl SPACE", "toggleSelectionPreserveAnchor", "ctrl shift PAGE_UP", "scrollUpExtendSelection", "ctrl \\", "clearSelection", "shift SPACE", "extendSelection", "ctrl PAGE_UP", "scrollUpChangeLead", "shift PAGE_UP","scrollUpExtendSelection", "SPACE", "toggleSelectionPreserveAnchor", "ctrl shift PAGE_DOWN", "scrollDownExtendSelection", "PAGE_UP", "scrollUpChangeSelection", "ctrl PAGE_DOWN", "scrollDownChangeLead" }), "Tree.font", new FontUIResource(new Font("Helvetica", Font.PLAIN, 12)), "Tree.foreground", new ColorUIResource(Color.black), "Tree.hash", new ColorUIResource(new Color(128, 128, 128)), "Tree.leftChildIndent", new Integer(7), "Tree.rightChildIndent", new Integer(13), "Tree.rowHeight", new Integer(20), // FIXME "Tree.scrollsOnExpand", Boolean.TRUE, "Tree.selectionBackground", new ColorUIResource(Color.black), "Tree.nonSelectionBackground", new ColorUIResource(new Color(239, 235, 231)), "Tree.selectionBorderColor", new ColorUIResource(Color.black), "Tree.selectionForeground", new ColorUIResource(new Color(255, 255, 255)), "Tree.textBackground", new ColorUIResource(new Color(255, 255, 255)), "Tree.textForeground", new ColorUIResource(Color.black), "Viewport.background", new ColorUIResource(light), "Viewport.foreground", new ColorUIResource(Color.black), "Viewport.font", new FontUIResource("Dialog", Font.PLAIN, 12) }; defaults.putDefaults(uiDefaults); }
"PAGE_UP", "scrollUpChangeSelection"
"PAGE_UP", "scrollUpChangeSelection", "ctrl shift LEFT", "selectPreviousColumnExtendSelection", "shift KP_UP", "selectPreviousRowExtendSelection", "ctrl shift UP", "selectPreviousRowExtendSelection", "ctrl shift RIGHT", "selectNextColumnExtendSelection", "ctrl shift KP_RIGHT", "selectNextColumnExtendSelection", "ctrl shift DOWN", "selectNextRowExtendSelection", "ctrl BACK_SLASH", "clearSelection", "ctrl shift KP_UP", "selectPreviousRowExtendSelection", "ctrl shift KP_LEFT", "selectPreviousColumnExtendSelection", "ctrl SLASH", "selectAll", "ctrl shift KP_DOWN", "selectNextRowExtendSelection",
protected void initComponentDefaults(UIDefaults defaults) { Object[] uiDefaults; Color highLight = new Color(249, 247, 246); Color light = new Color(239, 235, 231); Color shadow = new Color(139, 136, 134); Color darkShadow = new Color(16, 16, 16); uiDefaults = new Object[] { "AbstractUndoableEdit.undoText", "Undo", "AbstractUndoableEdit.redoText", "Redo", "Button.background", new ColorUIResource(Color.LIGHT_GRAY), "Button.border", new UIDefaults.LazyValue() { public Object createValue(UIDefaults table) { return BasicBorders.getButtonBorder(); } }, "Button.darkShadow", new ColorUIResource(Color.BLACK), "Button.focusInputMap", new UIDefaults.LazyInputMap(new Object[] { "SPACE", "pressed", "released SPACE", "released" }), "Button.font", new FontUIResource("Dialog", Font.PLAIN, 12), "Button.foreground", new ColorUIResource(Color.BLACK), "Button.highlight", new ColorUIResource(Color.WHITE), "Button.light", new ColorUIResource(Color.LIGHT_GRAY), "Button.margin", new InsetsUIResource(2, 2, 2, 2), "Button.shadow", new ColorUIResource(Color.GRAY), "Button.textIconGap", new Integer(4), "Button.textShiftOffset", new Integer(0), "CheckBox.background", new ColorUIResource(new Color(204, 204, 204)), "CheckBox.border", new BorderUIResource.CompoundBorderUIResource(null, null), "CheckBox.focusInputMap", new UIDefaults.LazyInputMap(new Object[] { "SPACE", "pressed", "released SPACE", "released" }), "CheckBox.font", new FontUIResource("Dialog", Font.PLAIN, 12), "CheckBox.foreground", new ColorUIResource(darkShadow), "CheckBox.icon", new UIDefaults.LazyValue() { public Object createValue(UIDefaults def) { return BasicIconFactory.getCheckBoxIcon(); } }, "CheckBox.checkIcon", new UIDefaults.LazyValue() { public Object createValue(UIDefaults def) { return BasicIconFactory.getMenuItemCheckIcon(); } }, "CheckBox.margin",new InsetsUIResource(2, 2, 2, 2), "CheckBox.textIconGap", new Integer(4), "CheckBox.textShiftOffset", new Integer(0), "CheckBoxMenuItem.icon", new UIDefaults.LazyValue() { public Object createValue(UIDefaults def) { return BasicIconFactory.getCheckBoxIcon(); } }, "CheckBoxMenuItem.acceleratorFont", new FontUIResource("Dialog", Font.PLAIN, 12), "CheckBoxMenuItem.acceleratorForeground", new ColorUIResource(new Color(16, 16, 16)), "CheckBoxMenuItem.acceleratorSelectionForeground", new ColorUIResource(Color.white), "CheckBoxMenuItem.arrowIcon", BasicIconFactory.getMenuItemArrowIcon(), "CheckBoxMenuItem.background", new ColorUIResource(light), "CheckBoxMenuItem.border", new BasicBorders.MarginBorder(), "CheckBoxMenuItem.borderPainted", Boolean.FALSE, "CheckBoxMenuItem.checkIcon", new UIDefaults.LazyValue() { public Object createValue(UIDefaults def) { return BasicIconFactory.getMenuItemCheckIcon(); } }, "CheckBoxMenuItem.font", new FontUIResource("Dialog", Font.PLAIN, 12), "CheckBoxMenuItem.foreground", new ColorUIResource(darkShadow), "CheckBoxMenuItem.margin", new InsetsUIResource(2, 2, 2, 2), "CheckBoxMenuItem.selectionBackground", new ColorUIResource(Color.black), "CheckBoxMenuItem.selectionForeground", new ColorUIResource(Color.white), "ColorChooser.background", new ColorUIResource(light), "ColorChooser.cancelText", "Cancel", "ColorChooser.font", new FontUIResource("Dialog", Font.PLAIN, 12), "ColorChooser.foreground", new ColorUIResource(darkShadow), "ColorChooser.hsbBlueText", "B", "ColorChooser.hsbBrightnessText", "B", "ColorChooser.hsbGreenText", "G", "ColorChooser.hsbHueText", "H", "ColorChooser.hsbNameText", "HSB", "ColorChooser.hsbRedText", "R", "ColorChooser.hsbSaturationText", "S", "ColorChooser.okText", "OK", "ColorChooser.previewText", "Preview", "ColorChooser.resetText", "Reset", "ColorChooser.rgbBlueMnemonic", new Integer(66), "ColorChooser.rgbBlueText", "Blue", "ColorChooser.rgbGreenMnemonic", new Integer(71), "ColorChooser.rgbGreenText", "Green", "ColorChooser.rgbNameText", "RGB", "ColorChooser.rgbRedMnemonic", new Integer(82), "ColorChooser.rgbRedText", "Red", "ColorChooser.sampleText", "Sample Text Sample Text", "ColorChooser.swatchesDefaultRecentColor", new ColorUIResource(light), "ColorChooser.swatchesNameText", "Swatches", "ColorChooser.swatchesRecentSwatchSize", new Dimension(10, 10), "ColorChooser.swatchesRecentText", "Recent:", "ColorChooser.swatchesSwatchSize", new Dimension(10, 10), "ComboBox.ancestorInputMap", new UIDefaults.LazyInputMap(new Object[] { "ESCAPE", "hidePopup", "PAGE_UP", "pageUpPassThrough", "PAGE_DOWN", "pageDownPassThrough", "HOME", "homePassThrough", "END", "endPassThrough" }), "ComboBox.background", new ColorUIResource(light), "ComboBox.buttonBackground", new ColorUIResource(light), "ComboBox.buttonDarkShadow", new ColorUIResource(shadow), "ComboBox.buttonHighlight", new ColorUIResource(highLight), "ComboBox.buttonShadow", new ColorUIResource(shadow), "ComboBox.disabledBackground", new ColorUIResource(light), "ComboBox.disabledForeground", new ColorUIResource(Color.gray), "ComboBox.font", new FontUIResource("SansSerif", Font.PLAIN, 12), "ComboBox.foreground", new ColorUIResource(Color.black), "ComboBox.selectionBackground", new ColorUIResource(Color.black), "ComboBox.selectionForeground", new ColorUIResource(Color.white), "Desktop.ancestorInputMap", new UIDefaults.LazyInputMap(new Object[] { "KP_LEFT", "left", "KP_RIGHT", "right", "ctrl F5", "restore", "LEFT", "left", "ctrl alt F6", "selectNextFrame", "UP", "up", "ctrl F6", "selectNextFrame", "RIGHT", "right", "DOWN", "down", "ctrl F7", "move", "ctrl F8", "resize", "ESCAPE", "escape", "ctrl TAB", "selectNextFrame", "ctrl F9", "minimize", "KP_UP", "up", "ctrl F4", "close", "KP_DOWN", "down", "ctrl F10", "maximize", "ctrl alt shift F6","selectPreviousFrame" }), "Desktop.background", new ColorUIResource(0, 92, 92), "DesktopIcon.border", new BorderUIResource.CompoundBorderUIResource(null, null), "EditorPane.background", new ColorUIResource(Color.white), "EditorPane.border", new BasicBorders.MarginBorder(), "EditorPane.caretBlinkRate", new Integer(500), "EditorPane.caretForeground", new ColorUIResource(Color.black), "EditorPane.font", new FontUIResource("Serif", Font.PLAIN, 12), "EditorPane.foreground", new ColorUIResource(Color.black), "EditorPane.inactiveForeground", new ColorUIResource(Color.gray), "EditorPane.keyBindings", new JTextComponent.KeyBinding[] { new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_UP, 0), "caret-up"), new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_DOWN, 0), "caret-down"), new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_PAGE_UP, 0), "page-up"), new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_PAGE_DOWN, 0), "page-down"), new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_ENTER, 0), "insert-break"), new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_TAB, 0), "insert-tab") }, "EditorPane.margin", new InsetsUIResource(3, 3, 3, 3), "EditorPane.selectionBackground", new ColorUIResource(Color.black), "EditorPane.selectionForeground", new ColorUIResource(Color.white), "FileChooser.acceptAllFileFilterText", "All Files (*.*)", "FileChooser.ancestorInputMap", new UIDefaults.LazyInputMap(new Object[] { "ESCAPE", "cancelSelection" }), "FileChooser.cancelButtonMnemonic", new Integer(67), "FileChooser.cancelButtonText", "Cancel", "FileChooser.cancelButtonToolTipText", "Abort file chooser dialog", // XXX Don't use gif// "FileChooser.detailsViewIcon", new IconUIResource(new ImageIcon("icons/DetailsView.gif")), "FileChooser.directoryDescriptionText", "Directory", "FileChooser.fileDescriptionText", "Generic File", "FileChooser.helpButtonMnemonic", new Integer(72), "FileChooser.helpButtonText", "Help", "FileChooser.helpButtonToolTipText", "FileChooser help", // XXX Don't use gif// "FileChooser.homeFolderIcon", new IconUIResource(new ImageIcon("icons/HomeFolder.gif")), // XXX Don't use gif// "FileChooser.listViewIcon", new IconUIResource(new ImageIcon("icons/ListView.gif")), "FileChooser.newFolderErrorSeparator", ":", "FileChooser.newFolderErrorText", "Error creating new folder", // XXX Don't use gif// "FileChooser.newFolderIcon", new IconUIResource(new ImageIcon("icons/NewFolder.gif")), "FileChooser.openButtonMnemonic", new Integer(79), "FileChooser.openButtonText", "Open", "FileChooser.openButtonToolTipText", "Open selected file", "FileChooser.saveButtonMnemonic", new Integer(83), "FileChooser.saveButtonText", "Save", "FileChooser.saveButtonToolTipText", "Save selected file", // XXX Don't use gif// "FileChooser.upFolderIcon", new IconUIResource(new ImageIcon("icons/UpFolder.gif")), "FileChooser.updateButtonMnemonic", new Integer(85), "FileChooser.updateButtonText", "Update", "FileChooser.updateButtonToolTipText", "Update directory listing", // XXX Don't use gif// "FileView.computerIcon", new IconUIResource(new ImageIcon("icons/Computer.gif")), // XXX Don't use gif// "FileView.directoryIcon", new IconUIResource(new ImageIcon("icons/Directory.gif")), // XXX Don't use gif// "FileView.fileIcon", new IconUIResource(new ImageIcon("icons/File.gif")), // XXX Don't use gif// "FileView.floppyDriveIcon", new IconUIResource(new ImageIcon("icons/Floppy.gif")), // XXX Don't use gif// "FileView.hardDriveIcon", new IconUIResource(new ImageIcon("icons/HardDrive.gif")), "FocusManagerClassName", "TODO", "FormattedTextField.background", new ColorUIResource(light), "FormattedTextField.caretForeground", new ColorUIResource(Color.black), "FormattedTextField.foreground", new ColorUIResource(Color.black), "FormattedTextField.inactiveBackground", new ColorUIResource(light), "FormattedTextField.inactiveForeground", new ColorUIResource(Color.gray), "FormattedTextField.selectionBackground", new ColorUIResource(Color.black), "FormattedTextField.selectionForeground", new ColorUIResource(Color.white), "FormView.resetButtonText", "Reset", "FormView.submitButtonText", "Submit Query", "InternalFrame.activeTitleBackground", new ColorUIResource(0, 0, 128), "InternalFrame.activeTitleForeground", new ColorUIResource(Color.white), "InternalFrame.border", new UIDefaults.LazyValue() { public Object createValue(UIDefaults table) { Color lineColor = new Color(238, 238, 238); Border inner = BorderFactory.createLineBorder(lineColor, 1); Color shadowInner = new Color(184, 207, 229); Color shadowOuter = new Color(122, 138, 153); Border outer = BorderFactory.createBevelBorder(BevelBorder.RAISED, Color.WHITE, Color.WHITE, shadowOuter, shadowInner); Border border = new BorderUIResource.CompoundBorderUIResource(outer, inner); return border; } }, "InternalFrame.borderColor", new ColorUIResource(light), "InternalFrame.borderDarkShadow", new ColorUIResource(Color.BLACK), "InternalFrame.borderHighlight", new ColorUIResource(Color.WHITE), "InternalFrame.borderLight", new ColorUIResource(Color.LIGHT_GRAY), "InternalFrame.borderShadow", new ColorUIResource(Color.GRAY), "InternalFrame.closeIcon", BasicIconFactory.createEmptyFrameIcon(), // FIXME: Set a nice icon for InternalFrames here. "InternalFrame.icon", new UIDefaults.LazyValue() { public Object createValue(UIDefaults def) { return new IconUIResource(BasicIconFactory.createEmptyFrameIcon()); } }, "InternalFrame.iconifyIcon", BasicIconFactory.createEmptyFrameIcon(), "InternalFrame.inactiveTitleBackground", new ColorUIResource(Color.gray), "InternalFrame.inactiveTitleForeground", new ColorUIResource(Color.lightGray), "InternalFrame.maximizeIcon", BasicIconFactory.createEmptyFrameIcon(), "InternalFrame.minimizeIcon", BasicIconFactory.createEmptyFrameIcon(), "InternalFrame.titleFont", new FontUIResource("Dialog", Font.PLAIN, 12), "InternalFrame.windowBindings", new Object[] { "shift ESCAPE", "showSystemMenu", "ctrl SPACE", "showSystemMenu", "ESCAPE", "showSystemMenu" }, "Label.background", new ColorUIResource(light), "Label.disabledForeground", new ColorUIResource(Color.white), "Label.disabledShadow", new ColorUIResource(shadow), "Label.font", new FontUIResource("Dialog", Font.PLAIN, 12), "Label.foreground", new ColorUIResource(darkShadow), "List.background", new ColorUIResource(light), "List.border", new BasicBorders.MarginBorder(), "List.focusInputMap", new UIDefaults.LazyInputMap(new Object[] { "PAGE_UP", "scrollUp", "ctrl \\", "clearSelection", "PAGE_DOWN", "scrollDown", "shift PAGE_DOWN","scrollDownExtendSelection", "END", "selectLastRow", "HOME", "selectFirstRow", "shift END", "selectLastRowExtendSelection", "shift HOME", "selectFirstRowExtendSelection", "UP", "selectPreviousRow", "ctrl /", "selectAll", "ctrl A", "selectAll", "DOWN", "selectNextRow", "shift UP", "selectPreviousRowExtendSelection", "ctrl SPACE", "selectNextRowExtendSelection", "shift DOWN", "selectNextRowExtendSelection", "KP_UP", "selectPreviousRow", "shift PAGE_UP","scrollUpExtendSelection", "KP_DOWN", "selectNextRow" }), "List.foreground", new ColorUIResource(darkShadow), "List.selectionBackground", new ColorUIResource(Color.black), "List.selectionForeground", new ColorUIResource(Color.white), "List.focusCellHighlightBorder", new BorderUIResource. LineBorderUIResource(new ColorUIResource(Color.yellow)), "Menu.acceleratorFont", new FontUIResource("Dialog", Font.PLAIN, 12), "Menu.acceleratorForeground", new ColorUIResource(darkShadow), "Menu.acceleratorSelectionForeground", new ColorUIResource(Color.white), "Menu.arrowIcon", BasicIconFactory.getMenuArrowIcon(), "Menu.background", new ColorUIResource(light), "Menu.border", new BasicBorders.MarginBorder(), "Menu.borderPainted", Boolean.FALSE, "Menu.checkIcon", BasicIconFactory.getMenuItemCheckIcon(), "Menu.consumesTabs", Boolean.TRUE, "Menu.font", new FontUIResource("Dialog", Font.PLAIN, 12), "Menu.foreground", new ColorUIResource(darkShadow), "Menu.margin", new InsetsUIResource(2, 2, 2, 2), "Menu.selectedWindowInputMapBindings", new Object[] { "ESCAPE", "cancel", "DOWN", "selectNext", "KP_DOWN", "selectNext", "UP", "selectPrevious", "KP_UP", "selectPrevious", "LEFT", "selectParent", "KP_LEFT", "selectParent", "RIGHT", "selectChild", "KP_RIGHT", "selectChild", "ENTER", "return", "SPACE", "return" }, "Menu.selectionBackground", new ColorUIResource(Color.black), "Menu.selectionForeground", new ColorUIResource(Color.white), "MenuBar.background", new ColorUIResource(light), "MenuBar.border", new BasicBorders.MenuBarBorder(null, null), "MenuBar.font", new FontUIResource("Dialog", Font.PLAIN, 12), "MenuBar.foreground", new ColorUIResource(darkShadow), "MenuBar.highlight", new ColorUIResource(highLight), "MenuBar.shadow", new ColorUIResource(shadow), "MenuBar.windowBindings", new Object[] { "F10", "takeFocus" }, "MenuItem.acceleratorDelimiter", "-", "MenuItem.acceleratorFont", new FontUIResource("Dialog", Font.PLAIN, 12), "MenuItem.acceleratorForeground", new ColorUIResource(darkShadow), "MenuItem.acceleratorSelectionForeground", new ColorUIResource(Color.white), "MenuItem.arrowIcon", BasicIconFactory.getMenuItemArrowIcon(), "MenuItem.background", new ColorUIResource(light), "MenuItem.border", new BasicBorders.MarginBorder(), "MenuItem.borderPainted", Boolean.FALSE, "MenuItem.checkIcon", BasicIconFactory.getMenuItemCheckIcon(), "MenuItem.font", new FontUIResource("Dialog", Font.PLAIN, 12), "MenuItem.foreground", new ColorUIResource(darkShadow), "MenuItem.margin", new InsetsUIResource(2, 2, 2, 2), "MenuItem.selectionBackground", new ColorUIResource(Color.black), "MenuItem.selectionForeground", new ColorUIResource(Color.white), "OptionPane.background", new ColorUIResource(light), "OptionPane.border", new BorderUIResource.EmptyBorderUIResource(0, 0, 0, 0), "OptionPane.buttonAreaBorder", new BorderUIResource.EmptyBorderUIResource(0, 0, 0, 0), "OptionPane.cancelButtonText", "Cancel", // XXX Don't use gif// "OptionPane.errorIcon",// new IconUIResource(new ImageIcon("icons/Error.gif")), "OptionPane.font", new FontUIResource("Dialog", Font.PLAIN, 12), "OptionPane.foreground", new ColorUIResource(darkShadow), // XXX Don't use gif// "OptionPane.informationIcon",// new IconUIResource(new ImageIcon("icons/Inform.gif")), "OptionPane.messageAreaBorder", new BorderUIResource.EmptyBorderUIResource(0, 0, 0, 0), "OptionPane.messageForeground", new ColorUIResource(darkShadow), "OptionPane.minimumSize", new DimensionUIResource(262, 90), "OptionPane.noButtonText", "No", "OptionPane.okButtonText", "OK", // XXX Don't use gif// "OptionPane.questionIcon",// new IconUIResource(new ImageIcon("icons/Question.gif")), // XXX Don't use gif// "OptionPane.warningIcon",// new IconUIResource(new ImageIcon("icons/Warn.gif")), "OptionPane.windowBindings", new Object[] { "ESCAPE", "close" }, "OptionPane.yesButtonText", "Yes", "Panel.background", new ColorUIResource(light), "Panel.font", new FontUIResource("Dialog", Font.PLAIN, 12), "Panel.foreground", new ColorUIResource(Color.black), "PasswordField.background", new ColorUIResource(light), "PasswordField.border", new BasicBorders.FieldBorder(null, null, null, null), "PasswordField.caretBlinkRate", new Integer(500), "PasswordField.caretForeground", new ColorUIResource(Color.black), "PasswordField.font", new FontUIResource("MonoSpaced", Font.PLAIN, 12), "PasswordField.foreground", new ColorUIResource(Color.black), "PasswordField.inactiveBackground", new ColorUIResource(light), "PasswordField.inactiveForeground", new ColorUIResource(Color.gray), "PasswordField.keyBindings", new JTextComponent.KeyBinding[] { new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_ENTER, 0), "notify-field-accept")}, "PasswordField.margin", new InsetsUIResource(0, 0, 0, 0), "PasswordField.selectionBackground", new ColorUIResource(Color.black), "PasswordField.selectionForeground", new ColorUIResource(Color.white), "PopupMenu.background", new ColorUIResource(light), "PopupMenu.border", new BorderUIResource.BevelBorderUIResource(0), "PopupMenu.font", new FontUIResource("Dialog", Font.PLAIN, 12), "PopupMenu.foreground", new ColorUIResource(darkShadow), "ProgressBar.background", new ColorUIResource(light), "ProgressBar.border", new BorderUIResource.LineBorderUIResource(Color.darkGray), "ProgressBar.cellLength", new Integer(1), "ProgressBar.cellSpacing", new Integer(0), "ProgressBar.font", new FontUIResource("Dialog", Font.PLAIN, 12), "ProgressBar.foreground", new ColorUIResource(Color.black), "ProgressBar.selectionBackground", new ColorUIResource(Color.black), "ProgressBar.selectionForeground", new ColorUIResource(light), "ProgressBar.repaintInterval", new Integer(250), "ProgressBar.cycleTime", new Integer(6000), "RadioButton.background", new ColorUIResource(light), "RadioButton.border", new BorderUIResource.CompoundBorderUIResource(null, null), "RadioButton.darkShadow", new ColorUIResource(shadow), "RadioButton.focusInputMap", new UIDefaults.LazyInputMap(new Object[] { "SPACE", "pressed", "released SPACE", "released" }), "RadioButton.font", new FontUIResource("Dialog", Font.PLAIN, 12), "RadioButton.foreground", new ColorUIResource(darkShadow), "RadioButton.highlight", new ColorUIResource(highLight), "RadioButton.icon", new UIDefaults.LazyValue() { public Object createValue(UIDefaults def) { return BasicIconFactory.getRadioButtonIcon(); } }, "RadioButton.light", new ColorUIResource(highLight), "RadioButton.margin", new InsetsUIResource(2, 2, 2, 2), "RadioButton.shadow", new ColorUIResource(shadow), "RadioButton.textIconGap", new Integer(4), "RadioButton.textShiftOffset", new Integer(0), "RadioButtonMenuItem.acceleratorFont", new FontUIResource("Dialog", Font.PLAIN, 12), "RadioButtonMenuItem.acceleratorForeground", new ColorUIResource(darkShadow), "RadioButtonMenuItem.acceleratorSelectionForeground", new ColorUIResource(Color.white), "RadioButtonMenuItem.arrowIcon", BasicIconFactory.getMenuItemArrowIcon(), "RadioButtonMenuItem.background", new ColorUIResource(light), "RadioButtonMenuItem.border", new BasicBorders.MarginBorder(), "RadioButtonMenuItem.borderPainted", Boolean.FALSE, "RadioButtonMenuItem.checkIcon", BasicIconFactory.getRadioButtonMenuItemIcon(), "RadioButtonMenuItem.font", new FontUIResource("Dialog", Font.PLAIN, 12), "RadioButtonMenuItem.foreground", new ColorUIResource(darkShadow), "RadioButtonMenuItem.margin", new InsetsUIResource(2, 2, 2, 2), "RadioButtonMenuItem.selectionBackground", new ColorUIResource(Color.black), "RadioButtonMenuItem.selectionForeground", new ColorUIResource(Color.white), "RootPane.defaultButtonWindowKeyBindings", new Object[] { "ENTER", "press", "released ENTER", "release", "ctrl ENTER", "press", "ctrl released ENTER", "release" }, "ScrollBar.background", new ColorUIResource(224, 224, 224), "ScrollBar.focusInputMap", new UIDefaults.LazyInputMap(new Object[] { "PAGE_UP", "negativeBlockIncrement", "PAGE_DOWN", "positiveBlockIncrement", "END", "maxScroll", "HOME", "minScroll", "LEFT", "positiveUnitIncrement", "KP_UP", "negativeUnitIncrement", "KP_DOWN", "positiveUnitIncrement", "UP", "negativeUnitIncrement", "RIGHT", "negativeUnitIncrement", "KP_LEFT", "positiveUnitIncrement", "DOWN", "positiveUnitIncrement", "KP_RIGHT", "negativeUnitIncrement" }), "ScrollBar.foreground", new ColorUIResource(light), "ScrollBar.maximumThumbSize", new DimensionUIResource(4096, 4096), "ScrollBar.minimumThumbSize", new DimensionUIResource(8, 8), "ScrollBar.thumb", new ColorUIResource(light), "ScrollBar.thumbDarkShadow", new ColorUIResource(shadow), "ScrollBar.thumbHighlight", new ColorUIResource(highLight), "ScrollBar.thumbShadow", new ColorUIResource(shadow), "ScrollBar.track", new ColorUIResource(light), "ScrollBar.trackHighlight", new ColorUIResource(shadow), "ScrollPane.ancestorInputMap", new UIDefaults.LazyInputMap(new Object[] { "PAGE_UP", "scrollUp", "KP_LEFT", "unitScrollLeft", "ctrl PAGE_DOWN","scrollRight", "PAGE_DOWN", "scrollDown", "KP_RIGHT", "unitScrollRight", "LEFT", "unitScrollLeft", "ctrl END", "scrollEnd", "UP", "unitScrollUp", "RIGHT", "unitScrollRight", "DOWN", "unitScrollDown", "ctrl HOME", "scrollHome", "ctrl PAGE_UP", "scrollLeft", "KP_UP", "unitScrollUp", "KP_DOWN", "unitScrollDown" }), "ScrollPane.background", new ColorUIResource(light), "ScrollPane.border", new BorderUIResource.EtchedBorderUIResource(), "ScrollPane.font", new FontUIResource("Dialog", Font.PLAIN, 12), "ScrollPane.foreground", new ColorUIResource(darkShadow), "Separator.background", new ColorUIResource(highLight), "Separator.foreground", new ColorUIResource(shadow), "Separator.highlight", new ColorUIResource(highLight), "Separator.shadow", new ColorUIResource(shadow), "Slider.background", new ColorUIResource(light), "Slider.focus", new ColorUIResource(shadow), "Slider.focusInputMap", new UIDefaults.LazyInputMap(new Object[] { "PAGE_UP", "positiveBlockIncrement", "PAGE_DOWN", "negativeBlockIncrement", "END", "maxScroll", "HOME", "minScroll", "LEFT", "negativeUnitIncrement", "KP_UP", "positiveUnitIncrement", "KP_DOWN", "negativeUnitIncrement", "UP", "positiveUnitIncrement", "RIGHT", "positiveUnitIncrement", "KP_LEFT", "negativeUnitIncrement", "DOWN", "negativeUnitIncrement", "KP_RIGHT", "positiveUnitIncrement" }), "Slider.focusInsets", new InsetsUIResource(2, 2, 2, 2), "Slider.foreground", new ColorUIResource(light), "Slider.highlight", new ColorUIResource(highLight), "Slider.shadow", new ColorUIResource(shadow), "Slider.thumbHeight", new Integer(20), "Slider.thumbWidth", new Integer(11), "Slider.tickHeight", new Integer(12), "Spinner.background", new ColorUIResource(light), "Spinner.foreground", new ColorUIResource(light), "SplitPane.ancestorInputMap", new UIDefaults.LazyInputMap(new Object[] { "F6", "toggleFocus", "F8", "startResize", "END", "selectMax", "HOME", "selectMin", "LEFT", "negativeIncremnent", "KP_UP", "negativeIncrement", "KP_DOWN", "positiveIncrement", "UP", "negativeIncrement", "RIGHT", "positiveIncrement", "KP_LEFT", "negativeIncrement", "DOWN", "positiveIncrement", "KP_RIGHT", "positiveIncrement" }), "SplitPane.background", new ColorUIResource(light), "SplitPane.border", new BasicBorders.SplitPaneBorder(null, null), "SplitPane.darkShadow", new ColorUIResource(shadow), "SplitPane.dividerSize", new Integer(10), "SplitPane.highlight", new ColorUIResource(highLight), "SplitPane.shadow", new ColorUIResource(shadow), "TabbedPane.ancestorInputMap", new UIDefaults.LazyInputMap(new Object[] { "ctrl PAGE_DOWN","navigatePageDown", "ctrl PAGE_UP", "navigatePageUp", "ctrl UP", "requestFocus", "ctrl KP_UP", "requestFocus" }), "TabbedPane.background", new ColorUIResource(light), "TabbedPane.contentBorderInsets", new InsetsUIResource(2, 2, 3, 3), "TabbedPane.darkShadow", new ColorUIResource(shadow), "TabbedPane.focus", new ColorUIResource(darkShadow), "TabbedPane.focusInputMap", new UIDefaults.LazyInputMap(new Object[] { "LEFT", "navigateLeft", "KP_UP", "navigateUp", "ctrl DOWN", "requestFocusForVisibleComponent", "UP", "navigateUp", "KP_DOWN", "navigateDown", "RIGHT", "navigateRight", "KP_LEFT", "navigateLeft", "ctrl KP_DOWN", "requestFocusForVisibleComponent", "KP_RIGHT", "navigateRight", "DOWN", "navigateDown" }), "TabbedPane.font", new FontUIResource("Dialog", Font.PLAIN, 12), "TabbedPane.foreground", new ColorUIResource(darkShadow), "TabbedPane.highlight", new ColorUIResource(highLight), "TabbedPane.light", new ColorUIResource(highLight), "TabbedPane.selectedTabPadInsets", new InsetsUIResource(2, 2, 2, 1), "TabbedPane.shadow", new ColorUIResource(shadow), "TabbedPane.tabbedPaneTabAreaInsets", new InsetsUIResource(3, 2, 1, 2), "TabbedPane.tabbedPaneTabInsets", new InsetsUIResource(1, 4, 1, 4), "TabbedPane.tabbedPaneContentBorderInsets", new InsetsUIResource(3, 2, 1, 2), "TabbedPane.tabbedPaneTabPadInsets", new InsetsUIResource(1, 1, 1, 1), "TabbedPane.tabRunOverlay", new Integer(2), "TabbedPane.textIconGap", new Integer(4), "Table.ancestorInputMap", new UIDefaults.LazyInputMap(new Object[] { "shift PAGE_DOWN","scrollDownExtendSelection", "PAGE_DOWN", "scrollDownChangeSelection", "END", "selectLastColumn", "shift END", "selectLastColumnExtendSelection", "HOME", "selectFirstColumn", "ctrl END", "selectLastRow", "ctrl shift END","selectLastRowExtendSelection", "LEFT", "selectPreviousColumn", "shift HOME", "selectFirstColumnExtendSelection", "UP", "selectPreviousRow", "RIGHT", "selectNextColumn", "ctrl HOME", "selectFirstRow", "shift LEFT", "selectPreviousColumnExtendSelection", "DOWN", "selectNextRow", "ctrl shift HOME","selectFirstRowExtendSelection", "shift UP", "selectPreviousRowExtendSelection", "F2", "startEditing", "shift RIGHT", "selectNextColumnExtendSelection", "TAB", "selectNextColumnCell", "shift DOWN", "selectNextRowExtendSelection", "ENTER", "selectNextRowCell", "KP_UP", "selectPreviousRow", "KP_DOWN", "selectNextRow", "KP_LEFT", "selectPreviousColumn", "KP_RIGHT", "selectNextColumn", "shift TAB", "selectPreviousColumnCell", "ctrl A", "selectAll", "shift ENTER", "selectPreviousRowCell", "shift KP_DOWN", "selectNextRowExtendSelection", "shift KP_LEFT", "selectPreviousColumnExtendSelection", "ESCAPE", "cancel", "ctrl shift PAGE_UP", "scrollRightExtendSelection", "shift KP_RIGHT", " selectNextColumnExtendSelection", "ctrl PAGE_UP", "scrollLeftChangeSelection", "shift PAGE_UP", "scrollUpExtendSelection", "ctrl shift PAGE_DOWN", "scrollLeftExtendSelection", "ctrl PAGE_DOWN", "scrollRightChangeSelection", "PAGE_UP", "scrollUpChangeSelection" }), "Table.background", new ColorUIResource(light), "Table.focusCellBackground", new ColorUIResource(light), "Table.focusCellForeground", new ColorUIResource(darkShadow), "Table.focusCellHighlightBorder", new BorderUIResource.LineBorderUIResource( new ColorUIResource(255, 255, 0)), "Table.font", new FontUIResource("Dialog", Font.PLAIN, 12), "Table.foreground", new ColorUIResource(darkShadow), "Table.gridColor", new ColorUIResource(Color.gray), "Table.scrollPaneBorder", new BorderUIResource.BevelBorderUIResource(0), "Table.selectionBackground", new ColorUIResource(Color.black), "Table.selectionForeground", new ColorUIResource(Color.white), "TableHeader.background", new ColorUIResource(light), "TableHeader.cellBorder", new BorderUIResource.BevelBorderUIResource(0), "TableHeader.font", new FontUIResource("Dialog", Font.PLAIN, 12), "TableHeader.foreground", new ColorUIResource(darkShadow), "TextArea.background", new ColorUIResource(light), "TextArea.border", new BasicBorders.MarginBorder(), "TextArea.caretBlinkRate", new Integer(500), "TextArea.caretForeground", new ColorUIResource(Color.black), "TextArea.font", new FontUIResource("MonoSpaced", Font.PLAIN, 12), "TextArea.foreground", new ColorUIResource(Color.black), "TextArea.inactiveForeground", new ColorUIResource(Color.gray), "TextArea.keyBindings", new JTextComponent.KeyBinding[] { new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_UP, 0), "caret-up"), new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_DOWN, 0), "caret-down"), new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_PAGE_UP, 0), "page-up"), new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_PAGE_DOWN, 0), "page-down"), new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_ENTER, 0), "insert-break"), new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_TAB, 0), "insert-tab") }, "TextArea.margin", new InsetsUIResource(0, 0, 0, 0), "TextArea.selectionBackground", new ColorUIResource(Color.black), "TextArea.selectionForeground", new ColorUIResource(Color.white), "TextField.background", new ColorUIResource(light), "TextField.border", new BasicBorders.FieldBorder(null, null, null, null), "TextField.caretBlinkRate", new Integer(500), "TextField.caretForeground", new ColorUIResource(Color.black), "TextField.darkShadow", new ColorUIResource(shadow), "TextField.font", new FontUIResource("SansSerif", Font.PLAIN, 12), "TextField.foreground", new ColorUIResource(Color.black), "TextField.highlight", new ColorUIResource(highLight), "TextField.inactiveBackground", new ColorUIResource(light), "TextField.inactiveForeground", new ColorUIResource(Color.gray), "TextField.light", new ColorUIResource(highLight), "TextField.highlight", new ColorUIResource(light), "TextField.keyBindings", new JTextComponent.KeyBinding[] { new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_ENTER, 0), "notify-field-accept"), new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_LEFT, InputEvent.SHIFT_DOWN_MASK), "selection-backward"), new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_RIGHT, InputEvent.SHIFT_DOWN_MASK), "selection-forward"), }, "TextField.margin", new InsetsUIResource(0, 0, 0, 0), "TextField.selectionBackground", new ColorUIResource(Color.black), "TextField.selectionForeground", new ColorUIResource(Color.white), "TextPane.background", new ColorUIResource(Color.white), "TextPane.border", new BasicBorders.MarginBorder(), "TextPane.caretBlinkRate", new Integer(500), "TextPane.caretForeground", new ColorUIResource(Color.black), "TextPane.font", new FontUIResource("Serif", Font.PLAIN, 12), "TextPane.foreground", new ColorUIResource(Color.black), "TextPane.inactiveForeground", new ColorUIResource(Color.gray), "TextPane.keyBindings", new JTextComponent.KeyBinding[] { new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_UP, 0), "caret-up"), new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_DOWN, 0), "caret-down"), new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_PAGE_UP, 0), "page-up"), new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_PAGE_DOWN, 0), "page-down"), new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_ENTER, 0), "insert-break"), new JTextComponent.KeyBinding(KeyStroke.getKeyStroke(KeyEvent.VK_TAB, 0), "insert-tab") }, "TextPane.margin", new InsetsUIResource(3, 3, 3, 3), "TextPane.selectionBackground", new ColorUIResource(Color.black), "TextPane.selectionForeground", new ColorUIResource(Color.white), "TitledBorder.border", new BorderUIResource.EtchedBorderUIResource(), "TitledBorder.font", new FontUIResource("Dialog", Font.PLAIN, 12), "TitledBorder.titleColor", new ColorUIResource(darkShadow), "ToggleButton.background", new ColorUIResource(light), "ToggleButton.border", new BorderUIResource.CompoundBorderUIResource(null, null), "ToggleButton.darkShadow", new ColorUIResource(shadow), "ToggleButton.focusInputMap", new UIDefaults.LazyInputMap(new Object[] { "SPACE", "pressed", "released SPACE", "released" }), "ToggleButton.font", new FontUIResource("Dialog", Font.PLAIN, 12), "ToggleButton.foreground", new ColorUIResource(darkShadow), "ToggleButton.highlight", new ColorUIResource(highLight), "ToggleButton.light", new ColorUIResource(light), "ToggleButton.margin", new InsetsUIResource(2, 14, 2, 14), "ToggleButton.shadow", new ColorUIResource(shadow), "ToggleButton.textIconGap", new Integer(4), "ToggleButton.textShiftOffset", new Integer(0), "ToolBar.ancestorInputMap", new UIDefaults.LazyInputMap(new Object[] { "UP", "navigateUp", "KP_UP", "navigateUp", "DOWN", "navigateDown", "KP_DOWN", "navigateDown", "LEFT", "navigateLeft", "KP_LEFT", "navigateLeft", "RIGHT", "navigateRight", "KP_RIGHT", "navigateRight" }), "ToolBar.background", new ColorUIResource(light), "ToolBar.border", new BorderUIResource.EtchedBorderUIResource(), "ToolBar.darkShadow", new ColorUIResource(shadow), "ToolBar.dockingBackground", new ColorUIResource(light), "ToolBar.dockingForeground", new ColorUIResource(Color.red), "ToolBar.floatingBackground", new ColorUIResource(light), "ToolBar.floatingForeground", new ColorUIResource(Color.darkGray), "ToolBar.font", new FontUIResource("Dialog", Font.PLAIN, 12), "ToolBar.foreground", new ColorUIResource(darkShadow), "ToolBar.highlight", new ColorUIResource(highLight), "ToolBar.light", new ColorUIResource(highLight), "ToolBar.separatorSize", new DimensionUIResource(20, 20), "ToolBar.shadow", new ColorUIResource(shadow), "ToolTip.background", new ColorUIResource(light), "ToolTip.border", new BorderUIResource.LineBorderUIResource(Color.lightGray), "ToolTip.font", new FontUIResource("SansSerif", Font.PLAIN, 12), "ToolTip.foreground", new ColorUIResource(darkShadow), "Tree.ancestorInputMap", new UIDefaults.LazyInputMap(new Object[] { "ESCAPE", "cancel" }), "Tree.background", new ColorUIResource(light), "Tree.changeSelectionWithFocus", Boolean.TRUE,// "Tree.closedIcon", new IconUIResource(new ImageIcon("icons/TreeClosed.png")),// "Tree.collapsedIcon", new IconUIResource(new ImageIcon("icons/TreeCollapsed.png")), "Tree.drawsFocusBorderAroundIcon", Boolean.FALSE, "Tree.editorBorder", new BorderUIResource.LineBorderUIResource(Color.lightGray), "Tree.focusInputMap", new UIDefaults.LazyInputMap(new Object[] { "shift PAGE_DOWN", "scrollDownExtendSelection", "PAGE_DOWN", "scrollDownChangeSelection", "END", "selectLast", "ctrl KP_UP", "selectPreviousChangeLead", "shift END", "selectLastExtendSelection", "HOME", "selectFirst", "ctrl END", "selectLastChangeLead", "ctrl /", "selectAll", "LEFT", "selectParent", "shift HOME", "selectFirstExtendSelection", "UP", "selectPrevious", "ctrl KP_DOWN", "selectNextChangeLead", "RIGHT", "selectChild", "ctrl HOME", "selectFirstChangeLead", "DOWN", "selectNext", "ctrl KP_LEFT", "scrollLeft", "shift UP", "selectPreviousExtendSelection", "F2", "startEditing", "ctrl LEFT", "scrollLeft", "ctrl KP_RIGHT","scrollRight", "ctrl UP", "selectPreviousChangeLead", "shift DOWN", "selectNextExtendSelection", "ENTER", "toggle", "KP_UP", "selectPrevious", "KP_DOWN", "selectNext", "ctrl RIGHT", "scrollRight", "KP_LEFT", "selectParent", "KP_RIGHT", "selectChild", "ctrl DOWN", "selectNextChangeLead", "ctrl A", "selectAll", "shift KP_UP", "selectPreviousExtendSelection", "shift KP_DOWN","selectNextExtendSelection", "ctrl SPACE", "toggleSelectionPreserveAnchor", "ctrl shift PAGE_UP", "scrollUpExtendSelection", "ctrl \\", "clearSelection", "shift SPACE", "extendSelection", "ctrl PAGE_UP", "scrollUpChangeLead", "shift PAGE_UP","scrollUpExtendSelection", "SPACE", "toggleSelectionPreserveAnchor", "ctrl shift PAGE_DOWN", "scrollDownExtendSelection", "PAGE_UP", "scrollUpChangeSelection", "ctrl PAGE_DOWN", "scrollDownChangeLead" }), "Tree.font", new FontUIResource(new Font("Helvetica", Font.PLAIN, 12)), "Tree.foreground", new ColorUIResource(Color.black), "Tree.hash", new ColorUIResource(new Color(128, 128, 128)), "Tree.leftChildIndent", new Integer(7), "Tree.rightChildIndent", new Integer(13), "Tree.rowHeight", new Integer(20), // FIXME "Tree.scrollsOnExpand", Boolean.TRUE, "Tree.selectionBackground", new ColorUIResource(Color.black), "Tree.nonSelectionBackground", new ColorUIResource(new Color(239, 235, 231)), "Tree.selectionBorderColor", new ColorUIResource(Color.black), "Tree.selectionForeground", new ColorUIResource(new Color(255, 255, 255)), "Tree.textBackground", new ColorUIResource(new Color(255, 255, 255)), "Tree.textForeground", new ColorUIResource(Color.black), "Viewport.background", new ColorUIResource(light), "Viewport.foreground", new ColorUIResource(Color.black), "Viewport.font", new FontUIResource("Dialog", Font.PLAIN, 12) }; defaults.putDefaults(uiDefaults); }
public long getAtime() {
public synchronized long getAtime() {
public long getAtime() { return Ext2Utils.get32(data, 8); }
public long getBlocks() {
public synchronized long getBlocks() {
public long getBlocks() { return Ext2Utils.get32(data, 28); }
public long getCtime() {
public synchronized long getCtime() {
public long getCtime() { return Ext2Utils.get32(data, 12); }
public long getDirACL() {
public synchronized long getDirACL() {
public long getDirACL() { return Ext2Utils.get32(data, 108); }
public long getDtime() {
public synchronized long getDtime() {
public long getDtime() { return Ext2Utils.get32(data, 20); }
public long getFAddr() {
public synchronized long getFAddr() {
public long getFAddr() { return Ext2Utils.get32(data, 112); }
public long getFileACL() {
public synchronized long getFileACL() {
public long getFileACL() { return Ext2Utils.get32(data, 104); }
public long getFlags() {
public synchronized long getFlags() {
public long getFlags() { return Ext2Utils.get32(data, 32); }
public long getGeneration() {
public synchronized long getGeneration() {
public long getGeneration() { return Ext2Utils.get32(data, 100); }
public int getGid() {
public synchronized int getGid() {
public int getGid() { return Ext2Utils.get16(data, 24); }
public int getLinksCount() {
public synchronized int getLinksCount() {
public int getLinksCount() { return Ext2Utils.get16(data, 26); }
public int getMode() {
public synchronized int getMode() {
public int getMode() { int iMode=Ext2Utils.get16(data, 0); //log.debug("INode.getIMode(): "+Ext2Print.hexFormat(iMode)); return iMode; }
public long getMtime() {
public synchronized long getMtime() {
public long getMtime() { return Ext2Utils.get32(data, 16); }
public long getOSD1() {
public synchronized long getOSD1() {
public long getOSD1() { return Ext2Utils.get32(data, 36); }
public long getSize() {
public synchronized long getSize() {
public long getSize() { return Ext2Utils.get32(data, 4); }
public int getUid() {
public synchronized int getUid() {
public int getUid() { return Ext2Utils.get16(data, 2); }
public void setAtime(long atime) {
public synchronized void setAtime(long atime) {
public void setAtime(long atime) { Ext2Utils.set32(data, 8, atime); setDirty(true); }
public void setBlocks(long count) {
public synchronized void setBlocks(long count) {
public void setBlocks(long count) { log.debug("setBlocks("+count+")"); Ext2Utils.set32(data, 28, count); setDirty(true); }
public void setCtime(long ctime) {
public synchronized void setCtime(long ctime) {
public void setCtime(long ctime) { Ext2Utils.set32(data, 12, ctime); setDirty(true); }
public void setDirACL(long acl) {
public synchronized void setDirACL(long acl) {
public void setDirACL(long acl) { Ext2Utils.set32(data, 108, acl); setDirty(true); }
public void setDtime(long dtime) {
public synchronized void setDtime(long dtime) {
public void setDtime(long dtime) { Ext2Utils.set32(data, 20, dtime); setDirty(true); }
public void setFAddr(long faddr) {
public synchronized void setFAddr(long faddr) {
public void setFAddr(long faddr) { Ext2Utils.set32(data, 112, faddr); setDirty(true); }
public void setFileACL(long acl) {
public synchronized void setFileACL(long acl) {
public void setFileACL(long acl) { Ext2Utils.set32(data, 104, acl); setDirty(true); }