Skip to content

Commit

Permalink
fix remaining test cases
Browse files Browse the repository at this point in the history
  • Loading branch information
asmuth committed May 9, 2020
1 parent 480fa9e commit 06830f3
Show file tree
Hide file tree
Showing 24 changed files with 4,586 additions and 4,596 deletions.
52 changes: 23 additions & 29 deletions doc/examples/charts-basic/custom_font.clp
@@ -1,30 +1,24 @@
(width 2048px)
(height 512px)
(dpi 240)
(layer/resize 2048px 512px)
(layer/set-dpi 240)
(layer/set-font "Comic Sans MS")

(font "Comic Sans MS")
(limit-x (1404278100 1404299700))
(limit-y (0 120))

(axes
position (bottom left)
label-format-y (fixed 2)
label-format-x (datetime "%H:%M:%S")
label-placement-x (linear 2400)
label-placement-y (linear 20))

;; (draw/rectangle fill #f2f2f2)

(grid
color #fff)

(lines
data-x (csv "test/testdata/measurement.csv" time)
data-y (csv "test/testdata/measurement.csv" value2))

(legend
position (top right)
border none
margin 0.5em
item-flow on
item (label "A very serious measurement"))
(tools/plotgen
limit-x (1404278100 1404299700)
limit-y (0 120)
grid (
color #fff)
axes (
position (bottom left)
label-format-y (fixed 2)
label-format-x (datetime "%H:%M:%S")
label-placement-x (linear 2400)
label-placement-y (linear 20))
lines (
data-x (csv "test/testdata/measurement.csv" time)
data-y (csv "test/testdata/measurement.csv" value2))
legend (
position (top right)
border none
margin 0.5em
item-flow on
item (label "A very serious measurement")))
44 changes: 22 additions & 22 deletions doc/examples/charts-basic/custom_font.svg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
24 changes: 12 additions & 12 deletions doc/examples/charts-custom/custom_color_palette.clp
@@ -1,15 +1,15 @@
(width 2048px)
(height 1024px)
(dpi 240)
(layer/resize 2048px 1024px)
(layer/set-dpi 240)

;;(set color-palette (#0c0 #c00 #00c))

(legend
item (label "Test Color 1" color 1)
item (label "Test Color 2" color 2)
item (label "Test Color 3" color 3)
item (label "Test Color 4" color 4)
item (label "Test Color 5" color 5)
item (label "Test Color 6" color 6)
item (label "Test Color 7" color 7)
item (label "Test Color 8" color 8))
(tools/plotgen
legend (
item (label "Test Color 1" color 1)
item (label "Test Color 2" color 2)
item (label "Test Color 3" color 3)
item (label "Test Color 4" color 4)
item (label "Test Color 5" color 5)
item (label "Test Color 6" color 6)
item (label "Test Color 7" color 7)
item (label "Test Color 8" color 8)))
27 changes: 12 additions & 15 deletions doc/examples/charts-custom/text_i18n.clp
@@ -1,16 +1,13 @@
(dpi 400)
(width 3600px)
(height 1920px)

;;(set text-script "Arabic")

(legend
border none
margin 0
item (label "北京市 (Beijing)" color #06c)
item (label "תל אביב (Tel Aviv)" color #c06)
item (label "القاهرة‎ (Cairo)" color #c06)
item (label "Москва" color #60c)
item (label "東京都 (Tokyo)" color #6c0)
item (label "서울 (Seoul)"))
(layer/resize 3600px 1920px)
(layer/set-dpi 400)

(tools/plotgen
legend (
border none
margin 0
item (label "北京市 (Beijing)" color #06c)
item (label "תל אביב (Tel Aviv)" color #c06)
item (label "القاهرة‎ (Cairo)" color #c06)
item (label "Москва" color #60c)
item (label "東京都 (Tokyo)" color #6c0)
item (label "서울 (Seoul)")))
124 changes: 57 additions & 67 deletions doc/examples/charts-editorial/stacked_areas.clp
@@ -1,67 +1,57 @@
(width 1600px)
(height 800px)
(dpi 240)

;;(set color-palette zhang)

(limit-x (0 100))
(limit-y (0 90))

(axes
position (bottom left)
label-placement-y (linear-interval 10 10 80)
border-style-left none
label-offset-left 0
label-attach-left left
label-color-left #666)

(grid
tick-placement-x (none)
tick-placement-y (linear-interval 10 10 80)
color (rgba 0 0 0 .1))

(areas
data-x (5 10 20 30 40 50 60 70 80 90 100)
data-y (7 13 17 27 38 39 52 59 48 60 65)
color 5
stroke-width .6pt
stroke-color (rgba 0 0 0 .5))

(areas
data-x (5 10 20 30 40 50 60 70 80 90 100)
data-y (4 12 15 22 35 38 47 47 42 53 60)
color 4
stroke-width .6pt
stroke-color (rgba 0 0 0 .4))

(areas
data-x (5 10 20 30 40 50 60 70 80 90 100)
data-y (3 10 10 18 32 34 42 40 36 46 54)
color 3
stroke-width .6pt
stroke-color (rgba 0 0 0 .5))

(areas
data-x (5 10 20 30 40 50 60 70 80 90 100)
data-y (2 6 6 8 18 20 30 30 30 36 35)
color 2
stroke-width .6pt
stroke-color (rgba 0 0 0 .5))

(areas
data-x (5 10 20 30 40 50 60 70 80 90 100)
data-y (1 2 4 7 13 15 20 16 18 23 18)
color 1
stroke-width .6pt
stroke-color (rgba 0 0 0 .5))

(legend
position (top right)
margin 0
padding 0
item-flow on
item (label "Series A" color 1)
item (label "Series B" color 2)
item (label "Series C" color 3)
item (label "Series D" color 4)
item (label "Series E" color 5))
(layer/resize 1600px 800px)
(layer/set-dpi 240)

(tools/plotgen
limit-x (0 100)
limit-y (0 90)
axes (
position (bottom left)
label-placement-y (linear-interval 10 10 80)
border-style-left none
label-offset-left 0
label-attach-left left
label-color-left #666)
grid (
tick-placement-x (none)
tick-placement-y (linear-interval 10 10 80)
color (rgba 0 0 0 0.1))
areas (
data-x (5 10 20 30 40 50 60 70 80 90 100)
data-y (7 13 17 27 38 39 52 59 48 60 65)
color 5
stroke-width .6pt
stroke-color (rgba 0 0 0 0.5))
areas (
data-x (5 10 20 30 40 50 60 70 80 90 100)
data-y (4 12 15 22 35 38 47 47 42 53 60)
color 4
stroke-width .6pt
stroke-color (rgba 0 0 0 0.4))
areas (
data-x (5 10 20 30 40 50 60 70 80 90 100)
data-y (3 10 10 18 32 34 42 40 36 46 54)
color 3
stroke-width .6pt
stroke-color (rgba 0 0 0 0.5))
areas (
data-x (5 10 20 30 40 50 60 70 80 90 100)
data-y (2 6 6 8 18 20 30 30 30 36 35)
color 2
stroke-width .6pt
stroke-color (rgba 0 0 0 0.5))
areas (
data-x (5 10 20 30 40 50 60 70 80 90 100)
data-y (1 2 4 7 13 15 20 16 18 23 18)
color 1
stroke-width .6pt
stroke-color (rgba 0 0 0 0.5))
legend (
position (top right)
margin 0
padding 0
item-flow on
item (label "Series A" color 1)
item (label "Series B" color 2)
item (label "Series C" color 3)
item (label "Series D" color 4)
item (label "Series E" color 5)))

0 comments on commit 06830f3

Please sign in to comment.