Alexander Iljin
a050823f29
Move charts* to ui.gadgets.charts* in the resource:extra root
2017-04-17 13:54:51 -07:00
Alexander Iljin
ecbb04d3fb
charts.demo: add a red cosine wave to the demo chart
2017-04-17 13:54:51 -07:00
Alexander Iljin
ce403e1f75
charts.lines: fix edge cases for fix-left-chunk and fix-right-chunk
2017-04-17 13:54:51 -07:00
Alexander Iljin
42e0224258
charts.lines: add a test for y-in-bounds?
2017-04-17 13:54:51 -07:00
Alexander Iljin
59f35e4d97
charts.demos: add demo vocab
2017-04-17 13:54:51 -07:00
Alexander Iljin
c2f8572393
charts: add optional axes slot
2017-04-17 13:54:51 -07:00
Alexander Iljin
0c9cb2f0a7
charts.lines-docs: add documentation
2017-04-17 13:54:51 -07:00
Alexander Iljin
df3d0ec8a5
charts.lines: add clip-data tests, fix implementation of left-cut-x
2017-04-17 13:54:51 -07:00
Alexander Iljin
6fee00014f
charts.lines: update some names
...
left-cut -> left-cut-x, min -> xmin; right-cut -> right-cut-x, max -> xmax.
2017-04-17 13:54:51 -07:00
Alexander Iljin
b0ec86be44
charts.lines: use x and y instead of first and second
2017-04-17 13:54:51 -07:00
Alexander Iljin
4fda623f51
charts.lines: fix some comments
2017-04-17 13:54:51 -07:00
Alexander Iljin
6aa7aad5b1
charts.lines: remove middle and its tests
2017-04-17 13:54:51 -07:00
John Benediktsson
3e6a6c189c
charts.lines: some cleanup
2017-04-17 13:54:51 -07:00
Alexander Iljin
41f520d606
charts: scale the chart to the gadget size
2017-04-17 13:54:51 -07:00
Alexander Iljin
88b1770cca
charts: add BSD license headers
2017-04-17 13:54:51 -07:00
Alexander Iljin
8658ec83fc
charts.lines: add scale-chunks
2017-04-17 13:54:51 -07:00
Alexander Iljin
22413dfa58
charts: add chart-dim
2017-04-17 13:54:51 -07:00
Alexander Iljin
664922ca21
charts.lines: add scale
2017-04-17 13:54:51 -07:00
Alexander Iljin
467bc37137
charts.lines: add flip-y-axis
2017-04-17 13:54:51 -07:00
Alexander Iljin
be999902fd
charts.lines: more tests for drawable-chunks
2017-04-17 13:54:51 -07:00
Alexander Iljin
79da6e1442
charts.lines: add tests for fix-right-chunk, fix implementation
2017-04-17 13:54:51 -07:00
Alexander Iljin
37ec09dd7a
charts.lines: add tests for fix-left-chunk, fix implementation
2017-04-17 13:54:51 -07:00
Alexander Iljin
cfd271aa88
charts.lines: add tests for 2-point-chunk
2017-04-17 13:54:51 -07:00
Alexander Iljin
29a8b9285b
charts.lines: add tests for drawable-chunks
2017-04-17 13:54:50 -07:00
Alexander Iljin
f366f1f790
charts.lines: make each2* output the last element
2017-04-17 13:54:50 -07:00
Alexander Iljin
5a3ae9099d
charts.lines: implement (drawable-chunks)
2017-04-17 13:54:50 -07:00
Alexander Iljin
8a87a8077e
charts.lines: reduce the amount of data copying in draw-lines
2017-04-17 13:54:50 -07:00
Alexander Iljin
5c0fa9c94e
charts.lines: add fix-left-chunk and fix-right-chunk
2017-04-17 13:54:50 -07:00
Alexander Iljin
48304ce5b5
charts.lines: add 2-point-chunk
2017-04-17 13:54:50 -07:00
Alexander Iljin
e11cf1a60b
charts.lines: add x and y aliases
2017-04-17 13:54:50 -07:00
Alexander Iljin
e645990eed
charts.lines: add calc-x
2017-04-17 13:54:50 -07:00
Alexander Iljin
d3e671565f
charts.lines: add extra points where necessary for drawing
2017-04-17 13:54:50 -07:00
Alexander Iljin
ff0c2fdf32
charts.lines: drop slices that are out of y range in drawable-chunks
2017-04-17 13:54:50 -07:00
Alexander Iljin
cb2fbac778
charts.lines: preliminary implementation of drawable-chunks
2017-04-17 13:54:50 -07:00
Alexander Iljin
739adb122d
charts.lines: factor some common code into y-at
2017-04-17 13:54:50 -07:00
Alexander Iljin
97d6ca4a83
charts.lines: add min-max-cut to cut data on the x axis
2017-04-17 13:54:50 -07:00
Alexander Iljin
c9def10dde
charts.lines: add last2
2017-04-17 13:54:50 -07:00
Alexander Iljin
fb2538a946
charts.lines: add calc-y
2017-04-17 13:54:50 -07:00
Alexander Iljin
8510b351cf
charts.lines: add calc-line-slope
2017-04-17 13:54:50 -07:00
Alexander Iljin
cdc321cd93
charts.lines: avoid calling like when not necessary
2017-04-17 13:54:50 -07:00
Alexander Iljin
317fe9e9f4
charts.lines: don't keep extra elements in data if exact match was found
2017-04-17 13:54:50 -07:00
Alexander Iljin
6071bd8d26
charts.lines: add and update some comments
2017-04-17 13:54:50 -07:00
Alexander Iljin
118b06be29
charts.lines: make clip-by-first operate on slices internally
2017-04-17 13:54:50 -07:00
Alexander Iljin
418b798460
charts.lines: rename search-index to search-first
2017-04-17 13:54:50 -07:00
Alexander Iljin
e9606b38d9
charts.lines: add dummy drawable-chunks
2017-04-17 13:54:50 -07:00
Alexander Iljin
13c197aa26
charts.lines: move (line-vertices) into private section
2017-04-17 13:54:50 -07:00
Alexander Iljin
fecae1bda6
charts: update some comments
2017-04-17 13:54:50 -07:00
Alexander Iljin
4b416f1a5a
charts: move code related to line drawing to charts.lines
2017-04-17 13:54:50 -07:00
Alexander Iljin
b357c62122
charts: use clip-data in draw-gadget*
2017-04-17 13:54:50 -07:00
Alexander Iljin
72c1ccba96
charts: make clip-data handle y coords as well
...
Implementation is efficient: the minmax for y is only called after trimming
the data on the x bounds. If the entire data set is outside the x range,
handling is terminated early.
2017-04-17 13:54:50 -07:00