Docsity

JavaFX Programming: Revision Questions and Answers, Exams of Computer Programming

Toggle sidebar
bg1
Starting out with Java - Chapter 13 Revision
Questions
A ____ is like a TextField that can accept multiple lines of input.
A. TextArea
B. MultilineTextField
C. ExpandableTextField
D. TextEditorField โœ“A. TextArea
Adding RadioButton controls to this type of object creates a mutually
exclusive relationship between them.
A. MutualExclude
B. RadioGroup
C. LogicalGroup
D. ToggleGroup โœ“D. ToggleGroup
Both the ListView control and the ComboBox control keeps its list of items
in a(n) ____object.
A. ArrayList
B. ExpandableList
C. ItemList
D. ObservableList โœ“D. ObservableList
If you want to apply styles to all of the nodes in a scene, use the____
selector.
A. .all-nodes
B. .stage
C. .home
D. .root โœ“D. .root
pf3
pf4
pf5

Partial preview of the text

Download JavaFX Programming: Revision Questions and Answers and more Exams Computer Programming in PDF only on Docsity!

Starting out with Java - Chapter 13 Revision

Questions

A ____ is like a TextField that can accept multiple lines of input. A. TextArea B. MultilineTextField C. ExpandableTextField D. TextEditorField โœ“A. TextArea Adding RadioButton controls to this type of object creates a mutually exclusive relationship between them. A. MutualExclude B. RadioGroup C. LogicalGroup D. ToggleGroup โœ“D. ToggleGroup Both the ListView control and the ComboBox control keeps its list of items in a(n) ____object. A. ArrayList B. ExpandableList C. ItemList D. ObservableList โœ“D. ObservableList If you want to apply styles to all of the nodes in a scene, use the____ selector. A. .all-nodes B. .stage C. .home D. .root โœ“D. .root

In the hexadecimal color value #05AAFF, the AA value specifies which color component? A. red B. green C. blue D. magenta โœ“B. green The ___ CSS property is used to change a control's background color in a JavaFX application. A. -fx-color B. -fx-background-color C. -fx-color-background D. -fx-bg-color โœ“B. -fx-background-color The ___control displays a list of items and allows the user to select one or more items from the list. A. DropList B. ListView C. ViewList D. ItemList โœ“B. ListView The____control presents its items in a drop-down list. A. DropList B. ListView C. ComboBox D. ItemList โœ“C. ComboBox This RadioButton method returns true if this control is selected. A. selected()

What style definition applies a background color of #0000FF to all Button controls? A. .button { -fx-background-color: #0000FF; } B. .button { -fx-bg-color = #0000FF; } C. .button.all { -fx-background-color: #0000FF; } D. .global {button: -fx-background-color: #0000FF; } โœ“A. .button { -fx- background-color: #0000FF; } 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 When you define a color in CSS, you specify an integer value in the range of ___ for each of the color components (red, green, and blue). A. 0 through 255 B. 0 through 1024 C. โˆ’255โˆ’255 through 255 D. 0 through 128 โœ“A. 0 through 255 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; } D. {.label; -fx-font-size: 20pt; } โœ“C. .label { -fx-font-size: 20pt; } 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