write_xlsx 0.85.9 → 1.09.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.gitignore +1 -0
- data/.travis.yml +53 -1
- data/Changes +242 -0
- data/LICENSE.txt +1 -1
- data/README.md +5 -5
- data/examples/a_simple.rb +2 -7
- data/examples/add_vba_project.rb +1 -1
- data/examples/array_formula.rb +1 -1
- data/examples/background.rb +19 -0
- data/examples/chart_area.rb +5 -2
- data/examples/chart_bar.rb +5 -2
- data/examples/chart_clustered.rb +1 -1
- data/examples/chart_column.rb +5 -2
- data/examples/chart_combined.rb +4 -2
- data/examples/chart_data_labels.rb +320 -0
- data/examples/chart_data_table.rb +9 -3
- data/examples/chart_data_tools.rb +25 -7
- data/examples/chart_doughnut.rb +17 -5
- data/examples/chart_gauge.rb +73 -0
- data/examples/chart_line.rb +90 -12
- data/examples/chart_pareto.rb +1 -1
- data/examples/chart_pie.rb +9 -3
- data/examples/chart_radar.rb +13 -4
- data/examples/chart_scatter.rb +5 -2
- data/examples/chart_secondary_axis.rb +5 -2
- data/examples/chart_stock.rb +1 -1
- data/examples/chart_styles.rb +1 -1
- data/examples/colors.rb +48 -1
- data/examples/comments2.rb +1 -1
- data/examples/conditional_format.rb +79 -1
- data/examples/data_validate.rb +8 -8
- data/examples/date_time.rb +1 -1
- data/examples/demo.rb +5 -8
- data/examples/formats.rb +1 -1
- data/examples/headers.rb +1 -1
- data/examples/hide_row_col.rb +1 -1
- data/examples/hide_sheet.rb +1 -1
- data/examples/hyperlink1.rb +5 -12
- data/examples/ignore_errors.rb +39 -0
- data/examples/indent.rb +1 -1
- data/examples/keep_leading_zeros.rb +17 -0
- data/examples/macros.rb +1 -1
- data/examples/merge1.rb +1 -1
- data/examples/merge2.rb +1 -1
- data/examples/merge3.rb +1 -1
- data/examples/merge4.rb +1 -1
- data/examples/merge5.rb +1 -1
- data/examples/merge6.rb +1 -1
- data/examples/outline.rb +1 -1
- data/examples/outline_collapsed.rb +1 -1
- data/examples/panes.rb +2 -2
- data/examples/properties.rb +1 -1
- data/examples/regions.rb +1 -1
- data/examples/rich_strings.rb +1 -1
- data/examples/right_to_left.rb +1 -1
- data/examples/shape1.rb +1 -1
- data/examples/shape2.rb +1 -1
- data/examples/shape3.rb +1 -1
- data/examples/shape4.rb +1 -1
- data/examples/shape5.rb +1 -1
- data/examples/shape6.rb +1 -1
- data/examples/shape7.rb +1 -1
- data/examples/shape8.rb +1 -1
- data/examples/shape_all.rb +1 -1
- data/examples/sparklines1.rb +1 -1
- data/examples/sparklines2.rb +1 -1
- data/examples/stats.rb +1 -1
- data/examples/stats_ext.rb +1 -1
- data/examples/stocks.rb +1 -1
- data/examples/tab_colors.rb +2 -2
- data/examples/tables.rb +78 -43
- data/examples/update_range_format_with_params.rb +33 -0
- data/lib/write_xlsx/chart/area.rb +1 -1
- data/lib/write_xlsx/chart/axis.rb +37 -12
- data/lib/write_xlsx/chart/bar.rb +1 -1
- data/lib/write_xlsx/chart/caption.rb +3 -1
- data/lib/write_xlsx/chart/column.rb +1 -1
- data/lib/write_xlsx/chart/doughnut.rb +1 -1
- data/lib/write_xlsx/chart/legend.rb +14 -0
- data/lib/write_xlsx/chart/line.rb +16 -2
- data/lib/write_xlsx/chart/pie.rb +32 -15
- data/lib/write_xlsx/chart/radar.rb +1 -1
- data/lib/write_xlsx/chart/scatter.rb +1 -16
- data/lib/write_xlsx/chart/series.rb +138 -18
- data/lib/write_xlsx/chart/stock.rb +1 -1
- data/lib/write_xlsx/chart.rb +365 -277
- data/lib/write_xlsx/chartsheet.rb +38 -10
- data/lib/write_xlsx/drawing.rb +190 -71
- data/lib/write_xlsx/format.rb +41 -201
- data/lib/write_xlsx/package/app.rb +17 -5
- data/lib/write_xlsx/package/button.rb +8 -8
- data/lib/write_xlsx/package/comments.rb +73 -68
- data/lib/write_xlsx/package/conditional_format.rb +367 -46
- data/lib/write_xlsx/package/content_types.rb +28 -9
- data/lib/write_xlsx/package/core.rb +13 -11
- data/lib/write_xlsx/package/custom.rb +125 -0
- data/lib/write_xlsx/package/metadata.rb +159 -0
- data/lib/write_xlsx/package/packager.rb +48 -0
- data/lib/write_xlsx/package/relationships.rb +4 -4
- data/lib/write_xlsx/package/shared_strings.rb +6 -6
- data/lib/write_xlsx/package/styles.rb +102 -39
- data/lib/write_xlsx/package/table.rb +83 -36
- data/lib/write_xlsx/package/theme.rb +1 -1
- data/lib/write_xlsx/package/vml.rb +63 -62
- data/lib/write_xlsx/package/xml_writer_simple.rb +3 -2
- data/lib/write_xlsx/shape.rb +21 -18
- data/lib/write_xlsx/sheets.rb +18 -16
- data/lib/write_xlsx/sparkline.rb +341 -341
- data/lib/write_xlsx/utility.rb +414 -53
- data/lib/write_xlsx/version.rb +1 -1
- data/lib/write_xlsx/workbook.rb +396 -699
- data/lib/write_xlsx/worksheet/cell_data.rb +46 -3
- data/lib/write_xlsx/worksheet/data_validation.rb +53 -50
- data/lib/write_xlsx/worksheet/hyperlink.rb +29 -50
- data/lib/write_xlsx/worksheet/page_setup.rb +12 -12
- data/lib/write_xlsx/worksheet.rb +1043 -4366
- data/test/chart/test_add_series.rb +11 -1
- data/test/chart/test_process_names.rb +1 -1
- data/test/chart/test_write_a_latin.rb +1 -1
- data/test/chart/test_write_auto.rb +1 -1
- data/test/chart/test_write_ax_id.rb +1 -1
- data/test/chart/test_write_ax_pos.rb +1 -1
- data/test/chart/test_write_cross_ax.rb +1 -1
- data/test/chart/test_write_crosses.rb +1 -1
- data/test/chart/test_write_d_lbls.rb +1 -1
- data/test/chart/test_write_format_code.rb +1 -1
- data/test/chart/test_write_idx.rb +1 -1
- data/test/chart/test_write_label_align.rb +1 -1
- data/test/chart/test_write_label_offset.rb +1 -1
- data/test/chart/test_write_lang.rb +1 -1
- data/test/chart/test_write_layout.rb +1 -1
- data/test/chart/test_write_legend.rb +1 -1
- data/test/chart/test_write_legend_pos.rb +10 -2
- data/test/chart/test_write_major_gridlines.rb +1 -1
- data/test/chart/test_write_marker.rb +1 -1
- data/test/chart/test_write_marker_size.rb +1 -1
- data/test/chart/test_write_marker_value.rb +1 -1
- data/test/chart/test_write_num_cache.rb +1 -1
- data/test/chart/test_write_number_format.rb +2 -3
- data/test/chart/test_write_order.rb +1 -1
- data/test/chart/test_write_orientation.rb +1 -1
- data/test/chart/test_write_page_margins.rb +1 -1
- data/test/chart/test_write_page_setup.rb +1 -1
- data/test/chart/test_write_plot_vis_only.rb +1 -1
- data/test/chart/test_write_pt.rb +1 -1
- data/test/chart/test_write_pt_count.rb +1 -1
- data/test/chart/test_write_series_formula.rb +1 -1
- data/test/chart/test_write_style.rb +1 -1
- data/test/chart/test_write_symbol.rb +1 -1
- data/test/chart/test_write_tick_lbl_pos.rb +1 -1
- data/test/chart/test_write_v.rb +1 -1
- data/test/chartsheet/test_chartsheet01.rb +1 -1
- data/test/chartsheet/test_write_sheet_protection.rb +91 -0
- data/test/drawing/test_drawing_chart_01.rb +7 -3
- data/test/drawing/test_drawing_image_01.rb +13 -4
- data/test/drawing/test_drawing_shape_01.rb +9 -6
- data/test/drawing/test_drawing_shape_02.rb +13 -6
- data/test/drawing/test_drawing_shape_03.rb +9 -6
- data/test/drawing/test_drawing_shape_04.rb +9 -25
- data/test/drawing/test_drawing_shape_05.rb +9 -6
- data/test/drawing/test_drawing_shape_06.rb +12 -7
- data/test/drawing/test_drawing_shape_07.rb +12 -7
- data/test/drawing/test_write_a_graphic_frame_locks.rb +2 -2
- data/test/drawing/test_write_c_chart.rb +2 -2
- data/test/drawing/test_write_c_nv_graphic_frame_pr.rb +2 -2
- data/test/drawing/test_write_c_nv_pr.rb +2 -2
- data/test/drawing/test_write_col.rb +2 -2
- data/test/drawing/test_write_col_off.rb +2 -2
- data/test/drawing/test_write_pos.rb +2 -2
- data/test/drawing/test_write_row.rb +2 -2
- data/test/drawing/test_write_row_off.rb +2 -2
- data/test/drawing/{test_write_ext.rb → test_write_xdr_ext.rb} +3 -3
- data/test/drawing/test_write_xfrm_extension.rb +2 -2
- data/test/drawing/test_write_xfrm_offset.rb +2 -2
- data/test/helper.rb +8 -3
- data/test/package/app/test_app01.rb +1 -1
- data/test/package/app/test_app02.rb +1 -1
- data/test/package/app/test_app03.rb +1 -1
- data/test/package/comments/test_comments_01.rb +54 -0
- data/test/package/comments/test_comments_02.rb +54 -0
- data/test/package/content_types/test_content_types.rb +1 -1
- data/test/package/content_types/test_write_default.rb +1 -1
- data/test/package/content_types/test_write_override.rb +1 -1
- data/test/package/core/test_core01.rb +1 -1
- data/test/package/core/test_core02.rb +1 -1
- data/test/package/relationships/test_relationships.rb +1 -1
- data/test/package/relationships/test_sheet_rels.rb +1 -1
- data/test/package/shared_strings/test_shared_strings01.rb +1 -1
- data/test/package/shared_strings/test_shared_strings02.rb +1 -1
- data/test/package/shared_strings/test_write_si.rb +1 -7
- data/test/package/styles/test_styles_01.rb +1 -1
- data/test/package/styles/test_styles_02.rb +1 -1
- data/test/package/styles/test_styles_03.rb +1 -1
- data/test/package/styles/test_styles_04.rb +1 -1
- data/test/package/styles/test_styles_05.rb +1 -1
- data/test/package/styles/test_styles_06.rb +1 -1
- data/test/package/styles/test_styles_07.rb +1 -1
- data/test/package/styles/test_styles_08.rb +1 -1
- data/test/package/styles/test_styles_09.rb +1 -1
- data/test/package/table/test_table01.rb +3 -3
- data/test/package/table/test_table02.rb +2 -2
- data/test/package/table/test_table03.rb +2 -2
- data/test/package/table/test_table04.rb +2 -2
- data/test/package/table/test_table05.rb +2 -2
- data/test/package/table/test_table06.rb +2 -2
- data/test/package/table/test_table07.rb +2 -2
- data/test/package/table/test_table08.rb +2 -2
- data/test/package/table/test_table09.rb +2 -2
- data/test/package/table/test_table10.rb +2 -2
- data/test/package/table/test_table11.rb +2 -2
- data/test/package/table/test_table12.rb +2 -2
- data/test/package/table/test_table13.rb +1 -1
- data/test/package/table/test_write_auto_filter.rb +1 -1
- data/test/package/table/test_write_table_column.rb +1 -1
- data/test/package/table/test_write_table_style_info.rb +1 -1
- data/test/package/vml/test_write_auto_fill.rb +1 -1
- data/test/package/vml/test_write_div.rb +1 -1
- data/test/package/vml/test_write_idmap.rb +1 -1
- data/test/package/vml/test_write_path.rb +1 -1
- data/test/package/vml/test_write_shapelayout.rb +1 -1
- data/test/package/vml/test_write_shapetype.rb +1 -1
- data/test/package/vml/test_write_stroke.rb +1 -1
- data/test/perl_output/background.xlsx +0 -0
- data/test/perl_output/chart_data_labels.xlsx +0 -0
- data/test/perl_output/chart_gauge.xlsx +0 -0
- data/test/perl_output/chart_line.xlsx +0 -0
- data/test/perl_output/comments2.xlsx +0 -0
- data/test/perl_output/formats.xlsx +0 -0
- data/test/perl_output/ignore_errors.xlsx +0 -0
- data/test/perl_output/keep_leading_zeros.xlsx +0 -0
- data/test/perl_output/multi_line.xlsx +0 -0
- data/test/perl_output/tables.xlsx +0 -0
- data/test/regression/_test_hyperlink31.rb +26 -0
- data/test/regression/disabled_test_vml04.rb +1 -1
- data/test/regression/images/happy.jpg +0 -0
- data/test/regression/images/logo.gif +0 -0
- data/test/regression/images/logo.jpg +0 -0
- data/test/regression/images/red.gif +0 -0
- data/test/regression/images/red2.png +0 -0
- data/test/regression/images/red_208.png +0 -0
- data/test/regression/images/zero_dpi.jpg +0 -0
- data/test/regression/test_array_formula01.rb +1 -1
- data/test/regression/test_array_formula02.rb +1 -1
- data/test/regression/test_array_formula03.rb +36 -0
- data/test/regression/test_array_formula04.rb +31 -0
- data/test/regression/test_autofilter00.rb +1 -1
- data/test/regression/test_autofilter01.rb +1 -1
- data/test/regression/test_autofilter02.rb +1 -1
- data/test/regression/test_autofilter03.rb +1 -1
- data/test/regression/test_autofilter04.rb +1 -1
- data/test/regression/test_autofilter05.rb +1 -1
- data/test/regression/test_autofilter06.rb +1 -1
- data/test/regression/test_autofilter07.rb +1 -1
- data/test/regression/test_autofilter08.rb +110 -0
- data/test/regression/test_autofilter09.rb +110 -0
- data/test/regression/test_autofilter10.rb +110 -0
- data/test/regression/test_background01.rb +23 -0
- data/test/regression/test_background02.rb +23 -0
- data/test/regression/test_background03.rb +24 -0
- data/test/regression/test_background04.rb +25 -0
- data/test/regression/test_background05.rb +25 -0
- data/test/regression/test_background06.rb +31 -0
- data/test/regression/test_background07.rb +37 -0
- data/test/regression/test_button01.rb +1 -1
- data/test/regression/test_button02.rb +1 -1
- data/test/regression/test_button03.rb +1 -1
- data/test/regression/test_button04.rb +1 -1
- data/test/regression/test_button05.rb +1 -1
- data/test/regression/test_button06.rb +1 -1
- data/test/regression/test_button07.rb +1 -1
- data/test/regression/test_button08.rb +1 -1
- data/test/regression/test_button13.rb +1 -1
- data/test/regression/test_button14.rb +1 -1
- data/test/regression/test_chart_area01.rb +1 -1
- data/test/regression/test_chart_area02.rb +1 -1
- data/test/regression/test_chart_area03.rb +1 -1
- data/test/regression/test_chart_area04.rb +1 -1
- data/test/regression/test_chart_axis01.rb +1 -1
- data/test/regression/test_chart_axis02.rb +1 -1
- data/test/regression/test_chart_axis03.rb +1 -1
- data/test/regression/test_chart_axis04.rb +1 -1
- data/test/regression/test_chart_axis05.rb +1 -1
- data/test/regression/test_chart_axis06.rb +1 -1
- data/test/regression/test_chart_axis07.rb +1 -1
- data/test/regression/test_chart_axis08.rb +1 -1
- data/test/regression/test_chart_axis09.rb +1 -1
- data/test/regression/test_chart_axis10.rb +1 -1
- data/test/regression/test_chart_axis11.rb +1 -1
- data/test/regression/test_chart_axis12.rb +1 -1
- data/test/regression/test_chart_axis13.rb +1 -1
- data/test/regression/test_chart_axis14.rb +1 -1
- data/test/regression/test_chart_axis15.rb +1 -1
- data/test/regression/test_chart_axis16.rb +1 -1
- data/test/regression/test_chart_axis17.rb +1 -1
- data/test/regression/test_chart_axis18.rb +1 -1
- data/test/regression/test_chart_axis19.rb +1 -1
- data/test/regression/test_chart_axis20.rb +1 -1
- data/test/regression/test_chart_axis21.rb +1 -1
- data/test/regression/test_chart_axis22.rb +1 -1
- data/test/regression/test_chart_axis23.rb +1 -1
- data/test/regression/test_chart_axis24.rb +1 -1
- data/test/regression/test_chart_axis25.rb +1 -1
- data/test/regression/test_chart_axis26.rb +11 -9
- data/test/regression/test_chart_axis27.rb +2 -2
- data/test/regression/test_chart_axis28.rb +2 -2
- data/test/regression/test_chart_axis29.rb +2 -2
- data/test/regression/test_chart_axis30.rb +1 -1
- data/test/regression/test_chart_axis31.rb +1 -1
- data/test/regression/test_chart_axis32.rb +1 -1
- data/test/regression/test_chart_axis33.rb +2 -2
- data/test/regression/test_chart_axis34.rb +1 -1
- data/test/regression/test_chart_axis35.rb +1 -1
- data/test/regression/test_chart_axis36.rb +1 -1
- data/test/regression/test_chart_axis37.rb +1 -1
- data/test/regression/test_chart_axis38.rb +1 -1
- data/test/regression/test_chart_axis39.rb +1 -1
- data/test/regression/test_chart_axis40.rb +44 -0
- data/test/regression/test_chart_axis41.rb +48 -0
- data/test/regression/test_chart_axis42.rb +44 -0
- data/test/regression/test_chart_axis43.rb +44 -0
- data/test/regression/test_chart_axis44.rb +54 -0
- data/test/regression/test_chart_axis45.rb +54 -0
- data/test/regression/test_chart_axis46.rb +54 -0
- data/test/regression/test_chart_axis47.rb +52 -0
- data/test/regression/test_chart_axis48.rb +53 -0
- data/test/regression/test_chart_bar01.rb +1 -1
- data/test/regression/test_chart_bar02.rb +1 -1
- data/test/regression/test_chart_bar03.rb +1 -1
- data/test/regression/test_chart_bar04.rb +1 -1
- data/test/regression/test_chart_bar05.rb +1 -1
- data/test/regression/test_chart_bar06.rb +1 -1
- data/test/regression/test_chart_bar07.rb +1 -1
- data/test/regression/test_chart_bar08.rb +4 -1
- data/test/regression/test_chart_bar09.rb +1 -1
- data/test/regression/test_chart_bar10.rb +1 -1
- data/test/regression/test_chart_bar11.rb +4 -1
- data/test/regression/test_chart_bar12.rb +1 -1
- data/test/regression/test_chart_bar13.rb +1 -1
- data/test/regression/test_chart_bar14.rb +4 -1
- data/test/regression/test_chart_bar15.rb +1 -1
- data/test/regression/test_chart_bar16.rb +1 -1
- data/test/regression/test_chart_bar17.rb +1 -1
- data/test/regression/test_chart_bar18.rb +1 -1
- data/test/regression/test_chart_bar19.rb +1 -1
- data/test/regression/test_chart_bar20.rb +1 -1
- data/test/regression/test_chart_bar21.rb +1 -1
- data/test/regression/test_chart_bar22.rb +1 -1
- data/test/regression/test_chart_bar23.rb +1 -1
- data/test/regression/test_chart_bar24.rb +1 -1
- data/test/regression/test_chart_blank01.rb +1 -1
- data/test/regression/test_chart_blank02.rb +1 -1
- data/test/regression/test_chart_blank03.rb +1 -1
- data/test/regression/test_chart_blank04.rb +1 -1
- data/test/regression/test_chart_blank05.rb +1 -1
- data/test/regression/test_chart_blank06.rb +1 -1
- data/test/regression/test_chart_chartarea01.rb +1 -1
- data/test/regression/test_chart_chartarea02.rb +1 -1
- data/test/regression/test_chart_chartarea03.rb +1 -1
- data/test/regression/test_chart_chartarea04.rb +1 -1
- data/test/regression/test_chart_chartarea05.rb +17 -18
- data/test/regression/test_chart_chartarea06.rb +49 -0
- data/test/regression/test_chart_clustered01.rb +1 -1
- data/test/regression/test_chart_column01.rb +1 -1
- data/test/regression/test_chart_column02.rb +1 -1
- data/test/regression/test_chart_column03.rb +1 -1
- data/test/regression/test_chart_column04.rb +1 -1
- data/test/regression/test_chart_column05.rb +1 -1
- data/test/regression/test_chart_column06.rb +1 -1
- data/test/regression/test_chart_column07.rb +1 -1
- data/test/regression/test_chart_column08.rb +1 -1
- data/test/regression/test_chart_column09.rb +1 -1
- data/test/regression/test_chart_column10.rb +1 -1
- data/test/regression/test_chart_column11.rb +1 -1
- data/test/regression/test_chart_column12.rb +1 -1
- data/test/regression/test_chart_combined01.rb +1 -1
- data/test/regression/test_chart_combined02.rb +1 -1
- data/test/regression/test_chart_combined03.rb +1 -1
- data/test/regression/test_chart_combined04.rb +1 -1
- data/test/regression/test_chart_combined05.rb +1 -1
- data/test/regression/test_chart_combined06.rb +1 -1
- data/test/regression/test_chart_combined07.rb +1 -1
- data/test/regression/test_chart_combined08.rb +1 -1
- data/test/regression/test_chart_combined09.rb +50 -0
- data/test/regression/test_chart_combined10.rb +43 -0
- data/test/regression/test_chart_combined11.rb +63 -0
- data/test/regression/test_chart_crossing01.rb +2 -2
- data/test/regression/test_chart_crossing02.rb +1 -1
- data/test/regression/test_chart_crossing03.rb +1 -1
- data/test/regression/test_chart_crossing04.rb +1 -1
- data/test/regression/test_chart_crossing05.rb +46 -0
- data/test/regression/test_chart_crossing06.rb +46 -0
- data/test/regression/test_chart_data_labels01.rb +1 -1
- data/test/regression/test_chart_data_labels02.rb +1 -1
- data/test/regression/test_chart_data_labels03.rb +1 -1
- data/test/regression/test_chart_data_labels04.rb +1 -1
- data/test/regression/test_chart_data_labels05.rb +1 -1
- data/test/regression/test_chart_data_labels06.rb +1 -1
- data/test/regression/test_chart_data_labels07.rb +1 -1
- data/test/regression/test_chart_data_labels08.rb +1 -1
- data/test/regression/test_chart_data_labels09.rb +1 -1
- data/test/regression/test_chart_data_labels10.rb +1 -1
- data/test/regression/test_chart_data_labels11.rb +1 -1
- data/test/regression/test_chart_data_labels12.rb +1 -1
- data/test/regression/test_chart_data_labels13.rb +1 -1
- data/test/regression/test_chart_data_labels14.rb +1 -1
- data/test/regression/test_chart_data_labels15.rb +1 -1
- data/test/regression/test_chart_data_labels16.rb +1 -1
- data/test/regression/test_chart_data_labels17.rb +1 -1
- data/test/regression/test_chart_data_labels18.rb +1 -1
- data/test/regression/test_chart_data_labels19.rb +1 -1
- data/test/regression/test_chart_data_labels20.rb +1 -1
- data/test/regression/test_chart_data_labels21.rb +1 -1
- data/test/regression/test_chart_data_labels22.rb +1 -1
- data/test/regression/test_chart_data_labels23.rb +1 -1
- data/test/regression/test_chart_data_labels24.rb +1 -1
- data/test/regression/test_chart_data_labels25.rb +61 -0
- data/test/regression/test_chart_data_labels26.rb +44 -0
- data/test/regression/test_chart_data_labels27.rb +44 -0
- data/test/regression/test_chart_data_labels28.rb +52 -0
- data/test/regression/test_chart_data_labels29.rb +43 -0
- data/test/regression/test_chart_data_labels30.rb +46 -0
- data/test/regression/test_chart_data_labels31.rb +49 -0
- data/test/regression/test_chart_data_labels32.rb +54 -0
- data/test/regression/test_chart_data_labels33.rb +52 -0
- data/test/regression/test_chart_data_labels34.rb +54 -0
- data/test/regression/test_chart_data_labels35.rb +46 -0
- data/test/regression/test_chart_data_labels36.rb +54 -0
- data/test/regression/test_chart_data_labels37.rb +51 -0
- data/test/regression/test_chart_data_labels38.rb +54 -0
- data/test/regression/test_chart_data_labels39.rb +53 -0
- data/test/regression/test_chart_data_labels40.rb +53 -0
- data/test/regression/test_chart_data_labels41.rb +54 -0
- data/test/regression/test_chart_data_labels42.rb +58 -0
- data/test/regression/test_chart_data_labels43.rb +58 -0
- data/test/regression/test_chart_data_labels44.rb +56 -0
- data/test/regression/test_chart_data_labels45.rb +57 -0
- data/test/regression/test_chart_data_labels46.rb +61 -0
- data/test/regression/test_chart_data_labels47.rb +61 -0
- data/test/regression/test_chart_data_labels48.rb +55 -0
- data/test/regression/test_chart_data_labels49.rb +55 -0
- data/test/regression/test_chart_data_labels50.rb +57 -0
- data/test/regression/test_chart_date01.rb +1 -1
- data/test/regression/test_chart_date02.rb +1 -1
- data/test/regression/test_chart_date03.rb +1 -1
- data/test/regression/test_chart_date04.rb +1 -1
- data/test/regression/test_chart_date05.rb +1 -1
- data/test/regression/test_chart_display_units01.rb +1 -1
- data/test/regression/test_chart_display_units02.rb +1 -1
- data/test/regression/test_chart_display_units03.rb +1 -1
- data/test/regression/test_chart_display_units04.rb +1 -1
- data/test/regression/test_chart_display_units05.rb +1 -1
- data/test/regression/test_chart_display_units06.rb +1 -1
- data/test/regression/test_chart_display_units07.rb +1 -1
- data/test/regression/test_chart_display_units08.rb +1 -1
- data/test/regression/test_chart_display_units09.rb +1 -1
- data/test/regression/test_chart_display_units10.rb +1 -1
- data/test/regression/test_chart_display_units11.rb +1 -1
- data/test/regression/test_chart_display_units12.rb +1 -1
- data/test/regression/test_chart_doughnut01.rb +1 -1
- data/test/regression/test_chart_doughnut02.rb +1 -1
- data/test/regression/test_chart_doughnut03.rb +1 -1
- data/test/regression/test_chart_doughnut04.rb +1 -1
- data/test/regression/test_chart_doughnut05.rb +1 -1
- data/test/regression/test_chart_doughnut06.rb +1 -1
- data/test/regression/test_chart_doughnut07.rb +37 -0
- data/test/regression/test_chart_drop_lines01.rb +1 -1
- data/test/regression/test_chart_drop_lines02.rb +1 -1
- data/test/regression/test_chart_drop_lines03.rb +1 -1
- data/test/regression/test_chart_drop_lines04.rb +1 -1
- data/test/regression/test_chart_errorbars01.rb +1 -1
- data/test/regression/test_chart_errorbars02.rb +1 -1
- data/test/regression/test_chart_errorbars03.rb +1 -1
- data/test/regression/test_chart_errorbars04.rb +1 -1
- data/test/regression/test_chart_errorbars05.rb +1 -1
- data/test/regression/test_chart_errorbars06.rb +1 -1
- data/test/regression/test_chart_errorbars07.rb +1 -1
- data/test/regression/test_chart_errorbars08.rb +1 -1
- data/test/regression/test_chart_errorbars09.rb +1 -1
- data/test/regression/test_chart_errorbars10.rb +1 -1
- data/test/regression/test_chart_font01.rb +1 -1
- data/test/regression/test_chart_font02.rb +1 -1
- data/test/regression/test_chart_font03.rb +1 -1
- data/test/regression/test_chart_font04.rb +1 -1
- data/test/regression/test_chart_font05.rb +1 -1
- data/test/regression/test_chart_font06.rb +1 -1
- data/test/regression/test_chart_font07.rb +1 -1
- data/test/regression/test_chart_font08.rb +1 -1
- data/test/regression/test_chart_font09.rb +2 -2
- data/test/regression/test_chart_format01.rb +1 -1
- data/test/regression/test_chart_format02.rb +1 -1
- data/test/regression/test_chart_format03.rb +1 -1
- data/test/regression/test_chart_format04.rb +1 -1
- data/test/regression/test_chart_format05.rb +1 -1
- data/test/regression/test_chart_format06.rb +1 -1
- data/test/regression/test_chart_format07.rb +1 -1
- data/test/regression/test_chart_format08.rb +1 -1
- data/test/regression/test_chart_format09.rb +1 -1
- data/test/regression/test_chart_format10.rb +1 -1
- data/test/regression/test_chart_format11.rb +1 -1
- data/test/regression/test_chart_format12.rb +1 -1
- data/test/regression/test_chart_format13.rb +1 -1
- data/test/regression/test_chart_format14.rb +1 -1
- data/test/regression/test_chart_format15.rb +1 -1
- data/test/regression/test_chart_format16.rb +1 -1
- data/test/regression/test_chart_format17.rb +1 -1
- data/test/regression/test_chart_format18.rb +1 -1
- data/test/regression/test_chart_format19.rb +1 -1
- data/test/regression/test_chart_format20.rb +1 -1
- data/test/regression/test_chart_format21.rb +47 -0
- data/test/regression/test_chart_format22.rb +47 -0
- data/test/regression/test_chart_format23.rb +47 -0
- data/test/regression/test_chart_format24.rb +52 -0
- data/test/regression/test_chart_format25.rb +46 -0
- data/test/regression/test_chart_format26.rb +48 -0
- data/test/regression/test_chart_format27.rb +58 -0
- data/test/regression/test_chart_format28.rb +52 -0
- data/test/regression/test_chart_format29.rb +59 -0
- data/test/regression/test_chart_format30.rb +53 -0
- data/test/regression/test_chart_format31.rb +60 -0
- data/test/regression/test_chart_gap01.rb +1 -1
- data/test/regression/test_chart_gap02.rb +1 -1
- data/test/regression/test_chart_gap03.rb +1 -1
- data/test/regression/test_chart_gap04.rb +1 -1
- data/test/regression/test_chart_gap05.rb +1 -1
- data/test/regression/test_chart_gradient01.rb +1 -1
- data/test/regression/test_chart_gradient02.rb +1 -1
- data/test/regression/test_chart_gradient03.rb +1 -1
- data/test/regression/test_chart_gradient04.rb +1 -1
- data/test/regression/test_chart_gradient05.rb +1 -1
- data/test/regression/test_chart_gradient06.rb +1 -1
- data/test/regression/test_chart_gradient07.rb +1 -1
- data/test/regression/test_chart_gradient08.rb +1 -1
- data/test/regression/test_chart_gradient09.rb +1 -1
- data/test/regression/test_chart_gradient10.rb +1 -1
- data/test/regression/test_chart_gradient11.rb +1 -1
- data/test/regression/test_chart_gradient12.rb +1 -1
- data/test/regression/test_chart_gradient13.rb +1 -1
- data/test/regression/test_chart_gridlines01.rb +1 -1
- data/test/regression/test_chart_gridlines02.rb +1 -1
- data/test/regression/test_chart_gridlines03.rb +1 -1
- data/test/regression/test_chart_gridlines04.rb +5 -4
- data/test/regression/test_chart_gridlines05.rb +1 -1
- data/test/regression/test_chart_gridlines06.rb +1 -1
- data/test/regression/test_chart_gridlines07.rb +1 -1
- data/test/regression/test_chart_gridlines08.rb +9 -12
- data/test/regression/test_chart_gridlines09.rb +1 -1
- data/test/regression/test_chart_layout01.rb +1 -1
- data/test/regression/test_chart_layout02.rb +1 -1
- data/test/regression/test_chart_layout03.rb +1 -1
- data/test/regression/test_chart_layout04.rb +1 -1
- data/test/regression/test_chart_layout05.rb +1 -1
- data/test/regression/test_chart_layout06.rb +1 -1
- data/test/regression/test_chart_layout07.rb +1 -1
- data/test/regression/test_chart_layout08.rb +1 -1
- data/test/regression/test_chart_legend01.rb +1 -1
- data/test/regression/test_chart_legend02.rb +1 -1
- data/test/regression/test_chart_legend03.rb +41 -0
- data/test/regression/test_chart_legend04.rb +41 -0
- data/test/regression/test_chart_legend05.rb +41 -0
- data/test/regression/test_chart_legend06.rb +41 -0
- data/test/regression/test_chart_legend07.rb +38 -0
- data/test/regression/test_chart_line01.rb +1 -1
- data/test/regression/test_chart_line02.rb +1 -1
- data/test/regression/test_chart_line03.rb +1 -1
- data/test/regression/test_chart_line04.rb +1 -1
- data/test/regression/test_chart_line05.rb +43 -0
- data/test/regression/test_chart_line06.rb +43 -0
- data/test/regression/test_chart_name01.rb +1 -1
- data/test/regression/test_chart_name02.rb +1 -1
- data/test/regression/test_chart_name03.rb +1 -1
- data/test/regression/test_chart_order01.rb +1 -1
- data/test/regression/test_chart_order02.rb +1 -1
- data/test/regression/test_chart_order03.rb +1 -1
- data/test/regression/test_chart_pattern01.rb +49 -0
- data/test/regression/test_chart_pattern02.rb +106 -0
- data/test/regression/test_chart_pattern03.rb +105 -0
- data/test/regression/test_chart_pattern04.rb +105 -0
- data/test/regression/test_chart_pattern05.rb +105 -0
- data/test/regression/test_chart_pattern06.rb +105 -0
- data/test/regression/test_chart_pattern07.rb +105 -0
- data/test/regression/test_chart_pattern08.rb +105 -0
- data/test/regression/test_chart_pattern09.rb +57 -0
- data/test/regression/test_chart_pattern10.rb +57 -0
- data/test/regression/test_chart_pie01.rb +1 -1
- data/test/regression/test_chart_pie02.rb +1 -1
- data/test/regression/test_chart_pie03.rb +1 -1
- data/test/regression/test_chart_pie04.rb +1 -1
- data/test/regression/test_chart_pie05.rb +1 -1
- data/test/regression/test_chart_points01.rb +1 -1
- data/test/regression/test_chart_points02.rb +1 -1
- data/test/regression/test_chart_points03.rb +1 -1
- data/test/regression/test_chart_points04.rb +1 -1
- data/test/regression/test_chart_points05.rb +1 -1
- data/test/regression/test_chart_points06.rb +1 -1
- data/test/regression/test_chart_radar01.rb +1 -1
- data/test/regression/test_chart_radar02.rb +1 -1
- data/test/regression/test_chart_radar03.rb +1 -1
- data/test/regression/test_chart_scatter01.rb +1 -1
- data/test/regression/test_chart_scatter02.rb +1 -1
- data/test/regression/test_chart_scatter03.rb +1 -1
- data/test/regression/test_chart_scatter04.rb +1 -1
- data/test/regression/test_chart_scatter05.rb +1 -1
- data/test/regression/test_chart_scatter06.rb +1 -1
- data/test/regression/test_chart_scatter07.rb +1 -1
- data/test/regression/test_chart_scatter08.rb +1 -1
- data/test/regression/test_chart_scatter09.rb +1 -1
- data/test/regression/test_chart_scatter10.rb +1 -1
- data/test/regression/test_chart_scatter11.rb +1 -1
- data/test/regression/test_chart_scatter12.rb +1 -1
- data/test/regression/test_chart_scatter13.rb +1 -1
- data/test/regression/test_chart_scatter14.rb +1 -1
- data/test/regression/test_chart_scatter15.rb +1 -1
- data/test/regression/test_chart_size01.rb +1 -1
- data/test/regression/test_chart_size02.rb +1 -1
- data/test/regression/test_chart_size03.rb +5 -2
- data/test/regression/test_chart_size04.rb +1 -1
- data/test/regression/test_chart_size05.rb +1 -1
- data/test/regression/test_chart_sparse01.rb +1 -1
- data/test/regression/test_chart_stock01.rb +1 -1
- data/test/regression/test_chart_stock02.rb +1 -1
- data/test/regression/test_chart_str01.rb +1 -1
- data/test/regression/test_chart_str02.rb +1 -1
- data/test/regression/test_chart_table01.rb +1 -1
- data/test/regression/test_chart_table02.rb +1 -1
- data/test/regression/test_chart_table03.rb +56 -0
- data/test/regression/test_chart_title01.rb +1 -1
- data/test/regression/test_chart_title02.rb +1 -1
- data/test/regression/test_chartsheet01.rb +1 -1
- data/test/regression/test_chartsheet02.rb +1 -1
- data/test/regression/test_chartsheet03.rb +1 -1
- data/test/regression/test_chartsheet04.rb +1 -1
- data/test/regression/test_chartsheet05.rb +1 -1
- data/test/regression/test_chartsheet06.rb +1 -1
- data/test/regression/test_chartsheet07.rb +1 -1
- data/test/regression/test_chartsheet08.rb +1 -1
- data/test/regression/test_chartsheet09.rb +1 -1
- data/test/regression/test_comment01.rb +1 -1
- data/test/regression/test_comment02.rb +1 -1
- data/test/regression/test_comment03.rb +1 -1
- data/test/regression/test_comment04.rb +1 -1
- data/test/regression/test_comment06.rb +1 -1
- data/test/regression/test_comment07.rb +1 -1
- data/test/regression/test_comment08.rb +1 -1
- data/test/regression/test_comment09.rb +1 -1
- data/test/regression/test_comment10.rb +1 -1
- data/test/regression/test_comment11.rb +1 -1
- data/test/regression/test_comment12.rb +1 -1
- data/test/regression/test_comment13.rb +36 -0
- data/test/regression/test_comment14.rb +29 -0
- data/test/regression/test_comment15.rb +28 -0
- data/test/regression/test_comment16.rb +34 -0
- data/test/regression/test_cond_format01.rb +1 -1
- data/test/regression/test_cond_format02.rb +1 -1
- data/test/regression/test_cond_format03.rb +1 -1
- data/test/regression/test_cond_format04.rb +1 -1
- data/test/regression/test_cond_format05.rb +1 -1
- data/test/regression/test_cond_format06.rb +1 -1
- data/test/regression/test_cond_format07.rb +1 -1
- data/test/regression/test_cond_format08.rb +1 -1
- data/test/regression/test_cond_format10.rb +1 -1
- data/test/regression/test_cond_format11.rb +1 -1
- data/test/regression/test_cond_format12.rb +1 -1
- data/test/regression/test_cond_format13.rb +1 -1
- data/test/regression/test_cond_format14.rb +42 -0
- data/test/regression/test_cond_format15.rb +53 -0
- data/test/regression/test_cond_format16.rb +53 -0
- data/test/regression/test_cond_format17.rb +37 -0
- data/test/regression/test_cond_format18.rb +136 -0
- data/test/regression/test_cond_format19.rb +64 -0
- data/test/regression/test_cond_format20.rb +43 -0
- data/test/regression/test_custom_colors01.rb +1 -1
- data/test/regression/test_data_validation01.rb +1 -1
- data/test/regression/test_data_validation02.rb +1 -1
- data/test/regression/test_data_validation03.rb +1 -1
- data/test/regression/test_data_validation04.rb +2 -2
- data/test/regression/test_data_validation05.rb +2 -2
- data/test/regression/test_data_validation08.rb +24 -0
- data/test/regression/test_date_1904_01.rb +2 -2
- data/test/regression/test_date_1904_02.rb +1 -1
- data/test/regression/test_date_examples01.rb +1 -1
- data/test/regression/test_default_format01.rb +1 -1
- data/test/regression/test_default_row01.rb +1 -1
- data/test/regression/test_default_row02.rb +1 -1
- data/test/regression/test_default_row03.rb +1 -1
- data/test/regression/test_default_row04.rb +1 -1
- data/test/regression/test_default_row05.rb +32 -0
- data/test/regression/test_defined_name01.rb +1 -1
- data/test/regression/test_defined_name02.rb +1 -1
- data/test/regression/test_defined_name03.rb +1 -1
- data/test/regression/test_defined_name04.rb +15 -15
- data/test/regression/test_dynamic_array01.rb +25 -0
- data/test/regression/test_escapes01.rb +1 -1
- data/test/regression/test_escapes02.rb +1 -1
- data/test/regression/test_escapes03.rb +1 -1
- data/test/regression/test_escapes04.rb +4 -1
- data/test/regression/test_escapes05.rb +4 -1
- data/test/regression/test_escapes06.rb +1 -1
- data/test/regression/test_escapes07.rb +4 -1
- data/test/regression/test_escapes08.rb +4 -1
- data/test/regression/test_excel2003_style01.rb +1 -1
- data/test/regression/test_excel2003_style02.rb +1 -1
- data/test/regression/test_excel2003_style03.rb +1 -1
- data/test/regression/test_excel2003_style04.rb +1 -1
- data/test/regression/test_excel2003_style05.rb +1 -1
- data/test/regression/test_excel2003_style06.rb +1 -1
- data/test/regression/test_excel2003_style07.rb +1 -1
- data/test/regression/test_excel2003_style08.rb +1 -1
- data/test/regression/test_firstsheet01.rb +1 -1
- data/test/regression/test_fit_to_pages01.rb +1 -1
- data/test/regression/test_fit_to_pages02.rb +1 -1
- data/test/regression/test_fit_to_pages03.rb +1 -1
- data/test/regression/test_fit_to_pages04.rb +1 -1
- data/test/regression/test_fit_to_pages05.rb +1 -1
- data/test/regression/test_format01.rb +1 -1
- data/test/regression/test_format02.rb +1 -1
- data/test/regression/test_format03.rb +1 -1
- data/test/regression/test_format04.rb +1 -1
- data/test/regression/test_format05.rb +1 -1
- data/test/regression/test_format11.rb +1 -1
- data/test/regression/test_format12.rb +1 -1
- data/test/regression/test_format13.rb +31 -0
- data/test/regression/test_format14.rb +26 -0
- data/test/regression/test_format15.rb +26 -0
- data/test/regression/test_format16.rb +24 -0
- data/test/regression/test_format17.rb +24 -0
- data/test/regression/test_formula_results01.rb +1 -1
- data/test/regression/test_gridlines01.rb +1 -1
- data/test/regression/test_header01.rb +1 -1
- data/test/regression/test_header02.rb +1 -1
- data/test/regression/test_header03.rb +1 -1
- data/test/regression/test_header04.rb +30 -0
- data/test/regression/test_header_image01.rb +1 -1
- data/test/regression/test_header_image02.rb +1 -1
- data/test/regression/test_header_image03.rb +1 -1
- data/test/regression/test_header_image04.rb +1 -1
- data/test/regression/test_header_image05.rb +1 -1
- data/test/regression/test_header_image06.rb +1 -1
- data/test/regression/test_header_image07.rb +1 -1
- data/test/regression/test_header_image08.rb +1 -1
- data/test/regression/test_header_image09.rb +1 -1
- data/test/regression/test_header_image10.rb +1 -1
- data/test/regression/test_header_image11.rb +1 -1
- data/test/regression/test_header_image12.rb +1 -1
- data/test/regression/test_header_image13.rb +1 -1
- data/test/regression/test_header_image14.rb +1 -1
- data/test/regression/test_header_image15.rb +36 -0
- data/test/regression/test_header_image16.rb +42 -0
- data/test/regression/test_header_image17.rb +46 -0
- data/test/regression/test_header_image18.rb +48 -0
- data/test/regression/test_header_image19.rb +36 -0
- data/test/regression/test_hide01.rb +1 -1
- data/test/regression/test_hyperlink01.rb +4 -1
- data/test/regression/test_hyperlink02.rb +4 -1
- data/test/regression/test_hyperlink03.rb +5 -1
- data/test/regression/test_hyperlink04.rb +4 -1
- data/test/regression/test_hyperlink05.rb +4 -1
- data/test/regression/test_hyperlink06.rb +4 -1
- data/test/regression/test_hyperlink07.rb +4 -1
- data/test/regression/test_hyperlink08.rb +4 -1
- data/test/regression/test_hyperlink09.rb +4 -1
- data/test/regression/test_hyperlink10.rb +4 -1
- data/test/regression/test_hyperlink11.rb +4 -1
- data/test/regression/test_hyperlink12.rb +4 -1
- data/test/regression/test_hyperlink13.rb +4 -1
- data/test/regression/test_hyperlink14.rb +4 -1
- data/test/regression/test_hyperlink15.rb +4 -1
- data/test/regression/test_hyperlink16.rb +4 -1
- data/test/regression/test_hyperlink17.rb +4 -1
- data/test/regression/test_hyperlink18.rb +4 -1
- data/test/regression/test_hyperlink20.rb +4 -1
- data/test/regression/test_hyperlink21.rb +4 -1
- data/test/regression/test_hyperlink22.rb +27 -0
- data/test/regression/test_hyperlink23.rb +27 -0
- data/test/regression/test_hyperlink24.rb +27 -0
- data/test/regression/test_hyperlink25.rb +30 -0
- data/test/regression/test_hyperlink26.rb +30 -0
- data/test/regression/test_hyperlink27.rb +27 -0
- data/test/regression/test_hyperlink28.rb +50 -0
- data/test/regression/test_hyperlink29.rb +27 -0
- data/test/regression/test_hyperlink30.rb +36 -0
- data/test/regression/test_hyperlink32.rb +27 -0
- data/test/regression/test_hyperlink33.rb +28 -0
- data/test/regression/test_hyperlink34.rb +33 -0
- data/test/regression/test_hyperlink35.rb +39 -0
- data/test/regression/test_hyperlink36.rb +34 -0
- data/test/regression/test_hyperlink37.rb +33 -0
- data/test/regression/test_hyperlink38.rb +27 -0
- data/test/regression/test_hyperlink39.rb +27 -0
- data/test/regression/test_hyperlink40.rb +27 -0
- data/test/regression/test_hyperlink41.rb +27 -0
- data/test/regression/test_hyperlink42.rb +27 -0
- data/test/regression/test_hyperlink43.rb +27 -0
- data/test/regression/test_hyperlink44.rb +27 -0
- data/test/regression/test_hyperlink45.rb +27 -0
- data/test/regression/test_hyperlink47.rb +27 -0
- data/test/regression/test_hyperlink48.rb +31 -0
- data/test/regression/test_hyperlink49.rb +29 -0
- data/test/regression/test_hyperlink50.rb +27 -0
- data/test/regression/test_hyperlink51.rb +27 -0
- data/test/regression/test_ignore_error01.rb +23 -0
- data/test/regression/test_ignore_error02.rb +24 -0
- data/test/regression/test_ignore_error03.rb +26 -0
- data/test/regression/test_ignore_error04.rb +26 -0
- data/test/regression/test_ignore_error05.rb +32 -0
- data/test/regression/test_ignore_error06.rb +32 -0
- data/test/regression/test_image01.rb +1 -1
- data/test/regression/test_image02.rb +1 -1
- data/test/regression/test_image03.rb +1 -1
- data/test/regression/test_image04.rb +1 -1
- data/test/regression/test_image05.rb +1 -1
- data/test/regression/test_image06.rb +6 -6
- data/test/regression/test_image07.rb +1 -1
- data/test/regression/test_image08.rb +6 -5
- data/test/regression/test_image09.rb +1 -1
- data/test/regression/test_image10.rb +1 -1
- data/test/regression/test_image11.rb +1 -1
- data/test/regression/test_image12.rb +1 -1
- data/test/regression/test_image13.rb +1 -1
- data/test/regression/test_image14.rb +1 -1
- data/test/regression/test_image15.rb +5 -3
- data/test/regression/test_image16.rb +1 -1
- data/test/regression/test_image17.rb +1 -1
- data/test/regression/test_image18.rb +1 -1
- data/test/regression/test_image19.rb +1 -1
- data/test/regression/test_image22.rb +1 -1
- data/test/regression/test_image23.rb +1 -1
- data/test/regression/test_image24.rb +1 -1
- data/test/regression/test_image25.rb +1 -1
- data/test/regression/test_image26.rb +1 -1
- data/test/regression/test_image27.rb +1 -1
- data/test/regression/test_image28.rb +27 -0
- data/test/regression/test_image29.rb +27 -0
- data/test/regression/test_image30.rb +27 -0
- data/test/regression/test_image31.rb +30 -0
- data/test/regression/test_image32.rb +28 -0
- data/test/regression/test_image33.rb +32 -0
- data/test/regression/test_image35.rb +26 -0
- data/test/regression/test_image36.rb +26 -0
- data/test/regression/test_image44.rb +28 -0
- data/test/regression/test_image45.rb +29 -0
- data/test/regression/test_image46.rb +29 -0
- data/test/regression/test_image47.rb +28 -0
- data/test/regression/test_image48.rb +32 -0
- data/test/regression/test_image49.rb +38 -0
- data/test/regression/test_image50.rb +24 -0
- data/test/regression/test_image51.rb +30 -0
- data/test/regression/test_image52.rb +26 -0
- data/test/regression/test_image53.rb +26 -0
- data/test/regression/test_image54.rb +26 -0
- data/test/regression/test_image55.rb +27 -0
- data/test/regression/test_image56.rb +23 -0
- data/test/regression/test_image57.rb +23 -0
- data/test/regression/test_landscape01.rb +1 -1
- data/test/regression/test_macro01.rb +1 -1
- data/test/regression/test_merge_cells01.rb +1 -1
- data/test/regression/test_merge_range01.rb +1 -1
- data/test/regression/test_merge_range02.rb +1 -1
- data/test/regression/test_merge_range03.rb +1 -1
- data/test/regression/test_merge_range04.rb +1 -1
- data/test/regression/test_merge_range05.rb +1 -1
- data/test/regression/test_object_position01.rb +26 -0
- data/test/regression/test_object_position02.rb +26 -0
- data/test/regression/test_object_position03.rb +26 -0
- data/test/regression/test_object_position04.rb +44 -0
- data/test/regression/test_object_position06.rb +28 -0
- data/test/regression/test_object_position07.rb +28 -0
- data/test/regression/test_object_position08.rb +47 -0
- data/test/regression/test_object_position09.rb +50 -0
- data/test/regression/test_object_position10.rb +28 -0
- data/test/regression/test_object_position12.rb +25 -0
- data/test/regression/test_object_position13.rb +25 -0
- data/test/regression/test_object_position14.rb +25 -0
- data/test/regression/test_object_position15.rb +29 -0
- data/test/regression/test_object_position16.rb +29 -0
- data/test/regression/test_object_position17.rb +29 -0
- data/test/regression/test_object_position18.rb +29 -0
- data/test/regression/test_object_position19.rb +29 -0
- data/test/regression/test_object_position20.rb +29 -0
- data/test/regression/test_outline01.rb +1 -1
- data/test/regression/test_outline02.rb +1 -1
- data/test/regression/test_outline03.rb +1 -1
- data/test/regression/test_outline04.rb +1 -1
- data/test/regression/test_outline05.rb +1 -1
- data/test/regression/test_outline06.rb +1 -1
- data/test/regression/test_page_breaks01.rb +1 -1
- data/test/regression/test_page_breaks02.rb +1 -1
- data/test/regression/test_page_breaks03.rb +1 -1
- data/test/regression/test_page_breaks04.rb +1 -1
- data/test/regression/test_page_breaks05.rb +1 -1
- data/test/regression/test_page_breaks06.rb +1 -1
- data/test/regression/test_page_view01.rb +1 -1
- data/test/regression/test_panes01.rb +1 -1
- data/test/regression/test_print_across01.rb +1 -1
- data/test/regression/test_print_area01.rb +1 -1
- data/test/regression/test_print_area02.rb +1 -1
- data/test/regression/test_print_area03.rb +1 -1
- data/test/regression/test_print_area04.rb +1 -1
- data/test/regression/test_print_area05.rb +1 -1
- data/test/regression/test_print_area06.rb +1 -1
- data/test/regression/test_print_area07.rb +1 -1
- data/test/regression/test_print_options01.rb +1 -1
- data/test/regression/test_print_options02.rb +1 -1
- data/test/regression/test_print_options03.rb +1 -1
- data/test/regression/test_print_options04.rb +1 -1
- data/test/regression/test_print_options05.rb +1 -1
- data/test/regression/test_print_options06.rb +1 -1
- data/test/regression/test_print_options07.rb +1 -1
- data/test/regression/test_print_scale01.rb +1 -1
- data/test/regression/test_print_scale02.rb +1 -1
- data/test/regression/test_properties01.rb +2 -5
- data/test/regression/test_properties02.rb +25 -0
- data/test/regression/test_properties03.rb +26 -0
- data/test/regression/test_properties04.rb +61 -0
- data/test/regression/test_properties05.rb +30 -0
- data/test/regression/test_protect01.rb +1 -1
- data/test/regression/test_protect02.rb +1 -1
- data/test/regression/test_protect03.rb +1 -1
- data/test/regression/test_protect04.rb +32 -0
- data/test/regression/test_protect05.rb +35 -0
- data/test/regression/test_protect06.rb +35 -0
- data/test/regression/test_protect07.rb +23 -0
- data/test/regression/test_quote_name01.rb +1 -1
- data/test/regression/test_quote_name03.rb +1 -1
- data/test/regression/test_quote_name04.rb +1 -1
- data/test/regression/test_repeat01.rb +1 -1
- data/test/regression/test_repeat02.rb +1 -1
- data/test/regression/test_repeat03.rb +1 -1
- data/test/regression/test_repeat04.rb +1 -1
- data/test/regression/test_repeat05.rb +1 -1
- data/test/regression/test_rich_string01.rb +1 -1
- data/test/regression/test_rich_string02.rb +1 -1
- data/test/regression/test_rich_string03.rb +1 -1
- data/test/regression/test_rich_string04.rb +1 -1
- data/test/regression/test_rich_string05.rb +1 -1
- data/test/regression/test_rich_string06.rb +1 -1
- data/test/regression/test_rich_string07.rb +1 -1
- data/test/regression/test_rich_string08.rb +1 -1
- data/test/regression/test_rich_string09.rb +1 -1
- data/test/regression/test_rich_string10.rb +1 -1
- data/test/regression/test_rich_string11.rb +1 -1
- data/test/regression/test_rich_string12.rb +1 -1
- data/test/regression/test_row_col_format01.rb +1 -1
- data/test/regression/test_row_col_format02.rb +1 -1
- data/test/regression/test_row_col_format03.rb +1 -1
- data/test/regression/test_row_col_format04.rb +1 -1
- data/test/regression/test_row_col_format05.rb +1 -1
- data/test/regression/test_row_col_format06.rb +1 -1
- data/test/regression/test_row_col_format07.rb +1 -1
- data/test/regression/test_row_col_format08.rb +1 -1
- data/test/regression/test_row_col_format09.rb +1 -1
- data/test/regression/test_row_col_format10.rb +1 -1
- data/test/regression/test_row_col_format11.rb +1 -1
- data/test/regression/test_row_col_format12.rb +1 -1
- data/test/regression/test_row_col_format13.rb +1 -1
- data/test/regression/test_row_col_format14.rb +1 -1
- data/test/regression/test_selection01.rb +1 -1
- data/test/regression/test_selection02.rb +1 -1
- data/test/regression/test_set_column01.rb +1 -1
- data/test/regression/test_set_column02.rb +1 -1
- data/test/regression/test_set_column03.rb +1 -1
- data/test/regression/test_set_column04.rb +1 -1
- data/test/regression/test_set_column05.rb +1 -1
- data/test/regression/test_set_column06.rb +1 -1
- data/test/regression/test_set_column07.rb +1 -1
- data/test/regression/test_set_column08.rb +1 -1
- data/test/regression/test_set_column09.rb +1 -1
- data/test/regression/test_set_column10.rb +55 -0
- data/test/regression/test_set_column11.rb +48 -0
- data/test/regression/test_set_print_scale01.rb +1 -1
- data/test/regression/test_set_row01.rb +35 -0
- data/test/regression/test_set_row02.rb +35 -0
- data/test/regression/test_set_row03.rb +35 -0
- data/test/regression/test_set_row04.rb +35 -0
- data/test/regression/test_set_start_page01.rb +1 -1
- data/test/regression/test_set_start_page02.rb +1 -1
- data/test/regression/test_set_start_page03.rb +1 -1
- data/test/regression/test_shape01.rb +1 -1
- data/test/regression/test_shape02.rb +1 -1
- data/test/regression/test_shape03.rb +1 -1
- data/test/regression/test_shape04.rb +1 -1
- data/test/regression/test_shape_connect01.rb +5 -3
- data/test/regression/test_shape_connect02.rb +1 -1
- data/test/regression/test_shape_connect03.rb +1 -1
- data/test/regression/test_shape_connect04.rb +1 -1
- data/test/regression/test_shape_scale01.rb +1 -1
- data/test/regression/test_shape_stencil01.rb +1 -1
- data/test/regression/test_shared_strings01.rb +1 -1
- data/test/regression/test_shared_strings02.rb +1 -1
- data/test/regression/test_simple01.rb +1 -1
- data/test/regression/test_simple02.rb +1 -1
- data/test/regression/test_simple03.rb +1 -1
- data/test/regression/test_simple04.rb +1 -1
- data/test/regression/test_simple05.rb +1 -1
- data/test/regression/test_tab_color01.rb +1 -1
- data/test/regression/test_table01.rb +1 -1
- data/test/regression/test_table02.rb +1 -1
- data/test/regression/test_table03.rb +4 -1
- data/test/regression/test_table04.rb +4 -1
- data/test/regression/test_table05.rb +4 -1
- data/test/regression/test_table06.rb +4 -1
- data/test/regression/test_table07.rb +1 -1
- data/test/regression/test_table08.rb +1 -1
- data/test/regression/test_table09.rb +1 -1
- data/test/regression/test_table10.rb +1 -1
- data/test/regression/test_table11.rb +1 -1
- data/test/regression/test_table12.rb +1 -1
- data/test/regression/test_table13.rb +1 -1
- data/test/regression/test_table14.rb +1 -1
- data/test/regression/test_table15.rb +1 -1
- data/test/regression/test_table16.rb +1 -1
- data/test/regression/test_table17.rb +1 -1
- data/test/regression/test_table20.rb +34 -0
- data/test/regression/test_table21.rb +36 -0
- data/test/regression/test_table22.rb +32 -0
- data/test/regression/test_table23.rb +56 -0
- data/test/regression/test_table24.rb +27 -0
- data/test/regression/test_table25.rb +27 -0
- data/test/regression/test_table26.rb +38 -0
- data/test/regression/test_tutorial01.rb +1 -1
- data/test/regression/test_tutorial02.rb +1 -1
- data/test/regression/test_tutorial03.rb +1 -1
- data/test/regression/test_types02.rb +25 -0
- data/test/regression/test_types08.rb +31 -0
- data/test/regression/test_update_range_format_with_params.rb +42 -0
- data/test/regression/test_urls_as_strings.rb +1 -1
- data/test/regression/test_utf8_01.rb +1 -1
- data/test/regression/test_utf8_03.rb +1 -1
- data/test/regression/test_utf8_04.rb +1 -1
- data/test/regression/test_utf8_05.rb +1 -1
- data/test/regression/test_utf8_06.rb +1 -1
- data/test/regression/test_utf8_07.rb +1 -1
- data/test/regression/test_utf8_08.rb +1 -1
- data/test/regression/test_utf8_09.rb +1 -1
- data/test/regression/test_utf8_10.rb +1 -1
- data/test/regression/test_utf8_11.rb +23 -0
- data/test/regression/test_vml01.rb +1 -1
- data/test/regression/test_vml02.rb +1 -1
- data/test/regression/test_vml03.rb +1 -1
- data/test/regression/xlsx_files/array_formula03.xlsx +0 -0
- data/test/regression/xlsx_files/array_formula04.xlsx +0 -0
- data/test/regression/xlsx_files/autofilter08.xlsx +0 -0
- data/test/regression/xlsx_files/autofilter09.xlsx +0 -0
- data/test/regression/xlsx_files/autofilter10.xlsx +0 -0
- data/test/regression/xlsx_files/background01.xlsx +0 -0
- data/test/regression/xlsx_files/background02.xlsx +0 -0
- data/test/regression/xlsx_files/background03.xlsx +0 -0
- data/test/regression/xlsx_files/background04.xlsx +0 -0
- data/test/regression/xlsx_files/background05.xlsx +0 -0
- data/test/regression/xlsx_files/background06.xlsx +0 -0
- data/test/regression/xlsx_files/background07.xlsx +0 -0
- data/test/regression/xlsx_files/chart_axis26.xlsx +0 -0
- data/test/regression/xlsx_files/chart_axis27.xlsx +0 -0
- data/test/regression/xlsx_files/chart_axis28.xlsx +0 -0
- data/test/regression/xlsx_files/chart_axis29.xlsx +0 -0
- data/test/regression/xlsx_files/chart_axis33.xlsx +0 -0
- data/test/regression/xlsx_files/chart_axis40.xlsx +0 -0
- data/test/regression/xlsx_files/chart_axis41.xlsx +0 -0
- data/test/regression/xlsx_files/chart_axis42.xlsx +0 -0
- data/test/regression/xlsx_files/chart_axis43.xlsx +0 -0
- data/test/regression/xlsx_files/chart_axis44.xlsx +0 -0
- data/test/regression/xlsx_files/chart_axis45.xlsx +0 -0
- data/test/regression/xlsx_files/chart_axis46.xlsx +0 -0
- data/test/regression/xlsx_files/chart_axis47.xlsx +0 -0
- data/test/regression/xlsx_files/chart_axis48.xlsx +0 -0
- data/test/regression/xlsx_files/chart_chartarea05.xlsx +0 -0
- data/test/regression/xlsx_files/chart_chartarea06.xlsx +0 -0
- data/test/regression/xlsx_files/chart_combined09.xlsx +0 -0
- data/test/regression/xlsx_files/chart_combined10.xlsx +0 -0
- data/test/regression/xlsx_files/chart_combined11.xlsx +0 -0
- data/test/regression/xlsx_files/chart_crossing05.xlsx +0 -0
- data/test/regression/xlsx_files/chart_crossing06.xlsx +0 -0
- data/test/regression/xlsx_files/chart_data_labels25.xlsx +0 -0
- data/test/regression/xlsx_files/chart_data_labels26.xlsx +0 -0
- data/test/regression/xlsx_files/chart_data_labels27.xlsx +0 -0
- data/test/regression/xlsx_files/chart_data_labels28.xlsx +0 -0
- data/test/regression/xlsx_files/chart_data_labels29.xlsx +0 -0
- data/test/regression/xlsx_files/chart_data_labels30.xlsx +0 -0
- data/test/regression/xlsx_files/chart_data_labels31.xlsx +0 -0
- data/test/regression/xlsx_files/chart_data_labels32.xlsx +0 -0
- data/test/regression/xlsx_files/chart_data_labels33.xlsx +0 -0
- data/test/regression/xlsx_files/chart_data_labels34.xlsx +0 -0
- data/test/regression/xlsx_files/chart_data_labels35.xlsx +0 -0
- data/test/regression/xlsx_files/chart_data_labels36.xlsx +0 -0
- data/test/regression/xlsx_files/chart_data_labels37.xlsx +0 -0
- data/test/regression/xlsx_files/chart_data_labels38.xlsx +0 -0
- data/test/regression/xlsx_files/chart_data_labels39.xlsx +0 -0
- data/test/regression/xlsx_files/chart_data_labels40.xlsx +0 -0
- data/test/regression/xlsx_files/chart_data_labels41.xlsx +0 -0
- data/test/regression/xlsx_files/chart_data_labels42.xlsx +0 -0
- data/test/regression/xlsx_files/chart_data_labels43.xlsx +0 -0
- data/test/regression/xlsx_files/chart_data_labels44.xlsx +0 -0
- data/test/regression/xlsx_files/chart_data_labels45.xlsx +0 -0
- data/test/regression/xlsx_files/chart_data_labels46.xlsx +0 -0
- data/test/regression/xlsx_files/chart_data_labels47.xlsx +0 -0
- data/test/regression/xlsx_files/chart_data_labels48.xlsx +0 -0
- data/test/regression/xlsx_files/chart_data_labels49.xlsx +0 -0
- data/test/regression/xlsx_files/chart_data_labels50.xlsx +0 -0
- data/test/regression/xlsx_files/chart_doughnut07.xlsx +0 -0
- data/test/regression/xlsx_files/chart_font09.xlsx +0 -0
- data/test/regression/xlsx_files/chart_format21.xlsx +0 -0
- data/test/regression/xlsx_files/chart_format22.xlsx +0 -0
- data/test/regression/xlsx_files/chart_format23.xlsx +0 -0
- data/test/regression/xlsx_files/chart_format24.xlsx +0 -0
- data/test/regression/xlsx_files/chart_format25.xlsx +0 -0
- data/test/regression/xlsx_files/chart_format26.xlsx +0 -0
- data/test/regression/xlsx_files/chart_format27.xlsx +0 -0
- data/test/regression/xlsx_files/chart_format28.xlsx +0 -0
- data/test/regression/xlsx_files/chart_format29.xlsx +0 -0
- data/test/regression/xlsx_files/chart_format30.xlsx +0 -0
- data/test/regression/xlsx_files/chart_format31.xlsx +0 -0
- data/test/regression/xlsx_files/chart_legend03.xlsx +0 -0
- data/test/regression/xlsx_files/chart_legend04.xlsx +0 -0
- data/test/regression/xlsx_files/chart_legend05.xlsx +0 -0
- data/test/regression/xlsx_files/chart_legend06.xlsx +0 -0
- data/test/regression/xlsx_files/chart_legend07.xlsx +0 -0
- data/test/regression/xlsx_files/chart_line05.xlsx +0 -0
- data/test/regression/xlsx_files/chart_line06.xlsx +0 -0
- data/test/regression/xlsx_files/chart_pattern01.xlsx +0 -0
- data/test/regression/xlsx_files/chart_pattern02.xlsx +0 -0
- data/test/regression/xlsx_files/chart_pattern03.xlsx +0 -0
- data/test/regression/xlsx_files/chart_pattern04.xlsx +0 -0
- data/test/regression/xlsx_files/chart_pattern05.xlsx +0 -0
- data/test/regression/xlsx_files/chart_pattern06.xlsx +0 -0
- data/test/regression/xlsx_files/chart_pattern07.xlsx +0 -0
- data/test/regression/xlsx_files/chart_pattern08.xlsx +0 -0
- data/test/regression/xlsx_files/chart_pattern09.xlsx +0 -0
- data/test/regression/xlsx_files/chart_pattern10.xlsx +0 -0
- data/test/regression/xlsx_files/chart_table03.xlsx +0 -0
- data/test/regression/xlsx_files/comment13.xlsx +0 -0
- data/test/regression/xlsx_files/comment14.xlsx +0 -0
- data/test/regression/xlsx_files/comment15.xlsx +0 -0
- data/test/regression/xlsx_files/comment16.xlsx +0 -0
- data/test/regression/xlsx_files/cond_format14.xlsx +0 -0
- data/test/regression/xlsx_files/cond_format15.xlsx +0 -0
- data/test/regression/xlsx_files/cond_format16.xlsx +0 -0
- data/test/regression/xlsx_files/cond_format17.xlsx +0 -0
- data/test/regression/xlsx_files/cond_format18.xlsx +0 -0
- data/test/regression/xlsx_files/cond_format19.xlsx +0 -0
- data/test/regression/xlsx_files/cond_format20.xlsx +0 -0
- data/test/regression/xlsx_files/data_validation08.xlsx +0 -0
- data/test/regression/xlsx_files/date_1904_01.xlsx +0 -0
- data/test/regression/xlsx_files/default_row05.xlsx +0 -0
- data/test/regression/xlsx_files/dynamic_array01.xlsx +0 -0
- data/test/regression/xlsx_files/format13.xlsx +0 -0
- data/test/regression/xlsx_files/format14.xlsx +0 -0
- data/test/regression/xlsx_files/format15.xlsx +0 -0
- data/test/regression/xlsx_files/format16.xlsx +0 -0
- data/test/regression/xlsx_files/format17.xlsx +0 -0
- data/test/regression/xlsx_files/header04.xlsx +0 -0
- data/test/regression/xlsx_files/header_image15.xlsx +0 -0
- data/test/regression/xlsx_files/header_image16.xlsx +0 -0
- data/test/regression/xlsx_files/header_image17.xlsx +0 -0
- data/test/regression/xlsx_files/header_image18.xlsx +0 -0
- data/test/regression/xlsx_files/header_image19.xlsx +0 -0
- data/test/regression/xlsx_files/hyperlink22.xlsx +0 -0
- data/test/regression/xlsx_files/hyperlink23.xlsx +0 -0
- data/test/regression/xlsx_files/hyperlink24.xlsx +0 -0
- data/test/regression/xlsx_files/hyperlink25.xlsx +0 -0
- data/test/regression/xlsx_files/hyperlink26.xlsx +0 -0
- data/test/regression/xlsx_files/hyperlink27.xlsx +0 -0
- data/test/regression/xlsx_files/hyperlink28.xlsx +0 -0
- data/test/regression/xlsx_files/hyperlink29.xlsx +0 -0
- data/test/regression/xlsx_files/hyperlink30.xlsx +0 -0
- data/test/regression/xlsx_files/hyperlink31.xlsx +0 -0
- data/test/regression/xlsx_files/hyperlink32.xlsx +0 -0
- data/test/regression/xlsx_files/hyperlink33.xlsx +0 -0
- data/test/regression/xlsx_files/hyperlink34.xlsx +0 -0
- data/test/regression/xlsx_files/hyperlink35.xlsx +0 -0
- data/test/regression/xlsx_files/hyperlink36.xlsx +0 -0
- data/test/regression/xlsx_files/hyperlink37.xlsx +0 -0
- data/test/regression/xlsx_files/hyperlink38.xlsx +0 -0
- data/test/regression/xlsx_files/hyperlink39.xlsx +0 -0
- data/test/regression/xlsx_files/hyperlink40.xlsx +0 -0
- data/test/regression/xlsx_files/hyperlink41.xlsx +0 -0
- data/test/regression/xlsx_files/hyperlink42.xlsx +0 -0
- data/test/regression/xlsx_files/hyperlink43.xlsx +0 -0
- data/test/regression/xlsx_files/hyperlink44.xlsx +0 -0
- data/test/regression/xlsx_files/hyperlink45.xlsx +0 -0
- data/test/regression/xlsx_files/hyperlink46.xlsx +0 -0
- data/test/regression/xlsx_files/hyperlink47.xlsx +0 -0
- data/test/regression/xlsx_files/hyperlink48.xlsx +0 -0
- data/test/regression/xlsx_files/hyperlink49.xlsx +0 -0
- data/test/regression/xlsx_files/hyperlink50.xlsx +0 -0
- data/test/regression/xlsx_files/hyperlink51.xlsx +0 -0
- data/test/regression/xlsx_files/ignore_error01.xlsx +0 -0
- data/test/regression/xlsx_files/ignore_error02.xlsx +0 -0
- data/test/regression/xlsx_files/ignore_error03.xlsx +0 -0
- data/test/regression/xlsx_files/ignore_error04.xlsx +0 -0
- data/test/regression/xlsx_files/ignore_error05.xlsx +0 -0
- data/test/regression/xlsx_files/ignore_error06.xlsx +0 -0
- data/test/regression/xlsx_files/image06.xlsx +0 -0
- data/test/regression/xlsx_files/image28.xlsx +0 -0
- data/test/regression/xlsx_files/image29.xlsx +0 -0
- data/test/regression/xlsx_files/image30.xlsx +0 -0
- data/test/regression/xlsx_files/image31.xlsx +0 -0
- data/test/regression/xlsx_files/image32.xlsx +0 -0
- data/test/regression/xlsx_files/image33.xlsx +0 -0
- data/test/regression/xlsx_files/image35.xlsx +0 -0
- data/test/regression/xlsx_files/image36.xlsx +0 -0
- data/test/regression/xlsx_files/image44.xlsx +0 -0
- data/test/regression/xlsx_files/image45.xlsx +0 -0
- data/test/regression/xlsx_files/image46.xlsx +0 -0
- data/test/regression/xlsx_files/image47.xlsx +0 -0
- data/test/regression/xlsx_files/image48.xlsx +0 -0
- data/test/regression/xlsx_files/image49.xlsx +0 -0
- data/test/regression/xlsx_files/image50.xlsx +0 -0
- data/test/regression/xlsx_files/image51.xlsx +0 -0
- data/test/regression/xlsx_files/image52.xlsx +0 -0
- data/test/regression/xlsx_files/image53.xlsx +0 -0
- data/test/regression/xlsx_files/image54.xlsx +0 -0
- data/test/regression/xlsx_files/image55.xlsx +0 -0
- data/test/regression/xlsx_files/image56.xlsx +0 -0
- data/test/regression/xlsx_files/image57.xlsx +0 -0
- data/test/regression/xlsx_files/object_position01.xlsx +0 -0
- data/test/regression/xlsx_files/object_position02.xlsx +0 -0
- data/test/regression/xlsx_files/object_position03.xlsx +0 -0
- data/test/regression/xlsx_files/object_position04.xlsx +0 -0
- data/test/regression/xlsx_files/object_position06.xlsx +0 -0
- data/test/regression/xlsx_files/object_position07.xlsx +0 -0
- data/test/regression/xlsx_files/object_position08.xlsx +0 -0
- data/test/regression/xlsx_files/object_position09.xlsx +0 -0
- data/test/regression/xlsx_files/object_position10.xlsx +0 -0
- data/test/regression/xlsx_files/object_position12.xlsx +0 -0
- data/test/regression/xlsx_files/object_position13.xlsx +0 -0
- data/test/regression/xlsx_files/object_position14.xlsx +0 -0
- data/test/regression/xlsx_files/object_position15.xlsx +0 -0
- data/test/regression/xlsx_files/object_position16.xlsx +0 -0
- data/test/regression/xlsx_files/object_position17.xlsx +0 -0
- data/test/regression/xlsx_files/object_position18.xlsx +0 -0
- data/test/regression/xlsx_files/object_position19.xlsx +0 -0
- data/test/regression/xlsx_files/object_position20.xlsx +0 -0
- data/test/regression/xlsx_files/properties02.xlsx +0 -0
- data/test/regression/xlsx_files/properties03.xlsx +0 -0
- data/test/regression/xlsx_files/properties04.xlsx +0 -0
- data/test/regression/xlsx_files/properties05.xlsx +0 -0
- data/test/regression/xlsx_files/protect04.xlsx +0 -0
- data/test/regression/xlsx_files/protect05.xlsx +0 -0
- data/test/regression/xlsx_files/protect06.xlsx +0 -0
- data/test/regression/xlsx_files/protect07.xlsx +0 -0
- data/test/regression/xlsx_files/set_row01.xlsx +0 -0
- data/test/regression/xlsx_files/set_row03.xlsx +0 -0
- data/test/regression/xlsx_files/table18.xlsx +0 -0
- data/test/regression/xlsx_files/table19.xlsx +0 -0
- data/test/regression/xlsx_files/table21.xlsx +0 -0
- data/test/regression/xlsx_files/table22.xlsx +0 -0
- data/test/regression/xlsx_files/table23.xlsx +0 -0
- data/test/regression/xlsx_files/table24.xlsx +0 -0
- data/test/regression/xlsx_files/table25.xlsx +0 -0
- data/test/regression/xlsx_files/table26.xlsx +0 -0
- data/test/regression/xlsx_files/types02.xlsx +0 -0
- data/test/regression/xlsx_files/types08.xlsx +0 -0
- data/test/regression/xlsx_files/update_range_format_with_params.xlsx +0 -0
- data/test/regression/xlsx_files/utf8_11.xlsx +0 -0
- data/test/test_delete_files.rb +3 -3
- data/test/test_example_match.rb +1342 -781
- data/test/test_option_hash_for_workbook.rb +1 -1
- data/test/test_xml_writer_simple.rb +1 -1
- data/test/utility/test_range.rb +20 -0
- data/test/workbook/test_check_sheetname.rb +51 -0
- data/test/workbook/test_define_name.rb +1 -1
- data/test/workbook/test_get_chart_range.rb +3 -5
- data/test/workbook/test_sort_defined_names.rb +1 -1
- data/test/workbook/test_workbook_01.rb +1 -1
- data/test/workbook/test_workbook_02.rb +1 -1
- data/test/workbook/test_workbook_03.rb +1 -1
- data/test/workbook/test_worksheet_by_name.rb +35 -0
- data/test/workbook/test_write_calc_pr.rb +1 -1
- data/test/workbook/test_write_defined_name.rb +1 -1
- data/test/workbook/test_write_defined_names.rb +1 -1
- data/test/workbook/test_write_workbook_view.rb +117 -0
- data/test/worksheet/test_calculate_spans.rb +1 -1
- data/test/worksheet/test_cond_format_01.rb +1 -1
- data/test/worksheet/test_cond_format_02.rb +1 -1
- data/test/worksheet/test_cond_format_03.rb +1 -1
- data/test/worksheet/test_cond_format_04.rb +1 -1
- data/test/worksheet/test_cond_format_05.rb +1 -1
- data/test/worksheet/test_cond_format_06.rb +1 -1
- data/test/worksheet/test_cond_format_07.rb +1 -1
- data/test/worksheet/test_cond_format_08.rb +1 -1
- data/test/worksheet/test_cond_format_09.rb +1 -1
- data/test/worksheet/test_cond_format_10.rb +1 -1
- data/test/worksheet/test_cond_format_11.rb +1 -1
- data/test/worksheet/test_cond_format_12.rb +1 -1
- data/test/worksheet/test_cond_format_13.rb +1 -1
- data/test/worksheet/test_cond_format_14.rb +1 -1
- data/test/worksheet/test_cond_format_15.rb +1 -1
- data/test/worksheet/test_cond_format_16.rb +1 -1
- data/test/worksheet/test_cond_format_17.rb +1 -1
- data/test/worksheet/test_cond_format_18.rb +1 -1
- data/test/worksheet/test_cond_format_19.rb +1 -1
- data/test/worksheet/test_cond_format_20.rb +1 -1
- data/test/worksheet/test_cond_format_21.rb +90 -0
- data/test/worksheet/test_cond_format_22.rb +266 -0
- data/test/worksheet/test_cond_format_23.rb +242 -0
- data/test/worksheet/test_cond_format_24.rb +303 -0
- data/test/worksheet/test_convert_date_time_01.rb +1 -1
- data/test/worksheet/test_convert_date_time_02.rb +1 -1
- data/test/worksheet/test_convert_date_time_03.rb +1 -1
- data/test/worksheet/test_convert_date_time_04.rb +1 -1
- data/test/worksheet/test_data_bar_01.rb +53 -0
- data/test/worksheet/test_data_bar_02.rb +79 -0
- data/test/worksheet/test_data_bar_03.rb +147 -0
- data/test/worksheet/test_data_bar_04.rb +145 -0
- data/test/worksheet/test_data_bar_05.rb +147 -0
- data/test/worksheet/test_data_bar_06.rb +145 -0
- data/test/worksheet/test_data_bar_07.rb +146 -0
- data/test/worksheet/test_data_bar_08.rb +54 -0
- data/test/worksheet/test_data_bar_09.rb +80 -0
- data/test/worksheet/test_data_bar_10.rb +165 -0
- data/test/worksheet/test_data_bar_11.rb +167 -0
- data/test/worksheet/test_data_bar_12.rb +104 -0
- data/test/worksheet/test_extract_filter_tokens.rb +1 -1
- data/test/worksheet/test_parse_filter_expression.rb +1 -1
- data/test/worksheet/test_pixels_to_row_col.rb +46 -0
- data/test/worksheet/test_position_object.rb +1 -1
- data/test/worksheet/test_repeat_formula.rb +1 -1
- data/test/worksheet/test_sparkline_01.rb +1 -1
- data/test/worksheet/test_sparkline_02.rb +1 -1
- data/test/worksheet/test_sparkline_03.rb +1 -1
- data/test/worksheet/test_sparkline_04.rb +1 -1
- data/test/worksheet/test_sparkline_05.rb +1 -1
- data/test/worksheet/test_sparkline_06.rb +1 -1
- data/test/worksheet/test_sparkline_07.rb +1 -1
- data/test/worksheet/test_sparkline_08.rb +1 -1
- data/test/worksheet/test_sparkline_09.rb +1 -1
- data/test/worksheet/test_sparkline_10.rb +1 -1
- data/test/worksheet/test_sparkline_11.rb +1 -1
- data/test/worksheet/test_sparkline_12.rb +94 -0
- data/test/worksheet/test_update_format_methods.rb +91 -0
- data/test/worksheet/test_worksheet_01.rb +1 -1
- data/test/worksheet/test_worksheet_02.rb +1 -1
- data/test/worksheet/test_worksheet_03.rb +1 -1
- data/test/worksheet/test_worksheet_04.rb +1 -1
- data/test/worksheet/test_write_array_formula_01.rb +1 -8
- data/test/worksheet/test_write_autofilter.rb +1 -1
- data/test/worksheet/test_write_brk.rb +1 -1
- data/test/worksheet/test_write_cell.rb +1 -1
- data/test/worksheet/test_write_cell_value.rb +1 -1
- data/test/worksheet/test_write_col_breaks.rb +1 -1
- data/test/worksheet/test_write_col_info.rb +1 -1
- data/test/worksheet/test_write_conditional_formatting.rb +1 -1
- data/test/worksheet/test_write_custom_filter.rb +1 -1
- data/test/worksheet/test_write_custom_filters.rb +1 -1
- data/test/worksheet/test_write_data_validation_01.rb +1 -1
- data/test/worksheet/test_write_data_validation_02.rb +59 -2
- data/test/worksheet/test_write_dimension.rb +1 -1
- data/test/worksheet/test_write_filter.rb +1 -1
- data/test/worksheet/test_write_filter_column.rb +1 -1
- data/test/worksheet/test_write_filters.rb +1 -1
- data/test/worksheet/test_write_formula_does_not_change_formula_string.rb +1 -1
- data/test/worksheet/test_write_header_footer.rb +1 -1
- data/test/worksheet/test_write_hyperlink.rb +1 -8
- data/test/worksheet/test_write_legacy_drawing.rb +1 -1
- data/test/worksheet/test_write_merge_cell.rb +1 -1
- data/test/worksheet/test_write_merge_cells.rb +1 -1
- data/test/worksheet/test_write_methods.rb +68 -177
- data/test/worksheet/test_write_page_margins.rb +1 -1
- data/test/worksheet/test_write_page_set_up_pr.rb +1 -1
- data/test/worksheet/test_write_page_setup.rb +1 -1
- data/test/worksheet/test_write_pane.rb +1 -1
- data/test/worksheet/test_write_phonetic_pr.rb +1 -1
- data/test/worksheet/test_write_print_options.rb +1 -1
- data/test/worksheet/test_write_row_breaks.rb +1 -1
- data/test/worksheet/test_write_row_element.rb +1 -1
- data/test/worksheet/test_write_selection.rb +1 -1
- data/test/worksheet/test_write_sheet_calc_pr.rb +1 -1
- data/test/worksheet/test_write_sheet_data.rb +1 -1
- data/test/worksheet/test_write_sheet_format_pr.rb +1 -1
- data/test/worksheet/test_write_sheet_pr.rb +1 -1
- data/test/worksheet/test_write_sheet_protection.rb +1 -1
- data/test/worksheet/test_write_sheet_view.rb +20 -2
- data/test/worksheet/test_write_sheet_view1.rb +1 -1
- data/test/worksheet/test_write_sheet_view2.rb +1 -1
- data/test/worksheet/test_write_sheet_view3.rb +1 -1
- data/test/worksheet/test_write_sheet_view4.rb +1 -1
- data/test/worksheet/test_write_sheet_view5.rb +1 -1
- data/test/worksheet/test_write_sheet_view6.rb +1 -1
- data/test/worksheet/test_write_sheet_view7.rb +1 -1
- data/test/worksheet/test_write_sheet_view8.rb +1 -1
- data/test/worksheet/test_write_sheet_view9.rb +1 -1
- data/test/worksheet/test_write_tab_color.rb +1 -1
- data/test/worksheet/test_write_worksheet_attributes.rb +1 -1
- data/write_xlsx.gemspec +4 -3
- metadata +937 -18
- data/test/package/comments/test_write_text_t.rb +0 -44
- data/test/test_col_name.rb +0 -13
- data/test/workbook/test_workbook_new.rb +0 -18
- data/test/worksheet/test_write_multiline_string_with_url.rb +0 -30
- data/test/worksheet/test_write_url.rb +0 -19
data/lib/write_xlsx/chart.rb
CHANGED
@@ -1,6 +1,7 @@
|
|
1
1
|
# -*- coding: utf-8 -*-
|
2
2
|
require 'write_xlsx/package/xml_writer_simple'
|
3
3
|
require 'write_xlsx/gradient'
|
4
|
+
require 'write_xlsx/chart/legend'
|
4
5
|
require 'write_xlsx/utility'
|
5
6
|
require 'write_xlsx/chart/axis'
|
6
7
|
require 'write_xlsx/chart/caption'
|
@@ -10,7 +11,7 @@ module Writexlsx
|
|
10
11
|
class Table
|
11
12
|
include Writexlsx::Utility
|
12
13
|
|
13
|
-
attr_reader :horizontal, :vertical, :outline, :show_keys
|
14
|
+
attr_reader :horizontal, :vertical, :outline, :show_keys, :font
|
14
15
|
|
15
16
|
def initialize(params = {})
|
16
17
|
@horizontal, @vertical, @outline, @show_keys = true, true, true, false
|
@@ -18,14 +19,22 @@ module Writexlsx
|
|
18
19
|
@vertical = params[:vertical] if params.has_key?(:vertical)
|
19
20
|
@outline = params[:outline] if params.has_key?(:outline)
|
20
21
|
@show_keys = params[:show_keys] if params.has_key?(:show_keys)
|
22
|
+
@font = convert_font_args(params[:font])
|
23
|
+
end
|
24
|
+
|
25
|
+
def palette=(palette)
|
26
|
+
@palette = palette
|
21
27
|
end
|
22
28
|
|
23
29
|
def write_d_table(writer)
|
24
|
-
writer
|
25
|
-
|
26
|
-
writer.empty_tag('c:
|
27
|
-
writer.empty_tag('c:
|
28
|
-
writer.empty_tag('c:
|
30
|
+
@writer = writer
|
31
|
+
@writer.tag_elements('c:dTable') do
|
32
|
+
@writer.empty_tag('c:showHorzBorder', attributes) if ptrue?(horizontal)
|
33
|
+
@writer.empty_tag('c:showVertBorder', attributes) if ptrue?(vertical)
|
34
|
+
@writer.empty_tag('c:showOutline', attributes) if ptrue?(outline)
|
35
|
+
@writer.empty_tag('c:showKeys', attributes) if ptrue?(show_keys)
|
36
|
+
# Write the table font.
|
37
|
+
write_tx_pr(font) if ptrue?(font)
|
29
38
|
end
|
30
39
|
end
|
31
40
|
|
@@ -40,7 +49,7 @@ module Writexlsx
|
|
40
49
|
include Writexlsx::Utility
|
41
50
|
include Writexlsx::Gradient
|
42
51
|
|
43
|
-
attr_reader :line, :fill, :gradient, :layout
|
52
|
+
attr_reader :line, :fill, :pattern, :gradient, :layout
|
44
53
|
|
45
54
|
def initialize(params = {})
|
46
55
|
@layout = layout_properties(params[:layout])
|
@@ -51,6 +60,9 @@ module Writexlsx
|
|
51
60
|
# Set the line properties for the chartarea.
|
52
61
|
@line = border ? line_properties(border) : line_properties(params[:line])
|
53
62
|
|
63
|
+
# Set the pattern properties for the series.
|
64
|
+
@pattern = pattern_properties(params[:pattern])
|
65
|
+
|
54
66
|
# Set the gradient fill properties for the series.
|
55
67
|
@gradient = gradient_properties(params[:gradient])
|
56
68
|
|
@@ -58,9 +70,16 @@ module Writexlsx
|
|
58
70
|
fill = params[:color] ? { :color => params[:color] } : params[:fill]
|
59
71
|
@fill = fill_properties(fill)
|
60
72
|
|
61
|
-
|
73
|
+
# Pattern fill overrides solid fill.
|
74
|
+
if ptrue?(@pattern)
|
62
75
|
@fill = nil
|
63
76
|
end
|
77
|
+
|
78
|
+
# Gradient fill overrides solid and pattern fills.
|
79
|
+
if ptrue?(@gradient)
|
80
|
+
@pattern = nil
|
81
|
+
@fill = nil
|
82
|
+
end
|
64
83
|
end
|
65
84
|
|
66
85
|
private
|
@@ -144,17 +163,18 @@ module Writexlsx
|
|
144
163
|
|
145
164
|
class Chart
|
146
165
|
include Writexlsx::Utility
|
166
|
+
include Writexlsx::Gradient
|
147
167
|
|
148
|
-
attr_accessor :id, :name
|
149
|
-
attr_writer :index, :palette, :protection
|
150
|
-
attr_reader :embedded, :formula_ids, :formula_data
|
151
|
-
attr_reader :x_scale, :y_scale, :x_offset, :y_offset
|
152
|
-
attr_reader :width, :height
|
168
|
+
attr_accessor :id, :name # :nodoc:
|
169
|
+
attr_writer :index, :palette, :protection # :nodoc:
|
170
|
+
attr_reader :embedded, :formula_ids, :formula_data # :nodoc:
|
171
|
+
attr_reader :x_scale, :y_scale, :x_offset, :y_offset # :nodoc:
|
172
|
+
attr_reader :width, :height # :nodoc:
|
153
173
|
attr_reader :label_positions, :label_position_default, :combined # :nodoc:
|
154
|
-
attr_writer :date_category, :already_inserted
|
155
|
-
attr_writer :series_index
|
156
|
-
attr_writer :writer
|
157
|
-
attr_reader :x2_axis, :y2_axis, :axis2_ids
|
174
|
+
attr_writer :date_category, :already_inserted # :nodoc:
|
175
|
+
attr_writer :series_index # :nodoc:
|
176
|
+
attr_writer :writer # :nodoc:
|
177
|
+
attr_reader :x2_axis, :y2_axis, :axis2_ids # :nodoc:
|
158
178
|
|
159
179
|
#
|
160
180
|
# Factory method for returning chart objects based on their class type.
|
@@ -254,6 +274,10 @@ module Writexlsx
|
|
254
274
|
raise "Must specify ':categories' in add_series for this chart type"
|
255
275
|
end
|
256
276
|
|
277
|
+
if @series.size == 255
|
278
|
+
raise "The maximum number of series that can be added to an Excel Chart is 255."
|
279
|
+
end
|
280
|
+
|
257
281
|
@series << Series.new(self, params)
|
258
282
|
|
259
283
|
# Set the secondary axis properties.
|
@@ -330,16 +354,8 @@ module Writexlsx
|
|
330
354
|
# Set the properties of the chart legend.
|
331
355
|
#
|
332
356
|
def set_legend(params)
|
333
|
-
|
334
|
-
|
335
|
-
else
|
336
|
-
@legend_position = params[:position] || 'right'
|
337
|
-
end
|
338
|
-
@legend_delete_series = params[:delete_series]
|
339
|
-
@legend_font = convert_font_args(params[:font])
|
340
|
-
|
341
|
-
# Set the legend layout.
|
342
|
-
@legend_layout = layout_properties(params[:layout])
|
357
|
+
# Convert the user default properties to internal properties.
|
358
|
+
legend_properties(params)
|
343
359
|
end
|
344
360
|
|
345
361
|
#
|
@@ -407,6 +423,7 @@ module Writexlsx
|
|
407
423
|
#
|
408
424
|
def set_table(params = {})
|
409
425
|
@table = Table.new(params)
|
426
|
+
@table.palette = @palette
|
410
427
|
end
|
411
428
|
|
412
429
|
#
|
@@ -507,39 +524,6 @@ module Writexlsx
|
|
507
524
|
end
|
508
525
|
end
|
509
526
|
|
510
|
-
#
|
511
|
-
# Convert user defined font values into private hash values.
|
512
|
-
#
|
513
|
-
def convert_font_args(params)
|
514
|
-
return unless params
|
515
|
-
font = params_to_font(params)
|
516
|
-
|
517
|
-
# Convert font size units.
|
518
|
-
font[:_size] *= 100 if font[:_size] && font[:_size] != 0
|
519
|
-
|
520
|
-
# Convert rotation into 60,000ths of a degree.
|
521
|
-
if ptrue?(font[:_rotation])
|
522
|
-
font[:_rotation] = 60_000 * font[:_rotation].to_i
|
523
|
-
end
|
524
|
-
|
525
|
-
font
|
526
|
-
end
|
527
|
-
|
528
|
-
def params_to_font(params)
|
529
|
-
{
|
530
|
-
:_name => params[:name],
|
531
|
-
:_color => params[:color],
|
532
|
-
:_size => params[:size],
|
533
|
-
:_bold => params[:bold],
|
534
|
-
:_italic => params[:italic],
|
535
|
-
:_underline => params[:underline],
|
536
|
-
:_pitch_family => params[:pitch_family],
|
537
|
-
:_charset => params[:charset],
|
538
|
-
:_baseline => params[:baseline] || 0,
|
539
|
-
:_rotation => params[:rotation]
|
540
|
-
}
|
541
|
-
end
|
542
|
-
|
543
527
|
#
|
544
528
|
# Switch name and name_formula parameters if required.
|
545
529
|
#
|
@@ -621,7 +605,7 @@ module Writexlsx
|
|
621
605
|
@y_scale = 1
|
622
606
|
@x_offset = 0
|
623
607
|
@y_offset = 0
|
624
|
-
@
|
608
|
+
@legend = Legend.new
|
625
609
|
@smooth_allowed = 0
|
626
610
|
@cross_between = 'between'
|
627
611
|
@date_category = false
|
@@ -662,20 +646,6 @@ module Writexlsx
|
|
662
646
|
'num'
|
663
647
|
end
|
664
648
|
|
665
|
-
#
|
666
|
-
# Convert the user specified colour index or string to a rgb colour.
|
667
|
-
#
|
668
|
-
def color(color_code) # :nodoc:
|
669
|
-
if color_code and color_code =~ /^#[0-9a-fA-F]{6}$/
|
670
|
-
# Convert a HTML style #RRGGBB color.
|
671
|
-
color_code.sub(/^#/, '').upcase
|
672
|
-
else
|
673
|
-
index = Format.color(color_code)
|
674
|
-
raise "Unknown color '#{color_code}' used in chart formatting." unless index
|
675
|
-
palette_color(index)
|
676
|
-
end
|
677
|
-
end
|
678
|
-
|
679
649
|
#
|
680
650
|
# Returns series which use the primary axes.
|
681
651
|
#
|
@@ -713,38 +683,6 @@ module Writexlsx
|
|
713
683
|
[id1, id2]
|
714
684
|
end
|
715
685
|
|
716
|
-
#
|
717
|
-
# Get the font style attributes from a font hash.
|
718
|
-
#
|
719
|
-
def get_font_style_attributes(font)
|
720
|
-
return [] unless font
|
721
|
-
|
722
|
-
attributes = []
|
723
|
-
attributes << ['sz', font[:_size]] if ptrue?(font[:_size])
|
724
|
-
attributes << ['b', font[:_bold]] if font[:_bold]
|
725
|
-
attributes << ['i', font[:_italic]] if font[:_italic]
|
726
|
-
attributes << ['u', 'sng'] if font[:_underline]
|
727
|
-
|
728
|
-
# Turn off baseline when testing fonts that don't have it.
|
729
|
-
if font[:_baseline] != -1
|
730
|
-
attributes << ['baseline', font[:_baseline]]
|
731
|
-
end
|
732
|
-
attributes
|
733
|
-
end
|
734
|
-
|
735
|
-
#
|
736
|
-
# Get the font latin attributes from a font hash.
|
737
|
-
#
|
738
|
-
def get_font_latin_attributes(font)
|
739
|
-
return [] unless font
|
740
|
-
|
741
|
-
attributes = []
|
742
|
-
attributes << ['typeface', font[:_name]] if ptrue?(font[:_name])
|
743
|
-
attributes << ['pitchFamily', font[:_pitch_family]] if font[:_pitch_family]
|
744
|
-
attributes << ['charset', font[:_charset]] if font[:_charset]
|
745
|
-
|
746
|
-
attributes
|
747
|
-
end
|
748
686
|
#
|
749
687
|
# Setup the default properties for a chart.
|
750
688
|
#
|
@@ -845,7 +783,7 @@ module Writexlsx
|
|
845
783
|
elsif @title.formula
|
846
784
|
write_title_formula(@title, nil, nil, @title.layout, @title.overlay)
|
847
785
|
elsif @title.name
|
848
|
-
write_title_rich(@title, nil, @title.layout, @title.overlay)
|
786
|
+
write_title_rich(@title, nil, @title.name_font, @title.layout, @title.overlay)
|
849
787
|
end
|
850
788
|
|
851
789
|
# Write the c:plotArea element.
|
@@ -1119,7 +1057,7 @@ module Writexlsx
|
|
1119
1057
|
end
|
1120
1058
|
|
1121
1059
|
def write_val_base(formula, data_id, tag) # :nodoc:
|
1122
|
-
data
|
1060
|
+
data = @formula_data[data_id]
|
1123
1061
|
|
1124
1062
|
@writer.tag_elements(tag) do
|
1125
1063
|
# Unlike Cat axes data should only be numeric.
|
@@ -1240,8 +1178,8 @@ module Writexlsx
|
|
1240
1178
|
return unless axis_ids
|
1241
1179
|
return if axis_ids.empty?
|
1242
1180
|
|
1243
|
-
position
|
1244
|
-
|
1181
|
+
position = @cat_axis_position
|
1182
|
+
is_y_axis = @horiz_cat_axis
|
1245
1183
|
|
1246
1184
|
# Overwrite the default axis position with a user supplied value.
|
1247
1185
|
position = x_axis.position || position
|
@@ -1264,9 +1202,9 @@ module Writexlsx
|
|
1264
1202
|
|
1265
1203
|
# Write the axis title elements.
|
1266
1204
|
if x_axis.formula
|
1267
|
-
write_title_formula(x_axis,
|
1205
|
+
write_title_formula(x_axis, is_y_axis, @x_axis, x_axis.layout)
|
1268
1206
|
elsif x_axis.name
|
1269
|
-
write_title_rich(x_axis,
|
1207
|
+
write_title_rich(x_axis, is_y_axis, x_axis.name_font, x_axis.layout)
|
1270
1208
|
end
|
1271
1209
|
|
1272
1210
|
# Write the c:numFmt element.
|
@@ -1275,6 +1213,9 @@ module Writexlsx
|
|
1275
1213
|
# Write the c:majorTickMark element.
|
1276
1214
|
write_major_tick_mark(x_axis.major_tick_mark)
|
1277
1215
|
|
1216
|
+
# Write the c:minorTickMark element.
|
1217
|
+
write_minor_tick_mark(x_axis.minor_tick_mark)
|
1218
|
+
|
1278
1219
|
# Write the c:tickLblPos element.
|
1279
1220
|
write_tick_label_pos(x_axis.label_position)
|
1280
1221
|
|
@@ -1293,11 +1234,13 @@ module Writexlsx
|
|
1293
1234
|
# Write the c:auto element.
|
1294
1235
|
write_auto(1) unless x_axis.text_axis
|
1295
1236
|
# Write the c:labelAlign element.
|
1296
|
-
write_label_align(
|
1237
|
+
write_label_align(x_axis.label_align)
|
1297
1238
|
# Write the c:labelOffset element.
|
1298
1239
|
write_label_offset(100)
|
1299
1240
|
# Write the c:tickLblSkip element.
|
1300
1241
|
write_tick_lbl_skip(x_axis.interval_unit)
|
1242
|
+
# Write the c:tickMarkSkip element.
|
1243
|
+
write_tick_mark_skip(x_axis.interval_tick)
|
1301
1244
|
end
|
1302
1245
|
end
|
1303
1246
|
|
@@ -1338,7 +1281,7 @@ module Writexlsx
|
|
1338
1281
|
if y_axis.formula
|
1339
1282
|
write_title_formula(y_axis, @horiz_val_axis, nil, y_axis.layout)
|
1340
1283
|
elsif y_axis.name
|
1341
|
-
write_title_rich(y_axis, @horiz_val_axis, y_axis.layout)
|
1284
|
+
write_title_rich(y_axis, @horiz_val_axis, y_axis.name_font, y_axis.layout)
|
1342
1285
|
end
|
1343
1286
|
|
1344
1287
|
# Write the c:numberFormat element.
|
@@ -1347,6 +1290,9 @@ module Writexlsx
|
|
1347
1290
|
# Write the c:majorTickMark element.
|
1348
1291
|
write_major_tick_mark(y_axis.major_tick_mark)
|
1349
1292
|
|
1293
|
+
# Write the c:minorTickMark element.
|
1294
|
+
write_minor_tick_mark(y_axis.minor_tick_mark)
|
1295
|
+
|
1350
1296
|
# Write the c:tickLblPos element.
|
1351
1297
|
write_tick_label_pos(y_axis.label_position)
|
1352
1298
|
|
@@ -1410,7 +1356,7 @@ module Writexlsx
|
|
1410
1356
|
if x_axis.formula
|
1411
1357
|
write_title_formula(x_axis, nil, nil, x_axis.layout)
|
1412
1358
|
elsif x_axis.name
|
1413
|
-
write_title_rich(x_axis, nil, x_axis.layout)
|
1359
|
+
write_title_rich(x_axis, nil, x_axis.name_font, x_axis.layout)
|
1414
1360
|
end
|
1415
1361
|
# Write the c:numFmt element.
|
1416
1362
|
write_number_format(x_axis)
|
@@ -1436,6 +1382,8 @@ module Writexlsx
|
|
1436
1382
|
write_label_offset(100)
|
1437
1383
|
# Write the c:tickLblSkip element.
|
1438
1384
|
write_tick_lbl_skip(x_axis.interval_unit)
|
1385
|
+
# Write the c:tickMarkSkip element.
|
1386
|
+
write_tick_mark_skip(x_axis.interval_tick)
|
1439
1387
|
# Write the c:majorUnit element.
|
1440
1388
|
write_c_major_unit(x_axis.major_unit)
|
1441
1389
|
# Write the c:majorTimeUnit element.
|
@@ -1449,7 +1397,7 @@ module Writexlsx
|
|
1449
1397
|
|
1450
1398
|
def write_crossing(crossing)
|
1451
1399
|
# Note, the category crossing comes from the value axis.
|
1452
|
-
if
|
1400
|
+
if [nil, 'max', 'min'].include?(crossing)
|
1453
1401
|
# Write the c:crosses element.
|
1454
1402
|
write_crosses(crossing)
|
1455
1403
|
else
|
@@ -1460,11 +1408,11 @@ module Writexlsx
|
|
1460
1408
|
|
1461
1409
|
def write_scaling_with_param(param)
|
1462
1410
|
write_scaling(
|
1463
|
-
|
1464
|
-
|
1465
|
-
|
1466
|
-
|
1467
|
-
|
1411
|
+
param.reverse,
|
1412
|
+
param.min,
|
1413
|
+
param.max,
|
1414
|
+
param.log_base
|
1415
|
+
)
|
1468
1416
|
end
|
1469
1417
|
#
|
1470
1418
|
# Write the <c:scaling> element.
|
@@ -1495,7 +1443,7 @@ module Writexlsx
|
|
1495
1443
|
# Write the <c:orientation> element.
|
1496
1444
|
#
|
1497
1445
|
def write_orientation(reverse = nil) # :nodoc:
|
1498
|
-
val
|
1446
|
+
val = ptrue?(reverse) ? 'maxMin' : 'minMax'
|
1499
1447
|
|
1500
1448
|
@writer.empty_tag('c:orientation', [ ['val', val] ])
|
1501
1449
|
end
|
@@ -1551,9 +1499,9 @@ module Writexlsx
|
|
1551
1499
|
source_linked = 0
|
1552
1500
|
|
1553
1501
|
attributes = [
|
1554
|
-
|
1555
|
-
|
1556
|
-
|
1502
|
+
['formatCode', format_code],
|
1503
|
+
['sourceLinked', source_linked]
|
1504
|
+
]
|
1557
1505
|
|
1558
1506
|
@writer.empty_tag('c:numFmt', attributes)
|
1559
1507
|
end
|
@@ -1567,6 +1515,15 @@ module Writexlsx
|
|
1567
1515
|
@writer.empty_tag('c:majorTickMark', [ ['val', val] ])
|
1568
1516
|
end
|
1569
1517
|
|
1518
|
+
#
|
1519
|
+
# Write the <c:minorTickMark> element.
|
1520
|
+
#
|
1521
|
+
def write_minor_tick_mark(val)
|
1522
|
+
return unless ptrue?(val)
|
1523
|
+
|
1524
|
+
@writer.empty_tag('c:minorTickMark', [ ['val', val] ])
|
1525
|
+
end
|
1526
|
+
|
1570
1527
|
#
|
1571
1528
|
# Write the <c:tickLblPos> element.
|
1572
1529
|
#
|
@@ -1611,6 +1568,12 @@ module Writexlsx
|
|
1611
1568
|
# Write the <c:labelAlign> element.
|
1612
1569
|
#
|
1613
1570
|
def write_label_align(val) # :nodoc:
|
1571
|
+
val ||= 'ctr'
|
1572
|
+
if val == 'right'
|
1573
|
+
val = 'r'
|
1574
|
+
elsif val == 'left'
|
1575
|
+
val = 'l'
|
1576
|
+
end
|
1614
1577
|
@writer.empty_tag('c:lblAlgn', [ ['val', val] ])
|
1615
1578
|
end
|
1616
1579
|
|
@@ -1630,6 +1593,15 @@ module Writexlsx
|
|
1630
1593
|
@writer.empty_tag('c:tickLblSkip', [ ['val', val] ])
|
1631
1594
|
end
|
1632
1595
|
|
1596
|
+
#
|
1597
|
+
# Write the <c:tickMarkSkip> element.
|
1598
|
+
#
|
1599
|
+
def write_tick_mark_skip(val) # :nodoc:
|
1600
|
+
return unless val
|
1601
|
+
|
1602
|
+
@writer.empty_tag( 'c:tickMarkSkip', [ ['val', val] ])
|
1603
|
+
end
|
1604
|
+
|
1633
1605
|
#
|
1634
1606
|
# Write the <c:majorGridlines> element.
|
1635
1607
|
#
|
@@ -1704,10 +1676,10 @@ module Writexlsx
|
|
1704
1676
|
# Write the <c:legend> element.
|
1705
1677
|
#
|
1706
1678
|
def write_legend # :nodoc:
|
1707
|
-
position = @
|
1679
|
+
position = @legend.position.sub(/^overlay_/, '')
|
1708
1680
|
return if position == 'none' || (not position_allowed.has_key?(position))
|
1709
1681
|
|
1710
|
-
@delete_series = @
|
1682
|
+
@delete_series = @legend.delete_series if @legend.delete_series.kind_of?(Array)
|
1711
1683
|
@writer.tag_elements('c:legend') do
|
1712
1684
|
# Write the c:legendPos element.
|
1713
1685
|
write_legend_pos(position_allowed[position])
|
@@ -1715,20 +1687,23 @@ module Writexlsx
|
|
1715
1687
|
# Write the c:legendEntry element.
|
1716
1688
|
@delete_series.each { |i| write_legend_entry(i) } if @delete_series
|
1717
1689
|
# Write the c:layout element.
|
1718
|
-
write_layout(@
|
1719
|
-
# Write the c:txPr element.
|
1720
|
-
write_tx_pr(nil, @legend_font) if ptrue?(@legend_font)
|
1690
|
+
write_layout(@legend.layout, 'legend')
|
1721
1691
|
# Write the c:overlay element.
|
1722
|
-
write_overlay if @
|
1692
|
+
write_overlay if @legend.position =~ /^overlay_/
|
1693
|
+
# Write the c:spPr element.
|
1694
|
+
write_sp_pr(@legend)
|
1695
|
+
# Write the c:txPr element.
|
1696
|
+
write_tx_pr(@legend.font) if ptrue?(@legend.font)
|
1723
1697
|
end
|
1724
1698
|
end
|
1725
1699
|
|
1726
1700
|
def position_allowed
|
1727
1701
|
{
|
1728
|
-
'right'
|
1729
|
-
'left'
|
1730
|
-
'top'
|
1731
|
-
'bottom'
|
1702
|
+
'right' => 'r',
|
1703
|
+
'left' => 'l',
|
1704
|
+
'top' => 't',
|
1705
|
+
'bottom' => 'b',
|
1706
|
+
'top_right' => 'tr'
|
1732
1707
|
}
|
1733
1708
|
end
|
1734
1709
|
|
@@ -1803,13 +1778,13 @@ module Writexlsx
|
|
1803
1778
|
footer = 0.3
|
1804
1779
|
|
1805
1780
|
attributes = [
|
1806
|
-
|
1807
|
-
|
1808
|
-
|
1809
|
-
|
1810
|
-
|
1811
|
-
|
1812
|
-
|
1781
|
+
['b', b],
|
1782
|
+
['l', l],
|
1783
|
+
['r', r],
|
1784
|
+
['t', t],
|
1785
|
+
['header', header],
|
1786
|
+
['footer', footer]
|
1787
|
+
]
|
1813
1788
|
|
1814
1789
|
@writer.empty_tag('c:pageMargins', attributes)
|
1815
1790
|
end
|
@@ -1833,10 +1808,10 @@ module Writexlsx
|
|
1833
1808
|
#
|
1834
1809
|
# Write the <c:title> element for a rich string.
|
1835
1810
|
#
|
1836
|
-
def write_title_rich(title,
|
1811
|
+
def write_title_rich(title, is_y_axis, font, layout, overlay = nil) # :nodoc:
|
1837
1812
|
@writer.tag_elements('c:title') do
|
1838
1813
|
# Write the c:tx element.
|
1839
|
-
write_tx_rich(title,
|
1814
|
+
write_tx_rich(title, is_y_axis, font)
|
1840
1815
|
# Write the c:layout element.
|
1841
1816
|
write_layout(layout, 'text')
|
1842
1817
|
# Write the c:overlay element.
|
@@ -1847,7 +1822,7 @@ module Writexlsx
|
|
1847
1822
|
#
|
1848
1823
|
# Write the <c:title> element for a rich string.
|
1849
1824
|
#
|
1850
|
-
def write_title_formula(title,
|
1825
|
+
def write_title_formula(title, is_y_axis = nil, axis = nil, layout = nil, overlay = nil) # :nodoc:
|
1851
1826
|
@writer.tag_elements('c:title') do
|
1852
1827
|
# Write the c:tx element.
|
1853
1828
|
write_tx_formula(title.formula, axis ? axis.data_id : title.data_id)
|
@@ -1856,15 +1831,17 @@ module Writexlsx
|
|
1856
1831
|
# Write the c:overlay element.
|
1857
1832
|
write_overlay if overlay
|
1858
1833
|
# Write the c:txPr element.
|
1859
|
-
write_tx_pr(
|
1834
|
+
write_tx_pr(axis ? axis.name_font : title.name_font, is_y_axis)
|
1860
1835
|
end
|
1861
1836
|
end
|
1862
1837
|
|
1863
1838
|
#
|
1864
1839
|
# Write the <c:tx> element.
|
1865
1840
|
#
|
1866
|
-
def write_tx_rich(title,
|
1867
|
-
@writer.tag_elements('c:tx')
|
1841
|
+
def write_tx_rich(title, is_y_axis, font) # :nodoc:
|
1842
|
+
@writer.tag_elements('c:tx') do
|
1843
|
+
write_rich(title, font, is_y_axis)
|
1844
|
+
end
|
1868
1845
|
end
|
1869
1846
|
|
1870
1847
|
#
|
@@ -1886,61 +1863,30 @@ module Writexlsx
|
|
1886
1863
|
#
|
1887
1864
|
# Write the <c:rich> element.
|
1888
1865
|
#
|
1889
|
-
def write_rich(title,
|
1866
|
+
def write_rich(title, font, is_y_axis, ignore_rich_pr = false) # :nodoc:
|
1890
1867
|
rotation = nil
|
1891
|
-
|
1892
|
-
|
1868
|
+
|
1869
|
+
if font && font[:_rotation]
|
1870
|
+
rotation = font[:_rotation]
|
1893
1871
|
end
|
1894
1872
|
@writer.tag_elements('c:rich') do
|
1895
1873
|
# Write the a:bodyPr element.
|
1896
|
-
write_a_body_pr(rotation,
|
1874
|
+
write_a_body_pr(rotation, is_y_axis)
|
1897
1875
|
# Write the a:lstStyle element.
|
1898
1876
|
write_a_lst_style
|
1899
1877
|
# Write the a:p element.
|
1900
|
-
write_a_p_rich(title)
|
1878
|
+
write_a_p_rich(title, font, ignore_rich_pr)
|
1901
1879
|
end
|
1902
1880
|
end
|
1903
|
-
|
1904
|
-
#
|
1905
|
-
# Write the <a:bodyPr> element.
|
1906
|
-
#
|
1907
|
-
def write_a_body_pr(rot, horiz = nil) # :nodoc:
|
1908
|
-
rot = -5400000 if !rot && ptrue?(horiz)
|
1909
|
-
attributes = []
|
1910
|
-
attributes << ['rot', rot] if rot
|
1911
|
-
attributes << ['vert', 'horz'] if ptrue?(horiz)
|
1912
|
-
|
1913
|
-
@writer.empty_tag('a:bodyPr', attributes)
|
1914
|
-
end
|
1915
|
-
|
1916
|
-
#
|
1917
|
-
# Write the <a:lstStyle> element.
|
1918
|
-
#
|
1919
|
-
def write_a_lst_style # :nodoc:
|
1920
|
-
@writer.empty_tag('a:lstStyle')
|
1921
|
-
end
|
1922
|
-
|
1923
1881
|
#
|
1924
1882
|
# Write the <a:p> element for rich string titles.
|
1925
1883
|
#
|
1926
|
-
def write_a_p_rich(title) # :nodoc:
|
1884
|
+
def write_a_p_rich(title, font, ignore_rich_pr) # :nodoc:
|
1927
1885
|
@writer.tag_elements('a:p') do
|
1928
1886
|
# Write the a:pPr element.
|
1929
|
-
write_a_p_pr_rich(
|
1887
|
+
write_a_p_pr_rich(font) if !ignore_rich_pr
|
1930
1888
|
# Write the a:r element.
|
1931
|
-
write_a_r(title)
|
1932
|
-
end
|
1933
|
-
end
|
1934
|
-
|
1935
|
-
#
|
1936
|
-
# Write the <a:p> element for formula titles.
|
1937
|
-
#
|
1938
|
-
def write_a_p_formula(font = nil) # :nodoc:
|
1939
|
-
@writer.tag_elements('a:p') do
|
1940
|
-
# Write the a:pPr element.
|
1941
|
-
write_a_p_pr_formula(font)
|
1942
|
-
# Write the a:endParaRPr element.
|
1943
|
-
write_a_end_para_rpr
|
1889
|
+
write_a_r(title, font)
|
1944
1890
|
end
|
1945
1891
|
end
|
1946
1892
|
|
@@ -1951,39 +1897,15 @@ module Writexlsx
|
|
1951
1897
|
@writer.tag_elements('a:pPr') { write_a_def_rpr(font) }
|
1952
1898
|
end
|
1953
1899
|
|
1954
|
-
#
|
1955
|
-
# Write the <a:pPr> element for formula titles.
|
1956
|
-
#
|
1957
|
-
def write_a_p_pr_formula(font) # :nodoc:
|
1958
|
-
@writer.tag_elements('a:pPr') { write_a_def_rpr(font) }
|
1959
|
-
end
|
1960
|
-
|
1961
|
-
#
|
1962
|
-
# Write the <a:defRPr> element.
|
1963
|
-
#
|
1964
|
-
def write_a_def_rpr(font = nil) # :nodoc:
|
1965
|
-
write_def_rpr_r_pr_common(
|
1966
|
-
font,
|
1967
|
-
get_font_style_attributes(font),
|
1968
|
-
'a:defRPr')
|
1969
|
-
end
|
1970
|
-
|
1971
|
-
#
|
1972
|
-
# Write the <a:endParaRPr> element.
|
1973
|
-
#
|
1974
|
-
def write_a_end_para_rpr # :nodoc:
|
1975
|
-
@writer.empty_tag('a:endParaRPr', [ ['lang', 'en-US'] ])
|
1976
|
-
end
|
1977
|
-
|
1978
1900
|
#
|
1979
1901
|
# Write the <a:r> element.
|
1980
1902
|
#
|
1981
|
-
def write_a_r(title) # :nodoc:
|
1903
|
+
def write_a_r(title, font) # :nodoc:
|
1982
1904
|
@writer.tag_elements('a:r') do
|
1983
1905
|
# Write the a:rPr element.
|
1984
|
-
write_a_r_pr(
|
1906
|
+
write_a_r_pr(font)
|
1985
1907
|
# Write the a:t element.
|
1986
|
-
write_a_t(title.name)
|
1908
|
+
write_a_t(title.respond_to?(:name) ? title.name : title)
|
1987
1909
|
end
|
1988
1910
|
end
|
1989
1911
|
|
@@ -1998,24 +1920,6 @@ module Writexlsx
|
|
1998
1920
|
write_def_rpr_r_pr_common(font, attributes, 'a:rPr')
|
1999
1921
|
end
|
2000
1922
|
|
2001
|
-
def write_def_rpr_r_pr_common(font, style_attributes, tag) # :nodoc:
|
2002
|
-
latin_attributes = get_font_latin_attributes(font)
|
2003
|
-
has_color = ptrue?(font) && ptrue?(font[:_color])
|
2004
|
-
|
2005
|
-
if !latin_attributes.empty? || has_color
|
2006
|
-
@writer.tag_elements(tag, style_attributes) do
|
2007
|
-
if has_color
|
2008
|
-
write_a_solid_fill(:color => font[:_color])
|
2009
|
-
end
|
2010
|
-
if !latin_attributes.empty?
|
2011
|
-
write_a_latin(latin_attributes)
|
2012
|
-
end
|
2013
|
-
end
|
2014
|
-
else
|
2015
|
-
@writer.empty_tag(tag, style_attributes)
|
2016
|
-
end
|
2017
|
-
end
|
2018
|
-
|
2019
1923
|
#
|
2020
1924
|
# Write the <a:t> element.
|
2021
1925
|
#
|
@@ -2023,24 +1927,6 @@ module Writexlsx
|
|
2023
1927
|
@writer.data_element('a:t', title)
|
2024
1928
|
end
|
2025
1929
|
|
2026
|
-
#
|
2027
|
-
# Write the <c:txPr> element.
|
2028
|
-
#
|
2029
|
-
def write_tx_pr(horiz, font) # :nodoc:
|
2030
|
-
rotation = nil
|
2031
|
-
if font && font[:_rotation]
|
2032
|
-
rotation = font[:_rotation]
|
2033
|
-
end
|
2034
|
-
@writer.tag_elements('c:txPr') do
|
2035
|
-
# Write the a:bodyPr element.
|
2036
|
-
write_a_body_pr(rotation, horiz)
|
2037
|
-
# Write the a:lstStyle element.
|
2038
|
-
write_a_lst_style
|
2039
|
-
# Write the a:p element.
|
2040
|
-
write_a_p_formula(font)
|
2041
|
-
end
|
2042
|
-
end
|
2043
|
-
|
2044
1930
|
#
|
2045
1931
|
# Write the <c:marker> element.
|
2046
1932
|
#
|
@@ -2084,16 +1970,27 @@ module Writexlsx
|
|
2084
1970
|
@writer.empty_tag('c:symbol', [ ['val', val] ])
|
2085
1971
|
end
|
2086
1972
|
|
1973
|
+
def has_fill_formatting(element)
|
1974
|
+
line = series_property(element, :line)
|
1975
|
+
fill = series_property(element, :fill)
|
1976
|
+
pattern = series_property(element, :pattern)
|
1977
|
+
gradient = series_property(element, :gradient)
|
1978
|
+
|
1979
|
+
(line && ptrue?(line[:_defined])) ||
|
1980
|
+
(fill && ptrue?(fill[:_defined])) || pattern || gradient
|
1981
|
+
end
|
1982
|
+
|
1983
|
+
|
2087
1984
|
#
|
2088
1985
|
# Write the <c:spPr> element.
|
2089
1986
|
#
|
2090
1987
|
def write_sp_pr(series) # :nodoc:
|
2091
|
-
|
2092
|
-
fill = series.fill
|
2093
|
-
gradient = series.gradient if series.respond_to?(:gradient)
|
1988
|
+
return if !has_fill_formatting(series)
|
2094
1989
|
|
2095
|
-
|
2096
|
-
|
1990
|
+
line = series_property(series, :line)
|
1991
|
+
fill = series_property(series, :fill)
|
1992
|
+
pattern = series_property(series, :pattern)
|
1993
|
+
gradient = series_property(series, :gradient)
|
2097
1994
|
|
2098
1995
|
@writer.tag_elements('c:spPr') do
|
2099
1996
|
# Write the fill elements for solid charts such as pie/doughnut and bar.
|
@@ -2106,6 +2003,9 @@ module Writexlsx
|
|
2106
2003
|
write_a_solid_fill(fill)
|
2107
2004
|
end
|
2108
2005
|
end
|
2006
|
+
if ptrue?(pattern)
|
2007
|
+
write_a_patt_fill(pattern)
|
2008
|
+
end
|
2109
2009
|
if ptrue?(gradient)
|
2110
2010
|
# Write the a:gradFill element.
|
2111
2011
|
write_a_grad_fill(gradient)
|
@@ -2115,6 +2015,14 @@ module Writexlsx
|
|
2115
2015
|
end
|
2116
2016
|
end
|
2117
2017
|
|
2018
|
+
def series_property(object, property)
|
2019
|
+
if object.respond_to?(property)
|
2020
|
+
object.send(property)
|
2021
|
+
elsif object.respond_to?(:[])
|
2022
|
+
object[property]
|
2023
|
+
end
|
2024
|
+
end
|
2025
|
+
|
2118
2026
|
#
|
2119
2027
|
# Write the <a:ln> element.
|
2120
2028
|
#
|
@@ -2158,20 +2066,12 @@ module Writexlsx
|
|
2158
2066
|
end
|
2159
2067
|
|
2160
2068
|
#
|
2161
|
-
# Write the <a:
|
2069
|
+
# Write the <a:alpha> element.
|
2162
2070
|
#
|
2163
|
-
def
|
2164
|
-
|
2165
|
-
# Write the a:srgbClr element.
|
2166
|
-
write_a_srgb_clr(color(line[:color])) if line[:color]
|
2167
|
-
end
|
2168
|
-
end
|
2071
|
+
def write_a_alpha(val)
|
2072
|
+
val = (100 - val.to_i) * 1000
|
2169
2073
|
|
2170
|
-
|
2171
|
-
# Write the <a:srgbClr> element.
|
2172
|
-
#
|
2173
|
-
def write_a_srgb_clr(val) # :nodoc:
|
2174
|
-
@writer.empty_tag('a:srgbClr', [ ['val', val] ])
|
2074
|
+
@writer.empty_tag('a:alpha', [ ['val', val] ])
|
2175
2075
|
end
|
2176
2076
|
|
2177
2077
|
#
|
@@ -2202,6 +2102,20 @@ module Writexlsx
|
|
2202
2102
|
write_forward(trendline.forward)
|
2203
2103
|
# Write the c:backward element.
|
2204
2104
|
write_backward(trendline.backward)
|
2105
|
+
if trendline.intercept
|
2106
|
+
# Write the c:intercept element.
|
2107
|
+
write_intercept(trendline.intercept)
|
2108
|
+
end
|
2109
|
+
if trendline.display_r_squared
|
2110
|
+
# Write the c:dispRSqr element.
|
2111
|
+
write_disp_rsqr
|
2112
|
+
end
|
2113
|
+
if trendline.display_equation
|
2114
|
+
# Write the c:dispEq element.
|
2115
|
+
write_disp_eq
|
2116
|
+
# Write the c:trendlineLbl element.
|
2117
|
+
write_trendline_lbl
|
2118
|
+
end
|
2205
2119
|
end
|
2206
2120
|
end
|
2207
2121
|
|
@@ -2253,6 +2167,54 @@ module Writexlsx
|
|
2253
2167
|
@writer.empty_tag('c:backward', [ ['val', val] ])
|
2254
2168
|
end
|
2255
2169
|
|
2170
|
+
#
|
2171
|
+
# Write the <c:intercept> element.
|
2172
|
+
#
|
2173
|
+
def write_intercept(val)
|
2174
|
+
@writer.empty_tag('c:intercept', [ ['val', val] ])
|
2175
|
+
end
|
2176
|
+
|
2177
|
+
#
|
2178
|
+
# Write the <c:dispEq> element.
|
2179
|
+
#
|
2180
|
+
def write_disp_eq
|
2181
|
+
@writer.empty_tag('c:dispEq', [ ['val', 1] ])
|
2182
|
+
end
|
2183
|
+
|
2184
|
+
#
|
2185
|
+
# Write the <c:dispRSqr> element.
|
2186
|
+
#
|
2187
|
+
def write_disp_rsqr
|
2188
|
+
@writer.empty_tag('c:dispRSqr', [ ['val', 1] ])
|
2189
|
+
end
|
2190
|
+
|
2191
|
+
#
|
2192
|
+
# Write the <c:trendlineLbl> element.
|
2193
|
+
#
|
2194
|
+
def write_trendline_lbl
|
2195
|
+
@writer.tag_elements('c:trendlineLbl') do
|
2196
|
+
# Write the c:layout element.
|
2197
|
+
write_layout
|
2198
|
+
# Write the c:numFmt element.
|
2199
|
+
write_trendline_num_fmt
|
2200
|
+
end
|
2201
|
+
end
|
2202
|
+
|
2203
|
+
#
|
2204
|
+
# Write the <c:numFmt> element.
|
2205
|
+
#
|
2206
|
+
def write_trendline_num_fmt
|
2207
|
+
format_code = 'General'
|
2208
|
+
source_linked = 0
|
2209
|
+
|
2210
|
+
attributes = [
|
2211
|
+
['formatCode', format_code],
|
2212
|
+
['sourceLinked', source_linked]
|
2213
|
+
]
|
2214
|
+
|
2215
|
+
@writer.empty_tag('c:numFmt', attributes)
|
2216
|
+
end
|
2217
|
+
|
2256
2218
|
#
|
2257
2219
|
# Write the <c:hiLowLines> element.
|
2258
2220
|
#
|
@@ -2300,12 +2262,17 @@ module Writexlsx
|
|
2300
2262
|
write_format_code('General')
|
2301
2263
|
|
2302
2264
|
# Write the c:ptCount element.
|
2303
|
-
|
2265
|
+
if data
|
2266
|
+
count = data.size
|
2267
|
+
else
|
2268
|
+
count = 0
|
2269
|
+
end
|
2270
|
+
write_pt_count(count)
|
2304
2271
|
|
2305
2272
|
data.each_with_index do |token, i|
|
2306
2273
|
# Write non-numeric data as 0.
|
2307
2274
|
if token &&
|
2308
|
-
|
2275
|
+
!(token.to_s =~ /^([+-]?)(?=\d|\.\d)\d*(\.\d*)?([Ee]([+-]?\d+))?$/)
|
2309
2276
|
token = 0
|
2310
2277
|
end
|
2311
2278
|
|
@@ -2403,8 +2370,14 @@ module Writexlsx
|
|
2403
2370
|
return unless labels
|
2404
2371
|
|
2405
2372
|
@writer.tag_elements('c:dLbls') do
|
2373
|
+
# Write the custom c:dLbl elements.
|
2374
|
+
if labels[:custom]
|
2375
|
+
write_custom_labels(labels, labels[:custom])
|
2376
|
+
end
|
2406
2377
|
# Write the c:numFmt element.
|
2407
2378
|
write_data_label_number_format(labels[:num_format]) if labels[:num_format]
|
2379
|
+
# Write the c:spPr element.
|
2380
|
+
write_sp_pr(labels)
|
2408
2381
|
# Write the data label font elements.
|
2409
2382
|
write_axis_font(labels[:font]) if labels[:font]
|
2410
2383
|
# Write the c:dLblPos element.
|
@@ -2426,6 +2399,105 @@ module Writexlsx
|
|
2426
2399
|
end
|
2427
2400
|
end
|
2428
2401
|
|
2402
|
+
#
|
2403
|
+
# Write the <c:dLbl> element.
|
2404
|
+
#
|
2405
|
+
def write_custom_labels(parent, labels)
|
2406
|
+
index = 0
|
2407
|
+
|
2408
|
+
labels.each do |label|
|
2409
|
+
index += 1
|
2410
|
+
next if !ptrue?(label)
|
2411
|
+
|
2412
|
+
@writer.tag_elements('c:dLbl') do
|
2413
|
+
# Write the c:idx element.
|
2414
|
+
write_idx(index - 1)
|
2415
|
+
|
2416
|
+
if label[:delete] && label[:delete]
|
2417
|
+
write_delete(1)
|
2418
|
+
elsif label[:formula]
|
2419
|
+
write_custom_label_formula(label)
|
2420
|
+
|
2421
|
+
write_d_lbl_pos(parent[:position]) if parent[:position]
|
2422
|
+
write_show_val if parent[:value]
|
2423
|
+
write_show_cat_name if parent[:category]
|
2424
|
+
write_show_ser_name if parent[:series_name]
|
2425
|
+
elsif label[:value]
|
2426
|
+
write_custom_label_str(label)
|
2427
|
+
|
2428
|
+
write_d_lbl_pos(parent[:position]) if parent[:position]
|
2429
|
+
write_show_val if parent[:value]
|
2430
|
+
write_show_cat_name if parent[:category]
|
2431
|
+
write_show_ser_name if parent[:series_name]
|
2432
|
+
else
|
2433
|
+
write_custom_label_format_only(label)
|
2434
|
+
end
|
2435
|
+
end
|
2436
|
+
end
|
2437
|
+
end
|
2438
|
+
|
2439
|
+
#
|
2440
|
+
# Write parts of the <c:dLbl> element for strings.
|
2441
|
+
#
|
2442
|
+
def write_custom_label_str(label)
|
2443
|
+
value = label[:value]
|
2444
|
+
font = label[:font]
|
2445
|
+
is_y_axis = 0
|
2446
|
+
has_formatting = has_fill_formatting(label)
|
2447
|
+
|
2448
|
+
# Write the c:layout element.
|
2449
|
+
write_layout()
|
2450
|
+
|
2451
|
+
@writer.tag_elements('c:tx') do
|
2452
|
+
# Write the c:rich element.
|
2453
|
+
write_rich(value, font, is_y_axis, !has_formatting)
|
2454
|
+
end
|
2455
|
+
|
2456
|
+
# Write the c:cpPr element.
|
2457
|
+
write_sp_pr(label)
|
2458
|
+
end
|
2459
|
+
|
2460
|
+
#
|
2461
|
+
# Write parts of the <c:dLbl> element for formulas.
|
2462
|
+
#
|
2463
|
+
def write_custom_label_formula(label)
|
2464
|
+
formula = label[:formula]
|
2465
|
+
data_id = label[:data_id]
|
2466
|
+
|
2467
|
+
if data_id
|
2468
|
+
data = @formula_data[data_id]
|
2469
|
+
end
|
2470
|
+
|
2471
|
+
# Write the c:layout element.
|
2472
|
+
write_layout
|
2473
|
+
|
2474
|
+
@writer.tag_elements('c:tx') do
|
2475
|
+
# Write the c:strRef element.
|
2476
|
+
write_str_ref(formula, data, 'str')
|
2477
|
+
end
|
2478
|
+
|
2479
|
+
# Write the data label formatting, if any.
|
2480
|
+
write_custom_label_format_only(label)
|
2481
|
+
end
|
2482
|
+
|
2483
|
+
#
|
2484
|
+
# Write parts of the <c:dLbl> element for labels where only the formatting has
|
2485
|
+
# changed.
|
2486
|
+
#
|
2487
|
+
def write_custom_label_format_only(label)
|
2488
|
+
font = label[:font]
|
2489
|
+
has_formatting = has_fill_formatting(label)
|
2490
|
+
|
2491
|
+
if has_formatting
|
2492
|
+
# Write the c:spPr element.
|
2493
|
+
write_sp_pr(label)
|
2494
|
+
write_tx_pr(font)
|
2495
|
+
elsif font
|
2496
|
+
@writer.empty_tag('c:spPr')
|
2497
|
+
write_tx_pr(font)
|
2498
|
+
end
|
2499
|
+
end
|
2500
|
+
|
2429
2501
|
#
|
2430
2502
|
# Write the <c:showLegendKey> element.
|
2431
2503
|
#
|
@@ -2631,7 +2703,7 @@ module Writexlsx
|
|
2631
2703
|
end
|
2632
2704
|
|
2633
2705
|
def write_num_ref_or_lit(values, data)
|
2634
|
-
if values.to_s =~ /^=/
|
2706
|
+
if values.to_s =~ /^=/ # '=Sheet1!$A$1:$A$5'
|
2635
2707
|
write_num_ref(values, data, 'num')
|
2636
2708
|
else # [1, 2, 3]
|
2637
2709
|
write_num_lit(values)
|
@@ -2754,7 +2826,7 @@ module Writexlsx
|
|
2754
2826
|
|
2755
2827
|
# Write the a:srgbClr element.
|
2756
2828
|
# TODO: Wait for a feature request to support transparency.
|
2757
|
-
write_a_srgb_clr( color )
|
2829
|
+
write_a_srgb_clr( color )
|
2758
2830
|
end
|
2759
2831
|
end
|
2760
2832
|
end
|
@@ -2829,6 +2901,26 @@ module Writexlsx
|
|
2829
2901
|
@writer.empty_tag('a:tileRect', attributes)
|
2830
2902
|
end
|
2831
2903
|
|
2904
|
+
#
|
2905
|
+
# Write the <a:pattFill> element.
|
2906
|
+
#
|
2907
|
+
def write_a_patt_fill(pattern)
|
2908
|
+
attributes = [ ['prst', pattern[:pattern]] ]
|
2909
|
+
|
2910
|
+
@writer.tag_elements('a:pattFill', attributes) do
|
2911
|
+
write_a_fg_clr(pattern[:fg_color])
|
2912
|
+
write_a_bg_clr(pattern[:bg_color])
|
2913
|
+
end
|
2914
|
+
end
|
2915
|
+
|
2916
|
+
def write_a_fg_clr(color)
|
2917
|
+
@writer.tag_elements('a:fgClr') { write_a_srgb_clr(color(color)) }
|
2918
|
+
end
|
2919
|
+
|
2920
|
+
def write_a_bg_clr(color)
|
2921
|
+
@writer.tag_elements('a:bgClr') { write_a_srgb_clr(color(color)) }
|
2922
|
+
end
|
2923
|
+
|
2832
2924
|
def write_bars_base(tag, format)
|
2833
2925
|
if format.line_defined? || format.fill_defined?
|
2834
2926
|
@writer.tag_elements(tag) { write_sp_pr(format) }
|
@@ -2836,9 +2928,5 @@ module Writexlsx
|
|
2836
2928
|
@writer.empty_tag(tag)
|
2837
2929
|
end
|
2838
2930
|
end
|
2839
|
-
|
2840
|
-
def nil_or_max?(val) # :nodoc:
|
2841
|
-
val.nil? || val == 'max'
|
2842
|
-
end
|
2843
2931
|
end
|
2844
2932
|
end
|