Which code segment should you insert at line 02?

You develop an interactive scalable vector graphic (SVG) application.
You write the following code (Line numbers are included for reference only.):

You need to increase the size of the circle by 50 percent.
Which code segment should you insert at line 02?

You develop an interactive scalable vector graphic (SVG) application.
You write the following code (Line numbers are included for reference only.):

You need to increase the size of the circle by 50 percent.
Which code segment should you insert at line 02?

A.
Option A

B.
Option B

C.
Option C

D.
Option D



Leave a Reply 15

Your email address will not be published. Required fields are marked *


Gabe

Gabe

C is also technically wrong, the 1.5 should be of data type string

Avery

Avery

It does look like is B

M

M

The correct answer is B!

Damien

Damien

B would change the size of the svg, but not the circle. C would change the size of the circle.

The answer is C.

Al

Al

The only correct answer is B. C is INCORRECT. The currentScale attribute belongs to the SVG element, only. Applying the currentScale attribute to a circle element has no effect on the scale of the circle. I verified this in IE.

Nikhil

Nikhil

Answer is B : it works only with IE , tested with IE 9, 10
tested with Chrome : and it does not work.

for other browser use : transform=”scale(1.5)”

carri

carri

you’re right.

For other browsers the equivalent answer is:

myGraphic.currentScale = 1.5;

abdullah tahan

abdullah tahan

in the current situation the current answer is B i already check it but you have to try it under IE :
https://jsfiddle.net/q2buo2x7/

function zoom() {
var outer = document.getElementById(‘outer’);
outer.setAttribute(“currentScale”, 1.5);
}
zoom();

for other browser i think we have to use “transform” which work in inner circle :

function zoom() {
var circle = document.getElementById(‘inner’);
inner.setAttribute(“transform”, “scale(1.5)”);
}
zoom();