このパッケージは、チャート、グラフ、またはその他の 2D グラフィックを簡単に実装できる軽量の 2D グラフィック システムを提供します。
説明
例
例 | |
{import * from CURL.GUI.SHAPES} {Canvas width = 3in, height = 2in, {GraphicShape {Frame vorigin = "top", horigin = "left", width = 1.5in, {text This is a pie chart made up of several overlapping EllipseShapes. } } }, {EllipseShape {GRect -2in, 3in, 0in, 1in}, border-color = "black", border-width = 1pt, color = "red", start-angle = 0deg, stop-angle = 30% * 360deg, {on PointerEnter at shape:Shape do set shape.color = "cyan" }, {on PointerLeave at shape:Shape do set shape.color = "red" } }, {EllipseShape {GRect -2in, 3in, 0in, 1in}, border-color = "black", border-width = 1pt, color = "blue", start-angle = 30% * 360deg, stop-angle = 85% * 360deg, {on PointerEnter at shape:Shape do set shape.color = "cyan" }, {on PointerLeave at shape:Shape do set shape.color = "blue" } }, {EllipseShape {GRect -2in, 3in, 0in, 1in}, border-color = "black", border-width = 1pt, color = "green", start-angle = 85% * 360deg, stop-angle = 95% * 360deg, {on PointerEnter at shape:Shape do set shape.color = "cyan" }, {on PointerLeave at shape:Shape do set shape.color = "green" } }, {EllipseShape {GRect -2in, 3in, 0in, 1in}, border-color = "black", border-width = 1pt, color = "grey", start-angle = 95% * 360deg, stop-angle = 100% * 360deg, {on PointerEnter at shape:Shape do set shape.color = "cyan" }, {on PointerLeave at shape:Shape do set shape.color = "grey" } } } |