reportbuilder 1.2.5 → 1.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (392) hide show
  1. data.tar.gz.sig +0 -0
  2. data/History.txt +6 -0
  3. data/Manifest.txt +377 -0
  4. data/data/flot/API.txt +1024 -0
  5. data/data/flot/FAQ.txt +71 -0
  6. data/data/flot/LICENSE.txt +22 -0
  7. data/data/flot/Makefile +15 -0
  8. data/data/flot/NEWS.txt +340 -0
  9. data/data/flot/PLUGINS.txt +105 -0
  10. data/data/flot/README.txt +81 -0
  11. data/data/flot/examples/ajax.html +143 -0
  12. data/data/flot/examples/annotating.html +75 -0
  13. data/data/flot/examples/arrow-down.gif +0 -0
  14. data/data/flot/examples/arrow-left.gif +0 -0
  15. data/data/flot/examples/arrow-right.gif +0 -0
  16. data/data/flot/examples/arrow-up.gif +0 -0
  17. data/data/flot/examples/basic.html +38 -0
  18. data/data/flot/examples/data-eu-gdp-growth-1.json +4 -0
  19. data/data/flot/examples/data-eu-gdp-growth-2.json +4 -0
  20. data/data/flot/examples/data-eu-gdp-growth-3.json +4 -0
  21. data/data/flot/examples/data-eu-gdp-growth-4.json +4 -0
  22. data/data/flot/examples/data-eu-gdp-growth-5.json +4 -0
  23. data/data/flot/examples/data-eu-gdp-growth.json +4 -0
  24. data/data/flot/examples/data-japan-gdp-growth.json +4 -0
  25. data/data/flot/examples/data-usa-gdp-growth.json +4 -0
  26. data/data/flot/examples/dual-axis.html +39 -0
  27. data/data/flot/examples/graph-types.html +75 -0
  28. data/data/flot/examples/hs-2004-27-a-large_web.jpg +0 -0
  29. data/data/flot/examples/image.html +45 -0
  30. data/data/flot/examples/index.html +43 -0
  31. data/data/flot/examples/interacting.html +93 -0
  32. data/data/flot/examples/layout.css +6 -0
  33. data/data/flot/examples/navigate.html +118 -0
  34. data/data/flot/examples/selection.html +114 -0
  35. data/data/flot/examples/setting-options.html +65 -0
  36. data/data/flot/examples/stacking.html +77 -0
  37. data/data/flot/examples/thresholding.html +54 -0
  38. data/data/flot/examples/time.html +71 -0
  39. data/data/flot/examples/tracking.html +95 -0
  40. data/data/flot/examples/turning-series.html +98 -0
  41. data/data/flot/examples/visitors.html +90 -0
  42. data/data/flot/examples/zooming.html +98 -0
  43. data/data/flot/excanvas.js +1427 -0
  44. data/data/flot/excanvas.min.js +1 -0
  45. data/data/flot/jquery.colorhelpers.js +174 -0
  46. data/data/flot/jquery.colorhelpers.min.js +1 -0
  47. data/data/flot/jquery.flot.crosshair.js +156 -0
  48. data/data/flot/jquery.flot.crosshair.min.js +1 -0
  49. data/data/flot/jquery.flot.image.js +237 -0
  50. data/data/flot/jquery.flot.image.min.js +1 -0
  51. data/data/flot/jquery.flot.js +2119 -0
  52. data/data/flot/jquery.flot.min.js +1 -0
  53. data/data/flot/jquery.flot.navigate.js +272 -0
  54. data/data/flot/jquery.flot.navigate.min.js +1 -0
  55. data/data/flot/jquery.flot.selection.js +299 -0
  56. data/data/flot/jquery.flot.selection.min.js +1 -0
  57. data/data/flot/jquery.flot.stack.js +152 -0
  58. data/data/flot/jquery.flot.stack.min.js +1 -0
  59. data/data/flot/jquery.flot.threshold.js +103 -0
  60. data/data/flot/jquery.flot.threshold.min.js +1 -0
  61. data/data/flot/jquery.js +4376 -0
  62. data/data/flot/jquery.min.js +19 -0
  63. data/data/jqplot/MIT-LICENSE.txt +21 -0
  64. data/data/jqplot/README.txt +73 -0
  65. data/data/jqplot/changes.txt +261 -0
  66. data/data/jqplot/copyright.txt +33 -0
  67. data/data/jqplot/docs/files/MIT-LICENSE-txt.html +39 -0
  68. data/data/jqplot/docs/files/changes-txt.html +39 -0
  69. data/data/jqplot/docs/files/gpl-2-0-txt.html +39 -0
  70. data/data/jqplot/docs/files/images/background.jpg +0 -0
  71. data/data/jqplot/docs/files/images/basicline.png +0 -0
  72. data/data/jqplot/docs/files/images/basiclogaxis.png +0 -0
  73. data/data/jqplot/docs/files/images/basiclogoptions.png +0 -0
  74. data/data/jqplot/docs/files/images/basicoptions.png +0 -0
  75. data/data/jqplot/docs/files/images/dualaxis.png +0 -0
  76. data/data/jqplot/docs/files/images/logo.jpg +0 -0
  77. data/data/jqplot/docs/files/images/navdocs.png +0 -0
  78. data/data/jqplot/docs/files/images/navdocsover.png +0 -0
  79. data/data/jqplot/docs/files/images/navdownload.png +0 -0
  80. data/data/jqplot/docs/files/images/navdownloadover.png +0 -0
  81. data/data/jqplot/docs/files/images/navexamples.png +0 -0
  82. data/data/jqplot/docs/files/images/navexamplesover.png +0 -0
  83. data/data/jqplot/docs/files/images/navhome.png +0 -0
  84. data/data/jqplot/docs/files/images/navhomeover.png +0 -0
  85. data/data/jqplot/docs/files/images/new.png +0 -0
  86. data/data/jqplot/docs/files/images/sample3.png +0 -0
  87. data/data/jqplot/docs/files/images/samplesm.png +0 -0
  88. data/data/jqplot/docs/files/jqPlotCssStyling-txt.html +39 -0
  89. data/data/jqplot/docs/files/jqPlotOptions-txt.html +292 -0
  90. data/data/jqplot/docs/files/jqplot-axisLabelRenderer-js.html +47 -0
  91. data/data/jqplot/docs/files/jqplot-axisTickRenderer-js.html +69 -0
  92. data/data/jqplot/docs/files/jqplot-canvasGridRenderer-js.html +39 -0
  93. data/data/jqplot/docs/files/jqplot-core-js.html +353 -0
  94. data/data/jqplot/docs/files/jqplot-divTitleRenderer-js.html +39 -0
  95. data/data/jqplot/docs/files/jqplot-lineRenderer-js.html +53 -0
  96. data/data/jqplot/docs/files/jqplot-linearAxisRenderer-js.html +39 -0
  97. data/data/jqplot/docs/files/jqplot-markerRenderer-js.html +65 -0
  98. data/data/jqplot/docs/files/jqplot-shadowRenderer-js.html +61 -0
  99. data/data/jqplot/docs/files/jqplot-shapeRenderer-js.html +63 -0
  100. data/data/jqplot/docs/files/jqplot-themeEngine-js.html +190 -0
  101. data/data/jqplot/docs/files/optionsTutorial-txt.html +119 -0
  102. data/data/jqplot/docs/files/plugins/jqplot-BezierCurveRenderer-js.html +45 -0
  103. data/data/jqplot/docs/files/plugins/jqplot-barRenderer-js.html +67 -0
  104. data/data/jqplot/docs/files/plugins/jqplot-blockRenderer-js.html +53 -0
  105. data/data/jqplot/docs/files/plugins/jqplot-bubbleRenderer-js.html +71 -0
  106. data/data/jqplot/docs/files/plugins/jqplot-canvasAxisLabelRenderer-js.html +63 -0
  107. data/data/jqplot/docs/files/plugins/jqplot-canvasAxisTickRenderer-js.html +79 -0
  108. data/data/jqplot/docs/files/plugins/jqplot-categoryAxisRenderer-js.html +46 -0
  109. data/data/jqplot/docs/files/plugins/jqplot-cursor-js.html +91 -0
  110. data/data/jqplot/docs/files/plugins/jqplot-dateAxisRenderer-js.html +93 -0
  111. data/data/jqplot/docs/files/plugins/jqplot-donutRenderer-js.html +98 -0
  112. data/data/jqplot/docs/files/plugins/jqplot-dragable-js.html +45 -0
  113. data/data/jqplot/docs/files/plugins/jqplot-enhancedLegendRenderer-js.html +49 -0
  114. data/data/jqplot/docs/files/plugins/jqplot-funnelRenderer-js.html +87 -0
  115. data/data/jqplot/docs/files/plugins/jqplot-highlighter-js.html +80 -0
  116. data/data/jqplot/docs/files/plugins/jqplot-logAxisRenderer-js.html +45 -0
  117. data/data/jqplot/docs/files/plugins/jqplot-mekkoAxisRenderer-js.html +49 -0
  118. data/data/jqplot/docs/files/plugins/jqplot-mekkoRenderer-js.html +62 -0
  119. data/data/jqplot/docs/files/plugins/jqplot-meterGaugeRenderer-js.html +103 -0
  120. data/data/jqplot/docs/files/plugins/jqplot-ohlcRenderer-js.html +65 -0
  121. data/data/jqplot/docs/files/plugins/jqplot-pieRenderer-js.html +93 -0
  122. data/data/jqplot/docs/files/plugins/jqplot-pointLabels-js.html +72 -0
  123. data/data/jqplot/docs/files/plugins/jqplot-trendline-js.html +67 -0
  124. data/data/jqplot/docs/files/usage-txt.html +58 -0
  125. data/data/jqplot/docs/index.html +1 -0
  126. data/data/jqplot/docs/index/Classes.html +58 -0
  127. data/data/jqplot/docs/index/Files.html +34 -0
  128. data/data/jqplot/docs/index/Functions.html +66 -0
  129. data/data/jqplot/docs/index/General.html +46 -0
  130. data/data/jqplot/docs/index/General2.html +46 -0
  131. data/data/jqplot/docs/index/General3.html +46 -0
  132. data/data/jqplot/docs/index/General4.html +50 -0
  133. data/data/jqplot/docs/index/General5.html +34 -0
  134. data/data/jqplot/docs/index/General6.html +58 -0
  135. data/data/jqplot/docs/index/Hooks.html +46 -0
  136. data/data/jqplot/docs/index/Properties.html +50 -0
  137. data/data/jqplot/docs/index/Properties2.html +50 -0
  138. data/data/jqplot/docs/index/Properties3.html +50 -0
  139. data/data/jqplot/docs/index/Properties4.html +34 -0
  140. data/data/jqplot/docs/index/Properties5.html +58 -0
  141. data/data/jqplot/docs/javascript/main.js +836 -0
  142. data/data/jqplot/docs/javascript/searchdata.js +182 -0
  143. data/data/jqplot/docs/search/ClassesA.html +20 -0
  144. data/data/jqplot/docs/search/ClassesG.html +20 -0
  145. data/data/jqplot/docs/search/ClassesJ.html +20 -0
  146. data/data/jqplot/docs/search/ClassesL.html +20 -0
  147. data/data/jqplot/docs/search/ClassesS.html +20 -0
  148. data/data/jqplot/docs/search/ClassesSymbols.html +20 -0
  149. data/data/jqplot/docs/search/ClassesT.html +20 -0
  150. data/data/jqplot/docs/search/FilesJ.html +20 -0
  151. data/data/jqplot/docs/search/FunctionsC.html +20 -0
  152. data/data/jqplot/docs/search/FunctionsD.html +20 -0
  153. data/data/jqplot/docs/search/FunctionsG.html +20 -0
  154. data/data/jqplot/docs/search/FunctionsI.html +20 -0
  155. data/data/jqplot/docs/search/FunctionsM.html +20 -0
  156. data/data/jqplot/docs/search/FunctionsN.html +20 -0
  157. data/data/jqplot/docs/search/FunctionsR.html +20 -0
  158. data/data/jqplot/docs/search/FunctionsS.html +20 -0
  159. data/data/jqplot/docs/search/FunctionsZ.html +20 -0
  160. data/data/jqplot/docs/search/GeneralA.html +20 -0
  161. data/data/jqplot/docs/search/GeneralB.html +20 -0
  162. data/data/jqplot/docs/search/GeneralC.html +20 -0
  163. data/data/jqplot/docs/search/GeneralD.html +20 -0
  164. data/data/jqplot/docs/search/GeneralE.html +20 -0
  165. data/data/jqplot/docs/search/GeneralF.html +20 -0
  166. data/data/jqplot/docs/search/GeneralG.html +20 -0
  167. data/data/jqplot/docs/search/GeneralH.html +20 -0
  168. data/data/jqplot/docs/search/GeneralI.html +20 -0
  169. data/data/jqplot/docs/search/GeneralJ.html +20 -0
  170. data/data/jqplot/docs/search/GeneralL.html +20 -0
  171. data/data/jqplot/docs/search/GeneralM.html +20 -0
  172. data/data/jqplot/docs/search/GeneralN.html +20 -0
  173. data/data/jqplot/docs/search/GeneralO.html +20 -0
  174. data/data/jqplot/docs/search/GeneralP.html +20 -0
  175. data/data/jqplot/docs/search/GeneralR.html +20 -0
  176. data/data/jqplot/docs/search/GeneralS.html +20 -0
  177. data/data/jqplot/docs/search/GeneralSymbols.html +20 -0
  178. data/data/jqplot/docs/search/GeneralT.html +20 -0
  179. data/data/jqplot/docs/search/GeneralU.html +20 -0
  180. data/data/jqplot/docs/search/GeneralV.html +20 -0
  181. data/data/jqplot/docs/search/GeneralW.html +20 -0
  182. data/data/jqplot/docs/search/GeneralX.html +20 -0
  183. data/data/jqplot/docs/search/GeneralY.html +20 -0
  184. data/data/jqplot/docs/search/GeneralZ.html +20 -0
  185. data/data/jqplot/docs/search/HooksA.html +20 -0
  186. data/data/jqplot/docs/search/HooksE.html +20 -0
  187. data/data/jqplot/docs/search/HooksJ.html +20 -0
  188. data/data/jqplot/docs/search/HooksP.html +20 -0
  189. data/data/jqplot/docs/search/NoResults.html +15 -0
  190. data/data/jqplot/docs/search/PropertiesA.html +20 -0
  191. data/data/jqplot/docs/search/PropertiesB.html +20 -0
  192. data/data/jqplot/docs/search/PropertiesC.html +20 -0
  193. data/data/jqplot/docs/search/PropertiesD.html +20 -0
  194. data/data/jqplot/docs/search/PropertiesE.html +20 -0
  195. data/data/jqplot/docs/search/PropertiesF.html +20 -0
  196. data/data/jqplot/docs/search/PropertiesG.html +20 -0
  197. data/data/jqplot/docs/search/PropertiesH.html +20 -0
  198. data/data/jqplot/docs/search/PropertiesI.html +20 -0
  199. data/data/jqplot/docs/search/PropertiesL.html +20 -0
  200. data/data/jqplot/docs/search/PropertiesM.html +20 -0
  201. data/data/jqplot/docs/search/PropertiesN.html +20 -0
  202. data/data/jqplot/docs/search/PropertiesO.html +20 -0
  203. data/data/jqplot/docs/search/PropertiesP.html +20 -0
  204. data/data/jqplot/docs/search/PropertiesR.html +20 -0
  205. data/data/jqplot/docs/search/PropertiesS.html +20 -0
  206. data/data/jqplot/docs/search/PropertiesT.html +20 -0
  207. data/data/jqplot/docs/search/PropertiesU.html +20 -0
  208. data/data/jqplot/docs/search/PropertiesV.html +20 -0
  209. data/data/jqplot/docs/search/PropertiesW.html +20 -0
  210. data/data/jqplot/docs/search/PropertiesX.html +20 -0
  211. data/data/jqplot/docs/search/PropertiesY.html +20 -0
  212. data/data/jqplot/docs/search/PropertiesZ.html +20 -0
  213. data/data/jqplot/docs/styles/1.css +767 -0
  214. data/data/jqplot/docs/styles/2.css +174 -0
  215. data/data/jqplot/docs/styles/main.css +2 -0
  216. data/data/jqplot/examples/.htaccess +1 -0
  217. data/data/jqplot/examples/OHLC.html +333 -0
  218. data/data/jqplot/examples/OHLC2.html +193 -0
  219. data/data/jqplot/examples/area.html +107 -0
  220. data/data/jqplot/examples/axisLabel.html +117 -0
  221. data/data/jqplot/examples/axisLabelsRotatedText.html +131 -0
  222. data/data/jqplot/examples/axisLabelsRotatedText2.html +155 -0
  223. data/data/jqplot/examples/barLinePieStack.html +198 -0
  224. data/data/jqplot/examples/barMissingValues.html +64 -0
  225. data/data/jqplot/examples/barTest.html +283 -0
  226. data/data/jqplot/examples/barTest2.html +74 -0
  227. data/data/jqplot/examples/bezierCurve.html +96 -0
  228. data/data/jqplot/examples/blockPlot.html +149 -0
  229. data/data/jqplot/examples/bubbleChart2.html +253 -0
  230. data/data/jqplot/examples/bubblechart.html +69 -0
  231. data/data/jqplot/examples/catchError.html +53 -0
  232. data/data/jqplot/examples/categoryHorizontalBar.html +81 -0
  233. data/data/jqplot/examples/categoryVsLinearAxes.html +74 -0
  234. data/data/jqplot/examples/chartInTable.html +33 -0
  235. data/data/jqplot/examples/customHighlighterCursorTrendline.html +72 -0
  236. data/data/jqplot/examples/customPieTests.html +73 -0
  237. data/data/jqplot/examples/dataLabels.html +192 -0
  238. data/data/jqplot/examples/dataTracking.html +91 -0
  239. data/data/jqplot/examples/donutTest.html +89 -0
  240. data/data/jqplot/examples/donutTest.js +96 -0
  241. data/data/jqplot/examples/examples.css +19 -0
  242. data/data/jqplot/examples/fillToZero.html +126 -0
  243. data/data/jqplot/examples/filledLine.html +78 -0
  244. data/data/jqplot/examples/filledLineCategoryAxis.html +80 -0
  245. data/data/jqplot/examples/funnelTest.html +82 -0
  246. data/data/jqplot/examples/funnelTest.js +74 -0
  247. data/data/jqplot/examples/gridCustomization.html +56 -0
  248. data/data/jqplot/examples/hiddenPlot.html +216 -0
  249. data/data/jqplot/examples/highlighter.html +95 -0
  250. data/data/jqplot/examples/highlighter2.html +63 -0
  251. data/data/jqplot/examples/horizontalLine.html +51 -0
  252. data/data/jqplot/examples/intticks.html +178 -0
  253. data/data/jqplot/examples/jquery-ui/css/ui-lightness/images/ui-bg_diagonals-thick_18_b81900_40x40.png +0 -0
  254. data/data/jqplot/examples/jquery-ui/css/ui-lightness/images/ui-bg_diagonals-thick_20_666666_40x40.png +0 -0
  255. data/data/jqplot/examples/jquery-ui/css/ui-lightness/images/ui-bg_flat_10_000000_40x100.png +0 -0
  256. data/data/jqplot/examples/jquery-ui/css/ui-lightness/images/ui-bg_glass_100_f6f6f6_1x400.png +0 -0
  257. data/data/jqplot/examples/jquery-ui/css/ui-lightness/images/ui-bg_glass_100_fdf5ce_1x400.png +0 -0
  258. data/data/jqplot/examples/jquery-ui/css/ui-lightness/images/ui-bg_glass_65_ffffff_1x400.png +0 -0
  259. data/data/jqplot/examples/jquery-ui/css/ui-lightness/images/ui-bg_gloss-wave_35_f6a828_500x100.png +0 -0
  260. data/data/jqplot/examples/jquery-ui/css/ui-lightness/images/ui-bg_highlight-soft_100_eeeeee_1x100.png +0 -0
  261. data/data/jqplot/examples/jquery-ui/css/ui-lightness/images/ui-bg_highlight-soft_75_ffe45c_1x100.png +0 -0
  262. data/data/jqplot/examples/jquery-ui/css/ui-lightness/images/ui-icons_222222_256x240.png +0 -0
  263. data/data/jqplot/examples/jquery-ui/css/ui-lightness/images/ui-icons_228ef1_256x240.png +0 -0
  264. data/data/jqplot/examples/jquery-ui/css/ui-lightness/images/ui-icons_ef8c08_256x240.png +0 -0
  265. data/data/jqplot/examples/jquery-ui/css/ui-lightness/images/ui-icons_ffd27a_256x240.png +0 -0
  266. data/data/jqplot/examples/jquery-ui/css/ui-lightness/images/ui-icons_ffffff_256x240.png +0 -0
  267. data/data/jqplot/examples/jquery-ui/css/ui-lightness/jquery-ui-1.8.1.custom.css +486 -0
  268. data/data/jqplot/examples/jquery-ui/js/jquery-1.4.2.min.js +154 -0
  269. data/data/jqplot/examples/jquery-ui/js/jquery-ui-1.8.1.custom.min.js +756 -0
  270. data/data/jqplot/examples/legendLabels.html +205 -0
  271. data/data/jqplot/examples/legendLabels2.html +228 -0
  272. data/data/jqplot/examples/liz.zip +0 -0
  273. data/data/jqplot/examples/markerStyles.html +44 -0
  274. data/data/jqplot/examples/mekkoChart.html +217 -0
  275. data/data/jqplot/examples/meterGauge.html +132 -0
  276. data/data/jqplot/examples/meterGauge2.html +158 -0
  277. data/data/jqplot/examples/minMaxLines.html +61 -0
  278. data/data/jqplot/examples/missingValues.html +119 -0
  279. data/data/jqplot/examples/multiAxesRotatedText.html +70 -0
  280. data/data/jqplot/examples/multipleBarColors.html +149 -0
  281. data/data/jqplot/examples/multipleLines.html +47 -0
  282. data/data/jqplot/examples/multipleYAxes.html +85 -0
  283. data/data/jqplot/examples/nav.inc +35 -0
  284. data/data/jqplot/examples/pieTest.html +77 -0
  285. data/data/jqplot/examples/pieTest2.html +87 -0
  286. data/data/jqplot/examples/pieTest2.js +80 -0
  287. data/data/jqplot/examples/pieTest3.html +100 -0
  288. data/data/jqplot/examples/pointLabels.html +94 -0
  289. data/data/jqplot/examples/pointLabels2.html +47 -0
  290. data/data/jqplot/examples/prefix.html +90 -0
  291. data/data/jqplot/examples/resizablePlot.html +150 -0
  292. data/data/jqplot/examples/rotatedTickLabels.html +61 -0
  293. data/data/jqplot/examples/rotatedTickLabelsZoom.html +68 -0
  294. data/data/jqplot/examples/seriesCanvasReorder.html +93 -0
  295. data/data/jqplot/examples/seriesUpdate.html +123 -0
  296. data/data/jqplot/examples/shadowTests.html +133 -0
  297. data/data/jqplot/examples/singlePoint.html +70 -0
  298. data/data/jqplot/examples/sparkLine.html +48 -0
  299. data/data/jqplot/examples/stackedBar2.html +104 -0
  300. data/data/jqplot/examples/stackedBar3.html +76 -0
  301. data/data/jqplot/examples/stackedBarCategoryVsLinearAxes.html +121 -0
  302. data/data/jqplot/examples/stackedCategoryAxis.html +89 -0
  303. data/data/jqplot/examples/stackedFilledLine.html +77 -0
  304. data/data/jqplot/examples/stackedLine.html +56 -0
  305. data/data/jqplot/examples/test2.html +64 -0
  306. data/data/jqplot/examples/theming.html +483 -0
  307. data/data/jqplot/examples/trendlineDragableCustomization.html +79 -0
  308. data/data/jqplot/examples/verticalLine.html +52 -0
  309. data/data/jqplot/examples/waterfall.html +135 -0
  310. data/data/jqplot/examples/zoom1.html +125 -0
  311. data/data/jqplot/examples/zoom2.html +73 -0
  312. data/data/jqplot/examples/zoom3.html +69 -0
  313. data/data/jqplot/examples/zoomOptions.html +101 -0
  314. data/data/jqplot/examples/zoomProxy.html +108 -0
  315. data/data/jqplot/excanvas.js +1416 -0
  316. data/data/jqplot/excanvas.min.js +35 -0
  317. data/data/jqplot/gpl-2.0.txt +280 -0
  318. data/data/jqplot/jqPlotCssStyling.txt +53 -0
  319. data/data/jqplot/jqPlotOptions.txt +276 -0
  320. data/data/jqplot/jquery-1.4.1.min.js +152 -0
  321. data/data/jqplot/jquery-1.4.2.min.js +154 -0
  322. data/data/jqplot/jquery.jqplot.css +212 -0
  323. data/data/jqplot/jquery.jqplot.js +7004 -0
  324. data/data/jqplot/jquery.jqplot.min.css +1 -0
  325. data/data/jqplot/jquery.jqplot.min.js +34 -0
  326. data/data/jqplot/optionsTutorial.txt +239 -0
  327. data/data/jqplot/plugins/jqplot.BezierCurveRenderer.js +300 -0
  328. data/data/jqplot/plugins/jqplot.BezierCurveRenderer.min.js +34 -0
  329. data/data/jqplot/plugins/jqplot.barRenderer.js +629 -0
  330. data/data/jqplot/plugins/jqplot.barRenderer.min.js +34 -0
  331. data/data/jqplot/plugins/jqplot.blockRenderer.js +221 -0
  332. data/data/jqplot/plugins/jqplot.blockRenderer.min.js +34 -0
  333. data/data/jqplot/plugins/jqplot.bubbleRenderer.js +724 -0
  334. data/data/jqplot/plugins/jqplot.bubbleRenderer.min.js +34 -0
  335. data/data/jqplot/plugins/jqplot.canvasAxisLabelRenderer.js +187 -0
  336. data/data/jqplot/plugins/jqplot.canvasAxisLabelRenderer.min.js +34 -0
  337. data/data/jqplot/plugins/jqplot.canvasAxisTickRenderer.js +226 -0
  338. data/data/jqplot/plugins/jqplot.canvasAxisTickRenderer.min.js +34 -0
  339. data/data/jqplot/plugins/jqplot.canvasTextRenderer.js +408 -0
  340. data/data/jqplot/plugins/jqplot.canvasTextRenderer.min.js +34 -0
  341. data/data/jqplot/plugins/jqplot.categoryAxisRenderer.js +630 -0
  342. data/data/jqplot/plugins/jqplot.categoryAxisRenderer.min.js +34 -0
  343. data/data/jqplot/plugins/jqplot.cursor.js +952 -0
  344. data/data/jqplot/plugins/jqplot.cursor.min.js +34 -0
  345. data/data/jqplot/plugins/jqplot.dateAxisRenderer.js +313 -0
  346. data/data/jqplot/plugins/jqplot.dateAxisRenderer.min.js +34 -0
  347. data/data/jqplot/plugins/jqplot.donutRenderer.js +876 -0
  348. data/data/jqplot/plugins/jqplot.donutRenderer.min.js +34 -0
  349. data/data/jqplot/plugins/jqplot.dragable.js +206 -0
  350. data/data/jqplot/plugins/jqplot.dragable.min.js +34 -0
  351. data/data/jqplot/plugins/jqplot.enhancedLegendRenderer.js +186 -0
  352. data/data/jqplot/plugins/jqplot.enhancedLegendRenderer.min.js +34 -0
  353. data/data/jqplot/plugins/jqplot.funnelRenderer.js +918 -0
  354. data/data/jqplot/plugins/jqplot.funnelRenderer.min.js +34 -0
  355. data/data/jqplot/plugins/jqplot.highlighter.js +374 -0
  356. data/data/jqplot/plugins/jqplot.highlighter.min.js +34 -0
  357. data/data/jqplot/plugins/jqplot.logAxisRenderer.js +434 -0
  358. data/data/jqplot/plugins/jqplot.logAxisRenderer.min.js +34 -0
  359. data/data/jqplot/plugins/jqplot.mekkoAxisRenderer.js +595 -0
  360. data/data/jqplot/plugins/jqplot.mekkoAxisRenderer.min.js +34 -0
  361. data/data/jqplot/plugins/jqplot.mekkoRenderer.js +419 -0
  362. data/data/jqplot/plugins/jqplot.mekkoRenderer.min.js +34 -0
  363. data/data/jqplot/plugins/jqplot.meterGaugeRenderer.js +1112 -0
  364. data/data/jqplot/plugins/jqplot.meterGaugeRenderer.min.js +34 -0
  365. data/data/jqplot/plugins/jqplot.ohlcRenderer.js +343 -0
  366. data/data/jqplot/plugins/jqplot.ohlcRenderer.min.js +34 -0
  367. data/data/jqplot/plugins/jqplot.pieRenderer.js +749 -0
  368. data/data/jqplot/plugins/jqplot.pieRenderer.min.js +34 -0
  369. data/data/jqplot/plugins/jqplot.pointLabels.js +325 -0
  370. data/data/jqplot/plugins/jqplot.pointLabels.min.js +34 -0
  371. data/data/jqplot/plugins/jqplot.trendline.js +208 -0
  372. data/data/jqplot/plugins/jqplot.trendline.min.js +34 -0
  373. data/data/jqplot/usage.txt +119 -0
  374. data/examples/graph.rb +17 -0
  375. data/lib/reportbuilder.rb +21 -2
  376. data/lib/reportbuilder/builder.rb +31 -3
  377. data/lib/reportbuilder/builder/html.rb +39 -5
  378. data/lib/reportbuilder/graph.rb +252 -0
  379. data/lib/reportbuilder/graph/html_flot.rb +149 -0
  380. data/lib/reportbuilder/graph/html_jqplot.rb +145 -0
  381. data/lib/reportbuilder/image.rb +178 -78
  382. data/lib/reportbuilder/table/rtfbuilder.rb +2 -2
  383. data/test/helper_test.rb +6 -7
  384. data/test/test_graph.rb +44 -0
  385. data/test/test_graph_html_flot.rb +36 -0
  386. data/test/test_graph_html_jqplot.rb +36 -0
  387. data/test/test_html.rb +4 -7
  388. data/test/test_image.rb +35 -7
  389. data/test/test_reportbuilder.rb +4 -6
  390. data/test/test_table.rb +0 -2
  391. metadata +402 -7
  392. metadata.gz.sig +4 -2
@@ -0,0 +1,34 @@
1
+ /**
2
+ * Copyright (c) 2009 - 2010 Chris Leonello
3
+ * jqPlot is currently available for use in all personal or commercial projects
4
+ * under both the MIT (http://www.opensource.org/licenses/mit-license.php) and GPL
5
+ * version 2.0 (http://www.gnu.org/licenses/gpl-2.0.html) licenses. This means that you can
6
+ * choose the license that best suits your project and use it accordingly.
7
+ *
8
+ * Although not required, the author would appreciate an email letting him
9
+ * know of any substantial use of jqPlot. You can reach the author at:
10
+ * chris at jqplot or see http://www.jqplot.com/info.php .
11
+ *
12
+ * If you are feeling kind and generous, consider supporting the project by
13
+ * making a donation at: http://www.jqplot.com/donate.php .
14
+ *
15
+ * jqPlot includes date instance methods and printf/sprintf functions by other authors:
16
+ *
17
+ * Date instance methods contained in jqplot.dateMethods.js:
18
+ *
19
+ * author Ken Snyder (ken d snyder at gmail dot com)
20
+ * date 2008-09-10
21
+ * version 2.0.2 (http://kendsnyder.com/sandbox/date/)
22
+ * license Creative Commons Attribution License 3.0 (http://creativecommons.org/licenses/by/3.0/)
23
+ *
24
+ * JavaScript printf/sprintf functions contained in jqplot.sprintf.js:
25
+ *
26
+ * version 2007.04.27
27
+ * author Ash Searle
28
+ * http://hexmen.com/blog/2007/03/printf-sprintf/
29
+ * http://hexmen.com/js/sprintf.js
30
+ * The author (Ash Searle) has placed this code in the public domain:
31
+ * "This code is unrestricted: you are free to use it however you like."
32
+ *
33
+ */
34
+ (function(a){a.jqplot.EnhancedLegendRenderer=function(){a.jqplot.TableLegendRenderer.call(this)};a.jqplot.EnhancedLegendRenderer.prototype=new a.jqplot.TableLegendRenderer();a.jqplot.EnhancedLegendRenderer.prototype.constructor=a.jqplot.EnhancedLegendRenderer;a.jqplot.EnhancedLegendRenderer.prototype.init=function(b){this.numberRows=null;this.numberColumns=null;this.seriesToggle="normal";this.disableIEFading=true;a.extend(true,this,b);if(this.seriesToggle){a.jqplot.postDrawHooks.push(postDraw)}};a.jqplot.EnhancedLegendRenderer.prototype.draw=function(){var t=this;if(this.show){var m=this._series;var u="position:absolute;";u+=(this.background)?"background:"+this.background+";":"";u+=(this.border)?"border:"+this.border+";":"";u+=(this.fontSize)?"font-size:"+this.fontSize+";":"";u+=(this.fontFamily)?"font-family:"+this.fontFamily+";":"";u+=(this.textColor)?"color:"+this.textColor+";":"";u+=(this.marginTop!=null)?"margin-top:"+this.marginTop+";":"";u+=(this.marginBottom!=null)?"margin-bottom:"+this.marginBottom+";":"";u+=(this.marginLeft!=null)?"margin-left:"+this.marginLeft+";":"";u+=(this.marginRight!=null)?"margin-right:"+this.marginRight+";":"";this._elem=a('<table class="jqplot-table-legend" style="'+u+'"></table>');if(this.seriesToggle){this._elem.css("z-index","3")}var d=false,o=false,q,l;if(this.numberRows){q=this.numberRows;if(!this.numberColumns){l=Math.ceil(m.length/q)}else{l=this.numberColumns}}else{if(this.numberColumns){l=this.numberColumns;q=Math.ceil(m.length/this.numberColumns)}else{q=m.length;l=1}}var n,k,p,e,c,h,g;var r=0;for(n=m.length-1;n>=0;n--){if(m[n]._stack||m[n].renderer.constructor==a.jqplot.BezierCurveRenderer){o=true}}for(n=0;n<q;n++){if(o){p=a('<tr class="jqplot-table-legend"></tr>').prependTo(this._elem)}else{p=a('<tr class="jqplot-table-legend"></tr>').appendTo(this._elem)}for(k=0;k<l;k++){if(r<m.length&&m[r].show&&m[r].showLabel){s=m[r];h=this.labels[r]||s.label.toString();if(h){var f=s.color;if(!o){if(n>0){d=true}else{d=false}}else{if(n==q-1){d=false}else{d=true}}g=(d)?this.rowSpacing:"0";e=a('<td class="jqplot-table-legend" style="text-align:center;padding-top:'+g+';"><div><div class="jqplot-table-legend-swatch" style="background-color:'+f+";border-color:"+f+';"></div></div></td>');c=a('<td class="jqplot-table-legend" style="padding-top:'+g+';"></td>');if(this.escapeHtml){c.text(h)}else{c.html(h)}if(o){if(this.showLabels){c.prependTo(p)}if(this.showSwatches){e.prependTo(p)}}else{if(this.showSwatches){e.appendTo(p)}if(this.showLabels){c.appendTo(p)}}if(this.seriesToggle){var b;if(typeof(this.seriesToggle)=="string"||typeof(this.seriesToggle)=="number"){if(!a.browser.msie||!this.disableIEFading){b=this.seriesToggle}}if(this.showSwatches){e.bind("click",{series:s,speed:b},s.toggleDisplay);e.addClass("jqplot-seriesToggle")}if(this.showLabels){c.bind("click",{series:s,speed:b},s.toggleDisplay);c.addClass("jqplot-seriesToggle")}}d=true}}r++}}}return this._elem};postDraw=function(){if(this.legend.renderer.constructor==a.jqplot.EnhancedLegendRenderer&&this.legend.seriesToggle){var b=this.legend._elem.detach();this.eventCanvas._elem.after(b)}}})(jQuery);
@@ -0,0 +1,918 @@
1
+ /**
2
+ * Copyright (c) 2009 - 2010 Chris Leonello
3
+ * jqPlot is currently available for use in all personal or commercial projects
4
+ * under both the MIT and GPL version 2.0 licenses. This means that you can
5
+ * choose the license that best suits your project and use it accordingly.
6
+ *
7
+ * The author would appreciate an email letting him know of any substantial
8
+ * use of jqPlot. You can reach the author at: chris at jqplot dot com
9
+ * or see http://www.jqplot.com/info.php . This is, of course,
10
+ * not required.
11
+ *
12
+ * If you are feeling kind and generous, consider supporting the project by
13
+ * making a donation at: http://www.jqplot.com/donate.php .
14
+ *
15
+ * Thanks for using jqPlot!
16
+ *
17
+ */
18
+ (function($) {
19
+ /**
20
+ * Class: $.jqplot.FunnelRenderer
21
+ * Plugin renderer to draw a funnel chart.
22
+ * x values, if present, will be used as labels.
23
+ * y values give area size.
24
+ *
25
+ * Funnel charts will draw a single series
26
+ * only.
27
+ *
28
+ * To use this renderer, you need to include the
29
+ * funnel renderer plugin, for example:
30
+ *
31
+ * > <script type="text/javascript" src="plugins/jqplot.funnelRenderer.js"></script>
32
+ *
33
+ * Properties described here are passed into the $.jqplot function
34
+ * as options on the series renderer. For example:
35
+ *
36
+ * > plot2 = $.jqplot('chart2', [s1, s2], {
37
+ * > seriesDefaults: {
38
+ * > renderer:$.jqplot.FunnelRenderer,
39
+ * > rendererOptions:{
40
+ * > sectionMargin: 12,
41
+ * > widthRatio: 0.3
42
+ * > }
43
+ * > }
44
+ * > });
45
+ *
46
+ * IMPORTANT
47
+ *
48
+ * *The funnel renderer will reorder data in descending order* so the largest value in
49
+ * the data set is first and displayed on top of the funnel. Data will then
50
+ * be displayed in descending order down the funnel. The area of each funnel
51
+ * section will correspond to the value of each data point relative to the sum
52
+ * of all values. That is section area is proportional to section value divided by
53
+ * sum of all section values.
54
+ *
55
+ * If your data is not in descending order when passed into the plot, *it will be
56
+ * reordered* when stored in the series.data property. A copy of the unordered
57
+ * data is kept in the series._unorderedData property.
58
+ *
59
+ * A funnel plot will trigger events on the plot target
60
+ * according to user interaction. All events return the event object,
61
+ * the series index, the point (section) index, and the point data for
62
+ * the appropriate section. *Note* the point index will referr to the ordered
63
+ * data, not the original unordered data.
64
+ *
65
+ * 'jqplotDataMouseOver' - triggered when mousing over a section.
66
+ * 'jqplotDataHighlight' - triggered the first time user mouses over a section,
67
+ * if highlighting is enabled.
68
+ * 'jqplotDataUnhighlight' - triggered when a user moves the mouse out of
69
+ * a highlighted section.
70
+ * 'jqplotDataClick' - triggered when the user clicks on a section.
71
+ * 'jqplotDataRightClick' - tiggered when the user right clicks on a section if
72
+ * the "captureRightClick" option is set to true on the plot.
73
+ */
74
+ $.jqplot.FunnelRenderer = function(){
75
+ $.jqplot.LineRenderer.call(this);
76
+ };
77
+
78
+ $.jqplot.FunnelRenderer.prototype = new $.jqplot.LineRenderer();
79
+ $.jqplot.FunnelRenderer.prototype.constructor = $.jqplot.FunnelRenderer;
80
+
81
+ // called with scope of a series
82
+ $.jqplot.FunnelRenderer.prototype.init = function(options, plot) {
83
+ // Group: Properties
84
+ //
85
+ // prop: padding
86
+ // padding between the funnel and plot edges, legend, etc.
87
+ this.padding = {top: 20, right: 20, bottom: 20, left: 20};
88
+ // prop: sectionMargin
89
+ // spacing between funnel sections in pixels.
90
+ this.sectionMargin = 6;
91
+ // prop: fill
92
+ // true or false, wether to fill the areas.
93
+ this.fill = true;
94
+ // prop: shadowOffset
95
+ // offset of the shadow from the area and offset of
96
+ // each succesive stroke of the shadow from the last.
97
+ this.shadowOffset = 2;
98
+ // prop: shadowAlpha
99
+ // transparency of the shadow (0 = transparent, 1 = opaque)
100
+ this.shadowAlpha = 0.07;
101
+ // prop: shadowDepth
102
+ // number of strokes to apply to the shadow,
103
+ // each stroke offset shadowOffset from the last.
104
+ this.shadowDepth = 5;
105
+ // prop: highlightMouseOver
106
+ // True to highlight area when moused over.
107
+ // This must be false to enable highlightMouseDown to highlight when clicking on a area.
108
+ this.highlightMouseOver = true;
109
+ // prop: highlightMouseDown
110
+ // True to highlight when a mouse button is pressed over a area.
111
+ // This will be disabled if highlightMouseOver is true.
112
+ this.highlightMouseDown = false;
113
+ // prop: highlightColors
114
+ // array of colors to use when highlighting an area.
115
+ this.highlightColors = [];
116
+ // prop: widthRatio
117
+ // The ratio of the width of the top of the funnel to the bottom.
118
+ // a ratio of 0 will make an upside down pyramid.
119
+ this.widthRatio = 0.2;
120
+ // prop: lineWidth
121
+ // width of line if areas are stroked and not filled.
122
+ this.lineWidth = 2;
123
+ // prop: dataLabels
124
+ // Either 'label', 'value', 'percent' or an array of labels to place on the pie slices.
125
+ // Defaults to percentage of each pie slice.
126
+ this.dataLabels = 'percent';
127
+ // prop: showDataLabels
128
+ // true to show data labels on slices.
129
+ this.showDataLabels = false;
130
+ // prop: dataLabelFormatString
131
+ // Format string for data labels. If none, '%s' is used for "label" and for arrays, '%d' for value and '%d%%' for percentage.
132
+ this.dataLabelFormatString = null;
133
+ // prop: dataLabelThreshold
134
+ // Threshhold in percentage (0 - 100) of pie area, below which no label will be displayed.
135
+ // This applies to all label types, not just to percentage labels.
136
+ this.dataLabelThreshold = 3;
137
+
138
+ this.tickRenderer = $.jqplot.FunnelTickRenderer;
139
+
140
+ // if user has passed in highlightMouseDown option and not set highlightMouseOver, disable highlightMouseOver
141
+ if (options.highlightMouseDown && options.highlightMouseOver == null) {
142
+ options.highlightMouseOver = false;
143
+ }
144
+
145
+ $.extend(true, this, options);
146
+
147
+ // index of the currenty highlighted point, if any
148
+ this._highlightedPoint = null;
149
+
150
+ // lengths of bases, or horizontal sides of areas of trapezoid.
151
+ this._bases = [];
152
+ // total area
153
+ this._atot;
154
+ // areas of segments.
155
+ this._areas = [];
156
+ // vertical lengths of segments.
157
+ this._lengths = [];
158
+ // angle of the funnel to vertical.
159
+ this._angle;
160
+ this._dataIndices = [];
161
+
162
+ // sort data
163
+ this._unorderedData = $.extend(true, [], this.data);
164
+ var idxs = $.extend(true, [], this.data);
165
+ for (var i=0; i<idxs.length; i++) {
166
+ idxs[i].push(i);
167
+ }
168
+ this.data.sort( function (a, b) { return b[1] - a[1]; } );
169
+ idxs.sort( function (a, b) { return b[1] - a[1]; });
170
+ for (var i=0; i<idxs.length; i++) {
171
+ this._dataIndices.push(idxs[i][2]);
172
+ }
173
+
174
+ // set highlight colors if none provided
175
+ if (this.highlightColors.length == 0) {
176
+ for (var i=0; i<this.seriesColors.length; i++){
177
+ var rgba = $.jqplot.getColorComponents(this.seriesColors[i]);
178
+ var newrgb = [rgba[0], rgba[1], rgba[2]];
179
+ var sum = newrgb[0] + newrgb[1] + newrgb[2];
180
+ for (var j=0; j<3; j++) {
181
+ // when darkening, lowest color component can be is 60.
182
+ newrgb[j] = (sum > 570) ? newrgb[j] * 0.8 : newrgb[j] + 0.4 * (255 - newrgb[j]);
183
+ newrgb[j] = parseInt(newrgb[j], 10);
184
+ }
185
+ this.highlightColors.push('rgb('+newrgb[0]+','+newrgb[1]+','+newrgb[2]+')');
186
+ }
187
+ }
188
+
189
+ plot.postParseOptionsHooks.addOnce(postParseOptions);
190
+ plot.postInitHooks.addOnce(postInit);
191
+ plot.eventListenerHooks.addOnce('jqplotMouseMove', handleMove);
192
+ plot.eventListenerHooks.addOnce('jqplotMouseDown', handleMouseDown);
193
+ plot.eventListenerHooks.addOnce('jqplotMouseUp', handleMouseUp);
194
+ plot.eventListenerHooks.addOnce('jqplotClick', handleClick);
195
+ plot.eventListenerHooks.addOnce('jqplotRightClick', handleRightClick);
196
+ plot.postDrawHooks.addOnce(postPlotDraw);
197
+
198
+ };
199
+
200
+ // gridData will be of form [label, percentage of total]
201
+ $.jqplot.FunnelRenderer.prototype.setGridData = function(plot) {
202
+ // set gridData property. This will hold angle in radians of each data point.
203
+ var sum = 0;
204
+ var td = [];
205
+ for (var i=0; i<this.data.length; i++){
206
+ sum += this.data[i][1];
207
+ td.push([this.data[i][0], this.data[i][1]]);
208
+ }
209
+
210
+ // normalize y values, so areas are proportional.
211
+ for (var i=0; i<td.length; i++) {
212
+ td[i][1] = td[i][1]/sum;
213
+ }
214
+
215
+ this._bases = new Array(td.length + 1);
216
+ this._lengths = new Array(td.length);
217
+
218
+ this.gridData = td;
219
+ };
220
+
221
+ $.jqplot.FunnelRenderer.prototype.makeGridData = function(data, plot) {
222
+ // set gridData property. This will hold angle in radians of each data point.
223
+ var sum = 0;
224
+ var td = [];
225
+ for (var i=0; i<this.data.length; i++){
226
+ sum += this.data[i][1];
227
+ td.push([this.data[i][0], this.data[i][1]]);
228
+ }
229
+
230
+ // normalize y values, so areas are proportional.
231
+ for (var i=0; i<td.length; i++) {
232
+ td[i][1] = td[i][1]/sum;
233
+ }
234
+
235
+ this._bases = new Array(td.length + 1);
236
+ this._lengths = new Array(td.length);
237
+
238
+ return td;
239
+ };
240
+
241
+ $.jqplot.FunnelRenderer.prototype.drawSection = function (ctx, vertices, color, isShadow) {
242
+ var fill = this.fill;
243
+ var lineWidth = this.lineWidth;
244
+ ctx.save();
245
+
246
+ if (isShadow) {
247
+ for (var i=0; i<this.shadowDepth; i++) {
248
+ ctx.save();
249
+ ctx.translate(this.shadowOffset*Math.cos(this.shadowAngle/180*Math.PI), this.shadowOffset*Math.sin(this.shadowAngle/180*Math.PI));
250
+ doDraw();
251
+ }
252
+ }
253
+
254
+ else {
255
+ doDraw();
256
+ }
257
+
258
+ function doDraw () {
259
+ ctx.beginPath();
260
+ ctx.fillStyle = color;
261
+ ctx.strokeStyle = color;
262
+ ctx.lineWidth = lineWidth;
263
+ ctx.moveTo(vertices[0][0], vertices[0][1]);
264
+ for (var i=1; i<4; i++) {
265
+ ctx.lineTo(vertices[i][0], vertices[i][1]);
266
+ }
267
+ ctx.closePath();
268
+ if (fill) {
269
+ ctx.fill();
270
+ }
271
+ else {
272
+ ctx.stroke();
273
+ }
274
+ }
275
+
276
+ if (isShadow) {
277
+ for (var i=0; i<this.shadowDepth; i++) {
278
+ ctx.restore();
279
+ }
280
+ }
281
+
282
+ ctx.restore();
283
+ };
284
+
285
+ // called with scope of series
286
+ $.jqplot.FunnelRenderer.prototype.draw = function (ctx, gd, options, plot) {
287
+ var i;
288
+ var opts = (options != undefined) ? options : {};
289
+ // offset and direction of offset due to legend placement
290
+ var offx = 0;
291
+ var offy = 0;
292
+ var trans = 1;
293
+ this._areas = [];
294
+ // var colorGenerator = new this.colorGenerator(this.seriesColors);
295
+ if (options.legendInfo && options.legendInfo.placement == 'insideGrid') {
296
+ var li = options.legendInfo;
297
+ switch (li.location) {
298
+ case 'nw':
299
+ offx = li.width + li.xoffset;
300
+ break;
301
+ case 'w':
302
+ offx = li.width + li.xoffset;
303
+ break;
304
+ case 'sw':
305
+ offx = li.width + li.xoffset;
306
+ break;
307
+ case 'ne':
308
+ offx = li.width + li.xoffset;
309
+ trans = -1;
310
+ break;
311
+ case 'e':
312
+ offx = li.width + li.xoffset;
313
+ trans = -1;
314
+ break;
315
+ case 'se':
316
+ offx = li.width + li.xoffset;
317
+ trans = -1;
318
+ break;
319
+ case 'n':
320
+ offy = li.height + li.yoffset;
321
+ break;
322
+ case 's':
323
+ offy = li.height + li.yoffset;
324
+ trans = -1;
325
+ break;
326
+ default:
327
+ break;
328
+ }
329
+ }
330
+
331
+ var loff = (trans==1) ? this.padding.left + offx : this.padding.left;
332
+ var toff = (trans==1) ? this.padding.top + offy : this.padding.top;
333
+ var roff = (trans==-1) ? this.padding.right + offx : this.padding.right;
334
+ var boff = (trans==-1) ? this.padding.bottom + offy : this.padding.bottom;
335
+
336
+ var shadow = (opts.shadow != undefined) ? opts.shadow : this.shadow;
337
+ var showLine = (opts.showLine != undefined) ? opts.showLine : this.showLine;
338
+ var fill = (opts.fill != undefined) ? opts.fill : this.fill;
339
+ var cw = ctx.canvas.width;
340
+ var ch = ctx.canvas.height;
341
+ this._bases[0] = cw - loff - roff;
342
+ var ltot = this._length = ch - toff - boff;
343
+
344
+ var hend = this._bases[0]*this.widthRatio;
345
+ this._atot = ltot/2 * (this._bases[0] + this._bases[0]*this.widthRatio);
346
+
347
+ this._angle = Math.atan((this._bases[0] - hend)/2/ltot);
348
+
349
+ for (i=0; i<gd.length; i++) {
350
+ this._areas.push(gd[i][1] * this._atot);
351
+ }
352
+
353
+
354
+ var guess, err, count, lsum=0;
355
+ var tolerance = 0.0001;
356
+
357
+ for (i=0; i<this._areas.length; i++) {
358
+ guess = this._areas[i]/this._bases[i];
359
+ err = 999999;
360
+ this._lengths[i] = guess;
361
+ count = 0;
362
+ while (err > this._lengths[i]*tolerance && count < 100) {
363
+ this._lengths[i] = this._areas[i]/(this._bases[i] - this._lengths[i] * Math.tan(this._angle));
364
+ err = Math.abs(this._lengths[i] - guess);
365
+ this._bases[i+1] = this._bases[i] - (2*this._lengths[i]*Math.tan(this._angle));
366
+ guess = this._lengths[i];
367
+ count++;
368
+ }
369
+ lsum += this._lengths[i];
370
+ }
371
+
372
+ // figure out vertices of each section
373
+ this._vertices = new Array(gd.length);
374
+
375
+ // these are 4 coners of entire trapezoid
376
+ var p0 = [loff, toff],
377
+ p1 = [loff+this._bases[0], toff],
378
+ p2 = [loff + (this._bases[0] - this._bases[this._bases.length-1])/2, toff + this._length],
379
+ p3 = [p2[0] + this._bases[this._bases.length-1], p2[1]];
380
+
381
+ // equations of right and left sides, returns x, y values given height of section (y value)
382
+ function findleft (l) {
383
+ var m = (p0[1] - p2[1])/(p0[0] - p2[0]);
384
+ var b = p0[1] - m*p0[0];
385
+ var y = l + p0[1];
386
+
387
+ return [(y - b)/m, y];
388
+ }
389
+
390
+ function findright (l) {
391
+ var m = (p1[1] - p3[1])/(p1[0] - p3[0]);
392
+ var b = p1[1] - m*p1[0];
393
+ var y = l + p1[1];
394
+
395
+ return [(y - b)/m, y];
396
+ }
397
+
398
+ var x = offx, y = offy;
399
+ var h=0, adj=0;
400
+
401
+ for (i=0; i<gd.length; i++) {
402
+ this._vertices[i] = new Array();
403
+ var v = this._vertices[i];
404
+ var sm = this.sectionMargin;
405
+ if (i == 0) {
406
+ adj = 0;
407
+ }
408
+ if (i == 1) {
409
+ adj = sm/3;
410
+ }
411
+ else if (i > 0 && i < gd.length-1) {
412
+ adj = sm/2;
413
+ }
414
+ else if (i == gd.length -1) {
415
+ adj = 2*sm/3;
416
+ }
417
+ v.push(findleft(h+adj));
418
+ v.push(findright(h+adj));
419
+ h += this._lengths[i];
420
+ if (i == 0) {
421
+ adj = -2*sm/3;
422
+ }
423
+ else if (i > 0 && i < gd.length-1) {
424
+ adj = -sm/2;
425
+ }
426
+ else if (i == gd.length - 1) {
427
+ adj = 0;
428
+ }
429
+ v.push(findright(h+adj));
430
+ v.push(findleft(h+adj));
431
+
432
+ }
433
+
434
+ if (this.shadow) {
435
+ var shadowColor = 'rgba(0,0,0,'+this.shadowAlpha+')';
436
+ for (var i=0; i<gd.length; i++) {
437
+ this.renderer.drawSection.call (this, ctx, this._vertices[i], shadowColor, true);
438
+ }
439
+
440
+ }
441
+ for (var i=0; i<gd.length; i++) {
442
+ var v = this._vertices[i];
443
+ this.renderer.drawSection.call (this, ctx, v, this.seriesColors[i]);
444
+
445
+ if (this.showDataLabels && gd[i][1]*100 >= this.dataLabelThreshold) {
446
+ var fstr, label;
447
+
448
+ if (this.dataLabels == 'label') {
449
+ fstr = this.dataLabelFormatString || '%s';
450
+ label = $.jqplot.sprintf(fstr, gd[i][0]);
451
+ }
452
+ else if (this.dataLabels == 'value') {
453
+ fstr = this.dataLabelFormatString || '%d';
454
+ label = $.jqplot.sprintf(fstr, this.data[i][1]);
455
+ }
456
+ else if (this.dataLabels == 'percent') {
457
+ fstr = this.dataLabelFormatString || '%d%%';
458
+ label = $.jqplot.sprintf(fstr, gd[i][1]*100);
459
+ }
460
+ else if (this.dataLabels.constructor == Array) {
461
+ fstr = this.dataLabelFormatString || '%s';
462
+ label = $.jqplot.sprintf(fstr, this.dataLabels[this._dataIndices[i]]);
463
+ }
464
+
465
+ var fact = (this._radius ) * this.dataLabelPositionFactor + this.sliceMargin + this.dataLabelNudge;
466
+
467
+ var x = (v[0][0] + v[1][0])/2 + this.canvas._offsets.left;
468
+ var y = (v[1][1] + v[2][1])/2 + this.canvas._offsets.top;
469
+
470
+ var labelelem = $('<span class="jqplot-funnel-series jqplot-data-label" style="position:absolute;">' + label + '</span>').insertBefore(plot.eventCanvas._elem);
471
+ x -= labelelem.width()/2;
472
+ y -= labelelem.height()/2;
473
+ x = Math.round(x);
474
+ y = Math.round(y);
475
+ labelelem.css({left: x, top: y});
476
+ }
477
+
478
+ }
479
+
480
+ };
481
+
482
+ $.jqplot.FunnelAxisRenderer = function() {
483
+ $.jqplot.LinearAxisRenderer.call(this);
484
+ };
485
+
486
+ $.jqplot.FunnelAxisRenderer.prototype = new $.jqplot.LinearAxisRenderer();
487
+ $.jqplot.FunnelAxisRenderer.prototype.constructor = $.jqplot.FunnelAxisRenderer;
488
+
489
+
490
+ // There are no traditional axes on a funnel chart. We just need to provide
491
+ // dummy objects with properties so the plot will render.
492
+ // called with scope of axis object.
493
+ $.jqplot.FunnelAxisRenderer.prototype.init = function(options){
494
+ //
495
+ this.tickRenderer = $.jqplot.FunnelTickRenderer;
496
+ $.extend(true, this, options);
497
+ // I don't think I'm going to need _dataBounds here.
498
+ // have to go Axis scaling in a way to fit chart onto plot area
499
+ // and provide u2p and p2u functionality for mouse cursor, etc.
500
+ // for convienence set _dataBounds to 0 and 100 and
501
+ // set min/max to 0 and 100.
502
+ this._dataBounds = {min:0, max:100};
503
+ this.min = 0;
504
+ this.max = 100;
505
+ this.showTicks = false;
506
+ this.ticks = [];
507
+ this.showMark = false;
508
+ this.show = false;
509
+ };
510
+
511
+
512
+
513
+ /**
514
+ * Class: $.jqplot.FunnelLegendRenderer
515
+ * Legend Renderer specific to funnel plots. Set by default
516
+ * when the user creates a funnel plot.
517
+ */
518
+ $.jqplot.FunnelLegendRenderer = function(){
519
+ $.jqplot.TableLegendRenderer.call(this);
520
+ };
521
+
522
+ $.jqplot.FunnelLegendRenderer.prototype = new $.jqplot.TableLegendRenderer();
523
+ $.jqplot.FunnelLegendRenderer.prototype.constructor = $.jqplot.FunnelLegendRenderer;
524
+
525
+ $.jqplot.FunnelLegendRenderer.prototype.init = function(options) {
526
+ // Group: Properties
527
+ //
528
+ // prop: numberRows
529
+ // Maximum number of rows in the legend. 0 or null for unlimited.
530
+ this.numberRows = null;
531
+ // prop: numberColumns
532
+ // Maximum number of columns in the legend. 0 or null for unlimited.
533
+ this.numberColumns = null;
534
+ $.extend(true, this, options);
535
+ };
536
+
537
+ // called with context of legend
538
+ $.jqplot.FunnelLegendRenderer.prototype.draw = function() {
539
+ var legend = this;
540
+ if (this.show) {
541
+ var series = this._series;
542
+ var ss = 'position:absolute;';
543
+ ss += (this.background) ? 'background:'+this.background+';' : '';
544
+ ss += (this.border) ? 'border:'+this.border+';' : '';
545
+ ss += (this.fontSize) ? 'font-size:'+this.fontSize+';' : '';
546
+ ss += (this.fontFamily) ? 'font-family:'+this.fontFamily+';' : '';
547
+ ss += (this.textColor) ? 'color:'+this.textColor+';' : '';
548
+ ss += (this.marginTop != null) ? 'margin-top:'+this.marginTop+';' : '';
549
+ ss += (this.marginBottom != null) ? 'margin-bottom:'+this.marginBottom+';' : '';
550
+ ss += (this.marginLeft != null) ? 'margin-left:'+this.marginLeft+';' : '';
551
+ ss += (this.marginRight != null) ? 'margin-right:'+this.marginRight+';' : '';
552
+ this._elem = $('<table class="jqplot-table-legend" style="'+ss+'"></table>');
553
+ // Funnel charts legends don't go by number of series, but by number of data points
554
+ // in the series. Refactor things here for that.
555
+
556
+ var pad = false,
557
+ reverse = false,
558
+ nr, nc;
559
+ var s = series[0];
560
+ var colorGenerator = new $.jqplot.ColorGenerator(s.seriesColors);
561
+
562
+ if (s.show) {
563
+ var pd = s.data;
564
+ if (this.numberRows) {
565
+ nr = this.numberRows;
566
+ if (!this.numberColumns){
567
+ nc = Math.ceil(pd.length/nr);
568
+ }
569
+ else{
570
+ nc = this.numberColumns;
571
+ }
572
+ }
573
+ else if (this.numberColumns) {
574
+ nc = this.numberColumns;
575
+ nr = Math.ceil(pd.length/this.numberColumns);
576
+ }
577
+ else {
578
+ nr = pd.length;
579
+ nc = 1;
580
+ }
581
+
582
+ var i, j, tr, td1, td2, lt, rs, color;
583
+ var idx = 0;
584
+
585
+ for (i=0; i<nr; i++) {
586
+ if (reverse){
587
+ tr = $('<tr class="jqplot-table-legend"></tr>').prependTo(this._elem);
588
+ }
589
+ else{
590
+ tr = $('<tr class="jqplot-table-legend"></tr>').appendTo(this._elem);
591
+ }
592
+ for (j=0; j<nc; j++) {
593
+ if (idx < pd.length){
594
+ lt = this.labels[idx] || pd[idx][0].toString();
595
+ color = colorGenerator.next();
596
+ if (!reverse){
597
+ if (i>0){
598
+ pad = true;
599
+ }
600
+ else{
601
+ pad = false;
602
+ }
603
+ }
604
+ else{
605
+ if (i == nr -1){
606
+ pad = false;
607
+ }
608
+ else{
609
+ pad = true;
610
+ }
611
+ }
612
+ rs = (pad) ? this.rowSpacing : '0';
613
+
614
+ td1 = $('<td class="jqplot-table-legend" style="text-align:center;padding-top:'+rs+';">'+
615
+ '<div><div class="jqplot-table-legend-swatch" style="border-color:'+color+';"></div>'+
616
+ '</div></td>');
617
+ td2 = $('<td class="jqplot-table-legend" style="padding-top:'+rs+';"></td>');
618
+ if (this.escapeHtml){
619
+ td2.text(lt);
620
+ }
621
+ else {
622
+ td2.html(lt);
623
+ }
624
+ if (reverse) {
625
+ td2.prependTo(tr);
626
+ td1.prependTo(tr);
627
+ }
628
+ else {
629
+ td1.appendTo(tr);
630
+ td2.appendTo(tr);
631
+ }
632
+ pad = true;
633
+ }
634
+ idx++;
635
+ }
636
+ }
637
+ }
638
+ }
639
+ return this._elem;
640
+ };
641
+
642
+ // $.jqplot.FunnelLegendRenderer.prototype.pack = function(offsets) {
643
+ // if (this.show) {
644
+ // // fake a grid for positioning
645
+ // var grid = {_top:offsets.top, _left:offsets.left, _right:offsets.right, _bottom:this._plotDimensions.height - offsets.bottom};
646
+ // if (this.placement == 'insideGrid') {
647
+ // switch (this.location) {
648
+ // case 'nw':
649
+ // var a = grid._left + this.xoffset;
650
+ // var b = grid._top + this.yoffset;
651
+ // this._elem.css('left', a);
652
+ // this._elem.css('top', b);
653
+ // break;
654
+ // case 'n':
655
+ // var a = (offsets.left + (this._plotDimensions.width - offsets.right))/2 - this.getWidth()/2;
656
+ // var b = grid._top + this.yoffset;
657
+ // this._elem.css('left', a);
658
+ // this._elem.css('top', b);
659
+ // break;
660
+ // case 'ne':
661
+ // var a = offsets.right + this.xoffset;
662
+ // var b = grid._top + this.yoffset;
663
+ // this._elem.css({right:a, top:b});
664
+ // break;
665
+ // case 'e':
666
+ // var a = offsets.right + this.xoffset;
667
+ // var b = (offsets.top + (this._plotDimensions.height - offsets.bottom))/2 - this.getHeight()/2;
668
+ // this._elem.css({right:a, top:b});
669
+ // break;
670
+ // case 'se':
671
+ // var a = offsets.right + this.xoffset;
672
+ // var b = offsets.bottom + this.yoffset;
673
+ // this._elem.css({right:a, bottom:b});
674
+ // break;
675
+ // case 's':
676
+ // var a = (offsets.left + (this._plotDimensions.width - offsets.right))/2 - this.getWidth()/2;
677
+ // var b = offsets.bottom + this.yoffset;
678
+ // this._elem.css({left:a, bottom:b});
679
+ // break;
680
+ // case 'sw':
681
+ // var a = grid._left + this.xoffset;
682
+ // var b = offsets.bottom + this.yoffset;
683
+ // this._elem.css({left:a, bottom:b});
684
+ // break;
685
+ // case 'w':
686
+ // var a = grid._left + this.xoffset;
687
+ // var b = (offsets.top + (this._plotDimensions.height - offsets.bottom))/2 - this.getHeight()/2;
688
+ // this._elem.css({left:a, top:b});
689
+ // break;
690
+ // default: // same as 'se'
691
+ // var a = grid._right - this.xoffset;
692
+ // var b = grid._bottom + this.yoffset;
693
+ // this._elem.css({right:a, bottom:b});
694
+ // break;
695
+ // }
696
+ //
697
+ // }
698
+ // else {
699
+ // switch (this.location) {
700
+ // case 'nw':
701
+ // var a = this._plotDimensions.width - grid._left + this.xoffset;
702
+ // var b = grid._top + this.yoffset;
703
+ // this._elem.css('right', a);
704
+ // this._elem.css('top', b);
705
+ // break;
706
+ // case 'n':
707
+ // var a = (offsets.left + (this._plotDimensions.width - offsets.right))/2 - this.getWidth()/2;
708
+ // var b = this._plotDimensions.height - grid._top + this.yoffset;
709
+ // this._elem.css('left', a);
710
+ // this._elem.css('bottom', b);
711
+ // break;
712
+ // case 'ne':
713
+ // var a = this._plotDimensions.width - offsets.right + this.xoffset;
714
+ // var b = grid._top + this.yoffset;
715
+ // this._elem.css({left:a, top:b});
716
+ // break;
717
+ // case 'e':
718
+ // var a = this._plotDimensions.width - offsets.right + this.xoffset;
719
+ // var b = (offsets.top + (this._plotDimensions.height - offsets.bottom))/2 - this.getHeight()/2;
720
+ // this._elem.css({left:a, top:b});
721
+ // break;
722
+ // case 'se':
723
+ // var a = this._plotDimensions.width - offsets.right + this.xoffset;
724
+ // var b = offsets.bottom + this.yoffset;
725
+ // this._elem.css({left:a, bottom:b});
726
+ // break;
727
+ // case 's':
728
+ // var a = (offsets.left + (this._plotDimensions.width - offsets.right))/2 - this.getWidth()/2;
729
+ // var b = this._plotDimensions.height - offsets.bottom + this.yoffset;
730
+ // this._elem.css({left:a, top:b});
731
+ // break;
732
+ // case 'sw':
733
+ // var a = this._plotDimensions.width - grid._left + this.xoffset;
734
+ // var b = offsets.bottom + this.yoffset;
735
+ // this._elem.css({right:a, bottom:b});
736
+ // break;
737
+ // case 'w':
738
+ // var a = this._plotDimensions.width - grid._left + this.xoffset;
739
+ // var b = (offsets.top + (this._plotDimensions.height - offsets.bottom))/2 - this.getHeight()/2;
740
+ // this._elem.css({right:a, top:b});
741
+ // break;
742
+ // default: // same as 'se'
743
+ // var a = grid._right - this.xoffset;
744
+ // var b = grid._bottom + this.yoffset;
745
+ // this._elem.css({right:a, bottom:b});
746
+ // break;
747
+ // }
748
+ // }
749
+ // }
750
+ // };
751
+
752
+ // setup default renderers for axes and legend so user doesn't have to
753
+ // called with scope of plot
754
+ function preInit(target, data, options) {
755
+ options = options || {};
756
+ options.axesDefaults = options.axesDefaults || {};
757
+ options.legend = options.legend || {};
758
+ options.seriesDefaults = options.seriesDefaults || {};
759
+ // only set these if there is a funnel series
760
+ var setopts = false;
761
+ if (options.seriesDefaults.renderer == $.jqplot.FunnelRenderer) {
762
+ setopts = true;
763
+ }
764
+ else if (options.series) {
765
+ for (var i=0; i < options.series.length; i++) {
766
+ if (options.series[i].renderer == $.jqplot.FunnelRenderer) {
767
+ setopts = true;
768
+ }
769
+ }
770
+ }
771
+
772
+ if (setopts) {
773
+ options.axesDefaults.renderer = $.jqplot.FunnelAxisRenderer;
774
+ options.legend.renderer = $.jqplot.FunnelLegendRenderer;
775
+ options.legend.preDraw = true;
776
+ options.sortData = false;
777
+ }
778
+ }
779
+
780
+ function postInit(target, data, options) {
781
+ // if multiple series, add a reference to the previous one so that
782
+ // funnel rings can nest.
783
+ for (i=0; i<this.series.length; i++) {
784
+ if (this.series[i].renderer.constructor == $.jqplot.FunnelRenderer) {
785
+ // don't allow mouseover and mousedown at same time.
786
+ if (this.series[i].highlightMouseOver) {
787
+ this.series[i].highlightMouseDown = false;
788
+ }
789
+ }
790
+ }
791
+ this.target.bind('mouseout', {plot:this}, function (ev) { unhighlight(ev.data.plot); });
792
+ }
793
+
794
+ // called with scope of plot
795
+ function postParseOptions(options) {
796
+ for (var i=0; i<this.series.length; i++) {
797
+ this.series[i].seriesColors = this.seriesColors;
798
+ this.series[i].colorGenerator = this.colorGenerator;
799
+ }
800
+ }
801
+
802
+ function highlight (plot, sidx, pidx) {
803
+ var s = plot.series[sidx];
804
+ var canvas = plot.plugins.funnelRenderer.highlightCanvas;
805
+ canvas._ctx.clearRect(0,0,canvas._ctx.canvas.width, canvas._ctx.canvas.height);
806
+ s._highlightedPoint = pidx;
807
+ plot.plugins.funnelRenderer.highlightedSeriesIndex = sidx;
808
+ s.renderer.drawSection.call(s, canvas._ctx, s._vertices[pidx], s.highlightColors[pidx], false);
809
+ }
810
+
811
+ function unhighlight (plot) {
812
+ var canvas = plot.plugins.funnelRenderer.highlightCanvas;
813
+ canvas._ctx.clearRect(0,0, canvas._ctx.canvas.width, canvas._ctx.canvas.height);
814
+ for (var i=0; i<plot.series.length; i++) {
815
+ plot.series[i]._highlightedPoint = null;
816
+ }
817
+ plot.plugins.funnelRenderer.highlightedSeriesIndex = null;
818
+ plot.target.trigger('jqplotDataUnhighlight');
819
+ }
820
+
821
+ function handleMove(ev, gridpos, datapos, neighbor, plot) {
822
+ if (neighbor) {
823
+ var ins = [neighbor.seriesIndex, neighbor.pointIndex, neighbor.data];
824
+ var evt1 = jQuery.Event('jqplotDataMouseOver');
825
+ evt1.pageX = ev.pageX;
826
+ evt1.pageY = ev.pageY;
827
+ plot.target.trigger(evt1, ins);
828
+ if (plot.series[ins[0]].highlightMouseOver && !(ins[0] == plot.plugins.funnelRenderer.highlightedSeriesIndex && ins[1] == plot.series[ins[0]]._highlightedPoint)) {
829
+ var evt = jQuery.Event('jqplotDataHighlight');
830
+ evt.pageX = ev.pageX;
831
+ evt.pageY = ev.pageY;
832
+ plot.target.trigger(evt, ins);
833
+ highlight (plot, ins[0], ins[1]);
834
+ }
835
+ }
836
+ else if (neighbor == null) {
837
+ unhighlight (plot);
838
+ }
839
+ }
840
+
841
+ function handleMouseDown(ev, gridpos, datapos, neighbor, plot) {
842
+ if (neighbor) {
843
+ var ins = [neighbor.seriesIndex, neighbor.pointIndex, neighbor.data];
844
+ if (plot.series[ins[0]].highlightMouseDown && !(ins[0] == plot.plugins.funnelRenderer.highlightedSeriesIndex && ins[1] == plot.series[ins[0]]._highlightedPoint)) {
845
+ var evt = jQuery.Event('jqplotDataHighlight');
846
+ evt.pageX = ev.pageX;
847
+ evt.pageY = ev.pageY;
848
+ plot.target.trigger(evt, ins);
849
+ highlight (plot, ins[0], ins[1]);
850
+ }
851
+ }
852
+ else if (neighbor == null) {
853
+ unhighlight (plot);
854
+ }
855
+ }
856
+
857
+ function handleMouseUp(ev, gridpos, datapos, neighbor, plot) {
858
+ var idx = plot.plugins.funnelRenderer.highlightedSeriesIndex;
859
+ if (idx != null && plot.series[idx].highlightMouseDown) {
860
+ unhighlight(plot);
861
+ }
862
+ }
863
+
864
+ function handleClick(ev, gridpos, datapos, neighbor, plot) {
865
+ if (neighbor) {
866
+ var ins = [neighbor.seriesIndex, neighbor.pointIndex, neighbor.data];
867
+ var evt = jQuery.Event('jqplotDataClick');
868
+ evt.pageX = ev.pageX;
869
+ evt.pageY = ev.pageY;
870
+ plot.target.trigger(evt, ins);
871
+ }
872
+ }
873
+
874
+ function handleRightClick(ev, gridpos, datapos, neighbor, plot) {
875
+ if (neighbor) {
876
+ var ins = [neighbor.seriesIndex, neighbor.pointIndex, neighbor.data];
877
+ var idx = plot.plugins.funnelRenderer.highlightedSeriesIndex;
878
+ if (idx != null && plot.series[idx].highlightMouseDown) {
879
+ unhighlight(plot);
880
+ }
881
+ var evt = jQuery.Event('jqplotDataRightClick');
882
+ evt.pageX = ev.pageX;
883
+ evt.pageY = ev.pageY;
884
+ plot.target.trigger(evt, ins);
885
+ }
886
+ }
887
+
888
+ // called within context of plot
889
+ // create a canvas which we can draw on.
890
+ // insert it before the eventCanvas, so eventCanvas will still capture events.
891
+ function postPlotDraw() {
892
+ this.plugins.funnelRenderer = {};
893
+ this.plugins.funnelRenderer.highlightCanvas = new $.jqplot.GenericCanvas();
894
+
895
+ // do we have any data labels? if so, put highlight canvas before those
896
+ var labels = $(this.targetId+' .jqplot-data-label');
897
+ if (labels.length) {
898
+ $(labels[0]).before(this.plugins.funnelRenderer.highlightCanvas.createElement(this._gridPadding, 'jqplot-funnelRenderer-highlight-canvas', this._plotDimensions));
899
+ }
900
+ // else put highlight canvas before event canvas.
901
+ else {
902
+ this.eventCanvas._elem.before(this.plugins.funnelRenderer.highlightCanvas.createElement(this._gridPadding, 'jqplot-funnelRenderer-highlight-canvas', this._plotDimensions));
903
+ }
904
+ var hctx = this.plugins.funnelRenderer.highlightCanvas.setContext();
905
+ }
906
+
907
+ $.jqplot.preInitHooks.push(preInit);
908
+
909
+ $.jqplot.FunnelTickRenderer = function() {
910
+ $.jqplot.AxisTickRenderer.call(this);
911
+ };
912
+
913
+ $.jqplot.FunnelTickRenderer.prototype = new $.jqplot.AxisTickRenderer();
914
+ $.jqplot.FunnelTickRenderer.prototype.constructor = $.jqplot.FunnelTickRenderer;
915
+
916
+ })(jQuery);
917
+
918
+