Chapter 18 Flashcards

1
Q

What is java applet

A

An applet is a small Internet-based program written in Java, which can be downloaded by any computer. The applet is also able to run in HTML. The applet is usually embedded in an HTML page on a Web site and can be executed from within a browser.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

Can java components redraw themselves when dealing with graphics in java

A

Yes

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

Does mostly repaint happen automatically

A

Yes

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

What is main method for painting

A

paintComponent()

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

Should we override paintBorder() or paintChildren() methods

A

No

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

How we call parent class method from child class

A

with super keyword e.g. super.paintComponent(g);

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

What draw and fill methods do

A

draw method make object with border only and fill method fill the color

How well did you know this?
1
Not at all
2
3
4
5
Perfectly