summaryrefslogtreecommitdiffstats
path: root/kig/macros/circle_by_point_and_diameter.kigt
blob: afe73a619ac90ea50d1ec279a501c4e8d100b174 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
<!DOCTYPE KigMacroFile>
<KigMacroFile Number="1" Version="0.9.0" >
 <Macro>
  <Name>Circle by Point &amp;&amp; Segment (as the Diameter)</Name>
  <Description>A circle defined by its center and the length of a segment as the diameter</Description>
  <ActionName>objects_new_circlebpd</ActionName>
  <IconFileName>circlebpd</IconFileName>
  <Construction>
   <input requirement="point" id="1">
    <UseText>Construct a circle with this center</UseText>
    <SelectStatement>Select the center of the new circle...</SelectStatement>
   </input>
   <input requirement="segment" id="2">
    <UseText>Construct a circle with the diameter given by the length of this segment</UseText>
    <SelectStatement>Select the segment whose length gives the diameter of the new circle...</SelectStatement>
   </input>
   <intermediate action="fetch-property" property="end-point-A" id="3" >
    <arg>2</arg>
   </intermediate>
   <intermediate action="fetch-property" property="mid-point" id="4" >
    <arg>2</arg>
   </intermediate>
   <intermediate action="calc" type="SegmentAB" id="5" >
    <arg>3</arg>
    <arg>4</arg>
   </intermediate>
   <intermediate action="fetch-property" property="length" id="6" >
    <arg>5</arg>
   </intermediate>
   <result action="calc" type="CircleBPR" id="7" >
    <arg>1</arg>
    <arg>6</arg>
   </result>
  </Construction>
 </Macro>
</KigMacroFile>