Graphics And Rendering(Engineering > Computer Science And Engineering > Javascript ) Questions and Answers
Question 1. Which of the following browsers use Webkit?
Chrome
Internet Explorer
Safari
Both a and c
Explanation:-
Answer: Option D. -> Both a and c
Webkit is what Chrome and Safari use, and is your target for most mobile web development since it is used as the layout or rendering engine for Android devices as well as mobile Safari for iOS devices and the Silk browser on Kindle Fires.
Question 2. What is the returning value of the getContext() method?
Drawing model
CanvasRenderingContext2D object
Context2D object
None of the mentioned
Explanation:-
Answer: Option B. -> CanvasRenderingContext2D object
Call getContext() with the argument "2d to obtain a CanvasRenderingContext2D object that you can use to draw two-dimensional graphics into the canvas. It is important to understand that the canvas element and its context object are two very different objects.
Question 3. What is the purpose of the JavaScript Engine?
Compiling the JavaScript
Interpreting the JavaScript
Both a and b
None of the mentioned
Explanation:-
Answer: Option B. -> Interpreting the JavaScript
The JavaScript Engine is generally used for interpreting the JavaScript.
Question 4. From which version of IE is canvas supported?
7
8
9
Not yet supported
Explanation:-
Answer: Option C. -> 9
The canvas element is not supported by IE before IE9, but it can be reasonably well emulated in IE6, 7, and 8.
Question 5. What is the return type of the remote server?
HTTP Response
HTTP Request
Get Request
None of the mentioned
Explanation:-
Answer: Option A. -> HTTP Response
The remote server finds the resource and returns it in an HTTP Response, the status of which is 200 to indicate a good response.
Question 6. Which is the method invoked to begin a path?
begin()
path()
createPath()
beginPath()
Explanation:-
Answer: Option D. -> beginPath()
The beginPath() is used to begin a new path.
Question 7. Which of the following is not the property of the video tag?
width
height
breadth
None of the mentioned
Explanation:-
Answer: Option C. -> breadth
The video tag does not contain a breadth property.
Question 8. Which of the following elements are used to include audio?
audio
video
svg
All of the mentioned
Explanation:-
Answer: Option A. -> audio
The audio tag is used to include audio in the HTML document.
Question 9. Which HTML element is used to include images?
image
img
src
sourceimg
Explanation:-
Answer: Option B. -> img
Web pages include images using the HTML img element.
Question 10. Which of the following attributes are common to both audio and video?
enter
control
controls
All of the mentioned
Explanation:-
Answer: Option C. -> controls
Both audio and video support a controls attribute.