123456789101112131415161718192021222324252627282930 |
- using fwt
- using gfx
- using swtChartWrapper
- class Example1
- {
- public static Void main ()
- {
- // define the series of data points to display
- series := LineSeries
- {
- label = "line series"
- points = [0.0f, 0.4f, 0.7f, 0.9f, 1.0f, 0.9f, 0.7f, 0.4f, 0.0f, -0.4f, -0.7f, -0.9f, -1.0f, -0.9f, -0.7f, -0.4f]
- }
- // define a window to display the chart in
- Window
- {
- title = "Example Chart"
- size = Size(450, 350)
- Chart
- {
- title.text = "Line Chart Example"
- xAxis.title.text = "Data Points"
- yAxis.title.text = "Amplitude"
- data = [series]
- },
- }.open
- }
- }
|