ziya 2.0.7 → 2.1.6
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.
- data/Manifest.txt +561 -89
- data/README.txt +203 -108
- data/Rakefile +7 -6
- data/bin/ziyafy +38 -14
- data/docs/History.txt.html +50 -0
- data/docs/README.txt.html +403 -0
- data/docs/String.html +832 -0
- data/docs/Ziya.html +636 -0
- data/docs/Ziya/Charts.html +909 -0
- data/docs/Ziya/Charts/Area.html +672 -0
- data/docs/Ziya/Charts/AreaThreed.html +672 -0
- data/docs/Ziya/Charts/Bar.html +672 -0
- data/docs/Ziya/Charts/Base.html +1101 -0
- data/docs/Ziya/Charts/Bubble.html +672 -0
- data/docs/Ziya/Charts/CandleStick.html +672 -0
- data/docs/Ziya/Charts/Column.html +672 -0
- data/docs/Ziya/Charts/ColumnThreed.html +672 -0
- data/docs/Ziya/Charts/Custom.html +672 -0
- data/docs/Ziya/Charts/Donut.html +672 -0
- data/docs/Ziya/Charts/FloatingBar.html +672 -0
- data/docs/Ziya/Charts/FloatingColumn.html +672 -0
- data/docs/Ziya/Charts/ImageColumn.html +672 -0
- data/docs/Ziya/Charts/ImagePie.html +672 -0
- data/docs/Ziya/Charts/Line.html +672 -0
- data/docs/Ziya/Charts/Mixed.html +672 -0
- data/docs/Ziya/Charts/ParallelThreedColumn.html +672 -0
- data/docs/Ziya/Charts/Pie.html +672 -0
- data/docs/Ziya/Charts/PieThreed.html +672 -0
- data/docs/Ziya/Charts/Polar.html +672 -0
- data/docs/Ziya/Charts/Scatter.html +672 -0
- data/docs/Ziya/Charts/StackedArea.html +672 -0
- data/docs/Ziya/Charts/StackedBar.html +672 -0
- data/docs/Ziya/Charts/StackedColumn.html +672 -0
- data/docs/Ziya/Charts/StackedThreedArea.html +672 -0
- data/docs/Ziya/Charts/StackedThreedColumn.html +672 -0
- data/docs/Ziya/Charts/Support.html +1245 -0
- data/docs/Ziya/Charts/Support/Area.html +582 -0
- data/docs/Ziya/Charts/Support/AxisCategory.html +583 -0
- data/docs/Ziya/Charts/Support/AxisTicks.html +644 -0
- data/docs/Ziya/Charts/Support/AxisValue.html +583 -0
- data/docs/Ziya/Charts/Support/Base.html +577 -0
- data/docs/Ziya/Charts/Support/Bevel.html +583 -0
- data/docs/Ziya/Charts/Support/Blur.html +583 -0
- data/docs/Ziya/Charts/Support/Button.html +583 -0
- data/docs/Ziya/Charts/Support/ChartBorder.html +582 -0
- data/docs/Ziya/Charts/Support/ChartGridH.html +616 -0
- data/docs/Ziya/Charts/Support/ChartGridV.html +616 -0
- data/docs/Ziya/Charts/Support/ChartGuide.html +582 -0
- data/docs/Ziya/Charts/Support/ChartLabel.html +583 -0
- data/docs/Ziya/Charts/Support/ChartNote.html +582 -0
- data/docs/Ziya/Charts/Support/ChartPref.html +589 -0
- data/docs/Ziya/Charts/Support/ChartRect.html +632 -0
- data/docs/Ziya/Charts/Support/ChartTransition.html +613 -0
- data/docs/Ziya/Charts/Support/Circle.html +583 -0
- data/docs/Ziya/Charts/Support/ContextMenu.html +583 -0
- data/docs/Ziya/Charts/Support/Draw.html +886 -0
- data/docs/Ziya/Charts/Support/DrawBase.html +577 -0
- data/docs/Ziya/Charts/Support/Filter.html +668 -0
- data/docs/Ziya/Charts/Support/FlashToJavascript.html +596 -0
- data/docs/Ziya/Charts/Support/Glow.html +583 -0
- data/docs/Ziya/Charts/Support/Image.html +583 -0
- data/docs/Ziya/Charts/Support/Legend.html +582 -0
- data/docs/Ziya/Charts/Support/Line.html +583 -0
- data/docs/Ziya/Charts/Support/Link.html +734 -0
- data/docs/Ziya/Charts/Support/LinkData.html +589 -0
- data/docs/Ziya/Charts/Support/Rect.html +583 -0
- data/docs/Ziya/Charts/Support/Scroll.html +583 -0
- data/docs/Ziya/Charts/Support/Series.html +583 -0
- data/docs/Ziya/Charts/Support/SeriesColor.html +676 -0
- data/docs/Ziya/Charts/Support/SeriesExplode.html +676 -0
- data/docs/Ziya/Charts/Support/Shadow.html +583 -0
- data/docs/Ziya/Charts/Support/Text.html +664 -0
- data/docs/Ziya/Charts/Support/Tooltip.html +583 -0
- data/docs/Ziya/Charts/Support/Update.html +590 -0
- data/docs/Ziya/Gauges.html +644 -0
- data/docs/Ziya/Gauges/Base.html +1052 -0
- data/docs/Ziya/Gauges/Radial.html +654 -0
- data/docs/Ziya/Gauges/Signal.html +794 -0
- data/docs/Ziya/Gauges/Support.html +726 -0
- data/docs/Ziya/Gauges/Support/Area.html +577 -0
- data/docs/Ziya/Gauges/Support/Base.html +690 -0
- data/docs/Ziya/Gauges/Support/Circle.html +577 -0
- data/docs/Ziya/Gauges/Support/Design.html +577 -0
- data/docs/Ziya/Gauges/Support/Image.html +577 -0
- data/docs/Ziya/Gauges/Support/Line.html +577 -0
- data/docs/Ziya/Gauges/Support/Link.html +577 -0
- data/docs/Ziya/Gauges/Support/Move.html +577 -0
- data/docs/Ziya/Gauges/Support/Point.html +577 -0
- data/docs/Ziya/Gauges/Support/Polygon.html +577 -0
- data/docs/Ziya/Gauges/Support/RadialBase.html +654 -0
- data/docs/Ziya/Gauges/Support/RadialNumbers.html +694 -0
- data/docs/Ziya/Gauges/Support/RadialTicks.html +676 -0
- data/docs/Ziya/Gauges/Support/Rect.html +577 -0
- data/docs/Ziya/Gauges/Support/Rotate.html +577 -0
- data/docs/Ziya/Gauges/Support/Scale.html +577 -0
- data/docs/Ziya/Gauges/Support/Text.html +656 -0
- data/docs/Ziya/Gauges/Support/Update.html +577 -0
- data/docs/Ziya/Gauges/Thermo.html +826 -0
- data/docs/Ziya/HtmlHelpers.html +597 -0
- data/docs/Ziya/HtmlHelpers/Charts.html +1399 -0
- data/docs/Ziya/HtmlHelpers/Gauges.html +987 -0
- data/docs/Ziya/HtmlHelpers/Maps.html +950 -0
- data/docs/Ziya/Maps.html +713 -0
- data/docs/Ziya/Maps/Australia.html +648 -0
- data/docs/Ziya/Maps/Base.html +1099 -0
- data/docs/Ziya/Maps/Belgium.html +648 -0
- data/docs/Ziya/Maps/Brazil.html +648 -0
- data/docs/Ziya/Maps/Canada.html +648 -0
- data/docs/Ziya/Maps/Europe.html +648 -0
- data/docs/Ziya/Maps/France.html +648 -0
- data/docs/Ziya/Maps/Geocode.html +752 -0
- data/docs/Ziya/Maps/Germany.html +648 -0
- data/docs/Ziya/Maps/Italy.html +648 -0
- data/docs/Ziya/Maps/Mexico.html +648 -0
- data/docs/Ziya/Maps/Support.html +798 -0
- data/docs/Ziya/Maps/Support/Arc.html +577 -0
- data/docs/Ziya/Maps/Support/ArcColor.html +577 -0
- data/docs/Ziya/Maps/Support/ArcRange.html +577 -0
- data/docs/Ziya/Maps/Support/BackgroundColor.html +577 -0
- data/docs/Ziya/Maps/Support/Base.html +792 -0
- data/docs/Ziya/Maps/Support/DefaultColor.html +577 -0
- data/docs/Ziya/Maps/Support/DefaultPoint.html +577 -0
- data/docs/Ziya/Maps/Support/FirstZoom.html +577 -0
- data/docs/Ziya/Maps/Support/HeatRange.html +658 -0
- data/docs/Ziya/Maps/Support/Hover.html +577 -0
- data/docs/Ziya/Maps/Support/Line.html +577 -0
- data/docs/Ziya/Maps/Support/LineColor.html +577 -0
- data/docs/Ziya/Maps/Support/LineRange.html +577 -0
- data/docs/Ziya/Maps/Support/OutlineColor.html +577 -0
- data/docs/Ziya/Maps/Support/Point.html +577 -0
- data/docs/Ziya/Maps/Support/PointRange.html +577 -0
- data/docs/Ziya/Maps/Support/Range.html +753 -0
- data/docs/Ziya/Maps/Support/Ranges.html +658 -0
- data/docs/Ziya/Maps/Support/Region.html +577 -0
- data/docs/Ziya/Maps/Support/ScalePoints.html +577 -0
- data/docs/Ziya/Maps/Support/ShowName.html +577 -0
- data/docs/Ziya/Maps/Support/State.html +577 -0
- data/docs/Ziya/Maps/Support/StateInfoIcon.html +577 -0
- data/docs/Ziya/Maps/Support/ZoomMode.html +577 -0
- data/docs/Ziya/Maps/Support/ZoomOutButton.html +577 -0
- data/docs/Ziya/Maps/Support/ZoomOutScale.html +577 -0
- data/docs/Ziya/Maps/Sweden.html +648 -0
- data/docs/Ziya/Maps/Uk.html +648 -0
- data/docs/Ziya/Maps/Us.html +648 -0
- data/docs/Ziya/Maps/World.html +648 -0
- data/docs/Ziya/YamlHelpers.html +592 -0
- data/docs/Ziya/YamlHelpers/Gauges.html +848 -0
- data/docs/Ziya/YamlHelpers/Maps.html +750 -0
- data/docs/Ziya/Ziyafy.html +735 -0
- data/docs/bin/ziyafy.html +52 -0
- data/docs/created.rid +1 -0
- data/docs/examples/charts/public/charts/themes/readme.txt.html +61 -0
- data/docs/examples/maps/public/maps/themes/readme.txt.html +61 -0
- data/docs/images/brick.png +0 -0
- data/docs/images/brick_link.png +0 -0
- data/docs/images/bullet_black.png +0 -0
- data/docs/images/date.png +0 -0
- data/docs/images/macFFBgHack.png +0 -0
- data/docs/images/package.png +0 -0
- data/docs/images/page_green.png +0 -0
- data/docs/images/page_white_width.png +0 -0
- data/docs/images/plugin.png +0 -0
- data/docs/images/ruby.png +0 -0
- data/docs/images/tag_green.png +0 -0
- data/docs/images/wrench.png +0 -0
- data/docs/images/wrench_orange.png +0 -0
- data/docs/images/zoom.png +0 -0
- data/docs/index.html +978 -0
- data/docs/js/darkfish.js +91 -0
- data/docs/js/jquery.js +32 -0
- data/docs/js/quicksearch.js +135 -0
- data/docs/js/thickbox-compressed.js +10 -0
- data/docs/lib/ziya.rb.html +43 -0
- data/docs/lib/ziya/charts/area.rb.html +54 -0
- data/docs/lib/ziya/charts/area_threed.rb.html +153 -0
- data/docs/lib/ziya/charts/bar.rb.html +45 -0
- data/docs/lib/ziya/charts/base.rb.html +71 -0
- data/docs/lib/ziya/charts/bubble.rb.html +54 -0
- data/docs/lib/ziya/charts/candle_stick.rb.html +45 -0
- data/docs/lib/ziya/charts/column.rb.html +45 -0
- data/docs/lib/ziya/charts/column_threed.rb.html +45 -0
- data/docs/lib/ziya/charts/custom.rb.html +54 -0
- data/docs/lib/ziya/charts/donut.rb.html +54 -0
- data/docs/lib/ziya/charts/floating_bar.rb.html +45 -0
- data/docs/lib/ziya/charts/floating_column.rb.html +45 -0
- data/docs/lib/ziya/charts/image_column.rb.html +54 -0
- data/docs/lib/ziya/charts/image_pie.rb.html +54 -0
- data/docs/lib/ziya/charts/line.rb.html +45 -0
- data/docs/lib/ziya/charts/mixed.rb.html +45 -0
- data/docs/lib/ziya/charts/parallel_threed_column.rb.html +45 -0
- data/docs/lib/ziya/charts/pie.rb.html +45 -0
- data/docs/lib/ziya/charts/pie_threed.rb.html +45 -0
- data/docs/lib/ziya/charts/polar.rb.html +45 -0
- data/docs/lib/ziya/charts/scatter.rb.html +45 -0
- data/docs/lib/ziya/charts/stacked_area.rb.html +45 -0
- data/docs/lib/ziya/charts/stacked_bar.rb.html +45 -0
- data/docs/lib/ziya/charts/stacked_column.rb.html +45 -0
- data/docs/lib/ziya/charts/stacked_threed_area.rb.html +45 -0
- data/docs/lib/ziya/charts/stacked_threed_column.rb.html +45 -0
- data/docs/lib/ziya/charts/support/area.rb.html +56 -0
- data/docs/lib/ziya/charts/support/axis_category.rb.html +407 -0
- data/docs/lib/ziya/charts/support/axis_ticks.rb.html +48 -0
- data/docs/lib/ziya/charts/support/axis_value.rb.html +48 -0
- data/docs/lib/ziya/charts/support/base.rb.html +64 -0
- data/docs/lib/ziya/charts/support/bevel.rb.html +48 -0
- data/docs/lib/ziya/charts/support/blur.rb.html +48 -0
- data/docs/lib/ziya/charts/support/button.rb.html +48 -0
- data/docs/lib/ziya/charts/support/chart_border.rb.html +48 -0
- data/docs/lib/ziya/charts/support/chart_grid_h.rb.html +48 -0
- data/docs/lib/ziya/charts/support/chart_grid_v.rb.html +48 -0
- data/docs/lib/ziya/charts/support/chart_guide.rb.html +48 -0
- data/docs/lib/ziya/charts/support/chart_label.rb.html +49 -0
- data/docs/lib/ziya/charts/support/chart_note.rb.html +53 -0
- data/docs/lib/ziya/charts/support/chart_pref.rb.html +48 -0
- data/docs/lib/ziya/charts/support/chart_rect.rb.html +48 -0
- data/docs/lib/ziya/charts/support/chart_transition.rb.html +48 -0
- data/docs/lib/ziya/charts/support/circle.rb.html +48 -0
- data/docs/lib/ziya/charts/support/context_menu.rb.html +47 -0
- data/docs/lib/ziya/charts/support/draw.rb.html +57 -0
- data/docs/lib/ziya/charts/support/draw_base.rb.html +48 -0
- data/docs/lib/ziya/charts/support/filter.rb.html +52 -0
- data/docs/lib/ziya/charts/support/flash_to_javascript.rb.html +48 -0
- data/docs/lib/ziya/charts/support/glow.rb.html +48 -0
- data/docs/lib/ziya/charts/support/image.rb.html +52 -0
- data/docs/lib/ziya/charts/support/legend.rb.html +48 -0
- data/docs/lib/ziya/charts/support/line.rb.html +48 -0
- data/docs/lib/ziya/charts/support/link.rb.html +48 -0
- data/docs/lib/ziya/charts/support/link_data.rb.html +48 -0
- data/docs/lib/ziya/charts/support/rect.rb.html +48 -0
- data/docs/lib/ziya/charts/support/scroll.rb.html +50 -0
- data/docs/lib/ziya/charts/support/series.rb.html +47 -0
- data/docs/lib/ziya/charts/support/series_color.rb.html +62 -0
- data/docs/lib/ziya/charts/support/series_explode.rb.html +65 -0
- data/docs/lib/ziya/charts/support/shadow.rb.html +48 -0
- data/docs/lib/ziya/charts/support/text.rb.html +51 -0
- data/docs/lib/ziya/charts/support/tooltip.rb.html +53 -0
- data/docs/lib/ziya/charts/support/update.rb.html +49 -0
- data/docs/lib/ziya/core_ext/string.rb.html +50 -0
- data/docs/lib/ziya/gauges/base.rb.html +54 -0
- data/docs/lib/ziya/gauges/radial.rb.html +64 -0
- data/docs/lib/ziya/gauges/signal.rb.html +49 -0
- data/docs/lib/ziya/gauges/support/area.rb.html +57 -0
- data/docs/lib/ziya/gauges/support/base.rb.html +39 -0
- data/docs/lib/ziya/gauges/support/circle.rb.html +57 -0
- data/docs/lib/ziya/gauges/support/design.rb.html +39 -0
- data/docs/lib/ziya/gauges/support/image.rb.html +57 -0
- data/docs/lib/ziya/gauges/support/line.rb.html +57 -0
- data/docs/lib/ziya/gauges/support/link.rb.html +57 -0
- data/docs/lib/ziya/gauges/support/move.rb.html +57 -0
- data/docs/lib/ziya/gauges/support/point.rb.html +57 -0
- data/docs/lib/ziya/gauges/support/polygon.rb.html +57 -0
- data/docs/lib/ziya/gauges/support/radial_base.rb.html +58 -0
- data/docs/lib/ziya/gauges/support/radial_numbers.rb.html +60 -0
- data/docs/lib/ziya/gauges/support/radial_ticks.rb.html +57 -0
- data/docs/lib/ziya/gauges/support/rect.rb.html +57 -0
- data/docs/lib/ziya/gauges/support/rotate.rb.html +57 -0
- data/docs/lib/ziya/gauges/support/scale.rb.html +57 -0
- data/docs/lib/ziya/gauges/support/text.rb.html +57 -0
- data/docs/lib/ziya/gauges/support/update.rb.html +57 -0
- data/docs/lib/ziya/gauges/thermo.rb.html +48 -0
- data/docs/lib/ziya/html_helpers.rb.html +39 -0
- data/docs/lib/ziya/html_helpers/base.rb.html +48 -0
- data/docs/lib/ziya/html_helpers/charts.rb.html +48 -0
- data/docs/lib/ziya/html_helpers/gauges.rb.html +48 -0
- data/docs/lib/ziya/html_helpers/maps.rb.html +39 -0
- data/docs/lib/ziya/maps/australia.rb.html +48 -0
- data/docs/lib/ziya/maps/base.rb.html +62 -0
- data/docs/lib/ziya/maps/belgium.rb.html +39 -0
- data/docs/lib/ziya/maps/brazil.rb.html +39 -0
- data/docs/lib/ziya/maps/canada.rb.html +39 -0
- data/docs/lib/ziya/maps/europe.rb.html +39 -0
- data/docs/lib/ziya/maps/france.rb.html +39 -0
- data/docs/lib/ziya/maps/geocode.rb.html +45 -0
- data/docs/lib/ziya/maps/germany.rb.html +39 -0
- data/docs/lib/ziya/maps/italy.rb.html +39 -0
- data/docs/lib/ziya/maps/mexico.rb.html +39 -0
- data/docs/lib/ziya/maps/support/arc.rb.html +48 -0
- data/docs/lib/ziya/maps/support/arc_color.rb.html +48 -0
- data/docs/lib/ziya/maps/support/arc_range.rb.html +48 -0
- data/docs/lib/ziya/maps/support/background_color.rb.html +48 -0
- data/docs/lib/ziya/maps/support/base.rb.html +48 -0
- data/docs/lib/ziya/maps/support/default_color.rb.html +48 -0
- data/docs/lib/ziya/maps/support/default_point.rb.html +48 -0
- data/docs/lib/ziya/maps/support/first_zoom.rb.html +48 -0
- data/docs/lib/ziya/maps/support/heat_range.rb.html +50 -0
- data/docs/lib/ziya/maps/support/hover.rb.html +48 -0
- data/docs/lib/ziya/maps/support/line.rb.html +48 -0
- data/docs/lib/ziya/maps/support/line_color.rb.html +48 -0
- data/docs/lib/ziya/maps/support/line_range.rb.html +48 -0
- data/docs/lib/ziya/maps/support/outline_color.rb.html +48 -0
- data/docs/lib/ziya/maps/support/point.rb.html +48 -0
- data/docs/lib/ziya/maps/support/point_range.rb.html +48 -0
- data/docs/lib/ziya/maps/support/range.rb.html +48 -0
- data/docs/lib/ziya/maps/support/ranges.rb.html +47 -0
- data/docs/lib/ziya/maps/support/region.rb.html +48 -0
- data/docs/lib/ziya/maps/support/scale_points.rb.html +48 -0
- data/docs/lib/ziya/maps/support/show_name.rb.html +48 -0
- data/docs/lib/ziya/maps/support/state.rb.html +48 -0
- data/docs/lib/ziya/maps/support/state_info_icon.rb.html +48 -0
- data/docs/lib/ziya/maps/support/zoom_mode.rb.html +48 -0
- data/docs/lib/ziya/maps/support/zoom_out_button.rb.html +48 -0
- data/docs/lib/ziya/maps/support/zoom_out_scale.rb.html +48 -0
- data/docs/lib/ziya/maps/sweden.rb.html +39 -0
- data/docs/lib/ziya/maps/uk.rb.html +39 -0
- data/docs/lib/ziya/maps/us.rb.html +39 -0
- data/docs/lib/ziya/maps/world.rb.html +39 -0
- data/docs/lib/ziya/utils/logger.rb.html +53 -0
- data/docs/lib/ziya/version.rb.html +39 -0
- data/docs/lib/ziya/yaml_helpers.rb.html +39 -0
- data/docs/lib/ziya/yaml_helpers/base.rb.html +48 -0
- data/docs/lib/ziya/yaml_helpers/charts.rb.html +50 -0
- data/docs/lib/ziya/yaml_helpers/gauges.rb.html +39 -0
- data/docs/lib/ziya/yaml_helpers/maps.rb.html +39 -0
- data/docs/rdoc.css +664 -0
- data/docs/release_notes.txt.html +51 -0
- data/docs/resources/charts/themes/readme.txt.html +61 -0
- data/docs/resources/maps/themes/readme.txt.html +61 -0
- data/examples/charts/basic_chart.rb +55 -0
- data/{charts → examples/charts/public/charts}/AC_RunActiveContent.js +0 -0
- data/examples/charts/public/charts/charts.swf +0 -0
- data/examples/charts/public/charts/charts_library/ar3d.swf +0 -0
- data/examples/charts/public/charts/charts_library/arno.swf +0 -0
- data/examples/charts/public/charts/charts_library/ars3.swf +0 -0
- data/examples/charts/public/charts/charts_library/arst.swf +0 -0
- data/examples/charts/public/charts/charts_library/brfl.swf +0 -0
- data/examples/charts/public/charts/charts_library/brno.swf +0 -0
- data/examples/charts/public/charts/charts_library/brst.swf +0 -0
- data/examples/charts/public/charts/charts_library/buno.swf +0 -0
- data/examples/charts/public/charts/charts_library/cl3d.swf +0 -0
- data/examples/charts/public/charts/charts_library/clfl.swf +0 -0
- data/examples/charts/public/charts/charts_library/clim.swf +0 -0
- data/examples/charts/public/charts/charts_library/clno.swf +0 -0
- data/examples/charts/public/charts/charts_library/clp3.swf +0 -0
- data/examples/charts/public/charts/charts_library/cls3.swf +0 -0
- data/examples/charts/public/charts/charts_library/clst.swf +0 -0
- data/examples/charts/public/charts/charts_library/cnno.swf +0 -0
- data/{charts → examples/charts/public/charts}/charts_library/dollar.jpg +0 -0
- data/examples/charts/public/charts/charts_library/dono.swf +0 -0
- data/examples/charts/public/charts/charts_library/lnno.swf +0 -0
- data/examples/charts/public/charts/charts_library/mxno.swf +0 -0
- data/examples/charts/public/charts/charts_library/pi3d.swf +0 -0
- data/{charts → examples/charts/public/charts}/charts_library/pie.jpg +0 -0
- data/examples/charts/public/charts/charts_library/piim.swf +0 -0
- data/examples/charts/public/charts/charts_library/pino.swf +0 -0
- data/examples/charts/public/charts/charts_library/pono.swf +0 -0
- data/examples/charts/public/charts/charts_library/scno.swf +0 -0
- data/examples/charts/public/charts/full_screen.fla +0 -0
- data/{charts → examples/charts/public/charts}/full_screen.swf +0 -0
- data/{charts → examples/charts/public/charts}/scripts/output_jpg.php +0 -0
- data/{charts → examples/charts/public/charts}/sliders/black.swf +0 -0
- data/{charts → examples/charts/public/charts}/sliders/preview_handle_1.swf +0 -0
- data/{charts → examples/charts/public/charts}/sliders/preview_handle_2.swf +0 -0
- data/examples/charts/public/charts/themes/cool_theme/column_chart.yml +150 -0
- data/examples/charts/public/charts/themes/cool_theme/line_chart.yml +5 -0
- data/examples/charts/public/charts/themes/readme.txt +13 -0
- data/examples/charts/public/fred.xml +21 -0
- data/examples/charts/views/index.erb +17 -0
- data/examples/maps/basic_map.rb +63 -0
- data/examples/maps/helpers/map_helper.rb +15 -0
- data/examples/maps/models/confidential_herpes_report.rb +78 -0
- data/examples/maps/public/javascripts/jquery-1.3.2.js +4376 -0
- data/examples/maps/public/map.xml +336 -0
- data/examples/maps/public/maps/js/Exception.js +45 -0
- data/examples/maps/public/maps/js/FlashProxy.js +72 -0
- data/examples/maps/public/maps/js/FlashSerializer.js +165 -0
- data/examples/maps/public/maps/js/FlashTag.js +111 -0
- data/examples/maps/public/maps/js/JavaScriptFlashGateway.js +455 -0
- data/examples/maps/public/maps/js/JavaScriptFlashGateway.swf +0 -0
- data/examples/maps/public/maps/map_library/australia.swf +0 -0
- data/examples/maps/public/maps/map_library/belgium.swf +0 -0
- data/examples/maps/public/maps/map_library/brazil.swf +0 -0
- data/examples/maps/public/maps/map_library/canada.swf +0 -0
- data/examples/maps/public/maps/map_library/europe.swf +0 -0
- data/examples/maps/public/maps/map_library/france.swf +0 -0
- data/examples/maps/public/maps/map_library/germany.swf +0 -0
- data/examples/maps/public/maps/map_library/italy.swf +0 -0
- data/examples/maps/public/maps/map_library/mexico.swf +0 -0
- data/examples/maps/public/maps/map_library/sweden.swf +0 -0
- data/examples/maps/public/maps/map_library/uk_ireland.swf +0 -0
- data/examples/maps/public/maps/map_library/us.swf +0 -0
- data/examples/maps/public/maps/map_library/us_canada.swf +0 -0
- data/examples/maps/public/maps/map_library/world.swf +0 -0
- data/examples/maps/public/maps/themes/default/base_map.yml +27 -0
- data/examples/maps/public/maps/themes/default/us_map.yml +20 -0
- data/examples/maps/public/maps/themes/default/us_map_2.yml +17 -0
- data/examples/maps/public/maps/themes/readme.txt +13 -0
- data/examples/maps/public/stylesheets/map.css +16 -0
- data/examples/maps/views/index.erb +26 -0
- data/examples/maps/views/layout.erb +21 -0
- data/gem_script.rb +5 -0
- data/lib/ziya.rb +20 -11
- data/lib/ziya/charts/base.rb +114 -90
- data/lib/ziya/{components → charts/support}/area.rb +2 -2
- data/lib/ziya/{components → charts/support}/axis_category.rb +1 -1
- data/lib/ziya/{components → charts/support}/axis_ticks.rb +1 -1
- data/lib/ziya/{components → charts/support}/axis_value.rb +1 -1
- data/lib/ziya/{components → charts/support}/base.rb +9 -21
- data/lib/ziya/{components → charts/support}/bevel.rb +1 -1
- data/lib/ziya/{components → charts/support}/blur.rb +1 -1
- data/lib/ziya/{components → charts/support}/button.rb +1 -1
- data/lib/ziya/{components → charts/support}/chart_border.rb +1 -1
- data/lib/ziya/{components → charts/support}/chart_grid_h.rb +1 -1
- data/lib/ziya/{components → charts/support}/chart_grid_v.rb +1 -1
- data/lib/ziya/{components → charts/support}/chart_guide.rb +1 -1
- data/lib/ziya/{components → charts/support}/chart_label.rb +1 -1
- data/lib/ziya/{components → charts/support}/chart_note.rb +1 -1
- data/lib/ziya/{components → charts/support}/chart_pref.rb +3 -2
- data/lib/ziya/{components → charts/support}/chart_rect.rb +1 -1
- data/lib/ziya/{components → charts/support}/chart_transition.rb +1 -1
- data/lib/ziya/{components → charts/support}/circle.rb +1 -1
- data/lib/ziya/{components → charts/support}/context_menu.rb +1 -3
- data/lib/ziya/charts/support/draw.rb +76 -0
- data/lib/ziya/{components → charts/support}/draw_base.rb +1 -1
- data/lib/ziya/{components → charts/support}/filter.rb +1 -1
- data/lib/ziya/charts/support/flash_to_javascript.rb +23 -0
- data/lib/ziya/{components → charts/support}/glow.rb +1 -1
- data/lib/ziya/{components → charts/support}/image.rb +1 -1
- data/lib/ziya/{components → charts/support}/legend.rb +1 -1
- data/lib/ziya/{components → charts/support}/line.rb +1 -1
- data/lib/ziya/{components → charts/support}/link.rb +9 -1
- data/lib/ziya/{components → charts/support}/link_data.rb +1 -1
- data/lib/ziya/{components → charts/support}/rect.rb +1 -1
- data/lib/ziya/{components → charts/support}/scroll.rb +1 -3
- data/lib/ziya/{components → charts/support}/series.rb +1 -3
- data/lib/ziya/{components → charts/support}/series_color.rb +1 -1
- data/lib/ziya/{components → charts/support}/series_explode.rb +1 -1
- data/lib/ziya/{components → charts/support}/shadow.rb +1 -1
- data/lib/ziya/{components → charts/support}/text.rb +9 -1
- data/lib/ziya/{components → charts/support}/tooltip.rb +1 -1
- data/lib/ziya/{components → charts/support}/update.rb +1 -1
- data/lib/ziya/core_ext/string.rb +31 -0
- data/lib/ziya/gauges/base.rb +17 -12
- data/lib/ziya/gauges/support/base.rb +4 -12
- data/lib/ziya/gauges/support/radial_numbers.rb +1 -1
- data/lib/ziya/html_helpers.rb +1 -0
- data/lib/ziya/html_helpers/base.rb +91 -0
- data/lib/ziya/html_helpers/charts.rb +200 -0
- data/lib/ziya/html_helpers/gauges.rb +90 -0
- data/lib/ziya/html_helpers/maps.rb +74 -0
- data/lib/ziya/maps/australia.rb +9 -0
- data/lib/ziya/maps/base.rb +409 -0
- data/lib/ziya/maps/belgium.rb +7 -0
- data/lib/ziya/maps/brazil.rb +7 -0
- data/lib/ziya/maps/canada.rb +7 -0
- data/lib/ziya/maps/europe.rb +7 -0
- data/lib/ziya/maps/france.rb +7 -0
- data/lib/ziya/maps/geocode.rb +18 -0
- data/lib/ziya/maps/germany.rb +7 -0
- data/lib/ziya/maps/italy.rb +7 -0
- data/lib/ziya/maps/mexico.rb +7 -0
- data/lib/ziya/maps/support/arc.rb +7 -0
- data/lib/ziya/maps/support/arc_color.rb +7 -0
- data/lib/ziya/maps/support/arc_range.rb +7 -0
- data/lib/ziya/maps/support/background_color.rb +7 -0
- data/lib/ziya/maps/support/base.rb +34 -0
- data/lib/ziya/maps/support/default_color.rb +7 -0
- data/lib/ziya/maps/support/default_point.rb +7 -0
- data/lib/ziya/maps/support/first_zoom.rb +7 -0
- data/lib/ziya/maps/support/heat_range.rb +35 -0
- data/lib/ziya/maps/support/hover.rb +7 -0
- data/lib/ziya/maps/support/line.rb +7 -0
- data/lib/ziya/maps/support/line_color.rb +7 -0
- data/lib/ziya/maps/support/line_range.rb +7 -0
- data/lib/ziya/maps/support/outline_color.rb +7 -0
- data/lib/ziya/maps/support/point.rb +8 -0
- data/lib/ziya/maps/support/point_range.rb +7 -0
- data/lib/ziya/maps/support/range.rb +31 -0
- data/lib/ziya/maps/support/ranges.rb +18 -0
- data/lib/ziya/maps/support/region.rb +7 -0
- data/lib/ziya/maps/support/scale_points.rb +7 -0
- data/lib/ziya/maps/support/show_name.rb +7 -0
- data/lib/ziya/maps/support/state.rb +7 -0
- data/lib/ziya/maps/support/state_info_icon.rb +7 -0
- data/lib/ziya/maps/support/zoom_mode.rb +7 -0
- data/lib/ziya/maps/support/zoom_out_button.rb +7 -0
- data/lib/ziya/maps/support/zoom_out_scale.rb +7 -0
- data/lib/ziya/maps/sweden.rb +7 -0
- data/lib/ziya/maps/uk.rb +7 -0
- data/lib/ziya/maps/us.rb +7 -0
- data/lib/ziya/maps/world.rb +7 -0
- data/lib/ziya/version.rb +3 -3
- data/lib/ziya/yaml_helpers.rb +1 -0
- data/lib/ziya/yaml_helpers/base.rb +20 -0
- data/lib/ziya/yaml_helpers/charts.rb +49 -0
- data/lib/ziya/yaml_helpers/gauges.rb +33 -0
- data/lib/ziya/yaml_helpers/maps.rb +17 -0
- data/resources/charts/AC_RunActiveContent.js +292 -0
- data/resources/charts/charts.swf +0 -0
- data/resources/charts/charts_library/ar3d.swf +0 -0
- data/resources/charts/charts_library/arno.swf +0 -0
- data/resources/charts/charts_library/ars3.swf +0 -0
- data/resources/charts/charts_library/arst.swf +0 -0
- data/resources/charts/charts_library/brfl.swf +0 -0
- data/resources/charts/charts_library/brno.swf +0 -0
- data/resources/charts/charts_library/brst.swf +0 -0
- data/resources/charts/charts_library/buno.swf +0 -0
- data/resources/charts/charts_library/cl3d.swf +0 -0
- data/resources/charts/charts_library/clfl.swf +0 -0
- data/resources/charts/charts_library/clim.swf +0 -0
- data/resources/charts/charts_library/clno.swf +0 -0
- data/resources/charts/charts_library/clp3.swf +0 -0
- data/resources/charts/charts_library/cls3.swf +0 -0
- data/resources/charts/charts_library/clst.swf +0 -0
- data/resources/charts/charts_library/cnno.swf +0 -0
- data/resources/charts/charts_library/dono.swf +0 -0
- data/resources/charts/charts_library/lnno.swf +0 -0
- data/resources/charts/charts_library/mxno.swf +0 -0
- data/resources/charts/charts_library/pi3d.swf +0 -0
- data/resources/charts/charts_library/piim.swf +0 -0
- data/resources/charts/charts_library/pino.swf +0 -0
- data/resources/charts/charts_library/pono.swf +0 -0
- data/resources/charts/charts_library/scno.swf +0 -0
- data/resources/charts/full_screen.fla +0 -0
- data/resources/charts/full_screen.swf +0 -0
- data/resources/charts/scripts/output_jpg.php +23 -0
- data/resources/charts/sliders/black.swf +0 -0
- data/resources/charts/sliders/preview_handle_1.swf +0 -0
- data/resources/charts/sliders/preview_handle_2.swf +0 -0
- data/resources/charts/themes/readme.txt +13 -0
- data/{gauges → resources/gauges}/designs/circle.yml +0 -0
- data/{gauges → resources/gauges}/designs/signal.yml +0 -0
- data/{gauges → resources/gauges}/designs/thermo.yml +0 -0
- data/{gauges → resources/gauges}/designs/title.yml +0 -0
- data/{gauges → resources/gauges}/gauge.swf +0 -0
- data/resources/maps/js/Exception.js +45 -0
- data/resources/maps/js/FlashProxy.js +72 -0
- data/resources/maps/js/FlashSerializer.js +165 -0
- data/resources/maps/js/FlashTag.js +111 -0
- data/resources/maps/js/JavaScriptFlashGateway.js +455 -0
- data/resources/maps/js/JavaScriptFlashGateway.swf +0 -0
- data/resources/maps/map_library/australia.swf +0 -0
- data/resources/maps/map_library/belgium.swf +0 -0
- data/resources/maps/map_library/brazil.swf +0 -0
- data/resources/maps/map_library/canada.swf +0 -0
- data/resources/maps/map_library/europe.swf +0 -0
- data/resources/maps/map_library/france.swf +0 -0
- data/resources/maps/map_library/germany.swf +0 -0
- data/resources/maps/map_library/italy.swf +0 -0
- data/resources/maps/map_library/mexico.swf +0 -0
- data/resources/maps/map_library/sweden.swf +0 -0
- data/resources/maps/map_library/uk_ireland.swf +0 -0
- data/resources/maps/map_library/us.swf +0 -0
- data/resources/maps/map_library/us_canada.swf +0 -0
- data/resources/maps/map_library/world.swf +0 -0
- data/resources/maps/themes/readme.txt +13 -0
- data/spec/charts/base_spec.rb +7 -6
- data/spec/charts/chart_type_spec.rb +11 -4
- data/spec/{components → charts/support}/area_spec.rb +8 -8
- data/spec/charts/support/chart_pref_spec.rb +36 -0
- data/spec/charts/support/draw_spec.rb +41 -0
- data/spec/{components → charts/support}/filter_spec.rb +6 -6
- data/spec/{components → charts/support}/link_spec.rb +6 -6
- data/spec/{components → charts/support}/series.rb +4 -4
- data/spec/{components → charts/support}/series_color_spec.rb +4 -4
- data/spec/{components → charts/support}/series_explode.rb +4 -4
- data/spec/{components → charts/support}/series_explode_spec.rb +4 -4
- data/spec/core_ext/string_spec.rb +40 -0
- data/spec/gauges/base_spec.rb +1 -1
- data/spec/html_helpers/base_spec.rb +50 -0
- data/spec/html_helpers/charts_spec.rb +23 -0
- data/spec/html_helpers/gauges_spec.rb +16 -0
- data/spec/html_helpers/maps_spec.rb +20 -0
- data/spec/maps/base_spec.rb +82 -0
- data/spec/maps/support/default_color_spec.rb +29 -0
- data/spec/maps/support/heat_range_spec.rb +29 -0
- data/spec/maps/us_spec.rb +12 -0
- data/spec/maps/world_spec.rb +18 -0
- data/spec/spec_helper.rb +5 -4
- data/spec/themes/maps/base_map.yml +81 -0
- data/spec/themes/maps/us_map.yml +6 -0
- data/spec/themes/maps/world_map.yml +6 -0
- data/spec/themes/maps/world_ov_map.yml +6 -0
- data/spec/{helpers/base_helper_spec.rb → yaml_helpers/charts_spec.rb} +10 -13
- data/spec/yaml_helpers/gauges_spec.rb +15 -0
- data/spec/ziya_helper_spec.rb +118 -116
- data/tasks/doc.rake +12 -7
- data/tasks/gem.rake +1 -1
- data/tasks/setup.rb +1 -1
- data/ziya.gemspec +40 -0
- metadata +582 -94
- data/charts/charts.swf +0 -0
- data/charts/charts_library/ar3d.swf +0 -0
- data/charts/charts_library/arno.swf +0 -0
- data/charts/charts_library/ars3.swf +0 -0
- data/charts/charts_library/arst.swf +0 -0
- data/charts/charts_library/brfl.swf +0 -0
- data/charts/charts_library/brno.swf +0 -0
- data/charts/charts_library/brst.swf +0 -0
- data/charts/charts_library/buno.swf +0 -0
- data/charts/charts_library/cl3d.swf +0 -0
- data/charts/charts_library/clfl.swf +0 -0
- data/charts/charts_library/clim.swf +0 -0
- data/charts/charts_library/clno.swf +0 -0
- data/charts/charts_library/clp3.swf +0 -0
- data/charts/charts_library/cls3.swf +0 -0
- data/charts/charts_library/clst.swf +0 -0
- data/charts/charts_library/cnno.swf +0 -0
- data/charts/charts_library/dono.swf +0 -0
- data/charts/charts_library/lnno.swf +0 -0
- data/charts/charts_library/mxno.swf +0 -0
- data/charts/charts_library/pi3d.swf +0 -0
- data/charts/charts_library/piim.swf +0 -0
- data/charts/charts_library/pino.swf +0 -0
- data/charts/charts_library/pono.swf +0 -0
- data/charts/charts_library/scno.swf +0 -0
- data/charts/ziya.js +0 -66
- data/lib/ziya/components/draw.rb +0 -47
- data/lib/ziya/helpers/base_helper.rb +0 -91
- data/lib/ziya/utils/text.rb +0 -39
- data/lib/ziya/ziya_helper.rb +0 -354
- data/spec/components/draw_spec.rb +0 -32
- data/spec/utils/text_spec.rb +0 -33
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
@@ -0,0 +1,13 @@
|
|
1
|
+
This directory indicates the location where you can specify the maps looks and feel.
|
2
|
+
You will need to create a new theme directory which contains the map YAML stylesheets for
|
3
|
+
your various maps.
|
4
|
+
|
5
|
+
For example
|
6
|
+
|
7
|
+
public/maps/themes/cool_maps
|
8
|
+
- us_map.yml
|
9
|
+
- world_map.yml
|
10
|
+
|
11
|
+
Then in your controller, indicate you want to choose the 'cool_maps' theme by using the following:
|
12
|
+
|
13
|
+
map.add( :theme, "cool_maps" )
|
data/spec/charts/base_spec.rb
CHANGED
@@ -40,11 +40,11 @@ describe Ziya::Charts::Base do
|
|
40
40
|
end
|
41
41
|
|
42
42
|
it "should support setting a composite chart urls" do
|
43
|
-
@chart.add( :composites,
|
44
|
-
@chart.to_xml.should == "<?xml version=\"1.0\" encoding=\"UTF-8\"?><chart></chart>"
|
43
|
+
@chart.add( :composites, { :fred => { :url => "url1" }, :blee => { :url => "url2" } } )
|
44
|
+
@chart.to_xml.should == "<?xml version=\"1.0\" encoding=\"UTF-8\"?><chart><draw><image url=\"/charts/charts.swf?library_path=/charts/charts_library&xml_source=url2&chart_id=blee\"/><image url=\"/charts/charts.swf?library_path=/charts/charts_library&xml_source=url1&chart_id=fred\"/></draw></chart>"
|
45
45
|
end
|
46
46
|
it "should error if the composite url arg is not an array" do
|
47
|
-
lambda { @chart.add( :composites, "") }.should raise_error( ArgumentError, /
|
47
|
+
lambda { @chart.add( :composites, "") }.should raise_error( ArgumentError, /hash of id => url/ )
|
48
48
|
end
|
49
49
|
|
50
50
|
it "should support setting the axis_value label" do
|
@@ -88,10 +88,11 @@ describe Ziya::Charts::Base do
|
|
88
88
|
@chart.add( :series, "test", [ 10, 20 ], "some_url" )
|
89
89
|
@chart.to_xml.should == "<?xml version=\"1.0\" encoding=\"UTF-8\"?><chart><chart_data><row><null/><string>dog</string><string>cat</string></row><row url=\"some_url\"><string>test</string><number>10</number><number>20</number></row></chart_data></chart>"
|
90
90
|
end
|
91
|
-
|
91
|
+
|
92
|
+
# BOZO !! Review
|
92
93
|
it "should error if a series is defined but no axis_category is specified" do
|
93
|
-
@chart.add( :series, "test", [10,20] )
|
94
|
-
lambda { @chart.to_xml }.should raise_error( RuntimeError, /axis_category_text/i )
|
94
|
+
# @chart.add( :series, "test", [10,20] )
|
95
|
+
# lambda { @chart.to_xml }.should raise_error( RuntimeError, /axis_category_text/i )
|
95
96
|
end
|
96
97
|
|
97
98
|
it "should accept a series with no name" do
|
@@ -1,8 +1,7 @@
|
|
1
1
|
require File.expand_path(File.join(File.dirname(__FILE__), %w[.. spec_helper]))
|
2
|
+
require 'ziya/core_ext/string'
|
2
3
|
|
3
|
-
describe Ziya::Charts::Base do
|
4
|
-
include Ziya::Utils::Text
|
5
|
-
|
4
|
+
describe Ziya::Charts::Base do
|
6
5
|
before( :all ) do
|
7
6
|
@types = %w[
|
8
7
|
Area
|
@@ -26,13 +25,19 @@ describe Ziya::Charts::Base do
|
|
26
25
|
StackedBar
|
27
26
|
StackedColumn
|
28
27
|
StackedThreedColumn
|
28
|
+
StackedThreedArea
|
29
|
+
AreaThreed
|
30
|
+
Donut
|
31
|
+
ImagePie
|
32
|
+
ImageColumn
|
33
|
+
Custom
|
29
34
|
]
|
30
35
|
end
|
31
36
|
|
32
37
|
describe "#initialize" do
|
33
38
|
it "should create a set of charts correctly" do
|
34
39
|
@types.each do |type|
|
35
|
-
chart = Ziya::Charts.const_get( classify
|
40
|
+
chart = Ziya::Charts.const_get( type.classify ).new
|
36
41
|
if type.index( /Threed/ )
|
37
42
|
match = type.match( /(.*)Threed(.*)/ )
|
38
43
|
if match[2] and !match[2].empty?
|
@@ -40,6 +45,8 @@ describe Ziya::Charts::Base do
|
|
40
45
|
else
|
41
46
|
chart.type.gsub(/ /, '' ).should == "3d" + match[1].downcase
|
42
47
|
end
|
48
|
+
elsif type == "Custom"
|
49
|
+
chart.type.should be_empty
|
43
50
|
else
|
44
51
|
chart.type.gsub(/ /, '' ).should == type.downcase unless type == "Mixed"
|
45
52
|
end
|
@@ -1,8 +1,8 @@
|
|
1
|
-
require File.expand_path(File.join(File.dirname(__FILE__), %w[.. spec_helper]))
|
1
|
+
require File.expand_path(File.join(File.dirname(__FILE__), %w[.. .. spec_helper]))
|
2
2
|
|
3
|
-
describe Ziya::
|
3
|
+
describe Ziya::Charts::Support::Area do
|
4
4
|
before( :each ) do
|
5
|
-
@comp = Ziya::
|
5
|
+
@comp = Ziya::Charts::Support::Area.new
|
6
6
|
@comp.x = 1
|
7
7
|
@comp.y = 2
|
8
8
|
@comp.width = 100
|
@@ -14,7 +14,7 @@ describe Ziya::Components::Area do
|
|
14
14
|
end
|
15
15
|
|
16
16
|
it "should construct an area correctly" do
|
17
|
-
area = Ziya::
|
17
|
+
area = Ziya::Charts::Support::Area.new( :height => 200, :width => 100, :x => 0, :y => 1 )
|
18
18
|
area.height.should == 200
|
19
19
|
area.width.should == 100
|
20
20
|
area.x.should == 0
|
@@ -26,7 +26,7 @@ describe Ziya::Components::Area do
|
|
26
26
|
end
|
27
27
|
|
28
28
|
it "should define the correct attribute methods" do
|
29
|
-
lambda{ Ziya::
|
29
|
+
lambda{ Ziya::Charts::Support::Area.attributes[@comp.class.name].each {
|
30
30
|
|m| @comp.send( m ) } }.should_not raise_error
|
31
31
|
end
|
32
32
|
|
@@ -35,12 +35,12 @@ describe Ziya::Components::Area do
|
|
35
35
|
end
|
36
36
|
|
37
37
|
it "should check that no properties are set correctly" do
|
38
|
-
@comp = Ziya::
|
38
|
+
@comp = Ziya::Charts::Support::Area.new
|
39
39
|
@comp.should_not be_configured
|
40
40
|
end
|
41
41
|
|
42
42
|
it "should merge attributes correctly" do
|
43
|
-
parent = Ziya::
|
43
|
+
parent = Ziya::Charts::Support::Area.new
|
44
44
|
parent.x = 20
|
45
45
|
parent.y = 50
|
46
46
|
@comp.merge( parent, false )
|
@@ -58,7 +58,7 @@ describe Ziya::Components::Area do
|
|
58
58
|
|
59
59
|
it "should flatten simple component correctly" do
|
60
60
|
xml = Builder::XmlMarkup.new
|
61
|
-
comp = Ziya::
|
61
|
+
comp = Ziya::Charts::Support::Area.new
|
62
62
|
comp.x = 10
|
63
63
|
comp.flatten( xml ).should == "<area x=\"10\"/>"
|
64
64
|
end
|
@@ -0,0 +1,36 @@
|
|
1
|
+
require File.expand_path(File.join(File.dirname(__FILE__), %w[.. .. spec_helper]))
|
2
|
+
|
3
|
+
describe Ziya::Charts::Support::ChartPref do
|
4
|
+
before( :each ) do
|
5
|
+
@comp = Ziya::Charts::Support::ChartPref.new
|
6
|
+
end
|
7
|
+
|
8
|
+
it "should define the correct attribute methods" do
|
9
|
+
lambda{ Ziya::Charts::Support::ChartPref.attributes[@comp.class.name].each {
|
10
|
+
|m| @comp.send( m ) } }.should_not raise_error
|
11
|
+
end
|
12
|
+
|
13
|
+
describe "#flatten" do
|
14
|
+
before( :each ) do
|
15
|
+
@xml = Builder::XmlMarkup.new
|
16
|
+
end
|
17
|
+
|
18
|
+
it "should flatten line point shape correctly" do
|
19
|
+
@comp.point_shape = "square"
|
20
|
+
@comp.flatten( @xml ).should == '<chart_pref point_shape="square"/>'
|
21
|
+
end
|
22
|
+
|
23
|
+
it "should flatten line connect correctly" do
|
24
|
+
@comp.connect = true
|
25
|
+
@comp.point_shape = 'square'
|
26
|
+
@comp.flatten( @xml ).should == '<chart_pref point_shape="square" connect="true"/>'
|
27
|
+
end
|
28
|
+
|
29
|
+
it "should flatten zero line correctly" do
|
30
|
+
@comp.zero_line = true
|
31
|
+
@comp.point_shape = 'square'
|
32
|
+
@comp.flatten( @xml ).should == '<chart_pref point_shape="square" zero_line="true"/>'
|
33
|
+
end
|
34
|
+
|
35
|
+
end
|
36
|
+
end
|
@@ -0,0 +1,41 @@
|
|
1
|
+
require File.expand_path(File.join(File.dirname(__FILE__), %w[.. .. spec_helper]))
|
2
|
+
|
3
|
+
describe Ziya::Charts::Support::Draw do
|
4
|
+
before( :each ) do
|
5
|
+
@comp = Ziya::Charts::Support::Draw.new
|
6
|
+
circle = Ziya::Charts::Support::Circle.new
|
7
|
+
circle.radius = 10
|
8
|
+
image = Ziya::Charts::Support::Image.new
|
9
|
+
image.x = 10
|
10
|
+
text = Ziya::Charts::Support::Text.new
|
11
|
+
text.x = 20
|
12
|
+
# text.y = 10
|
13
|
+
text.text = "Hello World"
|
14
|
+
@comp.components = [circle, image, text]
|
15
|
+
end
|
16
|
+
|
17
|
+
it "should define the correct attribute methods" do
|
18
|
+
lambda{ Ziya::Charts::Support::Draw.attributes[@comp.class.name].each {
|
19
|
+
|m| @comp.send( m ) } }.should_not raise_error
|
20
|
+
end
|
21
|
+
|
22
|
+
describe "#flatten" do
|
23
|
+
before( :each ) do
|
24
|
+
@xml = Builder::XmlMarkup.new
|
25
|
+
end
|
26
|
+
|
27
|
+
it "should flatten component correctly" do
|
28
|
+
@comp.flatten( @xml ).should == "<draw><circle radius=\"10\"/><image x=\"10\"/><text x=\"20\">Hello World</text></draw>"
|
29
|
+
end
|
30
|
+
|
31
|
+
it "should support composite charts" do
|
32
|
+
urls = { :fred => { :url => "/fred" }, :blee => { :url => "/blee" } }
|
33
|
+
@comp.flatten( @xml, urls ).should == "<draw><circle radius=\"10\"/><image x=\"10\"/><text x=\"20\">Hello World</text><image url=\"/charts/charts.swf?library_path=/charts/charts_library&xml_source=%2Fblee&chart_id=blee\"/><image url=\"/charts/charts.swf?library_path=/charts/charts_library&xml_source=%2Ffred&chart_id=fred\"/></draw>"
|
34
|
+
end
|
35
|
+
|
36
|
+
it "should support composite chart with options" do
|
37
|
+
urls = { :fred => { :url => "/fred", :transition => "slide_left", :duration => 1 } }
|
38
|
+
@comp.flatten( @xml, urls ).index( "transition=\"slide_left\"" ).should_not be_nil
|
39
|
+
end
|
40
|
+
end
|
41
|
+
end
|
@@ -1,17 +1,17 @@
|
|
1
|
-
require File.expand_path(File.join(File.dirname(__FILE__), %w[.. spec_helper]))
|
1
|
+
require File.expand_path(File.join(File.dirname(__FILE__), %w[.. .. spec_helper]))
|
2
2
|
|
3
|
-
describe Ziya::
|
3
|
+
describe Ziya::Charts::Support::Filter do
|
4
4
|
before( :each ) do
|
5
|
-
@comp = Ziya::
|
6
|
-
blur = Ziya::
|
5
|
+
@comp = Ziya::Charts::Support::Filter.new
|
6
|
+
blur = Ziya::Charts::Support::Blur.new
|
7
7
|
blur.blurX = 10
|
8
|
-
glow = Ziya::
|
8
|
+
glow = Ziya::Charts::Support::Glow.new
|
9
9
|
glow.alpha = 50
|
10
10
|
@comp.filters = [blur, glow]
|
11
11
|
end
|
12
12
|
|
13
13
|
it "should define the correct attribute methods" do
|
14
|
-
lambda{ Ziya::
|
14
|
+
lambda{ Ziya::Charts::Support::Filter.attributes[@comp.class.name].each {
|
15
15
|
|m| @comp.send( m ) } }.should_not raise_error
|
16
16
|
end
|
17
17
|
|
@@ -1,17 +1,17 @@
|
|
1
|
-
require File.expand_path(File.join(File.dirname(__FILE__), %w[.. spec_helper]))
|
1
|
+
require File.expand_path(File.join(File.dirname(__FILE__), %w[.. .. spec_helper]))
|
2
2
|
|
3
|
-
describe Ziya::
|
3
|
+
describe Ziya::Charts::Support::Link do
|
4
4
|
before( :each ) do
|
5
|
-
@comp = Ziya::
|
6
|
-
area1 = Ziya::
|
5
|
+
@comp = Ziya::Charts::Support::Link.new
|
6
|
+
area1 = Ziya::Charts::Support::Area.new
|
7
7
|
area1.x = 10
|
8
|
-
area2 = Ziya::
|
8
|
+
area2 = Ziya::Charts::Support::Area.new
|
9
9
|
area2.x = 20
|
10
10
|
@comp.areas = [area1, area2]
|
11
11
|
end
|
12
12
|
|
13
13
|
it "should define the correct attribute methods" do
|
14
|
-
lambda{ Ziya::
|
14
|
+
lambda{ Ziya::Charts::Support::Link.attributes[@comp.class.name].each {
|
15
15
|
|m| @comp.send( m ) } }.should_not raise_error
|
16
16
|
end
|
17
17
|
|
@@ -1,12 +1,12 @@
|
|
1
|
-
require File.expand_path(File.join(File.dirname(__FILE__), %w[.. spec_helper]))
|
1
|
+
require File.expand_path(File.join(File.dirname(__FILE__), %w[.. .. spec_helper]))
|
2
2
|
|
3
|
-
describe Ziya::
|
3
|
+
describe Ziya::Charts::Support::Series do
|
4
4
|
before( :each ) do
|
5
|
-
@comp = Ziya::
|
5
|
+
@comp = Ziya::Charts::Support::Series.new
|
6
6
|
end
|
7
7
|
|
8
8
|
it "should define the correct attribute methods" do
|
9
|
-
lambda{ Ziya::
|
9
|
+
lambda{ Ziya::Charts::Support::Series.attributes[@comp.class.name].each {
|
10
10
|
|m| @comp.send( m ) } }.should_not raise_error
|
11
11
|
end
|
12
12
|
|
@@ -1,12 +1,12 @@
|
|
1
|
-
require File.expand_path(File.join(File.dirname(__FILE__), %w[.. spec_helper]))
|
1
|
+
require File.expand_path(File.join(File.dirname(__FILE__), %w[.. .. spec_helper]))
|
2
2
|
|
3
|
-
describe Ziya::
|
3
|
+
describe Ziya::Charts::Support::SeriesColor do
|
4
4
|
before( :each ) do
|
5
|
-
@comp = Ziya::
|
5
|
+
@comp = Ziya::Charts::Support::SeriesColor.new
|
6
6
|
end
|
7
7
|
|
8
8
|
it "should define the correct attribute methods" do
|
9
|
-
lambda{ Ziya::
|
9
|
+
lambda{ Ziya::Charts::Support::SeriesColor.attributes[@comp.class.name].each {
|
10
10
|
|m| @comp.send( m ) } }.should_not raise_error
|
11
11
|
end
|
12
12
|
|
@@ -1,12 +1,12 @@
|
|
1
|
-
require File.expand_path(File.join(File.dirname(__FILE__), %w[.. spec_helper]))
|
1
|
+
require File.expand_path(File.join(File.dirname(__FILE__), %w[.. .. spec_helper]))
|
2
2
|
|
3
|
-
describe Ziya::
|
3
|
+
describe Ziya::Charts::Support::SeriesExplode do
|
4
4
|
before( :each ) do
|
5
|
-
@comp = Ziya::
|
5
|
+
@comp = Ziya::Charts::Support::SeriesExplode.new
|
6
6
|
end
|
7
7
|
|
8
8
|
it "should define the correct attribute methods" do
|
9
|
-
lambda{ Ziya::
|
9
|
+
lambda{ Ziya::Charts::Support::SeriesExplode.attributes[@comp.class.name].each {
|
10
10
|
|m| @comp.send( m ) } }.should_not raise_error
|
11
11
|
end
|
12
12
|
|
@@ -1,12 +1,12 @@
|
|
1
|
-
require File.expand_path(File.join(File.dirname(__FILE__), %w[.. spec_helper]))
|
1
|
+
require File.expand_path(File.join(File.dirname(__FILE__), %w[.. .. spec_helper]))
|
2
2
|
|
3
|
-
describe Ziya::
|
3
|
+
describe Ziya::Charts::Support::SeriesExplode do
|
4
4
|
before( :each ) do
|
5
|
-
@comp = Ziya::
|
5
|
+
@comp = Ziya::Charts::Support::SeriesExplode.new
|
6
6
|
end
|
7
7
|
|
8
8
|
it "should define the correct attribute methods" do
|
9
|
-
lambda{ Ziya::
|
9
|
+
lambda{ Ziya::Charts::Support::SeriesExplode.attributes[@comp.class.name].each {
|
10
10
|
|m| @comp.send( m ) } }.should_not raise_error
|
11
11
|
end
|
12
12
|
|
@@ -0,0 +1,40 @@
|
|
1
|
+
require File.expand_path(File.join(File.dirname(__FILE__), %w[.. spec_helper]))
|
2
|
+
require 'ziya/core_ext/string'
|
3
|
+
|
4
|
+
describe String do
|
5
|
+
describe "#camelize_it" do
|
6
|
+
describe "it should strip module info and camelize string correctly" do
|
7
|
+
"fred/blee/hello_world".camelize_it.should == "Fred::Blee::HelloWorld"
|
8
|
+
end
|
9
|
+
|
10
|
+
describe "it should camelize a string correctly" do
|
11
|
+
"hello_world".camelize_it.should == "HelloWorld"
|
12
|
+
end
|
13
|
+
|
14
|
+
describe "it should camelize a plural class correctly" do
|
15
|
+
"axis_ticks".camelize_it.should == "AxisTicks"
|
16
|
+
end
|
17
|
+
end
|
18
|
+
|
19
|
+
describe "#underscore" do
|
20
|
+
describe "it should underscore a class name correctly" do
|
21
|
+
"Fred::Blee::HelloWorld".underscore.should == "fred/blee/hello_world"
|
22
|
+
end
|
23
|
+
|
24
|
+
describe "it should underscore a name correctly" do
|
25
|
+
"HelloWorld".underscore.should == "hello_world"
|
26
|
+
end
|
27
|
+
end
|
28
|
+
|
29
|
+
describe "#classify" do
|
30
|
+
it "should create a class name correctly" do
|
31
|
+
"/fred.blee.hello_world".classify.should == "HelloWorld"
|
32
|
+
end
|
33
|
+
end
|
34
|
+
|
35
|
+
describe "#demodulize" do
|
36
|
+
it "should strip module info correctly" do
|
37
|
+
"Fred::Blee::HelloWorld".demodulize.should == "HelloWorld"
|
38
|
+
end
|
39
|
+
end
|
40
|
+
end
|
data/spec/gauges/base_spec.rb
CHANGED
@@ -1,6 +1,7 @@
|
|
1
1
|
require File.expand_path(File.join(File.dirname(__FILE__), %w[.. spec_helper]))
|
2
2
|
|
3
3
|
describe Ziya::Gauges::Base do
|
4
|
+
|
4
5
|
describe "#initialize" do
|
5
6
|
before( :each ) do
|
6
7
|
@gauge = Ziya::Gauges::Base.new( "test_license", "test" )
|
@@ -86,5 +87,4 @@ describe Ziya::Gauges::Base do
|
|
86
87
|
buff.scan( /url=\"(\/\w+\/\w+)\"/ ).should == [ ["/blee/fred"] ]
|
87
88
|
buff.scan( /delay=\"(.*?\d+)\"/ ).should == [ ["30"] ]
|
88
89
|
end
|
89
|
-
|
90
90
|
end
|
@@ -0,0 +1,50 @@
|
|
1
|
+
require File.expand_path(File.join(File.dirname(__FILE__), %w[.. spec_helper]))
|
2
|
+
|
3
|
+
describe Ziya::HtmlHelpers::Base do
|
4
|
+
|
5
|
+
include Ziya::HtmlHelpers::Base
|
6
|
+
|
7
|
+
it "should generate the correct mime" do
|
8
|
+
mime.should == "application/x-shockwave-flash"
|
9
|
+
end
|
10
|
+
|
11
|
+
it "should generate the correct plugin url" do
|
12
|
+
plugin_url.should == "http://www.macromedia.com/go/getflashplayer"
|
13
|
+
end
|
14
|
+
|
15
|
+
describe "should generate the correct wmode" do
|
16
|
+
before( :each ) do
|
17
|
+
@opts = { :bgcolor => '#ffffff' }
|
18
|
+
end
|
19
|
+
|
20
|
+
it "should set up the correct wmode when a background color is specified" do
|
21
|
+
setup_wmode( @opts )
|
22
|
+
@opts[:wmode].should == "opaque"
|
23
|
+
end
|
24
|
+
|
25
|
+
it "should not override wmode if specified" do
|
26
|
+
@opts[:wmode] = "test"
|
27
|
+
setup_wmode( @opts )
|
28
|
+
@opts[:wmode].should == "test"
|
29
|
+
end
|
30
|
+
|
31
|
+
it "should generate the correct defaults if no color is specified" do
|
32
|
+
@opts.delete( :bgcolor )
|
33
|
+
setup_wmode( @opts )
|
34
|
+
@opts[:wmode].should == "transparent"
|
35
|
+
@opts[:bgcolor].should == "#FFFFFF"
|
36
|
+
end
|
37
|
+
end
|
38
|
+
|
39
|
+
it "should set up the flash movie size correctly" do
|
40
|
+
opts = { :size => "400x300" }
|
41
|
+
setup_movie_size( opts )
|
42
|
+
opts[:size].should be_nil
|
43
|
+
opts[:width].should == "400"
|
44
|
+
opts[:height].should == "300"
|
45
|
+
end
|
46
|
+
|
47
|
+
it "should escape a url correctly" do
|
48
|
+
escape_url( "http://fred?arg1=1&arg2=2&test=hello world" ).should == "http%3A%2F%2Ffred%3Farg1%3D1%26arg2%3D2%26test%3Dhello+world"
|
49
|
+
end
|
50
|
+
end
|