• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

applets-urgent

 
pasan gamage
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
1.
why should we call repaint rather than calling paint
2.
what is the precedendce of arithmetic operators
ex: (a*b)-c/2
 
Manfred Leonhardt
Ranch Hand
Posts: 1492
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Pasan,
I already warned you about using URGENT when these are just questions that don't require urgency ...
Repaint creates a thread which then performs the painting as an thread. If you call paint directly you are just performing it sequencially which might give unexpected results.
Arithmetric operators have precedence. My advice, get a book on java and start reading. This is usually discussed in the first 1 or 2 chapters ...
Regards,
Manfred.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic