GUI Flashcards

1
Q

Graphical User Interfaces (GUI’s) are made up of components such as buttons, text fields, labels, etc.
To hold these components, we need to create some sort of ____ ____?

A

container object. A container object is designed to hold other GUI objects. (T!)

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

Which panes are created automatically when you creat a JFrame object?

A

JLayeredPane (holds menu bar object)

Content pane

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

Screen co-ordinates start at the?

A

upper left hand corner of the screen.
X values increase from left to right
Y values increase from top to bottom of the screen

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

What is a layout manager?

A

Layout managers are utility classes that are part of the original java.AWT package.
They are used to control the placement of components within containers such as JFrames or JPanels according to some pre-defined patterns.
All layout manager classes implement the methods contained in the interface called LayoutManager (look it up in the Java docs!)
A layout manager will take into account things like current screen resolution, size of components, and how they are to be laid out, and will do all of the positioning grunt work for you.
If the app user changes the screen resolution on their device, the layout manager will look after revising thing based on the new resolution setting when the app is loaded.

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

What is the default layout of a JFrame?

A

divided into five zones: North, South, East, West and center

Each zone can hold one component. If you put more than one component in a zone, only the last one will be visible.

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

What is stored in javax.swing

A

all the gui objects

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

what is stored in java.awt

A

layout managers

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