Reputation: 1
One of my students is using processing in IntelliJ on a Mac. We set it up using the same steps I used on my PC (Works on my PC), but now it gives me an error stating that the filename should be Scratch.java, but it already is (see attached photo).
What could be causing this? We tried a computer restart and we're getting the same error still.
Upvotes: 0
Views: 62
Reputation: 71
You need to remove public
from your class definition.
From: public class Scratch extends PApplet
To: class Scratch extends PApplet
It seems that is because the file is located under the Scratches and Consoles dir. More info about intelliJ's scratch here. If you place it under the src directory, it can be public.
Upvotes: 1
Reputation: 526
have you tried rewriting the class name and renaming the file again, perhaps a charset encoding problem ? Or like LppEdd says cleaning cache and restarting IDEA, hope it helps
Upvotes: 0