Professional Documents
Culture Documents
TVL-ICT-PROGRAMMING
(.NET TECHNOLOGY) NC III
Quarter 3
Week 1
CapSLET
Capsulized
Self - Learning
Empowerment
Toolkit
TVL – ICT-PROGRAMMING
SUBJECT &
GRADE/LEVEL
(.NET TECHNOLOGY) QUARTER 3 WEEK 1
GRADE 11
PERFORM PROGRAMMING IN HTML5 WITH JAVASCRIPT AND CSS3
TOPIC
(PPHJC)
CODE
LEARNING
Use CSS3 to create scalable graphics
COMPETENCY
and animated user interface TLE_ICTP.NET
11-12PPHJC-
IVd-h-33
1. Define Scalable Vector Graphics
LEARNING 2. Describe the tag syntax in using Scalable Vector Graphics.
OBJECTIVES 3. Give the meaning and importance of SVG in dealing with graphics.
IMPORTANT: Do not write anything on this material. Write your answers on the learner’s activity and
assessment sheets provided separately.
UNDERSTAND
HTML SVG Graphics
SVG stands for Scalable Vector Graphics and it is a language for describing 2D-graphics and
graphical applications in XML and the XML is then rendered by an SVG viewer.
SVG is mostly useful for vector type diagrams like Pie charts, Two-dimensional graphs in an X,Y
coordinate system etc.
Most of the web browsers can display SVG just like they can display PNG, GIF, and JPG. Internet
Explorer users may have to install the Adobe SVG Viewer to be able to view SVG in the browser.
HTML5 allows embedding SVG directly using <svg>...</svg> tag which has following simple syntax
2|Page
HTML5 − SVG Rectangle
Following is the HTML5 version of an SVG example which would draw a rectangle using <rect> tag −
3|Page
Differences Between SVG and Canvas
SVG is XML based, which means that every element is available within the SVG DOM. You can
attach JavaScript event handlers for an element.
In SVG, each drawn shape is remembered as an object. If attributes of an SVG object are changed,
4|Page
the browser can automatically re-render the shape.
Canvas is rendered pixel by pixel. In canvas, once the graphic is drawn, it is forgotten by the browser.
If its position should be changed, the entire scene needs to be redrawn, including any objects that
might have been covered by the graphic.
The table below shows some important differences between Canvas and SVG:
Canvas SVG
Let’s Practice!
5|Page
a. < ellipse x="100" y="100" rx="15" ry="35" fill="blue"/ >
b. < ellipse cx="100" cy="100" r="15" fill="blue"/ >
c. < ellipse cx="100" cy="100" rx="15" ry="35" fill="blue"/ >
d. None of the Above
REMEMBER
Key Points
What is SVG?
SVG Advantages
Advantages of using SVG over other image formats (like JPEG and GIF) are:
SVG images can be created and edited with any text editor
SVG images can be searched, indexed, scripted, and compressed
SVG images are scalable
SVG images can be printed with high quality at any resolution
SVG images are zoomable
SVG graphics do NOT lose any quality if they are zoomed or resized
SVG is an open standard
SVG files are pure XML
SVG images can be created with any text editor, but it is often more convenient to create SVG
images with a drawing program, like Inkscape.
6|Page
TRY
Directions: Open Notepad++ and predict the output of the following tags.
<!DOCTYPE html>
<html>
<head>
<style>
#svgelem {
position: relative;
left: 50%;
-webkit-transform: translateX(-20%);
-ms-transform: translateX(-20%);
transform: translateX(-20%);
}
</style>
<title>SVG</title>
<meta charset = "utf-8" />
</head>
<body>
<h2 align = "center">HTML5 SVG Polyline</h2>
<svg id = "svgelem" height = "200" xmlns = "http://www.w3.org/2000/svg">
<polyline points = "0,0 0,20 20,20 20,40 40,40 40,60" fill = "red" />
</svg>
</body>
</html>
This learning resource contains copyrighted materials. The use of which has not
been specifically authorized by the copyright owner. We are making this learning
resource in our efforts to provide printed and e-copy learning resources available
for the learners in reference to the learning continuity plan of this division in this
time of pandemic.
DISCLAIMER
This LR is produced and distributed locally without profit and will be used for
educational purposes only. No malicious infringement is intended by the writer.
Credits and respect to the original creator/owner of the materials found in this
learning resource.
Developed by:
7|Page
JOHNNY JEAN N. TIGAS
TEACHER-III
ZAMBOANGA CITY HIGH SCHOOL
Integrated Senior High School
SAQ2. <svg>...</svg>
Let’s Practice
1. A
2. B
3. B
4. A
5. C
TRY
8|Page
Republic of the Philippines
Department of Education
Division of Zamboanga City
Instructions:
1. Read carefully the learning resource (LR) page by page to evaluate the LR for compliance to standards
indicated in the criterion items under each factor below.
2. Put a check mark (/) in the appropriate column beside each criterion item. If your answer is NO, cite
specific page/s, briefly indicate the errors found, and give your recommendations in the attached
Summary of Findings form.
3. Write Not Applicable (NA) for criterion items that does not apply in the LR evaluated.
Note:
This tool is anchored on the Guidelines in ADM Content Evaluation, Guidelines in ADM
Layout Evaluation and Level 2 DepEd Evaluation Rating Sheet for 2 DepEd Evaluation Rating
Sheet for Story Books and Big Books.
.
9|Page
Legend: (Type of Error) C - Content, L – Language, DL – Design and Layout
10 | P a g e