Bug 601 : Autoformat fails on color values
Last modified: 2007-07-27 19:36




Status:
RESOLVED
Resolution:
DUPLICATE of bug 303
Priority:
P2
Severity:
normal

 

Reporter:
rgovostes
Assigned To:
fry

Attachment Type Created Size Actions

Description:   Opened: 2007-07-25 18:17
As of 0125:

void test() {
stroke(#000000);
}

Auto format chokes on this, saying there are too many left parentheses (although how it
would arrive at this answer anyway is unknown to me, there could be too few right
parentheses!).

The problem is the same with any hex value on any function.

Interestingly, if you have "frameRate(#000000);" on its own line and nothing else in the
entire sketch, it spits out the descriptive error "1024" and:













java.lang.ArrayIndexOutOfBoundsException: 1024
at processing.app.tools.AutoFormat.show(AutoFormat.java:792)
at processing.app.Editor$17.actionPerformed(Editor.java:683)
at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:1819)
at
javax.swing.AbstractButton$ForwardActionEvents.actionPerformed(AbstractButton.java:1872)
at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:420)
at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:258)
at javax.swing.AbstractButton.doClick(AbstractButton.java:321)
at apple.laf.ScreenMenuItem.actionPerformed(ScreenMenuItem.java:104)
at java.awt.MenuItem.processActionEvent(MenuItem.java:589)
at java.awt.MenuItem.processEvent(MenuItem.java:548)
at java.awt.MenuComponent.dispatchEventImpl(MenuComponent.java:285)
at java.awt.MenuComponent.dispatchEvent(MenuComponent.java:273)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:483)
at
java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchThread.java:234)
at
java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:184)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:178)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:170)
at java.awt.EventDispatchThread.run(EventDispatchThread.java:100)
Additional Comment #1 From fry 2007-07-27 19:36
i'll be ripping out the autoformatter for a proper formatting tool in the
release that has the new "tools" menu. currently, that's set for 0127, but
may be later.

*** This bug has been marked as a duplicate of 303 ***