No "Form Main" option in generate main for class bound to swing form
Answered
Hi there,
I created a Swing GUI form with a bound class, and made sure the root JPanel in the form has a field name. Now, in the bound class, I'm trying to use Command-N (I'm on a Mac) to generate the Form Main. However, I don't see this option anywhere. Tried to create a new form and bound class, but the option still wouldn't show up.
Also tried to type the code manually (which I got from https://www.jetbrains.com/help/idea/15.0/creating-and-disposing-of-a-form-s-runtime-frame.html?origin=old_help) but my bound class doesn't have a 'contentPane' field.
Would appreciate some help.

Please sign in to leave a comment.
You need to bind class to a form and then bind root JPanel to a field:
You will see the indicators in the left gutter showing that the class and the field are bound to form components.
Then there will be Form Main in the Generate menu.
I've bound the form:
And the field
But no gutters, and no "form main" in generate menu:
Please share a sample project to reproduce the problem.
Please find here a sample project with the same problem, thanks.
https://dl.dropboxusercontent.com/u/2477812/SampleProject.zip
This project doesn't reproduce the problem:
Please share idea.log (https://intellij-support.jetbrains.com/hc/articles/207241085).
Very strange... the exact same project I've shared does not show that option on my machine. Please find below idea.log as requested:
https://dl.dropboxusercontent.com/u/2477812/IntelliJLogs.zip
Try to uninstall Multimarkdown plug-in: http://www.jetbrains.com/idea/webhelp/enabling-and-disabling-plugins.html.
If it doesn't help, try disabling other third-party plug-ins as well.
You can also try 2016.1 release: http://www.jetbrains.com/idea/download/index.html.
Thanks so much Serge. I upgraded to 2016.1 and uninstalled Multimarkdown but that didn't help - but then I disabled the Gauge plugin (https://plugins.jetbrains.com/plugin/7535?pr=idea) and that did the trick!