A) g.setColor(Color.cyan);B) g.setCurrentColor(cyan);C) g.setColor("Color.cyan");D) g.setColor("cyan’);E) g.setColor(new Color(cyan));
Latest Answer: option A is the answer. ...
What does the following code draw?g.setColor(Color.black);g.drawLine(10, 10, 10, 50);g.setColor(Color.RED);g.drawRect(100, 100, 150, 150);
A) A red vertical line that is 40 pixels long and a red square with sides of 150 pixelsB) A black vertical line that is 40 pixels long and a red square with sides of 150 pixelsC) A black vertical line
A) ascentB) leadingC) caseD) height
Latest Answer: a b d ...
A) The AWT automatically causes a window to be repainted when a portion of a window has been minimized and then maximized.B) The AWT automatically causes a window to be repainted when a portion of a window
Latest Answer: a and c ...
You have created a simple Frame and overridden the paint method as follows public void paint(Graphics g){ g.drawString("Dolly",50,10);}What will be the result when you attempt to compile and run the program?
A) The string "Dolly" will be displayed at the centre of the frameB) An error at compilation complaining at the signature of the paint methodC) The lower part of the word Dolly will be seen at
A text field has a variable-width font. It is constructed by calling new TextField("iiiii"). What happens if you change the contents of the text field to "wwwww"? (Bear in mind that is one of the narrowest characters, and w is one of the widest.)
A) The text field becomes wider.B) The text field becomes narrower.C) The text field stays the same width; to see the entire contents you will have to scroll by using the ß and à keys.D) The
A) Container - ComponentB) MenuComponent - ObjectC) Dialog - WindowD) Applet - Panel
Latest Answer: answer is A,B,C ...
A) getVisible()B) getImmediateC) getParent()D) getContainer()
Latest Answer: C ...
A) ButtonB) LabelC) CheckboxMenuItemD) ToolbarE) Frame
Latest Answer: All are correct. ...
A) FrameB) TextAreaC) MenuBarD) FileDialogE) Applet
Latest Answer: A,E are the sub classes of container ...
View page << Previous 3 4 5 6 [7] 8 Next >>

Go Top