This week's book giveaway is in the OCMJEA forum. We're giving away four copies of OCM Java EE 6 Enterprise Architect Exam Guide and have Paul Allen & Joseph Bambara on-line! See this thread for details.
Which one is better for performance, JLabel or drawString? drawString is using Java2D, obviously. My hypothesis is JLabel. How much performance will I gain from moving from the worse one to the better one?
“Don’t worry if it doesn’t work right. If everything did, you’d be out of a job.” (Mosher's Law of Software Engineering)
“If debugging is the process of removing bugs, then programming must be the process of putting them in.” (Edsger Dijkstra)
I think you're more likely to get a useful response in the GUI forums, so I'll move this thread there.
Personal opinion though - I don't think performance is all that relevant. If a JLabel is appropriate it has all sorts of advantages regarding consistent look-and-fee, accessibility features, correct behaviour when used with layout managers compared to just drawing the string like a graphic.