Starting out with Java - Chapter 13 Questions
and Answers| Latest Update
A ____ is like a TextField that can accept multiple lines of input.
A. TextArea
B. MultilineTextField
C. ExpandableTextField
D. TextEditorField ✔️✔️A. TextArea
You use this class to create a menu bar.
A. MenuItem
B. MenuBar
C. Menu
D. Bar ✔️✔️B. MenuBar
You use this class to create a radio menu item.
A. MenuItem
B. RadioButton
C. RadioItem
D. RadioMenuItem ✔️✔️D. RadioMenuItem
TRUE OR FALSE: If you make any changes to an application's stylesheet, you have to recompile
the Java application in order for the style changes to take effect. ✔️✔️False
TRUE OR FALSE: If a style definition for a specific type of node contradicts a style rule in the
.root definition, the more specific style definition takes precedence over the .root definition.
✔️✔️True
, TRUE OR FALSE: You can list only one selector in the first line of a style definition. ✔️✔️False
TRUE OR FALSE: A node's setStyle method removes any styles that were previously applied to
the node, and replaces them with the new style rule that is passed as an argument. ✔️✔️True
TRUE OR FALSE: A scroll bar automatically appears when a ListView contains more items than
can be displayed in the space provided. ✔️✔️True
TRUE OR FALSE: By default, ListView controls are oriented horizontally. ✔️✔️False
TRUE OR FALSE: By default, TextArea controls perform line wrapping. ✔️✔️False
TRUE OR FALSE: A MenuBar object acts as a container for Menu objects. ✔️✔️True
TRUE OR FALSE: A Menu object cannot contain other Menu objects. ✔️✔️False
When a selector name starts with a period in a JavaFX CSS style definition, it means the selector
corresponds to ____.
A. specific variable names in the application
B. specific types of JavaFX nodes
C. values that the user enters
D. named constants in the application ✔️✔️B. specific types of JavaFX nodes
Which of these is written in the correct syntax for a CSS style definition?
A. {.label: -fx-font-size: 20pt; }
B. .label { -fx-font-size=20pt; }
C. .label { -fx-font-size: 20pt; }
and Answers| Latest Update
A ____ is like a TextField that can accept multiple lines of input.
A. TextArea
B. MultilineTextField
C. ExpandableTextField
D. TextEditorField ✔️✔️A. TextArea
You use this class to create a menu bar.
A. MenuItem
B. MenuBar
C. Menu
D. Bar ✔️✔️B. MenuBar
You use this class to create a radio menu item.
A. MenuItem
B. RadioButton
C. RadioItem
D. RadioMenuItem ✔️✔️D. RadioMenuItem
TRUE OR FALSE: If you make any changes to an application's stylesheet, you have to recompile
the Java application in order for the style changes to take effect. ✔️✔️False
TRUE OR FALSE: If a style definition for a specific type of node contradicts a style rule in the
.root definition, the more specific style definition takes precedence over the .root definition.
✔️✔️True
, TRUE OR FALSE: You can list only one selector in the first line of a style definition. ✔️✔️False
TRUE OR FALSE: A node's setStyle method removes any styles that were previously applied to
the node, and replaces them with the new style rule that is passed as an argument. ✔️✔️True
TRUE OR FALSE: A scroll bar automatically appears when a ListView contains more items than
can be displayed in the space provided. ✔️✔️True
TRUE OR FALSE: By default, ListView controls are oriented horizontally. ✔️✔️False
TRUE OR FALSE: By default, TextArea controls perform line wrapping. ✔️✔️False
TRUE OR FALSE: A MenuBar object acts as a container for Menu objects. ✔️✔️True
TRUE OR FALSE: A Menu object cannot contain other Menu objects. ✔️✔️False
When a selector name starts with a period in a JavaFX CSS style definition, it means the selector
corresponds to ____.
A. specific variable names in the application
B. specific types of JavaFX nodes
C. values that the user enters
D. named constants in the application ✔️✔️B. specific types of JavaFX nodes
Which of these is written in the correct syntax for a CSS style definition?
A. {.label: -fx-font-size: 20pt; }
B. .label { -fx-font-size=20pt; }
C. .label { -fx-font-size: 20pt; }