* Model/Tools/ElementCreationTool.cs: Added
* Model/Tools/PolyLineCreationTool.cs: Removed CheckDoubleClick() * Model/Tools/PathCreationTool.cs: Rewriteen * Model/Tools/ShapeCreationTool.cs: Now Iherits from ElementCreationTool * Model/Tools/AbstractTool.cs: Added CheckDoubleClick() * View/MainWindow.cs: Added PathToolHandlers svn path=/trunk/lunareclipse/; revision=106381
|
@ -2,6 +2,10 @@
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
2008-06-22 Manuel Cerón <ceronman@unicauca.edu.co>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
2008-06-21 Manuel Cerón <ceronman@unicauca.edu.co>
|
2008-06-21 Manuel Cerón <ceronman@unicauca.edu.co>
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -0,0 +1,4 @@
|
||||||
|
2008-06-22 Manuel Cerón <ceronman@unicauca.edu.co>
|
||||||
|
|
||||||
|
|
||||||
|
|
Двоичные данные
Icons/circle-tool.png
До Ширина: | Высота: | Размер: 950 B После Ширина: | Высота: | Размер: 950 B |
Двоичные данные
Icons/ellipse-tool.png
До Ширина: | Высота: | Размер: 780 B После Ширина: | Высота: | Размер: 739 B |
346
Icons/icons.svg
|
@ -62,7 +62,7 @@
|
||||||
id="perspective10" />
|
id="perspective10" />
|
||||||
<linearGradient
|
<linearGradient
|
||||||
inkscape:collect="always"
|
inkscape:collect="always"
|
||||||
xlink:href="#linearGradient3157"
|
xlink:href="#linearGradient3195"
|
||||||
id="linearGradient3163"
|
id="linearGradient3163"
|
||||||
x1="89.857147"
|
x1="89.857147"
|
||||||
y1="150.48718"
|
y1="150.48718"
|
||||||
|
@ -97,25 +97,6 @@
|
||||||
y1="160.03464"
|
y1="160.03464"
|
||||||
x2="121.95019"
|
x2="121.95019"
|
||||||
y2="189.34081" />
|
y2="189.34081" />
|
||||||
<linearGradient
|
|
||||||
inkscape:collect="always"
|
|
||||||
xlink:href="#linearGradient3195"
|
|
||||||
id="linearGradient3191"
|
|
||||||
gradientUnits="userSpaceOnUse"
|
|
||||||
x1="89.857147"
|
|
||||||
y1="150.48718"
|
|
||||||
x2="121.57146"
|
|
||||||
y2="181.55862"
|
|
||||||
gradientTransform="matrix(1.0134488,0,0,0.4570578,63.044189,94.613319)" />
|
|
||||||
<linearGradient
|
|
||||||
inkscape:collect="always"
|
|
||||||
xlink:href="#linearGradient3169"
|
|
||||||
id="linearGradient3193"
|
|
||||||
gradientUnits="userSpaceOnUse"
|
|
||||||
x1="129.14285"
|
|
||||||
y1="159.86218"
|
|
||||||
x2="154.42857"
|
|
||||||
y2="185.71933" />
|
|
||||||
<linearGradient
|
<linearGradient
|
||||||
inkscape:collect="always"
|
inkscape:collect="always"
|
||||||
xlink:href="#linearGradient3195"
|
xlink:href="#linearGradient3195"
|
||||||
|
@ -135,16 +116,34 @@
|
||||||
x2="353.42133"
|
x2="353.42133"
|
||||||
y2="186.47127"
|
y2="186.47127"
|
||||||
gradientUnits="userSpaceOnUse" />
|
gradientUnits="userSpaceOnUse" />
|
||||||
|
<linearGradient
|
||||||
|
inkscape:collect="always"
|
||||||
|
xlink:href="#linearGradient3195"
|
||||||
|
id="linearGradient3221"
|
||||||
|
x1="164.15488"
|
||||||
|
y1="165.19569"
|
||||||
|
x2="186.11554"
|
||||||
|
y2="178.07515"
|
||||||
|
gradientUnits="userSpaceOnUse" />
|
||||||
|
<linearGradient
|
||||||
|
inkscape:collect="always"
|
||||||
|
xlink:href="#linearGradient3169"
|
||||||
|
id="linearGradient3231"
|
||||||
|
x1="194.96452"
|
||||||
|
y1="153.07388"
|
||||||
|
x2="221.98102"
|
||||||
|
y2="183.37845"
|
||||||
|
gradientUnits="userSpaceOnUse" />
|
||||||
<linearGradient
|
<linearGradient
|
||||||
inkscape:collect="always"
|
inkscape:collect="always"
|
||||||
xlink:href="#linearGradient3157"
|
xlink:href="#linearGradient3157"
|
||||||
id="linearGradient3209"
|
id="linearGradient3248"
|
||||||
gradientUnits="userSpaceOnUse"
|
gradientUnits="userSpaceOnUse"
|
||||||
|
gradientTransform="translate(255.46337,6.7840018e-2)"
|
||||||
x1="89.857147"
|
x1="89.857147"
|
||||||
y1="150.48718"
|
y1="150.48718"
|
||||||
x2="121.57146"
|
x2="121.57146"
|
||||||
y2="181.55862"
|
y2="181.55862" />
|
||||||
gradientTransform="translate(255.46337,6.7840018e-2)" />
|
|
||||||
</defs>
|
</defs>
|
||||||
<sodipodi:namedview
|
<sodipodi:namedview
|
||||||
id="base"
|
id="base"
|
||||||
|
@ -154,7 +153,7 @@
|
||||||
inkscape:pageopacity="0.0"
|
inkscape:pageopacity="0.0"
|
||||||
inkscape:pageshadow="2"
|
inkscape:pageshadow="2"
|
||||||
inkscape:zoom="1.4"
|
inkscape:zoom="1.4"
|
||||||
inkscape:cx="308.22348"
|
inkscape:cx="292.4954"
|
||||||
inkscape:cy="876.59804"
|
inkscape:cy="876.59804"
|
||||||
inkscape:document-units="px"
|
inkscape:document-units="px"
|
||||||
inkscape:current-layer="layer1"
|
inkscape:current-layer="layer1"
|
||||||
|
@ -187,7 +186,7 @@
|
||||||
inkscape:groupmode="layer"
|
inkscape:groupmode="layer"
|
||||||
id="layer1">
|
id="layer1">
|
||||||
<rect
|
<rect
|
||||||
style="fill:url(#linearGradient3163);fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1"
|
style="fill:url(#linearGradient3163);fill-opacity:1.0;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1"
|
||||||
id="rect2383"
|
id="rect2383"
|
||||||
width="23.750025"
|
width="23.750025"
|
||||||
height="23.749998"
|
height="23.749998"
|
||||||
|
@ -196,7 +195,8 @@
|
||||||
rx="0"
|
rx="0"
|
||||||
ry="0"
|
ry="0"
|
||||||
inkscape:export-xdpi="90"
|
inkscape:export-xdpi="90"
|
||||||
inkscape:export-ydpi="90" />
|
inkscape:export-ydpi="90"
|
||||||
|
inkscape:export-filename="/home/ceronman/svn/lunareclipse/Icons/square-tool.png" />
|
||||||
<path
|
<path
|
||||||
sodipodi:type="arc"
|
sodipodi:type="arc"
|
||||||
style="fill:url(#linearGradient3177);fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1"
|
style="fill:url(#linearGradient3177);fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1"
|
||||||
|
@ -208,66 +208,27 @@
|
||||||
d="M 155,173.61218 A 11.607142,11.607142 0 1 1 131.78571,173.61218 A 11.607142,11.607142 0 1 1 155,173.61218 z"
|
d="M 155,173.61218 A 11.607142,11.607142 0 1 1 131.78571,173.61218 A 11.607142,11.607142 0 1 1 155,173.61218 z"
|
||||||
transform="translate(1.25,-1.0714286)"
|
transform="translate(1.25,-1.0714286)"
|
||||||
inkscape:export-xdpi="90"
|
inkscape:export-xdpi="90"
|
||||||
inkscape:export-ydpi="90" />
|
inkscape:export-ydpi="90"
|
||||||
<rect
|
inkscape:export-filename="/home/ceronman/svn/lunareclipse/Icons/circle-tool.png" />
|
||||||
style="fill:url(#linearGradient3191);fill-opacity:1;stroke:#000000;stroke-width:0.6805914;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1"
|
|
||||||
id="rect3187"
|
|
||||||
width="24.069433"
|
|
||||||
height="10.855121"
|
|
||||||
x="164.75102"
|
|
||||||
y="168.00604"
|
|
||||||
rx="0"
|
|
||||||
ry="0"
|
|
||||||
inkscape:export-xdpi="90"
|
|
||||||
inkscape:export-ydpi="90" />
|
|
||||||
<path
|
|
||||||
sodipodi:type="arc"
|
|
||||||
style="fill:url(#linearGradient3193);fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1"
|
|
||||||
id="path3189"
|
|
||||||
sodipodi:cx="143.39285"
|
|
||||||
sodipodi:cy="173.61218"
|
|
||||||
sodipodi:rx="11.607142"
|
|
||||||
sodipodi:ry="11.607142"
|
|
||||||
d="M 155,173.61218 A 11.607142,11.607142 0 1 1 131.78571,173.61218 A 11.607142,11.607142 0 1 1 155,173.61218 z"
|
|
||||||
transform="matrix(1.010972,0,0,0.5494335,62.623125,77.420251)"
|
|
||||||
inkscape:export-xdpi="90"
|
|
||||||
inkscape:export-ydpi="90" />
|
|
||||||
<path
|
|
||||||
style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
|
|
||||||
d="M 226.25,160.57647 C 226.88542,160.57647 231.27783,162.15011 233.03571,162.54075 C 234.43986,162.85278 231.1958,166.44062 231.07143,166.6479 C 230.89286,166.94551 230.71429,167.24313 230.53571,167.54075 C 229.70692,168.92207 229.49021,170.13484 230.35714,171.29075 C 232.51023,174.16153 237.06341,174.67037 240.35714,175.21932 C 242.74779,175.61776 241.70687,177.51987 240.89286,179.1479 C 239.07739,182.77883 243.17998,182.70217 246.07143,184.1479 C 246.29094,184.25765 246.54762,184.26694 246.78571,184.32647 C 247.74642,184.56664 248.84819,185.20325 249.82143,185.3979"
|
|
||||||
id="path3207"
|
|
||||||
inkscape:export-xdpi="90"
|
|
||||||
inkscape:export-ydpi="90" />
|
|
||||||
<path
|
|
||||||
style="fill:#807b7e;fill-opacity:1;stroke:#000000;stroke-width:0.8907389;stroke-miterlimit:4;stroke-dashoffset:0;stroke-opacity:1"
|
|
||||||
d="M 241.07402,169.58692 L 250.92062,158.58572 L 252.97986,160.12952 L 243.13328,171.13072 L 239.21629,173.58476 L 241.07402,169.58692 z"
|
|
||||||
id="rect3219"
|
|
||||||
sodipodi:nodetypes="cccccc"
|
|
||||||
inkscape:export-filename="/home/ceronman/path3207.png"
|
|
||||||
inkscape:export-xdpi="90"
|
|
||||||
inkscape:export-ydpi="90" />
|
|
||||||
<g
|
<g
|
||||||
id="g3263">
|
id="g3305"
|
||||||
|
inkscape:export-filename="/home/ceronman/svn/lunareclipse/Icons/pen-tool.png"
|
||||||
|
inkscape:export-xdpi="90"
|
||||||
|
inkscape:export-ydpi="90">
|
||||||
<path
|
<path
|
||||||
inkscape:export-ydpi="90"
|
inkscape:export-ydpi="90"
|
||||||
inkscape:export-xdpi="90"
|
inkscape:export-xdpi="90"
|
||||||
id="path2405"
|
id="path3207"
|
||||||
d="M 262.18162,163.34872 L 282.2906,184.46784"
|
d="M 226.25,160.57647 C 226.88542,160.57647 231.27783,162.15011 233.03571,162.54075 C 234.43986,162.85278 231.1958,166.44062 231.07143,166.6479 C 230.89286,166.94551 230.71429,167.24313 230.53571,167.54075 C 229.70692,168.92207 229.49021,170.13484 230.35714,171.29075 C 232.51023,174.16153 237.06341,174.67037 240.35714,175.21932 C 242.74779,175.61776 241.70687,177.51987 240.89286,179.1479 C 239.07739,182.77883 243.17998,182.70217 246.07143,184.1479 C 246.29094,184.25765 246.54762,184.26694 246.78571,184.32647 C 247.74642,184.56664 248.84819,185.20325 249.82143,185.3979"
|
||||||
style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:0.84154695px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1" />
|
style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1" />
|
||||||
<rect
|
<path
|
||||||
y="161.49251"
|
inkscape:export-ydpi="90"
|
||||||
x="260.57797"
|
inkscape:export-xdpi="90"
|
||||||
height="3.8708851"
|
inkscape:export-filename="/home/ceronman/path3207.png"
|
||||||
width="3.7446928"
|
sodipodi:nodetypes="cccccc"
|
||||||
id="rect2407"
|
id="rect3219"
|
||||||
style="fill:#fbff17;fill-opacity:0.68181817;stroke:#000000;stroke-width:0.91717356;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" />
|
d="M 241.07402,169.58692 L 250.92062,158.58572 L 252.97986,160.12952 L 243.13328,171.13072 L 239.21629,173.58476 L 241.07402,169.58692 z"
|
||||||
<rect
|
style="fill:#807b7e;fill-opacity:1;stroke:#000000;stroke-width:0.8907389;stroke-miterlimit:4;stroke-dashoffset:0;stroke-opacity:1" />
|
||||||
y="182.32689"
|
|
||||||
x="280.33902"
|
|
||||||
height="3.8708851"
|
|
||||||
width="3.7446928"
|
|
||||||
id="rect3179"
|
|
||||||
style="fill:#fbff17;fill-opacity:0.68181817;stroke:#000000;stroke-width:0.91717356;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" />
|
|
||||||
</g>
|
</g>
|
||||||
<path
|
<path
|
||||||
style="fill:url(#linearGradient3214);fill-opacity:1;fill-rule:evenodd;stroke:#000000;stroke-width:0.69899344px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
|
style="fill:url(#linearGradient3214);fill-opacity:1;fill-rule:evenodd;stroke:#000000;stroke-width:0.69899344px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
|
||||||
|
@ -275,11 +236,13 @@
|
||||||
id="path3206"
|
id="path3206"
|
||||||
sodipodi:nodetypes="cccccccc"
|
sodipodi:nodetypes="cccccccc"
|
||||||
inkscape:export-xdpi="90"
|
inkscape:export-xdpi="90"
|
||||||
inkscape:export-ydpi="90" />
|
inkscape:export-ydpi="90"
|
||||||
|
inkscape:export-filename="/home/ceronman/svn/lunareclipse/Icons/selection-tool.png" />
|
||||||
<g
|
<g
|
||||||
id="g3268"
|
id="g3268"
|
||||||
inkscape:export-xdpi="90"
|
inkscape:export-xdpi="90"
|
||||||
inkscape:export-ydpi="90">
|
inkscape:export-ydpi="90"
|
||||||
|
inkscape:export-filename="/home/ceronman/svn/lunareclipse/Icons/text-tool.png">
|
||||||
<text
|
<text
|
||||||
id="text2406"
|
id="text2406"
|
||||||
y="182.89789"
|
y="182.89789"
|
||||||
|
@ -308,8 +271,58 @@
|
||||||
id="path3200" />
|
id="path3200" />
|
||||||
</g>
|
</g>
|
||||||
</g>
|
</g>
|
||||||
|
<rect
|
||||||
|
style="fill:url(#linearGradient3221);fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1"
|
||||||
|
id="rect3213"
|
||||||
|
width="20.708128"
|
||||||
|
height="10.101525"
|
||||||
|
x="166.42264"
|
||||||
|
y="167.46855"
|
||||||
|
inkscape:export-filename="/home/ceronman/svn/lunareclipse/Icons/rectangle-tool.png"
|
||||||
|
inkscape:export-xdpi="90"
|
||||||
|
inkscape:export-ydpi="90" />
|
||||||
|
<path
|
||||||
|
sodipodi:type="arc"
|
||||||
|
style="fill:url(#linearGradient3231);fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1"
|
||||||
|
id="path3223"
|
||||||
|
sodipodi:cx="207.71262"
|
||||||
|
sodipodi:cy="169.86766"
|
||||||
|
sodipodi:rx="12.248099"
|
||||||
|
sodipodi:ry="5.4295697"
|
||||||
|
d="M 219.96072,169.86766 A 12.248099,5.4295697 0 1 1 195.46452,169.86766 A 12.248099,5.4295697 0 1 1 219.96072,169.86766 z"
|
||||||
|
transform="translate(0.2525381,3.5355339)"
|
||||||
|
inkscape:export-filename="/home/ceronman/svn/lunareclipse/Icons/ellipse-tool.png"
|
||||||
|
inkscape:export-xdpi="90"
|
||||||
|
inkscape:export-ydpi="90" />
|
||||||
<g
|
<g
|
||||||
id="g3232"
|
id="g3309"
|
||||||
|
inkscape:export-xdpi="90"
|
||||||
|
inkscape:export-ydpi="90"
|
||||||
|
inkscape:export-filename="/home/ceronman/svn/lunareclipse/Icons/line-tool.png">
|
||||||
|
<path
|
||||||
|
inkscape:export-ydpi="90"
|
||||||
|
inkscape:export-xdpi="90"
|
||||||
|
id="path2405"
|
||||||
|
d="M 262.18162,163.34872 L 282.2906,184.46784"
|
||||||
|
style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:0.84154695px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1" />
|
||||||
|
<rect
|
||||||
|
y="182.24203"
|
||||||
|
x="280.19104"
|
||||||
|
height="3.661803"
|
||||||
|
width="3.9143412"
|
||||||
|
id="rect3236"
|
||||||
|
style="fill:#ffff00;fill-opacity:0.62121211;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" />
|
||||||
|
<rect
|
||||||
|
y="161.47078"
|
||||||
|
x="260.30368"
|
||||||
|
height="3.661803"
|
||||||
|
width="3.9143412"
|
||||||
|
id="rect3238"
|
||||||
|
style="fill:#ffff00;fill-opacity:0.62121211;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" />
|
||||||
|
</g>
|
||||||
|
<g
|
||||||
|
id="g3264"
|
||||||
|
inkscape:export-filename="/home/ceronman/svn/lunareclipse/Icons/image-tool.png"
|
||||||
inkscape:export-xdpi="90"
|
inkscape:export-xdpi="90"
|
||||||
inkscape:export-ydpi="90">
|
inkscape:export-ydpi="90">
|
||||||
<rect
|
<rect
|
||||||
|
@ -322,7 +335,7 @@
|
||||||
height="20.535713"
|
height="20.535713"
|
||||||
width="23.571453"
|
width="23.571453"
|
||||||
id="rect3207"
|
id="rect3207"
|
||||||
style="fill:url(#linearGradient3209);fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-dasharray:2, 1;stroke-dashoffset:0;stroke-opacity:1" />
|
style="fill:url(#linearGradient3248);fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-dasharray:2, 1;stroke-dashoffset:0;stroke-opacity:1" />
|
||||||
<rect
|
<rect
|
||||||
y="166.09192"
|
y="166.09192"
|
||||||
x="360.11563"
|
x="360.11563"
|
||||||
|
@ -340,41 +353,42 @@
|
||||||
id="path3215"
|
id="path3215"
|
||||||
style="fill:#ff0b17;fill-opacity:0.85606061;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1"
|
style="fill:#ff0b17;fill-opacity:0.85606061;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1"
|
||||||
sodipodi:type="arc" />
|
sodipodi:type="arc" />
|
||||||
<rect
|
|
||||||
y="181.3196"
|
|
||||||
x="354.02051"
|
|
||||||
height="3.8708851"
|
|
||||||
width="3.7446928"
|
|
||||||
id="rect3220"
|
|
||||||
style="fill:#fbff17;fill-opacity:0.68181817;stroke:#000000;stroke-width:0.91717356;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" />
|
|
||||||
<rect
|
|
||||||
y="160.78387"
|
|
||||||
x="354.02051"
|
|
||||||
height="3.8708851"
|
|
||||||
width="3.7446928"
|
|
||||||
id="rect3222"
|
|
||||||
style="fill:#fbff17;fill-opacity:0.68181817;stroke:#000000;stroke-width:0.91717356;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" />
|
|
||||||
<rect
|
|
||||||
y="160.78387"
|
|
||||||
x="377.59195"
|
|
||||||
height="3.8708851"
|
|
||||||
width="3.7446928"
|
|
||||||
id="rect3224"
|
|
||||||
style="fill:#fbff17;fill-opacity:0.68181817;stroke:#000000;stroke-width:0.91717356;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" />
|
|
||||||
<rect
|
|
||||||
y="180.96245"
|
|
||||||
x="377.59195"
|
|
||||||
height="3.8708851"
|
|
||||||
width="3.7446928"
|
|
||||||
id="rect3226"
|
|
||||||
style="fill:#fbff17;fill-opacity:0.68181817;stroke:#000000;stroke-width:0.91717356;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" />
|
|
||||||
<path
|
<path
|
||||||
id="path3230"
|
id="path3230"
|
||||||
d="M 364.94624,172.84739 L 358.52721,177.35734 L 365.23691,180.30336 L 364.94624,172.84739 z"
|
d="M 364.94624,172.84739 L 358.52721,177.35734 L 365.23691,180.30336 L 364.94624,172.84739 z"
|
||||||
style="fill:#35ff00;fill-opacity:0.85606061;fill-rule:evenodd;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1" />
|
style="fill:#35ff00;fill-opacity:0.85606061;fill-rule:evenodd;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1" />
|
||||||
|
<rect
|
||||||
|
y="160.58688"
|
||||||
|
x="354.24783"
|
||||||
|
height="3.661803"
|
||||||
|
width="3.9143412"
|
||||||
|
id="rect3251"
|
||||||
|
style="fill:#ffff00;fill-opacity:0.62121211;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" />
|
||||||
|
<rect
|
||||||
|
y="160.58688"
|
||||||
|
x="377.48138"
|
||||||
|
height="3.661803"
|
||||||
|
width="3.9143412"
|
||||||
|
id="rect3253"
|
||||||
|
style="fill:#ffff00;fill-opacity:0.62121211;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" />
|
||||||
|
<rect
|
||||||
|
y="181.29503"
|
||||||
|
x="354.24783"
|
||||||
|
height="3.661803"
|
||||||
|
width="3.9143412"
|
||||||
|
id="rect3255"
|
||||||
|
style="fill:#ffff00;fill-opacity:0.62121211;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" />
|
||||||
|
<rect
|
||||||
|
y="181.29503"
|
||||||
|
x="377.48138"
|
||||||
|
height="3.661803"
|
||||||
|
width="3.9143412"
|
||||||
|
id="rect3257"
|
||||||
|
style="fill:#ffff00;fill-opacity:0.62121211;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" />
|
||||||
</g>
|
</g>
|
||||||
<g
|
<g
|
||||||
id="g3256"
|
id="g3314"
|
||||||
|
inkscape:export-filename="/home/ceronman/svn/lunareclipse/Icons/polyline-tool.png"
|
||||||
inkscape:export-xdpi="90"
|
inkscape:export-xdpi="90"
|
||||||
inkscape:export-ydpi="90">
|
inkscape:export-ydpi="90">
|
||||||
<path
|
<path
|
||||||
|
@ -383,33 +397,87 @@
|
||||||
d="M 388.90873,169.23632 L 400.02041,161.1551 L 396.23234,183.12592 L 411.38463,177.82262"
|
d="M 388.90873,169.23632 L 400.02041,161.1551 L 396.23234,183.12592 L 411.38463,177.82262"
|
||||||
style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1" />
|
style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1" />
|
||||||
<rect
|
<rect
|
||||||
y="167.04832"
|
y="167.15288"
|
||||||
x="387.28891"
|
x="387.33038"
|
||||||
height="3.8708851"
|
height="3.661803"
|
||||||
width="3.7446928"
|
width="3.9143412"
|
||||||
id="rect3246"
|
id="rect3274"
|
||||||
style="fill:#fbff17;fill-opacity:0.68181817;stroke:#000000;stroke-width:0.91717356;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" />
|
style="fill:#ffff00;fill-opacity:0.62121211;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" />
|
||||||
<rect
|
<rect
|
||||||
y="158.71458"
|
y="158.69286"
|
||||||
x="398.4006"
|
x="398.31577"
|
||||||
height="3.8708851"
|
height="3.661803"
|
||||||
width="3.7446928"
|
width="3.9143412"
|
||||||
id="rect3248"
|
id="rect3276"
|
||||||
style="fill:#fbff17;fill-opacity:0.68181817;stroke:#000000;stroke-width:0.91717356;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" />
|
style="fill:#ffff00;fill-opacity:0.62121211;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" />
|
||||||
<rect
|
<rect
|
||||||
y="176.13971"
|
y="181.54756"
|
||||||
x="409.5123"
|
x="394.1489"
|
||||||
height="3.8708851"
|
height="3.661803"
|
||||||
width="3.7446928"
|
width="3.9143412"
|
||||||
id="rect3250"
|
id="rect3278"
|
||||||
style="fill:#fbff17;fill-opacity:0.68181817;stroke:#000000;stroke-width:0.91717356;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" />
|
style="fill:#ffff00;fill-opacity:0.62121211;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" />
|
||||||
<rect
|
<rect
|
||||||
y="181.44301"
|
y="175.86545"
|
||||||
x="394.35999"
|
x="409.55374"
|
||||||
height="3.8708851"
|
height="3.661803"
|
||||||
width="3.7446928"
|
width="3.9143412"
|
||||||
id="rect3254"
|
id="rect3280"
|
||||||
style="fill:#fbff17;fill-opacity:0.68181817;stroke:#000000;stroke-width:0.91717356;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" />
|
style="fill:#ffff00;fill-opacity:0.62121211;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" />
|
||||||
|
</g>
|
||||||
|
<g
|
||||||
|
id="g3296"
|
||||||
|
inkscape:export-filename="/home/ceronman/svn/lunareclipse/Icons/path-tool.png"
|
||||||
|
inkscape:export-xdpi="90"
|
||||||
|
inkscape:export-ydpi="90">
|
||||||
|
<path
|
||||||
|
id="path3288"
|
||||||
|
d="M 442.32055,163.68048 L 439.92143,184.26234"
|
||||||
|
style="fill:none;fill-rule:evenodd;stroke:#c8c8c8;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;stroke-miterlimit:4;stroke-dasharray:2,1;stroke-dashoffset:0" />
|
||||||
|
<path
|
||||||
|
sodipodi:nodetypes="cc"
|
||||||
|
id="path3292"
|
||||||
|
d="M 428.24156,160.0818 L 423.31706,182.5577"
|
||||||
|
style="fill:none;fill-rule:evenodd;stroke:#c8c8c8;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:2, 1;stroke-dashoffset:0;stroke-opacity:1" />
|
||||||
|
<path
|
||||||
|
sodipodi:nodetypes="cs"
|
||||||
|
id="path2439"
|
||||||
|
d="M 423.25392,182.49457 C 427.29453,162.29151 439.72954,184.14927 442.44682,163.68048"
|
||||||
|
style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1" />
|
||||||
|
<rect
|
||||||
|
y="180.28485"
|
||||||
|
x="421.17047"
|
||||||
|
height="3.661803"
|
||||||
|
width="3.9143412"
|
||||||
|
id="rect3282"
|
||||||
|
style="fill:#ffff00;fill-opacity:0.62121211;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" />
|
||||||
|
<rect
|
||||||
|
y="161.97585"
|
||||||
|
x="440.48962"
|
||||||
|
height="3.661803"
|
||||||
|
width="3.9143412"
|
||||||
|
id="rect3284"
|
||||||
|
style="fill:#ffff00;fill-opacity:0.62121211;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" />
|
||||||
|
<path
|
||||||
|
transform="translate(-0.7576144,-0.5050763)"
|
||||||
|
d="M 442.44681,184.70428 A 1.767767,1.7046324 0 1 1 438.91128,184.70428 A 1.767767,1.7046324 0 1 1 442.44681,184.70428 z"
|
||||||
|
sodipodi:ry="1.7046324"
|
||||||
|
sodipodi:rx="1.767767"
|
||||||
|
sodipodi:cy="184.70428"
|
||||||
|
sodipodi:cx="440.67905"
|
||||||
|
id="path3286"
|
||||||
|
style="fill:#ff00ff;fill-opacity:0.62121212;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1"
|
||||||
|
sodipodi:type="arc" />
|
||||||
|
<path
|
||||||
|
transform="translate(-12.753174,-24.685607)"
|
||||||
|
d="M 442.44681,184.70428 A 1.767767,1.7046324 0 1 1 438.91128,184.70428 A 1.767767,1.7046324 0 1 1 442.44681,184.70428 z"
|
||||||
|
sodipodi:ry="1.7046324"
|
||||||
|
sodipodi:rx="1.767767"
|
||||||
|
sodipodi:cy="184.70428"
|
||||||
|
sodipodi:cx="440.67905"
|
||||||
|
id="path3294"
|
||||||
|
style="fill:#ff00ff;fill-opacity:0.62121211;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1"
|
||||||
|
sodipodi:type="arc" />
|
||||||
</g>
|
</g>
|
||||||
</g>
|
</g>
|
||||||
</svg>
|
</svg>
|
||||||
|
|
До Ширина: | Высота: | Размер: 16 KiB После Ширина: | Высота: | Размер: 20 KiB |
Двоичные данные
Icons/image-tool.png
До Ширина: | Высота: | Размер: 1.9 KiB После Ширина: | Высота: | Размер: 1.7 KiB |
Двоичные данные
Icons/line-tool.png
До Ширина: | Высота: | Размер: 525 B После Ширина: | Высота: | Размер: 447 B |
Двоичные данные
Icons/path-tool.png
До Ширина: | Высота: | Размер: 831 B После Ширина: | Высота: | Размер: 968 B |
После Ширина: | Высота: | Размер: 831 B |
Двоичные данные
Icons/polyline-tool.png
До Ширина: | Высота: | Размер: 789 B После Ширина: | Высота: | Размер: 726 B |
Двоичные данные
Icons/rectangle-tool.png
До Ширина: | Высота: | Размер: 411 B После Ширина: | Высота: | Размер: 325 B |
Двоичные данные
Icons/selection-tool.png
До Ширина: | Высота: | Размер: 1.1 KiB После Ширина: | Высота: | Размер: 774 B |
Двоичные данные
Icons/square-tool.png
До Ширина: | Высота: | Размер: 497 B После Ширина: | Высота: | Размер: 429 B |
Двоичные данные
Icons/text-tool.png
До Ширина: | Высота: | Размер: 1021 B После Ширина: | Высота: | Размер: 1021 B |
|
@ -89,23 +89,23 @@
|
||||||
<File name="Controller/UndoActions/UndoPropertyChange.cs" subtype="Code" buildaction="Compile" />
|
<File name="Controller/UndoActions/UndoPropertyChange.cs" subtype="Code" buildaction="Compile" />
|
||||||
<File name="Controller/UndoActions/UndoRotation.cs" subtype="Code" buildaction="Compile" />
|
<File name="Controller/UndoActions/UndoRotation.cs" subtype="Code" buildaction="Compile" />
|
||||||
<File name="View/MainWindow.cs" subtype="Code" buildaction="Compile" />
|
<File name="View/MainWindow.cs" subtype="Code" buildaction="Compile" />
|
||||||
<File name="Icons/circle-tool.png" subtype="Code" buildaction="Nothing" />
|
<File name="Icons/circle-tool.png" subtype="Code" buildaction="EmbedAsResource" />
|
||||||
<File name="Icons/ellipse-tool.png" subtype="Code" buildaction="Nothing" />
|
<File name="Icons/ellipse-tool.png" subtype="Code" buildaction="EmbedAsResource" />
|
||||||
<File name="Icons/path-tool.png" subtype="Code" buildaction="Nothing" />
|
<File name="Icons/path-tool.png" subtype="Code" buildaction="EmbedAsResource" />
|
||||||
<File name="Icons/rectangle-tool.png" subtype="Code" buildaction="Nothing" />
|
<File name="Icons/rectangle-tool.png" subtype="Code" buildaction="EmbedAsResource" />
|
||||||
<File name="Icons/square-tool.png" subtype="Code" buildaction="Nothing" />
|
<File name="Icons/square-tool.png" subtype="Code" buildaction="EmbedAsResource" />
|
||||||
<File name="Icons/line-tool.png" subtype="Code" buildaction="Nothing" />
|
<File name="Icons/line-tool.png" subtype="Code" buildaction="EmbedAsResource" />
|
||||||
<File name="Icons/selection-tool.png" subtype="Code" buildaction="Nothing" />
|
<File name="Icons/selection-tool.png" subtype="Code" buildaction="EmbedAsResource" />
|
||||||
<File name="Icons/icons.svg" subtype="Code" buildaction="Nothing" />
|
<File name="Icons/icons.svg" subtype="Code" buildaction="EmbedAsResource" />
|
||||||
<File name="View/MoonlightWidget.cs" subtype="Code" buildaction="Compile" />
|
<File name="View/MoonlightWidget.cs" subtype="Code" buildaction="Compile" />
|
||||||
<File name="gtk-gui/objects.xml" subtype="Code" buildaction="EmbedAsResource" resource_id="objects.xml" />
|
<File name="gtk-gui/objects.xml" subtype="Code" buildaction="EmbedAsResource" resource_id="objects.xml" />
|
||||||
<File name="gtk-gui/LunarEclipse.View.MoonlightWidget.cs" subtype="Code" buildaction="Compile" />
|
<File name="gtk-gui/LunarEclipse.View.MoonlightWidget.cs" subtype="Code" buildaction="Compile" />
|
||||||
<File name="gtk-gui/LunarEclipse.View.MainWindow.cs" subtype="Code" buildaction="Compile" />
|
<File name="gtk-gui/LunarEclipse.View.MainWindow.cs" subtype="Code" buildaction="Compile" />
|
||||||
<File name="Controls/TimeLine/AnimationTimelineWidget.cs" subtype="Code" buildaction="Compile" />
|
<File name="Controls/TimeLine/AnimationTimelineWidget.cs" subtype="Code" buildaction="Compile" />
|
||||||
<File name="gtk-gui/LunarEclipse.Controls.AnimationTimelineWidget.cs" subtype="Code" buildaction="Compile" />
|
<File name="gtk-gui/LunarEclipse.Controls.AnimationTimelineWidget.cs" subtype="Code" buildaction="Compile" />
|
||||||
<File name="Icons/image-tool.png" subtype="Code" buildaction="FileCopy" DeployService.UseProjectRelativePath="True" />
|
<File name="Icons/image-tool.png" subtype="Code" buildaction="EmbedAsResource" DeployService.UseProjectRelativePath="True" />
|
||||||
<File name="Icons/polyline-tool.png" subtype="Code" buildaction="FileCopy" DeployService.UseProjectRelativePath="True" />
|
<File name="Icons/polyline-tool.png" subtype="Code" buildaction="EmbedAsResource" DeployService.UseProjectRelativePath="True" />
|
||||||
<File name="Icons/text-tool.png" subtype="Code" buildaction="FileCopy" DeployService.UseProjectRelativePath="True" />
|
<File name="Icons/text-tool.png" subtype="Code" buildaction="EmbedAsResource" DeployService.UseProjectRelativePath="True" />
|
||||||
<File name="Model/Tools/PolyLineCreationTool.cs" subtype="Code" buildaction="Compile" />
|
<File name="Model/Tools/PolyLineCreationTool.cs" subtype="Code" buildaction="Compile" />
|
||||||
<File name="Model/Tools/TextBlockCreationTool.cs" subtype="Code" buildaction="Compile" />
|
<File name="Model/Tools/TextBlockCreationTool.cs" subtype="Code" buildaction="Compile" />
|
||||||
<File name="Model/Tools/PathCreationTool.cs" subtype="Code" buildaction="Compile" />
|
<File name="Model/Tools/PathCreationTool.cs" subtype="Code" buildaction="Compile" />
|
||||||
|
@ -133,6 +133,8 @@
|
||||||
<File name="Model/HandleGroups/ResizeHandleGroup.cs" subtype="Code" buildaction="Compile" />
|
<File name="Model/HandleGroups/ResizeHandleGroup.cs" subtype="Code" buildaction="Compile" />
|
||||||
<File name="Model/HandleGroups/RotateHandleGroup.cs" subtype="Code" buildaction="Compile" />
|
<File name="Model/HandleGroups/RotateHandleGroup.cs" subtype="Code" buildaction="Compile" />
|
||||||
<File name="Model/Handles/BezierSegmentPoint3Handle.cs" subtype="Code" buildaction="Compile" />
|
<File name="Model/Handles/BezierSegmentPoint3Handle.cs" subtype="Code" buildaction="Compile" />
|
||||||
|
<File name="Icons/pen-tool.png" subtype="Code" buildaction="EmbedAsResource" />
|
||||||
|
<File name="Model/Tools/ElementCreationTool.cs" subtype="Code" buildaction="Compile" />
|
||||||
</Contents>
|
</Contents>
|
||||||
<References>
|
<References>
|
||||||
<ProjectReference type="Gac" localcopy="True" refto="System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
|
<ProjectReference type="Gac" localcopy="True" refto="System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
|
||||||
|
|
|
@ -25,6 +25,7 @@
|
||||||
//
|
//
|
||||||
//
|
//
|
||||||
|
|
||||||
|
using System;
|
||||||
using System.Windows.Input;
|
using System.Windows.Input;
|
||||||
using LunarEclipse.Controller;
|
using LunarEclipse.Controller;
|
||||||
|
|
||||||
|
@ -85,9 +86,25 @@ namespace LunarEclipse.Model {
|
||||||
get { return dragging; }
|
get { return dragging; }
|
||||||
set { dragging = value; }
|
set { dragging = value; }
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
protected bool CheckDoubleClick()
|
||||||
|
{
|
||||||
|
bool result = false;
|
||||||
|
// Trick to detect double click
|
||||||
|
// http://hackingsilverlight.blogspot.com/2008/02/silverlight-20-double-click-support.html
|
||||||
|
if ((DateTime.Now.Ticks - last_ticks) < 2310000) {
|
||||||
|
result = true;
|
||||||
|
}
|
||||||
|
last_ticks = DateTime.Now.Ticks;
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
private bool activated;
|
private bool activated;
|
||||||
private MoonlightController controller;
|
private MoonlightController controller;
|
||||||
private bool dragging = false;
|
private bool dragging = false;
|
||||||
|
|
||||||
|
// trick to support double click;
|
||||||
|
private long last_ticks = 0;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,3 +1,11 @@
|
||||||
|
2008-06-22 Manuel Cerón <ceronman@unicauca.edu.co>
|
||||||
|
|
||||||
|
* ElementCreationTool.cs: Added
|
||||||
|
* PolyLineCreationTool.cs: Removed CheckDoubleClick()
|
||||||
|
* PathCreationTool.cs: Rewriteen
|
||||||
|
* ShapeCreationTool.cs: Now Iherits from ElementCreationTool
|
||||||
|
* AbstractTool.cs: Added CheckDoubleClick()
|
||||||
|
|
||||||
2008-06-21 Manuel Cerón <ceronman@unicauca.edu.co>
|
2008-06-21 Manuel Cerón <ceronman@unicauca.edu.co>
|
||||||
|
|
||||||
* SelectionTool.cs: Updated to use Frames.
|
* SelectionTool.cs: Updated to use Frames.
|
||||||
|
|
|
@ -0,0 +1,66 @@
|
||||||
|
// ElementCreationTool.cs
|
||||||
|
//
|
||||||
|
// Author:
|
||||||
|
// Manuel Cerón <ceronman@unicauca.edu.co>
|
||||||
|
//
|
||||||
|
// Copyright (c) 2008 Manuel Cerón
|
||||||
|
//
|
||||||
|
// Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||||
|
// of this software and associated documentation files (the "Software"), to deal
|
||||||
|
// in the Software without restriction, including without limitation the rights
|
||||||
|
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||||
|
// copies of the Software, and to permit persons to whom the Software is
|
||||||
|
// furnished to do so, subject to the following conditions:
|
||||||
|
//
|
||||||
|
// The above copyright notice and this permission notice shall be included in
|
||||||
|
// all copies or substantial portions of the Software.
|
||||||
|
//
|
||||||
|
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||||
|
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||||
|
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||||
|
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||||
|
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||||
|
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
||||||
|
// THE SOFTWARE.
|
||||||
|
//
|
||||||
|
//
|
||||||
|
|
||||||
|
using System.Windows;
|
||||||
|
using System.Windows.Media;
|
||||||
|
using System.Windows.Shapes;
|
||||||
|
using LunarEclipse.Controller;
|
||||||
|
|
||||||
|
namespace LunarEclipse.Model {
|
||||||
|
|
||||||
|
public abstract class ElementCreationTool: AbstractTool {
|
||||||
|
|
||||||
|
public ElementCreationTool(MoonlightController controller):
|
||||||
|
base (controller)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
protected UIElement CreatedShape {
|
||||||
|
get { return created_shape; }
|
||||||
|
set { created_shape = value; }
|
||||||
|
}
|
||||||
|
|
||||||
|
protected virtual void SetupShapeProperties()
|
||||||
|
{
|
||||||
|
CreatedShape.SetValue(Shape.StrokeProperty, new SolidColorBrush(Colors.Black));
|
||||||
|
CreatedShape.SetValue(Visual.NameProperty,
|
||||||
|
NameGenerator.GetName(Controller.Canvas, CreatedShape));
|
||||||
|
CreatedShape.SetValue(UIElement.RenderTransformOriginProperty, new Point(0.5, 0.5));
|
||||||
|
}
|
||||||
|
|
||||||
|
protected abstract UIElement CreateShape();
|
||||||
|
|
||||||
|
protected virtual void SetupElement()
|
||||||
|
{
|
||||||
|
CreatedShape = CreateShape();
|
||||||
|
SetupShapeProperties();
|
||||||
|
Controller.Canvas.Children.Add(CreatedShape);
|
||||||
|
}
|
||||||
|
|
||||||
|
private UIElement created_shape;
|
||||||
|
}
|
||||||
|
}
|
|
@ -25,15 +25,88 @@
|
||||||
//
|
//
|
||||||
//
|
//
|
||||||
|
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Windows;
|
||||||
|
using System.Windows.Shapes;
|
||||||
|
using System.Windows.Input;
|
||||||
|
using System.Windows.Media;
|
||||||
using LunarEclipse.Controller;
|
using LunarEclipse.Controller;
|
||||||
|
|
||||||
namespace LunarEclipse.Model {
|
namespace LunarEclipse.Model {
|
||||||
|
|
||||||
public class PathCreationTool: PenCreationTool{
|
public class PathCreationTool: ShapeCreationTool{
|
||||||
|
|
||||||
public PathCreationTool(MoonlightController controller):
|
public PathCreationTool(MoonlightController controller):
|
||||||
base (controller)
|
base (controller)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public override void MouseDown (MouseEventArgs ev)
|
||||||
|
{
|
||||||
|
if (CheckDoubleClick() ) {
|
||||||
|
create_new = true;
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
Point position = ev.GetPosition(Controller.Canvas);
|
||||||
|
|
||||||
|
if (create_new) {
|
||||||
|
SetupElement();
|
||||||
|
ShapeStart = position;
|
||||||
|
ShapeEnd = position;
|
||||||
|
create_new = false;
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
AddSegment();
|
||||||
|
}
|
||||||
|
UpdateShape();
|
||||||
|
}
|
||||||
|
|
||||||
|
public override void MouseMove (MouseEventArgs ev)
|
||||||
|
{
|
||||||
|
if (create_new)
|
||||||
|
return;
|
||||||
|
|
||||||
|
Point position = ev.GetPosition(Controller.Canvas);
|
||||||
|
ShapeEnd = position;
|
||||||
|
UpdateShape();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
protected override UIElement CreateShape ()
|
||||||
|
{
|
||||||
|
Path path = new Path();
|
||||||
|
PathGeometry geometry = new PathGeometry();
|
||||||
|
path.Data = geometry;
|
||||||
|
geometry.Figures = new PathFigureCollection();
|
||||||
|
figure = new PathFigure();
|
||||||
|
geometry.Figures.Add(figure);
|
||||||
|
figure.Segments = new PathSegmentCollection();
|
||||||
|
AddSegment();
|
||||||
|
|
||||||
|
return path;
|
||||||
|
}
|
||||||
|
|
||||||
|
protected override void UpdateShape ()
|
||||||
|
{
|
||||||
|
figure.StartPoint = ShapeStart;
|
||||||
|
current_segment.Point1 = ShapeEnd;
|
||||||
|
current_segment.Point2 = ShapeEnd;
|
||||||
|
current_segment.Point3 = ShapeEnd;
|
||||||
|
}
|
||||||
|
|
||||||
|
private void AddSegment()
|
||||||
|
{
|
||||||
|
current_segment = new BezierSegment();
|
||||||
|
figure.Segments.Add(current_segment);
|
||||||
|
}
|
||||||
|
|
||||||
|
private PathFigure figure;
|
||||||
|
private BezierSegment current_segment;
|
||||||
|
private Point start_point;
|
||||||
|
private Point current_point;
|
||||||
|
private bool create_new = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -44,13 +44,10 @@ namespace LunarEclipse.Model {
|
||||||
|
|
||||||
public override void MouseDown (MouseEventArgs ev)
|
public override void MouseDown (MouseEventArgs ev)
|
||||||
{
|
{
|
||||||
// Trick to detect double click
|
if (CheckDoubleClick()) {
|
||||||
// http://hackingsilverlight.blogspot.com/2008/02/silverlight-20-double-click-support.html
|
|
||||||
if ((DateTime.Now.Ticks - last_ticks) < 2310000) {
|
|
||||||
create_new = true;
|
create_new = true;
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
last_ticks = DateTime.Now.Ticks;
|
|
||||||
|
|
||||||
if (create_new) {
|
if (create_new) {
|
||||||
base.MouseDown (ev);
|
base.MouseDown (ev);
|
||||||
|
|
|
@ -34,7 +34,7 @@ using LunarEclipse.Controller;
|
||||||
|
|
||||||
namespace LunarEclipse.Model {
|
namespace LunarEclipse.Model {
|
||||||
|
|
||||||
public abstract class ShapeCreationTool: AbstractTool {
|
public abstract class ShapeCreationTool: ElementCreationTool {
|
||||||
|
|
||||||
public ShapeCreationTool(MoonlightController controller):
|
public ShapeCreationTool(MoonlightController controller):
|
||||||
base (controller)
|
base (controller)
|
||||||
|
@ -45,9 +45,7 @@ namespace LunarEclipse.Model {
|
||||||
{
|
{
|
||||||
base.MouseDown (ev);
|
base.MouseDown (ev);
|
||||||
|
|
||||||
CreatedShape = CreateShape();
|
SetupElement();
|
||||||
SetupShapeProperties();
|
|
||||||
Controller.Canvas.Children.Add(CreatedShape);
|
|
||||||
|
|
||||||
Point position = ev.GetPosition(Controller.Canvas);
|
Point position = ev.GetPosition(Controller.Canvas);
|
||||||
|
|
||||||
|
@ -68,9 +66,6 @@ namespace LunarEclipse.Model {
|
||||||
ShapeEnd = position;
|
ShapeEnd = position;
|
||||||
UpdateShape();
|
UpdateShape();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
protected abstract UIElement CreateShape();
|
|
||||||
|
|
||||||
protected virtual void UpdateShape()
|
protected virtual void UpdateShape()
|
||||||
{
|
{
|
||||||
|
@ -94,19 +89,6 @@ namespace LunarEclipse.Model {
|
||||||
Toolbox.NormalizeRect(ref x, ref y, ref width, ref height);
|
Toolbox.NormalizeRect(ref x, ref y, ref width, ref height);
|
||||||
}
|
}
|
||||||
|
|
||||||
protected virtual void SetupShapeProperties()
|
|
||||||
{
|
|
||||||
CreatedShape.SetValue(Shape.StrokeProperty, new SolidColorBrush(Colors.Black));
|
|
||||||
CreatedShape.SetValue(Visual.NameProperty,
|
|
||||||
NameGenerator.GetName(Controller.Canvas, CreatedShape));
|
|
||||||
CreatedShape.SetValue(UIElement.RenderTransformOriginProperty, new Point(0.5, 0.5));
|
|
||||||
}
|
|
||||||
|
|
||||||
protected UIElement CreatedShape {
|
|
||||||
get { return created_shape; }
|
|
||||||
set { created_shape = value; }
|
|
||||||
}
|
|
||||||
|
|
||||||
protected Point ShapeStart {
|
protected Point ShapeStart {
|
||||||
get {
|
get {
|
||||||
return shape_start;
|
return shape_start;
|
||||||
|
@ -125,7 +107,6 @@ namespace LunarEclipse.Model {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private UIElement created_shape;
|
|
||||||
private Point shape_start;
|
private Point shape_start;
|
||||||
private Point shape_end;
|
private Point shape_end;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,3 +1,7 @@
|
||||||
|
2008-06-22 Manuel Cerón <ceronman@unicauca.edu.co>
|
||||||
|
|
||||||
|
* MainWindow.cs: Added PathToolHandlers
|
||||||
|
|
||||||
2008-06-22 Manuel Cerón <ceronman@unicauca.edu.co>
|
2008-06-22 Manuel Cerón <ceronman@unicauca.edu.co>
|
||||||
|
|
||||||
* MoonlightWidget.cs: Updated Test
|
* MoonlightWidget.cs: Updated Test
|
||||||
|
|
|
@ -83,7 +83,7 @@ namespace LunarEclipse.View
|
||||||
|
|
||||||
protected virtual void OnPathToolActionActivated (object sender, System.EventArgs e)
|
protected virtual void OnPathToolActionActivated (object sender, System.EventArgs e)
|
||||||
{
|
{
|
||||||
controller.CurrentTool = new PenCreationTool(controller);
|
controller.CurrentTool = new PathCreationTool(controller);
|
||||||
}
|
}
|
||||||
|
|
||||||
protected virtual void OnLineToolActionActivated (object sender, System.EventArgs e)
|
protected virtual void OnLineToolActionActivated (object sender, System.EventArgs e)
|
||||||
|
@ -115,6 +115,11 @@ namespace LunarEclipse.View
|
||||||
{
|
{
|
||||||
controller.CurrentTool = new ImageCreationTool(controller);
|
controller.CurrentTool = new ImageCreationTool(controller);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
protected virtual void OnPenToolActionActivated (object sender, System.EventArgs e)
|
||||||
|
{
|
||||||
|
controller.CurrentTool = new PenCreationTool(controller);
|
||||||
|
}
|
||||||
|
|
||||||
private MoonlightController controller;
|
private MoonlightController controller;
|
||||||
}
|
}
|
||||||
|
|
|
@ -6,6 +6,10 @@
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
2008-06-22 Manuel Cerón <ceronman@unicauca.edu.co>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
2008-06-21 Manuel Cerón <ceronman@unicauca.edu.co>
|
2008-06-21 Manuel Cerón <ceronman@unicauca.edu.co>
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -77,6 +77,8 @@ namespace LunarEclipse.View {
|
||||||
|
|
||||||
private Gtk.RadioAction PolylineToolAction;
|
private Gtk.RadioAction PolylineToolAction;
|
||||||
|
|
||||||
|
private Gtk.RadioAction PenToolAction;
|
||||||
|
|
||||||
private Gtk.VBox vbox1;
|
private Gtk.VBox vbox1;
|
||||||
|
|
||||||
private Gtk.MenuBar menubar1;
|
private Gtk.MenuBar menubar1;
|
||||||
|
@ -173,7 +175,7 @@ namespace LunarEclipse.View {
|
||||||
this.SquareToolAction.ShortLabel = Mono.Unix.Catalog.GetString("S_quare Tool");
|
this.SquareToolAction.ShortLabel = Mono.Unix.Catalog.GetString("S_quare Tool");
|
||||||
w2.Add(this.SquareToolAction, null);
|
w2.Add(this.SquareToolAction, null);
|
||||||
this.EllipseToolAction = new Gtk.RadioAction("EllipseToolAction", Mono.Unix.Catalog.GetString("_Ellipse Tool"), null, "ellipse-tool", 0);
|
this.EllipseToolAction = new Gtk.RadioAction("EllipseToolAction", Mono.Unix.Catalog.GetString("_Ellipse Tool"), null, "ellipse-tool", 0);
|
||||||
this.EllipseToolAction.Group = this.SquareToolAction.Group;
|
this.EllipseToolAction.Group = this.RectangleToolAction.Group;
|
||||||
this.EllipseToolAction.ShortLabel = Mono.Unix.Catalog.GetString("_Ellipse Tool");
|
this.EllipseToolAction.ShortLabel = Mono.Unix.Catalog.GetString("_Ellipse Tool");
|
||||||
w2.Add(this.EllipseToolAction, null);
|
w2.Add(this.EllipseToolAction, null);
|
||||||
this.CircleToolAction = new Gtk.RadioAction("CircleToolAction", Mono.Unix.Catalog.GetString("_Circle Tool"), null, "circle-tool", 0);
|
this.CircleToolAction = new Gtk.RadioAction("CircleToolAction", Mono.Unix.Catalog.GetString("_Circle Tool"), null, "circle-tool", 0);
|
||||||
|
@ -215,9 +217,13 @@ namespace LunarEclipse.View {
|
||||||
this.LimpiarAction.ShortLabel = Mono.Unix.Catalog.GetString("_Limpiar");
|
this.LimpiarAction.ShortLabel = Mono.Unix.Catalog.GetString("_Limpiar");
|
||||||
w2.Add(this.LimpiarAction, null);
|
w2.Add(this.LimpiarAction, null);
|
||||||
this.PolylineToolAction = new Gtk.RadioAction("PolylineToolAction", Mono.Unix.Catalog.GetString("Polyline Tool"), null, "polyline-tool", 0);
|
this.PolylineToolAction = new Gtk.RadioAction("PolylineToolAction", Mono.Unix.Catalog.GetString("Polyline Tool"), null, "polyline-tool", 0);
|
||||||
this.PolylineToolAction.Group = this.LineToolAction.Group;
|
this.PolylineToolAction.Group = this.EllipseToolAction.Group;
|
||||||
this.PolylineToolAction.ShortLabel = Mono.Unix.Catalog.GetString("Polyline Tool");
|
this.PolylineToolAction.ShortLabel = Mono.Unix.Catalog.GetString("Polyline Tool");
|
||||||
w2.Add(this.PolylineToolAction, null);
|
w2.Add(this.PolylineToolAction, null);
|
||||||
|
this.PenToolAction = new Gtk.RadioAction("PenToolAction", Mono.Unix.Catalog.GetString("P_en Tool"), null, "pen-tool", 0);
|
||||||
|
this.PenToolAction.Group = this.EllipseToolAction.Group;
|
||||||
|
this.PenToolAction.ShortLabel = Mono.Unix.Catalog.GetString("P_en Tool");
|
||||||
|
w2.Add(this.PenToolAction, null);
|
||||||
w1.InsertActionGroup(w2, 0);
|
w1.InsertActionGroup(w2, 0);
|
||||||
this.AddAccelGroup(w1.AccelGroup);
|
this.AddAccelGroup(w1.AccelGroup);
|
||||||
this.Name = "LunarEclipse.View.MainWindow";
|
this.Name = "LunarEclipse.View.MainWindow";
|
||||||
|
@ -228,7 +234,7 @@ namespace LunarEclipse.View {
|
||||||
this.vbox1.Name = "vbox1";
|
this.vbox1.Name = "vbox1";
|
||||||
this.vbox1.Spacing = 6;
|
this.vbox1.Spacing = 6;
|
||||||
// Container child vbox1.Gtk.Box+BoxChild
|
// Container child vbox1.Gtk.Box+BoxChild
|
||||||
w1.AddUiFromString("<ui><menubar name='menubar1'><menu action='FileAction'><menuitem action='NuevoAction'/><menuitem action='AbrirAction'/><menuitem action='GuardarAction'/><menuitem action='GuardarComoAction'/><separator/><menuitem action='SalirAction'/></menu><menu action='EditAction'><menuitem action='DeshacerAction'/><menuitem action='RehacerAction'/><separator/><menuitem action='CortarAction'/><menuitem action='CopiarAction'/><menuitem action='PegarAction'/><menuitem action='BorrarAction'/></menu><menu action='DrawingAction'><menuitem action='LimpiarAction'/></menu><menu action='ToolsAction'><menuitem action='SelectionToolAction'/><menuitem action='RectangleToolAction'/><menuitem action='SquareToolAction'/><menuitem action='EllipseToolAction'/><menuitem action='CircleToolAction'/><menuitem action='LineToolAction'/><menuitem action='PolylineToolAction'/><menuitem action='PathToolAction'/><menuitem action='TextToolAction'/><menuitem action='ImageToolAction'/></menu><menu action='AnimationAction'><menuitem action='GrabarAction'/><menuitem action='ReproducirAction'/><menuitem action='DetenerAction'/></menu><menu action='HelpAction'><menuitem action='AcercaDeAction'/></menu></menubar></ui>");
|
w1.AddUiFromString("<ui><menubar name='menubar1'><menu action='FileAction'><menuitem action='NuevoAction'/><menuitem action='AbrirAction'/><menuitem action='GuardarAction'/><menuitem action='GuardarComoAction'/><separator/><menuitem action='SalirAction'/></menu><menu action='EditAction'><menuitem action='DeshacerAction'/><menuitem action='RehacerAction'/><separator/><menuitem action='CortarAction'/><menuitem action='CopiarAction'/><menuitem action='PegarAction'/><menuitem action='BorrarAction'/></menu><menu action='DrawingAction'><menuitem action='LimpiarAction'/></menu><menu action='ToolsAction'><menuitem action='SelectionToolAction'/><menuitem action='RectangleToolAction'/><menuitem action='SquareToolAction'/><menuitem action='EllipseToolAction'/><menuitem action='CircleToolAction'/><menuitem action='LineToolAction'/><menuitem action='PolylineToolAction'/><menuitem action='PenToolAction'/><menuitem action='PathToolAction'/><menuitem action='TextToolAction'/><menuitem action='ImageToolAction'/></menu><menu action='AnimationAction'><menuitem action='GrabarAction'/><menuitem action='ReproducirAction'/><menuitem action='DetenerAction'/></menu><menu action='HelpAction'><menuitem action='AcercaDeAction'/></menu></menubar></ui>");
|
||||||
this.menubar1 = ((Gtk.MenuBar)(w1.GetWidget("/menubar1")));
|
this.menubar1 = ((Gtk.MenuBar)(w1.GetWidget("/menubar1")));
|
||||||
this.menubar1.Name = "menubar1";
|
this.menubar1.Name = "menubar1";
|
||||||
this.vbox1.Add(this.menubar1);
|
this.vbox1.Add(this.menubar1);
|
||||||
|
@ -258,7 +264,7 @@ namespace LunarEclipse.View {
|
||||||
this.hbox2.Name = "hbox2";
|
this.hbox2.Name = "hbox2";
|
||||||
this.hbox2.Spacing = 6;
|
this.hbox2.Spacing = 6;
|
||||||
// Container child hbox2.Gtk.Box+BoxChild
|
// Container child hbox2.Gtk.Box+BoxChild
|
||||||
w1.AddUiFromString("<ui><toolbar name='toolbar2'><toolitem action='SelectionToolAction'/><toolitem action='RectangleToolAction'/><toolitem action='SquareToolAction'/><toolitem action='EllipseToolAction'/><toolitem action='CircleToolAction'/><toolitem action='PathToolAction'/><toolitem action='LineToolAction'/><toolitem action='PolylineToolAction'/><toolitem action='TextToolAction'/><toolitem action='ImageToolAction'/><separator/><toolitem action='LimpiarAction'/></toolbar></ui>");
|
w1.AddUiFromString("<ui><toolbar name='toolbar2'><toolitem action='SelectionToolAction'/><toolitem action='RectangleToolAction'/><toolitem action='SquareToolAction'/><toolitem action='EllipseToolAction'/><toolitem action='CircleToolAction'/><toolitem action='PathToolAction'/><toolitem action='PenToolAction'/><toolitem action='LineToolAction'/><toolitem action='PolylineToolAction'/><toolitem action='TextToolAction'/><toolitem action='ImageToolAction'/><separator/><toolitem action='LimpiarAction'/></toolbar></ui>");
|
||||||
this.toolbar2 = ((Gtk.Toolbar)(w1.GetWidget("/toolbar2")));
|
this.toolbar2 = ((Gtk.Toolbar)(w1.GetWidget("/toolbar2")));
|
||||||
this.toolbar2.Name = "toolbar2";
|
this.toolbar2.Name = "toolbar2";
|
||||||
this.toolbar2.Orientation = ((Gtk.Orientation)(1));
|
this.toolbar2.Orientation = ((Gtk.Orientation)(1));
|
||||||
|
@ -354,7 +360,7 @@ namespace LunarEclipse.View {
|
||||||
this.Child.ShowAll();
|
this.Child.ShowAll();
|
||||||
}
|
}
|
||||||
this.DefaultWidth = 650;
|
this.DefaultWidth = 650;
|
||||||
this.DefaultHeight = 610;
|
this.DefaultHeight = 646;
|
||||||
this.Show();
|
this.Show();
|
||||||
this.DeleteEvent += new Gtk.DeleteEventHandler(this.OnDeleteEvent);
|
this.DeleteEvent += new Gtk.DeleteEventHandler(this.OnDeleteEvent);
|
||||||
this.SelectionToolAction.Activated += new System.EventHandler(this.OnSelectionToolActionActivated);
|
this.SelectionToolAction.Activated += new System.EventHandler(this.OnSelectionToolActionActivated);
|
||||||
|
@ -368,6 +374,7 @@ namespace LunarEclipse.View {
|
||||||
this.LineToolAction.Activated += new System.EventHandler(this.OnLineToolActionActivated);
|
this.LineToolAction.Activated += new System.EventHandler(this.OnLineToolActionActivated);
|
||||||
this.LimpiarAction.Activated += new System.EventHandler(this.OnLimpiarActionActivated);
|
this.LimpiarAction.Activated += new System.EventHandler(this.OnLimpiarActionActivated);
|
||||||
this.PolylineToolAction.Activated += new System.EventHandler(this.OnPolylineToolActionActivated);
|
this.PolylineToolAction.Activated += new System.EventHandler(this.OnPolylineToolActionActivated);
|
||||||
|
this.PenToolAction.Activated += new System.EventHandler(this.OnPenToolActionActivated);
|
||||||
this.notebook.SwitchPage += new Gtk.SwitchPageHandler(this.OnNotebookSwitchPage);
|
this.notebook.SwitchPage += new Gtk.SwitchPageHandler(this.OnNotebookSwitchPage);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -19,26 +19,28 @@ namespace Stetic {
|
||||||
if ((Stetic.Gui.initialized == false)) {
|
if ((Stetic.Gui.initialized == false)) {
|
||||||
Stetic.Gui.initialized = true;
|
Stetic.Gui.initialized = true;
|
||||||
Gtk.IconFactory w1 = new Gtk.IconFactory();
|
Gtk.IconFactory w1 = new Gtk.IconFactory();
|
||||||
Gtk.IconSet w2 = new Gtk.IconSet(new Gdk.Pixbuf(System.IO.Path.Combine(System.AppDomain.CurrentDomain.BaseDirectory, "./Icons/circle-tool.png")));
|
Gtk.IconSet w2 = new Gtk.IconSet(Gdk.Pixbuf.LoadFromResource("selection-tool.png"));
|
||||||
w1.Add("circle-tool", w2);
|
w1.Add("selection-tool", w2);
|
||||||
Gtk.IconSet w3 = new Gtk.IconSet(new Gdk.Pixbuf(System.IO.Path.Combine(System.AppDomain.CurrentDomain.BaseDirectory, "./Icons/ellipse-tool.png")));
|
Gtk.IconSet w3 = new Gtk.IconSet(Gdk.Pixbuf.LoadFromResource("circle-tool.png"));
|
||||||
w1.Add("ellipse-tool", w3);
|
w1.Add("circle-tool", w3);
|
||||||
Gtk.IconSet w4 = new Gtk.IconSet(new Gdk.Pixbuf(System.IO.Path.Combine(System.AppDomain.CurrentDomain.BaseDirectory, "./Icons/line-tool.png")));
|
Gtk.IconSet w4 = new Gtk.IconSet(Gdk.Pixbuf.LoadFromResource("ellipse-tool.png"));
|
||||||
w1.Add("line-tool", w4);
|
w1.Add("ellipse-tool", w4);
|
||||||
Gtk.IconSet w5 = new Gtk.IconSet(new Gdk.Pixbuf(System.IO.Path.Combine(System.AppDomain.CurrentDomain.BaseDirectory, "./Icons/path-tool.png")));
|
Gtk.IconSet w5 = new Gtk.IconSet(Gdk.Pixbuf.LoadFromResource("path-tool.png"));
|
||||||
w1.Add("path-tool", w5);
|
w1.Add("path-tool", w5);
|
||||||
Gtk.IconSet w6 = new Gtk.IconSet(new Gdk.Pixbuf(System.IO.Path.Combine(System.AppDomain.CurrentDomain.BaseDirectory, "./Icons/rectangle-tool.png")));
|
Gtk.IconSet w6 = new Gtk.IconSet(Gdk.Pixbuf.LoadFromResource("rectangle-tool.png"));
|
||||||
w1.Add("rectangle-tool", w6);
|
w1.Add("rectangle-tool", w6);
|
||||||
Gtk.IconSet w7 = new Gtk.IconSet(new Gdk.Pixbuf(System.IO.Path.Combine(System.AppDomain.CurrentDomain.BaseDirectory, "./Icons/selection-tool.png")));
|
Gtk.IconSet w7 = new Gtk.IconSet(Gdk.Pixbuf.LoadFromResource("square-tool.png"));
|
||||||
w1.Add("selection-tool", w7);
|
w1.Add("square-tool", w7);
|
||||||
Gtk.IconSet w8 = new Gtk.IconSet(new Gdk.Pixbuf(System.IO.Path.Combine(System.AppDomain.CurrentDomain.BaseDirectory, "./Icons/square-tool.png")));
|
Gtk.IconSet w8 = new Gtk.IconSet(Gdk.Pixbuf.LoadFromResource("line-tool.png"));
|
||||||
w1.Add("square-tool", w8);
|
w1.Add("line-tool", w8);
|
||||||
Gtk.IconSet w9 = new Gtk.IconSet(new Gdk.Pixbuf(System.IO.Path.Combine(System.AppDomain.CurrentDomain.BaseDirectory, "./Icons/image-tool.png")));
|
Gtk.IconSet w9 = new Gtk.IconSet(Gdk.Pixbuf.LoadFromResource("image-tool.png"));
|
||||||
w1.Add("image-tool", w9);
|
w1.Add("image-tool", w9);
|
||||||
Gtk.IconSet w10 = new Gtk.IconSet(new Gdk.Pixbuf(System.IO.Path.Combine(System.AppDomain.CurrentDomain.BaseDirectory, "./Icons/polyline-tool.png")));
|
Gtk.IconSet w10 = new Gtk.IconSet(Gdk.Pixbuf.LoadFromResource("polyline-tool.png"));
|
||||||
w1.Add("polyline-tool", w10);
|
w1.Add("polyline-tool", w10);
|
||||||
Gtk.IconSet w11 = new Gtk.IconSet(new Gdk.Pixbuf(System.IO.Path.Combine(System.AppDomain.CurrentDomain.BaseDirectory, "./Icons/text-tool.png")));
|
Gtk.IconSet w11 = new Gtk.IconSet(Gdk.Pixbuf.LoadFromResource("text-tool.png"));
|
||||||
w1.Add("text-tool", w11);
|
w1.Add("text-tool", w11);
|
||||||
|
Gtk.IconSet w12 = new Gtk.IconSet(Gdk.Pixbuf.LoadFromResource("pen-tool.png"));
|
||||||
|
w1.Add("pen-tool", w12);
|
||||||
w1.AddDefault();
|
w1.AddDefault();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -9,58 +9,63 @@
|
||||||
<widget-library name="../bin/Debug/LunarEclipse.exe" internal="true" />
|
<widget-library name="../bin/Debug/LunarEclipse.exe" internal="true" />
|
||||||
</import>
|
</import>
|
||||||
<icon-factory>
|
<icon-factory>
|
||||||
|
<icon-set id="selection-tool">
|
||||||
|
<source>
|
||||||
|
<property name="Image">resource:selection-tool.png</property>
|
||||||
|
</source>
|
||||||
|
</icon-set>
|
||||||
<icon-set id="circle-tool">
|
<icon-set id="circle-tool">
|
||||||
<source>
|
<source>
|
||||||
<property name="Image">file:./Icons/circle-tool.png</property>
|
<property name="Image">resource:circle-tool.png</property>
|
||||||
</source>
|
</source>
|
||||||
</icon-set>
|
</icon-set>
|
||||||
<icon-set id="ellipse-tool">
|
<icon-set id="ellipse-tool">
|
||||||
<source>
|
<source>
|
||||||
<property name="Image">file:./Icons/ellipse-tool.png</property>
|
<property name="Image">resource:ellipse-tool.png</property>
|
||||||
</source>
|
|
||||||
</icon-set>
|
|
||||||
<icon-set id="line-tool">
|
|
||||||
<source>
|
|
||||||
<property name="Image">file:./Icons/line-tool.png</property>
|
|
||||||
</source>
|
</source>
|
||||||
</icon-set>
|
</icon-set>
|
||||||
<icon-set id="path-tool">
|
<icon-set id="path-tool">
|
||||||
<source>
|
<source>
|
||||||
<property name="Image">file:./Icons/path-tool.png</property>
|
<property name="Image">resource:path-tool.png</property>
|
||||||
</source>
|
</source>
|
||||||
</icon-set>
|
</icon-set>
|
||||||
<icon-set id="rectangle-tool">
|
<icon-set id="rectangle-tool">
|
||||||
<source>
|
<source>
|
||||||
<property name="Image">file:./Icons/rectangle-tool.png</property>
|
<property name="Image">resource:rectangle-tool.png</property>
|
||||||
</source>
|
|
||||||
</icon-set>
|
|
||||||
<icon-set id="selection-tool">
|
|
||||||
<source>
|
|
||||||
<property name="Image">file:./Icons/selection-tool.png</property>
|
|
||||||
</source>
|
</source>
|
||||||
</icon-set>
|
</icon-set>
|
||||||
<icon-set id="square-tool">
|
<icon-set id="square-tool">
|
||||||
<source>
|
<source>
|
||||||
<property name="Image">file:./Icons/square-tool.png</property>
|
<property name="Image">resource:square-tool.png</property>
|
||||||
|
</source>
|
||||||
|
</icon-set>
|
||||||
|
<icon-set id="line-tool">
|
||||||
|
<source>
|
||||||
|
<property name="Image">resource:line-tool.png</property>
|
||||||
</source>
|
</source>
|
||||||
</icon-set>
|
</icon-set>
|
||||||
<icon-set id="image-tool">
|
<icon-set id="image-tool">
|
||||||
<source>
|
<source>
|
||||||
<property name="Image">file:./Icons/image-tool.png</property>
|
<property name="Image">resource:image-tool.png</property>
|
||||||
</source>
|
</source>
|
||||||
</icon-set>
|
</icon-set>
|
||||||
<icon-set id="polyline-tool">
|
<icon-set id="polyline-tool">
|
||||||
<source>
|
<source>
|
||||||
<property name="Image">file:./Icons/polyline-tool.png</property>
|
<property name="Image">resource:polyline-tool.png</property>
|
||||||
</source>
|
</source>
|
||||||
</icon-set>
|
</icon-set>
|
||||||
<icon-set id="text-tool">
|
<icon-set id="text-tool">
|
||||||
<source>
|
<source>
|
||||||
<property name="Image">file:./Icons/text-tool.png</property>
|
<property name="Image">resource:text-tool.png</property>
|
||||||
|
</source>
|
||||||
|
</icon-set>
|
||||||
|
<icon-set id="pen-tool">
|
||||||
|
<source>
|
||||||
|
<property name="Image">resource:pen-tool.png</property>
|
||||||
</source>
|
</source>
|
||||||
</icon-set>
|
</icon-set>
|
||||||
</icon-factory>
|
</icon-factory>
|
||||||
<widget class="Gtk.Window" id="LunarEclipse.View.MainWindow" design-size="650 610">
|
<widget class="Gtk.Window" id="LunarEclipse.View.MainWindow" design-size="650 646">
|
||||||
<action-group name="Default">
|
<action-group name="Default">
|
||||||
<action id="FileAction">
|
<action id="FileAction">
|
||||||
<property name="Type">Action</property>
|
<property name="Type">Action</property>
|
||||||
|
@ -299,6 +304,17 @@
|
||||||
<property name="Group">group1</property>
|
<property name="Group">group1</property>
|
||||||
<signal name="Activated" handler="OnPolylineToolActionActivated" />
|
<signal name="Activated" handler="OnPolylineToolActionActivated" />
|
||||||
</action>
|
</action>
|
||||||
|
<action id="PenToolAction">
|
||||||
|
<property name="Type">Radio</property>
|
||||||
|
<property name="Label" translatable="yes">P_en Tool</property>
|
||||||
|
<property name="ShortLabel" translatable="yes">P_en Tool</property>
|
||||||
|
<property name="StockId">pen-tool</property>
|
||||||
|
<property name="DrawAsRadio">False</property>
|
||||||
|
<property name="Active">False</property>
|
||||||
|
<property name="Value">0</property>
|
||||||
|
<property name="Group">group1</property>
|
||||||
|
<signal name="Activated" handler="OnPenToolActionActivated" />
|
||||||
|
</action>
|
||||||
</action-group>
|
</action-group>
|
||||||
<property name="MemberName" />
|
<property name="MemberName" />
|
||||||
<property name="Title" translatable="yes">Lunar Eclipse</property>
|
<property name="Title" translatable="yes">Lunar Eclipse</property>
|
||||||
|
@ -340,6 +356,7 @@
|
||||||
<node type="Menuitem" action="CircleToolAction" />
|
<node type="Menuitem" action="CircleToolAction" />
|
||||||
<node type="Menuitem" action="LineToolAction" />
|
<node type="Menuitem" action="LineToolAction" />
|
||||||
<node type="Menuitem" action="PolylineToolAction" />
|
<node type="Menuitem" action="PolylineToolAction" />
|
||||||
|
<node type="Menuitem" action="PenToolAction" />
|
||||||
<node type="Menuitem" action="PathToolAction" />
|
<node type="Menuitem" action="PathToolAction" />
|
||||||
<node type="Menuitem" action="TextToolAction" />
|
<node type="Menuitem" action="TextToolAction" />
|
||||||
<node type="Menuitem" action="ImageToolAction" />
|
<node type="Menuitem" action="ImageToolAction" />
|
||||||
|
@ -415,6 +432,7 @@
|
||||||
<node type="Toolitem" action="EllipseToolAction" />
|
<node type="Toolitem" action="EllipseToolAction" />
|
||||||
<node type="Toolitem" action="CircleToolAction" />
|
<node type="Toolitem" action="CircleToolAction" />
|
||||||
<node type="Toolitem" action="PathToolAction" />
|
<node type="Toolitem" action="PathToolAction" />
|
||||||
|
<node type="Toolitem" action="PenToolAction" />
|
||||||
<node type="Toolitem" action="LineToolAction" />
|
<node type="Toolitem" action="LineToolAction" />
|
||||||
<node type="Toolitem" action="PolylineToolAction" />
|
<node type="Toolitem" action="PolylineToolAction" />
|
||||||
<node type="Toolitem" action="TextToolAction" />
|
<node type="Toolitem" action="TextToolAction" />
|
||||||
|
|