write_xlsx 0.86.0 → 0.97.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.travis.yml +43 -0
- data/Changes +74 -0
- data/LICENSE.txt +1 -1
- data/README.md +4 -4
- data/examples/a_simple.rb +1 -6
- data/examples/chart_combined.rb +3 -1
- data/examples/conditional_format.rb +73 -46
- data/examples/demo.rb +1 -7
- data/examples/hyperlink1.rb +4 -11
- data/lib/write_xlsx/chart.rb +150 -192
- data/lib/write_xlsx/chart/axis.rb +33 -8
- data/lib/write_xlsx/chart/caption.rb +3 -1
- data/lib/write_xlsx/chart/pie.rb +2 -0
- data/lib/write_xlsx/chart/series.rb +37 -17
- data/lib/write_xlsx/format.rb +19 -11
- data/lib/write_xlsx/package/conditional_format.rb +351 -38
- data/lib/write_xlsx/package/content_types.rb +10 -0
- data/lib/write_xlsx/package/core.rb +8 -6
- data/lib/write_xlsx/package/custom.rb +125 -0
- data/lib/write_xlsx/package/packager.rb +26 -0
- data/lib/write_xlsx/package/styles.rb +53 -21
- data/lib/write_xlsx/package/table.rb +25 -4
- data/lib/write_xlsx/utility.rb +317 -32
- data/lib/write_xlsx/version.rb +1 -1
- data/lib/write_xlsx/workbook.rb +103 -7
- data/lib/write_xlsx/worksheet.rb +280 -30
- data/lib/write_xlsx/worksheet/cell_data.rb +21 -0
- data/lib/write_xlsx/worksheet/hyperlink.rb +4 -8
- 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 +1 -1
- 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/drawing/test_drawing_chart_01.rb +1 -1
- data/test/drawing/test_drawing_image_01.rb +1 -1
- data/test/drawing/test_drawing_shape_01.rb +1 -1
- data/test/drawing/test_drawing_shape_02.rb +1 -1
- data/test/drawing/test_drawing_shape_03.rb +1 -1
- data/test/drawing/test_drawing_shape_04.rb +1 -1
- data/test/drawing/test_drawing_shape_05.rb +1 -1
- data/test/drawing/test_drawing_shape_06.rb +1 -1
- data/test/drawing/test_drawing_shape_07.rb +1 -1
- data/test/drawing/test_write_a_graphic_frame_locks.rb +1 -1
- data/test/drawing/test_write_c_chart.rb +1 -1
- data/test/drawing/test_write_c_nv_graphic_frame_pr.rb +1 -1
- data/test/drawing/test_write_c_nv_pr.rb +1 -1
- data/test/drawing/test_write_col.rb +1 -1
- data/test/drawing/test_write_col_off.rb +1 -1
- data/test/drawing/test_write_ext.rb +1 -1
- data/test/drawing/test_write_pos.rb +1 -1
- data/test/drawing/test_write_row.rb +1 -1
- data/test/drawing/test_write_row_off.rb +1 -1
- data/test/drawing/test_write_xfrm_extension.rb +1 -1
- data/test/drawing/test_write_xfrm_offset.rb +1 -1
- 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_write_text_t.rb +1 -1
- 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/regression/_test_hyperlink31.rb +26 -0
- data/test/regression/disabled_test_vml04.rb +1 -1
- 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_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_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 +1 -1
- data/test/regression/test_chart_axis27.rb +1 -1
- data/test/regression/test_chart_axis28.rb +1 -1
- data/test/regression/test_chart_axis29.rb +1 -1
- 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 +1 -1
- 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_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_crossing01.rb +1 -1
- 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_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_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_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 +1 -1
- 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_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_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 +1 -1
- 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_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_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 +2 -2
- 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_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_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_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_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 +4 -1
- data/test/regression/test_hyperlink23.rb +4 -1
- data/test/regression/test_hyperlink24.rb +4 -1
- 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_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 +1 -1
- data/test/regression/test_image07.rb +1 -1
- data/test/regression/test_image08.rb +1 -1
- 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 +1 -1
- 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 +2 -2
- data/test/regression/test_image29.rb +2 -2
- data/test/regression/test_image30.rb +1 -1
- data/test/regression/test_image31.rb +1 -1
- data/test/regression/test_image32.rb +1 -1
- data/test/regression/test_image33.rb +2 -2
- data/test/regression/test_image35.rb +26 -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_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 +2 -5
- 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_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_print_scale01.rb +1 -1
- 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 +1 -1
- 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_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 +1 -1
- 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/chart_axis40.xlsx +0 -0
- data/test/regression/xlsx_files/chart_axis41.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_data_labels25.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_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/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/date_1904_01.xlsx +0 -0
- data/test/regression/xlsx_files/default_row05.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/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/image35.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/table21.xlsx +0 -0
- data/test/regression/xlsx_files/table22.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/utf8_11.xlsx +0 -0
- data/test/test_delete_files.rb +3 -3
- data/test/test_example_match.rb +1 -1
- data/test/test_option_hash_for_workbook.rb +1 -1
- data/test/test_xml_writer_simple.rb +1 -1
- 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 +81 -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 +2 -2
- 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_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 +1 -1
- data/test/worksheet/test_update_format_methods.rb +9 -29
- 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 +28 -1
- 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 +1 -1
- 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 +2 -2
- metadata +248 -15
- data/test/test_col_name.rb +0 -13
- data/test/workbook/test_workbook_new.rb +0 -18
- data/test/worksheet/test_format.rb +0 -17
- 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/version.rb
CHANGED
@@ -1 +1 @@
|
|
1
|
-
WriteXLSX_VERSION = "0.
|
1
|
+
WriteXLSX_VERSION = "0.97.0"
|
data/lib/write_xlsx/workbook.rb
CHANGED
@@ -44,11 +44,14 @@ class Workbook
|
|
44
44
|
attr_reader :worksheets, :charts, :drawings # :nodoc:
|
45
45
|
attr_reader :named_ranges # :nodoc:
|
46
46
|
attr_reader :doc_properties # :nodoc:
|
47
|
+
attr_reader :custom_properties # :nodoc:
|
47
48
|
attr_reader :image_types, :images # :nodoc:
|
48
49
|
attr_reader :shared_strings # :nodoc:
|
49
50
|
attr_reader :vba_project # :nodoc:
|
50
51
|
attr_reader :excel2003_style # :nodoc:
|
51
52
|
attr_reader :strings_to_urls # :nodoc:
|
53
|
+
attr_reader :default_url_format # :nodoc:
|
54
|
+
|
52
55
|
#
|
53
56
|
# A new Excel workbook is created using the +new+ constructor
|
54
57
|
# which accepts either a filename or an IO object as a parameter.
|
@@ -114,7 +117,7 @@ def initialize(file, *option_params)
|
|
114
117
|
@named_ranges = []
|
115
118
|
@custom_colors = []
|
116
119
|
@doc_properties = {}
|
117
|
-
@
|
120
|
+
@custom_properties = []
|
118
121
|
@optimization = options[:optimization] || 0
|
119
122
|
@x_window = 240
|
120
123
|
@y_window = 15
|
@@ -141,6 +144,10 @@ def initialize(file, *option_params)
|
|
141
144
|
else
|
142
145
|
add_format(default_formats.merge(:xf_index => 0))
|
143
146
|
end
|
147
|
+
|
148
|
+
# Add a default URL format.
|
149
|
+
@default_url_format = add_format(:hyperlink => 1)
|
150
|
+
|
144
151
|
set_color_palette
|
145
152
|
end
|
146
153
|
|
@@ -203,6 +210,14 @@ def sheets(*args)
|
|
203
210
|
end
|
204
211
|
end
|
205
212
|
|
213
|
+
#
|
214
|
+
# Return a worksheet object in the workbook using the sheetname.
|
215
|
+
#
|
216
|
+
def worksheet_by_name(sheetname = nil)
|
217
|
+
sheets.select { |s| s.name == sheetname }.first
|
218
|
+
end
|
219
|
+
alias get_worksheet_by_name worksheet_by_name
|
220
|
+
|
206
221
|
#
|
207
222
|
# Set the date system: false = 1900 (the default), true = 1904
|
208
223
|
#
|
@@ -726,7 +741,7 @@ def define_name(name, formula)
|
|
726
741
|
|
727
742
|
# Raise if the sheet index wasn't found.
|
728
743
|
if !sheet_index
|
729
|
-
raise "Unknown sheet name #{sheetname} in defined_name()
|
744
|
+
raise "Unknown sheet name #{sheetname} in defined_name()"
|
730
745
|
end
|
731
746
|
|
732
747
|
# Raise if the name contains invalid chars as defined by Excel help.
|
@@ -734,22 +749,41 @@ def define_name(name, formula)
|
|
734
749
|
# http://office.microsoft.com/en-001/excel-help/define-and-use-names-in-formulas-HA010147120.aspx#BMsyntax_rules_for_names
|
735
750
|
#
|
736
751
|
if name =~ /\A[-0-9 !"#\$%&'\(\)\*\+,\.:;<=>\?@\[\]\^`\{\}~]/ || name =~ /.+[- !"#\$%&'\(\)\*\+,\\:;<=>\?@\[\]\^`\{\}~]/
|
737
|
-
raise "Invalid characters in name '#{name}' used in defined_name()
|
752
|
+
raise "Invalid characters in name '#{name}' used in defined_name()"
|
738
753
|
end
|
739
754
|
|
740
755
|
# Raise if the name looks like a cell name.
|
741
756
|
if name =~ %r(^[a-zA-Z][a-zA-Z]?[a-dA-D]?[0-9]+$)
|
742
|
-
raise "Invalid name '#{name}' looks like a cell name in defined_name()
|
757
|
+
raise "Invalid name '#{name}' looks like a cell name in defined_name()"
|
743
758
|
end
|
744
759
|
|
745
760
|
# Raise if the name looks like a R1C1
|
746
761
|
if name =~ /\A[rcRC]\Z/ || name =~ /\A[rcRC]\d+[rcRC]\d+\Z/
|
747
|
-
raise "Invalid name '#{name}' like a RC cell ref in defined_name()
|
762
|
+
raise "Invalid name '#{name}' like a RC cell ref in defined_name()"
|
748
763
|
end
|
749
764
|
|
750
765
|
@defined_names.push([ name, sheet_index, formula.sub(/^=/, '') ])
|
751
766
|
end
|
752
767
|
|
768
|
+
#
|
769
|
+
# Set the workbook size.
|
770
|
+
#
|
771
|
+
def set_size(width = nil, height = nil)
|
772
|
+
if ptrue?(width)
|
773
|
+
# Convert to twips at 96 dpi.
|
774
|
+
@window_width = width.to_i * 1440 / 96
|
775
|
+
else
|
776
|
+
@window_width = 16095
|
777
|
+
end
|
778
|
+
|
779
|
+
if ptrue?(height)
|
780
|
+
# Convert to twips at 96 dpi.
|
781
|
+
@window_height = height.to_i * 1440 / 96
|
782
|
+
else
|
783
|
+
@window_height = 9660
|
784
|
+
end
|
785
|
+
end
|
786
|
+
|
753
787
|
#
|
754
788
|
# The set_properties method can be used to set the document properties
|
755
789
|
# of the Excel file created by WriteXLSX. These properties are visible
|
@@ -806,11 +840,58 @@ def set_properties(params)
|
|
806
840
|
end
|
807
841
|
|
808
842
|
# Set the creation time unless specified by the user.
|
809
|
-
params[:created] = @
|
843
|
+
params[:created] = @createtime unless params.has_key?(:created)
|
810
844
|
|
811
845
|
@doc_properties = params.dup
|
812
846
|
end
|
813
847
|
|
848
|
+
#
|
849
|
+
# Set a user defined custom document property.
|
850
|
+
#
|
851
|
+
def set_custom_property(name, value, type = nil)
|
852
|
+
# Valid types.
|
853
|
+
valid_type = {
|
854
|
+
'text' => 1,
|
855
|
+
'date' => 1,
|
856
|
+
'number' => 1,
|
857
|
+
'number_int' => 1,
|
858
|
+
'bool' => 1,
|
859
|
+
}
|
860
|
+
|
861
|
+
if !name || (type != 'bool' && !value)
|
862
|
+
raise "The name and value parameters must be defined in set_custom_property()"
|
863
|
+
end
|
864
|
+
|
865
|
+
# Determine the type for strings and numbers if it hasn't been specified.
|
866
|
+
if !ptrue?(type)
|
867
|
+
if value =~ /^\d+$/
|
868
|
+
type = 'number_int'
|
869
|
+
elsif value =~
|
870
|
+
/^([+-]?)(?=[0-9]|\.[0-9])[0-9]*(\.[0-9]*)?([Ee]([+-]?[0-9]+))?$/
|
871
|
+
type = 'number'
|
872
|
+
else
|
873
|
+
type = 'text'
|
874
|
+
end
|
875
|
+
end
|
876
|
+
|
877
|
+
# Check for valid validation types.
|
878
|
+
if !valid_type[type]
|
879
|
+
raise "Unknown custom type '$type' in set_custom_property()"
|
880
|
+
end
|
881
|
+
|
882
|
+
# Check for strings longer than Excel's limit of 255 chars.
|
883
|
+
if type == 'text' && value.length > 255
|
884
|
+
raise "Length of text custom value '$value' exceeds Excel's limit of 255 in set_custom_property()"
|
885
|
+
end
|
886
|
+
|
887
|
+
if type == 'bool'
|
888
|
+
value = value ? 1 : 0
|
889
|
+
end
|
890
|
+
|
891
|
+
@custom_properties << [name, value, type]
|
892
|
+
end
|
893
|
+
|
894
|
+
|
814
895
|
#
|
815
896
|
# The add_vba_project method can be used to add macros or functions to an
|
816
897
|
# WriteXLSX file using a binary VBA project file that has been extracted
|
@@ -869,6 +950,16 @@ def set_calc_mode(mode, calc_id = nil)
|
|
869
950
|
@calc_id = calc_id if calc_id
|
870
951
|
end
|
871
952
|
|
953
|
+
#
|
954
|
+
# Get the default url format used when a user defined format isn't specified
|
955
|
+
# with write_url(). The format is the hyperlink style defined by Excel for the
|
956
|
+
# default theme.
|
957
|
+
#
|
958
|
+
def default_url_format
|
959
|
+
@default_url_format
|
960
|
+
end
|
961
|
+
alias get_default_url_format default_url_format
|
962
|
+
|
872
963
|
#
|
873
964
|
# Change the RGB components of the elements in the colour palette.
|
874
965
|
#
|
@@ -1633,9 +1724,10 @@ def prepare_vml_objects #:nodoc:
|
|
1633
1724
|
#
|
1634
1725
|
def prepare_tables
|
1635
1726
|
table_id = 0
|
1727
|
+
seen = {}
|
1636
1728
|
|
1637
1729
|
sheets.each do |sheet|
|
1638
|
-
table_id += sheet.prepare_tables(table_id + 1)
|
1730
|
+
table_id += sheet.prepare_tables(table_id + 1, seen)
|
1639
1731
|
end
|
1640
1732
|
end
|
1641
1733
|
|
@@ -1913,6 +2005,10 @@ def get_image_properties(filename)
|
|
1913
2005
|
|
1914
2006
|
@images << [filename, type]
|
1915
2007
|
|
2008
|
+
# Set a default dpi for images with 0 dpi.
|
2009
|
+
x_dpi = 96 if x_dpi == 0
|
2010
|
+
y_dpi = 96 if y_dpi == 0
|
2011
|
+
|
1916
2012
|
[type, width, height, File.basename(filename), x_dpi, y_dpi]
|
1917
2013
|
end
|
1918
2014
|
|
data/lib/write_xlsx/worksheet.rb
CHANGED
@@ -294,7 +294,7 @@ class Worksheet
|
|
294
294
|
attr_reader :writer, :set_rows, :col_formats # :nodoc:
|
295
295
|
attr_reader :vml_shape_id # :nodoc:
|
296
296
|
attr_reader :comments, :comments_author # :nodoc:
|
297
|
-
attr_accessor :dxf_priority # :nodoc:
|
297
|
+
attr_accessor :data_bars_2010, :dxf_priority # :nodoc:
|
298
298
|
attr_reader :vba_codename # :nodoc:
|
299
299
|
attr_writer :excel_version
|
300
300
|
|
@@ -308,6 +308,7 @@ def initialize(workbook, index, name) #:nodoc:
|
|
308
308
|
@cell_data_table = {}
|
309
309
|
@excel_version = 2007
|
310
310
|
@palette = workbook.palette
|
311
|
+
@default_url_format = workbook.default_url_format
|
311
312
|
|
312
313
|
@page_setup = PageSetup.new
|
313
314
|
|
@@ -376,8 +377,9 @@ def initialize(workbook, index, name) #:nodoc:
|
|
376
377
|
|
377
378
|
@validations = []
|
378
379
|
|
379
|
-
@cond_formats
|
380
|
-
@
|
380
|
+
@cond_formats = {}
|
381
|
+
@data_bars_2010 = []
|
382
|
+
@dxf_priority = 1
|
381
383
|
|
382
384
|
if excel2003_style?
|
383
385
|
@original_row_height = 12.75
|
@@ -422,7 +424,7 @@ def assemble_xml_file #:nodoc:
|
|
422
424
|
write_legacy_drawing
|
423
425
|
write_legacy_drawing_hf
|
424
426
|
write_table_parts
|
425
|
-
|
427
|
+
write_ext_list
|
426
428
|
end
|
427
429
|
end
|
428
430
|
end
|
@@ -2529,6 +2531,26 @@ def write_array_formula(*args)
|
|
2529
2531
|
end
|
2530
2532
|
end
|
2531
2533
|
|
2534
|
+
#
|
2535
|
+
# write_boolean(row, col, val, format)
|
2536
|
+
#
|
2537
|
+
# Write a boolean value to the specified row and column (zero indexed).
|
2538
|
+
#
|
2539
|
+
def write_boolean(*args)
|
2540
|
+
row, col, val, xf = row_col_notation(args)
|
2541
|
+
raise WriteXLSXInsufficientArgumentError if row.nil? || col.nil?
|
2542
|
+
|
2543
|
+
val = val ? 1 : 0 # Boolean value.
|
2544
|
+
# xf : cell format.
|
2545
|
+
type = 'l' # The data type
|
2546
|
+
|
2547
|
+
# Check that row and col are valid and store max and min values
|
2548
|
+
check_dimensions(row, col)
|
2549
|
+
store_row_col_max_min_values(row, col)
|
2550
|
+
|
2551
|
+
store_data_to_table(BooleanCellData.new(self, row, col, val, xf))
|
2552
|
+
end
|
2553
|
+
|
2532
2554
|
#
|
2533
2555
|
# :call-seq:
|
2534
2556
|
# update_format_with_params(row, col, format_params)
|
@@ -2537,12 +2559,12 @@ def write_array_formula(*args)
|
|
2537
2559
|
#
|
2538
2560
|
# worksheet.update_format_with_params(0, 0, color: 'red')
|
2539
2561
|
#
|
2540
|
-
# This method is used to update formatting of the cell keeping cell contents
|
2562
|
+
# This method is used to update formatting of the cell keeping cell contents
|
2541
2563
|
# and formatting.
|
2542
2564
|
#
|
2543
|
-
# If the cell doesn't have CellData object, this method create a CellData
|
2565
|
+
# If the cell doesn't have CellData object, this method create a CellData
|
2544
2566
|
# using write_blank method.
|
2545
|
-
# If the cell has CellData, this method fetch contents and format of cell from
|
2567
|
+
# If the cell has CellData, this method fetch contents and format of cell from
|
2546
2568
|
# the CellData object and recreate CellData using write method.
|
2547
2569
|
#
|
2548
2570
|
def update_format_with_params(*args)
|
@@ -2590,7 +2612,7 @@ def update_format_with_params(*args)
|
|
2590
2612
|
#
|
2591
2613
|
# worksheet.update_range_format_with_params(0, 0, 3, 3, color: 'red')
|
2592
2614
|
#
|
2593
|
-
# This method is used to update formatting of multiple cells keeping cells' contents
|
2615
|
+
# This method is used to update formatting of multiple cells keeping cells' contents
|
2594
2616
|
# and formatting.
|
2595
2617
|
#
|
2596
2618
|
#
|
@@ -2761,6 +2783,9 @@ def write_url(*args)
|
|
2761
2783
|
raise "URL '#{url}' added but number of URLS is over Excel's limit of 65,530 URLS per worksheet."
|
2762
2784
|
end
|
2763
2785
|
|
2786
|
+
# Add the default URL format.
|
2787
|
+
xf = @default_url_format unless xf
|
2788
|
+
|
2764
2789
|
# Write the hyperlink string.
|
2765
2790
|
write_string(row, col, hyperlink.str, xf)
|
2766
2791
|
end
|
@@ -5813,11 +5838,11 @@ def position_object_pixels(col_start, row_start, x1, y1, width, height) #:nodoc:
|
|
5813
5838
|
y1 += size_row(row_start - 1)
|
5814
5839
|
row_start -= 1
|
5815
5840
|
end
|
5816
|
-
|
5841
|
+
|
5817
5842
|
# Ensure that the image isn't shifted off the page at top left.
|
5818
5843
|
x1 = 0 if x1 < 0
|
5819
5844
|
y1 = 0 if y1 < 0
|
5820
|
-
|
5845
|
+
|
5821
5846
|
# Calculate the absolute x offset of the top-left vertex.
|
5822
5847
|
if @col_size_changed
|
5823
5848
|
x_abs = (0 .. col_start-1).inject(0) {|sum, col| sum += size_col(col)}
|
@@ -5970,12 +5995,18 @@ def prepare_header_vml_objects(vml_header_id, vml_drawing_id)
|
|
5970
5995
|
#
|
5971
5996
|
# Set the table ids for the worksheet tables.
|
5972
5997
|
#
|
5973
|
-
def prepare_tables(table_id)
|
5998
|
+
def prepare_tables(table_id, seen)
|
5974
5999
|
if tables_count > 0
|
5975
6000
|
id = table_id
|
5976
6001
|
tables.each do |table|
|
5977
6002
|
table.prepare(id)
|
5978
6003
|
|
6004
|
+
if seen[table.name]
|
6005
|
+
raise "error: invalid duplicate table name '#{table.name}' found."
|
6006
|
+
else
|
6007
|
+
seen[table.name] = 1
|
6008
|
+
end
|
6009
|
+
|
5979
6010
|
# Store the link used for the rels file.
|
5980
6011
|
@external_table_links << ['/table', "../tables/table#{id}.xml"]
|
5981
6012
|
id += 1
|
@@ -6011,6 +6042,26 @@ def set_vba_name(vba_codename = nil)
|
|
6011
6042
|
end
|
6012
6043
|
end
|
6013
6044
|
|
6045
|
+
def write_ext(url)
|
6046
|
+
attributes = [
|
6047
|
+
['xmlns:x14', "#{OFFICE_URL}spreadsheetml/2009/9/main"],
|
6048
|
+
['uri', url]
|
6049
|
+
]
|
6050
|
+
@writer.tag_elements('ext', attributes) do
|
6051
|
+
yield
|
6052
|
+
end
|
6053
|
+
end
|
6054
|
+
|
6055
|
+
def write_sparkline_groups
|
6056
|
+
# Write the x14:sparklineGroups element.
|
6057
|
+
@writer.tag_elements('x14:sparklineGroups', sparkline_groups_attributes) do
|
6058
|
+
# Write the sparkline elements.
|
6059
|
+
@sparklines.reverse.each do |sparkline|
|
6060
|
+
sparkline.write_sparkline_group(@writer)
|
6061
|
+
end
|
6062
|
+
end
|
6063
|
+
end
|
6064
|
+
|
6014
6065
|
private
|
6015
6066
|
|
6016
6067
|
def hyperlinks_count
|
@@ -6622,9 +6673,10 @@ def encode_password(password) #:nodoc:
|
|
6622
6673
|
def write_worksheet_attributes #:nodoc:
|
6623
6674
|
schema = 'http://schemas.openxmlformats.org/'
|
6624
6675
|
attributes = [
|
6625
|
-
|
6626
|
-
|
6627
|
-
|
6676
|
+
['xmlns', "#{schema}spreadsheetml/2006/main"],
|
6677
|
+
['xmlns:r', "#{schema}officeDocument/2006/relationships"]
|
6678
|
+
]
|
6679
|
+
|
6628
6680
|
if @excel_version == 2010
|
6629
6681
|
attributes << ['xmlns:mc', "#{schema}markup-compatibility/2006"]
|
6630
6682
|
attributes << ['xmlns:x14ac', "#{OFFICE_URL}spreadsheetml/2009/9/ac"]
|
@@ -7480,31 +7532,229 @@ def write_r_id(tag, id)
|
|
7480
7532
|
end
|
7481
7533
|
|
7482
7534
|
#
|
7483
|
-
# Write the <extLst> element and
|
7535
|
+
# Write the <extLst> element for data bars and sparklines.
|
7484
7536
|
#
|
7485
|
-
def
|
7486
|
-
@
|
7537
|
+
def write_ext_list # :nodoc:
|
7538
|
+
return if @data_bars_2010.empty? && @sparklines.empty?
|
7539
|
+
|
7540
|
+
@writer.tag_elements('extLst') do
|
7541
|
+
write_ext_list_data_bars if @data_bars_2010.size > 0
|
7542
|
+
write_ext_list_sparklines if @sparklines.size > 0
|
7543
|
+
end
|
7487
7544
|
end
|
7488
7545
|
|
7489
|
-
|
7490
|
-
|
7491
|
-
|
7546
|
+
#
|
7547
|
+
# Write the Excel 2010 data_bar subelements.
|
7548
|
+
#
|
7549
|
+
def write_ext_list_data_bars
|
7550
|
+
# Write the ext element.
|
7551
|
+
write_ext('{78C0D931-6437-407d-A8EE-F0AAD7539E65}') do
|
7552
|
+
|
7553
|
+
@writer.tag_elements('x14:conditionalFormattings') do
|
7554
|
+
# Write each of the Excel 2010 conditional formatting data bar elements.
|
7555
|
+
@data_bars_2010.each do |data_bar|
|
7556
|
+
# Write the x14:conditionalFormatting element.
|
7557
|
+
write_conditional_formatting_2010(data_bar)
|
7558
|
+
end
|
7559
|
+
end
|
7492
7560
|
end
|
7493
7561
|
end
|
7562
|
+
#
|
7563
|
+
# Write the <x14:conditionalFormatting> element.
|
7564
|
+
#
|
7565
|
+
def write_conditional_formatting_2010(data_bar)
|
7566
|
+
xmlns_xm = 'http://schemas.microsoft.com/office/excel/2006/main'
|
7494
7567
|
|
7495
|
-
|
7496
|
-
|
7497
|
-
|
7498
|
-
|
7568
|
+
attributes = [ ['xmlns:xm', xmlns_xm] ]
|
7569
|
+
|
7570
|
+
@writer.tag_elements('x14:conditionalFormatting', attributes) do
|
7571
|
+
|
7572
|
+
# Write the '<x14:cfRule element.
|
7573
|
+
write_x14_cf_rule(data_bar)
|
7574
|
+
|
7575
|
+
# Write the x14:dataBar element.
|
7576
|
+
write_x14_data_bar(data_bar)
|
7577
|
+
|
7578
|
+
# Write the x14 max and min data bars.
|
7579
|
+
write_x14_cfvo(data_bar[:x14_min_type], data_bar[:min_value])
|
7580
|
+
write_x14_cfvo(data_bar[:x14_max_type], data_bar[:max_value])
|
7581
|
+
|
7582
|
+
# Write the x14:borderColor element.
|
7583
|
+
if !ptrue?(data_bar[:bar_no_border])
|
7584
|
+
write_x14_border_color(data_bar[:bar_border_color])
|
7585
|
+
end
|
7586
|
+
|
7587
|
+
# Write the x14:negativeFillColor element.
|
7588
|
+
if !ptrue?(data_bar[:bar_negative_color_same])
|
7589
|
+
write_x14_negative_fill_color(data_bar[:bar_negative_color])
|
7590
|
+
end
|
7591
|
+
|
7592
|
+
# Write the x14:negativeBorderColor element.
|
7593
|
+
if !ptrue?(data_bar[:bar_no_border]) &&
|
7594
|
+
!ptrue?(data_bar[:bar_negative_border_color_same])
|
7595
|
+
write_x14_negative_border_color(
|
7596
|
+
data_bar[:bar_negative_border_color])
|
7597
|
+
end
|
7598
|
+
|
7599
|
+
# Write the x14:axisColor element.
|
7600
|
+
if data_bar[:bar_axis_position] != 'none'
|
7601
|
+
write_x14_axis_color(data_bar[:bar_axis_color])
|
7602
|
+
end
|
7603
|
+
|
7604
|
+
# Write closing elements.
|
7605
|
+
@writer.end_tag('x14:dataBar')
|
7606
|
+
@writer.end_tag('x14:cfRule')
|
7607
|
+
|
7608
|
+
# Add the conditional format range.
|
7609
|
+
@writer.data_element('xm:sqref', data_bar[:range])
|
7610
|
+
end
|
7611
|
+
end
|
7612
|
+
|
7613
|
+
#
|
7614
|
+
# Write the <cfvo> element.
|
7615
|
+
#
|
7616
|
+
def write_x14_cfvo(type, value)
|
7617
|
+
attributes = [ ['type', type ] ]
|
7618
|
+
|
7619
|
+
if %w(min max autoMin autoMax).include?(type)
|
7620
|
+
@writer.empty_tag('x14:cfvo', attributes)
|
7621
|
+
else
|
7622
|
+
@writer.tag_elements('x14:cfvo', attributes) do
|
7623
|
+
@writer.data_element('xm:f', value)
|
7624
|
+
end
|
7625
|
+
end
|
7626
|
+
end
|
7627
|
+
|
7628
|
+
#
|
7629
|
+
# Write the <'<x14:cfRule> element.
|
7630
|
+
#
|
7631
|
+
def write_x14_cf_rule(data_bar)
|
7632
|
+
type = 'dataBar'
|
7633
|
+
id = data_bar[:guid]
|
7634
|
+
|
7635
|
+
attributes = [
|
7636
|
+
['type', type],
|
7637
|
+
['id', id]
|
7499
7638
|
]
|
7639
|
+
|
7640
|
+
@writer.start_tag('x14:cfRule', attributes)
|
7641
|
+
|
7500
7642
|
end
|
7501
7643
|
|
7502
|
-
|
7503
|
-
|
7504
|
-
|
7505
|
-
|
7506
|
-
|
7507
|
-
|
7644
|
+
#
|
7645
|
+
# Write the <x14:dataBar> element.
|
7646
|
+
#
|
7647
|
+
def write_x14_data_bar(data_bar)
|
7648
|
+
min_length = 0
|
7649
|
+
max_length = 100
|
7650
|
+
|
7651
|
+
attributes = [
|
7652
|
+
['minLength', min_length],
|
7653
|
+
['maxLength', max_length]
|
7654
|
+
]
|
7655
|
+
|
7656
|
+
attributes << ['border', 1] if !ptrue?(data_bar[:bar_no_border])
|
7657
|
+
attributes << ['gradient', 0] if ptrue?(data_bar[:bar_solid])
|
7658
|
+
|
7659
|
+
if data_bar[:bar_direction] == 'left'
|
7660
|
+
attributes << ['direction', 'leftToRight']
|
7661
|
+
end
|
7662
|
+
if data_bar[:bar_direction] == 'right'
|
7663
|
+
attributes << ['direction', 'rightToLeft']
|
7664
|
+
end
|
7665
|
+
|
7666
|
+
if ptrue?(data_bar[:bar_negative_color_same])
|
7667
|
+
attributes << ['negativeBarColorSameAsPositive', 1]
|
7668
|
+
end
|
7669
|
+
|
7670
|
+
if !ptrue?(data_bar[:bar_no_border]) &&
|
7671
|
+
!ptrue?(data_bar[:bar_negative_border_color_same])
|
7672
|
+
attributes << ['negativeBarBorderColorSameAsPositive', 0]
|
7673
|
+
end
|
7674
|
+
|
7675
|
+
if data_bar[:bar_axis_position] == 'middle'
|
7676
|
+
attributes << ['axisPosition', 'middle']
|
7677
|
+
end
|
7678
|
+
|
7679
|
+
if data_bar[:bar_axis_position] == 'none'
|
7680
|
+
attributes << ['axisPosition', 'none']
|
7681
|
+
end
|
7682
|
+
|
7683
|
+
@writer.start_tag('x14:dataBar', attributes)
|
7684
|
+
end
|
7685
|
+
|
7686
|
+
#
|
7687
|
+
# Write the <x14:borderColor> element.
|
7688
|
+
#
|
7689
|
+
def write_x14_border_color(rgb)
|
7690
|
+
attributes = [ ['rgb', rgb] ]
|
7691
|
+
|
7692
|
+
@writer.empty_tag('x14:borderColor', attributes)
|
7693
|
+
end
|
7694
|
+
|
7695
|
+
#
|
7696
|
+
# Write the <x14:negativeFillColor> element.
|
7697
|
+
#
|
7698
|
+
def write_x14_negative_fill_color(rgb)
|
7699
|
+
attributes = [ ['rgb', rgb] ]
|
7700
|
+
|
7701
|
+
@writer.empty_tag('x14:negativeFillColor', attributes)
|
7702
|
+
end
|
7703
|
+
|
7704
|
+
#
|
7705
|
+
# Write the <x14:negativeBorderColor> element.
|
7706
|
+
#
|
7707
|
+
def write_x14_negative_border_color(rgb)
|
7708
|
+
attributes = [ ['rgb', rgb] ]
|
7709
|
+
|
7710
|
+
@writer.empty_tag('x14:negativeBorderColor', attributes)
|
7711
|
+
end
|
7712
|
+
|
7713
|
+
#
|
7714
|
+
# Write the <x14:axisColor> element.
|
7715
|
+
#
|
7716
|
+
def write_x14_axis_color(rgb)
|
7717
|
+
attributes = [ ['rgb', rgb] ]
|
7718
|
+
|
7719
|
+
@writer.empty_tag('x14:axisColor', attributes)
|
7720
|
+
end
|
7721
|
+
|
7722
|
+
#
|
7723
|
+
# Write the sparkline subelements.
|
7724
|
+
#
|
7725
|
+
def write_ext_list_sparklines
|
7726
|
+
# Write the ext element.
|
7727
|
+
write_ext('{05C60535-1F16-4fd2-B633-F4F36F0B64E0}') do
|
7728
|
+
|
7729
|
+
# Write the x14:sparklineGroups element.
|
7730
|
+
write_sparkline_groups
|
7731
|
+
|
7732
|
+
# # Write the sparkline elements.
|
7733
|
+
# @sparklines.reverse.each do |sparkline|
|
7734
|
+
# # Write the x14:sparklineGroup element.
|
7735
|
+
# # sparkline.write_sparkline_group(@writer)
|
7736
|
+
|
7737
|
+
# @writer.end_tag('x14:sparklineGroup')
|
7738
|
+
# end
|
7739
|
+
|
7740
|
+
# @writer.end_tag('x14:sparklineGroups')
|
7741
|
+
end
|
7742
|
+
end
|
7743
|
+
|
7744
|
+
#
|
7745
|
+
# Write the <x14:sparklines> element and <x14:sparkline> subelements.
|
7746
|
+
#
|
7747
|
+
def write_sparklines(sparkline)
|
7748
|
+
# Write the sparkline elements.
|
7749
|
+
@writer.tag_elements('x14:sparklines') do
|
7750
|
+
(0..sparkline[:count]-1).each do |i|
|
7751
|
+
range = sparkline[:ranges][i]
|
7752
|
+
location = sparkline[:locations][i]
|
7753
|
+
|
7754
|
+
@writer.tag_elements('x14:sparkline') do
|
7755
|
+
@writer.data_element('xm:f', range)
|
7756
|
+
@writer.data_element('xm:sqref', location)
|
7757
|
+
end
|
7508
7758
|
end
|
7509
7759
|
end
|
7510
7760
|
end
|