Skip to content

Instantly share code, notes, and snippets.

@takehiko
Created August 9, 2023 13:24
Show Gist options
  • Save takehiko/e485d0d57db8a45c2c1b7ea1b56d5f24 to your computer and use it in GitHub Desktop.
Save takehiko/e485d0d57db8a45c2c1b7ea1b56d5f24 to your computer and use it in GitHub Desktop.
Creating angles using a set square
Display the source blob
Display the rendered blob
Raw
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Display the source blob
Display the rendered blob
Raw
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Display the source blob
Display the rendered blob
Raw
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Display the source blob
Display the rendered blob
Raw
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<svg xmlns="http://www.w3.org/2000/svg" width="380" height="280" id="setsquare4">
<style type="text/css" >
<![CDATA[
.ssq1 { fill:#99f; fill-opacity:0.8; stroke:black; stroke-width:2; stroke-linejoin:round; }
.ssq2 { fill:#f99; fill-opacity:0.8; stroke:black; stroke-width:2; stroke-linejoin:round; }
.ang { fill:none; stroke:gold; stroke-width:2; stroke-linecap:round; }
#bg { fill:#f0fff0; stroke:none }
text { font-size:10px; font-family:Serif; font-style:normal; font-weight:normal; fill:black; stroke:none; }
]]>
</style>
<rect x="0" y="0" width="380" height="280" id="bg"/>
<!-- 2つの三角定規を配置して,その交点(247.9,119.97)に165°を作る -->
<g transform="translate(40,240) scale(3,3) rotate(0)">
<polygon points="0,0 100,0 100,-57.735" class="ssq1"/>
</g>
<g transform="translate(127.870,240) scale(3,-3) rotate(45)">
<polygon points="0,0 100,0 50,-50" class="ssq2"/>
</g>
<!-- 角の大きさを表す円弧の半径は4(の3倍) -->
<g transform="translate(247.9,119.97) scale(3,3) rotate(0)">
<path d="M 5.657,-5.657 A4,4 0,0,0 -6.928,4" class="ang"/>
<text x="-10" y="-12">165°</text>
</g>
</svg>
@takehiko
Copy link
Author

takehiko commented Aug 9, 2023

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment