Issue
I know that with Ctrl + Shift + I, one can fix imports easily in Netbeans.
Can Netbeans configured in a way that
- rather than importing com.google.gwt.user.client.ui.HTML,
- it will import com.google.gwt.user.client.ui.*.
Hence, my code lines will be decreased.
Solution
Navigate to Tools > Options > Editor > Formatting, then select Language: Java and Category: Imports. Finally, select the option Use Package Imports, and then click Apply:
Be aware that this configuration change will affect all of your projects; I don't think it can be set at the project level. Also, note that while the approach you are choosing certainly may reduce the number of lines in your source, it is more usual to have a separate import for each class.
Answered By - skomisa
Answer Checked By - Mildred Charles (JavaFixing Admin)