diff options
| author | Randy Morgan <[email protected]> | 2011-11-26 13:20:57 +0900 |
|---|---|---|
| committer | Randy Morgan <[email protected]> | 2011-11-26 13:20:57 +0900 |
| commit | 11303a4d6664d9a7ff7bc408035d2ab70378a375 (patch) | |
| tree | 51c675ae3ab8cd6c1afd7087145261b1eb2ec54c | |
| parent | 044afe5a35db42cefce4f18a0fecc3da90cab1b5 (diff) | |
| download | caxlsx-11303a4d6664d9a7ff7bc408035d2ab70378a375.tar.gz caxlsx-11303a4d6664d9a7ff7bc408035d2ab70378a375.zip | |
adding in support for ruby 1.9.3
release version 1.0.9
127 files changed, 8374 insertions, 12901 deletions
diff --git a/.yardoc/checksums b/.yardoc/checksums index 2b34c131..7617f1c1 100644 --- a/.yardoc/checksums +++ b/.yardoc/checksums @@ -1,58 +1,58 @@ -lib/axlsx/stylesheet/table_styles.rb 04b778652c29d612f63e93080d06c3936e48d765 -lib/axlsx/stylesheet/table_style.rb b592135b8b02969a29bd24c28a13282f6af76f30 -lib/axlsx/drawing/pie_3D_chart.rb f9c70bd12b697dcd51780f29c037d4659b48e479 -lib/axlsx/stylesheet/border_pr.rb 09dcb61ec7b0cf49f2da4c4f8ccba8f7e0df7b07 -lib/axlsx/stylesheet/color.rb 4927aaebe27dda42d78bb7baf9a44edc1753c77f +lib/axlsx.rb 3d1e5303c404a2c20dc007eae7f14fb59a0d3aae +lib/axlsx/version.rb 921bd286d3b4f56047b9f51f11d1aa16c0bf930a +lib/axlsx/package.rb d55d5445428d99d77b62d7c742f1c284a0ec4efd +lib/axlsx/drawing/pic.rb d91e014f8e2604480437a434f714ad25d31acbff +lib/axlsx/drawing/axis.rb 8eaf645e24c1fef43a475ceb28caf5116af25736 +lib/axlsx/doc_props/app.rb c64077808d7cb6aa30472e15c600009a01f3f338 +lib/axlsx/drawing/title.rb 497e6ddeb153bb230f5bf9dc76e799b91ae2a8ed +lib/axlsx/drawing/chart.rb bd437e8cb970bbd6df7488b2187199a1f0f3e376 +lib/axlsx/stylesheet/xf.rb 97e3c67007a182fc7df22e5c06f1510cfe5c11ac +lib/axlsx/doc_props/core.rb 90ebc8086f6606af02275c27068c359a5647faf0 +lib/axlsx/drawing/series.rb 168dbadedd446ff0f28bc9a5187b571d07a8936e +lib/axlsx/drawing/marker.rb 8b8c5ef799c7f56288e2951058a93db020846ea9 lib/axlsx/util/constants.rb 4dc8b1d765aa0593615a14c3761b0183be308908 -lib/axlsx/drawing/marker.rb 3507738522c02a3733a01f115d9ef22fae4ea542 -lib/axlsx/stylesheet/cell_protection.rb ce494f9add6de0a51407ddd9122fffe95759a48a -lib/axlsx/stylesheet/cell_style.rb 46c6ff183bce5c6b1ab6228823257d638007b03c -lib/axlsx/drawing/series_title.rb 8f088942649b5b5cc351b621bf8fb252f33cb510 -lib/axlsx/drawing/line_series.rb ffcd6d010ea0606f54a543eb1fc61022aac129d7 -lib/axlsx/drawing/series.rb 1cf010706e32e7e51affbc9edb9d4862a26b33ef -lib/axlsx/package.rb 339a8e5650f45623b126efddd22d3a5f0655aad9 -lib/axlsx/stylesheet/cell_alignment.rb f67f6a0bc16bf13669ed7b18714e4de23825ed94 -lib/axlsx/content_type/default.rb 8ec0d9d1e6bf261735739823acd460c271e3f5ed -lib/axlsx/drawing/title.rb b46fb082e3bea936d129c8aa0998f3b71c9838cc -lib/axlsx/drawing/axis.rb 5e37bac9f4dd258265213d5621522eed3c614954 -lib/axlsx/stylesheet/table_style_element.rb bee66d743e3113fb14adc7ebdecbeb606bfb49fc -lib/axlsx/content_type/content_type.rb 6c576e1618f99f7163fffa6b6e89e964653dcb5f +lib/axlsx/stylesheet/font.rb 1ee29414f720d26b7d484a90d8ebdaa7ecda4fa6 +lib/axlsx/drawing/view_3D.rb 8a83aed740c05d28aaa0e3430c7c4d2bbc44cc61 +lib/axlsx/drawing/drawing.rb 69b5fe2e76d64958e6c6529cabf6d2f717b0df81 +lib/axlsx/stylesheet/fill.rb 44c473c7eafc37690cae9de2cc11543c992752ff +lib/axlsx/util/validators.rb c70f27b943d3711fbe1244a8311789a6fad7e31e +lib/axlsx/drawing/scaling.rb 75a7a015a715bdd25f615ecdbe084d841fdc6ad0 +lib/axlsx/drawing/cat_axis.rb fde414377386d8ee7d1574e96d77a28a991ea21c +lib/axlsx/stylesheet/color.rb 442c205c92723c7b06f10e434ac03e2d09ab559f +lib/axlsx/drawing/ser_axis.rb 1f4952403738e3089e30deb266b1385679d46096 +lib/axlsx/drawing/val_axis.rb 8c1f847cff0b0c788c11b31ac55995566bef16b1 +lib/axlsx/stylesheet/border.rb cee9b6982c4a946f7caa850090f72d0d7ce0a0d2 +lib/axlsx/workbook/workbook.rb 96b55e7154132baf7dac707af3eea09583ef4d95 +lib/axlsx/stylesheet/styles.rb c5685e442e2a61f665e4aab479705bbc1889caed +lib/axlsx/rels/relationship.rb 8d279056b53ba22ff288187ff0f3d18273dcdcb7 +lib/axlsx/stylesheet/num_fmt.rb 796ee45611b89e8a670dcff3dd97ad9306f18048 +lib/axlsx/drawing/bar_series.rb ffe5dae5292d0324442b870fb1958847da6dde5e lib/axlsx/rels/relationships.rb 9c741e180796259bb378a789fd484fa1d8f04425 -lib/axlsx/stylesheet/num_fmt.rb dc830c6540465afa824881efa2f1ce4070957c47 -lib/axlsx.rb 7d8c589a0bdc16acf8774ae1b77d5177b030a80c -lib/axlsx/content_type/override.rb 72245683bca868f181d709a515f9152485653229 -lib/axlsx/drawing/graphic_frame.rb 9fb4e59405ea7974e9759906efd5c8c90dfa9b89 -lib/axlsx/drawing/pie_series.rb df339ed3eeb5692077e3a134339d04e77c9bc89b -lib/axlsx/drawing/bar_series.rb 76d41efe347318587a932f9313f03e0a76abb4ee -lib/axlsx/stylesheet/gradient_fill.rb 5fd260ec2b94ab75a970159035528548a9d21cd6 -lib/axlsx/workbook/worksheet/row.rb f866a98341ce4e604908e42d00f2af09e58c75d2 -lib/axlsx/util/simple_typed_list.rb b95f7e8d8958361cb1946b8545126b9384ff9fd2 -lib/axlsx/workbook/workbook.rb 12c82a584a9bfc4dfbb92c04426413d7eb44a504 -lib/axlsx/stylesheet/fill.rb 35966285f5d759d63451005ceae3a5ae5ba2ceca -lib/axlsx/drawing/view_3D.rb c8e25d57901dd7d679fe7d1ed674d5549ab6f1b3 -lib/axlsx/stylesheet/xf.rb e3d6e2e4c3b0b33c91de4c3db16c73aca3db4473 -lib/axlsx/drawing/two_cell_anchor.rb b89873e55820f9be35f8e5ebe22bd8a0d319622a -lib/axlsx/stylesheet/styles.rb 3679a8fe86270bdef96f02bcf76f2eac27b1c2ef -lib/axlsx/drawing/val_axis.rb da067622f8b09e6caf5067955b277d75ab3c8943 -lib/axlsx/drawing/cat_axis.rb f046262d1e8d04ff697fe29b88725225cd406cb2 -lib/axlsx/util/validators.rb 11eb309df0232fc1ad36c8c5ab0804d656b2294a -lib/axlsx/stylesheet/font.rb 8b002d5fcba2fb0979858517f5254aadf96c7e58 -lib/axlsx/doc_props/app.rb 52f01e985a33253987177798d4e79ed208649b30 -lib/axlsx/workbook/worksheet/worksheet.rb c7159356776e5ca1cfb6d0bc288c3acf278226c8 -lib/axlsx/workbook/worksheet/cell.rb b64976226d09066328cd1ae09763e324c4efada5 -lib/axlsx/rels/relationship.rb 067b924c964a870124d51ea6e39dc1cd8983db21 -lib/axlsx/stylesheet/border.rb 517bfcb43380919ce7abef494d5d3e50911b7c19 -lib/axlsx/drawing/ser_axis.rb 6d15f6cc2092ef5c3baa314ed1af793247418d9b -lib/axlsx/drawing/drawing.rb 243992f4dd131092c6981b3b8cb68905c55d7e1e -lib/axlsx/drawing/chart.rb b0bfdd0cc2f0f48ed3ddcf2a1b1c46c5d9cabc2e -lib/axlsx/version.rb ff68edc0a9bdaaaa00a81a27a3de4fa8fe4e70ce -lib/axlsx/stylesheet/gradient_stop.rb de34e289aeccb4abd9a3b7e60e816a0b12ffacff -lib/axlsx/drawing/cat_axis_data.rb f440010084afad99d97d31354f5b5a8ee8766e9b +lib/axlsx/drawing/pie_series.rb 66dfb2152f3b0e80b358c7af9061beb3c4ab984d +lib/axlsx/drawing/line_series.rb c7475484fd05284520a35806ff4562d125b2b3b8 +lib/axlsx/drawing/bar_3D_chart.rb 83de47e0e9a0c7b46bdc0ea255b50f9ee8a1d1a8 +lib/axlsx/stylesheet/border_pr.rb e8094ee1f75f5028d2ec68dce1590ee68dbede21 +lib/axlsx/content_type/default.rb 1c1a700e266964877599e8fdd28adb6771576030 +lib/axlsx/drawing/series_title.rb 2638d611b790db9281108110623fd71e8e79fae0 +lib/axlsx/drawing/pie_3D_chart.rb f9c70bd12b697dcd51780f29c037d4659b48e479 lib/axlsx/drawing/val_axis_data.rb c57c0abf5abb4aca9fba774f20e2f2c04d3020e8 -lib/axlsx/doc_props/core.rb 90ebc8086f6606af02275c27068c359a5647faf0 -lib/axlsx/drawing/pic.rb b728be1f2f927e02c08b55c7a03b8bc6059f8672 -lib/axlsx/drawing/bar_3D_chart.rb e5199cf0a33e416ea5ddf66677031ee08e5c116f -lib/axlsx/drawing/scaling.rb d3b59eed1897dc2b07bb41b2245c6e4b3e274d7e -lib/axlsx/stylesheet/pattern_fill.rb 817cf55beb3db160b2b56edb6c94de1ecf1ecee7 -lib/axlsx/drawing/one_cell_anchor.rb 512f300984cc9b2c4db73afb967b445d2e240ab7 -lib/axlsx/drawing/line_3D_chart.rb de0a2c8a49259e0348fd2c642c08eb4c567bcf1b +lib/axlsx/drawing/graphic_frame.rb 271e897616d85ebc069820c0d6a7dd3a716deff2 +lib/axlsx/drawing/line_3D_chart.rb 77bc8e6efbe42f8928fb6ffd3c2538ff99ec2444 +lib/axlsx/content_type/override.rb 43ff5dbbb01fbe0237a11c3da7fa5d8e1d5b67ef +lib/axlsx/drawing/cat_axis_data.rb f440010084afad99d97d31354f5b5a8ee8766e9b +lib/axlsx/stylesheet/cell_style.rb ceb0552421cb947584c1800c9aad43536fc7715d +lib/axlsx/util/simple_typed_list.rb b95f7e8d8958361cb1946b8545126b9384ff9fd2 +lib/axlsx/workbook/worksheet/row.rb 17cf7a468717fd6e01fddce1f00199307736adb5 +lib/axlsx/stylesheet/table_style.rb 3c3712b3958b6ae8f645971b0eb1fb92dd1dddbf +lib/axlsx/drawing/one_cell_anchor.rb 523ce88a5fd0245d119a6221ef88d629ed20c51e +lib/axlsx/stylesheet/table_styles.rb 805b00e2abd9b5e248590135067b6e43785e7240 +lib/axlsx/workbook/worksheet/cell.rb 33974b3d9807738d33943321d7864d36e1d5bcf8 +lib/axlsx/drawing/two_cell_anchor.rb 18b904330ac186f497a2c8d13e0b0de881340e09 +lib/axlsx/stylesheet/pattern_fill.rb 9ba1cf8983ab9fba89ca9489fd04714eb6a94a2b +lib/axlsx/stylesheet/gradient_stop.rb 56c3c6b030bad35ee6cff7ad3cd9207048dd4e68 +lib/axlsx/stylesheet/gradient_fill.rb 298777d050500c2f1f53294d8c71fce867997b3d +lib/axlsx/stylesheet/cell_alignment.rb 71118e51e1d11ab570fc89b8fbbd639b8023a39c +lib/axlsx/content_type/content_type.rb 6c576e1618f99f7163fffa6b6e89e964653dcb5f +lib/axlsx/stylesheet/cell_protection.rb 483e77c51f96cb52a805668b0ed40f14bf163634 +lib/axlsx/workbook/worksheet/worksheet.rb 0220616ef72c5bd3f7f4b94127c75a117b35b4d1 +lib/axlsx/stylesheet/table_style_element.rb 117b80432ed6191c81a9e07bd467281319d2b830 diff --git a/.yardoc/objects/root.dat b/.yardoc/objects/root.dat Binary files differindex 211638c5..d5d8617e 100644 --- a/.yardoc/objects/root.dat +++ b/.yardoc/objects/root.dat diff --git a/.yardoc/proxy_types b/.yardoc/proxy_types Binary files differindex bc38fbb8..3ba36e0a 100644 --- a/.yardoc/proxy_types +++ b/.yardoc/proxy_types @@ -1,4 +1,4 @@ --protected --no-private --title "AXLSX" -LICENSE CHANGELOG.md +--files LICENSE diff --git a/CHANGELOG.md b/CHANGELOG.md index 5c97382e..889a7469 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,20 @@ CHANGELOG --------- +- **October.23.11**: 1.0.8 release + - Added support for images (jpg, gif, png) in worksheets. + +- **October.23.11**: 1.0.7 released + - Added support for 3D options when creating a new chart. This lets you set the persective, rotation and other 3D attributes when using worksheet.add_chart + - Updated serialization write test to verify write permissions and warn if it cannot run the test due to permission restrcitions. + - updated rake to include build, genoc and deploy tasks. + - rebuilt documentation. + - moved version constant to its own file + - fixed bug in SerAxis that was requiring tickLblSkip and tickMarkSkip to be boolean. Should be unsigned int. + - Review and improve docs + - rebuild of anchor positioning to remove some spagetti code. Chart now supports a start_at and end_at method that accept an arrar for col/row positioning. See example6 for an example. You can still pass :start_at and :end_at options to worksheet.add_chart. + - Refactored cat and val axis data to keep series serialization a bit more DRY + ##October.22.11: 1.0.6 release - Bumping version to include docs. Bug in gemspec pointing to incorrect directory. @@ -6,15 +6,20 @@ Axlsx: Office Open XML Spreadsheet Generation **Author**: Randy Morgan **Copyright**: 2011 **License**: MIT License -**Latest Version**: 1.0.8 -**Ruby Version**: 1.8.7 -**Release Date**: November 23nd 2011 +**Latest Version**: 1.0.9 +**Ruby Version**: 1.8.7 - 1.9.3 +**Release Date**: November 26th 2011 Synopsis -------- Axlsx is an Office Open XML Spreadsheet generator for the Ruby programming language. -It enables the you to generate 100% valid xlsx files that include customised styling, images, 3D pie, bar and line charts and auto-width columns. Below is a summary of salient features. +With Axlsx you can create worksheets with charts, images, automated column width, customizable styles and full schema validation. Axlsx excels at helping you generate beautiful Office Open XML Spreadsheet documents without having to understand the entire ECMA specification. Check out the README for some examples of how easy it is. Best of all, you can validate your xlsx file before serialization so you know for sure that anything generated is going to load on your client's machine. + +Help Wanted +----------- + +I'd really like to get rid of the depenency on RMagick in this gem. RMagic is being used to calculate the column widths in a worksheet based on the content the user specified. If there happens to be anyone out there with the background and c skills to write an extenstion that can determine the width of a single character rendered with a specific font at a specific font size please give me a shout. Feature List ------------ @@ -147,6 +152,16 @@ Adding an Image end p.serialize("example7.xlsx") +Asian Language Support + + p = Axlsx::Package.new + p.workbook.add_worksheet do |sheet| + sheet.add_row ["日本語"] + sheet.add_row ["华语/華語"] + sheet.add_row ["한국어/조선말"] + end + p.serialize("example8.xlsx") + ###Documentation This gem is 100% documented with YARD, an exceptional documentation library. To see documentation for this, and all the gems installed on your system use: @@ -161,26 +176,12 @@ This gem has 100% test coverage using test/unit. To execute tests for this gem, Changelog --------- -- **October.23.11**: 1.0.8 release - - Added support for images (jpg, gif, png) in worksheets. - -- **October.23.11**: 1.0.7 released - - Added support for 3D options when creating a new chart. This lets you set the persective, rotation and other 3D attributes when using worksheet.add_chart - - Updated serialization write test to verify write permissions and warn if it cannot run the test due to permission restrcitions. - - updated rake to include build, genoc and deploy tasks. - - rebuilt documentation. - - moved version constant to its own file - - fixed bug in SerAxis that was requiring tickLblSkip and tickMarkSkip to be boolean. Should be unsigned int. - - Review and improve docs - - rebuild of anchor positioning to remove some spagetti code. Chart now supports a start_at and end_at method that accept an arrar for col/row positioning. See example6 for an example. You can still pass :start_at and :end_at options to worksheet.add_chart. - - Refactored cat and val axis data to keep series serialization a bit more DRY +- **October.26.11**: 1.0.9 release + - Updated to support ruby 1.9.3 + - Updated to eliminate all warnings originating in this gem Please see the {file:CHANGELOG.md} document for past release information. -Help Wanted ------------ - -I'd really like to get rid of the depenency on RMagick in this gem. RMagic is being used to calculate the column widths in a worksheet based on the content the user specified. If there happens to be anyone out there with the background and skill set to write an extenstion that can determine the width of a single character rendered with a specific font at a specific size please give me a shout. Copyright --------- @@ -4,7 +4,7 @@ task :build => :gendoc do system "gem build axlsx.gemspec" end -task :gendoc do +task :gendoc do system "yardoc" end diff --git a/axlsx.gemspec b/axlsx.gemspec index 4e865b94..a48f8417 100644 --- a/axlsx.gemspec +++ b/axlsx.gemspec @@ -1,22 +1,36 @@ +require 'rake' require File.expand_path(File.dirname(__FILE__) + '/lib/axlsx/version.rb') Gem::Specification.new do |s| s.name = 'axlsx' - s.rubyforge_project = 'axlsx' s.version = Axlsx::VERSION - s.date = Time.now.strftime('%Y-%m-%d') - s.summary = "Author fully validated xlsx files with custom charts and styles" - s.platform = Gem::Platform::RUBY - s.description = <<-eof - axslx allows you to create Office Open XML Spreadsheet documents. - It supports automated column widths, multiple worksheets, custom styles, cusomizable charts and allows you to validate your xlsx package before serialization. - eof s.author = "Randy Morgan" - s.email = '[email protected]' + s.email = '[email protected]' s.homepage = 'https://github.com/randym/axlsx' + s.platform = Gem::Platform::RUBY + s.date = Time.now.strftime('%Y-%m-%d') + s.summary = "OOXML (xlsx) with charts, styles, images and autowidth columns." s.has_rdoc = 'axlsx' - s.files = Dir.glob("{doc,lib,test,schema,examples}/**/*") + ['LICENSE','README.md','Rakefile','CHANGELOG.md'] - s.add_runtime_dependency 'nokogiri', '~> 1' + s.description = <<-eof + xlsx generation with charts, images, automated column width, customizable styles and full schema validation. Axlsx excels at helping you generate beautiful Office Open XML Spreadsheet documents without having to understand the entire ECMA specification. Check out the README for some examples of how easy it is. Best of all, you can validate your xlsx file before serialization so you know for sure that anything generated is going to load on your client's machine. + eof + # s.files = Dir.glob("{doc,lib,test,schema,examples}/**/*") + %w{ LICENSE README.md Rakefile CHANGELOG.md } + + s.files = FileList.new('*', 'lib/**/*', 'doc/**/*', 'test/**/*', 'schema/**/*', 'examples/**/*') do |fl| + fl.exclude("*.*~") + fl.exclude(".DS_Store") + fl.exclude(".gitignore") + fl.exclude(".yardops") + fl.exclude(".yardops_guide") + fl.exclude(".git") + fl.exclude(".*") + fl.exclude("todo") + fl.exclude("*.gem") + fl.exclude("*.xlsx") + end + s.add_runtime_dependency 'nokogiri', '~> 1.4' s.add_runtime_dependency 'active_support', '~> 3' - s.add_runtime_dependency 'rmagick', '~> 2.12' - s.add_runtime_dependency 'rubyzip', '~> 0.9.4' + s.add_runtime_dependency 'rmagick', '~> 2' + s.add_runtime_dependency 'zip', '~> 2' + s.require_path = 'lib' + s.required_ruby_version = '>= 1.8.7' end diff --git a/doc/Axlsx.html b/doc/Axlsx.html index 309542c2..05fbc258 100644 --- a/doc/Axlsx.html +++ b/doc/Axlsx.html @@ -6,7 +6,7 @@ <title> Module: Axlsx - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -72,8 +72,8 @@ <dt class="r1 last">Defined in:</dt> - <dd class="r1 last">lib/axlsx/package.rb<span class="defines">,<br /> - lib/axlsx.rb,<br /> lib/axlsx/version.rb,<br /> lib/axlsx/drawing/pic.rb,<br /> lib/axlsx/drawing/axis.rb,<br /> lib/axlsx/doc_props/app.rb,<br /> lib/axlsx/drawing/title.rb,<br /> lib/axlsx/drawing/chart.rb,<br /> lib/axlsx/stylesheet/xf.rb,<br /> lib/axlsx/doc_props/core.rb,<br /> lib/axlsx/drawing/series.rb,<br /> lib/axlsx/drawing/marker.rb,<br /> lib/axlsx/util/constants.rb,<br /> lib/axlsx/stylesheet/font.rb,<br /> lib/axlsx/drawing/view_3D.rb,<br /> lib/axlsx/drawing/drawing.rb,<br /> lib/axlsx/stylesheet/fill.rb,<br /> lib/axlsx/util/validators.rb,<br /> lib/axlsx/drawing/scaling.rb,<br /> lib/axlsx/drawing/cat_axis.rb,<br /> lib/axlsx/stylesheet/color.rb,<br /> lib/axlsx/drawing/ser_axis.rb,<br /> lib/axlsx/drawing/val_axis.rb,<br /> lib/axlsx/stylesheet/border.rb,<br /> lib/axlsx/workbook/workbook.rb,<br /> lib/axlsx/stylesheet/styles.rb,<br /> lib/axlsx/rels/relationship.rb,<br /> lib/axlsx/stylesheet/num_fmt.rb,<br /> lib/axlsx/drawing/bar_series.rb,<br /> lib/axlsx/rels/relationships.rb,<br /> lib/axlsx/drawing/pie_series.rb,<br /> lib/axlsx/drawing/line_series.rb,<br /> lib/axlsx/drawing/bar_3D_chart.rb,<br /> lib/axlsx/stylesheet/border_pr.rb,<br /> lib/axlsx/content_type/default.rb,<br /> lib/axlsx/drawing/series_title.rb,<br /> lib/axlsx/drawing/pie_3D_chart.rb,<br /> lib/axlsx/drawing/val_axis_data.rb,<br /> lib/axlsx/drawing/graphic_frame.rb,<br /> lib/axlsx/drawing/line_3D_chart.rb,<br /> lib/axlsx/content_type/override.rb,<br /> lib/axlsx/drawing/cat_axis_data.rb,<br /> lib/axlsx/stylesheet/cell_style.rb,<br /> lib/axlsx/util/simple_typed_list.rb,<br /> lib/axlsx/workbook/worksheet/row.rb,<br /> lib/axlsx/stylesheet/table_style.rb,<br /> lib/axlsx/drawing/one_cell_anchor.rb,<br /> lib/axlsx/stylesheet/table_styles.rb,<br /> lib/axlsx/workbook/worksheet/cell.rb,<br /> lib/axlsx/drawing/two_cell_anchor.rb,<br /> lib/axlsx/stylesheet/pattern_fill.rb,<br /> lib/axlsx/stylesheet/gradient_stop.rb,<br /> lib/axlsx/stylesheet/gradient_fill.rb,<br /> lib/axlsx/stylesheet/cell_alignment.rb,<br /> lib/axlsx/content_type/content_type.rb,<br /> lib/axlsx/stylesheet/cell_protection.rb,<br /> lib/axlsx/workbook/worksheet/worksheet.rb,<br /> lib/axlsx/stylesheet/table_style_element.rb</span> + <dd class="r1 last">lib/axlsx.rb<span class="defines">,<br /> + lib/axlsx/version.rb,<br /> lib/axlsx/package.rb,<br /> lib/axlsx/drawing/pic.rb,<br /> lib/axlsx/drawing/axis.rb,<br /> lib/axlsx/doc_props/app.rb,<br /> lib/axlsx/drawing/title.rb,<br /> lib/axlsx/drawing/chart.rb,<br /> lib/axlsx/stylesheet/xf.rb,<br /> lib/axlsx/doc_props/core.rb,<br /> lib/axlsx/drawing/series.rb,<br /> lib/axlsx/drawing/marker.rb,<br /> lib/axlsx/util/constants.rb,<br /> lib/axlsx/stylesheet/font.rb,<br /> lib/axlsx/drawing/view_3D.rb,<br /> lib/axlsx/drawing/drawing.rb,<br /> lib/axlsx/stylesheet/fill.rb,<br /> lib/axlsx/util/validators.rb,<br /> lib/axlsx/drawing/scaling.rb,<br /> lib/axlsx/drawing/cat_axis.rb,<br /> lib/axlsx/stylesheet/color.rb,<br /> lib/axlsx/drawing/ser_axis.rb,<br /> lib/axlsx/drawing/val_axis.rb,<br /> lib/axlsx/stylesheet/border.rb,<br /> lib/axlsx/workbook/workbook.rb,<br /> lib/axlsx/stylesheet/styles.rb,<br /> lib/axlsx/rels/relationship.rb,<br /> lib/axlsx/stylesheet/num_fmt.rb,<br /> lib/axlsx/drawing/bar_series.rb,<br /> lib/axlsx/rels/relationships.rb,<br /> lib/axlsx/drawing/pie_series.rb,<br /> lib/axlsx/drawing/line_series.rb,<br /> lib/axlsx/drawing/bar_3D_chart.rb,<br /> lib/axlsx/stylesheet/border_pr.rb,<br /> lib/axlsx/content_type/default.rb,<br /> lib/axlsx/drawing/series_title.rb,<br /> lib/axlsx/drawing/pie_3D_chart.rb,<br /> lib/axlsx/drawing/val_axis_data.rb,<br /> lib/axlsx/drawing/graphic_frame.rb,<br /> lib/axlsx/drawing/line_3D_chart.rb,<br /> lib/axlsx/content_type/override.rb,<br /> lib/axlsx/drawing/cat_axis_data.rb,<br /> lib/axlsx/stylesheet/cell_style.rb,<br /> lib/axlsx/util/simple_typed_list.rb,<br /> lib/axlsx/workbook/worksheet/row.rb,<br /> lib/axlsx/stylesheet/table_style.rb,<br /> lib/axlsx/drawing/one_cell_anchor.rb,<br /> lib/axlsx/stylesheet/table_styles.rb,<br /> lib/axlsx/workbook/worksheet/cell.rb,<br /> lib/axlsx/drawing/two_cell_anchor.rb,<br /> lib/axlsx/stylesheet/pattern_fill.rb,<br /> lib/axlsx/stylesheet/gradient_stop.rb,<br /> lib/axlsx/stylesheet/gradient_fill.rb,<br /> lib/axlsx/stylesheet/cell_alignment.rb,<br /> lib/axlsx/content_type/content_type.rb,<br /> lib/axlsx/stylesheet/cell_protection.rb,<br /> lib/axlsx/workbook/worksheet/worksheet.rb,<br /> lib/axlsx/stylesheet/table_style_element.rb</span> </dd> </dl> @@ -81,10 +81,14 @@ <h2>Overview</h2><div class="docstring"> <div class="discussion"> - <p> -Create Office Open XML Spreadsheets (xlsx) with safe and full control over -cell styles, automatically resized column widths and 3D pie charts. -</p> + +<p>xlsx generation with charts, images, automated column width, customizable +styles and full schema validation. Axlsx excels at helping you generate +beautiful Office Open XML Spreadsheet documents without having to +understand the entire ECMA specification. Check out the README for some +examples of how easy it is. Best of all, you can validate your xlsx file +before serialization so you know for sure that anything generated is going +to load on your client's machine.</p> </div> @@ -98,7 +102,7 @@ cell styles, automatically resized column widths and 3D pie charts. - <strong class="classes">Classes:</strong> <span class='object_link'><a href="Axlsx/App.html" title="Axlsx::App (class)">App</a></span>, <span class='object_link'><a href="Axlsx/Axis.html" title="Axlsx::Axis (class)">Axis</a></span>, <span class='object_link'><a href="Axlsx/Bar3DChart.html" title="Axlsx::Bar3DChart (class)">Bar3DChart</a></span>, <span class='object_link'><a href="Axlsx/BarSeries.html" title="Axlsx::BarSeries (class)">BarSeries</a></span>, <span class='object_link'><a href="Axlsx/Border.html" title="Axlsx::Border (class)">Border</a></span>, <span class='object_link'><a href="Axlsx/BorderPr.html" title="Axlsx::BorderPr (class)">BorderPr</a></span>, <span class='object_link'><a href="Axlsx/CatAxis.html" title="Axlsx::CatAxis (class)">CatAxis</a></span>, <span class='object_link'><a href="Axlsx/CatAxisData.html" title="Axlsx::CatAxisData (class)">CatAxisData</a></span>, <span class='object_link'><a href="Axlsx/Cell.html" title="Axlsx::Cell (class)">Cell</a></span>, <span class='object_link'><a href="Axlsx/CellAlignment.html" title="Axlsx::CellAlignment (class)">CellAlignment</a></span>, <span class='object_link'><a href="Axlsx/CellProtection.html" title="Axlsx::CellProtection (class)">CellProtection</a></span>, <span class='object_link'><a href="Axlsx/CellStyle.html" title="Axlsx::CellStyle (class)">CellStyle</a></span>, <span class='object_link'><a href="Axlsx/Chart.html" title="Axlsx::Chart (class)">Chart</a></span>, <span class='object_link'><a href="Axlsx/Color.html" title="Axlsx::Color (class)">Color</a></span>, <span class='object_link'><a href="Axlsx/ContentType.html" title="Axlsx::ContentType (class)">ContentType</a></span>, <span class='object_link'><a href="Axlsx/Core.html" title="Axlsx::Core (class)">Core</a></span>, <span class='object_link'><a href="Axlsx/DataTypeValidator.html" title="Axlsx::DataTypeValidator (class)">DataTypeValidator</a></span>, <span class='object_link'><a href="Axlsx/Default.html" title="Axlsx::Default (class)">Default</a></span>, <span class='object_link'><a href="Axlsx/Drawing.html" title="Axlsx::Drawing (class)">Drawing</a></span>, <span class='object_link'><a href="Axlsx/Fill.html" title="Axlsx::Fill (class)">Fill</a></span>, <span class='object_link'><a href="Axlsx/Font.html" title="Axlsx::Font (class)">Font</a></span>, <span class='object_link'><a href="Axlsx/GradientFill.html" title="Axlsx::GradientFill (class)">GradientFill</a></span>, <span class='object_link'><a href="Axlsx/GradientStop.html" title="Axlsx::GradientStop (class)">GradientStop</a></span>, <span class='object_link'><a href="Axlsx/GraphicFrame.html" title="Axlsx::GraphicFrame (class)">GraphicFrame</a></span>, <span class='object_link'><a href="Axlsx/Line3DChart.html" title="Axlsx::Line3DChart (class)">Line3DChart</a></span>, <span class='object_link'><a href="Axlsx/LineSeries.html" title="Axlsx::LineSeries (class)">LineSeries</a></span>, <span class='object_link'><a href="Axlsx/Marker.html" title="Axlsx::Marker (class)">Marker</a></span>, <span class='object_link'><a href="Axlsx/NumFmt.html" title="Axlsx::NumFmt (class)">NumFmt</a></span>, <span class='object_link'><a href="Axlsx/OneCellAnchor.html" title="Axlsx::OneCellAnchor (class)">OneCellAnchor</a></span>, <span class='object_link'><a href="Axlsx/Override.html" title="Axlsx::Override (class)">Override</a></span>, <span class='object_link'><a href="Axlsx/Package.html" title="Axlsx::Package (class)">Package</a></span>, <span class='object_link'><a href="Axlsx/PatternFill.html" title="Axlsx::PatternFill (class)">PatternFill</a></span>, <span class='object_link'><a href="Axlsx/Pic.html" title="Axlsx::Pic (class)">Pic</a></span>, <span class='object_link'><a href="Axlsx/Pie3DChart.html" title="Axlsx::Pie3DChart (class)">Pie3DChart</a></span>, <span class='object_link'><a href="Axlsx/PieSeries.html" title="Axlsx::PieSeries (class)">PieSeries</a></span>, <span class='object_link'><a href="Axlsx/RegexValidator.html" title="Axlsx::RegexValidator (class)">RegexValidator</a></span>, <span class='object_link'><a href="Axlsx/Relationship.html" title="Axlsx::Relationship (class)">Relationship</a></span>, <span class='object_link'><a href="Axlsx/Relationships.html" title="Axlsx::Relationships (class)">Relationships</a></span>, <span class='object_link'><a href="Axlsx/RestrictionValidator.html" title="Axlsx::RestrictionValidator (class)">RestrictionValidator</a></span>, <span class='object_link'><a href="Axlsx/Row.html" title="Axlsx::Row (class)">Row</a></span>, <span class='object_link'><a href="Axlsx/Scaling.html" title="Axlsx::Scaling (class)">Scaling</a></span>, <span class='object_link'><a href="Axlsx/SerAxis.html" title="Axlsx::SerAxis (class)">SerAxis</a></span>, <span class='object_link'><a href="Axlsx/Series.html" title="Axlsx::Series (class)">Series</a></span>, <span class='object_link'><a href="Axlsx/SeriesTitle.html" title="Axlsx::SeriesTitle (class)">SeriesTitle</a></span>, <span class='object_link'><a href="Axlsx/SimpleTypedList.html" title="Axlsx::SimpleTypedList (class)">SimpleTypedList</a></span>, <span class='object_link'><a href="Axlsx/Styles.html" title="Axlsx::Styles (class)">Styles</a></span>, <span class='object_link'><a href="Axlsx/TableStyle.html" title="Axlsx::TableStyle (class)">TableStyle</a></span>, <span class='object_link'><a href="Axlsx/TableStyleElement.html" title="Axlsx::TableStyleElement (class)">TableStyleElement</a></span>, <span class='object_link'><a href="Axlsx/TableStyles.html" title="Axlsx::TableStyles (class)">TableStyles</a></span>, <span class='object_link'><a href="Axlsx/Title.html" title="Axlsx::Title (class)">Title</a></span>, <span class='object_link'><a href="Axlsx/TwoCellAnchor.html" title="Axlsx::TwoCellAnchor (class)">TwoCellAnchor</a></span>, <span class='object_link'><a href="Axlsx/ValAxis.html" title="Axlsx::ValAxis (class)">ValAxis</a></span>, <span class='object_link'><a href="Axlsx/ValAxisData.html" title="Axlsx::ValAxisData (class)">ValAxisData</a></span>, <span class='object_link'><a href="Axlsx/View3D.html" title="Axlsx::View3D (class)">View3D</a></span>, <span class='object_link'><a href="Axlsx/Workbook.html" title="Axlsx::Workbook (class)">Workbook</a></span>, <span class='object_link'><a href="Axlsx/Worksheet.html" title="Axlsx::Worksheet (class)">Worksheet</a></span>, <span class='object_link'><a href="Axlsx/Xf.html" title="Axlsx::Xf (class)">Xf</a></span> + <strong class="classes">Classes:</strong> <span class='object_link'><a href="Axlsx/App.html" title="Axlsx::App (class)">App</a></span>, <span class='object_link'><a href="Axlsx/Axis.html" title="Axlsx::Axis (class)">Axis</a></span>, <span class='object_link'><a href="Axlsx/Bar3DChart.html" title="Axlsx::Bar3DChart (class)">Bar3DChart</a></span>, <span class='object_link'><a href="Axlsx/BarSeries.html" title="Axlsx::BarSeries (class)">BarSeries</a></span>, <span class='object_link'><a href="Axlsx/Border.html" title="Axlsx::Border (class)">Border</a></span>, <span class='object_link'><a href="Axlsx/BorderPr.html" title="Axlsx::BorderPr (class)">BorderPr</a></span>, <span class='object_link'><a href="Axlsx/CatAxis.html" title="Axlsx::CatAxis (class)">CatAxis</a></span>, <span class='object_link'><a href="Axlsx/CatAxisData.html" title="Axlsx::CatAxisData (class)">CatAxisData</a></span>, <span class='object_link'><a href="Axlsx/Cell.html" title="Axlsx::Cell (class)">Cell</a></span>, <span class='object_link'><a href="Axlsx/CellAlignment.html" title="Axlsx::CellAlignment (class)">CellAlignment</a></span>, <span class='object_link'><a href="Axlsx/CellProtection.html" title="Axlsx::CellProtection (class)">CellProtection</a></span>, <span class='object_link'><a href="Axlsx/CellStyle.html" title="Axlsx::CellStyle (class)">CellStyle</a></span>, <span class='object_link'><a href="Axlsx/Chart.html" title="Axlsx::Chart (class)">Chart</a></span>, <span class='object_link'><a href="Axlsx/Color.html" title="Axlsx::Color (class)">Color</a></span>, <span class='object_link'><a href="Axlsx/ContentType.html" title="Axlsx::ContentType (class)">ContentType</a></span>, <span class='object_link'><a href="Axlsx/Core.html" title="Axlsx::Core (class)">Core</a></span>, <span class='object_link'><a href="Axlsx/DataTypeValidator.html" title="Axlsx::DataTypeValidator (class)">DataTypeValidator</a></span>, <span class='object_link'><a href="Axlsx/Default.html" title="Axlsx::Default (class)">Default</a></span>, <span class='object_link'><a href="Axlsx/Drawing.html" title="Axlsx::Drawing (class)">Drawing</a></span>, <span class='object_link'><a href="Axlsx/Fill.html" title="Axlsx::Fill (class)">Fill</a></span>, <span class='object_link'><a href="Axlsx/Font.html" title="Axlsx::Font (class)">Font</a></span>, <span class='object_link'><a href="Axlsx/GradientFill.html" title="Axlsx::GradientFill (class)">GradientFill</a></span>, <span class='object_link'><a href="Axlsx/GradientStop.html" title="Axlsx::GradientStop (class)">GradientStop</a></span>, <span class='object_link'><a href="Axlsx/GraphicFrame.html" title="Axlsx::GraphicFrame (class)">GraphicFrame</a></span>, <span class='object_link'><a href="Axlsx/Line3DChart.html" title="Axlsx::Line3DChart (class)">Line3DChart</a></span>, <span class='object_link'><a href="Axlsx/LineSeries.html" title="Axlsx::LineSeries (class)">LineSeries</a></span>, <span class='object_link'><a href="Axlsx/Marker.html" title="Axlsx::Marker (class)">Marker</a></span>, <span class='object_link'><a href="Axlsx/NumFmt.html" title="Axlsx::NumFmt (class)">NumFmt</a></span>, <span class='object_link'><a href="Axlsx/OneCellAnchor.html" title="Axlsx::OneCellAnchor (class)">OneCellAnchor</a></span>, <span class='object_link'><a href="Axlsx/Override.html" title="Axlsx::Override (class)">Override</a></span>, <span class='object_link'><a href="Axlsx/Package.html" title="Axlsx::Package (class)">Package</a></span>, <span class='object_link'><a href="Axlsx/PatternFill.html" title="Axlsx::PatternFill (class)">PatternFill</a></span>, <span class='object_link'><a href="Axlsx/Pic.html" title="Axlsx::Pic (class)">Pic</a></span>, <span class='object_link'><a href="Axlsx/Pie3DChart.html" title="Axlsx::Pie3DChart (class)">Pie3DChart</a></span>, <span class='object_link'><a href="Axlsx/PieSeries.html" title="Axlsx::PieSeries (class)">PieSeries</a></span>, <span class='object_link'><a href="Axlsx/RegexValidator.html" title="Axlsx::RegexValidator (class)">RegexValidator</a></span>, <span class='object_link'><a href="Axlsx/Relationship.html" title="Axlsx::Relationship (class)">Relationship</a></span>, <span class='object_link'><a href="Axlsx/Relationships.html" title="Axlsx::Relationships (class)">Relationships</a></span>, <span class='object_link'><a href="Axlsx/RestrictionValidator.html" title="Axlsx::RestrictionValidator (class)">RestrictionValidator</a></span>, <span class='object_link'><a href="Axlsx/Row.html" title="Axlsx::Row (class)">Row</a></span>, <span class='object_link'><a href="Axlsx/Scaling.html" title="Axlsx::Scaling (class)">Scaling</a></span>, <span class='object_link'><a href="Axlsx/SerAxis.html" title="Axlsx::SerAxis (class)">SerAxis</a></span>, <span class='object_link'><a href="Axlsx/Series.html" title="Axlsx::Series (class)">Series</a></span>, <span class='object_link'><a href="Axlsx/SeriesTitle.html" title="Axlsx::SeriesTitle (class)">SeriesTitle</a></span>, <span class='object_link'><a href="Axlsx/Styles.html" title="Axlsx::Styles (class)">Styles</a></span>, <span class='object_link'><a href="Axlsx/TableStyle.html" title="Axlsx::TableStyle (class)">TableStyle</a></span>, <span class='object_link'><a href="Axlsx/TableStyleElement.html" title="Axlsx::TableStyleElement (class)">TableStyleElement</a></span>, <span class='object_link'><a href="Axlsx/TableStyles.html" title="Axlsx::TableStyles (class)">TableStyles</a></span>, <span class='object_link'><a href="Axlsx/Title.html" title="Axlsx::Title (class)">Title</a></span>, <span class='object_link'><a href="Axlsx/TwoCellAnchor.html" title="Axlsx::TwoCellAnchor (class)">TwoCellAnchor</a></span>, <span class='object_link'><a href="Axlsx/ValAxis.html" title="Axlsx::ValAxis (class)">ValAxis</a></span>, <span class='object_link'><a href="Axlsx/ValAxisData.html" title="Axlsx::ValAxisData (class)">ValAxisData</a></span>, <span class='object_link'><a href="Axlsx/View3D.html" title="Axlsx::View3D (class)">View3D</a></span>, <span class='object_link'><a href="Axlsx/Workbook.html" title="Axlsx::Workbook (class)">Workbook</a></span>, <span class='object_link'><a href="Axlsx/Worksheet.html" title="Axlsx::Worksheet (class)">Worksheet</a></span>, <span class='object_link'><a href="Axlsx/Xf.html" title="Axlsx::Xf (class)">Xf</a></span> </p> @@ -110,9 +114,8 @@ cell styles, automatically resized column widths and 3D pie charts. <dt id="VERSION-constant" class="">VERSION = <div class="docstring"> <div class="discussion"> - <p> -version -</p> + +<p>version</p> </div> @@ -122,15 +125,13 @@ version </div> </dt> - <dd><pre class="code"><span class='string val'>"1.0.8"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>1.0.9</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="ENCODING-constant" class="">ENCODING = <div class="docstring"> <div class="discussion"> - <p> -XML Encoding -</p> + +<p>XML Encoding</p> </div> @@ -140,15 +141,13 @@ XML Encoding </div> </dt> - <dd><pre class="code"><span class='string val'>"UTF-8"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>UTF-8</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="XML_NS-constant" class="">XML_NS = <div class="docstring"> <div class="discussion"> - <p> -spreadsheetML namespace -</p> + +<p>spreadsheetML namespace</p> </div> @@ -158,15 +157,13 @@ spreadsheetML namespace </div> </dt> - <dd><pre class="code"><span class='string val'>"http://schemas.openxmlformats.org/spreadsheetml/2006/main"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>http://schemas.openxmlformats.org/spreadsheetml/2006/main</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="XML_NS_T-constant" class="">XML_NS_T = <div class="docstring"> <div class="discussion"> - <p> -content-types namespace -</p> + +<p>content-types namespace</p> </div> @@ -176,15 +173,13 @@ content-types namespace </div> </dt> - <dd><pre class="code"><span class='string val'>"http://schemas.openxmlformats.org/package/2006/content-types"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>http://schemas.openxmlformats.org/package/2006/content-types</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="APP_NS-constant" class="">APP_NS = <div class="docstring"> <div class="discussion"> - <p> -extended-properties namespace -</p> + +<p>extended-properties namespace</p> </div> @@ -194,15 +189,13 @@ extended-properties namespace </div> </dt> - <dd><pre class="code"><span class='string val'>"http://schemas.openxmlformats.org/officeDocument/2006/extended-properties"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>http://schemas.openxmlformats.org/officeDocument/2006/extended-properties</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="APP_NS_VT-constant" class="">APP_NS_VT = <div class="docstring"> <div class="discussion"> - <p> -doc props namespace -</p> + +<p>doc props namespace</p> </div> @@ -212,15 +205,13 @@ doc props namespace </div> </dt> - <dd><pre class="code"><span class='string val'>"http://schemas.openxmlformats.org/officeDocument/2006/docPropsVTypes"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>http://schemas.openxmlformats.org/officeDocument/2006/docPropsVTypes</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="CORE_NS-constant" class="">CORE_NS = <div class="docstring"> <div class="discussion"> - <p> -core properties namespace -</p> + +<p>core properties namespace</p> </div> @@ -230,15 +221,13 @@ core properties namespace </div> </dt> - <dd><pre class="code"><span class='string val'>"http://schemas.openxmlformats.org/package/2006/metadata/core-properties"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>http://schemas.openxmlformats.org/package/2006/metadata/core-properties</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="CORE_NS_DC-constant" class="">CORE_NS_DC = <div class="docstring"> <div class="discussion"> - <p> -dc elements (core) namespace -</p> + +<p>dc elements (core) namespace</p> </div> @@ -248,15 +237,13 @@ dc elements (core) namespace </div> </dt> - <dd><pre class="code"><span class='string val'>"http://purl.org/dc/elements/1.1/"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>http://purl.org/dc/elements/1.1/</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="CORE_NS_DCMIT-constant" class="">CORE_NS_DCMIT = <div class="docstring"> <div class="discussion"> - <p> -dcmit (core) namespcace -</p> + +<p>dcmit (core) namespcace</p> </div> @@ -266,15 +253,13 @@ dcmit (core) namespcace </div> </dt> - <dd><pre class="code"><span class='string val'>"http://purl.org/dc/dcmitype/"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>http://purl.org/dc/dcmitype/</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="CORE_NS_DCT-constant" class="">CORE_NS_DCT = <div class="docstring"> <div class="discussion"> - <p> -dc terms namespace -</p> + +<p>dc terms namespace</p> </div> @@ -284,15 +269,13 @@ dc terms namespace </div> </dt> - <dd><pre class="code"><span class='string val'>"http://purl.org/dc/terms/"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>http://purl.org/dc/terms/</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="CORE_NS_XSI-constant" class="">CORE_NS_XSI = <div class="docstring"> <div class="discussion"> - <p> -xml schema namespace -</p> + +<p>xml schema namespace</p> </div> @@ -302,15 +285,13 @@ xml schema namespace </div> </dt> - <dd><pre class="code"><span class='string val'>"http://www.w3.org/2001/XMLSchema-instance"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>http://www.w3.org/2001/XMLSchema-instance</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="XML_NS_XDR-constant" class="">XML_NS_XDR = <div class="docstring"> <div class="discussion"> - <p> -spreadsheet drawing namespace -</p> + +<p>spreadsheet drawing namespace</p> </div> @@ -320,15 +301,13 @@ spreadsheet drawing namespace </div> </dt> - <dd><pre class="code"><span class='string val'>"http://schemas.openxmlformats.org/drawingml/2006/spreadsheetDrawing"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>http://schemas.openxmlformats.org/drawingml/2006/spreadsheetDrawing</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="XML_NS_A-constant" class="">XML_NS_A = <div class="docstring"> <div class="discussion"> - <p> -drawing namespace -</p> + +<p>drawing namespace</p> </div> @@ -338,15 +317,13 @@ drawing namespace </div> </dt> - <dd><pre class="code"><span class='string val'>"http://schemas.openxmlformats.org/drawingml/2006/main"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>http://schemas.openxmlformats.org/drawingml/2006/main</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="XML_NS_C-constant" class="">XML_NS_C = <div class="docstring"> <div class="discussion"> - <p> -chart namespace -</p> + +<p>chart namespace</p> </div> @@ -356,15 +333,13 @@ chart namespace </div> </dt> - <dd><pre class="code"><span class='string val'>"http://schemas.openxmlformats.org/drawingml/2006/chart"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>http://schemas.openxmlformats.org/drawingml/2006/chart</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="XML_NS_R-constant" class="">XML_NS_R = <div class="docstring"> <div class="discussion"> - <p> -relationships namespace -</p> + +<p>relationships namespace</p> </div> @@ -374,15 +349,13 @@ relationships namespace </div> </dt> - <dd><pre class="code"><span class='string val'>"http://schemas.openxmlformats.org/officeDocument/2006/relationships"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>http://schemas.openxmlformats.org/officeDocument/2006/relationships</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="RELS_R-constant" class="">RELS_R = <div class="docstring"> <div class="discussion"> - <p> -relationships name space -</p> + +<p>relationships name space</p> </div> @@ -392,15 +365,13 @@ relationships name space </div> </dt> - <dd><pre class="code"><span class='string val'>"http://schemas.openxmlformats.org/package/2006/relationships"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>http://schemas.openxmlformats.org/package/2006/relationships</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="TABLE_R-constant" class="">TABLE_R = <div class="docstring"> <div class="discussion"> - <p> -table rels namespace -</p> + +<p>table rels namespace</p> </div> @@ -410,15 +381,13 @@ table rels namespace </div> </dt> - <dd><pre class="code"><span class='string val'>"http://schemas.openxmlformats.org/officeDocument/2006/relationships/table"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>http://schemas.openxmlformats.org/officeDocument/2006/relationships/table</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="WORKBOOK_R-constant" class="">WORKBOOK_R = <div class="docstring"> <div class="discussion"> - <p> -workbook rels namespace -</p> + +<p>workbook rels namespace</p> </div> @@ -428,15 +397,13 @@ workbook rels namespace </div> </dt> - <dd><pre class="code"><span class='string val'>"http://schemas.openxmlformats.org/officeDocument/2006/relationships/officeDocument"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>http://schemas.openxmlformats.org/officeDocument/2006/relationships/officeDocument</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="WORKSHEET_R-constant" class="">WORKSHEET_R = <div class="docstring"> <div class="discussion"> - <p> -worksheet rels namespace -</p> + +<p>worksheet rels namespace</p> </div> @@ -446,15 +413,13 @@ worksheet rels namespace </div> </dt> - <dd><pre class="code"><span class='string val'>"http://schemas.openxmlformats.org/officeDocument/2006/relationships/worksheet"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>http://schemas.openxmlformats.org/officeDocument/2006/relationships/worksheet</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="APP_R-constant" class="">APP_R = <div class="docstring"> <div class="discussion"> - <p> -app rels namespace -</p> + +<p>app rels namespace</p> </div> @@ -464,15 +429,13 @@ app rels namespace </div> </dt> - <dd><pre class="code"><span class='string val'>"http://schemas.openxmlformats.org/officeDocument/2006/relationships/extended-properties"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>http://schemas.openxmlformats.org/officeDocument/2006/relationships/extended-properties</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="CORE_R-constant" class="">CORE_R = <div class="docstring"> <div class="discussion"> - <p> -core rels namespace -</p> + +<p>core rels namespace</p> </div> @@ -482,15 +445,13 @@ core rels namespace </div> </dt> - <dd><pre class="code"><span class='string val'>"http://schemas.openxmlformats.org/officeDocument/2006/relationships/metadata/core-properties"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>http://schemas.openxmlformats.org/officeDocument/2006/relationships/metadata/core-properties</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="STYLES_R-constant" class="">STYLES_R = <div class="docstring"> <div class="discussion"> - <p> -styles rels namespace -</p> + +<p>styles rels namespace</p> </div> @@ -500,15 +461,13 @@ styles rels namespace </div> </dt> - <dd><pre class="code"><span class='string val'>"http://schemas.openxmlformats.org/officeDocument/2006/relationships/styles"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>http://schemas.openxmlformats.org/officeDocument/2006/relationships/styles</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="DRAWING_R-constant" class="">DRAWING_R = <div class="docstring"> <div class="discussion"> - <p> -drawing rels namespace -</p> + +<p>drawing rels namespace</p> </div> @@ -518,15 +477,13 @@ drawing rels namespace </div> </dt> - <dd><pre class="code"><span class='string val'>"http://schemas.openxmlformats.org/officeDocument/2006/relationships/drawing"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>http://schemas.openxmlformats.org/officeDocument/2006/relationships/drawing</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="CHART_R-constant" class="">CHART_R = <div class="docstring"> <div class="discussion"> - <p> -chart rels namespace -</p> + +<p>chart rels namespace</p> </div> @@ -536,15 +493,13 @@ chart rels namespace </div> </dt> - <dd><pre class="code"><span class='string val'>"http://schemas.openxmlformats.org/officeDocument/2006/relationships/chart"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>http://schemas.openxmlformats.org/officeDocument/2006/relationships/chart</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="IMAGE_R-constant" class="">IMAGE_R = <div class="docstring"> <div class="discussion"> - <p> -image rels namespace -</p> + +<p>image rels namespace</p> </div> @@ -554,15 +509,13 @@ image rels namespace </div> </dt> - <dd><pre class="code"><span class='string val'>"http://schemas.openxmlformats.org/officeDocument/2006/relationships/image"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>http://schemas.openxmlformats.org/officeDocument/2006/relationships/image</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="TABLE_CT-constant" class="">TABLE_CT = <div class="docstring"> <div class="discussion"> - <p> -table content type -</p> + +<p>table content type</p> </div> @@ -572,15 +525,13 @@ table content type </div> </dt> - <dd><pre class="code"><span class='string val'>"application/vnd.openxmlformats-officedocument.spreadsheetml.table+xml"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>application/vnd.openxmlformats-officedocument.spreadsheetml.table+xml</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="WORKBOOK_CT-constant" class="">WORKBOOK_CT = <div class="docstring"> <div class="discussion"> - <p> -workbook content type -</p> + +<p>workbook content type</p> </div> @@ -590,15 +541,13 @@ workbook content type </div> </dt> - <dd><pre class="code"><span class='string val'>"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet.main+xml"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>application/vnd.openxmlformats-officedocument.spreadsheetml.sheet.main+xml</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="APP_CT-constant" class="">APP_CT = <div class="docstring"> <div class="discussion"> - <p> -app content type -</p> + +<p>app content type</p> </div> @@ -608,15 +557,13 @@ app content type </div> </dt> - <dd><pre class="code"><span class='string val'>"application/vnd.openxmlformats-officedocument.extended-properties+xml"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>application/vnd.openxmlformats-officedocument.extended-properties+xml</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="RELS_CT-constant" class="">RELS_CT = <div class="docstring"> <div class="discussion"> - <p> -rels content type -</p> + +<p>rels content type</p> </div> @@ -626,15 +573,13 @@ rels content type </div> </dt> - <dd><pre class="code"><span class='string val'>"application/vnd.openxmlformats-package.relationships+xml"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>application/vnd.openxmlformats-package.relationships+xml</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="STYLES_CT-constant" class="">STYLES_CT = <div class="docstring"> <div class="discussion"> - <p> -styles content type -</p> + +<p>styles content type</p> </div> @@ -644,15 +589,13 @@ styles content type </div> </dt> - <dd><pre class="code"><span class='string val'>"application/vnd.openxmlformats-officedocument.spreadsheetml.styles+xml"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>application/vnd.openxmlformats-officedocument.spreadsheetml.styles+xml</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="XML_CT-constant" class="">XML_CT = <div class="docstring"> <div class="discussion"> - <p> -xml content type -</p> + +<p>xml content type</p> </div> @@ -662,15 +605,13 @@ xml content type </div> </dt> - <dd><pre class="code"><span class='string val'>"application/xml"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>application/xml</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="WORKSHEET_CT-constant" class="">WORKSHEET_CT = <div class="docstring"> <div class="discussion"> - <p> -worksheet content type -</p> + +<p>worksheet content type</p> </div> @@ -680,15 +621,13 @@ worksheet content type </div> </dt> - <dd><pre class="code"><span class='string val'>"application/vnd.openxmlformats-officedocument.spreadsheetml.worksheet+xml"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>application/vnd.openxmlformats-officedocument.spreadsheetml.worksheet+xml</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="SHARED_STRINGS_CT-constant" class="">SHARED_STRINGS_CT = <div class="docstring"> <div class="discussion"> - <p> -shared strings content type -</p> + +<p>shared strings content type</p> </div> @@ -698,15 +637,13 @@ shared strings content type </div> </dt> - <dd><pre class="code"><span class='string val'>"application/vnd.openxmlformats-officedocument.spreadsheetml.sharedStrings+xml"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>application/vnd.openxmlformats-officedocument.spreadsheetml.sharedStrings+xml</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="CORE_CT-constant" class="">CORE_CT = <div class="docstring"> <div class="discussion"> - <p> -core content type -</p> + +<p>core content type</p> </div> @@ -716,15 +653,13 @@ core content type </div> </dt> - <dd><pre class="code"><span class='string val'>"application/vnd.openxmlformats-package.core-properties+xml"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>application/vnd.openxmlformats-package.core-properties+xml</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="CHART_CT-constant" class="">CHART_CT = <div class="docstring"> <div class="discussion"> - <p> -chart content type -</p> + +<p>chart content type</p> </div> @@ -734,15 +669,13 @@ chart content type </div> </dt> - <dd><pre class="code"><span class='string val'>"application/vnd.openxmlformats-officedocument.drawingml.chart+xml"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>application/vnd.openxmlformats-officedocument.drawingml.chart+xml</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="JPEG_CT-constant" class="">JPEG_CT = <div class="docstring"> <div class="discussion"> - <p> -jpeg content type -</p> + +<p>jpeg content type</p> </div> @@ -752,15 +685,13 @@ jpeg content type </div> </dt> - <dd><pre class="code"><span class='string val'>"image/jpeg"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>image/jpeg</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="GIF_CT-constant" class="">GIF_CT = <div class="docstring"> <div class="discussion"> - <p> -gif content type -</p> + +<p>gif content type</p> </div> @@ -770,15 +701,13 @@ gif content type </div> </dt> - <dd><pre class="code"><span class='string val'>"image/gif"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>image/gif</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="PNG_CT-constant" class="">PNG_CT = <div class="docstring"> <div class="discussion"> - <p> -png content type -</p> + +<p>png content type</p> </div> @@ -788,15 +717,13 @@ png content type </div> </dt> - <dd><pre class="code"><span class='string val'>"image/png"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>image/png</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="DRAWING_CT-constant" class="">DRAWING_CT = <div class="docstring"> <div class="discussion"> - <p> -drawing content type -</p> + +<p>drawing content type</p> </div> @@ -806,15 +733,13 @@ drawing content type </div> </dt> - <dd><pre class="code"><span class='string val'>"application/vnd.openxmlformats-officedocument.drawing+xml"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>application/vnd.openxmlformats-officedocument.drawing+xml</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="XML_EX-constant" class="">XML_EX = <div class="docstring"> <div class="discussion"> - <p> -xml content type extensions -</p> + +<p>xml content type extensions</p> </div> @@ -824,15 +749,13 @@ xml content type extensions </div> </dt> - <dd><pre class="code"><span class='string val'>"xml"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>xml</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="JPEG_EX-constant" class="">JPEG_EX = <div class="docstring"> <div class="discussion"> - <p> -jpeg extension -</p> + +<p>jpeg extension</p> </div> @@ -842,15 +765,13 @@ jpeg extension </div> </dt> - <dd><pre class="code"><span class='string val'>"jpeg"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>jpeg</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="GIF_EX-constant" class="">GIF_EX = <div class="docstring"> <div class="discussion"> - <p> -gif extension -</p> + +<p>gif extension</p> </div> @@ -860,15 +781,13 @@ gif extension </div> </dt> - <dd><pre class="code"><span class='string val'>"gif"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>gif</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="PNG_EX-constant" class="">PNG_EX = <div class="docstring"> <div class="discussion"> - <p> -png extension -</p> + +<p>png extension</p> </div> @@ -878,15 +797,13 @@ png extension </div> </dt> - <dd><pre class="code"><span class='string val'>"png"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>png</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="RELS_EX-constant" class="">RELS_EX = <div class="docstring"> <div class="discussion"> - <p> -rels content type extension -</p> + +<p>rels content type extension</p> </div> @@ -896,15 +813,13 @@ rels content type extension </div> </dt> - <dd><pre class="code"><span class='string val'>"rels"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>rels</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="WORKBOOK_PN-constant" class="">WORKBOOK_PN = <div class="docstring"> <div class="discussion"> - <p> -workbook part -</p> + +<p>workbook part</p> </div> @@ -914,15 +829,13 @@ workbook part </div> </dt> - <dd><pre class="code"><span class='string val'>"xl/workbook.xml"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>xl/workbook.xml</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="STYLES_PN-constant" class="">STYLES_PN = <div class="docstring"> <div class="discussion"> - <p> -styles part -</p> + +<p>styles part</p> </div> @@ -932,15 +845,13 @@ styles part </div> </dt> - <dd><pre class="code"><span class='string val'>"styles.xml"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>styles.xml</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="APP_PN-constant" class="">APP_PN = <div class="docstring"> <div class="discussion"> - <p> -app part -</p> + +<p>app part</p> </div> @@ -950,15 +861,13 @@ app part </div> </dt> - <dd><pre class="code"><span class='string val'>"docProps/app.xml"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>docProps/app.xml</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="CORE_PN-constant" class="">CORE_PN = <div class="docstring"> <div class="discussion"> - <p> -core part -</p> + +<p>core part</p> </div> @@ -968,15 +877,13 @@ core part </div> </dt> - <dd><pre class="code"><span class='string val'>"docProps/core.xml"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>docProps/core.xml</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="CONTENT_TYPES_PN-constant" class="">CONTENT_TYPES_PN = <div class="docstring"> <div class="discussion"> - <p> -content types part -</p> + +<p>content types part</p> </div> @@ -986,15 +893,13 @@ content types part </div> </dt> - <dd><pre class="code"><span class='string val'>"[Content_Types].xml"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>[Content_Types].xml</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="RELS_PN-constant" class="">RELS_PN = <div class="docstring"> <div class="discussion"> - <p> -rels part -</p> + +<p>rels part</p> </div> @@ -1004,15 +909,13 @@ rels part </div> </dt> - <dd><pre class="code"><span class='string val'>"_rels/.rels"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>_rels/.rels</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="WORKBOOK_RELS_PN-constant" class="">WORKBOOK_RELS_PN = <div class="docstring"> <div class="discussion"> - <p> -workbook rels part -</p> + +<p>workbook rels part</p> </div> @@ -1022,15 +925,13 @@ workbook rels part </div> </dt> - <dd><pre class="code"><span class='string val'>"xl/_rels/workbook.xml.rels"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>xl/_rels/workbook.xml.rels</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="WORKSHEET_PN-constant" class="">WORKSHEET_PN = <div class="docstring"> <div class="discussion"> - <p> -worksheet part -</p> + +<p>worksheet part</p> </div> @@ -1040,15 +941,13 @@ worksheet part </div> </dt> - <dd><pre class="code"><span class='string val'>"worksheets/sheet%d.xml"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>worksheets/sheet%d.xml</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="WORKSHEET_RELS_PN-constant" class="">WORKSHEET_RELS_PN = <div class="docstring"> <div class="discussion"> - <p> -worksheet rels part -</p> + +<p>worksheet rels part</p> </div> @@ -1058,15 +957,13 @@ worksheet rels part </div> </dt> - <dd><pre class="code"><span class='string val'>"worksheets/_rels/sheet%d.xml.rels"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>worksheets/_rels/sheet%d.xml.rels</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="DRAWING_PN-constant" class="">DRAWING_PN = <div class="docstring"> <div class="discussion"> - <p> -drawing part -</p> + +<p>drawing part</p> </div> @@ -1076,15 +973,13 @@ drawing part </div> </dt> - <dd><pre class="code"><span class='string val'>"drawings/drawing%d.xml"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>drawings/drawing%d.xml</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="DRAWING_RELS_PN-constant" class="">DRAWING_RELS_PN = <div class="docstring"> <div class="discussion"> - <p> -drawing rels part -</p> + +<p>drawing rels part</p> </div> @@ -1094,15 +989,13 @@ drawing rels part </div> </dt> - <dd><pre class="code"><span class='string val'>"drawings/_rels/drawing%d.xml.rels"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>drawings/_rels/drawing%d.xml.rels</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="CHART_PN-constant" class="">CHART_PN = <div class="docstring"> <div class="discussion"> - <p> -chart part -</p> + +<p>chart part</p> </div> @@ -1112,15 +1005,13 @@ chart part </div> </dt> - <dd><pre class="code"><span class='string val'>"charts/chart%d.xml"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>charts/chart%d.xml</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="IMAGE_PN-constant" class="">IMAGE_PN = <div class="docstring"> <div class="discussion"> - <p> -chart part -</p> + +<p>chart part</p> </div> @@ -1130,15 +1021,13 @@ chart part </div> </dt> - <dd><pre class="code"><span class='string val'>"media/image%d.%s"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>media/image%d.%s</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="APP_XSD-constant" class="">APP_XSD = <div class="docstring"> <div class="discussion"> - <p> -App validation schema -</p> + +<p>App validation schema</p> </div> @@ -1148,15 +1037,13 @@ App validation schema </div> </dt> - <dd><pre class="code"><span class='string val'>"lib/schema/shared-documentPropertiesExtended.xsd"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>lib/schema/shared-documentPropertiesExtended.xsd</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="CORE_XSD-constant" class="">CORE_XSD = <div class="docstring"> <div class="discussion"> - <p> -core validation schema -</p> + +<p>core validation schema</p> </div> @@ -1166,15 +1053,13 @@ core validation schema </div> </dt> - <dd><pre class="code"><span class='string val'>"lib/schema/opc-coreProperties.xsd"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>lib/schema/opc-coreProperties.xsd</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="CONTENT_TYPES_XSD-constant" class="">CONTENT_TYPES_XSD = <div class="docstring"> <div class="discussion"> - <p> -content types validation schema -</p> + +<p>content types validation schema</p> </div> @@ -1184,15 +1069,13 @@ content types validation schema </div> </dt> - <dd><pre class="code"><span class='string val'>"lib/schema/opc-contentTypes.xsd"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>lib/schema/opc-contentTypes.xsd</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="RELS_XSD-constant" class="">RELS_XSD = <div class="docstring"> <div class="discussion"> - <p> -rels validation schema -</p> + +<p>rels validation schema</p> </div> @@ -1202,15 +1085,13 @@ rels validation schema </div> </dt> - <dd><pre class="code"><span class='string val'>"lib/schema/opc-relationships.xsd"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>lib/schema/opc-relationships.xsd</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="SML_XSD-constant" class="">SML_XSD = <div class="docstring"> <div class="discussion"> - <p> -spreadsheetML validation schema -</p> + +<p>spreadsheetML validation schema</p> </div> @@ -1220,15 +1101,13 @@ spreadsheetML validation schema </div> </dt> - <dd><pre class="code"><span class='string val'>"lib/schema/sml.xsd"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>lib/schema/sml.xsd</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="DRAWING_XSD-constant" class="">DRAWING_XSD = <div class="docstring"> <div class="discussion"> - <p> -drawing validation schema -</p> + +<p>drawing validation schema</p> </div> @@ -1238,15 +1117,13 @@ drawing validation schema </div> </dt> - <dd><pre class="code"><span class='string val'>"lib/schema/dml-spreadsheetDrawing.xsd"</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>lib/schema/dml-spreadsheetDrawing.xsd</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="NUM_FMT_PERCENT-constant" class="">NUM_FMT_PERCENT = <div class="docstring"> <div class="discussion"> - <p> -number format id for pecentage formatting using the default formatting id. -</p> + +<p>number format id for pecentage formatting using the default formatting id.</p> </div> @@ -1256,15 +1133,13 @@ number format id for pecentage formatting using the default formatting id. </div> </dt> - <dd><pre class="code"><span class='integer val'>9</span> -</pre></dd> + <dd><pre class="code"><span class='int'>9</span></pre></dd> <dt id="NUM_FMT_YYYYMMDD-constant" class="">NUM_FMT_YYYYMMDD = <div class="docstring"> <div class="discussion"> - <p> -number format id for date format like 2011/11/13 -</p> + +<p>number format id for date format like 2011/11/13</p> </div> @@ -1274,15 +1149,13 @@ number format id for date format like 2011/11/13 </div> </dt> - <dd><pre class="code"><span class='integer val'>100</span> -</pre></dd> + <dd><pre class="code"><span class='int'>100</span></pre></dd> <dt id="NUM_FMT_YYYYMMDDHHMMSS-constant" class="">NUM_FMT_YYYYMMDDHHMMSS = <div class="docstring"> <div class="discussion"> - <p> -number format id for time format the creates 2011/11/13 12:23:10 -</p> + +<p>number format id for time format the creates 2011/11/13 12:23:10</p> </div> @@ -1292,15 +1165,13 @@ number format id for time format the creates 2011/11/13 12:23:10 </div> </dt> - <dd><pre class="code"><span class='integer val'>101</span> -</pre></dd> + <dd><pre class="code"><span class='int'>101</span></pre></dd> <dt id="STYLE_THIN_BORDER-constant" class="">STYLE_THIN_BORDER = <div class="docstring"> <div class="discussion"> - <p> -cellXfs id for thin borders around the cell -</p> + +<p>cellXfs id for thin borders around the cell</p> </div> @@ -1310,15 +1181,13 @@ cellXfs id for thin borders around the cell </div> </dt> - <dd><pre class="code"><span class='integer val'>1</span> -</pre></dd> + <dd><pre class="code"><span class='int'>1</span></pre></dd> <dt id="ERR_RESTRICTION-constant" class="">ERR_RESTRICTION = <div class="docstring"> <div class="discussion"> - <p> -error messages RestrictionValidor -</p> + +<p>error messages RestrictionValidor</p> </div> @@ -1328,15 +1197,13 @@ error messages RestrictionValidor </div> </dt> - <dd><pre class="code"><span class='string val'>"Invalid Data: %s. %s must be one of %s."</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Invalid Data: %s. %s must be one of %s.</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="ERR_TYPE-constant" class="">ERR_TYPE = <div class="docstring"> <div class="discussion"> - <p> -error message DataTypeValidator -</p> + +<p>error message DataTypeValidator</p> </div> @@ -1346,15 +1213,13 @@ error message DataTypeValidator </div> </dt> - <dd><pre class="code"><span class='string val'>"Invalid Data %s for %s. must be %s."</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Invalid Data %s for %s. must be %s.</span><span class='tstring_end'>"</span></span></pre></dd> <dt id="ERR_REGEX-constant" class="">ERR_REGEX = <div class="docstring"> <div class="discussion"> - <p> -error message for RegexValidator -</p> + +<p>error message for RegexValidator</p> </div> @@ -1364,8 +1229,7 @@ error message for RegexValidator </div> </dt> - <dd><pre class="code"><span class='string val'>"Invalid Data. %s does not match %s."</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Invalid Data. %s does not match %s.</span><span class='tstring_end'>"</span></span></pre></dd> </dl> @@ -1398,9 +1262,8 @@ error message for RegexValidator - <span class="summary_desc"><div class='inline'><p> -determines the cell range for the items provided. -</p> + <span class="summary_desc"><div class='inline'> +<p>determines the cell range for the items provided.</p> </div></span> </li> @@ -1422,10 +1285,9 @@ determines the cell range for the items provided. - <span class="summary_desc"><div class='inline'><p> -Requires that the value is a form that can be evaluated as a boolean in an -xml document. -</p> + <span class="summary_desc"><div class='inline'> +<p>Requires that the value is a form that can be evaluated as a boolean in an +xml document.</p> </div></span> </li> @@ -1447,11 +1309,10 @@ xml document. - <span class="summary_desc"><div class='inline'><p> -Requires that the value is a valid content_type TABLE_CT, WORKBOOK_CT, + <span class="summary_desc"><div class='inline'> +<p>Requires that the value is a valid content_type TABLE_CT, WORKBOOK_CT, APP_CT, RELS_CT, STYLES_CT, XML_CT, WORKSHEET_CT, SHARED_STRINGS_CT, -CORE_CT, CHART_CT, DRAWING_CT are allowed. -</p> +CORE_CT, CHART_CT, DRAWING_CT are allowed.</p> </div></span> </li> @@ -1473,9 +1334,8 @@ CORE_CT, CHART_CT, DRAWING_CT are allowed. - <span class="summary_desc"><div class='inline'><p> -Requires that the value is a Float. -</p> + <span class="summary_desc"><div class='inline'> +<p>Requires that the value is a Float.</p> </div></span> </li> @@ -1497,9 +1357,8 @@ Requires that the value is a Float. - <span class="summary_desc"><div class='inline'><p> -Requires that the value is a gradient_type. -</p> + <span class="summary_desc"><div class='inline'> +<p>Requires that the value is a gradient_type.</p> </div></span> </li> @@ -1521,11 +1380,10 @@ Requires that the value is a gradient_type. - <span class="summary_desc"><div class='inline'><p> -Requires that the value is a valid horizontal_alignment :general, :left, + <span class="summary_desc"><div class='inline'> +<p>Requires that the value is a valid horizontal_alignment :general, :left, :center, :right, :fill, :justify, :centerContinuous, :distributed are -allowed. -</p> +allowed.</p> </div></span> </li> @@ -1547,9 +1405,8 @@ allowed. - <span class="summary_desc"><div class='inline'><p> -Requires that the value is a Fixnum or Integer. -</p> + <span class="summary_desc"><div class='inline'> +<p>Requires that the value is a Fixnum or Integer.</p> </div></span> </li> @@ -1571,9 +1428,8 @@ Requires that the value is a Fixnum or Integer. - <span class="summary_desc"><div class='inline'><p> -Requires that the value is valid pattern type. -</p> + <span class="summary_desc"><div class='inline'> +<p>Requires that the value is valid pattern type.</p> </div></span> </li> @@ -1595,11 +1451,10 @@ Requires that the value is valid pattern type. - <span class="summary_desc"><div class='inline'><p> -Requires that the value is a valid relationship_type XML_NS_R, TABLE_R, + <span class="summary_desc"><div class='inline'> +<p>Requires that the value is a valid relationship_type XML_NS_R, TABLE_R, WORKBOOK_R, WORKSHEET_R, APP_R, RELS_R, CORE_R, STYLES_R, CHART_R, -DRAWING_R are allowed. -</p> +DRAWING_R are allowed.</p> </div></span> </li> @@ -1621,9 +1476,8 @@ DRAWING_R are allowed. - <span class="summary_desc"><div class='inline'><p> -Requires that the value is a String. -</p> + <span class="summary_desc"><div class='inline'> +<p>Requires that the value is a String.</p> </div></span> </li> @@ -1645,8 +1499,8 @@ Requires that the value is a String. - <span class="summary_desc"><div class='inline'><p> -Requires that the value is a valid table element type :wholeTable, + <span class="summary_desc"><div class='inline'> +<p>Requires that the value is a valid table element type :wholeTable, :headerRow, :totalRow, :firstColumn, :lastColumn, :firstRowStripe, :secondRowStripe, :firstColumnStripe, :secondColumnStripe, :firstHeaderCell, :lastHeaderCell, :firstTotalCell, :lastTotalCell, @@ -1654,8 +1508,7 @@ Requires that the value is a valid table element type :wholeTable, :firstSubtotalRow, :secondSubtotalRow, :thirdSubtotalRow, :blankRow, :firstColumnSubheading, :secondColumnSubheading, :thirdColumnSubheading, :firstRowSubheading, :secondRowSubheading, :thirdRowSubheading, -:pageFieldLabels, :pageFieldValues are allowed. -</p> +:pageFieldLabels, :pageFieldValues are allowed.</p> </div></span> </li> @@ -1677,10 +1530,9 @@ Requires that the value is a valid table element type :wholeTable, - <span class="summary_desc"><div class='inline'><p> -Requires that the value is a Fixnum or Integer and is greater or equal to -0. -</p> + <span class="summary_desc"><div class='inline'> +<p>Requires that the value is a Fixnum or Integer and is greater or equal to +0.</p> </div></span> </li> @@ -1702,10 +1554,9 @@ Requires that the value is a Fixnum or Integer and is greater or equal to - <span class="summary_desc"><div class='inline'><p> -Requires that the value is a valid vertical_alignment :top, :center, -:bottom, :justify, :distributed are allowed. -</p> + <span class="summary_desc"><div class='inline'> +<p>Requires that the value is a valid vertical_alignment :top, :center, +:bottom, :justify, :distributed are allowed.</p> </div></span> </li> @@ -1729,9 +1580,8 @@ Requires that the value is a valid vertical_alignment :top, :center, </p><div class="docstring"> <div class="discussion"> - <p> -determines the cell range for the items provided -</p> + +<p>determines the cell range for the items provided</p> </div> @@ -1745,21 +1595,24 @@ determines the cell range for the items provided <pre class="lines"> -31 -32 -33 -34 -35</pre> +36 +37 +38 +39 +40 +41 +42</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx.rb', line 31</span> - -<span class='def def kw'>def</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='cell_range identifier id'>cell_range</span><span class='lparen token'>(</span><span class='items identifier id'>items</span><span class='rparen token'>)</span> - <span class='return return kw'>return</span> <span class='string val'>""</span> <span class='unless unless_mod kw'>unless</span> <span class='items identifier id'>items</span><span class='dot token'>.</span><span class='first identifier id'>first</span><span class='dot token'>.</span><span class='is_a? fid id'>is_a?</span> <span class='Cell constant id'>Cell</span> - <span class='dstring node'>"#{items.first.row.worksheet.name}!"</span> <span class='plus op'>+</span> - <span class='dstring node'>"#{items.first.r_abs}:#{items.last.r_abs}"</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx.rb', line 36</span> + +<span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id cell_range'>cell_range</span><span class='lparen'>(</span><span class='id items'>items</span><span class='rparen'>)</span> + <span class='kw'>return</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_end'>"</span></span> <span class='kw'>unless</span> <span class='id items'>items</span><span class='period'>.</span><span class='id first'>first</span><span class='period'>.</span><span class='id is_a?'>is_a?</span> <span class='const'>Cell</span> + <span class='id ref'>ref</span> <span class='op'>=</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='id items'>items</span><span class='period'>.</span><span class='id first'>first</span><span class='period'>.</span><span class='id row'>row</span><span class='period'>.</span><span class='id worksheet'>worksheet</span><span class='period'>.</span><span class='id name'>name</span><span class='rbrace'>}</span><span class='tstring_content'>!</span><span class='tstring_end'>"</span></span> <span class='op'>+</span> + <span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='id items'>items</span><span class='period'>.</span><span class='id first'>first</span><span class='period'>.</span><span class='id r_abs'>r_abs</span><span class='rbrace'>}</span><span class='tstring_end'>"</span></span> + <span class='id ref'>ref</span> <span class='op'>+=</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>:</span><span class='embexpr_beg'>#{</span><span class='id items'>items</span><span class='period'>.</span><span class='id last'>last</span><span class='period'>.</span><span class='id r_abs'>r_abs</span><span class='rbrace'>}</span><span class='tstring_end'>"</span></span> <span class='kw'>if</span> <span class='id items'>items</span><span class='period'>.</span><span class='id size'>size</span> <span class='op'>></span> <span class='int'>1</span> + <span class='id ref'>ref</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1774,13 +1627,11 @@ determines the cell range for the items provided </p><div class="docstring"> <div class="discussion"> - <p> -Requires that the value is a form that can be evaluated as a boolean in an + +<p>Requires that the value is a form that can be evaluated as a boolean in an xml document. The value must be an instance of Fixnum, String, Integer, -Symbol, TrueClass or FalseClass and it must be one of 0, 1, -"true", "false", :true, :false, true, false, -"0", or "1" -</p> +Symbol, TrueClass or FalseClass and it must be one of 0, 1, "true", +"false", :true, :false, true, false, "0", or "1"</p> </div> @@ -1799,9 +1650,8 @@ Symbol, TrueClass or FalseClass and it must be one of 0, 1, — - <div class='inline'><p> -The value validated -</p> + <div class='inline'> +<p>The value validated</p> </div> </li> @@ -1822,10 +1672,9 @@ The value validated <td> <pre class="code"><span class="info file"># File 'lib/axlsx/util/validators.rb', line 65</span> -<span class='def def kw'>def</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='validate_boolean identifier id'>validate_boolean</span><span class='lparen token'>(</span><span class='v identifier id'>v</span><span class='rparen token'>)</span> - <span class='DataTypeValidator constant id'>DataTypeValidator</span><span class='dot token'>.</span><span class='validate identifier id'>validate</span><span class='lparen token'>(</span><span class='symbol val'>:boolean</span><span class='comma token'>,</span> <span class='lbrack token'>[</span><span class='Fixnum constant id'>Fixnum</span><span class='comma token'>,</span> <span class='String constant id'>String</span><span class='comma token'>,</span> <span class='Integer constant id'>Integer</span><span class='comma token'>,</span> <span class='Symbol constant id'>Symbol</span><span class='comma token'>,</span> <span class='TrueClass constant id'>TrueClass</span><span class='comma token'>,</span> <span class='FalseClass constant id'>FalseClass</span><span class='rbrack token'>]</span><span class='comma token'>,</span> <span class='v identifier id'>v</span><span class='comma token'>,</span> <span class='lambda identifier id'>lambda</span> <span class='lbrace token'>{</span> <span class='bitor op'>|</span><span class='v identifier id'>v</span><span class='bitor op'>|</span> <span class='lbrack token'>[</span><span class='integer val'>0</span><span class='comma token'>,</span> <span class='integer val'>1</span><span class='comma token'>,</span> <span class='string val'>"true"</span><span class='comma token'>,</span> <span class='string val'>"false"</span><span class='comma token'>,</span> <span class='symbol val'>:true</span><span class='comma token'>,</span> <span class='symbol val'>:false</span><span class='comma token'>,</span> <span class='true true kw'>true</span><span class='comma token'>,</span> <span class='false false kw'>false</span><span class='comma token'>,</span> <span class='string val'>"0"</span><span class='comma token'>,</span> <span class='string val'>"1"</span><span class='rbrack token'>]</span><span class='dot token'>.</span><span class='include? fid id'>include?</span><span class='lparen token'>(</span><span class='v identifier id'>v</span><span class='rparen token'>)</span> <span class='rbrace token'>}</span><span class='rparen token'>)</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id validate_boolean'>validate_boolean</span><span class='lparen'>(</span><span class='id v'>v</span><span class='rparen'>)</span> + <span class='const'>DataTypeValidator</span><span class='period'>.</span><span class='id validate'>validate</span><span class='lparen'>(</span><span class='symbol'>:boolean</span><span class='comma'>,</span> <span class='lbracket'>[</span><span class='const'>Fixnum</span><span class='comma'>,</span> <span class='const'>String</span><span class='comma'>,</span> <span class='const'>Integer</span><span class='comma'>,</span> <span class='const'>Symbol</span><span class='comma'>,</span> <span class='const'>TrueClass</span><span class='comma'>,</span> <span class='const'>FalseClass</span><span class='rbracket'>]</span><span class='comma'>,</span> <span class='id v'>v</span><span class='comma'>,</span> <span class='id lambda'>lambda</span> <span class='lbrace'>{</span> <span class='op'>|</span><span class='id arg'>arg</span><span class='op'>|</span> <span class='lbracket'>[</span><span class='int'>0</span><span class='comma'>,</span> <span class='int'>1</span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>true</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>false</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='symbol'>:true</span><span class='comma'>,</span> <span class='symbol'>:false</span><span class='comma'>,</span> <span class='kw'>true</span><span class='comma'>,</span> <span class='kw'>false</span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>0</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>1</span><span class='tstring_end'>"</span></span><span class='rbracket'>]</span><span class='period'>.</span><span class='id include?'>include?</span><span class='lparen'>(</span><span class='id arg'>arg</span><span class='rparen'>)</span> <span class='rbrace'>}</span><span class='rparen'>)</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1840,11 +1689,10 @@ The value validated </p><div class="docstring"> <div class="discussion"> - <p> -Requires that the value is a valid content_type TABLE_CT, WORKBOOK_CT, + +<p>Requires that the value is a valid content_type TABLE_CT, WORKBOOK_CT, APP_CT, RELS_CT, STYLES_CT, XML_CT, WORKSHEET_CT, SHARED_STRINGS_CT, -CORE_CT, CHART_CT, DRAWING_CT are allowed -</p> +CORE_CT, CHART_CT, DRAWING_CT are allowed</p> </div> @@ -1863,9 +1711,8 @@ CORE_CT, CHART_CT, DRAWING_CT are allowed — - <div class='inline'><p> -The value validated -</p> + <div class='inline'> +<p>The value validated</p> </div> </li> @@ -1886,10 +1733,9 @@ The value validated <td> <pre class="code"><span class="info file"># File 'lib/axlsx/util/validators.rb', line 114</span> -<span class='def def kw'>def</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='validate_content_type identifier id'>validate_content_type</span><span class='lparen token'>(</span><span class='v identifier id'>v</span><span class='rparen token'>)</span> - <span class='RestrictionValidator constant id'>RestrictionValidator</span><span class='dot token'>.</span><span class='validate identifier id'>validate</span> <span class='symbol val'>:content_type</span><span class='comma token'>,</span> <span class='lbrack token'>[</span><span class='TABLE_CT constant id'>TABLE_CT</span><span class='comma token'>,</span> <span class='WORKBOOK_CT constant id'>WORKBOOK_CT</span><span class='comma token'>,</span> <span class='APP_CT constant id'>APP_CT</span><span class='comma token'>,</span> <span class='RELS_CT constant id'>RELS_CT</span><span class='comma token'>,</span> <span class='STYLES_CT constant id'>STYLES_CT</span><span class='comma token'>,</span> <span class='XML_CT constant id'>XML_CT</span><span class='comma token'>,</span> <span class='WORKSHEET_CT constant id'>WORKSHEET_CT</span><span class='comma token'>,</span> <span class='SHARED_STRINGS_CT constant id'>SHARED_STRINGS_CT</span><span class='comma token'>,</span> <span class='CORE_CT constant id'>CORE_CT</span><span class='comma token'>,</span> <span class='CHART_CT constant id'>CHART_CT</span><span class='comma token'>,</span> <span class='JPEG_CT constant id'>JPEG_CT</span><span class='comma token'>,</span> <span class='GIF_CT constant id'>GIF_CT</span><span class='comma token'>,</span> <span class='PNG_CT constant id'>PNG_CT</span><span class='comma token'>,</span> <span class='DRAWING_CT constant id'>DRAWING_CT</span><span class='rbrack token'>]</span><span class='comma token'>,</span> <span class='v identifier id'>v</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id validate_content_type'>validate_content_type</span><span class='lparen'>(</span><span class='id v'>v</span><span class='rparen'>)</span> + <span class='const'>RestrictionValidator</span><span class='period'>.</span><span class='id validate'>validate</span> <span class='symbol'>:content_type</span><span class='comma'>,</span> <span class='lbracket'>[</span><span class='const'>TABLE_CT</span><span class='comma'>,</span> <span class='const'>WORKBOOK_CT</span><span class='comma'>,</span> <span class='const'>APP_CT</span><span class='comma'>,</span> <span class='const'>RELS_CT</span><span class='comma'>,</span> <span class='const'>STYLES_CT</span><span class='comma'>,</span> <span class='const'>XML_CT</span><span class='comma'>,</span> <span class='const'>WORKSHEET_CT</span><span class='comma'>,</span> <span class='const'>SHARED_STRINGS_CT</span><span class='comma'>,</span> <span class='const'>CORE_CT</span><span class='comma'>,</span> <span class='const'>CHART_CT</span><span class='comma'>,</span> <span class='const'>JPEG_CT</span><span class='comma'>,</span> <span class='const'>GIF_CT</span><span class='comma'>,</span> <span class='const'>PNG_CT</span><span class='comma'>,</span> <span class='const'>DRAWING_CT</span><span class='rbracket'>]</span><span class='comma'>,</span> <span class='id v'>v</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1904,9 +1750,8 @@ The value validated </p><div class="docstring"> <div class="discussion"> - <p> -Requires that the value is a Float -</p> + +<p>Requires that the value is a Float</p> </div> @@ -1925,9 +1770,8 @@ Requires that the value is a Float — - <div class='inline'><p> -The value validated -</p> + <div class='inline'> +<p>The value validated</p> </div> </li> @@ -1948,10 +1792,9 @@ The value validated <td> <pre class="code"><span class="info file"># File 'lib/axlsx/util/validators.rb', line 77</span> -<span class='def def kw'>def</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='validate_float identifier id'>validate_float</span><span class='lparen token'>(</span><span class='v identifier id'>v</span><span class='rparen token'>)</span> - <span class='DataTypeValidator constant id'>DataTypeValidator</span><span class='dot token'>.</span><span class='validate identifier id'>validate</span> <span class='symbol val'>:float</span><span class='comma token'>,</span> <span class='Float constant id'>Float</span><span class='comma token'>,</span> <span class='v identifier id'>v</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id validate_float'>validate_float</span><span class='lparen'>(</span><span class='id v'>v</span><span class='rparen'>)</span> + <span class='const'>DataTypeValidator</span><span class='period'>.</span><span class='id validate'>validate</span> <span class='symbol'>:float</span><span class='comma'>,</span> <span class='const'>Float</span><span class='comma'>,</span> <span class='id v'>v</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1966,10 +1809,9 @@ The value validated </p><div class="docstring"> <div class="discussion"> - <p> -Requires that the value is a gradient_type. valid types are :linear and -:path -</p> + +<p>Requires that the value is a gradient_type. valid types are :linear and +:path</p> </div> @@ -1988,9 +1830,8 @@ Requires that the value is a gradient_type. valid types are :linear and — - <div class='inline'><p> -The value validated -</p> + <div class='inline'> +<p>The value validated</p> </div> </li> @@ -2011,10 +1852,9 @@ The value validated <td> <pre class="code"><span class="info file"># File 'lib/axlsx/util/validators.rb', line 93</span> -<span class='def def kw'>def</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='validate_gradient_type identifier id'>validate_gradient_type</span><span class='lparen token'>(</span><span class='v identifier id'>v</span><span class='rparen token'>)</span> - <span class='RestrictionValidator constant id'>RestrictionValidator</span><span class='dot token'>.</span><span class='validate identifier id'>validate</span> <span class='symbol val'>:gradient_type</span><span class='comma token'>,</span> <span class='lbrack token'>[</span><span class='symbol val'>:linear</span><span class='comma token'>,</span> <span class='symbol val'>:path</span><span class='rbrack token'>]</span><span class='comma token'>,</span> <span class='v identifier id'>v</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id validate_gradient_type'>validate_gradient_type</span><span class='lparen'>(</span><span class='id v'>v</span><span class='rparen'>)</span> + <span class='const'>RestrictionValidator</span><span class='period'>.</span><span class='id validate'>validate</span> <span class='symbol'>:gradient_type</span><span class='comma'>,</span> <span class='lbracket'>[</span><span class='symbol'>:linear</span><span class='comma'>,</span> <span class='symbol'>:path</span><span class='rbracket'>]</span><span class='comma'>,</span> <span class='id v'>v</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -2029,11 +1869,10 @@ The value validated </p><div class="docstring"> <div class="discussion"> - <p> -Requires that the value is a valid horizontal_alignment :general, :left, + +<p>Requires that the value is a valid horizontal_alignment :general, :left, :center, :right, :fill, :justify, :centerContinuous, :distributed are -allowed -</p> +allowed</p> </div> @@ -2052,9 +1891,8 @@ allowed — - <div class='inline'><p> -The value validated -</p> + <div class='inline'> +<p>The value validated</p> </div> </li> @@ -2075,10 +1913,9 @@ The value validated <td> <pre class="code"><span class="info file"># File 'lib/axlsx/util/validators.rb', line 100</span> -<span class='def def kw'>def</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='validate_horizontal_alignment identifier id'>validate_horizontal_alignment</span><span class='lparen token'>(</span><span class='v identifier id'>v</span><span class='rparen token'>)</span> - <span class='RestrictionValidator constant id'>RestrictionValidator</span><span class='dot token'>.</span><span class='validate identifier id'>validate</span> <span class='symbol val'>:horizontal_alignment</span><span class='comma token'>,</span> <span class='lbrack token'>[</span><span class='symbol val'>:general</span><span class='comma token'>,</span> <span class='symbol val'>:left</span><span class='comma token'>,</span> <span class='symbol val'>:center</span><span class='comma token'>,</span> <span class='symbol val'>:right</span><span class='comma token'>,</span> <span class='symbol val'>:fill</span><span class='comma token'>,</span> <span class='symbol val'>:justify</span><span class='comma token'>,</span> <span class='symbol val'>:centerContinuous</span><span class='comma token'>,</span> <span class='symbol val'>:distributed</span><span class='rbrack token'>]</span><span class='comma token'>,</span> <span class='v identifier id'>v</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id validate_horizontal_alignment'>validate_horizontal_alignment</span><span class='lparen'>(</span><span class='id v'>v</span><span class='rparen'>)</span> + <span class='const'>RestrictionValidator</span><span class='period'>.</span><span class='id validate'>validate</span> <span class='symbol'>:horizontal_alignment</span><span class='comma'>,</span> <span class='lbracket'>[</span><span class='symbol'>:general</span><span class='comma'>,</span> <span class='symbol'>:left</span><span class='comma'>,</span> <span class='symbol'>:center</span><span class='comma'>,</span> <span class='symbol'>:right</span><span class='comma'>,</span> <span class='symbol'>:fill</span><span class='comma'>,</span> <span class='symbol'>:justify</span><span class='comma'>,</span> <span class='symbol'>:centerContinuous</span><span class='comma'>,</span> <span class='symbol'>:distributed</span><span class='rbracket'>]</span><span class='comma'>,</span> <span class='id v'>v</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -2093,9 +1930,8 @@ The value validated </p><div class="docstring"> <div class="discussion"> - <p> -Requires that the value is a Fixnum or Integer -</p> + +<p>Requires that the value is a Fixnum or Integer</p> </div> @@ -2114,9 +1950,8 @@ Requires that the value is a Fixnum or Integer — - <div class='inline'><p> -The value validated -</p> + <div class='inline'> +<p>The value validated</p> </div> </li> @@ -2137,10 +1972,9 @@ The value validated <td> <pre class="code"><span class="info file"># File 'lib/axlsx/util/validators.rb', line 57</span> -<span class='def def kw'>def</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='validate_int identifier id'>validate_int</span><span class='lparen token'>(</span><span class='v identifier id'>v</span><span class='rparen token'>)</span> - <span class='DataTypeValidator constant id'>DataTypeValidator</span><span class='dot token'>.</span><span class='validate identifier id'>validate</span> <span class='symbol val'>:unsigned_int</span><span class='comma token'>,</span> <span class='lbrack token'>[</span><span class='Fixnum constant id'>Fixnum</span><span class='comma token'>,</span> <span class='Integer constant id'>Integer</span><span class='rbrack token'>]</span><span class='comma token'>,</span> <span class='v identifier id'>v</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id validate_int'>validate_int</span><span class='lparen'>(</span><span class='id v'>v</span><span class='rparen'>)</span> + <span class='const'>DataTypeValidator</span><span class='period'>.</span><span class='id validate'>validate</span> <span class='symbol'>:unsigned_int</span><span class='comma'>,</span> <span class='lbracket'>[</span><span class='const'>Fixnum</span><span class='comma'>,</span> <span class='const'>Integer</span><span class='rbracket'>]</span><span class='comma'>,</span> <span class='id v'>v</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -2155,13 +1989,12 @@ The value validated </p><div class="docstring"> <div class="discussion"> - <p> -Requires that the value is valid pattern type. valid pattern types must be + +<p>Requires that the value is valid pattern type. valid pattern types must be one of :none, :solid, :mediumGray, :darkGray, :lightGray, :darkHorizontal, :darkVertical, :darkDown, :darkUp, :darkGrid, :darkTrellis, :lightHorizontal, :lightVertical, :lightDown, :lightUp, :lightGrid, -:lightTrellis, :gray125, or :gray0625. -</p> +:lightTrellis, :gray125, or :gray0625.</p> </div> @@ -2180,9 +2013,8 @@ one of :none, :solid, :mediumGray, :darkGray, :lightGray, :darkHorizontal, — - <div class='inline'><p> -The value validated -</p> + <div class='inline'> +<p>The value validated</p> </div> </li> @@ -2204,11 +2036,10 @@ The value validated <td> <pre class="code"><span class="info file"># File 'lib/axlsx/util/validators.rb', line 85</span> -<span class='def def kw'>def</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='validate_pattern_type identifier id'>validate_pattern_type</span><span class='lparen token'>(</span><span class='v identifier id'>v</span><span class='rparen token'>)</span> - <span class='RestrictionValidator constant id'>RestrictionValidator</span><span class='dot token'>.</span><span class='validate identifier id'>validate</span> <span class='symbol val'>:pattern_type</span><span class='comma token'>,</span> <span class='lbrack token'>[</span><span class='symbol val'>:none</span><span class='comma token'>,</span> <span class='symbol val'>:solid</span><span class='comma token'>,</span> <span class='symbol val'>:mediumGray</span><span class='comma token'>,</span> <span class='symbol val'>:darkGray</span><span class='comma token'>,</span> <span class='symbol val'>:lightGray</span><span class='comma token'>,</span> <span class='symbol val'>:darkHorizontal</span><span class='comma token'>,</span> <span class='symbol val'>:darkVertical</span><span class='comma token'>,</span> <span class='symbol val'>:darkDown</span><span class='comma token'>,</span> <span class='symbol val'>:darkUp</span><span class='comma token'>,</span> <span class='symbol val'>:darkGrid</span><span class='comma token'>,</span> - <span class='symbol val'>:darkTrellis</span><span class='comma token'>,</span> <span class='symbol val'>:lightHorizontal</span><span class='comma token'>,</span> <span class='symbol val'>:lightVertical</span><span class='comma token'>,</span> <span class='symbol val'>:lightDown</span><span class='comma token'>,</span> <span class='symbol val'>:lightUp</span><span class='comma token'>,</span> <span class='symbol val'>:lightGrid</span><span class='comma token'>,</span> <span class='symbol val'>:lightTrellis</span><span class='comma token'>,</span> <span class='symbol val'>:gray125</span><span class='comma token'>,</span> <span class='symbol val'>:gray0625</span><span class='rbrack token'>]</span><span class='comma token'>,</span> <span class='v identifier id'>v</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id validate_pattern_type'>validate_pattern_type</span><span class='lparen'>(</span><span class='id v'>v</span><span class='rparen'>)</span> + <span class='const'>RestrictionValidator</span><span class='period'>.</span><span class='id validate'>validate</span> <span class='symbol'>:pattern_type</span><span class='comma'>,</span> <span class='lbracket'>[</span><span class='symbol'>:none</span><span class='comma'>,</span> <span class='symbol'>:solid</span><span class='comma'>,</span> <span class='symbol'>:mediumGray</span><span class='comma'>,</span> <span class='symbol'>:darkGray</span><span class='comma'>,</span> <span class='symbol'>:lightGray</span><span class='comma'>,</span> <span class='symbol'>:darkHorizontal</span><span class='comma'>,</span> <span class='symbol'>:darkVertical</span><span class='comma'>,</span> <span class='symbol'>:darkDown</span><span class='comma'>,</span> <span class='symbol'>:darkUp</span><span class='comma'>,</span> <span class='symbol'>:darkGrid</span><span class='comma'>,</span> + <span class='symbol'>:darkTrellis</span><span class='comma'>,</span> <span class='symbol'>:lightHorizontal</span><span class='comma'>,</span> <span class='symbol'>:lightVertical</span><span class='comma'>,</span> <span class='symbol'>:lightDown</span><span class='comma'>,</span> <span class='symbol'>:lightUp</span><span class='comma'>,</span> <span class='symbol'>:lightGrid</span><span class='comma'>,</span> <span class='symbol'>:lightTrellis</span><span class='comma'>,</span> <span class='symbol'>:gray125</span><span class='comma'>,</span> <span class='symbol'>:gray0625</span><span class='rbracket'>]</span><span class='comma'>,</span> <span class='id v'>v</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -2223,11 +2054,10 @@ The value validated </p><div class="docstring"> <div class="discussion"> - <p> -Requires that the value is a valid relationship_type XML_NS_R, TABLE_R, + +<p>Requires that the value is a valid relationship_type XML_NS_R, TABLE_R, WORKBOOK_R, WORKSHEET_R, APP_R, RELS_R, CORE_R, STYLES_R, CHART_R, -DRAWING_R are allowed -</p> +DRAWING_R are allowed</p> </div> @@ -2246,9 +2076,8 @@ DRAWING_R are allowed — - <div class='inline'><p> -The value validated -</p> + <div class='inline'> +<p>The value validated</p> </div> </li> @@ -2269,10 +2098,9 @@ The value validated <td> <pre class="code"><span class="info file"># File 'lib/axlsx/util/validators.rb', line 121</span> -<span class='def def kw'>def</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='validate_relationship_type identifier id'>validate_relationship_type</span><span class='lparen token'>(</span><span class='v identifier id'>v</span><span class='rparen token'>)</span> - <span class='RestrictionValidator constant id'>RestrictionValidator</span><span class='dot token'>.</span><span class='validate identifier id'>validate</span> <span class='symbol val'>:relationship_type</span><span class='comma token'>,</span> <span class='lbrack token'>[</span><span class='XML_NS_R constant id'>XML_NS_R</span><span class='comma token'>,</span> <span class='TABLE_R constant id'>TABLE_R</span><span class='comma token'>,</span> <span class='WORKBOOK_R constant id'>WORKBOOK_R</span><span class='comma token'>,</span> <span class='WORKSHEET_R constant id'>WORKSHEET_R</span><span class='comma token'>,</span> <span class='APP_R constant id'>APP_R</span><span class='comma token'>,</span> <span class='RELS_R constant id'>RELS_R</span><span class='comma token'>,</span> <span class='CORE_R constant id'>CORE_R</span><span class='comma token'>,</span> <span class='STYLES_R constant id'>STYLES_R</span><span class='comma token'>,</span> <span class='CHART_R constant id'>CHART_R</span><span class='comma token'>,</span> <span class='DRAWING_R constant id'>DRAWING_R</span><span class='comma token'>,</span> <span class='IMAGE_R constant id'>IMAGE_R</span><span class='rbrack token'>]</span><span class='comma token'>,</span> <span class='v identifier id'>v</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id validate_relationship_type'>validate_relationship_type</span><span class='lparen'>(</span><span class='id v'>v</span><span class='rparen'>)</span> + <span class='const'>RestrictionValidator</span><span class='period'>.</span><span class='id validate'>validate</span> <span class='symbol'>:relationship_type</span><span class='comma'>,</span> <span class='lbracket'>[</span><span class='const'>XML_NS_R</span><span class='comma'>,</span> <span class='const'>TABLE_R</span><span class='comma'>,</span> <span class='const'>WORKBOOK_R</span><span class='comma'>,</span> <span class='const'>WORKSHEET_R</span><span class='comma'>,</span> <span class='const'>APP_R</span><span class='comma'>,</span> <span class='const'>RELS_R</span><span class='comma'>,</span> <span class='const'>CORE_R</span><span class='comma'>,</span> <span class='const'>STYLES_R</span><span class='comma'>,</span> <span class='const'>CHART_R</span><span class='comma'>,</span> <span class='const'>DRAWING_R</span><span class='comma'>,</span> <span class='const'>IMAGE_R</span><span class='rbracket'>]</span><span class='comma'>,</span> <span class='id v'>v</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -2287,9 +2115,8 @@ The value validated </p><div class="docstring"> <div class="discussion"> - <p> -Requires that the value is a String -</p> + +<p>Requires that the value is a String</p> </div> @@ -2308,9 +2135,8 @@ Requires that the value is a String — - <div class='inline'><p> -The value validated -</p> + <div class='inline'> +<p>The value validated</p> </div> </li> @@ -2331,10 +2157,9 @@ The value validated <td> <pre class="code"><span class="info file"># File 'lib/axlsx/util/validators.rb', line 71</span> -<span class='def def kw'>def</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='validate_string identifier id'>validate_string</span><span class='lparen token'>(</span><span class='v identifier id'>v</span><span class='rparen token'>)</span> - <span class='DataTypeValidator constant id'>DataTypeValidator</span><span class='dot token'>.</span><span class='validate identifier id'>validate</span> <span class='symbol val'>:string</span><span class='comma token'>,</span> <span class='String constant id'>String</span><span class='comma token'>,</span> <span class='v identifier id'>v</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id validate_string'>validate_string</span><span class='lparen'>(</span><span class='id v'>v</span><span class='rparen'>)</span> + <span class='const'>DataTypeValidator</span><span class='period'>.</span><span class='id validate'>validate</span> <span class='symbol'>:string</span><span class='comma'>,</span> <span class='const'>String</span><span class='comma'>,</span> <span class='id v'>v</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -2349,8 +2174,8 @@ The value validated </p><div class="docstring"> <div class="discussion"> - <p> -Requires that the value is a valid table element type :wholeTable, + +<p>Requires that the value is a valid table element type :wholeTable, :headerRow, :totalRow, :firstColumn, :lastColumn, :firstRowStripe, :secondRowStripe, :firstColumnStripe, :secondColumnStripe, :firstHeaderCell, :lastHeaderCell, :firstTotalCell, :lastTotalCell, @@ -2358,8 +2183,7 @@ Requires that the value is a valid table element type :wholeTable, :firstSubtotalRow, :secondSubtotalRow, :thirdSubtotalRow, :blankRow, :firstColumnSubheading, :secondColumnSubheading, :thirdColumnSubheading, :firstRowSubheading, :secondRowSubheading, :thirdRowSubheading, -:pageFieldLabels, :pageFieldValues are allowed -</p> +:pageFieldLabels, :pageFieldValues are allowed</p> </div> @@ -2378,9 +2202,8 @@ Requires that the value is a valid table element type :wholeTable, — - <div class='inline'><p> -The value validated -</p> + <div class='inline'> +<p>The value validated</p> </div> </li> @@ -2401,10 +2224,9 @@ The value validated <td> <pre class="code"><span class="info file"># File 'lib/axlsx/util/validators.rb', line 128</span> -<span class='def def kw'>def</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='validate_table_element_type identifier id'>validate_table_element_type</span><span class='lparen token'>(</span><span class='v identifier id'>v</span><span class='rparen token'>)</span> - <span class='RestrictionValidator constant id'>RestrictionValidator</span><span class='dot token'>.</span><span class='validate identifier id'>validate</span> <span class='symbol val'>:table_element_type</span><span class='comma token'>,</span> <span class='lbrack token'>[</span><span class='symbol val'>:wholeTable</span><span class='comma token'>,</span> <span class='symbol val'>:headerRow</span><span class='comma token'>,</span> <span class='symbol val'>:totalRow</span><span class='comma token'>,</span> <span class='symbol val'>:firstColumn</span><span class='comma token'>,</span> <span class='symbol val'>:lastColumn</span><span class='comma token'>,</span> <span class='symbol val'>:firstRowStripe</span><span class='comma token'>,</span> <span class='symbol val'>:secondRowStripe</span><span class='comma token'>,</span> <span class='symbol val'>:firstColumnStripe</span><span class='comma token'>,</span> <span class='symbol val'>:secondColumnStripe</span><span class='comma token'>,</span> <span class='symbol val'>:firstHeaderCell</span><span class='comma token'>,</span> <span class='symbol val'>:lastHeaderCell</span><span class='comma token'>,</span> <span class='symbol val'>:firstTotalCell</span><span class='comma token'>,</span> <span class='symbol val'>:lastTotalCell</span><span class='comma token'>,</span> <span class='symbol val'>:firstSubtotalColumn</span><span class='comma token'>,</span> <span class='symbol val'>:secondSubtotalColumn</span><span class='comma token'>,</span> <span class='symbol val'>:thirdSubtotalColumn</span><span class='comma token'>,</span> <span class='symbol val'>:firstSubtotalRow</span><span class='comma token'>,</span> <span class='symbol val'>:secondSubtotalRow</span><span class='comma token'>,</span> <span class='symbol val'>:thirdSubtotalRow</span><span class='comma token'>,</span> <span class='symbol val'>:blankRow</span><span class='comma token'>,</span> <span class='symbol val'>:firstColumnSubheading</span><span class='comma token'>,</span> <span class='symbol val'>:secondColumnSubheading</span><span class='comma token'>,</span> <span class='symbol val'>:thirdColumnSubheading</span><span class='comma token'>,</span> <span class='symbol val'>:firstRowSubheading</span><span class='comma token'>,</span> <span class='symbol val'>:secondRowSubheading</span><span class='comma token'>,</span> <span class='symbol val'>:thirdRowSubheading</span><span class='comma token'>,</span> <span class='symbol val'>:pageFieldLabels</span><span class='comma token'>,</span> <span class='symbol val'>:pageFieldValues</span><span class='rbrack token'>]</span><span class='comma token'>,</span> <span class='v identifier id'>v</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id validate_table_element_type'>validate_table_element_type</span><span class='lparen'>(</span><span class='id v'>v</span><span class='rparen'>)</span> + <span class='const'>RestrictionValidator</span><span class='period'>.</span><span class='id validate'>validate</span> <span class='symbol'>:table_element_type</span><span class='comma'>,</span> <span class='lbracket'>[</span><span class='symbol'>:wholeTable</span><span class='comma'>,</span> <span class='symbol'>:headerRow</span><span class='comma'>,</span> <span class='symbol'>:totalRow</span><span class='comma'>,</span> <span class='symbol'>:firstColumn</span><span class='comma'>,</span> <span class='symbol'>:lastColumn</span><span class='comma'>,</span> <span class='symbol'>:firstRowStripe</span><span class='comma'>,</span> <span class='symbol'>:secondRowStripe</span><span class='comma'>,</span> <span class='symbol'>:firstColumnStripe</span><span class='comma'>,</span> <span class='symbol'>:secondColumnStripe</span><span class='comma'>,</span> <span class='symbol'>:firstHeaderCell</span><span class='comma'>,</span> <span class='symbol'>:lastHeaderCell</span><span class='comma'>,</span> <span class='symbol'>:firstTotalCell</span><span class='comma'>,</span> <span class='symbol'>:lastTotalCell</span><span class='comma'>,</span> <span class='symbol'>:firstSubtotalColumn</span><span class='comma'>,</span> <span class='symbol'>:secondSubtotalColumn</span><span class='comma'>,</span> <span class='symbol'>:thirdSubtotalColumn</span><span class='comma'>,</span> <span class='symbol'>:firstSubtotalRow</span><span class='comma'>,</span> <span class='symbol'>:secondSubtotalRow</span><span class='comma'>,</span> <span class='symbol'>:thirdSubtotalRow</span><span class='comma'>,</span> <span class='symbol'>:blankRow</span><span class='comma'>,</span> <span class='symbol'>:firstColumnSubheading</span><span class='comma'>,</span> <span class='symbol'>:secondColumnSubheading</span><span class='comma'>,</span> <span class='symbol'>:thirdColumnSubheading</span><span class='comma'>,</span> <span class='symbol'>:firstRowSubheading</span><span class='comma'>,</span> <span class='symbol'>:secondRowSubheading</span><span class='comma'>,</span> <span class='symbol'>:thirdRowSubheading</span><span class='comma'>,</span> <span class='symbol'>:pageFieldLabels</span><span class='comma'>,</span> <span class='symbol'>:pageFieldValues</span><span class='rbracket'>]</span><span class='comma'>,</span> <span class='id v'>v</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -2419,9 +2241,8 @@ The value validated </p><div class="docstring"> <div class="discussion"> - <p> -Requires that the value is a Fixnum or Integer and is greater or equal to 0 -</p> + +<p>Requires that the value is a Fixnum or Integer and is greater or equal to 0</p> </div> @@ -2440,9 +2261,8 @@ Requires that the value is a Fixnum or Integer and is greater or equal to 0 — - <div class='inline'><p> -The value validated -</p> + <div class='inline'> +<p>The value validated</p> </div> </li> @@ -2460,9 +2280,8 @@ The value validated — - <div class='inline'><p> -true if the data is valid -</p> + <div class='inline'> +<p>true if the data is valid</p> </div> </li> @@ -2479,9 +2298,8 @@ true if the data is valid — - <div class='inline'><p> -raised if the value is not a Fixnum or Integer value greater or equal to 0 -</p> + <div class='inline'> +<p>raised if the value is not a Fixnum or Integer value greater or equal to 0</p> </div> </li> @@ -2501,10 +2319,9 @@ raised if the value is not a Fixnum or Integer value greater or equal to 0 <td> <pre class="code"><span class="info file"># File 'lib/axlsx/util/validators.rb', line 51</span> -<span class='def def kw'>def</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='validate_unsigned_int identifier id'>validate_unsigned_int</span><span class='lparen token'>(</span><span class='v identifier id'>v</span><span class='rparen token'>)</span> - <span class='DataTypeValidator constant id'>DataTypeValidator</span><span class='dot token'>.</span><span class='validate identifier id'>validate</span><span class='lparen token'>(</span><span class='symbol val'>:unsigned_int</span><span class='comma token'>,</span> <span class='lbrack token'>[</span><span class='Fixnum constant id'>Fixnum</span><span class='comma token'>,</span> <span class='Integer constant id'>Integer</span><span class='rbrack token'>]</span><span class='comma token'>,</span> <span class='v identifier id'>v</span><span class='comma token'>,</span> <span class='lambda identifier id'>lambda</span> <span class='lbrace token'>{</span> <span class='bitor op'>|</span><span class='v identifier id'>v</span><span class='bitor op'>|</span> <span class='v identifier id'>v</span><span class='dot token'>.</span><span class='respond_to? fid id'>respond_to?</span><span class='lparen token'>(</span><span class='symbol val'>:>=</span><span class='rparen token'>)</span> <span class='andop op'>&&</span> <span class='v identifier id'>v</span> <span class='geq op'>>=</span> <span class='integer val'>0</span> <span class='rbrace token'>}</span><span class='rparen token'>)</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id validate_unsigned_int'>validate_unsigned_int</span><span class='lparen'>(</span><span class='id v'>v</span><span class='rparen'>)</span> + <span class='const'>DataTypeValidator</span><span class='period'>.</span><span class='id validate'>validate</span><span class='lparen'>(</span><span class='symbol'>:unsigned_int</span><span class='comma'>,</span> <span class='lbracket'>[</span><span class='const'>Fixnum</span><span class='comma'>,</span> <span class='const'>Integer</span><span class='rbracket'>]</span><span class='comma'>,</span> <span class='id v'>v</span><span class='comma'>,</span> <span class='id lambda'>lambda</span> <span class='lbrace'>{</span> <span class='op'>|</span><span class='id arg'>arg</span><span class='op'>|</span> <span class='id arg'>arg</span><span class='period'>.</span><span class='id respond_to?'>respond_to?</span><span class='lparen'>(</span><span class='symbol'>:>=</span><span class='rparen'>)</span> <span class='op'>&&</span> <span class='id arg'>arg</span> <span class='op'>>=</span> <span class='int'>0</span> <span class='rbrace'>}</span><span class='rparen'>)</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -2519,10 +2336,9 @@ raised if the value is not a Fixnum or Integer value greater or equal to 0 </p><div class="docstring"> <div class="discussion"> - <p> -Requires that the value is a valid vertical_alignment :top, :center, -:bottom, :justify, :distributed are allowed -</p> + +<p>Requires that the value is a valid vertical_alignment :top, :center, +:bottom, :justify, :distributed are allowed</p> </div> @@ -2541,9 +2357,8 @@ Requires that the value is a valid vertical_alignment :top, :center, — - <div class='inline'><p> -The value validated -</p> + <div class='inline'> +<p>The value validated</p> </div> </li> @@ -2564,10 +2379,9 @@ The value validated <td> <pre class="code"><span class="info file"># File 'lib/axlsx/util/validators.rb', line 107</span> -<span class='def def kw'>def</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='validate_vertical_alignment identifier id'>validate_vertical_alignment</span><span class='lparen token'>(</span><span class='v identifier id'>v</span><span class='rparen token'>)</span> - <span class='RestrictionValidator constant id'>RestrictionValidator</span><span class='dot token'>.</span><span class='validate identifier id'>validate</span> <span class='symbol val'>:vertical_alignment</span><span class='comma token'>,</span> <span class='lbrack token'>[</span><span class='symbol val'>:top</span><span class='comma token'>,</span> <span class='symbol val'>:center</span><span class='comma token'>,</span> <span class='symbol val'>:bottom</span><span class='comma token'>,</span> <span class='symbol val'>:justify</span><span class='comma token'>,</span> <span class='symbol val'>:distributed</span><span class='rbrack token'>]</span><span class='comma token'>,</span> <span class='v identifier id'>v</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id validate_vertical_alignment'>validate_vertical_alignment</span><span class='lparen'>(</span><span class='id v'>v</span><span class='rparen'>)</span> + <span class='const'>RestrictionValidator</span><span class='period'>.</span><span class='id validate'>validate</span> <span class='symbol'>:vertical_alignment</span><span class='comma'>,</span> <span class='lbracket'>[</span><span class='symbol'>:top</span><span class='comma'>,</span> <span class='symbol'>:center</span><span class='comma'>,</span> <span class='symbol'>:bottom</span><span class='comma'>,</span> <span class='symbol'>:justify</span><span class='comma'>,</span> <span class='symbol'>:distributed</span><span class='rbracket'>]</span><span class='comma'>,</span> <span class='id v'>v</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -2578,9 +2392,9 @@ The value validated </div> <div id="footer"> - Generated on Wed Nov 23 22:20:48 2011 by + Generated on Sat Nov 26 13:16:36 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/App.html b/doc/Axlsx/App.html index c442c69e..ca993af0 100644 --- a/doc/Axlsx/App.html +++ b/doc/Axlsx/App.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::App - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -97,22 +97,19 @@ <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -Support is not implemented for the following complex types: -</p> -<p> -HeadingPairs (VectorVariant), TitlesOfParts (VectorLpstr), HLinks -(VectorVariant), DigSig (DigSigBlob) -</p> + <div class='inline'> +<p>Support is not implemented for the following complex types:</p> + +<p>HeadingPairs (VectorVariant), TitlesOfParts (VectorLpstr), HLinks +(VectorVariant), DigSig (DigSigBlob)</p> </div> </div> -<p> -App represents the app.xml document. The attributes for this object are + +<p>App represents the app.xml document. The attributes for this object are primarily managed by the application the end user uses to edit the document. None of the attributes are required to serialize a valid xlsx -object. -</p> +object.</p> </div> @@ -151,9 +148,8 @@ object. - <span class="summary_desc"><div class='inline'><p> -The name of the application. -</p> + <span class="summary_desc"><div class='inline'> +<p>The name of the application.</p> </div></span> </li> @@ -178,9 +174,8 @@ The name of the application. - <span class="summary_desc"><div class='inline'><p> -The version of the application. -</p> + <span class="summary_desc"><div class='inline'> +<p>The version of the application.</p> </div></span> </li> @@ -205,9 +200,8 @@ The version of the application. - <span class="summary_desc"><div class='inline'><p> -The number of characters in the document. -</p> + <span class="summary_desc"><div class='inline'> +<p>The number of characters in the document.</p> </div></span> </li> @@ -232,9 +226,8 @@ The number of characters in the document. - <span class="summary_desc"><div class='inline'><p> -The number of characters in the document including spaces. -</p> + <span class="summary_desc"><div class='inline'> +<p>The number of characters in the document including spaces.</p> </div></span> </li> @@ -259,9 +252,8 @@ The number of characters in the document including spaces. - <span class="summary_desc"><div class='inline'><p> -The name of the company generating the document. -</p> + <span class="summary_desc"><div class='inline'> +<p>The name of the company generating the document.</p> </div></span> </li> @@ -286,9 +278,8 @@ The name of the company generating the document. - <span class="summary_desc"><div class='inline'><p> -Document security. -</p> + <span class="summary_desc"><div class='inline'> +<p>Document security.</p> </div></span> </li> @@ -313,9 +304,8 @@ Document security. - <span class="summary_desc"><div class='inline'><p> -The number of hidden slides. -</p> + <span class="summary_desc"><div class='inline'> +<p>The number of hidden slides.</p> </div></span> </li> @@ -340,9 +330,8 @@ The number of hidden slides. - <span class="summary_desc"><div class='inline'><p> -The base for hyper links in the document. -</p> + <span class="summary_desc"><div class='inline'> +<p>The base for hyper links in the document.</p> </div></span> </li> @@ -367,9 +356,8 @@ The base for hyper links in the document. - <span class="summary_desc"><div class='inline'><p> -Indicates that the hyper links in the document have been changed. -</p> + <span class="summary_desc"><div class='inline'> +<p>Indicates that the hyper links in the document have been changed.</p> </div></span> </li> @@ -394,9 +382,8 @@ Indicates that the hyper links in the document have been changed. - <span class="summary_desc"><div class='inline'><p> -The number of lines in the document. -</p> + <span class="summary_desc"><div class='inline'> +<p>The number of lines in the document.</p> </div></span> </li> @@ -421,9 +408,8 @@ The number of lines in the document. - <span class="summary_desc"><div class='inline'><p> -The links in the document are up to date. -</p> + <span class="summary_desc"><div class='inline'> +<p>The links in the document are up to date.</p> </div></span> </li> @@ -448,9 +434,8 @@ The links in the document are up to date. - <span class="summary_desc"><div class='inline'><p> -The name of the manager for the document. -</p> + <span class="summary_desc"><div class='inline'> +<p>The name of the manager for the document.</p> </div></span> </li> @@ -475,9 +460,8 @@ The name of the manager for the document. - <span class="summary_desc"><div class='inline'><p> -The total number multimedia clips. -</p> + <span class="summary_desc"><div class='inline'> +<p>The total number multimedia clips.</p> </div></span> </li> @@ -502,9 +486,8 @@ The total number multimedia clips. - <span class="summary_desc"><div class='inline'><p> -The number of slides that have notes. -</p> + <span class="summary_desc"><div class='inline'> +<p>The number of slides that have notes.</p> </div></span> </li> @@ -529,9 +512,8 @@ The number of slides that have notes. - <span class="summary_desc"><div class='inline'><p> -The number of pages in the document. -</p> + <span class="summary_desc"><div class='inline'> +<p>The number of pages in the document.</p> </div></span> </li> @@ -556,9 +538,8 @@ The number of pages in the document. - <span class="summary_desc"><div class='inline'><p> -The number of paragraphs in the document. -</p> + <span class="summary_desc"><div class='inline'> +<p>The number of paragraphs in the document.</p> </div></span> </li> @@ -583,9 +564,8 @@ The number of paragraphs in the document. - <span class="summary_desc"><div class='inline'><p> -The intended format of the presentation. -</p> + <span class="summary_desc"><div class='inline'> +<p>The intended format of the presentation.</p> </div></span> </li> @@ -610,9 +590,8 @@ The intended format of the presentation. - <span class="summary_desc"><div class='inline'><p> -The display mode for the document thumbnail. -</p> + <span class="summary_desc"><div class='inline'> +<p>The display mode for the document thumbnail.</p> </div></span> </li> @@ -637,9 +616,8 @@ The display mode for the document thumbnail. - <span class="summary_desc"><div class='inline'><p> -Indicates if the document is shared. -</p> + <span class="summary_desc"><div class='inline'> +<p>Indicates if the document is shared.</p> </div></span> </li> @@ -664,9 +642,8 @@ Indicates if the document is shared. - <span class="summary_desc"><div class='inline'><p> -The number of slides in the document. -</p> + <span class="summary_desc"><div class='inline'> +<p>The number of slides in the document.</p> </div></span> </li> @@ -691,9 +668,8 @@ The number of slides in the document. - <span class="summary_desc"><div class='inline'><p> -The name of the document template. -</p> + <span class="summary_desc"><div class='inline'> +<p>The name of the document template.</p> </div></span> </li> @@ -718,9 +694,8 @@ The name of the document template. - <span class="summary_desc"><div class='inline'><p> -The total amount of time spent editing. -</p> + <span class="summary_desc"><div class='inline'> +<p>The total amount of time spent editing.</p> </div></span> </li> @@ -745,9 +720,8 @@ The total amount of time spent editing. - <span class="summary_desc"><div class='inline'><p> -The number of words in the document. -</p> + <span class="summary_desc"><div class='inline'> +<p>The number of words in the document.</p> </div></span> </li> @@ -782,9 +756,8 @@ The number of words in the document. - <span class="summary_desc"><div class='inline'><p> -Creates an App object. -</p> + <span class="summary_desc"><div class='inline'> +<p>Creates an App object.</p> </div></span> </li> @@ -806,9 +779,8 @@ Creates an App object. - <span class="summary_desc"><div class='inline'><p> -Generate an app.xml document. -</p> + <span class="summary_desc"><div class='inline'> +<p>Generate an app.xml document.</p> </div></span> </li> @@ -833,9 +805,8 @@ Generate an app.xml document. </p><div class="docstring"> <div class="discussion"> - <p> -The name of the application -</p> + +<p>The name of the application</p> </div> @@ -853,9 +824,8 @@ The name of the application — - <div class='inline'><p> -The name of the application -</p> + <div class='inline'> +<p>The name of the application</p> </div> </li> @@ -875,10 +845,9 @@ The name of the application <td> <pre class="code"><span class="info file"># File 'lib/axlsx/doc_props/app.rb', line 74</span> -<span class='def def kw'>def</span> <span class='Application constant id'>Application</span> - <span class='@Application ivar id'>@Application</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='const'>Application</span> + <span class='ivar'>@Application</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -896,9 +865,8 @@ The name of the application </p><div class="docstring"> <div class="discussion"> - <p> -The version of the application. -</p> + +<p>The version of the application.</p> </div> @@ -916,9 +884,8 @@ The version of the application. — - <div class='inline'><p> -The version of the application. -</p> + <div class='inline'> +<p>The version of the application.</p> </div> </li> @@ -938,10 +905,9 @@ The version of the application. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/doc_props/app.rb', line 77</span> -<span class='def def kw'>def</span> <span class='AppVersion constant id'>AppVersion</span> - <span class='@AppVersion ivar id'>@AppVersion</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='const'>AppVersion</span> + <span class='ivar'>@AppVersion</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -959,9 +925,8 @@ The version of the application. </p><div class="docstring"> <div class="discussion"> - <p> -The number of characters in the document. -</p> + +<p>The number of characters in the document.</p> </div> @@ -979,9 +944,8 @@ The number of characters in the document. — - <div class='inline'><p> -The number of characters in the document. -</p> + <div class='inline'> +<p>The number of characters in the document.</p> </div> </li> @@ -1001,10 +965,9 @@ The number of characters in the document. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/doc_props/app.rb', line 29</span> -<span class='def def kw'>def</span> <span class='Characters constant id'>Characters</span> - <span class='@Characters ivar id'>@Characters</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='const'>Characters</span> + <span class='ivar'>@Characters</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1022,9 +985,8 @@ The number of characters in the document. </p><div class="docstring"> <div class="discussion"> - <p> -The number of characters in the document including spaces. -</p> + +<p>The number of characters in the document including spaces.</p> </div> @@ -1042,9 +1004,8 @@ The number of characters in the document including spaces. — - <div class='inline'><p> -The number of characters in the document including spaces. -</p> + <div class='inline'> +<p>The number of characters in the document including spaces.</p> </div> </li> @@ -1064,10 +1025,9 @@ The number of characters in the document including spaces. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/doc_props/app.rb', line 62</span> -<span class='def def kw'>def</span> <span class='CharactersWithSpaces constant id'>CharactersWithSpaces</span> - <span class='@CharactersWithSpaces ivar id'>@CharactersWithSpaces</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='const'>CharactersWithSpaces</span> + <span class='ivar'>@CharactersWithSpaces</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1085,9 +1045,8 @@ The number of characters in the document including spaces. </p><div class="docstring"> <div class="discussion"> - <p> -The name of the company generating the document. -</p> + +<p>The name of the company generating the document.</p> </div> @@ -1105,9 +1064,8 @@ The name of the company generating the document. — - <div class='inline'><p> -The name of the company generating the document. -</p> + <div class='inline'> +<p>The name of the company generating the document.</p> </div> </li> @@ -1127,10 +1085,9 @@ The name of the company generating the document. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/doc_props/app.rb', line 20</span> -<span class='def def kw'>def</span> <span class='Company constant id'>Company</span> - <span class='@Company ivar id'>@Company</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='const'>Company</span> + <span class='ivar'>@Company</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1148,9 +1105,8 @@ The name of the company generating the document. </p><div class="docstring"> <div class="discussion"> - <p> -Document security -</p> + +<p>Document security</p> </div> @@ -1168,9 +1124,8 @@ Document security — - <div class='inline'><p> -Document security -</p> + <div class='inline'> +<p>Document security</p> </div> </li> @@ -1190,10 +1145,9 @@ Document security <td> <pre class="code"><span class="info file"># File 'lib/axlsx/doc_props/app.rb', line 80</span> -<span class='def def kw'>def</span> <span class='DocSecurity constant id'>DocSecurity</span> - <span class='@DocSecurity ivar id'>@DocSecurity</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='const'>DocSecurity</span> + <span class='ivar'>@DocSecurity</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1211,9 +1165,8 @@ Document security </p><div class="docstring"> <div class="discussion"> - <p> -The number of hidden slides. -</p> + +<p>The number of hidden slides.</p> </div> @@ -1231,9 +1184,8 @@ The number of hidden slides. — - <div class='inline'><p> -The number of hidden slides. -</p> + <div class='inline'> +<p>The number of hidden slides.</p> </div> </li> @@ -1253,10 +1205,9 @@ The number of hidden slides. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/doc_props/app.rb', line 50</span> -<span class='def def kw'>def</span> <span class='HiddenSlides constant id'>HiddenSlides</span> - <span class='@HiddenSlides ivar id'>@HiddenSlides</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='const'>HiddenSlides</span> + <span class='ivar'>@HiddenSlides</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1274,9 +1225,8 @@ The number of hidden slides. </p><div class="docstring"> <div class="discussion"> - <p> -The base for hyper links in the document. -</p> + +<p>The base for hyper links in the document.</p> </div> @@ -1294,9 +1244,8 @@ The base for hyper links in the document. — - <div class='inline'><p> -The base for hyper links in the document. -</p> + <div class='inline'> +<p>The base for hyper links in the document.</p> </div> </li> @@ -1316,10 +1265,9 @@ The base for hyper links in the document. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/doc_props/app.rb', line 68</span> -<span class='def def kw'>def</span> <span class='HyperLinkBase constant id'>HyperLinkBase</span> - <span class='@HyperLinkBase ivar id'>@HyperLinkBase</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='const'>HyperLinkBase</span> + <span class='ivar'>@HyperLinkBase</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1337,9 +1285,8 @@ The base for hyper links in the document. </p><div class="docstring"> <div class="discussion"> - <p> -Indicates that the hyper links in the document have been changed. -</p> + +<p>Indicates that the hyper links in the document have been changed.</p> </div> @@ -1357,9 +1304,8 @@ Indicates that the hyper links in the document have been changed. — - <div class='inline'><p> -Indicates that the hyper links in the document have been changed. -</p> + <div class='inline'> +<p>Indicates that the hyper links in the document have been changed.</p> </div> </li> @@ -1379,10 +1325,9 @@ Indicates that the hyper links in the document have been changed. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/doc_props/app.rb', line 71</span> -<span class='def def kw'>def</span> <span class='HyperlinksChanged constant id'>HyperlinksChanged</span> - <span class='@HyperlinksChanged ivar id'>@HyperlinksChanged</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='const'>HyperlinksChanged</span> + <span class='ivar'>@HyperlinksChanged</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1400,9 +1345,8 @@ Indicates that the hyper links in the document have been changed. </p><div class="docstring"> <div class="discussion"> - <p> -The number of lines in the document. -</p> + +<p>The number of lines in the document.</p> </div> @@ -1420,9 +1364,8 @@ The number of lines in the document. — - <div class='inline'><p> -The number of lines in the document. -</p> + <div class='inline'> +<p>The number of lines in the document.</p> </div> </li> @@ -1442,10 +1385,9 @@ The number of lines in the document. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/doc_props/app.rb', line 35</span> -<span class='def def kw'>def</span> <span class='Lines constant id'>Lines</span> - <span class='@Lines ivar id'>@Lines</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='const'>Lines</span> + <span class='ivar'>@Lines</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1463,9 +1405,8 @@ The number of lines in the document. </p><div class="docstring"> <div class="discussion"> - <p> -The links in the document are up to date. -</p> + +<p>The links in the document are up to date.</p> </div> @@ -1483,9 +1424,8 @@ The links in the document are up to date. — - <div class='inline'><p> -The links in the document are up to date. -</p> + <div class='inline'> +<p>The links in the document are up to date.</p> </div> </li> @@ -1505,10 +1445,9 @@ The links in the document are up to date. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/doc_props/app.rb', line 59</span> -<span class='def def kw'>def</span> <span class='LinksUpToDate constant id'>LinksUpToDate</span> - <span class='@LinksUpToDate ivar id'>@LinksUpToDate</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='const'>LinksUpToDate</span> + <span class='ivar'>@LinksUpToDate</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1526,9 +1465,8 @@ The links in the document are up to date. </p><div class="docstring"> <div class="discussion"> - <p> -The name of the manager for the document. -</p> + +<p>The name of the manager for the document.</p> </div> @@ -1546,9 +1484,8 @@ The name of the manager for the document. — - <div class='inline'><p> -The name of the manager for the document. -</p> + <div class='inline'> +<p>The name of the manager for the document.</p> </div> </li> @@ -1568,10 +1505,9 @@ The name of the manager for the document. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/doc_props/app.rb', line 17</span> -<span class='def def kw'>def</span> <span class='Manager constant id'>Manager</span> - <span class='@Manager ivar id'>@Manager</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='const'>Manager</span> + <span class='ivar'>@Manager</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1589,9 +1525,8 @@ The name of the manager for the document. </p><div class="docstring"> <div class="discussion"> - <p> -The total number multimedia clips -</p> + +<p>The total number multimedia clips</p> </div> @@ -1609,9 +1544,8 @@ The total number multimedia clips — - <div class='inline'><p> -The total number multimedia clips -</p> + <div class='inline'> +<p>The total number multimedia clips</p> </div> </li> @@ -1631,10 +1565,9 @@ The total number multimedia clips <td> <pre class="code"><span class="info file"># File 'lib/axlsx/doc_props/app.rb', line 53</span> -<span class='def def kw'>def</span> <span class='MMClips constant id'>MMClips</span> - <span class='@MMClips ivar id'>@MMClips</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='const'>MMClips</span> + <span class='ivar'>@MMClips</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1652,9 +1585,8 @@ The total number multimedia clips </p><div class="docstring"> <div class="discussion"> - <p> -The number of slides that have notes. -</p> + +<p>The number of slides that have notes.</p> </div> @@ -1672,9 +1604,8 @@ The number of slides that have notes. — - <div class='inline'><p> -The number of slides that have notes. -</p> + <div class='inline'> +<p>The number of slides that have notes.</p> </div> </li> @@ -1694,10 +1625,9 @@ The number of slides that have notes. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/doc_props/app.rb', line 44</span> -<span class='def def kw'>def</span> <span class='Notes constant id'>Notes</span> - <span class='@Notes ivar id'>@Notes</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='const'>Notes</span> + <span class='ivar'>@Notes</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1715,9 +1645,8 @@ The number of slides that have notes. </p><div class="docstring"> <div class="discussion"> - <p> -The number of pages in the document. -</p> + +<p>The number of pages in the document.</p> </div> @@ -1735,9 +1664,8 @@ The number of pages in the document. — - <div class='inline'><p> -The number of pages in the document. -</p> + <div class='inline'> +<p>The number of pages in the document.</p> </div> </li> @@ -1757,10 +1685,9 @@ The number of pages in the document. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/doc_props/app.rb', line 23</span> -<span class='def def kw'>def</span> <span class='Pages constant id'>Pages</span> - <span class='@Pages ivar id'>@Pages</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='const'>Pages</span> + <span class='ivar'>@Pages</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1778,9 +1705,8 @@ The number of pages in the document. </p><div class="docstring"> <div class="discussion"> - <p> -The number of paragraphs in the document -</p> + +<p>The number of paragraphs in the document</p> </div> @@ -1798,9 +1724,8 @@ The number of paragraphs in the document — - <div class='inline'><p> -The number of paragraphs in the document -</p> + <div class='inline'> +<p>The number of paragraphs in the document</p> </div> </li> @@ -1820,10 +1745,9 @@ The number of paragraphs in the document <td> <pre class="code"><span class="info file"># File 'lib/axlsx/doc_props/app.rb', line 38</span> -<span class='def def kw'>def</span> <span class='Paragraphs constant id'>Paragraphs</span> - <span class='@Paragraphs ivar id'>@Paragraphs</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='const'>Paragraphs</span> + <span class='ivar'>@Paragraphs</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1841,9 +1765,8 @@ The number of paragraphs in the document </p><div class="docstring"> <div class="discussion"> - <p> -The intended format of the presentation. -</p> + +<p>The intended format of the presentation.</p> </div> @@ -1861,9 +1784,8 @@ The intended format of the presentation. — - <div class='inline'><p> -The intended format of the presentation. -</p> + <div class='inline'> +<p>The intended format of the presentation.</p> </div> </li> @@ -1883,10 +1805,9 @@ The intended format of the presentation. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/doc_props/app.rb', line 32</span> -<span class='def def kw'>def</span> <span class='PresentationFormat constant id'>PresentationFormat</span> - <span class='@PresentationFormat ivar id'>@PresentationFormat</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='const'>PresentationFormat</span> + <span class='ivar'>@PresentationFormat</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1904,9 +1825,8 @@ The intended format of the presentation. </p><div class="docstring"> <div class="discussion"> - <p> -The display mode for the document thumbnail. -</p> + +<p>The display mode for the document thumbnail.</p> </div> @@ -1924,9 +1844,8 @@ The display mode for the document thumbnail. — - <div class='inline'><p> -The display mode for the document thumbnail. -</p> + <div class='inline'> +<p>The display mode for the document thumbnail.</p> </div> </li> @@ -1946,10 +1865,9 @@ The display mode for the document thumbnail. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/doc_props/app.rb', line 56</span> -<span class='def def kw'>def</span> <span class='ScaleCrop constant id'>ScaleCrop</span> - <span class='@ScaleCrop ivar id'>@ScaleCrop</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='const'>ScaleCrop</span> + <span class='ivar'>@ScaleCrop</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1967,9 +1885,8 @@ The display mode for the document thumbnail. </p><div class="docstring"> <div class="discussion"> - <p> -Indicates if the document is shared. -</p> + +<p>Indicates if the document is shared.</p> </div> @@ -1987,9 +1904,8 @@ Indicates if the document is shared. — - <div class='inline'><p> -Indicates if the document is shared. -</p> + <div class='inline'> +<p>Indicates if the document is shared.</p> </div> </li> @@ -2009,10 +1925,9 @@ Indicates if the document is shared. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/doc_props/app.rb', line 65</span> -<span class='def def kw'>def</span> <span class='ShareDoc constant id'>ShareDoc</span> - <span class='@ShareDoc ivar id'>@ShareDoc</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='const'>ShareDoc</span> + <span class='ivar'>@ShareDoc</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -2030,9 +1945,8 @@ Indicates if the document is shared. </p><div class="docstring"> <div class="discussion"> - <p> -The number of slides in the document. -</p> + +<p>The number of slides in the document.</p> </div> @@ -2050,9 +1964,8 @@ The number of slides in the document. — - <div class='inline'><p> -The number of slides in the document. -</p> + <div class='inline'> +<p>The number of slides in the document.</p> </div> </li> @@ -2072,10 +1985,9 @@ The number of slides in the document. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/doc_props/app.rb', line 41</span> -<span class='def def kw'>def</span> <span class='Slides constant id'>Slides</span> - <span class='@Slides ivar id'>@Slides</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='const'>Slides</span> + <span class='ivar'>@Slides</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -2093,9 +2005,8 @@ The number of slides in the document. </p><div class="docstring"> <div class="discussion"> - <p> -The name of the document template. -</p> + +<p>The name of the document template.</p> </div> @@ -2113,9 +2024,8 @@ The name of the document template. — - <div class='inline'><p> -The name of the document template. -</p> + <div class='inline'> +<p>The name of the document template.</p> </div> </li> @@ -2135,10 +2045,9 @@ The name of the document template. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/doc_props/app.rb', line 14</span> -<span class='def def kw'>def</span> <span class='Template constant id'>Template</span> - <span class='@Template ivar id'>@Template</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='const'>Template</span> + <span class='ivar'>@Template</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -2156,9 +2065,8 @@ The name of the document template. </p><div class="docstring"> <div class="discussion"> - <p> -The total amount of time spent editing. -</p> + +<p>The total amount of time spent editing.</p> </div> @@ -2176,9 +2084,8 @@ The total amount of time spent editing. — - <div class='inline'><p> -The total amount of time spent editing. -</p> + <div class='inline'> +<p>The total amount of time spent editing.</p> </div> </li> @@ -2198,10 +2105,9 @@ The total amount of time spent editing. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/doc_props/app.rb', line 47</span> -<span class='def def kw'>def</span> <span class='TotalTime constant id'>TotalTime</span> - <span class='@TotalTime ivar id'>@TotalTime</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='const'>TotalTime</span> + <span class='ivar'>@TotalTime</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -2219,9 +2125,8 @@ The total amount of time spent editing. </p><div class="docstring"> <div class="discussion"> - <p> -The number of words in the document. -</p> + +<p>The number of words in the document.</p> </div> @@ -2239,9 +2144,8 @@ The number of words in the document. — - <div class='inline'><p> -The number of words in the document. -</p> + <div class='inline'> +<p>The number of words in the document.</p> </div> </li> @@ -2261,10 +2165,9 @@ The number of words in the document. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/doc_props/app.rb', line 26</span> -<span class='def def kw'>def</span> <span class='Words constant id'>Words</span> - <span class='@Words ivar id'>@Words</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='const'>Words</span> + <span class='ivar'>@Words</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -2286,9 +2189,8 @@ The number of words in the document. </p><div class="docstring"> <div class="discussion"> - <p> -Creates an App object -</p> + +<p>Creates an App object</p> </div> @@ -2309,9 +2211,8 @@ Creates an App object — - <div class='inline'><p> -a customizable set of options -</p> + <div class='inline'> +<p>a customizable set of options</p> </div> </li> @@ -2541,12 +2442,11 @@ a customizable set of options <td> <pre class="code"><span class="info file"># File 'lib/axlsx/doc_props/app.rb', line 105</span> -<span class='def def kw'>def</span> <span class='initalize identifier id'>initalize</span><span class='lparen token'>(</span><span class='options identifier id'>options</span><span class='assign token'>=</span><span class='lbrace token'>{</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> - <span class='options identifier id'>options</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='o identifier id'>o</span><span class='bitor op'>|</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='dstring node'>"#{o[0]}="</span><span class='comma token'>,</span> <span class='o identifier id'>o</span><span class='lbrack token'>[</span><span class='integer val'>1</span><span class='rbrack token'>]</span><span class='rparen token'>)</span> <span class='if if_mod kw'>if</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='respond_to? fid id'>respond_to?</span> <span class='o identifier id'>o</span><span class='lbrack token'>[</span><span class='integer val'>0</span><span class='rbrack token'>]</span> - <span class='end end kw'>end</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id initalize'>initalize</span><span class='lparen'>(</span><span class='id options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span> + <span class='id options'>options</span><span class='period'>.</span><span class='id each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id o'>o</span><span class='op'>|</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span><span class='rbrace'>}</span><span class='tstring_content'>=</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>1</span><span class='rbracket'>]</span><span class='rparen'>)</span> <span class='kw'>if</span> <span class='kw'>self</span><span class='period'>.</span><span class='id respond_to?'>respond_to?</span> <span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span> + <span class='kw'>end</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -2561,9 +2461,8 @@ a customizable set of options </p><div class="docstring"> <div class="discussion"> - <p> -Generate an app.xml document -</p> + +<p>Generate an app.xml document</p> </div> @@ -2581,9 +2480,8 @@ Generate an app.xml document — - <div class='inline'><p> -The document as a string -</p> + <div class='inline'> +<p>The document as a string</p> </div> </li> @@ -2596,31 +2494,30 @@ The document as a string <pre class="lines"> -137 -138 -139 -140 -141 -142 -143 -144 -145 -146</pre> +167 +168 +169 +170 +171 +172 +173 +174 +175 +176</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/doc_props/app.rb', line 137</span> - -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='rparen token'>)</span> - <span class='builder identifier id'>builder</span> <span class='assign token'>=</span> <span class='Nokogiri constant id'>Nokogiri</span><span class='colon2 op'>::</span><span class='XML constant id'>XML</span><span class='colon2 op'>::</span><span class='Builder constant id'>Builder</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='symbol val'>:encoding</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='ENCODING constant id'>ENCODING</span><span class='rparen token'>)</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='xml identifier id'>xml</span><span class='bitor op'>|</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='symbol val'>:Properties</span><span class='comma token'>,</span> <span class='symbol val'>:xmlns</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='APP_NS constant id'>APP_NS</span><span class='comma token'>,</span> <span class='symbol val'>:'xmlns:vt'</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='APP_NS_VT constant id'>APP_NS_VT</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='instance_values identifier id'>instance_values</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='name identifier id'>name</span><span class='comma token'>,</span> <span class='value identifier id'>value</span><span class='bitor op'>|</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='dstring node'>"ap:#{name}"</span><span class='comma token'>,</span> <span class='value identifier id'>value</span><span class='rparen token'>)</span> - <span class='end end kw'>end</span> - <span class='rbrace token'>}</span> - <span class='end end kw'>end</span> - <span class='builder identifier id'>builder</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/doc_props/app.rb', line 167</span> + +<span class='kw'>def</span> <span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='rparen'>)</span> + <span class='id builder'>builder</span> <span class='op'>=</span> <span class='const'>Nokogiri</span><span class='op'>::</span><span class='const'>XML</span><span class='op'>::</span><span class='const'>Builder</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='symbol'>:encoding</span> <span class='op'>=></span> <span class='const'>ENCODING</span><span class='rparen'>)</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id xml'>xml</span><span class='op'>|</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='symbol'>:Properties</span><span class='comma'>,</span> <span class='symbol'>:xmlns</span> <span class='op'>=></span> <span class='const'>APP_NS</span><span class='comma'>,</span> <span class='symbol'>:xmlns:vt</span><span class='tstring_end'>'</span></span> <span class='op'>=></span> <span class='const'>APP_NS_VT</span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id instance_values'>instance_values</span><span class='period'>.</span><span class='id each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id name'>name</span><span class='comma'>,</span> <span class='id value'>value</span><span class='op'>|</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>ap:</span><span class='embexpr_beg'>#{</span><span class='id name'>name</span><span class='rbrace'>}</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='id value'>value</span><span class='rparen'>)</span> + <span class='kw'>end</span> + <span class='rbrace'>}</span> + <span class='kw'>end</span> + <span class='id builder'>builder</span><span class='period'>.</span><span class='id to_xml'>to_xml</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -2631,9 +2528,9 @@ The document as a string </div> <div id="footer"> - Generated on Wed Nov 23 22:21:04 2011 by + Generated on Sat Nov 26 13:16:36 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/Axis.html b/doc/Axlsx/Axis.html index efc31547..b3e3b295 100644 --- a/doc/Axlsx/Axis.html +++ b/doc/Axlsx/Axis.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::Axis - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -94,9 +94,8 @@ <h2>Overview</h2><div class="docstring"> <div class="discussion"> - <p> -the access class defines common properties and values for a chart axis. -</p> + +<p>the access class defines common properties and values for a chart axis.</p> </div> @@ -132,9 +131,8 @@ the access class defines common properties and values for a chart axis. - <span class="summary_desc"><div class='inline'><p> -the id of the axis. -</p> + <span class="summary_desc"><div class='inline'> +<p>the id of the axis.</p> </div></span> </li> @@ -159,9 +157,8 @@ the id of the axis. - <span class="summary_desc"><div class='inline'><p> -The position of the axis must be one of [:l, :r, :t, :b]. -</p> + <span class="summary_desc"><div class='inline'> +<p>The position of the axis must be one of [:l, :r, :t, :b].</p> </div></span> </li> @@ -186,9 +183,8 @@ The position of the axis must be one of [:l, :r, :t, :b]. - <span class="summary_desc"><div class='inline'><p> -The perpendicular axis. -</p> + <span class="summary_desc"><div class='inline'> +<p>The perpendicular axis.</p> </div></span> </li> @@ -213,10 +209,9 @@ The perpendicular axis. - <span class="summary_desc"><div class='inline'><p> -specifies how the perpendicular axis is crossed must be one of [:autoZero, -:min, :max]. -</p> + <span class="summary_desc"><div class='inline'> +<p>specifies how the perpendicular axis is crossed must be one of [:autoZero, +:min, :max].</p> </div></span> </li> @@ -241,9 +236,8 @@ specifies how the perpendicular axis is crossed must be one of [:autoZero, - <span class="summary_desc"><div class='inline'><p> -The number format format code for this axis default :General. -</p> + <span class="summary_desc"><div class='inline'> +<p>The number format format code for this axis default :General.</p> </div></span> </li> @@ -268,9 +262,8 @@ The number format format code for this axis default :General. - <span class="summary_desc"><div class='inline'><p> -The scaling of the axis. -</p> + <span class="summary_desc"><div class='inline'> +<p>The scaling of the axis.</p> </div></span> </li> @@ -295,9 +288,8 @@ The scaling of the axis. - <span class="summary_desc"><div class='inline'><p> -the position of the tick labels must be one of [:nextTo, :high, :low]. -</p> + <span class="summary_desc"><div class='inline'> +<p>the position of the tick labels must be one of [:nextTo, :high, :low].</p> </div></span> </li> @@ -334,9 +326,8 @@ the position of the tick labels must be one of [:nextTo, :high, :low]. - <span class="summary_desc"><div class='inline'><p> -Creates an Axis object. -</p> + <span class="summary_desc"><div class='inline'> +<p>Creates an Axis object.</p> </div></span> </li> @@ -358,9 +349,8 @@ Creates an Axis object. - <span class="summary_desc"><div class='inline'><p> -Serializes the common axis. -</p> + <span class="summary_desc"><div class='inline'> +<p>Serializes the common axis.</p> </div></span> </li> @@ -381,9 +371,8 @@ Serializes the common axis. </p><div class="docstring"> <div class="discussion"> - <p> -Creates an Axis object -</p> + +<p>Creates an Axis object</p> </div> @@ -402,9 +391,8 @@ Creates an Axis object — - <div class='inline'><p> -the id of this axis -</p> + <div class='inline'> +<p>the id of this axis</p> </div> </li> @@ -419,9 +407,8 @@ the id of this axis — - <div class='inline'><p> -the id of the perpendicular axis -</p> + <div class='inline'> +<p>the id of the perpendicular axis</p> </div> </li> @@ -438,9 +425,8 @@ the id of the perpendicular axis — - <div class='inline'><p> -a customizable set of options -</p> + <div class='inline'> +<p>a customizable set of options</p> </div> </li> @@ -498,9 +484,8 @@ a customizable set of options — - <div class='inline'><p> -If axId or crossAx are not unsigned integers -</p> + <div class='inline'> +<p>If axId or crossAx are not unsigned integers</p> </div> </li> @@ -526,26 +511,27 @@ If axId or crossAx are not unsigned integers 55 56 57 -58</pre> +58 +59</pre> </td> <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/axis.rb', line 45</span> -<span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span><span class='lparen token'>(</span><span class='axId identifier id'>axId</span><span class='comma token'>,</span> <span class='crossAx identifier id'>crossAx</span><span class='comma token'>,</span> <span class='options identifier id'>options</span><span class='assign token'>=</span><span class='lbrace token'>{</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> - <span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='validate_unsigned_int identifier id'>validate_unsigned_int</span><span class='lparen token'>(</span><span class='axId identifier id'>axId</span><span class='rparen token'>)</span> - <span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='validate_unsigned_int identifier id'>validate_unsigned_int</span><span class='lparen token'>(</span><span class='crossAx identifier id'>crossAx</span><span class='rparen token'>)</span> - <span class='@axId ivar id'>@axId</span> <span class='assign token'>=</span> <span class='axId identifier id'>axId</span> - <span class='@crossAx ivar id'>@crossAx</span> <span class='assign token'>=</span> <span class='crossAx identifier id'>crossAx</span> - <span class='@scaling ivar id'>@scaling</span> <span class='assign token'>=</span> <span class='Scaling constant id'>Scaling</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='symbol val'>:orientation=</span><span class='gt op'>></span><span class='symbol val'>:minMax</span><span class='rparen token'>)</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='axPos identifier id'>axPos</span> <span class='assign token'>=</span> <span class='symbol val'>:l</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='tickLblPos identifier id'>tickLblPos</span> <span class='assign token'>=</span> <span class='symbol val'>:nextTo</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='format_code identifier id'>format_code</span> <span class='assign token'>=</span> <span class='string val'>"General"</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='crosses identifier id'>crosses</span> <span class='assign token'>=</span> <span class='symbol val'>:autoZero</span> - <span class='options identifier id'>options</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='o identifier id'>o</span><span class='bitor op'>|</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='dstring node'>"#{o[0]}="</span><span class='comma token'>,</span> <span class='o identifier id'>o</span><span class='lbrack token'>[</span><span class='integer val'>1</span><span class='rbrack token'>]</span><span class='rparen token'>)</span> <span class='if if_mod kw'>if</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='respond_to? fid id'>respond_to?</span> <span class='dstring node'>"#{o[0]}="</span> - <span class='end end kw'>end</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id initialize'>initialize</span><span class='lparen'>(</span><span class='id axId'>axId</span><span class='comma'>,</span> <span class='id crossAx'>crossAx</span><span class='comma'>,</span> <span class='id options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span> + <span class='const'>Axlsx</span><span class='op'>::</span><span class='id validate_unsigned_int'>validate_unsigned_int</span><span class='lparen'>(</span><span class='id axId'>axId</span><span class='rparen'>)</span> + <span class='const'>Axlsx</span><span class='op'>::</span><span class='id validate_unsigned_int'>validate_unsigned_int</span><span class='lparen'>(</span><span class='id crossAx'>crossAx</span><span class='rparen'>)</span> + <span class='ivar'>@axId</span> <span class='op'>=</span> <span class='id axId'>axId</span> + <span class='ivar'>@crossAx</span> <span class='op'>=</span> <span class='id crossAx'>crossAx</span> + <span class='ivar'>@format_code</span> <span class='op'>=</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>General</span><span class='tstring_end'>"</span></span> + <span class='ivar'>@scaling</span> <span class='op'>=</span> <span class='const'>Scaling</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='symbol'>:orientation</span><span class='op'>=></span><span class='symbol'>:minMax</span><span class='rparen'>)</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id axPos'>axPos</span> <span class='op'>=</span> <span class='symbol'>:l</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id tickLblPos'>tickLblPos</span> <span class='op'>=</span> <span class='symbol'>:nextTo</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id format_code'>format_code</span> <span class='op'>=</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>General</span><span class='tstring_end'>"</span></span> + <span class='kw'>self</span><span class='period'>.</span><span class='id crosses'>crosses</span> <span class='op'>=</span> <span class='symbol'>:autoZero</span> + <span class='id options'>options</span><span class='period'>.</span><span class='id each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id o'>o</span><span class='op'>|</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span><span class='rbrace'>}</span><span class='tstring_content'>=</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>1</span><span class='rbracket'>]</span><span class='rparen'>)</span> <span class='kw'>if</span> <span class='kw'>self</span><span class='period'>.</span><span class='id respond_to?'>respond_to?</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span><span class='rbrace'>}</span><span class='tstring_content'>=</span><span class='tstring_end'>"</span></span> + <span class='kw'>end</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -568,9 +554,8 @@ If axId or crossAx are not unsigned integers </p><div class="docstring"> <div class="discussion"> - <p> -the id of the axis. -</p> + +<p>the id of the axis.</p> </div> @@ -604,10 +589,9 @@ the id of the axis. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/axis.rb', line 7</span> -<span class='def def kw'>def</span> <span class='axId identifier id'>axId</span> - <span class='@axId ivar id'>@axId</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id axId'>axId</span> + <span class='ivar'>@axId</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -625,9 +609,8 @@ the id of the axis. </p><div class="docstring"> <div class="discussion"> - <p> -The position of the axis must be one of [:l, :r, :t, :b] -</p> + +<p>The position of the axis must be one of [:l, :r, :t, :b]</p> </div> @@ -661,10 +644,9 @@ The position of the axis must be one of [:l, :r, :t, :b] <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/axis.rb', line 21</span> -<span class='def def kw'>def</span> <span class='axPos identifier id'>axPos</span> - <span class='@axPos ivar id'>@axPos</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id axPos'>axPos</span> + <span class='ivar'>@axPos</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -682,9 +664,8 @@ The position of the axis must be one of [:l, :r, :t, :b] </p><div class="docstring"> <div class="discussion"> - <p> -The perpendicular axis -</p> + +<p>The perpendicular axis</p> </div> @@ -718,10 +699,9 @@ The perpendicular axis <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/axis.rb', line 11</span> -<span class='def def kw'>def</span> <span class='crossAx identifier id'>crossAx</span> - <span class='@crossAx ivar id'>@crossAx</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id crossAx'>crossAx</span> + <span class='ivar'>@crossAx</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -739,10 +719,9 @@ The perpendicular axis </p><div class="docstring"> <div class="discussion"> - <p> -specifies how the perpendicular axis is crossed must be one of [:autoZero, -:min, :max] -</p> + +<p>specifies how the perpendicular axis is crossed must be one of [:autoZero, +:min, :max]</p> </div> @@ -776,10 +755,9 @@ specifies how the perpendicular axis is crossed must be one of [:autoZero, <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/axis.rb', line 36</span> -<span class='def def kw'>def</span> <span class='crosses identifier id'>crosses</span> - <span class='@crosses ivar id'>@crosses</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id crosses'>crosses</span> + <span class='ivar'>@crosses</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -797,9 +775,8 @@ specifies how the perpendicular axis is crossed must be one of [:autoZero, </p><div class="docstring"> <div class="discussion"> - <p> -The number format format code for this axis default :General -</p> + +<p>The number format format code for this axis default :General</p> </div> @@ -833,10 +810,9 @@ The number format format code for this axis default :General <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/axis.rb', line 31</span> -<span class='def def kw'>def</span> <span class='format_code identifier id'>format_code</span> - <span class='@format_code ivar id'>@format_code</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id format_code'>format_code</span> + <span class='ivar'>@format_code</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -854,9 +830,8 @@ The number format format code for this axis default :General </p><div class="docstring"> <div class="discussion"> - <p> -The scaling of the axis -</p> + +<p>The scaling of the axis</p> </div> @@ -897,10 +872,9 @@ The scaling of the axis <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/axis.rb', line 16</span> -<span class='def def kw'>def</span> <span class='scaling identifier id'>scaling</span> - <span class='@scaling ivar id'>@scaling</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id scaling'>scaling</span> + <span class='ivar'>@scaling</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -918,9 +892,8 @@ The scaling of the axis </p><div class="docstring"> <div class="discussion"> - <p> -the position of the tick labels must be one of [:nextTo, :high, :low] -</p> + +<p>the position of the tick labels must be one of [:nextTo, :high, :low]</p> </div> @@ -954,10 +927,9 @@ the position of the tick labels must be one of [:nextTo, :high, :low] <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/axis.rb', line 26</span> -<span class='def def kw'>def</span> <span class='tickLblPos identifier id'>tickLblPos</span> - <span class='@tickLblPos ivar id'>@tickLblPos</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id tickLblPos'>tickLblPos</span> + <span class='ivar'>@tickLblPos</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -979,9 +951,8 @@ the position of the tick labels must be one of [:nextTo, :high, :low] </p><div class="docstring"> <div class="discussion"> - <p> -Serializes the common axis -</p> + +<p>Serializes the common axis</p> </div> @@ -1000,9 +971,8 @@ Serializes the common axis — - <div class='inline'><p> -The document builder instance this objects xml will be added to. -</p> + <div class='inline'> +<p>The document builder instance this objects xml will be added to.</p> </div> </li> @@ -1029,31 +999,30 @@ The document builder instance this objects xml will be added to. <pre class="lines"> -68 -69 -70 -71 -72 -73 -74 -75 -76 -77</pre> +79 +80 +81 +82 +83 +84 +85 +86 +87 +88</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/axis.rb', line 68</span> - -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:axId'</span><span class='comma token'>,</span> <span class='symbol val'>:val=</span><span class='gt op'>></span><span class='@axId ivar id'>@axId</span><span class='rparen token'>)</span> - <span class='@scaling ivar id'>@scaling</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:axPos'</span><span class='comma token'>,</span> <span class='symbol val'>:val=</span><span class='gt op'>></span><span class='@axPos ivar id'>@axPos</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:majorGridlines'</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:numFmt'</span><span class='comma token'>,</span> <span class='symbol val'>:formatCode</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='@format_code ivar id'>@format_code</span><span class='comma token'>,</span> <span class='symbol val'>:sourceLinked=</span><span class='gt op'>></span><span class='string val'>"1"</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:tickLblPos'</span><span class='comma token'>,</span> <span class='symbol val'>:val=</span><span class='gt op'>></span><span class='@tickLblPos ivar id'>@tickLblPos</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:crossAx'</span><span class='comma token'>,</span> <span class='symbol val'>:val=</span><span class='gt op'>></span><span class='@crossAx ivar id'>@crossAx</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:crosses'</span><span class='comma token'>,</span> <span class='symbol val'>:val=</span><span class='gt op'>></span><span class='@crosses ivar id'>@crosses</span><span class='rparen token'>)</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/axis.rb', line 79</span> + +<span class='kw'>def</span> <span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:axId</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:val</span><span class='op'>=></span><span class='ivar'>@axId</span><span class='rparen'>)</span> + <span class='ivar'>@scaling</span><span class='period'>.</span><span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:axPos</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:val</span><span class='op'>=></span><span class='ivar'>@axPos</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:majorGridlines</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:numFmt</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:formatCode</span> <span class='op'>=></span> <span class='ivar'>@format_code</span><span class='comma'>,</span> <span class='symbol'>:sourceLinked</span><span class='op'>=></span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>1</span><span class='tstring_end'>"</span></span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:tickLblPos</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:val</span><span class='op'>=></span><span class='ivar'>@tickLblPos</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:crossAx</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:val</span><span class='op'>=></span><span class='ivar'>@crossAx</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:crosses</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:val</span><span class='op'>=></span><span class='ivar'>@crosses</span><span class='rparen'>)</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1064,9 +1033,9 @@ The document builder instance this objects xml will be added to. </div> <div id="footer"> - Generated on Wed Nov 23 22:20:54 2011 by + Generated on Sat Nov 26 13:16:36 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/Bar3DChart.html b/doc/Axlsx/Bar3DChart.html index 1ca256c1..3ad3b313 100644 --- a/doc/Axlsx/Bar3DChart.html +++ b/doc/Axlsx/Bar3DChart.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::Bar3DChart - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -96,10 +96,9 @@ <h2>Overview</h2><div class="docstring"> <div class="discussion"> - <p> -The Bar3DChart is a three dimentional barchart (who would have guessed?) -that you can add to your worksheet. -</p> + +<p>The Bar3DChart is a three dimentional barchart (who would have guessed?) +that you can add to your worksheet.</p> </div> @@ -128,9 +127,8 @@ that you can add to your worksheet. <dt id="GAP_AMOUNT_PERCENT-constant" class="">GAP_AMOUNT_PERCENT = <div class="docstring"> <div class="discussion"> - <p> -validation regex for gap amount percent -</p> + +<p>validation regex for gap amount percent</p> </div> @@ -140,8 +138,7 @@ validation regex for gap amount percent </div> </dt> - <dd><pre class="code"><span class='regexp val'>/0*(([0-9])|([1-9][0-9])|([1-4][0-9][0-9])|500)%/</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='regexp_beg'>/</span><span class='tstring_content'>0*(([0-9])|([1-9][0-9])|([1-4][0-9][0-9])|500)%</span><span class='regexp_end'>/</span></span></pre></dd> </dl> @@ -173,9 +170,8 @@ validation regex for gap amount percent - <span class="summary_desc"><div class='inline'><p> -The direction of the bars in the chart must be one of [:bar, :col]. -</p> + <span class="summary_desc"><div class='inline'> +<p>The direction of the bars in the chart must be one of [:bar, :col].</p> </div></span> </li> @@ -200,9 +196,8 @@ The direction of the bars in the chart must be one of [:bar, :col]. - <span class="summary_desc"><div class='inline'><p> -the category axis. -</p> + <span class="summary_desc"><div class='inline'> +<p>the category axis.</p> </div></span> </li> @@ -227,10 +222,9 @@ the category axis. - <span class="summary_desc"><div class='inline'><p> -space between bar or column clusters, as a percentage of the bar or column -width. -</p> + <span class="summary_desc"><div class='inline'> +<p>space between bar or column clusters, as a percentage of the bar or column +width.</p> </div></span> </li> @@ -255,10 +249,9 @@ width. - <span class="summary_desc"><div class='inline'><p> -space between bar or column clusters, as a percentage of the bar or column -width. -</p> + <span class="summary_desc"><div class='inline'> +<p>space between bar or column clusters, as a percentage of the bar or column +width.</p> </div></span> </li> @@ -283,9 +276,8 @@ width. - <span class="summary_desc"><div class='inline'><p> -grouping for a column, line, or area chart. -</p> + <span class="summary_desc"><div class='inline'> +<p>grouping for a column, line, or area chart.</p> </div></span> </li> @@ -310,10 +302,9 @@ grouping for a column, line, or area chart. - <span class="summary_desc"><div class='inline'><p> -The shabe of the bars or columns must be one of [:cone, :coneToMax, :box, -:cylinder, :pyramid, :pyramidToMax]. -</p> + <span class="summary_desc"><div class='inline'> +<p>The shabe of the bars or columns must be one of [:cone, :coneToMax, :box, +:cylinder, :pyramid, :pyramidToMax].</p> </div></span> </li> @@ -338,9 +329,8 @@ The shabe of the bars or columns must be one of [:cone, :coneToMax, :box, - <span class="summary_desc"><div class='inline'><p> -the valueaxis. -</p> + <span class="summary_desc"><div class='inline'> +<p>the valueaxis.</p> </div></span> </li> @@ -356,7 +346,7 @@ the valueaxis. <h3 class="inherited">Attributes inherited from <span class='object_link'><a href="Chart.html" title="Axlsx::Chart (class)">Chart</a></span></h3> - <p class="inherited"><span class='object_link'><a href="Chart.html#graphic_frame-instance_method" title="Axlsx::Chart#graphic_frame (method)">graphic_frame</a></span>, <span class='object_link'><a href="Chart.html#index-instance_method" title="Axlsx::Chart#index (method)">index</a></span>, <span class='object_link'><a href="Chart.html#pn-instance_method" title="Axlsx::Chart#pn (method)">pn</a></span>, <span class='object_link'><a href="Chart.html#series-instance_method" title="Axlsx::Chart#series (method)">series</a></span>, <span class='object_link'><a href="Chart.html#series_type-instance_method" title="Axlsx::Chart#series_type (method)">series_type</a></span>, <span class='object_link'><a href="Chart.html#show_legend-instance_method" title="Axlsx::Chart#show_legend (method)">show_legend</a></span>, <span class='object_link'><a href="Chart.html#style-instance_method" title="Axlsx::Chart#style (method)">style</a></span>, <span class='object_link'><a href="Chart.html#title-instance_method" title="Axlsx::Chart#title (method)">title</a></span>, <span class='object_link'><a href="Chart.html#view3D-instance_method" title="Axlsx::Chart#view3D (method)">view3D</a></span></p> + <p class="inherited"><span class='object_link'><a href="Chart.html#graphic_frame-instance_method" title="Axlsx::Chart#graphic_frame (method)">graphic_frame</a></span>, <span class='object_link'><a href="Chart.html#series-instance_method" title="Axlsx::Chart#series (method)">series</a></span>, <span class='object_link'><a href="Chart.html#series_type-instance_method" title="Axlsx::Chart#series_type (method)">series_type</a></span>, <span class='object_link'><a href="Chart.html#show_legend-instance_method" title="Axlsx::Chart#show_legend (method)">show_legend</a></span>, <span class='object_link'><a href="Chart.html#style-instance_method" title="Axlsx::Chart#style (method)">style</a></span>, <span class='object_link'><a href="Chart.html#title-instance_method" title="Axlsx::Chart#title (method)">title</a></span>, <span class='object_link'><a href="Chart.html#view3D-instance_method" title="Axlsx::Chart#view3D (method)">view3D</a></span></p> @@ -385,9 +375,8 @@ the valueaxis. - <span class="summary_desc"><div class='inline'><p> -Creates a new bar chart object. -</p> + <span class="summary_desc"><div class='inline'> +<p>Creates a new bar chart object.</p> </div></span> </li> @@ -409,9 +398,8 @@ Creates a new bar chart object. - <span class="summary_desc"><div class='inline'><p> -Serializes the bar chart. -</p> + <span class="summary_desc"><div class='inline'> +<p>Serializes the bar chart.</p> </div></span> </li> @@ -429,7 +417,7 @@ Serializes the bar chart. <h3 class="inherited">Methods inherited from <span class='object_link'><a href="Chart.html" title="Axlsx::Chart (class)">Chart</a></span></h3> - <p class="inherited"><span class='object_link'><a href="Chart.html#add_series-instance_method" title="Axlsx::Chart#add_series (method)">#add_series</a></span>, <span class='object_link'><a href="Chart.html#end_at-instance_method" title="Axlsx::Chart#end_at (method)">#end_at</a></span>, <span class='object_link'><a href="Chart.html#from-instance_method" title="Axlsx::Chart#from (method)">#from</a></span>, <span class='object_link'><a href="Chart.html#start_at-instance_method" title="Axlsx::Chart#start_at (method)">#start_at</a></span>, <span class='object_link'><a href="Chart.html#to-instance_method" title="Axlsx::Chart#to (method)">#to</a></span></p> + <p class="inherited"><span class='object_link'><a href="Chart.html#add_series-instance_method" title="Axlsx::Chart#add_series (method)">#add_series</a></span>, <span class='object_link'><a href="Chart.html#end_at-instance_method" title="Axlsx::Chart#end_at (method)">#end_at</a></span>, <span class='object_link'><a href="Chart.html#from-instance_method" title="Axlsx::Chart#from (method)">#from</a></span>, <span class='object_link'><a href="Chart.html#index-instance_method" title="Axlsx::Chart#index (method)">#index</a></span>, <span class='object_link'><a href="Chart.html#pn-instance_method" title="Axlsx::Chart#pn (method)">#pn</a></span>, <span class='object_link'><a href="Chart.html#start_at-instance_method" title="Axlsx::Chart#start_at (method)">#start_at</a></span>, <span class='object_link'><a href="Chart.html#to-instance_method" title="Axlsx::Chart#to (method)">#to</a></span></p> <div id="constructor_details" class="method_details_list"> <h2>Constructor Details</h2> @@ -442,9 +430,8 @@ Serializes the bar chart. </p><div class="docstring"> <div class="discussion"> - <p> -Creates a new bar chart object -</p> + +<p>Creates a new bar chart object</p> </div> @@ -463,9 +450,8 @@ Creates a new bar chart object — - <div class='inline'><p> -The workbook that owns this chart. -</p> + <div class='inline'> +<p>The workbook that owns this chart.</p> </div> </li> @@ -482,9 +468,8 @@ The workbook that owns this chart. — - <div class='inline'><p> -a customizable set of options -</p> + <div class='inline'> +<p>a customizable set of options</p> </div> </li> @@ -645,23 +630,24 @@ a customizable set of options 68 69 70 -71</pre> +71 +72</pre> </td> <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/bar_3D_chart.rb', line 61</span> -<span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span><span class='lparen token'>(</span><span class='frame identifier id'>frame</span><span class='comma token'>,</span> <span class='options identifier id'>options</span><span class='assign token'>=</span><span class='lbrace token'>{</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> - <span class='@barDir ivar id'>@barDir</span> <span class='assign token'>=</span> <span class='symbol val'>:bar</span> - <span class='@grouping ivar id'>@grouping</span> <span class='assign token'>=</span> <span class='symbol val'>:clustered</span> - <span class='@catAxId ivar id'>@catAxId</span> <span class='assign token'>=</span> <span class='rand identifier id'>rand</span><span class='lparen token'>(</span><span class='integer val'>8</span> <span class='pow op'>**</span> <span class='integer val'>8</span><span class='rparen token'>)</span> - <span class='@valAxId ivar id'>@valAxId</span> <span class='assign token'>=</span> <span class='rand identifier id'>rand</span><span class='lparen token'>(</span><span class='integer val'>8</span> <span class='pow op'>**</span> <span class='integer val'>8</span><span class='rparen token'>)</span> - <span class='@catAxis ivar id'>@catAxis</span> <span class='assign token'>=</span> <span class='CatAxis constant id'>CatAxis</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='@catAxId ivar id'>@catAxId</span><span class='comma token'>,</span> <span class='@valAxId ivar id'>@valAxId</span><span class='rparen token'>)</span> - <span class='@valAxis ivar id'>@valAxis</span> <span class='assign token'>=</span> <span class='ValAxis constant id'>ValAxis</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='@valAxId ivar id'>@valAxId</span><span class='comma token'>,</span> <span class='@catAxId ivar id'>@catAxId</span><span class='rparen token'>)</span> - <span class='super super kw'>super</span><span class='lparen token'>(</span><span class='frame identifier id'>frame</span><span class='comma token'>,</span> <span class='options identifier id'>options</span><span class='rparen token'>)</span> - <span class='@series_type ivar id'>@series_type</span> <span class='assign token'>=</span> <span class='BarSeries constant id'>BarSeries</span> - <span class='@view3D ivar id'>@view3D</span> <span class='assign token'>=</span> <span class='View3D constant id'>View3D</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='lbrace token'>{</span><span class='symbol val'>:rAngAx=</span><span class='gt op'>></span><span class='integer val'>1</span><span class='rbrace token'>}</span><span class='dot token'>.</span><span class='merge identifier id'>merge</span><span class='lparen token'>(</span><span class='options identifier id'>options</span><span class='rparen token'>)</span><span class='rparen token'>)</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id initialize'>initialize</span><span class='lparen'>(</span><span class='id frame'>frame</span><span class='comma'>,</span> <span class='id options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span> + <span class='ivar'>@barDir</span> <span class='op'>=</span> <span class='symbol'>:bar</span> + <span class='ivar'>@grouping</span> <span class='op'>=</span> <span class='symbol'>:clustered</span> + <span class='ivar'>@gapWidth</span><span class='comma'>,</span> <span class='ivar'>@gapDepth</span><span class='comma'>,</span> <span class='ivar'>@shape</span> <span class='op'>=</span> <span class='kw'>nil</span><span class='comma'>,</span> <span class='kw'>nil</span><span class='comma'>,</span> <span class='kw'>nil</span> + <span class='ivar'>@catAxId</span> <span class='op'>=</span> <span class='id rand'>rand</span><span class='lparen'>(</span><span class='int'>8</span> <span class='op'>**</span> <span class='int'>8</span><span class='rparen'>)</span> + <span class='ivar'>@valAxId</span> <span class='op'>=</span> <span class='id rand'>rand</span><span class='lparen'>(</span><span class='int'>8</span> <span class='op'>**</span> <span class='int'>8</span><span class='rparen'>)</span> + <span class='ivar'>@catAxis</span> <span class='op'>=</span> <span class='const'>CatAxis</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='ivar'>@catAxId</span><span class='comma'>,</span> <span class='ivar'>@valAxId</span><span class='rparen'>)</span> + <span class='ivar'>@valAxis</span> <span class='op'>=</span> <span class='const'>ValAxis</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='ivar'>@valAxId</span><span class='comma'>,</span> <span class='ivar'>@catAxId</span><span class='rparen'>)</span> + <span class='kw'>super</span><span class='lparen'>(</span><span class='id frame'>frame</span><span class='comma'>,</span> <span class='id options'>options</span><span class='rparen'>)</span> + <span class='ivar'>@series_type</span> <span class='op'>=</span> <span class='const'>BarSeries</span> + <span class='ivar'>@view3D</span> <span class='op'>=</span> <span class='const'>View3D</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='lbrace'>{</span><span class='symbol'>:rAngAx</span><span class='op'>=></span><span class='int'>1</span><span class='rbrace'>}</span><span class='period'>.</span><span class='id merge'>merge</span><span class='lparen'>(</span><span class='id options'>options</span><span class='rparen'>)</span><span class='rparen'>)</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -684,9 +670,8 @@ a customizable set of options </p><div class="docstring"> <div class="discussion"> - <p> -The direction of the bars in the chart must be one of [:bar, :col] -</p> + +<p>The direction of the bars in the chart must be one of [:bar, :col]</p> </div> @@ -720,10 +705,9 @@ The direction of the bars in the chart must be one of [:bar, :col] <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/bar_3D_chart.rb', line 21</span> -<span class='def def kw'>def</span> <span class='barDir identifier id'>barDir</span> - <span class='@barDir ivar id'>@barDir</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id barDir'>barDir</span> + <span class='ivar'>@barDir</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -741,9 +725,8 @@ The direction of the bars in the chart must be one of [:bar, :col] </p><div class="docstring"> <div class="discussion"> - <p> -the category axis -</p> + +<p>the category axis</p> </div> @@ -777,10 +760,9 @@ the category axis <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/bar_3D_chart.rb', line 12</span> -<span class='def def kw'>def</span> <span class='catAxis identifier id'>catAxis</span> - <span class='@catAxis ivar id'>@catAxis</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id catAxis'>catAxis</span> + <span class='ivar'>@catAxis</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -798,10 +780,9 @@ the category axis </p><div class="docstring"> <div class="discussion"> - <p> -space between bar or column clusters, as a percentage of the bar or column -width. -</p> + +<p>space between bar or column clusters, as a percentage of the bar or column +width.</p> </div> @@ -835,10 +816,9 @@ width. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/bar_3D_chart.rb', line 25</span> -<span class='def def kw'>def</span> <span class='gapDepth identifier id'>gapDepth</span> - <span class='@gapDepth ivar id'>@gapDepth</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id gapDepth'>gapDepth</span> + <span class='ivar'>@gapDepth</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -856,10 +836,9 @@ width. </p><div class="docstring"> <div class="discussion"> - <p> -space between bar or column clusters, as a percentage of the bar or column -width. -</p> + +<p>space between bar or column clusters, as a percentage of the bar or column +width.</p> </div> @@ -893,10 +872,9 @@ width. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/bar_3D_chart.rb', line 29</span> -<span class='def def kw'>def</span> <span class='gapWidth identifier id'>gapWidth</span> - <span class='@gapWidth ivar id'>@gapWidth</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id gapWidth'>gapWidth</span> + <span class='ivar'>@gapWidth</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -914,10 +892,9 @@ width. </p><div class="docstring"> <div class="discussion"> - <p> -grouping for a column, line, or area chart. must be one of -[:percentStacked, :clustered, :standard, :stacked] -</p> + +<p>grouping for a column, line, or area chart. must be one of +[:percentStacked, :clustered, :standard, :stacked]</p> </div> @@ -951,10 +928,9 @@ grouping for a column, line, or area chart. must be one of <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/bar_3D_chart.rb', line 34</span> -<span class='def def kw'>def</span> <span class='grouping identifier id'>grouping</span> - <span class='@grouping ivar id'>@grouping</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id grouping'>grouping</span> + <span class='ivar'>@grouping</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -972,10 +948,9 @@ grouping for a column, line, or area chart. must be one of </p><div class="docstring"> <div class="discussion"> - <p> -The shabe of the bars or columns must be one of [:cone, :coneToMax, :box, -:cylinder, :pyramid, :pyramidToMax] -</p> + +<p>The shabe of the bars or columns must be one of [:cone, :coneToMax, :box, +:cylinder, :pyramid, :pyramidToMax]</p> </div> @@ -1009,10 +984,9 @@ The shabe of the bars or columns must be one of [:cone, :coneToMax, :box, <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/bar_3D_chart.rb', line 39</span> -<span class='def def kw'>def</span> <span class='shape identifier id'>shape</span> - <span class='@shape ivar id'>@shape</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id shape'>shape</span> + <span class='ivar'>@shape</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1030,9 +1004,8 @@ The shabe of the bars or columns must be one of [:cone, :coneToMax, :box, </p><div class="docstring"> <div class="discussion"> - <p> -the valueaxis -</p> + +<p>the valueaxis</p> </div> @@ -1066,10 +1039,9 @@ the valueaxis <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/bar_3D_chart.rb', line 16</span> -<span class='def def kw'>def</span> <span class='valAxis identifier id'>valAxis</span> - <span class='@valAxis ivar id'>@valAxis</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id valAxis'>valAxis</span> + <span class='ivar'>@valAxis</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1091,9 +1063,8 @@ the valueaxis </p><div class="docstring"> <div class="discussion"> - <p> -Serializes the bar chart -</p> + +<p>Serializes the bar chart</p> </div> @@ -1120,14 +1091,6 @@ Serializes the bar chart <pre class="lines"> -101 -102 -103 -104 -105 -106 -107 -108 109 110 111 @@ -1137,30 +1100,37 @@ Serializes the bar chart 115 116 117 -118</pre> +118 +119 +120 +121 +122 +123 +124 +125 +126</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/bar_3D_chart.rb', line 101</span> - -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span> - <span class='super super kw'>super</span><span class='lparen token'>(</span><span class='rparen token'>)</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='xml identifier id'>xml</span><span class='bitor op'>|</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:bar3DChart'</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:barDir'</span><span class='comma token'>,</span> <span class='symbol val'>:val</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='barDir identifier id'>barDir</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:grouping'</span><span class='comma token'>,</span> <span class='symbol val'>:val=</span><span class='gt op'>></span><span class='grouping identifier id'>grouping</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:varyColors'</span><span class='comma token'>,</span> <span class='symbol val'>:val=</span><span class='gt op'>></span><span class='integer val'>1</span><span class='rparen token'>)</span> - <span class='@series ivar id'>@series</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='lbrace token'>{</span> <span class='bitor op'>|</span><span class='ser identifier id'>ser</span><span class='bitor op'>|</span> <span class='ser identifier id'>ser</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> <span class='rbrace token'>}</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:gapWidth'</span><span class='comma token'>,</span> <span class='symbol val'>:val=</span><span class='gt op'>></span><span class='@gapWidth ivar id'>@gapWidth</span><span class='rparen token'>)</span> <span class='unless unless_mod kw'>unless</span> <span class='@gapWidth ivar id'>@gapWidth</span><span class='dot token'>.</span><span class='nil? fid id'>nil?</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:gapDepth'</span><span class='comma token'>,</span> <span class='symbol val'>:val=</span><span class='gt op'>></span><span class='@gapDepth ivar id'>@gapDepth</span><span class='rparen token'>)</span> <span class='unless unless_mod kw'>unless</span> <span class='@gapDepth ivar id'>@gapDepth</span><span class='dot token'>.</span><span class='nil? fid id'>nil?</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:shape'</span><span class='comma token'>,</span> <span class='symbol val'>:val=</span><span class='gt op'>></span><span class='@shape ivar id'>@shape</span><span class='rparen token'>)</span> <span class='unless unless_mod kw'>unless</span> <span class='@shape ivar id'>@shape</span><span class='dot token'>.</span><span class='nil? fid id'>nil?</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:axId'</span><span class='comma token'>,</span> <span class='symbol val'>:val=</span><span class='gt op'>></span><span class='@catAxId ivar id'>@catAxId</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:axId'</span><span class='comma token'>,</span> <span class='symbol val'>:val=</span><span class='gt op'>></span><span class='@valAxId ivar id'>@valAxId</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:axId'</span><span class='comma token'>,</span> <span class='symbol val'>:val=</span><span class='gt op'>></span><span class='integer val'>0</span><span class='rparen token'>)</span> - <span class='rbrace token'>}</span> - <span class='@catAxis ivar id'>@catAxis</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='@valAxis ivar id'>@valAxis</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='end end kw'>end</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/bar_3D_chart.rb', line 109</span> + +<span class='kw'>def</span> <span class='id to_xml'>to_xml</span> + <span class='kw'>super</span><span class='lparen'>(</span><span class='rparen'>)</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id xml'>xml</span><span class='op'>|</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:bar3DChart</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:barDir</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:val</span> <span class='op'>=></span> <span class='id barDir'>barDir</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:grouping</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:val</span><span class='op'>=></span><span class='id grouping'>grouping</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:varyColors</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:val</span><span class='op'>=></span><span class='int'>1</span><span class='rparen'>)</span> + <span class='ivar'>@series</span><span class='period'>.</span><span class='id each'>each</span> <span class='lbrace'>{</span> <span class='op'>|</span><span class='id ser'>ser</span><span class='op'>|</span> <span class='id ser'>ser</span><span class='period'>.</span><span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> <span class='rbrace'>}</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:gapWidth</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:val</span><span class='op'>=></span><span class='ivar'>@gapWidth</span><span class='rparen'>)</span> <span class='kw'>unless</span> <span class='ivar'>@gapWidth</span><span class='period'>.</span><span class='id nil?'>nil?</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:gapDepth</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:val</span><span class='op'>=></span><span class='ivar'>@gapDepth</span><span class='rparen'>)</span> <span class='kw'>unless</span> <span class='ivar'>@gapDepth</span><span class='period'>.</span><span class='id nil?'>nil?</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:shape</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:val</span><span class='op'>=></span><span class='ivar'>@shape</span><span class='rparen'>)</span> <span class='kw'>unless</span> <span class='ivar'>@shape</span><span class='period'>.</span><span class='id nil?'>nil?</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:axId</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:val</span><span class='op'>=></span><span class='ivar'>@catAxId</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:axId</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:val</span><span class='op'>=></span><span class='ivar'>@valAxId</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:axId</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:val</span><span class='op'>=></span><span class='int'>0</span><span class='rparen'>)</span> + <span class='rbrace'>}</span> + <span class='ivar'>@catAxis</span><span class='period'>.</span><span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> + <span class='ivar'>@valAxis</span><span class='period'>.</span><span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> + <span class='kw'>end</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1171,9 +1141,9 @@ Serializes the bar chart </div> <div id="footer"> - Generated on Wed Nov 23 22:20:55 2011 by + Generated on Sat Nov 26 13:16:38 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/BarSeries.html b/doc/Axlsx/BarSeries.html index c4a1b690..14660129 100644 --- a/doc/Axlsx/BarSeries.html +++ b/doc/Axlsx/BarSeries.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::BarSeries - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -99,15 +99,13 @@ <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -The recommended way to manage series is to use Chart#add_series -</p> + <div class='inline'> +<p>The recommended way to manage series is to use Chart#add_series</p> </div> </div> -<p> -A BarSeries defines the title, data and labels for bar charts -</p> + +<p>A BarSeries defines the title, data and labels for bar charts</p> </div> @@ -152,9 +150,8 @@ A BarSeries defines the title, data and labels for bar charts - <span class="summary_desc"><div class='inline'><p> -The data for this series. -</p> + <span class="summary_desc"><div class='inline'> +<p>The data for this series.</p> </div></span> </li> @@ -179,9 +176,8 @@ The data for this series. - <span class="summary_desc"><div class='inline'><p> -The labels for this series. -</p> + <span class="summary_desc"><div class='inline'> +<p>The labels for this series.</p> </div></span> </li> @@ -206,10 +202,9 @@ The labels for this series. - <span class="summary_desc"><div class='inline'><p> -The shabe of the bars or columns must be one of [:percentStacked, -:clustered, :standard, :stacked]. -</p> + <span class="summary_desc"><div class='inline'> +<p>The shabe of the bars or columns must be one of [:percentStacked, +:clustered, :standard, :stacked].</p> </div></span> </li> @@ -225,7 +220,7 @@ The shabe of the bars or columns must be one of [:percentStacked, <h3 class="inherited">Attributes inherited from <span class='object_link'><a href="Series.html" title="Axlsx::Series (class)">Series</a></span></h3> - <p class="inherited"><span class='object_link'><a href="Series.html#chart-instance_method" title="Axlsx::Series#chart (method)">chart</a></span>, <span class='object_link'><a href="Series.html#index-instance_method" title="Axlsx::Series#index (method)">index</a></span>, <span class='object_link'><a href="Series.html#order-instance_method" title="Axlsx::Series#order (method)">order</a></span>, <span class='object_link'><a href="Series.html#title-instance_method" title="Axlsx::Series#title (method)">title</a></span></p> + <p class="inherited"><span class='object_link'><a href="Series.html#chart-instance_method" title="Axlsx::Series#chart (method)">chart</a></span>, <span class='object_link'><a href="Series.html#title-instance_method" title="Axlsx::Series#title (method)">title</a></span></p> @@ -254,9 +249,8 @@ The shabe of the bars or columns must be one of [:percentStacked, - <span class="summary_desc"><div class='inline'><p> -Creates a new series. -</p> + <span class="summary_desc"><div class='inline'> +<p>Creates a new series.</p> </div></span> </li> @@ -278,9 +272,8 @@ Creates a new series. - <span class="summary_desc"><div class='inline'><p> -Serializes the series. -</p> + <span class="summary_desc"><div class='inline'> +<p>Serializes the series.</p> </div></span> </li> @@ -294,7 +287,12 @@ Serializes the series. - <div id="constructor_details" class="method_details_list"> + + + + <h3 class="inherited">Methods inherited from <span class='object_link'><a href="Series.html" title="Axlsx::Series (class)">Series</a></span></h3> + <p class="inherited"><span class='object_link'><a href="Series.html#index-instance_method" title="Axlsx::Series#index (method)">#index</a></span>, <span class='object_link'><a href="Series.html#order-instance_method" title="Axlsx::Series#order (method)">#order</a></span>, <span class='object_link'><a href="Series.html#order%3D-instance_method" title="Axlsx::Series#order= (method)">#order=</a></span></p> +<div id="constructor_details" class="method_details_list"> <h2>Constructor Details</h2> <div class="method_details first"> @@ -306,9 +304,8 @@ Serializes the series. </p><div class="docstring"> <div class="discussion"> - <p> -Creates a new series -</p> + +<p>Creates a new series</p> </div> @@ -340,9 +337,8 @@ Creates a new series — - <div class='inline'><p> -a customizable set of options -</p> + <div class='inline'> +<p>a customizable set of options</p> </div> </li> @@ -413,13 +409,12 @@ a customizable set of options <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/bar_series.rb', line 28</span> -<span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span><span class='lparen token'>(</span><span class='chart identifier id'>chart</span><span class='comma token'>,</span> <span class='options identifier id'>options</span><span class='assign token'>=</span><span class='lbrace token'>{</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> - <span class='@shape ivar id'>@shape</span> <span class='assign token'>=</span> <span class='symbol val'>:box</span> - <span class='super super kw'>super</span><span class='lparen token'>(</span><span class='chart identifier id'>chart</span><span class='comma token'>,</span> <span class='options identifier id'>options</span><span class='rparen token'>)</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='labels identifier id'>labels</span> <span class='assign token'>=</span> <span class='CatAxisData constant id'>CatAxisData</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='options identifier id'>options</span><span class='lbrack token'>[</span><span class='symbol val'>:labels</span><span class='rbrack token'>]</span><span class='rparen token'>)</span> <span class='unless unless_mod kw'>unless</span> <span class='options identifier id'>options</span><span class='lbrack token'>[</span><span class='symbol val'>:labels</span><span class='rbrack token'>]</span><span class='dot token'>.</span><span class='nil? fid id'>nil?</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='data identifier id'>data</span> <span class='assign token'>=</span> <span class='ValAxisData constant id'>ValAxisData</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='options identifier id'>options</span><span class='lbrack token'>[</span><span class='symbol val'>:data</span><span class='rbrack token'>]</span><span class='rparen token'>)</span> <span class='unless unless_mod kw'>unless</span> <span class='options identifier id'>options</span><span class='lbrack token'>[</span><span class='symbol val'>:data</span><span class='rbrack token'>]</span><span class='dot token'>.</span><span class='nil? fid id'>nil?</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id initialize'>initialize</span><span class='lparen'>(</span><span class='id chart'>chart</span><span class='comma'>,</span> <span class='id options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span> + <span class='ivar'>@shape</span> <span class='op'>=</span> <span class='symbol'>:box</span> + <span class='kw'>super</span><span class='lparen'>(</span><span class='id chart'>chart</span><span class='comma'>,</span> <span class='id options'>options</span><span class='rparen'>)</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id labels'>labels</span> <span class='op'>=</span> <span class='const'>CatAxisData</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='id options'>options</span><span class='lbracket'>[</span><span class='symbol'>:labels</span><span class='rbracket'>]</span><span class='rparen'>)</span> <span class='kw'>unless</span> <span class='id options'>options</span><span class='lbracket'>[</span><span class='symbol'>:labels</span><span class='rbracket'>]</span><span class='period'>.</span><span class='id nil?'>nil?</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id data'>data</span> <span class='op'>=</span> <span class='const'>ValAxisData</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='id options'>options</span><span class='lbracket'>[</span><span class='symbol'>:data</span><span class='rbracket'>]</span><span class='rparen'>)</span> <span class='kw'>unless</span> <span class='id options'>options</span><span class='lbracket'>[</span><span class='symbol'>:data</span><span class='rbracket'>]</span><span class='period'>.</span><span class='id nil?'>nil?</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -442,9 +437,8 @@ a customizable set of options </p><div class="docstring"> <div class="discussion"> - <p> -The data for this series. -</p> + +<p>The data for this series.</p> </div> @@ -478,10 +472,9 @@ The data for this series. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/bar_series.rb', line 11</span> -<span class='def def kw'>def</span> <span class='data identifier id'>data</span> - <span class='@data ivar id'>@data</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id data'>data</span> + <span class='ivar'>@data</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -499,9 +492,8 @@ The data for this series. </p><div class="docstring"> <div class="discussion"> - <p> -The labels for this series. -</p> + +<p>The labels for this series.</p> </div> @@ -535,10 +527,9 @@ The labels for this series. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/bar_series.rb', line 15</span> -<span class='def def kw'>def</span> <span class='labels identifier id'>labels</span> - <span class='@labels ivar id'>@labels</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id labels'>labels</span> + <span class='ivar'>@labels</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -556,10 +547,9 @@ The labels for this series. </p><div class="docstring"> <div class="discussion"> - <p> -The shabe of the bars or columns must be one of [:percentStacked, -:clustered, :standard, :stacked] -</p> + +<p>The shabe of the bars or columns must be one of [:percentStacked, +:clustered, :standard, :stacked]</p> </div> @@ -593,10 +583,9 @@ The shabe of the bars or columns must be one of [:percentStacked, <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/bar_series.rb', line 20</span> -<span class='def def kw'>def</span> <span class='shape identifier id'>shape</span> - <span class='@shape ivar id'>@shape</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id shape'>shape</span> + <span class='ivar'>@shape</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -618,9 +607,8 @@ The shabe of the bars or columns must be one of [:percentStacked, </p><div class="docstring"> <div class="discussion"> - <p> -Serializes the series -</p> + +<p>Serializes the series</p> </div> @@ -639,9 +627,8 @@ Serializes the series — - <div class='inline'><p> -The document builder instance this objects xml will be added to. -</p> + <div class='inline'> +<p>The document builder instance this objects xml will be added to.</p> </div> </li> @@ -668,25 +655,24 @@ The document builder instance this objects xml will be added to. <pre class="lines"> -43 -44 45 46 47 48 -49</pre> +49 +50 +51</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/bar_series.rb', line 43</span> - -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='super super kw'>super</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='xml identifier id'>xml</span><span class='bitor op'>|</span> - <span class='@labels ivar id'>@labels</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> <span class='unless unless_mod kw'>unless</span> <span class='@labels ivar id'>@labels</span><span class='dot token'>.</span><span class='nil? fid id'>nil?</span> - <span class='@data ivar id'>@data</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> <span class='unless unless_mod kw'>unless</span> <span class='@data ivar id'>@data</span><span class='dot token'>.</span><span class='nil? fid id'>nil?</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:shape'</span><span class='comma token'>,</span> <span class='symbol val'>:val=</span><span class='gt op'>></span><span class='@shape ivar id'>@shape</span><span class='rparen token'>)</span> - <span class='end end kw'>end</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/bar_series.rb', line 45</span> + +<span class='kw'>def</span> <span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> + <span class='kw'>super</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id xml_inner'>xml_inner</span><span class='op'>|</span> + <span class='ivar'>@labels</span><span class='period'>.</span><span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml_inner'>xml_inner</span><span class='rparen'>)</span> <span class='kw'>unless</span> <span class='ivar'>@labels</span><span class='period'>.</span><span class='id nil?'>nil?</span> + <span class='ivar'>@data</span><span class='period'>.</span><span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml_inner'>xml_inner</span><span class='rparen'>)</span> <span class='kw'>unless</span> <span class='ivar'>@data</span><span class='period'>.</span><span class='id nil?'>nil?</span> + <span class='id xml_inner'>xml_inner</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:shape</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:val</span><span class='op'>=></span><span class='ivar'>@shape</span><span class='rparen'>)</span> + <span class='kw'>end</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -697,9 +683,9 @@ The document builder instance this objects xml will be added to. </div> <div id="footer"> - Generated on Wed Nov 23 22:20:54 2011 by + Generated on Sat Nov 26 13:16:38 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/Border.html b/doc/Axlsx/Border.html index ef0e2b00..26e5cfff 100644 --- a/doc/Axlsx/Border.html +++ b/doc/Axlsx/Border.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::Border - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -94,9 +94,8 @@ <h2>Overview</h2><div class="docstring"> <div class="discussion"> - <p> -This class details a border used in Office Open XML spreadsheet styles. -</p> + +<p>This class details a border used in Office Open XML spreadsheet styles.</p> </div> @@ -128,11 +127,10 @@ This class details a border used in Office Open XML spreadsheet styles. - <span class="summary_desc"><div class='inline'><p> -The diagonal down property for the border that indicates if the border + <span class="summary_desc"><div class='inline'> +<p>The diagonal down property for the border that indicates if the border should include a diagonal line from the top left to the top right of the -cell. -</p> +cell.</p> </div></span> </li> @@ -157,10 +155,9 @@ cell. - <span class="summary_desc"><div class='inline'><p> -The diagonal up property for the border that indicates if the border should -include a diagonal line from the bottom left to the top right of the cell. -</p> + <span class="summary_desc"><div class='inline'> +<p>The diagonal up property for the border that indicates if the border should +include a diagonal line from the bottom left to the top right of the cell.</p> </div></span> </li> @@ -185,11 +182,10 @@ include a diagonal line from the bottom left to the top right of the cell. - <span class="summary_desc"><div class='inline'><p> -The outline property for the border indicating that top, left, right and + <span class="summary_desc"><div class='inline'> +<p>The outline property for the border indicating that top, left, right and bottom borders should only be applied to the outside border of a range of -cells. -</p> +cells.</p> </div></span> </li> @@ -214,9 +210,8 @@ cells. - <span class="summary_desc"><div class='inline'><p> -A list of BorderPr objects for this border. -</p> + <span class="summary_desc"><div class='inline'> +<p>A list of BorderPr objects for this border.</p> </div></span> </li> @@ -253,9 +248,8 @@ A list of BorderPr objects for this border. - <span class="summary_desc"><div class='inline'><p> -Creates a new Border object. -</p> + <span class="summary_desc"><div class='inline'> +<p>Creates a new Border object.</p> </div></span> </li> @@ -277,9 +271,8 @@ Creates a new Border object. - <span class="summary_desc"><div class='inline'><p> -Serializes the border element. -</p> + <span class="summary_desc"><div class='inline'> +<p>Serializes the border element.</p> </div></span> </li> @@ -300,9 +293,8 @@ Serializes the border element. </p><div class="docstring"> <div class="discussion"> - <p> -Creates a new Border object -</p> + +<p>Creates a new Border object</p> </div> @@ -312,20 +304,18 @@ Creates a new Border object <div class="examples"> <h3>Examples:</h3> - <h4><div class='inline'><p> -Making a border -</p> + <h4><div class='inline'> +<p>Making a border</p> </div></h4> - <pre class="example code"><span class='p identifier id'>p</span> <span class='assign token'>=</span> <span class='Package constant id'>Package</span><span class='dot token'>.</span><span class='new identifier id'>new</span> -<span class='red_border identifier id'>red_border</span> <span class='assign token'>=</span> <span class='Border constant id'>Border</span><span class='dot token'>.</span><span class='new identifier id'>new</span> -<span class='lbrack token'>[</span><span class='symbol val'>:left</span><span class='comma token'>,</span> <span class='symbol val'>:right</span><span class='comma token'>,</span> <span class='symbol val'>:top</span><span class='comma token'>,</span> <span class='symbol val'>:bottom</span><span class='rbrack token'>]</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='item identifier id'>item</span><span class='bitor op'>|</span> - <span class='red_border identifier id'>red_border</span><span class='dot token'>.</span><span class='prs identifier id'>prs</span> <span class='lshft op'><<</span> <span class='BorderPr constant id'>BorderPr</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='symbol val'>:name=</span><span class='gt op'>></span><span class='item identifier id'>item</span><span class='comma token'>,</span> <span class='symbol val'>:style=</span><span class='gt op'>></span><span class='symbol val'>:thin</span><span class='comma token'>,</span> <span class='symbol val'>:color=</span><span class='gt op'>></span><span class='Color constant id'>Color</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='symbol val'>:rgb=</span><span class='gt op'>></span><span class='string val'>"FFFF0000"</span><span class='rparen token'>)</span><span class='rparen token'>)</span> <span class='comment val'># </span> -<span class='end end kw'>end</span> -<span class='comment val'># this sets red_border to be the index for the created border.</span> -<span class='red_border identifier id'>red_border</span> <span class='assign token'>=</span> <span class='p identifier id'>p</span><span class='dot token'>.</span><span class='workbook identifier id'>workbook</span><span class='dot token'>.</span><span class='styles identifier id'>styles</span><span class='dot token'>.</span><span class='@borders ivar id'>@borders</span> <span class='lshft op'><<</span> <span class='red_border identifier id'>red_border</span> -<span class='comment val'>#used in row creation as follows. This will add a red border to each of the cells in the row.</span> -<span class='p identifier id'>p</span><span class='dot token'>.</span><span class='workbook identifier id'>workbook</span><span class='dot token'>.</span><span class='add_worksheet identifier id'>add_worksheet</span><span class='dot token'>.</span><span class='rows identifier id'>rows</span> <span class='lshft op'><<</span> <span class='symbol val'>:values=</span><span class='gt op'>></span><span class='lbrack token'>[</span><span class='integer val'>1</span><span class='comma token'>,</span><span class='integer val'>2</span><span class='comma token'>,</span><span class='integer val'>3</span><span class='rbrack token'>]</span> <span class='symbol val'>:style=</span><span class='gt op'>></span><span class='red_border identifier id'>red_border</span> -</pre> + <pre class="example code">p = Package.new +red_border = Border.new +[:left, :right, :top, :bottom].each do |item| + red_border.prs << BorderPr.new(:name=>item, :style=>:thin, :color=>Color.new(:rgb=>"FFFF0000")) # +end +# this sets red_border to be the index for the created border. +red_border = p.workbook.styles.@borders << red_border +#used in row creation as follows. This will add a red border to each of the cells in the row. +p.workbook.add_worksheet.rows << :values=>[1,2,3] :style=>red_border</pre> </div> <h3>Parameters:</h3> @@ -343,9 +333,8 @@ Making a border — - <div class='inline'><p> -a customizable set of options -</p> + <div class='inline'> +<p>a customizable set of options</p> </div> </li> @@ -405,13 +394,12 @@ a customizable set of options <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/border.rb', line 31</span> -<span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span><span class='lparen token'>(</span><span class='options identifier id'>options</span><span class='assign token'>=</span><span class='lbrace token'>{</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> - <span class='@prs ivar id'>@prs</span> <span class='assign token'>=</span> <span class='SimpleTypedList constant id'>SimpleTypedList</span><span class='dot token'>.</span><span class='new identifier id'>new</span> <span class='BorderPr constant id'>BorderPr</span> - <span class='options identifier id'>options</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='o identifier id'>o</span><span class='bitor op'>|</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='dstring node'>"#{o[0]}="</span><span class='comma token'>,</span> <span class='o identifier id'>o</span><span class='lbrack token'>[</span><span class='integer val'>1</span><span class='rbrack token'>]</span><span class='rparen token'>)</span> <span class='if if_mod kw'>if</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='respond_to? fid id'>respond_to?</span> <span class='dstring node'>"#{o[0]}="</span> - <span class='end end kw'>end</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id initialize'>initialize</span><span class='lparen'>(</span><span class='id options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span> + <span class='ivar'>@prs</span> <span class='op'>=</span> <span class='const'>SimpleTypedList</span><span class='period'>.</span><span class='id new'>new</span> <span class='const'>BorderPr</span> + <span class='id options'>options</span><span class='period'>.</span><span class='id each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id o'>o</span><span class='op'>|</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span><span class='rbrace'>}</span><span class='tstring_content'>=</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>1</span><span class='rbracket'>]</span><span class='rparen'>)</span> <span class='kw'>if</span> <span class='kw'>self</span><span class='period'>.</span><span class='id respond_to?'>respond_to?</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span><span class='rbrace'>}</span><span class='tstring_content'>=</span><span class='tstring_end'>"</span></span> + <span class='kw'>end</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -434,11 +422,10 @@ a customizable set of options </p><div class="docstring"> <div class="discussion"> - <p> -The diagonal down property for the border that indicates if the border + +<p>The diagonal down property for the border that indicates if the border should include a diagonal line from the top left to the top right of the -cell. -</p> +cell.</p> </div> @@ -456,11 +443,10 @@ cell. — - <div class='inline'><p> -The diagonal down property for the border that indicates if the border + <div class='inline'> +<p>The diagonal down property for the border that indicates if the border should include a diagonal line from the top left to the top right of the -cell. -</p> +cell.</p> </div> </li> @@ -480,10 +466,9 @@ cell. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/border.rb', line 9</span> -<span class='def def kw'>def</span> <span class='diagonalDown identifier id'>diagonalDown</span> - <span class='@diagonalDown ivar id'>@diagonalDown</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id diagonalDown'>diagonalDown</span> + <span class='ivar'>@diagonalDown</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -501,10 +486,9 @@ cell. </p><div class="docstring"> <div class="discussion"> - <p> -The diagonal up property for the border that indicates if the border should -include a diagonal line from the bottom left to the top right of the cell. -</p> + +<p>The diagonal up property for the border that indicates if the border should +include a diagonal line from the bottom left to the top right of the cell.</p> </div> @@ -522,10 +506,9 @@ include a diagonal line from the bottom left to the top right of the cell. — - <div class='inline'><p> -The diagonal up property for the border that indicates if the border should -include a diagonal line from the bottom left to the top right of the cell. -</p> + <div class='inline'> +<p>The diagonal up property for the border that indicates if the border should +include a diagonal line from the bottom left to the top right of the cell.</p> </div> </li> @@ -545,10 +528,9 @@ include a diagonal line from the bottom left to the top right of the cell. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/border.rb', line 6</span> -<span class='def def kw'>def</span> <span class='diagonalUp identifier id'>diagonalUp</span> - <span class='@diagonalUp ivar id'>@diagonalUp</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id diagonalUp'>diagonalUp</span> + <span class='ivar'>@diagonalUp</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -566,11 +548,10 @@ include a diagonal line from the bottom left to the top right of the cell. </p><div class="docstring"> <div class="discussion"> - <p> -The outline property for the border indicating that top, left, right and + +<p>The outline property for the border indicating that top, left, right and bottom borders should only be applied to the outside border of a range of -cells. -</p> +cells.</p> </div> @@ -588,11 +569,10 @@ cells. — - <div class='inline'><p> -The outline property for the border indicating that top, left, right and + <div class='inline'> +<p>The outline property for the border indicating that top, left, right and bottom borders should only be applied to the outside border of a range of -cells. -</p> +cells.</p> </div> </li> @@ -612,10 +592,9 @@ cells. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/border.rb', line 12</span> -<span class='def def kw'>def</span> <span class='outline identifier id'>outline</span> - <span class='@outline ivar id'>@outline</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id outline'>outline</span> + <span class='ivar'>@outline</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -633,9 +612,8 @@ cells. </p><div class="docstring"> <div class="discussion"> - <p> -A list of BorderPr objects for this border. -</p> + +<p>A list of BorderPr objects for this border.</p> </div> @@ -653,9 +631,8 @@ A list of BorderPr objects for this border. — - <div class='inline'><p> -A list of BorderPr objects for this border. -</p> + <div class='inline'> +<p>A list of BorderPr objects for this border.</p> </div> </li> @@ -675,10 +652,9 @@ A list of BorderPr objects for this border. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/border.rb', line 15</span> -<span class='def def kw'>def</span> <span class='prs identifier id'>prs</span> - <span class='@prs ivar id'>@prs</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id prs'>prs</span> + <span class='ivar'>@prs</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -700,9 +676,8 @@ A list of BorderPr objects for this border. </p><div class="docstring"> <div class="discussion"> - <p> -Serializes the border element -</p> + +<p>Serializes the border element</p> </div> @@ -721,9 +696,8 @@ Serializes the border element — - <div class='inline'><p> -The document builder instance this objects xml will be added to. -</p> + <div class='inline'> +<p>The document builder instance this objects xml will be added to.</p> </div> </li> @@ -737,25 +711,28 @@ The document builder instance this objects xml will be added to. <pre class="lines"> -44 -45 -46 47 48 49 -50</pre> +50 +51 +52 +53 +54 +55</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/border.rb', line 44</span> - -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='border identifier id'>border</span><span class='lparen token'>(</span><span class='self self kw'>self</span><span class='dot token'>.</span><span class='instance_values identifier id'>instance_values</span><span class='dot token'>.</span><span class='select identifier id'>select</span><span class='lbrace token'>{</span> <span class='bitor op'>|</span><span class='k identifier id'>k</span><span class='comma token'>,</span><span class='v identifier id'>v</span><span class='bitor op'>|</span> <span class='lbrack token'>[</span><span class='symbol val'>:diagonalUp</span><span class='comma token'>,</span> <span class='symbol val'>:diagonalDown</span><span class='comma token'>,</span> <span class='symbol val'>:outline</span><span class='rbrack token'>]</span><span class='dot token'>.</span><span class='include? fid id'>include?</span> <span class='k identifier id'>k</span> <span class='rbrace token'>}</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='lbrack token'>[</span><span class='symbol val'>:start</span><span class='comma token'>,</span> <span class='symbol val'>:end</span><span class='comma token'>,</span> <span class='symbol val'>:left</span><span class='comma token'>,</span> <span class='symbol val'>:right</span><span class='comma token'>,</span> <span class='symbol val'>:top</span><span class='comma token'>,</span> <span class='symbol val'>:bottom</span><span class='comma token'>,</span> <span class='symbol val'>:diagonal</span><span class='comma token'>,</span> <span class='symbol val'>:vertical</span><span class='comma token'>,</span> <span class='symbol val'>:horizontal</span><span class='rbrack token'>]</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='k identifier id'>k</span><span class='bitor op'>|</span> - <span class='@prs ivar id'>@prs</span><span class='dot token'>.</span><span class='select identifier id'>select</span> <span class='lbrace token'>{</span> <span class='bitor op'>|</span><span class='pr identifier id'>pr</span><span class='bitor op'>|</span> <span class='pr identifier id'>pr</span><span class='dot token'>.</span><span class='name identifier id'>name</span> <span class='eq op'>==</span> <span class='k identifier id'>k</span> <span class='rbrace token'>}</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='lbrace token'>{</span> <span class='bitor op'>|</span><span class='pr identifier id'>pr</span><span class='bitor op'>|</span> <span class='pr identifier id'>pr</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> <span class='rbrace token'>}</span> - <span class='end end kw'>end</span> - <span class='rbrace token'>}</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/border.rb', line 47</span> + +<span class='kw'>def</span> <span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id border'>border</span><span class='lparen'>(</span><span class='kw'>self</span><span class='period'>.</span><span class='id instance_values'>instance_values</span><span class='period'>.</span><span class='id select'>select</span><span class='lbrace'>{</span> <span class='op'>|</span><span class='id k'>k</span><span class='comma'>,</span><span class='id v'>v</span><span class='op'>|</span> <span class='lbracket'>[</span><span class='symbol'>:diagonalUp</span><span class='comma'>,</span> <span class='symbol'>:diagonalDown</span><span class='comma'>,</span> <span class='symbol'>:outline</span><span class='rbracket'>]</span><span class='period'>.</span><span class='id include?'>include?</span> <span class='id k'>k</span> <span class='rbrace'>}</span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='lbracket'>[</span><span class='symbol'>:start</span><span class='comma'>,</span> <span class='symbol'>:end</span><span class='comma'>,</span> <span class='symbol'>:left</span><span class='comma'>,</span> <span class='symbol'>:right</span><span class='comma'>,</span> <span class='symbol'>:top</span><span class='comma'>,</span> <span class='symbol'>:bottom</span><span class='comma'>,</span> <span class='symbol'>:diagonal</span><span class='comma'>,</span> <span class='symbol'>:vertical</span><span class='comma'>,</span> <span class='symbol'>:horizontal</span><span class='rbracket'>]</span><span class='period'>.</span><span class='id each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id k'>k</span><span class='op'>|</span> + <span class='ivar'>@prs</span><span class='period'>.</span><span class='id select'>select</span> <span class='lbrace'>{</span> <span class='op'>|</span><span class='id pr'>pr</span><span class='op'>|</span> <span class='id pr'>pr</span><span class='period'>.</span><span class='id name'>name</span> <span class='op'>==</span> <span class='id k'>k</span> <span class='rbrace'>}</span><span class='period'>.</span><span class='id each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id part'>part</span><span class='op'>|</span> + <span class='id part'>part</span><span class='period'>.</span><span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> + <span class='kw'>end</span> + <span class='kw'>end</span> + <span class='rbrace'>}</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -766,9 +743,9 @@ The document builder instance this objects xml will be added to. </div> <div id="footer"> - Generated on Wed Nov 23 22:21:02 2011 by + Generated on Sat Nov 26 13:16:37 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/BorderPr.html b/doc/Axlsx/BorderPr.html index 2b2941d5..47c49d87 100644 --- a/doc/Axlsx/BorderPr.html +++ b/doc/Axlsx/BorderPr.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::BorderPr - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -94,9 +94,8 @@ <h2>Overview</h2><div class="docstring"> <div class="discussion"> - <p> -A border part. -</p> + +<p>A border part.</p> </div> @@ -128,9 +127,8 @@ A border part. - <span class="summary_desc"><div class='inline'><p> -The color of this border part. -</p> + <span class="summary_desc"><div class='inline'> +<p>The color of this border part.</p> </div></span> </li> @@ -155,9 +153,8 @@ The color of this border part. - <span class="summary_desc"><div class='inline'><p> -The name of this border part. -</p> + <span class="summary_desc"><div class='inline'> +<p>The name of this border part.</p> </div></span> </li> @@ -182,9 +179,8 @@ The name of this border part. - <span class="summary_desc"><div class='inline'><p> -The syle of this border part. -</p> + <span class="summary_desc"><div class='inline'> +<p>The syle of this border part.</p> </div></span> </li> @@ -221,9 +217,8 @@ The syle of this border part. - <span class="summary_desc"><div class='inline'><p> -Creates a new Border Part Object. -</p> + <span class="summary_desc"><div class='inline'> +<p>Creates a new Border Part Object.</p> </div></span> </li> @@ -245,9 +240,8 @@ Creates a new Border Part Object. - <span class="summary_desc"><div class='inline'><p> -Serializes the border part. -</p> + <span class="summary_desc"><div class='inline'> +<p>Serializes the border part.</p> </div></span> </li> @@ -268,9 +262,8 @@ Serializes the border part. </p><div class="docstring"> <div class="discussion"> - <p> -Creates a new Border Part Object -</p> + +<p>Creates a new Border Part Object</p> </div> @@ -291,9 +284,8 @@ Creates a new Border Part Object — - <div class='inline'><p> -a customizable set of options -</p> + <div class='inline'> +<p>a customizable set of options</p> </div> </li> @@ -359,12 +351,11 @@ a customizable set of options <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/border_pr.rb', line 46</span> -<span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span><span class='lparen token'>(</span><span class='options identifier id'>options</span><span class='assign token'>=</span><span class='lbrace token'>{</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> - <span class='options identifier id'>options</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='o identifier id'>o</span><span class='bitor op'>|</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='dstring node'>"#{o[0]}="</span><span class='comma token'>,</span> <span class='o identifier id'>o</span><span class='lbrack token'>[</span><span class='integer val'>1</span><span class='rbrack token'>]</span><span class='rparen token'>)</span> <span class='if if_mod kw'>if</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='respond_to? fid id'>respond_to?</span> <span class='dstring node'>"#{o[0]}="</span> - <span class='end end kw'>end</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id initialize'>initialize</span><span class='lparen'>(</span><span class='id options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span> + <span class='id options'>options</span><span class='period'>.</span><span class='id each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id o'>o</span><span class='op'>|</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span><span class='rbrace'>}</span><span class='tstring_content'>=</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>1</span><span class='rbracket'>]</span><span class='rparen'>)</span> <span class='kw'>if</span> <span class='kw'>self</span><span class='period'>.</span><span class='id respond_to?'>respond_to?</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span><span class='rbrace'>}</span><span class='tstring_content'>=</span><span class='tstring_end'>"</span></span> + <span class='kw'>end</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -387,9 +378,8 @@ a customizable set of options </p><div class="docstring"> <div class="discussion"> - <p> -The color of this border part. -</p> + +<p>The color of this border part.</p> </div> @@ -407,9 +397,8 @@ The color of this border part. — - <div class='inline'><p> -The color of this border part. -</p> + <div class='inline'> +<p>The color of this border part.</p> </div> </li> @@ -429,10 +418,9 @@ The color of this border part. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/border_pr.rb', line 6</span> -<span class='def def kw'>def</span> <span class='color identifier id'>color</span> - <span class='@color ivar id'>@color</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id color'>color</span> + <span class='ivar'>@color</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -453,26 +441,23 @@ The color of this border part. <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -The following are allowed -</p> -<pre class="code"> - <span class='symbol val'>:start</span> - <span class='symbol val'>:end</span> - <span class='symbol val'>:left</span> - <span class='symbol val'>:right</span> - <span class='symbol val'>:top</span> - <span class='symbol val'>:bottom</span> - <span class='symbol val'>:diagonal</span> - <span class='symbol val'>:vertical</span> - <span class='symbol val'>:horizontal</span> -</pre> + <div class='inline'> +<p>The following are allowed</p> + +<pre class="code"><span class='symbol'>:start</span> +<span class='symbol'>:end</span> +<span class='symbol'>:left</span> +<span class='symbol'>:right</span> +<span class='symbol'>:top</span> +<span class='symbol'>:bottom</span> +<span class='symbol'>:diagonal</span> +<span class='symbol'>:vertical</span> +<span class='symbol'>:horizontal</span></pre> </div> </div> -<p> -The name of this border part -</p> + +<p>The name of this border part</p> </div> @@ -490,9 +475,8 @@ The name of this border part — - <div class='inline'><p> -The name of this border part -</p> + <div class='inline'> +<p>The name of this border part</p> </div> </li> @@ -512,10 +496,9 @@ The name of this border part <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/border_pr.rb', line 39</span> -<span class='def def kw'>def</span> <span class='name identifier id'>name</span> - <span class='@name ivar id'>@name</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id name'>name</span> + <span class='ivar'>@name</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -536,31 +519,28 @@ The name of this border part <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -The following are allowed -</p> -<pre class="code"> - <span class='symbol val'>:none</span> - <span class='symbol val'>:thin</span> - <span class='symbol val'>:medium</span> - <span class='symbol val'>:dashed</span> - <span class='symbol val'>:dotted</span> - <span class='symbol val'>:thick</span> - <span class='symbol val'>:double</span> - <span class='symbol val'>:hair</span> - <span class='symbol val'>:mediumDashed</span> - <span class='symbol val'>:dashDot</span> - <span class='symbol val'>:mediumDashDot</span> - <span class='symbol val'>:dashDotDot</span> - <span class='symbol val'>:mediumDashDotDot</span> - <span class='symbol val'>:slantDashDot</span> -</pre> + <div class='inline'> +<p>The following are allowed</p> + +<pre class="code"><span class='symbol'>:none</span> +<span class='symbol'>:thin</span> +<span class='symbol'>:medium</span> +<span class='symbol'>:dashed</span> +<span class='symbol'>:dotted</span> +<span class='symbol'>:thick</span> +<span class='symbol'>:double</span> +<span class='symbol'>:hair</span> +<span class='symbol'>:mediumDashed</span> +<span class='symbol'>:dashDot</span> +<span class='symbol'>:mediumDashDot</span> +<span class='symbol'>:dashDotDot</span> +<span class='symbol'>:mediumDashDotDot</span> +<span class='symbol'>:slantDashDot</span></pre> </div> </div> -<p> -The syle of this border part. -</p> + +<p>The syle of this border part.</p> </div> @@ -578,9 +558,8 @@ The syle of this border part. — - <div class='inline'><p> -The syle of this border part. -</p> + <div class='inline'> +<p>The syle of this border part.</p> </div> </li> @@ -600,10 +579,9 @@ The syle of this border part. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/border_pr.rb', line 25</span> -<span class='def def kw'>def</span> <span class='style identifier id'>style</span> - <span class='@style ivar id'>@style</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id style'>style</span> + <span class='ivar'>@style</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -625,9 +603,8 @@ The syle of this border part. </p><div class="docstring"> <div class="discussion"> - <p> -Serializes the border part -</p> + +<p>Serializes the border part</p> </div> @@ -646,9 +623,8 @@ Serializes the border part — - <div class='inline'><p> -The document builder instance this objects xml will be added to. -</p> + <div class='inline'> +<p>The document builder instance this objects xml will be added to.</p> </div> </li> @@ -675,21 +651,20 @@ The document builder instance this objects xml will be added to. <pre class="lines"> -59 -60 -61 62 -63</pre> +63 +64 +65 +66</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/border_pr.rb', line 59</span> - -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='@name ivar id'>@name</span><span class='comma token'>,</span> <span class='symbol val'>:style=</span><span class='gt op'>></span><span class='@style ivar id'>@style</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='@color ivar id'>@color</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> <span class='if if_mod kw'>if</span> <span class='@color ivar id'>@color</span><span class='dot token'>.</span><span class='is_a? fid id'>is_a?</span> <span class='Color constant id'>Color</span> - <span class='rbrace token'>}</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/border_pr.rb', line 62</span> + +<span class='kw'>def</span> <span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='ivar'>@name</span><span class='comma'>,</span> <span class='symbol'>:style</span> <span class='op'>=></span> <span class='ivar'>@style</span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='ivar'>@color</span><span class='period'>.</span><span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> <span class='kw'>if</span> <span class='ivar'>@color</span><span class='period'>.</span><span class='id is_a?'>is_a?</span> <span class='const'>Color</span> + <span class='rbrace'>}</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -700,9 +675,9 @@ The document builder instance this objects xml will be added to. </div> <div id="footer"> - Generated on Wed Nov 23 22:20:56 2011 by + Generated on Sat Nov 26 13:16:38 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/CatAxis.html b/doc/Axlsx/CatAxis.html index 667906dd..59b286b7 100644 --- a/doc/Axlsx/CatAxis.html +++ b/doc/Axlsx/CatAxis.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::CatAxis - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -96,9 +96,8 @@ <h2>Overview</h2><div class="docstring"> <div class="discussion"> - <p> -A CatAxis object defines a chart category axis -</p> + +<p>A CatAxis object defines a chart category axis</p> </div> @@ -114,9 +113,8 @@ A CatAxis object defines a chart category axis <dt id="LBL_OFFSET_REGEX-constant" class="">LBL_OFFSET_REGEX = <div class="docstring"> <div class="discussion"> - <p> -regex for validating label offset -</p> + +<p>regex for validating label offset</p> </div> @@ -126,8 +124,7 @@ regex for validating label offset </div> </dt> - <dd><pre class="code"><span class='regexp val'>/0*(([0-9])|([1-9][0-9])|([1-9][0-9][0-9])|1000)%/</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='regexp_beg'>/</span><span class='tstring_content'>0*(([0-9])|([1-9][0-9])|([1-9][0-9][0-9])|1000)%</span><span class='regexp_end'>/</span></span></pre></dd> </dl> @@ -159,10 +156,9 @@ regex for validating label offset - <span class="summary_desc"><div class='inline'><p> -From the docs: This element specifies that this axis is a date or text axis -based on the data that is used for the axis labels, not a specific choice. -</p> + <span class="summary_desc"><div class='inline'> +<p>From the docs: This element specifies that this axis is a date or text axis +based on the data that is used for the axis labels, not a specific choice.</p> </div></span> </li> @@ -187,10 +183,9 @@ based on the data that is used for the axis labels, not a specific choice. - <span class="summary_desc"><div class='inline'><p> -specifies how the perpendicular axis is crossed must be one of [:ctr, :l, -:r]. -</p> + <span class="summary_desc"><div class='inline'> +<p>specifies how the perpendicular axis is crossed must be one of [:ctr, :l, +:r].</p> </div></span> </li> @@ -215,9 +210,8 @@ specifies how the perpendicular axis is crossed must be one of [:ctr, :l, - <span class="summary_desc"><div class='inline'><p> -The offset of the labels must be between a string between 0 and 1000. -</p> + <span class="summary_desc"><div class='inline'> +<p>The offset of the labels must be between a string between 0 and 1000.</p> </div></span> </li> @@ -262,9 +256,8 @@ The offset of the labels must be between a string between 0 and 1000. - <span class="summary_desc"><div class='inline'><p> -Creates a new CatAxis object. -</p> + <span class="summary_desc"><div class='inline'> +<p>Creates a new CatAxis object.</p> </div></span> </li> @@ -286,9 +279,8 @@ Creates a new CatAxis object. - <span class="summary_desc"><div class='inline'><p> -Serializes the category axis. -</p> + <span class="summary_desc"><div class='inline'> +<p>Serializes the category axis.</p> </div></span> </li> @@ -314,9 +306,8 @@ Serializes the category axis. </p><div class="docstring"> <div class="discussion"> - <p> -Creates a new CatAxis object -</p> + +<p>Creates a new CatAxis object</p> </div> @@ -335,9 +326,8 @@ Creates a new CatAxis object — - <div class='inline'><p> -the id of this axis. Inherited -</p> + <div class='inline'> +<p>the id of this axis. Inherited</p> </div> </li> @@ -352,9 +342,8 @@ the id of this axis. Inherited — - <div class='inline'><p> -the id of the perpendicular axis. Inherited -</p> + <div class='inline'> +<p>the id of the perpendicular axis. Inherited</p> </div> </li> @@ -371,9 +360,8 @@ the id of the perpendicular axis. Inherited — - <div class='inline'><p> -a customizable set of options -</p> + <div class='inline'> +<p>a customizable set of options</p> </div> </li> @@ -396,9 +384,8 @@ a customizable set of options <span class="default"> </span> - — <div class='inline'><p> -Inherited -</p> + — <div class='inline'> +<p>Inherited</p> </div> </li> @@ -408,9 +395,8 @@ Inherited <span class="default"> </span> - — <div class='inline'><p> -Inherited -</p> + — <div class='inline'> +<p>Inherited</p> </div> </li> @@ -420,9 +406,8 @@ Inherited <span class="default"> </span> - — <div class='inline'><p> -Inherited -</p> + — <div class='inline'> +<p>Inherited</p> </div> </li> @@ -473,13 +458,12 @@ Inherited <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/cat_axis.rb', line 31</span> -<span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span><span class='lparen token'>(</span><span class='axId identifier id'>axId</span><span class='comma token'>,</span> <span class='crossAx identifier id'>crossAx</span><span class='comma token'>,</span> <span class='options identifier id'>options</span><span class='assign token'>=</span><span class='lbrace token'>{</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='auto identifier id'>auto</span> <span class='assign token'>=</span> <span class='true true kw'>true</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='lblAlgn identifier id'>lblAlgn</span> <span class='assign token'>=</span> <span class='symbol val'>:ctr</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='lblOffset identifier id'>lblOffset</span> <span class='assign token'>=</span> <span class='string val'>"100%"</span> - <span class='super super kw'>super</span><span class='lparen token'>(</span><span class='axId identifier id'>axId</span><span class='comma token'>,</span> <span class='crossAx identifier id'>crossAx</span><span class='comma token'>,</span> <span class='options identifier id'>options</span><span class='rparen token'>)</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id initialize'>initialize</span><span class='lparen'>(</span><span class='id axId'>axId</span><span class='comma'>,</span> <span class='id crossAx'>crossAx</span><span class='comma'>,</span> <span class='id options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id auto'>auto</span> <span class='op'>=</span> <span class='kw'>true</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id lblAlgn'>lblAlgn</span> <span class='op'>=</span> <span class='symbol'>:ctr</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id lblOffset'>lblOffset</span> <span class='op'>=</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>100%</span><span class='tstring_end'>"</span></span> + <span class='kw'>super</span><span class='lparen'>(</span><span class='id axId'>axId</span><span class='comma'>,</span> <span class='id crossAx'>crossAx</span><span class='comma'>,</span> <span class='id options'>options</span><span class='rparen'>)</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -502,10 +486,9 @@ Inherited </p><div class="docstring"> <div class="discussion"> - <p> -From the docs: This element specifies that this axis is a date or text axis -based on the data that is used for the axis labels, not a specific choice. -</p> + +<p>From the docs: This element specifies that this axis is a date or text axis +based on the data that is used for the axis labels, not a specific choice.</p> </div> @@ -539,10 +522,9 @@ based on the data that is used for the axis labels, not a specific choice. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/cat_axis.rb', line 7</span> -<span class='def def kw'>def</span> <span class='auto identifier id'>auto</span> - <span class='@auto ivar id'>@auto</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id auto'>auto</span> + <span class='ivar'>@auto</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -560,10 +542,9 @@ based on the data that is used for the axis labels, not a specific choice. </p><div class="docstring"> <div class="discussion"> - <p> -specifies how the perpendicular axis is crossed must be one of [:ctr, :l, -:r] -</p> + +<p>specifies how the perpendicular axis is crossed must be one of [:ctr, :l, +:r]</p> </div> @@ -597,10 +578,9 @@ specifies how the perpendicular axis is crossed must be one of [:ctr, :l, <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/cat_axis.rb', line 12</span> -<span class='def def kw'>def</span> <span class='lblAlgn identifier id'>lblAlgn</span> - <span class='@lblAlgn ivar id'>@lblAlgn</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id lblAlgn'>lblAlgn</span> + <span class='ivar'>@lblAlgn</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -618,9 +598,8 @@ specifies how the perpendicular axis is crossed must be one of [:ctr, :l, </p><div class="docstring"> <div class="discussion"> - <p> -The offset of the labels must be between a string between 0 and 1000 -</p> + +<p>The offset of the labels must be between a string between 0 and 1000</p> </div> @@ -654,10 +633,9 @@ The offset of the labels must be between a string between 0 and 1000 <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/cat_axis.rb', line 17</span> -<span class='def def kw'>def</span> <span class='lblOffset identifier id'>lblOffset</span> - <span class='@lblOffset ivar id'>@lblOffset</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id lblOffset'>lblOffset</span> + <span class='ivar'>@lblOffset</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -679,9 +657,8 @@ The offset of the labels must be between a string between 0 and 1000 </p><div class="docstring"> <div class="discussion"> - <p> -Serializes the category axis -</p> + +<p>Serializes the category axis</p> </div> @@ -700,9 +677,8 @@ Serializes the category axis — - <div class='inline'><p> -The document builder instance this objects xml will be added to. -</p> + <div class='inline'> +<p>The document builder instance this objects xml will be added to.</p> </div> </li> @@ -729,27 +705,26 @@ The document builder instance this objects xml will be added to. <pre class="lines"> -45 -46 -47 -48 -49 -50 -51 -52</pre> +52 +53 +54 +55 +56 +57 +58 +59</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/cat_axis.rb', line 45</span> - -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:catAx'</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='super super kw'>super</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:auto'</span><span class='comma token'>,</span> <span class='symbol val'>:val=</span><span class='gt op'>></span><span class='@auto ivar id'>@auto</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:lblAlgn'</span><span class='comma token'>,</span> <span class='symbol val'>:val=</span><span class='gt op'>></span><span class='@lblAlgn ivar id'>@lblAlgn</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:lblOffset'</span><span class='comma token'>,</span> <span class='symbol val'>:val=</span><span class='gt op'>></span><span class='@lblOffset ivar id'>@lblOffset</span><span class='rparen token'>)</span> - <span class='rbrace token'>}</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/cat_axis.rb', line 52</span> + +<span class='kw'>def</span> <span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:catAx</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='kw'>super</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:auto</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:val</span><span class='op'>=></span><span class='ivar'>@auto</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:lblAlgn</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:val</span><span class='op'>=></span><span class='ivar'>@lblAlgn</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:lblOffset</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:val</span><span class='op'>=></span><span class='ivar'>@lblOffset</span><span class='rparen'>)</span> + <span class='rbrace'>}</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -760,9 +735,9 @@ The document builder instance this objects xml will be added to. </div> <div id="footer"> - Generated on Wed Nov 23 22:20:58 2011 by + Generated on Sat Nov 26 13:16:37 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/CatAxisData.html b/doc/Axlsx/CatAxisData.html index f28b881b..188310aa 100644 --- a/doc/Axlsx/CatAxisData.html +++ b/doc/Axlsx/CatAxisData.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::CatAxisData - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -96,9 +96,8 @@ <h2>Overview</h2><div class="docstring"> <div class="discussion"> - <p> -The CatAxisData class serializes the category axis data for a chart -</p> + +<p>The CatAxisData class serializes the category axis data for a chart</p> </div> @@ -153,9 +152,8 @@ The CatAxisData class serializes the category axis data for a chart - <span class="summary_desc"><div class='inline'><p> -Create a new CatAxisData object. -</p> + <span class="summary_desc"><div class='inline'> +<p>Create a new CatAxisData object.</p> </div></span> </li> @@ -177,9 +175,8 @@ Create a new CatAxisData object. - <span class="summary_desc"><div class='inline'><p> -Serializes the category axis data. -</p> + <span class="summary_desc"><div class='inline'> +<p>Serializes the category axis data.</p> </div></span> </li> @@ -193,12 +190,7 @@ Serializes the category axis data. - - - - <h3 class="inherited">Methods inherited from <span class='object_link'><a href="SimpleTypedList.html" title="Axlsx::SimpleTypedList (class)">SimpleTypedList</a></span></h3> - <p class="inherited"><span class='object_link'><a href="SimpleTypedList.html#%3C%3C-instance_method" title="Axlsx::SimpleTypedList#<< (method)">#<<</a></span>, <span class='object_link'><a href="SimpleTypedList.html#%3D%3D-instance_method" title="Axlsx::SimpleTypedList#== (method)">#==</a></span>, <span class='object_link'><a href="SimpleTypedList.html#%5B%5D%3D-instance_method" title="Axlsx::SimpleTypedList#[]= (method)">#[]=</a></span>, <span class='object_link'><a href="SimpleTypedList.html#delete-instance_method" title="Axlsx::SimpleTypedList#delete (method)">#delete</a></span>, <span class='object_link'><a href="SimpleTypedList.html#delete_at-instance_method" title="Axlsx::SimpleTypedList#delete_at (method)">#delete_at</a></span>, <span class='object_link'><a href="SimpleTypedList.html#lock-instance_method" title="Axlsx::SimpleTypedList#lock (method)">#lock</a></span>, <span class='object_link'><a href="SimpleTypedList.html#method_missing-instance_method" title="Axlsx::SimpleTypedList#method_missing (method)">#method_missing</a></span>, <span class='object_link'><a href="SimpleTypedList.html#protected%3F-instance_method" title="Axlsx::SimpleTypedList#protected? (method)">#protected?</a></span>, <span class='object_link'><a href="SimpleTypedList.html#push-instance_method" title="Axlsx::SimpleTypedList#push (method)">#push</a></span>, <span class='object_link'><a href="SimpleTypedList.html#unlock-instance_method" title="Axlsx::SimpleTypedList#unlock (method)">#unlock</a></span></p> -<div id="constructor_details" class="method_details_list"> + <div id="constructor_details" class="method_details_list"> <h2>Constructor Details</h2> <div class="method_details first"> @@ -210,9 +202,8 @@ Serializes the category axis data. </p><div class="docstring"> <div class="discussion"> - <p> -Create a new CatAxisData object -</p> + +<p>Create a new CatAxisData object</p> </div> @@ -233,10 +224,9 @@ Create a new CatAxisData object — - <div class='inline'><p> -the data for this category axis. This can be a simple array or a simple -typed list of cells. -</p> + <div class='inline'> +<p>the data for this category axis. This can be a simple array or a simple +typed list of cells.</p> </div> </li> @@ -259,12 +249,11 @@ typed list of cells. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/cat_axis_data.rb', line 7</span> -<span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span><span class='lparen token'>(</span><span class='data identifier id'>data</span><span class='assign token'>=</span><span class='lbrack token'>[</span><span class='rbrack token'>]</span><span class='rparen token'>)</span> - <span class='super super kw'>super</span> <span class='Object constant id'>Object</span> - <span class='@list ivar id'>@list</span><span class='dot token'>.</span><span class='concat identifier id'>concat</span> <span class='data identifier id'>data</span> <span class='if if_mod kw'>if</span> <span class='data identifier id'>data</span><span class='dot token'>.</span><span class='is_a? fid id'>is_a?</span><span class='lparen token'>(</span><span class='Array constant id'>Array</span><span class='rparen token'>)</span> - <span class='data identifier id'>data</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='lbrace token'>{</span> <span class='bitor op'>|</span><span class='i identifier id'>i</span><span class='bitor op'>|</span> <span class='@list ivar id'>@list</span> <span class='lshft op'><<</span> <span class='i identifier id'>i</span> <span class='rbrace token'>}</span> <span class='if if_mod kw'>if</span> <span class='data identifier id'>data</span><span class='dot token'>.</span><span class='is_a? fid id'>is_a?</span><span class='lparen token'>(</span><span class='SimpleTypedList constant id'>SimpleTypedList</span><span class='rparen token'>)</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id initialize'>initialize</span><span class='lparen'>(</span><span class='id data'>data</span><span class='op'>=</span><span class='lbracket'>[</span><span class='rbracket'>]</span><span class='rparen'>)</span> + <span class='kw'>super</span> <span class='const'>Object</span> + <span class='ivar'>@list</span><span class='period'>.</span><span class='id concat'>concat</span> <span class='id data'>data</span> <span class='kw'>if</span> <span class='id data'>data</span><span class='period'>.</span><span class='id is_a?'>is_a?</span><span class='lparen'>(</span><span class='const'>Array</span><span class='rparen'>)</span> + <span class='id data'>data</span><span class='period'>.</span><span class='id each'>each</span> <span class='lbrace'>{</span> <span class='op'>|</span><span class='id i'>i</span><span class='op'>|</span> <span class='ivar'>@list</span> <span class='op'><<</span> <span class='id i'>i</span> <span class='rbrace'>}</span> <span class='kw'>if</span> <span class='id data'>data</span><span class='period'>.</span><span class='id is_a?'>is_a?</span><span class='lparen'>(</span><span class='const'>SimpleTypedList</span><span class='rparen'>)</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -296,9 +285,8 @@ typed list of cells. </p><div class="docstring"> <div class="discussion"> - <p> -Serializes the category axis data -</p> + +<p>Serializes the category axis data</p> </div> @@ -317,9 +305,8 @@ Serializes the category axis data — - <div class='inline'><p> -The document builder instance this objects xml will be added to. -</p> + <div class='inline'> +<p>The document builder instance this objects xml will be added to.</p> </div> </li> @@ -366,23 +353,22 @@ The document builder instance this objects xml will be added to. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/cat_axis_data.rb', line 16</span> -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:cat'</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:strRef'</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:f'</span><span class='comma token'>,</span> <span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='cell_range identifier id'>cell_range</span><span class='lparen token'>(</span><span class='@list ivar id'>@list</span><span class='rparen token'>)</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:strCache'</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:ptCount'</span><span class='comma token'>,</span> <span class='symbol val'>:val=</span><span class='gt op'>></span><span class='size identifier id'>size</span><span class='rparen token'>)</span> - <span class='each_with_index identifier id'>each_with_index</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='item identifier id'>item</span><span class='comma token'>,</span> <span class='index identifier id'>index</span><span class='bitor op'>|</span> - <span class='v identifier id'>v</span> <span class='assign token'>=</span> <span class='item identifier id'>item</span><span class='dot token'>.</span><span class='is_a? fid id'>is_a?</span><span class='lparen token'>(</span><span class='Cell constant id'>Cell</span><span class='rparen token'>)</span> <span class='question op'>?</span> <span class='item identifier id'>item</span><span class='dot token'>.</span><span class='value identifier id'>value</span> <span class='colon op'>:</span> <span class='item identifier id'>item</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:pt'</span><span class='comma token'>,</span> <span class='symbol val'>:idx=</span><span class='gt op'>></span><span class='index identifier id'>index</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:v'</span><span class='comma token'>,</span> <span class='v identifier id'>v</span><span class='rparen token'>)</span> - <span class='rbrace token'>}</span> - <span class='end end kw'>end</span> - <span class='rbrace token'>}</span> - <span class='rbrace token'>}</span> - <span class='rbrace token'>}</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:cat</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:strRef</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:f</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='const'>Axlsx</span><span class='op'>::</span><span class='id cell_range'>cell_range</span><span class='lparen'>(</span><span class='ivar'>@list</span><span class='rparen'>)</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:strCache</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:ptCount</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:val</span><span class='op'>=></span><span class='id size'>size</span><span class='rparen'>)</span> + <span class='id each_with_index'>each_with_index</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id item'>item</span><span class='comma'>,</span> <span class='id index'>index</span><span class='op'>|</span> + <span class='id v'>v</span> <span class='op'>=</span> <span class='id item'>item</span><span class='period'>.</span><span class='id is_a?'>is_a?</span><span class='lparen'>(</span><span class='const'>Cell</span><span class='rparen'>)</span> <span class='op'>?</span> <span class='id item'>item</span><span class='period'>.</span><span class='id value'>value</span> <span class='op'>:</span> <span class='id item'>item</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:pt</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:idx</span><span class='op'>=></span><span class='id index'>index</span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:v</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='id v'>v</span><span class='rparen'>)</span> + <span class='rbrace'>}</span> + <span class='kw'>end</span> + <span class='rbrace'>}</span> + <span class='rbrace'>}</span> + <span class='rbrace'>}</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -393,9 +379,9 @@ The document builder instance this objects xml will be added to. </div> <div id="footer"> - Generated on Wed Nov 23 22:20:46 2011 by + Generated on Sat Nov 26 13:16:39 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/Cell.html b/doc/Axlsx/Cell.html index 3ed4c320..0873021a 100644 --- a/doc/Axlsx/Cell.html +++ b/doc/Axlsx/Cell.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::Cell - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -97,22 +97,20 @@ <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -The recommended way to generate cells is via Worksheet#add_row -</p> + <div class='inline'> +<p>The recommended way to generate cells is via Worksheet#add_row</p> </div> </div> -<p> -A cell in a worksheet. Cell stores inforamation requried to serialize a + +<p>A cell in a worksheet. Cell stores inforamation requried to serialize a single worksheet cell to xml. You must provde the Row that the cell belongs to and the cells value. The data type will automatically be determed if you do not specify the :type option. The default style will be applied if you -do not supply the :style option. Changing the cell’s type will recast -the value to the type specified. Altering the cell’s value via the -property accessor will also automatically cast the provided value to the -cell’s type. -</p> +do not supply the :style option. Changing the cell's type will recast the +value to the type specified. Altering the cell's value via the property +accessor will also automatically cast the provided value to the cell's +type.</p> </div> @@ -122,25 +120,23 @@ cell’s type. <div class="examples"> <h3>Examples:</h3> - <h4><div class='inline'><p> -Manually creating and manipulating Cell objects -</p> + <h4><div class='inline'> +<p>Manually creating and manipulating Cell objects</p> </div></h4> - <pre class="example code"><span class='ws identifier id'>ws</span> <span class='assign token'>=</span> <span class='Workbook constant id'>Workbook</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='dot token'>.</span><span class='add_worksheet identifier id'>add_worksheet</span> -<span class='comment val'># This is the simple, and recommended way to create cells. Data types will automatically be determined for you.</span> -<span class='ws identifier id'>ws</span><span class='dot token'>.</span><span class='add_row identifier id'>add_row</span> <span class='symbol val'>:values</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='lbrack token'>[</span><span class='integer val'>1</span><span class='comma token'>,</span><span class='string val'>"fish"</span><span class='comma token'>,</span><span class='Time constant id'>Time</span><span class='dot token'>.</span><span class='now identifier id'>now</span><span class='rbrack token'>]</span> + <pre class="example code"><span class='id ws'>ws</span> <span class='op'>=</span> <span class='const'>Workbook</span><span class='period'>.</span><span class='id new'>new</span><span class='period'>.</span><span class='id add_worksheet'>add_worksheet</span> +<span class='comment'># This is the simple, and recommended way to create cells. Data types will automatically be determined for you. +</span><span class='id ws'>ws</span><span class='period'>.</span><span class='id add_row'>add_row</span> <span class='symbol'>:values</span> <span class='op'>=></span> <span class='lbracket'>[</span><span class='int'>1</span><span class='comma'>,</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>fish</span><span class='tstring_end'>"</span></span><span class='comma'>,</span><span class='const'>Time</span><span class='period'>.</span><span class='id now'>now</span><span class='rbracket'>]</span> -<span class='comment val'># but you can also do this</span> -<span class='r identifier id'>r</span> <span class='assign token'>=</span> <span class='ws identifier id'>ws</span><span class='dot token'>.</span><span class='add_row identifier id'>add_row</span> -<span class='r identifier id'>r</span><span class='dot token'>.</span><span class='add_cell identifier id'>add_cell</span> <span class='integer val'>1</span> +<span class='comment'># but you can also do this +</span><span class='id r'>r</span> <span class='op'>=</span> <span class='id ws'>ws</span><span class='period'>.</span><span class='id add_row'>add_row</span> +<span class='id r'>r</span><span class='period'>.</span><span class='id add_cell'>add_cell</span> <span class='int'>1</span> -<span class='comment val'># or even this</span> -<span class='r identifier id'>r</span> <span class='assign token'>=</span> <span class='ws identifier id'>ws</span><span class='dot token'>.</span><span class='add_row identifier id'>add_row</span> -<span class='c identifier id'>c</span> <span class='assign token'>=</span> <span class='Cell constant id'>Cell</span><span class='dot token'>.</span><span class='new identifier id'>new</span> <span class='row identifier id'>row</span><span class='comma token'>,</span> <span class='integer val'>1</span><span class='comma token'>,</span> <span class='symbol val'>:value=</span><span class='gt op'>></span><span class='integer identifier id'>integer</span> +<span class='comment'># or even this +</span><span class='id r'>r</span> <span class='op'>=</span> <span class='id ws'>ws</span><span class='period'>.</span><span class='id add_row'>add_row</span> +<span class='id c'>c</span> <span class='op'>=</span> <span class='const'>Cell</span><span class='period'>.</span><span class='id new'>new</span> <span class='id row'>row</span><span class='comma'>,</span> <span class='int'>1</span><span class='comma'>,</span> <span class='symbol'>:value</span><span class='op'>=></span><span class='id integer'>integer</span> -<span class='comment val'># cells can also be accessed via Row#cells. The example here changes the cells type, which will automatically updated the value from 1 to 1.0</span> -<span class='r identifier id'>r</span><span class='dot token'>.</span><span class='cells identifier id'>cells</span><span class='dot token'>.</span><span class='last identifier id'>last</span><span class='dot token'>.</span><span class='type identifier id'>type</span> <span class='assign token'>=</span> <span class='symbol val'>:float</span> -</pre> +<span class='comment'># cells can also be accessed via Row#cells. The example here changes the cells type, which will automatically updated the value from 1 to 1.0 +</span><span class='id r'>r</span><span class='period'>.</span><span class='id cells'>cells</span><span class='period'>.</span><span class='id last'>last</span><span class='period'>.</span><span class='id type'>type</span> <span class='op'>=</span> <span class='symbol'>:float</span></pre> </div> @@ -176,9 +172,8 @@ Manually creating and manipulating Cell objects - <span class="summary_desc"><div class='inline'><p> -The row this cell belongs to. -</p> + <span class="summary_desc"><div class='inline'> +<p>The row this cell belongs to.</p> </div></span> </li> @@ -203,9 +198,8 @@ The row this cell belongs to. - <span class="summary_desc"><div class='inline'><p> -The index of the cellXfs item to be applied to this cell. -</p> + <span class="summary_desc"><div class='inline'> +<p>The index of the cellXfs item to be applied to this cell.</p> </div></span> </li> @@ -230,9 +224,8 @@ The index of the cellXfs item to be applied to this cell. - <span class="summary_desc"><div class='inline'><p> -The cell’s data type. -</p> + <span class="summary_desc"><div class='inline'> +<p>The cell's data type.</p> </div></span> </li> @@ -257,9 +250,8 @@ The cell’s data type. - <span class="summary_desc"><div class='inline'><p> -The value of this cell. -</p> + <span class="summary_desc"><div class='inline'> +<p>The value of this cell.</p> </div></span> </li> @@ -281,78 +273,6 @@ The value of this cell. <li class="public "> <span class="summary_signature"> - <a href="#cast_value-instance_method" title="#cast_value (instance method)">- (Object) <strong>cast_value</strong>(v) </a> - - - - </span> - - - - - - - - - <span class="summary_desc"><div class='inline'><p> -Cast the value into this cells data type. -</p> -</div></span> - -</li> - - - <li class="public "> - <span class="summary_signature"> - - <a href="#cell_type_from_value-instance_method" title="#cell_type_from_value (instance method)">- (Symbol) <strong>cell_type_from_value</strong>(v) </a> - - - - </span> - - - - - - - - - <span class="summary_desc"><div class='inline'><p> -Determines the cell type based on the cell value. -</p> -</div></span> - -</li> - - - <li class="public "> - <span class="summary_signature"> - - <a href="#col_ref-instance_method" title="#col_ref (instance method)">- (String) <strong>col_ref</strong> </a> - - - - </span> - - - - - - - - - <span class="summary_desc"><div class='inline'><p> -converts the column index into alphabetical values. -</p> -</div></span> - -</li> - - - <li class="public "> - <span class="summary_signature"> - <a href="#index-instance_method" title="#index (instance method)">- (Integer) <strong>index</strong> </a> @@ -366,9 +286,8 @@ converts the column index into alphabetical values. - <span class="summary_desc"><div class='inline'><p> -The index of the cell in the containing row. -</p> + <span class="summary_desc"><div class='inline'> +<p>The index of the cell in the containing row.</p> </div></span> </li> @@ -392,9 +311,8 @@ The index of the cell in the containing row. - <span class="summary_desc"><div class='inline'><p> -A new instance of Cell. -</p> + <span class="summary_desc"><div class='inline'> +<p>A new instance of Cell.</p> </div></span> </li> @@ -416,9 +334,8 @@ A new instance of Cell. - <span class="summary_desc"><div class='inline'><p> -The alpha(column)numeric(row) reference for this sell. -</p> + <span class="summary_desc"><div class='inline'> +<p>The alpha(column)numeric(row) reference for this sell.</p> </div></span> </li> @@ -440,9 +357,8 @@ The alpha(column)numeric(row) reference for this sell. - <span class="summary_desc"><div class='inline'><p> -The absolute alpha(column)numeric(row) reference for this sell. -</p> + <span class="summary_desc"><div class='inline'> +<p>The absolute alpha(column)numeric(row) reference for this sell.</p> </div></span> </li> @@ -464,9 +380,8 @@ The absolute alpha(column)numeric(row) reference for this sell. - <span class="summary_desc"><div class='inline'><p> -Serializes the cell. -</p> + <span class="summary_desc"><div class='inline'> +<p>Serializes the cell.</p> </div></span> </li> @@ -487,9 +402,8 @@ Serializes the cell. </p><div class="docstring"> <div class="discussion"> - <p> -A new instance of Cell -</p> + +<p>A new instance of Cell</p> </div> @@ -508,9 +422,8 @@ A new instance of Cell — - <div class='inline'><p> -The row this cell belongs to. -</p> + <div class='inline'> +<p>The row this cell belongs to.</p> </div> </li> @@ -527,9 +440,8 @@ The row this cell belongs to. — - <div class='inline'><p> -The value associated with this cell. -</p> + <div class='inline'> +<p>The value associated with this cell.</p> </div> </li> @@ -546,9 +458,8 @@ The value associated with this cell. — - <div class='inline'><p> -a customizable set of options -</p> + <div class='inline'> +<p>a customizable set of options</p> </div> </li> @@ -571,10 +482,9 @@ a customizable set of options <span class="default"> </span> - — <div class='inline'><p> -The intended data type for this cell. If not specified the data type will -be determined internally based on the vlue provided. -</p> + — <div class='inline'> +<p>The intended data type for this cell. If not specified the data type will +be determined internally based on the vlue provided.</p> </div> </li> @@ -584,10 +494,9 @@ be determined internally based on the vlue provided. <span class="default"> </span> - — <div class='inline'><p> -The index of the cellXfs item to be applied to this cell. If not specified, -the default style (0) will be applied. -</p> + — <div class='inline'> +<p>The index of the cellXfs item to be applied to this cell. If not specified, +the default style (0) will be applied.</p> </div> </li> @@ -601,29 +510,28 @@ the default style (0) will be applied. <pre class="lines"> -56 -57 -58 -59 -60 -61 -62 -63 -64</pre> +69 +70 +71 +72 +73 +74 +75 +76 +77</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/cell.rb', line 56</span> - -<span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span><span class='lparen token'>(</span><span class='row identifier id'>row</span><span class='comma token'>,</span> <span class='value identifier id'>value</span><span class='assign token'>=</span><span class='string val'>""</span><span class='comma token'>,</span> <span class='options identifier id'>options</span><span class='assign token'>=</span><span class='lbrace token'>{</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='row identifier id'>row</span><span class='assign token'>=</span><span class='row identifier id'>row</span> - <span class='comment val'>#reference for validation</span> - <span class='@styles ivar id'>@styles</span> <span class='assign token'>=</span> <span class='row identifier id'>row</span><span class='dot token'>.</span><span class='worksheet identifier id'>worksheet</span><span class='dot token'>.</span><span class='workbook identifier id'>workbook</span><span class='dot token'>.</span><span class='styles identifier id'>styles</span> - <span class='@type ivar id'>@type</span><span class='assign token'>=</span> <span class='options identifier id'>options</span><span class='lbrack token'>[</span><span class='symbol val'>:type</span><span class='rbrack token'>]</span> <span class='orop op'>||</span> <span class='cell_type_from_value identifier id'>cell_type_from_value</span><span class='lparen token'>(</span><span class='value identifier id'>value</span><span class='rparen token'>)</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='style identifier id'>style</span> <span class='assign token'>=</span> <span class='options identifier id'>options</span><span class='lbrack token'>[</span><span class='symbol val'>:style</span><span class='rbrack token'>]</span> <span class='orop op'>||</span> <span class='integer val'>0</span> - <span class='@value ivar id'>@value</span> <span class='assign token'>=</span> <span class='cast_value identifier id'>cast_value</span><span class='lparen token'>(</span><span class='value identifier id'>value</span><span class='rparen token'>)</span> - <span class='@row ivar id'>@row</span><span class='dot token'>.</span><span class='cells identifier id'>cells</span> <span class='lshft op'><<</span> <span class='self self kw'>self</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/cell.rb', line 69</span> + +<span class='kw'>def</span> <span class='id initialize'>initialize</span><span class='lparen'>(</span><span class='id row'>row</span><span class='comma'>,</span> <span class='id value'>value</span><span class='op'>=</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='id options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id row'>row</span><span class='op'>=</span><span class='id row'>row</span> + <span class='comment'>#reference for validation +</span> <span class='ivar'>@styles</span> <span class='op'>=</span> <span class='id row'>row</span><span class='period'>.</span><span class='id worksheet'>worksheet</span><span class='period'>.</span><span class='id workbook'>workbook</span><span class='period'>.</span><span class='id styles'>styles</span> + <span class='ivar'>@type</span><span class='op'>=</span> <span class='id options'>options</span><span class='lbracket'>[</span><span class='symbol'>:type</span><span class='rbracket'>]</span> <span class='op'>||</span> <span class='id cell_type_from_value'>cell_type_from_value</span><span class='lparen'>(</span><span class='id value'>value</span><span class='rparen'>)</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id style'>style</span> <span class='op'>=</span> <span class='id options'>options</span><span class='lbracket'>[</span><span class='symbol'>:style</span><span class='rbracket'>]</span> <span class='op'>||</span> <span class='int'>0</span> + <span class='ivar'>@value</span> <span class='op'>=</span> <span class='id cast_value'>cast_value</span><span class='lparen'>(</span><span class='id value'>value</span><span class='rparen'>)</span> + <span class='ivar'>@row</span><span class='period'>.</span><span class='id cells'>cells</span> <span class='op'><<</span> <span class='kw'>self</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -646,9 +554,8 @@ the default style (0) will be applied. </p><div class="docstring"> <div class="discussion"> - <p> -The row this cell belongs to. -</p> + +<p>The row this cell belongs to.</p> </div> @@ -675,17 +582,16 @@ The row this cell belongs to. <pre class="lines"> -32 33 -34</pre> +34 +35</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/cell.rb', line 32</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/cell.rb', line 33</span> -<span class='def def kw'>def</span> <span class='row identifier id'>row</span> - <span class='@row ivar id'>@row</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id row'>row</span> + <span class='ivar'>@row</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -703,9 +609,8 @@ The row this cell belongs to. </p><div class="docstring"> <div class="discussion"> - <p> -The index of the cellXfs item to be applied to this cell. -</p> + +<p>The index of the cellXfs item to be applied to this cell.</p> </div> @@ -739,17 +644,16 @@ The index of the cellXfs item to be applied to this cell. <pre class="lines"> -28 29 -30</pre> +30 +31</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/cell.rb', line 28</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/cell.rb', line 29</span> -<span class='def def kw'>def</span> <span class='style identifier id'>style</span> - <span class='@style ivar id'>@style</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id style'>style</span> + <span class='ivar'>@style</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -770,26 +674,22 @@ The index of the cellXfs item to be applied to this cell. <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -If the value provided cannot be cast into the type specified, type is -changed to :string and the following logic is applied. -</p> -<pre class="code"> - <span class='symbol val'>:string</span> <span class='to identifier id'>to</span> <span class='symbol val'>:integer</span> <span class='or or kw'>or</span> <span class='symbol val'>:float</span><span class='comma token'>,</span> <span class='type identifier id'>type</span> <span class='coversions identifier id'>coversions</span> <span class='always identifier id'>always</span> <span class='return return kw'>return</span> <span class='integer val'>0</span> <span class='or or kw'>or</span> <span class='integer val'>0</span><span class='integer val'>.0</span> - <span class='symbol val'>:string</span><span class='comma token'>,</span> <span class='symbol val'>:integer</span><span class='comma token'>,</span> <span class='or or kw'>or</span> <span class='symbol val'>:float</span> <span class='to identifier id'>to</span> <span class='symbol val'>:time</span> <span class='conversions identifier id'>conversions</span> <span class='always identifier id'>always</span> <span class='return return kw'>return</span> <span class='the identifier id'>the</span> <span class='original identifier id'>original</span> <span class='value identifier id'>value</span> <span class='as identifier id'>as</span> <span class='a identifier id'>a</span> <span class='string identifier id'>string</span> <span class='and and kw'>and</span> <span class='set identifier id'>set</span> <span class='the identifier id'>the</span> <span class='cells identifier id'>cells</span> <span class='type identifier id'>type</span> <span class='to identifier id'>to</span> <span class='symbol val'>:string</span><span class='dot token'>.</span> -</pre> -<p> -No support is currently implemented for parsing time strings. -</p> + <div class='inline'> +<p>If the value provided cannot be cast into the type specified, type is +changed to :string and the following logic is applied.</p> + +<pre class="code">:string to :integer or :float, type coversions always return 0 or 0.0 +:string, :integer, or :float to :time conversions always return the original value as a string and set the cells type to :string.</pre> + +<p>No support is currently implemented for parsing time strings.</p> </div> </div> -<p> -The cell’s data type. Currently only four types are supported, :time, + +<p>The cell's data type. Currently only four types are supported, :time, :float, :integer and :string. Changing the type for a cell will recast the value into that type. If no type option is specified in the constructor, -the type is automatically determed. -</p> +the type is automatically determed.</p> </div> @@ -807,9 +707,8 @@ the type is automatically determed. — - <div class='inline'><p> -The type of data this cell’s value is cast to. -</p> + <div class='inline'> +<p>The type of data this cell’s value is cast to.</p> </div> </li> @@ -826,9 +725,8 @@ The type of data this cell’s value is cast to. — - <div class='inline'><p> -Cell.type must be one of [:time, :float, :integer, :string] -</p> + <div class='inline'> +<p>Cell.type must be one of [:time, :float, :integer, :string]</p> </div> </li> @@ -855,10 +753,9 @@ Cell.type must be one of [:time, :float, :integer, :string] <td> <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/cell.rb', line 46</span> -<span class='def def kw'>def</span> <span class='type identifier id'>type</span> - <span class='@type ivar id'>@type</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id type'>type</span> + <span class='ivar'>@type</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -876,9 +773,8 @@ Cell.type must be one of [:time, :float, :integer, :string] </p><div class="docstring"> <div class="discussion"> - <p> -The value of this cell. -</p> + +<p>The value of this cell.</p> </div> @@ -896,9 +792,8 @@ The value of this cell. - <div class='inline'><p> -casted value based on cell’s type attribute. -</p> + <div class='inline'> +<p>casted value based on cell’s type attribute.</p> </div> </li> @@ -911,17 +806,16 @@ casted value based on cell’s type attribute. <pre class="lines"> -50 -51 -52</pre> +57 +58 +59</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/cell.rb', line 50</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/cell.rb', line 57</span> -<span class='def def kw'>def</span> <span class='value identifier id'>value</span> - <span class='@value ivar id'>@value</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id value'>value</span> + <span class='ivar'>@value</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -935,377 +829,7 @@ casted value based on cell’s type attribute. <div class="method_details first"> - <p class="signature first" id="cast_value-instance_method"> - - - (<tt>Object</tt>) <strong>cast_value</strong>(v) - - - -</p><div class="docstring"> - <div class="discussion"> - - <div class="note notetag"> - <strong>Note:</strong> - <div class='inline'><p> -About Time - Time in OOXML is <b>different</b> from what you might expect. -The history as to why is interesting, but you can safely assume that if you -are generating docs on a mac, you will want to specify Workbook.1904 as -true when using time typed values. -</p> -</div> - </div> - -<p> -Cast the value into this cells data type. -</p> - - - </div> -</div> -<div class="tags"> - - - <h3>See Also:</h3> - <ul class="see"> - - <li>Axlsx#date1904</li> - - </ul> - -</div><table class="source_code"> - <tr> - <td> - <pre class="lines"> - - -160 -161 -162 -163 -164 -165 -166 -167 -168 -169 -170 -171 -172 -173 -174 -175 -176 -177 -178 -179 -180 -181 -182</pre> - </td> - <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/cell.rb', line 160</span> - -<span class='def def kw'>def</span> <span class='cast_value identifier id'>cast_value</span><span class='lparen token'>(</span><span class='v identifier id'>v</span><span class='rparen token'>)</span> - <span class='if if kw'>if</span> <span class='@type ivar id'>@type</span> <span class='eq op'>==</span> <span class='symbol val'>:time</span> <span class='andop op'>&&</span> <span class='v identifier id'>v</span><span class='dot token'>.</span><span class='is_a? fid id'>is_a?</span><span class='lparen token'>(</span><span class='Time constant id'>Time</span><span class='rparen token'>)</span> - <span class='comment val'>#todo consider a time parsing method to convert strings to time</span> - <span class='epoc identifier id'>epoc</span> <span class='assign token'>=</span> <span class='Workbook constant id'>Workbook</span><span class='dot token'>.</span><span class='date1904 identifier id'>date1904</span> <span class='integer val'>? </span><span class='Time constant id'>Time</span><span class='dot token'>.</span><span class='local identifier id'>local</span><span class='lparen token'>(</span><span class='integer val'>1904</span><span class='comma token'>,</span><span class='integer val'>1</span><span class='comma token'>,</span><span class='integer val'>1</span><span class='comma token'>,</span><span class='integer val'>0</span><span class='comma token'>,</span><span class='integer val'>0</span><span class='comma token'>,</span><span class='integer val'>0</span><span class='comma token'>,</span><span class='integer val'>0</span><span class='comma token'>,</span><span class='v identifier id'>v</span><span class='dot token'>.</span><span class='zone identifier id'>zone</span><span class='rparen token'>)</span> <span class='colon op'>:</span> <span class='Time constant id'>Time</span><span class='dot token'>.</span><span class='local identifier id'>local</span><span class='lparen token'>(</span><span class='integer val'>1900</span><span class='comma token'>,</span><span class='integer val'>1</span><span class='comma token'>,</span><span class='integer val'>1</span><span class='comma token'>,</span><span class='integer val'>0</span><span class='comma token'>,</span><span class='integer val'>0</span><span class='comma token'>,</span><span class='integer val'>0</span><span class='comma token'>,</span><span class='integer val'>0</span><span class='comma token'>,</span><span class='v identifier id'>v</span><span class='dot token'>.</span><span class='zone identifier id'>zone</span><span class='rparen token'>)</span> - <span class='lparen token'>(</span><span class='lparen token'>(</span><span class='v identifier id'>v</span> <span class='minus op'>-</span> <span class='epoc identifier id'>epoc</span><span class='rparen token'>)</span> <span class='div op'>/</span><span class='float val'>60.0</span><span class='div op'>/</span><span class='float val'>60.0</span><span class='div op'>/</span><span class='float val'>24.0</span><span class='rparen token'>)</span><span class='dot token'>.</span><span class='to_f identifier id'>to_f</span> - <span class='elsif elsif kw'>elsif</span> <span class='@type ivar id'>@type</span> <span class='eq op'>==</span> <span class='symbol val'>:float</span> - <span class='v identifier id'>v</span><span class='dot token'>.</span><span class='to_f identifier id'>to_f</span> - <span class='elsif elsif kw'>elsif</span> <span class='@type ivar id'>@type</span> <span class='eq op'>==</span> <span class='symbol val'>:integer</span> - <span class='v identifier id'>v</span><span class='dot token'>.</span><span class='to_i identifier id'>to_i</span> - <span class='else else kw'>else</span> - <span class='@type ivar id'>@type</span> <span class='assign token'>=</span> <span class='symbol val'>:string</span> - <span class='v identifier id'>v</span><span class='dot token'>.</span><span class='to_s identifier id'>to_s</span> - <span class='comment val'># curious as to why this would be the cells responsibility</span> - <span class='comment val'># convert your values before passing them in wankers! CGI.unescapeHTML(v.to_s).to_xs</span> - <span class='comment val'># to revert, load this once when the gem is loaded.</span> - <span class='comment val'># unless String.method_defined? :to_xs</span> - <span class='comment val'># require 'fast_xs' #dep</span> - <span class='comment val'># class String</span> - <span class='comment val'># alias_method :to_xs, :fast_xs</span> - <span class='comment val'># end</span> - <span class='comment val'># end</span> - <span class='end end kw'>end</span> -<span class='end end kw'>end</span> -</pre> - </td> - </tr> -</table> -</div> - - <div class="method_details "> - <p class="signature " id="cell_type_from_value-instance_method"> - - - (<tt>Symbol</tt>) <strong>cell_type_from_value</strong>(v) - - - -</p><div class="docstring"> - <div class="discussion"> - - <div class="note notetag"> - <strong>Note:</strong> - <div class='inline'><p> -This is only used when a cell is created but no :type option is specified, -the following rules apply: -</p> -<ol> -<li>If the value is an instance of Time, the type is set to :time - -</li> -<li>:float and :integer types are determined by regular expression matching. - -</li> -<li>Anything that does not meet either of the above is determined to be -:string. - -</li> -</ol> -</div> - </div> - -<p> -Determines the cell type based on the cell value. -</p> - - - </div> -</div> -<div class="tags"> - -<h3>Returns:</h3> -<ul class="return"> - - <li> - - - <span class='type'>(<tt>Symbol</tt>)</span> - - - - — - <div class='inline'><p> -The determined type -</p> -</div> - - </li> - -</ul> - -</div><table class="source_code"> - <tr> - <td> - <pre class="lines"> - - -144 -145 -146 -147 -148 -149 -150 -151 -152 -153 -154</pre> - </td> - <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/cell.rb', line 144</span> - -<span class='def def kw'>def</span> <span class='cell_type_from_value identifier id'>cell_type_from_value</span><span class='lparen token'>(</span><span class='v identifier id'>v</span><span class='rparen token'>)</span> - <span class='if if kw'>if</span> <span class='v identifier id'>v</span><span class='dot token'>.</span><span class='is_a? fid id'>is_a?</span> <span class='Time constant id'>Time</span> - <span class='symbol val'>:time</span> - <span class='elsif elsif kw'>elsif</span> <span class='v identifier id'>v</span><span class='dot token'>.</span><span class='to_s identifier id'>to_s</span><span class='dot token'>.</span><span class='match identifier id'>match</span><span class='lparen token'>(</span><span class='regexp val'>/\A[+-]?\d+?\Z/</span><span class='rparen token'>)</span> <span class='comment val'>#numeric</span> - <span class='symbol val'>:integer</span> - <span class='elsif elsif kw'>elsif</span> <span class='v identifier id'>v</span><span class='dot token'>.</span><span class='to_s identifier id'>to_s</span><span class='dot token'>.</span><span class='match identifier id'>match</span><span class='lparen token'>(</span><span class='regexp val'>/\A[+-]?\d+\.\d+?\Z/</span><span class='rparen token'>)</span> <span class='comment val'>#float</span> - <span class='symbol val'>:float</span> - <span class='else else kw'>else</span> - <span class='symbol val'>:string</span> - <span class='end end kw'>end</span> -<span class='end end kw'>end</span> -</pre> - </td> - </tr> -</table> -</div> - - <div class="method_details "> - <p class="signature " id="col_ref-instance_method"> - - - (<tt>String</tt>) <strong>col_ref</strong> - - - -</p><div class="docstring"> - <div class="discussion"> - - <div class="note notetag"> - <strong>Note:</strong> - <div class='inline'><p> -This follows the standard spreadsheet convention of naming columns A to Z, -followed by AA to AZ etc. -</p> -</div> - </div> - -<p> -converts the column index into alphabetical values. -</p> - - - </div> -</div> -<div class="tags"> - -<h3>Returns:</h3> -<ul class="return"> - - <li> - - - <span class='type'>(<tt>String</tt>)</span> - - - - </li> - -</ul> - -</div><table class="source_code"> - <tr> - <td> - <pre class="lines"> - - -127 -128 -129 -130 -131 -132 -133 -134 -135 -136 -137 -138 -139 -140 -141 -142 -143 -144 -145 -146 -147 -148 -149 -150 -151 -152 -153 -154 -155 -156 -157 -158 -159 -160 -161 -162 -163 -164 -165 -166 -167 -168 -169 -170 -171 -172 -173 -174 -175 -176 -177 -178 -179 -180 -181 -182 -183</pre> - </td> - <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/cell.rb', line 127</span> - -<span class='def def kw'>def</span> <span class='col_ref identifier id'>col_ref</span> - <span class='chars identifier id'>chars</span> <span class='assign token'>=</span> <span class='lbrack token'>[</span><span class='rbrack token'>]</span> - <span class='index identifier id'>index</span> <span class='assign token'>=</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='index identifier id'>index</span> - <span class='while while kw'>while</span> <span class='index identifier id'>index</span> <span class='geq op'>>=</span> <span class='integer val'>26</span> <span class='do do kw'>do</span> - <span class='chars identifier id'>chars</span> <span class='lshft op'><<</span> <span class='lparen token'>(</span><span class='lparen token'>(</span><span class='index identifier id'>index</span> <span class='mod op'>%</span> <span class='integer val'>26</span><span class='rparen token'>)</span> <span class='plus op'>+</span> <span class='integer val'>65</span><span class='rparen token'>)</span><span class='dot token'>.</span><span class='chr identifier id'>chr</span> - <span class='index identifier id'>index</span> <span class='opasgn op'>/=</span> <span class='integer val'>26</span> - <span class='end end kw'>end</span> - <span class='chars identifier id'>chars</span> <span class='lshft op'><<</span> <span class='lparen token'>(</span><span class='lparen token'>(</span><span class='chars identifier id'>chars</span><span class='dot token'>.</span><span class='empty? fid id'>empty?</span> <span class='integer val'>? </span><span class='index identifier id'>index</span> <span class='colon op'>:</span> <span class='index identifier id'>index</span><span class='minus op'>-</span><span class='integer val'>1</span><span class='rparen token'>)</span> <span class='plus op'>+</span> <span class='integer val'>65</span><span class='rparen token'>)</span><span class='dot token'>.</span><span class='chr identifier id'>chr</span> - <span class='chars identifier id'>chars</span><span class='dot token'>.</span><span class='reverse identifier id'>reverse</span><span class='dot token'>.</span><span class='join identifier id'>join</span> - <span class='end end kw'>end</span> - - <span class='comment val'># Determines the cell type based on the cell value. </span> - <span class='comment val'># @note This is only used when a cell is created but no :type option is specified, the following rules apply:</span> - <span class='comment val'># 1. If the value is an instance of Time, the type is set to :time</span> - <span class='comment val'># 2. :float and :integer types are determined by regular expression matching.</span> - <span class='comment val'># 3. Anything that does not meet either of the above is determined to be :string.</span> - <span class='comment val'># @return [Symbol] The determined type</span> - <span class='def def kw'>def</span> <span class='cell_type_from_value identifier id'>cell_type_from_value</span><span class='lparen token'>(</span><span class='v identifier id'>v</span><span class='rparen token'>)</span> - <span class='if if kw'>if</span> <span class='v identifier id'>v</span><span class='dot token'>.</span><span class='is_a? fid id'>is_a?</span> <span class='Time constant id'>Time</span> - <span class='symbol val'>:time</span> - <span class='elsif elsif kw'>elsif</span> <span class='v identifier id'>v</span><span class='dot token'>.</span><span class='to_s identifier id'>to_s</span><span class='dot token'>.</span><span class='match identifier id'>match</span><span class='lparen token'>(</span><span class='regexp val'>/\A[+-]?\d+?\Z/</span><span class='rparen token'>)</span> <span class='comment val'>#numeric</span> - <span class='symbol val'>:integer</span> - <span class='elsif elsif kw'>elsif</span> <span class='v identifier id'>v</span><span class='dot token'>.</span><span class='to_s identifier id'>to_s</span><span class='dot token'>.</span><span class='match identifier id'>match</span><span class='lparen token'>(</span><span class='regexp val'>/\A[+-]?\d+\.\d+?\Z/</span><span class='rparen token'>)</span> <span class='comment val'>#float</span> - <span class='symbol val'>:float</span> - <span class='else else kw'>else</span> - <span class='symbol val'>:string</span> - <span class='end end kw'>end</span> - <span class='end end kw'>end</span> - - <span class='comment val'># Cast the value into this cells data type. </span> - <span class='comment val'># @note </span> - <span class='comment val'># About Time - Time in OOXML is *different* from what you might expect. The history as to why is interesting, but you can safely assume that if you are generating docs on a mac, you will want to specify Workbook.1904 as true when using time typed values.</span> - <span class='comment val'># @see Axlsx#date1904</span> - <span class='def def kw'>def</span> <span class='cast_value identifier id'>cast_value</span><span class='lparen token'>(</span><span class='v identifier id'>v</span><span class='rparen token'>)</span> - <span class='if if kw'>if</span> <span class='@type ivar id'>@type</span> <span class='eq op'>==</span> <span class='symbol val'>:time</span> <span class='andop op'>&&</span> <span class='v identifier id'>v</span><span class='dot token'>.</span><span class='is_a? fid id'>is_a?</span><span class='lparen token'>(</span><span class='Time constant id'>Time</span><span class='rparen token'>)</span> - <span class='comment val'>#todo consider a time parsing method to convert strings to time</span> - <span class='epoc identifier id'>epoc</span> <span class='assign token'>=</span> <span class='Workbook constant id'>Workbook</span><span class='dot token'>.</span><span class='date1904 identifier id'>date1904</span> <span class='integer val'>? </span><span class='Time constant id'>Time</span><span class='dot token'>.</span><span class='local identifier id'>local</span><span class='lparen token'>(</span><span class='integer val'>1904</span><span class='comma token'>,</span><span class='integer val'>1</span><span class='comma token'>,</span><span class='integer val'>1</span><span class='comma token'>,</span><span class='integer val'>0</span><span class='comma token'>,</span><span class='integer val'>0</span><span class='comma token'>,</span><span class='integer val'>0</span><span class='comma token'>,</span><span class='integer val'>0</span><span class='comma token'>,</span><span class='v identifier id'>v</span><span class='dot token'>.</span><span class='zone identifier id'>zone</span><span class='rparen token'>)</span> <span class='colon op'>:</span> <span class='Time constant id'>Time</span><span class='dot token'>.</span><span class='local identifier id'>local</span><span class='lparen token'>(</span><span class='integer val'>1900</span><span class='comma token'>,</span><span class='integer val'>1</span><span class='comma token'>,</span><span class='integer val'>1</span><span class='comma token'>,</span><span class='integer val'>0</span><span class='comma token'>,</span><span class='integer val'>0</span><span class='comma token'>,</span><span class='integer val'>0</span><span class='comma token'>,</span><span class='integer val'>0</span><span class='comma token'>,</span><span class='v identifier id'>v</span><span class='dot token'>.</span><span class='zone identifier id'>zone</span><span class='rparen token'>)</span> - <span class='lparen token'>(</span><span class='lparen token'>(</span><span class='v identifier id'>v</span> <span class='minus op'>-</span> <span class='epoc identifier id'>epoc</span><span class='rparen token'>)</span> <span class='div op'>/</span><span class='float val'>60.0</span><span class='div op'>/</span><span class='float val'>60.0</span><span class='div op'>/</span><span class='float val'>24.0</span><span class='rparen token'>)</span><span class='dot token'>.</span><span class='to_f identifier id'>to_f</span> - <span class='elsif elsif kw'>elsif</span> <span class='@type ivar id'>@type</span> <span class='eq op'>==</span> <span class='symbol val'>:float</span> - <span class='v identifier id'>v</span><span class='dot token'>.</span><span class='to_f identifier id'>to_f</span> - <span class='elsif elsif kw'>elsif</span> <span class='@type ivar id'>@type</span> <span class='eq op'>==</span> <span class='symbol val'>:integer</span> - <span class='v identifier id'>v</span><span class='dot token'>.</span><span class='to_i identifier id'>to_i</span> - <span class='else else kw'>else</span> - <span class='@type ivar id'>@type</span> <span class='assign token'>=</span> <span class='symbol val'>:string</span> - <span class='v identifier id'>v</span><span class='dot token'>.</span><span class='to_s identifier id'>to_s</span> - <span class='comment val'># curious as to why this would be the cells responsibility</span> - <span class='comment val'># convert your values before passing them in wankers! CGI.unescapeHTML(v.to_s).to_xs</span> - <span class='comment val'># to revert, load this once when the gem is loaded.</span> - <span class='comment val'># unless String.method_defined? :to_xs</span> - <span class='comment val'># require 'fast_xs' #dep</span> - <span class='comment val'># class String</span> - <span class='comment val'># alias_method :to_xs, :fast_xs</span> - <span class='comment val'># end</span> - <span class='comment val'># end</span> - <span class='end end kw'>end</span> - <span class='end end kw'>end</span> -<span class='end end kw'>end</span> -</pre> - </td> - </tr> -</table> -</div> - - <div class="method_details "> - <p class="signature " id="index-instance_method"> + <p class="signature first" id="index-instance_method"> - (<tt>Integer</tt>) <strong>index</strong> @@ -1313,9 +837,8 @@ converts the column index into alphabetical values. </p><div class="docstring"> <div class="discussion"> - <p> -The index of the cell in the containing row. -</p> + +<p>The index of the cell in the containing row.</p> </div> @@ -1333,9 +856,8 @@ The index of the cell in the containing row. — - <div class='inline'><p> -The index of the cell in the containing row. -</p> + <div class='inline'> +<p>The index of the cell in the containing row.</p> </div> </li> @@ -1348,17 +870,16 @@ The index of the cell in the containing row. <pre class="lines"> -67 -68 -69</pre> +80 +81 +82</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/cell.rb', line 67</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/cell.rb', line 80</span> -<span class='def def kw'>def</span> <span class='index identifier id'>index</span> - <span class='@row ivar id'>@row</span><span class='dot token'>.</span><span class='cells identifier id'>cells</span><span class='dot token'>.</span><span class='index identifier id'>index</span><span class='lparen token'>(</span><span class='self self kw'>self</span><span class='rparen token'>)</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id index'>index</span> + <span class='ivar'>@row</span><span class='period'>.</span><span class='id cells'>cells</span><span class='period'>.</span><span class='id index'>index</span><span class='lparen'>(</span><span class='kw'>self</span><span class='rparen'>)</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1373,9 +894,8 @@ The index of the cell in the containing row. </p><div class="docstring"> <div class="discussion"> - <p> -The alpha(column)numeric(row) reference for this sell. -</p> + +<p>The alpha(column)numeric(row) reference for this sell.</p> </div> @@ -1385,12 +905,10 @@ The alpha(column)numeric(row) reference for this sell. <div class="examples"> <h3>Examples:</h3> - <h4><div class='inline'><p> -Relative Cell Reference -</p> + <h4><div class='inline'> +<p>Relative Cell Reference</p> </div></h4> - <pre class="example code"><span class='ws identifier id'>ws</span><span class='dot token'>.</span><span class='rows identifier id'>rows</span><span class='dot token'>.</span><span class='first identifier id'>first</span><span class='dot token'>.</span><span class='cells identifier id'>cells</span><span class='dot token'>.</span><span class='first identifier id'>first</span><span class='dot token'>.</span><span class='r identifier id'>r</span> <span class='comment val'>#=> "A1" </span> -</pre> + <pre class="example code"><span class='id ws'>ws</span><span class='period'>.</span><span class='id rows'>rows</span><span class='period'>.</span><span class='id first'>first</span><span class='period'>.</span><span class='id cells'>cells</span><span class='period'>.</span><span class='id first'>first</span><span class='period'>.</span><span class='id r'>r</span> <span class='comment'>#=> "A1" </span></pre> </div> @@ -1405,9 +923,8 @@ Relative Cell Reference — - <div class='inline'><p> -The alpha(column)numeric(row) reference for this sell. -</p> + <div class='inline'> +<p>The alpha(column)numeric(row) reference for this sell.</p> </div> </li> @@ -1420,17 +937,16 @@ The alpha(column)numeric(row) reference for this sell. <pre class="lines"> -74 -75 -76</pre> +87 +88 +89</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/cell.rb', line 74</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/cell.rb', line 87</span> -<span class='def def kw'>def</span> <span class='r identifier id'>r</span> - <span class='dstring node'>"#{col_ref}#{@row.index+1}"</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id r'>r</span> + <span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='id col_ref'>col_ref</span><span class='rbrace'>}</span><span class='embexpr_beg'>#{</span><span class='ivar'>@row</span><span class='period'>.</span><span class='id index'>index</span><span class='op'>+</span><span class='int'>1</span><span class='rbrace'>}</span><span class='tstring_end'>"</span></span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1445,9 +961,8 @@ The alpha(column)numeric(row) reference for this sell. </p><div class="docstring"> <div class="discussion"> - <p> -The absolute alpha(column)numeric(row) reference for this sell. -</p> + +<p>The absolute alpha(column)numeric(row) reference for this sell.</p> </div> @@ -1457,12 +972,10 @@ The absolute alpha(column)numeric(row) reference for this sell. <div class="examples"> <h3>Examples:</h3> - <h4><div class='inline'><p> -Absolute Cell Reference -</p> + <h4><div class='inline'> +<p>Absolute Cell Reference</p> </div></h4> - <pre class="example code"><span class='ws identifier id'>ws</span><span class='dot token'>.</span><span class='rows identifier id'>rows</span><span class='dot token'>.</span><span class='first identifier id'>first</span><span class='dot token'>.</span><span class='cells identifier id'>cells</span><span class='dot token'>.</span><span class='first identifier id'>first</span><span class='dot token'>.</span><span class='r identifier id'>r</span> <span class='comment val'>#=> "$A$1" </span> -</pre> + <pre class="example code"><span class='id ws'>ws</span><span class='period'>.</span><span class='id rows'>rows</span><span class='period'>.</span><span class='id first'>first</span><span class='period'>.</span><span class='id cells'>cells</span><span class='period'>.</span><span class='id first'>first</span><span class='period'>.</span><span class='id r'>r</span> <span class='comment'>#=> "$A$1" </span></pre> </div> @@ -1477,9 +990,8 @@ Absolute Cell Reference — - <div class='inline'><p> -The absolute alpha(column)numeric(row) reference for this sell. -</p> + <div class='inline'> +<p>The absolute alpha(column)numeric(row) reference for this sell.</p> </div> </li> @@ -1492,17 +1004,16 @@ The absolute alpha(column)numeric(row) reference for this sell. <pre class="lines"> -81 -82 -83</pre> +94 +95 +96</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/cell.rb', line 81</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/cell.rb', line 94</span> -<span class='def def kw'>def</span> <span class='r_abs identifier id'>r_abs</span> - <span class='dstring node'>"$#{r.split('').join('$')}"</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id r_abs'>r_abs</span> + <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>$</span><span class='embexpr_beg'>#{</span><span class='id r'>r</span><span class='period'>.</span><span class='id split'>split</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span><span class='period'>.</span><span class='id join'>join</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>$</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span><span class='rbrace'>}</span><span class='tstring_end'>"</span></span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1520,16 +1031,14 @@ The absolute alpha(column)numeric(row) reference for this sell. <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -Shared Strings are not used in this library. All values are set directly in -the each sheet. -</p> + <div class='inline'> +<p>Shared Strings are not used in this library. All values are set directly in +the each sheet.</p> </div> </div> -<p> -Serializes the cell -</p> + +<p>Serializes the cell</p> </div> @@ -1548,9 +1057,8 @@ Serializes the cell — - <div class='inline'><p> -The document builder instance this objects xml will be added to. -</p> + <div class='inline'> +<p>The document builder instance this objects xml will be added to.</p> </div> </li> @@ -1568,9 +1076,8 @@ The document builder instance this objects xml will be added to. — - <div class='inline'><p> -xml text for the cell -</p> + <div class='inline'> +<p>xml text for the cell</p> </div> </li> @@ -1583,27 +1090,34 @@ xml text for the cell <pre class="lines"> -110 -111 -112 -113 114 115 116 -117</pre> +117 +118 +119 +120 +121 +122 +123 +124 +125</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/cell.rb', line 110</span> - -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='if if kw'>if</span> <span class='@type ivar id'>@type</span> <span class='eq op'>==</span> <span class='symbol val'>:string</span> - <span class='comment val'>#NOTE not sure why, but xml.t @v renders the text as html entities of unicode data</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='c identifier id'>c</span><span class='lparen token'>(</span><span class='symbol val'>:r</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='r identifier id'>r</span><span class='comma token'>,</span> <span class='symbol val'>:t=</span><span class='gt op'>></span><span class='symbol val'>:inlineStr</span><span class='comma token'>,</span> <span class='symbol val'>:s=</span><span class='gt op'>></span><span class='style identifier id'>style</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='is identifier id'>is</span> <span class='lbrace token'>{</span> <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='t identifier id'>t</span> <span class='value identifier id'>value</span><span class='dot token'>.</span><span class='to_s identifier id'>to_s</span> <span class='rbrace token'>}</span> <span class='rbrace token'>}</span> - <span class='else else kw'>else</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='c identifier id'>c</span><span class='lparen token'>(</span><span class='symbol val'>:r</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='r identifier id'>r</span><span class='comma token'>,</span> <span class='symbol val'>:s</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='style identifier id'>style</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='v identifier id'>v</span> <span class='value identifier id'>value</span> <span class='rbrace token'>}</span> - <span class='end end kw'>end</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/cell.rb', line 114</span> + +<span class='kw'>def</span> <span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> + <span class='comment'># Both 1.8 and 1.9 return the same 'fast_xf' +</span> <span class='comment'># &#12491;&#12507;&#12531;&#12468; +</span> <span class='comment'># &#12491;&#12507;&#12531;&#12468; +</span> + <span class='comment'># however nokogiri does a nice 'force_encoding' which we shall remove! +</span> <span class='kw'>if</span> <span class='ivar'>@type</span> <span class='op'>==</span> <span class='symbol'>:string</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id c'>c</span><span class='lparen'>(</span><span class='symbol'>:r</span> <span class='op'>=></span> <span class='id r'>r</span><span class='comma'>,</span> <span class='symbol'>:t</span><span class='op'>=></span><span class='symbol'>:inlineStr</span><span class='comma'>,</span> <span class='symbol'>:s</span><span class='op'>=></span><span class='id style'>style</span><span class='rparen'>)</span> <span class='lbrace'>{</span> <span class='id xml'>xml</span><span class='period'>.</span><span class='id is'>is</span> <span class='lbrace'>{</span> <span class='id xml'>xml</span><span class='period'>.</span><span class='id t'>t</span> <span class='ivar'>@value</span><span class='period'>.</span><span class='id to_s'>to_s</span> <span class='rbrace'>}</span> <span class='rbrace'>}</span> + <span class='kw'>else</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id c'>c</span><span class='lparen'>(</span><span class='symbol'>:r</span> <span class='op'>=></span> <span class='id r'>r</span><span class='comma'>,</span> <span class='symbol'>:s</span> <span class='op'>=></span> <span class='id style'>style</span><span class='rparen'>)</span> <span class='lbrace'>{</span> <span class='id xml'>xml</span><span class='period'>.</span><span class='id v'>v</span> <span class='id value'>value</span> <span class='rbrace'>}</span> + <span class='kw'>end</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1614,9 +1128,9 @@ xml text for the cell </div> <div id="footer"> - Generated on Wed Nov 23 22:21:00 2011 by + Generated on Sat Nov 26 13:16:39 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/CellAlignment.html b/doc/Axlsx/CellAlignment.html index 851be85e..a1c73464 100644 --- a/doc/Axlsx/CellAlignment.html +++ b/doc/Axlsx/CellAlignment.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::CellAlignment - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -97,16 +97,14 @@ <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -Using Styles#add_style is the recommended way to manage cell alignment. -</p> + <div class='inline'> +<p>Using Styles#add_style is the recommended way to manage cell alignment.</p> </div> </div> -<p> -CellAlignment stores information about the cell alignment of a style Xf -Object. -</p> + +<p>CellAlignment stores information about the cell alignment of a style Xf +Object.</p> </div> @@ -145,9 +143,8 @@ Object. - <span class="summary_desc"><div class='inline'><p> -The horizontal alignment of the cell. -</p> + <span class="summary_desc"><div class='inline'> +<p>The horizontal alignment of the cell.</p> </div></span> </li> @@ -172,9 +169,8 @@ The horizontal alignment of the cell. - <span class="summary_desc"><div class='inline'><p> -The amount of indent. -</p> + <span class="summary_desc"><div class='inline'> +<p>The amount of indent.</p> </div></span> </li> @@ -199,9 +195,8 @@ The amount of indent. - <span class="summary_desc"><div class='inline'><p> -Indicate if the last line should be justified. -</p> + <span class="summary_desc"><div class='inline'> +<p>Indicate if the last line should be justified.</p> </div></span> </li> @@ -226,10 +221,9 @@ Indicate if the last line should be justified. - <span class="summary_desc"><div class='inline'><p> -The reading order of the text 0 Context Dependent 1 Left-to-Right 2 -Right-to-Left. -</p> + <span class="summary_desc"><div class='inline'> +<p>The reading order of the text 0 Context Dependent 1 Left-to-Right 2 +Right-to-Left.</p> </div></span> </li> @@ -254,9 +248,8 @@ Right-to-Left. - <span class="summary_desc"><div class='inline'><p> -The amount of relativeIndent. -</p> + <span class="summary_desc"><div class='inline'> +<p>The amount of relativeIndent.</p> </div></span> </li> @@ -281,9 +274,8 @@ The amount of relativeIndent. - <span class="summary_desc"><div class='inline'><p> -Indicate if the text should be shrunk to the fit in the cell. -</p> + <span class="summary_desc"><div class='inline'> +<p>Indicate if the text should be shrunk to the fit in the cell.</p> </div></span> </li> @@ -308,9 +300,8 @@ Indicate if the text should be shrunk to the fit in the cell. - <span class="summary_desc"><div class='inline'><p> -The textRotation of the cell. -</p> + <span class="summary_desc"><div class='inline'> +<p>The textRotation of the cell.</p> </div></span> </li> @@ -335,9 +326,8 @@ The textRotation of the cell. - <span class="summary_desc"><div class='inline'><p> -The vertical alignment of the cell. -</p> + <span class="summary_desc"><div class='inline'> +<p>The vertical alignment of the cell.</p> </div></span> </li> @@ -362,9 +352,8 @@ The vertical alignment of the cell. - <span class="summary_desc"><div class='inline'><p> -Indicate if the text of the cell should wrap. -</p> + <span class="summary_desc"><div class='inline'> +<p>Indicate if the text of the cell should wrap.</p> </div></span> </li> @@ -401,9 +390,8 @@ Indicate if the text of the cell should wrap. - <span class="summary_desc"><div class='inline'><p> -Create a new cell_alignment object. -</p> + <span class="summary_desc"><div class='inline'> +<p>Create a new cell_alignment object.</p> </div></span> </li> @@ -425,9 +413,8 @@ Create a new cell_alignment object. - <span class="summary_desc"><div class='inline'><p> -Serializes the cell alignment. -</p> + <span class="summary_desc"><div class='inline'> +<p>Serializes the cell alignment.</p> </div></span> </li> @@ -448,9 +435,8 @@ Serializes the cell alignment. </p><div class="docstring"> <div class="discussion"> - <p> -Create a new cell_alignment object -</p> + +<p>Create a new cell_alignment object</p> </div> @@ -471,9 +457,8 @@ Create a new cell_alignment object — - <div class='inline'><p> -a customizable set of options -</p> + <div class='inline'> +<p>a customizable set of options</p> </div> </li> @@ -586,12 +571,11 @@ a customizable set of options <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/cell_alignment.rb', line 72</span> -<span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span><span class='lparen token'>(</span><span class='options identifier id'>options</span><span class='assign token'>=</span><span class='lbrace token'>{</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> - <span class='options identifier id'>options</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='o identifier id'>o</span><span class='bitor op'>|</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='dstring node'>"#{o[0]}="</span><span class='comma token'>,</span> <span class='o identifier id'>o</span><span class='lbrack token'>[</span><span class='integer val'>1</span><span class='rbrack token'>]</span><span class='rparen token'>)</span> <span class='if if_mod kw'>if</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='respond_to? fid id'>respond_to?</span> <span class='dstring node'>"#{o[0]}="</span> - <span class='end end kw'>end</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id initialize'>initialize</span><span class='lparen'>(</span><span class='id options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span> + <span class='id options'>options</span><span class='period'>.</span><span class='id each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id o'>o</span><span class='op'>|</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span><span class='rbrace'>}</span><span class='tstring_content'>=</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>1</span><span class='rbracket'>]</span><span class='rparen'>)</span> <span class='kw'>if</span> <span class='kw'>self</span><span class='period'>.</span><span class='id respond_to?'>respond_to?</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span><span class='rbrace'>}</span><span class='tstring_content'>=</span><span class='tstring_end'>"</span></span> + <span class='kw'>end</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -617,25 +601,22 @@ a customizable set of options <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -The horizontal cell alignement style must be one of -</p> -<pre class="code"> - <span class='symbol val'>:general</span> - <span class='symbol val'>:left</span> - <span class='symbol val'>:center</span> - <span class='symbol val'>:right</span> - <span class='symbol val'>:fill</span> - <span class='symbol val'>:justify</span> - <span class='symbol val'>:centerContinuous</span> - <span class='symbol val'>:distributed</span> -</pre> + <div class='inline'> +<p>The horizontal cell alignement style must be one of</p> + +<pre class="code"><span class='symbol'>:general</span> +<span class='symbol'>:left</span> +<span class='symbol'>:center</span> +<span class='symbol'>:right</span> +<span class='symbol'>:fill</span> +<span class='symbol'>:justify</span> +<span class='symbol'>:centerContinuous</span> +<span class='symbol'>:distributed</span></pre> </div> </div> -<p> -The horizontal alignment of the cell. -</p> + +<p>The horizontal alignment of the cell.</p> </div> @@ -669,10 +650,9 @@ The horizontal alignment of the cell. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/cell_alignment.rb', line 18</span> -<span class='def def kw'>def</span> <span class='horizontal identifier id'>horizontal</span> - <span class='@horizontal ivar id'>@horizontal</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id horizontal'>horizontal</span> + <span class='ivar'>@horizontal</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -690,9 +670,8 @@ The horizontal alignment of the cell. </p><div class="docstring"> <div class="discussion"> - <p> -The amount of indent -</p> + +<p>The amount of indent</p> </div> @@ -726,10 +705,9 @@ The amount of indent <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/cell_alignment.rb', line 41</span> -<span class='def def kw'>def</span> <span class='indent identifier id'>indent</span> - <span class='@indent ivar id'>@indent</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id indent'>indent</span> + <span class='ivar'>@indent</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -747,9 +725,8 @@ The amount of indent </p><div class="docstring"> <div class="discussion"> - <p> -Indicate if the last line should be justified. -</p> + +<p>Indicate if the last line should be justified.</p> </div> @@ -783,10 +760,9 @@ Indicate if the last line should be justified. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/cell_alignment.rb', line 49</span> -<span class='def def kw'>def</span> <span class='justifyLastLine identifier id'>justifyLastLine</span> - <span class='@justifyLastLine ivar id'>@justifyLastLine</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id justifyLastLine'>justifyLastLine</span> + <span class='ivar'>@justifyLastLine</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -804,10 +780,9 @@ Indicate if the last line should be justified. </p><div class="docstring"> <div class="discussion"> - <p> -The reading order of the text 0 Context Dependent 1 Left-to-Right 2 -Right-to-Left -</p> + +<p>The reading order of the text 0 Context Dependent 1 Left-to-Right 2 +Right-to-Left</p> </div> @@ -841,10 +816,9 @@ Right-to-Left <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/cell_alignment.rb', line 60</span> -<span class='def def kw'>def</span> <span class='readingOrder identifier id'>readingOrder</span> - <span class='@readingOrder ivar id'>@readingOrder</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id readingOrder'>readingOrder</span> + <span class='ivar'>@readingOrder</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -862,9 +836,8 @@ Right-to-Left </p><div class="docstring"> <div class="discussion"> - <p> -The amount of relativeIndent -</p> + +<p>The amount of relativeIndent</p> </div> @@ -898,10 +871,9 @@ The amount of relativeIndent <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/cell_alignment.rb', line 45</span> -<span class='def def kw'>def</span> <span class='relativeIndent identifier id'>relativeIndent</span> - <span class='@relativeIndent ivar id'>@relativeIndent</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id relativeIndent'>relativeIndent</span> + <span class='ivar'>@relativeIndent</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -919,9 +891,8 @@ The amount of relativeIndent </p><div class="docstring"> <div class="discussion"> - <p> -Indicate if the text should be shrunk to the fit in the cell. -</p> + +<p>Indicate if the text should be shrunk to the fit in the cell.</p> </div> @@ -955,10 +926,9 @@ Indicate if the text should be shrunk to the fit in the cell. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/cell_alignment.rb', line 53</span> -<span class='def def kw'>def</span> <span class='shrinkToFit identifier id'>shrinkToFit</span> - <span class='@shrinkToFit ivar id'>@shrinkToFit</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id shrinkToFit'>shrinkToFit</span> + <span class='ivar'>@shrinkToFit</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -976,9 +946,8 @@ Indicate if the text should be shrunk to the fit in the cell. </p><div class="docstring"> <div class="discussion"> - <p> -The textRotation of the cell. -</p> + +<p>The textRotation of the cell.</p> </div> @@ -1012,10 +981,9 @@ The textRotation of the cell. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/cell_alignment.rb', line 33</span> -<span class='def def kw'>def</span> <span class='textRotation identifier id'>textRotation</span> - <span class='@textRotation ivar id'>@textRotation</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id textRotation'>textRotation</span> + <span class='ivar'>@textRotation</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1036,22 +1004,19 @@ The textRotation of the cell. <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -The vertical cell allingment style must be one of the following: -</p> -<pre class="code"> - <span class='symbol val'>:top</span> - <span class='symbol val'>:center</span> - <span class='symbol val'>:bottom</span> - <span class='symbol val'>:justify</span> - <span class='symbol val'>:distributed</span> -</pre> + <div class='inline'> +<p>The vertical cell allingment style must be one of the following:</p> + +<pre class="code"><span class='symbol'>:top</span> +<span class='symbol'>:center</span> +<span class='symbol'>:bottom</span> +<span class='symbol'>:justify</span> +<span class='symbol'>:distributed</span></pre> </div> </div> -<p> -The vertical alignment of the cell. -</p> + +<p>The vertical alignment of the cell.</p> </div> @@ -1085,10 +1050,9 @@ The vertical alignment of the cell. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/cell_alignment.rb', line 29</span> -<span class='def def kw'>def</span> <span class='vertical identifier id'>vertical</span> - <span class='@vertical ivar id'>@vertical</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id vertical'>vertical</span> + <span class='ivar'>@vertical</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1106,9 +1070,8 @@ The vertical alignment of the cell. </p><div class="docstring"> <div class="discussion"> - <p> -Indicate if the text of the cell should wrap -</p> + +<p>Indicate if the text of the cell should wrap</p> </div> @@ -1142,10 +1105,9 @@ Indicate if the text of the cell should wrap <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/cell_alignment.rb', line 37</span> -<span class='def def kw'>def</span> <span class='wrapText identifier id'>wrapText</span> - <span class='@wrapText ivar id'>@wrapText</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id wrapText'>wrapText</span> + <span class='ivar'>@wrapText</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1167,9 +1129,8 @@ Indicate if the text of the cell should wrap </p><div class="docstring"> <div class="discussion"> - <p> -Serializes the cell alignment -</p> + +<p>Serializes the cell alignment</p> </div> @@ -1188,9 +1149,8 @@ Serializes the cell alignment — - <div class='inline'><p> -The document builder instance this objects xml will be added to. -</p> + <div class='inline'> +<p>The document builder instance this objects xml will be added to.</p> </div> </li> @@ -1217,17 +1177,16 @@ The document builder instance this objects xml will be added to. <pre class="lines"> -91 -92 -93</pre> +100 +101 +102</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/cell_alignment.rb', line 91</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/cell_alignment.rb', line 100</span> -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='alignment identifier id'>alignment</span><span class='lparen token'>(</span><span class='self self kw'>self</span><span class='dot token'>.</span><span class='instance_values identifier id'>instance_values</span><span class='rparen token'>)</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id alignment'>alignment</span><span class='lparen'>(</span><span class='kw'>self</span><span class='period'>.</span><span class='id instance_values'>instance_values</span><span class='rparen'>)</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1238,9 +1197,9 @@ The document builder instance this objects xml will be added to. </div> <div id="footer"> - Generated on Wed Nov 23 22:20:57 2011 by + Generated on Sat Nov 26 13:16:39 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/CellProtection.html b/doc/Axlsx/CellProtection.html index 089ca4b4..a62fe369 100644 --- a/doc/Axlsx/CellProtection.html +++ b/doc/Axlsx/CellProtection.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::CellProtection - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -97,16 +97,14 @@ <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -Using Styles#add_style is the recommended way to manage cell protection. -</p> + <div class='inline'> +<p>Using Styles#add_style is the recommended way to manage cell protection.</p> </div> </div> -<p> -CellProtection stores information about locking or hiding cells in -spreadsheet. -</p> + +<p>CellProtection stores information about locking or hiding cells in +spreadsheet.</p> </div> @@ -145,9 +143,8 @@ spreadsheet. - <span class="summary_desc"><div class='inline'><p> -specifies locking for cells that have the style containing this protection. -</p> + <span class="summary_desc"><div class='inline'> +<p>specifies locking for cells that have the style containing this protection.</p> </div></span> </li> @@ -172,9 +169,8 @@ specifies locking for cells that have the style containing this protection. - <span class="summary_desc"><div class='inline'><p> -specifies if the cells that have the style containing this protection. -</p> + <span class="summary_desc"><div class='inline'> +<p>specifies if the cells that have the style containing this protection.</p> </div></span> </li> @@ -211,9 +207,8 @@ specifies if the cells that have the style containing this protection. - <span class="summary_desc"><div class='inline'><p> -Creates a new CellProtection. -</p> + <span class="summary_desc"><div class='inline'> +<p>Creates a new CellProtection.</p> </div></span> </li> @@ -235,9 +230,8 @@ Creates a new CellProtection. - <span class="summary_desc"><div class='inline'><p> -Serializes the cell protection. -</p> + <span class="summary_desc"><div class='inline'> +<p>Serializes the cell protection.</p> </div></span> </li> @@ -258,9 +252,8 @@ Serializes the cell protection. </p><div class="docstring"> <div class="discussion"> - <p> -Creates a new CellProtection -</p> + +<p>Creates a new CellProtection</p> </div> @@ -281,9 +274,8 @@ Creates a new CellProtection — - <div class='inline'><p> -a customizable set of options -</p> + <div class='inline'> +<p>a customizable set of options</p> </div> </li> @@ -302,9 +294,8 @@ a customizable set of options <span class="default"> </span> - — <div class='inline'><p> -value for hidden protection -</p> + — <div class='inline'> +<p>value for hidden protection</p> </div> </li> @@ -314,9 +305,8 @@ value for hidden protection <span class="default"> </span> - — <div class='inline'><p> -value for locked protection -</p> + — <div class='inline'> +<p>value for locked protection</p> </div> </li> @@ -339,12 +329,11 @@ value for locked protection <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/cell_protection.rb', line 18</span> -<span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span><span class='lparen token'>(</span><span class='options identifier id'>options</span><span class='assign token'>=</span><span class='lbrace token'>{</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> - <span class='options identifier id'>options</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='o identifier id'>o</span><span class='bitor op'>|</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='dstring node'>"#{o[0]}="</span><span class='comma token'>,</span> <span class='o identifier id'>o</span><span class='lbrack token'>[</span><span class='integer val'>1</span><span class='rbrack token'>]</span><span class='rparen token'>)</span> <span class='if if_mod kw'>if</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='respond_to? fid id'>respond_to?</span> <span class='dstring node'>"#{o[0]}="</span> - <span class='end end kw'>end</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id initialize'>initialize</span><span class='lparen'>(</span><span class='id options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span> + <span class='id options'>options</span><span class='period'>.</span><span class='id each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id o'>o</span><span class='op'>|</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span><span class='rbrace'>}</span><span class='tstring_content'>=</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>1</span><span class='rbracket'>]</span><span class='rparen'>)</span> <span class='kw'>if</span> <span class='kw'>self</span><span class='period'>.</span><span class='id respond_to?'>respond_to?</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span><span class='rbrace'>}</span><span class='tstring_content'>=</span><span class='tstring_end'>"</span></span> + <span class='kw'>end</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -367,9 +356,8 @@ value for locked protection </p><div class="docstring"> <div class="discussion"> - <p> -specifies locking for cells that have the style containing this protection -</p> + +<p>specifies locking for cells that have the style containing this protection</p> </div> @@ -403,10 +391,9 @@ specifies locking for cells that have the style containing this protection <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/cell_protection.rb', line 9</span> -<span class='def def kw'>def</span> <span class='hidden identifier id'>hidden</span> - <span class='@hidden ivar id'>@hidden</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id hidden'>hidden</span> + <span class='ivar'>@hidden</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -424,9 +411,8 @@ specifies locking for cells that have the style containing this protection </p><div class="docstring"> <div class="discussion"> - <p> -specifies if the cells that have the style containing this protection -</p> + +<p>specifies if the cells that have the style containing this protection</p> </div> @@ -460,10 +446,9 @@ specifies if the cells that have the style containing this protection <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/cell_protection.rb', line 13</span> -<span class='def def kw'>def</span> <span class='locked identifier id'>locked</span> - <span class='@locked ivar id'>@locked</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id locked'>locked</span> + <span class='ivar'>@locked</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -485,9 +470,8 @@ specifies if the cells that have the style containing this protection </p><div class="docstring"> <div class="discussion"> - <p> -Serializes the cell protection -</p> + +<p>Serializes the cell protection</p> </div> @@ -506,9 +490,8 @@ Serializes the cell protection — - <div class='inline'><p> -The document builder instance this objects xml will be added to. -</p> + <div class='inline'> +<p>The document builder instance this objects xml will be added to.</p> </div> </li> @@ -535,17 +518,16 @@ The document builder instance this objects xml will be added to. <pre class="lines"> -29 -30 -31</pre> +32 +33 +34</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/cell_protection.rb', line 29</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/cell_protection.rb', line 32</span> -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='protection identifier id'>protection</span><span class='lparen token'>(</span><span class='self self kw'>self</span><span class='dot token'>.</span><span class='instance_values identifier id'>instance_values</span><span class='rparen token'>)</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id protection'>protection</span><span class='lparen'>(</span><span class='kw'>self</span><span class='period'>.</span><span class='id instance_values'>instance_values</span><span class='rparen'>)</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -556,9 +538,9 @@ The document builder instance this objects xml will be added to. </div> <div id="footer"> - Generated on Wed Nov 23 22:20:59 2011 by + Generated on Sat Nov 26 13:16:40 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/CellStyle.html b/doc/Axlsx/CellStyle.html index 6bf38863..33981c3b 100644 --- a/doc/Axlsx/CellStyle.html +++ b/doc/Axlsx/CellStyle.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::CellStyle - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -97,16 +97,14 @@ <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -Using Styles#add_style is the recommended way to manage cell styling. -</p> + <div class='inline'> +<p>Using Styles#add_style is the recommended way to manage cell styling.</p> </div> </div> -<p> -CellStyle defines named styles that reference defined formatting records -and can be used in your worksheet. -</p> + +<p>CellStyle defines named styles that reference defined formatting records +and can be used in your worksheet.</p> </div> @@ -145,9 +143,8 @@ and can be used in your worksheet. - <span class="summary_desc"><div class='inline'><p> -The buildinId to use when this named style is applied. -</p> + <span class="summary_desc"><div class='inline'> +<p>The buildinId to use when this named style is applied.</p> </div></span> </li> @@ -172,9 +169,8 @@ The buildinId to use when this named style is applied. - <span class="summary_desc"><div class='inline'><p> -Indicates that the build in style reference has been customized. -</p> + <span class="summary_desc"><div class='inline'> +<p>Indicates that the build in style reference has been customized.</p> </div></span> </li> @@ -199,10 +195,9 @@ Indicates that the build in style reference has been customized. - <span class="summary_desc"><div class='inline'><p> -Determines if this named style should show in the list of styles when using -excel. -</p> + <span class="summary_desc"><div class='inline'> +<p>Determines if this named style should show in the list of styles when using +excel.</p> </div></span> </li> @@ -227,10 +222,9 @@ excel. - <span class="summary_desc"><div class='inline'><p> -Determines if this formatting is for an outline style, and what level of -the outline it is to be applied to. -</p> + <span class="summary_desc"><div class='inline'> +<p>Determines if this formatting is for an outline style, and what level of +the outline it is to be applied to.</p> </div></span> </li> @@ -255,9 +249,8 @@ the outline it is to be applied to. - <span class="summary_desc"><div class='inline'><p> -The name of this cell style. -</p> + <span class="summary_desc"><div class='inline'> +<p>The name of this cell style.</p> </div></span> </li> @@ -282,9 +275,8 @@ The name of this cell style. - <span class="summary_desc"><div class='inline'><p> -The formatting record id this named style utilizes. -</p> + <span class="summary_desc"><div class='inline'> +<p>The formatting record id this named style utilizes.</p> </div></span> </li> @@ -321,9 +313,8 @@ The formatting record id this named style utilizes. - <span class="summary_desc"><div class='inline'><p> -Creats a new CellStyle object. -</p> + <span class="summary_desc"><div class='inline'> +<p>Creats a new CellStyle object.</p> </div></span> </li> @@ -345,9 +336,8 @@ Creats a new CellStyle object. - <span class="summary_desc"><div class='inline'><p> -Serializes the cell style. -</p> + <span class="summary_desc"><div class='inline'> +<p>Serializes the cell style.</p> </div></span> </li> @@ -368,9 +358,8 @@ Serializes the cell style. </p><div class="docstring"> <div class="discussion"> - <p> -Creats a new CellStyle object -</p> + +<p>Creats a new CellStyle object</p> </div> @@ -391,9 +380,8 @@ Creats a new CellStyle object — - <div class='inline'><p> -a customizable set of options -</p> + <div class='inline'> +<p>a customizable set of options</p> </div> </li> @@ -479,12 +467,11 @@ a customizable set of options <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/cell_style.rb', line 39</span> -<span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span><span class='lparen token'>(</span><span class='options identifier id'>options</span><span class='assign token'>=</span><span class='lbrace token'>{</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> - <span class='options identifier id'>options</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='o identifier id'>o</span><span class='bitor op'>|</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='dstring node'>"#{o[0]}="</span><span class='comma token'>,</span> <span class='o identifier id'>o</span><span class='lbrack token'>[</span><span class='integer val'>1</span><span class='rbrack token'>]</span><span class='rparen token'>)</span> <span class='if if_mod kw'>if</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='respond_to? fid id'>respond_to?</span> <span class='o identifier id'>o</span><span class='lbrack token'>[</span><span class='integer val'>0</span><span class='rbrack token'>]</span> - <span class='end end kw'>end</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id initialize'>initialize</span><span class='lparen'>(</span><span class='id options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span> + <span class='id options'>options</span><span class='period'>.</span><span class='id each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id o'>o</span><span class='op'>|</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span><span class='rbrace'>}</span><span class='tstring_content'>=</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>1</span><span class='rbracket'>]</span><span class='rparen'>)</span> <span class='kw'>if</span> <span class='kw'>self</span><span class='period'>.</span><span class='id respond_to?'>respond_to?</span> <span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span> + <span class='kw'>end</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -507,9 +494,8 @@ a customizable set of options </p><div class="docstring"> <div class="discussion"> - <p> -The buildinId to use when this named style is applied -</p> + +<p>The buildinId to use when this named style is applied</p> </div> @@ -550,10 +536,9 @@ The buildinId to use when this named style is applied <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/cell_style.rb', line 18</span> -<span class='def def kw'>def</span> <span class='builtinId identifier id'>builtinId</span> - <span class='@builtinId ivar id'>@builtinId</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id builtinId'>builtinId</span> + <span class='ivar'>@builtinId</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -571,9 +556,8 @@ The buildinId to use when this named style is applied </p><div class="docstring"> <div class="discussion"> - <p> -Indicates that the build in style reference has been customized. -</p> + +<p>Indicates that the build in style reference has been customized.</p> </div> @@ -607,10 +591,9 @@ Indicates that the build in style reference has been customized. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/cell_style.rb', line 30</span> -<span class='def def kw'>def</span> <span class='customBuiltin identifier id'>customBuiltin</span> - <span class='@customBuiltin ivar id'>@customBuiltin</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id customBuiltin'>customBuiltin</span> + <span class='ivar'>@customBuiltin</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -628,10 +611,9 @@ Indicates that the build in style reference has been customized. </p><div class="docstring"> <div class="discussion"> - <p> -Determines if this named style should show in the list of styles when using -excel -</p> + +<p>Determines if this named style should show in the list of styles when using +excel</p> </div> @@ -665,10 +647,9 @@ excel <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/cell_style.rb', line 26</span> -<span class='def def kw'>def</span> <span class='hidden identifier id'>hidden</span> - <span class='@hidden ivar id'>@hidden</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id hidden'>hidden</span> + <span class='ivar'>@hidden</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -686,10 +667,9 @@ excel </p><div class="docstring"> <div class="discussion"> - <p> -Determines if this formatting is for an outline style, and what level of -the outline it is to be applied to. -</p> + +<p>Determines if this formatting is for an outline style, and what level of +the outline it is to be applied to.</p> </div> @@ -723,10 +703,9 @@ the outline it is to be applied to. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/cell_style.rb', line 22</span> -<span class='def def kw'>def</span> <span class='iLevel identifier id'>iLevel</span> - <span class='@iLevel ivar id'>@iLevel</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id iLevel'>iLevel</span> + <span class='ivar'>@iLevel</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -744,9 +723,8 @@ the outline it is to be applied to. </p><div class="docstring"> <div class="discussion"> - <p> -The name of this cell style -</p> + +<p>The name of this cell style</p> </div> @@ -780,10 +758,9 @@ The name of this cell style <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/cell_style.rb', line 8</span> -<span class='def def kw'>def</span> <span class='name identifier id'>name</span> - <span class='@name ivar id'>@name</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id name'>name</span> + <span class='ivar'>@name</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -801,9 +778,8 @@ The name of this cell style </p><div class="docstring"> <div class="discussion"> - <p> -The formatting record id this named style utilizes -</p> + +<p>The formatting record id this named style utilizes</p> </div> @@ -844,10 +820,9 @@ The formatting record id this named style utilizes <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/cell_style.rb', line 13</span> -<span class='def def kw'>def</span> <span class='xfId identifier id'>xfId</span> - <span class='@xfId ivar id'>@xfId</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id xfId'>xfId</span> + <span class='ivar'>@xfId</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -869,9 +844,8 @@ The formatting record id this named style utilizes </p><div class="docstring"> <div class="discussion"> - <p> -Serializes the cell style -</p> + +<p>Serializes the cell style</p> </div> @@ -890,9 +864,8 @@ Serializes the cell style — - <div class='inline'><p> -The document builder instance this objects xml will be added to. -</p> + <div class='inline'> +<p>The document builder instance this objects xml will be added to.</p> </div> </li> @@ -919,17 +892,16 @@ The document builder instance this objects xml will be added to. <pre class="lines"> -55 -56 -57</pre> +60 +61 +62</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/cell_style.rb', line 55</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/cell_style.rb', line 60</span> -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='cellStyle identifier id'>cellStyle</span><span class='lparen token'>(</span><span class='self self kw'>self</span><span class='dot token'>.</span><span class='instance_values identifier id'>instance_values</span><span class='rparen token'>)</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id cellStyle'>cellStyle</span><span class='lparen'>(</span><span class='kw'>self</span><span class='period'>.</span><span class='id instance_values'>instance_values</span><span class='rparen'>)</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -940,9 +912,9 @@ The document builder instance this objects xml will be added to. </div> <div id="footer"> - Generated on Wed Nov 23 22:20:53 2011 by + Generated on Sat Nov 26 13:16:39 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/Chart.html b/doc/Axlsx/Chart.html index d0782980..77914e8a 100644 --- a/doc/Axlsx/Chart.html +++ b/doc/Axlsx/Chart.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::Chart - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -97,16 +97,14 @@ <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -Worksheet#add_chart is the recommended way to create charts for your -worksheets. -</p> + <div class='inline'> +<p>Worksheet#add_chart is the recommended way to create charts for your +worksheets.</p> </div> </div> -<p> -A Chart is the superclass for specific charts -</p> + +<p>A Chart is the superclass for specific charts</p> </div> @@ -149,9 +147,8 @@ A Chart is the superclass for specific charts - <span class="summary_desc"><div class='inline'><p> -A reference to the graphic frame that owns this chart. -</p> + <span class="summary_desc"><div class='inline'> +<p>A reference to the graphic frame that owns this chart.</p> </div></span> </li> @@ -160,7 +157,7 @@ A reference to the graphic frame that owns this chart. <li class="public "> <span class="summary_signature"> - <a href="#index-instance_method" title="#index (instance method)">- (Integer) <strong>index</strong> </a> + <a href="#series-instance_method" title="#series (instance method)">- (SimpleTypedList) <strong>series</strong> </a> @@ -176,9 +173,8 @@ A reference to the graphic frame that owns this chart. - <span class="summary_desc"><div class='inline'><p> -The index of this chart in the workbooks charts collection. -</p> + <span class="summary_desc"><div class='inline'> +<p>A collection of series objects that are applied to the chart.</p> </div></span> </li> @@ -187,7 +183,7 @@ The index of this chart in the workbooks charts collection. <li class="public "> <span class="summary_signature"> - <a href="#pn-instance_method" title="#pn (instance method)">- (String) <strong>pn</strong> </a> + <a href="#series_type-instance_method" title="#series_type (instance method)">- (Series) <strong>series_type</strong> </a> @@ -203,9 +199,8 @@ The index of this chart in the workbooks charts collection. - <span class="summary_desc"><div class='inline'><p> -The part name for this chart. -</p> + <span class="summary_desc"><div class='inline'> +<p>The type of series to use for this chart.</p> </div></span> </li> @@ -214,14 +209,14 @@ The part name for this chart. <li class="public "> <span class="summary_signature"> - <a href="#series-instance_method" title="#series (instance method)">- (SimpleTypedList) <strong>series</strong> </a> + <a href="#show_legend-instance_method" title="#show_legend (instance method)">- (Boolean) <strong>show_legend</strong> </a> </span> - <span class="note title readonly">readonly</span> + @@ -230,9 +225,8 @@ The part name for this chart. - <span class="summary_desc"><div class='inline'><p> -A collection of series objects that are applied to the chart. -</p> + <span class="summary_desc"><div class='inline'> +<p>Show the legend in the chart.</p> </div></span> </li> @@ -241,14 +235,14 @@ A collection of series objects that are applied to the chart. <li class="public "> <span class="summary_signature"> - <a href="#series_type-instance_method" title="#series_type (instance method)">- (Series) <strong>series_type</strong> </a> + <a href="#style-instance_method" title="#style (instance method)">- (Integer) <strong>style</strong> </a> </span> - <span class="note title readonly">readonly</span> + @@ -257,9 +251,8 @@ A collection of series objects that are applied to the chart. - <span class="summary_desc"><div class='inline'><p> -The type of series to use for this chart. -</p> + <span class="summary_desc"><div class='inline'> +<p>The style for the chart.</p> </div></span> </li> @@ -268,7 +261,7 @@ The type of series to use for this chart. <li class="public "> <span class="summary_signature"> - <a href="#show_legend-instance_method" title="#show_legend (instance method)">- (Boolean) <strong>show_legend</strong> </a> + <a href="#title-instance_method" title="#title (instance method)">- (Title) <strong>title</strong> </a> @@ -284,9 +277,8 @@ The type of series to use for this chart. - <span class="summary_desc"><div class='inline'><p> -Show the legend in the chart. -</p> + <span class="summary_desc"><div class='inline'> +<p>The title object for the chart.</p> </div></span> </li> @@ -295,7 +287,7 @@ Show the legend in the chart. <li class="public "> <span class="summary_signature"> - <a href="#style-instance_method" title="#style (instance method)">- (Integer) <strong>style</strong> </a> + <a href="#view3D-instance_method" title="#view3D (instance method)">- (Object) <strong>view3D</strong> </a> @@ -311,85 +303,77 @@ Show the legend in the chart. - <span class="summary_desc"><div class='inline'><p> -The style for the chart. -</p> + <span class="summary_desc"><div class='inline'> +<p>The 3D view properties for the chart.</p> </div></span> </li> - <li class="public "> + </ul> + + + + + + <h2> + Instance Method Summary + <small>(<a href="#" class="summary_toggle">collapse</a>)</small> + </h2> + + <ul class="summary"> + + <li class="public "> <span class="summary_signature"> - <a href="#title-instance_method" title="#title (instance method)">- (Title) <strong>title</strong> </a> + <a href="#add_series-instance_method" title="#add_series (instance method)">- (Series) <strong>add_series</strong>(options = {}) </a> </span> - - - - <span class="summary_desc"><div class='inline'><p> -The title object for the chart. -</p> + <span class="summary_desc"><div class='inline'> +<p>Adds a new series to the chart's series collection.</p> </div></span> </li> - - <li class="public "> + + <li class="public "> <span class="summary_signature"> - <a href="#view3D-instance_method" title="#view3D (instance method)">- (Object) <strong>view3D</strong> </a> + <a href="#end_at-instance_method" title="#end_at (instance method)">- (Marker) <strong>end_at</strong>(x, y) </a> </span> - - - - <span class="summary_desc"><div class='inline'><p> -The 3D view properties for the chart. -</p> + <span class="summary_desc"><div class='inline'> +<p>This is a short cut method to set the end anchor position If you need finer +granularity in positioning use graphic_frame.anchor.to.colOff / rowOff.</p> </div></span> </li> - - </ul> - - - - - - <h2> - Instance Method Summary - <small>(<a href="#" class="summary_toggle">collapse</a>)</small> - </h2> - - <ul class="summary"> <li class="public "> <span class="summary_signature"> - <a href="#add_series-instance_method" title="#add_series (instance method)">- (Series) <strong>add_series</strong>(options = {}) </a> + <a href="#from-instance_method" title="#from (instance method)">- (Object) <strong>from</strong> </a> @@ -402,9 +386,9 @@ The 3D view properties for the chart. - <span class="summary_desc"><div class='inline'><p> -Adds a new series to the chart’s series collection. -</p> + <span class="summary_desc"><div class='inline'> +<p>backwards compatibility to allow chart.to and chart.from access to anchor +markers.</p> </div></span> </li> @@ -413,7 +397,7 @@ Adds a new series to the chart’s series collection. <li class="public "> <span class="summary_signature"> - <a href="#end_at-instance_method" title="#end_at (instance method)">- (Marker) <strong>end_at</strong>(x, y) </a> + <a href="#index-instance_method" title="#index (instance method)">- (Integer) <strong>index</strong> </a> @@ -426,10 +410,8 @@ Adds a new series to the chart’s series collection. - <span class="summary_desc"><div class='inline'><p> -This is a short cut method to set the end anchor position If you need finer -granularity in positioning use graphic_frame.anchor.to.colOff / rowOff. -</p> + <span class="summary_desc"><div class='inline'> +<p>The index of this chart in the workbooks charts collection.</p> </div></span> </li> @@ -438,12 +420,14 @@ granularity in positioning use graphic_frame.anchor.to.colOff / rowOff. <li class="public "> <span class="summary_signature"> - <a href="#from-instance_method" title="#from (instance method)">- (Object) <strong>from</strong> </a> + <a href="#initialize-instance_method" title="#initialize (instance method)">- (Chart) <strong>initialize</strong>(frame, options = {}) {|_self| ... }</a> </span> + <span class="note title constructor">constructor</span> + @@ -451,10 +435,8 @@ granularity in positioning use graphic_frame.anchor.to.colOff / rowOff. - <span class="summary_desc"><div class='inline'><p> -backwards compatibility to allow chart.to and chart.from access to anchor -markers. -</p> + <span class="summary_desc"><div class='inline'> +<p>Creates a new chart object.</p> </div></span> </li> @@ -463,14 +445,12 @@ markers. <li class="public "> <span class="summary_signature"> - <a href="#initialize-instance_method" title="#initialize (instance method)">- (Chart) <strong>initialize</strong>(frame, options = {}) {|_self| ... }</a> + <a href="#pn-instance_method" title="#pn (instance method)">- (String) <strong>pn</strong> </a> </span> - <span class="note title constructor">constructor</span> - @@ -478,9 +458,8 @@ markers. - <span class="summary_desc"><div class='inline'><p> -Creates a new chart object. -</p> + <span class="summary_desc"><div class='inline'> +<p>The part name for this chart.</p> </div></span> </li> @@ -502,11 +481,10 @@ Creates a new chart object. - <span class="summary_desc"><div class='inline'><p> -This is a short cut method to set the start anchor position If you need + <span class="summary_desc"><div class='inline'> +<p>This is a short cut method to set the start anchor position If you need finer granularity in positioning use graphic_frame.anchor.from.colOff / -rowOff. -</p> +rowOff.</p> </div></span> </li> @@ -528,10 +506,9 @@ rowOff. - <span class="summary_desc"><div class='inline'><p> -backwards compatibility to allow chart.to and chart.from access to anchor -markers. -</p> + <span class="summary_desc"><div class='inline'> +<p>backwards compatibility to allow chart.to and chart.from access to anchor +markers.</p> </div></span> </li> @@ -553,9 +530,8 @@ markers. - <span class="summary_desc"><div class='inline'><p> -Chart Serialization serializes the chart. -</p> + <span class="summary_desc"><div class='inline'> +<p>Chart Serialization serializes the chart.</p> </div></span> </li> @@ -576,9 +552,8 @@ Chart Serialization serializes the chart. </p><div class="docstring"> <div class="discussion"> - <p> -Creates a new chart object -</p> + +<p>Creates a new chart object</p> </div> @@ -597,9 +572,8 @@ Creates a new chart object — - <div class='inline'><p> -The frame that holds this chart. -</p> + <div class='inline'> +<p>The frame that holds this chart.</p> </div> </li> @@ -616,9 +590,8 @@ The frame that holds this chart. — - <div class='inline'><p> -a customizable set of options -</p> + <div class='inline'> +<p>a customizable set of options</p> </div> </li> @@ -680,9 +653,8 @@ a customizable set of options — - <div class='inline'><p> -the object that the method was called on -</p> + <div class='inline'> +<p>the object that the method was called on</p> </div> </li> @@ -695,39 +667,38 @@ the object that the method was called on <pre class="lines"> +44 +45 +46 +47 +48 +49 +50 +51 52 53 54 55 56 -57 -58 -59 -60 -61 -62 -63 -64 -65</pre> +57</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/chart.rb', line 52</span> - -<span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span><span class='lparen token'>(</span><span class='frame identifier id'>frame</span><span class='comma token'>,</span> <span class='options identifier id'>options</span><span class='assign token'>=</span><span class='lbrace token'>{</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> - <span class='@style ivar id'>@style</span> <span class='assign token'>=</span> <span class='integer val'>2</span> - <span class='@graphic_frame ivar id'>@graphic_frame</span><span class='assign token'>=</span><span class='frame identifier id'>frame</span> - <span class='@graphic_frame ivar id'>@graphic_frame</span><span class='dot token'>.</span><span class='anchor identifier id'>anchor</span><span class='dot token'>.</span><span class='drawing identifier id'>drawing</span><span class='dot token'>.</span><span class='worksheet identifier id'>worksheet</span><span class='dot token'>.</span><span class='workbook identifier id'>workbook</span><span class='dot token'>.</span><span class='charts identifier id'>charts</span> <span class='lshft op'><<</span> <span class='self self kw'>self</span> - <span class='@series ivar id'>@series</span> <span class='assign token'>=</span> <span class='SimpleTypedList constant id'>SimpleTypedList</span><span class='dot token'>.</span><span class='new identifier id'>new</span> <span class='Series constant id'>Series</span> - <span class='@show_legend ivar id'>@show_legend</span> <span class='assign token'>=</span> <span class='true true kw'>true</span> - <span class='@series_type ivar id'>@series_type</span> <span class='assign token'>=</span> <span class='Series constant id'>Series</span> - <span class='options identifier id'>options</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='o identifier id'>o</span><span class='bitor op'>|</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='dstring node'>"#{o[0]}="</span><span class='comma token'>,</span> <span class='o identifier id'>o</span><span class='lbrack token'>[</span><span class='integer val'>1</span><span class='rbrack token'>]</span><span class='rparen token'>)</span> <span class='if if_mod kw'>if</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='respond_to? fid id'>respond_to?</span> <span class='dstring node'>"#{o[0]}="</span> - <span class='end end kw'>end</span> - <span class='start_at identifier id'>start_at</span> <span class='mult op'>*</span><span class='options identifier id'>options</span><span class='lbrack token'>[</span><span class='symbol val'>:start_at</span><span class='rbrack token'>]</span> <span class='if if_mod kw'>if</span> <span class='options identifier id'>options</span><span class='lbrack token'>[</span><span class='symbol val'>:start_at</span><span class='rbrack token'>]</span> - <span class='end_at identifier id'>end_at</span> <span class='mult op'>*</span><span class='options identifier id'>options</span><span class='lbrack token'>[</span><span class='symbol val'>:end_at</span><span class='rbrack token'>]</span> <span class='if if_mod kw'>if</span> <span class='options identifier id'>options</span><span class='lbrack token'>[</span><span class='symbol val'>:start_at</span><span class='rbrack token'>]</span> - <span class='yield yield kw'>yield</span> <span class='self self kw'>self</span> <span class='if if_mod kw'>if</span> <span class='block_given? fid id'>block_given?</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/chart.rb', line 44</span> + +<span class='kw'>def</span> <span class='id initialize'>initialize</span><span class='lparen'>(</span><span class='id frame'>frame</span><span class='comma'>,</span> <span class='id options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span> + <span class='ivar'>@style</span> <span class='op'>=</span> <span class='int'>2</span> + <span class='ivar'>@graphic_frame</span><span class='op'>=</span><span class='id frame'>frame</span> + <span class='ivar'>@graphic_frame</span><span class='period'>.</span><span class='id anchor'>anchor</span><span class='period'>.</span><span class='id drawing'>drawing</span><span class='period'>.</span><span class='id worksheet'>worksheet</span><span class='period'>.</span><span class='id workbook'>workbook</span><span class='period'>.</span><span class='id charts'>charts</span> <span class='op'><<</span> <span class='kw'>self</span> + <span class='ivar'>@series</span> <span class='op'>=</span> <span class='const'>SimpleTypedList</span><span class='period'>.</span><span class='id new'>new</span> <span class='const'>Series</span> + <span class='ivar'>@show_legend</span> <span class='op'>=</span> <span class='kw'>true</span> + <span class='ivar'>@series_type</span> <span class='op'>=</span> <span class='const'>Series</span> + <span class='id options'>options</span><span class='period'>.</span><span class='id each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id o'>o</span><span class='op'>|</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span><span class='rbrace'>}</span><span class='tstring_content'>=</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>1</span><span class='rbracket'>]</span><span class='rparen'>)</span> <span class='kw'>if</span> <span class='kw'>self</span><span class='period'>.</span><span class='id respond_to?'>respond_to?</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span><span class='rbrace'>}</span><span class='tstring_content'>=</span><span class='tstring_end'>"</span></span> + <span class='kw'>end</span> + <span class='id start_at'>start_at</span><span class='lparen'>(</span><span class='op'>*</span><span class='id options'>options</span><span class='lbracket'>[</span><span class='symbol'>:start_at</span><span class='rbracket'>]</span><span class='rparen'>)</span> <span class='kw'>if</span> <span class='id options'>options</span><span class='lbracket'>[</span><span class='symbol'>:start_at</span><span class='rbracket'>]</span> + <span class='id end_at'>end_at</span><span class='lparen'>(</span><span class='op'>*</span><span class='id options'>options</span><span class='lbracket'>[</span><span class='symbol'>:end_at</span><span class='rbracket'>]</span><span class='rparen'>)</span> <span class='kw'>if</span> <span class='id options'>options</span><span class='lbracket'>[</span><span class='symbol'>:start_at</span><span class='rbracket'>]</span> + <span class='kw'>yield</span> <span class='kw'>self</span> <span class='kw'>if</span> <span class='id block_given?'>block_given?</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -750,9 +721,8 @@ the object that the method was called on </p><div class="docstring"> <div class="discussion"> - <p> -A reference to the graphic frame that owns this chart -</p> + +<p>A reference to the graphic frame that owns this chart</p> </div> @@ -786,124 +756,9 @@ A reference to the graphic frame that owns this chart <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/chart.rb', line 14</span> -<span class='def def kw'>def</span> <span class='graphic_frame identifier id'>graphic_frame</span> - <span class='@graphic_frame ivar id'>@graphic_frame</span> -<span class='end end kw'>end</span> -</pre> - </td> - </tr> -</table> -</div> - - - <span id=""></span> - <span id="index-instance_method"></span> - <div class="method_details "> - <p class="signature " id="index-instance_method"> - - - (<tt>Integer</tt>) <strong>index</strong> <span class="extras">(readonly)</span> - - - -</p><div class="docstring"> - <div class="discussion"> - <p> -The index of this chart in the workbooks charts collection -</p> - - - </div> -</div> -<div class="tags"> - -<h3>Returns:</h3> -<ul class="return"> - - <li> - - - <span class='type'>(<tt>Integer</tt>)</span> - - - - </li> - -</ul> - -</div><table class="source_code"> - <tr> - <td> - <pre class="lines"> - - -26 -27 -28</pre> - </td> - <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/chart.rb', line 26</span> - -<span class='def def kw'>def</span> <span class='index identifier id'>index</span> - <span class='@graphic_frame ivar id'>@graphic_frame</span><span class='dot token'>.</span><span class='anchor identifier id'>anchor</span><span class='dot token'>.</span><span class='drawing identifier id'>drawing</span><span class='dot token'>.</span><span class='worksheet identifier id'>worksheet</span><span class='dot token'>.</span><span class='workbook identifier id'>workbook</span><span class='dot token'>.</span><span class='charts identifier id'>charts</span><span class='dot token'>.</span><span class='index identifier id'>index</span><span class='lparen token'>(</span><span class='self self kw'>self</span><span class='rparen token'>)</span> -<span class='end end kw'>end</span> -</pre> - </td> - </tr> -</table> -</div> - - - <span id=""></span> - <span id="pn-instance_method"></span> - <div class="method_details "> - <p class="signature " id="pn-instance_method"> - - - (<tt>String</tt>) <strong>pn</strong> <span class="extras">(readonly)</span> - - - -</p><div class="docstring"> - <div class="discussion"> - <p> -The part name for this chart -</p> - - - </div> -</div> -<div class="tags"> - -<h3>Returns:</h3> -<ul class="return"> - - <li> - - - <span class='type'>(<tt>String</tt>)</span> - - - - </li> - -</ul> - -</div><table class="source_code"> - <tr> - <td> - <pre class="lines"> - - -30 -31 -32</pre> - </td> - <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/chart.rb', line 30</span> - -<span class='def def kw'>def</span> <span class='pn identifier id'>pn</span> - <span class='dstring node'>"#{CHART_PN % (index+1)}"</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id graphic_frame'>graphic_frame</span> + <span class='ivar'>@graphic_frame</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -921,9 +776,8 @@ The part name for this chart </p><div class="docstring"> <div class="discussion"> - <p> -A collection of series objects that are applied to the chart -</p> + +<p>A collection of series objects that are applied to the chart</p> </div> @@ -957,10 +811,9 @@ A collection of series objects that are applied to the chart <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/chart.rb', line 18</span> -<span class='def def kw'>def</span> <span class='series identifier id'>series</span> - <span class='@series ivar id'>@series</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id series'>series</span> + <span class='ivar'>@series</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -978,9 +831,8 @@ A collection of series objects that are applied to the chart </p><div class="docstring"> <div class="discussion"> - <p> -The type of series to use for this chart. -</p> + +<p>The type of series to use for this chart.</p> </div> @@ -1014,10 +866,9 @@ The type of series to use for this chart. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/chart.rb', line 22</span> -<span class='def def kw'>def</span> <span class='series_type identifier id'>series_type</span> - <span class='@series_type ivar id'>@series_type</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id series_type'>series_type</span> + <span class='ivar'>@series_type</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1035,9 +886,8 @@ The type of series to use for this chart. </p><div class="docstring"> <div class="discussion"> - <p> -Show the legend in the chart -</p> + +<p>Show the legend in the chart</p> </div> @@ -1064,17 +914,16 @@ Show the legend in the chart <pre class="lines"> -46 -47 -48</pre> +38 +39 +40</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/chart.rb', line 46</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/chart.rb', line 38</span> -<span class='def def kw'>def</span> <span class='show_legend identifier id'>show_legend</span> - <span class='@show_legend ivar id'>@show_legend</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id show_legend'>show_legend</span> + <span class='ivar'>@show_legend</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1092,9 +941,8 @@ Show the legend in the chart </p><div class="docstring"> <div class="discussion"> - <p> -The style for the chart. see ECMA Part 1 §21.2.2.196 -</p> + +<p>The style for the chart. see ECMA Part 1 §21.2.2.196</p> </div> @@ -1121,17 +969,16 @@ The style for the chart. see ECMA Part 1 §21.2.2.196 <pre class="lines"> -42 -43 -44</pre> +34 +35 +36</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/chart.rb', line 42</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/chart.rb', line 34</span> -<span class='def def kw'>def</span> <span class='style identifier id'>style</span> - <span class='@style ivar id'>@style</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id style'>style</span> + <span class='ivar'>@style</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1149,9 +996,8 @@ The style for the chart. see ECMA Part 1 §21.2.2.196 </p><div class="docstring"> <div class="discussion"> - <p> -The title object for the chart. -</p> + +<p>The title object for the chart.</p> </div> @@ -1178,17 +1024,16 @@ The title object for the chart. <pre class="lines"> -37 -38 -39</pre> +29 +30 +31</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/chart.rb', line 37</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/chart.rb', line 29</span> -<span class='def def kw'>def</span> <span class='title identifier id'>title</span> - <span class='@title ivar id'>@title</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id title'>title</span> + <span class='ivar'>@title</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1206,9 +1051,8 @@ The title object for the chart. </p><div class="docstring"> <div class="discussion"> - <p> -The 3D view properties for the chart -</p> + +<p>The 3D view properties for the chart</p> </div> @@ -1229,10 +1073,9 @@ The 3D view properties for the chart <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/chart.rb', line 10</span> -<span class='def def kw'>def</span> <span class='view3D identifier id'>view3D</span> - <span class='@view3D ivar id'>@view3D</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id view3D'>view3D</span> + <span class='ivar'>@view3D</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1254,9 +1097,8 @@ The 3D view properties for the chart </p><div class="docstring"> <div class="discussion"> - <p> -Adds a new series to the chart’s series collection. -</p> + +<p>Adds a new series to the chart's series collection.</p> </div> @@ -1290,19 +1132,18 @@ Adds a new series to the chart’s series collection. <pre class="lines"> -100 -101 -102 -103</pre> +106 +107 +108 +109</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/chart.rb', line 100</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/chart.rb', line 106</span> -<span class='def def kw'>def</span> <span class='add_series identifier id'>add_series</span><span class='lparen token'>(</span><span class='options identifier id'>options</span><span class='assign token'>=</span><span class='lbrace token'>{</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> - <span class='@series_type ivar id'>@series_type</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='self self kw'>self</span><span class='comma token'>,</span> <span class='options identifier id'>options</span><span class='rparen token'>)</span> - <span class='@series ivar id'>@series</span><span class='dot token'>.</span><span class='last identifier id'>last</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id add_series'>add_series</span><span class='lparen'>(</span><span class='id options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span> + <span class='ivar'>@series_type</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='kw'>self</span><span class='comma'>,</span> <span class='id options'>options</span><span class='rparen'>)</span> + <span class='ivar'>@series</span><span class='period'>.</span><span class='id last'>last</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1317,10 +1158,9 @@ Adds a new series to the chart’s series collection. </p><div class="docstring"> <div class="discussion"> - <p> -This is a short cut method to set the end anchor position If you need finer -granularity in positioning use graphic_frame.anchor.to.colOff / rowOff -</p> + +<p>This is a short cut method to set the end anchor position If you need finer +granularity in positioning use graphic_frame.anchor.to.colOff / rowOff</p> </div> @@ -1339,9 +1179,8 @@ granularity in positioning use graphic_frame.anchor.to.colOff / rowOff — - <div class='inline'><p> -The column -</p> + <div class='inline'> +<p>The column</p> </div> </li> @@ -1356,9 +1195,8 @@ The column — - <div class='inline'><p> -The row -</p> + <div class='inline'> +<p>The row</p> </div> </li> @@ -1385,19 +1223,18 @@ The row <pre class="lines"> -148 -149 -150 -151</pre> +154 +155 +156 +157</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/chart.rb', line 148</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/chart.rb', line 154</span> -<span class='def def kw'>def</span> <span class='end_at identifier id'>end_at</span><span class='lparen token'>(</span><span class='x identifier id'>x</span><span class='comma token'>,</span> <span class='y identifier id'>y</span><span class='rparen token'>)</span> - <span class='@graphic_frame ivar id'>@graphic_frame</span><span class='dot token'>.</span><span class='anchor identifier id'>anchor</span><span class='dot token'>.</span><span class='to identifier id'>to</span><span class='dot token'>.</span><span class='col identifier id'>col</span> <span class='assign token'>=</span> <span class='x identifier id'>x</span> - <span class='@graphic_frame ivar id'>@graphic_frame</span><span class='dot token'>.</span><span class='anchor identifier id'>anchor</span><span class='dot token'>.</span><span class='to identifier id'>to</span><span class='dot token'>.</span><span class='row identifier id'>row</span> <span class='assign token'>=</span> <span class='y identifier id'>y</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id end_at'>end_at</span><span class='lparen'>(</span><span class='id x'>x</span><span class='comma'>,</span> <span class='id y'>y</span><span class='rparen'>)</span> + <span class='ivar'>@graphic_frame</span><span class='period'>.</span><span class='id anchor'>anchor</span><span class='period'>.</span><span class='id to'>to</span><span class='period'>.</span><span class='id col'>col</span> <span class='op'>=</span> <span class='id x'>x</span> + <span class='ivar'>@graphic_frame</span><span class='period'>.</span><span class='id anchor'>anchor</span><span class='period'>.</span><span class='id to'>to</span><span class='period'>.</span><span class='id row'>row</span> <span class='op'>=</span> <span class='id y'>y</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1415,16 +1252,14 @@ The row <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -This will be disconinued in version 2.0.0. please use the start_at method -</p> + <div class='inline'> +<p>This will be disconinued in version 2.0.0. please use the start_at method</p> </div> </div> -<p> -backwards compatibility to allow chart.to and chart.from access to anchor -markers -</p> + +<p>backwards compatibility to allow chart.to and chart.from access to anchor +markers</p> </div> @@ -1438,17 +1273,120 @@ markers <pre class="lines"> -93 -94 -95</pre> +99 +100 +101</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/chart.rb', line 93</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/chart.rb', line 99</span> + +<span class='kw'>def</span> <span class='id from'>from</span> + <span class='ivar'>@graphic_frame</span><span class='period'>.</span><span class='id anchor'>anchor</span><span class='period'>.</span><span class='id from'>from</span> +<span class='kw'>end</span></pre> + </td> + </tr> +</table> +</div> + + <div class="method_details "> + <p class="signature " id="index-instance_method"> + + - (<tt>Integer</tt>) <strong>index</strong> + + + +</p><div class="docstring"> + <div class="discussion"> + +<p>The index of this chart in the workbooks charts collection</p> + + + </div> +</div> +<div class="tags"> + +<h3>Returns:</h3> +<ul class="return"> + + <li> + + + <span class='type'>(<tt>Integer</tt>)</span> + + + + </li> + +</ul> + +</div><table class="source_code"> + <tr> + <td> + <pre class="lines"> + + +61 +62 +63</pre> + </td> + <td> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/chart.rb', line 61</span> -<span class='def def kw'>def</span> <span class='from identifier id'>from</span> - <span class='@graphic_frame ivar id'>@graphic_frame</span><span class='dot token'>.</span><span class='anchor identifier id'>anchor</span><span class='dot token'>.</span><span class='from identifier id'>from</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id index'>index</span> + <span class='ivar'>@graphic_frame</span><span class='period'>.</span><span class='id anchor'>anchor</span><span class='period'>.</span><span class='id drawing'>drawing</span><span class='period'>.</span><span class='id worksheet'>worksheet</span><span class='period'>.</span><span class='id workbook'>workbook</span><span class='period'>.</span><span class='id charts'>charts</span><span class='period'>.</span><span class='id index'>index</span><span class='lparen'>(</span><span class='kw'>self</span><span class='rparen'>)</span> +<span class='kw'>end</span></pre> + </td> + </tr> +</table> +</div> + + <div class="method_details "> + <p class="signature " id="pn-instance_method"> + + - (<tt>String</tt>) <strong>pn</strong> + + + +</p><div class="docstring"> + <div class="discussion"> + +<p>The part name for this chart</p> + + + </div> +</div> +<div class="tags"> + +<h3>Returns:</h3> +<ul class="return"> + + <li> + + + <span class='type'>(<tt>String</tt>)</span> + + + + </li> + +</ul> + +</div><table class="source_code"> + <tr> + <td> + <pre class="lines"> + + +67 +68 +69</pre> + </td> + <td> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/chart.rb', line 67</span> + +<span class='kw'>def</span> <span class='id pn'>pn</span> + <span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='const'>CHART_PN</span> <span class='op'>%</span> <span class='lparen'>(</span><span class='id index'>index</span><span class='op'>+</span><span class='int'>1</span><span class='rparen'>)</span><span class='rbrace'>}</span><span class='tstring_end'>"</span></span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1463,11 +1401,10 @@ markers </p><div class="docstring"> <div class="discussion"> - <p> -This is a short cut method to set the start anchor position If you need + +<p>This is a short cut method to set the start anchor position If you need finer granularity in positioning use graphic_frame.anchor.from.colOff / -rowOff -</p> +rowOff</p> </div> @@ -1486,9 +1423,8 @@ rowOff — - <div class='inline'><p> -The column -</p> + <div class='inline'> +<p>The column</p> </div> </li> @@ -1503,9 +1439,8 @@ The column — - <div class='inline'><p> -The row -</p> + <div class='inline'> +<p>The row</p> </div> </li> @@ -1532,19 +1467,18 @@ The row <pre class="lines"> -137 -138 -139 -140</pre> +143 +144 +145 +146</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/chart.rb', line 137</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/chart.rb', line 143</span> -<span class='def def kw'>def</span> <span class='start_at identifier id'>start_at</span><span class='lparen token'>(</span><span class='x identifier id'>x</span><span class='comma token'>,</span> <span class='y identifier id'>y</span><span class='rparen token'>)</span> - <span class='@graphic_frame ivar id'>@graphic_frame</span><span class='dot token'>.</span><span class='anchor identifier id'>anchor</span><span class='dot token'>.</span><span class='from identifier id'>from</span><span class='dot token'>.</span><span class='col identifier id'>col</span> <span class='assign token'>=</span> <span class='x identifier id'>x</span> - <span class='@graphic_frame ivar id'>@graphic_frame</span><span class='dot token'>.</span><span class='anchor identifier id'>anchor</span><span class='dot token'>.</span><span class='from identifier id'>from</span><span class='dot token'>.</span><span class='row identifier id'>row</span> <span class='assign token'>=</span> <span class='y identifier id'>y</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id start_at'>start_at</span><span class='lparen'>(</span><span class='id x'>x</span><span class='comma'>,</span> <span class='id y'>y</span><span class='rparen'>)</span> + <span class='ivar'>@graphic_frame</span><span class='period'>.</span><span class='id anchor'>anchor</span><span class='period'>.</span><span class='id from'>from</span><span class='period'>.</span><span class='id col'>col</span> <span class='op'>=</span> <span class='id x'>x</span> + <span class='ivar'>@graphic_frame</span><span class='period'>.</span><span class='id anchor'>anchor</span><span class='period'>.</span><span class='id from'>from</span><span class='period'>.</span><span class='id row'>row</span> <span class='op'>=</span> <span class='id y'>y</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1562,16 +1496,14 @@ The row <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -This will be disconinued in version 2.0.0. Please use the end_at method -</p> + <div class='inline'> +<p>This will be disconinued in version 2.0.0. Please use the end_at method</p> </div> </div> -<p> -backwards compatibility to allow chart.to and chart.from access to anchor -markers -</p> + +<p>backwards compatibility to allow chart.to and chart.from access to anchor +markers</p> </div> @@ -1585,17 +1517,16 @@ markers <pre class="lines"> -87 -88 -89</pre> +93 +94 +95</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/chart.rb', line 87</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/chart.rb', line 93</span> -<span class='def def kw'>def</span> <span class='to identifier id'>to</span> - <span class='@graphic_frame ivar id'>@graphic_frame</span><span class='dot token'>.</span><span class='anchor identifier id'>anchor</span><span class='dot token'>.</span><span class='to identifier id'>to</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id to'>to</span> + <span class='ivar'>@graphic_frame</span><span class='period'>.</span><span class='id anchor'>anchor</span><span class='period'>.</span><span class='id to'>to</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1610,9 +1541,8 @@ markers </p><div class="docstring"> <div class="discussion"> - <p> -Chart Serialization serializes the chart -</p> + +<p>Chart Serialization serializes the chart</p> </div> @@ -1626,12 +1556,6 @@ Chart Serialization serializes the chart <pre class="lines"> -107 -108 -109 -110 -111 -112 113 114 115 @@ -1648,35 +1572,40 @@ Chart Serialization serializes the chart 126 127 128 -129</pre> +129 +130 +131 +132 +133 +134 +135</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/chart.rb', line 107</span> - -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span> - <span class='builder identifier id'>builder</span> <span class='assign token'>=</span> <span class='Nokogiri constant id'>Nokogiri</span><span class='colon2 op'>::</span><span class='XML constant id'>XML</span><span class='colon2 op'>::</span><span class='Builder constant id'>Builder</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='symbol val'>:encoding</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='ENCODING constant id'>ENCODING</span><span class='rparen token'>)</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='xml identifier id'>xml</span><span class='bitor op'>|</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:chartSpace'</span><span class='comma token'>,</span><span class='symbol val'>:'xmlns:c'</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='XML_NS_C constant id'>XML_NS_C</span><span class='comma token'>,</span> <span class='symbol val'>:'xmlns:a'</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='XML_NS_A constant id'>XML_NS_A</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:date1904'</span><span class='comma token'>,</span> <span class='symbol val'>:val=</span><span class='gt op'>></span><span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='Workbook constant id'>Workbook</span><span class='dot token'>.</span><span class='date1904 identifier id'>date1904</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:style'</span><span class='comma token'>,</span> <span class='symbol val'>:val=</span><span class='gt op'>></span><span class='style identifier id'>style</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:chart'</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='@title ivar id'>@title</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> <span class='unless unless_mod kw'>unless</span> <span class='@title ivar id'>@title</span><span class='dot token'>.</span><span class='nil? fid id'>nil?</span> - <span class='@view3D ivar id'>@view3D</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> <span class='unless unless_mod kw'>unless</span> <span class='@view3D ivar id'>@view3D</span><span class='dot token'>.</span><span class='nil? fid id'>nil?</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:plotArea'</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:layout'</span><span class='rparen token'>)</span> - <span class='yield yield kw'>yield</span> <span class='xml identifier id'>xml</span> <span class='if if_mod kw'>if</span> <span class='block_given? fid id'>block_given?</span> - <span class='rbrace token'>}</span> - <span class='if if kw'>if</span> <span class='@show_legend ivar id'>@show_legend</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:legend'</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:legendPos'</span><span class='comma token'>,</span> <span class='symbol val'>:val</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='string val'>"r"</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:layout'</span><span class='rparen token'>)</span> - <span class='rbrace token'>}</span> - <span class='end end kw'>end</span> - <span class='rbrace token'>}</span> - <span class='rbrace token'>}</span> - <span class='end end kw'>end</span> - <span class='builder identifier id'>builder</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/chart.rb', line 113</span> + +<span class='kw'>def</span> <span class='id to_xml'>to_xml</span> + <span class='id builder'>builder</span> <span class='op'>=</span> <span class='const'>Nokogiri</span><span class='op'>::</span><span class='const'>XML</span><span class='op'>::</span><span class='const'>Builder</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='symbol'>:encoding</span> <span class='op'>=></span> <span class='const'>ENCODING</span><span class='rparen'>)</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id xml'>xml</span><span class='op'>|</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:chartSpace</span><span class='tstring_end'>'</span></span><span class='comma'>,</span><span class='symbol'>:xmlns:c</span><span class='tstring_end'>'</span></span> <span class='op'>=></span> <span class='const'>XML_NS_C</span><span class='comma'>,</span> <span class='symbol'>:xmlns:a</span><span class='tstring_end'>'</span></span> <span class='op'>=></span> <span class='const'>XML_NS_A</span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:date1904</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:val</span><span class='op'>=></span><span class='const'>Axlsx</span><span class='op'>::</span><span class='const'>Workbook</span><span class='period'>.</span><span class='id date1904'>date1904</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:style</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:val</span><span class='op'>=></span><span class='id style'>style</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:chart</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='ivar'>@title</span><span class='period'>.</span><span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> <span class='kw'>unless</span> <span class='ivar'>@title</span><span class='period'>.</span><span class='id nil?'>nil?</span> + <span class='ivar'>@view3D</span><span class='period'>.</span><span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> <span class='kw'>unless</span> <span class='ivar'>@view3D</span><span class='period'>.</span><span class='id nil?'>nil?</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:plotArea</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:layout</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> + <span class='kw'>yield</span> <span class='id xml'>xml</span> <span class='kw'>if</span> <span class='id block_given?'>block_given?</span> + <span class='rbrace'>}</span> + <span class='kw'>if</span> <span class='ivar'>@show_legend</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:legend</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:legendPos</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:val</span> <span class='op'>=></span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>r</span><span class='tstring_end'>"</span></span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:layout</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> + <span class='rbrace'>}</span> + <span class='kw'>end</span> + <span class='rbrace'>}</span> + <span class='rbrace'>}</span> + <span class='kw'>end</span> + <span class='id builder'>builder</span><span class='period'>.</span><span class='id to_xml'>to_xml</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1687,9 +1616,9 @@ Chart Serialization serializes the chart </div> <div id="footer"> - Generated on Wed Nov 23 22:21:05 2011 by + Generated on Sat Nov 26 13:16:36 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/Color.html b/doc/Axlsx/Color.html index 5bfd584e..30d44a38 100644 --- a/doc/Axlsx/Color.html +++ b/doc/Axlsx/Color.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::Color - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -94,9 +94,8 @@ <h2>Overview</h2><div class="docstring"> <div class="discussion"> - <p> -The color class represents a color used for borders, fills an fonts -</p> + +<p>The color class represents a color used for borders, fills an fonts</p> </div> @@ -128,9 +127,8 @@ The color class represents a color used for borders, fills an fonts - <span class="summary_desc"><div class='inline'><p> -Determines if the color is system color dependant. -</p> + <span class="summary_desc"><div class='inline'> +<p>Determines if the color is system color dependant.</p> </div></span> </li> @@ -155,9 +153,8 @@ Determines if the color is system color dependant. - <span class="summary_desc"><div class='inline'><p> -The color as defined in rgb terms. -</p> + <span class="summary_desc"><div class='inline'> +<p>The color as defined in rgb terms.</p> </div></span> </li> @@ -182,9 +179,8 @@ The color as defined in rgb terms. - <span class="summary_desc"><div class='inline'><p> -The tint value. -</p> + <span class="summary_desc"><div class='inline'> +<p>The tint value.</p> </div></span> </li> @@ -221,9 +217,8 @@ The tint value. - <span class="summary_desc"><div class='inline'><p> -Creates a new Color object. -</p> + <span class="summary_desc"><div class='inline'> +<p>Creates a new Color object.</p> </div></span> </li> @@ -245,9 +240,8 @@ Creates a new Color object. - <span class="summary_desc"><div class='inline'><p> -Serializes the color. -</p> + <span class="summary_desc"><div class='inline'> +<p>Serializes the color.</p> </div></span> </li> @@ -268,9 +262,8 @@ Serializes the color. </p><div class="docstring"> <div class="discussion"> - <p> -Creates a new Color object -</p> + +<p>Creates a new Color object</p> </div> @@ -291,9 +284,8 @@ Creates a new Color object — - <div class='inline'><p> -a customizable set of options -</p> + <div class='inline'> +<p>a customizable set of options</p> </div> </li> @@ -353,13 +345,12 @@ a customizable set of options <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/color.rb', line 34</span> -<span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span><span class='lparen token'>(</span><span class='options identifier id'>options</span><span class='assign token'>=</span><span class='lbrace token'>{</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> - <span class='@rgb ivar id'>@rgb</span> <span class='assign token'>=</span> <span class='string val'>"FF000000"</span> - <span class='options identifier id'>options</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='o identifier id'>o</span><span class='bitor op'>|</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='dstring node'>"#{o[0]}="</span><span class='comma token'>,</span> <span class='o identifier id'>o</span><span class='lbrack token'>[</span><span class='integer val'>1</span><span class='rbrack token'>]</span><span class='rparen token'>)</span> <span class='if if_mod kw'>if</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='respond_to? fid id'>respond_to?</span> <span class='o identifier id'>o</span><span class='lbrack token'>[</span><span class='integer val'>0</span><span class='rbrack token'>]</span> - <span class='end end kw'>end</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id initialize'>initialize</span><span class='lparen'>(</span><span class='id options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span> + <span class='ivar'>@rgb</span> <span class='op'>=</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>FF000000</span><span class='tstring_end'>"</span></span> + <span class='id options'>options</span><span class='period'>.</span><span class='id each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id o'>o</span><span class='op'>|</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span><span class='rbrace'>}</span><span class='tstring_content'>=</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>1</span><span class='rbracket'>]</span><span class='rparen'>)</span> <span class='kw'>if</span> <span class='kw'>self</span><span class='period'>.</span><span class='id respond_to?'>respond_to?</span> <span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span> + <span class='kw'>end</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -382,9 +373,8 @@ a customizable set of options </p><div class="docstring"> <div class="discussion"> - <p> -Determines if the color is system color dependant -</p> + +<p>Determines if the color is system color dependant</p> </div> @@ -418,10 +408,9 @@ Determines if the color is system color dependant <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/color.rb', line 6</span> -<span class='def def kw'>def</span> <span class='auto identifier id'>auto</span> - <span class='@auto ivar id'>@auto</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id auto'>auto</span> + <span class='ivar'>@auto</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -442,16 +431,14 @@ Determines if the color is system color dependant <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -rgb colors need to conform to ST_UnsignedIntHex. That basically means put -‘FF’ before you color -</p> + <div class='inline'> +<p>rgb colors need to conform to ST_UnsignedIntHex. That basically means put +'FF' before you color</p> </div> </div> -<p> -The color as defined in rgb terms. -</p> + +<p>The color as defined in rgb terms.</p> </div> @@ -461,13 +448,11 @@ The color as defined in rgb terms. <div class="examples"> <h3>Examples:</h3> - <h4><div class='inline'><p> -rgb colors -</p> + <h4><div class='inline'> +<p>rgb colors</p> </div></h4> - <pre class="example code"><span class='string val'>"FF000000"</span> <span class='is identifier id'>is</span> <span class='black identifier id'>black</span> -<span class='string val'>"FFFFFFFF"</span> <span class='is identifier id'>is</span> <span class='white identifier id'>white</span> -</pre> + <pre class="example code">"FF000000" is black +"FFFFFFFF" is white</pre> </div> @@ -498,10 +483,9 @@ rgb colors <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/color.rb', line 19</span> -<span class='def def kw'>def</span> <span class='rgb identifier id'>rgb</span> - <span class='@rgb ivar id'>@rgb</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id rgb'>rgb</span> + <span class='ivar'>@rgb</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -522,15 +506,13 @@ rgb colors <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -valid values are between -1.0 and 1.0 -</p> + <div class='inline'> +<p>valid values are between -1.0 and 1.0</p> </div> </div> -<p> -The tint value. -</p> + +<p>The tint value.</p> </div> @@ -564,10 +546,9 @@ The tint value. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/color.rb', line 28</span> -<span class='def def kw'>def</span> <span class='tint identifier id'>tint</span> - <span class='@tint ivar id'>@tint</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id tint'>tint</span> + <span class='ivar'>@tint</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -589,9 +570,8 @@ The tint value. </p><div class="docstring"> <div class="discussion"> - <p> -Serializes the color -</p> + +<p>Serializes the color</p> </div> @@ -610,9 +590,8 @@ Serializes the color — - <div class='inline'><p> -The document builder instance this objects xml will be added to. -</p> + <div class='inline'> +<p>The document builder instance this objects xml will be added to.</p> </div> </li> @@ -639,13 +618,12 @@ The document builder instance this objects xml will be added to. <pre class="lines"> -55</pre> +57</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/color.rb', line 55</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/color.rb', line 57</span> -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='color identifier id'>color</span><span class='lparen token'>(</span><span class='self self kw'>self</span><span class='dot token'>.</span><span class='instance_values identifier id'>instance_values</span><span class='rparen token'>)</span> <span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> <span class='id xml'>xml</span><span class='period'>.</span><span class='id color'>color</span><span class='lparen'>(</span><span class='kw'>self</span><span class='period'>.</span><span class='id instance_values'>instance_values</span><span class='rparen'>)</span> <span class='kw'>end</span></pre> </td> </tr> </table> @@ -656,9 +634,9 @@ The document builder instance this objects xml will be added to. </div> <div id="footer"> - Generated on Wed Nov 23 22:20:51 2011 by + Generated on Sat Nov 26 13:16:37 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/ContentType.html b/doc/Axlsx/ContentType.html index 428c4f6d..d0b1de57 100644 --- a/doc/Axlsx/ContentType.html +++ b/doc/Axlsx/ContentType.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::ContentType - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -96,10 +96,9 @@ <h2>Overview</h2><div class="docstring"> <div class="discussion"> - <p> -ContentTypes used in the package. This is automatcially managed by the -package package. -</p> + +<p>ContentTypes used in the package. This is automatcially managed by the +package package.</p> </div> @@ -150,9 +149,8 @@ package package. - <span class="summary_desc"><div class='inline'><p> -A new instance of ContentType. -</p> + <span class="summary_desc"><div class='inline'> +<p>A new instance of ContentType.</p> </div></span> </li> @@ -174,9 +172,8 @@ A new instance of ContentType. - <span class="summary_desc"><div class='inline'><p> -Generates the xml document for [Content_Types].xml. -</p> + <span class="summary_desc"><div class='inline'> +<p>Generates the xml document for [Content_Types].xml.</p> </div></span> </li> @@ -190,12 +187,7 @@ Generates the xml document for [Content_Types].xml. - - - - <h3 class="inherited">Methods inherited from <span class='object_link'><a href="SimpleTypedList.html" title="Axlsx::SimpleTypedList (class)">SimpleTypedList</a></span></h3> - <p class="inherited"><span class='object_link'><a href="SimpleTypedList.html#%3C%3C-instance_method" title="Axlsx::SimpleTypedList#<< (method)">#<<</a></span>, <span class='object_link'><a href="SimpleTypedList.html#%3D%3D-instance_method" title="Axlsx::SimpleTypedList#== (method)">#==</a></span>, <span class='object_link'><a href="SimpleTypedList.html#%5B%5D%3D-instance_method" title="Axlsx::SimpleTypedList#[]= (method)">#[]=</a></span>, <span class='object_link'><a href="SimpleTypedList.html#delete-instance_method" title="Axlsx::SimpleTypedList#delete (method)">#delete</a></span>, <span class='object_link'><a href="SimpleTypedList.html#delete_at-instance_method" title="Axlsx::SimpleTypedList#delete_at (method)">#delete_at</a></span>, <span class='object_link'><a href="SimpleTypedList.html#lock-instance_method" title="Axlsx::SimpleTypedList#lock (method)">#lock</a></span>, <span class='object_link'><a href="SimpleTypedList.html#method_missing-instance_method" title="Axlsx::SimpleTypedList#method_missing (method)">#method_missing</a></span>, <span class='object_link'><a href="SimpleTypedList.html#protected%3F-instance_method" title="Axlsx::SimpleTypedList#protected? (method)">#protected?</a></span>, <span class='object_link'><a href="SimpleTypedList.html#push-instance_method" title="Axlsx::SimpleTypedList#push (method)">#push</a></span>, <span class='object_link'><a href="SimpleTypedList.html#unlock-instance_method" title="Axlsx::SimpleTypedList#unlock (method)">#unlock</a></span></p> -<div id="constructor_details" class="method_details_list"> + <div id="constructor_details" class="method_details_list"> <h2>Constructor Details</h2> <div class="method_details first"> @@ -207,9 +199,8 @@ Generates the xml document for [Content_Types].xml. </p><div class="docstring"> <div class="discussion"> - <p> -A new instance of ContentType -</p> + +<p>A new instance of ContentType</p> </div> @@ -230,10 +221,9 @@ A new instance of ContentType <td> <pre class="code"><span class="info file"># File 'lib/axlsx/content_type/content_type.rb', line 8</span> -<span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span> - <span class='super super kw'>super</span> <span class='lbrack token'>[</span><span class='Override constant id'>Override</span><span class='comma token'>,</span> <span class='Default constant id'>Default</span><span class='rbrack token'>]</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id initialize'>initialize</span> + <span class='kw'>super</span> <span class='lbracket'>[</span><span class='const'>Override</span><span class='comma'>,</span> <span class='const'>Default</span><span class='rbracket'>]</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -265,9 +255,8 @@ A new instance of ContentType </p><div class="docstring"> <div class="discussion"> - <p> -Generates the xml document for [Content_Types].xml -</p> + +<p>Generates the xml document for [Content_Types].xml</p> </div> @@ -285,9 +274,8 @@ Generates the xml document for [Content_Types].xml — - <div class='inline'><p> -The document as a string. -</p> + <div class='inline'> +<p>The document as a string.</p> </div> </li> @@ -312,15 +300,14 @@ The document as a string. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/content_type/content_type.rb', line 14</span> -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='rparen token'>)</span> - <span class='builder identifier id'>builder</span> <span class='assign token'>=</span> <span class='Nokogiri constant id'>Nokogiri</span><span class='colon2 op'>::</span><span class='XML constant id'>XML</span><span class='colon2 op'>::</span><span class='Builder constant id'>Builder</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='symbol val'>:encoding</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='ENCODING constant id'>ENCODING</span><span class='rparen token'>)</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='xml identifier id'>xml</span><span class='bitor op'>|</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='Types constant id'>Types</span><span class='lparen token'>(</span><span class='symbol val'>:xmlns</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='XML_NS_T constant id'>XML_NS_T</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='each identifier id'>each</span> <span class='lbrace token'>{</span> <span class='bitor op'>|</span><span class='type identifier id'>type</span><span class='bitor op'>|</span> <span class='type identifier id'>type</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> <span class='rbrace token'>}</span> - <span class='rbrace token'>}</span> - <span class='end end kw'>end</span> - <span class='builder identifier id'>builder</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='rparen'>)</span> + <span class='id builder'>builder</span> <span class='op'>=</span> <span class='const'>Nokogiri</span><span class='op'>::</span><span class='const'>XML</span><span class='op'>::</span><span class='const'>Builder</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='symbol'>:encoding</span> <span class='op'>=></span> <span class='const'>ENCODING</span><span class='rparen'>)</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id xml'>xml</span><span class='op'>|</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='const'>Types</span><span class='lparen'>(</span><span class='symbol'>:xmlns</span> <span class='op'>=></span> <span class='const'>Axlsx</span><span class='op'>::</span><span class='const'>XML_NS_T</span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='id each'>each</span> <span class='lbrace'>{</span> <span class='op'>|</span><span class='id type'>type</span><span class='op'>|</span> <span class='id type'>type</span><span class='period'>.</span><span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> <span class='rbrace'>}</span> + <span class='rbrace'>}</span> + <span class='kw'>end</span> + <span class='id builder'>builder</span><span class='period'>.</span><span class='id to_xml'>to_xml</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -331,9 +318,9 @@ The document as a string. </div> <div id="footer"> - Generated on Wed Nov 23 22:20:51 2011 by + Generated on Sat Nov 26 13:16:40 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/Core.html b/doc/Axlsx/Core.html index 53b07924..b64268ea 100644 --- a/doc/Axlsx/Core.html +++ b/doc/Axlsx/Core.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::Core - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -97,15 +97,13 @@ <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -Packages manage their own core object. -</p> + <div class='inline'> +<p>Packages manage their own core object.</p> </div> </div> -<p> -The core object for the package. -</p> + +<p>The core object for the package.</p> </div> @@ -144,9 +142,8 @@ The core object for the package. - <span class="summary_desc"><div class='inline'><p> -The author of the document. -</p> + <span class="summary_desc"><div class='inline'> +<p>The author of the document.</p> </div></span> </li> @@ -183,9 +180,8 @@ The author of the document. - <span class="summary_desc"><div class='inline'><p> -Creates a new Core object. -</p> + <span class="summary_desc"><div class='inline'> +<p>Creates a new Core object.</p> </div></span> </li> @@ -207,9 +203,8 @@ Creates a new Core object. - <span class="summary_desc"><div class='inline'><p> -Serializes the core object. -</p> + <span class="summary_desc"><div class='inline'> +<p>Serializes the core object.</p> </div></span> </li> @@ -230,9 +225,8 @@ Serializes the core object. </p><div class="docstring"> <div class="discussion"> - <p> -Creates a new Core object. -</p> + +<p>Creates a new Core object.</p> </div> @@ -253,9 +247,8 @@ Creates a new Core object. — - <div class='inline'><p> -a customizable set of options -</p> + <div class='inline'> +<p>a customizable set of options</p> </div> </li> @@ -294,10 +287,9 @@ a customizable set of options <td> <pre class="code"><span class="info file"># File 'lib/axlsx/doc_props/core.rb', line 12</span> -<span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span><span class='lparen token'>(</span><span class='options identifier id'>options</span><span class='assign token'>=</span><span class='lbrace token'>{</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> - <span class='@creator ivar id'>@creator</span> <span class='assign token'>=</span> <span class='options identifier id'>options</span><span class='lbrack token'>[</span><span class='symbol val'>:creator</span><span class='rbrack token'>]</span> <span class='orop op'>||</span> <span class='string val'>'axlsx'</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id initialize'>initialize</span><span class='lparen'>(</span><span class='id options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span> + <span class='ivar'>@creator</span> <span class='op'>=</span> <span class='id options'>options</span><span class='lbracket'>[</span><span class='symbol'>:creator</span><span class='rbracket'>]</span> <span class='op'>||</span> <span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>axlsx</span><span class='tstring_end'>'</span></span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -320,9 +312,8 @@ a customizable set of options </p><div class="docstring"> <div class="discussion"> - <p> -The author of the document. By default this is ‘axlsx’ -</p> + +<p>The author of the document. By default this is 'axlsx'</p> </div> @@ -356,10 +347,9 @@ The author of the document. By default this is ‘axlsx’ <td> <pre class="code"><span class="info file"># File 'lib/axlsx/doc_props/core.rb', line 8</span> -<span class='def def kw'>def</span> <span class='creator identifier id'>creator</span> - <span class='@creator ivar id'>@creator</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id creator'>creator</span> + <span class='ivar'>@creator</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -381,10 +371,9 @@ The author of the document. By default this is ‘axlsx’ </p><div class="docstring"> <div class="discussion"> - <p> -Serializes the core object. The created dcterms item is set to the current -time when this method is called. -</p> + +<p>Serializes the core object. The created dcterms item is set to the current +time when this method is called.</p> </div> @@ -430,22 +419,21 @@ time when this method is called. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/doc_props/core.rb', line 18</span> -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='rparen token'>)</span> - <span class='builder identifier id'>builder</span> <span class='assign token'>=</span> <span class='Nokogiri constant id'>Nokogiri</span><span class='colon2 op'>::</span><span class='XML constant id'>XML</span><span class='colon2 op'>::</span><span class='Builder constant id'>Builder</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='symbol val'>:encoding</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='ENCODING constant id'>ENCODING</span><span class='rparen token'>)</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='xml identifier id'>xml</span><span class='bitor op'>|</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'cp:coreProperties'</span><span class='comma token'>,</span> - <span class='symbol val'>:"xmlns:cp"</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='CORE_NS constant id'>CORE_NS</span><span class='comma token'>,</span> - <span class='symbol val'>:'xmlns:dc'</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='CORE_NS_DC constant id'>CORE_NS_DC</span><span class='comma token'>,</span> - <span class='symbol val'>:'xmlns:dcmitype'</span><span class='assign token'>=</span><span class='gt op'>></span><span class='CORE_NS_DCMIT constant id'>CORE_NS_DCMIT</span><span class='comma token'>,</span> - <span class='symbol val'>:'xmlns:dcterms'</span><span class='assign token'>=</span><span class='gt op'>></span><span class='CORE_NS_DCT constant id'>CORE_NS_DCT</span><span class='comma token'>,</span> - <span class='symbol val'>:'xmlns:xsi'</span><span class='assign token'>=</span><span class='gt op'>></span><span class='CORE_NS_XSI constant id'>CORE_NS_XSI</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='xml identifier id'>xml</span><span class='lbrack token'>[</span><span class='string val'>'dc'</span><span class='rbrack token'>]</span><span class='dot token'>.</span><span class='creator identifier id'>creator</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='creator identifier id'>creator</span> - <span class='xml identifier id'>xml</span><span class='lbrack token'>[</span><span class='string val'>'dcterms'</span><span class='rbrack token'>]</span><span class='dot token'>.</span><span class='created identifier id'>created</span> <span class='Time constant id'>Time</span><span class='dot token'>.</span><span class='now identifier id'>now</span><span class='dot token'>.</span><span class='strftime identifier id'>strftime</span><span class='lparen token'>(</span><span class='string val'>'%Y-%m-%dT%H:%M:%S'</span><span class='rparen token'>)</span><span class='comma token'>,</span> <span class='symbol val'>:'xsi:type'</span><span class='assign token'>=</span><span class='gt op'>></span><span class='string val'>"dcterms:W3CDTF"</span> - <span class='xml identifier id'>xml</span><span class='lbrack token'>[</span><span class='string val'>'cp'</span><span class='rbrack token'>]</span><span class='dot token'>.</span><span class='revision identifier id'>revision</span> <span class='integer val'>0</span> - <span class='rbrace token'>}</span> - <span class='end end kw'>end</span> - <span class='builder identifier id'>builder</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='rparen'>)</span> + <span class='id builder'>builder</span> <span class='op'>=</span> <span class='const'>Nokogiri</span><span class='op'>::</span><span class='const'>XML</span><span class='op'>::</span><span class='const'>Builder</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='symbol'>:encoding</span> <span class='op'>=></span> <span class='const'>ENCODING</span><span class='rparen'>)</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id xml'>xml</span><span class='op'>|</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>cp:coreProperties</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> + <span class='symbol'>:xmlns:cp</span><span class='tstring_end'>"</span></span> <span class='op'>=></span> <span class='const'>CORE_NS</span><span class='comma'>,</span> + <span class='symbol'>:xmlns:dc</span><span class='tstring_end'>'</span></span> <span class='op'>=></span> <span class='const'>CORE_NS_DC</span><span class='comma'>,</span> + <span class='symbol'>:xmlns:dcmitype</span><span class='tstring_end'>'</span></span><span class='op'>=></span><span class='const'>CORE_NS_DCMIT</span><span class='comma'>,</span> + <span class='symbol'>:xmlns:dcterms</span><span class='tstring_end'>'</span></span><span class='op'>=></span><span class='const'>CORE_NS_DCT</span><span class='comma'>,</span> + <span class='symbol'>:xmlns:xsi</span><span class='tstring_end'>'</span></span><span class='op'>=></span><span class='const'>CORE_NS_XSI</span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='id xml'>xml</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>dc</span><span class='tstring_end'>'</span></span><span class='rbracket'>]</span><span class='period'>.</span><span class='id creator'>creator</span> <span class='kw'>self</span><span class='period'>.</span><span class='id creator'>creator</span> + <span class='id xml'>xml</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>dcterms</span><span class='tstring_end'>'</span></span><span class='rbracket'>]</span><span class='period'>.</span><span class='id created'>created</span> <span class='const'>Time</span><span class='period'>.</span><span class='id now'>now</span><span class='period'>.</span><span class='id strftime'>strftime</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>%Y-%m-%dT%H:%M:%S</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span><span class='comma'>,</span> <span class='symbol'>:xsi:type</span><span class='tstring_end'>'</span></span><span class='op'>=></span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>dcterms:W3CDTF</span><span class='tstring_end'>"</span></span> + <span class='id xml'>xml</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>cp</span><span class='tstring_end'>'</span></span><span class='rbracket'>]</span><span class='period'>.</span><span class='id revision'>revision</span> <span class='int'>0</span> + <span class='rbrace'>}</span> + <span class='kw'>end</span> + <span class='id builder'>builder</span><span class='period'>.</span><span class='id to_xml'>to_xml</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -456,9 +444,9 @@ time when this method is called. </div> <div id="footer"> - Generated on Wed Nov 23 22:20:53 2011 by + Generated on Sat Nov 26 13:16:37 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/DataTypeValidator.html b/doc/Axlsx/DataTypeValidator.html index b74915de..51a6b741 100644 --- a/doc/Axlsx/DataTypeValidator.html +++ b/doc/Axlsx/DataTypeValidator.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::DataTypeValidator - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -94,11 +94,10 @@ <h2>Overview</h2><div class="docstring"> <div class="discussion"> - <p> -Validate that the class of the value provided is either an instance or the + +<p>Validate that the class of the value provided is either an instance or the class of the allowed types and that any specified additional validation -returns true. -</p> +returns true.</p> </div> @@ -122,7 +121,7 @@ returns true. <li class="public "> <span class="summary_signature"> - <a href="#validate-class_method" title="validate (class method)">+ (Boolean) <strong>validate</strong>(name, types, v, other = lambda{|v| true }) </a> + <a href="#validate-class_method" title="validate (class method)">+ (Boolean) <strong>validate</strong>(name, types, v, other = lambda{|arg| true }) </a> @@ -135,9 +134,8 @@ returns true. - <span class="summary_desc"><div class='inline'><p> -Perform validation. -</p> + <span class="summary_desc"><div class='inline'> +<p>Perform validation.</p> </div></span> </li> @@ -155,15 +153,14 @@ Perform validation. <div class="method_details first"> <p class="signature first" id="validate-class_method"> - + (<tt>Boolean</tt>) <strong>validate</strong>(name, types, v, other = lambda{|v| true }) + + (<tt>Boolean</tt>) <strong>validate</strong>(name, types, v, other = lambda{|arg| true }) </p><div class="docstring"> <div class="discussion"> - <p> -Perform validation -</p> + +<p>Perform validation</p> </div> @@ -182,9 +179,8 @@ Perform validation — - <div class='inline'><p> -The name of what is being validated. This is included in the error message -</p> + <div class='inline'> +<p>The name of what is being validated. This is included in the error message</p> </div> </li> @@ -199,9 +195,8 @@ The name of what is being validated. This is included in the error message — - <div class='inline'><p> -A single class or array of classes that the value is validated against. -</p> + <div class='inline'> +<p>A single class or array of classes that the value is validated against.</p> </div> </li> @@ -214,13 +209,12 @@ A single class or array of classes that the value is validated against. <span class='type'>(<tt>Block</tt>)</span> - <em class="default">(defaults to: <tt>lambda{|v| true }</tt>)</em> + <em class="default">(defaults to: <tt>lambda{|arg| true }</tt>)</em> — - <div class='inline'><p> -Any block that must evaluate to true for the value to be valid -</p> + <div class='inline'> +<p>Any block that must evaluate to true for the value to be valid</p> </div> </li> @@ -238,9 +232,8 @@ Any block that must evaluate to true for the value to be valid — - <div class='inline'><p> -true if validation succeeds. -</p> + <div class='inline'> +<p>true if validation succeeds.</p> </div> </li> @@ -257,10 +250,9 @@ true if validation succeeds. — - <div class='inline'><p> -Raised if the class of the value provided is not in the specified array of -types or the block passed returns false -</p> + <div class='inline'> +<p>Raised if the class of the value provided is not in the specified array of +types or the block passed returns false</p> </div> </li> @@ -294,17 +286,16 @@ types or the block passed returns false <td> <pre class="code"><span class="info file"># File 'lib/axlsx/util/validators.rb', line 34</span> -<span class='def def kw'>def</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='validate identifier id'>validate</span><span class='lparen token'>(</span><span class='name identifier id'>name</span><span class='comma token'>,</span> <span class='types identifier id'>types</span><span class='comma token'>,</span> <span class='v identifier id'>v</span><span class='comma token'>,</span> <span class='other identifier id'>other</span><span class='assign token'>=</span> <span class='lambda identifier id'>lambda</span><span class='lbrace token'>{</span><span class='bitor op'>|</span><span class='v identifier id'>v</span><span class='bitor op'>|</span> <span class='true true kw'>true</span> <span class='rbrace token'>}</span><span class='rparen token'>)</span> - <span class='types identifier id'>types</span> <span class='assign token'>=</span> <span class='lbrack token'>[</span><span class='types identifier id'>types</span><span class='rbrack token'>]</span> <span class='unless unless_mod kw'>unless</span> <span class='types identifier id'>types</span><span class='dot token'>.</span><span class='is_a? fid id'>is_a?</span> <span class='Array constant id'>Array</span> - <span class='valid_type identifier id'>valid_type</span> <span class='assign token'>=</span> <span class='false false kw'>false</span> - <span class='if if kw'>if</span> <span class='v identifier id'>v</span><span class='dot token'>.</span><span class='class identifier id'>class</span> <span class='eq op'>==</span> <span class='Class constant id'>Class</span> - <span class='types identifier id'>types</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='lbrace token'>{</span> <span class='bitor op'>|</span><span class='t identifier id'>t</span><span class='bitor op'>|</span> <span class='valid_type identifier id'>valid_type</span> <span class='assign token'>=</span> <span class='true true kw'>true</span> <span class='if if_mod kw'>if</span> <span class='v identifier id'>v</span><span class='dot token'>.</span><span class='ancestors identifier id'>ancestors</span><span class='dot token'>.</span><span class='include? fid id'>include?</span><span class='lparen token'>(</span><span class='t identifier id'>t</span><span class='rparen token'>)</span> <span class='rbrace token'>}</span> - <span class='else else kw'>else</span> - <span class='types identifier id'>types</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='lbrace token'>{</span> <span class='bitor op'>|</span><span class='t identifier id'>t</span><span class='bitor op'>|</span> <span class='valid_type identifier id'>valid_type</span> <span class='assign token'>=</span> <span class='true true kw'>true</span> <span class='if if_mod kw'>if</span> <span class='v identifier id'>v</span><span class='dot token'>.</span><span class='is_a? fid id'>is_a?</span><span class='lparen token'>(</span><span class='t identifier id'>t</span><span class='rparen token'>)</span> <span class='rbrace token'>}</span> - <span class='end end kw'>end</span> - <span class='raise identifier id'>raise</span> <span class='ArgumentError constant id'>ArgumentError</span><span class='comma token'>,</span> <span class='lparen token'>(</span><span class='ERR_TYPE constant id'>ERR_TYPE</span> <span class='mod op'>%</span> <span class='lbrack token'>[</span><span class='v identifier id'>v</span><span class='dot token'>.</span><span class='inspect identifier id'>inspect</span><span class='comma token'>,</span> <span class='name identifier id'>name</span><span class='comma token'>,</span> <span class='types identifier id'>types</span><span class='dot token'>.</span><span class='inspect identifier id'>inspect</span><span class='rbrack token'>]</span><span class='rparen token'>)</span> <span class='unless unless_mod kw'>unless</span> <span class='lparen token'>(</span><span class='other identifier id'>other</span><span class='dot token'>.</span><span class='call identifier id'>call</span><span class='lparen token'>(</span><span class='v identifier id'>v</span><span class='rparen token'>)</span> <span class='andop op'>&&</span> <span class='valid_type identifier id'>valid_type</span><span class='rparen token'>)</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id validate'>validate</span><span class='lparen'>(</span><span class='id name'>name</span><span class='comma'>,</span> <span class='id types'>types</span><span class='comma'>,</span> <span class='id v'>v</span><span class='comma'>,</span> <span class='id other'>other</span><span class='op'>=</span> <span class='id lambda'>lambda</span><span class='lbrace'>{</span><span class='op'>|</span><span class='id arg'>arg</span><span class='op'>|</span> <span class='kw'>true</span> <span class='rbrace'>}</span><span class='rparen'>)</span> + <span class='id types'>types</span> <span class='op'>=</span> <span class='lbracket'>[</span><span class='id types'>types</span><span class='rbracket'>]</span> <span class='kw'>unless</span> <span class='id types'>types</span><span class='period'>.</span><span class='id is_a?'>is_a?</span> <span class='const'>Array</span> + <span class='id valid_type'>valid_type</span> <span class='op'>=</span> <span class='kw'>false</span> + <span class='kw'>if</span> <span class='id v'>v</span><span class='period'>.</span><span class='id class'>class</span> <span class='op'>==</span> <span class='const'>Class</span> + <span class='id types'>types</span><span class='period'>.</span><span class='id each'>each</span> <span class='lbrace'>{</span> <span class='op'>|</span><span class='id t'>t</span><span class='op'>|</span> <span class='id valid_type'>valid_type</span> <span class='op'>=</span> <span class='kw'>true</span> <span class='kw'>if</span> <span class='id v'>v</span><span class='period'>.</span><span class='id ancestors'>ancestors</span><span class='period'>.</span><span class='id include?'>include?</span><span class='lparen'>(</span><span class='id t'>t</span><span class='rparen'>)</span> <span class='rbrace'>}</span> + <span class='kw'>else</span> + <span class='id types'>types</span><span class='period'>.</span><span class='id each'>each</span> <span class='lbrace'>{</span> <span class='op'>|</span><span class='id t'>t</span><span class='op'>|</span> <span class='id valid_type'>valid_type</span> <span class='op'>=</span> <span class='kw'>true</span> <span class='kw'>if</span> <span class='id v'>v</span><span class='period'>.</span><span class='id is_a?'>is_a?</span><span class='lparen'>(</span><span class='id t'>t</span><span class='rparen'>)</span> <span class='rbrace'>}</span> + <span class='kw'>end</span> + <span class='id raise'>raise</span> <span class='const'>ArgumentError</span><span class='comma'>,</span> <span class='lparen'>(</span><span class='const'>ERR_TYPE</span> <span class='op'>%</span> <span class='lbracket'>[</span><span class='id v'>v</span><span class='period'>.</span><span class='id inspect'>inspect</span><span class='comma'>,</span> <span class='id name'>name</span><span class='comma'>,</span> <span class='id types'>types</span><span class='period'>.</span><span class='id inspect'>inspect</span><span class='rbracket'>]</span><span class='rparen'>)</span> <span class='kw'>unless</span> <span class='lparen'>(</span><span class='id other'>other</span><span class='period'>.</span><span class='id call'>call</span><span class='lparen'>(</span><span class='id v'>v</span><span class='rparen'>)</span> <span class='op'>&&</span> <span class='id valid_type'>valid_type</span><span class='rparen'>)</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -315,9 +306,9 @@ types or the block passed returns false </div> <div id="footer"> - Generated on Wed Nov 23 22:20:51 2011 by + Generated on Sat Nov 26 13:16:37 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/Default.html b/doc/Axlsx/Default.html index b5f875da..cbba6fdd 100644 --- a/doc/Axlsx/Default.html +++ b/doc/Axlsx/Default.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::Default - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -94,10 +94,9 @@ <h2>Overview</h2><div class="docstring"> <div class="discussion"> - <p> -An default content part. These parts are automatically created by for you -based on the content of your package. -</p> + +<p>An default content part. These parts are automatically created by for you +based on the content of your package.</p> </div> @@ -129,9 +128,8 @@ based on the content of your package. - <span class="summary_desc"><div class='inline'><p> -ContentType The type of content. -</p> + <span class="summary_desc"><div class='inline'> +<p>The type of content.</p> </div></span> </li> @@ -156,9 +154,8 @@ ContentType The type of content. - <span class="summary_desc"><div class='inline'><p> -The extension of the content type. -</p> + <span class="summary_desc"><div class='inline'> +<p>The extension of the content type.</p> </div></span> </li> @@ -195,9 +192,8 @@ The extension of the content type. - <span class="summary_desc"><div class='inline'><p> -Creates a new Default object. -</p> + <span class="summary_desc"><div class='inline'> +<p>Creates a new Default object.</p> </div></span> </li> @@ -219,9 +215,8 @@ Creates a new Default object. - <span class="summary_desc"><div class='inline'><p> -Serializes the object to xml. -</p> + <span class="summary_desc"><div class='inline'> +<p>Serializes the object to xml.</p> </div></span> </li> @@ -242,9 +237,8 @@ Serializes the object to xml. </p><div class="docstring"> <div class="discussion"> - <p> -Creates a new Default object -</p> + +<p>Creates a new Default object</p> </div> @@ -265,9 +259,8 @@ Creates a new Default object — - <div class='inline'><p> -a customizable set of options -</p> + <div class='inline'> +<p>a customizable set of options</p> </div> </li> @@ -312,10 +305,9 @@ a customizable set of options — - <div class='inline'><p> -An argument error is raised if both Extension and ContentType are not -specified. -</p> + <div class='inline'> +<p>An argument error is raised if both Extension and ContentType are not +specified.</p> </div> </li> @@ -328,23 +320,22 @@ specified. <pre class="lines"> -16 17 18 19 20 -21</pre> +21 +22</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/content_type/default.rb', line 16</span> - -<span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span><span class='lparen token'>(</span><span class='options identifier id'>options</span><span class='assign token'>=</span><span class='lbrace token'>{</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> - <span class='raise identifier id'>raise</span> <span class='ArgumentError constant id'>ArgumentError</span><span class='comma token'>,</span> <span class='string val'>"Extension and ContentType are required"</span> <span class='unless unless_mod kw'>unless</span> <span class='options identifier id'>options</span><span class='lbrack token'>[</span><span class='symbol val'>:Extension</span><span class='rbrack token'>]</span> <span class='andop op'>&&</span> <span class='options identifier id'>options</span><span class='lbrack token'>[</span><span class='symbol val'>:ContentType</span><span class='rbrack token'>]</span> - <span class='options identifier id'>options</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='o identifier id'>o</span><span class='bitor op'>|</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='dstring node'>"#{o[0]}="</span><span class='comma token'>,</span> <span class='o identifier id'>o</span><span class='lbrack token'>[</span><span class='integer val'>1</span><span class='rbrack token'>]</span><span class='rparen token'>)</span> <span class='if if_mod kw'>if</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='respond_to? fid id'>respond_to?</span> <span class='dstring node'>"#{o[0]}="</span> - <span class='end end kw'>end</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/content_type/default.rb', line 17</span> + +<span class='kw'>def</span> <span class='id initialize'>initialize</span><span class='lparen'>(</span><span class='id options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span> + <span class='id raise'>raise</span> <span class='const'>ArgumentError</span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Extension and ContentType are required</span><span class='tstring_end'>"</span></span> <span class='kw'>unless</span> <span class='id options'>options</span><span class='lbracket'>[</span><span class='symbol'>:Extension</span><span class='rbracket'>]</span> <span class='op'>&&</span> <span class='id options'>options</span><span class='lbracket'>[</span><span class='symbol'>:ContentType</span><span class='rbracket'>]</span> + <span class='id options'>options</span><span class='period'>.</span><span class='id each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id o'>o</span><span class='op'>|</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span><span class='rbrace'>}</span><span class='tstring_content'>=</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>1</span><span class='rbracket'>]</span><span class='rparen'>)</span> <span class='kw'>if</span> <span class='kw'>self</span><span class='period'>.</span><span class='id respond_to?'>respond_to?</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span><span class='rbrace'>}</span><span class='tstring_content'>=</span><span class='tstring_end'>"</span></span> + <span class='kw'>end</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -367,11 +358,8 @@ specified. </p><div class="docstring"> <div class="discussion"> - <p> -ContentType The type of content. TABLE_CT, WORKBOOK_CT, APP_CT, RELS_CT, -STYLES_CT, XML_CT, WORKSHEET_CT, SHARED_STRINGS_CT, CORE_CT, CHART_CT, -DRAWING_CT are allowed -</p> + +<p>The type of content.</p> </div> @@ -388,14 +376,6 @@ DRAWING_CT are allowed - — - <div class='inline'><p> -ContentType The type of content. TABLE_CT, WORKBOOK_CT, APP_CT, RELS_CT, -STYLES_CT, XML_CT, WORKSHEET_CT, SHARED_STRINGS_CT, CORE_CT, CHART_CT, -DRAWING_CT are allowed -</p> -</div> - </li> </ul> @@ -406,17 +386,16 @@ DRAWING_CT are allowed <pre class="lines"> -10 11 -12</pre> +12 +13</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/content_type/default.rb', line 10</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/content_type/default.rb', line 11</span> -<span class='def def kw'>def</span> <span class='ContentType constant id'>ContentType</span> - <span class='@ContentType ivar id'>@ContentType</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='const'>ContentType</span> + <span class='ivar'>@ContentType</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -434,9 +413,8 @@ DRAWING_CT are allowed </p><div class="docstring"> <div class="discussion"> - <p> -The extension of the content type. -</p> + +<p>The extension of the content type.</p> </div> @@ -470,10 +448,9 @@ The extension of the content type. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/content_type/default.rb', line 7</span> -<span class='def def kw'>def</span> <span class='Extension constant id'>Extension</span> - <span class='@Extension ivar id'>@Extension</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='const'>Extension</span> + <span class='ivar'>@Extension</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -495,9 +472,8 @@ The extension of the content type. </p><div class="docstring"> <div class="discussion"> - <p> -Serializes the object to xml -</p> + +<p>Serializes the object to xml</p> </div> @@ -516,9 +492,8 @@ Serializes the object to xml — - <div class='inline'><p> -The document builder instance this objects xml will be added to. -</p> + <div class='inline'> +<p>The document builder instance this objects xml will be added to.</p> </div> </li> @@ -545,17 +520,16 @@ The document builder instance this objects xml will be added to. <pre class="lines"> -28 -29 -30</pre> +33 +34 +35</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/content_type/default.rb', line 28</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/content_type/default.rb', line 33</span> -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='Default constant id'>Default</span><span class='lparen token'>(</span><span class='self self kw'>self</span><span class='dot token'>.</span><span class='instance_values identifier id'>instance_values</span><span class='rparen token'>)</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='const'>Default</span><span class='lparen'>(</span><span class='kw'>self</span><span class='period'>.</span><span class='id instance_values'>instance_values</span><span class='rparen'>)</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -566,9 +540,9 @@ The document builder instance this objects xml will be added to. </div> <div id="footer"> - Generated on Wed Nov 23 22:20:52 2011 by + Generated on Sat Nov 26 13:16:38 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/Drawing.html b/doc/Axlsx/Drawing.html index 89318def..80d5ca01 100644 --- a/doc/Axlsx/Drawing.html +++ b/doc/Axlsx/Drawing.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::Drawing - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -97,19 +97,17 @@ <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -The recommended way to manage drawings is to use the Worksheet.add_chart -method. -</p> + <div class='inline'> +<p>The recommended way to manage drawings is to use the Worksheet.add_chart +method.</p> </div> </div> -<p> -A Drawing is a canvas for charts. Each worksheet has a single drawing that + +<p>A Drawing is a canvas for charts. Each worksheet has a single drawing that manages anchors. The anchors reference the charts via graphical frames. This is not a trivial relationship so please do follow the advice in the -note. see README for an example of how to create a chart. -</p> +note. see README for an example of how to create a chart.</p> </div> @@ -150,10 +148,9 @@ note. see README for an example of how to create a chart. - <span class="summary_desc"><div class='inline'><p> -A collection of anchors for this drawing only TwoCellAnchors are supported -in this version. -</p> + <span class="summary_desc"><div class='inline'> +<p>A collection of anchors for this drawing only TwoCellAnchors are supported +in this version.</p> </div></span> </li> @@ -162,7 +159,7 @@ in this version. <li class="public "> <span class="summary_signature"> - <a href="#charts-instance_method" title="#charts (instance method)">- (Array) <strong>charts</strong> </a> + <a href="#worksheet-instance_method" title="#worksheet (instance method)">- (Worksheet) <strong>worksheet</strong> </a> @@ -178,163 +175,152 @@ in this version. - <span class="summary_desc"><div class='inline'><p> -An array of charts that are associated with this drawing’s anchors. -</p> + <span class="summary_desc"><div class='inline'> +<p>The worksheet that owns the drawing.</p> </div></span> </li> - <li class="public "> + </ul> + + + + + + <h2> + Instance Method Summary + <small>(<a href="#" class="summary_toggle">collapse</a>)</small> + </h2> + + <ul class="summary"> + + <li class="public "> <span class="summary_signature"> - <a href="#images-instance_method" title="#images (instance method)">- (Array) <strong>images</strong> </a> + <a href="#add_chart-instance_method" title="#add_chart (instance method)">- (Object) <strong>add_chart</strong>(chart_type, options = {}) </a> </span> - <span class="note title readonly">readonly</span> - - - <span class="summary_desc"><div class='inline'><p> -An array of image objects that are associated with this drawing’s -anchors. -</p> + <span class="summary_desc"><div class='inline'> +<p>Adds a chart to the drawing.</p> </div></span> </li> - - <li class="public "> + + <li class="public "> <span class="summary_signature"> - <a href="#index-instance_method" title="#index (instance method)">- (Integer) <strong>index</strong> </a> + <a href="#add_image-instance_method" title="#add_image (instance method)">- (Object) <strong>add_image</strong>(options = {}) </a> </span> - <span class="note title readonly">readonly</span> - - - <span class="summary_desc"><div class='inline'><p> -The index of this drawing in the owning workbooks’s drawings -collection. -</p> + <span class="summary_desc"><div class='inline'> +<p>Adds an image to the chart.</p> </div></span> </li> - - <li class="public "> + + <li class="public "> <span class="summary_signature"> - <a href="#pn-instance_method" title="#pn (instance method)">- (String) <strong>pn</strong> </a> + <a href="#charts-instance_method" title="#charts (instance method)">- (Array) <strong>charts</strong> </a> </span> - <span class="note title readonly">readonly</span> - - - <span class="summary_desc"><div class='inline'><p> -The part name for this drawing. -</p> + <span class="summary_desc"><div class='inline'> +<p>An array of charts that are associated with this drawing's anchors.</p> </div></span> </li> - - <li class="public "> + + <li class="public "> <span class="summary_signature"> - <a href="#relationships-instance_method" title="#relationships (instance method)">- (Relationships) <strong>relationships</strong> </a> + <a href="#images-instance_method" title="#images (instance method)">- (Array) <strong>images</strong> </a> </span> - <span class="note title readonly">readonly</span> - - - <span class="summary_desc"><div class='inline'><p> -The drawing’s relationships. -</p> + <span class="summary_desc"><div class='inline'> +<p>An array of image objects that are associated with this drawing's anchors.</p> </div></span> </li> - - <li class="public "> + + <li class="public "> <span class="summary_signature"> - <a href="#rels_pn-instance_method" title="#rels_pn (instance method)">- (String) <strong>rels_pn</strong> </a> + <a href="#index-instance_method" title="#index (instance method)">- (Integer) <strong>index</strong> </a> </span> - <span class="note title readonly">readonly</span> - - - <span class="summary_desc"><div class='inline'><p> -The relational part name for this drawing. -</p> + <span class="summary_desc"><div class='inline'> +<p>The index of this drawing in the owning workbooks's drawings collection.</p> </div></span> </li> - - <li class="public "> + + <li class="public "> <span class="summary_signature"> - <a href="#rId-instance_method" title="#rId (instance method)">- (String) <strong>rId</strong> </a> + <a href="#initialize-instance_method" title="#initialize (instance method)">- (Drawing) <strong>initialize</strong>(worksheet) </a> </span> + <span class="note title constructor">constructor</span> - <span class="note title readonly">readonly</span> - @@ -342,58 +328,40 @@ The relational part name for this drawing. - <span class="summary_desc"><div class='inline'><p> -The relation reference id for this drawing. -</p> + <span class="summary_desc"><div class='inline'> +<p>Creates a new Drawing object.</p> </div></span> </li> - - <li class="public "> + + <li class="public "> <span class="summary_signature"> - <a href="#worksheet-instance_method" title="#worksheet (instance method)">- (Worksheet) <strong>worksheet</strong> </a> + <a href="#pn-instance_method" title="#pn (instance method)">- (String) <strong>pn</strong> </a> </span> - <span class="note title readonly">readonly</span> - - - <span class="summary_desc"><div class='inline'><p> -The worksheet that owns the drawing. -</p> + <span class="summary_desc"><div class='inline'> +<p>The part name for this drawing.</p> </div></span> </li> - - </ul> - - - - - - <h2> - Instance Method Summary - <small>(<a href="#" class="summary_toggle">collapse</a>)</small> - </h2> - - <ul class="summary"> <li class="public "> <span class="summary_signature"> - <a href="#add_chart-instance_method" title="#add_chart (instance method)">- (Object) <strong>add_chart</strong>(chart_type, options = {}) </a> + <a href="#relationships-instance_method" title="#relationships (instance method)">- (Relationships) <strong>relationships</strong> </a> @@ -406,9 +374,8 @@ The worksheet that owns the drawing. - <span class="summary_desc"><div class='inline'><p> -Adds a chart to the drawing. -</p> + <span class="summary_desc"><div class='inline'> +<p>The drawing's relationships.</p> </div></span> </li> @@ -417,7 +384,7 @@ Adds a chart to the drawing. <li class="public "> <span class="summary_signature"> - <a href="#add_image-instance_method" title="#add_image (instance method)">- (Object) <strong>add_image</strong>(options = {}) </a> + <a href="#rels_pn-instance_method" title="#rels_pn (instance method)">- (String) <strong>rels_pn</strong> </a> @@ -430,9 +397,8 @@ Adds a chart to the drawing. - <span class="summary_desc"><div class='inline'><p> -Adds an image to the chart. -</p> + <span class="summary_desc"><div class='inline'> +<p>The relational part name for this drawing.</p> </div></span> </li> @@ -441,14 +407,12 @@ Adds an image to the chart. <li class="public "> <span class="summary_signature"> - <a href="#initialize-instance_method" title="#initialize (instance method)">- (Drawing) <strong>initialize</strong>(worksheet) </a> + <a href="#rId-instance_method" title="#rId (instance method)">- (String) <strong>rId</strong> </a> </span> - <span class="note title constructor">constructor</span> - @@ -456,9 +420,8 @@ Adds an image to the chart. - <span class="summary_desc"><div class='inline'><p> -Creates a new Drawing object. -</p> + <span class="summary_desc"><div class='inline'> +<p>The relation reference id for this drawing.</p> </div></span> </li> @@ -480,9 +443,8 @@ Creates a new Drawing object. - <span class="summary_desc"><div class='inline'><p> -Serializes the drawing. -</p> + <span class="summary_desc"><div class='inline'> +<p>Serializes the drawing.</p> </div></span> </li> @@ -503,9 +465,8 @@ Serializes the drawing. </p><div class="docstring"> <div class="discussion"> - <p> -Creates a new Drawing object -</p> + +<p>Creates a new Drawing object</p> </div> @@ -524,9 +485,8 @@ Creates a new Drawing object — - <div class='inline'><p> -The worksheet that owns this drawing -</p> + <div class='inline'> +<p>The worksheet that owns this drawing</p> </div> </li> @@ -540,23 +500,22 @@ The worksheet that owns this drawing <pre class="lines"> -80 -81 -82 -83 -84 -85</pre> +52 +53 +54 +55 +56 +57</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/drawing.rb', line 80</span> - -<span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span><span class='lparen token'>(</span><span class='worksheet identifier id'>worksheet</span><span class='rparen token'>)</span> - <span class='DataTypeValidator constant id'>DataTypeValidator</span><span class='dot token'>.</span><span class='validate identifier id'>validate</span> <span class='string val'>"Drawing.worksheet"</span><span class='comma token'>,</span> <span class='Worksheet constant id'>Worksheet</span><span class='comma token'>,</span> <span class='worksheet identifier id'>worksheet</span> - <span class='@worksheet ivar id'>@worksheet</span> <span class='assign token'>=</span> <span class='worksheet identifier id'>worksheet</span> - <span class='@worksheet ivar id'>@worksheet</span><span class='dot token'>.</span><span class='workbook identifier id'>workbook</span><span class='dot token'>.</span><span class='drawings identifier id'>drawings</span> <span class='lshft op'><<</span> <span class='self self kw'>self</span> - <span class='@anchors ivar id'>@anchors</span> <span class='assign token'>=</span> <span class='SimpleTypedList constant id'>SimpleTypedList</span><span class='dot token'>.</span><span class='new identifier id'>new</span> <span class='lbrack token'>[</span><span class='TwoCellAnchor constant id'>TwoCellAnchor</span><span class='comma token'>,</span> <span class='OneCellAnchor constant id'>OneCellAnchor</span><span class='rbrack token'>]</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/drawing.rb', line 52</span> + +<span class='kw'>def</span> <span class='id initialize'>initialize</span><span class='lparen'>(</span><span class='id worksheet'>worksheet</span><span class='rparen'>)</span> + <span class='const'>DataTypeValidator</span><span class='period'>.</span><span class='id validate'>validate</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Drawing.worksheet</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='const'>Worksheet</span><span class='comma'>,</span> <span class='id worksheet'>worksheet</span> + <span class='ivar'>@worksheet</span> <span class='op'>=</span> <span class='id worksheet'>worksheet</span> + <span class='ivar'>@worksheet</span><span class='period'>.</span><span class='id workbook'>workbook</span><span class='period'>.</span><span class='id drawings'>drawings</span> <span class='op'><<</span> <span class='kw'>self</span> + <span class='ivar'>@anchors</span> <span class='op'>=</span> <span class='const'>SimpleTypedList</span><span class='period'>.</span><span class='id new'>new</span> <span class='lbracket'>[</span><span class='const'>TwoCellAnchor</span><span class='comma'>,</span> <span class='const'>OneCellAnchor</span><span class='rbracket'>]</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -579,10 +538,9 @@ The worksheet that owns this drawing </p><div class="docstring"> <div class="discussion"> - <p> -A collection of anchors for this drawing only TwoCellAnchors are supported -in this version -</p> + +<p>A collection of anchors for this drawing only TwoCellAnchors are supported +in this version</p> </div> @@ -616,10 +574,9 @@ in this version <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/drawing.rb', line 48</span> -<span class='def def kw'>def</span> <span class='anchors identifier id'>anchors</span> - <span class='@anchors ivar id'>@anchors</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id anchors'>anchors</span> + <span class='ivar'>@anchors</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -627,19 +584,18 @@ in this version <span id=""></span> - <span id="charts-instance_method"></span> + <span id="worksheet-instance_method"></span> <div class="method_details "> - <p class="signature " id="charts-instance_method"> + <p class="signature " id="worksheet-instance_method"> - - (<tt>Array</tt>) <strong>charts</strong> <span class="extras">(readonly)</span> + - (<tt><span class='object_link'><a href="Worksheet.html" title="Axlsx::Worksheet (class)">Worksheet</a></span></tt>) <strong>worksheet</strong> <span class="extras">(readonly)</span> </p><div class="docstring"> <div class="discussion"> - <p> -An array of charts that are associated with this drawing’s anchors -</p> + +<p>The worksheet that owns the drawing</p> </div> @@ -652,7 +608,7 @@ An array of charts that are associated with this drawing’s anchors <li> - <span class='type'>(<tt>Array</tt>)</span> + <span class='type'>(<tt><span class='object_link'><a href="Worksheet.html" title="Axlsx::Worksheet (class)">Worksheet</a></span></tt>)</span> @@ -666,59 +622,61 @@ An array of charts that are associated with this drawing’s anchors <pre class="lines"> -52 -53 -54 -55</pre> +43 +44 +45</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/drawing.rb', line 52</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/drawing.rb', line 43</span> -<span class='def def kw'>def</span> <span class='charts identifier id'>charts</span> - <span class='charts identifier id'>charts</span> <span class='assign token'>=</span> <span class='@anchors ivar id'>@anchors</span><span class='dot token'>.</span><span class='select identifier id'>select</span> <span class='lbrace token'>{</span> <span class='bitor op'>|</span><span class='a identifier id'>a</span><span class='bitor op'>|</span> <span class='a identifier id'>a</span><span class='dot token'>.</span><span class='object identifier id'>object</span><span class='dot token'>.</span><span class='is_a? fid id'>is_a?</span><span class='lparen token'>(</span><span class='GraphicFrame constant id'>GraphicFrame</span><span class='rparen token'>)</span> <span class='rbrace token'>}</span> - <span class='charts identifier id'>charts</span><span class='dot token'>.</span><span class='map identifier id'>map</span> <span class='lbrace token'>{</span> <span class='bitor op'>|</span><span class='a identifier id'>a</span><span class='bitor op'>|</span> <span class='a identifier id'>a</span><span class='dot token'>.</span><span class='object identifier id'>object</span><span class='dot token'>.</span><span class='chart identifier id'>chart</span> <span class='rbrace token'>}</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id worksheet'>worksheet</span> + <span class='ivar'>@worksheet</span> +<span class='kw'>end</span></pre> </td> </tr> </table> </div> - - <span id=""></span> - <span id="images-instance_method"></span> - <div class="method_details "> - <p class="signature " id="images-instance_method"> + </div> + + + <div id="instance_method_details" class="method_details_list"> + <h2>Instance Method Details</h2> + + + <div class="method_details first"> + <p class="signature first" id="add_chart-instance_method"> - - (<tt>Array</tt>) <strong>images</strong> <span class="extras">(readonly)</span> + - (<tt>Object</tt>) <strong>add_chart</strong>(chart_type, options = {}) </p><div class="docstring"> <div class="discussion"> - <p> -An array of image objects that are associated with this drawing’s -anchors -</p> + + <div class="note notetag"> + <strong>Note:</strong> + <div class='inline'> +<p>The recommended way to manage charts is to use Worksheet.add_chart. Please +refer to that method for documentation.</p> +</div> + </div> + + +<p>Adds a chart to the drawing.</p> </div> </div> <div class="tags"> -<h3>Returns:</h3> -<ul class="return"> - - <li> - - - <span class='type'>(<tt>Array</tt>)</span> - - - - </li> - -</ul> + + <h3>See Also:</h3> + <ul class="see"> + + <li><span class='object_link'><a href="Worksheet.html#add_chart-instance_method" title="Axlsx::Worksheet#add_chart (method)">Worksheet#add_chart</a></span></li> + + </ul> </div><table class="source_code"> <tr> @@ -726,59 +684,56 @@ anchors <pre class="lines"> -56 -57 -58 -59</pre> +70 +71 +72 +73</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/drawing.rb', line 56</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/drawing.rb', line 70</span> -<span class='def def kw'>def</span> <span class='images identifier id'>images</span> - <span class='images identifier id'>images</span> <span class='assign token'>=</span> <span class='@anchors ivar id'>@anchors</span><span class='dot token'>.</span><span class='select identifier id'>select</span> <span class='lbrace token'>{</span> <span class='bitor op'>|</span><span class='a identifier id'>a</span><span class='bitor op'>|</span> <span class='a identifier id'>a</span><span class='dot token'>.</span><span class='object identifier id'>object</span><span class='dot token'>.</span><span class='is_a? fid id'>is_a?</span><span class='lparen token'>(</span><span class='Pic constant id'>Pic</span><span class='rparen token'>)</span> <span class='rbrace token'>}</span> - <span class='images identifier id'>images</span><span class='dot token'>.</span><span class='map identifier id'>map</span> <span class='lbrace token'>{</span> <span class='bitor op'>|</span><span class='a identifier id'>a</span><span class='bitor op'>|</span> <span class='a identifier id'>a</span><span class='dot token'>.</span><span class='object identifier id'>object</span> <span class='rbrace token'>}</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id add_chart'>add_chart</span><span class='lparen'>(</span><span class='id chart_type'>chart_type</span><span class='comma'>,</span> <span class='id options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span> + <span class='const'>TwoCellAnchor</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='kw'>self</span><span class='comma'>,</span> <span class='id options'>options</span><span class='rparen'>)</span> + <span class='ivar'>@anchors</span><span class='period'>.</span><span class='id last'>last</span><span class='period'>.</span><span class='id add_chart'>add_chart</span><span class='lparen'>(</span><span class='id chart_type'>chart_type</span><span class='comma'>,</span> <span class='id options'>options</span><span class='rparen'>)</span> +<span class='kw'>end</span></pre> </td> </tr> </table> </div> - - <span id=""></span> - <span id="index-instance_method"></span> <div class="method_details "> - <p class="signature " id="index-instance_method"> + <p class="signature " id="add_image-instance_method"> - - (<tt>Integer</tt>) <strong>index</strong> <span class="extras">(readonly)</span> + - (<tt>Object</tt>) <strong>add_image</strong>(options = {}) </p><div class="docstring"> <div class="discussion"> - <p> -The index of this drawing in the owning workbooks’s drawings -collection. -</p> + + <div class="note notetag"> + <strong>Note:</strong> + <div class='inline'> +<p>The recommended way to manage images is to use Worksheet.add_image. Please +refer to that method for documentation.</p> +</div> + </div> + + +<p>Adds an image to the chart</p> </div> </div> <div class="tags"> -<h3>Returns:</h3> -<ul class="return"> - - <li> - - - <span class='type'>(<tt>Integer</tt>)</span> - - - - </li> - -</ul> + + <h3>See Also:</h3> + <ul class="see"> + + <li><span class='object_link'><a href="Worksheet.html#add_image-instance_method" title="Axlsx::Worksheet#add_image (method)">Worksheet#add_image</a></span></li> + + </ul> </div><table class="source_code"> <tr> @@ -786,37 +741,34 @@ collection. <pre class="lines"> -60 -61 -62</pre> +62 +63 +64 +65</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/drawing.rb', line 60</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/drawing.rb', line 62</span> -<span class='def def kw'>def</span> <span class='index identifier id'>index</span> - <span class='@worksheet ivar id'>@worksheet</span><span class='dot token'>.</span><span class='workbook identifier id'>workbook</span><span class='dot token'>.</span><span class='drawings identifier id'>drawings</span><span class='dot token'>.</span><span class='index identifier id'>index</span><span class='lparen token'>(</span><span class='self self kw'>self</span><span class='rparen token'>)</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id add_image'>add_image</span><span class='lparen'>(</span><span class='id options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span> + <span class='const'>OneCellAnchor</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='kw'>self</span><span class='comma'>,</span> <span class='id options'>options</span><span class='rparen'>)</span> + <span class='ivar'>@anchors</span><span class='period'>.</span><span class='id last'>last</span><span class='period'>.</span><span class='id object'>object</span> +<span class='kw'>end</span></pre> </td> </tr> </table> </div> - - <span id=""></span> - <span id="pn-instance_method"></span> <div class="method_details "> - <p class="signature " id="pn-instance_method"> + <p class="signature " id="charts-instance_method"> - - (<tt>String</tt>) <strong>pn</strong> <span class="extras">(readonly)</span> + - (<tt>Array</tt>) <strong>charts</strong> </p><div class="docstring"> <div class="discussion"> - <p> -The part name for this drawing -</p> + +<p>An array of charts that are associated with this drawing's anchors</p> </div> @@ -829,7 +781,7 @@ The part name for this drawing <li> - <span class='type'>(<tt>String</tt>)</span> + <span class='type'>(<tt>Array</tt>)</span> @@ -843,37 +795,34 @@ The part name for this drawing <pre class="lines"> -68 -69 -70</pre> +77 +78 +79 +80</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/drawing.rb', line 68</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/drawing.rb', line 77</span> -<span class='def def kw'>def</span> <span class='pn identifier id'>pn</span> - <span class='dstring node'>"#{DRAWING_PN % (index+1)}"</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id charts'>charts</span> + <span class='id charts'>charts</span> <span class='op'>=</span> <span class='ivar'>@anchors</span><span class='period'>.</span><span class='id select'>select</span> <span class='lbrace'>{</span> <span class='op'>|</span><span class='id a'>a</span><span class='op'>|</span> <span class='id a'>a</span><span class='period'>.</span><span class='id object'>object</span><span class='period'>.</span><span class='id is_a?'>is_a?</span><span class='lparen'>(</span><span class='const'>GraphicFrame</span><span class='rparen'>)</span> <span class='rbrace'>}</span> + <span class='id charts'>charts</span><span class='period'>.</span><span class='id map'>map</span> <span class='lbrace'>{</span> <span class='op'>|</span><span class='id a'>a</span><span class='op'>|</span> <span class='id a'>a</span><span class='period'>.</span><span class='id object'>object</span><span class='period'>.</span><span class='id chart'>chart</span> <span class='rbrace'>}</span> +<span class='kw'>end</span></pre> </td> </tr> </table> </div> - - <span id=""></span> - <span id="relationships-instance_method"></span> <div class="method_details "> - <p class="signature " id="relationships-instance_method"> + <p class="signature " id="images-instance_method"> - - (<tt><span class='object_link'><a href="Relationships.html" title="Axlsx::Relationships (class)">Relationships</a></span></tt>) <strong>relationships</strong> <span class="extras">(readonly)</span> + - (<tt>Array</tt>) <strong>images</strong> </p><div class="docstring"> <div class="discussion"> - <p> -The drawing’s relationships. -</p> + +<p>An array of image objects that are associated with this drawing's anchors</p> </div> @@ -886,7 +835,7 @@ The drawing’s relationships. <li> - <span class='type'>(<tt><span class='object_link'><a href="Relationships.html" title="Axlsx::Relationships (class)">Relationships</a></span></tt>)</span> + <span class='type'>(<tt>Array</tt>)</span> @@ -900,51 +849,34 @@ The drawing’s relationships. <pre class="lines"> -76 -77 -78 -79 -80 -81 -82 -83 84 -85</pre> +85 +86 +87</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/drawing.rb', line 76</span> - -<span class='def def kw'>def</span> <span class='relationships identifier id'>relationships</span> - <span class='r identifier id'>r</span> <span class='assign token'>=</span> <span class='Relationships constant id'>Relationships</span><span class='dot token'>.</span><span class='new identifier id'>new</span> - <span class='charts identifier id'>charts</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='chart identifier id'>chart</span><span class='bitor op'>|</span> - <span class='r identifier id'>r</span> <span class='lshft op'><<</span> <span class='Relationship constant id'>Relationship</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='CHART_R constant id'>CHART_R</span><span class='comma token'>,</span> <span class='dstring node'>"../#{chart.pn}"</span><span class='rparen token'>)</span> - <span class='end end kw'>end</span> - <span class='images identifier id'>images</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='image identifier id'>image</span><span class='bitor op'>|</span> - <span class='r identifier id'>r</span> <span class='lshft op'><<</span> <span class='Relationship constant id'>Relationship</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='IMAGE_R constant id'>IMAGE_R</span><span class='comma token'>,</span> <span class='dstring node'>"../#{image.pn}"</span><span class='rparen token'>)</span> - <span class='end end kw'>end</span> - <span class='r identifier id'>r</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/drawing.rb', line 84</span> + +<span class='kw'>def</span> <span class='id images'>images</span> + <span class='id images'>images</span> <span class='op'>=</span> <span class='ivar'>@anchors</span><span class='period'>.</span><span class='id select'>select</span> <span class='lbrace'>{</span> <span class='op'>|</span><span class='id a'>a</span><span class='op'>|</span> <span class='id a'>a</span><span class='period'>.</span><span class='id object'>object</span><span class='period'>.</span><span class='id is_a?'>is_a?</span><span class='lparen'>(</span><span class='const'>Pic</span><span class='rparen'>)</span> <span class='rbrace'>}</span> + <span class='id images'>images</span><span class='period'>.</span><span class='id map'>map</span> <span class='lbrace'>{</span> <span class='op'>|</span><span class='id a'>a</span><span class='op'>|</span> <span class='id a'>a</span><span class='period'>.</span><span class='id object'>object</span> <span class='rbrace'>}</span> +<span class='kw'>end</span></pre> </td> </tr> </table> </div> - - <span id=""></span> - <span id="rels_pn-instance_method"></span> <div class="method_details "> - <p class="signature " id="rels_pn-instance_method"> + <p class="signature " id="index-instance_method"> - - (<tt>String</tt>) <strong>rels_pn</strong> <span class="extras">(readonly)</span> + - (<tt>Integer</tt>) <strong>index</strong> </p><div class="docstring"> <div class="discussion"> - <p> -The relational part name for this drawing -</p> + +<p>The index of this drawing in the owning workbooks's drawings collection.</p> </div> @@ -957,7 +889,7 @@ The relational part name for this drawing <li> - <span class='type'>(<tt>String</tt>)</span> + <span class='type'>(<tt>Integer</tt>)</span> @@ -971,37 +903,32 @@ The relational part name for this drawing <pre class="lines"> -72 -73 -74</pre> +91 +92 +93</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/drawing.rb', line 72</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/drawing.rb', line 91</span> -<span class='def def kw'>def</span> <span class='rels_pn identifier id'>rels_pn</span> - <span class='dstring node'>"#{DRAWING_RELS_PN % (index+1)}"</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id index'>index</span> + <span class='ivar'>@worksheet</span><span class='period'>.</span><span class='id workbook'>workbook</span><span class='period'>.</span><span class='id drawings'>drawings</span><span class='period'>.</span><span class='id index'>index</span><span class='lparen'>(</span><span class='kw'>self</span><span class='rparen'>)</span> +<span class='kw'>end</span></pre> </td> </tr> </table> </div> - - <span id=""></span> - <span id="rId-instance_method"></span> <div class="method_details "> - <p class="signature " id="rId-instance_method"> + <p class="signature " id="pn-instance_method"> - - (<tt>String</tt>) <strong>rId</strong> <span class="extras">(readonly)</span> + - (<tt>String</tt>) <strong>pn</strong> </p><div class="docstring"> <div class="discussion"> - <p> -The relation reference id for this drawing -</p> + +<p>The part name for this drawing</p> </div> @@ -1028,37 +955,32 @@ The relation reference id for this drawing <pre class="lines"> -64 -65 -66</pre> +103 +104 +105</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/drawing.rb', line 64</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/drawing.rb', line 103</span> -<span class='def def kw'>def</span> <span class='rId identifier id'>rId</span> - <span class='dstring node'>"rId#{index+1}"</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id pn'>pn</span> + <span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='const'>DRAWING_PN</span> <span class='op'>%</span> <span class='lparen'>(</span><span class='id index'>index</span><span class='op'>+</span><span class='int'>1</span><span class='rparen'>)</span><span class='rbrace'>}</span><span class='tstring_end'>"</span></span> +<span class='kw'>end</span></pre> </td> </tr> </table> </div> - - <span id=""></span> - <span id="worksheet-instance_method"></span> <div class="method_details "> - <p class="signature " id="worksheet-instance_method"> + <p class="signature " id="relationships-instance_method"> - - (<tt><span class='object_link'><a href="Worksheet.html" title="Axlsx::Worksheet (class)">Worksheet</a></span></tt>) <strong>worksheet</strong> <span class="extras">(readonly)</span> + - (<tt><span class='object_link'><a href="Relationships.html" title="Axlsx::Relationships (class)">Relationships</a></span></tt>) <strong>relationships</strong> </p><div class="docstring"> <div class="discussion"> - <p> -The worksheet that owns the drawing -</p> + +<p>The drawing's relationships.</p> </div> @@ -1071,7 +993,7 @@ The worksheet that owns the drawing <li> - <span class='type'>(<tt><span class='object_link'><a href="Worksheet.html" title="Axlsx::Worksheet (class)">Worksheet</a></span></tt>)</span> + <span class='type'>(<tt><span class='object_link'><a href="Relationships.html" title="Axlsx::Relationships (class)">Relationships</a></span></tt>)</span> @@ -1085,64 +1007,65 @@ The worksheet that owns the drawing <pre class="lines"> -43 -44 -45</pre> +115 +116 +117 +118 +119 +120 +121 +122 +123 +124</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/drawing.rb', line 43</span> - -<span class='def def kw'>def</span> <span class='worksheet identifier id'>worksheet</span> - <span class='@worksheet ivar id'>@worksheet</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/drawing.rb', line 115</span> + +<span class='kw'>def</span> <span class='id relationships'>relationships</span> + <span class='id r'>r</span> <span class='op'>=</span> <span class='const'>Relationships</span><span class='period'>.</span><span class='id new'>new</span> + <span class='id charts'>charts</span><span class='period'>.</span><span class='id each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id chart'>chart</span><span class='op'>|</span> + <span class='id r'>r</span> <span class='op'><<</span> <span class='const'>Relationship</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='const'>CHART_R</span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>../</span><span class='embexpr_beg'>#{</span><span class='id chart'>chart</span><span class='period'>.</span><span class='id pn'>pn</span><span class='rbrace'>}</span><span class='tstring_end'>"</span></span><span class='rparen'>)</span> + <span class='kw'>end</span> + <span class='id images'>images</span><span class='period'>.</span><span class='id each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id image'>image</span><span class='op'>|</span> + <span class='id r'>r</span> <span class='op'><<</span> <span class='const'>Relationship</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='const'>IMAGE_R</span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>../</span><span class='embexpr_beg'>#{</span><span class='id image'>image</span><span class='period'>.</span><span class='id pn'>pn</span><span class='rbrace'>}</span><span class='tstring_end'>"</span></span><span class='rparen'>)</span> + <span class='kw'>end</span> + <span class='id r'>r</span> +<span class='kw'>end</span></pre> </td> </tr> </table> </div> - </div> - - - <div id="instance_method_details" class="method_details_list"> - <h2>Instance Method Details</h2> - - - <div class="method_details first"> - <p class="signature first" id="add_chart-instance_method"> + <div class="method_details "> + <p class="signature " id="rels_pn-instance_method"> - - (<tt>Object</tt>) <strong>add_chart</strong>(chart_type, options = {}) + - (<tt>String</tt>) <strong>rels_pn</strong> </p><div class="docstring"> <div class="discussion"> - <div class="note notetag"> - <strong>Note:</strong> - <div class='inline'><p> -The recommended way to manage charts is to use Worksheet.add_chart. Please -refer to that method for documentation. -</p> -</div> - </div> - -<p> -Adds a chart to the drawing. -</p> +<p>The relational part name for this drawing</p> </div> </div> <div class="tags"> - - <h3>See Also:</h3> - <ul class="see"> - - <li><span class='object_link'><a href="Worksheet.html#add_chart-instance_method" title="Axlsx::Worksheet#add_chart (method)">Worksheet#add_chart</a></span></li> - - </ul> +<h3>Returns:</h3> +<ul class="return"> + + <li> + + + <span class='type'>(<tt>String</tt>)</span> + + + + </li> + +</ul> </div><table class="source_code"> <tr> @@ -1150,59 +1073,51 @@ Adds a chart to the drawing. <pre class="lines"> -98 -99 -100 -101</pre> +109 +110 +111</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/drawing.rb', line 98</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/drawing.rb', line 109</span> -<span class='def def kw'>def</span> <span class='add_chart identifier id'>add_chart</span><span class='lparen token'>(</span><span class='chart_type identifier id'>chart_type</span><span class='comma token'>,</span> <span class='options identifier id'>options</span><span class='assign token'>=</span><span class='lbrace token'>{</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> - <span class='TwoCellAnchor constant id'>TwoCellAnchor</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='self self kw'>self</span><span class='comma token'>,</span> <span class='options identifier id'>options</span><span class='rparen token'>)</span> - <span class='@anchors ivar id'>@anchors</span><span class='dot token'>.</span><span class='last identifier id'>last</span><span class='dot token'>.</span><span class='add_chart identifier id'>add_chart</span><span class='lparen token'>(</span><span class='chart_type identifier id'>chart_type</span><span class='comma token'>,</span> <span class='options identifier id'>options</span><span class='rparen token'>)</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id rels_pn'>rels_pn</span> + <span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='const'>DRAWING_RELS_PN</span> <span class='op'>%</span> <span class='lparen'>(</span><span class='id index'>index</span><span class='op'>+</span><span class='int'>1</span><span class='rparen'>)</span><span class='rbrace'>}</span><span class='tstring_end'>"</span></span> +<span class='kw'>end</span></pre> </td> </tr> </table> </div> <div class="method_details "> - <p class="signature " id="add_image-instance_method"> + <p class="signature " id="rId-instance_method"> - - (<tt>Object</tt>) <strong>add_image</strong>(options = {}) + - (<tt>String</tt>) <strong>rId</strong> </p><div class="docstring"> <div class="discussion"> - <div class="note notetag"> - <strong>Note:</strong> - <div class='inline'><p> -The recommended way to manage images is to use Worksheet.add_image. Please -refer to that method for documentation. -</p> -</div> - </div> - -<p> -Adds an image to the chart -</p> +<p>The relation reference id for this drawing</p> </div> </div> <div class="tags"> - - <h3>See Also:</h3> - <ul class="see"> - - <li><span class='object_link'><a href="Worksheet.html#add_image-instance_method" title="Axlsx::Worksheet#add_image (method)">Worksheet#add_image</a></span></li> - - </ul> +<h3>Returns:</h3> +<ul class="return"> + + <li> + + + <span class='type'>(<tt>String</tt>)</span> + + + + </li> + +</ul> </div><table class="source_code"> <tr> @@ -1210,19 +1125,16 @@ Adds an image to the chart <pre class="lines"> -90 -91 -92 -93</pre> +97 +98 +99</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/drawing.rb', line 90</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/drawing.rb', line 97</span> -<span class='def def kw'>def</span> <span class='add_image identifier id'>add_image</span><span class='lparen token'>(</span><span class='options identifier id'>options</span><span class='assign token'>=</span><span class='lbrace token'>{</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> - <span class='OneCellAnchor constant id'>OneCellAnchor</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='self self kw'>self</span><span class='comma token'>,</span> <span class='options identifier id'>options</span><span class='rparen token'>)</span> - <span class='@anchors ivar id'>@anchors</span><span class='dot token'>.</span><span class='last identifier id'>last</span><span class='dot token'>.</span><span class='object identifier id'>object</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id rId'>rId</span> + <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>rId</span><span class='embexpr_beg'>#{</span><span class='id index'>index</span><span class='op'>+</span><span class='int'>1</span><span class='rbrace'>}</span><span class='tstring_end'>"</span></span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1237,9 +1149,8 @@ Adds an image to the chart </p><div class="docstring"> <div class="discussion"> - <p> -Serializes the drawing -</p> + +<p>Serializes the drawing</p> </div> @@ -1266,27 +1177,26 @@ Serializes the drawing <pre class="lines"> -142 -143 -144 -145 -146 -147 -148 -149</pre> +128 +129 +130 +131 +132 +133 +134 +135</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/drawing.rb', line 142</span> - -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span> - <span class='builder identifier id'>builder</span> <span class='assign token'>=</span> <span class='Nokogiri constant id'>Nokogiri</span><span class='colon2 op'>::</span><span class='XML constant id'>XML</span><span class='colon2 op'>::</span><span class='Builder constant id'>Builder</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='symbol val'>:encoding</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='ENCODING constant id'>ENCODING</span><span class='rparen token'>)</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='xml identifier id'>xml</span><span class='bitor op'>|</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'xdr:wsDr'</span><span class='comma token'>,</span> <span class='symbol val'>:'xmlns:xdr'</span><span class='assign token'>=</span><span class='gt op'>></span><span class='XML_NS_XDR constant id'>XML_NS_XDR</span><span class='comma token'>,</span> <span class='symbol val'>:'xmlns:a'</span><span class='assign token'>=</span><span class='gt op'>></span><span class='XML_NS_A constant id'>XML_NS_A</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='anchors identifier id'>anchors</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='lbrace token'>{</span><span class='bitor op'>|</span><span class='anchor identifier id'>anchor</span><span class='bitor op'>|</span> <span class='anchor identifier id'>anchor</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> <span class='rbrace token'>}</span> - <span class='rbrace token'>}</span> - <span class='end end kw'>end</span> - <span class='builder identifier id'>builder</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/drawing.rb', line 128</span> + +<span class='kw'>def</span> <span class='id to_xml'>to_xml</span> + <span class='id builder'>builder</span> <span class='op'>=</span> <span class='const'>Nokogiri</span><span class='op'>::</span><span class='const'>XML</span><span class='op'>::</span><span class='const'>Builder</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='symbol'>:encoding</span> <span class='op'>=></span> <span class='const'>ENCODING</span><span class='rparen'>)</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id xml'>xml</span><span class='op'>|</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>xdr:wsDr</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:xmlns:xdr</span><span class='tstring_end'>'</span></span><span class='op'>=></span><span class='const'>XML_NS_XDR</span><span class='comma'>,</span> <span class='symbol'>:xmlns:a</span><span class='tstring_end'>'</span></span><span class='op'>=></span><span class='const'>XML_NS_A</span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='id anchors'>anchors</span><span class='period'>.</span><span class='id each'>each</span> <span class='lbrace'>{</span><span class='op'>|</span><span class='id anchor'>anchor</span><span class='op'>|</span> <span class='id anchor'>anchor</span><span class='period'>.</span><span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> <span class='rbrace'>}</span> + <span class='rbrace'>}</span> + <span class='kw'>end</span> + <span class='id builder'>builder</span><span class='period'>.</span><span class='id to_xml'>to_xml</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1297,9 +1207,9 @@ Serializes the drawing </div> <div id="footer"> - Generated on Wed Nov 23 22:20:46 2011 by + Generated on Sat Nov 26 13:16:37 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/Fill.html b/doc/Axlsx/Fill.html index fb9d0d63..c7012232 100644 --- a/doc/Axlsx/Fill.html +++ b/doc/Axlsx/Fill.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::Fill - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -97,17 +97,15 @@ <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -The recommended way to manage styles in your workbook is to use -Styles#add_style. -</p> + <div class='inline'> +<p>The recommended way to manage styles in your workbook is to use +Styles#add_style.</p> </div> </div> -<p> -The Fill is a formatting object that manages the background color, and -pattern for cells. -</p> + +<p>The Fill is a formatting object that manages the background color, and +pattern for cells.</p> </div> @@ -150,9 +148,8 @@ pattern for cells. - <span class="summary_desc"><div class='inline'><p> -The type of fill. -</p> + <span class="summary_desc"><div class='inline'> +<p>The type of fill.</p> </div></span> </li> @@ -189,9 +186,8 @@ The type of fill. - <span class="summary_desc"><div class='inline'><p> -Creates a new Fill object. -</p> + <span class="summary_desc"><div class='inline'> +<p>Creates a new Fill object.</p> </div></span> </li> @@ -213,9 +209,8 @@ Creates a new Fill object. - <span class="summary_desc"><div class='inline'><p> -Serializes the fill. -</p> + <span class="summary_desc"><div class='inline'> +<p>Serializes the fill.</p> </div></span> </li> @@ -236,9 +231,8 @@ Serializes the fill. </p><div class="docstring"> <div class="discussion"> - <p> -Creates a new Fill object -</p> + +<p>Creates a new Fill object</p> </div> @@ -271,9 +265,8 @@ Creates a new Fill object — - <div class='inline'><p> -if the fill_type parameter is not a PatternFill or a GradientFill instance -</p> + <div class='inline'> +<p>if the fill_type parameter is not a PatternFill or a GradientFill instance</p> </div> </li> @@ -293,10 +286,9 @@ if the fill_type parameter is not a PatternFill or a GradientFill instance <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/fill.rb', line 16</span> -<span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span><span class='lparen token'>(</span><span class='fill_type identifier id'>fill_type</span><span class='rparen token'>)</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='fill_type identifier id'>fill_type</span> <span class='assign token'>=</span> <span class='fill_type identifier id'>fill_type</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id initialize'>initialize</span><span class='lparen'>(</span><span class='id fill_type'>fill_type</span><span class='rparen'>)</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id fill_type'>fill_type</span> <span class='op'>=</span> <span class='id fill_type'>fill_type</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -319,9 +311,8 @@ if the fill_type parameter is not a PatternFill or a GradientFill instance </p><div class="docstring"> <div class="discussion"> - <p> -The type of fill -</p> + +<p>The type of fill</p> </div> @@ -355,10 +346,9 @@ The type of fill <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/fill.rb', line 11</span> -<span class='def def kw'>def</span> <span class='fill_type identifier id'>fill_type</span> - <span class='@fill_type ivar id'>@fill_type</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id fill_type'>fill_type</span> + <span class='ivar'>@fill_type</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -380,9 +370,8 @@ The type of fill </p><div class="docstring"> <div class="discussion"> - <p> -Serializes the fill -</p> + +<p>Serializes the fill</p> </div> @@ -401,9 +390,8 @@ Serializes the fill — - <div class='inline'><p> -The document builder instance this objects xml will be added to. -</p> + <div class='inline'> +<p>The document builder instance this objects xml will be added to.</p> </div> </li> @@ -437,10 +425,9 @@ The document builder instance this objects xml will be added to. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/fill.rb', line 23</span> -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='fill identifier id'>fill</span> <span class='lbrace token'>{</span> <span class='@fill_type ivar id'>@fill_type</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> <span class='rbrace token'>}</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id fill'>fill</span> <span class='lbrace'>{</span> <span class='ivar'>@fill_type</span><span class='period'>.</span><span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> <span class='rbrace'>}</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -451,9 +438,9 @@ The document builder instance this objects xml will be added to. </div> <div id="footer"> - Generated on Wed Nov 23 22:20:57 2011 by + Generated on Sat Nov 26 13:16:37 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/Font.html b/doc/Axlsx/Font.html index 9e635f51..575eb462 100644 --- a/doc/Axlsx/Font.html +++ b/doc/Axlsx/Font.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::Font - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -97,15 +97,13 @@ <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -The recommended way to manage fonts, and other styles is Styles#add_style -</p> + <div class='inline'> +<p>The recommended way to manage fonts, and other styles is Styles#add_style</p> </div> </div> -<p> -The Font class details a font instance for use in styling cells. -</p> + +<p>The Font class details a font instance for use in styling cells.</p> </div> @@ -144,9 +142,8 @@ The Font class details a font instance for use in styling cells. - <span class="summary_desc"><div class='inline'><p> -Indicates if the font should be rendered in <b>bold</b>. -</p> + <span class="summary_desc"><div class='inline'> +<p>Indicates if the font should be rendered in <b>bold</b>.</p> </div></span> </li> @@ -171,9 +168,8 @@ Indicates if the font should be rendered in <b>bold</b>. - <span class="summary_desc"><div class='inline'><p> -The charset of the font. -</p> + <span class="summary_desc"><div class='inline'> +<p>The charset of the font.</p> </div></span> </li> @@ -198,9 +194,8 @@ The charset of the font. - <span class="summary_desc"><div class='inline'><p> -The color of the font. -</p> + <span class="summary_desc"><div class='inline'> +<p>The color of the font.</p> </div></span> </li> @@ -225,9 +220,8 @@ The color of the font. - <span class="summary_desc"><div class='inline'><p> -Indicates if the font should be condensed. -</p> + <span class="summary_desc"><div class='inline'> +<p>Indicates if the font should be condensed.</p> </div></span> </li> @@ -252,9 +246,8 @@ Indicates if the font should be condensed. - <span class="summary_desc"><div class='inline'><p> -The font’s extend property. -</p> + <span class="summary_desc"><div class='inline'> +<p>The font's extend property.</p> </div></span> </li> @@ -279,9 +272,8 @@ The font’s extend property. - <span class="summary_desc"><div class='inline'><p> -The font’s family. -</p> + <span class="summary_desc"><div class='inline'> +<p>The font's family.</p> </div></span> </li> @@ -306,9 +298,8 @@ The font’s family. - <span class="summary_desc"><div class='inline'><p> -Indicates if the font should be rendered italicized. -</p> + <span class="summary_desc"><div class='inline'> +<p>Indicates if the font should be rendered italicized.</p> </div></span> </li> @@ -333,9 +324,8 @@ Indicates if the font should be rendered italicized. - <span class="summary_desc"><div class='inline'><p> -The name of the font. -</p> + <span class="summary_desc"><div class='inline'> +<p>The name of the font.</p> </div></span> </li> @@ -360,9 +350,8 @@ The name of the font. - <span class="summary_desc"><div class='inline'><p> -Indicates if the font should be rendered with an outline. -</p> + <span class="summary_desc"><div class='inline'> +<p>Indicates if the font should be rendered with an outline.</p> </div></span> </li> @@ -387,9 +376,8 @@ Indicates if the font should be rendered with an outline. - <span class="summary_desc"><div class='inline'><p> -Indicates if the font should be rendered with a shadow. -</p> + <span class="summary_desc"><div class='inline'> +<p>Indicates if the font should be rendered with a shadow.</p> </div></span> </li> @@ -414,9 +402,8 @@ Indicates if the font should be rendered with a shadow. - <span class="summary_desc"><div class='inline'><p> -Indicates if the font should be rendered with a strikthrough. -</p> + <span class="summary_desc"><div class='inline'> +<p>Indicates if the font should be rendered with a strikthrough.</p> </div></span> </li> @@ -441,9 +428,8 @@ Indicates if the font should be rendered with a strikthrough. - <span class="summary_desc"><div class='inline'><p> -The size of the font. -</p> + <span class="summary_desc"><div class='inline'> +<p>The size of the font.</p> </div></span> </li> @@ -480,9 +466,8 @@ The size of the font. - <span class="summary_desc"><div class='inline'><p> -Creates a new Font. -</p> + <span class="summary_desc"><div class='inline'> +<p>Creates a new Font.</p> </div></span> </li> @@ -504,9 +489,8 @@ Creates a new Font. - <span class="summary_desc"><div class='inline'><p> -Serializes the fill. -</p> + <span class="summary_desc"><div class='inline'> +<p>Serializes the fill.</p> </div></span> </li> @@ -527,9 +511,8 @@ Serializes the fill. </p><div class="docstring"> <div class="discussion"> - <p> -Creates a new Font -</p> + +<p>Creates a new Font</p> </div> @@ -550,9 +533,8 @@ Creates a new Font — - <div class='inline'><p> -a customizable set of options -</p> + <div class='inline'> +<p>a customizable set of options</p> </div> </li> @@ -701,12 +683,11 @@ a customizable set of options <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/font.rb', line 98</span> -<span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span><span class='lparen token'>(</span><span class='options identifier id'>options</span><span class='assign token'>=</span><span class='lbrace token'>{</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> - <span class='options identifier id'>options</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='o identifier id'>o</span><span class='bitor op'>|</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='dstring node'>"#{o[0]}="</span><span class='comma token'>,</span> <span class='o identifier id'>o</span><span class='lbrack token'>[</span><span class='integer val'>1</span><span class='rbrack token'>]</span><span class='rparen token'>)</span> <span class='if if_mod kw'>if</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='respond_to? fid id'>respond_to?</span> <span class='o identifier id'>o</span><span class='lbrack token'>[</span><span class='integer val'>0</span><span class='rbrack token'>]</span> - <span class='end end kw'>end</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id initialize'>initialize</span><span class='lparen'>(</span><span class='id options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span> + <span class='id options'>options</span><span class='period'>.</span><span class='id each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id o'>o</span><span class='op'>|</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span><span class='rbrace'>}</span><span class='tstring_content'>=</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>1</span><span class='rbracket'>]</span><span class='rparen'>)</span> <span class='kw'>if</span> <span class='kw'>self</span><span class='period'>.</span><span class='id respond_to?'>respond_to?</span> <span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span> + <span class='kw'>end</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -729,9 +710,8 @@ a customizable set of options </p><div class="docstring"> <div class="discussion"> - <p> -Indicates if the font should be rendered in <b>bold</b> -</p> + +<p>Indicates if the font should be rendered in <b>bold</b></p> </div> @@ -765,10 +745,9 @@ Indicates if the font should be rendered in <b>bold</b> <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/font.rb', line 50</span> -<span class='def def kw'>def</span> <span class='b identifier id'>b</span> - <span class='@b ivar id'>@b</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id b'>b</span> + <span class='ivar'>@b</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -789,37 +768,34 @@ Indicates if the font should be rendered in <b>bold</b> <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -The following values are defined in the OOXML specification and are OS -dependant values -</p> -<pre class="code"> - <span class='integer val'>0</span> <span class='ANSI_CHARSET constant id'>ANSI_CHARSET</span> - <span class='integer val'>1</span> <span class='DEFAULT_CHARSET constant id'>DEFAULT_CHARSET</span> - <span class='integer val'>2</span> <span class='SYMBOL_CHARSET constant id'>SYMBOL_CHARSET</span> - <span class='integer val'>77</span> <span class='MAC_CHARSET constant id'>MAC_CHARSET</span> - <span class='integer val'>128</span> <span class='SHIFTJIS_CHARSET constant id'>SHIFTJIS_CHARSET</span> - <span class='integer val'>129</span> <span class='HANGUL_CHARSET constant id'>HANGUL_CHARSET</span> - <span class='integer val'>130</span> <span class='JOHAB_CHARSET constant id'>JOHAB_CHARSET</span> - <span class='integer val'>134</span> <span class='GB2312_CHARSET constant id'>GB2312_CHARSET</span> - <span class='integer val'>136</span> <span class='CHINESEBIG5_CHARSET constant id'>CHINESEBIG5_CHARSET</span> - <span class='integer val'>161</span> <span class='GREEK_CHARSET constant id'>GREEK_CHARSET</span> - <span class='integer val'>162</span> <span class='TURKISH_CHARSET constant id'>TURKISH_CHARSET</span> - <span class='integer val'>163</span> <span class='VIETNAMESE_CHARSET constant id'>VIETNAMESE_CHARSET</span> - <span class='integer val'>177</span> <span class='HEBREW_CHARSET constant id'>HEBREW_CHARSET</span> - <span class='integer val'>178</span> <span class='ARABIC_CHARSET constant id'>ARABIC_CHARSET</span> - <span class='integer val'>186</span> <span class='BALTIC_CHARSET constant id'>BALTIC_CHARSET</span> - <span class='integer val'>204</span> <span class='RUSSIAN_CHARSET constant id'>RUSSIAN_CHARSET</span> - <span class='integer val'>222</span> <span class='THAI_CHARSET constant id'>THAI_CHARSET</span> - <span class='integer val'>238</span> <span class='EASTEUROPE_CHARSET constant id'>EASTEUROPE_CHARSET</span> - <span class='integer val'>255</span> <span class='OEM_CHARSET constant id'>OEM_CHARSET</span> -</pre> + <div class='inline'> +<p>The following values are defined in the OOXML specification and are OS +dependant values</p> + +<pre class="code">0 ANSI_CHARSET +1 DEFAULT_CHARSET +2 SYMBOL_CHARSET +77 MAC_CHARSET +128 SHIFTJIS_CHARSET +129 HANGUL_CHARSET +130 JOHAB_CHARSET +134 GB2312_CHARSET +136 CHINESEBIG5_CHARSET +161 GREEK_CHARSET +162 TURKISH_CHARSET +163 VIETNAMESE_CHARSET +177 HEBREW_CHARSET +178 ARABIC_CHARSET +186 BALTIC_CHARSET +204 RUSSIAN_CHARSET +222 THAI_CHARSET +238 EASTEUROPE_CHARSET +255 OEM_CHARSET</pre> </div> </div> -<p> -The charset of the font -</p> + +<p>The charset of the font</p> </div> @@ -853,10 +829,9 @@ The charset of the font <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/font.rb', line 33</span> -<span class='def def kw'>def</span> <span class='charset identifier id'>charset</span> - <span class='@charset ivar id'>@charset</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id charset'>charset</span> + <span class='ivar'>@charset</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -874,9 +849,8 @@ The charset of the font </p><div class="docstring"> <div class="discussion"> - <p> -The color of the font -</p> + +<p>The color of the font</p> </div> @@ -910,10 +884,9 @@ The color of the font <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/font.rb', line 78</span> -<span class='def def kw'>def</span> <span class='color identifier id'>color</span> - <span class='@color ivar id'>@color</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id color'>color</span> + <span class='ivar'>@color</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -931,9 +904,8 @@ The color of the font </p><div class="docstring"> <div class="discussion"> - <p> -Indicates if the font should be condensed -</p> + +<p>Indicates if the font should be condensed</p> </div> @@ -967,10 +939,9 @@ Indicates if the font should be condensed <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/font.rb', line 70</span> -<span class='def def kw'>def</span> <span class='condense identifier id'>condense</span> - <span class='@condense ivar id'>@condense</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id condense'>condense</span> + <span class='ivar'>@condense</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -988,9 +959,8 @@ Indicates if the font should be condensed </p><div class="docstring"> <div class="discussion"> - <p> -The font’s extend property -</p> + +<p>The font's extend property</p> </div> @@ -1024,10 +994,9 @@ The font’s extend property <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/font.rb', line 74</span> -<span class='def def kw'>def</span> <span class='extend identifier id'>extend</span> - <span class='@extend ivar id'>@extend</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id extend'>extend</span> + <span class='ivar'>@extend</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1048,24 +1017,21 @@ The font’s extend property <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -The following are defined OOXML specification -</p> -<pre class="code"> - <span class='integer val'>0</span> <span class='Not constant id'>Not</span> <span class='applicable identifier id'>applicable</span><span class='dot token'>.</span> - <span class='integer val'>1</span> <span class='Roman constant id'>Roman</span> - <span class='integer val'>2</span> <span class='Swiss constant id'>Swiss</span> - <span class='integer val'>3</span> <span class='Modern constant id'>Modern</span> - <span class='integer val'>4</span> <span class='Script constant id'>Script</span> - <span class='integer val'>5</span> <span class='Decorative constant id'>Decorative</span> - <span class='float val'>6</span><span class='dot2 op'>..</span><span class='integer val'>14</span> <span class='Reserved constant id'>Reserved</span> <span class='for for kw'>for</span> <span class='future identifier id'>future</span> <span class='use identifier id'>use</span> -</pre> + <div class='inline'> +<p>The following are defined OOXML specification</p> + +<pre class="code">0 Not applicable. +1 Roman +2 Swiss +3 Modern +4 Script +5 Decorative +6..14 Reserved for future use</pre> </div> </div> -<p> -The font’s family -</p> + +<p>The font's family</p> </div> @@ -1099,10 +1065,9 @@ The font’s family <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/font.rb', line 46</span> -<span class='def def kw'>def</span> <span class='family identifier id'>family</span> - <span class='@family ivar id'>@family</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id family'>family</span> + <span class='ivar'>@family</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1120,9 +1085,8 @@ The font’s family </p><div class="docstring"> <div class="discussion"> - <p> -Indicates if the font should be rendered italicized -</p> + +<p>Indicates if the font should be rendered italicized</p> </div> @@ -1156,10 +1120,9 @@ Indicates if the font should be rendered italicized <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/font.rb', line 54</span> -<span class='def def kw'>def</span> <span class='i identifier id'>i</span> - <span class='@i ivar id'>@i</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id i'>i</span> + <span class='ivar'>@i</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1177,9 +1140,8 @@ Indicates if the font should be rendered italicized </p><div class="docstring"> <div class="discussion"> - <p> -The name of the font -</p> + +<p>The name of the font</p> </div> @@ -1213,10 +1175,9 @@ The name of the font <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/font.rb', line 8</span> -<span class='def def kw'>def</span> <span class='name identifier id'>name</span> - <span class='@name ivar id'>@name</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id name'>name</span> + <span class='ivar'>@name</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1234,9 +1195,8 @@ The name of the font </p><div class="docstring"> <div class="discussion"> - <p> -Indicates if the font should be rendered with an outline -</p> + +<p>Indicates if the font should be rendered with an outline</p> </div> @@ -1270,10 +1230,9 @@ Indicates if the font should be rendered with an outline <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/font.rb', line 62</span> -<span class='def def kw'>def</span> <span class='outline identifier id'>outline</span> - <span class='@outline ivar id'>@outline</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id outline'>outline</span> + <span class='ivar'>@outline</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1291,9 +1250,8 @@ Indicates if the font should be rendered with an outline </p><div class="docstring"> <div class="discussion"> - <p> -Indicates if the font should be rendered with a shadow -</p> + +<p>Indicates if the font should be rendered with a shadow</p> </div> @@ -1327,10 +1285,9 @@ Indicates if the font should be rendered with a shadow <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/font.rb', line 66</span> -<span class='def def kw'>def</span> <span class='shadow identifier id'>shadow</span> - <span class='@shadow ivar id'>@shadow</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id shadow'>shadow</span> + <span class='ivar'>@shadow</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1348,9 +1305,8 @@ Indicates if the font should be rendered with a shadow </p><div class="docstring"> <div class="discussion"> - <p> -Indicates if the font should be rendered with a strikthrough -</p> + +<p>Indicates if the font should be rendered with a strikthrough</p> </div> @@ -1384,10 +1340,9 @@ Indicates if the font should be rendered with a strikthrough <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/font.rb', line 58</span> -<span class='def def kw'>def</span> <span class='strike identifier id'>strike</span> - <span class='@strike ivar id'>@strike</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id strike'>strike</span> + <span class='ivar'>@strike</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1405,9 +1360,8 @@ Indicates if the font should be rendered with a strikthrough </p><div class="docstring"> <div class="discussion"> - <p> -The size of the font. -</p> + +<p>The size of the font.</p> </div> @@ -1441,10 +1395,9 @@ The size of the font. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/font.rb', line 82</span> -<span class='def def kw'>def</span> <span class='sz identifier id'>sz</span> - <span class='@sz ivar id'>@sz</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id sz'>sz</span> + <span class='ivar'>@sz</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1466,9 +1419,8 @@ The size of the font. </p><div class="docstring"> <div class="discussion"> - <p> -Serializes the fill -</p> + +<p>Serializes the fill</p> </div> @@ -1487,9 +1439,8 @@ Serializes the fill — - <div class='inline'><p> -The document builder instance this objects xml will be added to. -</p> + <div class='inline'> +<p>The document builder instance this objects xml will be added to.</p> </div> </li> @@ -1516,25 +1467,24 @@ The document builder instance this objects xml will be added to. <pre class="lines"> -120 -121 -122 -123 -124 -125 -126</pre> +131 +132 +133 +134 +135 +136 +137</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/font.rb', line 120</span> - -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='font identifier id'>font</span> <span class='lbrace token'>{</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='instance_values identifier id'>instance_values</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='k identifier id'>k</span><span class='comma token'>,</span> <span class='v identifier id'>v</span><span class='bitor op'>|</span> - <span class='v identifier id'>v</span><span class='dot token'>.</span><span class='is_a? fid id'>is_a?</span><span class='lparen token'>(</span><span class='Color constant id'>Color</span><span class='rparen token'>)</span> <span class='question op'>?</span> <span class='v identifier id'>v</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> <span class='colon op'>:</span> <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='k identifier id'>k</span><span class='comma token'>,</span> <span class='lbrace token'>{</span><span class='symbol val'>:val</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='v identifier id'>v</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> - <span class='end end kw'>end</span> - <span class='rbrace token'>}</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/font.rb', line 131</span> + +<span class='kw'>def</span> <span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id font'>font</span> <span class='lbrace'>{</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id instance_values'>instance_values</span><span class='period'>.</span><span class='id each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id k'>k</span><span class='comma'>,</span> <span class='id v'>v</span><span class='op'>|</span> + <span class='id v'>v</span><span class='period'>.</span><span class='id is_a?'>is_a?</span><span class='lparen'>(</span><span class='const'>Color</span><span class='rparen'>)</span> <span class='op'>?</span> <span class='id v'>v</span><span class='period'>.</span><span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> <span class='op'>:</span> <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='id k'>k</span><span class='comma'>,</span> <span class='lbrace'>{</span><span class='symbol'>:val</span> <span class='op'>=></span> <span class='id v'>v</span><span class='rbrace'>}</span><span class='rparen'>)</span> + <span class='kw'>end</span> + <span class='rbrace'>}</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1545,9 +1495,9 @@ The document builder instance this objects xml will be added to. </div> <div id="footer"> - Generated on Wed Nov 23 22:20:50 2011 by + Generated on Sat Nov 26 13:16:37 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/GradientFill.html b/doc/Axlsx/GradientFill.html index 9013f3c6..893cc360 100644 --- a/doc/Axlsx/GradientFill.html +++ b/doc/Axlsx/GradientFill.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::GradientFill - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -94,9 +94,8 @@ <h2>Overview</h2><div class="docstring"> <div class="discussion"> - <p> -A GradientFill defines the color and positioning for gradiant cell fill. -</p> + +<p>A GradientFill defines the color and positioning for gradiant cell fill.</p> </div> @@ -135,9 +134,8 @@ A GradientFill defines the color and positioning for gradiant cell fill. - <span class="summary_desc"><div class='inline'><p> -Percentage format bottom. -</p> + <span class="summary_desc"><div class='inline'> +<p>Percentage format bottom.</p> </div></span> </li> @@ -162,9 +160,8 @@ Percentage format bottom. - <span class="summary_desc"><div class='inline'><p> -Angle of the linear gradient. -</p> + <span class="summary_desc"><div class='inline'> +<p>Angle of the linear gradient.</p> </div></span> </li> @@ -189,9 +186,8 @@ Angle of the linear gradient. - <span class="summary_desc"><div class='inline'><p> -Percentage format left. -</p> + <span class="summary_desc"><div class='inline'> +<p>Percentage format left.</p> </div></span> </li> @@ -216,9 +212,8 @@ Percentage format left. - <span class="summary_desc"><div class='inline'><p> -Percentage format right. -</p> + <span class="summary_desc"><div class='inline'> +<p>Percentage format right.</p> </div></span> </li> @@ -243,9 +238,8 @@ Percentage format right. - <span class="summary_desc"><div class='inline'><p> -Collection of stop objects. -</p> + <span class="summary_desc"><div class='inline'> +<p>Collection of stop objects.</p> </div></span> </li> @@ -270,9 +264,8 @@ Collection of stop objects. - <span class="summary_desc"><div class='inline'><p> -Percentage format top. -</p> + <span class="summary_desc"><div class='inline'> +<p>Percentage format top.</p> </div></span> </li> @@ -297,9 +290,8 @@ Percentage format top. - <span class="summary_desc"><div class='inline'><p> -The type of gradient. -</p> + <span class="summary_desc"><div class='inline'> +<p>The type of gradient.</p> </div></span> </li> @@ -336,9 +328,8 @@ The type of gradient. - <span class="summary_desc"><div class='inline'><p> -Creates a new GradientFill object. -</p> + <span class="summary_desc"><div class='inline'> +<p>Creates a new GradientFill object.</p> </div></span> </li> @@ -360,9 +351,8 @@ Creates a new GradientFill object. - <span class="summary_desc"><div class='inline'><p> -Serializes the gradientFill. -</p> + <span class="summary_desc"><div class='inline'> +<p>Serializes the gradientFill.</p> </div></span> </li> @@ -383,9 +373,8 @@ Serializes the gradientFill. </p><div class="docstring"> <div class="discussion"> - <p> -Creates a new GradientFill object -</p> + +<p>Creates a new GradientFill object</p> </div> @@ -406,9 +395,8 @@ Creates a new GradientFill object — - <div class='inline'><p> -a customizable set of options -</p> + <div class='inline'> +<p>a customizable set of options</p> </div> </li> @@ -496,14 +484,13 @@ a customizable set of options <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/gradient_fill.rb', line 46</span> -<span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span><span class='lparen token'>(</span><span class='options identifier id'>options</span><span class='assign token'>=</span><span class='lbrace token'>{</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> - <span class='options identifier id'>options</span><span class='lbrack token'>[</span><span class='symbol val'>:type</span><span class='rbrack token'>]</span> <span class='opasgn op'>||=</span> <span class='symbol val'>:linear</span> - <span class='options identifier id'>options</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='o identifier id'>o</span><span class='bitor op'>|</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='dstring node'>"#{o[0]}="</span><span class='comma token'>,</span> <span class='o identifier id'>o</span><span class='lbrack token'>[</span><span class='integer val'>1</span><span class='rbrack token'>]</span><span class='rparen token'>)</span> <span class='if if_mod kw'>if</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='respond_to? fid id'>respond_to?</span> <span class='o identifier id'>o</span><span class='lbrack token'>[</span><span class='integer val'>0</span><span class='rbrack token'>]</span> - <span class='end end kw'>end</span> - <span class='@stop ivar id'>@stop</span> <span class='assign token'>=</span> <span class='SimpleTypedList constant id'>SimpleTypedList</span><span class='dot token'>.</span><span class='new identifier id'>new</span> <span class='GradientStop constant id'>GradientStop</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id initialize'>initialize</span><span class='lparen'>(</span><span class='id options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span> + <span class='id options'>options</span><span class='lbracket'>[</span><span class='symbol'>:type</span><span class='rbracket'>]</span> <span class='op'>||=</span> <span class='symbol'>:linear</span> + <span class='id options'>options</span><span class='period'>.</span><span class='id each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id o'>o</span><span class='op'>|</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span><span class='rbrace'>}</span><span class='tstring_content'>=</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>1</span><span class='rbracket'>]</span><span class='rparen'>)</span> <span class='kw'>if</span> <span class='kw'>self</span><span class='period'>.</span><span class='id respond_to?'>respond_to?</span> <span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span> + <span class='kw'>end</span> + <span class='ivar'>@stop</span> <span class='op'>=</span> <span class='const'>SimpleTypedList</span><span class='period'>.</span><span class='id new'>new</span> <span class='const'>GradientStop</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -526,9 +513,8 @@ a customizable set of options </p><div class="docstring"> <div class="discussion"> - <p> -Percentage format bottom -</p> + +<p>Percentage format bottom</p> </div> @@ -562,10 +548,9 @@ Percentage format bottom <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/gradient_fill.rb', line 33</span> -<span class='def def kw'>def</span> <span class='bottom identifier id'>bottom</span> - <span class='@bottom ivar id'>@bottom</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id bottom'>bottom</span> + <span class='ivar'>@bottom</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -583,9 +568,8 @@ Percentage format bottom </p><div class="docstring"> <div class="discussion"> - <p> -Angle of the linear gradient -</p> + +<p>Angle of the linear gradient</p> </div> @@ -619,10 +603,9 @@ Angle of the linear gradient <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/gradient_fill.rb', line 17</span> -<span class='def def kw'>def</span> <span class='degree identifier id'>degree</span> - <span class='@degree ivar id'>@degree</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id degree'>degree</span> + <span class='ivar'>@degree</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -640,9 +623,8 @@ Angle of the linear gradient </p><div class="docstring"> <div class="discussion"> - <p> -Percentage format left -</p> + +<p>Percentage format left</p> </div> @@ -676,10 +658,9 @@ Percentage format left <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/gradient_fill.rb', line 21</span> -<span class='def def kw'>def</span> <span class='left identifier id'>left</span> - <span class='@left ivar id'>@left</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id left'>left</span> + <span class='ivar'>@left</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -697,9 +678,8 @@ Percentage format left </p><div class="docstring"> <div class="discussion"> - <p> -Percentage format right -</p> + +<p>Percentage format right</p> </div> @@ -733,10 +713,9 @@ Percentage format right <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/gradient_fill.rb', line 25</span> -<span class='def def kw'>def</span> <span class='right identifier id'>right</span> - <span class='@right ivar id'>@right</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id right'>right</span> + <span class='ivar'>@right</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -754,9 +733,8 @@ Percentage format right </p><div class="docstring"> <div class="discussion"> - <p> -Collection of stop objects -</p> + +<p>Collection of stop objects</p> </div> @@ -790,10 +768,9 @@ Collection of stop objects <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/gradient_fill.rb', line 37</span> -<span class='def def kw'>def</span> <span class='stop identifier id'>stop</span> - <span class='@stop ivar id'>@stop</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id stop'>stop</span> + <span class='ivar'>@stop</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -811,9 +788,8 @@ Collection of stop objects </p><div class="docstring"> <div class="discussion"> - <p> -Percentage format top -</p> + +<p>Percentage format top</p> </div> @@ -847,10 +823,9 @@ Percentage format top <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/gradient_fill.rb', line 29</span> -<span class='def def kw'>def</span> <span class='top identifier id'>top</span> - <span class='@top ivar id'>@top</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id top'>top</span> + <span class='ivar'>@top</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -871,19 +846,16 @@ Percentage format top <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -valid options are -</p> -<pre class="code"> - <span class='symbol val'>:linear</span> - <span class='symbol val'>:path</span> -</pre> + <div class='inline'> +<p>valid options are</p> + +<pre class="code"><span class='symbol'>:linear</span> +<span class='symbol'>:path</span></pre> </div> </div> -<p> -The type of gradient. -</p> + +<p>The type of gradient.</p> </div> @@ -917,10 +889,9 @@ The type of gradient. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/gradient_fill.rb', line 13</span> -<span class='def def kw'>def</span> <span class='type identifier id'>type</span> - <span class='@type ivar id'>@type</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id type'>type</span> + <span class='ivar'>@type</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -942,9 +913,8 @@ The type of gradient. </p><div class="docstring"> <div class="discussion"> - <p> -Serializes the gradientFill -</p> + +<p>Serializes the gradientFill</p> </div> @@ -963,9 +933,8 @@ Serializes the gradientFill — - <div class='inline'><p> -The document builder instance this objects xml will be added to. -</p> + <div class='inline'> +<p>The document builder instance this objects xml will be added to.</p> </div> </li> @@ -992,21 +961,20 @@ The document builder instance this objects xml will be added to. <pre class="lines"> -64 -65 -66 -67 -68</pre> +70 +71 +72 +73 +74</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/gradient_fill.rb', line 64</span> - -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='gradientFill identifier id'>gradientFill</span><span class='lparen token'>(</span><span class='self self kw'>self</span><span class='dot token'>.</span><span class='instance_values identifier id'>instance_values</span><span class='dot token'>.</span><span class='reject identifier id'>reject</span> <span class='lbrace token'>{</span> <span class='bitor op'>|</span><span class='k identifier id'>k</span><span class='comma token'>,</span><span class='v identifier id'>v</span><span class='bitor op'>|</span> <span class='k identifier id'>k</span><span class='dot token'>.</span><span class='to_sym identifier id'>to_sym</span> <span class='eq op'>==</span> <span class='symbol val'>:stop</span> <span class='rbrace token'>}</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='@stop ivar id'>@stop</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='lbrace token'>{</span> <span class='bitor op'>|</span><span class='s identifier id'>s</span><span class='bitor op'>|</span> <span class='s identifier id'>s</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> <span class='rbrace token'>}</span> - <span class='rbrace token'>}</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/gradient_fill.rb', line 70</span> + +<span class='kw'>def</span> <span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id gradientFill'>gradientFill</span><span class='lparen'>(</span><span class='kw'>self</span><span class='period'>.</span><span class='id instance_values'>instance_values</span><span class='period'>.</span><span class='id reject'>reject</span> <span class='lbrace'>{</span> <span class='op'>|</span><span class='id k'>k</span><span class='comma'>,</span><span class='id v'>v</span><span class='op'>|</span> <span class='id k'>k</span><span class='period'>.</span><span class='id to_sym'>to_sym</span> <span class='op'>==</span> <span class='symbol'>:stop</span> <span class='rbrace'>}</span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='ivar'>@stop</span><span class='period'>.</span><span class='id each'>each</span> <span class='lbrace'>{</span> <span class='op'>|</span><span class='id s'>s</span><span class='op'>|</span> <span class='id s'>s</span><span class='period'>.</span><span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> <span class='rbrace'>}</span> + <span class='rbrace'>}</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1017,9 +985,9 @@ The document builder instance this objects xml will be added to. </div> <div id="footer"> - Generated on Wed Nov 23 22:20:52 2011 by + Generated on Sat Nov 26 13:16:39 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/GradientStop.html b/doc/Axlsx/GradientStop.html index 36c97f81..405b6efd 100644 --- a/doc/Axlsx/GradientStop.html +++ b/doc/Axlsx/GradientStop.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::GradientStop - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -94,9 +94,8 @@ <h2>Overview</h2><div class="docstring"> <div class="discussion"> - <p> -The GradientStop object represents a color point in a gradient. -</p> + +<p>The GradientStop object represents a color point in a gradient.</p> </div> @@ -135,9 +134,8 @@ The GradientStop object represents a color point in a gradient. - <span class="summary_desc"><div class='inline'><p> -The color for this gradient stop. -</p> + <span class="summary_desc"><div class='inline'> +<p>The color for this gradient stop.</p> </div></span> </li> @@ -162,9 +160,8 @@ The color for this gradient stop. - <span class="summary_desc"><div class='inline'><p> -The position of the color. -</p> + <span class="summary_desc"><div class='inline'> +<p>The position of the color.</p> </div></span> </li> @@ -201,9 +198,8 @@ The position of the color. - <span class="summary_desc"><div class='inline'><p> -Creates a new GradientStop object. -</p> + <span class="summary_desc"><div class='inline'> +<p>Creates a new GradientStop object.</p> </div></span> </li> @@ -225,9 +221,8 @@ Creates a new GradientStop object. - <span class="summary_desc"><div class='inline'><p> -Serializes the gradientStop. -</p> + <span class="summary_desc"><div class='inline'> +<p>Serializes the gradientStop.</p> </div></span> </li> @@ -248,9 +243,8 @@ Serializes the gradientStop. </p><div class="docstring"> <div class="discussion"> - <p> -Creates a new GradientStop object -</p> + +<p>Creates a new GradientStop object</p> </div> @@ -298,11 +292,10 @@ Creates a new GradientStop object <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/gradient_stop.rb', line 18</span> -<span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span><span class='lparen token'>(</span><span class='color identifier id'>color</span><span class='comma token'>,</span> <span class='position identifier id'>position</span><span class='rparen token'>)</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='color identifier id'>color</span> <span class='assign token'>=</span> <span class='color identifier id'>color</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='position identifier id'>position</span> <span class='assign token'>=</span> <span class='position identifier id'>position</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id initialize'>initialize</span><span class='lparen'>(</span><span class='id color'>color</span><span class='comma'>,</span> <span class='id position'>position</span><span class='rparen'>)</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id color'>color</span> <span class='op'>=</span> <span class='id color'>color</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id position'>position</span> <span class='op'>=</span> <span class='id position'>position</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -325,9 +318,8 @@ Creates a new GradientStop object </p><div class="docstring"> <div class="discussion"> - <p> -The color for this gradient stop -</p> + +<p>The color for this gradient stop</p> </div> @@ -368,10 +360,9 @@ The color for this gradient stop <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/gradient_stop.rb', line 9</span> -<span class='def def kw'>def</span> <span class='color identifier id'>color</span> - <span class='@color ivar id'>@color</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id color'>color</span> + <span class='ivar'>@color</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -389,9 +380,8 @@ The color for this gradient stop </p><div class="docstring"> <div class="discussion"> - <p> -The position of the color -</p> + +<p>The position of the color</p> </div> @@ -425,10 +415,9 @@ The position of the color <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/gradient_stop.rb', line 13</span> -<span class='def def kw'>def</span> <span class='position identifier id'>position</span> - <span class='@position ivar id'>@position</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id position'>position</span> + <span class='ivar'>@position</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -450,9 +439,8 @@ The position of the color </p><div class="docstring"> <div class="discussion"> - <p> -Serializes the gradientStop -</p> + +<p>Serializes the gradientStop</p> </div> @@ -471,9 +459,8 @@ Serializes the gradientStop — - <div class='inline'><p> -The document builder instance this objects xml will be added to. -</p> + <div class='inline'> +<p>The document builder instance this objects xml will be added to.</p> </div> </li> @@ -500,13 +487,12 @@ The document builder instance this objects xml will be added to. <pre class="lines"> -29</pre> +31</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/gradient_stop.rb', line 29</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/gradient_stop.rb', line 31</span> -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='stop identifier id'>stop</span><span class='lparen token'>(</span><span class='symbol val'>:position</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='position identifier id'>position</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span><span class='self self kw'>self</span><span class='dot token'>.</span><span class='color identifier id'>color</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span><span class='rbrace token'>}</span> <span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> <span class='id xml'>xml</span><span class='period'>.</span><span class='id stop'>stop</span><span class='lparen'>(</span><span class='symbol'>:position</span> <span class='op'>=></span> <span class='kw'>self</span><span class='period'>.</span><span class='id position'>position</span><span class='rparen'>)</span> <span class='lbrace'>{</span><span class='kw'>self</span><span class='period'>.</span><span class='id color'>color</span><span class='period'>.</span><span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span><span class='rbrace'>}</span> <span class='kw'>end</span></pre> </td> </tr> </table> @@ -517,9 +503,9 @@ The document builder instance this objects xml will be added to. </div> <div id="footer"> - Generated on Wed Nov 23 22:21:02 2011 by + Generated on Sat Nov 26 13:16:39 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/GraphicFrame.html b/doc/Axlsx/GraphicFrame.html index a04b2477..39c8949b 100644 --- a/doc/Axlsx/GraphicFrame.html +++ b/doc/Axlsx/GraphicFrame.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::GraphicFrame - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -97,15 +97,13 @@ <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -The recommended way to manage charts is Worksheet#add_chart -</p> + <div class='inline'> +<p>The recommended way to manage charts is Worksheet#add_chart</p> </div> </div> -<p> -A graphic frame defines a container for a chart object -</p> + +<p>A graphic frame defines a container for a chart object</p> </div> @@ -144,9 +142,8 @@ A graphic frame defines a container for a chart object - <span class="summary_desc"><div class='inline'><p> -A anchor that holds this frame. -</p> + <span class="summary_desc"><div class='inline'> +<p>A anchor that holds this frame.</p> </div></span> </li> @@ -171,26 +168,37 @@ A anchor that holds this frame. - <span class="summary_desc"><div class='inline'><p> -A reference to the chart object associated with this frame. -</p> + <span class="summary_desc"><div class='inline'> +<p>A reference to the chart object associated with this frame.</p> </div></span> </li> - <li class="public "> + </ul> + + + + + + <h2> + Instance Method Summary + <small>(<a href="#" class="summary_toggle">collapse</a>)</small> + </h2> + + <ul class="summary"> + + <li class="public "> <span class="summary_signature"> - <a href="#rId-instance_method" title="#rId (instance method)">- (String) <strong>rId</strong> </a> + <a href="#initialize-instance_method" title="#initialize (instance method)">- (GraphicFrame) <strong>initialize</strong>(anchor, chart_type, options) </a> </span> + <span class="note title constructor">constructor</span> - <span class="note title readonly">readonly</span> - @@ -198,38 +206,22 @@ A reference to the chart object associated with this frame. - <span class="summary_desc"><div class='inline'><p> -The relationship id for this graphic. -</p> + <span class="summary_desc"><div class='inline'> +<p>Creates a new GraphicFrame object.</p> </div></span> </li> - - </ul> - - - - - - <h2> - Instance Method Summary - <small>(<a href="#" class="summary_toggle">collapse</a>)</small> - </h2> - - <ul class="summary"> <li class="public "> <span class="summary_signature"> - <a href="#initialize-instance_method" title="#initialize (instance method)">- (GraphicFrame) <strong>initialize</strong>(anchor, chart_type, options) </a> + <a href="#rId-instance_method" title="#rId (instance method)">- (String) <strong>rId</strong> </a> </span> - <span class="note title constructor">constructor</span> - @@ -237,9 +229,8 @@ The relationship id for this graphic. - <span class="summary_desc"><div class='inline'><p> -Creates a new GraphicFrame object. -</p> + <span class="summary_desc"><div class='inline'> +<p>The relationship id for this graphic.</p> </div></span> </li> @@ -261,9 +252,8 @@ Creates a new GraphicFrame object. - <span class="summary_desc"><div class='inline'><p> -Serializes the graphic frame. -</p> + <span class="summary_desc"><div class='inline'> +<p>Serializes the graphic frame.</p> </div></span> </li> @@ -284,9 +274,8 @@ Serializes the graphic frame. </p><div class="docstring"> <div class="discussion"> - <p> -Creates a new GraphicFrame object -</p> + +<p>Creates a new GraphicFrame object</p> </div> @@ -326,21 +315,20 @@ Creates a new GraphicFrame object <pre class="lines"> -22 -23 -24 -25 -26</pre> +18 +19 +20 +21 +22</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/graphic_frame.rb', line 22</span> - -<span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span><span class='lparen token'>(</span><span class='anchor identifier id'>anchor</span><span class='comma token'>,</span> <span class='chart_type identifier id'>chart_type</span><span class='comma token'>,</span> <span class='options identifier id'>options</span><span class='rparen token'>)</span> - <span class='DataTypeValidator constant id'>DataTypeValidator</span><span class='dot token'>.</span><span class='validate identifier id'>validate</span> <span class='string val'>"Drawing.chart_type"</span><span class='comma token'>,</span> <span class='Chart constant id'>Chart</span><span class='comma token'>,</span> <span class='chart_type identifier id'>chart_type</span> - <span class='@anchor ivar id'>@anchor</span> <span class='assign token'>=</span> <span class='anchor identifier id'>anchor</span> - <span class='@chart ivar id'>@chart</span> <span class='assign token'>=</span> <span class='chart_type identifier id'>chart_type</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='self self kw'>self</span><span class='comma token'>,</span> <span class='options identifier id'>options</span><span class='rparen token'>)</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/graphic_frame.rb', line 18</span> + +<span class='kw'>def</span> <span class='id initialize'>initialize</span><span class='lparen'>(</span><span class='id anchor'>anchor</span><span class='comma'>,</span> <span class='id chart_type'>chart_type</span><span class='comma'>,</span> <span class='id options'>options</span><span class='rparen'>)</span> + <span class='const'>DataTypeValidator</span><span class='period'>.</span><span class='id validate'>validate</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Drawing.chart_type</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='const'>Chart</span><span class='comma'>,</span> <span class='id chart_type'>chart_type</span> + <span class='ivar'>@anchor</span> <span class='op'>=</span> <span class='id anchor'>anchor</span> + <span class='ivar'>@chart</span> <span class='op'>=</span> <span class='id chart_type'>chart_type</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='kw'>self</span><span class='comma'>,</span> <span class='id options'>options</span><span class='rparen'>)</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -363,9 +351,8 @@ Creates a new GraphicFrame object </p><div class="docstring"> <div class="discussion"> - <p> -A anchor that holds this frame -</p> + +<p>A anchor that holds this frame</p> </div> @@ -399,10 +386,9 @@ A anchor that holds this frame <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/graphic_frame.rb', line 13</span> -<span class='def def kw'>def</span> <span class='anchor identifier id'>anchor</span> - <span class='@anchor ivar id'>@anchor</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id anchor'>anchor</span> + <span class='ivar'>@anchor</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -420,9 +406,8 @@ A anchor that holds this frame </p><div class="docstring"> <div class="discussion"> - <p> -A reference to the chart object associated with this frame -</p> + +<p>A reference to the chart object associated with this frame</p> </div> @@ -456,30 +441,32 @@ A reference to the chart object associated with this frame <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/graphic_frame.rb', line 9</span> -<span class='def def kw'>def</span> <span class='chart identifier id'>chart</span> - <span class='@chart ivar id'>@chart</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id chart'>chart</span> + <span class='ivar'>@chart</span> +<span class='kw'>end</span></pre> </td> </tr> </table> </div> - - <span id=""></span> - <span id="rId-instance_method"></span> - <div class="method_details "> - <p class="signature " id="rId-instance_method"> + </div> + + + <div id="instance_method_details" class="method_details_list"> + <h2>Instance Method Details</h2> + + + <div class="method_details first"> + <p class="signature first" id="rId-instance_method"> - - (<tt>String</tt>) <strong>rId</strong> <span class="extras">(readonly)</span> + - (<tt>String</tt>) <strong>rId</strong> </p><div class="docstring"> <div class="discussion"> - <p> -The relationship id for this graphic -</p> + +<p>The relationship id for this graphic</p> </div> @@ -506,31 +493,23 @@ The relationship id for this graphic <pre class="lines"> -17 -18 -19</pre> +26 +27 +28</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/graphic_frame.rb', line 17</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/graphic_frame.rb', line 26</span> -<span class='def def kw'>def</span> <span class='rId identifier id'>rId</span> - <span class='dstring node'>"rId#{@anchor.index+1}"</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id rId'>rId</span> + <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>rId</span><span class='embexpr_beg'>#{</span><span class='ivar'>@anchor</span><span class='period'>.</span><span class='id index'>index</span><span class='op'>+</span><span class='int'>1</span><span class='rbrace'>}</span><span class='tstring_end'>"</span></span> +<span class='kw'>end</span></pre> </td> </tr> </table> </div> - </div> - - - <div id="instance_method_details" class="method_details_list"> - <h2>Instance Method Details</h2> - - - <div class="method_details first"> - <p class="signature first" id="to_xml-instance_method"> + <div class="method_details "> + <p class="signature " id="to_xml-instance_method"> - (<tt>String</tt>) <strong>to_xml</strong>(xml) @@ -538,9 +517,8 @@ The relationship id for this graphic </p><div class="docstring"> <div class="discussion"> - <p> -Serializes the graphic frame -</p> + +<p>Serializes the graphic frame</p> </div> @@ -559,9 +537,8 @@ Serializes the graphic frame — - <div class='inline'><p> -The document builder instance this objects xml will be added to. -</p> + <div class='inline'> +<p>The document builder instance this objects xml will be added to.</p> </div> </li> @@ -588,6 +565,8 @@ The document builder instance this objects xml will be added to. <pre class="lines"> +33 +34 35 36 37 @@ -603,32 +582,29 @@ The document builder instance this objects xml will be added to. 47 48 49 -50 -51 -52</pre> +50</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/graphic_frame.rb', line 35</span> - -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'xdr:graphicFrame'</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'xdr:nvGraphicFramePr'</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'xdr:cNvPr'</span><span class='comma token'>,</span> <span class='symbol val'>:id=</span><span class='gt op'>></span><span class='integer val'>2</span><span class='comma token'>,</span> <span class='symbol val'>:name=</span><span class='gt op'>></span><span class='chart identifier id'>chart</span><span class='dot token'>.</span><span class='title identifier id'>title</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'xdr:cNvGraphicFramePr'</span><span class='rparen token'>)</span> - <span class='rbrace token'>}</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'xdr:xfrm'</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'a:off'</span><span class='comma token'>,</span> <span class='symbol val'>:x=</span><span class='gt op'>></span><span class='integer val'>0</span><span class='comma token'>,</span> <span class='symbol val'>:y=</span><span class='gt op'>></span><span class='integer val'>0</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'a:ext'</span><span class='comma token'>,</span> <span class='symbol val'>:cx=</span><span class='gt op'>></span><span class='integer val'>0</span><span class='comma token'>,</span> <span class='symbol val'>:cy=</span><span class='gt op'>></span><span class='integer val'>0</span><span class='rparen token'>)</span> - <span class='rbrace token'>}</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'a:graphic'</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'a:graphicData'</span><span class='comma token'>,</span> <span class='symbol val'>:uri=</span><span class='gt op'>></span><span class='XML_NS_C constant id'>XML_NS_C</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:chart'</span><span class='comma token'>,</span> <span class='symbol val'>:'xmlns:c'</span><span class='assign token'>=</span><span class='gt op'>></span><span class='XML_NS_C constant id'>XML_NS_C</span><span class='comma token'>,</span> <span class='symbol val'>:'xmlns:r'</span><span class='assign token'>=</span><span class='gt op'>></span><span class='XML_NS_R constant id'>XML_NS_R</span><span class='comma token'>,</span> <span class='symbol val'>:'r:id'</span><span class='assign token'>=</span><span class='gt op'>></span><span class='rId identifier id'>rId</span><span class='rparen token'>)</span> - <span class='rbrace token'>}</span> - <span class='rbrace token'>}</span> - <span class='rbrace token'>}</span> - -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/graphic_frame.rb', line 33</span> + +<span class='kw'>def</span> <span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>xdr:graphicFrame</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>xdr:nvGraphicFramePr</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>xdr:cNvPr</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:id</span><span class='op'>=></span><span class='int'>2</span><span class='comma'>,</span> <span class='symbol'>:name</span><span class='op'>=></span><span class='id chart'>chart</span><span class='period'>.</span><span class='id title'>title</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>xdr:cNvGraphicFramePr</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> + <span class='rbrace'>}</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>xdr:xfrm</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>a:off</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:x</span><span class='op'>=></span><span class='int'>0</span><span class='comma'>,</span> <span class='symbol'>:y</span><span class='op'>=></span><span class='int'>0</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>a:ext</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:cx</span><span class='op'>=></span><span class='int'>0</span><span class='comma'>,</span> <span class='symbol'>:cy</span><span class='op'>=></span><span class='int'>0</span><span class='rparen'>)</span> + <span class='rbrace'>}</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>a:graphic</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>a:graphicData</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:uri</span><span class='op'>=></span><span class='const'>XML_NS_C</span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:chart</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:xmlns:c</span><span class='tstring_end'>'</span></span><span class='op'>=></span><span class='const'>XML_NS_C</span><span class='comma'>,</span> <span class='symbol'>:xmlns:r</span><span class='tstring_end'>'</span></span><span class='op'>=></span><span class='const'>XML_NS_R</span><span class='comma'>,</span> <span class='symbol'>:r:id</span><span class='tstring_end'>'</span></span><span class='op'>=></span><span class='id rId'>rId</span><span class='rparen'>)</span> + <span class='rbrace'>}</span> + <span class='rbrace'>}</span> + <span class='rbrace'>}</span> + +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -639,9 +615,9 @@ The document builder instance this objects xml will be added to. </div> <div id="footer"> - Generated on Wed Nov 23 22:20:51 2011 by + Generated on Sat Nov 26 13:16:38 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/Line3DChart.html b/doc/Axlsx/Line3DChart.html index 2fd3d0b2..cdb85a73 100644 --- a/doc/Axlsx/Line3DChart.html +++ b/doc/Axlsx/Line3DChart.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::Line3DChart - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -96,10 +96,9 @@ <h2>Overview</h2><div class="docstring"> <div class="discussion"> - <p> -The Line3DChart is a three dimentional line chart (who would have guessed?) -that you can add to your worksheet. -</p> + +<p>The Line3DChart is a three dimentional line chart (who would have guessed?) +that you can add to your worksheet.</p> </div> @@ -109,21 +108,19 @@ that you can add to your worksheet. <div class="examples"> <h3>Examples:</h3> - <h4><div class='inline'><p> -Creating a chart -</p> + <h4><div class='inline'> +<p>Creating a chart</p> </div></h4> - <pre class="example code"><span class='comment val'># This example creates a line in a single sheet.</span> -<span class='require identifier id'>require</span> <span class='string val'>"rubygems"</span> <span class='comment val'># if that is your preferred way to manage gems!</span> -<span class='require identifier id'>require</span> <span class='string val'>"axlsx"</span> + <pre class="example code"><span class='comment'># This example creates a line in a single sheet. +</span><span class='id require'>require</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>rubygems</span><span class='tstring_end'>"</span></span> <span class='comment'># if that is your preferred way to manage gems! +</span><span class='id require'>require</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>axlsx</span><span class='tstring_end'>"</span></span> -<span class='p identifier id'>p</span> <span class='assign token'>=</span> <span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='Package constant id'>Package</span><span class='dot token'>.</span><span class='new identifier id'>new</span> -<span class='ws identifier id'>ws</span> <span class='assign token'>=</span> <span class='p identifier id'>p</span><span class='dot token'>.</span><span class='workbook identifier id'>workbook</span><span class='dot token'>.</span><span class='add_worksheet identifier id'>add_worksheet</span> -<span class='ws identifier id'>ws</span><span class='dot token'>.</span><span class='add_row identifier id'>add_row</span> <span class='symbol val'>:values</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='lbrack token'>[</span><span class='string val'>"This is a chart with no data in the sheet"</span><span class='rbrack token'>]</span> +<span class='id p'>p</span> <span class='op'>=</span> <span class='const'>Axlsx</span><span class='op'>::</span><span class='const'>Package</span><span class='period'>.</span><span class='id new'>new</span> +<span class='id ws'>ws</span> <span class='op'>=</span> <span class='id p'>p</span><span class='period'>.</span><span class='id workbook'>workbook</span><span class='period'>.</span><span class='id add_worksheet'>add_worksheet</span> +<span class='id ws'>ws</span><span class='period'>.</span><span class='id add_row'>add_row</span> <span class='symbol'>:values</span> <span class='op'>=></span> <span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>This is a chart with no data in the sheet</span><span class='tstring_end'>"</span></span><span class='rbracket'>]</span> -<span class='chart identifier id'>chart</span> <span class='assign token'>=</span> <span class='ws identifier id'>ws</span><span class='dot token'>.</span><span class='add_chart identifier id'>add_chart</span><span class='lparen token'>(</span><span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='Line3DChart constant id'>Line3DChart</span><span class='comma token'>,</span> <span class='symbol val'>:start_at=</span><span class='gt op'>></span> <span class='lbrack token'>[</span><span class='integer val'>0</span><span class='comma token'>,</span><span class='integer val'>1</span><span class='rbrack token'>]</span><span class='comma token'>,</span> <span class='symbol val'>:end_at=</span><span class='gt op'>></span><span class='lbrack token'>[</span><span class='integer val'>0</span><span class='comma token'>,</span><span class='integer val'>6</span><span class='rbrack token'>]</span><span class='comma token'>,</span> <span class='symbol val'>:title=</span><span class='gt op'>></span><span class='string val'>"Most Popular Pets"</span><span class='rparen token'>)</span> -<span class='chart identifier id'>chart</span><span class='dot token'>.</span><span class='add_series identifier id'>add_series</span> <span class='symbol val'>:data</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='lbrack token'>[</span><span class='integer val'>1</span><span class='comma token'>,</span> <span class='integer val'>9</span><span class='comma token'>,</span> <span class='integer val'>10</span><span class='rbrack token'>]</span><span class='comma token'>,</span> <span class='symbol val'>:labels</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='lbrack token'>[</span><span class='string val'>"Slimy Reptiles"</span><span class='comma token'>,</span> <span class='string val'>"Fuzzy Bunnies"</span><span class='comma token'>,</span> <span class='string val'>"Rottweiler"</span><span class='rbrack token'>]</span> -</pre> +<span class='id chart'>chart</span> <span class='op'>=</span> <span class='id ws'>ws</span><span class='period'>.</span><span class='id add_chart'>add_chart</span><span class='lparen'>(</span><span class='const'>Axlsx</span><span class='op'>::</span><span class='const'>Line3DChart</span><span class='comma'>,</span> <span class='symbol'>:start_at</span><span class='op'>=></span> <span class='lbracket'>[</span><span class='int'>0</span><span class='comma'>,</span><span class='int'>1</span><span class='rbracket'>]</span><span class='comma'>,</span> <span class='symbol'>:end_at</span><span class='op'>=></span><span class='lbracket'>[</span><span class='int'>0</span><span class='comma'>,</span><span class='int'>6</span><span class='rbracket'>]</span><span class='comma'>,</span> <span class='symbol'>:title</span><span class='op'>=></span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Most Popular Pets</span><span class='tstring_end'>"</span></span><span class='rparen'>)</span> +<span class='id chart'>chart</span><span class='period'>.</span><span class='id add_series'>add_series</span> <span class='symbol'>:data</span> <span class='op'>=></span> <span class='lbracket'>[</span><span class='int'>1</span><span class='comma'>,</span> <span class='int'>9</span><span class='comma'>,</span> <span class='int'>10</span><span class='rbracket'>]</span><span class='comma'>,</span> <span class='symbol'>:labels</span> <span class='op'>=></span> <span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Slimy Reptiles</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Fuzzy Bunnies</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Rottweiler</span><span class='tstring_end'>"</span></span><span class='rbracket'>]</span></pre> </div> @@ -151,9 +148,8 @@ Creating a chart <dt id="GAP_AMOUNT_PERCENT-constant" class="">GAP_AMOUNT_PERCENT = <div class="docstring"> <div class="discussion"> - <p> -validation regex for gap amount percent -</p> + +<p>validation regex for gap amount percent</p> </div> @@ -163,8 +159,7 @@ validation regex for gap amount percent </div> </dt> - <dd><pre class="code"><span class='regexp val'>/0*(([0-9])|([1-9][0-9])|([1-4][0-9][0-9])|500)%/</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='regexp_beg'>/</span><span class='tstring_content'>0*(([0-9])|([1-9][0-9])|([1-4][0-9][0-9])|500)%</span><span class='regexp_end'>/</span></span></pre></dd> </dl> @@ -196,9 +191,8 @@ validation regex for gap amount percent - <span class="summary_desc"><div class='inline'><p> -the category axis. -</p> + <span class="summary_desc"><div class='inline'> +<p>the category axis.</p> </div></span> </li> @@ -223,10 +217,9 @@ the category axis. - <span class="summary_desc"><div class='inline'><p> -space between bar or column clusters, as a percentage of the bar or column -width. -</p> + <span class="summary_desc"><div class='inline'> +<p>space between bar or column clusters, as a percentage of the bar or column +width.</p> </div></span> </li> @@ -251,9 +244,8 @@ width. - <span class="summary_desc"><div class='inline'><p> -grouping for a column, line, or area chart. -</p> + <span class="summary_desc"><div class='inline'> +<p>grouping for a column, line, or area chart.</p> </div></span> </li> @@ -278,9 +270,8 @@ grouping for a column, line, or area chart. - <span class="summary_desc"><div class='inline'><p> -the category axis. -</p> + <span class="summary_desc"><div class='inline'> +<p>the category axis.</p> </div></span> </li> @@ -305,9 +296,8 @@ the category axis. - <span class="summary_desc"><div class='inline'><p> -the category axis. -</p> + <span class="summary_desc"><div class='inline'> +<p>the category axis.</p> </div></span> </li> @@ -323,7 +313,7 @@ the category axis. <h3 class="inherited">Attributes inherited from <span class='object_link'><a href="Chart.html" title="Axlsx::Chart (class)">Chart</a></span></h3> - <p class="inherited"><span class='object_link'><a href="Chart.html#graphic_frame-instance_method" title="Axlsx::Chart#graphic_frame (method)">graphic_frame</a></span>, <span class='object_link'><a href="Chart.html#index-instance_method" title="Axlsx::Chart#index (method)">index</a></span>, <span class='object_link'><a href="Chart.html#pn-instance_method" title="Axlsx::Chart#pn (method)">pn</a></span>, <span class='object_link'><a href="Chart.html#series-instance_method" title="Axlsx::Chart#series (method)">series</a></span>, <span class='object_link'><a href="Chart.html#series_type-instance_method" title="Axlsx::Chart#series_type (method)">series_type</a></span>, <span class='object_link'><a href="Chart.html#show_legend-instance_method" title="Axlsx::Chart#show_legend (method)">show_legend</a></span>, <span class='object_link'><a href="Chart.html#style-instance_method" title="Axlsx::Chart#style (method)">style</a></span>, <span class='object_link'><a href="Chart.html#title-instance_method" title="Axlsx::Chart#title (method)">title</a></span>, <span class='object_link'><a href="Chart.html#view3D-instance_method" title="Axlsx::Chart#view3D (method)">view3D</a></span></p> + <p class="inherited"><span class='object_link'><a href="Chart.html#graphic_frame-instance_method" title="Axlsx::Chart#graphic_frame (method)">graphic_frame</a></span>, <span class='object_link'><a href="Chart.html#series-instance_method" title="Axlsx::Chart#series (method)">series</a></span>, <span class='object_link'><a href="Chart.html#series_type-instance_method" title="Axlsx::Chart#series_type (method)">series_type</a></span>, <span class='object_link'><a href="Chart.html#show_legend-instance_method" title="Axlsx::Chart#show_legend (method)">show_legend</a></span>, <span class='object_link'><a href="Chart.html#style-instance_method" title="Axlsx::Chart#style (method)">style</a></span>, <span class='object_link'><a href="Chart.html#title-instance_method" title="Axlsx::Chart#title (method)">title</a></span>, <span class='object_link'><a href="Chart.html#view3D-instance_method" title="Axlsx::Chart#view3D (method)">view3D</a></span></p> @@ -352,9 +342,8 @@ the category axis. - <span class="summary_desc"><div class='inline'><p> -Creates a new line chart object. -</p> + <span class="summary_desc"><div class='inline'> +<p>Creates a new line chart object.</p> </div></span> </li> @@ -376,9 +365,8 @@ Creates a new line chart object. - <span class="summary_desc"><div class='inline'><p> -Serializes the bar chart. -</p> + <span class="summary_desc"><div class='inline'> +<p>Serializes the bar chart.</p> </div></span> </li> @@ -396,7 +384,7 @@ Serializes the bar chart. <h3 class="inherited">Methods inherited from <span class='object_link'><a href="Chart.html" title="Axlsx::Chart (class)">Chart</a></span></h3> - <p class="inherited"><span class='object_link'><a href="Chart.html#add_series-instance_method" title="Axlsx::Chart#add_series (method)">#add_series</a></span>, <span class='object_link'><a href="Chart.html#end_at-instance_method" title="Axlsx::Chart#end_at (method)">#end_at</a></span>, <span class='object_link'><a href="Chart.html#from-instance_method" title="Axlsx::Chart#from (method)">#from</a></span>, <span class='object_link'><a href="Chart.html#start_at-instance_method" title="Axlsx::Chart#start_at (method)">#start_at</a></span>, <span class='object_link'><a href="Chart.html#to-instance_method" title="Axlsx::Chart#to (method)">#to</a></span></p> + <p class="inherited"><span class='object_link'><a href="Chart.html#add_series-instance_method" title="Axlsx::Chart#add_series (method)">#add_series</a></span>, <span class='object_link'><a href="Chart.html#end_at-instance_method" title="Axlsx::Chart#end_at (method)">#end_at</a></span>, <span class='object_link'><a href="Chart.html#from-instance_method" title="Axlsx::Chart#from (method)">#from</a></span>, <span class='object_link'><a href="Chart.html#index-instance_method" title="Axlsx::Chart#index (method)">#index</a></span>, <span class='object_link'><a href="Chart.html#pn-instance_method" title="Axlsx::Chart#pn (method)">#pn</a></span>, <span class='object_link'><a href="Chart.html#start_at-instance_method" title="Axlsx::Chart#start_at (method)">#start_at</a></span>, <span class='object_link'><a href="Chart.html#to-instance_method" title="Axlsx::Chart#to (method)">#to</a></span></p> <div id="constructor_details" class="method_details_list"> <h2>Constructor Details</h2> @@ -409,9 +397,8 @@ Serializes the bar chart. </p><div class="docstring"> <div class="discussion"> - <p> -Creates a new line chart object -</p> + +<p>Creates a new line chart object</p> </div> @@ -430,9 +417,8 @@ Creates a new line chart object — - <div class='inline'><p> -The workbook that owns this chart. -</p> + <div class='inline'> +<p>The workbook that owns this chart.</p> </div> </li> @@ -449,9 +435,8 @@ The workbook that owns this chart. — - <div class='inline'><p> -a customizable set of options -</p> + <div class='inline'> +<p>a customizable set of options</p> </div> </li> @@ -586,24 +571,25 @@ a customizable set of options 69 70 71 -72</pre> +72 +73</pre> </td> <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/line_3D_chart.rb', line 61</span> -<span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span><span class='lparen token'>(</span><span class='frame identifier id'>frame</span><span class='comma token'>,</span> <span class='options identifier id'>options</span><span class='assign token'>=</span><span class='lbrace token'>{</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> - <span class='@grouping ivar id'>@grouping</span> <span class='assign token'>=</span> <span class='symbol val'>:standard</span> - <span class='@catAxId ivar id'>@catAxId</span> <span class='assign token'>=</span> <span class='rand identifier id'>rand</span><span class='lparen token'>(</span><span class='integer val'>8</span> <span class='pow op'>**</span> <span class='integer val'>8</span><span class='rparen token'>)</span> - <span class='@valAxId ivar id'>@valAxId</span> <span class='assign token'>=</span> <span class='rand identifier id'>rand</span><span class='lparen token'>(</span><span class='integer val'>8</span> <span class='pow op'>**</span> <span class='integer val'>8</span><span class='rparen token'>)</span> - <span class='@serAxId ivar id'>@serAxId</span> <span class='assign token'>=</span> <span class='rand identifier id'>rand</span><span class='lparen token'>(</span><span class='integer val'>8</span> <span class='pow op'>**</span> <span class='integer val'>8</span><span class='rparen token'>)</span> - <span class='@catAxis ivar id'>@catAxis</span> <span class='assign token'>=</span> <span class='CatAxis constant id'>CatAxis</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='@catAxId ivar id'>@catAxId</span><span class='comma token'>,</span> <span class='@valAxId ivar id'>@valAxId</span><span class='rparen token'>)</span> - <span class='@valAxis ivar id'>@valAxis</span> <span class='assign token'>=</span> <span class='ValAxis constant id'>ValAxis</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='@valAxId ivar id'>@valAxId</span><span class='comma token'>,</span> <span class='@catAxId ivar id'>@catAxId</span><span class='rparen token'>)</span> - <span class='@serAxis ivar id'>@serAxis</span> <span class='assign token'>=</span> <span class='SerAxis constant id'>SerAxis</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='@serAxId ivar id'>@serAxId</span><span class='comma token'>,</span> <span class='@valAxId ivar id'>@valAxId</span><span class='rparen token'>)</span> - <span class='super super kw'>super</span><span class='lparen token'>(</span><span class='frame identifier id'>frame</span><span class='comma token'>,</span> <span class='options identifier id'>options</span><span class='rparen token'>)</span> - <span class='@series_type ivar id'>@series_type</span> <span class='assign token'>=</span> <span class='LineSeries constant id'>LineSeries</span> - <span class='@view3D ivar id'>@view3D</span> <span class='assign token'>=</span> <span class='View3D constant id'>View3D</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='lbrace token'>{</span><span class='symbol val'>:perspective=</span><span class='gt op'>></span><span class='integer val'>30</span><span class='rbrace token'>}</span><span class='dot token'>.</span><span class='merge identifier id'>merge</span><span class='lparen token'>(</span><span class='options identifier id'>options</span><span class='rparen token'>)</span><span class='rparen token'>)</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id initialize'>initialize</span><span class='lparen'>(</span><span class='id frame'>frame</span><span class='comma'>,</span> <span class='id options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span> + <span class='ivar'>@gapDepth</span> <span class='op'>=</span> <span class='kw'>nil</span> + <span class='ivar'>@grouping</span> <span class='op'>=</span> <span class='symbol'>:standard</span> + <span class='ivar'>@catAxId</span> <span class='op'>=</span> <span class='id rand'>rand</span><span class='lparen'>(</span><span class='int'>8</span> <span class='op'>**</span> <span class='int'>8</span><span class='rparen'>)</span> + <span class='ivar'>@valAxId</span> <span class='op'>=</span> <span class='id rand'>rand</span><span class='lparen'>(</span><span class='int'>8</span> <span class='op'>**</span> <span class='int'>8</span><span class='rparen'>)</span> + <span class='ivar'>@serAxId</span> <span class='op'>=</span> <span class='id rand'>rand</span><span class='lparen'>(</span><span class='int'>8</span> <span class='op'>**</span> <span class='int'>8</span><span class='rparen'>)</span> + <span class='ivar'>@catAxis</span> <span class='op'>=</span> <span class='const'>CatAxis</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='ivar'>@catAxId</span><span class='comma'>,</span> <span class='ivar'>@valAxId</span><span class='rparen'>)</span> + <span class='ivar'>@valAxis</span> <span class='op'>=</span> <span class='const'>ValAxis</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='ivar'>@valAxId</span><span class='comma'>,</span> <span class='ivar'>@catAxId</span><span class='rparen'>)</span> + <span class='ivar'>@serAxis</span> <span class='op'>=</span> <span class='const'>SerAxis</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='ivar'>@serAxId</span><span class='comma'>,</span> <span class='ivar'>@valAxId</span><span class='rparen'>)</span> + <span class='kw'>super</span><span class='lparen'>(</span><span class='id frame'>frame</span><span class='comma'>,</span> <span class='id options'>options</span><span class='rparen'>)</span> + <span class='ivar'>@series_type</span> <span class='op'>=</span> <span class='const'>LineSeries</span> + <span class='ivar'>@view3D</span> <span class='op'>=</span> <span class='const'>View3D</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='lbrace'>{</span><span class='symbol'>:perspective</span><span class='op'>=></span><span class='int'>30</span><span class='rbrace'>}</span><span class='period'>.</span><span class='id merge'>merge</span><span class='lparen'>(</span><span class='id options'>options</span><span class='rparen'>)</span><span class='rparen'>)</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -626,9 +612,8 @@ a customizable set of options </p><div class="docstring"> <div class="discussion"> - <p> -the category axis -</p> + +<p>the category axis</p> </div> @@ -662,10 +647,9 @@ the category axis <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/line_3D_chart.rb', line 25</span> -<span class='def def kw'>def</span> <span class='catAxis identifier id'>catAxis</span> - <span class='@catAxis ivar id'>@catAxis</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id catAxis'>catAxis</span> + <span class='ivar'>@catAxis</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -683,10 +667,9 @@ the category axis </p><div class="docstring"> <div class="discussion"> - <p> -space between bar or column clusters, as a percentage of the bar or column -width. -</p> + +<p>space between bar or column clusters, as a percentage of the bar or column +width.</p> </div> @@ -720,10 +703,9 @@ width. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/line_3D_chart.rb', line 37</span> -<span class='def def kw'>def</span> <span class='gapDepth identifier id'>gapDepth</span> - <span class='@gapDepth ivar id'>@gapDepth</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id gapDepth'>gapDepth</span> + <span class='ivar'>@gapDepth</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -741,10 +723,9 @@ width. </p><div class="docstring"> <div class="discussion"> - <p> -grouping for a column, line, or area chart. must be one of -[:percentStacked, :clustered, :standard, :stacked] -</p> + +<p>grouping for a column, line, or area chart. must be one of +[:percentStacked, :clustered, :standard, :stacked]</p> </div> @@ -778,10 +759,9 @@ grouping for a column, line, or area chart. must be one of <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/line_3D_chart.rb', line 42</span> -<span class='def def kw'>def</span> <span class='grouping identifier id'>grouping</span> - <span class='@grouping ivar id'>@grouping</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id grouping'>grouping</span> + <span class='ivar'>@grouping</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -799,9 +779,8 @@ grouping for a column, line, or area chart. must be one of </p><div class="docstring"> <div class="discussion"> - <p> -the category axis -</p> + +<p>the category axis</p> </div> @@ -835,10 +814,9 @@ the category axis <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/line_3D_chart.rb', line 33</span> -<span class='def def kw'>def</span> <span class='serAxis identifier id'>serAxis</span> - <span class='@serAxis ivar id'>@serAxis</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id serAxis'>serAxis</span> + <span class='ivar'>@serAxis</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -856,9 +834,8 @@ the category axis </p><div class="docstring"> <div class="discussion"> - <p> -the category axis -</p> + +<p>the category axis</p> </div> @@ -892,10 +869,9 @@ the category axis <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/line_3D_chart.rb', line 29</span> -<span class='def def kw'>def</span> <span class='valAxis identifier id'>valAxis</span> - <span class='@valAxis ivar id'>@valAxis</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id valAxis'>valAxis</span> + <span class='ivar'>@valAxis</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -917,9 +893,8 @@ the category axis </p><div class="docstring"> <div class="discussion"> - <p> -Serializes the bar chart -</p> + +<p>Serializes the bar chart</p> </div> @@ -946,9 +921,6 @@ Serializes the bar chart <pre class="lines"> -86 -87 -88 89 90 91 @@ -961,28 +933,30 @@ Serializes the bar chart 98 99 100 -101</pre> +101 +102 +103 +104</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/line_3D_chart.rb', line 86</span> - -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span> - <span class='super super kw'>super</span><span class='lparen token'>(</span><span class='rparen token'>)</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='xml identifier id'>xml</span><span class='bitor op'>|</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:line3DChart'</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:grouping'</span><span class='comma token'>,</span> <span class='symbol val'>:val=</span><span class='gt op'>></span><span class='grouping identifier id'>grouping</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:varyColors'</span><span class='comma token'>,</span> <span class='symbol val'>:val=</span><span class='gt op'>></span><span class='integer val'>1</span><span class='rparen token'>)</span> - <span class='@series ivar id'>@series</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='lbrace token'>{</span> <span class='bitor op'>|</span><span class='ser identifier id'>ser</span><span class='bitor op'>|</span> <span class='ser identifier id'>ser</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> <span class='rbrace token'>}</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:gapDepth'</span><span class='comma token'>,</span> <span class='symbol val'>:val=</span><span class='gt op'>></span><span class='@gapDepth ivar id'>@gapDepth</span><span class='rparen token'>)</span> <span class='unless unless_mod kw'>unless</span> <span class='@gapDepth ivar id'>@gapDepth</span><span class='dot token'>.</span><span class='nil? fid id'>nil?</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:axId'</span><span class='comma token'>,</span> <span class='symbol val'>:val=</span><span class='gt op'>></span><span class='@catAxId ivar id'>@catAxId</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:axId'</span><span class='comma token'>,</span> <span class='symbol val'>:val=</span><span class='gt op'>></span><span class='@valAxId ivar id'>@valAxId</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:axId'</span><span class='comma token'>,</span> <span class='symbol val'>:val=</span><span class='gt op'>></span><span class='@serAxId ivar id'>@serAxId</span><span class='rparen token'>)</span> - <span class='rbrace token'>}</span> - <span class='@catAxis ivar id'>@catAxis</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='@valAxis ivar id'>@valAxis</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='@serAxis ivar id'>@serAxis</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='end end kw'>end</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/line_3D_chart.rb', line 89</span> + +<span class='kw'>def</span> <span class='id to_xml'>to_xml</span> + <span class='kw'>super</span><span class='lparen'>(</span><span class='rparen'>)</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id xml'>xml</span><span class='op'>|</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:line3DChart</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:grouping</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:val</span><span class='op'>=></span><span class='id grouping'>grouping</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:varyColors</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:val</span><span class='op'>=></span><span class='int'>1</span><span class='rparen'>)</span> + <span class='ivar'>@series</span><span class='period'>.</span><span class='id each'>each</span> <span class='lbrace'>{</span> <span class='op'>|</span><span class='id ser'>ser</span><span class='op'>|</span> <span class='id ser'>ser</span><span class='period'>.</span><span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> <span class='rbrace'>}</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:gapDepth</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:val</span><span class='op'>=></span><span class='ivar'>@gapDepth</span><span class='rparen'>)</span> <span class='kw'>unless</span> <span class='ivar'>@gapDepth</span><span class='period'>.</span><span class='id nil?'>nil?</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:axId</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:val</span><span class='op'>=></span><span class='ivar'>@catAxId</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:axId</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:val</span><span class='op'>=></span><span class='ivar'>@valAxId</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:axId</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:val</span><span class='op'>=></span><span class='ivar'>@serAxId</span><span class='rparen'>)</span> + <span class='rbrace'>}</span> + <span class='ivar'>@catAxis</span><span class='period'>.</span><span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> + <span class='ivar'>@valAxis</span><span class='period'>.</span><span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> + <span class='ivar'>@serAxis</span><span class='period'>.</span><span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> + <span class='kw'>end</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -993,9 +967,9 @@ Serializes the bar chart </div> <div id="footer"> - Generated on Wed Nov 23 22:20:58 2011 by + Generated on Sat Nov 26 13:16:39 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/LineSeries.html b/doc/Axlsx/LineSeries.html index d5cc8c2c..b2d75a69 100644 --- a/doc/Axlsx/LineSeries.html +++ b/doc/Axlsx/LineSeries.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::LineSeries - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -99,15 +99,13 @@ <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -The recommended way to manage series is to use Chart#add_series -</p> + <div class='inline'> +<p>The recommended way to manage series is to use Chart#add_series</p> </div> </div> -<p> -A LineSeries defines the title, data and labels for line charts -</p> + +<p>A LineSeries defines the title, data and labels for line charts</p> </div> @@ -152,9 +150,8 @@ A LineSeries defines the title, data and labels for line charts - <span class="summary_desc"><div class='inline'><p> -The data for this series. -</p> + <span class="summary_desc"><div class='inline'> +<p>The data for this series.</p> </div></span> </li> @@ -179,9 +176,8 @@ The data for this series. - <span class="summary_desc"><div class='inline'><p> -The labels for this series. -</p> + <span class="summary_desc"><div class='inline'> +<p>The labels for this series.</p> </div></span> </li> @@ -197,7 +193,7 @@ The labels for this series. <h3 class="inherited">Attributes inherited from <span class='object_link'><a href="Series.html" title="Axlsx::Series (class)">Series</a></span></h3> - <p class="inherited"><span class='object_link'><a href="Series.html#chart-instance_method" title="Axlsx::Series#chart (method)">chart</a></span>, <span class='object_link'><a href="Series.html#index-instance_method" title="Axlsx::Series#index (method)">index</a></span>, <span class='object_link'><a href="Series.html#order-instance_method" title="Axlsx::Series#order (method)">order</a></span>, <span class='object_link'><a href="Series.html#title-instance_method" title="Axlsx::Series#title (method)">title</a></span></p> + <p class="inherited"><span class='object_link'><a href="Series.html#chart-instance_method" title="Axlsx::Series#chart (method)">chart</a></span>, <span class='object_link'><a href="Series.html#title-instance_method" title="Axlsx::Series#title (method)">title</a></span></p> @@ -226,9 +222,8 @@ The labels for this series. - <span class="summary_desc"><div class='inline'><p> -Creates a new series. -</p> + <span class="summary_desc"><div class='inline'> +<p>Creates a new series.</p> </div></span> </li> @@ -250,9 +245,8 @@ Creates a new series. - <span class="summary_desc"><div class='inline'><p> -Serializes the series. -</p> + <span class="summary_desc"><div class='inline'> +<p>Serializes the series.</p> </div></span> </li> @@ -266,7 +260,12 @@ Serializes the series. - <div id="constructor_details" class="method_details_list"> + + + + <h3 class="inherited">Methods inherited from <span class='object_link'><a href="Series.html" title="Axlsx::Series (class)">Series</a></span></h3> + <p class="inherited"><span class='object_link'><a href="Series.html#index-instance_method" title="Axlsx::Series#index (method)">#index</a></span>, <span class='object_link'><a href="Series.html#order-instance_method" title="Axlsx::Series#order (method)">#order</a></span>, <span class='object_link'><a href="Series.html#order%3D-instance_method" title="Axlsx::Series#order= (method)">#order=</a></span></p> +<div id="constructor_details" class="method_details_list"> <h2>Constructor Details</h2> <div class="method_details first"> @@ -278,9 +277,8 @@ Serializes the series. </p><div class="docstring"> <div class="discussion"> - <p> -Creates a new series -</p> + +<p>Creates a new series</p> </div> @@ -312,9 +310,8 @@ Creates a new series — - <div class='inline'><p> -a customizable set of options -</p> + <div class='inline'> +<p>a customizable set of options</p> </div> </li> @@ -361,17 +358,18 @@ a customizable set of options 21 22 23 -24</pre> +24 +25</pre> </td> <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/line_series.rb', line 20</span> -<span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span><span class='lparen token'>(</span><span class='chart identifier id'>chart</span><span class='comma token'>,</span> <span class='options identifier id'>options</span><span class='assign token'>=</span><span class='lbrace token'>{</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> - <span class='super super kw'>super</span><span class='lparen token'>(</span><span class='chart identifier id'>chart</span><span class='comma token'>,</span> <span class='options identifier id'>options</span><span class='rparen token'>)</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='labels identifier id'>labels</span> <span class='assign token'>=</span> <span class='CatAxisData constant id'>CatAxisData</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='options identifier id'>options</span><span class='lbrack token'>[</span><span class='symbol val'>:labels</span><span class='rbrack token'>]</span><span class='rparen token'>)</span> <span class='unless unless_mod kw'>unless</span> <span class='options identifier id'>options</span><span class='lbrack token'>[</span><span class='symbol val'>:labels</span><span class='rbrack token'>]</span><span class='dot token'>.</span><span class='nil? fid id'>nil?</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='data identifier id'>data</span> <span class='assign token'>=</span> <span class='ValAxisData constant id'>ValAxisData</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='options identifier id'>options</span><span class='lbrack token'>[</span><span class='symbol val'>:data</span><span class='rbrack token'>]</span><span class='rparen token'>)</span> <span class='unless unless_mod kw'>unless</span> <span class='options identifier id'>options</span><span class='lbrack token'>[</span><span class='symbol val'>:data</span><span class='rbrack token'>]</span><span class='dot token'>.</span><span class='nil? fid id'>nil?</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id initialize'>initialize</span><span class='lparen'>(</span><span class='id chart'>chart</span><span class='comma'>,</span> <span class='id options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span> + <span class='ivar'>@labels</span><span class='comma'>,</span> <span class='ivar'>@data</span> <span class='op'>=</span> <span class='kw'>nil</span><span class='comma'>,</span> <span class='kw'>nil</span> + <span class='kw'>super</span><span class='lparen'>(</span><span class='id chart'>chart</span><span class='comma'>,</span> <span class='id options'>options</span><span class='rparen'>)</span> + <span class='ivar'>@labels</span> <span class='op'>=</span> <span class='const'>CatAxisData</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='id options'>options</span><span class='lbracket'>[</span><span class='symbol'>:labels</span><span class='rbracket'>]</span><span class='rparen'>)</span> <span class='kw'>unless</span> <span class='id options'>options</span><span class='lbracket'>[</span><span class='symbol'>:labels</span><span class='rbracket'>]</span><span class='period'>.</span><span class='id nil?'>nil?</span> + <span class='ivar'>@data</span> <span class='op'>=</span> <span class='const'>ValAxisData</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='id options'>options</span><span class='lbracket'>[</span><span class='symbol'>:data</span><span class='rbracket'>]</span><span class='rparen'>)</span> <span class='kw'>unless</span> <span class='id options'>options</span><span class='lbracket'>[</span><span class='symbol'>:data</span><span class='rbracket'>]</span><span class='period'>.</span><span class='id nil?'>nil?</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -394,9 +392,8 @@ a customizable set of options </p><div class="docstring"> <div class="discussion"> - <p> -The data for this series. -</p> + +<p>The data for this series.</p> </div> @@ -430,10 +427,9 @@ The data for this series. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/line_series.rb', line 10</span> -<span class='def def kw'>def</span> <span class='data identifier id'>data</span> - <span class='@data ivar id'>@data</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id data'>data</span> + <span class='ivar'>@data</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -451,9 +447,8 @@ The data for this series. </p><div class="docstring"> <div class="discussion"> - <p> -The labels for this series. -</p> + +<p>The labels for this series.</p> </div> @@ -487,10 +482,9 @@ The labels for this series. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/line_series.rb', line 14</span> -<span class='def def kw'>def</span> <span class='labels identifier id'>labels</span> - <span class='@labels ivar id'>@labels</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id labels'>labels</span> + <span class='ivar'>@labels</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -512,9 +506,8 @@ The labels for this series. </p><div class="docstring"> <div class="discussion"> - <p> -Serializes the series -</p> + +<p>Serializes the series</p> </div> @@ -533,9 +526,8 @@ Serializes the series — - <div class='inline'><p> -The document builder instance this objects xml will be added to. -</p> + <div class='inline'> +<p>The document builder instance this objects xml will be added to.</p> </div> </li> @@ -562,23 +554,22 @@ The document builder instance this objects xml will be added to. <pre class="lines"> -29 30 31 32 33 -34</pre> +34 +35</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/line_series.rb', line 29</span> - -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='super super kw'>super</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='xml identifier id'>xml</span><span class='bitor op'>|</span> - <span class='@labels ivar id'>@labels</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> <span class='unless unless_mod kw'>unless</span> <span class='@labels ivar id'>@labels</span><span class='dot token'>.</span><span class='nil? fid id'>nil?</span> - <span class='@data ivar id'>@data</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> <span class='unless unless_mod kw'>unless</span> <span class='@data ivar id'>@data</span><span class='dot token'>.</span><span class='nil? fid id'>nil?</span> - <span class='end end kw'>end</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/line_series.rb', line 30</span> + +<span class='kw'>def</span> <span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> + <span class='kw'>super</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id xml_inner'>xml_inner</span><span class='op'>|</span> + <span class='ivar'>@labels</span><span class='period'>.</span><span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml_inner'>xml_inner</span><span class='rparen'>)</span> <span class='kw'>unless</span> <span class='ivar'>@labels</span><span class='period'>.</span><span class='id nil?'>nil?</span> + <span class='ivar'>@data</span><span class='period'>.</span><span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml_inner'>xml_inner</span><span class='rparen'>)</span> <span class='kw'>unless</span> <span class='ivar'>@data</span><span class='period'>.</span><span class='id nil?'>nil?</span> + <span class='kw'>end</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -589,9 +580,9 @@ The document builder instance this objects xml will be added to. </div> <div id="footer"> - Generated on Wed Nov 23 22:20:57 2011 by + Generated on Sat Nov 26 13:16:38 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/Marker.html b/doc/Axlsx/Marker.html index 2c3a2fb6..e58b67ed 100644 --- a/doc/Axlsx/Marker.html +++ b/doc/Axlsx/Marker.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::Marker - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -97,17 +97,15 @@ <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -The recommended way to manage markers is Worksheet#add_chart Markers are -created for a two cell anchor based on the :start and :end options. -</p> + <div class='inline'> +<p>The recommended way to manage markers is Worksheet#add_chart Markers are +created for a two cell anchor based on the :start and :end options.</p> </div> </div> -<p> -The Marker class defines a point in the worksheet that drawing anchors -attach to. -</p> + +<p>The Marker class defines a point in the worksheet that drawing anchors +attach to.</p> </div> @@ -146,9 +144,8 @@ attach to. - <span class="summary_desc"><div class='inline'><p> -The column this marker anchors to. -</p> + <span class="summary_desc"><div class='inline'> +<p>The column this marker anchors to.</p> </div></span> </li> @@ -173,9 +170,8 @@ The column this marker anchors to. - <span class="summary_desc"><div class='inline'><p> -The offset distance from this marker’s column. -</p> + <span class="summary_desc"><div class='inline'> +<p>The offset distance from this marker's column.</p> </div></span> </li> @@ -200,9 +196,8 @@ The offset distance from this marker’s column. - <span class="summary_desc"><div class='inline'><p> -The row this marker anchors to. -</p> + <span class="summary_desc"><div class='inline'> +<p>The row this marker anchors to.</p> </div></span> </li> @@ -227,9 +222,8 @@ The row this marker anchors to. - <span class="summary_desc"><div class='inline'><p> -The offset distance from this marker’s row. -</p> + <span class="summary_desc"><div class='inline'> +<p>The offset distance from this marker's row.</p> </div></span> </li> @@ -264,9 +258,8 @@ The offset distance from this marker’s row. - <span class="summary_desc"><div class='inline'><p> -shortcut to set the column, row position for this marker. -</p> + <span class="summary_desc"><div class='inline'> +<p>shortcut to set the column, row position for this marker.</p> </div></span> </li> @@ -290,9 +283,8 @@ shortcut to set the column, row position for this marker. - <span class="summary_desc"><div class='inline'><p> -Creates a new Marker object. -</p> + <span class="summary_desc"><div class='inline'> +<p>Creates a new Marker object.</p> </div></span> </li> @@ -314,9 +306,8 @@ Creates a new Marker object. - <span class="summary_desc"><div class='inline'><p> -Serializes the marker. -</p> + <span class="summary_desc"><div class='inline'> +<p>Serializes the marker.</p> </div></span> </li> @@ -337,9 +328,8 @@ Serializes the marker. </p><div class="docstring"> <div class="discussion"> - <p> -Creates a new Marker object -</p> + +<p>Creates a new Marker object</p> </div> @@ -360,9 +350,8 @@ Creates a new Marker object — - <div class='inline'><p> -a customizable set of options -</p> + <div class='inline'> +<p>a customizable set of options</p> </div> </li> @@ -431,13 +420,12 @@ a customizable set of options <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/marker.rb', line 28</span> -<span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span><span class='lparen token'>(</span><span class='options identifier id'>options</span><span class='assign token'>=</span><span class='lbrace token'>{</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> - <span class='@col ivar id'>@col</span><span class='comma token'>,</span> <span class='@colOff ivar id'>@colOff</span><span class='comma token'>,</span> <span class='@row ivar id'>@row</span><span class='comma token'>,</span> <span class='@rowOff ivar id'>@rowOff</span> <span class='assign token'>=</span> <span class='integer val'>0</span><span class='comma token'>,</span> <span class='integer val'>0</span><span class='comma token'>,</span> <span class='integer val'>0</span><span class='comma token'>,</span> <span class='integer val'>0</span> - <span class='options identifier id'>options</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='o identifier id'>o</span><span class='bitor op'>|</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='dstring node'>"#{o[0]}="</span><span class='comma token'>,</span> <span class='o identifier id'>o</span><span class='lbrack token'>[</span><span class='integer val'>1</span><span class='rbrack token'>]</span><span class='rparen token'>)</span> <span class='if if_mod kw'>if</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='respond_to? fid id'>respond_to?</span> <span class='o identifier id'>o</span><span class='lbrack token'>[</span><span class='integer val'>0</span><span class='rbrack token'>]</span> - <span class='end end kw'>end</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id initialize'>initialize</span><span class='lparen'>(</span><span class='id options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span> + <span class='ivar'>@col</span><span class='comma'>,</span> <span class='ivar'>@colOff</span><span class='comma'>,</span> <span class='ivar'>@row</span><span class='comma'>,</span> <span class='ivar'>@rowOff</span> <span class='op'>=</span> <span class='int'>0</span><span class='comma'>,</span> <span class='int'>0</span><span class='comma'>,</span> <span class='int'>0</span><span class='comma'>,</span> <span class='int'>0</span> + <span class='id options'>options</span><span class='period'>.</span><span class='id each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id o'>o</span><span class='op'>|</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span><span class='rbrace'>}</span><span class='tstring_content'>=</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>1</span><span class='rbracket'>]</span><span class='rparen'>)</span> <span class='kw'>if</span> <span class='kw'>self</span><span class='period'>.</span><span class='id respond_to?'>respond_to?</span> <span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span> + <span class='kw'>end</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -460,9 +448,8 @@ a customizable set of options </p><div class="docstring"> <div class="discussion"> - <p> -The column this marker anchors to -</p> + +<p>The column this marker anchors to</p> </div> @@ -496,10 +483,9 @@ The column this marker anchors to <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/marker.rb', line 9</span> -<span class='def def kw'>def</span> <span class='col identifier id'>col</span> - <span class='@col ivar id'>@col</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id col'>col</span> + <span class='ivar'>@col</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -517,9 +503,8 @@ The column this marker anchors to </p><div class="docstring"> <div class="discussion"> - <p> -The offset distance from this marker’s column -</p> + +<p>The offset distance from this marker's column</p> </div> @@ -553,10 +538,9 @@ The offset distance from this marker’s column <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/marker.rb', line 13</span> -<span class='def def kw'>def</span> <span class='colOff identifier id'>colOff</span> - <span class='@colOff ivar id'>@colOff</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id colOff'>colOff</span> + <span class='ivar'>@colOff</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -574,9 +558,8 @@ The offset distance from this marker’s column </p><div class="docstring"> <div class="discussion"> - <p> -The row this marker anchors to -</p> + +<p>The row this marker anchors to</p> </div> @@ -610,10 +593,9 @@ The row this marker anchors to <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/marker.rb', line 17</span> -<span class='def def kw'>def</span> <span class='row identifier id'>row</span> - <span class='@row ivar id'>@row</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id row'>row</span> + <span class='ivar'>@row</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -631,9 +613,8 @@ The row this marker anchors to </p><div class="docstring"> <div class="discussion"> - <p> -The offset distance from this marker’s row -</p> + +<p>The offset distance from this marker's row</p> </div> @@ -667,10 +648,9 @@ The offset distance from this marker’s row <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/marker.rb', line 21</span> -<span class='def def kw'>def</span> <span class='rowOff identifier id'>rowOff</span> - <span class='@rowOff ivar id'>@rowOff</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id rowOff'>rowOff</span> + <span class='ivar'>@rowOff</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -692,9 +672,8 @@ The offset distance from this marker’s row </p><div class="docstring"> <div class="discussion"> - <p> -shortcut to set the column, row position for this marker -</p> + +<p>shortcut to set the column, row position for this marker</p> </div> @@ -713,9 +692,8 @@ shortcut to set the column, row position for this marker — - <div class='inline'><p> -the column for the marker -</p> + <div class='inline'> +<p>the column for the marker</p> </div> </li> @@ -730,9 +708,8 @@ the column for the marker — - <div class='inline'><p> -the row of the marker -</p> + <div class='inline'> +<p>the row of the marker</p> </div> </li> @@ -746,19 +723,18 @@ the row of the marker <pre class="lines"> -43 -44 -45 -46</pre> +47 +48 +49 +50</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/marker.rb', line 43</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/marker.rb', line 47</span> -<span class='def def kw'>def</span> <span class='coord identifier id'>coord</span><span class='lparen token'>(</span><span class='col identifier id'>col</span><span class='comma token'>,</span> <span class='row identifier id'>row</span><span class='rparen token'>)</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='col identifier id'>col</span> <span class='assign token'>=</span> <span class='col identifier id'>col</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='row identifier id'>row</span> <span class='assign token'>=</span> <span class='row identifier id'>row</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id coord'>coord</span><span class='lparen'>(</span><span class='id col'>col</span><span class='comma'>,</span> <span class='id row'>row</span><span class='rparen'>)</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id col'>col</span> <span class='op'>=</span> <span class='id col'>col</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id row'>row</span> <span class='op'>=</span> <span class='id row'>row</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -773,9 +749,8 @@ the row of the marker </p><div class="docstring"> <div class="discussion"> - <p> -Serializes the marker -</p> + +<p>Serializes the marker</p> </div> @@ -794,9 +769,8 @@ Serializes the marker — - <div class='inline'><p> -The document builder instance this objects xml will be added to. -</p> + <div class='inline'> +<p>The document builder instance this objects xml will be added to.</p> </div> </li> @@ -823,21 +797,20 @@ The document builder instance this objects xml will be added to. <pre class="lines"> -50 -51 -52 -53 -54</pre> +54 +55 +56 +57 +58</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/marker.rb', line 50</span> - -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='lbrack token'>[</span><span class='symbol val'>:col</span><span class='comma token'>,</span> <span class='symbol val'>:colOff</span><span class='comma token'>,</span> <span class='symbol val'>:row</span><span class='comma token'>,</span> <span class='symbol val'>:rowOff</span><span class='rbrack token'>]</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='k identifier id'>k</span><span class='bitor op'>|</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='dstring node'>"xdr:#{k.to_s}"</span><span class='comma token'>,</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='k identifier id'>k</span><span class='rparen token'>)</span><span class='rparen token'>)</span> - <span class='end end kw'>end</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/marker.rb', line 54</span> + +<span class='kw'>def</span> <span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> + <span class='lbracket'>[</span><span class='symbol'>:col</span><span class='comma'>,</span> <span class='symbol'>:colOff</span><span class='comma'>,</span> <span class='symbol'>:row</span><span class='comma'>,</span> <span class='symbol'>:rowOff</span><span class='rbracket'>]</span><span class='period'>.</span><span class='id each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id k'>k</span><span class='op'>|</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>xdr:</span><span class='embexpr_beg'>#{</span><span class='id k'>k</span><span class='period'>.</span><span class='id to_s'>to_s</span><span class='rbrace'>}</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='kw'>self</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='id k'>k</span><span class='rparen'>)</span><span class='rparen'>)</span> + <span class='kw'>end</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -848,9 +821,9 @@ The document builder instance this objects xml will be added to. </div> <div id="footer"> - Generated on Wed Nov 23 22:21:03 2011 by + Generated on Sat Nov 26 13:16:37 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/NumFmt.html b/doc/Axlsx/NumFmt.html index e035b3b5..b308d6dc 100644 --- a/doc/Axlsx/NumFmt.html +++ b/doc/Axlsx/NumFmt.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::NumFmt - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -97,16 +97,14 @@ <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -The recommended way to manage styles is Styles#add_style -</p> + <div class='inline'> +<p>The recommended way to manage styles is Styles#add_style</p> </div> </div> -<p> -A NumFmt object defines an identifier and formatting code for data in -cells. -</p> + +<p>A NumFmt object defines an identifier and formatting code for data in +cells.</p> </div> @@ -138,9 +136,8 @@ cells. - <span class="summary_desc"><div class='inline'><p> -The formatting to use for this number format. -</p> + <span class="summary_desc"><div class='inline'> +<p>The formatting to use for this number format.</p> </div></span> </li> @@ -165,9 +162,8 @@ The formatting to use for this number format. - <span class="summary_desc"><div class='inline'><p> -An unsinged integer referencing a standard or custom number format. -</p> + <span class="summary_desc"><div class='inline'> +<p>An unsinged integer referencing a standard or custom number format.</p> </div></span> </li> @@ -204,9 +200,8 @@ An unsinged integer referencing a standard or custom number format. - <span class="summary_desc"><div class='inline'><p> -A new instance of NumFmt. -</p> + <span class="summary_desc"><div class='inline'> +<p>A new instance of NumFmt.</p> </div></span> </li> @@ -228,10 +223,9 @@ A new instance of NumFmt. - <span class="summary_desc"><div class='inline'><p> -Creates a numFmt element applying the instance values of this object as -attributes. -</p> + <span class="summary_desc"><div class='inline'> +<p>Creates a numFmt element applying the instance values of this object as +attributes.</p> </div></span> </li> @@ -252,9 +246,8 @@ attributes. </p><div class="docstring"> <div class="discussion"> - <p> -A new instance of NumFmt -</p> + +<p>A new instance of NumFmt</p> </div> @@ -279,14 +272,13 @@ A new instance of NumFmt <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/num_fmt.rb', line 45</span> -<span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span><span class='lparen token'>(</span><span class='options identifier id'>options</span><span class='assign token'>=</span><span class='lbrace token'>{</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> - <span class='@numFmtId ivar id'>@numFmtId</span> <span class='assign token'>=</span> <span class='integer val'>0</span> - <span class='@formatCode ivar id'>@formatCode</span> <span class='assign token'>=</span> <span class='string val'>""</span> - <span class='options identifier id'>options</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='o identifier id'>o</span><span class='bitor op'>|</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='dstring node'>"#{o[0]}="</span><span class='comma token'>,</span> <span class='o identifier id'>o</span><span class='lbrack token'>[</span><span class='integer val'>1</span><span class='rbrack token'>]</span><span class='rparen token'>)</span> <span class='if if_mod kw'>if</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='respond_to? fid id'>respond_to?</span> <span class='o identifier id'>o</span><span class='lbrack token'>[</span><span class='integer val'>0</span><span class='rbrack token'>]</span> - <span class='end end kw'>end</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id initialize'>initialize</span><span class='lparen'>(</span><span class='id options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span> + <span class='ivar'>@numFmtId</span> <span class='op'>=</span> <span class='int'>0</span> + <span class='ivar'>@formatCode</span> <span class='op'>=</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_end'>"</span></span> + <span class='id options'>options</span><span class='period'>.</span><span class='id each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id o'>o</span><span class='op'>|</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span><span class='rbrace'>}</span><span class='tstring_content'>=</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>1</span><span class='rbracket'>]</span><span class='rparen'>)</span> <span class='kw'>if</span> <span class='kw'>self</span><span class='period'>.</span><span class='id respond_to?'>respond_to?</span> <span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span> + <span class='kw'>end</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -309,9 +301,8 @@ A new instance of NumFmt </p><div class="docstring"> <div class="discussion"> - <p> -The formatting to use for this number format. -</p> + +<p>The formatting to use for this number format.</p> </div> @@ -329,9 +320,8 @@ The formatting to use for this number format. — - <div class='inline'><p> -The formatting to use for this number format. -</p> + <div class='inline'> +<p>The formatting to use for this number format.</p> </div> </li> @@ -358,10 +348,9 @@ The formatting to use for this number format. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/num_fmt.rb', line 44</span> -<span class='def def kw'>def</span> <span class='formatCode identifier id'>formatCode</span> - <span class='@formatCode ivar id'>@formatCode</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id formatCode'>formatCode</span> + <span class='ivar'>@formatCode</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -382,51 +371,48 @@ The formatting to use for this number format. <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -These are the known formats I can dig up. The constant NUM_FMT_PERCENT is + <div class='inline'> +<p>These are the known formats I can dig up. The constant NUM_FMT_PERCENT is 9, and uses the default % formatting. Axlsx also defines a few formats for date and time that are commonly used in asia as NUM_FMT_YYYYMMDD and -NUM_FRM_YYYYMMDDHHMMSS. -</p> -<pre class="code"> - <span class='integer val'>1</span> <span class='integer val'>0</span> - <span class='integer val'>2</span> <span class='integer val'>0</span><span class='integer val'>.00</span> - <span class='integer val'>3</span> <span class='comment val'>#,##0</span> - <span class='integer val'>4</span> <span class='comment val'>#,##0.00</span> - <span class='integer val'>5</span> $<span class='comment val'>#,##0_);($#,##0)</span> - <span class='integer val'>6</span> $<span class='comment val'>#,##0_);[Red]($#,##0)</span> - <span class='integer val'>7</span> $<span class='comment val'>#,##0.00_);($#,##0.00)</span> - <span class='integer val'>8</span> $<span class='comment val'>#,##0.00_);[Red]($#,##0.00)</span> - <span class='integer val'>9</span> <span class='integer val'>0</span><span class='mod op'>%</span> - <span class='integer val'>10</span> <span class='integer val'>0</span><span class='integer val'>.00</span><span class='mod op'>%</span> - <span class='integer val'>11</span> <span class='integer val'>0</span><span class='float val'>.00E+00</span> - <span class='integer val'>12</span> <span class='comment val'># ?/?</span> - <span class='integer val'>13</span> <span class='comment val'># ??/??</span> - <span class='integer val'>14</span> <span class='m identifier id'>m</span><span class='div op'>/</span><span class='d identifier id'>d</span><span class='div op'>/</span><span class='yyyy identifier id'>yyyy</span> - <span class='integer val'>15</span> <span class='d identifier id'>d</span><span class='minus op'>-</span><span class='mmm identifier id'>mmm</span><span class='minus op'>-</span><span class='yy identifier id'>yy</span> - <span class='integer val'>16</span> <span class='d identifier id'>d</span><span class='minus op'>-</span><span class='mmm identifier id'>mmm</span> - <span class='integer val'>17</span> <span class='mmm identifier id'>mmm</span><span class='minus op'>-</span><span class='yy identifier id'>yy</span> - <span class='integer val'>18</span> <span class='h identifier id'>h</span><span class='symbol val'>:mm</span> <span class='AM constant id'>AM</span><span class='div op'>/</span><span class='PM constant id'>PM</span> - <span class='integer val'>19</span> <span class='h identifier id'>h</span><span class='symbol val'>:mm</span><span class='symbol val'>:ss</span> <span class='AM constant id'>AM</span><span class='div op'>/</span><span class='PM constant id'>PM</span> - <span class='integer val'>20</span> <span class='h identifier id'>h</span><span class='symbol val'>:mm</span> - <span class='integer val'>21</span> <span class='h identifier id'>h</span><span class='symbol val'>:mm</span><span class='symbol val'>:ss</span> - <span class='integer val'>22</span> <span class='m identifier id'>m</span><span class='div op'>/</span><span class='d identifier id'>d</span><span class='div op'>/</span><span class='yyyy identifier id'>yyyy</span> <span class='h identifier id'>h</span><span class='symbol val'>:mm</span> - <span class='integer val'>37</span> <span class='comment val'>#,##0_);(#,##0)</span> - <span class='integer val'>38</span> <span class='comment val'>#,##0_);[Red](#,##0)</span> - <span class='integer val'>39</span> <span class='comment val'>#,##0.00_);(#,##0.00)</span> - <span class='integer val'>40</span> <span class='comment val'>#,##0.00_);[Red](#,##0.00)</span> - <span class='integer val'>45</span> <span class='mm identifier id'>mm</span><span class='symbol val'>:ss</span> - <span class='integer val'>46</span> <span class='lbrack token'>[</span><span class='h identifier id'>h</span><span class='rbrack token'>]</span><span class='symbol val'>:mm</span><span class='symbol val'>:ss</span> - <span class='integer val'>47</span> <span class='mm identifier id'>mm</span><span class='symbol val'>:ss</span><span class='integer val'>.0</span> - <span class='integer val'>48</span> <span class='comment val'>##0.0E+0</span> - <span class='integer val'>49</span> @ -</pre> +NUM_FRM_YYYYMMDDHHMMSS.</p> + +<pre class="code">1 0 +2 0.00 +3 #,##0 +4 #,##0.00 +5 $#,##0_);($#,##0) +6 $#,##0_);[Red]($#,##0) +7 $#,##0.00_);($#,##0.00) +8 $#,##0.00_);[Red]($#,##0.00) +9 0% +10 0.00% +11 0.00E+00 +12 # ?/? +13 # ??/?? +14 m/d/yyyy +15 d-mmm-yy +16 d-mmm +17 mmm-yy +18 h:mm AM/PM +19 h:mm:ss AM/PM +20 h:mm +21 h:mm:ss +22 m/d/yyyy h:mm +37 #,##0_);(#,##0) +38 #,##0_);[Red](#,##0) +39 #,##0.00_);(#,##0.00) +40 #,##0.00_);[Red](#,##0.00) +45 mm:ss +46 [h]:mm:ss +47 mm:ss.0 +48 ##0.0E+0 +49 @</pre> </div> </div> -<p> -An unsinged integer referencing a standard or custom number format. -</p> + +<p>An unsinged integer referencing a standard or custom number format.</p> </div> @@ -444,9 +430,8 @@ An unsinged integer referencing a standard or custom number format. — - <div class='inline'><p> -An unsinged integer referencing a standard or custom number format. -</p> + <div class='inline'> +<p>An unsinged integer referencing a standard or custom number format.</p> </div> </li> @@ -473,10 +458,9 @@ An unsinged integer referencing a standard or custom number format. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/num_fmt.rb', line 40</span> -<span class='def def kw'>def</span> <span class='numFmtId identifier id'>numFmtId</span> - <span class='@numFmtId ivar id'>@numFmtId</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id numFmtId'>numFmtId</span> + <span class='ivar'>@numFmtId</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -498,10 +482,9 @@ An unsinged integer referencing a standard or custom number format. </p><div class="docstring"> <div class="discussion"> - <p> -Creates a numFmt element applying the instance values of this object as -attributes. -</p> + +<p>Creates a numFmt element applying the instance values of this object as +attributes.</p> </div> @@ -520,9 +503,8 @@ attributes. — - <div class='inline'><p> -The document builder instance this objects xml will be added to. -</p> + <div class='inline'> +<p>The document builder instance this objects xml will be added to.</p> </div> </li> @@ -536,13 +518,12 @@ The document builder instance this objects xml will be added to. <pre class="lines"> -58</pre> +60</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/num_fmt.rb', line 58</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/num_fmt.rb', line 60</span> -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='numFmt identifier id'>numFmt</span><span class='lparen token'>(</span><span class='self self kw'>self</span><span class='dot token'>.</span><span class='instance_values identifier id'>instance_values</span><span class='rparen token'>)</span> <span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> <span class='id xml'>xml</span><span class='period'>.</span><span class='id numFmt'>numFmt</span><span class='lparen'>(</span><span class='kw'>self</span><span class='period'>.</span><span class='id instance_values'>instance_values</span><span class='rparen'>)</span> <span class='kw'>end</span></pre> </td> </tr> </table> @@ -553,9 +534,9 @@ The document builder instance this objects xml will be added to. </div> <div id="footer"> - Generated on Wed Nov 23 22:20:45 2011 by + Generated on Sat Nov 26 13:16:38 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/OneCellAnchor.html b/doc/Axlsx/OneCellAnchor.html index e9b0d76a..eaec6d92 100644 --- a/doc/Axlsx/OneCellAnchor.html +++ b/doc/Axlsx/OneCellAnchor.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::OneCellAnchor - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -97,16 +97,14 @@ <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -The recommended way to manage drawings, images and charts is -Worksheet#add_chart or Worksheet#add_image. -</p> + <div class='inline'> +<p>The recommended way to manage drawings, images and charts is +Worksheet#add_chart or Worksheet#add_image.</p> </div> </div> -<p> -This class details a single cell anchor for drawings. -</p> + +<p>This class details a single cell anchor for drawings.</p> </div> @@ -147,9 +145,8 @@ This class details a single cell anchor for drawings. - <span class="summary_desc"><div class='inline'><p> -The drawing that holds this anchor. -</p> + <span class="summary_desc"><div class='inline'> +<p>The drawing that holds this anchor.</p> </div></span> </li> @@ -174,9 +171,8 @@ The drawing that holds this anchor. - <span class="summary_desc"><div class='inline'><p> -A marker that defines the from cell anchor. -</p> + <span class="summary_desc"><div class='inline'> +<p>A marker that defines the from cell anchor.</p> </div></span> </li> @@ -201,10 +197,9 @@ A marker that defines the from cell anchor. - <span class="summary_desc"><div class='inline'><p> -the height of the graphic object in pixels this is converted to EMU at a 92 -ppi resolution. -</p> + <span class="summary_desc"><div class='inline'> +<p>the height of the graphic object in pixels this is converted to EMU at a 92 +ppi resolution.</p> </div></span> </li> @@ -213,7 +208,7 @@ ppi resolution. <li class="public "> <span class="summary_signature"> - <a href="#index-instance_method" title="#index (instance method)">- (Integer) <strong>index</strong> </a> + <a href="#object-instance_method" title="#object (instance method)">- (Pic) <strong>object</strong> </a> @@ -229,9 +224,8 @@ ppi resolution. - <span class="summary_desc"><div class='inline'><p> -The index of this anchor in the drawing. -</p> + <span class="summary_desc"><div class='inline'> +<p>The object this anchor hosts.</p> </div></span> </li> @@ -240,14 +234,14 @@ The index of this anchor in the drawing. <li class="public "> <span class="summary_signature"> - <a href="#object-instance_method" title="#object (instance method)">- (Pic) <strong>object</strong> </a> + <a href="#width-instance_method" title="#width (instance method)">- (Integer) <strong>width</strong> </a> </span> - <span class="note title readonly">readonly</span> + @@ -256,53 +250,48 @@ The index of this anchor in the drawing. - <span class="summary_desc"><div class='inline'><p> -The object this anchor hosts. -</p> + <span class="summary_desc"><div class='inline'> +<p>the width of the graphic object in pixels.</p> </div></span> </li> - <li class="public "> + </ul> + + + + + + <h2> + Instance Method Summary + <small>(<a href="#" class="summary_toggle">collapse</a>)</small> + </h2> + + <ul class="summary"> + + <li class="public "> <span class="summary_signature"> - <a href="#width-instance_method" title="#width (instance method)">- (Integer) <strong>width</strong> </a> + <a href="#index-instance_method" title="#index (instance method)">- (Integer) <strong>index</strong> </a> </span> - - - - <span class="summary_desc"><div class='inline'><p> -the width of the graphic object in pixels. -</p> + <span class="summary_desc"><div class='inline'> +<p>The index of this anchor in the drawing.</p> </div></span> </li> - - </ul> - - - - - - <h2> - Instance Method Summary - <small>(<a href="#" class="summary_toggle">collapse</a>)</small> - </h2> - - <ul class="summary"> <li class="public "> <span class="summary_signature"> @@ -322,9 +311,8 @@ the width of the graphic object in pixels. - <span class="summary_desc"><div class='inline'><p> -Creates a new OneCellAnchor object and an Pic associated with it. -</p> + <span class="summary_desc"><div class='inline'> +<p>Creates a new OneCellAnchor object and an Pic associated with it.</p> </div></span> </li> @@ -346,9 +334,8 @@ Creates a new OneCellAnchor object and an Pic associated with it. - <span class="summary_desc"><div class='inline'><p> -Serializes the anchor. -</p> + <span class="summary_desc"><div class='inline'> +<p>Serializes the anchor.</p> </div></span> </li> @@ -369,9 +356,8 @@ Serializes the anchor. </p><div class="docstring"> <div class="discussion"> - <p> -Creates a new OneCellAnchor object and an Pic associated with it. -</p> + +<p>Creates a new OneCellAnchor object and an Pic associated with it.</p> </div> @@ -403,9 +389,8 @@ Creates a new OneCellAnchor object and an Pic associated with it. — - <div class='inline'><p> -a customizable set of options -</p> + <div class='inline'> +<p>a customizable set of options</p> </div> </li> @@ -426,9 +411,8 @@ a customizable set of options <span class="default"> </span> - — <div class='inline'><p> -the col, row to start at -</p> + — <div class='inline'> +<p>the col, row to start at</p> </div> </li> @@ -456,9 +440,8 @@ the col, row to start at <span class="default"> </span> - — <div class='inline'><p> -the file location of the image you will render -</p> + — <div class='inline'> +<p>the file location of the image you will render</p> </div> </li> @@ -468,9 +451,8 @@ the file location of the image you will render <span class="default"> </span> - — <div class='inline'><p> -the name attribute for the rendered image -</p> + — <div class='inline'> +<p>the name attribute for the rendered image</p> </div> </li> @@ -480,9 +462,8 @@ the name attribute for the rendered image <span class="default"> </span> - — <div class='inline'><p> -the description of the image rendered -</p> + — <div class='inline'> +<p>the description of the image rendered</p> </div> </li> @@ -496,33 +477,32 @@ the description of the image rendered <pre class="lines"> +39 +40 +41 +42 +43 44 45 46 47 48 -49 -50 -51 -52 -53 -54</pre> +49</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/one_cell_anchor.rb', line 44</span> - -<span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span><span class='lparen token'>(</span><span class='drawing identifier id'>drawing</span><span class='comma token'>,</span> <span class='options identifier id'>options</span><span class='assign token'>=</span><span class='lbrace token'>{</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> - <span class='@drawing ivar id'>@drawing</span> <span class='assign token'>=</span> <span class='drawing identifier id'>drawing</span> - <span class='@width ivar id'>@width</span> <span class='assign token'>=</span> <span class='integer val'>0</span> - <span class='@height ivar id'>@height</span> <span class='assign token'>=</span> <span class='integer val'>0</span> - <span class='drawing identifier id'>drawing</span><span class='dot token'>.</span><span class='anchors identifier id'>anchors</span> <span class='lshft op'><<</span> <span class='self self kw'>self</span> - <span class='@from ivar id'>@from</span> <span class='assign token'>=</span> <span class='Marker constant id'>Marker</span><span class='dot token'>.</span><span class='new identifier id'>new</span> - <span class='options identifier id'>options</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='o identifier id'>o</span><span class='bitor op'>|</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='dstring node'>"#{o[0]}="</span><span class='comma token'>,</span> <span class='o identifier id'>o</span><span class='lbrack token'>[</span><span class='integer val'>1</span><span class='rbrack token'>]</span><span class='rparen token'>)</span> <span class='if if_mod kw'>if</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='respond_to? fid id'>respond_to?</span> <span class='dstring node'>"#{o[0]}="</span> - <span class='end end kw'>end</span> - <span class='@object ivar id'>@object</span> <span class='assign token'>=</span> <span class='Pic constant id'>Pic</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='self self kw'>self</span><span class='comma token'>,</span> <span class='options identifier id'>options</span><span class='rparen token'>)</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/one_cell_anchor.rb', line 39</span> + +<span class='kw'>def</span> <span class='id initialize'>initialize</span><span class='lparen'>(</span><span class='id drawing'>drawing</span><span class='comma'>,</span> <span class='id options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span> + <span class='ivar'>@drawing</span> <span class='op'>=</span> <span class='id drawing'>drawing</span> + <span class='ivar'>@width</span> <span class='op'>=</span> <span class='int'>0</span> + <span class='ivar'>@height</span> <span class='op'>=</span> <span class='int'>0</span> + <span class='id drawing'>drawing</span><span class='period'>.</span><span class='id anchors'>anchors</span> <span class='op'><<</span> <span class='kw'>self</span> + <span class='ivar'>@from</span> <span class='op'>=</span> <span class='const'>Marker</span><span class='period'>.</span><span class='id new'>new</span> + <span class='id options'>options</span><span class='period'>.</span><span class='id each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id o'>o</span><span class='op'>|</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span><span class='rbrace'>}</span><span class='tstring_content'>=</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>1</span><span class='rbracket'>]</span><span class='rparen'>)</span> <span class='kw'>if</span> <span class='kw'>self</span><span class='period'>.</span><span class='id respond_to?'>respond_to?</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span><span class='rbrace'>}</span><span class='tstring_content'>=</span><span class='tstring_end'>"</span></span> + <span class='kw'>end</span> + <span class='ivar'>@object</span> <span class='op'>=</span> <span class='const'>Pic</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='kw'>self</span><span class='comma'>,</span> <span class='id options'>options</span><span class='rparen'>)</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -545,9 +525,8 @@ the description of the image rendered </p><div class="docstring"> <div class="discussion"> - <p> -The drawing that holds this anchor -</p> + +<p>The drawing that holds this anchor</p> </div> @@ -581,10 +560,9 @@ The drawing that holds this anchor <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/one_cell_anchor.rb', line 18</span> -<span class='def def kw'>def</span> <span class='drawing identifier id'>drawing</span> - <span class='@drawing ivar id'>@drawing</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id drawing'>drawing</span> + <span class='ivar'>@drawing</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -602,10 +580,9 @@ The drawing that holds this anchor </p><div class="docstring"> <div class="discussion"> - <p> -A marker that defines the from cell anchor. The default from column and row -are 0 and 0 respectively -</p> + +<p>A marker that defines the from cell anchor. The default from column and row +are 0 and 0 respectively</p> </div> @@ -639,10 +616,9 @@ are 0 and 0 respectively <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/one_cell_anchor.rb', line 10</span> -<span class='def def kw'>def</span> <span class='from identifier id'>from</span> - <span class='@from ivar id'>@from</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id from'>from</span> + <span class='ivar'>@from</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -660,10 +636,9 @@ are 0 and 0 respectively </p><div class="docstring"> <div class="discussion"> - <p> -the height of the graphic object in pixels this is converted to EMU at a 92 -ppi resolution -</p> + +<p>the height of the graphic object in pixels this is converted to EMU at a 92 +ppi resolution</p> </div> @@ -690,17 +665,16 @@ ppi resolution <pre class="lines"> -33 -34 -35</pre> +28 +29 +30</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/one_cell_anchor.rb', line 33</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/one_cell_anchor.rb', line 28</span> -<span class='def def kw'>def</span> <span class='height identifier id'>height</span> - <span class='@height ivar id'>@height</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id height'>height</span> + <span class='ivar'>@height</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -708,19 +682,18 @@ ppi resolution <span id=""></span> - <span id="index-instance_method"></span> + <span id="object-instance_method"></span> <div class="method_details "> - <p class="signature " id="index-instance_method"> + <p class="signature " id="object-instance_method"> - - (<tt>Integer</tt>) <strong>index</strong> <span class="extras">(readonly)</span> + - (<tt><span class='object_link'><a href="Pic.html" title="Axlsx::Pic (class)">Pic</a></span></tt>) <strong>object</strong> <span class="extras">(readonly)</span> </p><div class="docstring"> <div class="discussion"> - <p> -The index of this anchor in the drawing -</p> + +<p>The object this anchor hosts</p> </div> @@ -733,7 +706,7 @@ The index of this anchor in the drawing <li> - <span class='type'>(<tt>Integer</tt>)</span> + <span class='type'>(<tt><span class='object_link'><a href="Pic.html" title="Axlsx::Pic (class)">Pic</a></span></tt>)</span> @@ -747,37 +720,36 @@ The index of this anchor in the drawing <pre class="lines"> -22 -23 -24</pre> +14 +15 +16</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/one_cell_anchor.rb', line 22</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/one_cell_anchor.rb', line 14</span> -<span class='def def kw'>def</span> <span class='index identifier id'>index</span> - <span class='@drawing ivar id'>@drawing</span><span class='dot token'>.</span><span class='anchors identifier id'>anchors</span><span class='dot token'>.</span><span class='index identifier id'>index</span><span class='lparen token'>(</span><span class='self self kw'>self</span><span class='rparen token'>)</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id object'>object</span> + <span class='ivar'>@object</span> +<span class='kw'>end</span></pre> </td> </tr> </table> </div> - <span id=""></span> - <span id="object-instance_method"></span> + <span id="width=-instance_method"></span> + <span id="width-instance_method"></span> <div class="method_details "> - <p class="signature " id="object-instance_method"> + <p class="signature " id="width-instance_method"> - - (<tt><span class='object_link'><a href="Pic.html" title="Axlsx::Pic (class)">Pic</a></span></tt>) <strong>object</strong> <span class="extras">(readonly)</span> + - (<tt>Integer</tt>) <strong>width</strong> </p><div class="docstring"> <div class="discussion"> - <p> -The object this anchor hosts -</p> + +<p>the width of the graphic object in pixels. this is converted to EMU at a 92 +ppi resolution</p> </div> @@ -790,7 +762,7 @@ The object this anchor hosts <li> - <span class='type'>(<tt><span class='object_link'><a href="Pic.html" title="Axlsx::Pic (class)">Pic</a></span></tt>)</span> + <span class='type'>(<tt>Integer</tt>)</span> @@ -804,38 +776,39 @@ The object this anchor hosts <pre class="lines"> -14 -15 -16</pre> +23 +24 +25</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/one_cell_anchor.rb', line 14</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/one_cell_anchor.rb', line 23</span> -<span class='def def kw'>def</span> <span class='object identifier id'>object</span> - <span class='@object ivar id'>@object</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id width'>width</span> + <span class='ivar'>@width</span> +<span class='kw'>end</span></pre> </td> </tr> </table> </div> - - <span id="width=-instance_method"></span> - <span id="width-instance_method"></span> - <div class="method_details "> - <p class="signature " id="width-instance_method"> + </div> + + + <div id="instance_method_details" class="method_details_list"> + <h2>Instance Method Details</h2> + + + <div class="method_details first"> + <p class="signature first" id="index-instance_method"> - - (<tt>Integer</tt>) <strong>width</strong> + - (<tt>Integer</tt>) <strong>index</strong> </p><div class="docstring"> <div class="discussion"> - <p> -the width of the graphic object in pixels. this is converted to EMU at a 92 -ppi resolution -</p> + +<p>The index of this anchor in the drawing</p> </div> @@ -862,31 +835,23 @@ ppi resolution <pre class="lines"> -28 -29 -30</pre> +59 +60 +61</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/one_cell_anchor.rb', line 28</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/one_cell_anchor.rb', line 59</span> -<span class='def def kw'>def</span> <span class='width identifier id'>width</span> - <span class='@width ivar id'>@width</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id index'>index</span> + <span class='ivar'>@drawing</span><span class='period'>.</span><span class='id anchors'>anchors</span><span class='period'>.</span><span class='id index'>index</span><span class='lparen'>(</span><span class='kw'>self</span><span class='rparen'>)</span> +<span class='kw'>end</span></pre> </td> </tr> </table> </div> - </div> - - - <div id="instance_method_details" class="method_details_list"> - <h2>Instance Method Details</h2> - - - <div class="method_details first"> - <p class="signature first" id="to_xml-instance_method"> + <div class="method_details "> + <p class="signature " id="to_xml-instance_method"> - (<tt>String</tt>) <strong>to_xml</strong>(xml) @@ -894,9 +859,8 @@ ppi resolution </p><div class="docstring"> <div class="discussion"> - <p> -Serializes the anchor -</p> + +<p>Serializes the anchor</p> </div> @@ -915,9 +879,8 @@ Serializes the anchor — - <div class='inline'><p> -The document builder instance this objects xml will be added to. -</p> + <div class='inline'> +<p>The document builder instance this objects xml will be added to.</p> </div> </li> @@ -958,17 +921,16 @@ The document builder instance this objects xml will be added to. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/one_cell_anchor.rb', line 66</span> -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'xdr:oneCellAnchor'</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'xdr:from'</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='from identifier id'>from</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='rbrace token'>}</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'xdr:ext'</span><span class='comma token'>,</span> <span class='ext identifier id'>ext</span><span class='rparen token'>)</span> - <span class='@object ivar id'>@object</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'xdr:clientData'</span><span class='rparen token'>)</span> - <span class='rbrace token'>}</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>xdr:oneCellAnchor</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>xdr:from</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='id from'>from</span><span class='period'>.</span><span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> + <span class='rbrace'>}</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>xdr:ext</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='id ext'>ext</span><span class='rparen'>)</span> + <span class='ivar'>@object</span><span class='period'>.</span><span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>xdr:clientData</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> + <span class='rbrace'>}</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -979,9 +941,9 @@ The document builder instance this objects xml will be added to. </div> <div id="footer"> - Generated on Wed Nov 23 22:20:46 2011 by + Generated on Sat Nov 26 13:16:39 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/Override.html b/doc/Axlsx/Override.html index 78fca49c..542e1ad5 100644 --- a/doc/Axlsx/Override.html +++ b/doc/Axlsx/Override.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::Override - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -94,10 +94,9 @@ <h2>Overview</h2><div class="docstring"> <div class="discussion"> - <p> -An override content part. These parts are automatically created by for you -based on the content of your package. -</p> + +<p>An override content part. These parts are automatically created by for you +based on the content of your package.</p> </div> @@ -129,9 +128,8 @@ based on the content of your package. - <span class="summary_desc"><div class='inline'><p> -ContentType The type of content. -</p> + <span class="summary_desc"><div class='inline'> +<p>The type of content.</p> </div></span> </li> @@ -156,9 +154,8 @@ ContentType The type of content. - <span class="summary_desc"><div class='inline'><p> -PartName The name and location of the part. -</p> + <span class="summary_desc"><div class='inline'> +<p>The name and location of the part.</p> </div></span> </li> @@ -195,9 +192,8 @@ PartName The name and location of the part. - <span class="summary_desc"><div class='inline'><p> -Creates a new Override object. -</p> + <span class="summary_desc"><div class='inline'> +<p>Creates a new Override object.</p> </div></span> </li> @@ -219,9 +215,8 @@ Creates a new Override object. - <span class="summary_desc"><div class='inline'><p> -Serializes the Override object to xml. -</p> + <span class="summary_desc"><div class='inline'> +<p>Serializes the Override object to xml.</p> </div></span> </li> @@ -242,9 +237,8 @@ Serializes the Override object to xml. </p><div class="docstring"> <div class="discussion"> - <p> -Creates a new Override object -</p> + +<p>Creates a new Override object</p> </div> @@ -265,9 +259,8 @@ Creates a new Override object — - <div class='inline'><p> -a customizable set of options -</p> + <div class='inline'> +<p>a customizable set of options</p> </div> </li> @@ -312,10 +305,9 @@ a customizable set of options — - <div class='inline'><p> -An argument error is raised if both PartName and ContentType are not -specified. -</p> + <div class='inline'> +<p>An argument error is raised if both PartName and ContentType are not +specified.</p> </div> </li> @@ -328,23 +320,22 @@ specified. <pre class="lines"> -15 -16 17 18 19 -20</pre> +20 +21 +22</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/content_type/override.rb', line 15</span> - -<span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span><span class='lparen token'>(</span><span class='options identifier id'>options</span><span class='assign token'>=</span><span class='lbrace token'>{</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> - <span class='raise identifier id'>raise</span> <span class='ArgumentError constant id'>ArgumentError</span><span class='comma token'>,</span> <span class='string val'>"PartName and ContentType are required"</span> <span class='unless unless_mod kw'>unless</span> <span class='options identifier id'>options</span><span class='lbrack token'>[</span><span class='symbol val'>:PartName</span><span class='rbrack token'>]</span> <span class='andop op'>&&</span> <span class='options identifier id'>options</span><span class='lbrack token'>[</span><span class='symbol val'>:ContentType</span><span class='rbrack token'>]</span> - <span class='options identifier id'>options</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='o identifier id'>o</span><span class='bitor op'>|</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='dstring node'>"#{o[0]}="</span><span class='comma token'>,</span> <span class='o identifier id'>o</span><span class='lbrack token'>[</span><span class='integer val'>1</span><span class='rbrack token'>]</span><span class='rparen token'>)</span> <span class='if if_mod kw'>if</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='respond_to? fid id'>respond_to?</span> <span class='dstring node'>"#{o[0]}="</span> - <span class='end end kw'>end</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/content_type/override.rb', line 17</span> + +<span class='kw'>def</span> <span class='id initialize'>initialize</span><span class='lparen'>(</span><span class='id options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span> + <span class='id raise'>raise</span> <span class='const'>ArgumentError</span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>PartName and ContentType are required</span><span class='tstring_end'>"</span></span> <span class='kw'>unless</span> <span class='id options'>options</span><span class='lbracket'>[</span><span class='symbol'>:PartName</span><span class='rbracket'>]</span> <span class='op'>&&</span> <span class='id options'>options</span><span class='lbracket'>[</span><span class='symbol'>:ContentType</span><span class='rbracket'>]</span> + <span class='id options'>options</span><span class='period'>.</span><span class='id each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id o'>o</span><span class='op'>|</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span><span class='rbrace'>}</span><span class='tstring_content'>=</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>1</span><span class='rbracket'>]</span><span class='rparen'>)</span> <span class='kw'>if</span> <span class='kw'>self</span><span class='period'>.</span><span class='id respond_to?'>respond_to?</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span><span class='rbrace'>}</span><span class='tstring_content'>=</span><span class='tstring_end'>"</span></span> + <span class='kw'>end</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -367,11 +358,8 @@ specified. </p><div class="docstring"> <div class="discussion"> - <p> -ContentType The type of content. TABLE_CT, WORKBOOK_CT, APP_CT, RELS_CT, -STYLES_CT, XML_CT, WORKSHEET_CT, SHARED_STRINGS_CT, CORE_CT, CHART_CT, -DRAWING_CT are allowed -</p> + +<p>The type of content.</p> </div> @@ -388,14 +376,6 @@ DRAWING_CT are allowed - — - <div class='inline'><p> -ContentType The type of content. TABLE_CT, WORKBOOK_CT, APP_CT, RELS_CT, -STYLES_CT, XML_CT, WORKSHEET_CT, SHARED_STRINGS_CT, CORE_CT, CHART_CT, -DRAWING_CT are allowed -</p> -</div> - </li> </ul> @@ -406,17 +386,16 @@ DRAWING_CT are allowed <pre class="lines"> -6 7 -8</pre> +8 +9</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/content_type/override.rb', line 6</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/content_type/override.rb', line 7</span> -<span class='def def kw'>def</span> <span class='ContentType constant id'>ContentType</span> - <span class='@ContentType ivar id'>@ContentType</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='const'>ContentType</span> + <span class='ivar'>@ContentType</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -434,9 +413,8 @@ DRAWING_CT are allowed </p><div class="docstring"> <div class="discussion"> - <p> -PartName The name and location of the part. -</p> + +<p>The name and location of the part.</p> </div> @@ -453,12 +431,6 @@ PartName The name and location of the part. - — - <div class='inline'><p> -PartName The name and location of the part. -</p> -</div> - </li> </ul> @@ -469,17 +441,16 @@ PartName The name and location of the part. <pre class="lines"> -9 -10 -11</pre> +11 +12 +13</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/content_type/override.rb', line 9</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/content_type/override.rb', line 11</span> -<span class='def def kw'>def</span> <span class='PartName constant id'>PartName</span> - <span class='@PartName ivar id'>@PartName</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='const'>PartName</span> + <span class='ivar'>@PartName</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -501,9 +472,8 @@ PartName The name and location of the part. </p><div class="docstring"> <div class="discussion"> - <p> -Serializes the Override object to xml -</p> + +<p>Serializes the Override object to xml</p> </div> @@ -522,9 +492,8 @@ Serializes the Override object to xml — - <div class='inline'><p> -The document builder instance this objects xml will be added to. -</p> + <div class='inline'> +<p>The document builder instance this objects xml will be added to.</p> </div> </li> @@ -538,17 +507,16 @@ The document builder instance this objects xml will be added to. <pre class="lines"> -26 -27 -28</pre> +33 +34 +35</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/content_type/override.rb', line 26</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/content_type/override.rb', line 33</span> -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='Override constant id'>Override</span><span class='lparen token'>(</span><span class='self self kw'>self</span><span class='dot token'>.</span><span class='instance_values identifier id'>instance_values</span><span class='rparen token'>)</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='const'>Override</span><span class='lparen'>(</span><span class='kw'>self</span><span class='period'>.</span><span class='id instance_values'>instance_values</span><span class='rparen'>)</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -559,9 +527,9 @@ The document builder instance this objects xml will be added to. </div> <div id="footer"> - Generated on Wed Nov 23 22:20:57 2011 by + Generated on Sat Nov 26 13:16:39 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/Package.html b/doc/Axlsx/Package.html index bb9468bd..6ab5ca37 100644 --- a/doc/Axlsx/Package.html +++ b/doc/Axlsx/Package.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::Package - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -94,11 +94,10 @@ <h2>Overview</h2><div class="docstring"> <div class="discussion"> - <p> -Package is responsible for managing all the bits and peices that Open + +<p>Package is responsible for managing all the bits and peices that Open Office XML requires to make a valid xlsx document including valdation and -serialization. -</p> +serialization.</p> </div> @@ -108,38 +107,6 @@ serialization. </div> - <h2>Instance Attribute Summary <small>(<a href="#" class="summary_toggle">collapse</a>)</small></h2> - <ul class="summary"> - - <li class="public "> - <span class="summary_signature"> - - <a href="#workbook-instance_method" title="#workbook (instance method)">- (Workbook) <strong>workbook</strong> </a> - - - - </span> - - - - - - - - - - - - <span class="summary_desc"><div class='inline'><p> -The workbook this package will serialize or validate. -</p> -</div></span> - -</li> - - - </ul> - @@ -154,55 +121,6 @@ The workbook this package will serialize or validate. <li class="public "> <span class="summary_signature"> - <a href="#base_content_types-instance_method" title="#base_content_types (instance method)">- (ContentType) <strong>base_content_types</strong> </a> - - - - </span> - - - - - - - - - <span class="summary_desc"><div class='inline'><p> -Creates the minimum content types for generating a valid xlsx document. -</p> -</div></span> - -</li> - - - <li class="public "> - <span class="summary_signature"> - - <a href="#content_types-instance_method" title="#content_types (instance method)">- (ContentType) <strong>content_types</strong> </a> - - - - </span> - - - - - - - - - <span class="summary_desc"><div class='inline'><p> -Appends override objects for drawings, charts, and sheets as they exist in -your workbook to the default content types. -</p> -</div></span> - -</li> - - - <li class="public "> - <span class="summary_signature"> - <a href="#initialize-instance_method" title="#initialize (instance method)">- (Package) <strong>initialize</strong>(options = {}) {|_self| ... }</a> @@ -218,33 +136,8 @@ your workbook to the default content types. - <span class="summary_desc"><div class='inline'><p> -Initializes your package. -</p> -</div></span> - -</li> - - - <li class="public "> - <span class="summary_signature"> - - <a href="#parts-instance_method" title="#parts (instance method)">- (Array) <strong>parts</strong> </a> - - - - </span> - - - - - - - - - <span class="summary_desc"><div class='inline'><p> -The parts of a package. -</p> + <span class="summary_desc"><div class='inline'> +<p>Initializes your package.</p> </div></span> </li> @@ -253,7 +146,7 @@ The parts of a package. <li class="public "> <span class="summary_signature"> - <a href="#relationships-instance_method" title="#relationships (instance method)">- (Relationships) <strong>relationships</strong> </a> + <a href="#serialize-instance_method" title="#serialize (instance method)">- (Boolean) <strong>serialize</strong>(output, confirm_valid = false) </a> @@ -266,9 +159,8 @@ The parts of a package. - <span class="summary_desc"><div class='inline'><p> -Creates the relationships required for a valid xlsx document. -</p> + <span class="summary_desc"><div class='inline'> +<p>Serialize your workbook to disk as an xlsx document.</p> </div></span> </li> @@ -277,7 +169,7 @@ Creates the relationships required for a valid xlsx document. <li class="public "> <span class="summary_signature"> - <a href="#serialize-instance_method" title="#serialize (instance method)">- (Boolean) <strong>serialize</strong>(output, confirm_valid = false) </a> + <a href="#validate-instance_method" title="#validate (instance method)">- (Array) <strong>validate</strong> </a> @@ -290,9 +182,8 @@ Creates the relationships required for a valid xlsx document. - <span class="summary_desc"><div class='inline'><p> -Serialize your workbook to disk as an xlsx document. -</p> + <span class="summary_desc"><div class='inline'> +<p>Validate all parts of the package against xsd schema.</p> </div></span> </li> @@ -301,7 +192,7 @@ Serialize your workbook to disk as an xlsx document. <li class="public "> <span class="summary_signature"> - <a href="#validate-instance_method" title="#validate (instance method)">- (Array) <strong>validate</strong> </a> + <a href="#workbook-instance_method" title="#workbook (instance method)">- (Workbook) <strong>workbook</strong> </a> @@ -314,9 +205,8 @@ Serialize your workbook to disk as an xlsx document. - <span class="summary_desc"><div class='inline'><p> -Validate all parts of the package against xsd schema. -</p> + <span class="summary_desc"><div class='inline'> +<p>The workbook this package will serialize or validate.</p> </div></span> </li> @@ -325,7 +215,7 @@ Validate all parts of the package against xsd schema. <li class="public "> <span class="summary_signature"> - <a href="#validate_single_doc-instance_method" title="#validate_single_doc (instance method)">- (Array) <strong>validate_single_doc</strong>(schema, doc) </a> + <a href="#workbook%3D-instance_method" title="#workbook= (instance method)">- (Object) <strong>workbook=</strong>(workbook) </a> @@ -338,10 +228,7 @@ Validate all parts of the package against xsd schema. - <span class="summary_desc"><div class='inline'><p> -Performs xsd validation for a signle document. -</p> -</div></span> + <span class="summary_desc"><div class='inline'></div></span> </li> @@ -361,9 +248,8 @@ Performs xsd validation for a signle document. </p><div class="docstring"> <div class="discussion"> - <p> -Initializes your package -</p> + +<p>Initializes your package</p> </div> @@ -373,12 +259,10 @@ Initializes your package <div class="examples"> <h3>Examples:</h3> - <h4><div class='inline'><p> -Package.new :author => ‘you!’, :workbook => Workbook.new -</p> + <h4><div class='inline'> +<p>Package.new :author => ‘you!’, :workbook => Workbook.new</p> </div></h4> - <pre class="example code"> -</pre> + <pre class="example code"></pre> </div> <h3>Parameters:</h3> @@ -396,10 +280,9 @@ Package.new :author => ‘you!’, :workbook => Workbook.new — - <div class='inline'><p> -A hash that you can use to specify the author and workbook for this -package. -</p> + <div class='inline'> +<p>A hash that you can use to specify the author and workbook for this +package.</p> </div> </li> @@ -418,9 +301,8 @@ package. <span class="default"> </span> - — <div class='inline'><p> -The author of the document -</p> + — <div class='inline'> +<p>The author of the document</p> </div> </li> @@ -453,9 +335,8 @@ The author of the document — - <div class='inline'><p> -the object that the method was called on -</p> + <div class='inline'> +<p>the object that the method was called on</p> </div> </li> @@ -468,21 +349,22 @@ the object that the method was called on <pre class="lines"> -28 -29 -30 -31 -32</pre> +12 +13 +14 +15 +16 +17</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/package.rb', line 28</span> - -<span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span><span class='lparen token'>(</span><span class='options identifier id'>options</span><span class='assign token'>=</span><span class='lbrace token'>{</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> - <span class='@core ivar id'>@core</span><span class='comma token'>,</span> <span class='@app ivar id'>@app</span> <span class='assign token'>=</span> <span class='Core constant id'>Core</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='comma token'>,</span> <span class='App constant id'>App</span><span class='dot token'>.</span><span class='new identifier id'>new</span> - <span class='@core ivar id'>@core</span><span class='dot token'>.</span><span class='creator identifier id'>creator</span> <span class='assign token'>=</span> <span class='options identifier id'>options</span><span class='lbrack token'>[</span><span class='symbol val'>:author</span><span class='rbrack token'>]</span> <span class='orop op'>||</span> <span class='@core ivar id'>@core</span><span class='dot token'>.</span><span class='creator identifier id'>creator</span> - <span class='yield yield kw'>yield</span> <span class='self self kw'>self</span> <span class='if if_mod kw'>if</span> <span class='block_given? fid id'>block_given?</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/package.rb', line 12</span> + +<span class='kw'>def</span> <span class='id initialize'>initialize</span><span class='lparen'>(</span><span class='id options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span> + <span class='ivar'>@workbook</span> <span class='op'>=</span> <span class='kw'>nil</span> + <span class='ivar'>@core</span><span class='comma'>,</span> <span class='ivar'>@app</span> <span class='op'>=</span> <span class='const'>Core</span><span class='period'>.</span><span class='id new'>new</span><span class='comma'>,</span> <span class='const'>App</span><span class='period'>.</span><span class='id new'>new</span> + <span class='ivar'>@core</span><span class='period'>.</span><span class='id creator'>creator</span> <span class='op'>=</span> <span class='id options'>options</span><span class='lbracket'>[</span><span class='symbol'>:author</span><span class='rbracket'>]</span> <span class='op'>||</span> <span class='ivar'>@core</span><span class='period'>.</span><span class='id creator'>creator</span> + <span class='kw'>yield</span> <span class='kw'>self</span> <span class='kw'>if</span> <span class='id block_given?'>block_given?</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -490,470 +372,13 @@ the object that the method was called on </div> - <div id="instance_attr_details" class="attr_details"> - <h2>Instance Attribute Details</h2> - - - <span id="workbook=-instance_method"></span> - <span id="workbook-instance_method"></span> - <div class="method_details first"> - <p class="signature first" id="workbook-instance_method"> - - - (<tt><span class='object_link'><a href="Workbook.html" title="Axlsx::Workbook (class)">Workbook</a></span></tt>) <strong>workbook</strong> - - - -</p><div class="docstring"> - <div class="discussion"> - - <div class="note notetag"> - <strong>Note:</strong> - <div class='inline'><p> -As there are multiple ways to instantiate a workbook for the package, here -are a few examples: -</p> -<pre class="code"> - <span class='comment val'># assign directly during package instanciation</span> - <span class='wb identifier id'>wb</span> <span class='assign token'>=</span> <span class='Package constant id'>Package</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='symbol val'>:workbook</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='Workbook constant id'>Workbook</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='rparen token'>)</span><span class='dot token'>.</span><span class='workbook identifier id'>workbook</span> - - <span class='comment val'># get a fresh workbook automatically from the package</span> - <span class='wb identifier id'>wb</span> <span class='assign token'>=</span> <span class='Pacakge constant id'>Pacakge</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='rparen token'>)</span><span class='dot token'>.</span><span class='workbook identifier id'>workbook</span> - <span class='comment val'># # set the workbook after creating the package</span> - <span class='wb identifier id'>wb</span> <span class='assign token'>=</span> <span class='Package constant id'>Package</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='rparen token'>)</span><span class='dot token'>.</span><span class='workbook identifier id'>workbook</span> <span class='assign token'>=</span> <span class='Workbook constant id'>Workbook</span><span class='dot token'>.</span><span class='new identifier id'>new</span> -</pre> -</div> - </div> - -<p> -The workbook this package will serialize or validate. -</p> - - - </div> -</div> -<div class="tags"> - -<h3>Returns:</h3> -<ul class="return"> - - <li> - - - <span class='type'>(<tt><span class='object_link'><a href="Workbook.html" title="Axlsx::Workbook (class)">Workbook</a></span></tt>)</span> - - - - — - <div class='inline'><p> -If no workbook instance has been assigned with this package a new Workbook -instance is returned. -</p> -</div> - - </li> - -</ul> -<h3>Raises:</h3> -<ul class="raise"> - - <li> - - - <span class='type'></span> - - - - - <div class='inline'><p> -ArgumentError if workbook parameter is not a Workbook instance. -</p> -</div> - - </li> - -</ul> - -</div><table class="source_code"> - <tr> - <td> - <pre class="lines"> - - -21 -22 -23</pre> - </td> - <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/package.rb', line 21</span> - -<span class='def def kw'>def</span> <span class='workbook identifier id'>workbook</span> - <span class='@workbook ivar id'>@workbook</span> <span class='orop op'>||</span> <span class='@workbook ivar id'>@workbook</span> <span class='assign token'>=</span> <span class='Workbook constant id'>Workbook</span><span class='dot token'>.</span><span class='new identifier id'>new</span> -<span class='end end kw'>end</span> -</pre> - </td> - </tr> -</table> -</div> - - </div> - <div id="instance_method_details" class="method_details_list"> <h2>Instance Method Details</h2> <div class="method_details first"> - <p class="signature first" id="base_content_types-instance_method"> - - - (<tt><span class='object_link'><a href="ContentType.html" title="Axlsx::ContentType (class)">ContentType</a></span></tt>) <strong>base_content_types</strong> - - - -</p><div class="docstring"> - <div class="discussion"> - <p> -Creates the minimum content types for generating a valid xlsx document. -</p> - - - </div> -</div> -<div class="tags"> - -<h3>Returns:</h3> -<ul class="return"> - - <li> - - - <span class='type'>(<tt><span class='object_link'><a href="ContentType.html" title="Axlsx::ContentType (class)">ContentType</a></span></tt>)</span> - - - - </li> - -</ul> - -</div><table class="source_code"> - <tr> - <td> - <pre class="lines"> - - -182 -183 -184 -185 -186 -187 -188 -189 -190 -191 -192</pre> - </td> - <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/package.rb', line 182</span> - -<span class='def def kw'>def</span> <span class='base_content_types identifier id'>base_content_types</span> - <span class='c_types identifier id'>c_types</span> <span class='assign token'>=</span> <span class='ContentType constant id'>ContentType</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='rparen token'>)</span> - <span class='c_types identifier id'>c_types</span> <span class='lshft op'><<</span> <span class='Default constant id'>Default</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='symbol val'>:ContentType</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='RELS_CT constant id'>RELS_CT</span><span class='comma token'>,</span> <span class='symbol val'>:Extension</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='RELS_EX constant id'>RELS_EX</span><span class='rparen token'>)</span> - <span class='c_types identifier id'>c_types</span> <span class='lshft op'><<</span> <span class='Default constant id'>Default</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='symbol val'>:Extension</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='XML_EX constant id'>XML_EX</span><span class='comma token'>,</span> <span class='symbol val'>:ContentType</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='XML_CT constant id'>XML_CT</span><span class='rparen token'>)</span> - <span class='c_types identifier id'>c_types</span> <span class='lshft op'><<</span> <span class='Override constant id'>Override</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='symbol val'>:PartName</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='dstring node'>"/#{APP_PN}"</span><span class='comma token'>,</span> <span class='symbol val'>:ContentType</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='APP_CT constant id'>APP_CT</span><span class='rparen token'>)</span> - <span class='c_types identifier id'>c_types</span> <span class='lshft op'><<</span> <span class='Override constant id'>Override</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='symbol val'>:PartName</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='dstring node'>"/#{CORE_PN}"</span><span class='comma token'>,</span> <span class='symbol val'>:ContentType</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='CORE_CT constant id'>CORE_CT</span><span class='rparen token'>)</span> - <span class='c_types identifier id'>c_types</span> <span class='lshft op'><<</span> <span class='Override constant id'>Override</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='symbol val'>:PartName</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='dstring node'>"/xl/#{STYLES_PN}"</span><span class='comma token'>,</span> <span class='symbol val'>:ContentType</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='STYLES_CT constant id'>STYLES_CT</span><span class='rparen token'>)</span> - <span class='c_types identifier id'>c_types</span> <span class='lshft op'><<</span> <span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='Override constant id'>Override</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='symbol val'>:PartName</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='dstring node'>"/#{WORKBOOK_PN}"</span><span class='comma token'>,</span> <span class='symbol val'>:ContentType</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='WORKBOOK_CT constant id'>WORKBOOK_CT</span><span class='rparen token'>)</span> - <span class='c_types identifier id'>c_types</span><span class='dot token'>.</span><span class='lock identifier id'>lock</span> - <span class='c_types identifier id'>c_types</span> -<span class='end end kw'>end</span> -</pre> - </td> - </tr> -</table> -</div> - - <div class="method_details "> - <p class="signature " id="content_types-instance_method"> - - - (<tt><span class='object_link'><a href="ContentType.html" title="Axlsx::ContentType (class)">ContentType</a></span></tt>) <strong>content_types</strong> - - - -</p><div class="docstring"> - <div class="discussion"> - <p> -Appends override objects for drawings, charts, and sheets as they exist in -your workbook to the default content types. -</p> - - - </div> -</div> -<div class="tags"> - -<h3>Returns:</h3> -<ul class="return"> - - <li> - - - <span class='type'>(<tt><span class='object_link'><a href="ContentType.html" title="Axlsx::ContentType (class)">ContentType</a></span></tt>)</span> - - - - </li> - -</ul> - -</div><table class="source_code"> - <tr> - <td> - <pre class="lines"> - - -151 -152 -153 -154 -155 -156 -157 -158 -159 -160 -161 -162 -163 -164 -165 -166 -167 -168 -169 -170 -171 -172 -173 -174 -175 -176 -177</pre> - </td> - <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/package.rb', line 151</span> - -<span class='def def kw'>def</span> <span class='content_types identifier id'>content_types</span> - <span class='c_types identifier id'>c_types</span> <span class='assign token'>=</span> <span class='base_content_types identifier id'>base_content_types</span> - <span class='workbook identifier id'>workbook</span><span class='dot token'>.</span><span class='drawings identifier id'>drawings</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='drawing identifier id'>drawing</span><span class='bitor op'>|</span> - <span class='c_types identifier id'>c_types</span> <span class='lshft op'><<</span> <span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='Override constant id'>Override</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='symbol val'>:PartName</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='dstring node'>"/xl/#{drawing.pn}"</span><span class='comma token'>,</span> - <span class='symbol val'>:ContentType</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='DRAWING_CT constant id'>DRAWING_CT</span><span class='rparen token'>)</span> - <span class='end end kw'>end</span> - <span class='workbook identifier id'>workbook</span><span class='dot token'>.</span><span class='charts identifier id'>charts</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='chart identifier id'>chart</span><span class='bitor op'>|</span> - <span class='c_types identifier id'>c_types</span> <span class='lshft op'><<</span> <span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='Override constant id'>Override</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='symbol val'>:PartName</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='dstring node'>"/xl/#{chart.pn}"</span><span class='comma token'>,</span> - <span class='symbol val'>:ContentType</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='CHART_CT constant id'>CHART_CT</span><span class='rparen token'>)</span> - <span class='end end kw'>end</span> - <span class='workbook identifier id'>workbook</span><span class='dot token'>.</span><span class='worksheets identifier id'>worksheets</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='sheet identifier id'>sheet</span><span class='bitor op'>|</span> - <span class='c_types identifier id'>c_types</span> <span class='lshft op'><<</span> <span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='Override constant id'>Override</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='symbol val'>:PartName</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='dstring node'>"/xl/#{sheet.pn}"</span><span class='comma token'>,</span> - <span class='symbol val'>:ContentType</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='WORKSHEET_CT constant id'>WORKSHEET_CT</span><span class='rparen token'>)</span> - <span class='end end kw'>end</span> - <span class='exts identifier id'>exts</span> <span class='assign token'>=</span> <span class='workbook identifier id'>workbook</span><span class='dot token'>.</span><span class='images identifier id'>images</span><span class='dot token'>.</span><span class='map identifier id'>map</span> <span class='lbrace token'>{</span> <span class='bitor op'>|</span><span class='image identifier id'>image</span><span class='bitor op'>|</span> <span class='image identifier id'>image</span><span class='dot token'>.</span><span class='extname identifier id'>extname</span> <span class='rbrace token'>}</span> - <span class='exts identifier id'>exts</span><span class='dot token'>.</span><span class='uniq identifier id'>uniq</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='ext identifier id'>ext</span><span class='bitor op'>|</span> - <span class='ct identifier id'>ct</span> <span class='assign token'>=</span> <span class='if if kw'>if</span> <span class='lbrack token'>[</span><span class='string val'>'jpeg'</span><span class='comma token'>,</span> <span class='string val'>'jpg'</span><span class='rbrack token'>]</span><span class='dot token'>.</span><span class='include? fid id'>include?</span><span class='lparen token'>(</span><span class='ext identifier id'>ext</span><span class='rparen token'>)</span> - <span class='JPEG_CT constant id'>JPEG_CT</span> - <span class='elsif elsif kw'>elsif</span> <span class='ext identifier id'>ext</span> <span class='eq op'>==</span> <span class='string val'>'gif'</span> - <span class='GIF_CT constant id'>GIF_CT</span> - <span class='elsif elsif kw'>elsif</span> <span class='ext identifier id'>ext</span> <span class='eq op'>==</span> <span class='string val'>'png'</span> - <span class='PNG_CT constant id'>PNG_CT</span> - <span class='end end kw'>end</span> - <span class='c_types identifier id'>c_types</span> <span class='lshft op'><<</span> <span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='Default constant id'>Default</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='symbol val'>:ContentType</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='ct identifier id'>ct</span><span class='comma token'>,</span> <span class='symbol val'>:Extension</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='ext identifier id'>ext</span> <span class='rparen token'>)</span> - <span class='end end kw'>end</span> - <span class='c_types identifier id'>c_types</span> -<span class='end end kw'>end</span> -</pre> - </td> - </tr> -</table> -</div> - - <div class="method_details "> - <p class="signature " id="parts-instance_method"> - - - (<tt>Array</tt>) <strong>parts</strong> - - - -</p><div class="docstring"> - <div class="discussion"> - <p> -The parts of a package -</p> - - - </div> -</div> -<div class="tags"> - -<h3>Returns:</h3> -<ul class="return"> - - <li> - - - <span class='type'>(<tt>Array</tt>)</span> - - - - — - <div class='inline'><p> -An array of hashes that define the entry, document and schema for each part -of the package. -</p> -</div> - - </li> - -</ul> - -</div><table class="source_code"> - <tr> - <td> - <pre class="lines"> - - -101 -102 -103 -104 -105 -106 -107 -108 -109 -110 -111 -112 -113 -114 -115 -116 -117 -118 -119 -120 -121 -122 -123 -124 -125 -126 -127 -128 -129</pre> - </td> - <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/package.rb', line 101</span> - -<span class='def def kw'>def</span> <span class='parts identifier id'>parts</span> - <span class='@parts ivar id'>@parts</span> <span class='assign token'>=</span> <span class='lbrack token'>[</span> - <span class='lbrace token'>{</span><span class='symbol val'>:entry</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='RELS_PN constant id'>RELS_PN</span><span class='comma token'>,</span> <span class='symbol val'>:doc</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='relationships identifier id'>relationships</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='comma token'>,</span> <span class='symbol val'>:schema</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='RELS_XSD constant id'>RELS_XSD</span><span class='rbrace token'>}</span><span class='comma token'>,</span> - <span class='lbrace token'>{</span><span class='symbol val'>:entry</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='CORE_PN constant id'>CORE_PN</span><span class='comma token'>,</span> <span class='symbol val'>:doc</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='@core ivar id'>@core</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='comma token'>,</span> <span class='symbol val'>:schema</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='CORE_XSD constant id'>CORE_XSD</span><span class='rbrace token'>}</span><span class='comma token'>,</span> - <span class='lbrace token'>{</span><span class='symbol val'>:entry</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='APP_PN constant id'>APP_PN</span><span class='comma token'>,</span> <span class='symbol val'>:doc</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='@app ivar id'>@app</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='comma token'>,</span> <span class='symbol val'>:schema</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='APP_XSD constant id'>APP_XSD</span><span class='rbrace token'>}</span><span class='comma token'>,</span> - <span class='lbrace token'>{</span><span class='symbol val'>:entry</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='WORKBOOK_RELS_PN constant id'>WORKBOOK_RELS_PN</span><span class='comma token'>,</span> <span class='symbol val'>:doc</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='workbook identifier id'>workbook</span><span class='dot token'>.</span><span class='relationships identifier id'>relationships</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='comma token'>,</span> <span class='symbol val'>:schema</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='RELS_XSD constant id'>RELS_XSD</span><span class='rbrace token'>}</span><span class='comma token'>,</span> - <span class='lbrace token'>{</span><span class='symbol val'>:entry</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='WORKBOOK_PN constant id'>WORKBOOK_PN</span><span class='comma token'>,</span> <span class='symbol val'>:doc</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='workbook identifier id'>workbook</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='comma token'>,</span> <span class='symbol val'>:schema</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='SML_XSD constant id'>SML_XSD</span><span class='rbrace token'>}</span><span class='comma token'>,</span> - <span class='lbrace token'>{</span><span class='symbol val'>:entry</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='CONTENT_TYPES_PN constant id'>CONTENT_TYPES_PN</span><span class='comma token'>,</span> <span class='symbol val'>:doc</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='content_types identifier id'>content_types</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='comma token'>,</span> <span class='symbol val'>:schema</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='CONTENT_TYPES_XSD constant id'>CONTENT_TYPES_XSD</span><span class='rbrace token'>}</span><span class='comma token'>,</span> - <span class='lbrace token'>{</span><span class='symbol val'>:entry</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='dstring node'>"xl/#{STYLES_PN}"</span><span class='comma token'>,</span> <span class='symbol val'>:doc</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='workbook identifier id'>workbook</span><span class='dot token'>.</span><span class='styles identifier id'>styles</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='comma token'>,</span> <span class='symbol val'>:schema</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='SML_XSD constant id'>SML_XSD</span><span class='rbrace token'>}</span> - <span class='rbrack token'>]</span> - <span class='workbook identifier id'>workbook</span><span class='dot token'>.</span><span class='drawings identifier id'>drawings</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='drawing identifier id'>drawing</span><span class='bitor op'>|</span> - <span class='@parts ivar id'>@parts</span> <span class='lshft op'><<</span> <span class='lbrace token'>{</span><span class='symbol val'>:entry</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='dstring node'>"xl/#{drawing.rels_pn}"</span><span class='comma token'>,</span> <span class='symbol val'>:doc</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='drawing identifier id'>drawing</span><span class='dot token'>.</span><span class='relationships identifier id'>relationships</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='comma token'>,</span> <span class='symbol val'>:schema</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='RELS_XSD constant id'>RELS_XSD</span><span class='rbrace token'>}</span> - <span class='@parts ivar id'>@parts</span> <span class='lshft op'><<</span> <span class='lbrace token'>{</span><span class='symbol val'>:entry</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='dstring node'>"xl/#{drawing.pn}"</span><span class='comma token'>,</span> <span class='symbol val'>:doc</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='drawing identifier id'>drawing</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='comma token'>,</span> <span class='symbol val'>:schema</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='DRAWING_XSD constant id'>DRAWING_XSD</span><span class='rbrace token'>}</span> - <span class='end end kw'>end</span> - - <span class='workbook identifier id'>workbook</span><span class='dot token'>.</span><span class='charts identifier id'>charts</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='chart identifier id'>chart</span><span class='bitor op'>|</span> - <span class='@parts ivar id'>@parts</span> <span class='lshft op'><<</span> <span class='lbrace token'>{</span><span class='symbol val'>:entry</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='dstring node'>"xl/#{chart.pn}"</span><span class='comma token'>,</span> <span class='symbol val'>:doc</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='chart identifier id'>chart</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='comma token'>,</span> <span class='symbol val'>:schema</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='DRAWING_XSD constant id'>DRAWING_XSD</span><span class='rbrace token'>}</span> - <span class='end end kw'>end</span> - - <span class='workbook identifier id'>workbook</span><span class='dot token'>.</span><span class='images identifier id'>images</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='image identifier id'>image</span><span class='bitor op'>|</span> - <span class='@parts ivar id'>@parts</span> <span class='lshft op'><<</span> <span class='lbrace token'>{</span><span class='symbol val'>:entry</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='dstring node'>"xl/#{image.pn}"</span><span class='comma token'>,</span> <span class='symbol val'>:path</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='image identifier id'>image</span><span class='dot token'>.</span><span class='image_src identifier id'>image_src</span><span class='rbrace token'>}</span> - <span class='end end kw'>end</span> - - <span class='workbook identifier id'>workbook</span><span class='dot token'>.</span><span class='worksheets identifier id'>worksheets</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='sheet identifier id'>sheet</span><span class='bitor op'>|</span> - <span class='@parts ivar id'>@parts</span> <span class='lshft op'><<</span> <span class='lbrace token'>{</span><span class='symbol val'>:entry</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='dstring node'>"xl/#{sheet.rels_pn}"</span><span class='comma token'>,</span> <span class='symbol val'>:doc</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='relationships identifier id'>relationships</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='comma token'>,</span> <span class='symbol val'>:schema</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='RELS_XSD constant id'>RELS_XSD</span><span class='rbrace token'>}</span> - <span class='@parts ivar id'>@parts</span> <span class='lshft op'><<</span> <span class='lbrace token'>{</span><span class='symbol val'>:entry</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='dstring node'>"xl/#{sheet.pn}"</span><span class='comma token'>,</span> <span class='symbol val'>:doc</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='comma token'>,</span> <span class='symbol val'>:schema</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='SML_XSD constant id'>SML_XSD</span><span class='rbrace token'>}</span> - <span class='end end kw'>end</span> - <span class='@parts ivar id'>@parts</span> -<span class='end end kw'>end</span> -</pre> - </td> - </tr> -</table> -</div> - - <div class="method_details "> - <p class="signature " id="relationships-instance_method"> - - - (<tt><span class='object_link'><a href="Relationships.html" title="Axlsx::Relationships (class)">Relationships</a></span></tt>) <strong>relationships</strong> - - - -</p><div class="docstring"> - <div class="discussion"> - <p> -Creates the relationships required for a valid xlsx document -</p> - - - </div> -</div> -<div class="tags"> - -<h3>Returns:</h3> -<ul class="return"> - - <li> - - - <span class='type'>(<tt><span class='object_link'><a href="Relationships.html" title="Axlsx::Relationships (class)">Relationships</a></span></tt>)</span> - - - - </li> - -</ul> - -</div><table class="source_code"> - <tr> - <td> - <pre class="lines"> - - -197 -198 -199 -200 -201 -202 -203 -204</pre> - </td> - <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/package.rb', line 197</span> - -<span class='def def kw'>def</span> <span class='relationships identifier id'>relationships</span> - <span class='rels identifier id'>rels</span> <span class='assign token'>=</span> <span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='Relationships constant id'>Relationships</span><span class='dot token'>.</span><span class='new identifier id'>new</span> - <span class='rels identifier id'>rels</span> <span class='lshft op'><<</span> <span class='Relationship constant id'>Relationship</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='WORKBOOK_R constant id'>WORKBOOK_R</span><span class='comma token'>,</span> <span class='WORKBOOK_PN constant id'>WORKBOOK_PN</span><span class='rparen token'>)</span> - <span class='rels identifier id'>rels</span> <span class='lshft op'><<</span> <span class='Relationship constant id'>Relationship</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='CORE_R constant id'>CORE_R</span><span class='comma token'>,</span> <span class='CORE_PN constant id'>CORE_PN</span><span class='rparen token'>)</span> - <span class='rels identifier id'>rels</span> <span class='lshft op'><<</span> <span class='Relationship constant id'>Relationship</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='APP_R constant id'>APP_R</span><span class='comma token'>,</span> <span class='APP_PN constant id'>APP_PN</span><span class='rparen token'>)</span> - <span class='rels identifier id'>rels</span><span class='dot token'>.</span><span class='lock identifier id'>lock</span> - <span class='rels identifier id'>rels</span> -<span class='end end kw'>end</span> -</pre> - </td> - </tr> -</table> -</div> - - <div class="method_details "> - <p class="signature " id="serialize-instance_method"> + <p class="signature first" id="serialize-instance_method"> - (<tt>Boolean</tt>) <strong>serialize</strong>(output, confirm_valid = false) @@ -964,17 +389,15 @@ Creates the relationships required for a valid xlsx document <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -A tremendous amount of effort has gone into ensuring that you cannot create + <div class='inline'> +<p>A tremendous amount of effort has gone into ensuring that you cannot create invalid xlsx documents. confirm_valid should be used in the rare case that -you cannot open the serialized file. -</p> +you cannot open the serialized file.</p> </div> </div> -<p> -Serialize your workbook to disk as an xlsx document. -</p> + +<p>Serialize your workbook to disk as an xlsx document.</p> </div> @@ -985,13 +408,12 @@ Serialize your workbook to disk as an xlsx document. <h3>Examples:</h3> <h4><div class='inline'></div></h4> - <pre class="example code"><span class='comment val'># This is how easy it is to create a valid xlsx file. Of course you might want to add a sheet or two, and maybe some data, styles and charts.</span> -<span class='comment val'># Take a look at the README for an example of how to do it!</span> -<span class='f identifier id'>f</span> <span class='assign token'>=</span> <span class='File constant id'>File</span><span class='dot token'>.</span><span class='open identifier id'>open</span><span class='lparen token'>(</span><span class='string val'>'test.xlsx'</span><span class='comma token'>,</span> <span class='string val'>'w'</span><span class='rparen token'>)</span> -<span class='Package constant id'>Package</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='dot token'>.</span><span class='serialize identifier id'>serialize</span><span class='lparen token'>(</span><span class='f identifier id'>f</span><span class='rparen token'>)</span> + <pre class="example code"><span class='comment'># This is how easy it is to create a valid xlsx file. Of course you might want to add a sheet or two, and maybe some data, styles and charts. +</span><span class='comment'># Take a look at the README for an example of how to do it! +</span><span class='id f'>f</span> <span class='op'>=</span> <span class='const'>File</span><span class='period'>.</span><span class='id open'>open</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>test.xlsx</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>w</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> +<span class='const'>Package</span><span class='period'>.</span><span class='id new'>new</span><span class='period'>.</span><span class='id serialize'>serialize</span><span class='lparen'>(</span><span class='id f'>f</span><span class='rparen'>)</span> -<span class='comment val'># You will find a file called test.xlsx</span> -</pre> +<span class='comment'># You will find a file called test.xlsx</span></pre> </div> <h3>Parameters:</h3> @@ -1007,9 +429,8 @@ Serialize your workbook to disk as an xlsx document. — - <div class='inline'><p> -The file you want to serialize your package to -</p> + <div class='inline'> +<p>The file you want to serialize your package to</p> </div> </li> @@ -1026,9 +447,8 @@ The file you want to serialize your package to — - <div class='inline'><p> -Validate the package prior to serialization. -</p> + <div class='inline'> +<p>Validate the package prior to serialization.</p> </div> </li> @@ -1046,10 +466,9 @@ Validate the package prior to serialization. — - <div class='inline'><p> -False if confirm_valid and validation errors exist. True if the package was -serialized -</p> + <div class='inline'> +<p>False if confirm_valid and validation errors exist. True if the package was +serialized</p> </div> </li> @@ -1069,6 +488,7 @@ serialized <pre class="lines"> +54 55 56 57 @@ -1085,33 +505,29 @@ serialized 68 69 70 -71 -72 -73</pre> +71</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/package.rb', line 55</span> - -<span class='def def kw'>def</span> <span class='serialize identifier id'>serialize</span><span class='lparen token'>(</span><span class='output identifier id'>output</span><span class='comma token'>,</span> <span class='confirm_valid identifier id'>confirm_valid</span><span class='assign token'>=</span><span class='false false kw'>false</span><span class='rparen token'>)</span> - <span class='return return kw'>return</span> <span class='false false kw'>false</span> <span class='unless unless_mod kw'>unless</span> <span class='notop op'>!</span><span class='confirm_valid identifier id'>confirm_valid</span> <span class='orop op'>||</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='validate identifier id'>validate</span><span class='dot token'>.</span><span class='empty? fid id'>empty?</span> - <span class='p identifier id'>p</span> <span class='assign token'>=</span> <span class='parts identifier id'>parts</span> - <span class='Zip constant id'>Zip</span><span class='colon2 op'>::</span><span class='ZipOutputStream constant id'>ZipOutputStream</span><span class='dot token'>.</span><span class='open identifier id'>open</span><span class='lparen token'>(</span><span class='output identifier id'>output</span><span class='rparen token'>)</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='zip identifier id'>zip</span><span class='bitor op'>|</span> - <span class='p identifier id'>p</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='part identifier id'>part</span><span class='bitor op'>|</span> - <span class='zip identifier id'>zip</span><span class='dot token'>.</span><span class='put_next_entry identifier id'>put_next_entry</span><span class='lparen token'>(</span><span class='part identifier id'>part</span><span class='lbrack token'>[</span><span class='symbol val'>:entry</span><span class='rbrack token'>]</span><span class='rparen token'>)</span><span class='semicolon token'>;</span> <span class='zip identifier id'>zip</span><span class='dot token'>.</span><span class='puts identifier id'>puts</span><span class='lparen token'>(</span><span class='part identifier id'>part</span><span class='lbrack token'>[</span><span class='symbol val'>:doc</span><span class='rbrack token'>]</span><span class='rparen token'>)</span> <span class='unless unless_mod kw'>unless</span> <span class='part identifier id'>part</span><span class='lbrack token'>[</span><span class='symbol val'>:doc</span><span class='rbrack token'>]</span><span class='dot token'>.</span><span class='nil? fid id'>nil?</span> - <span class='end end kw'>end</span> - <span class='end end kw'>end</span> - <span class='Zip constant id'>Zip</span><span class='colon2 op'>::</span><span class='ZipFile constant id'>ZipFile</span><span class='dot token'>.</span><span class='open identifier id'>open</span><span class='lparen token'>(</span><span class='output identifier id'>output</span><span class='rparen token'>)</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='zip identifier id'>zip</span><span class='bitor op'>|</span> - <span class='p identifier id'>p</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='part identifier id'>part</span><span class='bitor op'>|</span> - <span class='if if kw'>if</span> <span class='part identifier id'>part</span><span class='lbrack token'>[</span><span class='symbol val'>:path</span><span class='rbrack token'>]</span> - <span class='zip identifier id'>zip</span><span class='dot token'>.</span><span class='add identifier id'>add</span><span class='lparen token'>(</span><span class='part identifier id'>part</span><span class='lbrack token'>[</span><span class='symbol val'>:entry</span><span class='rbrack token'>]</span><span class='comma token'>,</span> <span class='part identifier id'>part</span><span class='lbrack token'>[</span><span class='symbol val'>:path</span><span class='rbrack token'>]</span><span class='comma token'>,</span> <span class='bitand op'>&</span><span class='proc identifier id'>proc</span><span class='lbrace token'>{</span> <span class='true true kw'>true</span> <span class='rbrace token'>}</span><span class='rparen token'>)</span> - <span class='end end kw'>end</span> - <span class='end end kw'>end</span> - <span class='end end kw'>end</span> - - - <span class='true true kw'>true</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/package.rb', line 54</span> + +<span class='kw'>def</span> <span class='id serialize'>serialize</span><span class='lparen'>(</span><span class='id output'>output</span><span class='comma'>,</span> <span class='id confirm_valid'>confirm_valid</span><span class='op'>=</span><span class='kw'>false</span><span class='rparen'>)</span> + <span class='kw'>return</span> <span class='kw'>false</span> <span class='kw'>unless</span> <span class='op'>!</span><span class='id confirm_valid'>confirm_valid</span> <span class='op'>||</span> <span class='kw'>self</span><span class='period'>.</span><span class='id validate'>validate</span><span class='period'>.</span><span class='id empty?'>empty?</span> + <span class='id p'>p</span> <span class='op'>=</span> <span class='id parts'>parts</span> + <span class='const'>Zip</span><span class='op'>::</span><span class='const'>ZipOutputStream</span><span class='period'>.</span><span class='id open'>open</span><span class='lparen'>(</span><span class='id output'>output</span><span class='rparen'>)</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id zip'>zip</span><span class='op'>|</span> + <span class='id p'>p</span><span class='period'>.</span><span class='id each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id part'>part</span><span class='op'>|</span> + <span class='kw'>unless</span> <span class='id part'>part</span><span class='lbracket'>[</span><span class='symbol'>:doc</span><span class='rbracket'>]</span><span class='period'>.</span><span class='id nil?'>nil?</span> + <span class='id zip'>zip</span><span class='period'>.</span><span class='id put_next_entry'>put_next_entry</span><span class='lparen'>(</span><span class='id part'>part</span><span class='lbracket'>[</span><span class='symbol'>:entry</span><span class='rbracket'>]</span><span class='rparen'>)</span><span class='semicolon'>;</span> + <span class='id zip'>zip</span><span class='period'>.</span><span class='id puts'>puts</span><span class='lparen'>(</span><span class='id part'>part</span><span class='lbracket'>[</span><span class='symbol'>:doc</span><span class='rbracket'>]</span><span class='rparen'>)</span> + <span class='kw'>end</span> + <span class='kw'>unless</span> <span class='id part'>part</span><span class='lbracket'>[</span><span class='symbol'>:path</span><span class='rbracket'>]</span><span class='period'>.</span><span class='id nil?'>nil?</span> + <span class='id zip'>zip</span><span class='period'>.</span><span class='id put_next_entry'>put_next_entry</span><span class='lparen'>(</span><span class='id part'>part</span><span class='lbracket'>[</span><span class='symbol'>:entry</span><span class='rbracket'>]</span><span class='rparen'>)</span><span class='semicolon'>;</span> + <span class='comment'># binread for 1.9.3 +</span> <span class='id zip'>zip</span><span class='period'>.</span><span class='id write'>write</span> <span class='const'>IO</span><span class='period'>.</span><span class='id respond_to?'>respond_to?</span><span class='lparen'>(</span><span class='symbol'>:binread</span><span class='rparen'>)</span> <span class='op'>?</span> <span class='const'>IO</span><span class='period'>.</span><span class='id binread'>binread</span><span class='lparen'>(</span><span class='id part'>part</span><span class='lbracket'>[</span><span class='symbol'>:path</span><span class='rbracket'>]</span><span class='rparen'>)</span> <span class='op'>:</span> <span class='const'>IO</span><span class='period'>.</span><span class='id read'>read</span><span class='lparen'>(</span><span class='id part'>part</span><span class='lbracket'>[</span><span class='symbol'>:path</span><span class='rbracket'>]</span><span class='rparen'>)</span> + <span class='kw'>end</span> + <span class='kw'>end</span> + <span class='kw'>end</span> + <span class='kw'>true</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1129,25 +545,22 @@ serialized <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -This gem includes all schema from OfficeOpenXML-XMLSchema-Transitional.zip + <div class='inline'> +<p>This gem includes all schema from OfficeOpenXML-XMLSchema-Transitional.zip and OpenPackagingConventions-XMLSchema.zip as per ECMA-376, Third edition. opc schema require an internet connection to import remote schema from dublin core for dc, dcterms and xml namespaces. Those remote schema are -included in this gem, and the original files have been altered to refer to -the local versions. -</p> -<p> -If by chance you are able to creat a package that does not validate it +included in this gem, and the original files have been altered to refer to +the local versions.</p> + +<p>If by chance you are able to creat a package that does not validate it indicates that the internal validation is not robust enough and needs to be -improved. Please report your errors to the gem author. -</p> +improved. Please report your errors to the gem author.</p> </div> </div> -<p> -Validate all parts of the package against xsd schema. -</p> + +<p>Validate all parts of the package against xsd schema.</p> </div> @@ -1158,11 +571,10 @@ Validate all parts of the package against xsd schema. <h3>Examples:</h3> <h4><div class='inline'></div></h4> - <pre class="example code"><span class='comment val'># The following will output any error messages found in serialization.</span> -<span class='p identifier id'>p</span> <span class='assign token'>=</span> <span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='Package constant id'>Package</span><span class='dot token'>.</span><span class='new identifier id'>new</span> -<span class='comment val'># ... code to create sheets, charts, styles etc.</span> -<span class='p identifier id'>p</span><span class='dot token'>.</span><span class='validate identifier id'>validate</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='lbrace token'>{</span> <span class='bitor op'>|</span><span class='error identifier id'>error</span><span class='bitor op'>|</span> <span class='puts identifier id'>puts</span> <span class='error identifier id'>error</span><span class='dot token'>.</span><span class='message identifier id'>message</span> <span class='rbrace token'>}</span> -</pre> + <pre class="example code"><span class='comment'># The following will output any error messages found in serialization. +</span><span class='id p'>p</span> <span class='op'>=</span> <span class='const'>Axlsx</span><span class='op'>::</span><span class='const'>Package</span><span class='period'>.</span><span class='id new'>new</span> +<span class='comment'># ... code to create sheets, charts, styles etc. +</span><span class='id p'>p</span><span class='period'>.</span><span class='id validate'>validate</span><span class='period'>.</span><span class='id each'>each</span> <span class='lbrace'>{</span> <span class='op'>|</span><span class='id error'>error</span><span class='op'>|</span> <span class='id puts'>puts</span> <span class='id error'>error</span><span class='period'>.</span><span class='id message'>message</span> <span class='rbrace'>}</span></pre> </div> @@ -1177,9 +589,8 @@ Validate all parts of the package against xsd schema. — - <div class='inline'><p> -An array of all validation errors found. -</p> + <div class='inline'> +<p>An array of all validation errors found.</p> </div> </li> @@ -1199,101 +610,140 @@ An array of all validation errors found. <pre class="lines"> +88 +89 90 91 -92 -93 -94</pre> +92</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/package.rb', line 90</span> - -<span class='def def kw'>def</span> <span class='validate identifier id'>validate</span> - <span class='errors identifier id'>errors</span> <span class='assign token'>=</span> <span class='lbrack token'>[</span><span class='rbrack token'>]</span> - <span class='parts identifier id'>parts</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='lbrace token'>{</span> <span class='bitor op'>|</span><span class='part identifier id'>part</span><span class='bitor op'>|</span> <span class='errors identifier id'>errors</span><span class='dot token'>.</span><span class='concat identifier id'>concat</span> <span class='validate_single_doc identifier id'>validate_single_doc</span><span class='lparen token'>(</span><span class='part identifier id'>part</span><span class='lbrack token'>[</span><span class='symbol val'>:schema</span><span class='rbrack token'>]</span><span class='comma token'>,</span> <span class='part identifier id'>part</span><span class='lbrack token'>[</span><span class='symbol val'>:doc</span><span class='rbrack token'>]</span><span class='rparen token'>)</span> <span class='unless unless_mod kw'>unless</span> <span class='part identifier id'>part</span><span class='lbrack token'>[</span><span class='symbol val'>:schema</span><span class='rbrack token'>]</span><span class='dot token'>.</span><span class='nil? fid id'>nil?</span> <span class='rbrace token'>}</span> - <span class='errors identifier id'>errors</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/package.rb', line 88</span> + +<span class='kw'>def</span> <span class='id validate'>validate</span> + <span class='id errors'>errors</span> <span class='op'>=</span> <span class='lbracket'>[</span><span class='rbracket'>]</span> + <span class='id parts'>parts</span><span class='period'>.</span><span class='id each'>each</span> <span class='lbrace'>{</span> <span class='op'>|</span><span class='id part'>part</span><span class='op'>|</span> <span class='id errors'>errors</span><span class='period'>.</span><span class='id concat'>concat</span> <span class='id validate_single_doc'>validate_single_doc</span><span class='lparen'>(</span><span class='id part'>part</span><span class='lbracket'>[</span><span class='symbol'>:schema</span><span class='rbracket'>]</span><span class='comma'>,</span> <span class='id part'>part</span><span class='lbracket'>[</span><span class='symbol'>:doc</span><span class='rbracket'>]</span><span class='rparen'>)</span> <span class='kw'>unless</span> <span class='id part'>part</span><span class='lbracket'>[</span><span class='symbol'>:schema</span><span class='rbracket'>]</span><span class='period'>.</span><span class='id nil?'>nil?</span> <span class='rbrace'>}</span> + <span class='id errors'>errors</span> +<span class='kw'>end</span></pre> </td> </tr> </table> </div> <div class="method_details "> - <p class="signature " id="validate_single_doc-instance_method"> + <p class="signature " id="workbook-instance_method"> - - (<tt>Array</tt>) <strong>validate_single_doc</strong>(schema, doc) + - (<tt><span class='object_link'><a href="Workbook.html" title="Axlsx::Workbook (class)">Workbook</a></span></tt>) <strong>workbook</strong> </p><div class="docstring"> <div class="discussion"> - <p> -Performs xsd validation for a signle document -</p> + + <div class="note notetag"> + <strong>Note:</strong> + <div class='inline'> +<p>As there are multiple ways to instantiate a workbook for the package, here +are a few examples:</p> + +<pre class="code"><span class='comment'># assign directly during package instanciation +</span><span class='id wb'>wb</span> <span class='op'>=</span> <span class='const'>Package</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='symbol'>:workbook</span> <span class='op'>=></span> <span class='const'>Workbook</span><span class='period'>.</span><span class='id new'>new</span><span class='rparen'>)</span><span class='period'>.</span><span class='id workbook'>workbook</span> + +<span class='comment'># get a fresh workbook automatically from the package +</span><span class='id wb'>wb</span> <span class='op'>=</span> <span class='const'>Pacakge</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='rparen'>)</span><span class='period'>.</span><span class='id workbook'>workbook</span> +<span class='comment'># # set the workbook after creating the package +</span><span class='id wb'>wb</span> <span class='op'>=</span> <span class='const'>Package</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='rparen'>)</span><span class='period'>.</span><span class='id workbook'>workbook</span> <span class='op'>=</span> <span class='const'>Workbook</span><span class='period'>.</span><span class='id new'>new</span></pre> +</div> + </div> + + +<p>The workbook this package will serialize or validate.</p> </div> </div> <div class="tags"> - <h3>Parameters:</h3> -<ul class="param"> + +<h3>Returns:</h3> +<ul class="return"> <li> - <span class='name'>schema</span> - - <span class='type'>(<tt>String</tt>)</span> + <span class='type'>(<tt><span class='object_link'><a href="Workbook.html" title="Axlsx::Workbook (class)">Workbook</a></span></tt>)</span> — - <div class='inline'><p> -path to the xsd schema to be used in validation. -</p> + <div class='inline'> +<p>If no workbook instance has been assigned with this package a new Workbook +instance is returned.</p> </div> </li> +</ul> +<h3>Raises:</h3> +<ul class="raise"> + <li> - <span class='name'>doc</span> - - <span class='type'>(<tt>String</tt>)</span> + <span class='type'></span> - — - <div class='inline'><p> -The xml text to be validated -</p> + + <div class='inline'> +<p>ArgumentError if workbook parameter is not a Workbook instance.</p> </div> </li> </ul> -<h3>Returns:</h3> -<ul class="return"> +</div><table class="source_code"> + <tr> + <td> + <pre class="lines"> + + +32 +33 +34</pre> + </td> + <td> + <pre class="code"><span class="info file"># File 'lib/axlsx/package.rb', line 32</span> + +<span class='kw'>def</span> <span class='id workbook'>workbook</span> + <span class='ivar'>@workbook</span> <span class='op'>||</span> <span class='ivar'>@workbook</span> <span class='op'>=</span> <span class='const'>Workbook</span><span class='period'>.</span><span class='id new'>new</span> +<span class='kw'>end</span></pre> + </td> + </tr> +</table> +</div> + + <div class="method_details "> + <p class="signature " id="workbook=-instance_method"> - <li> - - - <span class='type'>(<tt>Array</tt>)</span> - - - - — - <div class='inline'><p> -An array of all validation errors encountered. -</p> + - (<tt>Object</tt>) <strong>workbook=</strong>(workbook) + + + +</p><div class="docstring"> + <div class="discussion"> + + + </div> </div> - - </li> +<div class="tags"> -</ul> + + <h3>See Also:</h3> + <ul class="see"> + + <li>workbook</li> + + </ul> </div><table class="source_code"> <tr> @@ -1301,31 +751,12 @@ An array of all validation errors encountered. <pre class="lines"> -137 -138 -139 -140 -141 -142 -143 -144 -145 -146</pre> +37</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/package.rb', line 137</span> - -<span class='def def kw'>def</span> <span class='validate_single_doc identifier id'>validate_single_doc</span><span class='lparen token'>(</span><span class='schema identifier id'>schema</span><span class='comma token'>,</span> <span class='doc identifier id'>doc</span><span class='rparen token'>)</span> - <span class='schema identifier id'>schema</span> <span class='assign token'>=</span> <span class='Nokogiri constant id'>Nokogiri</span><span class='colon2 op'>::</span><span class='XML constant id'>XML</span><span class='colon2 op'>::</span><span class='Schema constant id'>Schema</span><span class='lparen token'>(</span><span class='File constant id'>File</span><span class='dot token'>.</span><span class='open identifier id'>open</span><span class='lparen token'>(</span><span class='schema identifier id'>schema</span><span class='rparen token'>)</span><span class='rparen token'>)</span> - <span class='doc identifier id'>doc</span> <span class='assign token'>=</span> <span class='Nokogiri constant id'>Nokogiri</span><span class='colon2 op'>::</span><span class='XML constant id'>XML</span><span class='lparen token'>(</span><span class='doc identifier id'>doc</span><span class='rparen token'>)</span> - - <span class='errors identifier id'>errors</span> <span class='assign token'>=</span> <span class='lbrack token'>[</span><span class='rbrack token'>]</span> - <span class='schema identifier id'>schema</span><span class='dot token'>.</span><span class='validate identifier id'>validate</span><span class='lparen token'>(</span><span class='doc identifier id'>doc</span><span class='rparen token'>)</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='error identifier id'>error</span><span class='bitor op'>|</span> - <span class='errors identifier id'>errors</span> <span class='lshft op'><<</span> <span class='error identifier id'>error</span> - <span class='end end kw'>end</span> - <span class='errors identifier id'>errors</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/package.rb', line 37</span> + +<span class='kw'>def</span> <span class='id workbook='>workbook=</span><span class='lparen'>(</span><span class='id workbook'>workbook</span><span class='rparen'>)</span> <span class='const'>DataTypeValidator</span><span class='period'>.</span><span class='id validate'>validate</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Package.workbook</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='const'>Workbook</span><span class='comma'>,</span> <span class='id workbook'>workbook</span><span class='semicolon'>;</span> <span class='ivar'>@workbook</span> <span class='op'>=</span> <span class='id workbook'>workbook</span><span class='semicolon'>;</span> <span class='kw'>end</span></pre> </td> </tr> </table> @@ -1336,9 +767,9 @@ An array of all validation errors encountered. </div> <div id="footer"> - Generated on Wed Nov 23 22:20:59 2011 by + Generated on Sat Nov 26 13:16:36 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/PatternFill.html b/doc/Axlsx/PatternFill.html index 3565ee12..c49ced12 100644 --- a/doc/Axlsx/PatternFill.html +++ b/doc/Axlsx/PatternFill.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::PatternFill - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -97,15 +97,13 @@ <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -The recommended way to manage styles is with Styles#add_style -</p> + <div class='inline'> +<p>The recommended way to manage styles is with Styles#add_style</p> </div> </div> -<p> -A PatternFill is the pattern and solid fill styling for a cell. -</p> + +<p>A PatternFill is the pattern and solid fill styling for a cell.</p> </div> @@ -144,9 +142,8 @@ A PatternFill is the pattern and solid fill styling for a cell. - <span class="summary_desc"><div class='inline'><p> -The color to use for the background of the fill when the type is not solid. -</p> + <span class="summary_desc"><div class='inline'> +<p>The color to use for the background of the fill when the type is not solid.</p> </div></span> </li> @@ -171,9 +168,8 @@ The color to use for the background of the fill when the type is not solid. - <span class="summary_desc"><div class='inline'><p> -The color to use for the the background in solid fills. -</p> + <span class="summary_desc"><div class='inline'> +<p>The color to use for the the background in solid fills.</p> </div></span> </li> @@ -198,9 +194,8 @@ The color to use for the the background in solid fills. - <span class="summary_desc"><div class='inline'><p> -The pattern type to use. -</p> + <span class="summary_desc"><div class='inline'> +<p>The pattern type to use.</p> </div></span> </li> @@ -237,9 +232,8 @@ The pattern type to use. - <span class="summary_desc"><div class='inline'><p> -Creates a new PatternFill Object. -</p> + <span class="summary_desc"><div class='inline'> +<p>Creates a new PatternFill Object.</p> </div></span> </li> @@ -261,9 +255,8 @@ Creates a new PatternFill Object. - <span class="summary_desc"><div class='inline'><p> -Serializes the pattern fill. -</p> + <span class="summary_desc"><div class='inline'> +<p>Serializes the pattern fill.</p> </div></span> </li> @@ -284,9 +277,8 @@ Serializes the pattern fill. </p><div class="docstring"> <div class="discussion"> - <p> -Creates a new PatternFill Object -</p> + +<p>Creates a new PatternFill Object</p> </div> @@ -307,9 +299,8 @@ Creates a new PatternFill Object — - <div class='inline'><p> -a customizable set of options -</p> + <div class='inline'> +<p>a customizable set of options</p> </div> </li> @@ -369,13 +360,12 @@ a customizable set of options <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/pattern_fill.rb', line 44</span> -<span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span><span class='lparen token'>(</span><span class='options identifier id'>options</span><span class='assign token'>=</span><span class='lbrace token'>{</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> - <span class='@patternType ivar id'>@patternType</span> <span class='assign token'>=</span> <span class='symbol val'>:none</span> - <span class='options identifier id'>options</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='o identifier id'>o</span><span class='bitor op'>|</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='dstring node'>"#{o[0]}="</span><span class='comma token'>,</span> <span class='o identifier id'>o</span><span class='lbrack token'>[</span><span class='integer val'>1</span><span class='rbrack token'>]</span><span class='rparen token'>)</span> <span class='if if_mod kw'>if</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='respond_to? fid id'>respond_to?</span> <span class='dstring node'>"#{o[0]}="</span> - <span class='end end kw'>end</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id initialize'>initialize</span><span class='lparen'>(</span><span class='id options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span> + <span class='ivar'>@patternType</span> <span class='op'>=</span> <span class='symbol'>:none</span> + <span class='id options'>options</span><span class='period'>.</span><span class='id each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id o'>o</span><span class='op'>|</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span><span class='rbrace'>}</span><span class='tstring_content'>=</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>1</span><span class='rbracket'>]</span><span class='rparen'>)</span> <span class='kw'>if</span> <span class='kw'>self</span><span class='period'>.</span><span class='id respond_to?'>respond_to?</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span><span class='rbrace'>}</span><span class='tstring_content'>=</span><span class='tstring_end'>"</span></span> + <span class='kw'>end</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -398,9 +388,8 @@ a customizable set of options </p><div class="docstring"> <div class="discussion"> - <p> -The color to use for the background of the fill when the type is not solid. -</p> + +<p>The color to use for the background of the fill when the type is not solid.</p> </div> @@ -434,10 +423,9 @@ The color to use for the background of the fill when the type is not solid. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/pattern_fill.rb', line 13</span> -<span class='def def kw'>def</span> <span class='bgColor identifier id'>bgColor</span> - <span class='@bgColor ivar id'>@bgColor</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id bgColor'>bgColor</span> + <span class='ivar'>@bgColor</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -455,9 +443,8 @@ The color to use for the background of the fill when the type is not solid. </p><div class="docstring"> <div class="discussion"> - <p> -The color to use for the the background in solid fills. -</p> + +<p>The color to use for the the background in solid fills.</p> </div> @@ -491,10 +478,9 @@ The color to use for the the background in solid fills. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/pattern_fill.rb', line 9</span> -<span class='def def kw'>def</span> <span class='fgColor identifier id'>fgColor</span> - <span class='@fgColor ivar id'>@fgColor</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id fgColor'>fgColor</span> + <span class='ivar'>@fgColor</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -515,36 +501,33 @@ The color to use for the the background in solid fills. <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -patternType must be one of -</p> -<pre class="code"> - <span class='symbol val'>:none</span> - <span class='symbol val'>:solid</span> - <span class='symbol val'>:mediumGray</span> - <span class='symbol val'>:darkGray</span> - <span class='symbol val'>:lightGray</span> - <span class='symbol val'>:darkHorizontal</span> - <span class='symbol val'>:darkVertical</span> - <span class='symbol val'>:darkDown</span> - <span class='symbol val'>:darkUp</span> - <span class='symbol val'>:darkGrid</span> - <span class='symbol val'>:darkTrellis</span> - <span class='symbol val'>:lightHorizontal</span> - <span class='symbol val'>:lightVertical</span> - <span class='symbol val'>:lightDown</span> - <span class='symbol val'>:lightUp</span> - <span class='symbol val'>:lightGrid</span> - <span class='symbol val'>:lightTrellis</span> - <span class='symbol val'>:gray125</span> - <span class='symbol val'>:gray0625</span> -</pre> + <div class='inline'> +<p>patternType must be one of</p> + +<pre class="code"><span class='symbol'>:none</span> +<span class='symbol'>:solid</span> +<span class='symbol'>:mediumGray</span> +<span class='symbol'>:darkGray</span> +<span class='symbol'>:lightGray</span> +<span class='symbol'>:darkHorizontal</span> +<span class='symbol'>:darkVertical</span> +<span class='symbol'>:darkDown</span> +<span class='symbol'>:darkUp</span> +<span class='symbol'>:darkGrid</span> +<span class='symbol'>:darkTrellis</span> +<span class='symbol'>:lightHorizontal</span> +<span class='symbol'>:lightVertical</span> +<span class='symbol'>:lightDown</span> +<span class='symbol'>:lightUp</span> +<span class='symbol'>:lightGrid</span> +<span class='symbol'>:lightTrellis</span> +<span class='symbol'>:gray125</span> +<span class='symbol'>:gray0625</span></pre> </div> </div> -<p> -The pattern type to use -</p> + +<p>The pattern type to use</p> </div> @@ -572,10 +555,9 @@ The pattern type to use <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/pattern_fill.rb', line 38</span> -<span class='def def kw'>def</span> <span class='patternType identifier id'>patternType</span> - <span class='@patternType ivar id'>@patternType</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id patternType'>patternType</span> + <span class='ivar'>@patternType</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -597,9 +579,8 @@ The pattern type to use </p><div class="docstring"> <div class="discussion"> - <p> -Serializes the pattern fill -</p> + +<p>Serializes the pattern fill</p> </div> @@ -618,9 +599,8 @@ Serializes the pattern fill — - <div class='inline'><p> -The document builder instance this objects xml will be added to. -</p> + <div class='inline'> +<p>The document builder instance this objects xml will be added to.</p> </div> </li> @@ -647,21 +627,20 @@ The document builder instance this objects xml will be added to. <pre class="lines"> -58 -59 60 61 -62</pre> +62 +63 +64</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/pattern_fill.rb', line 58</span> - -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='patternFill identifier id'>patternFill</span><span class='lparen token'>(</span><span class='symbol val'>:patternType</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='patternType identifier id'>patternType</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='instance_values identifier id'>instance_values</span><span class='dot token'>.</span><span class='reject identifier id'>reject</span> <span class='lbrace token'>{</span> <span class='bitor op'>|</span><span class='k identifier id'>k</span><span class='comma token'>,</span><span class='v identifier id'>v</span><span class='bitor op'>|</span> <span class='k identifier id'>k</span><span class='dot token'>.</span><span class='to_sym identifier id'>to_sym</span> <span class='eq op'>==</span> <span class='symbol val'>:patternType</span> <span class='rbrace token'>}</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='lbrace token'>{</span> <span class='bitor op'>|</span><span class='k identifier id'>k</span><span class='comma token'>,</span><span class='v identifier id'>v</span><span class='bitor op'>|</span> <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='k identifier id'>k</span><span class='comma token'>,</span> <span class='v identifier id'>v</span><span class='dot token'>.</span><span class='instance_values identifier id'>instance_values</span><span class='rparen token'>)</span> <span class='rbrace token'>}</span> - <span class='rbrace token'>}</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/pattern_fill.rb', line 60</span> + +<span class='kw'>def</span> <span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id patternFill'>patternFill</span><span class='lparen'>(</span><span class='symbol'>:patternType</span> <span class='op'>=></span> <span class='kw'>self</span><span class='period'>.</span><span class='id patternType'>patternType</span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id instance_values'>instance_values</span><span class='period'>.</span><span class='id reject'>reject</span> <span class='lbrace'>{</span> <span class='op'>|</span><span class='id k'>k</span><span class='comma'>,</span><span class='id v'>v</span><span class='op'>|</span> <span class='id k'>k</span><span class='period'>.</span><span class='id to_sym'>to_sym</span> <span class='op'>==</span> <span class='symbol'>:patternType</span> <span class='rbrace'>}</span><span class='period'>.</span><span class='id each'>each</span> <span class='lbrace'>{</span> <span class='op'>|</span><span class='id k'>k</span><span class='comma'>,</span><span class='id v'>v</span><span class='op'>|</span> <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='id k'>k</span><span class='comma'>,</span> <span class='id v'>v</span><span class='period'>.</span><span class='id instance_values'>instance_values</span><span class='rparen'>)</span> <span class='rbrace'>}</span> + <span class='rbrace'>}</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -672,9 +651,9 @@ The document builder instance this objects xml will be added to. </div> <div id="footer"> - Generated on Wed Nov 23 22:20:56 2011 by + Generated on Sat Nov 26 13:16:39 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/Pic.html b/doc/Axlsx/Pic.html index 6b078a26..c18b3682 100644 --- a/doc/Axlsx/Pic.html +++ b/doc/Axlsx/Pic.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::Pic - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -94,10 +94,9 @@ <h2>Overview</h2><div class="docstring"> <div class="discussion"> - <p> -a Pic object represents an image in your worksheet Worksheet#add_image is -the recommended way to manage images in your sheets -</p> + +<p>a Pic object represents an image in your worksheet Worksheet#add_image is +the recommended way to manage images in your sheets</p> </div> @@ -120,9 +119,8 @@ the recommended way to manage images in your sheets <dt id="ALLOWED_EXTENSIONS-constant" class="">ALLOWED_EXTENSIONS = <div class="docstring"> <div class="discussion"> - <p> -allowed file extenstions -</p> + +<p>allowed file extenstions</p> </div> @@ -132,8 +130,7 @@ allowed file extenstions </div> </dt> - <dd><pre class="code"><span class='lbrack token'>[</span><span class='string val'>'gif'</span><span class='comma token'>,</span> <span class='string val'>'jpeg'</span><span class='comma token'>,</span> <span class='string val'>'png'</span><span class='comma token'>,</span> <span class='string val'>'jpg'</span><span class='rbrack token'>]</span> -</pre></dd> + <dd><pre class="code"><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>gif</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>jpeg</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>png</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>jpg</span><span class='tstring_end'>'</span></span><span class='rbracket'>]</span></pre></dd> </dl> @@ -161,9 +158,8 @@ allowed file extenstions - <span class="summary_desc"><div class='inline'><p> -The anchor for this image. -</p> + <span class="summary_desc"><div class='inline'> +<p>The anchor for this image.</p> </div></span> </li> @@ -188,9 +184,8 @@ The anchor for this image. - <span class="summary_desc"><div class='inline'><p> -A description of the picture. -</p> + <span class="summary_desc"><div class='inline'> +<p>A description of the picture.</p> </div></span> </li> @@ -199,14 +194,14 @@ A description of the picture. <li class="public "> <span class="summary_signature"> - <a href="#extname-instance_method" title="#extname (instance method)">- (String) <strong>extname</strong> </a> + <a href="#image_src-instance_method" title="#image_src (instance method)">- (String) <strong>image_src</strong> </a> </span> - <span class="note title readonly">readonly</span> + @@ -215,9 +210,9 @@ A description of the picture. - <span class="summary_desc"><div class='inline'><p> -returns the extension of image_src without the preceeding ’.’. -</p> + <span class="summary_desc"><div class='inline'> +<p>The path to the image you want to include Only local images are supported +at this time and only jpg support.</p> </div></span> </li> @@ -226,14 +221,14 @@ returns the extension of image_src without the preceeding ’.’. <li class="public "> <span class="summary_signature"> - <a href="#file_name-instance_method" title="#file_name (instance method)">- (String) <strong>file_name</strong> </a> + <a href="#name-instance_method" title="#name (instance method)">- (String) <strong>name</strong> </a> </span> - <span class="note title readonly">readonly</span> + @@ -242,108 +237,125 @@ returns the extension of image_src without the preceeding ’.’. - <span class="summary_desc"><div class='inline'><p> -The name of the image file, sans directory info. -</p> + <span class="summary_desc"><div class='inline'> +<p>The name to use for this picture.</p> </div></span> </li> - <li class="public "> + </ul> + + + + + + <h2> + Instance Method Summary + <small>(<a href="#" class="summary_toggle">collapse</a>)</small> + </h2> + + <ul class="summary"> + + <li class="public "> <span class="summary_signature"> - <a href="#height-instance_method" title="#height (instance method)">- (Object) <strong>height</strong> </a> + <a href="#extname-instance_method" title="#extname (instance method)">- (String) <strong>extname</strong> </a> </span> - - - - <span class="summary_desc"><div class='inline'><p> -providing access to update the anchor’s height attribute. -</p> + <span class="summary_desc"><div class='inline'> +<p>returns the extension of image_src without the preceeding '.'.</p> </div></span> </li> - - <li class="public "> + + <li class="public "> <span class="summary_signature"> - <a href="#image_src-instance_method" title="#image_src (instance method)">- (String) <strong>image_src</strong> </a> + <a href="#file_name-instance_method" title="#file_name (instance method)">- (String) <strong>file_name</strong> </a> </span> - - - - <span class="summary_desc"><div class='inline'><p> -The path to the image you want to include Only local images are supported -at this time and only jpg support. -</p> + <span class="summary_desc"><div class='inline'> +<p>The file name of image_src without any path information.</p> </div></span> </li> - - <li class="public "> + + <li class="public "> <span class="summary_signature"> - <a href="#index-instance_method" title="#index (instance method)">- (Index) <strong>index</strong> </a> + <a href="#height-instance_method" title="#height (instance method)">- (Object) <strong>height</strong> </a> </span> - <span class="note title readonly">readonly</span> - - - <span class="summary_desc"><div class='inline'><p> -The index of this image in the workbooks images collections. -</p> + <span class="summary_desc"><div class='inline'> +<p>providing access to update the anchor's height attribute.</p> </div></span> </li> - - <li class="public "> + + <li class="public "> <span class="summary_signature"> - <a href="#name-instance_method" title="#name (instance method)">- (String) <strong>name</strong> </a> + <a href="#height%3D-instance_method" title="#height= (instance method)">- (Object) <strong>height=</strong>(v) </a> </span> + + + + + + + <span class="summary_desc"><div class='inline'></div></span> + +</li> + + + <li class="public "> + <span class="summary_signature"> + + <a href="#index-instance_method" title="#index (instance method)">- (Index) <strong>index</strong> </a> + + </span> + @@ -351,26 +363,24 @@ The index of this image in the workbooks images collections. - <span class="summary_desc"><div class='inline'><p> -The name to use for this picture. -</p> + <span class="summary_desc"><div class='inline'> +<p>The index of this image in the workbooks images collections.</p> </div></span> </li> - - <li class="public "> + + <li class="public "> <span class="summary_signature"> - <a href="#pn-instance_method" title="#pn (instance method)">- (String) <strong>pn</strong> </a> + <a href="#initialize-instance_method" title="#initialize (instance method)">- (Pic) <strong>initialize</strong>(anchor, options = {}) {|_self| ... }</a> </span> + <span class="note title constructor">constructor</span> - <span class="note title readonly">readonly</span> - @@ -378,66 +388,71 @@ The name to use for this picture. - <span class="summary_desc"><div class='inline'><p> -The part name for this image used in serialization and relationship -building. -</p> + <span class="summary_desc"><div class='inline'> +<p>Creates a new Pic(ture) object.</p> </div></span> </li> - - <li class="public "> + + <li class="public "> <span class="summary_signature"> - <a href="#width-instance_method" title="#width (instance method)">- (Object) <strong>width</strong> </a> + <a href="#pn-instance_method" title="#pn (instance method)">- (String) <strong>pn</strong> </a> </span> - - - - <span class="summary_desc"><div class='inline'><p> -providing access to the anchor’s width attribute. -</p> + <span class="summary_desc"><div class='inline'> +<p>The part name for this image used in serialization and relationship +building.</p> </div></span> </li> + + <li class="public "> + <span class="summary_signature"> + + <a href="#start_at-instance_method" title="#start_at (instance method)">- (Marker) <strong>start_at</strong>(x, y) </a> - </ul> - - + + </span> + + + + + + - <h2> - Instance Method Summary - <small>(<a href="#" class="summary_toggle">collapse</a>)</small> - </h2> + <span class="summary_desc"><div class='inline'> +<p>This is a short cut method to set the start anchor position If you need +finer granularity in positioning use graphic_frame.anchor.from.colOff / +rowOff.</p> +</div></span> + +</li> - <ul class="summary"> <li class="public "> <span class="summary_signature"> - <a href="#initialize-instance_method" title="#initialize (instance method)">- (Pic) <strong>initialize</strong>(anchor, options = {}) {|_self| ... }</a> + <a href="#to_xml-instance_method" title="#to_xml (instance method)">- (String) <strong>to_xml</strong>(xml) </a> </span> - <span class="note title constructor">constructor</span> - @@ -445,9 +460,8 @@ providing access to the anchor’s width attribute. - <span class="summary_desc"><div class='inline'><p> -Creates a new Pic(ture) object. -</p> + <span class="summary_desc"><div class='inline'> +<p>Serializes the picture.</p> </div></span> </li> @@ -456,7 +470,7 @@ Creates a new Pic(ture) object. <li class="public "> <span class="summary_signature"> - <a href="#start_at-instance_method" title="#start_at (instance method)">- (Marker) <strong>start_at</strong>(x, y) </a> + <a href="#width-instance_method" title="#width (instance method)">- (Object) <strong>width</strong> </a> @@ -469,11 +483,8 @@ Creates a new Pic(ture) object. - <span class="summary_desc"><div class='inline'><p> -This is a short cut method to set the start anchor position If you need -finer granularity in positioning use graphic_frame.anchor.from.colOff / -rowOff. -</p> + <span class="summary_desc"><div class='inline'> +<p>providing access to the anchor's width attribute.</p> </div></span> </li> @@ -482,7 +493,7 @@ rowOff. <li class="public "> <span class="summary_signature"> - <a href="#to_xml-instance_method" title="#to_xml (instance method)">- (String) <strong>to_xml</strong>(xml) </a> + <a href="#width%3D-instance_method" title="#width= (instance method)">- (Object) <strong>width=</strong>(v) </a> @@ -495,10 +506,7 @@ rowOff. - <span class="summary_desc"><div class='inline'><p> -Serializes the picture. -</p> -</div></span> + <span class="summary_desc"><div class='inline'></div></span> </li> @@ -518,9 +526,8 @@ Serializes the picture. </p><div class="docstring"> <div class="discussion"> - <p> -Creates a new Pic(ture) object -</p> + +<p>Creates a new Pic(ture) object</p> </div> @@ -539,9 +546,8 @@ Creates a new Pic(ture) object — - <div class='inline'><p> -the anchor that holds this image -</p> + <div class='inline'> +<p>the anchor that holds this image</p> </div> </li> @@ -558,9 +564,8 @@ the anchor that holds this image — - <div class='inline'><p> -a customizable set of options -</p> + <div class='inline'> +<p>a customizable set of options</p> </div> </li> @@ -658,9 +663,8 @@ a customizable set of options — - <div class='inline'><p> -the object that the method was called on -</p> + <div class='inline'> +<p>the object that the method was called on</p> </div> </li> @@ -673,29 +677,28 @@ the object that the method was called on <pre class="lines"> -66 -67 -68 -69 -70 -71 -72 -73 -74</pre> +38 +39 +40 +41 +42 +43 +44 +45 +46</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/pic.rb', line 66</span> - -<span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span><span class='lparen token'>(</span><span class='anchor identifier id'>anchor</span><span class='comma token'>,</span> <span class='options identifier id'>options</span><span class='assign token'>=</span><span class='lbrace token'>{</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> - <span class='@anchor ivar id'>@anchor</span> <span class='assign token'>=</span> <span class='anchor identifier id'>anchor</span> - <span class='@anchor ivar id'>@anchor</span><span class='dot token'>.</span><span class='drawing identifier id'>drawing</span><span class='dot token'>.</span><span class='worksheet identifier id'>worksheet</span><span class='dot token'>.</span><span class='workbook identifier id'>workbook</span><span class='dot token'>.</span><span class='images identifier id'>images</span> <span class='lshft op'><<</span> <span class='self self kw'>self</span> - <span class='options identifier id'>options</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='o identifier id'>o</span><span class='bitor op'>|</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='dstring node'>"#{o[0]}="</span><span class='comma token'>,</span> <span class='o identifier id'>o</span><span class='lbrack token'>[</span><span class='integer val'>1</span><span class='rbrack token'>]</span><span class='rparen token'>)</span> <span class='if if_mod kw'>if</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='respond_to? fid id'>respond_to?</span> <span class='dstring node'>"#{o[0]}="</span> - <span class='end end kw'>end</span> - <span class='start_at identifier id'>start_at</span> <span class='mult op'>*</span><span class='options identifier id'>options</span><span class='lbrack token'>[</span><span class='symbol val'>:start_at</span><span class='rbrack token'>]</span> <span class='if if_mod kw'>if</span> <span class='options identifier id'>options</span><span class='lbrack token'>[</span><span class='symbol val'>:start_at</span><span class='rbrack token'>]</span> - <span class='yield yield kw'>yield</span> <span class='self self kw'>self</span> <span class='if if_mod kw'>if</span> <span class='block_given? fid id'>block_given?</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/pic.rb', line 38</span> + +<span class='kw'>def</span> <span class='id initialize'>initialize</span><span class='lparen'>(</span><span class='id anchor'>anchor</span><span class='comma'>,</span> <span class='id options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span> + <span class='ivar'>@anchor</span> <span class='op'>=</span> <span class='id anchor'>anchor</span> + <span class='ivar'>@anchor</span><span class='period'>.</span><span class='id drawing'>drawing</span><span class='period'>.</span><span class='id worksheet'>worksheet</span><span class='period'>.</span><span class='id workbook'>workbook</span><span class='period'>.</span><span class='id images'>images</span> <span class='op'><<</span> <span class='kw'>self</span> + <span class='id options'>options</span><span class='period'>.</span><span class='id each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id o'>o</span><span class='op'>|</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span><span class='rbrace'>}</span><span class='tstring_content'>=</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>1</span><span class='rbracket'>]</span><span class='rparen'>)</span> <span class='kw'>if</span> <span class='kw'>self</span><span class='period'>.</span><span class='id respond_to?'>respond_to?</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span><span class='rbrace'>}</span><span class='tstring_content'>=</span><span class='tstring_end'>"</span></span> + <span class='kw'>end</span> + <span class='id start_at'>start_at</span><span class='lparen'>(</span><span class='op'>*</span><span class='id options'>options</span><span class='lbracket'>[</span><span class='symbol'>:start_at</span><span class='rbracket'>]</span><span class='rparen'>)</span> <span class='kw'>if</span> <span class='id options'>options</span><span class='lbracket'>[</span><span class='symbol'>:start_at</span><span class='rbracket'>]</span> + <span class='kw'>yield</span> <span class='kw'>self</span> <span class='kw'>if</span> <span class='id block_given?'>block_given?</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -718,9 +721,8 @@ the object that the method was called on </p><div class="docstring"> <div class="discussion"> - <p> -The anchor for this image -</p> + +<p>The anchor for this image</p> </div> @@ -747,17 +749,16 @@ The anchor for this image <pre class="lines"> -36 -37 -38</pre> +27 +28 +29</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/pic.rb', line 36</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/pic.rb', line 27</span> -<span class='def def kw'>def</span> <span class='anchor identifier id'>anchor</span> - <span class='@anchor ivar id'>@anchor</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id anchor'>anchor</span> + <span class='ivar'>@anchor</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -775,9 +776,8 @@ The anchor for this image </p><div class="docstring"> <div class="discussion"> - <p> -A description of the picture -</p> + +<p>A description of the picture</p> </div> @@ -804,37 +804,36 @@ A description of the picture <pre class="lines"> -27 -28 -29</pre> +18 +19 +20</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/pic.rb', line 27</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/pic.rb', line 18</span> -<span class='def def kw'>def</span> <span class='descr identifier id'>descr</span> - <span class='@descr ivar id'>@descr</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id descr'>descr</span> + <span class='ivar'>@descr</span> +<span class='kw'>end</span></pre> </td> </tr> </table> </div> - <span id=""></span> - <span id="extname-instance_method"></span> + <span id="image_src=-instance_method"></span> + <span id="image_src-instance_method"></span> <div class="method_details "> - <p class="signature " id="extname-instance_method"> + <p class="signature " id="image_src-instance_method"> - - (<tt>String</tt>) <strong>extname</strong> <span class="extras">(readonly)</span> + - (<tt>String</tt>) <strong>image_src</strong> </p><div class="docstring"> <div class="discussion"> - <p> -returns the extension of image_src without the preceeding ’.’ -</p> + +<p>The path to the image you want to include Only local images are supported +at this time and only jpg support</p> </div> @@ -861,37 +860,35 @@ returns the extension of image_src without the preceeding ’.’ <pre class="lines"> -40 -41 -42</pre> +23 +24 +25</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/pic.rb', line 40</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/pic.rb', line 23</span> -<span class='def def kw'>def</span> <span class='extname identifier id'>extname</span> - <span class='File constant id'>File</span><span class='dot token'>.</span><span class='extname identifier id'>extname</span><span class='lparen token'>(</span><span class='image_src identifier id'>image_src</span><span class='rparen token'>)</span><span class='dot token'>.</span><span class='delete identifier id'>delete</span><span class='lparen token'>(</span><span class='string val'>'.'</span><span class='rparen token'>)</span> <span class='unless unless_mod kw'>unless</span> <span class='image_src identifier id'>image_src</span><span class='dot token'>.</span><span class='nil? fid id'>nil?</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id image_src'>image_src</span> + <span class='ivar'>@image_src</span> +<span class='kw'>end</span></pre> </td> </tr> </table> </div> - <span id=""></span> - <span id="file_name-instance_method"></span> + <span id="name=-instance_method"></span> + <span id="name-instance_method"></span> <div class="method_details "> - <p class="signature " id="file_name-instance_method"> + <p class="signature " id="name-instance_method"> - - (<tt>String</tt>) <strong>file_name</strong> <span class="extras">(readonly)</span> + - (<tt>String</tt>) <strong>name</strong> </p><div class="docstring"> <div class="discussion"> - <p> -The name of the image file, sans directory info -</p> + +<p>The name to use for this picture</p> </div> @@ -918,51 +915,52 @@ The name of the image file, sans directory info <pre class="lines"> -44 -45 -46</pre> +13 +14 +15</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/pic.rb', line 44</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/pic.rb', line 13</span> -<span class='def def kw'>def</span> <span class='file_name identifier id'>file_name</span> - <span class='File constant id'>File</span><span class='dot token'>.</span><span class='basename identifier id'>basename</span><span class='lparen token'>(</span><span class='image_src identifier id'>image_src</span><span class='rparen token'>)</span> <span class='unless unless_mod kw'>unless</span> <span class='image_src identifier id'>image_src</span><span class='dot token'>.</span><span class='nil? fid id'>nil?</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id name'>name</span> + <span class='ivar'>@name</span> +<span class='kw'>end</span></pre> </td> </tr> </table> </div> - - <span id="height=-instance_method"></span> - <span id="height-instance_method"></span> - <div class="method_details "> - <p class="signature " id="height-instance_method"> + </div> + + + <div id="instance_method_details" class="method_details_list"> + <h2>Instance Method Details</h2> + + + <div class="method_details first"> + <p class="signature first" id="extname-instance_method"> - - (<tt>Object</tt>) <strong>height</strong> + - (<tt>String</tt>) <strong>extname</strong> </p><div class="docstring"> <div class="discussion"> - <p> -providing access to update the anchor’s height attribute -</p> + +<p>returns the extension of image_src without the preceeding '.'</p> </div> </div> <div class="tags"> - <h3>Parameters:</h3> -<ul class="param"> + +<h3>Returns:</h3> +<ul class="return"> <li> - <span class='name'>v</span> - - <span class='type'>(<tt>Integer</tt>)</span> + <span class='type'>(<tt>String</tt>)</span> @@ -970,52 +968,38 @@ providing access to update the anchor’s height attribute </ul> - - <h3>See Also:</h3> - <ul class="see"> - - <li>OneCellAnchor.width</li> - - </ul> - </div><table class="source_code"> <tr> <td> <pre class="lines"> -23 -24 -25</pre> +70 +71 +72</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/pic.rb', line 23</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/pic.rb', line 70</span> -<span class='def def kw'>def</span> <span class='height identifier id'>height</span> - <span class='@anchor ivar id'>@anchor</span><span class='dot token'>.</span><span class='height identifier id'>height</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id extname'>extname</span> + <span class='const'>File</span><span class='period'>.</span><span class='id extname'>extname</span><span class='lparen'>(</span><span class='id image_src'>image_src</span><span class='rparen'>)</span><span class='period'>.</span><span class='id delete'>delete</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>.</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> <span class='kw'>unless</span> <span class='id image_src'>image_src</span><span class='period'>.</span><span class='id nil?'>nil?</span> +<span class='kw'>end</span></pre> </td> </tr> </table> </div> - - <span id="image_src=-instance_method"></span> - <span id="image_src-instance_method"></span> <div class="method_details "> - <p class="signature " id="image_src-instance_method"> + <p class="signature " id="file_name-instance_method"> - - (<tt>String</tt>) <strong>image_src</strong> + - (<tt>String</tt>) <strong>file_name</strong> </p><div class="docstring"> <div class="discussion"> - <p> -The path to the image you want to include Only local images are supported -at this time and only jpg support -</p> + +<p>The file name of image_src without any path information</p> </div> @@ -1042,50 +1026,46 @@ at this time and only jpg support <pre class="lines"> -32 -33 -34</pre> +64 +65 +66</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/pic.rb', line 32</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/pic.rb', line 64</span> -<span class='def def kw'>def</span> <span class='image_src identifier id'>image_src</span> - <span class='@image_src ivar id'>@image_src</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id file_name'>file_name</span> + <span class='const'>File</span><span class='period'>.</span><span class='id basename'>basename</span><span class='lparen'>(</span><span class='id image_src'>image_src</span><span class='rparen'>)</span> <span class='kw'>unless</span> <span class='id image_src'>image_src</span><span class='period'>.</span><span class='id nil?'>nil?</span> +<span class='kw'>end</span></pre> </td> </tr> </table> </div> - - <span id=""></span> - <span id="index-instance_method"></span> <div class="method_details "> - <p class="signature " id="index-instance_method"> + <p class="signature " id="height-instance_method"> - - (<tt>Index</tt>) <strong>index</strong> <span class="extras">(readonly)</span> + - (<tt>Object</tt>) <strong>height</strong> </p><div class="docstring"> <div class="discussion"> - <p> -The index of this image in the workbooks images collections -</p> + +<p>providing access to update the anchor's height attribute</p> </div> </div> <div class="tags"> - -<h3>Returns:</h3> -<ul class="return"> + <h3>Parameters:</h3> +<ul class="param"> <li> + <span class='name'>v</span> - <span class='type'>(<tt>Index</tt>)</span> + + <span class='type'>(<tt>Integer</tt>)</span> @@ -1093,62 +1073,57 @@ The index of this image in the workbooks images collections </ul> + + <h3>See Also:</h3> + <ul class="see"> + + <li>OneCellAnchor.width</li> + + </ul> + </div><table class="source_code"> <tr> <td> <pre class="lines"> -52 -53 -54</pre> +101 +102 +103</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/pic.rb', line 52</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/pic.rb', line 101</span> -<span class='def def kw'>def</span> <span class='index identifier id'>index</span> - <span class='@anchor ivar id'>@anchor</span><span class='dot token'>.</span><span class='drawing identifier id'>drawing</span><span class='dot token'>.</span><span class='worksheet identifier id'>worksheet</span><span class='dot token'>.</span><span class='workbook identifier id'>workbook</span><span class='dot token'>.</span><span class='images identifier id'>images</span><span class='dot token'>.</span><span class='index identifier id'>index</span><span class='lparen token'>(</span><span class='self self kw'>self</span><span class='rparen token'>)</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id height'>height</span> + <span class='ivar'>@anchor</span><span class='period'>.</span><span class='id height'>height</span> +<span class='kw'>end</span></pre> </td> </tr> </table> </div> - - <span id="name=-instance_method"></span> - <span id="name-instance_method"></span> <div class="method_details "> - <p class="signature " id="name-instance_method"> + <p class="signature " id="height=-instance_method"> - - (<tt>String</tt>) <strong>name</strong> + - (<tt>Object</tt>) <strong>height=</strong>(v) </p><div class="docstring"> <div class="discussion"> - <p> -The name to use for this picture -</p> - + </div> </div> <div class="tags"> -<h3>Returns:</h3> -<ul class="return"> - - <li> - - - <span class='type'>(<tt>String</tt>)</span> - - - - </li> - -</ul> + + <h3>See Also:</h3> + <ul class="see"> + + <li>height</li> + + </ul> </div><table class="source_code"> <tr> @@ -1156,38 +1131,32 @@ The name to use for this picture <pre class="lines"> -13 -14 -15</pre> +106 +107 +108</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/pic.rb', line 13</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/pic.rb', line 106</span> -<span class='def def kw'>def</span> <span class='name identifier id'>name</span> - <span class='@name ivar id'>@name</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id height='>height=</span><span class='lparen'>(</span><span class='id v'>v</span><span class='rparen'>)</span> + <span class='ivar'>@anchor</span><span class='period'>.</span><span class='id height'>height</span> <span class='op'>=</span> <span class='id v'>v</span> +<span class='kw'>end</span></pre> </td> </tr> </table> </div> - - <span id=""></span> - <span id="pn-instance_method"></span> <div class="method_details "> - <p class="signature " id="pn-instance_method"> + <p class="signature " id="index-instance_method"> - - (<tt>String</tt>) <strong>pn</strong> <span class="extras">(readonly)</span> + - (<tt>Index</tt>) <strong>index</strong> </p><div class="docstring"> <div class="discussion"> - <p> -The part name for this image used in serialization and relationship -building -</p> + +<p>The index of this image in the workbooks images collections</p> </div> @@ -1200,7 +1169,7 @@ building <li> - <span class='type'>(<tt>String</tt>)</span> + <span class='type'>(<tt>Index</tt>)</span> @@ -1214,51 +1183,46 @@ building <pre class="lines"> -48 -49 -50</pre> +76 +77 +78</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/pic.rb', line 48</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/pic.rb', line 76</span> -<span class='def def kw'>def</span> <span class='pn identifier id'>pn</span> - <span class='dstring node'>"#{IMAGE_PN % [(index+1), extname]}"</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id index'>index</span> + <span class='ivar'>@anchor</span><span class='period'>.</span><span class='id drawing'>drawing</span><span class='period'>.</span><span class='id worksheet'>worksheet</span><span class='period'>.</span><span class='id workbook'>workbook</span><span class='period'>.</span><span class='id images'>images</span><span class='period'>.</span><span class='id index'>index</span><span class='lparen'>(</span><span class='kw'>self</span><span class='rparen'>)</span> +<span class='kw'>end</span></pre> </td> </tr> </table> </div> - - <span id="width=-instance_method"></span> - <span id="width-instance_method"></span> <div class="method_details "> - <p class="signature " id="width-instance_method"> + <p class="signature " id="pn-instance_method"> - - (<tt>Object</tt>) <strong>width</strong> + - (<tt>String</tt>) <strong>pn</strong> </p><div class="docstring"> <div class="discussion"> - <p> -providing access to the anchor’s width attribute -</p> + +<p>The part name for this image used in serialization and relationship +building</p> </div> </div> <div class="tags"> - <h3>Parameters:</h3> -<ul class="param"> + +<h3>Returns:</h3> +<ul class="return"> <li> - <span class='name'>v</span> - - <span class='type'>(<tt>Integer</tt>)</span> + <span class='type'>(<tt>String</tt>)</span> @@ -1266,45 +1230,29 @@ providing access to the anchor’s width attribute </ul> - - <h3>See Also:</h3> - <ul class="see"> - - <li>OneCellAnchor.width</li> - - </ul> - </div><table class="source_code"> <tr> <td> <pre class="lines"> -18 -19 -20</pre> +82 +83 +84</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/pic.rb', line 18</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/pic.rb', line 82</span> -<span class='def def kw'>def</span> <span class='width identifier id'>width</span> - <span class='@anchor ivar id'>@anchor</span><span class='dot token'>.</span><span class='width identifier id'>width</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id pn'>pn</span> + <span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='const'>IMAGE_PN</span> <span class='op'>%</span> <span class='lbracket'>[</span><span class='lparen'>(</span><span class='id index'>index</span><span class='op'>+</span><span class='int'>1</span><span class='rparen'>)</span><span class='comma'>,</span> <span class='id extname'>extname</span><span class='rbracket'>]</span><span class='rbrace'>}</span><span class='tstring_end'>"</span></span> +<span class='kw'>end</span></pre> </td> </tr> </table> </div> - </div> - - - <div id="instance_method_details" class="method_details_list"> - <h2>Instance Method Details</h2> - - - <div class="method_details first"> - <p class="signature first" id="start_at-instance_method"> + <div class="method_details "> + <p class="signature " id="start_at-instance_method"> - (<tt><span class='object_link'><a href="Marker.html" title="Axlsx::Marker (class)">Marker</a></span></tt>) <strong>start_at</strong>(x, y) @@ -1312,11 +1260,10 @@ providing access to the anchor’s width attribute </p><div class="docstring"> <div class="discussion"> - <p> -This is a short cut method to set the start anchor position If you need + +<p>This is a short cut method to set the start anchor position If you need finer granularity in positioning use graphic_frame.anchor.from.colOff / -rowOff -</p> +rowOff</p> </div> @@ -1335,9 +1282,8 @@ rowOff — - <div class='inline'><p> -The column -</p> + <div class='inline'> +<p>The column</p> </div> </li> @@ -1352,9 +1298,8 @@ The column — - <div class='inline'><p> -The row -</p> + <div class='inline'> +<p>The row</p> </div> </li> @@ -1381,19 +1326,18 @@ The row <pre class="lines"> -124 -125 -126 -127</pre> +116 +117 +118 +119</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/pic.rb', line 124</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/pic.rb', line 116</span> -<span class='def def kw'>def</span> <span class='start_at identifier id'>start_at</span><span class='lparen token'>(</span><span class='x identifier id'>x</span><span class='comma token'>,</span> <span class='y identifier id'>y</span><span class='rparen token'>)</span> - <span class='@anchor ivar id'>@anchor</span><span class='dot token'>.</span><span class='from identifier id'>from</span><span class='dot token'>.</span><span class='col identifier id'>col</span> <span class='assign token'>=</span> <span class='x identifier id'>x</span> - <span class='@anchor ivar id'>@anchor</span><span class='dot token'>.</span><span class='from identifier id'>from</span><span class='dot token'>.</span><span class='row identifier id'>row</span> <span class='assign token'>=</span> <span class='y identifier id'>y</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id start_at'>start_at</span><span class='lparen'>(</span><span class='id x'>x</span><span class='comma'>,</span> <span class='id y'>y</span><span class='rparen'>)</span> + <span class='ivar'>@anchor</span><span class='period'>.</span><span class='id from'>from</span><span class='period'>.</span><span class='id col'>col</span> <span class='op'>=</span> <span class='id x'>x</span> + <span class='ivar'>@anchor</span><span class='period'>.</span><span class='id from'>from</span><span class='period'>.</span><span class='id row'>row</span> <span class='op'>=</span> <span class='id y'>y</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1408,9 +1352,8 @@ The row </p><div class="docstring"> <div class="discussion"> - <p> -Serializes the picture -</p> + +<p>Serializes the picture</p> </div> @@ -1429,9 +1372,8 @@ Serializes the picture — - <div class='inline'><p> -The document builder instance this objects xml will be added to. -</p> + <div class='inline'> +<p>The document builder instance this objects xml will be added to.</p> </div> </li> @@ -1458,6 +1400,14 @@ The document builder instance this objects xml will be added to. <pre class="lines"> +124 +125 +126 +127 +128 +129 +130 +131 132 133 134 @@ -1474,45 +1424,141 @@ The document builder instance this objects xml will be added to. 145 146 147 -148 -149 -150 -151 -152 -153 -154 -155 -156</pre> +148</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/pic.rb', line 132</span> - -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'xdr:pic'</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'xdr:nvPicPr'</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'xdr:cNvPr'</span><span class='comma token'>,</span> <span class='symbol val'>:id=</span><span class='gt op'>></span><span class='string val'>"2"</span><span class='comma token'>,</span> <span class='symbol val'>:name=</span><span class='gt op'>></span><span class='name identifier id'>name</span><span class='comma token'>,</span> <span class='symbol val'>:descr=</span><span class='gt op'>></span><span class='descr identifier id'>descr</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'xdr:cNvPicPr'</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'a:picLocks'</span><span class='comma token'>,</span> <span class='symbol val'>:noChangeAspect=</span><span class='gt op'>></span><span class='integer val'>1</span><span class='rparen token'>)</span> - <span class='rbrace token'>}</span> - <span class='rbrace token'>}</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'xdr:blipFill'</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'a:blip'</span><span class='comma token'>,</span> <span class='symbol val'>:'xmlns:r'</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='XML_NS_R constant id'>XML_NS_R</span><span class='comma token'>,</span> <span class='symbol val'>:'r:embed'</span><span class='assign token'>=</span><span class='gt op'>></span><span class='string val'>"rId1"</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'a:stretch'</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'a:fillRect'</span><span class='rparen token'>)</span> - <span class='rbrace token'>}</span> - <span class='rbrace token'>}</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'xdr:spPr'</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'a:xfrm'</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'a:off'</span><span class='comma token'>,</span> <span class='symbol val'>:x=</span><span class='gt op'>></span><span class='integer val'>0</span><span class='comma token'>,</span> <span class='symbol val'>:y=</span><span class='gt op'>></span><span class='integer val'>0</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'a:ext'</span><span class='comma token'>,</span> <span class='symbol val'>:cx=</span><span class='gt op'>></span><span class='integer val'>2336800</span><span class='comma token'>,</span> <span class='symbol val'>:cy=</span><span class='gt op'>></span><span class='integer val'>2161540</span><span class='rparen token'>)</span> - <span class='rbrace token'>}</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'a:prstGeom'</span><span class='comma token'>,</span> <span class='symbol val'>:prst=</span><span class='gt op'>></span><span class='symbol val'>:rect</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'a:avLst'</span><span class='rparen token'>)</span> - <span class='rbrace token'>}</span> - <span class='rbrace token'>}</span> - <span class='rbrace token'>}</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/pic.rb', line 124</span> + +<span class='kw'>def</span> <span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>xdr:pic</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>xdr:nvPicPr</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>xdr:cNvPr</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:id</span><span class='op'>=></span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>2</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='symbol'>:name</span><span class='op'>=></span><span class='id name'>name</span><span class='comma'>,</span> <span class='symbol'>:descr</span><span class='op'>=></span><span class='id descr'>descr</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>xdr:cNvPicPr</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>a:picLocks</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:noChangeAspect</span><span class='op'>=></span><span class='int'>1</span><span class='rparen'>)</span> + <span class='rbrace'>}</span> + <span class='rbrace'>}</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>xdr:blipFill</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>a:blip</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:xmlns:r</span><span class='tstring_end'>'</span></span> <span class='op'>=></span> <span class='const'>XML_NS_R</span><span class='comma'>,</span> <span class='symbol'>:r:embed</span><span class='tstring_end'>'</span></span><span class='op'>=></span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>rId1</span><span class='tstring_end'>"</span></span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>a:stretch</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>a:fillRect</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> + <span class='rbrace'>}</span> + <span class='rbrace'>}</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>xdr:spPr</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>a:xfrm</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>a:off</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:x</span><span class='op'>=></span><span class='int'>0</span><span class='comma'>,</span> <span class='symbol'>:y</span><span class='op'>=></span><span class='int'>0</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>a:ext</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:cx</span><span class='op'>=></span><span class='int'>2336800</span><span class='comma'>,</span> <span class='symbol'>:cy</span><span class='op'>=></span><span class='int'>2161540</span><span class='rparen'>)</span> + <span class='rbrace'>}</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>a:prstGeom</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:prst</span><span class='op'>=></span><span class='symbol'>:rect</span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>a:avLst</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> + <span class='rbrace'>}</span> + <span class='rbrace'>}</span> + <span class='rbrace'>}</span> +<span class='kw'>end</span></pre> + </td> + </tr> +</table> +</div> + + <div class="method_details "> + <p class="signature " id="width-instance_method"> + + - (<tt>Object</tt>) <strong>width</strong> + + + +</p><div class="docstring"> + <div class="discussion"> + +<p>providing access to the anchor's width attribute</p> + + + </div> +</div> +<div class="tags"> + <h3>Parameters:</h3> +<ul class="param"> + + <li> + + <span class='name'>v</span> + + + <span class='type'>(<tt>Integer</tt>)</span> + + + + </li> + +</ul> + + + <h3>See Also:</h3> + <ul class="see"> + + <li>OneCellAnchor.width</li> + + </ul> + +</div><table class="source_code"> + <tr> + <td> + <pre class="lines"> + + +89 +90 +91</pre> + </td> + <td> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/pic.rb', line 89</span> + +<span class='kw'>def</span> <span class='id width'>width</span> + <span class='ivar'>@anchor</span><span class='period'>.</span><span class='id width'>width</span> +<span class='kw'>end</span></pre> + </td> + </tr> +</table> +</div> + + <div class="method_details "> + <p class="signature " id="width=-instance_method"> + + - (<tt>Object</tt>) <strong>width=</strong>(v) + + + +</p><div class="docstring"> + <div class="discussion"> + + + </div> +</div> +<div class="tags"> + + + <h3>See Also:</h3> + <ul class="see"> + + <li>width</li> + + </ul> + +</div><table class="source_code"> + <tr> + <td> + <pre class="lines"> + + +94 +95 +96</pre> + </td> + <td> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/pic.rb', line 94</span> + +<span class='kw'>def</span> <span class='id width='>width=</span><span class='lparen'>(</span><span class='id v'>v</span><span class='rparen'>)</span> + <span class='ivar'>@anchor</span><span class='period'>.</span><span class='id width'>width</span> <span class='op'>=</span> <span class='id v'>v</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1523,9 +1569,9 @@ The document builder instance this objects xml will be added to. </div> <div id="footer"> - Generated on Wed Nov 23 22:21:04 2011 by + Generated on Sat Nov 26 13:16:36 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/Pie3DChart.html b/doc/Axlsx/Pie3DChart.html index b0b9ea0c..dd55e82e 100644 --- a/doc/Axlsx/Pie3DChart.html +++ b/doc/Axlsx/Pie3DChart.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::Pie3DChart - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -96,10 +96,9 @@ <h2>Overview</h2><div class="docstring"> <div class="discussion"> - <p> -The Pie3DChart is a three dimentional piechart (who would have guessed?) -that you can add to your worksheet. -</p> + +<p>The Pie3DChart is a three dimentional piechart (who would have guessed?) +that you can add to your worksheet.</p> </div> @@ -132,7 +131,7 @@ that you can add to your worksheet. <h2>Instance Attribute Summary</h2> <h3 class="inherited">Attributes inherited from <span class='object_link'><a href="Chart.html" title="Axlsx::Chart (class)">Chart</a></span></h3> - <p class="inherited"><span class='object_link'><a href="Chart.html#graphic_frame-instance_method" title="Axlsx::Chart#graphic_frame (method)">graphic_frame</a></span>, <span class='object_link'><a href="Chart.html#index-instance_method" title="Axlsx::Chart#index (method)">index</a></span>, <span class='object_link'><a href="Chart.html#pn-instance_method" title="Axlsx::Chart#pn (method)">pn</a></span>, <span class='object_link'><a href="Chart.html#series-instance_method" title="Axlsx::Chart#series (method)">series</a></span>, <span class='object_link'><a href="Chart.html#series_type-instance_method" title="Axlsx::Chart#series_type (method)">series_type</a></span>, <span class='object_link'><a href="Chart.html#show_legend-instance_method" title="Axlsx::Chart#show_legend (method)">show_legend</a></span>, <span class='object_link'><a href="Chart.html#style-instance_method" title="Axlsx::Chart#style (method)">style</a></span>, <span class='object_link'><a href="Chart.html#title-instance_method" title="Axlsx::Chart#title (method)">title</a></span>, <span class='object_link'><a href="Chart.html#view3D-instance_method" title="Axlsx::Chart#view3D (method)">view3D</a></span></p> + <p class="inherited"><span class='object_link'><a href="Chart.html#graphic_frame-instance_method" title="Axlsx::Chart#graphic_frame (method)">graphic_frame</a></span>, <span class='object_link'><a href="Chart.html#series-instance_method" title="Axlsx::Chart#series (method)">series</a></span>, <span class='object_link'><a href="Chart.html#series_type-instance_method" title="Axlsx::Chart#series_type (method)">series_type</a></span>, <span class='object_link'><a href="Chart.html#show_legend-instance_method" title="Axlsx::Chart#show_legend (method)">show_legend</a></span>, <span class='object_link'><a href="Chart.html#style-instance_method" title="Axlsx::Chart#style (method)">style</a></span>, <span class='object_link'><a href="Chart.html#title-instance_method" title="Axlsx::Chart#title (method)">title</a></span>, <span class='object_link'><a href="Chart.html#view3D-instance_method" title="Axlsx::Chart#view3D (method)">view3D</a></span></p> @@ -161,9 +160,8 @@ that you can add to your worksheet. - <span class="summary_desc"><div class='inline'><p> -Creates a new pie chart object. -</p> + <span class="summary_desc"><div class='inline'> +<p>Creates a new pie chart object.</p> </div></span> </li> @@ -185,9 +183,8 @@ Creates a new pie chart object. - <span class="summary_desc"><div class='inline'><p> -Serializes the pie chart. -</p> + <span class="summary_desc"><div class='inline'> +<p>Serializes the pie chart.</p> </div></span> </li> @@ -205,7 +202,7 @@ Serializes the pie chart. <h3 class="inherited">Methods inherited from <span class='object_link'><a href="Chart.html" title="Axlsx::Chart (class)">Chart</a></span></h3> - <p class="inherited"><span class='object_link'><a href="Chart.html#add_series-instance_method" title="Axlsx::Chart#add_series (method)">#add_series</a></span>, <span class='object_link'><a href="Chart.html#end_at-instance_method" title="Axlsx::Chart#end_at (method)">#end_at</a></span>, <span class='object_link'><a href="Chart.html#from-instance_method" title="Axlsx::Chart#from (method)">#from</a></span>, <span class='object_link'><a href="Chart.html#start_at-instance_method" title="Axlsx::Chart#start_at (method)">#start_at</a></span>, <span class='object_link'><a href="Chart.html#to-instance_method" title="Axlsx::Chart#to (method)">#to</a></span></p> + <p class="inherited"><span class='object_link'><a href="Chart.html#add_series-instance_method" title="Axlsx::Chart#add_series (method)">#add_series</a></span>, <span class='object_link'><a href="Chart.html#end_at-instance_method" title="Axlsx::Chart#end_at (method)">#end_at</a></span>, <span class='object_link'><a href="Chart.html#from-instance_method" title="Axlsx::Chart#from (method)">#from</a></span>, <span class='object_link'><a href="Chart.html#index-instance_method" title="Axlsx::Chart#index (method)">#index</a></span>, <span class='object_link'><a href="Chart.html#pn-instance_method" title="Axlsx::Chart#pn (method)">#pn</a></span>, <span class='object_link'><a href="Chart.html#start_at-instance_method" title="Axlsx::Chart#start_at (method)">#start_at</a></span>, <span class='object_link'><a href="Chart.html#to-instance_method" title="Axlsx::Chart#to (method)">#to</a></span></p> <div id="constructor_details" class="method_details_list"> <h2>Constructor Details</h2> @@ -218,9 +215,8 @@ Serializes the pie chart. </p><div class="docstring"> <div class="discussion"> - <p> -Creates a new pie chart object -</p> + +<p>Creates a new pie chart object</p> </div> @@ -239,9 +235,8 @@ Creates a new pie chart object — - <div class='inline'><p> -The workbook that owns this chart. -</p> + <div class='inline'> +<p>The workbook that owns this chart.</p> </div> </li> @@ -258,9 +253,8 @@ The workbook that owns this chart. — - <div class='inline'><p> -a customizable set of options -</p> + <div class='inline'> +<p>a customizable set of options</p> </div> </li> @@ -393,12 +387,11 @@ a customizable set of options <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/pie_3D_chart.rb', line 24</span> -<span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span><span class='lparen token'>(</span><span class='frame identifier id'>frame</span><span class='comma token'>,</span> <span class='options identifier id'>options</span><span class='assign token'>=</span><span class='lbrace token'>{</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> - <span class='super super kw'>super</span><span class='lparen token'>(</span><span class='frame identifier id'>frame</span><span class='comma token'>,</span> <span class='options identifier id'>options</span><span class='rparen token'>)</span> - <span class='@series_type ivar id'>@series_type</span> <span class='assign token'>=</span> <span class='PieSeries constant id'>PieSeries</span> - <span class='@view3D ivar id'>@view3D</span> <span class='assign token'>=</span> <span class='View3D constant id'>View3D</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='lbrace token'>{</span><span class='symbol val'>:rotX=</span><span class='gt op'>></span><span class='integer val'>30</span><span class='comma token'>,</span> <span class='symbol val'>:perspective=</span><span class='gt op'>></span><span class='integer val'>30</span><span class='rbrace token'>}</span><span class='dot token'>.</span><span class='merge identifier id'>merge</span><span class='lparen token'>(</span><span class='options identifier id'>options</span><span class='rparen token'>)</span><span class='rparen token'>)</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id initialize'>initialize</span><span class='lparen'>(</span><span class='id frame'>frame</span><span class='comma'>,</span> <span class='id options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span> + <span class='kw'>super</span><span class='lparen'>(</span><span class='id frame'>frame</span><span class='comma'>,</span> <span class='id options'>options</span><span class='rparen'>)</span> + <span class='ivar'>@series_type</span> <span class='op'>=</span> <span class='const'>PieSeries</span> + <span class='ivar'>@view3D</span> <span class='op'>=</span> <span class='const'>View3D</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='lbrace'>{</span><span class='symbol'>:rotX</span><span class='op'>=></span><span class='int'>30</span><span class='comma'>,</span> <span class='symbol'>:perspective</span><span class='op'>=></span><span class='int'>30</span><span class='rbrace'>}</span><span class='period'>.</span><span class='id merge'>merge</span><span class='lparen'>(</span><span class='id options'>options</span><span class='rparen'>)</span><span class='rparen'>)</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -420,9 +413,8 @@ a customizable set of options </p><div class="docstring"> <div class="discussion"> - <p> -Serializes the pie chart -</p> + +<p>Serializes the pie chart</p> </div> @@ -461,15 +453,14 @@ Serializes the pie chart <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/pie_3D_chart.rb', line 32</span> -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span> - <span class='super super kw'>super</span><span class='lparen token'>(</span><span class='rparen token'>)</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='xml identifier id'>xml</span><span class='bitor op'>|</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:pie3DChart'</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:varyColors'</span><span class='comma token'>,</span> <span class='symbol val'>:val=</span><span class='gt op'>></span><span class='integer val'>1</span><span class='rparen token'>)</span> - <span class='@series ivar id'>@series</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='lbrace token'>{</span> <span class='bitor op'>|</span><span class='ser identifier id'>ser</span><span class='bitor op'>|</span> <span class='ser identifier id'>ser</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> <span class='rbrace token'>}</span> - <span class='rbrace token'>}</span> - <span class='end end kw'>end</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id to_xml'>to_xml</span> + <span class='kw'>super</span><span class='lparen'>(</span><span class='rparen'>)</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id xml'>xml</span><span class='op'>|</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:pie3DChart</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:varyColors</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:val</span><span class='op'>=></span><span class='int'>1</span><span class='rparen'>)</span> + <span class='ivar'>@series</span><span class='period'>.</span><span class='id each'>each</span> <span class='lbrace'>{</span> <span class='op'>|</span><span class='id ser'>ser</span><span class='op'>|</span> <span class='id ser'>ser</span><span class='period'>.</span><span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> <span class='rbrace'>}</span> + <span class='rbrace'>}</span> + <span class='kw'>end</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -480,9 +471,9 @@ Serializes the pie chart </div> <div id="footer"> - Generated on Wed Nov 23 22:20:51 2011 by + Generated on Sat Nov 26 13:16:38 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/PieSeries.html b/doc/Axlsx/PieSeries.html index 93de2b0a..312c62b8 100644 --- a/doc/Axlsx/PieSeries.html +++ b/doc/Axlsx/PieSeries.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::PieSeries - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -99,16 +99,14 @@ <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -The recommended way to manage series is to use Chart#add_series -</p> + <div class='inline'> +<p>The recommended way to manage series is to use Chart#add_series</p> </div> </div> -<p> -A PieSeries defines the data and labels and explosion for pie charts -series. -</p> + +<p>A PieSeries defines the data and labels and explosion for pie charts +series.</p> </div> @@ -153,9 +151,8 @@ series. - <span class="summary_desc"><div class='inline'><p> -The data for this series. -</p> + <span class="summary_desc"><div class='inline'> +<p>The data for this series.</p> </div></span> </li> @@ -180,9 +177,8 @@ The data for this series. - <span class="summary_desc"><div class='inline'><p> -The explosion for this series. -</p> + <span class="summary_desc"><div class='inline'> +<p>The explosion for this series.</p> </div></span> </li> @@ -207,9 +203,8 @@ The explosion for this series. - <span class="summary_desc"><div class='inline'><p> -The labels for this series. -</p> + <span class="summary_desc"><div class='inline'> +<p>The labels for this series.</p> </div></span> </li> @@ -225,7 +220,7 @@ The labels for this series. <h3 class="inherited">Attributes inherited from <span class='object_link'><a href="Series.html" title="Axlsx::Series (class)">Series</a></span></h3> - <p class="inherited"><span class='object_link'><a href="Series.html#chart-instance_method" title="Axlsx::Series#chart (method)">chart</a></span>, <span class='object_link'><a href="Series.html#index-instance_method" title="Axlsx::Series#index (method)">index</a></span>, <span class='object_link'><a href="Series.html#order-instance_method" title="Axlsx::Series#order (method)">order</a></span>, <span class='object_link'><a href="Series.html#title-instance_method" title="Axlsx::Series#title (method)">title</a></span></p> + <p class="inherited"><span class='object_link'><a href="Series.html#chart-instance_method" title="Axlsx::Series#chart (method)">chart</a></span>, <span class='object_link'><a href="Series.html#title-instance_method" title="Axlsx::Series#title (method)">title</a></span></p> @@ -254,9 +249,8 @@ The labels for this series. - <span class="summary_desc"><div class='inline'><p> -Creates a new series. -</p> + <span class="summary_desc"><div class='inline'> +<p>Creates a new series.</p> </div></span> </li> @@ -278,9 +272,8 @@ Creates a new series. - <span class="summary_desc"><div class='inline'><p> -Serializes the series. -</p> + <span class="summary_desc"><div class='inline'> +<p>Serializes the series.</p> </div></span> </li> @@ -294,7 +287,12 @@ Serializes the series. - <div id="constructor_details" class="method_details_list"> + + + + <h3 class="inherited">Methods inherited from <span class='object_link'><a href="Series.html" title="Axlsx::Series (class)">Series</a></span></h3> + <p class="inherited"><span class='object_link'><a href="Series.html#index-instance_method" title="Axlsx::Series#index (method)">#index</a></span>, <span class='object_link'><a href="Series.html#order-instance_method" title="Axlsx::Series#order (method)">#order</a></span>, <span class='object_link'><a href="Series.html#order%3D-instance_method" title="Axlsx::Series#order= (method)">#order=</a></span></p> +<div id="constructor_details" class="method_details_list"> <h2>Constructor Details</h2> <div class="method_details first"> @@ -306,9 +304,8 @@ Serializes the series. </p><div class="docstring"> <div class="discussion"> - <p> -Creates a new series -</p> + +<p>Creates a new series</p> </div> @@ -340,9 +337,8 @@ Creates a new series — - <div class='inline'><p> -a customizable set of options -</p> + <div class='inline'> +<p>a customizable set of options</p> </div> </li> @@ -407,17 +403,18 @@ a customizable set of options 27 28 29 -30</pre> +30 +31</pre> </td> <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/pie_series.rb', line 26</span> -<span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span><span class='lparen token'>(</span><span class='chart identifier id'>chart</span><span class='comma token'>,</span> <span class='options identifier id'>options</span><span class='assign token'>=</span><span class='lbrace token'>{</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> - <span class='super super kw'>super</span><span class='lparen token'>(</span><span class='chart identifier id'>chart</span><span class='comma token'>,</span> <span class='options identifier id'>options</span><span class='rparen token'>)</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='labels identifier id'>labels</span> <span class='assign token'>=</span> <span class='CatAxisData constant id'>CatAxisData</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='options identifier id'>options</span><span class='lbrack token'>[</span><span class='symbol val'>:labels</span><span class='rbrack token'>]</span><span class='rparen token'>)</span> <span class='unless unless_mod kw'>unless</span> <span class='options identifier id'>options</span><span class='lbrack token'>[</span><span class='symbol val'>:labels</span><span class='rbrack token'>]</span><span class='dot token'>.</span><span class='nil? fid id'>nil?</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='data identifier id'>data</span> <span class='assign token'>=</span> <span class='ValAxisData constant id'>ValAxisData</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='options identifier id'>options</span><span class='lbrack token'>[</span><span class='symbol val'>:data</span><span class='rbrack token'>]</span><span class='rparen token'>)</span> <span class='unless unless_mod kw'>unless</span> <span class='options identifier id'>options</span><span class='lbrack token'>[</span><span class='symbol val'>:data</span><span class='rbrack token'>]</span><span class='dot token'>.</span><span class='nil? fid id'>nil?</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id initialize'>initialize</span><span class='lparen'>(</span><span class='id chart'>chart</span><span class='comma'>,</span> <span class='id options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span> + <span class='ivar'>@explosion</span> <span class='op'>=</span> <span class='kw'>nil</span> + <span class='kw'>super</span><span class='lparen'>(</span><span class='id chart'>chart</span><span class='comma'>,</span> <span class='id options'>options</span><span class='rparen'>)</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id labels'>labels</span> <span class='op'>=</span> <span class='const'>CatAxisData</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='id options'>options</span><span class='lbracket'>[</span><span class='symbol'>:labels</span><span class='rbracket'>]</span><span class='rparen'>)</span> <span class='kw'>unless</span> <span class='id options'>options</span><span class='lbracket'>[</span><span class='symbol'>:labels</span><span class='rbracket'>]</span><span class='period'>.</span><span class='id nil?'>nil?</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id data'>data</span> <span class='op'>=</span> <span class='const'>ValAxisData</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='id options'>options</span><span class='lbracket'>[</span><span class='symbol'>:data</span><span class='rbracket'>]</span><span class='rparen'>)</span> <span class='kw'>unless</span> <span class='id options'>options</span><span class='lbracket'>[</span><span class='symbol'>:data</span><span class='rbracket'>]</span><span class='period'>.</span><span class='id nil?'>nil?</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -440,9 +437,8 @@ a customizable set of options </p><div class="docstring"> <div class="discussion"> - <p> -The data for this series. -</p> + +<p>The data for this series.</p> </div> @@ -476,10 +472,9 @@ The data for this series. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/pie_series.rb', line 10</span> -<span class='def def kw'>def</span> <span class='data identifier id'>data</span> - <span class='@data ivar id'>@data</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id data'>data</span> + <span class='ivar'>@data</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -497,9 +492,8 @@ The data for this series. </p><div class="docstring"> <div class="discussion"> - <p> -The explosion for this series -</p> + +<p>The explosion for this series</p> </div> @@ -533,10 +527,9 @@ The explosion for this series <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/pie_series.rb', line 18</span> -<span class='def def kw'>def</span> <span class='explosion identifier id'>explosion</span> - <span class='@explosion ivar id'>@explosion</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id explosion'>explosion</span> + <span class='ivar'>@explosion</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -554,9 +547,8 @@ The explosion for this series </p><div class="docstring"> <div class="discussion"> - <p> -The labels for this series. -</p> + +<p>The labels for this series.</p> </div> @@ -590,10 +582,9 @@ The labels for this series. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/pie_series.rb', line 14</span> -<span class='def def kw'>def</span> <span class='labels identifier id'>labels</span> - <span class='@labels ivar id'>@labels</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id labels'>labels</span> + <span class='ivar'>@labels</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -615,9 +606,8 @@ The labels for this series. </p><div class="docstring"> <div class="discussion"> - <p> -Serializes the series -</p> + +<p>Serializes the series</p> </div> @@ -636,9 +626,8 @@ Serializes the series — - <div class='inline'><p> -The document builder instance this objects xml will be added to. -</p> + <div class='inline'> +<p>The document builder instance this objects xml will be added to.</p> </div> </li> @@ -665,25 +654,24 @@ The document builder instance this objects xml will be added to. <pre class="lines"> -37 -38 39 40 41 42 -43</pre> +43 +44 +45</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/pie_series.rb', line 37</span> - -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='super super kw'>super</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='xml identifier id'>xml</span><span class='bitor op'>|</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:explosion'</span><span class='comma token'>,</span> <span class='symbol val'>:val=</span><span class='gt op'>></span><span class='@explosion ivar id'>@explosion</span><span class='rparen token'>)</span> <span class='unless unless_mod kw'>unless</span> <span class='@explosion ivar id'>@explosion</span><span class='dot token'>.</span><span class='nil? fid id'>nil?</span> - <span class='@labels ivar id'>@labels</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> <span class='unless unless_mod kw'>unless</span> <span class='@labels ivar id'>@labels</span><span class='dot token'>.</span><span class='nil? fid id'>nil?</span> - <span class='@data ivar id'>@data</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> <span class='unless unless_mod kw'>unless</span> <span class='@data ivar id'>@data</span><span class='dot token'>.</span><span class='nil? fid id'>nil?</span> - <span class='end end kw'>end</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/pie_series.rb', line 39</span> + +<span class='kw'>def</span> <span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> + <span class='kw'>super</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id xml_inner'>xml_inner</span><span class='op'>|</span> + <span class='id xml_inner'>xml_inner</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:explosion</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:val</span><span class='op'>=></span><span class='ivar'>@explosion</span><span class='rparen'>)</span> <span class='kw'>unless</span> <span class='ivar'>@explosion</span><span class='period'>.</span><span class='id nil?'>nil?</span> + <span class='ivar'>@labels</span><span class='period'>.</span><span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml_inner'>xml_inner</span><span class='rparen'>)</span> <span class='kw'>unless</span> <span class='ivar'>@labels</span><span class='period'>.</span><span class='id nil?'>nil?</span> + <span class='ivar'>@data</span><span class='period'>.</span><span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml_inner'>xml_inner</span><span class='rparen'>)</span> <span class='kw'>unless</span> <span class='ivar'>@data</span><span class='period'>.</span><span class='id nil?'>nil?</span> + <span class='kw'>end</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -694,9 +682,9 @@ The document builder instance this objects xml will be added to. </div> <div id="footer"> - Generated on Wed Nov 23 22:20:57 2011 by + Generated on Sat Nov 26 13:16:38 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/RegexValidator.html b/doc/Axlsx/RegexValidator.html index 5335e4a7..398202ce 100644 --- a/doc/Axlsx/RegexValidator.html +++ b/doc/Axlsx/RegexValidator.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::RegexValidator - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -94,9 +94,8 @@ <h2>Overview</h2><div class="docstring"> <div class="discussion"> - <p> -Validates the value against the regular expression provided. -</p> + +<p>Validates the value against the regular expression provided.</p> </div> @@ -174,10 +173,9 @@ Validates the value against the regular expression provided. — - <div class='inline'><p> -The name of what is being validated. This is included in the output when -the value is invalid -</p> + <div class='inline'> +<p>The name of what is being validated. This is included in the output when +the value is invalid</p> </div> </li> @@ -192,9 +190,8 @@ the value is invalid — - <div class='inline'><p> -The regular expression to evaluate -</p> + <div class='inline'> +<p>The regular expression to evaluate</p> </div> </li> @@ -209,9 +206,8 @@ The regular expression to evaluate — - <div class='inline'><p> -The value to validate. -</p> + <div class='inline'> +<p>The value to validate.</p> </div> </li> @@ -245,10 +241,9 @@ The value to validate. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/util/validators.rb', line 21</span> -<span class='def def kw'>def</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='validate identifier id'>validate</span><span class='lparen token'>(</span><span class='name identifier id'>name</span><span class='comma token'>,</span> <span class='regex identifier id'>regex</span><span class='comma token'>,</span> <span class='v identifier id'>v</span><span class='rparen token'>)</span> - <span class='raise identifier id'>raise</span> <span class='ArgumentError constant id'>ArgumentError</span><span class='comma token'>,</span> <span class='lparen token'>(</span><span class='ERR_REGEX constant id'>ERR_REGEX</span> <span class='mod op'>%</span> <span class='lbrack token'>[</span><span class='v identifier id'>v</span><span class='dot token'>.</span><span class='inspect identifier id'>inspect</span><span class='comma token'>,</span> <span class='regex identifier id'>regex</span><span class='dot token'>.</span><span class='to_s identifier id'>to_s</span><span class='rbrack token'>]</span><span class='rparen token'>)</span> <span class='unless unless_mod kw'>unless</span> <span class='lparen token'>(</span><span class='v identifier id'>v</span><span class='dot token'>.</span><span class='respond_to? fid id'>respond_to?</span><span class='lparen token'>(</span><span class='symbol val'>:=~</span><span class='rparen token'>)</span> <span class='andop op'>&&</span> <span class='v identifier id'>v</span> <span class='match op'>=~</span> <span class='regex identifier id'>regex</span><span class='rparen token'>)</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id validate'>validate</span><span class='lparen'>(</span><span class='id name'>name</span><span class='comma'>,</span> <span class='id regex'>regex</span><span class='comma'>,</span> <span class='id v'>v</span><span class='rparen'>)</span> + <span class='id raise'>raise</span> <span class='const'>ArgumentError</span><span class='comma'>,</span> <span class='lparen'>(</span><span class='const'>ERR_REGEX</span> <span class='op'>%</span> <span class='lbracket'>[</span><span class='id v'>v</span><span class='period'>.</span><span class='id inspect'>inspect</span><span class='comma'>,</span> <span class='id regex'>regex</span><span class='period'>.</span><span class='id to_s'>to_s</span><span class='rbracket'>]</span><span class='rparen'>)</span> <span class='kw'>unless</span> <span class='lparen'>(</span><span class='id v'>v</span><span class='period'>.</span><span class='id respond_to?'>respond_to?</span><span class='lparen'>(</span><span class='symbol'>:=~</span><span class='rparen'>)</span> <span class='op'>&&</span> <span class='id v'>v</span> <span class='op'>=~</span> <span class='id regex'>regex</span><span class='rparen'>)</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -259,9 +254,9 @@ The value to validate. </div> <div id="footer"> - Generated on Wed Nov 23 22:20:52 2011 by + Generated on Sat Nov 26 13:16:37 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/Relationship.html b/doc/Axlsx/Relationship.html index 9aa93e52..e2fb7a6d 100644 --- a/doc/Axlsx/Relationship.html +++ b/doc/Axlsx/Relationship.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::Relationship - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -97,15 +97,13 @@ <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -Packages automatcially manage relationships. -</p> + <div class='inline'> +<p>Packages automatcially manage relationships.</p> </div> </div> -<p> -A relationship defines a reference between package parts. -</p> + +<p>A relationship defines a reference between package parts.</p> </div> @@ -137,9 +135,8 @@ A relationship defines a reference between package parts. - <span class="summary_desc"><div class='inline'><p> -The location of the relationship target. -</p> + <span class="summary_desc"><div class='inline'> +<p>The location of the relationship target.</p> </div></span> </li> @@ -164,9 +161,8 @@ The location of the relationship target. - <span class="summary_desc"><div class='inline'><p> -The type of relationship. -</p> + <span class="summary_desc"><div class='inline'> +<p>The type of relationship.</p> </div></span> </li> @@ -203,9 +199,8 @@ The type of relationship. - <span class="summary_desc"><div class='inline'><p> -A new instance of Relationship. -</p> + <span class="summary_desc"><div class='inline'> +<p>A new instance of Relationship.</p> </div></span> </li> @@ -227,9 +222,8 @@ A new instance of Relationship. - <span class="summary_desc"><div class='inline'><p> -Serializes the relationship. -</p> + <span class="summary_desc"><div class='inline'> +<p>Serializes the relationship.</p> </div></span> </li> @@ -250,9 +244,8 @@ Serializes the relationship. </p><div class="docstring"> <div class="discussion"> - <p> -A new instance of Relationship -</p> + +<p>A new instance of Relationship</p> </div> @@ -274,11 +267,10 @@ A new instance of Relationship <td> <pre class="code"><span class="info file"># File 'lib/axlsx/rels/relationship.rb', line 24</span> -<span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span><span class='lparen token'>(</span><span class='type identifier id'>type</span><span class='comma token'>,</span> <span class='target identifier id'>target</span><span class='rparen token'>)</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='Target constant id'>Target</span><span class='assign token'>=</span><span class='target identifier id'>target</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='Type constant id'>Type</span><span class='assign token'>=</span><span class='type identifier id'>type</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id initialize'>initialize</span><span class='lparen'>(</span><span class='id type'>type</span><span class='comma'>,</span> <span class='id target'>target</span><span class='rparen'>)</span> + <span class='kw'>self</span><span class='period'>.</span><span class='const'>Target</span><span class='op'>=</span><span class='id target'>target</span> + <span class='kw'>self</span><span class='period'>.</span><span class='const'>Type</span><span class='op'>=</span><span class='id type'>type</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -301,9 +293,8 @@ A new instance of Relationship </p><div class="docstring"> <div class="discussion"> - <p> -The location of the relationship target -</p> + +<p>The location of the relationship target</p> </div> @@ -337,10 +328,9 @@ The location of the relationship target <td> <pre class="code"><span class="info file"># File 'lib/axlsx/rels/relationship.rb', line 8</span> -<span class='def def kw'>def</span> <span class='Target constant id'>Target</span> - <span class='@Target ivar id'>@Target</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='const'>Target</span> + <span class='ivar'>@Target</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -361,15 +351,13 @@ The location of the relationship target <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -Supported types are defined as constants in Axlsx: -</p> + <div class='inline'> +<p>Supported types are defined as constants in Axlsx:</p> </div> </div> -<p> -The type of relationship -</p> + +<p>The type of relationship</p> </div> @@ -428,10 +416,9 @@ The type of relationship <td> <pre class="code"><span class="info file"># File 'lib/axlsx/rels/relationship.rb', line 23</span> -<span class='def def kw'>def</span> <span class='Type constant id'>Type</span> - <span class='@Type ivar id'>@Type</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='const'>Type</span> + <span class='ivar'>@Type</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -453,9 +440,8 @@ The type of relationship </p><div class="docstring"> <div class="discussion"> - <p> -Serializes the relationship -</p> + +<p>Serializes the relationship</p> </div> @@ -474,9 +460,8 @@ Serializes the relationship — - <div class='inline'><p> -The document builder instance this objects xml will be added to. -</p> + <div class='inline'> +<p>The document builder instance this objects xml will be added to.</p> </div> </li> @@ -491,9 +476,8 @@ The document builder instance this objects xml will be added to. — - <div class='inline'><p> -the reference id of the object. -</p> + <div class='inline'> +<p>the reference id of the object.</p> </div> </li> @@ -520,21 +504,20 @@ the reference id of the object. <pre class="lines"> -36 -37 38 39 -40</pre> +40 +41 +42</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/rels/relationship.rb', line 36</span> - -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='comma token'>,</span> <span class='rId identifier id'>rId</span><span class='rparen token'>)</span> - <span class='h identifier id'>h</span> <span class='assign token'>=</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='instance_values identifier id'>instance_values</span> - <span class='h identifier id'>h</span><span class='lbrack token'>[</span><span class='symbol val'>:Id</span><span class='rbrack token'>]</span> <span class='assign token'>=</span> <span class='rId identifier id'>rId</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='Relationship constant id'>Relationship</span><span class='lparen token'>(</span><span class='h identifier id'>h</span><span class='rparen token'>)</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/rels/relationship.rb', line 38</span> + +<span class='kw'>def</span> <span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='comma'>,</span> <span class='id rId'>rId</span><span class='rparen'>)</span> + <span class='id h'>h</span> <span class='op'>=</span> <span class='kw'>self</span><span class='period'>.</span><span class='id instance_values'>instance_values</span> + <span class='id h'>h</span><span class='lbracket'>[</span><span class='symbol'>:Id</span><span class='rbracket'>]</span> <span class='op'>=</span> <span class='id rId'>rId</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='const'>Relationship</span><span class='lparen'>(</span><span class='id h'>h</span><span class='rparen'>)</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -545,9 +528,9 @@ the reference id of the object. </div> <div id="footer"> - Generated on Wed Nov 23 22:21:04 2011 by + Generated on Sat Nov 26 13:16:38 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/Relationships.html b/doc/Axlsx/Relationships.html index f82180e0..b68eff83 100644 --- a/doc/Axlsx/Relationships.html +++ b/doc/Axlsx/Relationships.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::Relationships - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -99,16 +99,14 @@ <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -The package automatically manages releationships. -</p> + <div class='inline'> +<p>The package automatically manages releationships.</p> </div> </div> -<p> -Relationships are a collection of Relations that define how package parts -are related. -</p> + +<p>Relationships are a collection of Relations that define how package parts +are related.</p> </div> @@ -159,9 +157,8 @@ are related. - <span class="summary_desc"><div class='inline'><p> -Creates a new Relationships collection based on SimpleTypedList. -</p> + <span class="summary_desc"><div class='inline'> +<p>Creates a new Relationships collection based on SimpleTypedList.</p> </div></span> </li> @@ -183,9 +180,8 @@ Creates a new Relationships collection based on SimpleTypedList. - <span class="summary_desc"><div class='inline'><p> -Serializes the relationships document. -</p> + <span class="summary_desc"><div class='inline'> +<p>Serializes the relationships document.</p> </div></span> </li> @@ -199,12 +195,7 @@ Serializes the relationships document. - - - - <h3 class="inherited">Methods inherited from <span class='object_link'><a href="SimpleTypedList.html" title="Axlsx::SimpleTypedList (class)">SimpleTypedList</a></span></h3> - <p class="inherited"><span class='object_link'><a href="SimpleTypedList.html#%3C%3C-instance_method" title="Axlsx::SimpleTypedList#<< (method)">#<<</a></span>, <span class='object_link'><a href="SimpleTypedList.html#%3D%3D-instance_method" title="Axlsx::SimpleTypedList#== (method)">#==</a></span>, <span class='object_link'><a href="SimpleTypedList.html#%5B%5D%3D-instance_method" title="Axlsx::SimpleTypedList#[]= (method)">#[]=</a></span>, <span class='object_link'><a href="SimpleTypedList.html#delete-instance_method" title="Axlsx::SimpleTypedList#delete (method)">#delete</a></span>, <span class='object_link'><a href="SimpleTypedList.html#delete_at-instance_method" title="Axlsx::SimpleTypedList#delete_at (method)">#delete_at</a></span>, <span class='object_link'><a href="SimpleTypedList.html#lock-instance_method" title="Axlsx::SimpleTypedList#lock (method)">#lock</a></span>, <span class='object_link'><a href="SimpleTypedList.html#method_missing-instance_method" title="Axlsx::SimpleTypedList#method_missing (method)">#method_missing</a></span>, <span class='object_link'><a href="SimpleTypedList.html#protected%3F-instance_method" title="Axlsx::SimpleTypedList#protected? (method)">#protected?</a></span>, <span class='object_link'><a href="SimpleTypedList.html#push-instance_method" title="Axlsx::SimpleTypedList#push (method)">#push</a></span>, <span class='object_link'><a href="SimpleTypedList.html#unlock-instance_method" title="Axlsx::SimpleTypedList#unlock (method)">#unlock</a></span></p> -<div id="constructor_details" class="method_details_list"> + <div id="constructor_details" class="method_details_list"> <h2>Constructor Details</h2> <div class="method_details first"> @@ -216,9 +207,8 @@ Serializes the relationships document. </p><div class="docstring"> <div class="discussion"> - <p> -Creates a new Relationships collection based on SimpleTypedList -</p> + +<p>Creates a new Relationships collection based on SimpleTypedList</p> </div> @@ -239,10 +229,9 @@ Creates a new Relationships collection based on SimpleTypedList <td> <pre class="code"><span class="info file"># File 'lib/axlsx/rels/relationships.rb', line 9</span> -<span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span> - <span class='super super kw'>super</span> <span class='Relationship constant id'>Relationship</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id initialize'>initialize</span> + <span class='kw'>super</span> <span class='const'>Relationship</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -274,9 +263,8 @@ Creates a new Relationships collection based on SimpleTypedList </p><div class="docstring"> <div class="discussion"> - <p> -Serializes the relationships document. -</p> + +<p>Serializes the relationships document.</p> </div> @@ -315,15 +303,14 @@ Serializes the relationships document. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/rels/relationships.rb', line 15</span> -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='rparen token'>)</span> - <span class='builder identifier id'>builder</span> <span class='assign token'>=</span> <span class='Nokogiri constant id'>Nokogiri</span><span class='colon2 op'>::</span><span class='XML constant id'>XML</span><span class='colon2 op'>::</span><span class='Builder constant id'>Builder</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='symbol val'>:encoding</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='ENCODING constant id'>ENCODING</span><span class='rparen token'>)</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='xml identifier id'>xml</span><span class='bitor op'>|</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='Relationships constant id'>Relationships</span><span class='lparen token'>(</span><span class='symbol val'>:xmlns</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='RELS_R constant id'>RELS_R</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='each_with_index identifier id'>each_with_index</span> <span class='lbrace token'>{</span> <span class='bitor op'>|</span><span class='rel identifier id'>rel</span><span class='comma token'>,</span> <span class='index identifier id'>index</span><span class='bitor op'>|</span> <span class='rel identifier id'>rel</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='comma token'>,</span> <span class='dstring node'>"rId#{index+1}"</span><span class='rparen token'>)</span> <span class='rbrace token'>}</span> - <span class='rbrace token'>}</span> - <span class='end end kw'>end</span> - <span class='builder identifier id'>builder</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='rparen'>)</span> + <span class='id builder'>builder</span> <span class='op'>=</span> <span class='const'>Nokogiri</span><span class='op'>::</span><span class='const'>XML</span><span class='op'>::</span><span class='const'>Builder</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='symbol'>:encoding</span> <span class='op'>=></span> <span class='const'>ENCODING</span><span class='rparen'>)</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id xml'>xml</span><span class='op'>|</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='const'>Relationships</span><span class='lparen'>(</span><span class='symbol'>:xmlns</span> <span class='op'>=></span> <span class='const'>Axlsx</span><span class='op'>::</span><span class='const'>RELS_R</span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='id each_with_index'>each_with_index</span> <span class='lbrace'>{</span> <span class='op'>|</span><span class='id rel'>rel</span><span class='comma'>,</span> <span class='id index'>index</span><span class='op'>|</span> <span class='id rel'>rel</span><span class='period'>.</span><span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>rId</span><span class='embexpr_beg'>#{</span><span class='id index'>index</span><span class='op'>+</span><span class='int'>1</span><span class='rbrace'>}</span><span class='tstring_end'>"</span></span><span class='rparen'>)</span> <span class='rbrace'>}</span> + <span class='rbrace'>}</span> + <span class='kw'>end</span> + <span class='id builder'>builder</span><span class='period'>.</span><span class='id to_xml'>to_xml</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -334,9 +321,9 @@ Serializes the relationships document. </div> <div id="footer"> - Generated on Wed Nov 23 22:20:57 2011 by + Generated on Sat Nov 26 13:16:38 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/RestrictionValidator.html b/doc/Axlsx/RestrictionValidator.html index 928537b7..32f5900d 100644 --- a/doc/Axlsx/RestrictionValidator.html +++ b/doc/Axlsx/RestrictionValidator.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::RestrictionValidator - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -94,9 +94,8 @@ <h2>Overview</h2><div class="docstring"> <div class="discussion"> - <p> -Validate a value against a specific list of allowed values. -</p> + +<p>Validate a value against a specific list of allowed values.</p> </div> @@ -133,9 +132,8 @@ Validate a value against a specific list of allowed values. - <span class="summary_desc"><div class='inline'><p> -Perform validation. -</p> + <span class="summary_desc"><div class='inline'> +<p>Perform validation.</p> </div></span> </li> @@ -159,9 +157,8 @@ Perform validation. </p><div class="docstring"> <div class="discussion"> - <p> -Perform validation -</p> + +<p>Perform validation</p> </div> @@ -180,9 +177,8 @@ Perform validation — - <div class='inline'><p> -The name of what is being validatied. This is included in the error message -</p> + <div class='inline'> +<p>The name of what is being validatied. This is included in the error message</p> </div> </li> @@ -197,9 +193,8 @@ The name of what is being validatied. This is included in the error message — - <div class='inline'><p> -The list of choices to validate against -</p> + <div class='inline'> +<p>The list of choices to validate against</p> </div> </li> @@ -214,9 +209,8 @@ The list of choices to validate against — - <div class='inline'><p> -The value to be validated -</p> + <div class='inline'> +<p>The value to be validated</p> </div> </li> @@ -234,9 +228,8 @@ The value to be validated — - <div class='inline'><p> -true if validation succeeds. -</p> + <div class='inline'> +<p>true if validation succeeds.</p> </div> </li> @@ -253,9 +246,8 @@ true if validation succeeds. — - <div class='inline'><p> -Raised if the value provided is not in the list of choices. -</p> + <div class='inline'> +<p>Raised if the value provided is not in the list of choices.</p> </div> </li> @@ -276,11 +268,10 @@ Raised if the value provided is not in the list of choices. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/util/validators.rb', line 10</span> -<span class='def def kw'>def</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='validate identifier id'>validate</span><span class='lparen token'>(</span><span class='name identifier id'>name</span><span class='comma token'>,</span> <span class='choices identifier id'>choices</span><span class='comma token'>,</span> <span class='v identifier id'>v</span><span class='rparen token'>)</span> - <span class='raise identifier id'>raise</span> <span class='ArgumentError constant id'>ArgumentError</span><span class='comma token'>,</span> <span class='lparen token'>(</span><span class='ERR_RESTRICTION constant id'>ERR_RESTRICTION</span> <span class='mod op'>%</span> <span class='lbrack token'>[</span><span class='v identifier id'>v</span><span class='dot token'>.</span><span class='to_s identifier id'>to_s</span><span class='comma token'>,</span> <span class='name identifier id'>name</span><span class='comma token'>,</span> <span class='choices identifier id'>choices</span><span class='dot token'>.</span><span class='inspect identifier id'>inspect</span><span class='rbrack token'>]</span><span class='rparen token'>)</span> <span class='unless unless_mod kw'>unless</span> <span class='choices identifier id'>choices</span><span class='dot token'>.</span><span class='include? fid id'>include?</span><span class='lparen token'>(</span><span class='v identifier id'>v</span><span class='rparen token'>)</span> - <span class='true true kw'>true</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id validate'>validate</span><span class='lparen'>(</span><span class='id name'>name</span><span class='comma'>,</span> <span class='id choices'>choices</span><span class='comma'>,</span> <span class='id v'>v</span><span class='rparen'>)</span> + <span class='id raise'>raise</span> <span class='const'>ArgumentError</span><span class='comma'>,</span> <span class='lparen'>(</span><span class='const'>ERR_RESTRICTION</span> <span class='op'>%</span> <span class='lbracket'>[</span><span class='id v'>v</span><span class='period'>.</span><span class='id to_s'>to_s</span><span class='comma'>,</span> <span class='id name'>name</span><span class='comma'>,</span> <span class='id choices'>choices</span><span class='period'>.</span><span class='id inspect'>inspect</span><span class='rbracket'>]</span><span class='rparen'>)</span> <span class='kw'>unless</span> <span class='id choices'>choices</span><span class='period'>.</span><span class='id include?'>include?</span><span class='lparen'>(</span><span class='id v'>v</span><span class='rparen'>)</span> + <span class='kw'>true</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -291,9 +282,9 @@ Raised if the value provided is not in the list of choices. </div> <div id="footer"> - Generated on Wed Nov 23 22:20:54 2011 by + Generated on Sat Nov 26 13:16:37 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/Row.html b/doc/Axlsx/Row.html index 92ff0d15..84687f5e 100644 --- a/doc/Axlsx/Row.html +++ b/doc/Axlsx/Row.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::Row - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -97,15 +97,13 @@ <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -The recommended way to manage rows and cells is to use Worksheet#add_row -</p> + <div class='inline'> +<p>The recommended way to manage rows and cells is to use Worksheet#add_row</p> </div> </div> -<p> -A Row is a single row in a worksheet. -</p> + +<p>A Row is a single row in a worksheet.</p> </div> @@ -144,9 +142,8 @@ A Row is a single row in a worksheet. - <span class="summary_desc"><div class='inline'><p> -The cells this row holds. -</p> + <span class="summary_desc"><div class='inline'> +<p>The cells this row holds.</p> </div></span> </li> @@ -155,14 +152,14 @@ The cells this row holds. <li class="public "> <span class="summary_signature"> - <a href="#index-instance_method" title="#index (instance method)">- (Integer) <strong>index</strong> </a> + <a href="#worksheet-instance_method" title="#worksheet (instance method)">- (Worksheet) <strong>worksheet</strong> </a> </span> - <span class="note title readonly">readonly</span> + @@ -171,58 +168,54 @@ The cells this row holds. - <span class="summary_desc"><div class='inline'><p> -The index of this row in the worksheet. -</p> + <span class="summary_desc"><div class='inline'> +<p>The worksheet this row belongs to.</p> </div></span> </li> - <li class="public "> + </ul> + + + + + + <h2> + Instance Method Summary + <small>(<a href="#" class="summary_toggle">collapse</a>)</small> + </h2> + + <ul class="summary"> + + <li class="public "> <span class="summary_signature"> - <a href="#worksheet-instance_method" title="#worksheet (instance method)">- (Worksheet) <strong>worksheet</strong> </a> + <a href="#add_cell-instance_method" title="#add_cell (instance method)">- (Cell) <strong>add_cell</strong>(value = "", options = {}) </a> </span> - - - - <span class="summary_desc"><div class='inline'><p> -The worksheet this row belongs to. -</p> + <span class="summary_desc"><div class='inline'> +<p>Adds a singel sell to the row based on the data provided and updates the +worksheet's autofit data.</p> </div></span> </li> - - </ul> - - - - - - <h2> - Instance Method Summary - <small>(<a href="#" class="summary_toggle">collapse</a>)</small> - </h2> - - <ul class="summary"> <li class="public "> <span class="summary_signature"> - <a href="#add_cell-instance_method" title="#add_cell (instance method)">- (Cell) <strong>add_cell</strong>(value = "", options = {}) </a> + <a href="#index-instance_method" title="#index (instance method)">- (Integer) <strong>index</strong> </a> @@ -235,10 +228,8 @@ The worksheet this row belongs to. - <span class="summary_desc"><div class='inline'><p> -Adds a singel sell to the row based on the data provided and updates the -worksheet’s autofit data. -</p> + <span class="summary_desc"><div class='inline'> +<p>The index of this row in the worksheet.</p> </div></span> </li> @@ -262,9 +253,8 @@ worksheet’s autofit data. - <span class="summary_desc"><div class='inline'><p> -Creates a new row. -</p> + <span class="summary_desc"><div class='inline'> +<p>Creates a new row.</p> </div></span> </li> @@ -286,9 +276,8 @@ Creates a new row. - <span class="summary_desc"><div class='inline'><p> -Serializes the row. -</p> + <span class="summary_desc"><div class='inline'> +<p>Serializes the row.</p> </div></span> </li> @@ -309,19 +298,17 @@ Serializes the row. </p><div class="docstring"> <div class="discussion"> - <p> -Creates a new row. New Cell objects are created based on the values, types + +<p>Creates a new row. New Cell objects are created based on the values, types and style options. A new cell is created for each item in the values array. -style and types options are applied as follows: -</p> -<pre class="code"> - <span class='If constant id'>If</span> <span class='the identifier id'>the</span> <span class='types identifier id'>types</span> <span class='option identifier id'>option</span> <span class='is identifier id'>is</span> <span class='defined identifier id'>defined</span> <span class='and and kw'>and</span> <span class='is identifier id'>is</span> <span class='a identifier id'>a</span> <span class='symbol identifier id'>symbol</span> <span class='it identifier id'>it</span> <span class='is identifier id'>is</span> <span class='applied identifier id'>applied</span> <span class='to identifier id'>to</span> <span class='all identifier id'>all</span> <span class='the identifier id'>the</span> <span class='cells identifier id'>cells</span> <span class='created identifier id'>created</span><span class='dot token'>.</span> - <span class='If constant id'>If</span> <span class='the identifier id'>the</span> <span class='types identifier id'>types</span> <span class='option identifier id'>option</span> <span class='is identifier id'>is</span> <span class='an identifier id'>an</span> <span class='array identifier id'>array</span><span class='comma token'>,</span> <span class='cell identifier id'>cell</span> <span class='types identifier id'>types</span> <span class='are identifier id'>are</span> <span class='applied identifier id'>applied</span> <span class='by identifier id'>by</span> <span class='index identifier id'>index</span> <span class='for for kw'>for</span> <span class='each identifier id'>each</span> <span class='cell identifier id'>cell</span> - <span class='If constant id'>If</span> <span class='the identifier id'>the</span> <span class='types identifier id'>types</span> <span class='option identifier id'>option</span> <span class='is identifier id'>is</span> <span class='not not kw'>not</span> <span class='set identifier id'>set</span><span class='comma token'>,</span> <span class='the identifier id'>the</span> <span class='cell identifier id'>cell</span> <span class='will identifier id'>will</span> <span class='automatically identifier id'>automatically</span> <span class='determine identifier id'>determine</span> <span class='its identifier id'>its</span> <span class='type identifier id'>type</span><span class='dot token'>.</span> - <span class='If constant id'>If</span> <span class='the identifier id'>the</span> <span class='style identifier id'>style</span> <span class='option identifier id'>option</span> <span class='is identifier id'>is</span> <span class='defined identifier id'>defined</span> <span class='and and kw'>and</span> <span class='is identifier id'>is</span> <span class='an identifier id'>an</span> <span class='Integer constant id'>Integer</span><span class='comma token'>,</span> <span class='it identifier id'>it</span> <span class='is identifier id'>is</span> <span class='applied identifier id'>applied</span> <span class='to identifier id'>to</span> <span class='all identifier id'>all</span> <span class='cells identifier id'>cells</span> <span class='created identifier id'>created</span><span class='dot token'>.</span> - <span class='If constant id'>If</span> <span class='the identifier id'>the</span> <span class='style identifier id'>style</span> <span class='option identifier id'>option</span> <span class='is identifier id'>is</span> <span class='an identifier id'>an</span> <span class='array identifier id'>array</span><span class='comma token'>,</span> <span class='style identifier id'>style</span> <span class='is identifier id'>is</span> <span class='applied identifier id'>applied</span> <span class='by identifier id'>by</span> <span class='index identifier id'>index</span> <span class='for for kw'>for</span> <span class='each identifier id'>each</span> <span class='cell identifier id'>cell</span><span class='dot token'>.</span> - <span class='If constant id'>If</span> <span class='the identifier id'>the</span> <span class='style identifier id'>style</span> <span class='option identifier id'>option</span> <span class='is identifier id'>is</span> <span class='not not kw'>not</span> <span class='defined identifier id'>defined</span><span class='comma token'>,</span> <span class='the identifier id'>the</span> <span class='default identifier id'>default</span> <span class='style identifier id'>style</span> <span class='lparen token'>(</span><span class='integer val'>0</span><span class='rparen token'>)</span> <span class='is identifier id'>is</span> <span class='applied identifier id'>applied</span> <span class='to identifier id'>to</span> <span class='each identifier id'>each</span> <span class='cell identifier id'>cell</span><span class='dot token'>.</span> -</pre> +style and types options are applied as follows:</p> + +<pre class="code">If the types option is defined and is a symbol it is applied to all the cells created. +If the types option is an array, cell types are applied by index for each cell +If the types option is not set, the cell will automatically determine its type. +If the style option is defined and is an Integer, it is applied to all cells created. +If the style option is an array, style is applied by index for each cell. +If the style option is not defined, the default style (0) is applied to each cell.</pre> </div> @@ -353,9 +340,8 @@ style and types options are applied as follows: — - <div class='inline'><p> -a customizable set of options -</p> + <div class='inline'> +<p>a customizable set of options</p> </div> </li> @@ -418,23 +404,22 @@ a customizable set of options <pre class="lines"> +29 +30 +31 +32 33 -34 -35 -36 -37 -38</pre> +34</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/row.rb', line 33</span> - -<span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span><span class='lparen token'>(</span><span class='worksheet identifier id'>worksheet</span><span class='comma token'>,</span> <span class='values identifier id'>values</span><span class='assign token'>=</span><span class='lbrack token'>[</span><span class='rbrack token'>]</span><span class='comma token'>,</span> <span class='options identifier id'>options</span><span class='assign token'>=</span><span class='lbrace token'>{</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='worksheet identifier id'>worksheet</span> <span class='assign token'>=</span> <span class='worksheet identifier id'>worksheet</span> - <span class='@cells ivar id'>@cells</span> <span class='assign token'>=</span> <span class='SimpleTypedList constant id'>SimpleTypedList</span><span class='dot token'>.</span><span class='new identifier id'>new</span> <span class='Cell constant id'>Cell</span> - <span class='@worksheet ivar id'>@worksheet</span><span class='dot token'>.</span><span class='rows identifier id'>rows</span> <span class='lshft op'><<</span> <span class='self self kw'>self</span> - <span class='array_to_cells identifier id'>array_to_cells</span><span class='lparen token'>(</span><span class='values identifier id'>values</span><span class='comma token'>,</span> <span class='options identifier id'>options</span><span class='rparen token'>)</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/row.rb', line 29</span> + +<span class='kw'>def</span> <span class='id initialize'>initialize</span><span class='lparen'>(</span><span class='id worksheet'>worksheet</span><span class='comma'>,</span> <span class='id values'>values</span><span class='op'>=</span><span class='lbracket'>[</span><span class='rbracket'>]</span><span class='comma'>,</span> <span class='id options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id worksheet'>worksheet</span> <span class='op'>=</span> <span class='id worksheet'>worksheet</span> + <span class='ivar'>@cells</span> <span class='op'>=</span> <span class='const'>SimpleTypedList</span><span class='period'>.</span><span class='id new'>new</span> <span class='const'>Cell</span> + <span class='ivar'>@worksheet</span><span class='period'>.</span><span class='id rows'>rows</span> <span class='op'><<</span> <span class='kw'>self</span> + <span class='id array_to_cells'>array_to_cells</span><span class='lparen'>(</span><span class='id values'>values</span><span class='comma'>,</span> <span class='id options'>options</span><span class='rparen'>)</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -457,9 +442,8 @@ a customizable set of options </p><div class="docstring"> <div class="discussion"> - <p> -The cells this row holds -</p> + +<p>The cells this row holds</p> </div> @@ -493,30 +477,28 @@ The cells this row holds <td> <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/row.rb', line 13</span> -<span class='def def kw'>def</span> <span class='cells identifier id'>cells</span> - <span class='@cells ivar id'>@cells</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id cells'>cells</span> + <span class='ivar'>@cells</span> +<span class='kw'>end</span></pre> </td> </tr> </table> </div> - <span id=""></span> - <span id="index-instance_method"></span> + <span id="worksheet=-instance_method"></span> + <span id="worksheet-instance_method"></span> <div class="method_details "> - <p class="signature " id="index-instance_method"> + <p class="signature " id="worksheet-instance_method"> - - (<tt>Integer</tt>) <strong>index</strong> <span class="extras">(readonly)</span> + - (<tt><span class='object_link'><a href="Worksheet.html" title="Axlsx::Worksheet (class)">Worksheet</a></span></tt>) <strong>worksheet</strong> </p><div class="docstring"> <div class="discussion"> - <p> -The index of this row in the worksheet -</p> + +<p>The worksheet this row belongs to</p> </div> @@ -529,7 +511,7 @@ The index of this row in the worksheet <li> - <span class='type'>(<tt>Integer</tt>)</span> + <span class='type'>(<tt><span class='object_link'><a href="Worksheet.html" title="Axlsx::Worksheet (class)">Worksheet</a></span></tt>)</span> @@ -543,37 +525,40 @@ The index of this row in the worksheet <pre class="lines"> -17 -18 -19</pre> +9 +10 +11</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/row.rb', line 17</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/row.rb', line 9</span> -<span class='def def kw'>def</span> <span class='index identifier id'>index</span> - <span class='worksheet identifier id'>worksheet</span><span class='dot token'>.</span><span class='rows identifier id'>rows</span><span class='dot token'>.</span><span class='index identifier id'>index</span><span class='lparen token'>(</span><span class='self self kw'>self</span><span class='rparen token'>)</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id worksheet'>worksheet</span> + <span class='ivar'>@worksheet</span> +<span class='kw'>end</span></pre> </td> </tr> </table> </div> - - <span id="worksheet=-instance_method"></span> - <span id="worksheet-instance_method"></span> - <div class="method_details "> - <p class="signature " id="worksheet-instance_method"> + </div> + + + <div id="instance_method_details" class="method_details_list"> + <h2>Instance Method Details</h2> + + + <div class="method_details first"> + <p class="signature first" id="add_cell-instance_method"> - - (<tt><span class='object_link'><a href="Worksheet.html" title="Axlsx::Worksheet (class)">Worksheet</a></span></tt>) <strong>worksheet</strong> + - (<tt><span class='object_link'><a href="Cell.html" title="Axlsx::Cell (class)">Cell</a></span></tt>) <strong>add_cell</strong>(value = "", options = {}) </p><div class="docstring"> <div class="discussion"> - <p> -The worksheet this row belongs to -</p> + +<p>Adds a singel sell to the row based on the data provided and updates the +worksheet's autofit data.</p> </div> @@ -586,7 +571,7 @@ The worksheet this row belongs to <li> - <span class='type'>(<tt><span class='object_link'><a href="Worksheet.html" title="Axlsx::Worksheet (class)">Worksheet</a></span></tt>)</span> + <span class='type'>(<tt><span class='object_link'><a href="Cell.html" title="Axlsx::Cell (class)">Cell</a></span></tt>)</span> @@ -600,42 +585,36 @@ The worksheet this row belongs to <pre class="lines"> -9 -10 -11</pre> +51 +52 +53 +54 +55</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/row.rb', line 9</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/row.rb', line 51</span> -<span class='def def kw'>def</span> <span class='worksheet identifier id'>worksheet</span> - <span class='@worksheet ivar id'>@worksheet</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id add_cell'>add_cell</span><span class='lparen'>(</span><span class='id value'>value</span><span class='op'>=</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='id options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span> + <span class='id c'>c</span> <span class='op'>=</span> <span class='const'>Cell</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='kw'>self</span><span class='comma'>,</span> <span class='id value'>value</span><span class='comma'>,</span> <span class='id options'>options</span><span class='rparen'>)</span> + <span class='id update_auto_fit_data'>update_auto_fit_data</span> + <span class='id c'>c</span> +<span class='kw'>end</span></pre> </td> </tr> </table> </div> - </div> - - - <div id="instance_method_details" class="method_details_list"> - <h2>Instance Method Details</h2> - - - <div class="method_details first"> - <p class="signature first" id="add_cell-instance_method"> + <div class="method_details "> + <p class="signature " id="index-instance_method"> - - (<tt><span class='object_link'><a href="Cell.html" title="Axlsx::Cell (class)">Cell</a></span></tt>) <strong>add_cell</strong>(value = "", options = {}) + - (<tt>Integer</tt>) <strong>index</strong> </p><div class="docstring"> <div class="discussion"> - <p> -Adds a singel sell to the row based on the data provided and updates the -worksheet’s autofit data. -</p> + +<p>The index of this row in the worksheet</p> </div> @@ -648,7 +627,7 @@ worksheet’s autofit data. <li> - <span class='type'>(<tt><span class='object_link'><a href="Cell.html" title="Axlsx::Cell (class)">Cell</a></span></tt>)</span> + <span class='type'>(<tt>Integer</tt>)</span> @@ -662,21 +641,16 @@ worksheet’s autofit data. <pre class="lines"> -53 -54 -55 -56 -57</pre> +38 +39 +40</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/row.rb', line 53</span> - -<span class='def def kw'>def</span> <span class='add_cell identifier id'>add_cell</span><span class='lparen token'>(</span><span class='value identifier id'>value</span><span class='assign token'>=</span><span class='string val'>""</span><span class='comma token'>,</span> <span class='options identifier id'>options</span><span class='assign token'>=</span><span class='lbrace token'>{</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> - <span class='c identifier id'>c</span> <span class='assign token'>=</span> <span class='Cell constant id'>Cell</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='self self kw'>self</span><span class='comma token'>,</span> <span class='value identifier id'>value</span><span class='comma token'>,</span> <span class='options identifier id'>options</span><span class='rparen token'>)</span> - <span class='update_auto_fit_data identifier id'>update_auto_fit_data</span> - <span class='c identifier id'>c</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/row.rb', line 38</span> + +<span class='kw'>def</span> <span class='id index'>index</span> + <span class='id worksheet'>worksheet</span><span class='period'>.</span><span class='id rows'>rows</span><span class='period'>.</span><span class='id index'>index</span><span class='lparen'>(</span><span class='kw'>self</span><span class='rparen'>)</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -691,9 +665,8 @@ worksheet’s autofit data. </p><div class="docstring"> <div class="discussion"> - <p> -Serializes the row -</p> + +<p>Serializes the row</p> </div> @@ -712,9 +685,8 @@ Serializes the row — - <div class='inline'><p> -The document builder instance this objects xml will be added to. -</p> + <div class='inline'> +<p>The document builder instance this objects xml will be added to.</p> </div> </li> @@ -741,17 +713,16 @@ The document builder instance this objects xml will be added to. <pre class="lines"> -47 -48 -49</pre> +45 +46 +47</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/row.rb', line 47</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/row.rb', line 45</span> -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='row identifier id'>row</span><span class='lparen token'>(</span><span class='symbol val'>:r</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='index identifier id'>index</span><span class='plus op'>+</span><span class='integer val'>1</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> <span class='@cells ivar id'>@cells</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='lbrace token'>{</span> <span class='bitor op'>|</span><span class='cell identifier id'>cell</span><span class='bitor op'>|</span> <span class='cell identifier id'>cell</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> <span class='rbrace token'>}</span> <span class='rbrace token'>}</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id row'>row</span><span class='lparen'>(</span><span class='symbol'>:r</span> <span class='op'>=></span> <span class='id index'>index</span><span class='op'>+</span><span class='int'>1</span><span class='rparen'>)</span> <span class='lbrace'>{</span> <span class='ivar'>@cells</span><span class='period'>.</span><span class='id each'>each</span> <span class='lbrace'>{</span> <span class='op'>|</span><span class='id cell'>cell</span><span class='op'>|</span> <span class='id cell'>cell</span><span class='period'>.</span><span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> <span class='rbrace'>}</span> <span class='rbrace'>}</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -762,9 +733,9 @@ The document builder instance this objects xml will be added to. </div> <div id="footer"> - Generated on Wed Nov 23 22:20:49 2011 by + Generated on Sat Nov 26 13:16:39 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/Scaling.html b/doc/Axlsx/Scaling.html index 327e33fc..e8a6a8be 100644 --- a/doc/Axlsx/Scaling.html +++ b/doc/Axlsx/Scaling.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::Scaling - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -94,9 +94,8 @@ <h2>Overview</h2><div class="docstring"> <div class="discussion"> - <p> -The Scaling class defines axis scaling -</p> + +<p>The Scaling class defines axis scaling</p> </div> @@ -128,9 +127,8 @@ The Scaling class defines axis scaling - <span class="summary_desc"><div class='inline'><p> -logarithmic base for a logarithmic axis. -</p> + <span class="summary_desc"><div class='inline'> +<p>logarithmic base for a logarithmic axis.</p> </div></span> </li> @@ -155,9 +153,8 @@ logarithmic base for a logarithmic axis. - <span class="summary_desc"><div class='inline'><p> -the maximum scaling. -</p> + <span class="summary_desc"><div class='inline'> +<p>the maximum scaling.</p> </div></span> </li> @@ -182,9 +179,8 @@ the maximum scaling. - <span class="summary_desc"><div class='inline'><p> -the minimu scaling. -</p> + <span class="summary_desc"><div class='inline'> +<p>the minimu scaling.</p> </div></span> </li> @@ -209,9 +205,8 @@ the minimu scaling. - <span class="summary_desc"><div class='inline'><p> -the orientation of the axis must be one of [:minMax, :maxMin]. -</p> + <span class="summary_desc"><div class='inline'> +<p>the orientation of the axis must be one of [:minMax, :maxMin].</p> </div></span> </li> @@ -248,9 +243,8 @@ the orientation of the axis must be one of [:minMax, :maxMin]. - <span class="summary_desc"><div class='inline'><p> -creates a new Scaling object. -</p> + <span class="summary_desc"><div class='inline'> +<p>creates a new Scaling object.</p> </div></span> </li> @@ -272,9 +266,8 @@ creates a new Scaling object. - <span class="summary_desc"><div class='inline'><p> -Serializes the axId. -</p> + <span class="summary_desc"><div class='inline'> +<p>Serializes the axId.</p> </div></span> </li> @@ -295,9 +288,8 @@ Serializes the axId. </p><div class="docstring"> <div class="discussion"> - <p> -creates a new Scaling object -</p> + +<p>creates a new Scaling object</p> </div> @@ -318,9 +310,8 @@ creates a new Scaling object — - <div class='inline'><p> -a customizable set of options -</p> + <div class='inline'> +<p>a customizable set of options</p> </div> </li> @@ -384,18 +375,19 @@ a customizable set of options 30 31 32 -33</pre> +33 +34</pre> </td> <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/scaling.rb', line 28</span> -<span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span><span class='lparen token'>(</span><span class='options identifier id'>options</span><span class='assign token'>=</span><span class='lbrace token'>{</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> - <span class='@orientation ivar id'>@orientation</span> <span class='assign token'>=</span> <span class='symbol val'>:minMax</span> - <span class='options identifier id'>options</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='o identifier id'>o</span><span class='bitor op'>|</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='dstring node'>"#{o[0]}="</span><span class='comma token'>,</span> <span class='o identifier id'>o</span><span class='lbrack token'>[</span><span class='integer val'>1</span><span class='rbrack token'>]</span><span class='rparen token'>)</span> <span class='if if_mod kw'>if</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='respond_to? fid id'>respond_to?</span> <span class='dstring node'>"#{o[0]}="</span> - <span class='end end kw'>end</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id initialize'>initialize</span><span class='lparen'>(</span><span class='id options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span> + <span class='ivar'>@orientation</span> <span class='op'>=</span> <span class='symbol'>:minMax</span> + <span class='ivar'>@logBase</span><span class='comma'>,</span> <span class='ivar'>@min</span><span class='comma'>,</span> <span class='ivar'>@max</span> <span class='op'>=</span> <span class='kw'>nil</span><span class='comma'>,</span> <span class='kw'>nil</span><span class='comma'>,</span> <span class='kw'>nil</span> + <span class='id options'>options</span><span class='period'>.</span><span class='id each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id o'>o</span><span class='op'>|</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span><span class='rbrace'>}</span><span class='tstring_content'>=</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>1</span><span class='rbracket'>]</span><span class='rparen'>)</span> <span class='kw'>if</span> <span class='kw'>self</span><span class='period'>.</span><span class='id respond_to?'>respond_to?</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span><span class='rbrace'>}</span><span class='tstring_content'>=</span><span class='tstring_end'>"</span></span> + <span class='kw'>end</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -418,9 +410,8 @@ a customizable set of options </p><div class="docstring"> <div class="discussion"> - <p> -logarithmic base for a logarithmic axis. must be between 2 and 1000 -</p> + +<p>logarithmic base for a logarithmic axis. must be between 2 and 1000</p> </div> @@ -454,10 +445,9 @@ logarithmic base for a logarithmic axis. must be between 2 and 1000 <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/scaling.rb', line 8</span> -<span class='def def kw'>def</span> <span class='logBase identifier id'>logBase</span> - <span class='@logBase ivar id'>@logBase</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id logBase'>logBase</span> + <span class='ivar'>@logBase</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -475,9 +465,8 @@ logarithmic base for a logarithmic axis. must be between 2 and 1000 </p><div class="docstring"> <div class="discussion"> - <p> -the maximum scaling -</p> + +<p>the maximum scaling</p> </div> @@ -511,10 +500,9 @@ the maximum scaling <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/scaling.rb', line 17</span> -<span class='def def kw'>def</span> <span class='max identifier id'>max</span> - <span class='@max ivar id'>@max</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id max'>max</span> + <span class='ivar'>@max</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -532,9 +520,8 @@ the maximum scaling </p><div class="docstring"> <div class="discussion"> - <p> -the minimu scaling -</p> + +<p>the minimu scaling</p> </div> @@ -568,10 +555,9 @@ the minimu scaling <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/scaling.rb', line 21</span> -<span class='def def kw'>def</span> <span class='min identifier id'>min</span> - <span class='@min ivar id'>@min</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id min'>min</span> + <span class='ivar'>@min</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -589,9 +575,8 @@ the minimu scaling </p><div class="docstring"> <div class="discussion"> - <p> -the orientation of the axis must be one of [:minMax, :maxMin] -</p> + +<p>the orientation of the axis must be one of [:minMax, :maxMin]</p> </div> @@ -625,10 +610,9 @@ the orientation of the axis must be one of [:minMax, :maxMin] <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/scaling.rb', line 13</span> -<span class='def def kw'>def</span> <span class='orientation identifier id'>orientation</span> - <span class='@orientation ivar id'>@orientation</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id orientation'>orientation</span> + <span class='ivar'>@orientation</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -650,9 +634,8 @@ the orientation of the axis must be one of [:minMax, :maxMin] </p><div class="docstring"> <div class="discussion"> - <p> -Serializes the axId -</p> + +<p>Serializes the axId</p> </div> @@ -671,9 +654,8 @@ Serializes the axId — - <div class='inline'><p> -The document builder instance this objects xml will be added to. -</p> + <div class='inline'> +<p>The document builder instance this objects xml will be added to.</p> </div> </li> @@ -700,27 +682,26 @@ The document builder instance this objects xml will be added to. <pre class="lines"> -43 -44 -45 -46 -47 -48 49 -50</pre> +50 +51 +52 +53 +54 +55 +56</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/scaling.rb', line 43</span> - -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:scaling'</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:logBase'</span><span class='comma token'>,</span> <span class='symbol val'>:val=</span><span class='gt op'>></span> <span class='@logBase ivar id'>@logBase</span><span class='rparen token'>)</span> <span class='unless unless_mod kw'>unless</span> <span class='@logBase ivar id'>@logBase</span><span class='dot token'>.</span><span class='nil? fid id'>nil?</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:orientation'</span><span class='comma token'>,</span> <span class='symbol val'>:val=</span><span class='gt op'>></span> <span class='@orientation ivar id'>@orientation</span><span class='rparen token'>)</span> <span class='unless unless_mod kw'>unless</span> <span class='@orientation ivar id'>@orientation</span><span class='dot token'>.</span><span class='nil? fid id'>nil?</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:min'</span><span class='comma token'>,</span> <span class='symbol val'>:val</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='@min ivar id'>@min</span><span class='rparen token'>)</span> <span class='unless unless_mod kw'>unless</span> <span class='@min ivar id'>@min</span><span class='dot token'>.</span><span class='nil? fid id'>nil?</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:max'</span><span class='comma token'>,</span> <span class='symbol val'>:val</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='@max ivar id'>@max</span><span class='rparen token'>)</span> <span class='unless unless_mod kw'>unless</span> <span class='@max ivar id'>@max</span><span class='dot token'>.</span><span class='nil? fid id'>nil?</span> - <span class='rbrace token'>}</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/scaling.rb', line 49</span> + +<span class='kw'>def</span> <span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:scaling</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:logBase</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:val</span><span class='op'>=></span> <span class='ivar'>@logBase</span><span class='rparen'>)</span> <span class='kw'>unless</span> <span class='ivar'>@logBase</span><span class='period'>.</span><span class='id nil?'>nil?</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:orientation</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:val</span><span class='op'>=></span> <span class='ivar'>@orientation</span><span class='rparen'>)</span> <span class='kw'>unless</span> <span class='ivar'>@orientation</span><span class='period'>.</span><span class='id nil?'>nil?</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:min</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:val</span> <span class='op'>=></span> <span class='ivar'>@min</span><span class='rparen'>)</span> <span class='kw'>unless</span> <span class='ivar'>@min</span><span class='period'>.</span><span class='id nil?'>nil?</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:max</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:val</span> <span class='op'>=></span> <span class='ivar'>@max</span><span class='rparen'>)</span> <span class='kw'>unless</span> <span class='ivar'>@max</span><span class='period'>.</span><span class='id nil?'>nil?</span> + <span class='rbrace'>}</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -731,9 +712,9 @@ The document builder instance this objects xml will be added to. </div> <div id="footer"> - Generated on Wed Nov 23 22:20:53 2011 by + Generated on Sat Nov 26 13:16:37 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/SerAxis.html b/doc/Axlsx/SerAxis.html index cd476df7..bec08bde 100644 --- a/doc/Axlsx/SerAxis.html +++ b/doc/Axlsx/SerAxis.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::SerAxis - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -96,9 +96,8 @@ <h2>Overview</h2><div class="docstring"> <div class="discussion"> - <p> -A SerAxis object defines a series axis -</p> + +<p>A SerAxis object defines a series axis</p> </div> @@ -134,9 +133,8 @@ A SerAxis object defines a series axis - <span class="summary_desc"><div class='inline'><p> -The number of tick lables to skip between labels. -</p> + <span class="summary_desc"><div class='inline'> +<p>The number of tick lables to skip between labels.</p> </div></span> </li> @@ -161,9 +159,8 @@ The number of tick lables to skip between labels. - <span class="summary_desc"><div class='inline'><p> -The number of tickmarks to be skipped before the next one is rendered. -</p> + <span class="summary_desc"><div class='inline'> +<p>The number of tickmarks to be skipped before the next one is rendered.</p> </div></span> </li> @@ -208,9 +205,8 @@ The number of tickmarks to be skipped before the next one is rendered. - <span class="summary_desc"><div class='inline'><p> -Creates a new SerAxis object. -</p> + <span class="summary_desc"><div class='inline'> +<p>Creates a new SerAxis object.</p> </div></span> </li> @@ -232,9 +228,8 @@ Creates a new SerAxis object. - <span class="summary_desc"><div class='inline'><p> -Serializes the series axis. -</p> + <span class="summary_desc"><div class='inline'> +<p>Serializes the series axis.</p> </div></span> </li> @@ -260,9 +255,8 @@ Serializes the series axis. </p><div class="docstring"> <div class="discussion"> - <p> -Creates a new SerAxis object -</p> + +<p>Creates a new SerAxis object</p> </div> @@ -281,9 +275,8 @@ Creates a new SerAxis object — - <div class='inline'><p> -the id of this axis. Inherited -</p> + <div class='inline'> +<p>the id of this axis. Inherited</p> </div> </li> @@ -298,9 +291,8 @@ the id of this axis. Inherited — - <div class='inline'><p> -the id of the perpendicular axis. Inherited -</p> + <div class='inline'> +<p>the id of the perpendicular axis. Inherited</p> </div> </li> @@ -317,9 +309,8 @@ the id of the perpendicular axis. Inherited — - <div class='inline'><p> -a customizable set of options -</p> + <div class='inline'> +<p>a customizable set of options</p> </div> </li> @@ -342,9 +333,8 @@ a customizable set of options <span class="default"> </span> - — <div class='inline'><p> -Inherited -</p> + — <div class='inline'> +<p>Inherited</p> </div> </li> @@ -354,9 +344,8 @@ Inherited <span class="default"> </span> - — <div class='inline'><p> -Inherited -</p> + — <div class='inline'> +<p>Inherited</p> </div> </li> @@ -366,9 +355,8 @@ Inherited <span class="default"> </span> - — <div class='inline'><p> -Inherited -</p> + — <div class='inline'> +<p>Inherited</p> </div> </li> @@ -402,15 +390,16 @@ Inherited 21 22 -23</pre> +23 +24</pre> </td> <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/ser_axis.rb', line 21</span> -<span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span><span class='lparen token'>(</span><span class='axId identifier id'>axId</span><span class='comma token'>,</span> <span class='crossAx identifier id'>crossAx</span><span class='comma token'>,</span> <span class='options identifier id'>options</span><span class='assign token'>=</span><span class='lbrace token'>{</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> - <span class='super super kw'>super</span><span class='lparen token'>(</span><span class='axId identifier id'>axId</span><span class='comma token'>,</span> <span class='crossAx identifier id'>crossAx</span><span class='comma token'>,</span> <span class='options identifier id'>options</span><span class='rparen token'>)</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id initialize'>initialize</span><span class='lparen'>(</span><span class='id axId'>axId</span><span class='comma'>,</span> <span class='id crossAx'>crossAx</span><span class='comma'>,</span> <span class='id options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span> + <span class='ivar'>@tickLblSkip</span><span class='comma'>,</span> <span class='ivar'>@tickMarkSkip</span> <span class='op'>=</span> <span class='kw'>nil</span><span class='comma'>,</span> <span class='kw'>nil</span> + <span class='kw'>super</span><span class='lparen'>(</span><span class='id axId'>axId</span><span class='comma'>,</span> <span class='id crossAx'>crossAx</span><span class='comma'>,</span> <span class='id options'>options</span><span class='rparen'>)</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -433,9 +422,8 @@ Inherited </p><div class="docstring"> <div class="discussion"> - <p> -The number of tick lables to skip between labels -</p> + +<p>The number of tick lables to skip between labels</p> </div> @@ -469,10 +457,9 @@ The number of tick lables to skip between labels <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/ser_axis.rb', line 7</span> -<span class='def def kw'>def</span> <span class='tickLblSkip identifier id'>tickLblSkip</span> - <span class='@tickLblSkip ivar id'>@tickLblSkip</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id tickLblSkip'>tickLblSkip</span> + <span class='ivar'>@tickLblSkip</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -490,9 +477,8 @@ The number of tick lables to skip between labels </p><div class="docstring"> <div class="discussion"> - <p> -The number of tickmarks to be skipped before the next one is rendered. -</p> + +<p>The number of tickmarks to be skipped before the next one is rendered.</p> </div> @@ -526,10 +512,9 @@ The number of tickmarks to be skipped before the next one is rendered. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/ser_axis.rb', line 11</span> -<span class='def def kw'>def</span> <span class='tickMarkSkip identifier id'>tickMarkSkip</span> - <span class='@tickMarkSkip ivar id'>@tickMarkSkip</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id tickMarkSkip'>tickMarkSkip</span> + <span class='ivar'>@tickMarkSkip</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -551,9 +536,8 @@ The number of tickmarks to be skipped before the next one is rendered. </p><div class="docstring"> <div class="discussion"> - <p> -Serializes the series axis -</p> + +<p>Serializes the series axis</p> </div> @@ -572,9 +556,8 @@ Serializes the series axis — - <div class='inline'><p> -The document builder instance this objects xml will be added to. -</p> + <div class='inline'> +<p>The document builder instance this objects xml will be added to.</p> </div> </li> @@ -601,25 +584,24 @@ The document builder instance this objects xml will be added to. <pre class="lines"> -31 -32 -33 -34 35 36 -37</pre> +37 +38 +39 +40 +41</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/ser_axis.rb', line 31</span> - -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:serAx'</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='super super kw'>super</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:tickLblSkip'</span><span class='comma token'>,</span> <span class='symbol val'>:val=</span><span class='gt op'>></span><span class='@tickLblSkip ivar id'>@tickLblSkip</span><span class='rparen token'>)</span> <span class='unless unless_mod kw'>unless</span> <span class='@tickLblSkip ivar id'>@tickLblSkip</span><span class='dot token'>.</span><span class='nil? fid id'>nil?</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:tickMarkSkip'</span><span class='comma token'>,</span> <span class='symbol val'>:val=</span><span class='gt op'>></span><span class='@tickMarkSkip ivar id'>@tickMarkSkip</span><span class='rparen token'>)</span> <span class='unless unless_mod kw'>unless</span> <span class='@tickMarkSkip ivar id'>@tickMarkSkip</span><span class='dot token'>.</span><span class='nil? fid id'>nil?</span> - <span class='rbrace token'>}</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/ser_axis.rb', line 35</span> + +<span class='kw'>def</span> <span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:serAx</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='kw'>super</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:tickLblSkip</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:val</span><span class='op'>=></span><span class='ivar'>@tickLblSkip</span><span class='rparen'>)</span> <span class='kw'>unless</span> <span class='ivar'>@tickLblSkip</span><span class='period'>.</span><span class='id nil?'>nil?</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:tickMarkSkip</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:val</span><span class='op'>=></span><span class='ivar'>@tickMarkSkip</span><span class='rparen'>)</span> <span class='kw'>unless</span> <span class='ivar'>@tickMarkSkip</span><span class='period'>.</span><span class='id nil?'>nil?</span> + <span class='rbrace'>}</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -630,9 +612,9 @@ The document builder instance this objects xml will be added to. </div> <div id="footer"> - Generated on Wed Nov 23 22:21:05 2011 by + Generated on Sat Nov 26 13:16:37 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/Series.html b/doc/Axlsx/Series.html index 1b6792b5..f93a1220 100644 --- a/doc/Axlsx/Series.html +++ b/doc/Axlsx/Series.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::Series - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -97,16 +97,14 @@ <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -The recommended way to manage series is to use Chart#add_series -</p> + <div class='inline'> +<p>The recommended way to manage series is to use Chart#add_series</p> </div> </div> -<p> -A Series defines the common series attributes and is the super class for -all concrete series types. -</p> + +<p>A Series defines the common series attributes and is the super class for +all concrete series types.</p> </div> @@ -151,9 +149,8 @@ all concrete series types. - <span class="summary_desc"><div class='inline'><p> -The chart that owns this series. -</p> + <span class="summary_desc"><div class='inline'> +<p>The chart that owns this series.</p> </div></span> </li> @@ -162,14 +159,14 @@ The chart that owns this series. <li class="public "> <span class="summary_signature"> - <a href="#index-instance_method" title="#index (instance method)">- (Integer) <strong>index</strong> </a> + <a href="#title-instance_method" title="#title (instance method)">- (SeriesTitle) <strong>title</strong> </a> </span> - <span class="note title readonly">readonly</span> + @@ -178,53 +175,60 @@ The chart that owns this series. - <span class="summary_desc"><div class='inline'><p> -The index of this series in the chart’s series. -</p> + <span class="summary_desc"><div class='inline'> +<p>The title of the series.</p> </div></span> </li> - <li class="public "> + </ul> + + + + + + <h2> + Instance Method Summary + <small>(<a href="#" class="summary_toggle">collapse</a>)</small> + </h2> + + <ul class="summary"> + + <li class="public "> <span class="summary_signature"> - <a href="#order-instance_method" title="#order (instance method)">- (Integer) <strong>order</strong> </a> + <a href="#index-instance_method" title="#index (instance method)">- (Integer) <strong>index</strong> </a> </span> - - - - <span class="summary_desc"><div class='inline'><p> -The order of this series in the chart’s series. -</p> + <span class="summary_desc"><div class='inline'> +<p>The index of this series in the chart's series.</p> </div></span> </li> - - <li class="public "> + + <li class="public "> <span class="summary_signature"> - <a href="#title-instance_method" title="#title (instance method)">- (SeriesTitle) <strong>title</strong> </a> + <a href="#initialize-instance_method" title="#initialize (instance method)">- (Series) <strong>initialize</strong>(chart, options = {}) </a> </span> + <span class="note title constructor">constructor</span> - - @@ -232,38 +236,22 @@ The order of this series in the chart’s series. - <span class="summary_desc"><div class='inline'><p> -The title of the series. -</p> + <span class="summary_desc"><div class='inline'> +<p>Creates a new series.</p> </div></span> </li> - - </ul> - - - - - - <h2> - Instance Method Summary - <small>(<a href="#" class="summary_toggle">collapse</a>)</small> - </h2> - - <ul class="summary"> <li class="public "> <span class="summary_signature"> - <a href="#initialize-instance_method" title="#initialize (instance method)">- (Series) <strong>initialize</strong>(chart, options = {}) </a> + <a href="#order-instance_method" title="#order (instance method)">- (Integer) <strong>order</strong> </a> </span> - <span class="note title constructor">constructor</span> - @@ -271,9 +259,8 @@ The title of the series. - <span class="summary_desc"><div class='inline'><p> -Creates a new series. -</p> + <span class="summary_desc"><div class='inline'> +<p>The order of this series in the chart's series.</p> </div></span> </li> @@ -282,7 +269,7 @@ Creates a new series. <li class="public "> <span class="summary_signature"> - <a href="#to_xml-instance_method" title="#to_xml (instance method)">- (String) <strong>to_xml</strong>(xml) </a> + <a href="#order%3D-instance_method" title="#order= (instance method)">- (Object) <strong>order=</strong>(v) </a> @@ -295,10 +282,7 @@ Creates a new series. - <span class="summary_desc"><div class='inline'><p> -Serializes the series. -</p> -</div></span> + <span class="summary_desc"><div class='inline'></div></span> </li> @@ -318,9 +302,8 @@ Serializes the series. </p><div class="docstring"> <div class="discussion"> - <p> -Creates a new series -</p> + +<p>Creates a new series</p> </div> @@ -352,9 +335,8 @@ Creates a new series — - <div class='inline'><p> -a customizable set of options -</p> + <div class='inline'> +<p>a customizable set of options</p> </div> </li> @@ -397,25 +379,26 @@ a customizable set of options <pre class="lines"> -28 -29 -30 -31 -32 -33 -34</pre> +20 +21 +22 +23 +24 +25 +26 +27</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/series.rb', line 28</span> - -<span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span><span class='lparen token'>(</span><span class='chart identifier id'>chart</span><span class='comma token'>,</span> <span class='options identifier id'>options</span><span class='assign token'>=</span><span class='lbrace token'>{</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='chart identifier id'>chart</span> <span class='assign token'>=</span> <span class='chart identifier id'>chart</span> - <span class='@chart ivar id'>@chart</span><span class='dot token'>.</span><span class='series identifier id'>series</span> <span class='lshft op'><<</span> <span class='self self kw'>self</span> - <span class='options identifier id'>options</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='o identifier id'>o</span><span class='bitor op'>|</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='dstring node'>"#{o[0]}="</span><span class='comma token'>,</span> <span class='o identifier id'>o</span><span class='lbrack token'>[</span><span class='integer val'>1</span><span class='rbrack token'>]</span><span class='rparen token'>)</span> <span class='if if_mod kw'>if</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='respond_to? fid id'>respond_to?</span> <span class='dstring node'>"#{o[0]}="</span> - <span class='end end kw'>end</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/series.rb', line 20</span> + +<span class='kw'>def</span> <span class='id initialize'>initialize</span><span class='lparen'>(</span><span class='id chart'>chart</span><span class='comma'>,</span> <span class='id options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span> + <span class='ivar'>@order</span> <span class='op'>=</span> <span class='kw'>nil</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id chart'>chart</span> <span class='op'>=</span> <span class='id chart'>chart</span> + <span class='ivar'>@chart</span><span class='period'>.</span><span class='id series'>series</span> <span class='op'><<</span> <span class='kw'>self</span> + <span class='id options'>options</span><span class='period'>.</span><span class='id each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id o'>o</span><span class='op'>|</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span><span class='rbrace'>}</span><span class='tstring_content'>=</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>1</span><span class='rbracket'>]</span><span class='rparen'>)</span> <span class='kw'>if</span> <span class='kw'>self</span><span class='period'>.</span><span class='id respond_to?'>respond_to?</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span><span class='rbrace'>}</span><span class='tstring_content'>=</span><span class='tstring_end'>"</span></span> + <span class='kw'>end</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -438,9 +421,8 @@ a customizable set of options </p><div class="docstring"> <div class="discussion"> - <p> -The chart that owns this series -</p> + +<p>The chart that owns this series</p> </div> @@ -474,30 +456,28 @@ The chart that owns this series <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/series.rb', line 10</span> -<span class='def def kw'>def</span> <span class='chart identifier id'>chart</span> - <span class='@chart ivar id'>@chart</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id chart'>chart</span> + <span class='ivar'>@chart</span> +<span class='kw'>end</span></pre> </td> </tr> </table> </div> - <span id=""></span> - <span id="index-instance_method"></span> + <span id="title=-instance_method"></span> + <span id="title-instance_method"></span> <div class="method_details "> - <p class="signature " id="index-instance_method"> + <p class="signature " id="title-instance_method"> - - (<tt>Integer</tt>) <strong>index</strong> <span class="extras">(readonly)</span> + - (<tt><span class='object_link'><a href="SeriesTitle.html" title="Axlsx::SeriesTitle (class)">SeriesTitle</a></span></tt>) <strong>title</strong> </p><div class="docstring"> <div class="discussion"> - <p> -The index of this series in the chart’s series. -</p> + +<p>The title of the series</p> </div> @@ -510,7 +490,7 @@ The index of this series in the chart’s series. <li> - <span class='type'>(<tt>Integer</tt>)</span> + <span class='type'>(<tt><span class='object_link'><a href="SeriesTitle.html" title="Axlsx::SeriesTitle (class)">SeriesTitle</a></span></tt>)</span> @@ -531,31 +511,32 @@ The index of this series in the chart’s series. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/series.rb', line 14</span> -<span class='def def kw'>def</span> <span class='index identifier id'>index</span> - <span class='@chart ivar id'>@chart</span><span class='dot token'>.</span><span class='series identifier id'>series</span><span class='dot token'>.</span><span class='index identifier id'>index</span><span class='lparen token'>(</span><span class='self self kw'>self</span><span class='rparen token'>)</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id title'>title</span> + <span class='ivar'>@title</span> +<span class='kw'>end</span></pre> </td> </tr> </table> </div> - - <span id="order=-instance_method"></span> - <span id="order-instance_method"></span> - <div class="method_details "> - <p class="signature " id="order-instance_method"> + </div> + + + <div id="instance_method_details" class="method_details_list"> + <h2>Instance Method Details</h2> + + + <div class="method_details first"> + <p class="signature first" id="index-instance_method"> - - (<tt>Integer</tt>) <strong>order</strong> + - (<tt>Integer</tt>) <strong>index</strong> </p><div class="docstring"> <div class="discussion"> - <p> -The order of this series in the chart’s series. By default the order -is the index of the series. -</p> + +<p>The index of this series in the chart's series.</p> </div> @@ -582,37 +563,33 @@ is the index of the series. <pre class="lines"> -18 -19 -20</pre> +31 +32 +33</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/series.rb', line 18</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/series.rb', line 31</span> -<span class='def def kw'>def</span> <span class='order identifier id'>order</span> - <span class='@order ivar id'>@order</span> <span class='orop op'>||</span> <span class='index identifier id'>index</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id index'>index</span> + <span class='ivar'>@chart</span><span class='period'>.</span><span class='id series'>series</span><span class='period'>.</span><span class='id index'>index</span><span class='lparen'>(</span><span class='kw'>self</span><span class='rparen'>)</span> +<span class='kw'>end</span></pre> </td> </tr> </table> </div> - - <span id="title=-instance_method"></span> - <span id="title-instance_method"></span> <div class="method_details "> - <p class="signature " id="title-instance_method"> + <p class="signature " id="order-instance_method"> - - (<tt><span class='object_link'><a href="SeriesTitle.html" title="Axlsx::SeriesTitle (class)">SeriesTitle</a></span></tt>) <strong>title</strong> + - (<tt>Integer</tt>) <strong>order</strong> </p><div class="docstring"> <div class="discussion"> - <p> -The title of the series -</p> + +<p>The order of this series in the chart's series. By default the order is the +index of the series.</p> </div> @@ -625,7 +602,7 @@ The title of the series <li> - <span class='type'>(<tt><span class='object_link'><a href="SeriesTitle.html" title="Axlsx::SeriesTitle (class)">SeriesTitle</a></span></tt>)</span> + <span class='type'>(<tt>Integer</tt>)</span> @@ -639,81 +616,43 @@ The title of the series <pre class="lines"> -22 -23 -24</pre> +38 +39 +40</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/series.rb', line 22</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/series.rb', line 38</span> -<span class='def def kw'>def</span> <span class='title identifier id'>title</span> - <span class='@title ivar id'>@title</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id order'>order</span> + <span class='ivar'>@order</span> <span class='op'>||</span> <span class='id index'>index</span> +<span class='kw'>end</span></pre> </td> </tr> </table> </div> - </div> - - - <div id="instance_method_details" class="method_details_list"> - <h2>Instance Method Details</h2> - - - <div class="method_details first"> - <p class="signature first" id="to_xml-instance_method"> + <div class="method_details "> + <p class="signature " id="order=-instance_method"> - - (<tt>String</tt>) <strong>to_xml</strong>(xml) + - (<tt>Object</tt>) <strong>order=</strong>(v) </p><div class="docstring"> <div class="discussion"> - <p> -Serializes the series -</p> - + </div> </div> <div class="tags"> - <h3>Parameters:</h3> -<ul class="param"> - <li> - - <span class='name'>xml</span> - - - <span class='type'>(<tt>Nokogiri::XML::Builder</tt>)</span> - - - - — - <div class='inline'><p> -The document builder instance this objects xml will be added to. -</p> -</div> - - </li> - -</ul> -<h3>Returns:</h3> -<ul class="return"> - - <li> - - - <span class='type'>(<tt>String</tt>)</span> - - - - </li> - -</ul> + <h3>See Also:</h3> + <ul class="see"> + + <li>order</li> + + </ul> </div><table class="source_code"> <tr> @@ -721,27 +660,12 @@ The document builder instance this objects xml will be added to. <pre class="lines"> -60 -61 -62 -63 -64 -65 -66 -67</pre> +43</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/series.rb', line 60</span> - -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:ser'</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:idx'</span><span class='comma token'>,</span> <span class='symbol val'>:val=</span><span class='gt op'>></span><span class='index identifier id'>index</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:order'</span><span class='comma token'>,</span> <span class='symbol val'>:val=</span><span class='gt op'>></span><span class='order identifier id'>order</span> <span class='orop op'>||</span> <span class='index identifier id'>index</span><span class='rparen token'>)</span> - <span class='title identifier id'>title</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> <span class='unless unless_mod kw'>unless</span> <span class='title identifier id'>title</span><span class='dot token'>.</span><span class='nil? fid id'>nil?</span> - <span class='yield yield kw'>yield</span> <span class='xml identifier id'>xml</span> <span class='if if_mod kw'>if</span> <span class='block_given? fid id'>block_given?</span> - <span class='rbrace token'>}</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/series.rb', line 43</span> + +<span class='kw'>def</span> <span class='id order='>order=</span><span class='lparen'>(</span><span class='id v'>v</span><span class='rparen'>)</span> <span class='const'>Axlsx</span><span class='op'>::</span><span class='id validate_unsigned_int'>validate_unsigned_int</span><span class='lparen'>(</span><span class='id v'>v</span><span class='rparen'>)</span><span class='semicolon'>;</span> <span class='ivar'>@order</span> <span class='op'>=</span> <span class='id v'>v</span><span class='semicolon'>;</span> <span class='kw'>end</span></pre> </td> </tr> </table> @@ -752,9 +676,9 @@ The document builder instance this objects xml will be added to. </div> <div id="footer"> - Generated on Wed Nov 23 22:20:50 2011 by + Generated on Sat Nov 26 13:16:37 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/SeriesTitle.html b/doc/Axlsx/SeriesTitle.html index d455e01b..e809a40e 100644 --- a/doc/Axlsx/SeriesTitle.html +++ b/doc/Axlsx/SeriesTitle.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::SeriesTitle - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -96,10 +96,9 @@ <h2>Overview</h2><div class="docstring"> <div class="discussion"> - <p> -A series title is a Title with a slightly different serialization than -chart titles. -</p> + +<p>A series title is a Title with a slightly different serialization than +chart titles.</p> </div> @@ -148,9 +147,8 @@ chart titles. - <span class="summary_desc"><div class='inline'><p> -Serializes the series title. -</p> + <span class="summary_desc"><div class='inline'> +<p>Serializes the series title.</p> </div></span> </li> @@ -168,7 +166,7 @@ Serializes the series title. <h3 class="inherited">Methods inherited from <span class='object_link'><a href="Title.html" title="Axlsx::Title (class)">Title</a></span></h3> - <p class="inherited"><span class='object_link'><a href="Title.html#initialize-instance_method" title="Axlsx::Title#initialize (method)">#initialize</a></span>, <span class='object_link'><a href="Title.html#range-instance_method" title="Axlsx::Title#range (method)">#range</a></span></p> + <p class="inherited"><span class='object_link'><a href="Title.html#initialize-instance_method" title="Axlsx::Title#initialize (method)">#initialize</a></span></p> <div id="constructor_details" class="method_details_list"> <h2>Constructor Details</h2> @@ -190,9 +188,8 @@ Serializes the series title. </p><div class="docstring"> <div class="discussion"> - <p> -Serializes the series title -</p> + +<p>Serializes the series title</p> </div> @@ -211,9 +208,8 @@ Serializes the series title — - <div class='inline'><p> -The document builder instance this objects xml will be added to. -</p> + <div class='inline'> +<p>The document builder instance this objects xml will be added to.</p> </div> </li> @@ -257,20 +253,19 @@ The document builder instance this objects xml will be added to. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/series_title.rb', line 8</span> -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:tx'</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:strRef'</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:f'</span><span class='comma token'>,</span> <span class='range identifier id'>range</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:strCache'</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:ptCount'</span><span class='comma token'>,</span> <span class='symbol val'>:val=</span><span class='gt op'>></span><span class='integer val'>1</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:pt'</span><span class='comma token'>,</span> <span class='symbol val'>:idx=</span><span class='gt op'>></span><span class='integer val'>0</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:v'</span><span class='comma token'>,</span> <span class='@text ivar id'>@text</span><span class='rparen token'>)</span> - <span class='rbrace token'>}</span> - <span class='rbrace token'>}</span> - <span class='rbrace token'>}</span> - <span class='rbrace token'>}</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:tx</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:strRef</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:f</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='const'>Axlsx</span><span class='op'>::</span><span class='id cell_range'>cell_range</span><span class='lparen'>(</span><span class='lbracket'>[</span><span class='ivar'>@cell</span><span class='rbracket'>]</span><span class='rparen'>)</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:strCache</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:ptCount</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:val</span><span class='op'>=></span><span class='int'>1</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:pt</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:idx</span><span class='op'>=></span><span class='int'>0</span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:v</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='ivar'>@text</span><span class='rparen'>)</span> + <span class='rbrace'>}</span> + <span class='rbrace'>}</span> + <span class='rbrace'>}</span> + <span class='rbrace'>}</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -281,9 +276,9 @@ The document builder instance this objects xml will be added to. </div> <div id="footer"> - Generated on Wed Nov 23 22:20:53 2011 by + Generated on Sat Nov 26 13:16:38 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/SimpleTypedList.html b/doc/Axlsx/SimpleTypedList.html deleted file mode 100644 index f2136a97..00000000 --- a/doc/Axlsx/SimpleTypedList.html +++ /dev/null @@ -1,1686 +0,0 @@ -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" - "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> - <head> - <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> -<title> - Class: Axlsx::SimpleTypedList - - — Documentation by YARD 0.7.3 - -</title> - - <link rel="stylesheet" href="../css/style.css" type="text/css" media="screen" charset="utf-8" /> - - <link rel="stylesheet" href="../css/common.css" type="text/css" media="screen" charset="utf-8" /> - -<script type="text/javascript" charset="utf-8"> - relpath = '..'; - if (relpath != '') relpath += '/'; -</script> - - <script type="text/javascript" charset="utf-8" src="../js/jquery.js"></script> - - <script type="text/javascript" charset="utf-8" src="../js/app.js"></script> - - - </head> - <body> - <script type="text/javascript" charset="utf-8"> - if (window.top.frames.main) document.body.className = 'frames'; - </script> - - <div id="header"> - <div id="menu"> - - <a href="../_index.html">Index (S)</a> » - <span class='title'><span class='object_link'><a href="../Axlsx.html" title="Axlsx (module)">Axlsx</a></span></span> - » - <span class="title">SimpleTypedList</span> - - - <div class="noframes"><span class="title">(</span><a href="." target="_top">no frames</a><span class="title">)</span></div> -</div> - - <div id="search"> - - <a id="class_list_link" href="#">Class List</a> - - <a id="method_list_link" href="#">Method List</a> - - <a id="file_list_link" href="#">File List</a> - -</div> - <div class="clear"></div> - </div> - - <iframe id="search_frame"></iframe> - - <div id="content"><h1>Class: Axlsx::SimpleTypedList - - - -</h1> - -<dl class="box"> - - <dt class="r1">Inherits:</dt> - <dd class="r1"> - <span class="inheritName">Object</span> - - <ul class="fullTree"> - <li>Object</li> - - <li class="next">Axlsx::SimpleTypedList</li> - - </ul> - <a href="#" class="inheritanceTree">show all</a> - - </dd> - - - - - - - - - - <dt class="r2 last">Defined in:</dt> - <dd class="r2 last">lib/axlsx/util/simple_typed_list.rb</dd> - -</dl> -<div class="clear"></div> - -<h2>Overview</h2><div class="docstring"> - <div class="discussion"> - <p> -A SimpleTypedList is a type restrictive collection that allows some of the -methods from Array and supports basic xml serialization. -</p> - - - </div> -</div> -<div class="tags"> - - -</div><div id="subclasses"> - <h2>Direct Known Subclasses</h2> - <p class="children"><span class='object_link'><a href="CatAxisData.html" title="Axlsx::CatAxisData (class)">CatAxisData</a></span>, <span class='object_link'><a href="ContentType.html" title="Axlsx::ContentType (class)">ContentType</a></span>, <span class='object_link'><a href="Relationships.html" title="Axlsx::Relationships (class)">Relationships</a></span>, <span class='object_link'><a href="TableStyle.html" title="Axlsx::TableStyle (class)">TableStyle</a></span>, <span class='object_link'><a href="TableStyles.html" title="Axlsx::TableStyles (class)">TableStyles</a></span></p> -</div> - - - <h2>Instance Attribute Summary <small>(<a href="#" class="summary_toggle">collapse</a>)</small></h2> - <ul class="summary"> - - <li class="public "> - <span class="summary_signature"> - - <a href="#allowed_types-instance_method" title="#allowed_types (instance method)">- (Array) <strong>allowed_types</strong> </a> - - - - </span> - - - <span class="note title readonly">readonly</span> - - - - - - - - - <span class="summary_desc"><div class='inline'><p> -The class constants of allowed types. -</p> -</div></span> - -</li> - - - <li class="public "> - <span class="summary_signature"> - - <a href="#locked_at-instance_method" title="#locked_at (instance method)">- (Integer) <strong>locked_at</strong> </a> - - - - </span> - - - <span class="note title readonly">readonly</span> - - - - - - - - - <span class="summary_desc"><div class='inline'><p> -The index below which items cannot be removed. -</p> -</div></span> - -</li> - - - <li class="public "> - <span class="summary_signature"> - - <a href="#serialize_as-instance_method" title="#serialize_as (instance method)">- (String) <strong>serialize_as</strong> </a> - - - - </span> - - - <span class="note title readonly">readonly</span> - - - - - - - - - <span class="summary_desc"><div class='inline'><p> -The tag name to use when serializing this object by default the parent node -for all items in the list is the classname of the first allowed type with -the first letter in lowercase. -</p> -</div></span> - -</li> - - - </ul> - - - - - - <h2> - Instance Method Summary - <small>(<a href="#" class="summary_toggle">collapse</a>)</small> - </h2> - - <ul class="summary"> - - <li class="public "> - <span class="summary_signature"> - - <a href="#%3C%3C-instance_method" title="#<< (instance method)">- (Integer) <strong><<</strong>(v) </a> - - - - </span> - - - - - - - - - <span class="summary_desc"><div class='inline'><p> -Concat operator. -</p> -</div></span> - -</li> - - - <li class="public "> - <span class="summary_signature"> - - <a href="#%3D%3D-instance_method" title="#== (instance method)">- (Object) <strong>==</strong>(v) </a> - - - - </span> - - - - - - - - - <span class="summary_desc"><div class='inline'><p> -override the equality method so that this object can be compared to a -simple array. -</p> -</div></span> - -</li> - - - <li class="public "> - <span class="summary_signature"> - - <a href="#%5B%5D%3D-instance_method" title="#[]= (instance method)">- (Object) <strong>[]=</strong>(index, v) </a> - - - - </span> - - - - - - - - - <span class="summary_desc"><div class='inline'><p> -positional assignment. -</p> -</div></span> - -</li> - - - <li class="public "> - <span class="summary_signature"> - - <a href="#delete-instance_method" title="#delete (instance method)">- (Any) <strong>delete</strong>(v) </a> - - - - </span> - - - - - - - - - <span class="summary_desc"><div class='inline'><p> -delete the item from the list. -</p> -</div></span> - -</li> - - - <li class="public "> - <span class="summary_signature"> - - <a href="#delete_at-instance_method" title="#delete_at (instance method)">- (Any) <strong>delete_at</strong>(index) </a> - - - - </span> - - - - - - - - - <span class="summary_desc"><div class='inline'><p> -delete the item from the list at the index position provided. -</p> -</div></span> - -</li> - - - <li class="public "> - <span class="summary_signature"> - - <a href="#initialize-instance_method" title="#initialize (instance method)">- (SimpleTypedList) <strong>initialize</strong>(type, serialize_as = nil) </a> - - - - </span> - - <span class="note title constructor">constructor</span> - - - - - - - - - <span class="summary_desc"><div class='inline'><p> -Creats a new typed list. -</p> -</div></span> - -</li> - - - <li class="public "> - <span class="summary_signature"> - - <a href="#lock-instance_method" title="#lock (instance method)">- (self) <strong>lock</strong> </a> - - - - </span> - - - - - - - - - <span class="summary_desc"><div class='inline'><p> -Lock this list at the current size. -</p> -</div></span> - -</li> - - - <li class="public "> - <span class="summary_signature"> - - <a href="#method_missing-instance_method" title="#method_missing (instance method)">- (Object) <strong>method_missing</strong>(meth, *args, &block) </a> - - - - </span> - - - - - - - - - <span class="summary_desc"><div class='inline'><p> -method_mission override to pass allowed methods to the list. -</p> -</div></span> - -</li> - - - <li class="public "> - <span class="summary_signature"> - - <a href="#protected%3F-instance_method" title="#protected? (instance method)">- (Boolean) <strong>protected?</strong>(index) </a> - - - - </span> - - - - - - - - - <span class="summary_desc"><div class='inline'><p> -determines if the index is protected. -</p> -</div></span> - -</li> - - - <li class="public "> - <span class="summary_signature"> - - <a href="#push-instance_method" title="#push (instance method)">- (Object) <strong>push</strong>(v) </a> - - - - </span> - - - - - - - - - <span class="summary_desc"><div class='inline'><p> -alternate of << method. -</p> -</div></span> - -</li> - - - <li class="public "> - <span class="summary_signature"> - - <a href="#to_xml-instance_method" title="#to_xml (instance method)">- (String) <strong>to_xml</strong>(xml) </a> - - - - </span> - - - - - - - - - <span class="summary_desc"><div class='inline'><p> -Serializes the list If the serialize_as property is set, it is used as the -parent node name. -</p> -</div></span> - -</li> - - - <li class="public "> - <span class="summary_signature"> - - <a href="#unlock-instance_method" title="#unlock (instance method)">- (self) <strong>unlock</strong> </a> - - - - </span> - - - - - - - - - <span class="summary_desc"><div class='inline'><p> -Unlock the list. -</p> -</div></span> - -</li> - - - </ul> - - -<div id="constructor_details" class="method_details_list"> - <h2>Constructor Details</h2> - - <div class="method_details first"> - <p class="signature first" id="initialize-instance_method"> - - - (<tt><span class='object_link'><a href="" title="Axlsx::SimpleTypedList (class)">SimpleTypedList</a></span></tt>) <strong>initialize</strong>(type, serialize_as = nil) - - - -</p><div class="docstring"> - <div class="discussion"> - <p> -Creats a new typed list -</p> - - - </div> -</div> -<div class="tags"> - <h3>Parameters:</h3> -<ul class="param"> - - <li> - - <span class='name'>type</span> - - - <span class='type'>(<tt>Array</tt>, <tt>Class</tt>)</span> - - - - — - <div class='inline'><p> -An array of Class objects or a single Class object -</p> -</div> - - </li> - - <li> - - <span class='name'>serialize</span> - - - <span class='type'>(<tt>String</tt>)</span> - - - - — - <div class='inline'><p> -The tag name to use in serialization -</p> -</div> - - </li> - -</ul> - -<h3>Raises:</h3> -<ul class="raise"> - - <li> - - - <span class='type'>(<tt>ArgumentError</tt>)</span> - - - - — - <div class='inline'><p> -if all members of type are not Class objects -</p> -</div> - - </li> - -</ul> - -</div><table class="source_code"> - <tr> - <td> - <pre class="lines"> - - -22 -23 -24 -25 -26 -27 -28 -29 -30 -31 -32 -33</pre> - </td> - <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/util/simple_typed_list.rb', line 22</span> - -<span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span> <span class='type identifier id'>type</span><span class='comma token'>,</span> <span class='serialize_as identifier id'>serialize_as</span><span class='assign token'>=</span><span class='nil nil kw'>nil</span> - <span class='if if kw'>if</span> <span class='type identifier id'>type</span><span class='dot token'>.</span><span class='is_a? fid id'>is_a?</span> <span class='Array constant id'>Array</span> - <span class='type identifier id'>type</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='lbrace token'>{</span> <span class='bitor op'>|</span><span class='item identifier id'>item</span><span class='bitor op'>|</span> <span class='raise identifier id'>raise</span> <span class='ArgumentError constant id'>ArgumentError</span><span class='comma token'>,</span> <span class='string val'>"All members of type must be Class objects"</span> <span class='unless unless_mod kw'>unless</span> <span class='item identifier id'>item</span><span class='dot token'>.</span><span class='is_a? fid id'>is_a?</span> <span class='Class constant id'>Class</span> <span class='rbrace token'>}</span> - <span class='@allowed_types ivar id'>@allowed_types</span> <span class='assign token'>=</span> <span class='type identifier id'>type</span> - <span class='else else kw'>else</span> - <span class='raise identifier id'>raise</span> <span class='ArgumentError constant id'>ArgumentError</span><span class='comma token'>,</span> <span class='string val'>"Type must be a Class object or array of Class objects"</span> <span class='unless unless_mod kw'>unless</span> <span class='type identifier id'>type</span><span class='dot token'>.</span><span class='is_a? fid id'>is_a?</span> <span class='Class constant id'>Class</span> - <span class='@allowed_types ivar id'>@allowed_types</span> <span class='assign token'>=</span> <span class='lbrack token'>[</span><span class='type identifier id'>type</span><span class='rbrack token'>]</span> - <span class='end end kw'>end</span> - <span class='@list ivar id'>@list</span> <span class='assign token'>=</span> <span class='lbrack token'>[</span><span class='rbrack token'>]</span> - <span class='@locked_at ivar id'>@locked_at</span> <span class='assign token'>=</span> <span class='nil nil kw'>nil</span> - <span class='@serialize_as ivar id'>@serialize_as</span> <span class='assign token'>=</span> <span class='serialize_as identifier id'>serialize_as</span> -<span class='end end kw'>end</span> -</pre> - </td> - </tr> -</table> -</div> - -</div> -<div id="method_missing_details" class="method_details_list"> - <h2>Dynamic Method Handling</h2> - <p class="notice this"> - This class handles dynamic methods through the <tt>method_missing</tt> method - - </p> - - <div class="method_details first"> - <p class="signature first" id="method_missing-instance_method"> - - - (<tt>Object</tt>) <strong>method_missing</strong>(meth, *args, &block) - - - -</p><div class="docstring"> - <div class="discussion"> - - <div class="note notetag"> - <strong>Note:</strong> - <div class='inline'><p> -the following methods are not allowed -</p> -<pre class="code"> - <span class='symbol val'>:replace</span> - <span class='symbol val'>:insert</span> - <span class='symbol val'>:collect!</span> - <span class='symbol val'>:map!</span> - <span class='symbol val'>:pop</span> - <span class='symbol val'>:delete_if</span> - <span class='symbol val'>:reverse!</span> - <span class='symbol val'>:shift</span> - <span class='symbol val'>:shuffle!</span> - <span class='symbol val'>:slice!</span> - <span class='symbol val'>:sort!</span> - <span class='symbol val'>:uniq!</span> - <span class='symbol val'>:unshift</span> - <span class='symbol val'>:zip</span> - <span class='symbol val'>:flatten!</span> - <span class='symbol val'>:fill</span> - <span class='symbol val'>:drop</span> - <span class='symbol val'>:drop_while</span> - <span class='symbol val'>:delete_if</span> - <span class='symbol val'>:clear</span> -</pre> -</div> - </div> - -<p> -method_mission override to pass allowed methods to the list. -</p> - - - </div> -</div> -<div class="tags"> - -<h3>Raises:</h3> -<ul class="raise"> - - <li> - - - <span class='type'>(<tt>ArgumentError</tt>)</span> - - - - </li> - -</ul> - -</div><table class="source_code"> - <tr> - <td> - <pre class="lines"> - - -131 -132 -133 -134 -135 -136 -137 -138 -139</pre> - </td> - <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/util/simple_typed_list.rb', line 131</span> - -<span class='def def kw'>def</span> <span class='method_missing identifier id'>method_missing</span><span class='lparen token'>(</span><span class='meth identifier id'>meth</span><span class='comma token'>,</span> <span class='mult op'>*</span><span class='args identifier id'>args</span><span class='comma token'>,</span> <span class='bitand op'>&</span><span class='block identifier id'>block</span><span class='rparen token'>)</span> - <span class='raise identifier id'>raise</span> <span class='ArgumentError constant id'>ArgumentError</span><span class='comma token'>,</span> <span class='dstring node'>"#{meth} not supported"</span> <span class='if if_mod kw'>if</span> <span class='lbrack token'>[</span><span class='symbol val'>:replace</span><span class='comma token'>,</span> <span class='symbol val'>:insert</span><span class='comma token'>,</span> <span class='symbol val'>:collect!</span><span class='comma token'>,</span> <span class='symbol val'>:map!</span><span class='comma token'>,</span> <span class='symbol val'>:pop</span><span class='comma token'>,</span> <span class='symbol val'>:delete_if</span><span class='comma token'>,</span> <span class='symbol val'>:reverse!</span><span class='comma token'>,</span> <span class='symbol val'>:shift</span><span class='comma token'>,</span> <span class='symbol val'>:shuffle!</span><span class='comma token'>,</span> <span class='symbol val'>:slice!</span><span class='comma token'>,</span> <span class='symbol val'>:sort!</span><span class='comma token'>,</span> <span class='symbol val'>:uniq!</span><span class='comma token'>,</span> <span class='symbol val'>:unshift</span><span class='comma token'>,</span> <span class='symbol val'>:zip</span><span class='comma token'>,</span> <span class='symbol val'>:flatten!</span><span class='comma token'>,</span> <span class='symbol val'>:fill</span><span class='comma token'>,</span> <span class='symbol val'>:drop</span><span class='comma token'>,</span> <span class='symbol val'>:drop_while</span><span class='comma token'>,</span> <span class='symbol val'>:delete_if</span><span class='comma token'>,</span> <span class='symbol val'>:clear</span><span class='rbrack token'>]</span><span class='dot token'>.</span><span class='include? fid id'>include?</span> <span class='meth identifier id'>meth</span><span class='dot token'>.</span><span class='to_sym identifier id'>to_sym</span> - <span class='if if kw'>if</span> <span class='@list ivar id'>@list</span><span class='dot token'>.</span><span class='respond_to? fid id'>respond_to?</span> <span class='meth identifier id'>meth</span> - <span class='@list ivar id'>@list</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='meth identifier id'>meth</span><span class='comma token'>,</span> <span class='mult op'>*</span><span class='args identifier id'>args</span><span class='comma token'>,</span> <span class='bitand op'>&</span><span class='block identifier id'>block</span><span class='rparen token'>)</span> - <span class='else else kw'>else</span> - <span class='puts identifier id'>puts</span> <span class='dstring node'>"method:#{meth.inspect}"</span> - <span class='super super kw'>super</span> - <span class='end end kw'>end</span> -<span class='end end kw'>end</span> -</pre> - </td> - </tr> -</table> -</div> - -</div> - - <div id="instance_attr_details" class="attr_details"> - <h2>Instance Attribute Details</h2> - - - <span id=""></span> - <span id="allowed_types-instance_method"></span> - <div class="method_details first"> - <p class="signature first" id="allowed_types-instance_method"> - - - (<tt>Array</tt>) <strong>allowed_types</strong> <span class="extras">(readonly)</span> - - - -</p><div class="docstring"> - <div class="discussion"> - <p> -The class constants of allowed types -</p> - - - </div> -</div> -<div class="tags"> - -<h3>Returns:</h3> -<ul class="return"> - - <li> - - - <span class='type'>(<tt>Array</tt>)</span> - - - - </li> - -</ul> - -</div><table class="source_code"> - <tr> - <td> - <pre class="lines"> - - -7 -8 -9</pre> - </td> - <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/util/simple_typed_list.rb', line 7</span> - -<span class='def def kw'>def</span> <span class='allowed_types identifier id'>allowed_types</span> - <span class='@allowed_types ivar id'>@allowed_types</span> -<span class='end end kw'>end</span> -</pre> - </td> - </tr> -</table> -</div> - - - <span id=""></span> - <span id="locked_at-instance_method"></span> - <div class="method_details "> - <p class="signature " id="locked_at-instance_method"> - - - (<tt>Integer</tt>) <strong>locked_at</strong> <span class="extras">(readonly)</span> - - - -</p><div class="docstring"> - <div class="discussion"> - <p> -The index below which items cannot be removed -</p> - - - </div> -</div> -<div class="tags"> - -<h3>Returns:</h3> -<ul class="return"> - - <li> - - - <span class='type'>(<tt>Integer</tt>)</span> - - - - </li> - -</ul> - -</div><table class="source_code"> - <tr> - <td> - <pre class="lines"> - - -11 -12 -13</pre> - </td> - <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/util/simple_typed_list.rb', line 11</span> - -<span class='def def kw'>def</span> <span class='locked_at identifier id'>locked_at</span> - <span class='@locked_at ivar id'>@locked_at</span> -<span class='end end kw'>end</span> -</pre> - </td> - </tr> -</table> -</div> - - - <span id=""></span> - <span id="serialize_as-instance_method"></span> - <div class="method_details "> - <p class="signature " id="serialize_as-instance_method"> - - - (<tt>String</tt>) <strong>serialize_as</strong> <span class="extras">(readonly)</span> - - - -</p><div class="docstring"> - <div class="discussion"> - <p> -The tag name to use when serializing this object by default the parent node -for all items in the list is the classname of the first allowed type with -the first letter in lowercase. -</p> - - - </div> -</div> -<div class="tags"> - -<h3>Returns:</h3> -<ul class="return"> - - <li> - - - <span class='type'>(<tt>String</tt>)</span> - - - - </li> - -</ul> - -</div><table class="source_code"> - <tr> - <td> - <pre class="lines"> - - -16 -17 -18</pre> - </td> - <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/util/simple_typed_list.rb', line 16</span> - -<span class='def def kw'>def</span> <span class='serialize_as identifier id'>serialize_as</span> - <span class='@serialize_as ivar id'>@serialize_as</span> -<span class='end end kw'>end</span> -</pre> - </td> - </tr> -</table> -</div> - - </div> - - - <div id="instance_method_details" class="method_details_list"> - <h2>Instance Method Details</h2> - - - <div class="method_details first"> - <p class="signature first" id="<<-instance_method"> - - - (<tt>Integer</tt>) <strong><<</strong>(v) - - - -</p><div class="docstring"> - <div class="discussion"> - <p> -Concat operator -</p> - - - </div> -</div> -<div class="tags"> - <h3>Parameters:</h3> -<ul class="param"> - - <li> - - <span class='name'>v</span> - - - <span class='type'>(<tt>Any</tt>)</span> - - - - — - <div class='inline'><p> -the data to be added -</p> -</div> - - </li> - -</ul> - -<h3>Returns:</h3> -<ul class="return"> - - <li> - - - <span class='type'>(<tt>Integer</tt>)</span> - - - - — - <div class='inline'><p> -returns the index of the item added. -</p> -</div> - - </li> - -</ul> -<h3>Raises:</h3> -<ul class="raise"> - - <li> - - - <span class='type'>(<tt>ArgumentError</tt>)</span> - - - - — - <div class='inline'><p> -if the value being added is not one fo the allowed types -</p> -</div> - - </li> - -</ul> - -</div><table class="source_code"> - <tr> - <td> - <pre class="lines"> - - -53 -54 -55 -56 -57</pre> - </td> - <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/util/simple_typed_list.rb', line 53</span> - -<span class='def def kw'>def</span> <span class='lshft op'><<</span><span class='lparen token'>(</span><span class='v identifier id'>v</span><span class='rparen token'>)</span> - <span class='DataTypeValidator constant id'>DataTypeValidator</span><span class='dot token'>.</span><span class='validate identifier id'>validate</span> <span class='string val'>"SimpleTypedList.<<"</span><span class='comma token'>,</span> <span class='@allowed_types ivar id'>@allowed_types</span><span class='comma token'>,</span> <span class='v identifier id'>v</span> - <span class='@list ivar id'>@list</span> <span class='lshft op'><<</span> <span class='v identifier id'>v</span> - <span class='@list ivar id'>@list</span><span class='dot token'>.</span><span class='size identifier id'>size</span> <span class='minus op'>-</span> <span class='integer val'>1</span> -<span class='end end kw'>end</span> -</pre> - </td> - </tr> -</table> -</div> - - <div class="method_details "> - <p class="signature " id="==-instance_method"> - - - (<tt>Object</tt>) <strong>==</strong>(v) - - - -</p><div class="docstring"> - <div class="discussion"> - <p> -override the equality method so that this object can be compared to a -simple array. if this object’s list is equal to the specifiec array, -we return true. -</p> - - - </div> -</div> -<div class="tags"> - - -</div><table class="source_code"> - <tr> - <td> - <pre class="lines"> - - -105 -106 -107</pre> - </td> - <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/util/simple_typed_list.rb', line 105</span> - -<span class='def def kw'>def</span> <span class='eq op'>==</span><span class='lparen token'>(</span><span class='v identifier id'>v</span><span class='rparen token'>)</span> - <span class='v identifier id'>v</span> <span class='eq op'>==</span> <span class='@list ivar id'>@list</span> -<span class='end end kw'>end</span> -</pre> - </td> - </tr> -</table> -</div> - - <div class="method_details "> - <p class="signature " id="[]=-instance_method"> - - - (<tt>Object</tt>) <strong>[]=</strong>(index, v) - - - -</p><div class="docstring"> - <div class="discussion"> - <p> -positional assignment. Adds the item at the index specified -</p> - - - </div> -</div> -<div class="tags"> - <h3>Parameters:</h3> -<ul class="param"> - - <li> - - <span class='name'>index</span> - - - <span class='type'>(<tt>Integer</tt>)</span> - - - - </li> - - <li> - - <span class='name'>v</span> - - - <span class='type'>(<tt>Any</tt>)</span> - - - - </li> - -</ul> - -<h3>Raises:</h3> -<ul class="raise"> - - <li> - - - <span class='type'>(<tt>ArgumentError</tt>)</span> - - - - — - <div class='inline'><p> -if the index is protected by locking -</p> -</div> - - </li> - - <li> - - - <span class='type'>(<tt>ArgumentError</tt>)</span> - - - - — - <div class='inline'><p> -if the item is not one of the allowed types -</p> -</div> - - </li> - -</ul> - -</div><table class="source_code"> - <tr> - <td> - <pre class="lines"> - - -89 -90 -91 -92 -93 -94</pre> - </td> - <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/util/simple_typed_list.rb', line 89</span> - -<span class='def def kw'>def</span> <span class='aset op'>[]=</span><span class='lparen token'>(</span><span class='index identifier id'>index</span><span class='comma token'>,</span> <span class='v identifier id'>v</span><span class='rparen token'>)</span> - <span class='DataTypeValidator constant id'>DataTypeValidator</span><span class='dot token'>.</span><span class='validate identifier id'>validate</span> <span class='string val'>"SimpleTypedList.<<"</span><span class='comma token'>,</span> <span class='@allowed_types ivar id'>@allowed_types</span><span class='comma token'>,</span> <span class='v identifier id'>v</span> - <span class='raise identifier id'>raise</span> <span class='ArgumentError constant id'>ArgumentError</span><span class='comma token'>,</span> <span class='string val'>"Item is protected and cannot be changed"</span> <span class='if if_mod kw'>if</span> <span class='protected? fid id'>protected?</span> <span class='index identifier id'>index</span> - <span class='@list ivar id'>@list</span><span class='lbrack token'>[</span><span class='index identifier id'>index</span><span class='rbrack token'>]</span> <span class='assign token'>=</span> <span class='v identifier id'>v</span> - <span class='v identifier id'>v</span> -<span class='end end kw'>end</span> -</pre> - </td> - </tr> -</table> -</div> - - <div class="method_details "> - <p class="signature " id="delete-instance_method"> - - - (<tt>Any</tt>) <strong>delete</strong>(v) - - - -</p><div class="docstring"> - <div class="discussion"> - <p> -delete the item from the list -</p> - - - </div> -</div> -<div class="tags"> - <h3>Parameters:</h3> -<ul class="param"> - - <li> - - <span class='name'>v</span> - - - <span class='type'>(<tt>Any</tt>)</span> - - - - — - <div class='inline'><p> -The item to be deleted. -</p> -</div> - - </li> - -</ul> - -<h3>Returns:</h3> -<ul class="return"> - - <li> - - - <span class='type'>(<tt>Any</tt>)</span> - - - - — - <div class='inline'><p> -The item deleted -</p> -</div> - - </li> - -</ul> -<h3>Raises:</h3> -<ul class="raise"> - - <li> - - - <span class='type'>(<tt>ArgumentError</tt>)</span> - - - - — - <div class='inline'><p> -if the item’s index is protected by locking -</p> -</div> - - </li> - -</ul> - -</div><table class="source_code"> - <tr> - <td> - <pre class="lines"> - - -69 -70 -71 -72 -73</pre> - </td> - <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/util/simple_typed_list.rb', line 69</span> - -<span class='def def kw'>def</span> <span class='delete identifier id'>delete</span><span class='lparen token'>(</span><span class='v identifier id'>v</span><span class='rparen token'>)</span> - <span class='return return kw'>return</span> <span class='unless unless_mod kw'>unless</span> <span class='@list ivar id'>@list</span><span class='dot token'>.</span><span class='include? fid id'>include?</span> <span class='v identifier id'>v</span> - <span class='raise identifier id'>raise</span> <span class='ArgumentError constant id'>ArgumentError</span><span class='comma token'>,</span> <span class='string val'>"Item is protected and cannot be deleted"</span> <span class='if if_mod kw'>if</span> <span class='protected? fid id'>protected?</span> <span class='@list ivar id'>@list</span><span class='dot token'>.</span><span class='index identifier id'>index</span><span class='lparen token'>(</span><span class='v identifier id'>v</span><span class='rparen token'>)</span> - <span class='@list ivar id'>@list</span><span class='dot token'>.</span><span class='delete identifier id'>delete</span> <span class='v identifier id'>v</span> -<span class='end end kw'>end</span> -</pre> - </td> - </tr> -</table> -</div> - - <div class="method_details "> - <p class="signature " id="delete_at-instance_method"> - - - (<tt>Any</tt>) <strong>delete_at</strong>(index) - - - -</p><div class="docstring"> - <div class="discussion"> - <p> -delete the item from the list at the index position provided -</p> - - - </div> -</div> -<div class="tags"> - -<h3>Returns:</h3> -<ul class="return"> - - <li> - - - <span class='type'>(<tt>Any</tt>)</span> - - - - — - <div class='inline'><p> -The item deleted -</p> -</div> - - </li> - -</ul> -<h3>Raises:</h3> -<ul class="raise"> - - <li> - - - <span class='type'>(<tt>ArgumentError</tt>)</span> - - - - — - <div class='inline'><p> -if the index is protected by locking -</p> -</div> - - </li> - -</ul> - -</div><table class="source_code"> - <tr> - <td> - <pre class="lines"> - - -78 -79 -80 -81 -82</pre> - </td> - <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/util/simple_typed_list.rb', line 78</span> - -<span class='def def kw'>def</span> <span class='delete_at identifier id'>delete_at</span><span class='lparen token'>(</span><span class='index identifier id'>index</span><span class='rparen token'>)</span> - <span class='@list ivar id'>@list</span><span class='lbrack token'>[</span><span class='index identifier id'>index</span><span class='rbrack token'>]</span> - <span class='raise identifier id'>raise</span> <span class='ArgumentError constant id'>ArgumentError</span><span class='comma token'>,</span> <span class='string val'>"Item is protected and cannot be deleted"</span> <span class='if if_mod kw'>if</span> <span class='protected? fid id'>protected?</span> <span class='index identifier id'>index</span> - <span class='@list ivar id'>@list</span><span class='dot token'>.</span><span class='delete_at identifier id'>delete_at</span> <span class='index identifier id'>index</span> -<span class='end end kw'>end</span> -</pre> - </td> - </tr> -</table> -</div> - - <div class="method_details "> - <p class="signature " id="lock-instance_method"> - - - (<tt>self</tt>) <strong>lock</strong> - - - -</p><div class="docstring"> - <div class="discussion"> - <p> -Lock this list at the current size -</p> - - - </div> -</div> -<div class="tags"> - -<h3>Returns:</h3> -<ul class="return"> - - <li> - - - <span class='type'>(<tt>self</tt>)</span> - - - - </li> - -</ul> - -</div><table class="source_code"> - <tr> - <td> - <pre class="lines"> - - -37 -38 -39 -40</pre> - </td> - <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/util/simple_typed_list.rb', line 37</span> - -<span class='def def kw'>def</span> <span class='lock identifier id'>lock</span> - <span class='@locked_at ivar id'>@locked_at</span> <span class='assign token'>=</span> <span class='@list ivar id'>@list</span><span class='dot token'>.</span><span class='size identifier id'>size</span> - <span class='self self kw'>self</span> -<span class='end end kw'>end</span> -</pre> - </td> - </tr> -</table> -</div> - - <div class="method_details "> - <p class="signature " id="protected?-instance_method"> - - - (<tt>Boolean</tt>) <strong>protected?</strong>(index) - - - -</p><div class="docstring"> - <div class="discussion"> - <p> -determines if the index is protected -</p> - - - </div> -</div> -<div class="tags"> - <h3>Parameters:</h3> -<ul class="param"> - - <li> - - <span class='name'>index</span> - - - <span class='type'>(<tt>Integer</tt>)</span> - - - - </li> - -</ul> - -<h3>Returns:</h3> -<ul class="return"> - - <li> - - - <span class='type'>(<tt>Boolean</tt>)</span> - - - - </li> - -</ul> - -</div><table class="source_code"> - <tr> - <td> - <pre class="lines"> - - -98 -99 -100 -101</pre> - </td> - <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/util/simple_typed_list.rb', line 98</span> - -<span class='def def kw'>def</span> <span class='protected? fid id'>protected?</span> <span class='index identifier id'>index</span> - <span class='return return kw'>return</span> <span class='false false kw'>false</span> <span class='unless unless_mod kw'>unless</span> <span class='@locked_at ivar id'>@locked_at</span><span class='dot token'>.</span><span class='is_a? fid id'>is_a?</span> <span class='Fixnum constant id'>Fixnum</span> - <span class='index identifier id'>index</span> <span class='lt op'><</span> <span class='@locked_at ivar id'>@locked_at</span> -<span class='end end kw'>end</span> -</pre> - </td> - </tr> -</table> -</div> - - <div class="method_details "> - <p class="signature " id="push-instance_method"> - - - (<tt>Object</tt>) <strong>push</strong>(v) - - - -</p><div class="docstring"> - <div class="discussion"> - <p> -alternate of << method -</p> - - - </div> -</div> -<div class="tags"> - - - <h3>See Also:</h3> - <ul class="see"> - - <li><<</li> - - </ul> - -</div><table class="source_code"> - <tr> - <td> - <pre class="lines"> - - -61 -62 -63</pre> - </td> - <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/util/simple_typed_list.rb', line 61</span> - -<span class='def def kw'>def</span> <span class='push identifier id'>push</span><span class='lparen token'>(</span><span class='v identifier id'>v</span><span class='rparen token'>)</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='lshft op'><<</span> <span class='v identifier id'>v</span> -<span class='end end kw'>end</span> -</pre> - </td> - </tr> -</table> -</div> - - <div class="method_details "> - <p class="signature " id="to_xml-instance_method"> - - - (<tt>String</tt>) <strong>to_xml</strong>(xml) - - - -</p><div class="docstring"> - <div class="discussion"> - <p> -Serializes the list If the serialize_as property is set, it is used as the -parent node name. If the serialize_as property is nil, the first item in -the list of allowed_types will be used, having the first letter of the -class changed to lower case. -</p> - - - </div> -</div> -<div class="tags"> - <h3>Parameters:</h3> -<ul class="param"> - - <li> - - <span class='name'>xml</span> - - - <span class='type'>(<tt>Nokogiri::XML::Builder</tt>)</span> - - - - — - <div class='inline'><p> -The document builder instance this objects xml will be added to. -</p> -</div> - - </li> - -</ul> - -<h3>Returns:</h3> -<ul class="return"> - - <li> - - - <span class='type'>(<tt>String</tt>)</span> - - - - </li> - -</ul> - -</div><table class="source_code"> - <tr> - <td> - <pre class="lines"> - - -146 -147 -148 -149 -150 -151 -152</pre> - </td> - <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/util/simple_typed_list.rb', line 146</span> - -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='classname identifier id'>classname</span> <span class='assign token'>=</span> <span class='@allowed_types ivar id'>@allowed_types</span><span class='lbrack token'>[</span><span class='integer val'>0</span><span class='rbrack token'>]</span><span class='dot token'>.</span><span class='name identifier id'>name</span><span class='dot token'>.</span><span class='split identifier id'>split</span><span class='lparen token'>(</span><span class='string val'>'::'</span><span class='rparen token'>)</span><span class='dot token'>.</span><span class='last identifier id'>last</span> - <span class='el_name identifier id'>el_name</span> <span class='assign token'>=</span> <span class='serialize_as identifier id'>serialize_as</span> <span class='orop op'>||</span> <span class='lparen token'>(</span><span class='classname identifier id'>classname</span><span class='lbrack token'>[</span><span class='integer val'>0</span><span class='comma token'>,</span><span class='integer val'>1</span><span class='rbrack token'>]</span><span class='dot token'>.</span><span class='downcase identifier id'>downcase</span> <span class='plus op'>+</span> <span class='classname identifier id'>classname</span><span class='lbrack token'>[</span><span class='float val'>1</span><span class='dot2 op'>..</span><span class='integer val'>-1</span><span class='rbrack token'>]</span><span class='rparen token'>)</span><span class='dot token'>.</span><span class='pluralize identifier id'>pluralize</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='el_name identifier id'>el_name</span><span class='comma token'>,</span> <span class='symbol val'>:count=</span><span class='gt op'>></span><span class='@list ivar id'>@list</span><span class='dot token'>.</span><span class='size identifier id'>size</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='@list ivar id'>@list</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='lbrace token'>{</span> <span class='bitor op'>|</span><span class='item identifier id'>item</span><span class='bitor op'>|</span> <span class='item identifier id'>item</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> <span class='rbrace token'>}</span> - <span class='rbrace token'>}</span> -<span class='end end kw'>end</span> -</pre> - </td> - </tr> -</table> -</div> - - <div class="method_details "> - <p class="signature " id="unlock-instance_method"> - - - (<tt>self</tt>) <strong>unlock</strong> - - - -</p><div class="docstring"> - <div class="discussion"> - <p> -Unlock the list -</p> - - - </div> -</div> -<div class="tags"> - -<h3>Returns:</h3> -<ul class="return"> - - <li> - - - <span class='type'>(<tt>self</tt>)</span> - - - - </li> - -</ul> - -</div><table class="source_code"> - <tr> - <td> - <pre class="lines"> - - -44 -45 -46 -47</pre> - </td> - <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/util/simple_typed_list.rb', line 44</span> - -<span class='def def kw'>def</span> <span class='unlock identifier id'>unlock</span> - <span class='@locked_at ivar id'>@locked_at</span> <span class='assign token'>=</span> <span class='nil nil kw'>nil</span> - <span class='self self kw'>self</span> -<span class='end end kw'>end</span> -</pre> - </td> - </tr> -</table> -</div> - - </div> - -</div> - - <div id="footer"> - Generated on Wed Nov 23 22:21:00 2011 by - <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). -</div> - - </body> -</html>
\ No newline at end of file diff --git a/doc/Axlsx/Styles.html b/doc/Axlsx/Styles.html index b429ec58..f0eff10d 100644 --- a/doc/Axlsx/Styles.html +++ b/doc/Axlsx/Styles.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::Styles - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -97,20 +97,18 @@ <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -The recommended way to manage styles is with add_style -</p> + <div class='inline'> +<p>The recommended way to manage styles is with add_style</p> </div> </div> -<p> -The Styles class manages worksheet styles In addition to creating the + +<p>The Styles class manages worksheet styles In addition to creating the require style objects for a valid xlsx package, this class provides the key mechanism for adding styles to your workbook, and safely applying them to the cells of your worksheet. All portions of the stylesheet are implemented here exception colors, which specify legacy and modified pallete colors, -and exLst, whic is used as a future feature data storage area. -</p> +and exLst, whic is used as a future feature data storage area.</p> </div> @@ -151,10 +149,9 @@ and exLst, whic is used as a future feature data storage area. - <span class="summary_desc"><div class='inline'><p> -The collection of borders used in this workbook Axlsx predefines -THIN_BORDER which can be used to put a border around all of your cells. -</p> + <span class="summary_desc"><div class='inline'> +<p>The collection of borders used in this workbook Axlsx predefines +THIN_BORDER which can be used to put a border around all of your cells.</p> </div></span> </li> @@ -179,10 +176,9 @@ THIN_BORDER which can be used to put a border around all of your cells. - <span class="summary_desc"><div class='inline'><p> -The collection of named styles, referencing cellStyleXfs items in the -workbook. -</p> + <span class="summary_desc"><div class='inline'> +<p>The collection of named styles, referencing cellStyleXfs items in the +workbook.</p> </div></span> </li> @@ -207,10 +203,9 @@ workbook. - <span class="summary_desc"><div class='inline'><p> -The collection of master formatting records for named cell styles, which -means records defined in cellStyles, in the workbook. -</p> + <span class="summary_desc"><div class='inline'> +<p>The collection of master formatting records for named cell styles, which +means records defined in cellStyles, in the workbook.</p> </div></span> </li> @@ -235,9 +230,8 @@ means records defined in cellStyles, in the workbook. - <span class="summary_desc"><div class='inline'><p> -The collection of master formatting records. -</p> + <span class="summary_desc"><div class='inline'> +<p>The collection of master formatting records.</p> </div></span> </li> @@ -262,9 +256,8 @@ The collection of master formatting records. - <span class="summary_desc"><div class='inline'><p> -The collection of non-cell formatting records used in the worksheet. -</p> + <span class="summary_desc"><div class='inline'> +<p>The collection of non-cell formatting records used in the worksheet.</p> </div></span> </li> @@ -289,9 +282,8 @@ The collection of non-cell formatting records used in the worksheet. - <span class="summary_desc"><div class='inline'><p> -The collection of fills used in this workbook. -</p> + <span class="summary_desc"><div class='inline'> +<p>The collection of fills used in this workbook.</p> </div></span> </li> @@ -316,9 +308,8 @@ The collection of fills used in this workbook. - <span class="summary_desc"><div class='inline'><p> -The collection of fonts used in this workbook. -</p> + <span class="summary_desc"><div class='inline'> +<p>The collection of fonts used in this workbook.</p> </div></span> </li> @@ -343,9 +334,8 @@ The collection of fonts used in this workbook. - <span class="summary_desc"><div class='inline'><p> -numFmts for your styles. -</p> + <span class="summary_desc"><div class='inline'> +<p>numFmts for your styles.</p> </div></span> </li> @@ -370,10 +360,9 @@ numFmts for your styles. - <span class="summary_desc"><div class='inline'><p> -The collection of table styles that will be available to the user in the -excel UI. -</p> + <span class="summary_desc"><div class='inline'> +<p>The collection of table styles that will be available to the user in the +excel UI.</p> </div></span> </li> @@ -408,9 +397,8 @@ excel UI. - <span class="summary_desc"><div class='inline'><p> -Drastically simplifies style creation and management. -</p> + <span class="summary_desc"><div class='inline'> +<p>Drastically simplifies style creation and management.</p> </div></span> </li> @@ -434,10 +422,9 @@ Drastically simplifies style creation and management. - <span class="summary_desc"><div class='inline'><p> -Creates a new Styles object and prepopulates it with the requires objects -to generate a valid package style part. -</p> + <span class="summary_desc"><div class='inline'> +<p>Creates a new Styles object and prepopulates it with the requires objects +to generate a valid package style part.</p> </div></span> </li> @@ -459,9 +446,8 @@ to generate a valid package style part. - <span class="summary_desc"><div class='inline'><p> -Serializes the styles document. -</p> + <span class="summary_desc"><div class='inline'> +<p>Serializes the styles document.</p> </div></span> </li> @@ -482,10 +468,9 @@ Serializes the styles document. </p><div class="docstring"> <div class="discussion"> - <p> -Creates a new Styles object and prepopulates it with the requires objects -to generate a valid package style part. -</p> + +<p>Creates a new Styles object and prepopulates it with the requires objects +to generate a valid package style part.</p> </div> @@ -506,10 +491,9 @@ to generate a valid package style part. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/styles.rb', line 118</span> -<span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span><span class='lparen token'>(</span><span class='rparen token'>)</span> - <span class='load_default_styles identifier id'>load_default_styles</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id initialize'>initialize</span><span class='lparen'>(</span><span class='rparen'>)</span> + <span class='id load_default_styles'>load_default_styles</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -535,16 +519,14 @@ to generate a valid package style part. <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -The recommended way to manage styles is with add_style -</p> + <div class='inline'> +<p>The recommended way to manage styles is with add_style</p> </div> </div> -<p> -The collection of borders used in this workbook Axlsx predefines -THIN_BORDER which can be used to put a border around all of your cells. -</p> + +<p>The collection of borders used in this workbook Axlsx predefines +THIN_BORDER which can be used to put a border around all of your cells.</p> </div> @@ -585,10 +567,9 @@ THIN_BORDER which can be used to put a border around all of your cells. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/styles.rb', line 85</span> -<span class='def def kw'>def</span> <span class='borders identifier id'>borders</span> - <span class='@borders ivar id'>@borders</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id borders'>borders</span> + <span class='ivar'>@borders</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -609,16 +590,14 @@ THIN_BORDER which can be used to put a border around all of your cells. <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -The recommended way to manage styles is with add_style -</p> + <div class='inline'> +<p>The recommended way to manage styles is with add_style</p> </div> </div> -<p> -The collection of named styles, referencing cellStyleXfs items in the -workbook. -</p> + +<p>The collection of named styles, referencing cellStyleXfs items in the +workbook.</p> </div> @@ -659,10 +638,9 @@ workbook. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/styles.rb', line 97</span> -<span class='def def kw'>def</span> <span class='cellStyles identifier id'>cellStyles</span> - <span class='@cellStyles ivar id'>@cellStyles</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id cellStyles'>cellStyles</span> + <span class='ivar'>@cellStyles</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -683,16 +661,14 @@ workbook. <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -The recommended way to manage styles is with add_style -</p> + <div class='inline'> +<p>The recommended way to manage styles is with add_style</p> </div> </div> -<p> -The collection of master formatting records for named cell styles, which -means records defined in cellStyles, in the workbook -</p> + +<p>The collection of master formatting records for named cell styles, which +means records defined in cellStyles, in the workbook</p> </div> @@ -733,10 +709,9 @@ means records defined in cellStyles, in the workbook <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/styles.rb', line 91</span> -<span class='def def kw'>def</span> <span class='cellStyleXfs identifier id'>cellStyleXfs</span> - <span class='@cellStyleXfs ivar id'>@cellStyleXfs</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id cellStyleXfs'>cellStyleXfs</span> + <span class='ivar'>@cellStyleXfs</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -757,16 +732,14 @@ means records defined in cellStyles, in the workbook <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -The recommended way to manage styles is with add_style -</p> + <div class='inline'> +<p>The recommended way to manage styles is with add_style</p> </div> </div> -<p> -The collection of master formatting records. This is the list that you will -actually use in styling a workbook. -</p> + +<p>The collection of master formatting records. This is the list that you will +actually use in styling a workbook.</p> </div> @@ -807,10 +780,9 @@ actually use in styling a workbook. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/styles.rb', line 103</span> -<span class='def def kw'>def</span> <span class='cellXfs identifier id'>cellXfs</span> - <span class='@cellXfs ivar id'>@cellXfs</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id cellXfs'>cellXfs</span> + <span class='ivar'>@cellXfs</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -831,15 +803,13 @@ actually use in styling a workbook. <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -The recommended way to manage styles is with add_style -</p> + <div class='inline'> +<p>The recommended way to manage styles is with add_style</p> </div> </div> -<p> -The collection of non-cell formatting records used in the worksheet. -</p> + +<p>The collection of non-cell formatting records used in the worksheet.</p> </div> @@ -880,10 +850,9 @@ The collection of non-cell formatting records used in the worksheet. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/styles.rb', line 109</span> -<span class='def def kw'>def</span> <span class='dxfs identifier id'>dxfs</span> - <span class='@dxfs ivar id'>@dxfs</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id dxfs'>dxfs</span> + <span class='ivar'>@dxfs</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -904,15 +873,13 @@ The collection of non-cell formatting records used in the worksheet. <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -The recommended way to manage styles is with add_style -</p> + <div class='inline'> +<p>The recommended way to manage styles is with add_style</p> </div> </div> -<p> -The collection of fills used in this workbook -</p> + +<p>The collection of fills used in this workbook</p> </div> @@ -953,10 +920,9 @@ The collection of fills used in this workbook <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/styles.rb', line 78</span> -<span class='def def kw'>def</span> <span class='fills identifier id'>fills</span> - <span class='@fills ivar id'>@fills</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id fills'>fills</span> + <span class='ivar'>@fills</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -977,15 +943,13 @@ The collection of fills used in this workbook <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -The recommended way to manage styles is with add_style -</p> + <div class='inline'> +<p>The recommended way to manage styles is with add_style</p> </div> </div> -<p> -The collection of fonts used in this workbook -</p> + +<p>The collection of fonts used in this workbook</p> </div> @@ -1026,10 +990,9 @@ The collection of fonts used in this workbook <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/styles.rb', line 72</span> -<span class='def def kw'>def</span> <span class='fonts identifier id'>fonts</span> - <span class='@fonts ivar id'>@fonts</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id fonts'>fonts</span> + <span class='ivar'>@fonts</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1050,51 +1013,48 @@ The collection of fonts used in this workbook <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -The recommended way to manage styles is with add_style -</p> + <div class='inline'> +<p>The recommended way to manage styles is with add_style</p> </div> </div> -<p> -numFmts for your styles. -</p> -<pre class="code"> - <span class='The constant id'>The</span> <span class='default identifier id'>default</span> <span class='styles identifier id'>styles</span><span class='comma token'>,</span> <span class='which identifier id'>which</span> <span class='change identifier id'>change</span> <span class='based identifier id'>based</span> <span class='on identifier id'>on</span> <span class='the identifier id'>the</span> <span class='system identifier id'>system</span> <span class='local identifier id'>local</span><span class='comma token'>,</span> <span class='are identifier id'>are</span> <span class='as identifier id'>as</span> <span class='follows identifier id'>follows</span><span class='dot token'>.</span> - <span class='id identifier id'>id</span> <span class='formatCode identifier id'>formatCode</span> - <span class='integer val'>0</span> <span class='General constant id'>General</span> - <span class='integer val'>1</span> <span class='integer val'>0</span> - <span class='integer val'>2</span> <span class='integer val'>0</span><span class='integer val'>.00</span> - <span class='integer val'>3</span> <span class='comment val'>#,##0</span> - <span class='integer val'>4</span> <span class='comment val'>#,##0.00</span> - <span class='integer val'>9</span> <span class='integer val'>0</span><span class='mod op'>%</span> - <span class='integer val'>10</span> <span class='integer val'>0</span><span class='integer val'>.00</span><span class='mod op'>%</span> - <span class='integer val'>11</span> <span class='integer val'>0</span><span class='float val'>.00E+00</span> - <span class='integer val'>12</span> <span class='comment val'># ?/?</span> - <span class='integer val'>13</span> <span class='comment val'># ??/??</span> - <span class='integer val'>14</span> <span class='mm identifier id'>mm</span><span class='minus op'>-</span><span class='dd identifier id'>dd</span><span class='minus op'>-</span><span class='yy identifier id'>yy</span> - <span class='integer val'>15</span> <span class='d identifier id'>d</span><span class='minus op'>-</span><span class='mmm identifier id'>mmm</span><span class='minus op'>-</span><span class='yy identifier id'>yy</span> - <span class='integer val'>16</span> <span class='d identifier id'>d</span><span class='minus op'>-</span><span class='mmm identifier id'>mmm</span> - <span class='integer val'>17</span> <span class='mmm identifier id'>mmm</span><span class='minus op'>-</span><span class='yy identifier id'>yy</span> - <span class='integer val'>18</span> <span class='h identifier id'>h</span><span class='symbol val'>:mm</span> <span class='AM constant id'>AM</span><span class='div op'>/</span><span class='PM constant id'>PM</span> - <span class='integer val'>19</span> <span class='h identifier id'>h</span><span class='symbol val'>:mm</span><span class='symbol val'>:ss</span> <span class='AM constant id'>AM</span><span class='div op'>/</span><span class='PM constant id'>PM</span> - <span class='integer val'>20</span> <span class='h identifier id'>h</span><span class='symbol val'>:mm</span> - <span class='integer val'>21</span> <span class='h identifier id'>h</span><span class='symbol val'>:mm</span><span class='symbol val'>:ss</span> - <span class='integer val'>22</span> <span class='m identifier id'>m</span><span class='div op'>/</span><span class='d identifier id'>d</span><span class='div op'>/</span><span class='yy identifier id'>yy</span> <span class='h identifier id'>h</span><span class='symbol val'>:mm</span> - <span class='integer val'>37</span> <span class='comment val'>#,##0 ;(#,##0)</span> - <span class='integer val'>38</span> <span class='comment val'>#,##0 ;[Red](#,##0)</span> - <span class='integer val'>39</span> <span class='comment val'>#,##0.00;(#,##0.00)</span> - <span class='integer val'>40</span> <span class='comment val'>#,##0.00;[Red](#,##0.00)</span> - <span class='integer val'>45</span> <span class='mm identifier id'>mm</span><span class='symbol val'>:ss</span> - <span class='integer val'>46</span> <span class='lbrack token'>[</span><span class='h identifier id'>h</span><span class='rbrack token'>]</span><span class='symbol val'>:mm</span><span class='symbol val'>:ss</span> - <span class='integer val'>47</span> <span class='mmss identifier id'>mmss</span><span class='integer val'>.0</span> - <span class='integer val'>48</span> <span class='comment val'>##0.0E+0</span> - <span class='integer val'>49</span> @ - <span class='Axlsx constant id'>Axlsx</span> <span class='also identifier id'>also</span> <span class='defines identifier id'>defines</span> <span class='the identifier id'>the</span> <span class='following identifier id'>following</span> <span class='constants identifier id'>constants</span> <span class='which identifier id'>which</span> <span class='you identifier id'>you</span> <span class='can identifier id'>can</span> <span class='use identifier id'>use</span> <span class='in in kw'>in</span> <span class='add_style identifier id'>add_style</span><span class='dot token'>.</span> - <span class='NUM_FMT_PERCENT constant id'>NUM_FMT_PERCENT</span> <span class='formats identifier id'>formats</span> <span class='to identifier id'>to</span> <span class='string val'>"0%"</span> - <span class='NUM_FMT_YYYYMMDD constant id'>NUM_FMT_YYYYMMDD</span> <span class='formats identifier id'>formats</span> <span class='to identifier id'>to</span> <span class='string val'>"yyyy/mm/dd"</span> - <span class='NUM_FMT_YYYYMMDDHHMMSS constant id'>NUM_FMT_YYYYMMDDHHMMSS</span> <span class='formats identifier id'>formats</span> <span class='to identifier id'>to</span> <span class='string val'>"yyyy/mm/dd hh:mm:ss"</span> -</pre> + +<p>numFmts for your styles.</p> + +<pre class="code">The default styles, which change based on the system local, are as follows. +id formatCode + 0 General + 1 0 + 2 0.00 + 3 #,##0 + 4 #,##0.00 + 9 0% + 10 0.00% + 11 0.00E+00 + 12 # ?/? + 13 # ??/?? + 14 mm-dd-yy + 15 d-mmm-yy + 16 d-mmm + 17 mmm-yy + 18 h:mm AM/PM + 19 h:mm:ss AM/PM + 20 h:mm + 21 h:mm:ss + 22 m/d/yy h:mm + 37 #,##0 ;(#,##0) + 38 #,##0 ;[Red](#,##0) + 39 #,##0.00;(#,##0.00) + 40 #,##0.00;[Red](#,##0.00) + 45 mm:ss + 46 [h]:mm:ss + 47 mmss.0 + 48 ##0.0E+0 + 49 @ +Axlsx also defines the following constants which you can use in add_style. + NUM_FMT_PERCENT formats to "0%" + NUM_FMT_YYYYMMDD formats to "yyyy/mm/dd" + NUM_FMT_YYYYMMDDHHMMSS formats to "yyyy/mm/dd hh:mm:ss"</pre> </div> @@ -1137,10 +1097,9 @@ numFmts for your styles. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/styles.rb', line 66</span> -<span class='def def kw'>def</span> <span class='numFmts identifier id'>numFmts</span> - <span class='@numFmts ivar id'>@numFmts</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id numFmts'>numFmts</span> + <span class='ivar'>@numFmts</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1161,16 +1120,14 @@ numFmts for your styles. <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -The recommended way to manage styles is with add_style -</p> + <div class='inline'> +<p>The recommended way to manage styles is with add_style</p> </div> </div> -<p> -The collection of table styles that will be available to the user in the -excel UI -</p> + +<p>The collection of table styles that will be available to the user in the +excel UI</p> </div> @@ -1211,10 +1168,9 @@ excel UI <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/styles.rb', line 115</span> -<span class='def def kw'>def</span> <span class='tableStyles identifier id'>tableStyles</span> - <span class='@tableStyles ivar id'>@tableStyles</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id tableStyles'>tableStyles</span> + <span class='ivar'>@tableStyles</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1236,9 +1192,8 @@ excel UI </p><div class="docstring"> <div class="discussion"> - <p> -Drastically simplifies style creation and management. -</p> + +<p>Drastically simplifies style creation and management.</p> </div> @@ -1248,63 +1203,59 @@ Drastically simplifies style creation and management. <div class="examples"> <h3>Examples:</h3> - <h4><div class='inline'><p> -You Got Style -</p> + <h4><div class='inline'> +<p>You Got Style</p> </div></h4> - <pre class="example code"><span class='require identifier id'>require</span> <span class='string val'>"rubygems"</span> <span class='comment val'># if that is your preferred way to manage gems!</span> -<span class='require identifier id'>require</span> <span class='string val'>"axlsx"</span> + <pre class="example code">require "rubygems" # if that is your preferred way to manage gems! +require "axlsx" -<span class='p identifier id'>p</span> <span class='assign token'>=</span> <span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='Package constant id'>Package</span><span class='dot token'>.</span><span class='new identifier id'>new</span> -<span class='ws identifier id'>ws</span> <span class='assign token'>=</span> <span class='p identifier id'>p</span><span class='dot token'>.</span><span class='workbook identifier id'>workbook</span><span class='dot token'>.</span><span class='add_worksheet identifier id'>add_worksheet</span> +p = Axlsx::Package.new +ws = p.workbook.add_worksheet -<span class='comment val'># black text on a white background at 14pt with thin borders!</span> -<span class='title identifier id'>title</span> <span class='assign token'>=</span> <span class='ws identifier id'>ws</span><span class='dot token'>.</span><span class='style identifier id'>style</span><span class='dot token'>.</span><span class='add_style identifier id'>add_style</span><span class='lparen token'>(</span><span class='symbol val'>:bg_color</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='string val'>"FFFF0000"</span><span class='comma token'>,</span> <span class='symbol val'>:fg_color=</span><span class='gt op'>></span><span class='string val'>"#FF000000"</span><span class='comma token'>,</span> <span class='symbol val'>:sz=</span><span class='gt op'>></span><span class='integer val'>14</span><span class='comma token'>,</span> <span class='symbol val'>:border=</span><span class='gt op'>></span><span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='STYLE_THIN_BORDER constant id'>STYLE_THIN_BORDER</span> +# black text on a white background at 14pt with thin borders! +title = ws.style.add_style(:bg_color => "FFFF0000", :fg_color=>"#FF000000", :sz=>14, :border=>Axlsx::STYLE_THIN_BORDER -<span class='ws identifier id'>ws</span><span class='dot token'>.</span><span class='add_row identifier id'>add_row</span> <span class='symbol val'>:values</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='lbrack token'>[</span><span class='string val'>"Least Popular Pets"</span><span class='rbrack token'>]</span> -<span class='ws identifier id'>ws</span><span class='dot token'>.</span><span class='add_row identifier id'>add_row</span> <span class='symbol val'>:values</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='lbrack token'>[</span><span class='string val'>""</span><span class='comma token'>,</span> <span class='string val'>"Dry Skinned Reptiles"</span><span class='comma token'>,</span> <span class='string val'>"Bald Cats"</span><span class='comma token'>,</span> <span class='string val'>"Violent Parrots"</span><span class='rbrack token'>]</span><span class='comma token'>,</span> <span class='symbol val'>:style=</span><span class='gt op'>></span><span class='title identifier id'>title</span> -<span class='ws identifier id'>ws</span><span class='dot token'>.</span><span class='add_row identifier id'>add_row</span> <span class='symbol val'>:values</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='lbrack token'>[</span><span class='string val'>"Votes"</span><span class='comma token'>,</span> <span class='integer val'>6</span><span class='comma token'>,</span> <span class='integer val'>4</span><span class='comma token'>,</span> <span class='integer val'>1</span><span class='rbrack token'>]</span><span class='comma token'>,</span> <span class='symbol val'>:style=</span><span class='gt op'>></span><span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='STYLE_THIN_BORDER constant id'>STYLE_THIN_BORDER</span> -<span class='f identifier id'>f</span> <span class='assign token'>=</span> <span class='File constant id'>File</span><span class='dot token'>.</span><span class='open identifier id'>open</span><span class='lparen token'>(</span><span class='string val'>'example_you_got_style.xlsx'</span><span class='comma token'>,</span> <span class='string val'>'w'</span><span class='rparen token'>)</span> -<span class='p identifier id'>p</span><span class='dot token'>.</span><span class='serialize identifier id'>serialize</span><span class='lparen token'>(</span><span class='f identifier id'>f</span><span class='rparen token'>)</span> -</pre> +ws.add_row :values => ["Least Popular Pets"] +ws.add_row :values => ["", "Dry Skinned Reptiles", "Bald Cats", "Violent Parrots"], :style=>title +ws.add_row :values => ["Votes", 6, 4, 1], :style=>Axlsx::STYLE_THIN_BORDER +f = File.open('example_you_got_style.xlsx', 'w') +p.serialize(f)</pre> - <h4><div class='inline'><p> -Styling specifically -</p> + <h4><div class='inline'> +<p>Styling specifically</p> </div></h4> - <pre class="example code"><span class='comment val'># an example of applying specific styles to specific cells</span> -<span class='require identifier id'>require</span> <span class='string val'>"rubygems"</span> <span class='comment val'># if that is your preferred way to manage gems!</span> -<span class='require identifier id'>require</span> <span class='string val'>"axlsx"</span> - -<span class='p identifier id'>p</span> <span class='assign token'>=</span> <span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='Package constant id'>Package</span><span class='dot token'>.</span><span class='new identifier id'>new</span> -<span class='ws identifier id'>ws</span> <span class='assign token'>=</span> <span class='p identifier id'>p</span><span class='dot token'>.</span><span class='workbook identifier id'>workbook</span><span class='dot token'>.</span><span class='add_worksheet identifier id'>add_worksheet</span> - -<span class='comment val'># define your styles</span> -<span class='title identifier id'>title</span> <span class='assign token'>=</span> <span class='ws identifier id'>ws</span><span class='dot token'>.</span><span class='style identifier id'>style</span><span class='dot token'>.</span><span class='add_style identifier id'>add_style</span><span class='lparen token'>(</span><span class='symbol val'>:bg_color</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='string val'>"FFFF0000"</span><span class='comma token'>,</span> - <span class='symbol val'>:fg_color=</span><span class='gt op'>></span><span class='string val'>"#FF000000"</span><span class='comma token'>,</span> - <span class='symbol val'>:border=</span><span class='gt op'>></span><span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='STYLE_THIN_BORDER constant id'>STYLE_THIN_BORDER</span><span class='comma token'>,</span> - <span class='symbol val'>:alignment=</span><span class='gt op'>></span><span class='lbrace token'>{</span><span class='symbol val'>:horizontal</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='symbol val'>:center</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> - -<span class='date_time identifier id'>date_time</span> <span class='assign token'>=</span> <span class='ws identifier id'>ws</span><span class='dot token'>.</span><span class='style identifier id'>style</span><span class='dot token'>.</span><span class='add_style identifier id'>add_style</span><span class='lparen token'>(</span><span class='symbol val'>:num_fmt</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='NUM_FMT_YYYYMMDDHHMMSS constant id'>NUM_FMT_YYYYMMDDHHMMSS</span><span class='comma token'>,</span> - <span class='symbol val'>:border=</span><span class='gt op'>></span><span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='STYLE_THIN_BORDER constant id'>STYLE_THIN_BORDER</span><span class='rparen token'>)</span> - -<span class='percent identifier id'>percent</span> <span class='assign token'>=</span> <span class='ws identifier id'>ws</span><span class='dot token'>.</span><span class='style identifier id'>style</span><span class='dot token'>.</span><span class='add_style identifier id'>add_style</span><span class='lparen token'>(</span><span class='symbol val'>:num_fmt</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='NUM_FMT_PERCENT constant id'>NUM_FMT_PERCENT</span><span class='comma token'>,</span> - <span class='symbol val'>:border=</span><span class='gt op'>></span><span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='STYLE_THIN_BORDER constant id'>STYLE_THIN_BORDER</span><span class='rparen token'>)</span> - -<span class='currency identifier id'>currency</span> <span class='assign token'>=</span> <span class='ws identifier id'>ws</span><span class='dot token'>.</span><span class='style identifier id'>style</span><span class='dot token'>.</span><span class='add_style identifier id'>add_style</span><span class='lparen token'>(</span><span class='symbol val'>:format_code=</span><span class='gt op'>></span><span class='string val'>"¥#,##0;[Red]¥-#,##0"</span><span class='comma token'>,</span> - <span class='symbol val'>:border=</span><span class='gt op'>></span><span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='STYLE_THIN_BORDER constant id'>STYLE_THIN_BORDER</span><span class='rparen token'>)</span> - -<span class='comment val'># build your rows</span> -<span class='ws identifier id'>ws</span><span class='dot token'>.</span><span class='add_row identifier id'>add_row</span> <span class='symbol val'>:values</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='lbrack token'>[</span><span class='string val'>"Genreated At:"</span><span class='comma token'>,</span> <span class='Time constant id'>Time</span><span class='dot token'>.</span><span class='now identifier id'>now</span><span class='rbrack token'>]</span><span class='comma token'>,</span> <span class='symbol val'>:styles=</span><span class='gt op'>></span><span class='lbrack token'>[</span><span class='nil nil kw'>nil</span><span class='comma token'>,</span> <span class='date_time identifier id'>date_time</span><span class='rbrack token'>]</span> -<span class='ws identifier id'>ws</span><span class='dot token'>.</span><span class='add_row identifier id'>add_row</span> <span class='symbol val'>:values</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='lbrack token'>[</span><span class='string val'>"Previous Year Quarterly Profits (JPY)"</span><span class='rbrack token'>]</span><span class='comma token'>,</span> <span class='symbol val'>:style=</span><span class='gt op'>></span><span class='title identifier id'>title</span> -<span class='ws identifier id'>ws</span><span class='dot token'>.</span><span class='add_row identifier id'>add_row</span> <span class='symbol val'>:values</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='lbrack token'>[</span><span class='string val'>"Quarter"</span><span class='comma token'>,</span> <span class='string val'>"Profit"</span><span class='comma token'>,</span> <span class='string val'>"% of Total"</span><span class='rbrack token'>]</span><span class='comma token'>,</span> <span class='symbol val'>:style=</span><span class='gt op'>></span><span class='title identifier id'>title</span> -<span class='ws identifier id'>ws</span><span class='dot token'>.</span><span class='add_row identifier id'>add_row</span> <span class='symbol val'>:values</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='lbrack token'>[</span><span class='string val'>"Q1"</span><span class='comma token'>,</span> <span class='integer val'>4000</span><span class='comma token'>,</span> <span class='integer val'>40</span><span class='rbrack token'>]</span><span class='comma token'>,</span> <span class='symbol val'>:style=</span><span class='gt op'>></span><span class='lbrack token'>[</span><span class='title identifier id'>title</span><span class='comma token'>,</span> <span class='currency identifier id'>currency</span><span class='comma token'>,</span> <span class='percent identifier id'>percent</span><span class='rbrack token'>]</span> -<span class='ws identifier id'>ws</span><span class='dot token'>.</span><span class='add_row identifier id'>add_row</span> <span class='symbol val'>:values</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='lbrack token'>[</span><span class='string val'>"Q2"</span><span class='comma token'>,</span> <span class='integer val'>3000</span><span class='comma token'>,</span> <span class='integer val'>30</span><span class='rbrack token'>]</span><span class='comma token'>,</span> <span class='symbol val'>:style=</span><span class='gt op'>></span><span class='lbrack token'>[</span><span class='title identifier id'>title</span><span class='comma token'>,</span> <span class='currency identifier id'>currency</span><span class='comma token'>,</span> <span class='percent identifier id'>percent</span><span class='rbrack token'>]</span> -<span class='ws identifier id'>ws</span><span class='dot token'>.</span><span class='add_row identifier id'>add_row</span> <span class='symbol val'>:values</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='lbrack token'>[</span><span class='string val'>"Q3"</span><span class='comma token'>,</span> <span class='integer val'>1000</span><span class='comma token'>,</span> <span class='integer val'>10</span><span class='rbrack token'>]</span><span class='comma token'>,</span> <span class='symbol val'>:style=</span><span class='gt op'>></span><span class='lbrack token'>[</span><span class='title identifier id'>title</span><span class='comma token'>,</span> <span class='currency identifier id'>currency</span><span class='comma token'>,</span> <span class='percent identifier id'>percent</span><span class='rbrack token'>]</span> -<span class='ws identifier id'>ws</span><span class='dot token'>.</span><span class='add_row identifier id'>add_row</span> <span class='symbol val'>:values</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='lbrack token'>[</span><span class='string val'>"Q4"</span><span class='comma token'>,</span> <span class='integer val'>2000</span><span class='comma token'>,</span> <span class='integer val'>20</span><span class='rbrack token'>]</span><span class='comma token'>,</span> <span class='symbol val'>:style=</span><span class='gt op'>></span><span class='lbrack token'>[</span><span class='title identifier id'>title</span><span class='comma token'>,</span> <span class='currency identifier id'>currency</span><span class='comma token'>,</span> <span class='percent identifier id'>percent</span><span class='rbrack token'>]</span> -<span class='f identifier id'>f</span> <span class='assign token'>=</span> <span class='File constant id'>File</span><span class='dot token'>.</span><span class='open identifier id'>open</span><span class='lparen token'>(</span><span class='string val'>'example_you_got_style.xlsx'</span><span class='comma token'>,</span> <span class='string val'>'w'</span><span class='rparen token'>)</span> -<span class='p identifier id'>p</span><span class='dot token'>.</span><span class='serialize identifier id'>serialize</span><span class='lparen token'>(</span><span class='f identifier id'>f</span><span class='rparen token'>)</span> -</pre> + <pre class="example code"><span class='comment'># an example of applying specific styles to specific cells +</span><span class='id require'>require</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>rubygems</span><span class='tstring_end'>"</span></span> <span class='comment'># if that is your preferred way to manage gems! +</span><span class='id require'>require</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>axlsx</span><span class='tstring_end'>"</span></span> + +<span class='id p'>p</span> <span class='op'>=</span> <span class='const'>Axlsx</span><span class='op'>::</span><span class='const'>Package</span><span class='period'>.</span><span class='id new'>new</span> +<span class='id ws'>ws</span> <span class='op'>=</span> <span class='id p'>p</span><span class='period'>.</span><span class='id workbook'>workbook</span><span class='period'>.</span><span class='id add_worksheet'>add_worksheet</span> + +<span class='comment'># define your styles +</span><span class='id title'>title</span> <span class='op'>=</span> <span class='id ws'>ws</span><span class='period'>.</span><span class='id style'>style</span><span class='period'>.</span><span class='id add_style'>add_style</span><span class='lparen'>(</span><span class='symbol'>:bg_color</span> <span class='op'>=></span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>FFFF0000</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> + <span class='symbol'>:fg_color</span><span class='op'>=></span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>#FF000000</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> + <span class='symbol'>:border</span><span class='op'>=></span><span class='const'>Axlsx</span><span class='op'>::</span><span class='const'>STYLE_THIN_BORDER</span><span class='comma'>,</span> + <span class='symbol'>:alignment</span><span class='op'>=></span><span class='lbrace'>{</span><span class='symbol'>:horizontal</span> <span class='op'>=></span> <span class='symbol'>:center</span><span class='rbrace'>}</span><span class='rparen'>)</span> + +<span class='id date_time'>date_time</span> <span class='op'>=</span> <span class='id ws'>ws</span><span class='period'>.</span><span class='id style'>style</span><span class='period'>.</span><span class='id add_style'>add_style</span><span class='lparen'>(</span><span class='symbol'>:num_fmt</span> <span class='op'>=></span> <span class='const'>Axlsx</span><span class='op'>::</span><span class='const'>NUM_FMT_YYYYMMDDHHMMSS</span><span class='comma'>,</span> + <span class='symbol'>:border</span><span class='op'>=></span><span class='const'>Axlsx</span><span class='op'>::</span><span class='const'>STYLE_THIN_BORDER</span><span class='rparen'>)</span> + +<span class='id percent'>percent</span> <span class='op'>=</span> <span class='id ws'>ws</span><span class='period'>.</span><span class='id style'>style</span><span class='period'>.</span><span class='id add_style'>add_style</span><span class='lparen'>(</span><span class='symbol'>:num_fmt</span> <span class='op'>=></span> <span class='const'>Axlsx</span><span class='op'>::</span><span class='const'>NUM_FMT_PERCENT</span><span class='comma'>,</span> + <span class='symbol'>:border</span><span class='op'>=></span><span class='const'>Axlsx</span><span class='op'>::</span><span class='const'>STYLE_THIN_BORDER</span><span class='rparen'>)</span> + +<span class='id currency'>currency</span> <span class='op'>=</span> <span class='id ws'>ws</span><span class='period'>.</span><span class='id style'>style</span><span class='period'>.</span><span class='id add_style'>add_style</span><span class='lparen'>(</span><span class='symbol'>:format_code</span><span class='op'>=></span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>¥#,##0;[Red]¥-#,##0</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> + <span class='symbol'>:border</span><span class='op'>=></span><span class='const'>Axlsx</span><span class='op'>::</span><span class='const'>STYLE_THIN_BORDER</span><span class='rparen'>)</span> + +<span class='comment'># build your rows +</span><span class='id ws'>ws</span><span class='period'>.</span><span class='id add_row'>add_row</span> <span class='symbol'>:values</span> <span class='op'>=></span> <span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Genreated At:</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='const'>Time</span><span class='period'>.</span><span class='id now'>now</span><span class='rbracket'>]</span><span class='comma'>,</span> <span class='symbol'>:styles</span><span class='op'>=></span><span class='lbracket'>[</span><span class='kw'>nil</span><span class='comma'>,</span> <span class='id date_time'>date_time</span><span class='rbracket'>]</span> +<span class='id ws'>ws</span><span class='period'>.</span><span class='id add_row'>add_row</span> <span class='symbol'>:values</span> <span class='op'>=></span> <span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Previous Year Quarterly Profits (JPY)</span><span class='tstring_end'>"</span></span><span class='rbracket'>]</span><span class='comma'>,</span> <span class='symbol'>:style</span><span class='op'>=></span><span class='id title'>title</span> +<span class='id ws'>ws</span><span class='period'>.</span><span class='id add_row'>add_row</span> <span class='symbol'>:values</span> <span class='op'>=></span> <span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Quarter</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Profit</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>% of Total</span><span class='tstring_end'>"</span></span><span class='rbracket'>]</span><span class='comma'>,</span> <span class='symbol'>:style</span><span class='op'>=></span><span class='id title'>title</span> +<span class='id ws'>ws</span><span class='period'>.</span><span class='id add_row'>add_row</span> <span class='symbol'>:values</span> <span class='op'>=></span> <span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Q1</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='int'>4000</span><span class='comma'>,</span> <span class='int'>40</span><span class='rbracket'>]</span><span class='comma'>,</span> <span class='symbol'>:style</span><span class='op'>=></span><span class='lbracket'>[</span><span class='id title'>title</span><span class='comma'>,</span> <span class='id currency'>currency</span><span class='comma'>,</span> <span class='id percent'>percent</span><span class='rbracket'>]</span> +<span class='id ws'>ws</span><span class='period'>.</span><span class='id add_row'>add_row</span> <span class='symbol'>:values</span> <span class='op'>=></span> <span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Q2</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='int'>3000</span><span class='comma'>,</span> <span class='int'>30</span><span class='rbracket'>]</span><span class='comma'>,</span> <span class='symbol'>:style</span><span class='op'>=></span><span class='lbracket'>[</span><span class='id title'>title</span><span class='comma'>,</span> <span class='id currency'>currency</span><span class='comma'>,</span> <span class='id percent'>percent</span><span class='rbracket'>]</span> +<span class='id ws'>ws</span><span class='period'>.</span><span class='id add_row'>add_row</span> <span class='symbol'>:values</span> <span class='op'>=></span> <span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Q3</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='int'>1000</span><span class='comma'>,</span> <span class='int'>10</span><span class='rbracket'>]</span><span class='comma'>,</span> <span class='symbol'>:style</span><span class='op'>=></span><span class='lbracket'>[</span><span class='id title'>title</span><span class='comma'>,</span> <span class='id currency'>currency</span><span class='comma'>,</span> <span class='id percent'>percent</span><span class='rbracket'>]</span> +<span class='id ws'>ws</span><span class='period'>.</span><span class='id add_row'>add_row</span> <span class='symbol'>:values</span> <span class='op'>=></span> <span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Q4</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='int'>2000</span><span class='comma'>,</span> <span class='int'>20</span><span class='rbracket'>]</span><span class='comma'>,</span> <span class='symbol'>:style</span><span class='op'>=></span><span class='lbracket'>[</span><span class='id title'>title</span><span class='comma'>,</span> <span class='id currency'>currency</span><span class='comma'>,</span> <span class='id percent'>percent</span><span class='rbracket'>]</span> +<span class='id f'>f</span> <span class='op'>=</span> <span class='const'>File</span><span class='period'>.</span><span class='id open'>open</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>example_you_got_style.xlsx</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>w</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> +<span class='id p'>p</span><span class='period'>.</span><span class='id serialize'>serialize</span><span class='lparen'>(</span><span class='id f'>f</span><span class='rparen'>)</span></pre> </div> <h3>Parameters:</h3> @@ -1322,9 +1273,8 @@ Styling specifically — - <div class='inline'><p> -a customizable set of options -</p> + <div class='inline'> +<p>a customizable set of options</p> </div> </li> @@ -1343,9 +1293,8 @@ a customizable set of options <span class="default"> </span> - — <div class='inline'><p> -The text color -</p> + — <div class='inline'> +<p>The text color</p> </div> </li> @@ -1355,9 +1304,8 @@ The text color <span class="default"> </span> - — <div class='inline'><p> -The text size -</p> + — <div class='inline'> +<p>The text size</p> </div> </li> @@ -1367,9 +1315,8 @@ The text size <span class="default"> </span> - — <div class='inline'><p> -Indicates if the text should be bold -</p> + — <div class='inline'> +<p>Indicates if the text should be bold</p> </div> </li> @@ -1379,9 +1326,8 @@ Indicates if the text should be bold <span class="default"> </span> - — <div class='inline'><p> -Indicates if the text should be italicised -</p> + — <div class='inline'> +<p>Indicates if the text should be italicised</p> </div> </li> @@ -1391,9 +1337,8 @@ Indicates if the text should be italicised <span class="default"> </span> - — <div class='inline'><p> -Indicates if the text should be rendered with a strikethrough -</p> + — <div class='inline'> +<p>Indicates if the text should be rendered with a strikethrough</p> </div> </li> @@ -1403,9 +1348,8 @@ Indicates if the text should be rendered with a strikethrough <span class="default"> </span> - — <div class='inline'><p> -Indicates if the text should be rendered with a shadow -</p> + — <div class='inline'> +<p>Indicates if the text should be rendered with a shadow</p> </div> </li> @@ -1415,9 +1359,8 @@ Indicates if the text should be rendered with a shadow <span class="default"> </span> - — <div class='inline'><p> -The character set to use. -</p> + — <div class='inline'> +<p>The character set to use.</p> </div> </li> @@ -1427,9 +1370,8 @@ The character set to use. <span class="default"> </span> - — <div class='inline'><p> -The font family to use. -</p> + — <div class='inline'> +<p>The font family to use.</p> </div> </li> @@ -1439,9 +1381,8 @@ The font family to use. <span class="default"> </span> - — <div class='inline'><p> -The name of the font to use -</p> + — <div class='inline'> +<p>The name of the font to use</p> </div> </li> @@ -1451,9 +1392,8 @@ The name of the font to use <span class="default"> </span> - — <div class='inline'><p> -The number format to apply -</p> + — <div class='inline'> +<p>The number format to apply</p> </div> </li> @@ -1463,9 +1403,8 @@ The number format to apply <span class="default"> </span> - — <div class='inline'><p> -The formatting to apply. If this is specified, num_fmt is ignored. -</p> + — <div class='inline'> +<p>The formatting to apply. If this is specified, num_fmt is ignored.</p> </div> </li> @@ -1475,9 +1414,8 @@ The formatting to apply. If this is specified, num_fmt is ignored. <span class="default"> </span> - — <div class='inline'><p> -The border style to use. -</p> + — <div class='inline'> +<p>The border style to use.</p> </div> </li> @@ -1487,9 +1425,8 @@ The border style to use. <span class="default"> </span> - — <div class='inline'><p> -The background color to apply to the cell -</p> + — <div class='inline'> +<p>The background color to apply to the cell</p> </div> </li> @@ -1499,9 +1436,8 @@ The background color to apply to the cell <span class="default"> </span> - — <div class='inline'><p> -Indicates if the cell should be hidden -</p> + — <div class='inline'> +<p>Indicates if the cell should be hidden</p> </div> </li> @@ -1511,9 +1447,8 @@ Indicates if the cell should be hidden <span class="default"> </span> - — <div class='inline'><p> -Indicates if the cell should be locked -</p> + — <div class='inline'> +<p>Indicates if the cell should be locked</p> </div> </li> @@ -1523,9 +1458,8 @@ Indicates if the cell should be locked <span class="default"> </span> - — <div class='inline'><p> -A hash defining any of the attributes used in CellAlignment -</p> + — <div class='inline'> +<p>A hash defining any of the attributes used in CellAlignment</p> </div> </li> @@ -1621,52 +1555,51 @@ A hash defining any of the attributes used in CellAlignment <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/styles.rb', line 191</span> -<span class='def def kw'>def</span> <span class='add_style identifier id'>add_style</span><span class='lparen token'>(</span><span class='options identifier id'>options</span><span class='assign token'>=</span><span class='lbrace token'>{</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> - - <span class='numFmtId identifier id'>numFmtId</span> <span class='assign token'>=</span> <span class='if if kw'>if</span> <span class='options identifier id'>options</span><span class='lbrack token'>[</span><span class='symbol val'>:format_code</span><span class='rbrack token'>]</span> - <span class='n identifier id'>n</span> <span class='assign token'>=</span> <span class='@numFmts ivar id'>@numFmts</span><span class='dot token'>.</span><span class='map identifier id'>map</span><span class='lbrace token'>{</span> <span class='bitor op'>|</span><span class='f identifier id'>f</span><span class='bitor op'>|</span> <span class='f identifier id'>f</span><span class='dot token'>.</span><span class='numFmtId identifier id'>numFmtId</span> <span class='rbrace token'>}</span><span class='dot token'>.</span><span class='max identifier id'>max</span> <span class='plus op'>+</span> <span class='integer val'>1</span> - <span class='numFmts identifier id'>numFmts</span> <span class='lshft op'><<</span> <span class='NumFmt constant id'>NumFmt</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='symbol val'>:numFmtId</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='n identifier id'>n</span><span class='comma token'>,</span> <span class='symbol val'>:formatCode=</span><span class='gt op'>></span> <span class='options identifier id'>options</span><span class='lbrack token'>[</span><span class='symbol val'>:format_code</span><span class='rbrack token'>]</span><span class='rparen token'>)</span> - <span class='n identifier id'>n</span> - <span class='else else kw'>else</span> - <span class='options identifier id'>options</span><span class='lbrack token'>[</span><span class='symbol val'>:num_fmt</span><span class='rbrack token'>]</span> <span class='orop op'>||</span> <span class='integer val'>0</span> - <span class='end end kw'>end</span> - - <span class='borderId identifier id'>borderId</span> <span class='assign token'>=</span> <span class='options identifier id'>options</span><span class='lbrack token'>[</span><span class='symbol val'>:border</span><span class='rbrack token'>]</span> <span class='orop op'>||</span> <span class='integer val'>0</span> - <span class='raise identifier id'>raise</span> <span class='ArgumentError constant id'>ArgumentError</span><span class='comma token'>,</span> <span class='string val'>"Invalid borderId"</span> <span class='unless unless_mod kw'>unless</span> <span class='borderId identifier id'>borderId</span> <span class='lt op'><</span> <span class='borders identifier id'>borders</span><span class='dot token'>.</span><span class='size identifier id'>size</span> - - <span class='fill identifier id'>fill</span> <span class='assign token'>=</span> <span class='if if kw'>if</span> <span class='options identifier id'>options</span><span class='lbrack token'>[</span><span class='symbol val'>:bg_color</span><span class='rbrack token'>]</span> - <span class='color identifier id'>color</span> <span class='assign token'>=</span> <span class='Color constant id'>Color</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='symbol val'>:rgb=</span><span class='gt op'>></span><span class='options identifier id'>options</span><span class='lbrack token'>[</span><span class='symbol val'>:bg_color</span><span class='rbrack token'>]</span><span class='rparen token'>)</span> - <span class='pattern identifier id'>pattern</span> <span class='assign token'>=</span> <span class='PatternFill constant id'>PatternFill</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='symbol val'>:patternType</span> <span class='assign token'>=</span><span class='gt op'>></span><span class='symbol val'>:solid</span><span class='comma token'>,</span> <span class='symbol val'>:fgColor=</span><span class='gt op'>></span><span class='color identifier id'>color</span><span class='rparen token'>)</span> - <span class='fills identifier id'>fills</span> <span class='lshft op'><<</span> <span class='Fill constant id'>Fill</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='pattern identifier id'>pattern</span><span class='rparen token'>)</span> - <span class='else else kw'>else</span> - <span class='integer val'>0</span> - <span class='end end kw'>end</span> - - <span class='fontId identifier id'>fontId</span> <span class='assign token'>=</span> <span class='if if kw'>if</span> <span class='lparen token'>(</span><span class='options identifier id'>options</span><span class='dot token'>.</span><span class='values_at identifier id'>values_at</span><span class='lparen token'>(</span><span class='symbol val'>:fg_color</span><span class='comma token'>,</span> <span class='symbol val'>:sz</span><span class='comma token'>,</span> <span class='symbol val'>:b</span><span class='comma token'>,</span> <span class='symbol val'>:i</span><span class='comma token'>,</span> <span class='symbol val'>:strike</span><span class='comma token'>,</span> <span class='symbol val'>:outline</span><span class='comma token'>,</span> <span class='symbol val'>:shadow</span><span class='comma token'>,</span> <span class='symbol val'>:charset</span><span class='comma token'>,</span> <span class='symbol val'>:family</span><span class='comma token'>,</span> <span class='symbol val'>:font_name</span><span class='rparen token'>)</span><span class='dot token'>.</span><span class='length identifier id'>length</span><span class='rparen token'>)</span> - <span class='font identifier id'>font</span> <span class='assign token'>=</span> <span class='Font constant id'>Font</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='rparen token'>)</span> - <span class='lbrack token'>[</span><span class='symbol val'>:b</span><span class='comma token'>,</span> <span class='symbol val'>:i</span><span class='comma token'>,</span> <span class='symbol val'>:strike</span><span class='comma token'>,</span> <span class='symbol val'>:outline</span><span class='comma token'>,</span> <span class='symbol val'>:shadow</span><span class='comma token'>,</span> <span class='symbol val'>:charset</span><span class='comma token'>,</span> <span class='symbol val'>:family</span><span class='comma token'>,</span> <span class='symbol val'>:sz</span><span class='rbrack token'>]</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='lbrace token'>{</span> <span class='bitor op'>|</span><span class='k identifier id'>k</span><span class='bitor op'>|</span> <span class='font identifier id'>font</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='dstring node'>"#{k}="</span><span class='comma token'>,</span> <span class='options identifier id'>options</span><span class='lbrack token'>[</span><span class='k identifier id'>k</span><span class='rbrack token'>]</span><span class='rparen token'>)</span> <span class='unless unless_mod kw'>unless</span> <span class='options identifier id'>options</span><span class='lbrack token'>[</span><span class='k identifier id'>k</span><span class='rbrack token'>]</span><span class='dot token'>.</span><span class='nil? fid id'>nil?</span> <span class='rbrace token'>}</span> - <span class='font identifier id'>font</span><span class='dot token'>.</span><span class='color identifier id'>color</span> <span class='assign token'>=</span> <span class='Color constant id'>Color</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='symbol val'>:rgb</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='options identifier id'>options</span><span class='lbrack token'>[</span><span class='symbol val'>:fg_color</span><span class='rbrack token'>]</span><span class='rparen token'>)</span> <span class='unless unless_mod kw'>unless</span> <span class='options identifier id'>options</span><span class='lbrack token'>[</span><span class='symbol val'>:fg_color</span><span class='rbrack token'>]</span><span class='dot token'>.</span><span class='nil? fid id'>nil?</span> - <span class='font identifier id'>font</span><span class='dot token'>.</span><span class='name identifier id'>name</span> <span class='assign token'>=</span> <span class='options identifier id'>options</span><span class='lbrack token'>[</span><span class='symbol val'>:font_name</span><span class='rbrack token'>]</span> <span class='unless unless_mod kw'>unless</span> <span class='options identifier id'>options</span><span class='lbrack token'>[</span><span class='symbol val'>:font_name</span><span class='rbrack token'>]</span><span class='dot token'>.</span><span class='nil? fid id'>nil?</span> - <span class='fonts identifier id'>fonts</span> <span class='lshft op'><<</span> <span class='font identifier id'>font</span> - <span class='else else kw'>else</span> - <span class='integer val'>0</span> - <span class='end end kw'>end</span> - - <span class='applyProtection identifier id'>applyProtection</span> <span class='assign token'>=</span> <span class='lparen token'>(</span><span class='options identifier id'>options</span><span class='lbrack token'>[</span><span class='symbol val'>:hidden</span><span class='rbrack token'>]</span> <span class='orop op'>||</span> <span class='options identifier id'>options</span><span class='lbrack token'>[</span><span class='symbol val'>:locked</span><span class='rbrack token'>]</span><span class='rparen token'>)</span> <span class='question op'>?</span> <span class='integer val'>1</span> <span class='colon op'>:</span> <span class='integer val'>0</span> - - <span class='xf identifier id'>xf</span> <span class='assign token'>=</span> <span class='Xf constant id'>Xf</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='symbol val'>:fillId</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='fill identifier id'>fill</span><span class='comma token'>,</span> <span class='symbol val'>:fontId=</span><span class='gt op'>></span><span class='fontId identifier id'>fontId</span><span class='comma token'>,</span> <span class='symbol val'>:applyFill=</span><span class='gt op'>></span><span class='integer val'>1</span><span class='comma token'>,</span> <span class='symbol val'>:applyFont=</span><span class='gt op'>></span><span class='integer val'>1</span><span class='comma token'>,</span> <span class='symbol val'>:numFmtId=</span><span class='gt op'>></span><span class='numFmtId identifier id'>numFmtId</span><span class='comma token'>,</span> <span class='symbol val'>:borderId=</span><span class='gt op'>></span><span class='borderId identifier id'>borderId</span><span class='comma token'>,</span> <span class='symbol val'>:applyProtection=</span><span class='gt op'>></span><span class='applyProtection identifier id'>applyProtection</span><span class='rparen token'>)</span> - - <span class='if if kw'>if</span> <span class='options identifier id'>options</span><span class='lbrack token'>[</span><span class='symbol val'>:alignment</span><span class='rbrack token'>]</span> - <span class='xf identifier id'>xf</span><span class='dot token'>.</span><span class='alignment identifier id'>alignment</span> <span class='assign token'>=</span> <span class='CellAlignment constant id'>CellAlignment</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='options identifier id'>options</span><span class='lbrack token'>[</span><span class='symbol val'>:alignment</span><span class='rbrack token'>]</span><span class='rparen token'>)</span> - <span class='end end kw'>end</span> - - <span class='if if kw'>if</span> <span class='applyProtection identifier id'>applyProtection</span> - <span class='xf identifier id'>xf</span><span class='dot token'>.</span><span class='protection identifier id'>protection</span> <span class='assign token'>=</span> <span class='CellProtection constant id'>CellProtection</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='options identifier id'>options</span><span class='rparen token'>)</span> - <span class='end end kw'>end</span> - - <span class='cellXfs identifier id'>cellXfs</span> <span class='lshft op'><<</span> <span class='xf identifier id'>xf</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id add_style'>add_style</span><span class='lparen'>(</span><span class='id options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span> + + <span class='id numFmtId'>numFmtId</span> <span class='op'>=</span> <span class='kw'>if</span> <span class='id options'>options</span><span class='lbracket'>[</span><span class='symbol'>:format_code</span><span class='rbracket'>]</span> + <span class='id n'>n</span> <span class='op'>=</span> <span class='ivar'>@numFmts</span><span class='period'>.</span><span class='id map'>map</span><span class='lbrace'>{</span> <span class='op'>|</span><span class='id f'>f</span><span class='op'>|</span> <span class='id f'>f</span><span class='period'>.</span><span class='id numFmtId'>numFmtId</span> <span class='rbrace'>}</span><span class='period'>.</span><span class='id max'>max</span> <span class='op'>+</span> <span class='int'>1</span> + <span class='id numFmts'>numFmts</span> <span class='op'><<</span> <span class='const'>NumFmt</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='symbol'>:numFmtId</span> <span class='op'>=></span> <span class='id n'>n</span><span class='comma'>,</span> <span class='symbol'>:formatCode</span><span class='op'>=></span> <span class='id options'>options</span><span class='lbracket'>[</span><span class='symbol'>:format_code</span><span class='rbracket'>]</span><span class='rparen'>)</span> + <span class='id n'>n</span> + <span class='kw'>else</span> + <span class='id options'>options</span><span class='lbracket'>[</span><span class='symbol'>:num_fmt</span><span class='rbracket'>]</span> <span class='op'>||</span> <span class='int'>0</span> + <span class='kw'>end</span> + + <span class='id borderId'>borderId</span> <span class='op'>=</span> <span class='id options'>options</span><span class='lbracket'>[</span><span class='symbol'>:border</span><span class='rbracket'>]</span> <span class='op'>||</span> <span class='int'>0</span> + <span class='id raise'>raise</span> <span class='const'>ArgumentError</span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Invalid borderId</span><span class='tstring_end'>"</span></span> <span class='kw'>unless</span> <span class='id borderId'>borderId</span> <span class='op'><</span> <span class='id borders'>borders</span><span class='period'>.</span><span class='id size'>size</span> + + <span class='id fill'>fill</span> <span class='op'>=</span> <span class='kw'>if</span> <span class='id options'>options</span><span class='lbracket'>[</span><span class='symbol'>:bg_color</span><span class='rbracket'>]</span> + <span class='id color'>color</span> <span class='op'>=</span> <span class='const'>Color</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='symbol'>:rgb</span><span class='op'>=></span><span class='id options'>options</span><span class='lbracket'>[</span><span class='symbol'>:bg_color</span><span class='rbracket'>]</span><span class='rparen'>)</span> + <span class='id pattern'>pattern</span> <span class='op'>=</span> <span class='const'>PatternFill</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='symbol'>:patternType</span> <span class='op'>=></span><span class='symbol'>:solid</span><span class='comma'>,</span> <span class='symbol'>:fgColor</span><span class='op'>=></span><span class='id color'>color</span><span class='rparen'>)</span> + <span class='id fills'>fills</span> <span class='op'><<</span> <span class='const'>Fill</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='id pattern'>pattern</span><span class='rparen'>)</span> + <span class='kw'>else</span> + <span class='int'>0</span> + <span class='kw'>end</span> + + <span class='id fontId'>fontId</span> <span class='op'>=</span> <span class='kw'>if</span> <span class='lparen'>(</span><span class='id options'>options</span><span class='period'>.</span><span class='id values_at'>values_at</span><span class='lparen'>(</span><span class='symbol'>:fg_color</span><span class='comma'>,</span> <span class='symbol'>:sz</span><span class='comma'>,</span> <span class='symbol'>:b</span><span class='comma'>,</span> <span class='symbol'>:i</span><span class='comma'>,</span> <span class='symbol'>:strike</span><span class='comma'>,</span> <span class='symbol'>:outline</span><span class='comma'>,</span> <span class='symbol'>:shadow</span><span class='comma'>,</span> <span class='symbol'>:charset</span><span class='comma'>,</span> <span class='symbol'>:family</span><span class='comma'>,</span> <span class='symbol'>:font_name</span><span class='rparen'>)</span><span class='period'>.</span><span class='id length'>length</span><span class='rparen'>)</span> + <span class='id font'>font</span> <span class='op'>=</span> <span class='const'>Font</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='rparen'>)</span> + <span class='lbracket'>[</span><span class='symbol'>:b</span><span class='comma'>,</span> <span class='symbol'>:i</span><span class='comma'>,</span> <span class='symbol'>:strike</span><span class='comma'>,</span> <span class='symbol'>:outline</span><span class='comma'>,</span> <span class='symbol'>:shadow</span><span class='comma'>,</span> <span class='symbol'>:charset</span><span class='comma'>,</span> <span class='symbol'>:family</span><span class='comma'>,</span> <span class='symbol'>:sz</span><span class='rbracket'>]</span><span class='period'>.</span><span class='id each'>each</span> <span class='lbrace'>{</span> <span class='op'>|</span><span class='id k'>k</span><span class='op'>|</span> <span class='id font'>font</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='id k'>k</span><span class='rbrace'>}</span><span class='tstring_content'>=</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='id options'>options</span><span class='lbracket'>[</span><span class='id k'>k</span><span class='rbracket'>]</span><span class='rparen'>)</span> <span class='kw'>unless</span> <span class='id options'>options</span><span class='lbracket'>[</span><span class='id k'>k</span><span class='rbracket'>]</span><span class='period'>.</span><span class='id nil?'>nil?</span> <span class='rbrace'>}</span> + <span class='id font'>font</span><span class='period'>.</span><span class='id color'>color</span> <span class='op'>=</span> <span class='const'>Color</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='symbol'>:rgb</span> <span class='op'>=></span> <span class='id options'>options</span><span class='lbracket'>[</span><span class='symbol'>:fg_color</span><span class='rbracket'>]</span><span class='rparen'>)</span> <span class='kw'>unless</span> <span class='id options'>options</span><span class='lbracket'>[</span><span class='symbol'>:fg_color</span><span class='rbracket'>]</span><span class='period'>.</span><span class='id nil?'>nil?</span> + <span class='id font'>font</span><span class='period'>.</span><span class='id name'>name</span> <span class='op'>=</span> <span class='id options'>options</span><span class='lbracket'>[</span><span class='symbol'>:font_name</span><span class='rbracket'>]</span> <span class='kw'>unless</span> <span class='id options'>options</span><span class='lbracket'>[</span><span class='symbol'>:font_name</span><span class='rbracket'>]</span><span class='period'>.</span><span class='id nil?'>nil?</span> + <span class='id fonts'>fonts</span> <span class='op'><<</span> <span class='id font'>font</span> + <span class='kw'>else</span> + <span class='int'>0</span> + <span class='kw'>end</span> + + <span class='id applyProtection'>applyProtection</span> <span class='op'>=</span> <span class='lparen'>(</span><span class='id options'>options</span><span class='lbracket'>[</span><span class='symbol'>:hidden</span><span class='rbracket'>]</span> <span class='op'>||</span> <span class='id options'>options</span><span class='lbracket'>[</span><span class='symbol'>:locked</span><span class='rbracket'>]</span><span class='rparen'>)</span> <span class='op'>?</span> <span class='int'>1</span> <span class='op'>:</span> <span class='int'>0</span> + + <span class='id xf'>xf</span> <span class='op'>=</span> <span class='const'>Xf</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='symbol'>:fillId</span> <span class='op'>=></span> <span class='id fill'>fill</span><span class='comma'>,</span> <span class='symbol'>:fontId</span><span class='op'>=></span><span class='id fontId'>fontId</span><span class='comma'>,</span> <span class='symbol'>:applyFill</span><span class='op'>=></span><span class='int'>1</span><span class='comma'>,</span> <span class='symbol'>:applyFont</span><span class='op'>=></span><span class='int'>1</span><span class='comma'>,</span> <span class='symbol'>:numFmtId</span><span class='op'>=></span><span class='id numFmtId'>numFmtId</span><span class='comma'>,</span> <span class='symbol'>:borderId</span><span class='op'>=></span><span class='id borderId'>borderId</span><span class='comma'>,</span> <span class='symbol'>:applyProtection</span><span class='op'>=></span><span class='id applyProtection'>applyProtection</span><span class='rparen'>)</span> + + <span class='kw'>if</span> <span class='id options'>options</span><span class='lbracket'>[</span><span class='symbol'>:alignment</span><span class='rbracket'>]</span> + <span class='id xf'>xf</span><span class='period'>.</span><span class='id alignment'>alignment</span> <span class='op'>=</span> <span class='const'>CellAlignment</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='id options'>options</span><span class='lbracket'>[</span><span class='symbol'>:alignment</span><span class='rbracket'>]</span><span class='rparen'>)</span> + <span class='kw'>end</span> + + <span class='kw'>if</span> <span class='id applyProtection'>applyProtection</span> + <span class='id xf'>xf</span><span class='period'>.</span><span class='id protection'>protection</span> <span class='op'>=</span> <span class='const'>CellProtection</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='id options'>options</span><span class='rparen'>)</span> + <span class='kw'>end</span> + + <span class='id cellXfs'>cellXfs</span> <span class='op'><<</span> <span class='id xf'>xf</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1681,9 +1614,8 @@ A hash defining any of the attributes used in CellAlignment </p><div class="docstring"> <div class="discussion"> - <p> -Serializes the styles document -</p> + +<p>Serializes the styles document</p> </div> @@ -1724,17 +1656,16 @@ Serializes the styles document <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/styles.rb', line 239</span> -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='rparen token'>)</span> - <span class='builder identifier id'>builder</span> <span class='assign token'>=</span> <span class='Nokogiri constant id'>Nokogiri</span><span class='colon2 op'>::</span><span class='XML constant id'>XML</span><span class='colon2 op'>::</span><span class='Builder constant id'>Builder</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='symbol val'>:encoding</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='ENCODING constant id'>ENCODING</span><span class='rparen token'>)</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='xml identifier id'>xml</span><span class='bitor op'>|</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='styleSheet identifier id'>styleSheet</span><span class='lparen token'>(</span><span class='symbol val'>:xmlns</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='XML_NS constant id'>XML_NS</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='lbrack token'>[</span><span class='symbol val'>:numFmts</span><span class='comma token'>,</span> <span class='symbol val'>:fonts</span><span class='comma token'>,</span> <span class='symbol val'>:fills</span><span class='comma token'>,</span> <span class='symbol val'>:borders</span><span class='comma token'>,</span> <span class='symbol val'>:cellStyleXfs</span><span class='comma token'>,</span> <span class='symbol val'>:cellXfs</span><span class='comma token'>,</span> <span class='symbol val'>:dxfs</span><span class='comma token'>,</span> <span class='symbol val'>:tableStyles</span><span class='rbrack token'>]</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='key identifier id'>key</span><span class='bitor op'>|</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='instance_values identifier id'>instance_values</span><span class='lbrack token'>[</span><span class='key identifier id'>key</span><span class='dot token'>.</span><span class='to_s identifier id'>to_s</span><span class='rbrack token'>]</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='end end kw'>end</span> - <span class='rbrace token'>}</span> - <span class='end end kw'>end</span> - <span class='builder identifier id'>builder</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='rparen'>)</span> + <span class='id builder'>builder</span> <span class='op'>=</span> <span class='const'>Nokogiri</span><span class='op'>::</span><span class='const'>XML</span><span class='op'>::</span><span class='const'>Builder</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='symbol'>:encoding</span> <span class='op'>=></span> <span class='const'>ENCODING</span><span class='rparen'>)</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id xml'>xml</span><span class='op'>|</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id styleSheet'>styleSheet</span><span class='lparen'>(</span><span class='symbol'>:xmlns</span> <span class='op'>=></span> <span class='const'>XML_NS</span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='lbracket'>[</span><span class='symbol'>:numFmts</span><span class='comma'>,</span> <span class='symbol'>:fonts</span><span class='comma'>,</span> <span class='symbol'>:fills</span><span class='comma'>,</span> <span class='symbol'>:borders</span><span class='comma'>,</span> <span class='symbol'>:cellStyleXfs</span><span class='comma'>,</span> <span class='symbol'>:cellXfs</span><span class='comma'>,</span> <span class='symbol'>:cellStyles</span><span class='comma'>,</span> <span class='symbol'>:dxfs</span><span class='comma'>,</span> <span class='symbol'>:tableStyles</span><span class='rbracket'>]</span><span class='period'>.</span><span class='id each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id key'>key</span><span class='op'>|</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id instance_values'>instance_values</span><span class='lbracket'>[</span><span class='id key'>key</span><span class='period'>.</span><span class='id to_s'>to_s</span><span class='rbracket'>]</span><span class='period'>.</span><span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> + <span class='kw'>end</span> + <span class='rbrace'>}</span> + <span class='kw'>end</span> + <span class='id builder'>builder</span><span class='period'>.</span><span class='id to_xml'>to_xml</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1745,9 +1676,9 @@ Serializes the styles document </div> <div id="footer"> - Generated on Wed Nov 23 22:20:55 2011 by + Generated on Sat Nov 26 13:16:38 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/TableStyle.html b/doc/Axlsx/TableStyle.html index 88399487..1f43f1e9 100644 --- a/doc/Axlsx/TableStyle.html +++ b/doc/Axlsx/TableStyle.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::TableStyle - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -99,16 +99,14 @@ <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -Table are not supported in this version and only the defaults required for -a valid workbook are created. -</p> + <div class='inline'> +<p>Table are not supported in this version and only the defaults required for +a valid workbook are created.</p> </div> </div> -<p> -A single table style definition and is a collection for tableStyleElements -</p> + +<p>A single table style definition and is a collection for tableStyleElements</p> </div> @@ -144,9 +142,8 @@ A single table style definition and is a collection for tableStyleElements - <span class="summary_desc"><div class='inline'><p> -The name of this table style. -</p> + <span class="summary_desc"><div class='inline'> +<p>The name of this table style.</p> </div></span> </li> @@ -171,9 +168,8 @@ The name of this table style. - <span class="summary_desc"><div class='inline'><p> -indicates if this style should be applied to pivot tables. -</p> + <span class="summary_desc"><div class='inline'> +<p>indicates if this style should be applied to pivot tables.</p> </div></span> </li> @@ -198,9 +194,8 @@ indicates if this style should be applied to pivot tables. - <span class="summary_desc"><div class='inline'><p> -indicates if this style should be applied to tables. -</p> + <span class="summary_desc"><div class='inline'> +<p>indicates if this style should be applied to tables.</p> </div></span> </li> @@ -245,9 +240,8 @@ indicates if this style should be applied to tables. - <span class="summary_desc"><div class='inline'><p> -creates a new TableStyle object. -</p> + <span class="summary_desc"><div class='inline'> +<p>creates a new TableStyle object.</p> </div></span> </li> @@ -269,9 +263,8 @@ creates a new TableStyle object. - <span class="summary_desc"><div class='inline'><p> -Serializes the table style. -</p> + <span class="summary_desc"><div class='inline'> +<p>Serializes the table style.</p> </div></span> </li> @@ -285,12 +278,7 @@ Serializes the table style. - - - - <h3 class="inherited">Methods inherited from <span class='object_link'><a href="SimpleTypedList.html" title="Axlsx::SimpleTypedList (class)">SimpleTypedList</a></span></h3> - <p class="inherited"><span class='object_link'><a href="SimpleTypedList.html#%3C%3C-instance_method" title="Axlsx::SimpleTypedList#<< (method)">#<<</a></span>, <span class='object_link'><a href="SimpleTypedList.html#%3D%3D-instance_method" title="Axlsx::SimpleTypedList#== (method)">#==</a></span>, <span class='object_link'><a href="SimpleTypedList.html#%5B%5D%3D-instance_method" title="Axlsx::SimpleTypedList#[]= (method)">#[]=</a></span>, <span class='object_link'><a href="SimpleTypedList.html#delete-instance_method" title="Axlsx::SimpleTypedList#delete (method)">#delete</a></span>, <span class='object_link'><a href="SimpleTypedList.html#delete_at-instance_method" title="Axlsx::SimpleTypedList#delete_at (method)">#delete_at</a></span>, <span class='object_link'><a href="SimpleTypedList.html#lock-instance_method" title="Axlsx::SimpleTypedList#lock (method)">#lock</a></span>, <span class='object_link'><a href="SimpleTypedList.html#method_missing-instance_method" title="Axlsx::SimpleTypedList#method_missing (method)">#method_missing</a></span>, <span class='object_link'><a href="SimpleTypedList.html#protected%3F-instance_method" title="Axlsx::SimpleTypedList#protected? (method)">#protected?</a></span>, <span class='object_link'><a href="SimpleTypedList.html#push-instance_method" title="Axlsx::SimpleTypedList#push (method)">#push</a></span>, <span class='object_link'><a href="SimpleTypedList.html#unlock-instance_method" title="Axlsx::SimpleTypedList#unlock (method)">#unlock</a></span></p> -<div id="constructor_details" class="method_details_list"> + <div id="constructor_details" class="method_details_list"> <h2>Constructor Details</h2> <div class="method_details first"> @@ -302,9 +290,8 @@ Serializes the table style. </p><div class="docstring"> <div class="discussion"> - <p> -creates a new TableStyle object -</p> + +<p>creates a new TableStyle object</p> </div> @@ -336,9 +323,8 @@ creates a new TableStyle object — - <div class='inline'><p> -a customizable set of options -</p> + <div class='inline'> +<p>a customizable set of options</p> </div> </li> @@ -385,9 +371,8 @@ a customizable set of options — - <div class='inline'><p> -if name option is not provided. -</p> + <div class='inline'> +<p>if name option is not provided.</p> </div> </li> @@ -411,14 +396,13 @@ if name option is not provided. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/table_style.rb', line 23</span> -<span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span><span class='lparen token'>(</span><span class='name identifier id'>name</span><span class='comma token'>,</span> <span class='options identifier id'>options</span><span class='assign token'>=</span><span class='lbrace token'>{</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='name identifier id'>name</span> <span class='assign token'>=</span> <span class='name identifier id'>name</span> - <span class='options identifier id'>options</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='o identifier id'>o</span><span class='bitor op'>|</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='dstring node'>"#{o[0]}="</span><span class='comma token'>,</span> <span class='o identifier id'>o</span><span class='lbrack token'>[</span><span class='integer val'>1</span><span class='rbrack token'>]</span><span class='rparen token'>)</span> <span class='if if_mod kw'>if</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='respond_to? fid id'>respond_to?</span> <span class='o identifier id'>o</span><span class='lbrack token'>[</span><span class='integer val'>0</span><span class='rbrack token'>]</span> - <span class='end end kw'>end</span> - <span class='super super kw'>super</span> <span class='TableStyleElement constant id'>TableStyleElement</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id initialize'>initialize</span><span class='lparen'>(</span><span class='id name'>name</span><span class='comma'>,</span> <span class='id options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id name'>name</span> <span class='op'>=</span> <span class='id name'>name</span> + <span class='id options'>options</span><span class='period'>.</span><span class='id each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id o'>o</span><span class='op'>|</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span><span class='rbrace'>}</span><span class='tstring_content'>=</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>1</span><span class='rbracket'>]</span><span class='rparen'>)</span> <span class='kw'>if</span> <span class='kw'>self</span><span class='period'>.</span><span class='id respond_to?'>respond_to?</span> <span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span> + <span class='kw'>end</span> + <span class='kw'>super</span> <span class='const'>TableStyleElement</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -451,9 +435,8 @@ if name option is not provided. </p><div class="docstring"> <div class="discussion"> - <p> -The name of this table style -</p> + +<p>The name of this table style</p> </div> @@ -487,10 +470,9 @@ The name of this table style <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/table_style.rb', line 8</span> -<span class='def def kw'>def</span> <span class='name identifier id'>name</span> - <span class='@name ivar id'>@name</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id name'>name</span> + <span class='ivar'>@name</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -508,9 +490,8 @@ The name of this table style </p><div class="docstring"> <div class="discussion"> - <p> -indicates if this style should be applied to pivot tables -</p> + +<p>indicates if this style should be applied to pivot tables</p> </div> @@ -544,10 +525,9 @@ indicates if this style should be applied to pivot tables <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/table_style.rb', line 12</span> -<span class='def def kw'>def</span> <span class='pivot identifier id'>pivot</span> - <span class='@pivot ivar id'>@pivot</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id pivot'>pivot</span> + <span class='ivar'>@pivot</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -565,9 +545,8 @@ indicates if this style should be applied to pivot tables </p><div class="docstring"> <div class="discussion"> - <p> -indicates if this style should be applied to tables -</p> + +<p>indicates if this style should be applied to tables</p> </div> @@ -601,10 +580,9 @@ indicates if this style should be applied to tables <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/table_style.rb', line 16</span> -<span class='def def kw'>def</span> <span class='table identifier id'>table</span> - <span class='@table ivar id'>@table</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id table'>table</span> + <span class='ivar'>@table</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -626,9 +604,8 @@ indicates if this style should be applied to tables </p><div class="docstring"> <div class="discussion"> - <p> -Serializes the table style -</p> + +<p>Serializes the table style</p> </div> @@ -647,9 +624,8 @@ Serializes the table style — - <div class='inline'><p> -The document builder instance this objects xml will be added to. -</p> + <div class='inline'> +<p>The document builder instance this objects xml will be added to.</p> </div> </li> @@ -676,21 +652,20 @@ The document builder instance this objects xml will be added to. <pre class="lines"> -38 -39 -40 41 -42</pre> +42 +43 +44 +45</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/table_style.rb', line 38</span> - -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='attr identifier id'>attr</span> <span class='assign token'>=</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='instance_values identifier id'>instance_values</span><span class='dot token'>.</span><span class='select identifier id'>select</span> <span class='lbrace token'>{</span> <span class='bitor op'>|</span><span class='k identifier id'>k</span><span class='comma token'>,</span> <span class='v identifier id'>v</span><span class='bitor op'>|</span> <span class='lbrack token'>[</span><span class='symbol val'>:name</span><span class='comma token'>,</span> <span class='symbol val'>:pivot</span><span class='comma token'>,</span> <span class='symbol val'>:table</span><span class='rbrack token'>]</span><span class='dot token'>.</span><span class='include? fid id'>include?</span> <span class='k identifier id'>k</span> <span class='rbrace token'>}</span> - <span class='attr identifier id'>attr</span><span class='lbrack token'>[</span><span class='symbol val'>:count</span><span class='rbrack token'>]</span> <span class='assign token'>=</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='size identifier id'>size</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='tableStyle identifier id'>tableStyle</span><span class='lparen token'>(</span><span class='attr identifier id'>attr</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='lbrace token'>{</span> <span class='bitor op'>|</span><span class='table_style_el identifier id'>table_style_el</span><span class='bitor op'>|</span> <span class='table_style_el identifier id'>table_style_el</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> <span class='rbrace token'>}</span> <span class='rbrace token'>}</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/table_style.rb', line 41</span> + +<span class='kw'>def</span> <span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> + <span class='id attr'>attr</span> <span class='op'>=</span> <span class='kw'>self</span><span class='period'>.</span><span class='id instance_values'>instance_values</span><span class='period'>.</span><span class='id select'>select</span> <span class='lbrace'>{</span> <span class='op'>|</span><span class='id k'>k</span><span class='comma'>,</span> <span class='id v'>v</span><span class='op'>|</span> <span class='lbracket'>[</span><span class='symbol'>:name</span><span class='comma'>,</span> <span class='symbol'>:pivot</span><span class='comma'>,</span> <span class='symbol'>:table</span><span class='rbracket'>]</span><span class='period'>.</span><span class='id include?'>include?</span> <span class='id k'>k</span> <span class='rbrace'>}</span> + <span class='id attr'>attr</span><span class='lbracket'>[</span><span class='symbol'>:count</span><span class='rbracket'>]</span> <span class='op'>=</span> <span class='kw'>self</span><span class='period'>.</span><span class='id size'>size</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id tableStyle'>tableStyle</span><span class='lparen'>(</span><span class='id attr'>attr</span><span class='rparen'>)</span> <span class='lbrace'>{</span> <span class='kw'>self</span><span class='period'>.</span><span class='id each'>each</span> <span class='lbrace'>{</span> <span class='op'>|</span><span class='id table_style_el'>table_style_el</span><span class='op'>|</span> <span class='id table_style_el'>table_style_el</span><span class='period'>.</span><span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> <span class='rbrace'>}</span> <span class='rbrace'>}</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -701,9 +676,9 @@ The document builder instance this objects xml will be added to. </div> <div id="footer"> - Generated on Wed Nov 23 22:20:45 2011 by + Generated on Sat Nov 26 13:16:39 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/TableStyleElement.html b/doc/Axlsx/TableStyleElement.html index 489c801c..3f4b41fe 100644 --- a/doc/Axlsx/TableStyleElement.html +++ b/doc/Axlsx/TableStyleElement.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::TableStyleElement - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -97,16 +97,14 @@ <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -tables and table styles are not supported in this version. This class -exists in preparation for that support. -</p> + <div class='inline'> +<p>tables and table styles are not supported in this version. This class +exists in preparation for that support.</p> </div> </div> -<p> -an element of style that belongs to a table style. -</p> + +<p>an element of style that belongs to a table style.</p> </div> @@ -138,9 +136,8 @@ an element of style that belongs to a table style. - <span class="summary_desc"><div class='inline'><p> -The dxfId this style element points to. -</p> + <span class="summary_desc"><div class='inline'> +<p>The dxfId this style element points to.</p> </div></span> </li> @@ -165,10 +162,9 @@ The dxfId this style element points to. - <span class="summary_desc"><div class='inline'><p> -Number of rows or columns used in striping when the type is firstRowStripe, -secondRowStripe, firstColumnStripe, or secondColumnStripe. -</p> + <span class="summary_desc"><div class='inline'> +<p>Number of rows or columns used in striping when the type is firstRowStripe, +secondRowStripe, firstColumnStripe, or secondColumnStripe.</p> </div></span> </li> @@ -193,9 +189,8 @@ secondRowStripe, firstColumnStripe, or secondColumnStripe. - <span class="summary_desc"><div class='inline'><p> -The type of style element. -</p> + <span class="summary_desc"><div class='inline'> +<p>The type of style element.</p> </div></span> </li> @@ -232,9 +227,8 @@ The type of style element. - <span class="summary_desc"><div class='inline'><p> -creates a new TableStyleElement object. -</p> + <span class="summary_desc"><div class='inline'> +<p>creates a new TableStyleElement object.</p> </div></span> </li> @@ -256,9 +250,8 @@ creates a new TableStyleElement object. - <span class="summary_desc"><div class='inline'><p> -Serializes the table style element. -</p> + <span class="summary_desc"><div class='inline'> +<p>Serializes the table style element.</p> </div></span> </li> @@ -279,9 +272,8 @@ Serializes the table style element. </p><div class="docstring"> <div class="discussion"> - <p> -creates a new TableStyleElement object -</p> + +<p>creates a new TableStyleElement object</p> </div> @@ -302,9 +294,8 @@ creates a new TableStyleElement object — - <div class='inline'><p> -a customizable set of options -</p> + <div class='inline'> +<p>a customizable set of options</p> </div> </li> @@ -363,12 +354,11 @@ a customizable set of options <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/table_style_element.rb', line 49</span> -<span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span><span class='lparen token'>(</span><span class='options identifier id'>options</span><span class='assign token'>=</span><span class='lbrace token'>{</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> - <span class='options identifier id'>options</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='o identifier id'>o</span><span class='bitor op'>|</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='dstring node'>"#{o[0]}="</span><span class='comma token'>,</span> <span class='o identifier id'>o</span><span class='lbrack token'>[</span><span class='integer val'>1</span><span class='rbrack token'>]</span><span class='rparen token'>)</span> <span class='if if_mod kw'>if</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='respond_to? fid id'>respond_to?</span> <span class='o identifier id'>o</span><span class='lbrack token'>[</span><span class='integer val'>0</span><span class='rbrack token'>]</span> - <span class='end end kw'>end</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id initialize'>initialize</span><span class='lparen'>(</span><span class='id options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span> + <span class='id options'>options</span><span class='period'>.</span><span class='id each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id o'>o</span><span class='op'>|</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span><span class='rbrace'>}</span><span class='tstring_content'>=</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>1</span><span class='rbracket'>]</span><span class='rparen'>)</span> <span class='kw'>if</span> <span class='kw'>self</span><span class='period'>.</span><span class='id respond_to?'>respond_to?</span> <span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span> + <span class='kw'>end</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -391,9 +381,8 @@ a customizable set of options </p><div class="docstring"> <div class="discussion"> - <p> -The dxfId this style element points to -</p> + +<p>The dxfId this style element points to</p> </div> @@ -427,10 +416,9 @@ The dxfId this style element points to <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/table_style_element.rb', line 43</span> -<span class='def def kw'>def</span> <span class='dxfId identifier id'>dxfId</span> - <span class='@dxfId ivar id'>@dxfId</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id dxfId'>dxfId</span> + <span class='ivar'>@dxfId</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -448,10 +436,9 @@ The dxfId this style element points to </p><div class="docstring"> <div class="discussion"> - <p> -Number of rows or columns used in striping when the type is firstRowStripe, -secondRowStripe, firstColumnStripe, or secondColumnStripe. -</p> + +<p>Number of rows or columns used in striping when the type is firstRowStripe, +secondRowStripe, firstColumnStripe, or secondColumnStripe.</p> </div> @@ -485,10 +472,9 @@ secondRowStripe, firstColumnStripe, or secondColumnStripe. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/table_style_element.rb', line 39</span> -<span class='def def kw'>def</span> <span class='size identifier id'>size</span> - <span class='@size ivar id'>@size</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id size'>size</span> + <span class='ivar'>@size</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -506,39 +492,37 @@ secondRowStripe, firstColumnStripe, or secondColumnStripe. </p><div class="docstring"> <div class="discussion"> - <p> -The type of style element. The following type are allowed -</p> -<pre class="code"> - <span class='symbol val'>:wholeTable</span> - <span class='symbol val'>:headerRow</span> - <span class='symbol val'>:totalRow</span> - <span class='symbol val'>:firstColumn</span> - <span class='symbol val'>:lastColumn</span> - <span class='symbol val'>:firstRowStripe</span> - <span class='symbol val'>:secondRowStripe</span> - <span class='symbol val'>:firstColumnStripe</span> - <span class='symbol val'>:secondColumnStripe</span> - <span class='symbol val'>:firstHeaderCell</span> - <span class='symbol val'>:lastHeaderCell</span> - <span class='symbol val'>:firstTotalCell</span> - <span class='symbol val'>:lastTotalCell</span> - <span class='symbol val'>:firstSubtotalColumn</span> - <span class='symbol val'>:secondSubtotalColumn</span> - <span class='symbol val'>:thirdSubtotalColumn</span> - <span class='symbol val'>:firstSubtotalRow</span> - <span class='symbol val'>:secondSubtotalRow</span> - <span class='symbol val'>:thirdSubtotalRow</span> - <span class='symbol val'>:blankRow</span> - <span class='symbol val'>:firstColumnSubheading</span> - <span class='symbol val'>:secondColumnSubheading</span> - <span class='symbol val'>:thirdColumnSubheading</span> - <span class='symbol val'>:firstRowSubheading</span> - <span class='symbol val'>:secondRowSubheading</span> - <span class='symbol val'>:thirdRowSubheading</span> - <span class='symbol val'>:pageFieldLabels</span> - <span class='symbol val'>:pageFieldValues</span> -</pre> + +<p>The type of style element. The following type are allowed</p> + +<pre class="code"><span class='symbol'>:wholeTable</span> +<span class='symbol'>:headerRow</span> +<span class='symbol'>:totalRow</span> +<span class='symbol'>:firstColumn</span> +<span class='symbol'>:lastColumn</span> +<span class='symbol'>:firstRowStripe</span> +<span class='symbol'>:secondRowStripe</span> +<span class='symbol'>:firstColumnStripe</span> +<span class='symbol'>:secondColumnStripe</span> +<span class='symbol'>:firstHeaderCell</span> +<span class='symbol'>:lastHeaderCell</span> +<span class='symbol'>:firstTotalCell</span> +<span class='symbol'>:lastTotalCell</span> +<span class='symbol'>:firstSubtotalColumn</span> +<span class='symbol'>:secondSubtotalColumn</span> +<span class='symbol'>:thirdSubtotalColumn</span> +<span class='symbol'>:firstSubtotalRow</span> +<span class='symbol'>:secondSubtotalRow</span> +<span class='symbol'>:thirdSubtotalRow</span> +<span class='symbol'>:blankRow</span> +<span class='symbol'>:firstColumnSubheading</span> +<span class='symbol'>:secondColumnSubheading</span> +<span class='symbol'>:thirdColumnSubheading</span> +<span class='symbol'>:firstRowSubheading</span> +<span class='symbol'>:secondRowSubheading</span> +<span class='symbol'>:thirdRowSubheading</span> +<span class='symbol'>:pageFieldLabels</span> +<span class='symbol'>:pageFieldValues</span></pre> </div> @@ -572,10 +556,9 @@ The type of style element. The following type are allowed <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/table_style_element.rb', line 35</span> -<span class='def def kw'>def</span> <span class='type identifier id'>type</span> - <span class='@type ivar id'>@type</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id type'>type</span> + <span class='ivar'>@type</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -597,9 +580,8 @@ The type of style element. The following type are allowed </p><div class="docstring"> <div class="discussion"> - <p> -Serializes the table style element -</p> + +<p>Serializes the table style element</p> </div> @@ -618,9 +600,8 @@ Serializes the table style element — - <div class='inline'><p> -The document builder instance this objects xml will be added to. -</p> + <div class='inline'> +<p>The document builder instance this objects xml will be added to.</p> </div> </li> @@ -647,17 +628,16 @@ The document builder instance this objects xml will be added to. <pre class="lines"> -62 -63 -64</pre> +67 +68 +69</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/table_style_element.rb', line 62</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/table_style_element.rb', line 67</span> -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='tableStyleElement identifier id'>tableStyleElement</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='instance_values identifier id'>instance_values</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id tableStyleElement'>tableStyleElement</span> <span class='kw'>self</span><span class='period'>.</span><span class='id instance_values'>instance_values</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -668,9 +648,9 @@ The document builder instance this objects xml will be added to. </div> <div id="footer"> - Generated on Wed Nov 23 22:20:46 2011 by + Generated on Sat Nov 26 13:16:40 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/TableStyles.html b/doc/Axlsx/TableStyles.html index 47ff1ffe..0afdbba1 100644 --- a/doc/Axlsx/TableStyles.html +++ b/doc/Axlsx/TableStyles.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::TableStyles - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -99,18 +99,16 @@ <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -Support for custom table styles does not exist in this version. Many of the + <div class='inline'> +<p>Support for custom table styles does not exist in this version. Many of the classes required are defined in preparation for future release. Please do -not attempt to add custom table styles. -</p> +not attempt to add custom table styles.</p> </div> </div> -<p> -TableStyles represents a collection of style definitions for table styles -and pivot table styles. -</p> + +<p>TableStyles represents a collection of style definitions for table styles +and pivot table styles.</p> </div> @@ -146,9 +144,8 @@ and pivot table styles. - <span class="summary_desc"><div class='inline'><p> -The default pivot table style. -</p> + <span class="summary_desc"><div class='inline'> +<p>The default pivot table style.</p> </div></span> </li> @@ -173,9 +170,8 @@ The default pivot table style. - <span class="summary_desc"><div class='inline'><p> -The default table style. -</p> + <span class="summary_desc"><div class='inline'> +<p>The default table style.</p> </div></span> </li> @@ -220,10 +216,9 @@ The default table style. - <span class="summary_desc"><div class='inline'><p> -Creates a new TableStyles object that is a container for TableStyle -objects. -</p> + <span class="summary_desc"><div class='inline'> +<p>Creates a new TableStyles object that is a container for TableStyle +objects.</p> </div></span> </li> @@ -245,9 +240,8 @@ objects. - <span class="summary_desc"><div class='inline'><p> -Serializes the table styles element. -</p> + <span class="summary_desc"><div class='inline'> +<p>Serializes the table styles element.</p> </div></span> </li> @@ -261,12 +255,7 @@ Serializes the table styles element. - - - - <h3 class="inherited">Methods inherited from <span class='object_link'><a href="SimpleTypedList.html" title="Axlsx::SimpleTypedList (class)">SimpleTypedList</a></span></h3> - <p class="inherited"><span class='object_link'><a href="SimpleTypedList.html#%3C%3C-instance_method" title="Axlsx::SimpleTypedList#<< (method)">#<<</a></span>, <span class='object_link'><a href="SimpleTypedList.html#%3D%3D-instance_method" title="Axlsx::SimpleTypedList#== (method)">#==</a></span>, <span class='object_link'><a href="SimpleTypedList.html#%5B%5D%3D-instance_method" title="Axlsx::SimpleTypedList#[]= (method)">#[]=</a></span>, <span class='object_link'><a href="SimpleTypedList.html#delete-instance_method" title="Axlsx::SimpleTypedList#delete (method)">#delete</a></span>, <span class='object_link'><a href="SimpleTypedList.html#delete_at-instance_method" title="Axlsx::SimpleTypedList#delete_at (method)">#delete_at</a></span>, <span class='object_link'><a href="SimpleTypedList.html#lock-instance_method" title="Axlsx::SimpleTypedList#lock (method)">#lock</a></span>, <span class='object_link'><a href="SimpleTypedList.html#method_missing-instance_method" title="Axlsx::SimpleTypedList#method_missing (method)">#method_missing</a></span>, <span class='object_link'><a href="SimpleTypedList.html#protected%3F-instance_method" title="Axlsx::SimpleTypedList#protected? (method)">#protected?</a></span>, <span class='object_link'><a href="SimpleTypedList.html#push-instance_method" title="Axlsx::SimpleTypedList#push (method)">#push</a></span>, <span class='object_link'><a href="SimpleTypedList.html#unlock-instance_method" title="Axlsx::SimpleTypedList#unlock (method)">#unlock</a></span></p> -<div id="constructor_details" class="method_details_list"> + <div id="constructor_details" class="method_details_list"> <h2>Constructor Details</h2> <div class="method_details first"> @@ -278,9 +267,8 @@ Serializes the table styles element. </p><div class="docstring"> <div class="discussion"> - <p> -Creates a new TableStyles object that is a container for TableStyle objects -</p> + +<p>Creates a new TableStyles object that is a container for TableStyle objects</p> </div> @@ -301,9 +289,8 @@ Creates a new TableStyles object that is a container for TableStyle objects — - <div class='inline'><p> -a customizable set of options -</p> + <div class='inline'> +<p>a customizable set of options</p> </div> </li> @@ -344,21 +331,20 @@ a customizable set of options <pre class="lines"> +17 18 19 20 -21 -22</pre> +21</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/table_styles.rb', line 18</span> - -<span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span><span class='lparen token'>(</span><span class='options identifier id'>options</span><span class='assign token'>=</span><span class='lbrace token'>{</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> - <span class='@defaultTableStyle ivar id'>@defaultTableStyle</span> <span class='assign token'>=</span> <span class='options identifier id'>options</span><span class='lbrack token'>[</span><span class='symbol val'>:defaultTableStyle</span><span class='rbrack token'>]</span> <span class='orop op'>||</span> <span class='string val'>"TableStyleMedium9"</span> - <span class='@defaultPivotStyle ivar id'>@defaultPivotStyle</span> <span class='assign token'>=</span> <span class='options identifier id'>options</span><span class='lbrack token'>[</span><span class='symbol val'>:defaultPivotStyle</span><span class='rbrack token'>]</span> <span class='orop op'>||</span> <span class='string val'>"PivotStyleLight16"</span> - <span class='super super kw'>super</span> <span class='TableStyle constant id'>TableStyle</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/table_styles.rb', line 17</span> + +<span class='kw'>def</span> <span class='id initialize'>initialize</span><span class='lparen'>(</span><span class='id options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span> + <span class='ivar'>@defaultTableStyle</span> <span class='op'>=</span> <span class='id options'>options</span><span class='lbracket'>[</span><span class='symbol'>:defaultTableStyle</span><span class='rbracket'>]</span> <span class='op'>||</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>TableStyleMedium9</span><span class='tstring_end'>"</span></span> + <span class='ivar'>@defaultPivotStyle</span> <span class='op'>=</span> <span class='id options'>options</span><span class='lbracket'>[</span><span class='symbol'>:defaultPivotStyle</span><span class='rbracket'>]</span> <span class='op'>||</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>PivotStyleLight16</span><span class='tstring_end'>"</span></span> + <span class='kw'>super</span> <span class='const'>TableStyle</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -391,10 +377,8 @@ a customizable set of options </p><div class="docstring"> <div class="discussion"> - <p> -The default pivot table style. The default value is -‘PivotStyleLight6’ -</p> + +<p>The default pivot table style. The default value is 'PivotStyleLight6'</p> </div> @@ -421,17 +405,16 @@ The default pivot table style. The default value is <pre class="lines"> +12 13 -14 -15</pre> +14</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/table_styles.rb', line 13</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/table_styles.rb', line 12</span> -<span class='def def kw'>def</span> <span class='defaultPivotStyle identifier id'>defaultPivotStyle</span> - <span class='@defaultPivotStyle ivar id'>@defaultPivotStyle</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id defaultPivotStyle'>defaultPivotStyle</span> + <span class='ivar'>@defaultPivotStyle</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -449,10 +432,8 @@ The default pivot table style. The default value is </p><div class="docstring"> <div class="discussion"> - <p> -The default table style. The default value is -‘TableStyleMedium9’ -</p> + +<p>The default table style. The default value is 'TableStyleMedium9'</p> </div> @@ -479,17 +460,16 @@ The default table style. The default value is <pre class="lines"> +8 9 -10 -11</pre> +10</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/table_styles.rb', line 9</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/table_styles.rb', line 8</span> -<span class='def def kw'>def</span> <span class='defaultTableStyle identifier id'>defaultTableStyle</span> - <span class='@defaultTableStyle ivar id'>@defaultTableStyle</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id defaultTableStyle'>defaultTableStyle</span> + <span class='ivar'>@defaultTableStyle</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -511,9 +491,8 @@ The default table style. The default value is </p><div class="docstring"> <div class="discussion"> - <p> -Serializes the table styles element -</p> + +<p>Serializes the table styles element</p> </div> @@ -532,9 +511,8 @@ Serializes the table styles element — - <div class='inline'><p> -The document builder instance this objects xml will be added to. -</p> + <div class='inline'> +<p>The document builder instance this objects xml will be added to.</p> </div> </li> @@ -572,14 +550,13 @@ The document builder instance this objects xml will be added to. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/table_styles.rb', line 30</span> -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='attr identifier id'>attr</span> <span class='assign token'>=</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='instance_values identifier id'>instance_values</span><span class='dot token'>.</span><span class='reject identifier id'>reject</span> <span class='lbrace token'>{</span><span class='bitor op'>|</span><span class='k identifier id'>k</span><span class='comma token'>,</span> <span class='v identifier id'>v</span><span class='bitor op'>|</span> <span class='notop op'>!</span><span class='lbrack token'>[</span><span class='symbol val'>:defaultTableStyle</span><span class='comma token'>,</span> <span class='symbol val'>:defaultPivotStyle</span><span class='rbrack token'>]</span><span class='dot token'>.</span><span class='include? fid id'>include?</span><span class='lparen token'>(</span><span class='k identifier id'>k</span><span class='dot token'>.</span><span class='to_sym identifier id'>to_sym</span><span class='rparen token'>)</span> <span class='rbrace token'>}</span> - <span class='attr identifier id'>attr</span><span class='lbrack token'>[</span><span class='symbol val'>:count</span><span class='rbrack token'>]</span> <span class='assign token'>=</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='size identifier id'>size</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='tableStyles identifier id'>tableStyles</span><span class='lparen token'>(</span><span class='attr identifier id'>attr</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='lbrace token'>{</span> <span class='bitor op'>|</span><span class='table_style identifier id'>table_style</span><span class='bitor op'>|</span> <span class='table_style identifier id'>table_style</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> <span class='rbrace token'>}</span> - <span class='rbrace token'>}</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> + <span class='id attr'>attr</span> <span class='op'>=</span> <span class='kw'>self</span><span class='period'>.</span><span class='id instance_values'>instance_values</span><span class='period'>.</span><span class='id reject'>reject</span> <span class='lbrace'>{</span><span class='op'>|</span><span class='id k'>k</span><span class='comma'>,</span> <span class='id v'>v</span><span class='op'>|</span> <span class='op'>!</span><span class='lbracket'>[</span><span class='symbol'>:defaultTableStyle</span><span class='comma'>,</span> <span class='symbol'>:defaultPivotStyle</span><span class='rbracket'>]</span><span class='period'>.</span><span class='id include?'>include?</span><span class='lparen'>(</span><span class='id k'>k</span><span class='period'>.</span><span class='id to_sym'>to_sym</span><span class='rparen'>)</span> <span class='rbrace'>}</span> + <span class='id attr'>attr</span><span class='lbracket'>[</span><span class='symbol'>:count</span><span class='rbracket'>]</span> <span class='op'>=</span> <span class='kw'>self</span><span class='period'>.</span><span class='id size'>size</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id tableStyles'>tableStyles</span><span class='lparen'>(</span><span class='id attr'>attr</span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id each'>each</span> <span class='lbrace'>{</span> <span class='op'>|</span><span class='id table_style'>table_style</span><span class='op'>|</span> <span class='id table_style'>table_style</span><span class='period'>.</span><span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> <span class='rbrace'>}</span> + <span class='rbrace'>}</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -590,9 +567,9 @@ The document builder instance this objects xml will be added to. </div> <div id="footer"> - Generated on Wed Nov 23 22:20:58 2011 by + Generated on Sat Nov 26 13:16:39 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/Title.html b/doc/Axlsx/Title.html index 1e38aab7..a9d6c7c5 100644 --- a/doc/Axlsx/Title.html +++ b/doc/Axlsx/Title.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::Title - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -94,9 +94,8 @@ <h2>Overview</h2><div class="docstring"> <div class="discussion"> - <p> -A Title stores information about the title of a chart -</p> + +<p>A Title stores information about the title of a chart</p> </div> @@ -132,9 +131,8 @@ A Title stores information about the title of a chart - <span class="summary_desc"><div class='inline'><p> -The cell that holds the text for the title. -</p> + <span class="summary_desc"><div class='inline'> +<p>The cell that holds the text for the title.</p> </div></span> </li> @@ -159,9 +157,8 @@ The cell that holds the text for the title. - <span class="summary_desc"><div class='inline'><p> -The text to be shown. -</p> + <span class="summary_desc"><div class='inline'> +<p>The text to be shown.</p> </div></span> </li> @@ -198,34 +195,8 @@ The text to be shown. - <span class="summary_desc"><div class='inline'><p> -Creates a new Title object. -</p> -</div></span> - -</li> - - - <li class="public "> - <span class="summary_signature"> - - <a href="#range-instance_method" title="#range (instance method)">- (String) <strong>range</strong> </a> - - - - </span> - - - - - - - - - <span class="summary_desc"><div class='inline'><p> -returns the excel style abslute reference for the title when title is a -Cell object. -</p> + <span class="summary_desc"><div class='inline'> +<p>Creates a new Title object.</p> </div></span> </li> @@ -247,9 +218,8 @@ Cell object. - <span class="summary_desc"><div class='inline'><p> -Serializes the chart title. -</p> + <span class="summary_desc"><div class='inline'> +<p>Serializes the chart title.</p> </div></span> </li> @@ -270,9 +240,8 @@ Serializes the chart title. </p><div class="docstring"> <div class="discussion"> - <p> -Creates a new Title object -</p> + +<p>Creates a new Title object</p> </div> @@ -293,9 +262,8 @@ Creates a new Title object — - <div class='inline'><p> -The cell or string to be used for the chart’s title -</p> + <div class='inline'> +<p>The cell or string to be used for the chart's title</p> </div> </li> @@ -317,11 +285,10 @@ The cell or string to be used for the chart’s title <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/title.rb', line 15</span> -<span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span><span class='lparen token'>(</span><span class='title identifier id'>title</span><span class='assign token'>=</span><span class='string val'>""</span><span class='rparen token'>)</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='cell identifier id'>cell</span> <span class='assign token'>=</span> <span class='title identifier id'>title</span> <span class='if if_mod kw'>if</span> <span class='title identifier id'>title</span><span class='dot token'>.</span><span class='is_a? fid id'>is_a?</span><span class='lparen token'>(</span><span class='Cell constant id'>Cell</span><span class='rparen token'>)</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='text identifier id'>text</span> <span class='assign token'>=</span> <span class='title identifier id'>title</span><span class='dot token'>.</span><span class='to_s identifier id'>to_s</span> <span class='unless unless_mod kw'>unless</span> <span class='title identifier id'>title</span><span class='dot token'>.</span><span class='is_a? fid id'>is_a?</span><span class='lparen token'>(</span><span class='Cell constant id'>Cell</span><span class='rparen token'>)</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id initialize'>initialize</span><span class='lparen'>(</span><span class='id title'>title</span><span class='op'>=</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_end'>"</span></span><span class='rparen'>)</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id cell'>cell</span> <span class='op'>=</span> <span class='id title'>title</span> <span class='kw'>if</span> <span class='id title'>title</span><span class='period'>.</span><span class='id is_a?'>is_a?</span><span class='lparen'>(</span><span class='const'>Cell</span><span class='rparen'>)</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id text'>text</span> <span class='op'>=</span> <span class='id title'>title</span><span class='period'>.</span><span class='id to_s'>to_s</span> <span class='kw'>unless</span> <span class='id title'>title</span><span class='period'>.</span><span class='id is_a?'>is_a?</span><span class='lparen'>(</span><span class='const'>Cell</span><span class='rparen'>)</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -344,10 +311,9 @@ The cell or string to be used for the chart’s title </p><div class="docstring"> <div class="discussion"> - <p> -The cell that holds the text for the title. Setting this property will -automatically update the text attribute. -</p> + +<p>The cell that holds the text for the title. Setting this property will +automatically update the text attribute.</p> </div> @@ -381,10 +347,9 @@ automatically update the text attribute. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/title.rb', line 11</span> -<span class='def def kw'>def</span> <span class='cell identifier id'>cell</span> - <span class='@cell ivar id'>@cell</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id cell'>cell</span> + <span class='ivar'>@cell</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -402,10 +367,9 @@ automatically update the text attribute. </p><div class="docstring"> <div class="discussion"> - <p> -The text to be shown. Setting this property directly with a string will -remove the cell reference. -</p> + +<p>The text to be shown. Setting this property directly with a string will +remove the cell reference.</p> </div> @@ -439,10 +403,9 @@ remove the cell reference. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/title.rb', line 7</span> -<span class='def def kw'>def</span> <span class='text identifier id'>text</span> - <span class='@text ivar id'>@text</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id text'>text</span> + <span class='ivar'>@text</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -456,64 +419,7 @@ remove the cell reference. <div class="method_details first"> - <p class="signature first" id="range-instance_method"> - - - (<tt>String</tt>) <strong>range</strong> - - - -</p><div class="docstring"> - <div class="discussion"> - <p> -returns the excel style abslute reference for the title when title is a -Cell object -</p> - - - </div> -</div> -<div class="tags"> - -<h3>Returns:</h3> -<ul class="return"> - - <li> - - - <span class='type'>(<tt>String</tt>)</span> - - - - </li> - -</ul> - -</div><table class="source_code"> - <tr> - <td> - <pre class="lines"> - - -62 -63 -64 -65</pre> - </td> - <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/title.rb', line 62</span> - -<span class='def def kw'>def</span> <span class='range identifier id'>range</span> - <span class='return return kw'>return</span> <span class='string val'>""</span> <span class='unless unless_mod kw'>unless</span> <span class='@data ivar id'>@data</span><span class='dot token'>.</span><span class='is_a? fid id'>is_a?</span><span class='lparen token'>(</span><span class='Cell constant id'>Cell</span><span class='rparen token'>)</span> - <span class='dstring node'>"#{@data.row.worksheet.name}!#{data.row.r_abs}"</span> -<span class='end end kw'>end</span> -</pre> - </td> - </tr> -</table> -</div> - - <div class="method_details "> - <p class="signature " id="to_xml-instance_method"> + <p class="signature first" id="to_xml-instance_method"> - (<tt>String</tt>) <strong>to_xml</strong>(xml) @@ -521,9 +427,8 @@ Cell object </p><div class="docstring"> <div class="discussion"> - <p> -Serializes the chart title -</p> + +<p>Serializes the chart title</p> </div> @@ -542,9 +447,8 @@ Serializes the chart title — - <div class='inline'><p> -The document builder instance this objects xml will be added to. -</p> + <div class='inline'> +<p>The document builder instance this objects xml will be added to.</p> </div> </li> @@ -571,8 +475,6 @@ The document builder instance this objects xml will be added to. <pre class="lines"> -42 -43 44 45 46 @@ -585,27 +487,28 @@ The document builder instance this objects xml will be added to. 53 54 55 -56</pre> +56 +57 +58</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/title.rb', line 42</span> - -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:title'</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:tx'</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:strRef'</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:f'</span><span class='comma token'>,</span> <span class='range identifier id'>range</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:strCache'</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:ptCount'</span><span class='comma token'>,</span> <span class='symbol val'>:val=</span><span class='gt op'>></span><span class='integer val'>1</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:pt'</span><span class='comma token'>,</span> <span class='symbol val'>:idx=</span><span class='gt op'>></span><span class='integer val'>0</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:v'</span><span class='comma token'>,</span> <span class='@text ivar id'>@text</span><span class='rparen token'>)</span> - <span class='rbrace token'>}</span> - <span class='rbrace token'>}</span> - <span class='rbrace token'>}</span> - <span class='rbrace token'>}</span> - <span class='rbrace token'>}</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/title.rb', line 44</span> + +<span class='kw'>def</span> <span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:title</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:tx</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:strRef</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:f</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='const'>Axlsx</span><span class='op'>::</span><span class='id cell_range'>cell_range</span><span class='lparen'>(</span><span class='lbracket'>[</span><span class='ivar'>@cell</span><span class='rbracket'>]</span><span class='rparen'>)</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:strCache</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:ptCount</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:val</span><span class='op'>=></span><span class='int'>1</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:pt</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:idx</span><span class='op'>=></span><span class='int'>0</span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:v</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='ivar'>@text</span><span class='rparen'>)</span> + <span class='rbrace'>}</span> + <span class='rbrace'>}</span> + <span class='rbrace'>}</span> + <span class='rbrace'>}</span> + <span class='rbrace'>}</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -616,9 +519,9 @@ The document builder instance this objects xml will be added to. </div> <div id="footer"> - Generated on Wed Nov 23 22:20:52 2011 by + Generated on Sat Nov 26 13:16:36 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/TwoCellAnchor.html b/doc/Axlsx/TwoCellAnchor.html index 07adaac8..8e2b5d7c 100644 --- a/doc/Axlsx/TwoCellAnchor.html +++ b/doc/Axlsx/TwoCellAnchor.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::TwoCellAnchor - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -97,16 +97,14 @@ <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -The recommended way to manage drawings and charts is Worksheet#add_chart. -Anchors are specified by the :start_at and :end_at options to that method. -</p> + <div class='inline'> +<p>The recommended way to manage drawings and charts is Worksheet#add_chart. +Anchors are specified by the :start_at and :end_at options to that method.</p> </div> </div> -<p> -This class details the anchor points for drawings. -</p> + +<p>This class details the anchor points for drawings.</p> </div> @@ -145,9 +143,8 @@ This class details the anchor points for drawings. - <span class="summary_desc"><div class='inline'><p> -The drawing that holds this anchor. -</p> + <span class="summary_desc"><div class='inline'> +<p>The drawing that holds this anchor.</p> </div></span> </li> @@ -172,9 +169,8 @@ The drawing that holds this anchor. - <span class="summary_desc"><div class='inline'><p> -A marker that defines the from cell anchor. -</p> + <span class="summary_desc"><div class='inline'> +<p>A marker that defines the from cell anchor.</p> </div></span> </li> @@ -183,7 +179,7 @@ A marker that defines the from cell anchor. <li class="public "> <span class="summary_signature"> - <a href="#index-instance_method" title="#index (instance method)">- (Integer) <strong>index</strong> </a> + <a href="#object-instance_method" title="#object (instance method)">- (Pic, GraphicFrame) <strong>object</strong> </a> @@ -199,9 +195,8 @@ A marker that defines the from cell anchor. - <span class="summary_desc"><div class='inline'><p> -The index of this anchor in the drawing. -</p> + <span class="summary_desc"><div class='inline'> +<p>The object this anchor hosts.</p> </div></span> </li> @@ -210,7 +205,7 @@ The index of this anchor in the drawing. <li class="public "> <span class="summary_signature"> - <a href="#object-instance_method" title="#object (instance method)">- (Pic, GraphicFrame) <strong>object</strong> </a> + <a href="#to-instance_method" title="#to (instance method)">- (Marker) <strong>to</strong> </a> @@ -226,58 +221,53 @@ The index of this anchor in the drawing. - <span class="summary_desc"><div class='inline'><p> -The object this anchor hosts. -</p> + <span class="summary_desc"><div class='inline'> +<p>A marker that returns the to cell anchor.</p> </div></span> </li> - <li class="public "> + </ul> + + + + + + <h2> + Instance Method Summary + <small>(<a href="#" class="summary_toggle">collapse</a>)</small> + </h2> + + <ul class="summary"> + + <li class="public "> <span class="summary_signature"> - <a href="#to-instance_method" title="#to (instance method)">- (Marker) <strong>to</strong> </a> + <a href="#add_chart-instance_method" title="#add_chart (instance method)">- (Chart) <strong>add_chart</strong>(chart_type, options) </a> </span> - <span class="note title readonly">readonly</span> - - - <span class="summary_desc"><div class='inline'><p> -A marker that returns the to cell anchor. -</p> + <span class="summary_desc"><div class='inline'> +<p>Creates a graphic frame and chart object associated with this anchor.</p> </div></span> </li> - - </ul> - - - - - - <h2> - Instance Method Summary - <small>(<a href="#" class="summary_toggle">collapse</a>)</small> - </h2> - - <ul class="summary"> <li class="public "> <span class="summary_signature"> - <a href="#add_chart-instance_method" title="#add_chart (instance method)">- (Chart) <strong>add_chart</strong>(chart_type, options) </a> + <a href="#index-instance_method" title="#index (instance method)">- (Integer) <strong>index</strong> </a> @@ -290,9 +280,8 @@ A marker that returns the to cell anchor. - <span class="summary_desc"><div class='inline'><p> -Creates a graphic frame and chart object associated with this anchor. -</p> + <span class="summary_desc"><div class='inline'> +<p>The index of this anchor in the drawing.</p> </div></span> </li> @@ -316,10 +305,9 @@ Creates a graphic frame and chart object associated with this anchor. - <span class="summary_desc"><div class='inline'><p> -Creates a new TwoCellAnchor object and sets up a reference to the from and -to markers in the graphic_frame’s chart. -</p> + <span class="summary_desc"><div class='inline'> +<p>Creates a new TwoCellAnchor object and sets up a reference to the from and +to markers in the graphic_frame's chart.</p> </div></span> </li> @@ -341,9 +329,8 @@ to markers in the graphic_frame’s chart. - <span class="summary_desc"><div class='inline'><p> -Serializes the two cell anchor. -</p> + <span class="summary_desc"><div class='inline'> +<p>Serializes the two cell anchor.</p> </div></span> </li> @@ -367,17 +354,15 @@ Serializes the two cell anchor. <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -the chart_type parameter will be replaced with object in v. 2.0.0 -</p> + <div class='inline'> +<p>the chart_type parameter will be replaced with object in v. 2.0.0</p> </div> </div> -<p> -Creates a new TwoCellAnchor object and sets up a reference to the from and -to markers in the graphic_frame’s chart. That means that you can do -stuff like c = worksheet.add_chart Axlsx::Chart c.start_at 5, 9 -</p> + +<p>Creates a new TwoCellAnchor object and sets up a reference to the from and +to markers in the graphic_frame's chart. That means that you can do stuff +like c = worksheet.add_chart Axlsx::Chart c.start_at 5, 9</p> </div> @@ -407,10 +392,9 @@ stuff like c = worksheet.add_chart Axlsx::Chart c.start_at 5, 9 — - <div class='inline'><p> -This is passed to the graphic frame for instantiation. must be Chart or a -subclass of Chart -</p> + <div class='inline'> +<p>This is passed to the graphic frame for instantiation. must be Chart or a +subclass of Chart</p> </div> </li> @@ -425,9 +409,8 @@ subclass of Chart — - <div class='inline'><p> -The object this anchor holds. -</p> + <div class='inline'> +<p>The object this anchor holds.</p> </div> </li> @@ -444,9 +427,8 @@ The object this anchor holds. — - <div class='inline'><p> -a customizable set of options -</p> + <div class='inline'> +<p>a customizable set of options</p> </div> </li> @@ -467,9 +449,8 @@ a customizable set of options <span class="default"> </span> - — <div class='inline'><p> -the col, row to start at -</p> + — <div class='inline'> +<p>the col, row to start at</p> </div> </li> @@ -479,9 +460,8 @@ the col, row to start at <span class="default"> </span> - — <div class='inline'><p> -the col, row to end at -</p> + — <div class='inline'> +<p>the col, row to end at</p> </div> </li> @@ -495,21 +475,20 @@ the col, row to end at <pre class="lines"> +38 +39 +40 41 -42 -43 -44 -45</pre> +42</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/two_cell_anchor.rb', line 41</span> - -<span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span><span class='lparen token'>(</span><span class='drawing identifier id'>drawing</span><span class='comma token'>,</span> <span class='options identifier id'>options</span><span class='assign token'>=</span><span class='lbrace token'>{</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> - <span class='@drawing ivar id'>@drawing</span> <span class='assign token'>=</span> <span class='drawing identifier id'>drawing</span> - <span class='drawing identifier id'>drawing</span><span class='dot token'>.</span><span class='anchors identifier id'>anchors</span> <span class='lshft op'><<</span> <span class='self self kw'>self</span> - <span class='@from ivar id'>@from</span><span class='comma token'>,</span> <span class='@to ivar id'>@to</span> <span class='assign token'>=</span> <span class='Marker constant id'>Marker</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='comma token'>,</span> <span class='Marker constant id'>Marker</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='symbol val'>:col</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='integer val'>5</span><span class='comma token'>,</span> <span class='symbol val'>:row=</span><span class='gt op'>></span><span class='integer val'>10</span><span class='rparen token'>)</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/two_cell_anchor.rb', line 38</span> + +<span class='kw'>def</span> <span class='id initialize'>initialize</span><span class='lparen'>(</span><span class='id drawing'>drawing</span><span class='comma'>,</span> <span class='id options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span> + <span class='ivar'>@drawing</span> <span class='op'>=</span> <span class='id drawing'>drawing</span> + <span class='id drawing'>drawing</span><span class='period'>.</span><span class='id anchors'>anchors</span> <span class='op'><<</span> <span class='kw'>self</span> + <span class='ivar'>@from</span><span class='comma'>,</span> <span class='ivar'>@to</span> <span class='op'>=</span> <span class='const'>Marker</span><span class='period'>.</span><span class='id new'>new</span><span class='comma'>,</span> <span class='const'>Marker</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='symbol'>:col</span> <span class='op'>=></span> <span class='int'>5</span><span class='comma'>,</span> <span class='symbol'>:row</span><span class='op'>=></span><span class='int'>10</span><span class='rparen'>)</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -532,9 +511,8 @@ the col, row to end at </p><div class="docstring"> <div class="discussion"> - <p> -The drawing that holds this anchor -</p> + +<p>The drawing that holds this anchor</p> </div> @@ -568,10 +546,9 @@ The drawing that holds this anchor <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/two_cell_anchor.rb', line 25</span> -<span class='def def kw'>def</span> <span class='drawing identifier id'>drawing</span> - <span class='@drawing ivar id'>@drawing</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id drawing'>drawing</span> + <span class='ivar'>@drawing</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -589,10 +566,9 @@ The drawing that holds this anchor </p><div class="docstring"> <div class="discussion"> - <p> -A marker that defines the from cell anchor. The default from column and row -are 0 and 0 respectively -</p> + +<p>A marker that defines the from cell anchor. The default from column and row +are 0 and 0 respectively</p> </div> @@ -626,10 +602,9 @@ are 0 and 0 respectively <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/two_cell_anchor.rb', line 9</span> -<span class='def def kw'>def</span> <span class='from identifier id'>from</span> - <span class='@from ivar id'>@from</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id from'>from</span> + <span class='ivar'>@from</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -637,19 +612,18 @@ are 0 and 0 respectively <span id=""></span> - <span id="index-instance_method"></span> + <span id="object-instance_method"></span> <div class="method_details "> - <p class="signature " id="index-instance_method"> + <p class="signature " id="object-instance_method"> - - (<tt>Integer</tt>) <strong>index</strong> <span class="extras">(readonly)</span> + - (<tt><span class='object_link'><a href="Pic.html" title="Axlsx::Pic (class)">Pic</a></span></tt>, <tt><span class='object_link'><a href="GraphicFrame.html" title="Axlsx::GraphicFrame (class)">GraphicFrame</a></span></tt>) <strong>object</strong> <span class="extras">(readonly)</span> </p><div class="docstring"> <div class="discussion"> - <p> -The index of this anchor in the drawing -</p> + +<p>The object this anchor hosts</p> </div> @@ -662,7 +636,7 @@ The index of this anchor in the drawing <li> - <span class='type'>(<tt>Integer</tt>)</span> + <span class='type'>(<tt><span class='object_link'><a href="Pic.html" title="Axlsx::Pic (class)">Pic</a></span></tt>, <tt><span class='object_link'><a href="GraphicFrame.html" title="Axlsx::GraphicFrame (class)">GraphicFrame</a></span></tt>)</span> @@ -676,17 +650,16 @@ The index of this anchor in the drawing <pre class="lines"> -29 -30 -31</pre> +21 +22 +23</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/two_cell_anchor.rb', line 29</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/two_cell_anchor.rb', line 21</span> -<span class='def def kw'>def</span> <span class='index identifier id'>index</span> - <span class='@drawing ivar id'>@drawing</span><span class='dot token'>.</span><span class='anchors identifier id'>anchors</span><span class='dot token'>.</span><span class='index identifier id'>index</span><span class='lparen token'>(</span><span class='self self kw'>self</span><span class='rparen token'>)</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id object'>object</span> + <span class='ivar'>@object</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -694,19 +667,19 @@ The index of this anchor in the drawing <span id=""></span> - <span id="object-instance_method"></span> + <span id="to-instance_method"></span> <div class="method_details "> - <p class="signature " id="object-instance_method"> + <p class="signature " id="to-instance_method"> - - (<tt><span class='object_link'><a href="Pic.html" title="Axlsx::Pic (class)">Pic</a></span></tt>, <tt><span class='object_link'><a href="GraphicFrame.html" title="Axlsx::GraphicFrame (class)">GraphicFrame</a></span></tt>) <strong>object</strong> <span class="extras">(readonly)</span> + - (<tt><span class='object_link'><a href="Marker.html" title="Axlsx::Marker (class)">Marker</a></span></tt>) <strong>to</strong> <span class="extras">(readonly)</span> </p><div class="docstring"> <div class="discussion"> - <p> -The object this anchor hosts -</p> + +<p>A marker that returns the to cell anchor. The default to column and row are +5 and 10 respectively</p> </div> @@ -719,7 +692,7 @@ The object this anchor hosts <li> - <span class='type'>(<tt><span class='object_link'><a href="Pic.html" title="Axlsx::Pic (class)">Pic</a></span></tt>, <tt><span class='object_link'><a href="GraphicFrame.html" title="Axlsx::GraphicFrame (class)">GraphicFrame</a></span></tt>)</span> + <span class='type'>(<tt><span class='object_link'><a href="Marker.html" title="Axlsx::Marker (class)">Marker</a></span></tt>)</span> @@ -733,38 +706,39 @@ The object this anchor hosts <pre class="lines"> -21 -22 -23</pre> +12 +13 +14</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/two_cell_anchor.rb', line 21</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/two_cell_anchor.rb', line 12</span> -<span class='def def kw'>def</span> <span class='object identifier id'>object</span> - <span class='@object ivar id'>@object</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id to'>to</span> + <span class='ivar'>@to</span> +<span class='kw'>end</span></pre> </td> </tr> </table> </div> - - <span id=""></span> - <span id="to-instance_method"></span> - <div class="method_details "> - <p class="signature " id="to-instance_method"> + </div> + + + <div id="instance_method_details" class="method_details_list"> + <h2>Instance Method Details</h2> + + + <div class="method_details first"> + <p class="signature first" id="add_chart-instance_method"> - - (<tt><span class='object_link'><a href="Marker.html" title="Axlsx::Marker (class)">Marker</a></span></tt>) <strong>to</strong> <span class="extras">(readonly)</span> + - (<tt><span class='object_link'><a href="Chart.html" title="Axlsx::Chart (class)">Chart</a></span></tt>) <strong>add_chart</strong>(chart_type, options) </p><div class="docstring"> <div class="discussion"> - <p> -A marker that returns the to cell anchor. The default to column and row are -5 and 10 respectively -</p> + +<p>Creates a graphic frame and chart object associated with this anchor</p> </div> @@ -777,7 +751,7 @@ A marker that returns the to cell anchor. The default to column and row are <li> - <span class='type'>(<tt><span class='object_link'><a href="Marker.html" title="Axlsx::Marker (class)">Marker</a></span></tt>)</span> + <span class='type'>(<tt><span class='object_link'><a href="Chart.html" title="Axlsx::Chart (class)">Chart</a></span></tt>)</span> @@ -791,41 +765,34 @@ A marker that returns the to cell anchor. The default to column and row are <pre class="lines"> -12 -13 -14</pre> +46 +47 +48 +49</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/two_cell_anchor.rb', line 12</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/two_cell_anchor.rb', line 46</span> -<span class='def def kw'>def</span> <span class='to identifier id'>to</span> - <span class='@to ivar id'>@to</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id add_chart'>add_chart</span><span class='lparen'>(</span><span class='id chart_type'>chart_type</span><span class='comma'>,</span> <span class='id options'>options</span><span class='rparen'>)</span> + <span class='ivar'>@object</span> <span class='op'>=</span> <span class='const'>GraphicFrame</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='kw'>self</span><span class='comma'>,</span> <span class='id chart_type'>chart_type</span><span class='comma'>,</span> <span class='id options'>options</span><span class='rparen'>)</span> + <span class='ivar'>@object</span><span class='period'>.</span><span class='id chart'>chart</span> +<span class='kw'>end</span></pre> </td> </tr> </table> </div> - </div> - - - <div id="instance_method_details" class="method_details_list"> - <h2>Instance Method Details</h2> - - - <div class="method_details first"> - <p class="signature first" id="add_chart-instance_method"> + <div class="method_details "> + <p class="signature " id="index-instance_method"> - - (<tt><span class='object_link'><a href="Chart.html" title="Axlsx::Chart (class)">Chart</a></span></tt>) <strong>add_chart</strong>(chart_type, options) + - (<tt>Integer</tt>) <strong>index</strong> </p><div class="docstring"> <div class="discussion"> - <p> -Creates a graphic frame and chart object associated with this anchor -</p> + +<p>The index of this anchor in the drawing</p> </div> @@ -838,7 +805,7 @@ Creates a graphic frame and chart object associated with this anchor <li> - <span class='type'>(<tt><span class='object_link'><a href="Chart.html" title="Axlsx::Chart (class)">Chart</a></span></tt>)</span> + <span class='type'>(<tt>Integer</tt>)</span> @@ -852,19 +819,16 @@ Creates a graphic frame and chart object associated with this anchor <pre class="lines"> -49 -50 -51 -52</pre> +53 +54 +55</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/two_cell_anchor.rb', line 49</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/two_cell_anchor.rb', line 53</span> -<span class='def def kw'>def</span> <span class='add_chart identifier id'>add_chart</span><span class='lparen token'>(</span><span class='chart_type identifier id'>chart_type</span><span class='comma token'>,</span> <span class='options identifier id'>options</span><span class='rparen token'>)</span> - <span class='@object ivar id'>@object</span> <span class='assign token'>=</span> <span class='GraphicFrame constant id'>GraphicFrame</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='self self kw'>self</span><span class='comma token'>,</span> <span class='chart_type identifier id'>chart_type</span><span class='comma token'>,</span> <span class='options identifier id'>options</span><span class='rparen token'>)</span> - <span class='@object ivar id'>@object</span><span class='dot token'>.</span><span class='chart identifier id'>chart</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id index'>index</span> + <span class='ivar'>@drawing</span><span class='period'>.</span><span class='id anchors'>anchors</span><span class='period'>.</span><span class='id index'>index</span><span class='lparen'>(</span><span class='kw'>self</span><span class='rparen'>)</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -879,9 +843,8 @@ Creates a graphic frame and chart object associated with this anchor </p><div class="docstring"> <div class="discussion"> - <p> -Serializes the two cell anchor -</p> + +<p>Serializes the two cell anchor</p> </div> @@ -900,9 +863,8 @@ Serializes the two cell anchor — - <div class='inline'><p> -The document builder instance this objects xml will be added to. -</p> + <div class='inline'> +<p>The document builder instance this objects xml will be added to.</p> </div> </li> @@ -929,6 +891,7 @@ The document builder instance this objects xml will be added to. <pre class="lines"> +59 60 61 62 @@ -940,26 +903,24 @@ The document builder instance this objects xml will be added to. 68 69 70 -71 -72</pre> +71</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/two_cell_anchor.rb', line 60</span> - -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='comment val'>#build it for now, break it down later!</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'xdr:twoCellAnchor'</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'xdr:from'</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='from identifier id'>from</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='rbrace token'>}</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'xdr:to'</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='to identifier id'>to</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='rbrace token'>}</span> - <span class='@object ivar id'>@object</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'xdr:clientData'</span><span class='rparen token'>)</span> - <span class='rbrace token'>}</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/two_cell_anchor.rb', line 59</span> + +<span class='kw'>def</span> <span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> + <span class='comment'>#build it for now, break it down later! +</span> <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>xdr:twoCellAnchor</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>xdr:from</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='id from'>from</span><span class='period'>.</span><span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> + <span class='rbrace'>}</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>xdr:to</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='id to'>to</span><span class='period'>.</span><span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> + <span class='rbrace'>}</span> + <span class='ivar'>@object</span><span class='period'>.</span><span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>xdr:clientData</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> + <span class='rbrace'>}</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -970,9 +931,9 @@ The document builder instance this objects xml will be added to. </div> <div id="footer"> - Generated on Wed Nov 23 22:20:51 2011 by + Generated on Sat Nov 26 13:16:39 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/ValAxis.html b/doc/Axlsx/ValAxis.html index ca87efb1..252c78df 100644 --- a/doc/Axlsx/ValAxis.html +++ b/doc/Axlsx/ValAxis.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::ValAxis - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -96,9 +96,8 @@ <h2>Overview</h2><div class="docstring"> <div class="discussion"> - <p> -the ValAxis class defines a chart value axis. -</p> + +<p>the ValAxis class defines a chart value axis.</p> </div> @@ -134,9 +133,8 @@ the ValAxis class defines a chart value axis. - <span class="summary_desc"><div class='inline'><p> -This element specifies how the value axis crosses the category axis. -</p> + <span class="summary_desc"><div class='inline'> +<p>This element specifies how the value axis crosses the category axis.</p> </div></span> </li> @@ -181,9 +179,8 @@ This element specifies how the value axis crosses the category axis. - <span class="summary_desc"><div class='inline'><p> -Creates a new ValAxis object. -</p> + <span class="summary_desc"><div class='inline'> +<p>Creates a new ValAxis object.</p> </div></span> </li> @@ -205,9 +202,8 @@ Creates a new ValAxis object. - <span class="summary_desc"><div class='inline'><p> -Serializes the value axis. -</p> + <span class="summary_desc"><div class='inline'> +<p>Serializes the value axis.</p> </div></span> </li> @@ -233,9 +229,8 @@ Serializes the value axis. </p><div class="docstring"> <div class="discussion"> - <p> -Creates a new ValAxis object -</p> + +<p>Creates a new ValAxis object</p> </div> @@ -254,9 +249,8 @@ Creates a new ValAxis object — - <div class='inline'><p> -the id of this axis -</p> + <div class='inline'> +<p>the id of this axis</p> </div> </li> @@ -271,9 +265,8 @@ the id of this axis — - <div class='inline'><p> -the id of the perpendicular axis -</p> + <div class='inline'> +<p>the id of the perpendicular axis</p> </div> </li> @@ -290,9 +283,8 @@ the id of the perpendicular axis — - <div class='inline'><p> -a customizable set of options -</p> + <div class='inline'> +<p>a customizable set of options</p> </div> </li> @@ -363,11 +355,10 @@ a customizable set of options <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/val_axis.rb', line 17</span> -<span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span><span class='lparen token'>(</span><span class='axId identifier id'>axId</span><span class='comma token'>,</span> <span class='crossAx identifier id'>crossAx</span><span class='comma token'>,</span> <span class='options identifier id'>options</span><span class='assign token'>=</span><span class='lbrace token'>{</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='crossBetween identifier id'>crossBetween</span> <span class='assign token'>=</span> <span class='symbol val'>:between</span> - <span class='super super kw'>super</span><span class='lparen token'>(</span><span class='axId identifier id'>axId</span><span class='comma token'>,</span> <span class='crossAx identifier id'>crossAx</span><span class='comma token'>,</span> <span class='options identifier id'>options</span><span class='rparen token'>)</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id initialize'>initialize</span><span class='lparen'>(</span><span class='id axId'>axId</span><span class='comma'>,</span> <span class='id crossAx'>crossAx</span><span class='comma'>,</span> <span class='id options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id crossBetween'>crossBetween</span> <span class='op'>=</span> <span class='symbol'>:between</span> + <span class='kw'>super</span><span class='lparen'>(</span><span class='id axId'>axId</span><span class='comma'>,</span> <span class='id crossAx'>crossAx</span><span class='comma'>,</span> <span class='id options'>options</span><span class='rparen'>)</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -390,10 +381,9 @@ a customizable set of options </p><div class="docstring"> <div class="discussion"> - <p> -This element specifies how the value axis crosses the category axis. must -be one of [:between, :midCat] -</p> + +<p>This element specifies how the value axis crosses the category axis. must +be one of [:between, :midCat]</p> </div> @@ -427,10 +417,9 @@ be one of [:between, :midCat] <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/val_axis.rb', line 8</span> -<span class='def def kw'>def</span> <span class='crossBetween identifier id'>crossBetween</span> - <span class='@crossBetween ivar id'>@crossBetween</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id crossBetween'>crossBetween</span> + <span class='ivar'>@crossBetween</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -452,9 +441,8 @@ be one of [:between, :midCat] </p><div class="docstring"> <div class="discussion"> - <p> -Serializes the value axis -</p> + +<p>Serializes the value axis</p> </div> @@ -473,9 +461,8 @@ Serializes the value axis — - <div class='inline'><p> -The document builder instance this objects xml will be added to. -</p> + <div class='inline'> +<p>The document builder instance this objects xml will be added to.</p> </div> </li> @@ -512,13 +499,12 @@ The document builder instance this objects xml will be added to. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/val_axis.rb', line 27</span> -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:valAx'</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='super super kw'>super</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:crossBetween'</span><span class='comma token'>,</span> <span class='symbol val'>:val=</span><span class='gt op'>></span><span class='@crossBetween ivar id'>@crossBetween</span><span class='rparen token'>)</span> - <span class='rbrace token'>}</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:valAx</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='kw'>super</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:crossBetween</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:val</span><span class='op'>=></span><span class='ivar'>@crossBetween</span><span class='rparen'>)</span> + <span class='rbrace'>}</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -529,9 +515,9 @@ The document builder instance this objects xml will be added to. </div> <div id="footer"> - Generated on Wed Nov 23 22:20:45 2011 by + Generated on Sat Nov 26 13:16:37 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/ValAxisData.html b/doc/Axlsx/ValAxisData.html index a4e30dd3..06cae71d 100644 --- a/doc/Axlsx/ValAxisData.html +++ b/doc/Axlsx/ValAxisData.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::ValAxisData - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -98,9 +98,8 @@ <h2>Overview</h2><div class="docstring"> <div class="discussion"> - <p> -The ValAxisData class manages the values for a chart value series. -</p> + +<p>The ValAxisData class manages the values for a chart value series.</p> </div> @@ -156,9 +155,8 @@ The ValAxisData class manages the values for a chart value series. - <span class="summary_desc"><div class='inline'><p> -Serializes the value axis data. -</p> + <span class="summary_desc"><div class='inline'> +<p>Serializes the value axis data.</p> </div></span> </li> @@ -182,12 +180,7 @@ Serializes the value axis data. - - - - <h3 class="inherited">Methods inherited from <span class='object_link'><a href="SimpleTypedList.html" title="Axlsx::SimpleTypedList (class)">SimpleTypedList</a></span></h3> - <p class="inherited"><span class='object_link'><a href="SimpleTypedList.html#%3C%3C-instance_method" title="Axlsx::SimpleTypedList#<< (method)">#<<</a></span>, <span class='object_link'><a href="SimpleTypedList.html#%3D%3D-instance_method" title="Axlsx::SimpleTypedList#== (method)">#==</a></span>, <span class='object_link'><a href="SimpleTypedList.html#%5B%5D%3D-instance_method" title="Axlsx::SimpleTypedList#[]= (method)">#[]=</a></span>, <span class='object_link'><a href="SimpleTypedList.html#delete-instance_method" title="Axlsx::SimpleTypedList#delete (method)">#delete</a></span>, <span class='object_link'><a href="SimpleTypedList.html#delete_at-instance_method" title="Axlsx::SimpleTypedList#delete_at (method)">#delete_at</a></span>, <span class='object_link'><a href="SimpleTypedList.html#initialize-instance_method" title="Axlsx::SimpleTypedList#initialize (method)">#initialize</a></span>, <span class='object_link'><a href="SimpleTypedList.html#lock-instance_method" title="Axlsx::SimpleTypedList#lock (method)">#lock</a></span>, <span class='object_link'><a href="SimpleTypedList.html#method_missing-instance_method" title="Axlsx::SimpleTypedList#method_missing (method)">#method_missing</a></span>, <span class='object_link'><a href="SimpleTypedList.html#protected%3F-instance_method" title="Axlsx::SimpleTypedList#protected? (method)">#protected?</a></span>, <span class='object_link'><a href="SimpleTypedList.html#push-instance_method" title="Axlsx::SimpleTypedList#push (method)">#push</a></span>, <span class='object_link'><a href="SimpleTypedList.html#unlock-instance_method" title="Axlsx::SimpleTypedList#unlock (method)">#unlock</a></span></p> -<div id="constructor_details" class="method_details_list"> + <div id="constructor_details" class="method_details_list"> <h2>Constructor Details</h2> <p class="notice">This class inherits a constructor from <span class='object_link'><a href="CatAxisData.html#initialize-instance_method" title="Axlsx::CatAxisData#initialize (method)">Axlsx::CatAxisData</a></span></p> @@ -218,9 +211,8 @@ Serializes the value axis data. </p><div class="docstring"> <div class="discussion"> - <p> -Serializes the value axis data -</p> + +<p>Serializes the value axis data</p> </div> @@ -239,9 +231,8 @@ Serializes the value axis data — - <div class='inline'><p> -The document builder instance this objects xml will be added to. -</p> + <div class='inline'> +<p>The document builder instance this objects xml will be added to.</p> </div> </li> @@ -289,24 +280,23 @@ The document builder instance this objects xml will be added to. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/val_axis_data.rb', line 8</span> -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:val'</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:numRef'</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:f'</span><span class='comma token'>,</span> <span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='cell_range identifier id'>cell_range</span><span class='lparen token'>(</span><span class='@list ivar id'>@list</span><span class='rparen token'>)</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:numCache'</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:formatCode'</span><span class='comma token'>,</span> <span class='string val'>'General'</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:ptCount'</span><span class='comma token'>,</span> <span class='symbol val'>:val=</span><span class='gt op'>></span><span class='size identifier id'>size</span><span class='rparen token'>)</span> - <span class='each_with_index identifier id'>each_with_index</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='item identifier id'>item</span><span class='comma token'>,</span> <span class='index identifier id'>index</span><span class='bitor op'>|</span> - <span class='v identifier id'>v</span> <span class='assign token'>=</span> <span class='item identifier id'>item</span><span class='dot token'>.</span><span class='is_a? fid id'>is_a?</span><span class='lparen token'>(</span><span class='Cell constant id'>Cell</span><span class='rparen token'>)</span> <span class='question op'>?</span> <span class='item identifier id'>item</span><span class='dot token'>.</span><span class='value identifier id'>value</span> <span class='colon op'>:</span> <span class='item identifier id'>item</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:pt'</span><span class='comma token'>,</span> <span class='symbol val'>:idx=</span><span class='gt op'>></span><span class='index identifier id'>index</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:v'</span><span class='comma token'>,</span> <span class='v identifier id'>v</span><span class='rparen token'>)</span> - <span class='rbrace token'>}</span> - <span class='end end kw'>end</span> - <span class='rbrace token'>}</span> - <span class='rbrace token'>}</span> - <span class='rbrace token'>}</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:val</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:numRef</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:f</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='const'>Axlsx</span><span class='op'>::</span><span class='id cell_range'>cell_range</span><span class='lparen'>(</span><span class='ivar'>@list</span><span class='rparen'>)</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:numCache</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:formatCode</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>General</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:ptCount</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:val</span><span class='op'>=></span><span class='id size'>size</span><span class='rparen'>)</span> + <span class='id each_with_index'>each_with_index</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id item'>item</span><span class='comma'>,</span> <span class='id index'>index</span><span class='op'>|</span> + <span class='id v'>v</span> <span class='op'>=</span> <span class='id item'>item</span><span class='period'>.</span><span class='id is_a?'>is_a?</span><span class='lparen'>(</span><span class='const'>Cell</span><span class='rparen'>)</span> <span class='op'>?</span> <span class='id item'>item</span><span class='period'>.</span><span class='id value'>value</span> <span class='op'>:</span> <span class='id item'>item</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:pt</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:idx</span><span class='op'>=></span><span class='id index'>index</span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:v</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='id v'>v</span><span class='rparen'>)</span> + <span class='rbrace'>}</span> + <span class='kw'>end</span> + <span class='rbrace'>}</span> + <span class='rbrace'>}</span> + <span class='rbrace'>}</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -317,9 +307,9 @@ The document builder instance this objects xml will be added to. </div> <div id="footer"> - Generated on Wed Nov 23 22:21:01 2011 by + Generated on Sat Nov 26 13:16:38 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/View3D.html b/doc/Axlsx/View3D.html index 67681d0c..d884bc39 100644 --- a/doc/Axlsx/View3D.html +++ b/doc/Axlsx/View3D.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::View3D - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -94,9 +94,8 @@ <h2>Overview</h2><div class="docstring"> <div class="discussion"> - <p> -3D attributes for a chart. -</p> + +<p>3D attributes for a chart.</p> </div> @@ -112,9 +111,8 @@ <dt id="H_PERCENT_REGEX-constant" class="">H_PERCENT_REGEX = <div class="docstring"> <div class="discussion"> - <p> -Validation for hPercent -</p> + +<p>Validation for hPercent</p> </div> @@ -124,15 +122,13 @@ Validation for hPercent </div> </dt> - <dd><pre class="code"><span class='regexp val'>/0*(([5-9])|([1-9][0-9])|([1-4][0-9][0-9])|500)%/</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='regexp_beg'>/</span><span class='tstring_content'>0*(([5-9])|([1-9][0-9])|([1-4][0-9][0-9])|500)%</span><span class='regexp_end'>/</span></span></pre></dd> <dt id="DEPTH_PERCENT_REGEX-constant" class="">DEPTH_PERCENT_REGEX = <div class="docstring"> <div class="discussion"> - <p> -validation for depthPercent -</p> + +<p>validation for depthPercent</p> </div> @@ -142,8 +138,7 @@ validation for depthPercent </div> </dt> - <dd><pre class="code"><span class='regexp val'>/0*(([2-9][0-9])|([1-9][0-9][0-9])|(1[0-9][0-9][0-9])|2000)%/</span> -</pre></dd> + <dd><pre class="code"><span class='tstring'><span class='regexp_beg'>/</span><span class='tstring_content'>0*(([2-9][0-9])|([1-9][0-9][0-9])|(1[0-9][0-9][0-9])|2000)%</span><span class='regexp_end'>/</span></span></pre></dd> </dl> @@ -171,9 +166,8 @@ validation for depthPercent - <span class="summary_desc"><div class='inline'><p> -depth or chart as % of chart width must be between 20% and 2000%. -</p> + <span class="summary_desc"><div class='inline'> +<p>depth or chart as % of chart width must be between 20% and 2000%.</p> </div></span> </li> @@ -198,9 +192,8 @@ depth or chart as % of chart width must be between 20% and 2000%. - <span class="summary_desc"><div class='inline'><p> -height of chart as % of chart must be between 5% and 500%. -</p> + <span class="summary_desc"><div class='inline'> +<p>height of chart as % of chart must be between 5% and 500%.</p> </div></span> </li> @@ -225,9 +218,8 @@ height of chart as % of chart must be between 5% and 500%. - <span class="summary_desc"><div class='inline'><p> -field of view angle. -</p> + <span class="summary_desc"><div class='inline'> +<p>field of view angle.</p> </div></span> </li> @@ -252,9 +244,8 @@ field of view angle. - <span class="summary_desc"><div class='inline'><p> -Chart axis are at right angles. -</p> + <span class="summary_desc"><div class='inline'> +<p>Chart axis are at right angles.</p> </div></span> </li> @@ -279,9 +270,8 @@ Chart axis are at right angles. - <span class="summary_desc"><div class='inline'><p> -x rotation for the chart must be between -90 and 90. -</p> + <span class="summary_desc"><div class='inline'> +<p>x rotation for the chart must be between -90 and 90.</p> </div></span> </li> @@ -306,9 +296,8 @@ x rotation for the chart must be between -90 and 90. - <span class="summary_desc"><div class='inline'><p> -y rotation for the chart must be between 0 and 360. -</p> + <span class="summary_desc"><div class='inline'> +<p>y rotation for the chart must be between 0 and 360.</p> </div></span> </li> @@ -345,9 +334,8 @@ y rotation for the chart must be between 0 and 360. - <span class="summary_desc"><div class='inline'><p> -Creates a new View3D for charts. -</p> + <span class="summary_desc"><div class='inline'> +<p>Creates a new View3D for charts.</p> </div></span> </li> @@ -369,9 +357,8 @@ Creates a new View3D for charts. - <span class="summary_desc"><div class='inline'><p> -Serializes the view3D properties. -</p> + <span class="summary_desc"><div class='inline'> +<p>Serializes the view3D properties.</p> </div></span> </li> @@ -392,9 +379,8 @@ Serializes the view3D properties. </p><div class="docstring"> <div class="discussion"> - <p> -Creates a new View3D for charts -</p> + +<p>Creates a new View3D for charts</p> </div> @@ -415,9 +401,8 @@ Creates a new View3D for charts — - <div class='inline'><p> -a customizable set of options -</p> + <div class='inline'> +<p>a customizable set of options</p> </div> </li> @@ -498,17 +483,18 @@ a customizable set of options 47 48 49 -50</pre> +50 +51</pre> </td> <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/view_3D.rb', line 46</span> -<span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span><span class='lparen token'>(</span><span class='options identifier id'>options</span><span class='assign token'>=</span><span class='lbrace token'>{</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> - <span class='options identifier id'>options</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='o identifier id'>o</span><span class='bitor op'>|</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='dstring node'>"#{o[0]}="</span><span class='comma token'>,</span> <span class='o identifier id'>o</span><span class='lbrack token'>[</span><span class='integer val'>1</span><span class='rbrack token'>]</span><span class='rparen token'>)</span> <span class='if if_mod kw'>if</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='respond_to? fid id'>respond_to?</span> <span class='dstring node'>"#{o[0]}="</span> - <span class='end end kw'>end</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id initialize'>initialize</span><span class='lparen'>(</span><span class='id options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span> + <span class='ivar'>@rotX</span><span class='comma'>,</span> <span class='ivar'>@hPercent</span><span class='comma'>,</span> <span class='ivar'>@rotY</span><span class='comma'>,</span> <span class='ivar'>@depthPercent</span><span class='comma'>,</span> <span class='ivar'>@rAngAx</span><span class='comma'>,</span> <span class='ivar'>@perspective</span> <span class='op'>=</span> <span class='kw'>nil</span><span class='comma'>,</span> <span class='kw'>nil</span><span class='comma'>,</span> <span class='kw'>nil</span><span class='comma'>,</span> <span class='kw'>nil</span><span class='comma'>,</span> <span class='kw'>nil</span><span class='comma'>,</span> <span class='kw'>nil</span> + <span class='id options'>options</span><span class='period'>.</span><span class='id each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id o'>o</span><span class='op'>|</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span><span class='rbrace'>}</span><span class='tstring_content'>=</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>1</span><span class='rbracket'>]</span><span class='rparen'>)</span> <span class='kw'>if</span> <span class='kw'>self</span><span class='period'>.</span><span class='id respond_to?'>respond_to?</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span><span class='rbrace'>}</span><span class='tstring_content'>=</span><span class='tstring_end'>"</span></span> + <span class='kw'>end</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -531,9 +517,8 @@ a customizable set of options </p><div class="docstring"> <div class="discussion"> - <p> -depth or chart as % of chart width must be between 20% and 2000% -</p> + +<p>depth or chart as % of chart width must be between 20% and 2000%</p> </div> @@ -567,10 +552,9 @@ depth or chart as % of chart width must be between 20% and 2000% <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/view_3D.rb', line 29</span> -<span class='def def kw'>def</span> <span class='depthPercent identifier id'>depthPercent</span> - <span class='@depthPercent ivar id'>@depthPercent</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id depthPercent'>depthPercent</span> + <span class='ivar'>@depthPercent</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -588,9 +572,8 @@ depth or chart as % of chart width must be between 20% and 2000% </p><div class="docstring"> <div class="discussion"> - <p> -height of chart as % of chart must be between 5% and 500% -</p> + +<p>height of chart as % of chart must be between 5% and 500%</p> </div> @@ -624,10 +607,9 @@ height of chart as % of chart must be between 5% and 500% <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/view_3D.rb', line 19</span> -<span class='def def kw'>def</span> <span class='hPercent identifier id'>hPercent</span> - <span class='@hPercent ivar id'>@hPercent</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id hPercent'>hPercent</span> + <span class='ivar'>@hPercent</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -645,9 +627,8 @@ height of chart as % of chart must be between 5% and 500% </p><div class="docstring"> <div class="discussion"> - <p> -field of view angle -</p> + +<p>field of view angle</p> </div> @@ -681,10 +662,9 @@ field of view angle <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/view_3D.rb', line 37</span> -<span class='def def kw'>def</span> <span class='perspective identifier id'>perspective</span> - <span class='@perspective ivar id'>@perspective</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id perspective'>perspective</span> + <span class='ivar'>@perspective</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -702,9 +682,8 @@ field of view angle </p><div class="docstring"> <div class="discussion"> - <p> -Chart axis are at right angles -</p> + +<p>Chart axis are at right angles</p> </div> @@ -738,10 +717,9 @@ Chart axis are at right angles <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/view_3D.rb', line 33</span> -<span class='def def kw'>def</span> <span class='rAngAx identifier id'>rAngAx</span> - <span class='@rAngAx ivar id'>@rAngAx</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id rAngAx'>rAngAx</span> + <span class='ivar'>@rAngAx</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -759,9 +737,8 @@ Chart axis are at right angles </p><div class="docstring"> <div class="discussion"> - <p> -x rotation for the chart must be between -90 and 90 -</p> + +<p>x rotation for the chart must be between -90 and 90</p> </div> @@ -795,10 +772,9 @@ x rotation for the chart must be between -90 and 90 <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/view_3D.rb', line 14</span> -<span class='def def kw'>def</span> <span class='rotX identifier id'>rotX</span> - <span class='@rotX ivar id'>@rotX</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id rotX'>rotX</span> + <span class='ivar'>@rotX</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -816,9 +792,8 @@ x rotation for the chart must be between -90 and 90 </p><div class="docstring"> <div class="discussion"> - <p> -y rotation for the chart must be between 0 and 360 -</p> + +<p>y rotation for the chart must be between 0 and 360</p> </div> @@ -852,10 +827,9 @@ y rotation for the chart must be between 0 and 360 <td> <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/view_3D.rb', line 24</span> -<span class='def def kw'>def</span> <span class='rotY identifier id'>rotY</span> - <span class='@rotY ivar id'>@rotY</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id rotY'>rotY</span> + <span class='ivar'>@rotY</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -877,9 +851,8 @@ y rotation for the chart must be between 0 and 360 </p><div class="docstring"> <div class="discussion"> - <p> -Serializes the view3D properties -</p> + +<p>Serializes the view3D properties</p> </div> @@ -898,9 +871,8 @@ Serializes the view3D properties — - <div class='inline'><p> -The document builder instance this objects xml will be added to. -</p> + <div class='inline'> +<p>The document builder instance this objects xml will be added to.</p> </div> </li> @@ -927,31 +899,30 @@ The document builder instance this objects xml will be added to. <pre class="lines"> -67 -68 -69 -70 -71 -72 -73 74 75 -76</pre> +76 +77 +78 +79 +80 +81 +82 +83</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/view_3D.rb', line 67</span> - -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:view3D'</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:rotX'</span><span class='comma token'>,</span> <span class='symbol val'>:val=</span><span class='gt op'>></span><span class='@rotX ivar id'>@rotX</span><span class='rparen token'>)</span> <span class='unless unless_mod kw'>unless</span> <span class='@rotX ivar id'>@rotX</span><span class='dot token'>.</span><span class='nil? fid id'>nil?</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:hPercent'</span><span class='comma token'>,</span> <span class='symbol val'>:val=</span><span class='gt op'>></span><span class='@hPercent ivar id'>@hPercent</span><span class='rparen token'>)</span> <span class='unless unless_mod kw'>unless</span> <span class='@hPercent ivar id'>@hPercent</span><span class='dot token'>.</span><span class='nil? fid id'>nil?</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:rotY'</span><span class='comma token'>,</span> <span class='symbol val'>:val=</span><span class='gt op'>></span><span class='@rotY ivar id'>@rotY</span><span class='rparen token'>)</span> <span class='unless unless_mod kw'>unless</span> <span class='@rotY ivar id'>@rotY</span><span class='dot token'>.</span><span class='nil? fid id'>nil?</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:depthPercent'</span><span class='comma token'>,</span> <span class='symbol val'>:val=</span><span class='gt op'>></span><span class='@depthPercent ivar id'>@depthPercent</span><span class='rparen token'>)</span> <span class='unless unless_mod kw'>unless</span> <span class='@depthPercent ivar id'>@depthPercent</span><span class='dot token'>.</span><span class='nil? fid id'>nil?</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:rAngAx'</span><span class='comma token'>,</span> <span class='symbol val'>:val=</span><span class='gt op'>></span><span class='@rAngAx ivar id'>@rAngAx</span><span class='rparen token'>)</span> <span class='unless unless_mod kw'>unless</span> <span class='@rAngAx ivar id'>@rAngAx</span><span class='dot token'>.</span><span class='nil? fid id'>nil?</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='string val'>'c:perspective'</span><span class='comma token'>,</span> <span class='symbol val'>:val=</span><span class='gt op'>></span><span class='@perspective ivar id'>@perspective</span><span class='rparen token'>)</span> <span class='unless unless_mod kw'>unless</span> <span class='@perspective ivar id'>@perspective</span><span class='dot token'>.</span><span class='nil? fid id'>nil?</span> - <span class='rbrace token'>}</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/drawing/view_3D.rb', line 74</span> + +<span class='kw'>def</span> <span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:view3D</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:rotX</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:val</span><span class='op'>=></span><span class='ivar'>@rotX</span><span class='rparen'>)</span> <span class='kw'>unless</span> <span class='ivar'>@rotX</span><span class='period'>.</span><span class='id nil?'>nil?</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:hPercent</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:val</span><span class='op'>=></span><span class='ivar'>@hPercent</span><span class='rparen'>)</span> <span class='kw'>unless</span> <span class='ivar'>@hPercent</span><span class='period'>.</span><span class='id nil?'>nil?</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:rotY</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:val</span><span class='op'>=></span><span class='ivar'>@rotY</span><span class='rparen'>)</span> <span class='kw'>unless</span> <span class='ivar'>@rotY</span><span class='period'>.</span><span class='id nil?'>nil?</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:depthPercent</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:val</span><span class='op'>=></span><span class='ivar'>@depthPercent</span><span class='rparen'>)</span> <span class='kw'>unless</span> <span class='ivar'>@depthPercent</span><span class='period'>.</span><span class='id nil?'>nil?</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:rAngAx</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:val</span><span class='op'>=></span><span class='ivar'>@rAngAx</span><span class='rparen'>)</span> <span class='kw'>unless</span> <span class='ivar'>@rAngAx</span><span class='period'>.</span><span class='id nil?'>nil?</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>c:perspective</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:val</span><span class='op'>=></span><span class='ivar'>@perspective</span><span class='rparen'>)</span> <span class='kw'>unless</span> <span class='ivar'>@perspective</span><span class='period'>.</span><span class='id nil?'>nil?</span> + <span class='rbrace'>}</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -962,9 +933,9 @@ The document builder instance this objects xml will be added to. </div> <div id="footer"> - Generated on Wed Nov 23 22:20:54 2011 by + Generated on Sat Nov 26 13:16:37 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/Workbook.html b/doc/Axlsx/Workbook.html index f1e19bd0..69e4e8e0 100644 --- a/doc/Axlsx/Workbook.html +++ b/doc/Axlsx/Workbook.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::Workbook - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -94,33 +94,31 @@ <h2>Overview</h2><div class="docstring"> <div class="discussion"> - <p> -The Workbook class is an xlsx workbook that manages worksheets, charts, + +<p>The Workbook class is an xlsx workbook that manages worksheets, charts, drawings and styles. The following parts of the Office Open XML spreadsheet -specification are not implimented in this version. -</p> -<pre class="code"> - <span class='bookViews identifier id'>bookViews</span> - <span class='calcPr identifier id'>calcPr</span> - <span class='customWorkbookViews identifier id'>customWorkbookViews</span> - <span class='definedNames identifier id'>definedNames</span> - <span class='externalReferences identifier id'>externalReferences</span> - <span class='extLst identifier id'>extLst</span> - <span class='fileRecoveryPr identifier id'>fileRecoveryPr</span> - <span class='fileSharing identifier id'>fileSharing</span> - <span class='fileVersion identifier id'>fileVersion</span> - <span class='functionGroups identifier id'>functionGroups</span> - <span class='oleSize identifier id'>oleSize</span> - <span class='pivotCaches identifier id'>pivotCaches</span> - <span class='smartTagPr identifier id'>smartTagPr</span> - <span class='smartTagTypes identifier id'>smartTagTypes</span> - <span class='webPublishing identifier id'>webPublishing</span> - <span class='webPublishObjects identifier id'>webPublishObjects</span> - <span class='workbookProtection identifier id'>workbookProtection</span> - <span class='workbookPr identifier id'>workbookPr</span><span class='mult op'>*</span> - - <span class='mult op'>*</span><span class='workbookPr identifier id'>workbookPr</span> <span class='is identifier id'>is</span> <span class='only identifier id'>only</span> <span class='supported identifier id'>supported</span> <span class='to identifier id'>to</span> <span class='the identifier id'>the</span> <span class='extend identifier id'>extend</span> <span class='of identifier id'>of</span> <span class='date1904 identifier id'>date1904</span> -</pre> +specification are not implimented in this version.</p> + +<pre class="code">bookViews +calcPr +customWorkbookViews +definedNames +externalReferences +extLst +fileRecoveryPr +fileSharing +fileVersion +functionGroups +oleSize +pivotCaches +smartTagPr +smartTagTypes +webPublishing +webPublishObjects +workbookProtection +workbookPr* + +*workbookPr is only supported to the extend of date1904</pre> </div> @@ -136,10 +134,9 @@ specification are not implimented in this version. <dt id="date1904-classvariable" class="">@@date1904 = <div class="docstring"> <div class="discussion"> - <p> -Indicates if the epoc date for serialization should be 1904. If false, 1900 -is used. -</p> + +<p>Indicates if the epoc date for serialization should be 1904. If false, 1900 +is used.</p> </div> @@ -149,8 +146,7 @@ is used. </div> </dt> - <dd><pre class="code"><span class='false false kw'>false</span> -</pre></dd> + <dd><pre class="code"><span class='kw'>false</span></pre></dd> </dl> @@ -178,9 +174,8 @@ is used. - <span class="summary_desc"><div class='inline'><p> -A colllection of charts associated with this workbook. -</p> + <span class="summary_desc"><div class='inline'> +<p>A colllection of charts associated with this workbook.</p> </div></span> </li> @@ -189,14 +184,14 @@ A colllection of charts associated with this workbook. <li class="public "> <span class="summary_signature"> - <a href="#date1904-instance_method" title="#date1904 (instance method)">- (Boolean) <strong>date1904</strong> </a> + <a href="#drawings-instance_method" title="#drawings (instance method)">- (SimpleTypedList) <strong>drawings</strong> </a> </span> - + <span class="note title readonly">readonly</span> @@ -205,9 +200,8 @@ A colllection of charts associated with this workbook. - <span class="summary_desc"><div class='inline'><p> -Instance level access to the class variable 1904. -</p> + <span class="summary_desc"><div class='inline'> +<p>A colllection of drawings associated with this workbook.</p> </div></span> </li> @@ -216,7 +210,7 @@ Instance level access to the class variable 1904. <li class="public "> <span class="summary_signature"> - <a href="#drawings-instance_method" title="#drawings (instance method)">- (SimpleTypedList) <strong>drawings</strong> </a> + <a href="#images-instance_method" title="#images (instance method)">- (SimpleTypedList) <strong>images</strong> </a> @@ -232,9 +226,8 @@ Instance level access to the class variable 1904. - <span class="summary_desc"><div class='inline'><p> -A colllection of drawings associated with this workbook. -</p> + <span class="summary_desc"><div class='inline'> +<p>A colllection of images associated with this workbook.</p> </div></span> </li> @@ -243,7 +236,7 @@ A colllection of drawings associated with this workbook. <li class="public "> <span class="summary_signature"> - <a href="#images-instance_method" title="#images (instance method)">- (SimpleTypedList) <strong>images</strong> </a> + <a href="#styles-instance_method" title="#styles (instance method)">- (Styles) <strong>styles</strong> </a> @@ -259,9 +252,8 @@ A colllection of drawings associated with this workbook. - <span class="summary_desc"><div class='inline'><p> -A colllection of images associated with this workbook. -</p> + <span class="summary_desc"><div class='inline'> +<p>The styles associated with this workbook.</p> </div></span> </li> @@ -270,7 +262,7 @@ A colllection of images associated with this workbook. <li class="public "> <span class="summary_signature"> - <a href="#relationships-instance_method" title="#relationships (instance method)">- (Relationships) <strong>relationships</strong> </a> + <a href="#worksheets-instance_method" title="#worksheets (instance method)">- (SimpleTypedList) <strong>worksheets</strong> </a> @@ -286,76 +278,76 @@ A colllection of images associated with this workbook. - <span class="summary_desc"><div class='inline'><p> -The workbook relationships. -</p> + <span class="summary_desc"><div class='inline'> +<p>A collection of worksheets associated with this workbook.</p> </div></span> </li> - <li class="public "> + </ul> + + + + + + <h2> + Class Method Summary + <small>(<a href="#" class="summary_toggle">collapse</a>)</small> + </h2> + + <ul class="summary"> + + <li class="public "> <span class="summary_signature"> - <a href="#styles-instance_method" title="#styles (instance method)">- (Styles) <strong>styles</strong> </a> + <a href="#date1904-class_method" title="date1904 (class method)">+ (Boolean) <strong>date1904</strong> </a> </span> - <span class="note title readonly">readonly</span> - - - <span class="summary_desc"><div class='inline'><p> -The styles associated with this workbook. -</p> + <span class="summary_desc"><div class='inline'> +<p>retrieves the date1904 attribute.</p> </div></span> </li> - - <li class="public "> + + <li class="public "> <span class="summary_signature"> - <a href="#worksheets-instance_method" title="#worksheets (instance method)">- (SimpleTypedList) <strong>worksheets</strong> </a> + <a href="#date1904%3D-class_method" title="date1904= (class method)">+ (Boolean) <strong>date1904=</strong>(v) </a> </span> - <span class="note title readonly">readonly</span> - - - <span class="summary_desc"><div class='inline'><p> -A collection of worksheets associated with this workbook. -</p> + <span class="summary_desc"><div class='inline'> +<p>Sets the date1904 attribute to the provided boolean.</p> </div></span> </li> - - </ul> - - - - + + </ul> <h2> - Class Method Summary + Instance Method Summary <small>(<a href="#" class="summary_toggle">collapse</a>)</small> </h2> @@ -364,7 +356,7 @@ A collection of worksheets associated with this workbook. <li class="public "> <span class="summary_signature"> - <a href="#date1904-class_method" title="date1904 (class method)">+ (Boolean) <strong>date1904</strong> </a> + <a href="#add_worksheet-instance_method" title="#add_worksheet (instance method)">- (Worksheet) <strong>add_worksheet</strong>(options = {}) {|worksheet| ... }</a> @@ -377,9 +369,8 @@ A collection of worksheets associated with this workbook. - <span class="summary_desc"><div class='inline'><p> -retrieves the date1904 attribute. -</p> + <span class="summary_desc"><div class='inline'> +<p>Adds a worksheet to this workbook.</p> </div></span> </li> @@ -388,7 +379,7 @@ retrieves the date1904 attribute. <li class="public "> <span class="summary_signature"> - <a href="#date1904%3D-class_method" title="date1904= (class method)">+ (Boolean) <strong>date1904=</strong>(v) </a> + <a href="#date1904-instance_method" title="#date1904 (instance method)">- (Boolean) <strong>date1904</strong> </a> @@ -401,27 +392,17 @@ retrieves the date1904 attribute. - <span class="summary_desc"><div class='inline'><p> -Sets the date1904 attribute to the provided boolean. -</p> + <span class="summary_desc"><div class='inline'> +<p>Instance level access to the class variable 1904.</p> </div></span> </li> - </ul> - - <h2> - Instance Method Summary - <small>(<a href="#" class="summary_toggle">collapse</a>)</small> - </h2> - - <ul class="summary"> - <li class="public "> <span class="summary_signature"> - <a href="#add_worksheet-instance_method" title="#add_worksheet (instance method)">- (Worksheet) <strong>add_worksheet</strong>(options = {}) {|worksheet| ... }</a> + <a href="#date1904%3D-instance_method" title="#date1904= (instance method)">- (Object) <strong>date1904=</strong>(v) </a> @@ -434,9 +415,8 @@ Sets the date1904 attribute to the provided boolean. - <span class="summary_desc"><div class='inline'><p> -Adds a worksheet to this workbook. -</p> + <span class="summary_desc"><div class='inline'> +<p>see @date1904.</p> </div></span> </li> @@ -460,9 +440,31 @@ Adds a worksheet to this workbook. - <span class="summary_desc"><div class='inline'><p> -Creates a new Workbook. -</p> + <span class="summary_desc"><div class='inline'> +<p>Creates a new Workbook.</p> +</div></span> + +</li> + + + <li class="public "> + <span class="summary_signature"> + + <a href="#relationships-instance_method" title="#relationships (instance method)">- (Relationships) <strong>relationships</strong> </a> + + + + </span> + + + + + + + + + <span class="summary_desc"><div class='inline'> +<p>The workbook relationships.</p> </div></span> </li> @@ -484,9 +486,8 @@ Creates a new Workbook. - <span class="summary_desc"><div class='inline'><p> -Serializes the workbook document. -</p> + <span class="summary_desc"><div class='inline'> +<p>Serializes the workbook document.</p> </div></span> </li> @@ -507,9 +508,8 @@ Serializes the workbook document. </p><div class="docstring"> <div class="discussion"> - <p> -Creates a new Workbook -</p> + +<p>Creates a new Workbook</p> </div> @@ -530,9 +530,8 @@ Creates a new Workbook — - <div class='inline'><p> -a customizable set of options -</p> + <div class='inline'> +<p>a customizable set of options</p> </div> </li> @@ -583,9 +582,8 @@ a customizable set of options — - <div class='inline'><p> -the object that the method was called on -</p> + <div class='inline'> +<p>the object that the method was called on</p> </div> </li> @@ -598,29 +596,28 @@ the object that the method was called on <pre class="lines"> +75 +76 +77 +78 +79 +80 +81 82 -83 -84 -85 -86 -87 -88 -89 -90</pre> +83</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/workbook.rb', line 82</span> - -<span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span><span class='lparen token'>(</span><span class='options identifier id'>options</span><span class='assign token'>=</span><span class='lbrace token'>{</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> - <span class='@styles ivar id'>@styles</span> <span class='assign token'>=</span> <span class='Styles constant id'>Styles</span><span class='dot token'>.</span><span class='new identifier id'>new</span> - <span class='@worksheets ivar id'>@worksheets</span> <span class='assign token'>=</span> <span class='SimpleTypedList constant id'>SimpleTypedList</span><span class='dot token'>.</span><span class='new identifier id'>new</span> <span class='Worksheet constant id'>Worksheet</span> - <span class='@drawings ivar id'>@drawings</span> <span class='assign token'>=</span> <span class='SimpleTypedList constant id'>SimpleTypedList</span><span class='dot token'>.</span><span class='new identifier id'>new</span> <span class='Drawing constant id'>Drawing</span> - <span class='@charts ivar id'>@charts</span> <span class='assign token'>=</span> <span class='SimpleTypedList constant id'>SimpleTypedList</span><span class='dot token'>.</span><span class='new identifier id'>new</span> <span class='Chart constant id'>Chart</span> - <span class='@images ivar id'>@images</span> <span class='assign token'>=</span> <span class='SimpleTypedList constant id'>SimpleTypedList</span><span class='dot token'>.</span><span class='new identifier id'>new</span> <span class='Pic constant id'>Pic</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='date1904 identifier id'>date1904</span><span class='assign token'>=</span> <span class='options identifier id'>options</span><span class='lbrack token'>[</span><span class='symbol val'>:date1904</span><span class='rbrack token'>]</span> <span class='unless unless_mod kw'>unless</span> <span class='options identifier id'>options</span><span class='lbrack token'>[</span><span class='symbol val'>:date1904</span><span class='rbrack token'>]</span><span class='dot token'>.</span><span class='nil? fid id'>nil?</span> - <span class='yield yield kw'>yield</span> <span class='self self kw'>self</span> <span class='if if_mod kw'>if</span> <span class='block_given? fid id'>block_given?</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/workbook.rb', line 75</span> + +<span class='kw'>def</span> <span class='id initialize'>initialize</span><span class='lparen'>(</span><span class='id options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span> + <span class='ivar'>@styles</span> <span class='op'>=</span> <span class='const'>Styles</span><span class='period'>.</span><span class='id new'>new</span> + <span class='ivar'>@worksheets</span> <span class='op'>=</span> <span class='const'>SimpleTypedList</span><span class='period'>.</span><span class='id new'>new</span> <span class='const'>Worksheet</span> + <span class='ivar'>@drawings</span> <span class='op'>=</span> <span class='const'>SimpleTypedList</span><span class='period'>.</span><span class='id new'>new</span> <span class='const'>Drawing</span> + <span class='ivar'>@charts</span> <span class='op'>=</span> <span class='const'>SimpleTypedList</span><span class='period'>.</span><span class='id new'>new</span> <span class='const'>Chart</span> + <span class='ivar'>@images</span> <span class='op'>=</span> <span class='const'>SimpleTypedList</span><span class='period'>.</span><span class='id new'>new</span> <span class='const'>Pic</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id date1904'>date1904</span><span class='op'>=</span> <span class='id options'>options</span><span class='lbracket'>[</span><span class='symbol'>:date1904</span><span class='rbracket'>]</span> <span class='kw'>unless</span> <span class='id options'>options</span><span class='lbracket'>[</span><span class='symbol'>:date1904</span><span class='rbracket'>]</span><span class='period'>.</span><span class='id nil?'>nil?</span> + <span class='kw'>yield</span> <span class='kw'>self</span> <span class='kw'>if</span> <span class='id block_given?'>block_given?</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -646,15 +643,13 @@ the object that the method was called on <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -The recommended way to manage charts is Worksheet#add_chart -</p> + <div class='inline'> +<p>The recommended way to manage charts is Worksheet#add_chart</p> </div> </div> -<p> -A colllection of charts associated with this workbook -</p> + +<p>A colllection of charts associated with this workbook</p> </div> @@ -697,63 +692,9 @@ A colllection of charts associated with this workbook <td> <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/workbook.rb', line 45</span> -<span class='def def kw'>def</span> <span class='charts identifier id'>charts</span> - <span class='@charts ivar id'>@charts</span> -<span class='end end kw'>end</span> -</pre> - </td> - </tr> -</table> -</div> - - - <span id="date1904=-instance_method"></span> - <span id="date1904-instance_method"></span> - <div class="method_details "> - <p class="signature " id="date1904-instance_method"> - - - (<tt>Boolean</tt>) <strong>date1904</strong> - - - -</p><div class="docstring"> - <div class="discussion"> - <p> -Instance level access to the class variable 1904 -</p> - - - </div> -</div> -<div class="tags"> - -<h3>Returns:</h3> -<ul class="return"> - - <li> - - - <span class='type'>(<tt>Boolean</tt>)</span> - - - - </li> - -</ul> - -</div><table class="source_code"> - <tr> - <td> - <pre class="lines"> - - -74</pre> - </td> - <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/workbook.rb', line 74</span> - -<span class='def def kw'>def</span> <span class='date1904 identifier id'>date1904</span><span class='lparen token'>(</span><span class='rparen token'>)</span> <span class='@@date1904 ivar id'>@@date1904</span><span class='semicolon token'>;</span> <span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id charts'>charts</span> + <span class='ivar'>@charts</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -774,15 +715,13 @@ Instance level access to the class variable 1904 <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -The recommended way to manage drawings is Worksheet#add_chart -</p> + <div class='inline'> +<p>The recommended way to manage drawings is Worksheet#add_chart</p> </div> </div> -<p> -A colllection of drawings associated with this workbook -</p> + +<p>A colllection of drawings associated with this workbook</p> </div> @@ -825,10 +764,9 @@ A colllection of drawings associated with this workbook <td> <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/workbook.rb', line 59</span> -<span class='def def kw'>def</span> <span class='drawings identifier id'>drawings</span> - <span class='@drawings ivar id'>@drawings</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id drawings'>drawings</span> + <span class='ivar'>@drawings</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -849,15 +787,13 @@ A colllection of drawings associated with this workbook <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -The recommended way to manage images is Worksheet#add_image -</p> + <div class='inline'> +<p>The recommended way to manage images is Worksheet#add_image</p> </div> </div> -<p> -A colllection of images associated with this workbook -</p> + +<p>A colllection of images associated with this workbook</p> </div> @@ -900,77 +836,9 @@ A colllection of images associated with this workbook <td> <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/workbook.rb', line 52</span> -<span class='def def kw'>def</span> <span class='images identifier id'>images</span> - <span class='@images ivar id'>@images</span> -<span class='end end kw'>end</span> -</pre> - </td> - </tr> -</table> -</div> - - - <span id=""></span> - <span id="relationships-instance_method"></span> - <div class="method_details "> - <p class="signature " id="relationships-instance_method"> - - - (<tt><span class='object_link'><a href="Relationships.html" title="Axlsx::Relationships (class)">Relationships</a></span></tt>) <strong>relationships</strong> <span class="extras">(readonly)</span> - - - -</p><div class="docstring"> - <div class="discussion"> - <p> -The workbook relationships. This is managed automatically by the workbook -</p> - - - </div> -</div> -<div class="tags"> - -<h3>Returns:</h3> -<ul class="return"> - - <li> - - - <span class='type'>(<tt><span class='object_link'><a href="Relationships.html" title="Axlsx::Relationships (class)">Relationships</a></span></tt>)</span> - - - - </li> - -</ul> - -</div><table class="source_code"> - <tr> - <td> - <pre class="lines"> - - -70 -71 -72 -73 -74 -75 -76 -77</pre> - </td> - <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/workbook.rb', line 70</span> - -<span class='def def kw'>def</span> <span class='relationships identifier id'>relationships</span> - <span class='r identifier id'>r</span> <span class='assign token'>=</span> <span class='Relationships constant id'>Relationships</span><span class='dot token'>.</span><span class='new identifier id'>new</span> - <span class='@worksheets ivar id'>@worksheets</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='sheet identifier id'>sheet</span><span class='bitor op'>|</span> - <span class='r identifier id'>r</span> <span class='lshft op'><<</span> <span class='Relationship constant id'>Relationship</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='WORKSHEET_R constant id'>WORKSHEET_R</span><span class='comma token'>,</span> <span class='WORKSHEET_PN constant id'>WORKSHEET_PN</span> <span class='mod op'>%</span> <span class='lparen token'>(</span><span class='r identifier id'>r</span><span class='dot token'>.</span><span class='size identifier id'>size</span><span class='plus op'>+</span><span class='integer val'>1</span><span class='rparen token'>)</span><span class='rparen token'>)</span> - <span class='end end kw'>end</span> - <span class='r identifier id'>r</span> <span class='lshft op'><<</span> <span class='Relationship constant id'>Relationship</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='STYLES_R constant id'>STYLES_R</span><span class='comma token'>,</span> <span class='STYLES_PN constant id'>STYLES_PN</span><span class='rparen token'>)</span> - <span class='r identifier id'>r</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id images'>images</span> + <span class='ivar'>@images</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -991,15 +859,13 @@ The workbook relationships. This is managed automatically by the workbook <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -The recommended way to manage styles is Styles#add_style -</p> + <div class='inline'> +<p>The recommended way to manage styles is Styles#add_style</p> </div> </div> -<p> -The styles associated with this workbook -</p> + +<p>The styles associated with this workbook</p> </div> @@ -1042,10 +908,9 @@ The styles associated with this workbook <td> <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/workbook.rb', line 66</span> -<span class='def def kw'>def</span> <span class='styles identifier id'>styles</span> - <span class='@styles ivar id'>@styles</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id styles'>styles</span> + <span class='ivar'>@styles</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1066,15 +931,13 @@ The styles associated with this workbook <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -The recommended way to manage worksheets is add_worksheet -</p> + <div class='inline'> +<p>The recommended way to manage worksheets is add_worksheet</p> </div> </div> -<p> -A collection of worksheets associated with this workbook. -</p> + +<p>A collection of worksheets associated with this workbook.</p> </div> @@ -1117,10 +980,9 @@ A collection of worksheets associated with this workbook. <td> <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/workbook.rb', line 38</span> -<span class='def def kw'>def</span> <span class='worksheets identifier id'>worksheets</span> - <span class='@worksheets ivar id'>@worksheets</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id worksheets'>worksheets</span> + <span class='ivar'>@worksheets</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1142,9 +1004,8 @@ A collection of worksheets associated with this workbook. </p><div class="docstring"> <div class="discussion"> - <p> -retrieves the date1904 attribute -</p> + +<p>retrieves the date1904 attribute</p> </div> @@ -1171,13 +1032,12 @@ retrieves the date1904 attribute <pre class="lines"> -101</pre> +98</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/workbook.rb', line 101</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/workbook.rb', line 98</span> -<span class='def def kw'>def</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='date1904 identifier id'>date1904</span><span class='lparen token'>(</span><span class='rparen token'>)</span> <span class='@@date1904 ivar id'>@@date1904</span><span class='semicolon token'>;</span> <span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id date1904'>date1904</span><span class='lparen'>(</span><span class='rparen'>)</span> <span class='cvar'>@@date1904</span><span class='semicolon'>;</span> <span class='kw'>end</span></pre> </td> </tr> </table> @@ -1192,9 +1052,8 @@ retrieves the date1904 attribute </p><div class="docstring"> <div class="discussion"> - <p> -Sets the date1904 attribute to the provided boolean -</p> + +<p>Sets the date1904 attribute to the provided boolean</p> </div> @@ -1221,13 +1080,12 @@ Sets the date1904 attribute to the provided boolean <pre class="lines"> -97</pre> +94</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/workbook.rb', line 97</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/workbook.rb', line 94</span> -<span class='def def kw'>def</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='date1904 identifier id'>date1904</span><span class='assign token'>=</span><span class='lparen token'>(</span><span class='v identifier id'>v</span><span class='rparen token'>)</span> <span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='validate_boolean identifier id'>validate_boolean</span> <span class='v identifier id'>v</span><span class='semicolon token'>;</span> <span class='@@date1904 ivar id'>@@date1904</span> <span class='assign token'>=</span> <span class='v identifier id'>v</span> <span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id date1904='>date1904=</span><span class='lparen'>(</span><span class='id v'>v</span><span class='rparen'>)</span> <span class='const'>Axlsx</span><span class='op'>::</span><span class='id validate_boolean'>validate_boolean</span> <span class='id v'>v</span><span class='semicolon'>;</span> <span class='cvar'>@@date1904</span> <span class='op'>=</span> <span class='id v'>v</span><span class='semicolon'>;</span> <span class='kw'>end</span></pre> </td> </tr> </table> @@ -1248,9 +1106,8 @@ Sets the date1904 attribute to the provided boolean </p><div class="docstring"> <div class="discussion"> - <p> -Adds a worksheet to this workbook -</p> + +<p>Adds a worksheet to this workbook</p> </div> @@ -1271,9 +1128,8 @@ Adds a worksheet to this workbook — - <div class='inline'><p> -a customizable set of options -</p> + <div class='inline'> +<p>a customizable set of options</p> </div> </li> @@ -1292,9 +1148,8 @@ a customizable set of options <span class="default"> </span> - — <div class='inline'><p> -The name of the worksheet. -</p> + — <div class='inline'> +<p>The name of the worksheet.</p> </div> </li> @@ -1341,21 +1196,165 @@ The name of the worksheet. <pre class="lines"> +104 +105 +106 107 -108 -109 -110 -111</pre> +108</pre> + </td> + <td> + <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/workbook.rb', line 104</span> + +<span class='kw'>def</span> <span class='id add_worksheet'>add_worksheet</span><span class='lparen'>(</span><span class='id options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span> + <span class='id worksheet'>worksheet</span> <span class='op'>=</span> <span class='const'>Worksheet</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='kw'>self</span><span class='comma'>,</span> <span class='id options'>options</span><span class='rparen'>)</span> + <span class='kw'>yield</span> <span class='id worksheet'>worksheet</span> <span class='kw'>if</span> <span class='id block_given?'>block_given?</span> + <span class='id worksheet'>worksheet</span> +<span class='kw'>end</span></pre> + </td> + </tr> +</table> +</div> + + <div class="method_details "> + <p class="signature " id="date1904-instance_method"> + + - (<tt>Boolean</tt>) <strong>date1904</strong> + + + +</p><div class="docstring"> + <div class="discussion"> + +<p>Instance level access to the class variable 1904</p> + + + </div> +</div> +<div class="tags"> + +<h3>Returns:</h3> +<ul class="return"> + + <li> + + + <span class='type'>(<tt>Boolean</tt>)</span> + + + + </li> + +</ul> + +</div><table class="source_code"> + <tr> + <td> + <pre class="lines"> + + +87</pre> + </td> + <td> + <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/workbook.rb', line 87</span> + +<span class='kw'>def</span> <span class='id date1904'>date1904</span><span class='lparen'>(</span><span class='rparen'>)</span> <span class='cvar'>@@date1904</span><span class='semicolon'>;</span> <span class='kw'>end</span></pre> + </td> + </tr> +</table> +</div> + + <div class="method_details "> + <p class="signature " id="date1904=-instance_method"> + + - (<tt>Object</tt>) <strong>date1904=</strong>(v) + + + +</p><div class="docstring"> + <div class="discussion"> + +<p>see @date1904</p> + + + </div> +</div> +<div class="tags"> + + +</div><table class="source_code"> + <tr> + <td> + <pre class="lines"> + + +90</pre> + </td> + <td> + <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/workbook.rb', line 90</span> + +<span class='kw'>def</span> <span class='id date1904='>date1904=</span><span class='lparen'>(</span><span class='id v'>v</span><span class='rparen'>)</span> <span class='const'>Axlsx</span><span class='op'>::</span><span class='id validate_boolean'>validate_boolean</span> <span class='id v'>v</span><span class='semicolon'>;</span> <span class='cvar'>@@date1904</span> <span class='op'>=</span> <span class='id v'>v</span><span class='semicolon'>;</span> <span class='kw'>end</span></pre> + </td> + </tr> +</table> +</div> + + <div class="method_details "> + <p class="signature " id="relationships-instance_method"> + + - (<tt><span class='object_link'><a href="Relationships.html" title="Axlsx::Relationships (class)">Relationships</a></span></tt>) <strong>relationships</strong> + + + +</p><div class="docstring"> + <div class="discussion"> + +<p>The workbook relationships. This is managed automatically by the workbook</p> + + + </div> +</div> +<div class="tags"> + +<h3>Returns:</h3> +<ul class="return"> + + <li> + + + <span class='type'>(<tt><span class='object_link'><a href="Relationships.html" title="Axlsx::Relationships (class)">Relationships</a></span></tt>)</span> + + + + </li> + +</ul> + +</div><table class="source_code"> + <tr> + <td> + <pre class="lines"> + + +112 +113 +114 +115 +116 +117 +118 +119</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/workbook.rb', line 107</span> - -<span class='def def kw'>def</span> <span class='add_worksheet identifier id'>add_worksheet</span><span class='lparen token'>(</span><span class='options identifier id'>options</span><span class='assign token'>=</span><span class='lbrace token'>{</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> - <span class='worksheet identifier id'>worksheet</span> <span class='assign token'>=</span> <span class='Worksheet constant id'>Worksheet</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='self self kw'>self</span><span class='comma token'>,</span> <span class='options identifier id'>options</span><span class='rparen token'>)</span> - <span class='yield yield kw'>yield</span> <span class='worksheet identifier id'>worksheet</span> <span class='if if_mod kw'>if</span> <span class='block_given? fid id'>block_given?</span> - <span class='worksheet identifier id'>worksheet</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/workbook.rb', line 112</span> + +<span class='kw'>def</span> <span class='id relationships'>relationships</span> + <span class='id r'>r</span> <span class='op'>=</span> <span class='const'>Relationships</span><span class='period'>.</span><span class='id new'>new</span> + <span class='ivar'>@worksheets</span><span class='period'>.</span><span class='id each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id sheet'>sheet</span><span class='op'>|</span> + <span class='id r'>r</span> <span class='op'><<</span> <span class='const'>Relationship</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='const'>WORKSHEET_R</span><span class='comma'>,</span> <span class='const'>WORKSHEET_PN</span> <span class='op'>%</span> <span class='lparen'>(</span><span class='id r'>r</span><span class='period'>.</span><span class='id size'>size</span><span class='op'>+</span><span class='int'>1</span><span class='rparen'>)</span><span class='rparen'>)</span> + <span class='kw'>end</span> + <span class='id r'>r</span> <span class='op'><<</span> <span class='const'>Relationship</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='const'>STYLES_R</span><span class='comma'>,</span> <span class='const'>STYLES_PN</span><span class='rparen'>)</span> + <span class='id r'>r</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1370,9 +1369,8 @@ The name of the worksheet. </p><div class="docstring"> <div class="discussion"> - <p> -Serializes the workbook document -</p> + +<p>Serializes the workbook document</p> </div> @@ -1399,6 +1397,7 @@ Serializes the workbook document <pre class="lines"> +123 124 125 126 @@ -1411,27 +1410,25 @@ Serializes the workbook document 133 134 135 -136 -137</pre> +136</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/workbook.rb', line 124</span> - -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='rparen token'>)</span> - <span class='add_worksheet identifier id'>add_worksheet</span> <span class='unless unless_mod kw'>unless</span> <span class='worksheets identifier id'>worksheets</span><span class='dot token'>.</span><span class='size identifier id'>size</span> <span class='gt op'>></span> <span class='integer val'>0</span> - <span class='builder identifier id'>builder</span> <span class='assign token'>=</span> <span class='Nokogiri constant id'>Nokogiri</span><span class='colon2 op'>::</span><span class='XML constant id'>XML</span><span class='colon2 op'>::</span><span class='Builder constant id'>Builder</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='symbol val'>:encoding</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='ENCODING constant id'>ENCODING</span><span class='rparen token'>)</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='xml identifier id'>xml</span><span class='bitor op'>|</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='workbook identifier id'>workbook</span><span class='lparen token'>(</span><span class='symbol val'>:xmlns</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='XML_NS constant id'>XML_NS</span><span class='comma token'>,</span> <span class='symbol val'>:'xmlns:r'</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='XML_NS_R constant id'>XML_NS_R</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='workbookPr identifier id'>workbookPr</span><span class='lparen token'>(</span><span class='symbol val'>:date1904=</span><span class='gt op'>></span><span class='@@date1904 ivar id'>@@date1904</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='sheets identifier id'>sheets</span> <span class='lbrace token'>{</span> - <span class='@worksheets ivar id'>@worksheets</span><span class='dot token'>.</span><span class='each_with_index identifier id'>each_with_index</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='sheet identifier id'>sheet</span><span class='comma token'>,</span> <span class='index identifier id'>index</span><span class='bitor op'>|</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='sheet identifier id'>sheet</span><span class='lparen token'>(</span><span class='symbol val'>:name=</span><span class='gt op'>></span><span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='name identifier id'>name</span><span class='comma token'>,</span> <span class='symbol val'>:sheetId=</span><span class='gt op'>></span><span class='index identifier id'>index</span><span class='plus op'>+</span><span class='integer val'>1</span><span class='comma token'>,</span> <span class='symbol val'>:"r:id"</span><span class='assign token'>=</span><span class='gt op'>></span><span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='rId identifier id'>rId</span><span class='rparen token'>)</span> - <span class='end end kw'>end</span> - <span class='rbrace token'>}</span> - <span class='rbrace token'>}</span> - <span class='end end kw'>end</span> - <span class='builder identifier id'>builder</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='symbol val'>:indent=</span><span class='gt op'>></span><span class='integer val'>0</span><span class='rparen token'>)</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/workbook.rb', line 123</span> + +<span class='kw'>def</span> <span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='rparen'>)</span> + <span class='id add_worksheet'>add_worksheet</span> <span class='kw'>unless</span> <span class='id worksheets'>worksheets</span><span class='period'>.</span><span class='id size'>size</span> <span class='op'>></span> <span class='int'>0</span> + <span class='id builder'>builder</span> <span class='op'>=</span> <span class='const'>Nokogiri</span><span class='op'>::</span><span class='const'>XML</span><span class='op'>::</span><span class='const'>Builder</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='symbol'>:encoding</span> <span class='op'>=></span> <span class='const'>ENCODING</span><span class='rparen'>)</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id xml'>xml</span><span class='op'>|</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id workbook'>workbook</span><span class='lparen'>(</span><span class='symbol'>:xmlns</span> <span class='op'>=></span> <span class='const'>XML_NS</span><span class='comma'>,</span> <span class='symbol'>:xmlns:r</span><span class='tstring_end'>'</span></span> <span class='op'>=></span> <span class='const'>XML_NS_R</span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id workbookPr'>workbookPr</span><span class='lparen'>(</span><span class='symbol'>:date1904</span><span class='op'>=></span><span class='cvar'>@@date1904</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id sheets'>sheets</span> <span class='lbrace'>{</span> + <span class='ivar'>@worksheets</span><span class='period'>.</span><span class='id each_with_index'>each_with_index</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id sheet'>sheet</span><span class='comma'>,</span> <span class='id index'>index</span><span class='op'>|</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id sheet'>sheet</span><span class='lparen'>(</span><span class='symbol'>:name</span><span class='op'>=></span><span class='id sheet'>sheet</span><span class='period'>.</span><span class='id name'>name</span><span class='comma'>,</span> <span class='symbol'>:sheetId</span><span class='op'>=></span><span class='id index'>index</span><span class='op'>+</span><span class='int'>1</span><span class='comma'>,</span> <span class='symbol'>:r:id</span><span class='tstring_end'>"</span></span><span class='op'>=></span><span class='id sheet'>sheet</span><span class='period'>.</span><span class='id rId'>rId</span><span class='rparen'>)</span> + <span class='kw'>end</span> + <span class='rbrace'>}</span> + <span class='rbrace'>}</span> + <span class='kw'>end</span> + <span class='id builder'>builder</span><span class='period'>.</span><span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='symbol'>:indent</span><span class='op'>=></span><span class='int'>0</span><span class='rparen'>)</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1442,9 +1439,9 @@ Serializes the workbook document </div> <div id="footer"> - Generated on Wed Nov 23 22:21:01 2011 by + Generated on Sat Nov 26 13:16:38 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/Worksheet.html b/doc/Axlsx/Worksheet.html index 83359c16..db1e39f7 100644 --- a/doc/Axlsx/Worksheet.html +++ b/doc/Axlsx/Worksheet.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::Worksheet - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -94,9 +94,8 @@ <h2>Overview</h2><div class="docstring"> <div class="discussion"> - <p> -The Worksheet class represents a worksheet in the workbook. -</p> + +<p>The Worksheet class represents a worksheet in the workbook.</p> </div> @@ -128,9 +127,8 @@ The Worksheet class represents a worksheet in the workbook. - <span class="summary_desc"><div class='inline'><p> -An array of content based calculated column widths. -</p> + <span class="summary_desc"><div class='inline'> +<p>An array of content based calculated column widths.</p> </div></span> </li> @@ -139,14 +137,14 @@ An array of content based calculated column widths. <li class="public "> <span class="summary_signature"> - <a href="#drawing-instance_method" title="#drawing (instance method)">- (Drawing) <strong>drawing</strong> </a> + <a href="#name-instance_method" title="#name (instance method)">- (String) <strong>name</strong> </a> </span> - <span class="note title readonly">readonly</span> + @@ -155,9 +153,8 @@ An array of content based calculated column widths. - <span class="summary_desc"><div class='inline'><p> -The drawing associated with this worksheet. -</p> + <span class="summary_desc"><div class='inline'> +<p>The name of the worksheet.</p> </div></span> </li> @@ -166,7 +163,7 @@ The drawing associated with this worksheet. <li class="public "> <span class="summary_signature"> - <a href="#index-instance_method" title="#index (instance method)">- (Integer) <strong>index</strong> </a> + <a href="#rows-instance_method" title="#rows (instance method)">- (SimpleTypedList) <strong>rows</strong> </a> @@ -182,9 +179,8 @@ The drawing associated with this worksheet. - <span class="summary_desc"><div class='inline'><p> -The index of this worksheet in the owning Workbook’s worksheets list. -</p> + <span class="summary_desc"><div class='inline'> +<p>The rows in this worksheet.</p> </div></span> </li> @@ -193,7 +189,7 @@ The index of this worksheet in the owning Workbook’s worksheets list. <li class="public "> <span class="summary_signature"> - <a href="#name-instance_method" title="#name (instance method)">- (String) <strong>name</strong> </a> + <a href="#workbook-instance_method" title="#workbook (instance method)">- (Workbook) <strong>workbook</strong> </a> @@ -209,193 +205,122 @@ The index of this worksheet in the owning Workbook’s worksheets list. - <span class="summary_desc"><div class='inline'><p> -The name of the worksheet. -</p> + <span class="summary_desc"><div class='inline'> +<p>The workbook that owns this worksheet.</p> </div></span> </li> - <li class="public "> - <span class="summary_signature"> - - <a href="#pn-instance_method" title="#pn (instance method)">- (String) <strong>pn</strong> </a> - + </ul> - - </span> - - - <span class="note title readonly">readonly</span> - - - - - - - - <span class="summary_desc"><div class='inline'><p> -The part name of this worksheet. -</p> -</div></span> - -</li> - - <li class="public "> - <span class="summary_signature"> - - <a href="#relationships-instance_method" title="#relationships (instance method)">- (Object) <strong>relationships</strong> </a> - - - </span> - - <span class="note title readonly">readonly</span> - - - - - - - - - <span class="summary_desc"><div class='inline'><p> -The worksheet’s relationships. -</p> -</div></span> - -</li> + <h2> + Instance Method Summary + <small>(<a href="#" class="summary_toggle">collapse</a>)</small> + </h2> - - <li class="public "> + <ul class="summary"> + + <li class="public "> <span class="summary_signature"> - <a href="#rels_pn-instance_method" title="#rels_pn (instance method)">- (String) <strong>rels_pn</strong> </a> + <a href="#add_chart-instance_method" title="#add_chart (instance method)">- (Object) <strong>add_chart</strong>(chart_type, options = {}) {|chart| ... }</a> </span> - <span class="note title readonly">readonly</span> - - - <span class="summary_desc"><div class='inline'><p> -The relationship part name of this worksheet. -</p> + <span class="summary_desc"><div class='inline'> +<p>Adds a chart to this worksheets drawing.</p> </div></span> </li> - - <li class="public "> + + <li class="public "> <span class="summary_signature"> - <a href="#rId-instance_method" title="#rId (instance method)">- (String) <strong>rId</strong> </a> + <a href="#add_image-instance_method" title="#add_image (instance method)">- (Object) <strong>add_image</strong>(options = {}) {|image| ... }</a> </span> - <span class="note title readonly">readonly</span> - - - <span class="summary_desc"><div class='inline'><p> -The relationship Id of thiw worksheet. -</p> + <span class="summary_desc"><div class='inline'> +<p>Adds a media item to the worksheets drawing.</p> </div></span> </li> - - <li class="public "> + + <li class="public "> <span class="summary_signature"> - <a href="#rows-instance_method" title="#rows (instance method)">- (SimpleTypedList) <strong>rows</strong> </a> + <a href="#add_row-instance_method" title="#add_row (instance method)">- (Row) <strong>add_row</strong>(values = [], options = {}) {|@rows.last| ... }</a> </span> - <span class="note title readonly">readonly</span> - - - <span class="summary_desc"><div class='inline'><p> -The rows in this worksheet. -</p> + <span class="summary_desc"><div class='inline'> +<p>Adds a row to the worksheet and updates auto fit data.</p> </div></span> </li> - - <li class="public "> + + <li class="public "> <span class="summary_signature"> - <a href="#workbook-instance_method" title="#workbook (instance method)">- (Workbook) <strong>workbook</strong> </a> + <a href="#drawing-instance_method" title="#drawing (instance method)">- (Drawing) <strong>drawing</strong> </a> </span> - - - - <span class="summary_desc"><div class='inline'><p> -The workbook that owns this worksheet. -</p> + <span class="summary_desc"><div class='inline'> +<p>The drawing associated with this worksheet.</p> </div></span> </li> - - </ul> - - - - - - <h2> - Instance Method Summary - <small>(<a href="#" class="summary_toggle">collapse</a>)</small> - </h2> - - <ul class="summary"> <li class="public "> <span class="summary_signature"> - <a href="#add_chart-instance_method" title="#add_chart (instance method)">- (Object) <strong>add_chart</strong>(chart_type, options = {}) {|chart| ... }</a> + <a href="#index-instance_method" title="#index (instance method)">- (Integer) <strong>index</strong> </a> @@ -408,9 +333,8 @@ The workbook that owns this worksheet. - <span class="summary_desc"><div class='inline'><p> -Adds a chart to this worksheets drawing. -</p> + <span class="summary_desc"><div class='inline'> +<p>The index of this worksheet in the owning Workbook's worksheets list.</p> </div></span> </li> @@ -419,12 +343,14 @@ Adds a chart to this worksheets drawing. <li class="public "> <span class="summary_signature"> - <a href="#add_image-instance_method" title="#add_image (instance method)">- (Object) <strong>add_image</strong>(options = {}) {|image| ... }</a> + <a href="#initialize-instance_method" title="#initialize (instance method)">- (Worksheet) <strong>initialize</strong>(wb, options = {}) </a> </span> + <span class="note title constructor">constructor</span> + @@ -432,9 +358,8 @@ Adds a chart to this worksheets drawing. - <span class="summary_desc"><div class='inline'><p> -Adds a media item to the worksheets drawing. -</p> + <span class="summary_desc"><div class='inline'> +<p>Creates a new worksheet.</p> </div></span> </li> @@ -443,7 +368,7 @@ Adds a media item to the worksheets drawing. <li class="public "> <span class="summary_signature"> - <a href="#add_row-instance_method" title="#add_row (instance method)">- (Row) <strong>add_row</strong>(values = [], options = {}) {|@rows.last| ... }</a> + <a href="#pn-instance_method" title="#pn (instance method)">- (String) <strong>pn</strong> </a> @@ -456,9 +381,8 @@ Adds a media item to the worksheets drawing. - <span class="summary_desc"><div class='inline'><p> -Adds a row to the worksheet and updates auto fit data. -</p> + <span class="summary_desc"><div class='inline'> +<p>The part name of this worksheet.</p> </div></span> </li> @@ -467,7 +391,7 @@ Adds a row to the worksheet and updates auto fit data. <li class="public "> <span class="summary_signature"> - <a href="#auto_width-instance_method" title="#auto_width (instance method)">- (Float) <strong>auto_width</strong>(col) </a> + <a href="#relationships-instance_method" title="#relationships (instance method)">- (Relationships) <strong>relationships</strong> </a> @@ -480,9 +404,8 @@ Adds a row to the worksheet and updates auto fit data. - <span class="summary_desc"><div class='inline'><p> -Determines the proper width for a column based on content. -</p> + <span class="summary_desc"><div class='inline'> +<p>The worksheet relationships.</p> </div></span> </li> @@ -491,14 +414,12 @@ Determines the proper width for a column based on content. <li class="public "> <span class="summary_signature"> - <a href="#initialize-instance_method" title="#initialize (instance method)">- (Worksheet) <strong>initialize</strong>(wb, options = {}) </a> + <a href="#rels_pn-instance_method" title="#rels_pn (instance method)">- (String) <strong>rels_pn</strong> </a> </span> - <span class="note title constructor">constructor</span> - @@ -506,9 +427,8 @@ Determines the proper width for a column based on content. - <span class="summary_desc"><div class='inline'><p> -Creates a new worksheet. -</p> + <span class="summary_desc"><div class='inline'> +<p>The relationship part name of this worksheet.</p> </div></span> </li> @@ -517,7 +437,7 @@ Creates a new worksheet. <li class="public "> <span class="summary_signature"> - <a href="#to_xml-instance_method" title="#to_xml (instance method)">- (String) <strong>to_xml</strong> </a> + <a href="#rId-instance_method" title="#rId (instance method)">- (String) <strong>rId</strong> </a> @@ -530,9 +450,8 @@ Creates a new worksheet. - <span class="summary_desc"><div class='inline'><p> -Serializes the worksheet document. -</p> + <span class="summary_desc"><div class='inline'> +<p>The relationship Id of thiw worksheet.</p> </div></span> </li> @@ -541,7 +460,7 @@ Serializes the worksheet document. <li class="public "> <span class="summary_signature"> - <a href="#update_auto_fit_data-instance_method" title="#update_auto_fit_data (instance method)">- (Array) <strong>update_auto_fit_data</strong>(cells) </a> + <a href="#to_xml-instance_method" title="#to_xml (instance method)">- (String) <strong>to_xml</strong> </a> @@ -554,9 +473,8 @@ Serializes the worksheet document. - <span class="summary_desc"><div class='inline'><p> -Updates auto fit data. -</p> + <span class="summary_desc"><div class='inline'> +<p>Serializes the worksheet document.</p> </div></span> </li> @@ -580,15 +498,13 @@ Updates auto fit data. <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -the recommended way to manage worksheets is Workbook#add_worksheet -</p> + <div class='inline'> +<p>the recommended way to manage worksheets is Workbook#add_worksheet</p> </div> </div> -<p> -Creates a new worksheet. -</p> + +<p>Creates a new worksheet.</p> </div> @@ -609,9 +525,8 @@ Creates a new worksheet. — - <div class='inline'><p> -a customizable set of options -</p> + <div class='inline'> +<p>a customizable set of options</p> </div> </li> @@ -632,9 +547,8 @@ a customizable set of options <span class="default"> </span> - — <div class='inline'><p> -The name of this sheet. -</p> + — <div class='inline'> +<p>The name of this sheet.</p> </div> </li> @@ -655,27 +569,28 @@ The name of this sheet. <pre class="lines"> -59 -60 -61 -62 -63 -64 -65 -66</pre> +34 +35 +36 +37 +38 +39 +40 +41 +42</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 59</span> - -<span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span><span class='lparen token'>(</span><span class='wb identifier id'>wb</span><span class='comma token'>,</span> <span class='options identifier id'>options</span><span class='assign token'>=</span><span class='lbrace token'>{</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> - <span class='@rows ivar id'>@rows</span> <span class='assign token'>=</span> <span class='SimpleTypedList constant id'>SimpleTypedList</span><span class='dot token'>.</span><span class='new identifier id'>new</span> <span class='Row constant id'>Row</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='workbook identifier id'>workbook</span> <span class='assign token'>=</span> <span class='wb identifier id'>wb</span> - <span class='@workbook ivar id'>@workbook</span><span class='dot token'>.</span><span class='worksheets identifier id'>worksheets</span> <span class='lshft op'><<</span> <span class='self self kw'>self</span> - <span class='@auto_fit_data ivar id'>@auto_fit_data</span> <span class='assign token'>=</span> <span class='lbrack token'>[</span><span class='rbrack token'>]</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='name identifier id'>name</span> <span class='assign token'>=</span> <span class='options identifier id'>options</span><span class='lbrack token'>[</span><span class='symbol val'>:name</span><span class='rbrack token'>]</span> <span class='orop op'>||</span> <span class='string val'>"Sheet"</span> <span class='plus op'>+</span> <span class='lparen token'>(</span><span class='index identifier id'>index</span><span class='plus op'>+</span><span class='integer val'>1</span><span class='rparen token'>)</span><span class='dot token'>.</span><span class='to_s identifier id'>to_s</span> - <span class='@magick_draw ivar id'>@magick_draw</span> <span class='assign token'>=</span> <span class='Magick constant id'>Magick</span><span class='colon2 op'>::</span><span class='Draw constant id'>Draw</span><span class='dot token'>.</span><span class='new identifier id'>new</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 34</span> + +<span class='kw'>def</span> <span class='id initialize'>initialize</span><span class='lparen'>(</span><span class='id wb'>wb</span><span class='comma'>,</span> <span class='id options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span> + <span class='ivar'>@drawing</span> <span class='op'>=</span> <span class='kw'>nil</span> + <span class='ivar'>@rows</span> <span class='op'>=</span> <span class='const'>SimpleTypedList</span><span class='period'>.</span><span class='id new'>new</span> <span class='const'>Row</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id workbook'>workbook</span> <span class='op'>=</span> <span class='id wb'>wb</span> + <span class='ivar'>@workbook</span><span class='period'>.</span><span class='id worksheets'>worksheets</span> <span class='op'><<</span> <span class='kw'>self</span> + <span class='ivar'>@auto_fit_data</span> <span class='op'>=</span> <span class='lbracket'>[</span><span class='rbracket'>]</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id name'>name</span> <span class='op'>=</span> <span class='id options'>options</span><span class='lbracket'>[</span><span class='symbol'>:name</span><span class='rbracket'>]</span> <span class='op'>||</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Sheet</span><span class='tstring_end'>"</span></span> <span class='op'>+</span> <span class='lparen'>(</span><span class='id index'>index</span><span class='op'>+</span><span class='int'>1</span><span class='rparen'>)</span><span class='period'>.</span><span class='id to_s'>to_s</span> + <span class='ivar'>@magick_draw</span> <span class='op'>=</span> <span class='const'>Magick</span><span class='op'>::</span><span class='const'>Draw</span><span class='period'>.</span><span class='id new'>new</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -701,16 +616,14 @@ The name of this sheet. <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -a single auto fit data item is a hash with :longest => [String] and -:sz=> [Integer] members. -</p> + <div class='inline'> +<p>a single auto fit data item is a hash with :longest => [String] and +:sz=> [Integer] members.</p> </div> </div> -<p> -An array of content based calculated column widths. -</p> + +<p>An array of content based calculated column widths.</p> </div> @@ -728,9 +641,8 @@ An array of content based calculated column widths. — - <div class='inline'><p> -of Hash -</p> + <div class='inline'> +<p>of Hash</p> </div> </li> @@ -743,147 +655,16 @@ of Hash <pre class="lines"> -34 -35 -36</pre> +25 +26 +27</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 34</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 25</span> -<span class='def def kw'>def</span> <span class='auto_fit_data identifier id'>auto_fit_data</span> - <span class='@auto_fit_data ivar id'>@auto_fit_data</span> -<span class='end end kw'>end</span> -</pre> - </td> - </tr> -</table> -</div> - - - <span id=""></span> - <span id="drawing-instance_method"></span> - <div class="method_details "> - <p class="signature " id="drawing-instance_method"> - - - (<tt><span class='object_link'><a href="Drawing.html" title="Axlsx::Drawing (class)">Drawing</a></span></tt>) <strong>drawing</strong> <span class="extras">(readonly)</span> - - - -</p><div class="docstring"> - <div class="discussion"> - - <div class="note notetag"> - <strong>Note:</strong> - <div class='inline'><p> -the recommended way to work with drawings and charts is Worksheet#add_chart -</p> -</div> - </div> - -<p> -The drawing associated with this worksheet. -</p> - - - </div> -</div> -<div class="tags"> - -<h3>Returns:</h3> -<ul class="return"> - - <li> - - - <span class='type'>(<tt><span class='object_link'><a href="Drawing.html" title="Axlsx::Drawing (class)">Drawing</a></span></tt>)</span> - - - - </li> - -</ul> - - <h3>See Also:</h3> - <ul class="see"> - - <li><span class='object_link'><a href="#add_chart-instance_method" title="Axlsx::Worksheet#add_chart (method)">#add_chart</a></span></li> - - </ul> - -</div><table class="source_code"> - <tr> - <td> - <pre class="lines"> - - -29 -30 -31</pre> - </td> - <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 29</span> - -<span class='def def kw'>def</span> <span class='drawing identifier id'>drawing</span> - <span class='@drawing ivar id'>@drawing</span> <span class='orop op'>||</span> <span class='@drawing ivar id'>@drawing</span> <span class='assign token'>=</span> <span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='Drawing constant id'>Drawing</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='self self kw'>self</span><span class='rparen token'>)</span> -<span class='end end kw'>end</span> -</pre> - </td> - </tr> -</table> -</div> - - - <span id=""></span> - <span id="index-instance_method"></span> - <div class="method_details "> - <p class="signature " id="index-instance_method"> - - - (<tt>Integer</tt>) <strong>index</strong> <span class="extras">(readonly)</span> - - - -</p><div class="docstring"> - <div class="discussion"> - <p> -The index of this worksheet in the owning Workbook’s worksheets list. -</p> - - - </div> -</div> -<div class="tags"> - -<h3>Returns:</h3> -<ul class="return"> - - <li> - - - <span class='type'>(<tt>Integer</tt>)</span> - - - - </li> - -</ul> - -</div><table class="source_code"> - <tr> - <td> - <pre class="lines"> - - -50 -51 -52</pre> - </td> - <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 50</span> - -<span class='def def kw'>def</span> <span class='index identifier id'>index</span> - <span class='@workbook ivar id'>@workbook</span><span class='dot token'>.</span><span class='worksheets identifier id'>worksheets</span><span class='dot token'>.</span><span class='index identifier id'>index</span><span class='lparen token'>(</span><span class='self self kw'>self</span><span class='rparen token'>)</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id auto_fit_data'>auto_fit_data</span> + <span class='ivar'>@auto_fit_data</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -901,9 +682,8 @@ The index of this worksheet in the owning Workbook’s worksheets list. </p><div class="docstring"> <div class="discussion"> - <p> -The name of the worksheet -</p> + +<p>The name of the worksheet</p> </div> @@ -937,229 +717,9 @@ The name of the worksheet <td> <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 9</span> -<span class='def def kw'>def</span> <span class='name identifier id'>name</span> - <span class='@name ivar id'>@name</span> -<span class='end end kw'>end</span> -</pre> - </td> - </tr> -</table> -</div> - - - <span id=""></span> - <span id="pn-instance_method"></span> - <div class="method_details "> - <p class="signature " id="pn-instance_method"> - - - (<tt>String</tt>) <strong>pn</strong> <span class="extras">(readonly)</span> - - - -</p><div class="docstring"> - <div class="discussion"> - <p> -The part name of this worksheet -</p> - - - </div> -</div> -<div class="tags"> - -<h3>Returns:</h3> -<ul class="return"> - - <li> - - - <span class='type'>(<tt>String</tt>)</span> - - - - </li> - -</ul> - -</div><table class="source_code"> - <tr> - <td> - <pre class="lines"> - - -38 -39 -40</pre> - </td> - <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 38</span> - -<span class='def def kw'>def</span> <span class='pn identifier id'>pn</span> - <span class='dstring node'>"#{WORKSHEET_PN % (index+1)}"</span> -<span class='end end kw'>end</span> -</pre> - </td> - </tr> -</table> -</div> - - - <span id=""></span> - <span id="relationships-instance_method"></span> - <div class="method_details "> - <p class="signature " id="relationships-instance_method"> - - - (<tt>Object</tt>) <strong>relationships</strong> <span class="extras">(readonly)</span> - - - -</p><div class="docstring"> - <div class="discussion"> - <p> -The worksheet’s relationships. -</p> - - - </div> -</div> -<div class="tags"> - - -</div><table class="source_code"> - <tr> - <td> - <pre class="lines"> - - -17 -18 -19 -20 -21</pre> - </td> - <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 17</span> - -<span class='def def kw'>def</span> <span class='relationships identifier id'>relationships</span> - <span class='r identifier id'>r</span> <span class='assign token'>=</span> <span class='Relationships constant id'>Relationships</span><span class='dot token'>.</span><span class='new identifier id'>new</span> - <span class='r identifier id'>r</span> <span class='lshft op'><<</span> <span class='Relationship constant id'>Relationship</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='DRAWING_R constant id'>DRAWING_R</span><span class='comma token'>,</span> <span class='dstring node'>"../#{@drawing.pn}"</span><span class='rparen token'>)</span> <span class='if if_mod kw'>if</span> <span class='@drawing ivar id'>@drawing</span> - <span class='r identifier id'>r</span> -<span class='end end kw'>end</span> -</pre> - </td> - </tr> -</table> -</div> - - - <span id=""></span> - <span id="rels_pn-instance_method"></span> - <div class="method_details "> - <p class="signature " id="rels_pn-instance_method"> - - - (<tt>String</tt>) <strong>rels_pn</strong> <span class="extras">(readonly)</span> - - - -</p><div class="docstring"> - <div class="discussion"> - <p> -The relationship part name of this worksheet -</p> - - - </div> -</div> -<div class="tags"> - -<h3>Returns:</h3> -<ul class="return"> - - <li> - - - <span class='type'>(<tt>String</tt>)</span> - - - - </li> - -</ul> - -</div><table class="source_code"> - <tr> - <td> - <pre class="lines"> - - -42 -43 -44</pre> - </td> - <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 42</span> - -<span class='def def kw'>def</span> <span class='rels_pn identifier id'>rels_pn</span> - <span class='dstring node'>"#{WORKSHEET_RELS_PN % (index+1)}"</span> -<span class='end end kw'>end</span> -</pre> - </td> - </tr> -</table> -</div> - - - <span id=""></span> - <span id="rId-instance_method"></span> - <div class="method_details "> - <p class="signature " id="rId-instance_method"> - - - (<tt>String</tt>) <strong>rId</strong> <span class="extras">(readonly)</span> - - - -</p><div class="docstring"> - <div class="discussion"> - <p> -The relationship Id of thiw worksheet -</p> - - - </div> -</div> -<div class="tags"> - -<h3>Returns:</h3> -<ul class="return"> - - <li> - - - <span class='type'>(<tt>String</tt>)</span> - - - - </li> - -</ul> - -</div><table class="source_code"> - <tr> - <td> - <pre class="lines"> - - -46 -47 -48</pre> - </td> - <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 46</span> - -<span class='def def kw'>def</span> <span class='rId identifier id'>rId</span> - <span class='dstring node'>"rId#{index+1}"</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id name'>name</span> + <span class='ivar'>@name</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1180,15 +740,13 @@ The relationship Id of thiw worksheet <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -The recommended way to manage rows is Worksheet#add_row -</p> + <div class='inline'> +<p>The recommended way to manage rows is Worksheet#add_row</p> </div> </div> -<p> -The rows in this worksheet -</p> + +<p>The rows in this worksheet</p> </div> @@ -1222,17 +780,16 @@ The rows in this worksheet <pre class="lines"> -23 -24 -25</pre> +20 +21 +22</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 23</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 20</span> -<span class='def def kw'>def</span> <span class='rows identifier id'>rows</span> - <span class='@rows ivar id'>@rows</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id rows'>rows</span> + <span class='ivar'>@rows</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1250,9 +807,8 @@ The rows in this worksheet </p><div class="docstring"> <div class="discussion"> - <p> -The workbook that owns this worksheet -</p> + +<p>The workbook that owns this worksheet</p> </div> @@ -1286,10 +842,9 @@ The workbook that owns this worksheet <td> <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 13</span> -<span class='def def kw'>def</span> <span class='workbook identifier id'>workbook</span> - <span class='@workbook ivar id'>@workbook</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id workbook'>workbook</span> + <span class='ivar'>@workbook</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1314,18 +869,16 @@ The workbook that owns this worksheet <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -each chart type also specifies additional options -</p> + <div class='inline'> +<p>each chart type also specifies additional options</p> </div> </div> -<p> -Adds a chart to this worksheets drawing. This is the recommended way to + +<p>Adds a chart to this worksheets drawing. This is the recommended way to create charts for your worksheet. This method wraps the complexity of dealing with ooxml drawing, anchors, markers graphic frames chart objects -and all the other dirty details. -</p> +and all the other dirty details.</p> </div> @@ -1357,9 +910,8 @@ and all the other dirty details. — - <div class='inline'><p> -a customizable set of options -</p> + <div class='inline'> +<p>a customizable set of options</p> </div> </li> @@ -1457,21 +1009,20 @@ a customizable set of options <pre class="lines"> -116 -117 -118 -119 -120</pre> +105 +106 +107 +108 +109</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 116</span> - -<span class='def def kw'>def</span> <span class='add_chart identifier id'>add_chart</span><span class='lparen token'>(</span><span class='chart_type identifier id'>chart_type</span><span class='comma token'>,</span> <span class='options identifier id'>options</span><span class='assign token'>=</span><span class='lbrace token'>{</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> - <span class='chart identifier id'>chart</span> <span class='assign token'>=</span> <span class='drawing identifier id'>drawing</span><span class='dot token'>.</span><span class='add_chart identifier id'>add_chart</span><span class='lparen token'>(</span><span class='chart_type identifier id'>chart_type</span><span class='comma token'>,</span> <span class='options identifier id'>options</span><span class='rparen token'>)</span> - <span class='yield yield kw'>yield</span> <span class='chart identifier id'>chart</span> <span class='if if_mod kw'>if</span> <span class='block_given? fid id'>block_given?</span> - <span class='chart identifier id'>chart</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 105</span> + +<span class='kw'>def</span> <span class='id add_chart'>add_chart</span><span class='lparen'>(</span><span class='id chart_type'>chart_type</span><span class='comma'>,</span> <span class='id options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span> + <span class='id chart'>chart</span> <span class='op'>=</span> <span class='id drawing'>drawing</span><span class='period'>.</span><span class='id add_chart'>add_chart</span><span class='lparen'>(</span><span class='id chart_type'>chart_type</span><span class='comma'>,</span> <span class='id options'>options</span><span class='rparen'>)</span> + <span class='kw'>yield</span> <span class='id chart'>chart</span> <span class='kw'>if</span> <span class='id block_given?'>block_given?</span> + <span class='id chart'>chart</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1486,9 +1037,8 @@ a customizable set of options </p><div class="docstring"> <div class="discussion"> - <p> -Adds a media item to the worksheets drawing -</p> + +<p>Adds a media item to the worksheets drawing</p> </div> @@ -1520,9 +1070,8 @@ Adds a media item to the worksheets drawing — - <div class='inline'><p> -a customizable set of options -</p> + <div class='inline'> +<p>a customizable set of options</p> </div> </li> @@ -1541,9 +1090,8 @@ a customizable set of options <span class="default"> </span> - — <div class='inline'><p> -unknown -</p> + — <div class='inline'> +<p>unknown</p> </div> </li> @@ -1570,21 +1118,20 @@ unknown <pre class="lines"> -125 -126 -127 -128 -129</pre> +114 +115 +116 +117 +118</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 125</span> - -<span class='def def kw'>def</span> <span class='add_image identifier id'>add_image</span><span class='lparen token'>(</span><span class='options identifier id'>options</span><span class='assign token'>=</span><span class='lbrace token'>{</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> - <span class='image identifier id'>image</span> <span class='assign token'>=</span> <span class='drawing identifier id'>drawing</span><span class='dot token'>.</span><span class='add_image identifier id'>add_image</span><span class='lparen token'>(</span><span class='options identifier id'>options</span><span class='rparen token'>)</span> - <span class='yield yield kw'>yield</span> <span class='image identifier id'>image</span> <span class='if if_mod kw'>if</span> <span class='block_given? fid id'>block_given?</span> - <span class='image identifier id'>image</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 114</span> + +<span class='kw'>def</span> <span class='id add_image'>add_image</span><span class='lparen'>(</span><span class='id options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span> + <span class='id image'>image</span> <span class='op'>=</span> <span class='id drawing'>drawing</span><span class='period'>.</span><span class='id add_image'>add_image</span><span class='lparen'>(</span><span class='id options'>options</span><span class='rparen'>)</span> + <span class='kw'>yield</span> <span class='id image'>image</span> <span class='kw'>if</span> <span class='id block_given?'>block_given?</span> + <span class='id image'>image</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1599,9 +1146,8 @@ unknown </p><div class="docstring"> <div class="discussion"> - <p> -Adds a row to the worksheet and updates auto fit data -</p> + +<p>Adds a row to the worksheet and updates auto fit data</p> </div> @@ -1622,9 +1168,8 @@ Adds a row to the worksheet and updates auto fit data — - <div class='inline'><p> -a customizable set of options -</p> + <div class='inline'> +<p>a customizable set of options</p> </div> </li> @@ -1702,32 +1247,31 @@ a customizable set of options <pre class="lines"> -96 -97 -98 -99 -100 -101</pre> +85 +86 +87 +88 +89 +90</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 96</span> - -<span class='def def kw'>def</span> <span class='add_row identifier id'>add_row</span><span class='lparen token'>(</span><span class='values identifier id'>values</span><span class='assign token'>=</span><span class='lbrack token'>[</span><span class='rbrack token'>]</span><span class='comma token'>,</span> <span class='options identifier id'>options</span><span class='assign token'>=</span><span class='lbrace token'>{</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> - <span class='Row constant id'>Row</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='self self kw'>self</span><span class='comma token'>,</span> <span class='values identifier id'>values</span><span class='comma token'>,</span> <span class='options identifier id'>options</span><span class='rparen token'>)</span> - <span class='update_auto_fit_data identifier id'>update_auto_fit_data</span> <span class='@rows ivar id'>@rows</span><span class='dot token'>.</span><span class='last identifier id'>last</span><span class='dot token'>.</span><span class='cells identifier id'>cells</span> - <span class='yield yield kw'>yield</span> <span class='@rows ivar id'>@rows</span><span class='dot token'>.</span><span class='last identifier id'>last</span> <span class='if if_mod kw'>if</span> <span class='block_given? fid id'>block_given?</span> - <span class='@rows ivar id'>@rows</span><span class='dot token'>.</span><span class='last identifier id'>last</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 85</span> + +<span class='kw'>def</span> <span class='id add_row'>add_row</span><span class='lparen'>(</span><span class='id values'>values</span><span class='op'>=</span><span class='lbracket'>[</span><span class='rbracket'>]</span><span class='comma'>,</span> <span class='id options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span> + <span class='const'>Row</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='kw'>self</span><span class='comma'>,</span> <span class='id values'>values</span><span class='comma'>,</span> <span class='id options'>options</span><span class='rparen'>)</span> + <span class='id update_auto_fit_data'>update_auto_fit_data</span> <span class='ivar'>@rows</span><span class='period'>.</span><span class='id last'>last</span><span class='period'>.</span><span class='id cells'>cells</span> + <span class='kw'>yield</span> <span class='ivar'>@rows</span><span class='period'>.</span><span class='id last'>last</span> <span class='kw'>if</span> <span class='id block_given?'>block_given?</span> + <span class='ivar'>@rows</span><span class='period'>.</span><span class='id last'>last</span> +<span class='kw'>end</span></pre> </td> </tr> </table> </div> <div class="method_details "> - <p class="signature " id="auto_width-instance_method"> + <p class="signature " id="drawing-instance_method"> - - (<tt>Float</tt>) <strong>auto_width</strong>(col) + - (<tt><span class='object_link'><a href="Drawing.html" title="Axlsx::Drawing (class)">Drawing</a></span></tt>) <strong>drawing</strong> @@ -1736,54 +1280,137 @@ a customizable set of options <div class="note notetag"> <strong>Note:</strong> - <div class='inline'><p> -From ECMA docs -</p> -<pre class="code"> - <span class='Column constant id'>Column</span> <span class='width identifier id'>width</span> <span class='measured identifier id'>measured</span> <span class='as identifier id'>as</span> <span class='the identifier id'>the</span> <span class='number identifier id'>number</span> <span class='of identifier id'>of</span> <span class='characters identifier id'>characters</span> <span class='of identifier id'>of</span> <span class='the identifier id'>the</span> <span class='maximum identifier id'>maximum</span> <span class='digit identifier id'>digit</span> <span class='width identifier id'>width</span> <span class='of identifier id'>of</span> <span class='the identifier id'>the</span> <span class='numbers identifier id'>numbers</span> <span class='integer val'>0</span> <span class='dot2 op'>..</span> <span class='integer val'>9</span> <span class='as identifier id'>as</span> - <span class='rendered identifier id'>rendered</span> <span class='in in kw'>in</span> <span class='the identifier id'>the</span> <span class='normal identifier id'>normal</span> <span class='style identifier id'>style</span><span class='string val'>'s font. There are 4 pixels of margin padding (two on each side), plus 1 pixel padding for the gridlines. - width = Truncate([{Number of Characters} * {Maximum Digit Width} + {5 pixel padding}]/{Maximum Digit Width}*256)/256 -</span></pre> + <div class='inline'> +<p>the recommended way to work with drawings and charts is Worksheet#add_chart</p> </div> </div> -<p> -Determines the proper width for a column based on content. -</p> + +<p>The drawing associated with this worksheet.</p> </div> </div> <div class="tags"> - <h3>Parameters:</h3> -<ul class="param"> + +<h3>Returns:</h3> +<ul class="return"> <li> - <span class='name'>A</span> - - <span class='type'>(<tt>Hash</tt>)</span> + <span class='type'>(<tt><span class='object_link'><a href="Drawing.html" title="Axlsx::Drawing (class)">Drawing</a></span></tt>)</span> - — - <div class='inline'><p> -hash of auto_fit_data -</p> + </li> + +</ul> + + <h3>See Also:</h3> + <ul class="see"> + + <li><span class='object_link'><a href="#add_chart-instance_method" title="Axlsx::Worksheet#add_chart (method)">#add_chart</a></span></li> + + </ul> + +</div><table class="source_code"> + <tr> + <td> + <pre class="lines"> + + +76 +77 +78</pre> + </td> + <td> + <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 76</span> + +<span class='kw'>def</span> <span class='id drawing'>drawing</span> + <span class='ivar'>@drawing</span> <span class='op'>||</span> <span class='ivar'>@drawing</span> <span class='op'>=</span> <span class='const'>Axlsx</span><span class='op'>::</span><span class='const'>Drawing</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='kw'>self</span><span class='rparen'>)</span> +<span class='kw'>end</span></pre> + </td> + </tr> +</table> </div> + + <div class="method_details "> + <p class="signature " id="index-instance_method"> + + - (<tt>Integer</tt>) <strong>index</strong> + + + +</p><div class="docstring"> + <div class="discussion"> + +<p>The index of this worksheet in the owning Workbook's worksheets list.</p> + + + </div> +</div> +<div class="tags"> + +<h3>Returns:</h3> +<ul class="return"> + + <li> + + + <span class='type'>(<tt>Integer</tt>)</span> + + </li> </ul> +</div><table class="source_code"> + <tr> + <td> + <pre class="lines"> + + +68 +69 +70</pre> + </td> + <td> + <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 68</span> + +<span class='kw'>def</span> <span class='id index'>index</span> + <span class='ivar'>@workbook</span><span class='period'>.</span><span class='id worksheets'>worksheets</span><span class='period'>.</span><span class='id index'>index</span><span class='lparen'>(</span><span class='kw'>self</span><span class='rparen'>)</span> +<span class='kw'>end</span></pre> + </td> + </tr> +</table> +</div> + + <div class="method_details "> + <p class="signature " id="pn-instance_method"> + + - (<tt>String</tt>) <strong>pn</strong> + + + +</p><div class="docstring"> + <div class="discussion"> + +<p>The part name of this worksheet</p> + + + </div> +</div> +<div class="tags"> + <h3>Returns:</h3> <ul class="return"> <li> - <span class='type'>(<tt>Float</tt>)</span> + <span class='type'>(<tt>String</tt>)</span> @@ -1797,48 +1424,32 @@ hash of auto_fit_data <pre class="lines"> -199 -200 -201 -202 -203 -204 -205 -206 -207 -208</pre> +50 +51 +52</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 199</span> - -<span class='def def kw'>def</span> <span class='auto_width identifier id'>auto_width</span><span class='lparen token'>(</span><span class='col identifier id'>col</span><span class='rparen token'>)</span> - <span class='mdw identifier id'>mdw</span> <span class='assign token'>=</span> <span class='float val'>6.0</span> <span class='comment val'># maximum digit with is always 6.0 with RMagick's default font</span> - <span class='mdw_count identifier id'>mdw_count</span> <span class='assign token'>=</span> <span class='integer val'>0</span> - <span class='best_guess identifier id'>best_guess</span> <span class='assign token'>=</span> <span class='float val'>1.5</span> <span class='comment val'>#direct testing shows the results of the documented formula to be a bit too small. This is a best guess scaling</span> - <span class='font_scale identifier id'>font_scale</span> <span class='assign token'>=</span> <span class='col identifier id'>col</span><span class='lbrack token'>[</span><span class='symbol val'>:sz</span><span class='rbrack token'>]</span><span class='dot token'>.</span><span class='to_f identifier id'>to_f</span> <span class='div op'>/</span> <span class='lparen token'>(</span><span class='self self kw'>self</span><span class='dot token'>.</span><span class='workbook identifier id'>workbook</span><span class='dot token'>.</span><span class='styles identifier id'>styles</span><span class='dot token'>.</span><span class='fonts identifier id'>fonts</span><span class='lbrack token'>[</span><span class='integer val'>0</span><span class='rbrack token'>]</span><span class='dot token'>.</span><span class='sz identifier id'>sz</span><span class='dot token'>.</span><span class='to_f identifier id'>to_f</span> <span class='orop op'>||</span> <span class='float val'>11.0</span><span class='rparen token'>)</span> - <span class='col identifier id'>col</span><span class='lbrack token'>[</span><span class='symbol val'>:longest</span><span class='rbrack token'>]</span><span class='dot token'>.</span><span class='scan identifier id'>scan</span><span class='lparen token'>(</span><span class='regexp val'>/./</span><span class='mu identifier id'>mu</span><span class='rparen token'>)</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='i identifier id'>i</span><span class='bitor op'>|</span> - <span class='mdw_count identifier id'>mdw_count</span> <span class='opasgn op'>+=</span><span class='integer val'>1</span> <span class='if if_mod kw'>if</span> <span class='@magick_draw ivar id'>@magick_draw</span><span class='dot token'>.</span><span class='get_type_metrics identifier id'>get_type_metrics</span><span class='lparen token'>(</span><span class='i identifier id'>i</span><span class='rparen token'>)</span><span class='dot token'>.</span><span class='width identifier id'>width</span> <span class='geq op'>>=</span> <span class='mdw identifier id'>mdw</span> - <span class='end end kw'>end</span> - <span class='lparen token'>(</span><span class='lparen token'>(</span><span class='mdw_count identifier id'>mdw_count</span> <span class='mult op'>*</span> <span class='mdw identifier id'>mdw</span> <span class='plus op'>+</span> <span class='integer val'>5</span><span class='rparen token'>)</span> <span class='div op'>/</span> <span class='mdw identifier id'>mdw</span> <span class='mult op'>*</span> <span class='integer val'>256</span><span class='rparen token'>)</span> <span class='div op'>/</span> <span class='float val'>256.0</span> <span class='mult op'>*</span> <span class='best_guess identifier id'>best_guess</span> <span class='mult op'>*</span> <span class='font_scale identifier id'>font_scale</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 50</span> + +<span class='kw'>def</span> <span class='id pn'>pn</span> + <span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='const'>WORKSHEET_PN</span> <span class='op'>%</span> <span class='lparen'>(</span><span class='id index'>index</span><span class='op'>+</span><span class='int'>1</span><span class='rparen'>)</span><span class='rbrace'>}</span><span class='tstring_end'>"</span></span> +<span class='kw'>end</span></pre> </td> </tr> </table> </div> <div class="method_details "> - <p class="signature " id="to_xml-instance_method"> + <p class="signature " id="relationships-instance_method"> - - (<tt>String</tt>) <strong>to_xml</strong> + - (<tt><span class='object_link'><a href="Relationships.html" title="Axlsx::Relationships (class)">Relationships</a></span></tt>) <strong>relationships</strong> </p><div class="docstring"> <div class="discussion"> - <p> -Serializes the worksheet document -</p> + +<p>The worksheet relationships. This is managed automatically by the worksheet</p> </div> @@ -1851,7 +1462,7 @@ Serializes the worksheet document <li> - <span class='type'>(<tt>String</tt>)</span> + <span class='type'>(<tt><span class='object_link'><a href="Relationships.html" title="Axlsx::Relationships (class)">Relationships</a></span></tt>)</span> @@ -1865,114 +1476,155 @@ Serializes the worksheet document <pre class="lines"> -133 -134 -135 -136 -137 -138 -139 -140 -141 -142 -143 -144 -145 146 147 148 149 -150 -151 -152 -153</pre> +150</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 133</span> - -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span> - <span class='builder identifier id'>builder</span> <span class='assign token'>=</span> <span class='Nokogiri constant id'>Nokogiri</span><span class='colon2 op'>::</span><span class='XML constant id'>XML</span><span class='colon2 op'>::</span><span class='Builder constant id'>Builder</span><span class='dot token'>.</span><span class='new identifier id'>new</span><span class='lparen token'>(</span><span class='symbol val'>:encoding</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='ENCODING constant id'>ENCODING</span><span class='rparen token'>)</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='xml identifier id'>xml</span><span class='bitor op'>|</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='worksheet identifier id'>worksheet</span><span class='lparen token'>(</span><span class='symbol val'>:xmlns</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='XML_NS constant id'>XML_NS</span><span class='comma token'>,</span> <span class='symbol val'>:'xmlns:r'</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='XML_NS_R constant id'>XML_NS_R</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='if if kw'>if</span> <span class='@auto_fit_data ivar id'>@auto_fit_data</span><span class='dot token'>.</span><span class='size identifier id'>size</span> <span class='gt op'>></span> <span class='integer val'>0</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='cols identifier id'>cols</span> <span class='lbrace token'>{</span> - <span class='@auto_fit_data ivar id'>@auto_fit_data</span><span class='dot token'>.</span><span class='each_with_index identifier id'>each_with_index</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='col identifier id'>col</span><span class='comma token'>,</span> <span class='index identifier id'>index</span><span class='bitor op'>|</span> - <span class='min_max identifier id'>min_max</span> <span class='assign token'>=</span> <span class='index identifier id'>index</span><span class='plus op'>+</span><span class='integer val'>1</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='col identifier id'>col</span><span class='lparen token'>(</span><span class='symbol val'>:min=</span><span class='gt op'>></span><span class='min_max identifier id'>min_max</span><span class='comma token'>,</span> <span class='symbol val'>:max=</span><span class='gt op'>></span><span class='min_max identifier id'>min_max</span><span class='comma token'>,</span> <span class='symbol val'>:width</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='auto_width identifier id'>auto_width</span><span class='lparen token'>(</span><span class='col identifier id'>col</span><span class='rparen token'>)</span><span class='comma token'>,</span> <span class='symbol val'>:customWidth=</span><span class='gt op'>></span><span class='string val'>"true"</span><span class='rparen token'>)</span> - <span class='end end kw'>end</span> - <span class='rbrace token'>}</span> - <span class='end end kw'>end</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='sheetData identifier id'>sheetData</span> <span class='lbrace token'>{</span> - <span class='@rows ivar id'>@rows</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='row identifier id'>row</span><span class='bitor op'>|</span> - <span class='row identifier id'>row</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='end end kw'>end</span> - <span class='rbrace token'>}</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='drawing identifier id'>drawing</span> <span class='symbol val'>:"r:id"</span><span class='assign token'>=</span><span class='gt op'>></span><span class='string val'>"rId1"</span> <span class='if if_mod kw'>if</span> <span class='@drawing ivar id'>@drawing</span> - <span class='rbrace token'>}</span> - <span class='end end kw'>end</span> - <span class='builder identifier id'>builder</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='symbol val'>:indent=</span><span class='gt op'>></span><span class='integer val'>0</span><span class='comma token'>,</span> <span class='symbol val'>:save_with=</span><span class='gt op'>></span><span class='integer val'>0</span><span class='rparen token'>)</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 146</span> + +<span class='kw'>def</span> <span class='id relationships'>relationships</span> + <span class='id r'>r</span> <span class='op'>=</span> <span class='const'>Relationships</span><span class='period'>.</span><span class='id new'>new</span> + <span class='id r'>r</span> <span class='op'><<</span> <span class='const'>Relationship</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='const'>DRAWING_R</span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>../</span><span class='embexpr_beg'>#{</span><span class='ivar'>@drawing</span><span class='period'>.</span><span class='id pn'>pn</span><span class='rbrace'>}</span><span class='tstring_end'>"</span></span><span class='rparen'>)</span> <span class='kw'>if</span> <span class='ivar'>@drawing</span> + <span class='id r'>r</span> +<span class='kw'>end</span></pre> </td> </tr> </table> </div> <div class="method_details "> - <p class="signature " id="update_auto_fit_data-instance_method"> + <p class="signature " id="rels_pn-instance_method"> - - (<tt>Array</tt>) <strong>update_auto_fit_data</strong>(cells) + - (<tt>String</tt>) <strong>rels_pn</strong> </p><div class="docstring"> <div class="discussion"> - <p> -Updates auto fit data. Autofit data attempts to determine the cell in a -column that has the greatest width by comparing the length of the text -multiplied by the size of the font. -</p> + +<p>The relationship part name of this worksheet</p> </div> </div> <div class="tags"> - <h3>Parameters:</h3> -<ul class="param"> + +<h3>Returns:</h3> +<ul class="return"> <li> - <span class='name'>cells</span> - - - <span class='type'>(<tt>Array</tt>)</span> + <span class='type'>(<tt>String</tt>)</span> - — - <div class='inline'><p> -an array of cells -</p> -</div> </li> </ul> +</div><table class="source_code"> + <tr> + <td> + <pre class="lines"> + + +56 +57 +58</pre> + </td> + <td> + <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 56</span> + +<span class='kw'>def</span> <span class='id rels_pn'>rels_pn</span> + <span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='const'>WORKSHEET_RELS_PN</span> <span class='op'>%</span> <span class='lparen'>(</span><span class='id index'>index</span><span class='op'>+</span><span class='int'>1</span><span class='rparen'>)</span><span class='rbrace'>}</span><span class='tstring_end'>"</span></span> +<span class='kw'>end</span></pre> + </td> + </tr> +</table> +</div> + + <div class="method_details "> + <p class="signature " id="rId-instance_method"> + + - (<tt>String</tt>) <strong>rId</strong> + + + +</p><div class="docstring"> + <div class="discussion"> + +<p>The relationship Id of thiw worksheet</p> + + + </div> +</div> +<div class="tags"> + <h3>Returns:</h3> <ul class="return"> <li> - <span class='type'>(<tt>Array</tt>)</span> + <span class='type'>(<tt>String</tt>)</span> - — - <div class='inline'><p> -of Cell objects -</p> + </li> + +</ul> + +</div><table class="source_code"> + <tr> + <td> + <pre class="lines"> + + +62 +63 +64</pre> + </td> + <td> + <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 62</span> + +<span class='kw'>def</span> <span class='id rId'>rId</span> + <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>rId</span><span class='embexpr_beg'>#{</span><span class='id index'>index</span><span class='op'>+</span><span class='int'>1</span><span class='rbrace'>}</span><span class='tstring_end'>"</span></span> +<span class='kw'>end</span></pre> + </td> + </tr> +</table> </div> + + <div class="method_details "> + <p class="signature " id="to_xml-instance_method"> + + - (<tt>String</tt>) <strong>to_xml</strong> + + + +</p><div class="docstring"> + <div class="discussion"> + +<p>Serializes the worksheet document</p> + + + </div> +</div> +<div class="tags"> + +<h3>Returns:</h3> +<ul class="return"> + + <li> + + + <span class='type'>(<tt>String</tt>)</span> + + </li> @@ -1984,49 +1636,52 @@ of Cell objects <pre class="lines"> -171 -172 -173 -174 -175 -176 -177 -178 -179 -180 -181 -182 -183 -184 -185 -186 -187 -188 -189</pre> +122 +123 +124 +125 +126 +127 +128 +129 +130 +131 +132 +133 +134 +135 +136 +137 +138 +139 +140 +141 +142</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 171</span> - -<span class='def def kw'>def</span> <span class='update_auto_fit_data identifier id'>update_auto_fit_data</span><span class='lparen token'>(</span><span class='cells identifier id'>cells</span><span class='rparen token'>)</span> - <span class='styles identifier id'>styles</span> <span class='assign token'>=</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='workbook identifier id'>workbook</span><span class='dot token'>.</span><span class='styles identifier id'>styles</span> - <span class='cellXfs identifier id'>cellXfs</span><span class='comma token'>,</span> <span class='fonts identifier id'>fonts</span> <span class='assign token'>=</span> <span class='styles identifier id'>styles</span><span class='dot token'>.</span><span class='cellXfs identifier id'>cellXfs</span><span class='comma token'>,</span> <span class='styles identifier id'>styles</span><span class='dot token'>.</span><span class='fonts identifier id'>fonts</span> - <span class='sz identifier id'>sz</span> <span class='assign token'>=</span> <span class='fonts identifier id'>fonts</span><span class='lbrack token'>[</span><span class='integer val'>0</span><span class='rbrack token'>]</span><span class='dot token'>.</span><span class='sz identifier id'>sz</span> - - <span class='cells identifier id'>cells</span><span class='dot token'>.</span><span class='each_with_index identifier id'>each_with_index</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='item identifier id'>item</span><span class='comma token'>,</span> <span class='index identifier id'>index</span><span class='bitor op'>|</span> - <span class='col identifier id'>col</span> <span class='assign token'>=</span> <span class='@auto_fit_data ivar id'>@auto_fit_data</span><span class='lbrack token'>[</span><span class='index identifier id'>index</span><span class='rbrack token'>]</span> <span class='orop op'>||</span> <span class='lbrace token'>{</span><span class='symbol val'>:longest=</span><span class='gt op'>></span><span class='string val'>""</span><span class='comma token'>,</span> <span class='symbol val'>:sz=</span><span class='gt op'>></span><span class='sz identifier id'>sz</span><span class='rbrace token'>}</span> - <span class='cell_xf identifier id'>cell_xf</span> <span class='assign token'>=</span> <span class='cellXfs identifier id'>cellXfs</span><span class='lbrack token'>[</span><span class='item identifier id'>item</span><span class='dot token'>.</span><span class='style identifier id'>style</span><span class='rbrack token'>]</span> - <span class='font identifier id'>font</span> <span class='assign token'>=</span> <span class='fonts identifier id'>fonts</span><span class='lbrack token'>[</span><span class='cell_xf identifier id'>cell_xf</span><span class='dot token'>.</span><span class='fontId identifier id'>fontId</span> <span class='orop op'>||</span> <span class='integer val'>0</span><span class='rbrack token'>]</span> - <span class='sz identifier id'>sz</span> <span class='assign token'>=</span> <span class='font identifier id'>font</span><span class='dot token'>.</span><span class='sz identifier id'>sz</span> <span class='orop op'>||</span> <span class='sz identifier id'>sz</span> - - <span class='if if kw'>if</span> <span class='lparen token'>(</span><span class='col identifier id'>col</span><span class='lbrack token'>[</span><span class='symbol val'>:longest</span><span class='rbrack token'>]</span><span class='dot token'>.</span><span class='scan identifier id'>scan</span><span class='lparen token'>(</span><span class='regexp val'>/./</span><span class='mu identifier id'>mu</span><span class='rparen token'>)</span><span class='dot token'>.</span><span class='size identifier id'>size</span> <span class='mult op'>*</span> <span class='col identifier id'>col</span><span class='lbrack token'>[</span><span class='symbol val'>:sz</span><span class='rbrack token'>]</span><span class='rparen token'>)</span> <span class='lt op'><</span> <span class='lparen token'>(</span><span class='item identifier id'>item</span><span class='dot token'>.</span><span class='value identifier id'>value</span><span class='dot token'>.</span><span class='to_s identifier id'>to_s</span><span class='dot token'>.</span><span class='scan identifier id'>scan</span><span class='lparen token'>(</span><span class='regexp val'>/./</span><span class='mu identifier id'>mu</span><span class='rparen token'>)</span><span class='dot token'>.</span><span class='size identifier id'>size</span> <span class='mult op'>*</span> <span class='sz identifier id'>sz</span><span class='rparen token'>)</span> - <span class='col identifier id'>col</span><span class='lbrack token'>[</span><span class='symbol val'>:sz</span><span class='rbrack token'>]</span> <span class='assign token'>=</span> <span class='sz identifier id'>sz</span> - <span class='col identifier id'>col</span><span class='lbrack token'>[</span><span class='symbol val'>:longest</span><span class='rbrack token'>]</span> <span class='assign token'>=</span> <span class='item identifier id'>item</span><span class='dot token'>.</span><span class='value identifier id'>value</span><span class='dot token'>.</span><span class='to_s identifier id'>to_s</span> - <span class='end end kw'>end</span> - <span class='@auto_fit_data ivar id'>@auto_fit_data</span><span class='lbrack token'>[</span><span class='index identifier id'>index</span><span class='rbrack token'>]</span> <span class='assign token'>=</span> <span class='col identifier id'>col</span> - <span class='end end kw'>end</span> - <span class='cells identifier id'>cells</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 122</span> + +<span class='kw'>def</span> <span class='id to_xml'>to_xml</span> + <span class='id builder'>builder</span> <span class='op'>=</span> <span class='const'>Nokogiri</span><span class='op'>::</span><span class='const'>XML</span><span class='op'>::</span><span class='const'>Builder</span><span class='period'>.</span><span class='id new'>new</span><span class='lparen'>(</span><span class='symbol'>:encoding</span> <span class='op'>=></span> <span class='const'>ENCODING</span><span class='rparen'>)</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id xml'>xml</span><span class='op'>|</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id worksheet'>worksheet</span><span class='lparen'>(</span><span class='symbol'>:xmlns</span> <span class='op'>=></span> <span class='const'>XML_NS</span><span class='comma'>,</span> <span class='symbol'>:xmlns:r</span><span class='tstring_end'>'</span></span> <span class='op'>=></span> <span class='const'>XML_NS_R</span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='kw'>if</span> <span class='ivar'>@auto_fit_data</span><span class='period'>.</span><span class='id size'>size</span> <span class='op'>></span> <span class='int'>0</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id cols'>cols</span> <span class='lbrace'>{</span> + <span class='ivar'>@auto_fit_data</span><span class='period'>.</span><span class='id each_with_index'>each_with_index</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id col'>col</span><span class='comma'>,</span> <span class='id index'>index</span><span class='op'>|</span> + <span class='id min_max'>min_max</span> <span class='op'>=</span> <span class='id index'>index</span><span class='op'>+</span><span class='int'>1</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id col'>col</span><span class='lparen'>(</span><span class='symbol'>:min</span><span class='op'>=></span><span class='id min_max'>min_max</span><span class='comma'>,</span> <span class='symbol'>:max</span><span class='op'>=></span><span class='id min_max'>min_max</span><span class='comma'>,</span> <span class='symbol'>:width</span> <span class='op'>=></span> <span class='id auto_width'>auto_width</span><span class='lparen'>(</span><span class='id col'>col</span><span class='rparen'>)</span><span class='comma'>,</span> <span class='symbol'>:customWidth</span><span class='op'>=></span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>true</span><span class='tstring_end'>"</span></span><span class='rparen'>)</span> + <span class='kw'>end</span> + <span class='rbrace'>}</span> + <span class='kw'>end</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id sheetData'>sheetData</span> <span class='lbrace'>{</span> + <span class='ivar'>@rows</span><span class='period'>.</span><span class='id each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id row'>row</span><span class='op'>|</span> + <span class='id row'>row</span><span class='period'>.</span><span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> + <span class='kw'>end</span> + <span class='rbrace'>}</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id drawing'>drawing</span> <span class='symbol'>:r:id</span><span class='tstring_end'>"</span></span><span class='op'>=></span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>rId1</span><span class='tstring_end'>"</span></span> <span class='kw'>if</span> <span class='ivar'>@drawing</span> + <span class='rbrace'>}</span> + <span class='kw'>end</span> + <span class='id builder'>builder</span><span class='period'>.</span><span class='id to_xml'>to_xml</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -2037,9 +1692,9 @@ of Cell objects </div> <div id="footer"> - Generated on Wed Nov 23 22:20:49 2011 by + Generated on Sat Nov 26 13:16:40 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/Axlsx/Xf.html b/doc/Axlsx/Xf.html index 8e0d5d8b..b42932ab 100644 --- a/doc/Axlsx/Xf.html +++ b/doc/Axlsx/Xf.html @@ -6,7 +6,7 @@ <title> Class: Axlsx::Xf - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -94,9 +94,9 @@ <h2>Overview</h2><div class="docstring"> <div class="discussion"> - <p> -The Xf class defines a formatting record for use in Styles -</p> + +<p>The Xf class defines a formatting record for use in Styles. The recommended +way to manage styles for your workbook is with Styles#add_style</p> </div> @@ -104,6 +104,13 @@ The Xf class defines a formatting record for use in Styles <div class="tags"> + <h3>See Also:</h3> + <ul class="see"> + + <li><span class='object_link'><a href="Styles.html#add_style-instance_method" title="Axlsx::Styles#add_style (method)">Styles#add_style</a></span></li> + + </ul> + </div> <h2>Instance Attribute Summary <small>(<a href="#" class="summary_toggle">collapse</a>)</small></h2> @@ -128,9 +135,8 @@ The Xf class defines a formatting record for use in Styles - <span class="summary_desc"><div class='inline'><p> -The cell alignment for this style. -</p> + <span class="summary_desc"><div class='inline'> +<p>The cell alignment for this style.</p> </div></span> </li> @@ -155,9 +161,8 @@ The cell alignment for this style. - <span class="summary_desc"><div class='inline'><p> -Indicates if the alignment options should be applied. -</p> + <span class="summary_desc"><div class='inline'> +<p>Indicates if the alignment options should be applied.</p> </div></span> </li> @@ -182,9 +187,8 @@ Indicates if the alignment options should be applied. - <span class="summary_desc"><div class='inline'><p> -indicates if the borderId should be applied. -</p> + <span class="summary_desc"><div class='inline'> +<p>indicates if the borderId should be applied.</p> </div></span> </li> @@ -209,9 +213,8 @@ indicates if the borderId should be applied. - <span class="summary_desc"><div class='inline'><p> -indicates if the fillId should be applied. -</p> + <span class="summary_desc"><div class='inline'> +<p>indicates if the fillId should be applied.</p> </div></span> </li> @@ -236,9 +239,8 @@ indicates if the fillId should be applied. - <span class="summary_desc"><div class='inline'><p> -indicates if the fontId should be applied. -</p> + <span class="summary_desc"><div class='inline'> +<p>indicates if the fontId should be applied.</p> </div></span> </li> @@ -263,9 +265,8 @@ indicates if the fontId should be applied. - <span class="summary_desc"><div class='inline'><p> -indicates if the numFmtId should be applied. -</p> + <span class="summary_desc"><div class='inline'> +<p>indicates if the numFmtId should be applied.</p> </div></span> </li> @@ -290,9 +291,8 @@ indicates if the numFmtId should be applied. - <span class="summary_desc"><div class='inline'><p> -Indicates if the protection options should be applied. -</p> + <span class="summary_desc"><div class='inline'> +<p>Indicates if the protection options should be applied.</p> </div></span> </li> @@ -317,9 +317,8 @@ Indicates if the protection options should be applied. - <span class="summary_desc"><div class='inline'><p> -index (0 based) of the border to be used in this style. -</p> + <span class="summary_desc"><div class='inline'> +<p>index (0 based) of the border to be used in this style.</p> </div></span> </li> @@ -344,9 +343,8 @@ index (0 based) of the border to be used in this style. - <span class="summary_desc"><div class='inline'><p> -index (0 based) of the fill to be used in this style. -</p> + <span class="summary_desc"><div class='inline'> +<p>index (0 based) of the fill to be used in this style.</p> </div></span> </li> @@ -371,9 +369,8 @@ index (0 based) of the fill to be used in this style. - <span class="summary_desc"><div class='inline'><p> -index (0 based) of the font to be used in this style. -</p> + <span class="summary_desc"><div class='inline'> +<p>index (0 based) of the font to be used in this style.</p> </div></span> </li> @@ -398,9 +395,8 @@ index (0 based) of the font to be used in this style. - <span class="summary_desc"><div class='inline'><p> -id of the numFmt to apply to this style. -</p> + <span class="summary_desc"><div class='inline'> +<p>id of the numFmt to apply to this style.</p> </div></span> </li> @@ -425,9 +421,8 @@ id of the numFmt to apply to this style. - <span class="summary_desc"><div class='inline'><p> -indicates if the cell has a pivot table drop down button. -</p> + <span class="summary_desc"><div class='inline'> +<p>indicates if the cell has a pivot table drop down button.</p> </div></span> </li> @@ -452,9 +447,8 @@ indicates if the cell has a pivot table drop down button. - <span class="summary_desc"><div class='inline'><p> -The cell protection for this style. -</p> + <span class="summary_desc"><div class='inline'> +<p>The cell protection for this style.</p> </div></span> </li> @@ -479,9 +473,8 @@ The cell protection for this style. - <span class="summary_desc"><div class='inline'><p> -indecates if text should be prefixed by a single quote in the cell. -</p> + <span class="summary_desc"><div class='inline'> +<p>indecates if text should be prefixed by a single quote in the cell.</p> </div></span> </li> @@ -506,9 +499,8 @@ indecates if text should be prefixed by a single quote in the cell. - <span class="summary_desc"><div class='inline'><p> -index (0 based) of cellStylesXfs item to be used in this style. -</p> + <span class="summary_desc"><div class='inline'> +<p>index (0 based) of cellStylesXfs item to be used in this style.</p> </div></span> </li> @@ -545,9 +537,8 @@ index (0 based) of cellStylesXfs item to be used in this style. - <span class="summary_desc"><div class='inline'><p> -Creates a new Xf object. -</p> + <span class="summary_desc"><div class='inline'> +<p>Creates a new Xf object.</p> </div></span> </li> @@ -569,9 +560,8 @@ Creates a new Xf object. - <span class="summary_desc"><div class='inline'><p> -Serializes the xf elemen. -</p> + <span class="summary_desc"><div class='inline'> +<p>Serializes the xf elemen.</p> </div></span> </li> @@ -592,9 +582,8 @@ Serializes the xf elemen. </p><div class="docstring"> <div class="discussion"> - <p> -Creates a new Xf object -</p> + +<p>Creates a new Xf object</p> </div> @@ -605,68 +594,18 @@ Creates a new Xf object <li> - <span class='name'>[Integer]</span> - - - <span class='type'>(<tt>Hash</tt>)</span> - - - - — - <div class='inline'><p> -a customizable set of options -</p> -</div> - - </li> - - <li> - - <span class='name'>[Boolean]</span> + <span class='name'>options</span> <span class='type'>(<tt>Hash</tt>)</span> - - — - <div class='inline'><p> -a customizable set of options -</p> -</div> - - </li> - - <li> - - <span class='name'>[CellAlignment]</span> - - - <span class='type'>(<tt>Hash</tt>)</span> - - - - — - <div class='inline'><p> -a customizable set of options -</p> -</div> - - </li> - - <li> - - <span class='name'>[CellProtection]</span> - - - <span class='type'>(<tt>Hash</tt>)</span> - + <em class="default">(defaults to: <tt>{}</tt>)</em> — - <div class='inline'><p> -a customizable set of options -</p> + <div class='inline'> +<p>a customizable set of options</p> </div> </li> @@ -676,6 +615,146 @@ a customizable set of options + <h3>Options Hash (<tt>options</tt>):</h3> + <ul class="option"> + + <li> + <span class="name">numFmtId</span> + <span class="type">(<tt>Integer</tt>)</span> + <span class="default"> + + </span> + + </li> + + <li> + <span class="name">fontId</span> + <span class="type">(<tt>Integer</tt>)</span> + <span class="default"> + + </span> + + </li> + + <li> + <span class="name">fillId</span> + <span class="type">(<tt>Integer</tt>)</span> + <span class="default"> + + </span> + + </li> + + <li> + <span class="name">borderId</span> + <span class="type">(<tt>Integer</tt>)</span> + <span class="default"> + + </span> + + </li> + + <li> + <span class="name">xfId</span> + <span class="type">(<tt>Integer</tt>)</span> + <span class="default"> + + </span> + + </li> + + <li> + <span class="name">quotePrefix</span> + <span class="type">(<tt>Boolean</tt>)</span> + <span class="default"> + + </span> + + </li> + + <li> + <span class="name">pivotButton</span> + <span class="type">(<tt>Boolean</tt>)</span> + <span class="default"> + + </span> + + </li> + + <li> + <span class="name">applyNumberFormat</span> + <span class="type">(<tt>Boolean</tt>)</span> + <span class="default"> + + </span> + + </li> + + <li> + <span class="name">applyFont</span> + <span class="type">(<tt>Boolean</tt>)</span> + <span class="default"> + + </span> + + </li> + + <li> + <span class="name">applyFill</span> + <span class="type">(<tt>Boolean</tt>)</span> + <span class="default"> + + </span> + + </li> + + <li> + <span class="name">applyBorder</span> + <span class="type">(<tt>Boolean</tt>)</span> + <span class="default"> + + </span> + + </li> + + <li> + <span class="name">applyAlignment</span> + <span class="type">(<tt>Boolean</tt>)</span> + <span class="default"> + + </span> + + </li> + + <li> + <span class="name">applyProtection</span> + <span class="type">(<tt>Boolean</tt>)</span> + <span class="default"> + + </span> + + </li> + + <li> + <span class="name">alignment</span> + <span class="type">(<tt><span class='object_link'><a href="CellAlignment.html" title="Axlsx::CellAlignment (class)">CellAlignment</a></span></tt>)</span> + <span class="default"> + + </span> + + </li> + + <li> + <span class="name">protection</span> + <span class="type">(<tt><span class='object_link'><a href="CellProtection.html" title="Axlsx::CellProtection (class)">CellProtection</a></span></tt>)</span> + <span class="default"> + + </span> + + </li> + + </ul> + </div><table class="source_code"> @@ -684,21 +763,20 @@ a customizable set of options <pre class="lines"> -84 85 86 87 -88</pre> +88 +89</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/xf.rb', line 84</span> - -<span class='def def kw'>def</span> <span class='initialize identifier id'>initialize</span><span class='lparen token'>(</span><span class='options identifier id'>options</span><span class='assign token'>=</span><span class='lbrace token'>{</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> - <span class='options identifier id'>options</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='o identifier id'>o</span><span class='bitor op'>|</span> - <span class='self self kw'>self</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='dstring node'>"#{o[0]}="</span><span class='comma token'>,</span> <span class='o identifier id'>o</span><span class='lbrack token'>[</span><span class='integer val'>1</span><span class='rbrack token'>]</span><span class='rparen token'>)</span> <span class='if if_mod kw'>if</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='respond_to? fid id'>respond_to?</span> <span class='dstring node'>"#{o[0]}="</span> - <span class='end end kw'>end</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/xf.rb', line 85</span> + +<span class='kw'>def</span> <span class='id initialize'>initialize</span><span class='lparen'>(</span><span class='id options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span> + <span class='id options'>options</span><span class='period'>.</span><span class='id each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id o'>o</span><span class='op'>|</span> + <span class='kw'>self</span><span class='period'>.</span><span class='id send'>send</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span><span class='rbrace'>}</span><span class='tstring_content'>=</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>1</span><span class='rbracket'>]</span><span class='rparen'>)</span> <span class='kw'>if</span> <span class='kw'>self</span><span class='period'>.</span><span class='id respond_to?'>respond_to?</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='id o'>o</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span><span class='rbrace'>}</span><span class='tstring_content'>=</span><span class='tstring_end'>"</span></span> + <span class='kw'>end</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -721,9 +799,8 @@ a customizable set of options </p><div class="docstring"> <div class="discussion"> - <p> -The cell alignment for this style -</p> + +<p>The cell alignment for this style</p> </div> @@ -757,17 +834,16 @@ The cell alignment for this style <pre class="lines"> -9 10 -11</pre> +11 +12</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/xf.rb', line 9</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/xf.rb', line 10</span> -<span class='def def kw'>def</span> <span class='alignment identifier id'>alignment</span> - <span class='@alignment ivar id'>@alignment</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id alignment'>alignment</span> + <span class='ivar'>@alignment</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -785,9 +861,8 @@ The cell alignment for this style </p><div class="docstring"> <div class="discussion"> - <p> -Indicates if the alignment options should be applied -</p> + +<p>Indicates if the alignment options should be applied</p> </div> @@ -814,17 +889,16 @@ Indicates if the alignment options should be applied <pre class="lines"> -62 63 -64</pre> +64 +65</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/xf.rb', line 62</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/xf.rb', line 63</span> -<span class='def def kw'>def</span> <span class='applyAlignment identifier id'>applyAlignment</span> - <span class='@applyAlignment ivar id'>@applyAlignment</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id applyAlignment'>applyAlignment</span> + <span class='ivar'>@applyAlignment</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -842,9 +916,8 @@ Indicates if the alignment options should be applied </p><div class="docstring"> <div class="discussion"> - <p> -indicates if the borderId should be applied -</p> + +<p>indicates if the borderId should be applied</p> </div> @@ -871,17 +944,16 @@ indicates if the borderId should be applied <pre class="lines"> -58 59 -60</pre> +60 +61</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/xf.rb', line 58</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/xf.rb', line 59</span> -<span class='def def kw'>def</span> <span class='applyBorder identifier id'>applyBorder</span> - <span class='@applyBorder ivar id'>@applyBorder</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id applyBorder'>applyBorder</span> + <span class='ivar'>@applyBorder</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -899,9 +971,8 @@ indicates if the borderId should be applied </p><div class="docstring"> <div class="discussion"> - <p> -indicates if the fillId should be applied -</p> + +<p>indicates if the fillId should be applied</p> </div> @@ -928,17 +999,16 @@ indicates if the fillId should be applied <pre class="lines"> -54 55 -56</pre> +56 +57</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/xf.rb', line 54</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/xf.rb', line 55</span> -<span class='def def kw'>def</span> <span class='applyFill identifier id'>applyFill</span> - <span class='@applyFill ivar id'>@applyFill</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id applyFill'>applyFill</span> + <span class='ivar'>@applyFill</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -956,9 +1026,8 @@ indicates if the fillId should be applied </p><div class="docstring"> <div class="discussion"> - <p> -indicates if the fontId should be applied -</p> + +<p>indicates if the fontId should be applied</p> </div> @@ -985,17 +1054,16 @@ indicates if the fontId should be applied <pre class="lines"> -50 51 -52</pre> +52 +53</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/xf.rb', line 50</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/xf.rb', line 51</span> -<span class='def def kw'>def</span> <span class='applyFont identifier id'>applyFont</span> - <span class='@applyFont ivar id'>@applyFont</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id applyFont'>applyFont</span> + <span class='ivar'>@applyFont</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1013,9 +1081,8 @@ indicates if the fontId should be applied </p><div class="docstring"> <div class="discussion"> - <p> -indicates if the numFmtId should be applied -</p> + +<p>indicates if the numFmtId should be applied</p> </div> @@ -1042,17 +1109,16 @@ indicates if the numFmtId should be applied <pre class="lines"> -46 47 -48</pre> +48 +49</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/xf.rb', line 46</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/xf.rb', line 47</span> -<span class='def def kw'>def</span> <span class='applyNumberFormat identifier id'>applyNumberFormat</span> - <span class='@applyNumberFormat ivar id'>@applyNumberFormat</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id applyNumberFormat'>applyNumberFormat</span> + <span class='ivar'>@applyNumberFormat</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1070,9 +1136,8 @@ indicates if the numFmtId should be applied </p><div class="docstring"> <div class="discussion"> - <p> -Indicates if the protection options should be applied -</p> + +<p>Indicates if the protection options should be applied</p> </div> @@ -1099,17 +1164,16 @@ Indicates if the protection options should be applied <pre class="lines"> -66 67 -68</pre> +68 +69</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/xf.rb', line 66</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/xf.rb', line 67</span> -<span class='def def kw'>def</span> <span class='applyProtection identifier id'>applyProtection</span> - <span class='@applyProtection ivar id'>@applyProtection</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id applyProtection'>applyProtection</span> + <span class='ivar'>@applyProtection</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1127,9 +1191,8 @@ Indicates if the protection options should be applied </p><div class="docstring"> <div class="discussion"> - <p> -index (0 based) of the border to be used in this style -</p> + +<p>index (0 based) of the border to be used in this style</p> </div> @@ -1156,17 +1219,16 @@ index (0 based) of the border to be used in this style <pre class="lines"> -30 31 -32</pre> +32 +33</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/xf.rb', line 30</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/xf.rb', line 31</span> -<span class='def def kw'>def</span> <span class='borderId identifier id'>borderId</span> - <span class='@borderId ivar id'>@borderId</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id borderId'>borderId</span> + <span class='ivar'>@borderId</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1184,9 +1246,8 @@ index (0 based) of the border to be used in this style </p><div class="docstring"> <div class="discussion"> - <p> -index (0 based) of the fill to be used in this style -</p> + +<p>index (0 based) of the fill to be used in this style</p> </div> @@ -1213,17 +1274,16 @@ index (0 based) of the fill to be used in this style <pre class="lines"> -26 27 -28</pre> +28 +29</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/xf.rb', line 26</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/xf.rb', line 27</span> -<span class='def def kw'>def</span> <span class='fillId identifier id'>fillId</span> - <span class='@fillId ivar id'>@fillId</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id fillId'>fillId</span> + <span class='ivar'>@fillId</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1241,9 +1301,8 @@ index (0 based) of the fill to be used in this style </p><div class="docstring"> <div class="discussion"> - <p> -index (0 based) of the font to be used in this style -</p> + +<p>index (0 based) of the font to be used in this style</p> </div> @@ -1270,17 +1329,16 @@ index (0 based) of the font to be used in this style <pre class="lines"> -22 23 -24</pre> +24 +25</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/xf.rb', line 22</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/xf.rb', line 23</span> -<span class='def def kw'>def</span> <span class='fontId identifier id'>fontId</span> - <span class='@fontId ivar id'>@fontId</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id fontId'>fontId</span> + <span class='ivar'>@fontId</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1298,9 +1356,8 @@ index (0 based) of the font to be used in this style </p><div class="docstring"> <div class="discussion"> - <p> -id of the numFmt to apply to this style -</p> + +<p>id of the numFmt to apply to this style</p> </div> @@ -1327,17 +1384,16 @@ id of the numFmt to apply to this style <pre class="lines"> -18 19 -20</pre> +20 +21</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/xf.rb', line 18</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/xf.rb', line 19</span> -<span class='def def kw'>def</span> <span class='numFmtId identifier id'>numFmtId</span> - <span class='@numFmtId ivar id'>@numFmtId</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id numFmtId'>numFmtId</span> + <span class='ivar'>@numFmtId</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1355,9 +1411,8 @@ id of the numFmt to apply to this style </p><div class="docstring"> <div class="discussion"> - <p> -indicates if the cell has a pivot table drop down button -</p> + +<p>indicates if the cell has a pivot table drop down button</p> </div> @@ -1384,17 +1439,16 @@ indicates if the cell has a pivot table drop down button <pre class="lines"> -42 43 -44</pre> +44 +45</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/xf.rb', line 42</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/xf.rb', line 43</span> -<span class='def def kw'>def</span> <span class='pivotButton identifier id'>pivotButton</span> - <span class='@pivotButton ivar id'>@pivotButton</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id pivotButton'>pivotButton</span> + <span class='ivar'>@pivotButton</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1412,9 +1466,8 @@ indicates if the cell has a pivot table drop down button </p><div class="docstring"> <div class="discussion"> - <p> -The cell protection for this style -</p> + +<p>The cell protection for this style</p> </div> @@ -1448,17 +1501,16 @@ The cell protection for this style <pre class="lines"> -14 15 -16</pre> +16 +17</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/xf.rb', line 14</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/xf.rb', line 15</span> -<span class='def def kw'>def</span> <span class='protection identifier id'>protection</span> - <span class='@protection ivar id'>@protection</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id protection'>protection</span> + <span class='ivar'>@protection</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1476,9 +1528,8 @@ The cell protection for this style </p><div class="docstring"> <div class="discussion"> - <p> -indecates if text should be prefixed by a single quote in the cell -</p> + +<p>indecates if text should be prefixed by a single quote in the cell</p> </div> @@ -1505,17 +1556,16 @@ indecates if text should be prefixed by a single quote in the cell <pre class="lines"> -38 39 -40</pre> +40 +41</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/xf.rb', line 38</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/xf.rb', line 39</span> -<span class='def def kw'>def</span> <span class='quotePrefix identifier id'>quotePrefix</span> - <span class='@quotePrefix ivar id'>@quotePrefix</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id quotePrefix'>quotePrefix</span> + <span class='ivar'>@quotePrefix</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1533,10 +1583,9 @@ indecates if text should be prefixed by a single quote in the cell </p><div class="docstring"> <div class="discussion"> - <p> -index (0 based) of cellStylesXfs item to be used in this style. Only -applies to cellXfs items -</p> + +<p>index (0 based) of cellStylesXfs item to be used in this style. Only +applies to cellXfs items</p> </div> @@ -1563,17 +1612,16 @@ applies to cellXfs items <pre class="lines"> -34 35 -36</pre> +36 +37</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/xf.rb', line 34</span> + <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/xf.rb', line 35</span> -<span class='def def kw'>def</span> <span class='xfId identifier id'>xfId</span> - <span class='@xfId ivar id'>@xfId</span> -<span class='end end kw'>end</span> -</pre> +<span class='kw'>def</span> <span class='id xfId'>xfId</span> + <span class='ivar'>@xfId</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1595,9 +1643,8 @@ applies to cellXfs items </p><div class="docstring"> <div class="discussion"> - <p> -Serializes the xf elemen -</p> + +<p>Serializes the xf elemen</p> </div> @@ -1616,9 +1663,8 @@ Serializes the xf elemen — - <div class='inline'><p> -The document builder instance this objects xml will be added to. -</p> + <div class='inline'> +<p>The document builder instance this objects xml will be added to.</p> </div> </li> @@ -1645,23 +1691,22 @@ The document builder instance this objects xml will be added to. <pre class="lines"> -110 -111 -112 -113 -114 -115</pre> +131 +132 +133 +134 +135 +136</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/xf.rb', line 110</span> - -<span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> - <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='xf identifier id'>xf</span><span class='lparen token'>(</span><span class='self self kw'>self</span><span class='dot token'>.</span><span class='instance_values identifier id'>instance_values</span><span class='dot token'>.</span><span class='reject identifier id'>reject</span> <span class='lbrace token'>{</span> <span class='bitor op'>|</span><span class='k identifier id'>k</span><span class='comma token'>,</span> <span class='v identifier id'>v</span><span class='bitor op'>|</span> <span class='lbrack token'>[</span><span class='symbol val'>:alignment</span><span class='comma token'>,</span> <span class='symbol val'>:protection</span><span class='comma token'>,</span> <span class='symbol val'>:extList</span><span class='comma token'>,</span> <span class='symbol val'>:name</span><span class='rbrack token'>]</span><span class='dot token'>.</span><span class='include? fid id'>include?</span> <span class='k identifier id'>k</span><span class='dot token'>.</span><span class='to_sym identifier id'>to_sym</span><span class='rbrace token'>}</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span> - <span class='alignment identifier id'>alignment</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> <span class='if if_mod kw'>if</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='alignment identifier id'>alignment</span> - <span class='protection identifier id'>protection</span><span class='dot token'>.</span><span class='to_xml identifier id'>to_xml</span><span class='lparen token'>(</span><span class='xml identifier id'>xml</span><span class='rparen token'>)</span> <span class='if if_mod kw'>if</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='protection identifier id'>protection</span> - <span class='rbrace token'>}</span> -<span class='end end kw'>end</span> -</pre> + <pre class="code"><span class="info file"># File 'lib/axlsx/stylesheet/xf.rb', line 131</span> + +<span class='kw'>def</span> <span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> + <span class='id xml'>xml</span><span class='period'>.</span><span class='id xf'>xf</span><span class='lparen'>(</span><span class='kw'>self</span><span class='period'>.</span><span class='id instance_values'>instance_values</span><span class='period'>.</span><span class='id reject'>reject</span> <span class='lbrace'>{</span> <span class='op'>|</span><span class='id k'>k</span><span class='comma'>,</span> <span class='id v'>v</span><span class='op'>|</span> <span class='lbracket'>[</span><span class='symbol'>:alignment</span><span class='comma'>,</span> <span class='symbol'>:protection</span><span class='comma'>,</span> <span class='symbol'>:extList</span><span class='comma'>,</span> <span class='symbol'>:name</span><span class='rbracket'>]</span><span class='period'>.</span><span class='id include?'>include?</span> <span class='id k'>k</span><span class='period'>.</span><span class='id to_sym'>to_sym</span><span class='rbrace'>}</span><span class='rparen'>)</span> <span class='lbrace'>{</span> + <span class='id alignment'>alignment</span><span class='period'>.</span><span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> <span class='kw'>if</span> <span class='kw'>self</span><span class='period'>.</span><span class='id alignment'>alignment</span> + <span class='id protection'>protection</span><span class='period'>.</span><span class='id to_xml'>to_xml</span><span class='lparen'>(</span><span class='id xml'>xml</span><span class='rparen'>)</span> <span class='kw'>if</span> <span class='kw'>self</span><span class='period'>.</span><span class='id protection'>protection</span> + <span class='rbrace'>}</span> +<span class='kw'>end</span></pre> </td> </tr> </table> @@ -1672,9 +1717,9 @@ The document builder instance this objects xml will be added to. </div> <div id="footer"> - Generated on Wed Nov 23 22:21:02 2011 by + Generated on Sat Nov 26 13:16:37 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/_index.html b/doc/_index.html index 2ffb447b..06787029 100644 --- a/doc/_index.html +++ b/doc/_index.html @@ -4,7 +4,7 @@ <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title> - Documentation by YARD 0.7.3 + AXLSX </title> @@ -52,7 +52,7 @@ <iframe id="search_frame"></iframe> - <div id="content"><h1 class="noborder title">Documentation by YARD 0.7.3</h1> + <div id="content"><h1 class="noborder title">AXLSX</h1> <div id="listing"> <h1 class="alphaindex">Alphabetic Index</h1> @@ -63,6 +63,9 @@ <li class="r1"><a href="index.html" title="README">README</a></li> + <li class="r2"><a href="file.LICENSE.html" title="LICENSE">LICENSE</a></li> + + </ul> <div class="clear"></div> @@ -493,13 +496,6 @@ </li> <li> - <span class='object_link'><a href="Axlsx/SimpleTypedList.html" title="Axlsx::SimpleTypedList (class)">SimpleTypedList</a></span> - - <small>(Axlsx)</small> - - </li> - - <li> <span class='object_link'><a href="Axlsx/Styles.html" title="Axlsx::Styles (class)">Styles</a></span> <small>(Axlsx)</small> @@ -630,9 +626,9 @@ </div> <div id="footer"> - Generated on Wed Nov 23 22:20:44 2011 by + Generated on Sat Nov 26 13:16:35 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/class_list.html b/doc/class_list.html index 060e3f46..2d555b04 100644 --- a/doc/class_list.html +++ b/doc/class_list.html @@ -39,7 +39,7 @@ <ul id="full_list" class="class"> <li><span class='object_link'><a href="top-level-namespace.html" title=" (root)">Top Level Namespace</a></span></li> -<li><a class='toggle'></a> <span class='object_link'><a href="Axlsx.html" title="Axlsx (module)">Axlsx</a></span><small class='search_info'>Top Level Namespace</small></li><ul><li><span class='object_link'><a href="Axlsx/App.html" title="Axlsx::App (class)">App</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Axis.html" title="Axlsx::Axis (class)">Axis</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Bar3DChart.html" title="Axlsx::Bar3DChart (class)">Bar3DChart</a></span> < Chart<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/BarSeries.html" title="Axlsx::BarSeries (class)">BarSeries</a></span> < Series<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Border.html" title="Axlsx::Border (class)">Border</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/BorderPr.html" title="Axlsx::BorderPr (class)">BorderPr</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/CatAxis.html" title="Axlsx::CatAxis (class)">CatAxis</a></span> < Axis<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/CatAxisData.html" title="Axlsx::CatAxisData (class)">CatAxisData</a></span> < SimpleTypedList<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Cell.html" title="Axlsx::Cell (class)">Cell</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/CellAlignment.html" title="Axlsx::CellAlignment (class)">CellAlignment</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/CellProtection.html" title="Axlsx::CellProtection (class)">CellProtection</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/CellStyle.html" title="Axlsx::CellStyle (class)">CellStyle</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Chart.html" title="Axlsx::Chart (class)">Chart</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Color.html" title="Axlsx::Color (class)">Color</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/ContentType.html" title="Axlsx::ContentType (class)">ContentType</a></span> < SimpleTypedList<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Core.html" title="Axlsx::Core (class)">Core</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/DataTypeValidator.html" title="Axlsx::DataTypeValidator (class)">DataTypeValidator</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Default.html" title="Axlsx::Default (class)">Default</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Drawing.html" title="Axlsx::Drawing (class)">Drawing</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Fill.html" title="Axlsx::Fill (class)">Fill</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Font.html" title="Axlsx::Font (class)">Font</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/GradientFill.html" title="Axlsx::GradientFill (class)">GradientFill</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/GradientStop.html" title="Axlsx::GradientStop (class)">GradientStop</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/GraphicFrame.html" title="Axlsx::GraphicFrame (class)">GraphicFrame</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Line3DChart.html" title="Axlsx::Line3DChart (class)">Line3DChart</a></span> < Chart<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/LineSeries.html" title="Axlsx::LineSeries (class)">LineSeries</a></span> < Series<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Marker.html" title="Axlsx::Marker (class)">Marker</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/NumFmt.html" title="Axlsx::NumFmt (class)">NumFmt</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/OneCellAnchor.html" title="Axlsx::OneCellAnchor (class)">OneCellAnchor</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Override.html" title="Axlsx::Override (class)">Override</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Package.html" title="Axlsx::Package (class)">Package</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/PatternFill.html" title="Axlsx::PatternFill (class)">PatternFill</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Pic.html" title="Axlsx::Pic (class)">Pic</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Pie3DChart.html" title="Axlsx::Pie3DChart (class)">Pie3DChart</a></span> < Chart<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/PieSeries.html" title="Axlsx::PieSeries (class)">PieSeries</a></span> < Series<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/RegexValidator.html" title="Axlsx::RegexValidator (class)">RegexValidator</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Relationship.html" title="Axlsx::Relationship (class)">Relationship</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Relationships.html" title="Axlsx::Relationships (class)">Relationships</a></span> < SimpleTypedList<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/RestrictionValidator.html" title="Axlsx::RestrictionValidator (class)">RestrictionValidator</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Row.html" title="Axlsx::Row (class)">Row</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Scaling.html" title="Axlsx::Scaling (class)">Scaling</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/SerAxis.html" title="Axlsx::SerAxis (class)">SerAxis</a></span> < Axis<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Series.html" title="Axlsx::Series (class)">Series</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/SeriesTitle.html" title="Axlsx::SeriesTitle (class)">SeriesTitle</a></span> < Title<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/SimpleTypedList.html" title="Axlsx::SimpleTypedList (class)">SimpleTypedList</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Styles.html" title="Axlsx::Styles (class)">Styles</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/TableStyle.html" title="Axlsx::TableStyle (class)">TableStyle</a></span> < SimpleTypedList<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/TableStyleElement.html" title="Axlsx::TableStyleElement (class)">TableStyleElement</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/TableStyles.html" title="Axlsx::TableStyles (class)">TableStyles</a></span> < SimpleTypedList<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Title.html" title="Axlsx::Title (class)">Title</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/TwoCellAnchor.html" title="Axlsx::TwoCellAnchor (class)">TwoCellAnchor</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/ValAxis.html" title="Axlsx::ValAxis (class)">ValAxis</a></span> < Axis<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/ValAxisData.html" title="Axlsx::ValAxisData (class)">ValAxisData</a></span> < CatAxisData<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/View3D.html" title="Axlsx::View3D (class)">View3D</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Workbook.html" title="Axlsx::Workbook (class)">Workbook</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Worksheet.html" title="Axlsx::Worksheet (class)">Worksheet</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Xf.html" title="Axlsx::Xf (class)">Xf</a></span> < Object<small class='search_info'>Axlsx</small></li></ul> +<li><a class='toggle'></a> <span class='object_link'><a href="Axlsx.html" title="Axlsx (module)">Axlsx</a></span><small class='search_info'>Top Level Namespace</small></li><ul><li><span class='object_link'><a href="Axlsx/App.html" title="Axlsx::App (class)">App</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Axis.html" title="Axlsx::Axis (class)">Axis</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Bar3DChart.html" title="Axlsx::Bar3DChart (class)">Bar3DChart</a></span> < Chart<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/BarSeries.html" title="Axlsx::BarSeries (class)">BarSeries</a></span> < Series<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Border.html" title="Axlsx::Border (class)">Border</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/BorderPr.html" title="Axlsx::BorderPr (class)">BorderPr</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/CatAxis.html" title="Axlsx::CatAxis (class)">CatAxis</a></span> < Axis<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/CatAxisData.html" title="Axlsx::CatAxisData (class)">CatAxisData</a></span> < SimpleTypedList<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Cell.html" title="Axlsx::Cell (class)">Cell</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/CellAlignment.html" title="Axlsx::CellAlignment (class)">CellAlignment</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/CellProtection.html" title="Axlsx::CellProtection (class)">CellProtection</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/CellStyle.html" title="Axlsx::CellStyle (class)">CellStyle</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Chart.html" title="Axlsx::Chart (class)">Chart</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Color.html" title="Axlsx::Color (class)">Color</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/ContentType.html" title="Axlsx::ContentType (class)">ContentType</a></span> < SimpleTypedList<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Core.html" title="Axlsx::Core (class)">Core</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/DataTypeValidator.html" title="Axlsx::DataTypeValidator (class)">DataTypeValidator</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Default.html" title="Axlsx::Default (class)">Default</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Drawing.html" title="Axlsx::Drawing (class)">Drawing</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Fill.html" title="Axlsx::Fill (class)">Fill</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Font.html" title="Axlsx::Font (class)">Font</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/GradientFill.html" title="Axlsx::GradientFill (class)">GradientFill</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/GradientStop.html" title="Axlsx::GradientStop (class)">GradientStop</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/GraphicFrame.html" title="Axlsx::GraphicFrame (class)">GraphicFrame</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Line3DChart.html" title="Axlsx::Line3DChart (class)">Line3DChart</a></span> < Chart<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/LineSeries.html" title="Axlsx::LineSeries (class)">LineSeries</a></span> < Series<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Marker.html" title="Axlsx::Marker (class)">Marker</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/NumFmt.html" title="Axlsx::NumFmt (class)">NumFmt</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/OneCellAnchor.html" title="Axlsx::OneCellAnchor (class)">OneCellAnchor</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Override.html" title="Axlsx::Override (class)">Override</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Package.html" title="Axlsx::Package (class)">Package</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/PatternFill.html" title="Axlsx::PatternFill (class)">PatternFill</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Pic.html" title="Axlsx::Pic (class)">Pic</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Pie3DChart.html" title="Axlsx::Pie3DChart (class)">Pie3DChart</a></span> < Chart<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/PieSeries.html" title="Axlsx::PieSeries (class)">PieSeries</a></span> < Series<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/RegexValidator.html" title="Axlsx::RegexValidator (class)">RegexValidator</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Relationship.html" title="Axlsx::Relationship (class)">Relationship</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Relationships.html" title="Axlsx::Relationships (class)">Relationships</a></span> < SimpleTypedList<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/RestrictionValidator.html" title="Axlsx::RestrictionValidator (class)">RestrictionValidator</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Row.html" title="Axlsx::Row (class)">Row</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Scaling.html" title="Axlsx::Scaling (class)">Scaling</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/SerAxis.html" title="Axlsx::SerAxis (class)">SerAxis</a></span> < Axis<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Series.html" title="Axlsx::Series (class)">Series</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/SeriesTitle.html" title="Axlsx::SeriesTitle (class)">SeriesTitle</a></span> < Title<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Styles.html" title="Axlsx::Styles (class)">Styles</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/TableStyle.html" title="Axlsx::TableStyle (class)">TableStyle</a></span> < SimpleTypedList<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/TableStyleElement.html" title="Axlsx::TableStyleElement (class)">TableStyleElement</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/TableStyles.html" title="Axlsx::TableStyles (class)">TableStyles</a></span> < SimpleTypedList<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Title.html" title="Axlsx::Title (class)">Title</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/TwoCellAnchor.html" title="Axlsx::TwoCellAnchor (class)">TwoCellAnchor</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/ValAxis.html" title="Axlsx::ValAxis (class)">ValAxis</a></span> < Axis<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/ValAxisData.html" title="Axlsx::ValAxisData (class)">ValAxisData</a></span> < CatAxisData<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/View3D.html" title="Axlsx::View3D (class)">View3D</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Workbook.html" title="Axlsx::Workbook (class)">Workbook</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Worksheet.html" title="Axlsx::Worksheet (class)">Worksheet</a></span> < Object<small class='search_info'>Axlsx</small></li><li><span class='object_link'><a href="Axlsx/Xf.html" title="Axlsx::Xf (class)">Xf</a></span> < Object<small class='search_info'>Axlsx</small></li></ul> </ul> </div> diff --git a/doc/file.LICENSE.html b/doc/file.LICENSE.html new file mode 100644 index 00000000..239b148f --- /dev/null +++ b/doc/file.LICENSE.html @@ -0,0 +1,86 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" + "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> + <head> + <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> +<title> + File: LICENSE + + — AXLSX + +</title> + + <link rel="stylesheet" href="css/style.css" type="text/css" media="screen" charset="utf-8" /> + + <link rel="stylesheet" href="css/common.css" type="text/css" media="screen" charset="utf-8" /> + +<script type="text/javascript" charset="utf-8"> + relpath = ''; + if (relpath != '') relpath += '/'; +</script> + + <script type="text/javascript" charset="utf-8" src="js/jquery.js"></script> + + <script type="text/javascript" charset="utf-8" src="js/app.js"></script> + + + </head> + <body> + <script type="text/javascript" charset="utf-8"> + if (window.top.frames.main) document.body.className = 'frames'; + </script> + + <div id="header"> + <div id="menu"> + + <a href="_index.html" title="Index">Index</a> » + <span class="title">File: LICENSE</span> + + + <div class="noframes"><span class="title">(</span><a href="." target="_top">no frames</a><span class="title">)</span></div> +</div> + + <div id="search"> + + <a id="class_list_link" href="#">Class List</a> + + <a id="method_list_link" href="#">Method List</a> + + <a id="file_list_link" href="#">File List</a> + +</div> + <div class="clear"></div> + </div> + + <iframe id="search_frame"></iframe> + + <div id="content"><div id='filecontents'> +<p>Copyright © 2011 Randy Morgan</p> + +<p>Permission is hereby granted, free of charge, to any person obtaining a +copy of this software and associated documentation files (the “Software”), +to deal in the Software without restriction, including without limitation +the rights to use, copy, modify, merge, publish, distribute, sublicense, +and/or sell copies of the Software, and to permit persons to whom the +Software is furnished to do so, subject to the following conditions:</p> + +<p>The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software.</p> + +<p>THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING +FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER +DEALINGS IN THE SOFTWARE.</p> +</div></div> + + <div id="footer"> + Generated on Sat Nov 26 13:16:35 2011 by + <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> + 0.7.3 (ruby-1.9.3). +</div> + + </body> +</html>
\ No newline at end of file diff --git a/doc/file.README.html b/doc/file.README.html index 18af1cab..f76e610f 100644 --- a/doc/file.README.html +++ b/doc/file.README.html @@ -2,11 +2,11 @@ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <head> - <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> + <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> <title> File: README - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -61,14 +61,18 @@ <strong>Author</strong>: Randy Morgan <br/> <strong>Copyright</strong>: 2011 <br/> <strong>License</strong>: MIT License <br/> -<strong>Latest Version</strong>: 1.0.8 <br/> -<strong>Ruby Version</strong>: 1.8.7 <br/> -<strong>Release Date</strong>: November 23nd 2011</p> +<strong>Latest Version</strong>: 1.0.9 <br/> +<strong>Ruby Version</strong>: 1.8.7 - 1.9.3 <br/> +<strong>Release Date</strong>: November 26th 2011</p> <h2>Synopsis</h2> <p>Axlsx is an Office Open XML Spreadsheet generator for the Ruby programming language. -It enables the you to generate 100% valid xlsx files that include customised styling, images, 3D pie, bar and line charts and auto-width columns. Below is a summary of salient features.</p> +With Axlsx you can create worksheets with charts, images, automated column width, customizable styles and full schema validation. Axlsx excels at helping you generate beautiful Office Open XML Spreadsheet documents without having to understand the entire ECMA specification. Check out the README for some examples of how easy it is. Best of all, you can validate your xlsx file before serialization so you know for sure that anything generated is going to load on your client's machine.</p> + +<h2>Help Wanted</h2> + +<p>I'd really like to get rid of the depenency on RMagick in this gem. RMagic is being used to calculate the column widths in a worksheet based on the content the user specified. If there happens to be anyone out there with the background and c skills to write an extenstion that can determine the width of a single character rendered with a specific font at a specific font size please give me a shout.</p> <h2>Feature List</h2> @@ -90,130 +94,141 @@ It enables the you to generate 100% valid xlsx files that include customised sty <p>To install Axlsx, use the following command:</p> -<pre class="code">$ <span class='gem identifier id'>gem</span> <span class='install identifier id'>install</span> <span class='axlsx identifier id'>axlsx</span> +<pre class="code">$ gem install axlsx </pre> <h2>Usage</h2> <h3>Examples</h3> -<pre class="code"> <span class='require identifier id'>require</span> <span class='string val'>'rubygems'</span> - <span class='require identifier id'>require</span> <span class='string val'>'axlsx'</span> +<pre class="code"> <span class='id require'>require</span> <span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>rubygems</span><span class='tstring_end'>'</span></span> + <span class='id require'>require</span> <span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>axlsx</span><span class='tstring_end'>'</span></span> </pre> <p>A Simple Workbook</p> -<pre class="code"> <span class='p identifier id'>p</span> <span class='assign token'>=</span> <span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='Package constant id'>Package</span><span class='dot token'>.</span><span class='new identifier id'>new</span> - <span class='p identifier id'>p</span><span class='dot token'>.</span><span class='workbook identifier id'>workbook</span><span class='dot token'>.</span><span class='add_worksheet identifier id'>add_worksheet</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='sheet identifier id'>sheet</span><span class='bitor op'>|</span> - <span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='add_row identifier id'>add_row</span> <span class='lbrack token'>[</span><span class='string val'>"First"</span><span class='comma token'>,</span> <span class='string val'>"Second"</span><span class='comma token'>,</span> <span class='string val'>"Third"</span><span class='rbrack token'>]</span> - <span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='add_row identifier id'>add_row</span> <span class='lbrack token'>[</span><span class='integer val'>1</span><span class='comma token'>,</span> <span class='integer val'>2</span><span class='comma token'>,</span> <span class='integer val'>3</span><span class='rbrack token'>]</span> - <span class='end end kw'>end</span> - <span class='p identifier id'>p</span><span class='dot token'>.</span><span class='serialize identifier id'>serialize</span><span class='lparen token'>(</span><span class='string val'>"example1.xlsx"</span><span class='rparen token'>)</span> +<pre class="code"> <span class='id p'>p</span> <span class='op'>=</span> <span class='const'>Axlsx</span><span class='op'>::</span><span class='const'>Package</span><span class='period'>.</span><span class='id new'>new</span> + <span class='id p'>p</span><span class='period'>.</span><span class='id workbook'>workbook</span><span class='period'>.</span><span class='id add_worksheet'>add_worksheet</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id sheet'>sheet</span><span class='op'>|</span> + <span class='id sheet'>sheet</span><span class='period'>.</span><span class='id add_row'>add_row</span> <span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>First</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Second</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Third</span><span class='tstring_end'>"</span></span><span class='rbracket'>]</span> + <span class='id sheet'>sheet</span><span class='period'>.</span><span class='id add_row'>add_row</span> <span class='lbracket'>[</span><span class='int'>1</span><span class='comma'>,</span> <span class='int'>2</span><span class='comma'>,</span> <span class='int'>3</span><span class='rbracket'>]</span> + <span class='kw'>end</span> + <span class='id p'>p</span><span class='period'>.</span><span class='id serialize'>serialize</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>example1.xlsx</span><span class='tstring_end'>"</span></span><span class='rparen'>)</span> </pre> <p>Generating A Bar Chart</p> -<pre class="code"> <span class='p identifier id'>p</span> <span class='assign token'>=</span> <span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='Package constant id'>Package</span><span class='dot token'>.</span><span class='new identifier id'>new</span> - <span class='p identifier id'>p</span><span class='dot token'>.</span><span class='workbook identifier id'>workbook</span><span class='dot token'>.</span><span class='add_worksheet identifier id'>add_worksheet</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='sheet identifier id'>sheet</span><span class='bitor op'>|</span> - <span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='add_row identifier id'>add_row</span> <span class='lbrack token'>[</span><span class='string val'>"First"</span><span class='comma token'>,</span> <span class='string val'>"Second"</span><span class='comma token'>,</span> <span class='string val'>"Third"</span><span class='rbrack token'>]</span> - <span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='add_row identifier id'>add_row</span> <span class='lbrack token'>[</span><span class='integer val'>1</span><span class='comma token'>,</span> <span class='integer val'>2</span><span class='comma token'>,</span> <span class='integer val'>3</span><span class='rbrack token'>]</span> - <span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='add_chart identifier id'>add_chart</span><span class='lparen token'>(</span><span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='Bar3DChart constant id'>Bar3DChart</span><span class='comma token'>,</span> <span class='symbol val'>:start_at</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='lbrack token'>[</span><span class='integer val'>0</span><span class='comma token'>,</span><span class='integer val'>2</span><span class='rbrack token'>]</span><span class='comma token'>,</span> <span class='symbol val'>:end_at</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='lbrack token'>[</span><span class='integer val'>5</span><span class='comma token'>,</span> <span class='integer val'>15</span><span class='rbrack token'>]</span><span class='comma token'>,</span> <span class='symbol val'>:title=</span><span class='gt op'>></span><span class='string val'>"example 2: Chart"</span><span class='rparen token'>)</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='chart identifier id'>chart</span><span class='bitor op'>|</span> - <span class='chart identifier id'>chart</span><span class='dot token'>.</span><span class='add_series identifier id'>add_series</span> <span class='symbol val'>:data=</span><span class='gt op'>></span><span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='rows identifier id'>rows</span><span class='dot token'>.</span><span class='last identifier id'>last</span><span class='dot token'>.</span><span class='cells identifier id'>cells</span><span class='comma token'>,</span> <span class='symbol val'>:labels=</span><span class='gt op'>></span> <span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='rows identifier id'>rows</span><span class='dot token'>.</span><span class='first identifier id'>first</span><span class='dot token'>.</span><span class='cells identifier id'>cells</span> - <span class='end end kw'>end</span> - <span class='end end kw'>end</span> - <span class='p identifier id'>p</span><span class='dot token'>.</span><span class='serialize identifier id'>serialize</span><span class='lparen token'>(</span><span class='string val'>"example2.xlsx"</span><span class='rparen token'>)</span> +<pre class="code"> <span class='id p'>p</span> <span class='op'>=</span> <span class='const'>Axlsx</span><span class='op'>::</span><span class='const'>Package</span><span class='period'>.</span><span class='id new'>new</span> + <span class='id p'>p</span><span class='period'>.</span><span class='id workbook'>workbook</span><span class='period'>.</span><span class='id add_worksheet'>add_worksheet</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id sheet'>sheet</span><span class='op'>|</span> + <span class='id sheet'>sheet</span><span class='period'>.</span><span class='id add_row'>add_row</span> <span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>First</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Second</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Third</span><span class='tstring_end'>"</span></span><span class='rbracket'>]</span> + <span class='id sheet'>sheet</span><span class='period'>.</span><span class='id add_row'>add_row</span> <span class='lbracket'>[</span><span class='int'>1</span><span class='comma'>,</span> <span class='int'>2</span><span class='comma'>,</span> <span class='int'>3</span><span class='rbracket'>]</span> + <span class='id sheet'>sheet</span><span class='period'>.</span><span class='id add_chart'>add_chart</span><span class='lparen'>(</span><span class='const'>Axlsx</span><span class='op'>::</span><span class='const'>Bar3DChart</span><span class='comma'>,</span> <span class='symbol'>:start_at</span> <span class='op'>=></span> <span class='lbracket'>[</span><span class='int'>0</span><span class='comma'>,</span><span class='int'>2</span><span class='rbracket'>]</span><span class='comma'>,</span> <span class='symbol'>:end_at</span> <span class='op'>=></span> <span class='lbracket'>[</span><span class='int'>5</span><span class='comma'>,</span> <span class='int'>15</span><span class='rbracket'>]</span><span class='comma'>,</span> <span class='symbol'>:title</span><span class='op'>=></span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>example 2: Chart</span><span class='tstring_end'>"</span></span><span class='rparen'>)</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id chart'>chart</span><span class='op'>|</span> + <span class='id chart'>chart</span><span class='period'>.</span><span class='id add_series'>add_series</span> <span class='symbol'>:data</span><span class='op'>=></span><span class='id sheet'>sheet</span><span class='period'>.</span><span class='id rows'>rows</span><span class='period'>.</span><span class='id last'>last</span><span class='period'>.</span><span class='id cells'>cells</span><span class='comma'>,</span> <span class='symbol'>:labels</span><span class='op'>=></span> <span class='id sheet'>sheet</span><span class='period'>.</span><span class='id rows'>rows</span><span class='period'>.</span><span class='id first'>first</span><span class='period'>.</span><span class='id cells'>cells</span> + <span class='kw'>end</span> + <span class='kw'>end</span> + <span class='id p'>p</span><span class='period'>.</span><span class='id serialize'>serialize</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>example2.xlsx</span><span class='tstring_end'>"</span></span><span class='rparen'>)</span> </pre> <p>Generating A Pie Chart</p> -<pre class="code"> <span class='p identifier id'>p</span> <span class='assign token'>=</span> <span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='Package constant id'>Package</span><span class='dot token'>.</span><span class='new identifier id'>new</span> - <span class='p identifier id'>p</span><span class='dot token'>.</span><span class='workbook identifier id'>workbook</span><span class='dot token'>.</span><span class='add_worksheet identifier id'>add_worksheet</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='sheet identifier id'>sheet</span><span class='bitor op'>|</span> - <span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='add_row identifier id'>add_row</span> <span class='lbrack token'>[</span><span class='string val'>"First"</span><span class='comma token'>,</span> <span class='string val'>"Second"</span><span class='comma token'>,</span> <span class='string val'>"Third"</span><span class='rbrack token'>]</span> - <span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='add_row identifier id'>add_row</span> <span class='lbrack token'>[</span><span class='integer val'>1</span><span class='comma token'>,</span> <span class='integer val'>2</span><span class='comma token'>,</span> <span class='integer val'>3</span><span class='rbrack token'>]</span> - <span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='add_chart identifier id'>add_chart</span><span class='lparen token'>(</span><span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='Pie3DChart constant id'>Pie3DChart</span><span class='comma token'>,</span> <span class='symbol val'>:start_at</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='lbrack token'>[</span><span class='integer val'>0</span><span class='comma token'>,</span><span class='integer val'>2</span><span class='rbrack token'>]</span><span class='comma token'>,</span> <span class='symbol val'>:end_at</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='lbrack token'>[</span><span class='integer val'>5</span><span class='comma token'>,</span> <span class='integer val'>15</span><span class='rbrack token'>]</span><span class='comma token'>,</span> <span class='symbol val'>:title=</span><span class='gt op'>></span><span class='string val'>"example 3: Pie Chart"</span><span class='rparen token'>)</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='chart identifier id'>chart</span><span class='bitor op'>|</span> - <span class='chart identifier id'>chart</span><span class='dot token'>.</span><span class='add_series identifier id'>add_series</span> <span class='symbol val'>:data=</span><span class='gt op'>></span><span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='rows identifier id'>rows</span><span class='dot token'>.</span><span class='last identifier id'>last</span><span class='dot token'>.</span><span class='cells identifier id'>cells</span><span class='comma token'>,</span> <span class='symbol val'>:labels=</span><span class='gt op'>></span> <span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='rows identifier id'>rows</span><span class='dot token'>.</span><span class='first identifier id'>first</span><span class='dot token'>.</span><span class='cells identifier id'>cells</span> - <span class='end end kw'>end</span> - <span class='end end kw'>end</span> - <span class='p identifier id'>p</span><span class='dot token'>.</span><span class='serialize identifier id'>serialize</span><span class='lparen token'>(</span><span class='string val'>"example3.xlsx"</span><span class='rparen token'>)</span> +<pre class="code"> <span class='id p'>p</span> <span class='op'>=</span> <span class='const'>Axlsx</span><span class='op'>::</span><span class='const'>Package</span><span class='period'>.</span><span class='id new'>new</span> + <span class='id p'>p</span><span class='period'>.</span><span class='id workbook'>workbook</span><span class='period'>.</span><span class='id add_worksheet'>add_worksheet</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id sheet'>sheet</span><span class='op'>|</span> + <span class='id sheet'>sheet</span><span class='period'>.</span><span class='id add_row'>add_row</span> <span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>First</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Second</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Third</span><span class='tstring_end'>"</span></span><span class='rbracket'>]</span> + <span class='id sheet'>sheet</span><span class='period'>.</span><span class='id add_row'>add_row</span> <span class='lbracket'>[</span><span class='int'>1</span><span class='comma'>,</span> <span class='int'>2</span><span class='comma'>,</span> <span class='int'>3</span><span class='rbracket'>]</span> + <span class='id sheet'>sheet</span><span class='period'>.</span><span class='id add_chart'>add_chart</span><span class='lparen'>(</span><span class='const'>Axlsx</span><span class='op'>::</span><span class='const'>Pie3DChart</span><span class='comma'>,</span> <span class='symbol'>:start_at</span> <span class='op'>=></span> <span class='lbracket'>[</span><span class='int'>0</span><span class='comma'>,</span><span class='int'>2</span><span class='rbracket'>]</span><span class='comma'>,</span> <span class='symbol'>:end_at</span> <span class='op'>=></span> <span class='lbracket'>[</span><span class='int'>5</span><span class='comma'>,</span> <span class='int'>15</span><span class='rbracket'>]</span><span class='comma'>,</span> <span class='symbol'>:title</span><span class='op'>=></span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>example 3: Pie Chart</span><span class='tstring_end'>"</span></span><span class='rparen'>)</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id chart'>chart</span><span class='op'>|</span> + <span class='id chart'>chart</span><span class='period'>.</span><span class='id add_series'>add_series</span> <span class='symbol'>:data</span><span class='op'>=></span><span class='id sheet'>sheet</span><span class='period'>.</span><span class='id rows'>rows</span><span class='period'>.</span><span class='id last'>last</span><span class='period'>.</span><span class='id cells'>cells</span><span class='comma'>,</span> <span class='symbol'>:labels</span><span class='op'>=></span> <span class='id sheet'>sheet</span><span class='period'>.</span><span class='id rows'>rows</span><span class='period'>.</span><span class='id first'>first</span><span class='period'>.</span><span class='id cells'>cells</span> + <span class='kw'>end</span> + <span class='kw'>end</span> + <span class='id p'>p</span><span class='period'>.</span><span class='id serialize'>serialize</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>example3.xlsx</span><span class='tstring_end'>"</span></span><span class='rparen'>)</span> </pre> <p>Using Custom Styles</p> -<pre class="code"> <span class='p identifier id'>p</span> <span class='assign token'>=</span> <span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='Package constant id'>Package</span><span class='dot token'>.</span><span class='new identifier id'>new</span> - <span class='wb identifier id'>wb</span> <span class='assign token'>=</span> <span class='p identifier id'>p</span><span class='dot token'>.</span><span class='workbook identifier id'>workbook</span> - <span class='black_cell identifier id'>black_cell</span> <span class='assign token'>=</span> <span class='wb identifier id'>wb</span><span class='dot token'>.</span><span class='styles identifier id'>styles</span><span class='dot token'>.</span><span class='add_style identifier id'>add_style</span> <span class='symbol val'>:bg_color</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='string val'>"FF000000"</span><span class='comma token'>,</span> <span class='symbol val'>:fg_color</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='string val'>"FFFFFFFF"</span><span class='comma token'>,</span> <span class='symbol val'>:sz=</span><span class='gt op'>></span><span class='integer val'>14</span><span class='comma token'>,</span> <span class='symbol val'>:alignment</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='lbrace token'>{</span> <span class='symbol val'>:horizontal=</span><span class='gt op'>></span> <span class='symbol val'>:center</span> <span class='rbrace token'>}</span> - <span class='blue_cell identifier id'>blue_cell</span> <span class='assign token'>=</span> <span class='wb identifier id'>wb</span><span class='dot token'>.</span><span class='styles identifier id'>styles</span><span class='dot token'>.</span><span class='add_style identifier id'>add_style</span> <span class='symbol val'>:bg_color</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='string val'>"FF0000FF"</span><span class='comma token'>,</span> <span class='symbol val'>:fg_color</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='string val'>"FFFFFFFF"</span><span class='comma token'>,</span> <span class='symbol val'>:sz=</span><span class='gt op'>></span><span class='integer val'>14</span><span class='comma token'>,</span> <span class='symbol val'>:alignment</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='lbrace token'>{</span> <span class='symbol val'>:horizontal=</span><span class='gt op'>></span> <span class='symbol val'>:center</span> <span class='rbrace token'>}</span> - <span class='wb identifier id'>wb</span><span class='dot token'>.</span><span class='add_worksheet identifier id'>add_worksheet</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='sheet identifier id'>sheet</span><span class='bitor op'>|</span> - <span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='add_row identifier id'>add_row</span> <span class='lbrack token'>[</span><span class='string val'>"Text Autowidth"</span><span class='comma token'>,</span> <span class='string val'>"Second"</span><span class='comma token'>,</span> <span class='string val'>"Third"</span><span class='rbrack token'>]</span><span class='comma token'>,</span> <span class='symbol val'>:style</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='lbrack token'>[</span><span class='black_cell identifier id'>black_cell</span><span class='comma token'>,</span> <span class='blue_cell identifier id'>blue_cell</span><span class='comma token'>,</span> <span class='black_cell identifier id'>black_cell</span><span class='rbrack token'>]</span> - <span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='add_row identifier id'>add_row</span> <span class='lbrack token'>[</span><span class='integer val'>1</span><span class='comma token'>,</span> <span class='integer val'>2</span><span class='comma token'>,</span> <span class='integer val'>3</span><span class='rbrack token'>]</span><span class='comma token'>,</span> <span class='symbol val'>:style</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='STYLE_THIN_BORDER constant id'>STYLE_THIN_BORDER</span> - <span class='end end kw'>end</span> - <span class='p identifier id'>p</span><span class='dot token'>.</span><span class='serialize identifier id'>serialize</span><span class='lparen token'>(</span><span class='string val'>"example4.xlsx"</span><span class='rparen token'>)</span> +<pre class="code"> <span class='id p'>p</span> <span class='op'>=</span> <span class='const'>Axlsx</span><span class='op'>::</span><span class='const'>Package</span><span class='period'>.</span><span class='id new'>new</span> + <span class='id wb'>wb</span> <span class='op'>=</span> <span class='id p'>p</span><span class='period'>.</span><span class='id workbook'>workbook</span> + <span class='id black_cell'>black_cell</span> <span class='op'>=</span> <span class='id wb'>wb</span><span class='period'>.</span><span class='id styles'>styles</span><span class='period'>.</span><span class='id add_style'>add_style</span> <span class='symbol'>:bg_color</span> <span class='op'>=></span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>FF000000</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='symbol'>:fg_color</span> <span class='op'>=></span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>FFFFFFFF</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='symbol'>:sz</span><span class='op'>=></span><span class='int'>14</span><span class='comma'>,</span> <span class='symbol'>:alignment</span> <span class='op'>=></span> <span class='lbrace'>{</span> <span class='symbol'>:horizontal</span><span class='op'>=></span> <span class='symbol'>:center</span> <span class='rbrace'>}</span> + <span class='id blue_cell'>blue_cell</span> <span class='op'>=</span> <span class='id wb'>wb</span><span class='period'>.</span><span class='id styles'>styles</span><span class='period'>.</span><span class='id add_style'>add_style</span> <span class='symbol'>:bg_color</span> <span class='op'>=></span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>FF0000FF</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='symbol'>:fg_color</span> <span class='op'>=></span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>FFFFFFFF</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='symbol'>:sz</span><span class='op'>=></span><span class='int'>14</span><span class='comma'>,</span> <span class='symbol'>:alignment</span> <span class='op'>=></span> <span class='lbrace'>{</span> <span class='symbol'>:horizontal</span><span class='op'>=></span> <span class='symbol'>:center</span> <span class='rbrace'>}</span> + <span class='id wb'>wb</span><span class='period'>.</span><span class='id add_worksheet'>add_worksheet</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id sheet'>sheet</span><span class='op'>|</span> + <span class='id sheet'>sheet</span><span class='period'>.</span><span class='id add_row'>add_row</span> <span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Text Autowidth</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Second</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Third</span><span class='tstring_end'>"</span></span><span class='rbracket'>]</span><span class='comma'>,</span> <span class='symbol'>:style</span> <span class='op'>=></span> <span class='lbracket'>[</span><span class='id black_cell'>black_cell</span><span class='comma'>,</span> <span class='id blue_cell'>blue_cell</span><span class='comma'>,</span> <span class='id black_cell'>black_cell</span><span class='rbracket'>]</span> + <span class='id sheet'>sheet</span><span class='period'>.</span><span class='id add_row'>add_row</span> <span class='lbracket'>[</span><span class='int'>1</span><span class='comma'>,</span> <span class='int'>2</span><span class='comma'>,</span> <span class='int'>3</span><span class='rbracket'>]</span><span class='comma'>,</span> <span class='symbol'>:style</span> <span class='op'>=></span> <span class='const'>Axlsx</span><span class='op'>::</span><span class='const'>STYLE_THIN_BORDER</span> + <span class='kw'>end</span> + <span class='id p'>p</span><span class='period'>.</span><span class='id serialize'>serialize</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>example4.xlsx</span><span class='tstring_end'>"</span></span><span class='rparen'>)</span> </pre> <p>Using Custom Formatting and date1904</p> -<pre class="code"> <span class='p identifier id'>p</span> <span class='assign token'>=</span> <span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='Package constant id'>Package</span><span class='dot token'>.</span><span class='new identifier id'>new</span> - <span class='wb identifier id'>wb</span> <span class='assign token'>=</span> <span class='p identifier id'>p</span><span class='dot token'>.</span><span class='workbook identifier id'>workbook</span> - <span class='date identifier id'>date</span> <span class='assign token'>=</span> <span class='wb identifier id'>wb</span><span class='dot token'>.</span><span class='styles identifier id'>styles</span><span class='dot token'>.</span><span class='add_style identifier id'>add_style</span> <span class='symbol val'>:format_code=</span><span class='gt op'>></span><span class='string val'>"yyyy-mm-dd"</span><span class='comma token'>,</span> <span class='symbol val'>:border</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='STYLE_THIN_BORDER constant id'>STYLE_THIN_BORDER</span> - <span class='padded identifier id'>padded</span> <span class='assign token'>=</span> <span class='wb identifier id'>wb</span><span class='dot token'>.</span><span class='styles identifier id'>styles</span><span class='dot token'>.</span><span class='add_style identifier id'>add_style</span> <span class='symbol val'>:format_code=</span><span class='gt op'>></span><span class='string val'>"00#"</span><span class='comma token'>,</span> <span class='symbol val'>:border</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='STYLE_THIN_BORDER constant id'>STYLE_THIN_BORDER</span> - <span class='percent identifier id'>percent</span> <span class='assign token'>=</span> <span class='wb identifier id'>wb</span><span class='dot token'>.</span><span class='styles identifier id'>styles</span><span class='dot token'>.</span><span class='add_style identifier id'>add_style</span> <span class='symbol val'>:format_code=</span><span class='gt op'>></span><span class='string val'>"0%"</span><span class='comma token'>,</span> <span class='symbol val'>:border</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='STYLE_THIN_BORDER constant id'>STYLE_THIN_BORDER</span> - <span class='wb identifier id'>wb</span><span class='dot token'>.</span><span class='date1904 identifier id'>date1904</span> <span class='assign token'>=</span> <span class='true true kw'>true</span> <span class='comment val'># required for generation on mac</span> - <span class='wb identifier id'>wb</span><span class='dot token'>.</span><span class='add_worksheet identifier id'>add_worksheet</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='sheet identifier id'>sheet</span><span class='bitor op'>|</span> - <span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='add_row identifier id'>add_row</span> <span class='lbrack token'>[</span><span class='string val'>"Custom Formatted Date"</span><span class='comma token'>,</span> <span class='string val'>"Percent Formatted Float"</span><span class='comma token'>,</span> <span class='string val'>"Padded Numbers"</span><span class='rbrack token'>]</span><span class='comma token'>,</span> <span class='symbol val'>:style</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='STYLE_THIN_BORDER constant id'>STYLE_THIN_BORDER</span> - <span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='add_row identifier id'>add_row</span> <span class='lbrack token'>[</span><span class='Time constant id'>Time</span><span class='dot token'>.</span><span class='now identifier id'>now</span><span class='comma token'>,</span> <span class='integer val'>0</span><span class='integer val'>.2</span><span class='comma token'>,</span> <span class='integer val'>32</span><span class='rbrack token'>]</span><span class='comma token'>,</span> <span class='symbol val'>:style</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='lbrack token'>[</span><span class='date identifier id'>date</span><span class='comma token'>,</span> <span class='percent identifier id'>percent</span><span class='comma token'>,</span> <span class='padded identifier id'>padded</span><span class='rbrack token'>]</span> - <span class='end end kw'>end</span> - <span class='p identifier id'>p</span><span class='dot token'>.</span><span class='serialize identifier id'>serialize</span><span class='lparen token'>(</span><span class='string val'>"example5.xlsx"</span><span class='rparen token'>)</span> +<pre class="code"> <span class='id p'>p</span> <span class='op'>=</span> <span class='const'>Axlsx</span><span class='op'>::</span><span class='const'>Package</span><span class='period'>.</span><span class='id new'>new</span> + <span class='id wb'>wb</span> <span class='op'>=</span> <span class='id p'>p</span><span class='period'>.</span><span class='id workbook'>workbook</span> + <span class='id date'>date</span> <span class='op'>=</span> <span class='id wb'>wb</span><span class='period'>.</span><span class='id styles'>styles</span><span class='period'>.</span><span class='id add_style'>add_style</span> <span class='symbol'>:format_code</span><span class='op'>=></span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>yyyy-mm-dd</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='symbol'>:border</span> <span class='op'>=></span> <span class='const'>Axlsx</span><span class='op'>::</span><span class='const'>STYLE_THIN_BORDER</span> + <span class='id padded'>padded</span> <span class='op'>=</span> <span class='id wb'>wb</span><span class='period'>.</span><span class='id styles'>styles</span><span class='period'>.</span><span class='id add_style'>add_style</span> <span class='symbol'>:format_code</span><span class='op'>=></span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>00#</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='symbol'>:border</span> <span class='op'>=></span> <span class='const'>Axlsx</span><span class='op'>::</span><span class='const'>STYLE_THIN_BORDER</span> + <span class='id percent'>percent</span> <span class='op'>=</span> <span class='id wb'>wb</span><span class='period'>.</span><span class='id styles'>styles</span><span class='period'>.</span><span class='id add_style'>add_style</span> <span class='symbol'>:format_code</span><span class='op'>=></span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>0%</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='symbol'>:border</span> <span class='op'>=></span> <span class='const'>Axlsx</span><span class='op'>::</span><span class='const'>STYLE_THIN_BORDER</span> + <span class='id wb'>wb</span><span class='period'>.</span><span class='id date1904'>date1904</span> <span class='op'>=</span> <span class='kw'>true</span> <span class='comment'># required for generation on mac +</span> <span class='id wb'>wb</span><span class='period'>.</span><span class='id add_worksheet'>add_worksheet</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id sheet'>sheet</span><span class='op'>|</span> + <span class='id sheet'>sheet</span><span class='period'>.</span><span class='id add_row'>add_row</span> <span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Custom Formatted Date</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Percent Formatted Float</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Padded Numbers</span><span class='tstring_end'>"</span></span><span class='rbracket'>]</span><span class='comma'>,</span> <span class='symbol'>:style</span> <span class='op'>=></span> <span class='const'>Axlsx</span><span class='op'>::</span><span class='const'>STYLE_THIN_BORDER</span> + <span class='id sheet'>sheet</span><span class='period'>.</span><span class='id add_row'>add_row</span> <span class='lbracket'>[</span><span class='const'>Time</span><span class='period'>.</span><span class='id now'>now</span><span class='comma'>,</span> <span class='float'>0.2</span><span class='comma'>,</span> <span class='int'>32</span><span class='rbracket'>]</span><span class='comma'>,</span> <span class='symbol'>:style</span> <span class='op'>=></span> <span class='lbracket'>[</span><span class='id date'>date</span><span class='comma'>,</span> <span class='id percent'>percent</span><span class='comma'>,</span> <span class='id padded'>padded</span><span class='rbracket'>]</span> + <span class='kw'>end</span> + <span class='id p'>p</span><span class='period'>.</span><span class='id serialize'>serialize</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>example5.xlsx</span><span class='tstring_end'>"</span></span><span class='rparen'>)</span> </pre> <p>Validation</p> -<pre class="code"> <span class='p identifier id'>p</span> <span class='assign token'>=</span> <span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='Package constant id'>Package</span><span class='dot token'>.</span><span class='new identifier id'>new</span> - <span class='p identifier id'>p</span><span class='dot token'>.</span><span class='workbook identifier id'>workbook</span><span class='dot token'>.</span><span class='add_worksheet identifier id'>add_worksheet</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='sheet identifier id'>sheet</span><span class='bitor op'>|</span> - <span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='add_row identifier id'>add_row</span> <span class='lbrack token'>[</span><span class='string val'>"First"</span><span class='comma token'>,</span> <span class='string val'>"Second"</span><span class='comma token'>,</span> <span class='string val'>"Third"</span><span class='rbrack token'>]</span> - <span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='add_row identifier id'>add_row</span> <span class='lbrack token'>[</span><span class='integer val'>1</span><span class='comma token'>,</span> <span class='integer val'>2</span><span class='comma token'>,</span> <span class='integer val'>3</span><span class='rbrack token'>]</span> - <span class='end end kw'>end</span> +<pre class="code"> <span class='id p'>p</span> <span class='op'>=</span> <span class='const'>Axlsx</span><span class='op'>::</span><span class='const'>Package</span><span class='period'>.</span><span class='id new'>new</span> + <span class='id p'>p</span><span class='period'>.</span><span class='id workbook'>workbook</span><span class='period'>.</span><span class='id add_worksheet'>add_worksheet</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id sheet'>sheet</span><span class='op'>|</span> + <span class='id sheet'>sheet</span><span class='period'>.</span><span class='id add_row'>add_row</span> <span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>First</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Second</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Third</span><span class='tstring_end'>"</span></span><span class='rbracket'>]</span> + <span class='id sheet'>sheet</span><span class='period'>.</span><span class='id add_row'>add_row</span> <span class='lbracket'>[</span><span class='int'>1</span><span class='comma'>,</span> <span class='int'>2</span><span class='comma'>,</span> <span class='int'>3</span><span class='rbracket'>]</span> + <span class='kw'>end</span> - <span class='p identifier id'>p</span><span class='dot token'>.</span><span class='validate identifier id'>validate</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='error identifier id'>error</span><span class='bitor op'>|</span> - <span class='puts identifier id'>puts</span> <span class='error identifier id'>error</span><span class='dot token'>.</span><span class='inspect identifier id'>inspect</span> - <span class='end end kw'>end</span> + <span class='id p'>p</span><span class='period'>.</span><span class='id validate'>validate</span><span class='period'>.</span><span class='id each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id error'>error</span><span class='op'>|</span> + <span class='id puts'>puts</span> <span class='id error'>error</span><span class='period'>.</span><span class='id inspect'>inspect</span> + <span class='kw'>end</span> </pre> <p>Generating A Line Chart</p> -<pre class="code"> <span class='p identifier id'>p</span> <span class='assign token'>=</span> <span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='Package constant id'>Package</span><span class='dot token'>.</span><span class='new identifier id'>new</span> - <span class='p identifier id'>p</span><span class='dot token'>.</span><span class='workbook identifier id'>workbook</span><span class='dot token'>.</span><span class='add_worksheet identifier id'>add_worksheet</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='sheet identifier id'>sheet</span><span class='bitor op'>|</span> - <span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='add_row identifier id'>add_row</span> <span class='lbrack token'>[</span><span class='string val'>"First"</span><span class='comma token'>,</span> <span class='integer val'>1</span><span class='comma token'>,</span> <span class='integer val'>5</span><span class='comma token'>,</span> <span class='integer val'>7</span><span class='comma token'>,</span> <span class='integer val'>9</span><span class='rbrack token'>]</span> - <span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='add_row identifier id'>add_row</span> <span class='lbrack token'>[</span><span class='string val'>"Second"</span><span class='comma token'>,</span> <span class='integer val'>5</span><span class='comma token'>,</span> <span class='integer val'>2</span><span class='comma token'>,</span> <span class='integer val'>14</span><span class='comma token'>,</span> <span class='integer val'>9</span><span class='rbrack token'>]</span> - <span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='add_chart identifier id'>add_chart</span><span class='lparen token'>(</span><span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='Line3DChart constant id'>Line3DChart</span><span class='comma token'>,</span> <span class='symbol val'>:title=</span><span class='gt op'>></span><span class='string val'>"example 6: Line Chart"</span><span class='rparen token'>)</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='chart identifier id'>chart</span><span class='bitor op'>|</span> - <span class='chart identifier id'>chart</span><span class='dot token'>.</span><span class='start_at identifier id'>start_at</span> <span class='integer val'>0</span><span class='comma token'>,</span> <span class='integer val'>2</span> - <span class='chart identifier id'>chart</span><span class='dot token'>.</span><span class='end_at identifier id'>end_at</span> <span class='integer val'>10</span><span class='comma token'>,</span> <span class='integer val'>15</span> - <span class='chart identifier id'>chart</span><span class='dot token'>.</span><span class='add_series identifier id'>add_series</span> <span class='symbol val'>:data=</span><span class='gt op'>></span><span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='rows identifier id'>rows</span><span class='dot token'>.</span><span class='first identifier id'>first</span><span class='dot token'>.</span><span class='cells identifier id'>cells</span><span class='lbrack token'>[</span><span class='lparen token'>(</span><span class='float val'>1</span><span class='dot2 op'>..</span><span class='integer val'>-1</span><span class='rparen token'>)</span><span class='rbrack token'>]</span><span class='comma token'>,</span> <span class='symbol val'>:title=</span><span class='gt op'>></span> <span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='rows identifier id'>rows</span><span class='dot token'>.</span><span class='first identifier id'>first</span><span class='dot token'>.</span><span class='cells identifier id'>cells</span><span class='dot token'>.</span><span class='first identifier id'>first</span> - <span class='chart identifier id'>chart</span><span class='dot token'>.</span><span class='add_series identifier id'>add_series</span> <span class='symbol val'>:data=</span><span class='gt op'>></span><span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='rows identifier id'>rows</span><span class='dot token'>.</span><span class='last identifier id'>last</span><span class='dot token'>.</span><span class='cells identifier id'>cells</span><span class='lbrack token'>[</span><span class='lparen token'>(</span><span class='float val'>1</span><span class='dot2 op'>..</span><span class='integer val'>-1</span><span class='rparen token'>)</span><span class='rbrack token'>]</span><span class='comma token'>,</span> <span class='symbol val'>:title=</span><span class='gt op'>></span> <span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='rows identifier id'>rows</span><span class='dot token'>.</span><span class='last identifier id'>last</span><span class='dot token'>.</span><span class='cells identifier id'>cells</span><span class='dot token'>.</span><span class='first identifier id'>first</span> - <span class='end end kw'>end</span> - - <span class='end end kw'>end</span> - <span class='p identifier id'>p</span><span class='dot token'>.</span><span class='serialize identifier id'>serialize</span><span class='lparen token'>(</span><span class='string val'>"example6.xlsx"</span><span class='rparen token'>)</span> +<pre class="code"> <span class='id p'>p</span> <span class='op'>=</span> <span class='const'>Axlsx</span><span class='op'>::</span><span class='const'>Package</span><span class='period'>.</span><span class='id new'>new</span> + <span class='id p'>p</span><span class='period'>.</span><span class='id workbook'>workbook</span><span class='period'>.</span><span class='id add_worksheet'>add_worksheet</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id sheet'>sheet</span><span class='op'>|</span> + <span class='id sheet'>sheet</span><span class='period'>.</span><span class='id add_row'>add_row</span> <span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>First</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='int'>1</span><span class='comma'>,</span> <span class='int'>5</span><span class='comma'>,</span> <span class='int'>7</span><span class='comma'>,</span> <span class='int'>9</span><span class='rbracket'>]</span> + <span class='id sheet'>sheet</span><span class='period'>.</span><span class='id add_row'>add_row</span> <span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Second</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='int'>5</span><span class='comma'>,</span> <span class='int'>2</span><span class='comma'>,</span> <span class='int'>14</span><span class='comma'>,</span> <span class='int'>9</span><span class='rbracket'>]</span> + <span class='id sheet'>sheet</span><span class='period'>.</span><span class='id add_chart'>add_chart</span><span class='lparen'>(</span><span class='const'>Axlsx</span><span class='op'>::</span><span class='const'>Line3DChart</span><span class='comma'>,</span> <span class='symbol'>:title</span><span class='op'>=></span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>example 6: Line Chart</span><span class='tstring_end'>"</span></span><span class='rparen'>)</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id chart'>chart</span><span class='op'>|</span> + <span class='id chart'>chart</span><span class='period'>.</span><span class='id start_at'>start_at</span> <span class='int'>0</span><span class='comma'>,</span> <span class='int'>2</span> + <span class='id chart'>chart</span><span class='period'>.</span><span class='id end_at'>end_at</span> <span class='int'>10</span><span class='comma'>,</span> <span class='int'>15</span> + <span class='id chart'>chart</span><span class='period'>.</span><span class='id add_series'>add_series</span> <span class='symbol'>:data</span><span class='op'>=></span><span class='id sheet'>sheet</span><span class='period'>.</span><span class='id rows'>rows</span><span class='period'>.</span><span class='id first'>first</span><span class='period'>.</span><span class='id cells'>cells</span><span class='lbracket'>[</span><span class='lparen'>(</span><span class='int'>1</span><span class='op'>..</span><span class='op'>-</span><span class='int'>1</span><span class='rparen'>)</span><span class='rbracket'>]</span><span class='comma'>,</span> <span class='symbol'>:title</span><span class='op'>=></span> <span class='id sheet'>sheet</span><span class='period'>.</span><span class='id rows'>rows</span><span class='period'>.</span><span class='id first'>first</span><span class='period'>.</span><span class='id cells'>cells</span><span class='period'>.</span><span class='id first'>first</span> + <span class='id chart'>chart</span><span class='period'>.</span><span class='id add_series'>add_series</span> <span class='symbol'>:data</span><span class='op'>=></span><span class='id sheet'>sheet</span><span class='period'>.</span><span class='id rows'>rows</span><span class='period'>.</span><span class='id last'>last</span><span class='period'>.</span><span class='id cells'>cells</span><span class='lbracket'>[</span><span class='lparen'>(</span><span class='int'>1</span><span class='op'>..</span><span class='op'>-</span><span class='int'>1</span><span class='rparen'>)</span><span class='rbracket'>]</span><span class='comma'>,</span> <span class='symbol'>:title</span><span class='op'>=></span> <span class='id sheet'>sheet</span><span class='period'>.</span><span class='id rows'>rows</span><span class='period'>.</span><span class='id last'>last</span><span class='period'>.</span><span class='id cells'>cells</span><span class='period'>.</span><span class='id first'>first</span> + <span class='kw'>end</span> + + <span class='kw'>end</span> + <span class='id p'>p</span><span class='period'>.</span><span class='id serialize'>serialize</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>example6.xlsx</span><span class='tstring_end'>"</span></span><span class='rparen'>)</span> </pre> <p>Adding an Image</p> -<pre class="code"> <span class='p identifier id'>p</span> <span class='assign token'>=</span> <span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='Package constant id'>Package</span><span class='dot token'>.</span><span class='new identifier id'>new</span> - <span class='p identifier id'>p</span><span class='dot token'>.</span><span class='workbook identifier id'>workbook</span><span class='dot token'>.</span><span class='add_worksheet identifier id'>add_worksheet</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='sheet identifier id'>sheet</span><span class='bitor op'>|</span> - <span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='add_image identifier id'>add_image</span><span class='lparen token'>(</span><span class='symbol val'>:image_src</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='lparen token'>(</span><span class='File constant id'>File</span><span class='dot token'>.</span><span class='dirname identifier id'>dirname</span><span class='lparen token'>(</span><span class='__FILE__ __file__ kw'>__FILE__</span><span class='rparen token'>)</span> <span class='plus op'>+</span> <span class='string val'>"/image1.png"</span><span class='rparen token'>)</span><span class='rparen token'>)</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='image identifier id'>image</span><span class='bitor op'>|</span> - <span class='image identifier id'>image</span><span class='dot token'>.</span><span class='width identifier id'>width</span><span class='assign token'>=</span><span class='integer val'>720</span> - <span class='image identifier id'>image</span><span class='dot token'>.</span><span class='height identifier id'>height</span><span class='assign token'>=</span><span class='integer val'>666</span> - <span class='image identifier id'>image</span><span class='dot token'>.</span><span class='start_at identifier id'>start_at</span> <span class='integer val'>2</span><span class='comma token'>,</span> <span class='integer val'>2</span> - <span class='end end kw'>end</span> - <span class='end end kw'>end</span> - <span class='p identifier id'>p</span><span class='dot token'>.</span><span class='serialize identifier id'>serialize</span><span class='lparen token'>(</span><span class='string val'>"example7.xlsx"</span><span class='rparen token'>)</span> +<pre class="code"> <span class='id p'>p</span> <span class='op'>=</span> <span class='const'>Axlsx</span><span class='op'>::</span><span class='const'>Package</span><span class='period'>.</span><span class='id new'>new</span> + <span class='id p'>p</span><span class='period'>.</span><span class='id workbook'>workbook</span><span class='period'>.</span><span class='id add_worksheet'>add_worksheet</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id sheet'>sheet</span><span class='op'>|</span> + <span class='id sheet'>sheet</span><span class='period'>.</span><span class='id add_image'>add_image</span><span class='lparen'>(</span><span class='symbol'>:image_src</span> <span class='op'>=></span> <span class='lparen'>(</span><span class='const'>File</span><span class='period'>.</span><span class='id dirname'>dirname</span><span class='lparen'>(</span><span class='kw'>__FILE__</span><span class='rparen'>)</span> <span class='op'>+</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>/image1.png</span><span class='tstring_end'>"</span></span><span class='rparen'>)</span><span class='rparen'>)</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id image'>image</span><span class='op'>|</span> + <span class='id image'>image</span><span class='period'>.</span><span class='id width'>width</span><span class='op'>=</span><span class='int'>720</span> + <span class='id image'>image</span><span class='period'>.</span><span class='id height'>height</span><span class='op'>=</span><span class='int'>666</span> + <span class='id image'>image</span><span class='period'>.</span><span class='id start_at'>start_at</span> <span class='int'>2</span><span class='comma'>,</span> <span class='int'>2</span> + <span class='kw'>end</span> + <span class='kw'>end</span> + <span class='id p'>p</span><span class='period'>.</span><span class='id serialize'>serialize</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>example7.xlsx</span><span class='tstring_end'>"</span></span><span class='rparen'>)</span> +</pre> + +<p>Asian Language Support</p> + +<pre class="code"> <span class='id p'>p</span> <span class='op'>=</span> <span class='const'>Axlsx</span><span class='op'>::</span><span class='const'>Package</span><span class='period'>.</span><span class='id new'>new</span> + <span class='id p'>p</span><span class='period'>.</span><span class='id workbook'>workbook</span><span class='period'>.</span><span class='id add_worksheet'>add_worksheet</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id sheet'>sheet</span><span class='op'>|</span> + <span class='id sheet'>sheet</span><span class='period'>.</span><span class='id add_row'>add_row</span> <span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>日本語</span><span class='tstring_end'>"</span></span><span class='rbracket'>]</span> + <span class='id sheet'>sheet</span><span class='period'>.</span><span class='id add_row'>add_row</span> <span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>华语/華語</span><span class='tstring_end'>"</span></span><span class='rbracket'>]</span> + <span class='id sheet'>sheet</span><span class='period'>.</span><span class='id add_row'>add_row</span> <span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>한국어/조선말</span><span class='tstring_end'>"</span></span><span class='rbracket'>]</span> + <span class='kw'>end</span> + <span class='id p'>p</span><span class='period'>.</span><span class='id serialize'>serialize</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>example8.xlsx</span><span class='tstring_end'>"</span></span><span class='rparen'>)</span> </pre> <h3>Documentation</h3> <p>This gem is 100% documented with YARD, an exceptional documentation library. To see documentation for this, and all the gems installed on your system use:</p> -<pre class="code"> <span class='gem identifier id'>gem</span> <span class='install identifier id'>install</span> <span class='yard identifier id'>yard</span> - <span class='yard identifier id'>yard</span> <span class='server identifier id'>server</span> <span class='minus op'>-</span><span class='g identifier id'>g</span> +<pre class="code"> <span class='id gem'>gem</span> <span class='id install'>install</span> <span class='id yard'>yard</span> + <span class='id yard'>yard</span> <span class='id server'>server</span> <span class='op'>-</span><span class='id g'>g</span> </pre> <h3>Specs</h3> @@ -223,24 +238,11 @@ It enables the you to generate 100% valid xlsx files that include customised sty <h2>Changelog</h2> <ul> -<li><p><strong>October.23.11</strong>: 1.0.8 release</p> +<li><strong>October.26.11</strong>: 1.0.9 release <ul> -<li>Added support for images (jpg, gif, png) in worksheets.</li> -</ul> -</li> -<li><p><strong>October.23.11</strong>: 1.0.7 released</p> - -<ul> -<li>Added support for 3D options when creating a new chart. This lets you set the persective, rotation and other 3D attributes when using worksheet.add_chart</li> -<li>Updated serialization write test to verify write permissions and warn if it cannot run the test due to permission restrcitions.</li> -<li>updated rake to include build, genoc and deploy tasks.</li> -<li>rebuilt documentation.</li> -<li>moved version constant to its own file</li> -<li>fixed bug in SerAxis that was requiring tickLblSkip and tickMarkSkip to be boolean. Should be unsigned int.</li> -<li>Review and improve docs</li> -<li>rebuild of anchor positioning to remove some spagetti code. Chart now supports a start_at and end_at method that accept an arrar for col/row positioning. See example6 for an example. You can still pass :start_at and :end_at options to worksheet.add_chart.</li> -<li>Refactored cat and val axis data to keep series serialization a bit more DRY</li> +<li>Updated to support ruby 1.9.3</li> +<li>Updated to eliminate all warnings originating in this gem</li> </ul> </li> </ul> @@ -248,10 +250,6 @@ It enables the you to generate 100% valid xlsx files that include customised sty <p>Please see the <a href="file.CHANGELOG.html" title="CHANGELOG">CHANGELOG</a> document for past release information.</p> -<h2>Help Wanted</h2> - -<p>I'd really like to get rid of the depenency on RMagick in this gem. RMagic is being used to calculate the column widths in a worksheet based on the content the user specified. If there happens to be anyone out there with the background and skill set to write an extenstion that can determine the width of a single character rendered with a specific font at a specific size please give me a shout.</p> - <h2>Copyright</h2> <p>Axlsx © 2011 by <a href="mailto:[email protected]">Randy Morgan</a>. Axlsx is @@ -259,9 +257,9 @@ licensed under the MIT license. Please see the <a href="file.LICENSE.html" title </div></div> <div id="footer"> - Generated on Wed Nov 23 22:20:44 2011 by + Generated on Sat Nov 26 13:16:35 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/file_list.html b/doc/file_list.html index 2ea5474e..b552e568 100644 --- a/doc/file_list.html +++ b/doc/file_list.html @@ -43,6 +43,9 @@ <li class="r1"><a href="index.html" title="README">README</a></li> + <li class="r2"><a href="file.LICENSE.html" title="LICENSE">LICENSE</a></li> + + </ul> </div> </body> diff --git a/doc/frames.html b/doc/frames.html index 4cc52cb7..ac451281 100644 --- a/doc/frames.html +++ b/doc/frames.html @@ -4,7 +4,7 @@ <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/> - <title>Documentation by YARD 0.7.3</title> + <title>AXLSX</title> </head> <frameset cols="20%,*"> <frame name="list" src="class_list.html" /> diff --git a/doc/index.html b/doc/index.html index 18af1cab..f76e610f 100644 --- a/doc/index.html +++ b/doc/index.html @@ -2,11 +2,11 @@ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <head> - <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> + <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> <title> File: README - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -61,14 +61,18 @@ <strong>Author</strong>: Randy Morgan <br/> <strong>Copyright</strong>: 2011 <br/> <strong>License</strong>: MIT License <br/> -<strong>Latest Version</strong>: 1.0.8 <br/> -<strong>Ruby Version</strong>: 1.8.7 <br/> -<strong>Release Date</strong>: November 23nd 2011</p> +<strong>Latest Version</strong>: 1.0.9 <br/> +<strong>Ruby Version</strong>: 1.8.7 - 1.9.3 <br/> +<strong>Release Date</strong>: November 26th 2011</p> <h2>Synopsis</h2> <p>Axlsx is an Office Open XML Spreadsheet generator for the Ruby programming language. -It enables the you to generate 100% valid xlsx files that include customised styling, images, 3D pie, bar and line charts and auto-width columns. Below is a summary of salient features.</p> +With Axlsx you can create worksheets with charts, images, automated column width, customizable styles and full schema validation. Axlsx excels at helping you generate beautiful Office Open XML Spreadsheet documents without having to understand the entire ECMA specification. Check out the README for some examples of how easy it is. Best of all, you can validate your xlsx file before serialization so you know for sure that anything generated is going to load on your client's machine.</p> + +<h2>Help Wanted</h2> + +<p>I'd really like to get rid of the depenency on RMagick in this gem. RMagic is being used to calculate the column widths in a worksheet based on the content the user specified. If there happens to be anyone out there with the background and c skills to write an extenstion that can determine the width of a single character rendered with a specific font at a specific font size please give me a shout.</p> <h2>Feature List</h2> @@ -90,130 +94,141 @@ It enables the you to generate 100% valid xlsx files that include customised sty <p>To install Axlsx, use the following command:</p> -<pre class="code">$ <span class='gem identifier id'>gem</span> <span class='install identifier id'>install</span> <span class='axlsx identifier id'>axlsx</span> +<pre class="code">$ gem install axlsx </pre> <h2>Usage</h2> <h3>Examples</h3> -<pre class="code"> <span class='require identifier id'>require</span> <span class='string val'>'rubygems'</span> - <span class='require identifier id'>require</span> <span class='string val'>'axlsx'</span> +<pre class="code"> <span class='id require'>require</span> <span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>rubygems</span><span class='tstring_end'>'</span></span> + <span class='id require'>require</span> <span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>axlsx</span><span class='tstring_end'>'</span></span> </pre> <p>A Simple Workbook</p> -<pre class="code"> <span class='p identifier id'>p</span> <span class='assign token'>=</span> <span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='Package constant id'>Package</span><span class='dot token'>.</span><span class='new identifier id'>new</span> - <span class='p identifier id'>p</span><span class='dot token'>.</span><span class='workbook identifier id'>workbook</span><span class='dot token'>.</span><span class='add_worksheet identifier id'>add_worksheet</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='sheet identifier id'>sheet</span><span class='bitor op'>|</span> - <span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='add_row identifier id'>add_row</span> <span class='lbrack token'>[</span><span class='string val'>"First"</span><span class='comma token'>,</span> <span class='string val'>"Second"</span><span class='comma token'>,</span> <span class='string val'>"Third"</span><span class='rbrack token'>]</span> - <span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='add_row identifier id'>add_row</span> <span class='lbrack token'>[</span><span class='integer val'>1</span><span class='comma token'>,</span> <span class='integer val'>2</span><span class='comma token'>,</span> <span class='integer val'>3</span><span class='rbrack token'>]</span> - <span class='end end kw'>end</span> - <span class='p identifier id'>p</span><span class='dot token'>.</span><span class='serialize identifier id'>serialize</span><span class='lparen token'>(</span><span class='string val'>"example1.xlsx"</span><span class='rparen token'>)</span> +<pre class="code"> <span class='id p'>p</span> <span class='op'>=</span> <span class='const'>Axlsx</span><span class='op'>::</span><span class='const'>Package</span><span class='period'>.</span><span class='id new'>new</span> + <span class='id p'>p</span><span class='period'>.</span><span class='id workbook'>workbook</span><span class='period'>.</span><span class='id add_worksheet'>add_worksheet</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id sheet'>sheet</span><span class='op'>|</span> + <span class='id sheet'>sheet</span><span class='period'>.</span><span class='id add_row'>add_row</span> <span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>First</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Second</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Third</span><span class='tstring_end'>"</span></span><span class='rbracket'>]</span> + <span class='id sheet'>sheet</span><span class='period'>.</span><span class='id add_row'>add_row</span> <span class='lbracket'>[</span><span class='int'>1</span><span class='comma'>,</span> <span class='int'>2</span><span class='comma'>,</span> <span class='int'>3</span><span class='rbracket'>]</span> + <span class='kw'>end</span> + <span class='id p'>p</span><span class='period'>.</span><span class='id serialize'>serialize</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>example1.xlsx</span><span class='tstring_end'>"</span></span><span class='rparen'>)</span> </pre> <p>Generating A Bar Chart</p> -<pre class="code"> <span class='p identifier id'>p</span> <span class='assign token'>=</span> <span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='Package constant id'>Package</span><span class='dot token'>.</span><span class='new identifier id'>new</span> - <span class='p identifier id'>p</span><span class='dot token'>.</span><span class='workbook identifier id'>workbook</span><span class='dot token'>.</span><span class='add_worksheet identifier id'>add_worksheet</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='sheet identifier id'>sheet</span><span class='bitor op'>|</span> - <span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='add_row identifier id'>add_row</span> <span class='lbrack token'>[</span><span class='string val'>"First"</span><span class='comma token'>,</span> <span class='string val'>"Second"</span><span class='comma token'>,</span> <span class='string val'>"Third"</span><span class='rbrack token'>]</span> - <span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='add_row identifier id'>add_row</span> <span class='lbrack token'>[</span><span class='integer val'>1</span><span class='comma token'>,</span> <span class='integer val'>2</span><span class='comma token'>,</span> <span class='integer val'>3</span><span class='rbrack token'>]</span> - <span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='add_chart identifier id'>add_chart</span><span class='lparen token'>(</span><span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='Bar3DChart constant id'>Bar3DChart</span><span class='comma token'>,</span> <span class='symbol val'>:start_at</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='lbrack token'>[</span><span class='integer val'>0</span><span class='comma token'>,</span><span class='integer val'>2</span><span class='rbrack token'>]</span><span class='comma token'>,</span> <span class='symbol val'>:end_at</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='lbrack token'>[</span><span class='integer val'>5</span><span class='comma token'>,</span> <span class='integer val'>15</span><span class='rbrack token'>]</span><span class='comma token'>,</span> <span class='symbol val'>:title=</span><span class='gt op'>></span><span class='string val'>"example 2: Chart"</span><span class='rparen token'>)</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='chart identifier id'>chart</span><span class='bitor op'>|</span> - <span class='chart identifier id'>chart</span><span class='dot token'>.</span><span class='add_series identifier id'>add_series</span> <span class='symbol val'>:data=</span><span class='gt op'>></span><span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='rows identifier id'>rows</span><span class='dot token'>.</span><span class='last identifier id'>last</span><span class='dot token'>.</span><span class='cells identifier id'>cells</span><span class='comma token'>,</span> <span class='symbol val'>:labels=</span><span class='gt op'>></span> <span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='rows identifier id'>rows</span><span class='dot token'>.</span><span class='first identifier id'>first</span><span class='dot token'>.</span><span class='cells identifier id'>cells</span> - <span class='end end kw'>end</span> - <span class='end end kw'>end</span> - <span class='p identifier id'>p</span><span class='dot token'>.</span><span class='serialize identifier id'>serialize</span><span class='lparen token'>(</span><span class='string val'>"example2.xlsx"</span><span class='rparen token'>)</span> +<pre class="code"> <span class='id p'>p</span> <span class='op'>=</span> <span class='const'>Axlsx</span><span class='op'>::</span><span class='const'>Package</span><span class='period'>.</span><span class='id new'>new</span> + <span class='id p'>p</span><span class='period'>.</span><span class='id workbook'>workbook</span><span class='period'>.</span><span class='id add_worksheet'>add_worksheet</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id sheet'>sheet</span><span class='op'>|</span> + <span class='id sheet'>sheet</span><span class='period'>.</span><span class='id add_row'>add_row</span> <span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>First</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Second</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Third</span><span class='tstring_end'>"</span></span><span class='rbracket'>]</span> + <span class='id sheet'>sheet</span><span class='period'>.</span><span class='id add_row'>add_row</span> <span class='lbracket'>[</span><span class='int'>1</span><span class='comma'>,</span> <span class='int'>2</span><span class='comma'>,</span> <span class='int'>3</span><span class='rbracket'>]</span> + <span class='id sheet'>sheet</span><span class='period'>.</span><span class='id add_chart'>add_chart</span><span class='lparen'>(</span><span class='const'>Axlsx</span><span class='op'>::</span><span class='const'>Bar3DChart</span><span class='comma'>,</span> <span class='symbol'>:start_at</span> <span class='op'>=></span> <span class='lbracket'>[</span><span class='int'>0</span><span class='comma'>,</span><span class='int'>2</span><span class='rbracket'>]</span><span class='comma'>,</span> <span class='symbol'>:end_at</span> <span class='op'>=></span> <span class='lbracket'>[</span><span class='int'>5</span><span class='comma'>,</span> <span class='int'>15</span><span class='rbracket'>]</span><span class='comma'>,</span> <span class='symbol'>:title</span><span class='op'>=></span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>example 2: Chart</span><span class='tstring_end'>"</span></span><span class='rparen'>)</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id chart'>chart</span><span class='op'>|</span> + <span class='id chart'>chart</span><span class='period'>.</span><span class='id add_series'>add_series</span> <span class='symbol'>:data</span><span class='op'>=></span><span class='id sheet'>sheet</span><span class='period'>.</span><span class='id rows'>rows</span><span class='period'>.</span><span class='id last'>last</span><span class='period'>.</span><span class='id cells'>cells</span><span class='comma'>,</span> <span class='symbol'>:labels</span><span class='op'>=></span> <span class='id sheet'>sheet</span><span class='period'>.</span><span class='id rows'>rows</span><span class='period'>.</span><span class='id first'>first</span><span class='period'>.</span><span class='id cells'>cells</span> + <span class='kw'>end</span> + <span class='kw'>end</span> + <span class='id p'>p</span><span class='period'>.</span><span class='id serialize'>serialize</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>example2.xlsx</span><span class='tstring_end'>"</span></span><span class='rparen'>)</span> </pre> <p>Generating A Pie Chart</p> -<pre class="code"> <span class='p identifier id'>p</span> <span class='assign token'>=</span> <span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='Package constant id'>Package</span><span class='dot token'>.</span><span class='new identifier id'>new</span> - <span class='p identifier id'>p</span><span class='dot token'>.</span><span class='workbook identifier id'>workbook</span><span class='dot token'>.</span><span class='add_worksheet identifier id'>add_worksheet</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='sheet identifier id'>sheet</span><span class='bitor op'>|</span> - <span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='add_row identifier id'>add_row</span> <span class='lbrack token'>[</span><span class='string val'>"First"</span><span class='comma token'>,</span> <span class='string val'>"Second"</span><span class='comma token'>,</span> <span class='string val'>"Third"</span><span class='rbrack token'>]</span> - <span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='add_row identifier id'>add_row</span> <span class='lbrack token'>[</span><span class='integer val'>1</span><span class='comma token'>,</span> <span class='integer val'>2</span><span class='comma token'>,</span> <span class='integer val'>3</span><span class='rbrack token'>]</span> - <span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='add_chart identifier id'>add_chart</span><span class='lparen token'>(</span><span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='Pie3DChart constant id'>Pie3DChart</span><span class='comma token'>,</span> <span class='symbol val'>:start_at</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='lbrack token'>[</span><span class='integer val'>0</span><span class='comma token'>,</span><span class='integer val'>2</span><span class='rbrack token'>]</span><span class='comma token'>,</span> <span class='symbol val'>:end_at</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='lbrack token'>[</span><span class='integer val'>5</span><span class='comma token'>,</span> <span class='integer val'>15</span><span class='rbrack token'>]</span><span class='comma token'>,</span> <span class='symbol val'>:title=</span><span class='gt op'>></span><span class='string val'>"example 3: Pie Chart"</span><span class='rparen token'>)</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='chart identifier id'>chart</span><span class='bitor op'>|</span> - <span class='chart identifier id'>chart</span><span class='dot token'>.</span><span class='add_series identifier id'>add_series</span> <span class='symbol val'>:data=</span><span class='gt op'>></span><span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='rows identifier id'>rows</span><span class='dot token'>.</span><span class='last identifier id'>last</span><span class='dot token'>.</span><span class='cells identifier id'>cells</span><span class='comma token'>,</span> <span class='symbol val'>:labels=</span><span class='gt op'>></span> <span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='rows identifier id'>rows</span><span class='dot token'>.</span><span class='first identifier id'>first</span><span class='dot token'>.</span><span class='cells identifier id'>cells</span> - <span class='end end kw'>end</span> - <span class='end end kw'>end</span> - <span class='p identifier id'>p</span><span class='dot token'>.</span><span class='serialize identifier id'>serialize</span><span class='lparen token'>(</span><span class='string val'>"example3.xlsx"</span><span class='rparen token'>)</span> +<pre class="code"> <span class='id p'>p</span> <span class='op'>=</span> <span class='const'>Axlsx</span><span class='op'>::</span><span class='const'>Package</span><span class='period'>.</span><span class='id new'>new</span> + <span class='id p'>p</span><span class='period'>.</span><span class='id workbook'>workbook</span><span class='period'>.</span><span class='id add_worksheet'>add_worksheet</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id sheet'>sheet</span><span class='op'>|</span> + <span class='id sheet'>sheet</span><span class='period'>.</span><span class='id add_row'>add_row</span> <span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>First</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Second</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Third</span><span class='tstring_end'>"</span></span><span class='rbracket'>]</span> + <span class='id sheet'>sheet</span><span class='period'>.</span><span class='id add_row'>add_row</span> <span class='lbracket'>[</span><span class='int'>1</span><span class='comma'>,</span> <span class='int'>2</span><span class='comma'>,</span> <span class='int'>3</span><span class='rbracket'>]</span> + <span class='id sheet'>sheet</span><span class='period'>.</span><span class='id add_chart'>add_chart</span><span class='lparen'>(</span><span class='const'>Axlsx</span><span class='op'>::</span><span class='const'>Pie3DChart</span><span class='comma'>,</span> <span class='symbol'>:start_at</span> <span class='op'>=></span> <span class='lbracket'>[</span><span class='int'>0</span><span class='comma'>,</span><span class='int'>2</span><span class='rbracket'>]</span><span class='comma'>,</span> <span class='symbol'>:end_at</span> <span class='op'>=></span> <span class='lbracket'>[</span><span class='int'>5</span><span class='comma'>,</span> <span class='int'>15</span><span class='rbracket'>]</span><span class='comma'>,</span> <span class='symbol'>:title</span><span class='op'>=></span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>example 3: Pie Chart</span><span class='tstring_end'>"</span></span><span class='rparen'>)</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id chart'>chart</span><span class='op'>|</span> + <span class='id chart'>chart</span><span class='period'>.</span><span class='id add_series'>add_series</span> <span class='symbol'>:data</span><span class='op'>=></span><span class='id sheet'>sheet</span><span class='period'>.</span><span class='id rows'>rows</span><span class='period'>.</span><span class='id last'>last</span><span class='period'>.</span><span class='id cells'>cells</span><span class='comma'>,</span> <span class='symbol'>:labels</span><span class='op'>=></span> <span class='id sheet'>sheet</span><span class='period'>.</span><span class='id rows'>rows</span><span class='period'>.</span><span class='id first'>first</span><span class='period'>.</span><span class='id cells'>cells</span> + <span class='kw'>end</span> + <span class='kw'>end</span> + <span class='id p'>p</span><span class='period'>.</span><span class='id serialize'>serialize</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>example3.xlsx</span><span class='tstring_end'>"</span></span><span class='rparen'>)</span> </pre> <p>Using Custom Styles</p> -<pre class="code"> <span class='p identifier id'>p</span> <span class='assign token'>=</span> <span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='Package constant id'>Package</span><span class='dot token'>.</span><span class='new identifier id'>new</span> - <span class='wb identifier id'>wb</span> <span class='assign token'>=</span> <span class='p identifier id'>p</span><span class='dot token'>.</span><span class='workbook identifier id'>workbook</span> - <span class='black_cell identifier id'>black_cell</span> <span class='assign token'>=</span> <span class='wb identifier id'>wb</span><span class='dot token'>.</span><span class='styles identifier id'>styles</span><span class='dot token'>.</span><span class='add_style identifier id'>add_style</span> <span class='symbol val'>:bg_color</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='string val'>"FF000000"</span><span class='comma token'>,</span> <span class='symbol val'>:fg_color</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='string val'>"FFFFFFFF"</span><span class='comma token'>,</span> <span class='symbol val'>:sz=</span><span class='gt op'>></span><span class='integer val'>14</span><span class='comma token'>,</span> <span class='symbol val'>:alignment</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='lbrace token'>{</span> <span class='symbol val'>:horizontal=</span><span class='gt op'>></span> <span class='symbol val'>:center</span> <span class='rbrace token'>}</span> - <span class='blue_cell identifier id'>blue_cell</span> <span class='assign token'>=</span> <span class='wb identifier id'>wb</span><span class='dot token'>.</span><span class='styles identifier id'>styles</span><span class='dot token'>.</span><span class='add_style identifier id'>add_style</span> <span class='symbol val'>:bg_color</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='string val'>"FF0000FF"</span><span class='comma token'>,</span> <span class='symbol val'>:fg_color</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='string val'>"FFFFFFFF"</span><span class='comma token'>,</span> <span class='symbol val'>:sz=</span><span class='gt op'>></span><span class='integer val'>14</span><span class='comma token'>,</span> <span class='symbol val'>:alignment</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='lbrace token'>{</span> <span class='symbol val'>:horizontal=</span><span class='gt op'>></span> <span class='symbol val'>:center</span> <span class='rbrace token'>}</span> - <span class='wb identifier id'>wb</span><span class='dot token'>.</span><span class='add_worksheet identifier id'>add_worksheet</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='sheet identifier id'>sheet</span><span class='bitor op'>|</span> - <span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='add_row identifier id'>add_row</span> <span class='lbrack token'>[</span><span class='string val'>"Text Autowidth"</span><span class='comma token'>,</span> <span class='string val'>"Second"</span><span class='comma token'>,</span> <span class='string val'>"Third"</span><span class='rbrack token'>]</span><span class='comma token'>,</span> <span class='symbol val'>:style</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='lbrack token'>[</span><span class='black_cell identifier id'>black_cell</span><span class='comma token'>,</span> <span class='blue_cell identifier id'>blue_cell</span><span class='comma token'>,</span> <span class='black_cell identifier id'>black_cell</span><span class='rbrack token'>]</span> - <span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='add_row identifier id'>add_row</span> <span class='lbrack token'>[</span><span class='integer val'>1</span><span class='comma token'>,</span> <span class='integer val'>2</span><span class='comma token'>,</span> <span class='integer val'>3</span><span class='rbrack token'>]</span><span class='comma token'>,</span> <span class='symbol val'>:style</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='STYLE_THIN_BORDER constant id'>STYLE_THIN_BORDER</span> - <span class='end end kw'>end</span> - <span class='p identifier id'>p</span><span class='dot token'>.</span><span class='serialize identifier id'>serialize</span><span class='lparen token'>(</span><span class='string val'>"example4.xlsx"</span><span class='rparen token'>)</span> +<pre class="code"> <span class='id p'>p</span> <span class='op'>=</span> <span class='const'>Axlsx</span><span class='op'>::</span><span class='const'>Package</span><span class='period'>.</span><span class='id new'>new</span> + <span class='id wb'>wb</span> <span class='op'>=</span> <span class='id p'>p</span><span class='period'>.</span><span class='id workbook'>workbook</span> + <span class='id black_cell'>black_cell</span> <span class='op'>=</span> <span class='id wb'>wb</span><span class='period'>.</span><span class='id styles'>styles</span><span class='period'>.</span><span class='id add_style'>add_style</span> <span class='symbol'>:bg_color</span> <span class='op'>=></span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>FF000000</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='symbol'>:fg_color</span> <span class='op'>=></span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>FFFFFFFF</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='symbol'>:sz</span><span class='op'>=></span><span class='int'>14</span><span class='comma'>,</span> <span class='symbol'>:alignment</span> <span class='op'>=></span> <span class='lbrace'>{</span> <span class='symbol'>:horizontal</span><span class='op'>=></span> <span class='symbol'>:center</span> <span class='rbrace'>}</span> + <span class='id blue_cell'>blue_cell</span> <span class='op'>=</span> <span class='id wb'>wb</span><span class='period'>.</span><span class='id styles'>styles</span><span class='period'>.</span><span class='id add_style'>add_style</span> <span class='symbol'>:bg_color</span> <span class='op'>=></span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>FF0000FF</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='symbol'>:fg_color</span> <span class='op'>=></span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>FFFFFFFF</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='symbol'>:sz</span><span class='op'>=></span><span class='int'>14</span><span class='comma'>,</span> <span class='symbol'>:alignment</span> <span class='op'>=></span> <span class='lbrace'>{</span> <span class='symbol'>:horizontal</span><span class='op'>=></span> <span class='symbol'>:center</span> <span class='rbrace'>}</span> + <span class='id wb'>wb</span><span class='period'>.</span><span class='id add_worksheet'>add_worksheet</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id sheet'>sheet</span><span class='op'>|</span> + <span class='id sheet'>sheet</span><span class='period'>.</span><span class='id add_row'>add_row</span> <span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Text Autowidth</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Second</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Third</span><span class='tstring_end'>"</span></span><span class='rbracket'>]</span><span class='comma'>,</span> <span class='symbol'>:style</span> <span class='op'>=></span> <span class='lbracket'>[</span><span class='id black_cell'>black_cell</span><span class='comma'>,</span> <span class='id blue_cell'>blue_cell</span><span class='comma'>,</span> <span class='id black_cell'>black_cell</span><span class='rbracket'>]</span> + <span class='id sheet'>sheet</span><span class='period'>.</span><span class='id add_row'>add_row</span> <span class='lbracket'>[</span><span class='int'>1</span><span class='comma'>,</span> <span class='int'>2</span><span class='comma'>,</span> <span class='int'>3</span><span class='rbracket'>]</span><span class='comma'>,</span> <span class='symbol'>:style</span> <span class='op'>=></span> <span class='const'>Axlsx</span><span class='op'>::</span><span class='const'>STYLE_THIN_BORDER</span> + <span class='kw'>end</span> + <span class='id p'>p</span><span class='period'>.</span><span class='id serialize'>serialize</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>example4.xlsx</span><span class='tstring_end'>"</span></span><span class='rparen'>)</span> </pre> <p>Using Custom Formatting and date1904</p> -<pre class="code"> <span class='p identifier id'>p</span> <span class='assign token'>=</span> <span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='Package constant id'>Package</span><span class='dot token'>.</span><span class='new identifier id'>new</span> - <span class='wb identifier id'>wb</span> <span class='assign token'>=</span> <span class='p identifier id'>p</span><span class='dot token'>.</span><span class='workbook identifier id'>workbook</span> - <span class='date identifier id'>date</span> <span class='assign token'>=</span> <span class='wb identifier id'>wb</span><span class='dot token'>.</span><span class='styles identifier id'>styles</span><span class='dot token'>.</span><span class='add_style identifier id'>add_style</span> <span class='symbol val'>:format_code=</span><span class='gt op'>></span><span class='string val'>"yyyy-mm-dd"</span><span class='comma token'>,</span> <span class='symbol val'>:border</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='STYLE_THIN_BORDER constant id'>STYLE_THIN_BORDER</span> - <span class='padded identifier id'>padded</span> <span class='assign token'>=</span> <span class='wb identifier id'>wb</span><span class='dot token'>.</span><span class='styles identifier id'>styles</span><span class='dot token'>.</span><span class='add_style identifier id'>add_style</span> <span class='symbol val'>:format_code=</span><span class='gt op'>></span><span class='string val'>"00#"</span><span class='comma token'>,</span> <span class='symbol val'>:border</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='STYLE_THIN_BORDER constant id'>STYLE_THIN_BORDER</span> - <span class='percent identifier id'>percent</span> <span class='assign token'>=</span> <span class='wb identifier id'>wb</span><span class='dot token'>.</span><span class='styles identifier id'>styles</span><span class='dot token'>.</span><span class='add_style identifier id'>add_style</span> <span class='symbol val'>:format_code=</span><span class='gt op'>></span><span class='string val'>"0%"</span><span class='comma token'>,</span> <span class='symbol val'>:border</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='STYLE_THIN_BORDER constant id'>STYLE_THIN_BORDER</span> - <span class='wb identifier id'>wb</span><span class='dot token'>.</span><span class='date1904 identifier id'>date1904</span> <span class='assign token'>=</span> <span class='true true kw'>true</span> <span class='comment val'># required for generation on mac</span> - <span class='wb identifier id'>wb</span><span class='dot token'>.</span><span class='add_worksheet identifier id'>add_worksheet</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='sheet identifier id'>sheet</span><span class='bitor op'>|</span> - <span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='add_row identifier id'>add_row</span> <span class='lbrack token'>[</span><span class='string val'>"Custom Formatted Date"</span><span class='comma token'>,</span> <span class='string val'>"Percent Formatted Float"</span><span class='comma token'>,</span> <span class='string val'>"Padded Numbers"</span><span class='rbrack token'>]</span><span class='comma token'>,</span> <span class='symbol val'>:style</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='STYLE_THIN_BORDER constant id'>STYLE_THIN_BORDER</span> - <span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='add_row identifier id'>add_row</span> <span class='lbrack token'>[</span><span class='Time constant id'>Time</span><span class='dot token'>.</span><span class='now identifier id'>now</span><span class='comma token'>,</span> <span class='integer val'>0</span><span class='integer val'>.2</span><span class='comma token'>,</span> <span class='integer val'>32</span><span class='rbrack token'>]</span><span class='comma token'>,</span> <span class='symbol val'>:style</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='lbrack token'>[</span><span class='date identifier id'>date</span><span class='comma token'>,</span> <span class='percent identifier id'>percent</span><span class='comma token'>,</span> <span class='padded identifier id'>padded</span><span class='rbrack token'>]</span> - <span class='end end kw'>end</span> - <span class='p identifier id'>p</span><span class='dot token'>.</span><span class='serialize identifier id'>serialize</span><span class='lparen token'>(</span><span class='string val'>"example5.xlsx"</span><span class='rparen token'>)</span> +<pre class="code"> <span class='id p'>p</span> <span class='op'>=</span> <span class='const'>Axlsx</span><span class='op'>::</span><span class='const'>Package</span><span class='period'>.</span><span class='id new'>new</span> + <span class='id wb'>wb</span> <span class='op'>=</span> <span class='id p'>p</span><span class='period'>.</span><span class='id workbook'>workbook</span> + <span class='id date'>date</span> <span class='op'>=</span> <span class='id wb'>wb</span><span class='period'>.</span><span class='id styles'>styles</span><span class='period'>.</span><span class='id add_style'>add_style</span> <span class='symbol'>:format_code</span><span class='op'>=></span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>yyyy-mm-dd</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='symbol'>:border</span> <span class='op'>=></span> <span class='const'>Axlsx</span><span class='op'>::</span><span class='const'>STYLE_THIN_BORDER</span> + <span class='id padded'>padded</span> <span class='op'>=</span> <span class='id wb'>wb</span><span class='period'>.</span><span class='id styles'>styles</span><span class='period'>.</span><span class='id add_style'>add_style</span> <span class='symbol'>:format_code</span><span class='op'>=></span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>00#</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='symbol'>:border</span> <span class='op'>=></span> <span class='const'>Axlsx</span><span class='op'>::</span><span class='const'>STYLE_THIN_BORDER</span> + <span class='id percent'>percent</span> <span class='op'>=</span> <span class='id wb'>wb</span><span class='period'>.</span><span class='id styles'>styles</span><span class='period'>.</span><span class='id add_style'>add_style</span> <span class='symbol'>:format_code</span><span class='op'>=></span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>0%</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='symbol'>:border</span> <span class='op'>=></span> <span class='const'>Axlsx</span><span class='op'>::</span><span class='const'>STYLE_THIN_BORDER</span> + <span class='id wb'>wb</span><span class='period'>.</span><span class='id date1904'>date1904</span> <span class='op'>=</span> <span class='kw'>true</span> <span class='comment'># required for generation on mac +</span> <span class='id wb'>wb</span><span class='period'>.</span><span class='id add_worksheet'>add_worksheet</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id sheet'>sheet</span><span class='op'>|</span> + <span class='id sheet'>sheet</span><span class='period'>.</span><span class='id add_row'>add_row</span> <span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Custom Formatted Date</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Percent Formatted Float</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Padded Numbers</span><span class='tstring_end'>"</span></span><span class='rbracket'>]</span><span class='comma'>,</span> <span class='symbol'>:style</span> <span class='op'>=></span> <span class='const'>Axlsx</span><span class='op'>::</span><span class='const'>STYLE_THIN_BORDER</span> + <span class='id sheet'>sheet</span><span class='period'>.</span><span class='id add_row'>add_row</span> <span class='lbracket'>[</span><span class='const'>Time</span><span class='period'>.</span><span class='id now'>now</span><span class='comma'>,</span> <span class='float'>0.2</span><span class='comma'>,</span> <span class='int'>32</span><span class='rbracket'>]</span><span class='comma'>,</span> <span class='symbol'>:style</span> <span class='op'>=></span> <span class='lbracket'>[</span><span class='id date'>date</span><span class='comma'>,</span> <span class='id percent'>percent</span><span class='comma'>,</span> <span class='id padded'>padded</span><span class='rbracket'>]</span> + <span class='kw'>end</span> + <span class='id p'>p</span><span class='period'>.</span><span class='id serialize'>serialize</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>example5.xlsx</span><span class='tstring_end'>"</span></span><span class='rparen'>)</span> </pre> <p>Validation</p> -<pre class="code"> <span class='p identifier id'>p</span> <span class='assign token'>=</span> <span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='Package constant id'>Package</span><span class='dot token'>.</span><span class='new identifier id'>new</span> - <span class='p identifier id'>p</span><span class='dot token'>.</span><span class='workbook identifier id'>workbook</span><span class='dot token'>.</span><span class='add_worksheet identifier id'>add_worksheet</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='sheet identifier id'>sheet</span><span class='bitor op'>|</span> - <span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='add_row identifier id'>add_row</span> <span class='lbrack token'>[</span><span class='string val'>"First"</span><span class='comma token'>,</span> <span class='string val'>"Second"</span><span class='comma token'>,</span> <span class='string val'>"Third"</span><span class='rbrack token'>]</span> - <span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='add_row identifier id'>add_row</span> <span class='lbrack token'>[</span><span class='integer val'>1</span><span class='comma token'>,</span> <span class='integer val'>2</span><span class='comma token'>,</span> <span class='integer val'>3</span><span class='rbrack token'>]</span> - <span class='end end kw'>end</span> +<pre class="code"> <span class='id p'>p</span> <span class='op'>=</span> <span class='const'>Axlsx</span><span class='op'>::</span><span class='const'>Package</span><span class='period'>.</span><span class='id new'>new</span> + <span class='id p'>p</span><span class='period'>.</span><span class='id workbook'>workbook</span><span class='period'>.</span><span class='id add_worksheet'>add_worksheet</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id sheet'>sheet</span><span class='op'>|</span> + <span class='id sheet'>sheet</span><span class='period'>.</span><span class='id add_row'>add_row</span> <span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>First</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Second</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Third</span><span class='tstring_end'>"</span></span><span class='rbracket'>]</span> + <span class='id sheet'>sheet</span><span class='period'>.</span><span class='id add_row'>add_row</span> <span class='lbracket'>[</span><span class='int'>1</span><span class='comma'>,</span> <span class='int'>2</span><span class='comma'>,</span> <span class='int'>3</span><span class='rbracket'>]</span> + <span class='kw'>end</span> - <span class='p identifier id'>p</span><span class='dot token'>.</span><span class='validate identifier id'>validate</span><span class='dot token'>.</span><span class='each identifier id'>each</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='error identifier id'>error</span><span class='bitor op'>|</span> - <span class='puts identifier id'>puts</span> <span class='error identifier id'>error</span><span class='dot token'>.</span><span class='inspect identifier id'>inspect</span> - <span class='end end kw'>end</span> + <span class='id p'>p</span><span class='period'>.</span><span class='id validate'>validate</span><span class='period'>.</span><span class='id each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id error'>error</span><span class='op'>|</span> + <span class='id puts'>puts</span> <span class='id error'>error</span><span class='period'>.</span><span class='id inspect'>inspect</span> + <span class='kw'>end</span> </pre> <p>Generating A Line Chart</p> -<pre class="code"> <span class='p identifier id'>p</span> <span class='assign token'>=</span> <span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='Package constant id'>Package</span><span class='dot token'>.</span><span class='new identifier id'>new</span> - <span class='p identifier id'>p</span><span class='dot token'>.</span><span class='workbook identifier id'>workbook</span><span class='dot token'>.</span><span class='add_worksheet identifier id'>add_worksheet</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='sheet identifier id'>sheet</span><span class='bitor op'>|</span> - <span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='add_row identifier id'>add_row</span> <span class='lbrack token'>[</span><span class='string val'>"First"</span><span class='comma token'>,</span> <span class='integer val'>1</span><span class='comma token'>,</span> <span class='integer val'>5</span><span class='comma token'>,</span> <span class='integer val'>7</span><span class='comma token'>,</span> <span class='integer val'>9</span><span class='rbrack token'>]</span> - <span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='add_row identifier id'>add_row</span> <span class='lbrack token'>[</span><span class='string val'>"Second"</span><span class='comma token'>,</span> <span class='integer val'>5</span><span class='comma token'>,</span> <span class='integer val'>2</span><span class='comma token'>,</span> <span class='integer val'>14</span><span class='comma token'>,</span> <span class='integer val'>9</span><span class='rbrack token'>]</span> - <span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='add_chart identifier id'>add_chart</span><span class='lparen token'>(</span><span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='Line3DChart constant id'>Line3DChart</span><span class='comma token'>,</span> <span class='symbol val'>:title=</span><span class='gt op'>></span><span class='string val'>"example 6: Line Chart"</span><span class='rparen token'>)</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='chart identifier id'>chart</span><span class='bitor op'>|</span> - <span class='chart identifier id'>chart</span><span class='dot token'>.</span><span class='start_at identifier id'>start_at</span> <span class='integer val'>0</span><span class='comma token'>,</span> <span class='integer val'>2</span> - <span class='chart identifier id'>chart</span><span class='dot token'>.</span><span class='end_at identifier id'>end_at</span> <span class='integer val'>10</span><span class='comma token'>,</span> <span class='integer val'>15</span> - <span class='chart identifier id'>chart</span><span class='dot token'>.</span><span class='add_series identifier id'>add_series</span> <span class='symbol val'>:data=</span><span class='gt op'>></span><span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='rows identifier id'>rows</span><span class='dot token'>.</span><span class='first identifier id'>first</span><span class='dot token'>.</span><span class='cells identifier id'>cells</span><span class='lbrack token'>[</span><span class='lparen token'>(</span><span class='float val'>1</span><span class='dot2 op'>..</span><span class='integer val'>-1</span><span class='rparen token'>)</span><span class='rbrack token'>]</span><span class='comma token'>,</span> <span class='symbol val'>:title=</span><span class='gt op'>></span> <span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='rows identifier id'>rows</span><span class='dot token'>.</span><span class='first identifier id'>first</span><span class='dot token'>.</span><span class='cells identifier id'>cells</span><span class='dot token'>.</span><span class='first identifier id'>first</span> - <span class='chart identifier id'>chart</span><span class='dot token'>.</span><span class='add_series identifier id'>add_series</span> <span class='symbol val'>:data=</span><span class='gt op'>></span><span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='rows identifier id'>rows</span><span class='dot token'>.</span><span class='last identifier id'>last</span><span class='dot token'>.</span><span class='cells identifier id'>cells</span><span class='lbrack token'>[</span><span class='lparen token'>(</span><span class='float val'>1</span><span class='dot2 op'>..</span><span class='integer val'>-1</span><span class='rparen token'>)</span><span class='rbrack token'>]</span><span class='comma token'>,</span> <span class='symbol val'>:title=</span><span class='gt op'>></span> <span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='rows identifier id'>rows</span><span class='dot token'>.</span><span class='last identifier id'>last</span><span class='dot token'>.</span><span class='cells identifier id'>cells</span><span class='dot token'>.</span><span class='first identifier id'>first</span> - <span class='end end kw'>end</span> - - <span class='end end kw'>end</span> - <span class='p identifier id'>p</span><span class='dot token'>.</span><span class='serialize identifier id'>serialize</span><span class='lparen token'>(</span><span class='string val'>"example6.xlsx"</span><span class='rparen token'>)</span> +<pre class="code"> <span class='id p'>p</span> <span class='op'>=</span> <span class='const'>Axlsx</span><span class='op'>::</span><span class='const'>Package</span><span class='period'>.</span><span class='id new'>new</span> + <span class='id p'>p</span><span class='period'>.</span><span class='id workbook'>workbook</span><span class='period'>.</span><span class='id add_worksheet'>add_worksheet</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id sheet'>sheet</span><span class='op'>|</span> + <span class='id sheet'>sheet</span><span class='period'>.</span><span class='id add_row'>add_row</span> <span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>First</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='int'>1</span><span class='comma'>,</span> <span class='int'>5</span><span class='comma'>,</span> <span class='int'>7</span><span class='comma'>,</span> <span class='int'>9</span><span class='rbracket'>]</span> + <span class='id sheet'>sheet</span><span class='period'>.</span><span class='id add_row'>add_row</span> <span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Second</span><span class='tstring_end'>"</span></span><span class='comma'>,</span> <span class='int'>5</span><span class='comma'>,</span> <span class='int'>2</span><span class='comma'>,</span> <span class='int'>14</span><span class='comma'>,</span> <span class='int'>9</span><span class='rbracket'>]</span> + <span class='id sheet'>sheet</span><span class='period'>.</span><span class='id add_chart'>add_chart</span><span class='lparen'>(</span><span class='const'>Axlsx</span><span class='op'>::</span><span class='const'>Line3DChart</span><span class='comma'>,</span> <span class='symbol'>:title</span><span class='op'>=></span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>example 6: Line Chart</span><span class='tstring_end'>"</span></span><span class='rparen'>)</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id chart'>chart</span><span class='op'>|</span> + <span class='id chart'>chart</span><span class='period'>.</span><span class='id start_at'>start_at</span> <span class='int'>0</span><span class='comma'>,</span> <span class='int'>2</span> + <span class='id chart'>chart</span><span class='period'>.</span><span class='id end_at'>end_at</span> <span class='int'>10</span><span class='comma'>,</span> <span class='int'>15</span> + <span class='id chart'>chart</span><span class='period'>.</span><span class='id add_series'>add_series</span> <span class='symbol'>:data</span><span class='op'>=></span><span class='id sheet'>sheet</span><span class='period'>.</span><span class='id rows'>rows</span><span class='period'>.</span><span class='id first'>first</span><span class='period'>.</span><span class='id cells'>cells</span><span class='lbracket'>[</span><span class='lparen'>(</span><span class='int'>1</span><span class='op'>..</span><span class='op'>-</span><span class='int'>1</span><span class='rparen'>)</span><span class='rbracket'>]</span><span class='comma'>,</span> <span class='symbol'>:title</span><span class='op'>=></span> <span class='id sheet'>sheet</span><span class='period'>.</span><span class='id rows'>rows</span><span class='period'>.</span><span class='id first'>first</span><span class='period'>.</span><span class='id cells'>cells</span><span class='period'>.</span><span class='id first'>first</span> + <span class='id chart'>chart</span><span class='period'>.</span><span class='id add_series'>add_series</span> <span class='symbol'>:data</span><span class='op'>=></span><span class='id sheet'>sheet</span><span class='period'>.</span><span class='id rows'>rows</span><span class='period'>.</span><span class='id last'>last</span><span class='period'>.</span><span class='id cells'>cells</span><span class='lbracket'>[</span><span class='lparen'>(</span><span class='int'>1</span><span class='op'>..</span><span class='op'>-</span><span class='int'>1</span><span class='rparen'>)</span><span class='rbracket'>]</span><span class='comma'>,</span> <span class='symbol'>:title</span><span class='op'>=></span> <span class='id sheet'>sheet</span><span class='period'>.</span><span class='id rows'>rows</span><span class='period'>.</span><span class='id last'>last</span><span class='period'>.</span><span class='id cells'>cells</span><span class='period'>.</span><span class='id first'>first</span> + <span class='kw'>end</span> + + <span class='kw'>end</span> + <span class='id p'>p</span><span class='period'>.</span><span class='id serialize'>serialize</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>example6.xlsx</span><span class='tstring_end'>"</span></span><span class='rparen'>)</span> </pre> <p>Adding an Image</p> -<pre class="code"> <span class='p identifier id'>p</span> <span class='assign token'>=</span> <span class='Axlsx constant id'>Axlsx</span><span class='colon2 op'>::</span><span class='Package constant id'>Package</span><span class='dot token'>.</span><span class='new identifier id'>new</span> - <span class='p identifier id'>p</span><span class='dot token'>.</span><span class='workbook identifier id'>workbook</span><span class='dot token'>.</span><span class='add_worksheet identifier id'>add_worksheet</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='sheet identifier id'>sheet</span><span class='bitor op'>|</span> - <span class='sheet identifier id'>sheet</span><span class='dot token'>.</span><span class='add_image identifier id'>add_image</span><span class='lparen token'>(</span><span class='symbol val'>:image_src</span> <span class='assign token'>=</span><span class='gt op'>></span> <span class='lparen token'>(</span><span class='File constant id'>File</span><span class='dot token'>.</span><span class='dirname identifier id'>dirname</span><span class='lparen token'>(</span><span class='__FILE__ __file__ kw'>__FILE__</span><span class='rparen token'>)</span> <span class='plus op'>+</span> <span class='string val'>"/image1.png"</span><span class='rparen token'>)</span><span class='rparen token'>)</span> <span class='do do kw'>do</span> <span class='bitor op'>|</span><span class='image identifier id'>image</span><span class='bitor op'>|</span> - <span class='image identifier id'>image</span><span class='dot token'>.</span><span class='width identifier id'>width</span><span class='assign token'>=</span><span class='integer val'>720</span> - <span class='image identifier id'>image</span><span class='dot token'>.</span><span class='height identifier id'>height</span><span class='assign token'>=</span><span class='integer val'>666</span> - <span class='image identifier id'>image</span><span class='dot token'>.</span><span class='start_at identifier id'>start_at</span> <span class='integer val'>2</span><span class='comma token'>,</span> <span class='integer val'>2</span> - <span class='end end kw'>end</span> - <span class='end end kw'>end</span> - <span class='p identifier id'>p</span><span class='dot token'>.</span><span class='serialize identifier id'>serialize</span><span class='lparen token'>(</span><span class='string val'>"example7.xlsx"</span><span class='rparen token'>)</span> +<pre class="code"> <span class='id p'>p</span> <span class='op'>=</span> <span class='const'>Axlsx</span><span class='op'>::</span><span class='const'>Package</span><span class='period'>.</span><span class='id new'>new</span> + <span class='id p'>p</span><span class='period'>.</span><span class='id workbook'>workbook</span><span class='period'>.</span><span class='id add_worksheet'>add_worksheet</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id sheet'>sheet</span><span class='op'>|</span> + <span class='id sheet'>sheet</span><span class='period'>.</span><span class='id add_image'>add_image</span><span class='lparen'>(</span><span class='symbol'>:image_src</span> <span class='op'>=></span> <span class='lparen'>(</span><span class='const'>File</span><span class='period'>.</span><span class='id dirname'>dirname</span><span class='lparen'>(</span><span class='kw'>__FILE__</span><span class='rparen'>)</span> <span class='op'>+</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>/image1.png</span><span class='tstring_end'>"</span></span><span class='rparen'>)</span><span class='rparen'>)</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id image'>image</span><span class='op'>|</span> + <span class='id image'>image</span><span class='period'>.</span><span class='id width'>width</span><span class='op'>=</span><span class='int'>720</span> + <span class='id image'>image</span><span class='period'>.</span><span class='id height'>height</span><span class='op'>=</span><span class='int'>666</span> + <span class='id image'>image</span><span class='period'>.</span><span class='id start_at'>start_at</span> <span class='int'>2</span><span class='comma'>,</span> <span class='int'>2</span> + <span class='kw'>end</span> + <span class='kw'>end</span> + <span class='id p'>p</span><span class='period'>.</span><span class='id serialize'>serialize</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>example7.xlsx</span><span class='tstring_end'>"</span></span><span class='rparen'>)</span> +</pre> + +<p>Asian Language Support</p> + +<pre class="code"> <span class='id p'>p</span> <span class='op'>=</span> <span class='const'>Axlsx</span><span class='op'>::</span><span class='const'>Package</span><span class='period'>.</span><span class='id new'>new</span> + <span class='id p'>p</span><span class='period'>.</span><span class='id workbook'>workbook</span><span class='period'>.</span><span class='id add_worksheet'>add_worksheet</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id sheet'>sheet</span><span class='op'>|</span> + <span class='id sheet'>sheet</span><span class='period'>.</span><span class='id add_row'>add_row</span> <span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>日本語</span><span class='tstring_end'>"</span></span><span class='rbracket'>]</span> + <span class='id sheet'>sheet</span><span class='period'>.</span><span class='id add_row'>add_row</span> <span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>华语/華語</span><span class='tstring_end'>"</span></span><span class='rbracket'>]</span> + <span class='id sheet'>sheet</span><span class='period'>.</span><span class='id add_row'>add_row</span> <span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>한국어/조선말</span><span class='tstring_end'>"</span></span><span class='rbracket'>]</span> + <span class='kw'>end</span> + <span class='id p'>p</span><span class='period'>.</span><span class='id serialize'>serialize</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>example8.xlsx</span><span class='tstring_end'>"</span></span><span class='rparen'>)</span> </pre> <h3>Documentation</h3> <p>This gem is 100% documented with YARD, an exceptional documentation library. To see documentation for this, and all the gems installed on your system use:</p> -<pre class="code"> <span class='gem identifier id'>gem</span> <span class='install identifier id'>install</span> <span class='yard identifier id'>yard</span> - <span class='yard identifier id'>yard</span> <span class='server identifier id'>server</span> <span class='minus op'>-</span><span class='g identifier id'>g</span> +<pre class="code"> <span class='id gem'>gem</span> <span class='id install'>install</span> <span class='id yard'>yard</span> + <span class='id yard'>yard</span> <span class='id server'>server</span> <span class='op'>-</span><span class='id g'>g</span> </pre> <h3>Specs</h3> @@ -223,24 +238,11 @@ It enables the you to generate 100% valid xlsx files that include customised sty <h2>Changelog</h2> <ul> -<li><p><strong>October.23.11</strong>: 1.0.8 release</p> +<li><strong>October.26.11</strong>: 1.0.9 release <ul> -<li>Added support for images (jpg, gif, png) in worksheets.</li> -</ul> -</li> -<li><p><strong>October.23.11</strong>: 1.0.7 released</p> - -<ul> -<li>Added support for 3D options when creating a new chart. This lets you set the persective, rotation and other 3D attributes when using worksheet.add_chart</li> -<li>Updated serialization write test to verify write permissions and warn if it cannot run the test due to permission restrcitions.</li> -<li>updated rake to include build, genoc and deploy tasks.</li> -<li>rebuilt documentation.</li> -<li>moved version constant to its own file</li> -<li>fixed bug in SerAxis that was requiring tickLblSkip and tickMarkSkip to be boolean. Should be unsigned int.</li> -<li>Review and improve docs</li> -<li>rebuild of anchor positioning to remove some spagetti code. Chart now supports a start_at and end_at method that accept an arrar for col/row positioning. See example6 for an example. You can still pass :start_at and :end_at options to worksheet.add_chart.</li> -<li>Refactored cat and val axis data to keep series serialization a bit more DRY</li> +<li>Updated to support ruby 1.9.3</li> +<li>Updated to eliminate all warnings originating in this gem</li> </ul> </li> </ul> @@ -248,10 +250,6 @@ It enables the you to generate 100% valid xlsx files that include customised sty <p>Please see the <a href="file.CHANGELOG.html" title="CHANGELOG">CHANGELOG</a> document for past release information.</p> -<h2>Help Wanted</h2> - -<p>I'd really like to get rid of the depenency on RMagick in this gem. RMagic is being used to calculate the column widths in a worksheet based on the content the user specified. If there happens to be anyone out there with the background and skill set to write an extenstion that can determine the width of a single character rendered with a specific font at a specific size please give me a shout.</p> - <h2>Copyright</h2> <p>Axlsx © 2011 by <a href="mailto:[email protected]">Randy Morgan</a>. Axlsx is @@ -259,9 +257,9 @@ licensed under the MIT license. Please see the <a href="file.LICENSE.html" title </div></div> <div id="footer"> - Generated on Wed Nov 23 22:20:44 2011 by + Generated on Sat Nov 26 13:16:35 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/doc/method_list.html b/doc/method_list.html index 704dd4d6..db85672c 100644 --- a/doc/method_list.html +++ b/doc/method_list.html @@ -41,22 +41,6 @@ <li class="r1 "> - <span class='object_link'><a href="Axlsx/SimpleTypedList.html#%3C%3C-instance_method" title="Axlsx::SimpleTypedList#<< (method)">#<<</a></span> - - <small>Axlsx::SimpleTypedList</small> - - </li> - - - <li class="r2 "> - <span class='object_link'><a href="Axlsx/SimpleTypedList.html#%3D%3D-instance_method" title="Axlsx::SimpleTypedList#== (method)">#==</a></span> - - <small>Axlsx::SimpleTypedList</small> - - </li> - - - <li class="r1 "> <span class='object_link'><a href="Axlsx/App.html#AppVersion-instance_method" title="Axlsx::App#AppVersion (method)">#AppVersion</a></span> <small>Axlsx::App</small> @@ -97,17 +81,17 @@ <li class="r2 "> - <span class='object_link'><a href="Axlsx/Default.html#ContentType-instance_method" title="Axlsx::Default#ContentType (method)">#ContentType</a></span> + <span class='object_link'><a href="Axlsx/Override.html#ContentType-instance_method" title="Axlsx::Override#ContentType (method)">#ContentType</a></span> - <small>Axlsx::Default</small> + <small>Axlsx::Override</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/Override.html#ContentType-instance_method" title="Axlsx::Override#ContentType (method)">#ContentType</a></span> + <span class='object_link'><a href="Axlsx/Default.html#ContentType-instance_method" title="Axlsx::Default#ContentType (method)">#ContentType</a></span> - <small>Axlsx::Override</small> + <small>Axlsx::Default</small> </li> @@ -289,17 +273,17 @@ <li class="r2 "> - <span class='object_link'><a href="Axlsx/SimpleTypedList.html#%5B%5D%3D-instance_method" title="Axlsx::SimpleTypedList#[]= (method)">#[]=</a></span> + <span class='object_link'><a href="Axlsx/Row.html#add_cell-instance_method" title="Axlsx::Row#add_cell (method)">#add_cell</a></span> - <small>Axlsx::SimpleTypedList</small> + <small>Axlsx::Row</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/Row.html#add_cell-instance_method" title="Axlsx::Row#add_cell (method)">#add_cell</a></span> + <span class='object_link'><a href="Axlsx/Drawing.html#add_chart-instance_method" title="Axlsx::Drawing#add_chart (method)">#add_chart</a></span> - <small>Axlsx::Row</small> + <small>Axlsx::Drawing</small> </li> @@ -313,17 +297,17 @@ <li class="r1 "> - <span class='object_link'><a href="Axlsx/Drawing.html#add_chart-instance_method" title="Axlsx::Drawing#add_chart (method)">#add_chart</a></span> + <span class='object_link'><a href="Axlsx/TwoCellAnchor.html#add_chart-instance_method" title="Axlsx::TwoCellAnchor#add_chart (method)">#add_chart</a></span> - <small>Axlsx::Drawing</small> + <small>Axlsx::TwoCellAnchor</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/TwoCellAnchor.html#add_chart-instance_method" title="Axlsx::TwoCellAnchor#add_chart (method)">#add_chart</a></span> + <span class='object_link'><a href="Axlsx/Worksheet.html#add_image-instance_method" title="Axlsx::Worksheet#add_image (method)">#add_image</a></span> - <small>Axlsx::TwoCellAnchor</small> + <small>Axlsx::Worksheet</small> </li> @@ -337,14 +321,6 @@ <li class="r2 "> - <span class='object_link'><a href="Axlsx/Worksheet.html#add_image-instance_method" title="Axlsx::Worksheet#add_image (method)">#add_image</a></span> - - <small>Axlsx::Worksheet</small> - - </li> - - - <li class="r1 "> <span class='object_link'><a href="Axlsx/Worksheet.html#add_row-instance_method" title="Axlsx::Worksheet#add_row (method)">#add_row</a></span> <small>Axlsx::Worksheet</small> @@ -352,7 +328,7 @@ </li> - <li class="r2 "> + <li class="r1 "> <span class='object_link'><a href="Axlsx/Chart.html#add_series-instance_method" title="Axlsx::Chart#add_series (method)">#add_series</a></span> <small>Axlsx::Chart</small> @@ -360,7 +336,7 @@ </li> - <li class="r1 "> + <li class="r2 "> <span class='object_link'><a href="Axlsx/Styles.html#add_style-instance_method" title="Axlsx::Styles#add_style (method)">#add_style</a></span> <small>Axlsx::Styles</small> @@ -368,7 +344,7 @@ </li> - <li class="r2 "> + <li class="r1 "> <span class='object_link'><a href="Axlsx/Workbook.html#add_worksheet-instance_method" title="Axlsx::Workbook#add_worksheet (method)">#add_worksheet</a></span> <small>Axlsx::Workbook</small> @@ -376,7 +352,7 @@ </li> - <li class="r1 "> + <li class="r2 "> <span class='object_link'><a href="Axlsx/Xf.html#alignment-instance_method" title="Axlsx::Xf#alignment (method)">#alignment</a></span> <small>Axlsx::Xf</small> @@ -384,14 +360,6 @@ </li> - <li class="r2 "> - <span class='object_link'><a href="Axlsx/SimpleTypedList.html#allowed_types-instance_method" title="Axlsx::SimpleTypedList#allowed_types (method)">#allowed_types</a></span> - - <small>Axlsx::SimpleTypedList</small> - - </li> - - <li class="r1 "> <span class='object_link'><a href="Axlsx/GraphicFrame.html#anchor-instance_method" title="Axlsx::GraphicFrame#anchor (method)">#anchor</a></span> @@ -489,14 +457,6 @@ <li class="r1 "> - <span class='object_link'><a href="Axlsx/Worksheet.html#auto_width-instance_method" title="Axlsx::Worksheet#auto_width (method)">#auto_width</a></span> - - <small>Axlsx::Worksheet</small> - - </li> - - - <li class="r2 "> <span class='object_link'><a href="Axlsx/Axis.html#axId-instance_method" title="Axlsx::Axis#axId (method)">#axId</a></span> <small>Axlsx::Axis</small> @@ -504,7 +464,7 @@ </li> - <li class="r1 "> + <li class="r2 "> <span class='object_link'><a href="Axlsx/Axis.html#axPos-instance_method" title="Axlsx::Axis#axPos (method)">#axPos</a></span> <small>Axlsx::Axis</small> @@ -512,7 +472,7 @@ </li> - <li class="r2 "> + <li class="r1 "> <span class='object_link'><a href="Axlsx/Font.html#b-instance_method" title="Axlsx::Font#b (method)">#b</a></span> <small>Axlsx::Font</small> @@ -520,7 +480,7 @@ </li> - <li class="r1 "> + <li class="r2 "> <span class='object_link'><a href="Axlsx/Bar3DChart.html#barDir-instance_method" title="Axlsx::Bar3DChart#barDir (method)">#barDir</a></span> <small>Axlsx::Bar3DChart</small> @@ -528,14 +488,6 @@ </li> - <li class="r2 "> - <span class='object_link'><a href="Axlsx/Package.html#base_content_types-instance_method" title="Axlsx::Package#base_content_types (method)">#base_content_types</a></span> - - <small>Axlsx::Package</small> - - </li> - - <li class="r1 "> <span class='object_link'><a href="Axlsx/PatternFill.html#bgColor-instance_method" title="Axlsx::PatternFill#bgColor (method)">#bgColor</a></span> @@ -577,9 +529,9 @@ <li class="r2 "> - <span class='object_link'><a href="Axlsx/Cell.html#cast_value-instance_method" title="Axlsx::Cell#cast_value (method)">#cast_value</a></span> + <span class='object_link'><a href="Axlsx/Line3DChart.html#catAxis-instance_method" title="Axlsx::Line3DChart#catAxis (method)">#catAxis</a></span> - <small>Axlsx::Cell</small> + <small>Axlsx::Line3DChart</small> </li> @@ -593,14 +545,6 @@ <li class="r2 "> - <span class='object_link'><a href="Axlsx/Line3DChart.html#catAxis-instance_method" title="Axlsx::Line3DChart#catAxis (method)">#catAxis</a></span> - - <small>Axlsx::Line3DChart</small> - - </li> - - - <li class="r1 "> <span class='object_link'><a href="Axlsx/Title.html#cell-instance_method" title="Axlsx::Title#cell (method)">#cell</a></span> <small>Axlsx::Title</small> @@ -608,7 +552,7 @@ </li> - <li class="r2 "> + <li class="r1 "> <span class='object_link'><a href="Axlsx/Styles.html#cellStyleXfs-instance_method" title="Axlsx::Styles#cellStyleXfs (method)">#cellStyleXfs</a></span> <small>Axlsx::Styles</small> @@ -616,7 +560,7 @@ </li> - <li class="r1 "> + <li class="r2 "> <span class='object_link'><a href="Axlsx/Styles.html#cellStyles-instance_method" title="Axlsx::Styles#cellStyles (method)">#cellStyles</a></span> <small>Axlsx::Styles</small> @@ -624,7 +568,7 @@ </li> - <li class="r2 "> + <li class="r1 "> <span class='object_link'><a href="Axlsx/Styles.html#cellXfs-instance_method" title="Axlsx::Styles#cellXfs (method)">#cellXfs</a></span> <small>Axlsx::Styles</small> @@ -632,7 +576,7 @@ </li> - <li class="r1 "> + <li class="r2 "> <span class='object_link'><a href="Axlsx.html#cell_range-class_method" title="Axlsx.cell_range (method)">cell_range</a></span> <small>Axlsx</small> @@ -640,14 +584,6 @@ </li> - <li class="r2 "> - <span class='object_link'><a href="Axlsx/Cell.html#cell_type_from_value-instance_method" title="Axlsx::Cell#cell_type_from_value (method)">#cell_type_from_value</a></span> - - <small>Axlsx::Cell</small> - - </li> - - <li class="r1 "> <span class='object_link'><a href="Axlsx/Row.html#cells-instance_method" title="Axlsx::Row#cells (method)">#cells</a></span> @@ -665,33 +601,33 @@ <li class="r1 "> - <span class='object_link'><a href="Axlsx/GraphicFrame.html#chart-instance_method" title="Axlsx::GraphicFrame#chart (method)">#chart</a></span> + <span class='object_link'><a href="Axlsx/Series.html#chart-instance_method" title="Axlsx::Series#chart (method)">#chart</a></span> - <small>Axlsx::GraphicFrame</small> + <small>Axlsx::Series</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/Series.html#chart-instance_method" title="Axlsx::Series#chart (method)">#chart</a></span> + <span class='object_link'><a href="Axlsx/GraphicFrame.html#chart-instance_method" title="Axlsx::GraphicFrame#chart (method)">#chart</a></span> - <small>Axlsx::Series</small> + <small>Axlsx::GraphicFrame</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/Drawing.html#charts-instance_method" title="Axlsx::Drawing#charts (method)">#charts</a></span> + <span class='object_link'><a href="Axlsx/Workbook.html#charts-instance_method" title="Axlsx::Workbook#charts (method)">#charts</a></span> - <small>Axlsx::Drawing</small> + <small>Axlsx::Workbook</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/Workbook.html#charts-instance_method" title="Axlsx::Workbook#charts (method)">#charts</a></span> + <span class='object_link'><a href="Axlsx/Drawing.html#charts-instance_method" title="Axlsx::Drawing#charts (method)">#charts</a></span> - <small>Axlsx::Workbook</small> + <small>Axlsx::Drawing</small> </li> @@ -713,9 +649,9 @@ <li class="r1 "> - <span class='object_link'><a href="Axlsx/Cell.html#col_ref-instance_method" title="Axlsx::Cell#col_ref (method)">#col_ref</a></span> + <span class='object_link'><a href="Axlsx/GradientStop.html#color-instance_method" title="Axlsx::GradientStop#color (method)">#color</a></span> - <small>Axlsx::Cell</small> + <small>Axlsx::GradientStop</small> </li> @@ -737,14 +673,6 @@ <li class="r2 "> - <span class='object_link'><a href="Axlsx/GradientStop.html#color-instance_method" title="Axlsx::GradientStop#color (method)">#color</a></span> - - <small>Axlsx::GradientStop</small> - - </li> - - - <li class="r1 "> <span class='object_link'><a href="Axlsx/Font.html#condense-instance_method" title="Axlsx::Font#condense (method)">#condense</a></span> <small>Axlsx::Font</small> @@ -752,14 +680,6 @@ </li> - <li class="r2 "> - <span class='object_link'><a href="Axlsx/Package.html#content_types-instance_method" title="Axlsx::Package#content_types (method)">#content_types</a></span> - - <small>Axlsx::Package</small> - - </li> - - <li class="r1 "> <span class='object_link'><a href="Axlsx/Marker.html#coord-instance_method" title="Axlsx::Marker#coord (method)">#coord</a></span> @@ -809,25 +729,25 @@ <li class="r1 "> - <span class='object_link'><a href="Axlsx/BarSeries.html#data-instance_method" title="Axlsx::BarSeries#data (method)">#data</a></span> + <span class='object_link'><a href="Axlsx/LineSeries.html#data-instance_method" title="Axlsx::LineSeries#data (method)">#data</a></span> - <small>Axlsx::BarSeries</small> + <small>Axlsx::LineSeries</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/LineSeries.html#data-instance_method" title="Axlsx::LineSeries#data (method)">#data</a></span> + <span class='object_link'><a href="Axlsx/PieSeries.html#data-instance_method" title="Axlsx::PieSeries#data (method)">#data</a></span> - <small>Axlsx::LineSeries</small> + <small>Axlsx::PieSeries</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/PieSeries.html#data-instance_method" title="Axlsx::PieSeries#data (method)">#data</a></span> + <span class='object_link'><a href="Axlsx/BarSeries.html#data-instance_method" title="Axlsx::BarSeries#data (method)">#data</a></span> - <small>Axlsx::PieSeries</small> + <small>Axlsx::BarSeries</small> </li> @@ -857,15 +777,15 @@ <li class="r1 "> - <span class='object_link'><a href="Axlsx/TableStyles.html#defaultPivotStyle-instance_method" title="Axlsx::TableStyles#defaultPivotStyle (method)">#defaultPivotStyle</a></span> + <span class='object_link'><a href="Axlsx/Workbook.html#date1904%3D-instance_method" title="Axlsx::Workbook#date1904= (method)">#date1904=</a></span> - <small>Axlsx::TableStyles</small> + <small>Axlsx::Workbook</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/TableStyles.html#defaultTableStyle-instance_method" title="Axlsx::TableStyles#defaultTableStyle (method)">#defaultTableStyle</a></span> + <span class='object_link'><a href="Axlsx/TableStyles.html#defaultPivotStyle-instance_method" title="Axlsx::TableStyles#defaultPivotStyle (method)">#defaultPivotStyle</a></span> <small>Axlsx::TableStyles</small> @@ -873,47 +793,47 @@ <li class="r1 "> - <span class='object_link'><a href="Axlsx/GradientFill.html#degree-instance_method" title="Axlsx::GradientFill#degree (method)">#degree</a></span> + <span class='object_link'><a href="Axlsx/TableStyles.html#defaultTableStyle-instance_method" title="Axlsx::TableStyles#defaultTableStyle (method)">#defaultTableStyle</a></span> - <small>Axlsx::GradientFill</small> + <small>Axlsx::TableStyles</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/SimpleTypedList.html#delete-instance_method" title="Axlsx::SimpleTypedList#delete (method)">#delete</a></span> + <span class='object_link'><a href="Axlsx/GradientFill.html#degree-instance_method" title="Axlsx::GradientFill#degree (method)">#degree</a></span> - <small>Axlsx::SimpleTypedList</small> + <small>Axlsx::GradientFill</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/SimpleTypedList.html#delete_at-instance_method" title="Axlsx::SimpleTypedList#delete_at (method)">#delete_at</a></span> + <span class='object_link'><a href="Axlsx/View3D.html#depthPercent-instance_method" title="Axlsx::View3D#depthPercent (method)">#depthPercent</a></span> - <small>Axlsx::SimpleTypedList</small> + <small>Axlsx::View3D</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/View3D.html#depthPercent-instance_method" title="Axlsx::View3D#depthPercent (method)">#depthPercent</a></span> + <span class='object_link'><a href="Axlsx/Pic.html#descr-instance_method" title="Axlsx::Pic#descr (method)">#descr</a></span> - <small>Axlsx::View3D</small> + <small>Axlsx::Pic</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/Pic.html#descr-instance_method" title="Axlsx::Pic#descr (method)">#descr</a></span> + <span class='object_link'><a href="Axlsx/Border.html#diagonalDown-instance_method" title="Axlsx::Border#diagonalDown (method)">#diagonalDown</a></span> - <small>Axlsx::Pic</small> + <small>Axlsx::Border</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/Border.html#diagonalDown-instance_method" title="Axlsx::Border#diagonalDown (method)">#diagonalDown</a></span> + <span class='object_link'><a href="Axlsx/Border.html#diagonalUp-instance_method" title="Axlsx::Border#diagonalUp (method)">#diagonalUp</a></span> <small>Axlsx::Border</small> @@ -921,9 +841,9 @@ <li class="r1 "> - <span class='object_link'><a href="Axlsx/Border.html#diagonalUp-instance_method" title="Axlsx::Border#diagonalUp (method)">#diagonalUp</a></span> + <span class='object_link'><a href="Axlsx/Worksheet.html#drawing-instance_method" title="Axlsx::Worksheet#drawing (method)">#drawing</a></span> - <small>Axlsx::Border</small> + <small>Axlsx::Worksheet</small> </li> @@ -937,14 +857,6 @@ <li class="r1 "> - <span class='object_link'><a href="Axlsx/Worksheet.html#drawing-instance_method" title="Axlsx::Worksheet#drawing (method)">#drawing</a></span> - - <small>Axlsx::Worksheet</small> - - </li> - - - <li class="r2 "> <span class='object_link'><a href="Axlsx/OneCellAnchor.html#drawing-instance_method" title="Axlsx::OneCellAnchor#drawing (method)">#drawing</a></span> <small>Axlsx::OneCellAnchor</small> @@ -952,7 +864,7 @@ </li> - <li class="r1 "> + <li class="r2 "> <span class='object_link'><a href="Axlsx/Workbook.html#drawings-instance_method" title="Axlsx::Workbook#drawings (method)">#drawings</a></span> <small>Axlsx::Workbook</small> @@ -960,7 +872,7 @@ </li> - <li class="r2 "> + <li class="r1 "> <span class='object_link'><a href="Axlsx/TableStyleElement.html#dxfId-instance_method" title="Axlsx::TableStyleElement#dxfId (method)">#dxfId</a></span> <small>Axlsx::TableStyleElement</small> @@ -968,7 +880,7 @@ </li> - <li class="r1 "> + <li class="r2 "> <span class='object_link'><a href="Axlsx/Styles.html#dxfs-instance_method" title="Axlsx::Styles#dxfs (method)">#dxfs</a></span> <small>Axlsx::Styles</small> @@ -976,7 +888,7 @@ </li> - <li class="r2 "> + <li class="r1 "> <span class='object_link'><a href="Axlsx/Chart.html#end_at-instance_method" title="Axlsx::Chart#end_at (method)">#end_at</a></span> <small>Axlsx::Chart</small> @@ -984,7 +896,7 @@ </li> - <li class="r1 "> + <li class="r2 "> <span class='object_link'><a href="Axlsx/PieSeries.html#explosion-instance_method" title="Axlsx::PieSeries#explosion (method)">#explosion</a></span> <small>Axlsx::PieSeries</small> @@ -992,7 +904,7 @@ </li> - <li class="r2 "> + <li class="r1 "> <span class='object_link'><a href="Axlsx/Font.html#extend-instance_method" title="Axlsx::Font#extend (method)">#extend</a></span> <small>Axlsx::Font</small> @@ -1000,7 +912,7 @@ </li> - <li class="r1 "> + <li class="r2 "> <span class='object_link'><a href="Axlsx/Pic.html#extname-instance_method" title="Axlsx::Pic#extname (method)">#extname</a></span> <small>Axlsx::Pic</small> @@ -1008,7 +920,7 @@ </li> - <li class="r2 "> + <li class="r1 "> <span class='object_link'><a href="Axlsx/Font.html#family-instance_method" title="Axlsx::Font#family (method)">#family</a></span> <small>Axlsx::Font</small> @@ -1016,7 +928,7 @@ </li> - <li class="r1 "> + <li class="r2 "> <span class='object_link'><a href="Axlsx/PatternFill.html#fgColor-instance_method" title="Axlsx::PatternFill#fgColor (method)">#fgColor</a></span> <small>Axlsx::PatternFill</small> @@ -1024,7 +936,7 @@ </li> - <li class="r2 "> + <li class="r1 "> <span class='object_link'><a href="Axlsx/Pic.html#file_name-instance_method" title="Axlsx::Pic#file_name (method)">#file_name</a></span> <small>Axlsx::Pic</small> @@ -1032,7 +944,7 @@ </li> - <li class="r1 "> + <li class="r2 "> <span class='object_link'><a href="Axlsx/Xf.html#fillId-instance_method" title="Axlsx::Xf#fillId (method)">#fillId</a></span> <small>Axlsx::Xf</small> @@ -1040,7 +952,7 @@ </li> - <li class="r2 "> + <li class="r1 "> <span class='object_link'><a href="Axlsx/Fill.html#fill_type-instance_method" title="Axlsx::Fill#fill_type (method)">#fill_type</a></span> <small>Axlsx::Fill</small> @@ -1048,7 +960,7 @@ </li> - <li class="r1 "> + <li class="r2 "> <span class='object_link'><a href="Axlsx/Styles.html#fills-instance_method" title="Axlsx::Styles#fills (method)">#fills</a></span> <small>Axlsx::Styles</small> @@ -1056,7 +968,7 @@ </li> - <li class="r2 "> + <li class="r1 "> <span class='object_link'><a href="Axlsx/Xf.html#fontId-instance_method" title="Axlsx::Xf#fontId (method)">#fontId</a></span> <small>Axlsx::Xf</small> @@ -1064,7 +976,7 @@ </li> - <li class="r1 "> + <li class="r2 "> <span class='object_link'><a href="Axlsx/Styles.html#fonts-instance_method" title="Axlsx::Styles#fonts (method)">#fonts</a></span> <small>Axlsx::Styles</small> @@ -1072,7 +984,7 @@ </li> - <li class="r2 "> + <li class="r1 "> <span class='object_link'><a href="Axlsx/NumFmt.html#formatCode-instance_method" title="Axlsx::NumFmt#formatCode (method)">#formatCode</a></span> <small>Axlsx::NumFmt</small> @@ -1080,7 +992,7 @@ </li> - <li class="r1 "> + <li class="r2 "> <span class='object_link'><a href="Axlsx/Axis.html#format_code-instance_method" title="Axlsx::Axis#format_code (method)">#format_code</a></span> <small>Axlsx::Axis</small> @@ -1088,6 +1000,14 @@ </li> + <li class="r1 "> + <span class='object_link'><a href="Axlsx/Chart.html#from-instance_method" title="Axlsx::Chart#from (method)">#from</a></span> + + <small>Axlsx::Chart</small> + + </li> + + <li class="r2 "> <span class='object_link'><a href="Axlsx/TwoCellAnchor.html#from-instance_method" title="Axlsx::TwoCellAnchor#from (method)">#from</a></span> @@ -1097,17 +1017,17 @@ <li class="r1 "> - <span class='object_link'><a href="Axlsx/Chart.html#from-instance_method" title="Axlsx::Chart#from (method)">#from</a></span> + <span class='object_link'><a href="Axlsx/OneCellAnchor.html#from-instance_method" title="Axlsx::OneCellAnchor#from (method)">#from</a></span> - <small>Axlsx::Chart</small> + <small>Axlsx::OneCellAnchor</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/OneCellAnchor.html#from-instance_method" title="Axlsx::OneCellAnchor#from (method)">#from</a></span> + <span class='object_link'><a href="Axlsx/Bar3DChart.html#gapDepth-instance_method" title="Axlsx::Bar3DChart#gapDepth (method)">#gapDepth</a></span> - <small>Axlsx::OneCellAnchor</small> + <small>Axlsx::Bar3DChart</small> </li> @@ -1121,7 +1041,7 @@ <li class="r2 "> - <span class='object_link'><a href="Axlsx/Bar3DChart.html#gapDepth-instance_method" title="Axlsx::Bar3DChart#gapDepth (method)">#gapDepth</a></span> + <span class='object_link'><a href="Axlsx/Bar3DChart.html#gapWidth-instance_method" title="Axlsx::Bar3DChart#gapWidth (method)">#gapWidth</a></span> <small>Axlsx::Bar3DChart</small> @@ -1129,17 +1049,17 @@ <li class="r1 "> - <span class='object_link'><a href="Axlsx/Bar3DChart.html#gapWidth-instance_method" title="Axlsx::Bar3DChart#gapWidth (method)">#gapWidth</a></span> + <span class='object_link'><a href="Axlsx/Chart.html#graphic_frame-instance_method" title="Axlsx::Chart#graphic_frame (method)">#graphic_frame</a></span> - <small>Axlsx::Bar3DChart</small> + <small>Axlsx::Chart</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/Chart.html#graphic_frame-instance_method" title="Axlsx::Chart#graphic_frame (method)">#graphic_frame</a></span> + <span class='object_link'><a href="Axlsx/Bar3DChart.html#grouping-instance_method" title="Axlsx::Bar3DChart#grouping (method)">#grouping</a></span> - <small>Axlsx::Chart</small> + <small>Axlsx::Bar3DChart</small> </li> @@ -1153,17 +1073,17 @@ <li class="r2 "> - <span class='object_link'><a href="Axlsx/Bar3DChart.html#grouping-instance_method" title="Axlsx::Bar3DChart#grouping (method)">#grouping</a></span> + <span class='object_link'><a href="Axlsx/View3D.html#hPercent-instance_method" title="Axlsx::View3D#hPercent (method)">#hPercent</a></span> - <small>Axlsx::Bar3DChart</small> + <small>Axlsx::View3D</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/View3D.html#hPercent-instance_method" title="Axlsx::View3D#hPercent (method)">#hPercent</a></span> + <span class='object_link'><a href="Axlsx/Pic.html#height-instance_method" title="Axlsx::Pic#height (method)">#height</a></span> - <small>Axlsx::View3D</small> + <small>Axlsx::Pic</small> </li> @@ -1177,7 +1097,7 @@ <li class="r1 "> - <span class='object_link'><a href="Axlsx/Pic.html#height-instance_method" title="Axlsx::Pic#height (method)">#height</a></span> + <span class='object_link'><a href="Axlsx/Pic.html#height%3D-instance_method" title="Axlsx::Pic#height= (method)">#height=</a></span> <small>Axlsx::Pic</small> @@ -1257,41 +1177,41 @@ <li class="r1 "> - <span class='object_link'><a href="Axlsx/Chart.html#index-instance_method" title="Axlsx::Chart#index (method)">#index</a></span> + <span class='object_link'><a href="Axlsx/Worksheet.html#index-instance_method" title="Axlsx::Worksheet#index (method)">#index</a></span> - <small>Axlsx::Chart</small> + <small>Axlsx::Worksheet</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/Cell.html#index-instance_method" title="Axlsx::Cell#index (method)">#index</a></span> + <span class='object_link'><a href="Axlsx/Row.html#index-instance_method" title="Axlsx::Row#index (method)">#index</a></span> - <small>Axlsx::Cell</small> + <small>Axlsx::Row</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/Row.html#index-instance_method" title="Axlsx::Row#index (method)">#index</a></span> + <span class='object_link'><a href="Axlsx/Series.html#index-instance_method" title="Axlsx::Series#index (method)">#index</a></span> - <small>Axlsx::Row</small> + <small>Axlsx::Series</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/Worksheet.html#index-instance_method" title="Axlsx::Worksheet#index (method)">#index</a></span> + <span class='object_link'><a href="Axlsx/Chart.html#index-instance_method" title="Axlsx::Chart#index (method)">#index</a></span> - <small>Axlsx::Worksheet</small> + <small>Axlsx::Chart</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/Series.html#index-instance_method" title="Axlsx::Series#index (method)">#index</a></span> + <span class='object_link'><a href="Axlsx/Cell.html#index-instance_method" title="Axlsx::Cell#index (method)">#index</a></span> - <small>Axlsx::Series</small> + <small>Axlsx::Cell</small> </li> @@ -1305,25 +1225,25 @@ <li class="r1 "> - <span class='object_link'><a href="Axlsx/Pic.html#index-instance_method" title="Axlsx::Pic#index (method)">#index</a></span> + <span class='object_link'><a href="Axlsx/TwoCellAnchor.html#index-instance_method" title="Axlsx::TwoCellAnchor#index (method)">#index</a></span> - <small>Axlsx::Pic</small> + <small>Axlsx::TwoCellAnchor</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/Drawing.html#index-instance_method" title="Axlsx::Drawing#index (method)">#index</a></span> + <span class='object_link'><a href="Axlsx/Pic.html#index-instance_method" title="Axlsx::Pic#index (method)">#index</a></span> - <small>Axlsx::Drawing</small> + <small>Axlsx::Pic</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/TwoCellAnchor.html#index-instance_method" title="Axlsx::TwoCellAnchor#index (method)">#index</a></span> + <span class='object_link'><a href="Axlsx/Drawing.html#index-instance_method" title="Axlsx::Drawing#index (method)">#index</a></span> - <small>Axlsx::TwoCellAnchor</small> + <small>Axlsx::Drawing</small> </li> @@ -1337,41 +1257,41 @@ <li class="r1 "> - <span class='object_link'><a href="Axlsx/BarSeries.html#initialize-instance_method" title="Axlsx::BarSeries#initialize (method)">#initialize</a></span> + <span class='object_link'><a href="Axlsx/Font.html#initialize-instance_method" title="Axlsx::Font#initialize (method)">#initialize</a></span> - <small>Axlsx::BarSeries</small> + <small>Axlsx::Font</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/Title.html#initialize-instance_method" title="Axlsx::Title#initialize (method)">#initialize</a></span> + <span class='object_link'><a href="Axlsx/Core.html#initialize-instance_method" title="Axlsx::Core#initialize (method)">#initialize</a></span> - <small>Axlsx::Title</small> + <small>Axlsx::Core</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/SimpleTypedList.html#initialize-instance_method" title="Axlsx::SimpleTypedList#initialize (method)">#initialize</a></span> + <span class='object_link'><a href="Axlsx/Bar3DChart.html#initialize-instance_method" title="Axlsx::Bar3DChart#initialize (method)">#initialize</a></span> - <small>Axlsx::SimpleTypedList</small> + <small>Axlsx::Bar3DChart</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/Bar3DChart.html#initialize-instance_method" title="Axlsx::Bar3DChart#initialize (method)">#initialize</a></span> + <span class='object_link'><a href="Axlsx/Override.html#initialize-instance_method" title="Axlsx::Override#initialize (method)">#initialize</a></span> - <small>Axlsx::Bar3DChart</small> + <small>Axlsx::Override</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/GradientStop.html#initialize-instance_method" title="Axlsx::GradientStop#initialize (method)">#initialize</a></span> + <span class='object_link'><a href="Axlsx/View3D.html#initialize-instance_method" title="Axlsx::View3D#initialize (method)">#initialize</a></span> - <small>Axlsx::GradientStop</small> + <small>Axlsx::View3D</small> </li> @@ -1385,49 +1305,49 @@ <li class="r1 "> - <span class='object_link'><a href="Axlsx/CatAxis.html#initialize-instance_method" title="Axlsx::CatAxis#initialize (method)">#initialize</a></span> + <span class='object_link'><a href="Axlsx/Drawing.html#initialize-instance_method" title="Axlsx::Drawing#initialize (method)">#initialize</a></span> - <small>Axlsx::CatAxis</small> + <small>Axlsx::Drawing</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/ContentType.html#initialize-instance_method" title="Axlsx::ContentType#initialize (method)">#initialize</a></span> + <span class='object_link'><a href="Axlsx/Xf.html#initialize-instance_method" title="Axlsx::Xf#initialize (method)">#initialize</a></span> - <small>Axlsx::ContentType</small> + <small>Axlsx::Xf</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/Marker.html#initialize-instance_method" title="Axlsx::Marker#initialize (method)">#initialize</a></span> + <span class='object_link'><a href="Axlsx/LineSeries.html#initialize-instance_method" title="Axlsx::LineSeries#initialize (method)">#initialize</a></span> - <small>Axlsx::Marker</small> + <small>Axlsx::LineSeries</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/Xf.html#initialize-instance_method" title="Axlsx::Xf#initialize (method)">#initialize</a></span> + <span class='object_link'><a href="Axlsx/Axis.html#initialize-instance_method" title="Axlsx::Axis#initialize (method)">#initialize</a></span> - <small>Axlsx::Xf</small> + <small>Axlsx::Axis</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/Row.html#initialize-instance_method" title="Axlsx::Row#initialize (method)">#initialize</a></span> + <span class='object_link'><a href="Axlsx/PieSeries.html#initialize-instance_method" title="Axlsx::PieSeries#initialize (method)">#initialize</a></span> - <small>Axlsx::Row</small> + <small>Axlsx::PieSeries</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/LineSeries.html#initialize-instance_method" title="Axlsx::LineSeries#initialize (method)">#initialize</a></span> + <span class='object_link'><a href="Axlsx/Title.html#initialize-instance_method" title="Axlsx::Title#initialize (method)">#initialize</a></span> - <small>Axlsx::LineSeries</small> + <small>Axlsx::Title</small> </li> @@ -1441,65 +1361,65 @@ <li class="r2 "> - <span class='object_link'><a href="Axlsx/TableStyles.html#initialize-instance_method" title="Axlsx::TableStyles#initialize (method)">#initialize</a></span> + <span class='object_link'><a href="Axlsx/Scaling.html#initialize-instance_method" title="Axlsx::Scaling#initialize (method)">#initialize</a></span> - <small>Axlsx::TableStyles</small> + <small>Axlsx::Scaling</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/Default.html#initialize-instance_method" title="Axlsx::Default#initialize (method)">#initialize</a></span> + <span class='object_link'><a href="Axlsx/Relationships.html#initialize-instance_method" title="Axlsx::Relationships#initialize (method)">#initialize</a></span> - <small>Axlsx::Default</small> + <small>Axlsx::Relationships</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/Font.html#initialize-instance_method" title="Axlsx::Font#initialize (method)">#initialize</a></span> + <span class='object_link'><a href="Axlsx/Default.html#initialize-instance_method" title="Axlsx::Default#initialize (method)">#initialize</a></span> - <small>Axlsx::Font</small> + <small>Axlsx::Default</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/TableStyleElement.html#initialize-instance_method" title="Axlsx::TableStyleElement#initialize (method)">#initialize</a></span> + <span class='object_link'><a href="Axlsx/BarSeries.html#initialize-instance_method" title="Axlsx::BarSeries#initialize (method)">#initialize</a></span> - <small>Axlsx::TableStyleElement</small> + <small>Axlsx::BarSeries</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/Core.html#initialize-instance_method" title="Axlsx::Core#initialize (method)">#initialize</a></span> + <span class='object_link'><a href="Axlsx/CellAlignment.html#initialize-instance_method" title="Axlsx::CellAlignment#initialize (method)">#initialize</a></span> - <small>Axlsx::Core</small> + <small>Axlsx::CellAlignment</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/Chart.html#initialize-instance_method" title="Axlsx::Chart#initialize (method)">#initialize</a></span> + <span class='object_link'><a href="Axlsx/CatAxis.html#initialize-instance_method" title="Axlsx::CatAxis#initialize (method)">#initialize</a></span> - <small>Axlsx::Chart</small> + <small>Axlsx::CatAxis</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/Worksheet.html#initialize-instance_method" title="Axlsx::Worksheet#initialize (method)">#initialize</a></span> + <span class='object_link'><a href="Axlsx/NumFmt.html#initialize-instance_method" title="Axlsx::NumFmt#initialize (method)">#initialize</a></span> - <small>Axlsx::Worksheet</small> + <small>Axlsx::NumFmt</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/CellProtection.html#initialize-instance_method" title="Axlsx::CellProtection#initialize (method)">#initialize</a></span> + <span class='object_link'><a href="Axlsx/GradientStop.html#initialize-instance_method" title="Axlsx::GradientStop#initialize (method)">#initialize</a></span> - <small>Axlsx::CellProtection</small> + <small>Axlsx::GradientStop</small> </li> @@ -1513,238 +1433,230 @@ <li class="r1 "> - <span class='object_link'><a href="Axlsx/Border.html#initialize-instance_method" title="Axlsx::Border#initialize (method)">#initialize</a></span> + <span class='object_link'><a href="Axlsx/Relationship.html#initialize-instance_method" title="Axlsx::Relationship#initialize (method)">#initialize</a></span> - <small>Axlsx::Border</small> + <small>Axlsx::Relationship</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/CellAlignment.html#initialize-instance_method" title="Axlsx::CellAlignment#initialize (method)">#initialize</a></span> + <span class='object_link'><a href="Axlsx/Color.html#initialize-instance_method" title="Axlsx::Color#initialize (method)">#initialize</a></span> - <small>Axlsx::CellAlignment</small> + <small>Axlsx::Color</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/Pic.html#initialize-instance_method" title="Axlsx::Pic#initialize (method)">#initialize</a></span> + <span class='object_link'><a href="Axlsx/BorderPr.html#initialize-instance_method" title="Axlsx::BorderPr#initialize (method)">#initialize</a></span> - <small>Axlsx::Pic</small> + <small>Axlsx::BorderPr</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/PieSeries.html#initialize-instance_method" title="Axlsx::PieSeries#initialize (method)">#initialize</a></span> + <span class='object_link'><a href="Axlsx/Pic.html#initialize-instance_method" title="Axlsx::Pic#initialize (method)">#initialize</a></span> - <small>Axlsx::PieSeries</small> + <small>Axlsx::Pic</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/TableStyle.html#initialize-instance_method" title="Axlsx::TableStyle#initialize (method)">#initialize</a></span> + <span class='object_link'><a href="Axlsx/Marker.html#initialize-instance_method" title="Axlsx::Marker#initialize (method)">#initialize</a></span> - <small>Axlsx::TableStyle</small> + <small>Axlsx::Marker</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/GraphicFrame.html#initialize-instance_method" title="Axlsx::GraphicFrame#initialize (method)">#initialize</a></span> + <span class='object_link'><a href="Axlsx/SerAxis.html#initialize-instance_method" title="Axlsx::SerAxis#initialize (method)">#initialize</a></span> - <small>Axlsx::GraphicFrame</small> + <small>Axlsx::SerAxis</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/Line3DChart.html#initialize-instance_method" title="Axlsx::Line3DChart#initialize (method)">#initialize</a></span> + <span class='object_link'><a href="Axlsx/Styles.html#initialize-instance_method" title="Axlsx::Styles#initialize (method)">#initialize</a></span> - <small>Axlsx::Line3DChart</small> + <small>Axlsx::Styles</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/BorderPr.html#initialize-instance_method" title="Axlsx::BorderPr#initialize (method)">#initialize</a></span> + <span class='object_link'><a href="Axlsx/TableStyles.html#initialize-instance_method" title="Axlsx::TableStyles#initialize (method)">#initialize</a></span> - <small>Axlsx::BorderPr</small> + <small>Axlsx::TableStyles</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/Drawing.html#initialize-instance_method" title="Axlsx::Drawing#initialize (method)">#initialize</a></span> + <span class='object_link'><a href="Axlsx/ValAxis.html#initialize-instance_method" title="Axlsx::ValAxis#initialize (method)">#initialize</a></span> - <small>Axlsx::Drawing</small> + <small>Axlsx::ValAxis</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/Override.html#initialize-instance_method" title="Axlsx::Override#initialize (method)">#initialize</a></span> + <span class='object_link'><a href="Axlsx/Cell.html#initialize-instance_method" title="Axlsx::Cell#initialize (method)">#initialize</a></span> - <small>Axlsx::Override</small> + <small>Axlsx::Cell</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/Styles.html#initialize-instance_method" title="Axlsx::Styles#initialize (method)">#initialize</a></span> + <span class='object_link'><a href="Axlsx/ContentType.html#initialize-instance_method" title="Axlsx::ContentType#initialize (method)">#initialize</a></span> - <small>Axlsx::Styles</small> + <small>Axlsx::ContentType</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/Fill.html#initialize-instance_method" title="Axlsx::Fill#initialize (method)">#initialize</a></span> + <span class='object_link'><a href="Axlsx/GraphicFrame.html#initialize-instance_method" title="Axlsx::GraphicFrame#initialize (method)">#initialize</a></span> - <small>Axlsx::Fill</small> + <small>Axlsx::GraphicFrame</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/OneCellAnchor.html#initialize-instance_method" title="Axlsx::OneCellAnchor#initialize (method)">#initialize</a></span> + <span class='object_link'><a href="Axlsx/Fill.html#initialize-instance_method" title="Axlsx::Fill#initialize (method)">#initialize</a></span> - <small>Axlsx::OneCellAnchor</small> + <small>Axlsx::Fill</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/View3D.html#initialize-instance_method" title="Axlsx::View3D#initialize (method)">#initialize</a></span> + <span class='object_link'><a href="Axlsx/Worksheet.html#initialize-instance_method" title="Axlsx::Worksheet#initialize (method)">#initialize</a></span> - <small>Axlsx::View3D</small> + <small>Axlsx::Worksheet</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/Workbook.html#initialize-instance_method" title="Axlsx::Workbook#initialize (method)">#initialize</a></span> + <span class='object_link'><a href="Axlsx/Border.html#initialize-instance_method" title="Axlsx::Border#initialize (method)">#initialize</a></span> - <small>Axlsx::Workbook</small> + <small>Axlsx::Border</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/CellStyle.html#initialize-instance_method" title="Axlsx::CellStyle#initialize (method)">#initialize</a></span> + <span class='object_link'><a href="Axlsx/TableStyleElement.html#initialize-instance_method" title="Axlsx::TableStyleElement#initialize (method)">#initialize</a></span> - <small>Axlsx::CellStyle</small> + <small>Axlsx::TableStyleElement</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/SerAxis.html#initialize-instance_method" title="Axlsx::SerAxis#initialize (method)">#initialize</a></span> + <span class='object_link'><a href="Axlsx/Package.html#initialize-instance_method" title="Axlsx::Package#initialize (method)">#initialize</a></span> - <small>Axlsx::SerAxis</small> + <small>Axlsx::Package</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/Cell.html#initialize-instance_method" title="Axlsx::Cell#initialize (method)">#initialize</a></span> + <span class='object_link'><a href="Axlsx/PatternFill.html#initialize-instance_method" title="Axlsx::PatternFill#initialize (method)">#initialize</a></span> - <small>Axlsx::Cell</small> + <small>Axlsx::PatternFill</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/Relationship.html#initialize-instance_method" title="Axlsx::Relationship#initialize (method)">#initialize</a></span> + <span class='object_link'><a href="Axlsx/OneCellAnchor.html#initialize-instance_method" title="Axlsx::OneCellAnchor#initialize (method)">#initialize</a></span> - <small>Axlsx::Relationship</small> + <small>Axlsx::OneCellAnchor</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/Package.html#initialize-instance_method" title="Axlsx::Package#initialize (method)">#initialize</a></span> + <span class='object_link'><a href="Axlsx/TwoCellAnchor.html#initialize-instance_method" title="Axlsx::TwoCellAnchor#initialize (method)">#initialize</a></span> - <small>Axlsx::Package</small> + <small>Axlsx::TwoCellAnchor</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/ValAxis.html#initialize-instance_method" title="Axlsx::ValAxis#initialize (method)">#initialize</a></span> + <span class='object_link'><a href="Axlsx/Row.html#initialize-instance_method" title="Axlsx::Row#initialize (method)">#initialize</a></span> - <small>Axlsx::ValAxis</small> + <small>Axlsx::Row</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/PatternFill.html#initialize-instance_method" title="Axlsx::PatternFill#initialize (method)">#initialize</a></span> + <span class='object_link'><a href="Axlsx/Workbook.html#initialize-instance_method" title="Axlsx::Workbook#initialize (method)">#initialize</a></span> - <small>Axlsx::PatternFill</small> + <small>Axlsx::Workbook</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/Series.html#initialize-instance_method" title="Axlsx::Series#initialize (method)">#initialize</a></span> + <span class='object_link'><a href="Axlsx/Chart.html#initialize-instance_method" title="Axlsx::Chart#initialize (method)">#initialize</a></span> - <small>Axlsx::Series</small> + <small>Axlsx::Chart</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/Axis.html#initialize-instance_method" title="Axlsx::Axis#initialize (method)">#initialize</a></span> + <span class='object_link'><a href="Axlsx/CellProtection.html#initialize-instance_method" title="Axlsx::CellProtection#initialize (method)">#initialize</a></span> - <small>Axlsx::Axis</small> + <small>Axlsx::CellProtection</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/TwoCellAnchor.html#initialize-instance_method" title="Axlsx::TwoCellAnchor#initialize (method)">#initialize</a></span> + <span class='object_link'><a href="Axlsx/Line3DChart.html#initialize-instance_method" title="Axlsx::Line3DChart#initialize (method)">#initialize</a></span> - <small>Axlsx::TwoCellAnchor</small> + <small>Axlsx::Line3DChart</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/Relationships.html#initialize-instance_method" title="Axlsx::Relationships#initialize (method)">#initialize</a></span> + <span class='object_link'><a href="Axlsx/Series.html#initialize-instance_method" title="Axlsx::Series#initialize (method)">#initialize</a></span> - <small>Axlsx::Relationships</small> + <small>Axlsx::Series</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/NumFmt.html#initialize-instance_method" title="Axlsx::NumFmt#initialize (method)">#initialize</a></span> + <span class='object_link'><a href="Axlsx/TableStyle.html#initialize-instance_method" title="Axlsx::TableStyle#initialize (method)">#initialize</a></span> - <small>Axlsx::NumFmt</small> + <small>Axlsx::TableStyle</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/Color.html#initialize-instance_method" title="Axlsx::Color#initialize (method)">#initialize</a></span> + <span class='object_link'><a href="Axlsx/CellStyle.html#initialize-instance_method" title="Axlsx::CellStyle#initialize (method)">#initialize</a></span> - <small>Axlsx::Color</small> + <small>Axlsx::CellStyle</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/Scaling.html#initialize-instance_method" title="Axlsx::Scaling#initialize (method)">#initialize</a></span> - - <small>Axlsx::Scaling</small> - - </li> - - - <li class="r2 "> <span class='object_link'><a href="Axlsx/CellAlignment.html#justifyLastLine-instance_method" title="Axlsx::CellAlignment#justifyLastLine (method)">#justifyLastLine</a></span> <small>Axlsx::CellAlignment</small> @@ -1752,15 +1664,15 @@ </li> - <li class="r1 "> - <span class='object_link'><a href="Axlsx/PieSeries.html#labels-instance_method" title="Axlsx::PieSeries#labels (method)">#labels</a></span> + <li class="r2 "> + <span class='object_link'><a href="Axlsx/BarSeries.html#labels-instance_method" title="Axlsx::BarSeries#labels (method)">#labels</a></span> - <small>Axlsx::PieSeries</small> + <small>Axlsx::BarSeries</small> </li> - <li class="r2 "> + <li class="r1 "> <span class='object_link'><a href="Axlsx/LineSeries.html#labels-instance_method" title="Axlsx::LineSeries#labels (method)">#labels</a></span> <small>Axlsx::LineSeries</small> @@ -1768,15 +1680,15 @@ </li> - <li class="r1 "> - <span class='object_link'><a href="Axlsx/BarSeries.html#labels-instance_method" title="Axlsx::BarSeries#labels (method)">#labels</a></span> + <li class="r2 "> + <span class='object_link'><a href="Axlsx/PieSeries.html#labels-instance_method" title="Axlsx::PieSeries#labels (method)">#labels</a></span> - <small>Axlsx::BarSeries</small> + <small>Axlsx::PieSeries</small> </li> - <li class="r2 "> + <li class="r1 "> <span class='object_link'><a href="Axlsx/CatAxis.html#lblAlgn-instance_method" title="Axlsx::CatAxis#lblAlgn (method)">#lblAlgn</a></span> <small>Axlsx::CatAxis</small> @@ -1784,7 +1696,7 @@ </li> - <li class="r1 "> + <li class="r2 "> <span class='object_link'><a href="Axlsx/CatAxis.html#lblOffset-instance_method" title="Axlsx::CatAxis#lblOffset (method)">#lblOffset</a></span> <small>Axlsx::CatAxis</small> @@ -1792,7 +1704,7 @@ </li> - <li class="r2 "> + <li class="r1 "> <span class='object_link'><a href="Axlsx/GradientFill.html#left-instance_method" title="Axlsx::GradientFill#left (method)">#left</a></span> <small>Axlsx::GradientFill</small> @@ -1800,14 +1712,6 @@ </li> - <li class="r1 "> - <span class='object_link'><a href="Axlsx/SimpleTypedList.html#lock-instance_method" title="Axlsx::SimpleTypedList#lock (method)">#lock</a></span> - - <small>Axlsx::SimpleTypedList</small> - - </li> - - <li class="r2 "> <span class='object_link'><a href="Axlsx/CellProtection.html#locked-instance_method" title="Axlsx::CellProtection#locked (method)">#locked</a></span> @@ -1817,15 +1721,15 @@ <li class="r1 "> - <span class='object_link'><a href="Axlsx/SimpleTypedList.html#locked_at-instance_method" title="Axlsx::SimpleTypedList#locked_at (method)">#locked_at</a></span> + <span class='object_link'><a href="Axlsx/Scaling.html#logBase-instance_method" title="Axlsx::Scaling#logBase (method)">#logBase</a></span> - <small>Axlsx::SimpleTypedList</small> + <small>Axlsx::Scaling</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/Scaling.html#logBase-instance_method" title="Axlsx::Scaling#logBase (method)">#logBase</a></span> + <span class='object_link'><a href="Axlsx/Scaling.html#max-instance_method" title="Axlsx::Scaling#max (method)">#max</a></span> <small>Axlsx::Scaling</small> @@ -1833,7 +1737,7 @@ <li class="r1 "> - <span class='object_link'><a href="Axlsx/Scaling.html#max-instance_method" title="Axlsx::Scaling#max (method)">#max</a></span> + <span class='object_link'><a href="Axlsx/Scaling.html#min-instance_method" title="Axlsx::Scaling#min (method)">#min</a></span> <small>Axlsx::Scaling</small> @@ -1841,25 +1745,25 @@ <li class="r2 "> - <span class='object_link'><a href="Axlsx/SimpleTypedList.html#method_missing-instance_method" title="Axlsx::SimpleTypedList#method_missing (method)">#method_missing</a></span> + <span class='object_link'><a href="Axlsx/Worksheet.html#name-instance_method" title="Axlsx::Worksheet#name (method)">#name</a></span> - <small>Axlsx::SimpleTypedList</small> + <small>Axlsx::Worksheet</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/Scaling.html#min-instance_method" title="Axlsx::Scaling#min (method)">#min</a></span> + <span class='object_link'><a href="Axlsx/Pic.html#name-instance_method" title="Axlsx::Pic#name (method)">#name</a></span> - <small>Axlsx::Scaling</small> + <small>Axlsx::Pic</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/Worksheet.html#name-instance_method" title="Axlsx::Worksheet#name (method)">#name</a></span> + <span class='object_link'><a href="Axlsx/Font.html#name-instance_method" title="Axlsx::Font#name (method)">#name</a></span> - <small>Axlsx::Worksheet</small> + <small>Axlsx::Font</small> </li> @@ -1889,22 +1793,6 @@ <li class="r2 "> - <span class='object_link'><a href="Axlsx/Pic.html#name-instance_method" title="Axlsx::Pic#name (method)">#name</a></span> - - <small>Axlsx::Pic</small> - - </li> - - - <li class="r1 "> - <span class='object_link'><a href="Axlsx/Font.html#name-instance_method" title="Axlsx::Font#name (method)">#name</a></span> - - <small>Axlsx::Font</small> - - </li> - - - <li class="r2 "> <span class='object_link'><a href="Axlsx/NumFmt.html#numFmtId-instance_method" title="Axlsx::NumFmt#numFmtId (method)">#numFmtId</a></span> <small>Axlsx::NumFmt</small> @@ -1953,33 +1841,33 @@ <li class="r2 "> - <span class='object_link'><a href="Axlsx/Scaling.html#orientation-instance_method" title="Axlsx::Scaling#orientation (method)">#orientation</a></span> + <span class='object_link'><a href="Axlsx/Series.html#order%3D-instance_method" title="Axlsx::Series#order= (method)">#order=</a></span> - <small>Axlsx::Scaling</small> + <small>Axlsx::Series</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/Font.html#outline-instance_method" title="Axlsx::Font#outline (method)">#outline</a></span> + <span class='object_link'><a href="Axlsx/Scaling.html#orientation-instance_method" title="Axlsx::Scaling#orientation (method)">#orientation</a></span> - <small>Axlsx::Font</small> + <small>Axlsx::Scaling</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/Border.html#outline-instance_method" title="Axlsx::Border#outline (method)">#outline</a></span> + <span class='object_link'><a href="Axlsx/Font.html#outline-instance_method" title="Axlsx::Font#outline (method)">#outline</a></span> - <small>Axlsx::Border</small> + <small>Axlsx::Font</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/Package.html#parts-instance_method" title="Axlsx::Package#parts (method)">#parts</a></span> + <span class='object_link'><a href="Axlsx/Border.html#outline-instance_method" title="Axlsx::Border#outline (method)">#outline</a></span> - <small>Axlsx::Package</small> + <small>Axlsx::Border</small> </li> @@ -2017,25 +1905,25 @@ <li class="r2 "> - <span class='object_link'><a href="Axlsx/Drawing.html#pn-instance_method" title="Axlsx::Drawing#pn (method)">#pn</a></span> + <span class='object_link'><a href="Axlsx/Pic.html#pn-instance_method" title="Axlsx::Pic#pn (method)">#pn</a></span> - <small>Axlsx::Drawing</small> + <small>Axlsx::Pic</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/Pic.html#pn-instance_method" title="Axlsx::Pic#pn (method)">#pn</a></span> + <span class='object_link'><a href="Axlsx/Chart.html#pn-instance_method" title="Axlsx::Chart#pn (method)">#pn</a></span> - <small>Axlsx::Pic</small> + <small>Axlsx::Chart</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/Chart.html#pn-instance_method" title="Axlsx::Chart#pn (method)">#pn</a></span> + <span class='object_link'><a href="Axlsx/Drawing.html#pn-instance_method" title="Axlsx::Drawing#pn (method)">#pn</a></span> - <small>Axlsx::Chart</small> + <small>Axlsx::Drawing</small> </li> @@ -2057,14 +1945,6 @@ <li class="r1 "> - <span class='object_link'><a href="Axlsx/SimpleTypedList.html#protected%3F-instance_method" title="Axlsx::SimpleTypedList#protected? (method)">#protected?</a></span> - - <small>Axlsx::SimpleTypedList</small> - - </li> - - - <li class="r2 "> <span class='object_link'><a href="Axlsx/Xf.html#protection-instance_method" title="Axlsx::Xf#protection (method)">#protection</a></span> <small>Axlsx::Xf</small> @@ -2072,7 +1952,7 @@ </li> - <li class="r1 "> + <li class="r2 "> <span class='object_link'><a href="Axlsx/Border.html#prs-instance_method" title="Axlsx::Border#prs (method)">#prs</a></span> <small>Axlsx::Border</small> @@ -2080,14 +1960,6 @@ </li> - <li class="r2 "> - <span class='object_link'><a href="Axlsx/SimpleTypedList.html#push-instance_method" title="Axlsx::SimpleTypedList#push (method)">#push</a></span> - - <small>Axlsx::SimpleTypedList</small> - - </li> - - <li class="r1 "> <span class='object_link'><a href="Axlsx/Xf.html#quotePrefix-instance_method" title="Axlsx::Xf#quotePrefix (method)">#quotePrefix</a></span> @@ -2113,9 +1985,9 @@ <li class="r2 "> - <span class='object_link'><a href="Axlsx/Drawing.html#rId-instance_method" title="Axlsx::Drawing#rId (method)">#rId</a></span> + <span class='object_link'><a href="Axlsx/Worksheet.html#rId-instance_method" title="Axlsx::Worksheet#rId (method)">#rId</a></span> - <small>Axlsx::Drawing</small> + <small>Axlsx::Worksheet</small> </li> @@ -2129,9 +2001,9 @@ <li class="r2 "> - <span class='object_link'><a href="Axlsx/Worksheet.html#rId-instance_method" title="Axlsx::Worksheet#rId (method)">#rId</a></span> + <span class='object_link'><a href="Axlsx/Drawing.html#rId-instance_method" title="Axlsx::Drawing#rId (method)">#rId</a></span> - <small>Axlsx::Worksheet</small> + <small>Axlsx::Drawing</small> </li> @@ -2145,14 +2017,6 @@ <li class="r2 "> - <span class='object_link'><a href="Axlsx/Title.html#range-instance_method" title="Axlsx::Title#range (method)">#range</a></span> - - <small>Axlsx::Title</small> - - </li> - - - <li class="r1 "> <span class='object_link'><a href="Axlsx/CellAlignment.html#readingOrder-instance_method" title="Axlsx::CellAlignment#readingOrder (method)">#readingOrder</a></span> <small>Axlsx::CellAlignment</small> @@ -2160,7 +2024,7 @@ </li> - <li class="r2 "> + <li class="r1 "> <span class='object_link'><a href="Axlsx/Worksheet.html#relationships-instance_method" title="Axlsx::Worksheet#relationships (method)">#relationships</a></span> <small>Axlsx::Worksheet</small> @@ -2168,14 +2032,6 @@ </li> - <li class="r1 "> - <span class='object_link'><a href="Axlsx/Package.html#relationships-instance_method" title="Axlsx::Package#relationships (method)">#relationships</a></span> - - <small>Axlsx::Package</small> - - </li> - - <li class="r2 "> <span class='object_link'><a href="Axlsx/Workbook.html#relationships-instance_method" title="Axlsx::Workbook#relationships (method)">#relationships</a></span> @@ -2249,17 +2105,17 @@ <li class="r1 "> - <span class='object_link'><a href="Axlsx/Cell.html#row-instance_method" title="Axlsx::Cell#row (method)">#row</a></span> + <span class='object_link'><a href="Axlsx/Marker.html#row-instance_method" title="Axlsx::Marker#row (method)">#row</a></span> - <small>Axlsx::Cell</small> + <small>Axlsx::Marker</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/Marker.html#row-instance_method" title="Axlsx::Marker#row (method)">#row</a></span> + <span class='object_link'><a href="Axlsx/Cell.html#row-instance_method" title="Axlsx::Cell#row (method)">#row</a></span> - <small>Axlsx::Marker</small> + <small>Axlsx::Cell</small> </li> @@ -2305,15 +2161,15 @@ <li class="r2 "> - <span class='object_link'><a href="Axlsx/SimpleTypedList.html#serialize_as-instance_method" title="Axlsx::SimpleTypedList#serialize_as (method)">#serialize_as</a></span> + <span class='object_link'><a href="Axlsx/Chart.html#series-instance_method" title="Axlsx::Chart#series (method)">#series</a></span> - <small>Axlsx::SimpleTypedList</small> + <small>Axlsx::Chart</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/Chart.html#series-instance_method" title="Axlsx::Chart#series (method)">#series</a></span> + <span class='object_link'><a href="Axlsx/Chart.html#series_type-instance_method" title="Axlsx::Chart#series_type (method)">#series_type</a></span> <small>Axlsx::Chart</small> @@ -2321,17 +2177,17 @@ <li class="r2 "> - <span class='object_link'><a href="Axlsx/Chart.html#series_type-instance_method" title="Axlsx::Chart#series_type (method)">#series_type</a></span> + <span class='object_link'><a href="Axlsx/Font.html#shadow-instance_method" title="Axlsx::Font#shadow (method)">#shadow</a></span> - <small>Axlsx::Chart</small> + <small>Axlsx::Font</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/Font.html#shadow-instance_method" title="Axlsx::Font#shadow (method)">#shadow</a></span> + <span class='object_link'><a href="Axlsx/BarSeries.html#shape-instance_method" title="Axlsx::BarSeries#shape (method)">#shape</a></span> - <small>Axlsx::Font</small> + <small>Axlsx::BarSeries</small> </li> @@ -2345,14 +2201,6 @@ <li class="r1 "> - <span class='object_link'><a href="Axlsx/BarSeries.html#shape-instance_method" title="Axlsx::BarSeries#shape (method)">#shape</a></span> - - <small>Axlsx::BarSeries</small> - - </li> - - - <li class="r2 "> <span class='object_link'><a href="Axlsx/Chart.html#show_legend-instance_method" title="Axlsx::Chart#show_legend (method)">#show_legend</a></span> <small>Axlsx::Chart</small> @@ -2360,7 +2208,7 @@ </li> - <li class="r1 "> + <li class="r2 "> <span class='object_link'><a href="Axlsx/CellAlignment.html#shrinkToFit-instance_method" title="Axlsx::CellAlignment#shrinkToFit (method)">#shrinkToFit</a></span> <small>Axlsx::CellAlignment</small> @@ -2368,7 +2216,7 @@ </li> - <li class="r2 "> + <li class="r1 "> <span class='object_link'><a href="Axlsx/TableStyleElement.html#size-instance_method" title="Axlsx::TableStyleElement#size (method)">#size</a></span> <small>Axlsx::TableStyleElement</small> @@ -2376,7 +2224,7 @@ </li> - <li class="r1 "> + <li class="r2 "> <span class='object_link'><a href="Axlsx/Chart.html#start_at-instance_method" title="Axlsx::Chart#start_at (method)">#start_at</a></span> <small>Axlsx::Chart</small> @@ -2384,7 +2232,7 @@ </li> - <li class="r2 "> + <li class="r1 "> <span class='object_link'><a href="Axlsx/Pic.html#start_at-instance_method" title="Axlsx::Pic#start_at (method)">#start_at</a></span> <small>Axlsx::Pic</small> @@ -2392,7 +2240,7 @@ </li> - <li class="r1 "> + <li class="r2 "> <span class='object_link'><a href="Axlsx/GradientFill.html#stop-instance_method" title="Axlsx::GradientFill#stop (method)">#stop</a></span> <small>Axlsx::GradientFill</small> @@ -2400,7 +2248,7 @@ </li> - <li class="r2 "> + <li class="r1 "> <span class='object_link'><a href="Axlsx/Font.html#strike-instance_method" title="Axlsx::Font#strike (method)">#strike</a></span> <small>Axlsx::Font</small> @@ -2408,7 +2256,7 @@ </li> - <li class="r1 "> + <li class="r2 "> <span class='object_link'><a href="Axlsx/Chart.html#style-instance_method" title="Axlsx::Chart#style (method)">#style</a></span> <small>Axlsx::Chart</small> @@ -2416,7 +2264,7 @@ </li> - <li class="r2 "> + <li class="r1 "> <span class='object_link'><a href="Axlsx/BorderPr.html#style-instance_method" title="Axlsx::BorderPr#style (method)">#style</a></span> <small>Axlsx::BorderPr</small> @@ -2424,7 +2272,7 @@ </li> - <li class="r1 "> + <li class="r2 "> <span class='object_link'><a href="Axlsx/Cell.html#style-instance_method" title="Axlsx::Cell#style (method)">#style</a></span> <small>Axlsx::Cell</small> @@ -2432,7 +2280,7 @@ </li> - <li class="r2 "> + <li class="r1 "> <span class='object_link'><a href="Axlsx/Workbook.html#styles-instance_method" title="Axlsx::Workbook#styles (method)">#styles</a></span> <small>Axlsx::Workbook</small> @@ -2440,7 +2288,7 @@ </li> - <li class="r1 "> + <li class="r2 "> <span class='object_link'><a href="Axlsx/Font.html#sz-instance_method" title="Axlsx::Font#sz (method)">#sz</a></span> <small>Axlsx::Font</small> @@ -2448,7 +2296,7 @@ </li> - <li class="r2 "> + <li class="r1 "> <span class='object_link'><a href="Axlsx/TableStyle.html#table-instance_method" title="Axlsx::TableStyle#table (method)">#table</a></span> <small>Axlsx::TableStyle</small> @@ -2456,7 +2304,7 @@ </li> - <li class="r1 "> + <li class="r2 "> <span class='object_link'><a href="Axlsx/Styles.html#tableStyles-instance_method" title="Axlsx::Styles#tableStyles (method)">#tableStyles</a></span> <small>Axlsx::Styles</small> @@ -2464,7 +2312,7 @@ </li> - <li class="r2 "> + <li class="r1 "> <span class='object_link'><a href="Axlsx/Title.html#text-instance_method" title="Axlsx::Title#text (method)">#text</a></span> <small>Axlsx::Title</small> @@ -2472,7 +2320,7 @@ </li> - <li class="r1 "> + <li class="r2 "> <span class='object_link'><a href="Axlsx/CellAlignment.html#textRotation-instance_method" title="Axlsx::CellAlignment#textRotation (method)">#textRotation</a></span> <small>Axlsx::CellAlignment</small> @@ -2480,7 +2328,7 @@ </li> - <li class="r2 "> + <li class="r1 "> <span class='object_link'><a href="Axlsx/Axis.html#tickLblPos-instance_method" title="Axlsx::Axis#tickLblPos (method)">#tickLblPos</a></span> <small>Axlsx::Axis</small> @@ -2488,7 +2336,7 @@ </li> - <li class="r1 "> + <li class="r2 "> <span class='object_link'><a href="Axlsx/SerAxis.html#tickLblSkip-instance_method" title="Axlsx::SerAxis#tickLblSkip (method)">#tickLblSkip</a></span> <small>Axlsx::SerAxis</small> @@ -2496,7 +2344,7 @@ </li> - <li class="r2 "> + <li class="r1 "> <span class='object_link'><a href="Axlsx/SerAxis.html#tickMarkSkip-instance_method" title="Axlsx::SerAxis#tickMarkSkip (method)">#tickMarkSkip</a></span> <small>Axlsx::SerAxis</small> @@ -2504,7 +2352,7 @@ </li> - <li class="r1 "> + <li class="r2 "> <span class='object_link'><a href="Axlsx/Color.html#tint-instance_method" title="Axlsx::Color#tint (method)">#tint</a></span> <small>Axlsx::Color</small> @@ -2512,7 +2360,7 @@ </li> - <li class="r2 "> + <li class="r1 "> <span class='object_link'><a href="Axlsx/Chart.html#title-instance_method" title="Axlsx::Chart#title (method)">#title</a></span> <small>Axlsx::Chart</small> @@ -2520,7 +2368,7 @@ </li> - <li class="r1 "> + <li class="r2 "> <span class='object_link'><a href="Axlsx/Series.html#title-instance_method" title="Axlsx::Series#title (method)">#title</a></span> <small>Axlsx::Series</small> @@ -2528,14 +2376,6 @@ </li> - <li class="r2 "> - <span class='object_link'><a href="Axlsx/TwoCellAnchor.html#to-instance_method" title="Axlsx::TwoCellAnchor#to (method)">#to</a></span> - - <small>Axlsx::TwoCellAnchor</small> - - </li> - - <li class="r1 "> <span class='object_link'><a href="Axlsx/Chart.html#to-instance_method" title="Axlsx::Chart#to (method)">#to</a></span> @@ -2545,81 +2385,81 @@ <li class="r2 "> - <span class='object_link'><a href="Axlsx/GradientStop.html#to_xml-instance_method" title="Axlsx::GradientStop#to_xml (method)">#to_xml</a></span> + <span class='object_link'><a href="Axlsx/TwoCellAnchor.html#to-instance_method" title="Axlsx::TwoCellAnchor#to (method)">#to</a></span> - <small>Axlsx::GradientStop</small> + <small>Axlsx::TwoCellAnchor</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/TableStyles.html#to_xml-instance_method" title="Axlsx::TableStyles#to_xml (method)">#to_xml</a></span> + <span class='object_link'><a href="Axlsx/Workbook.html#to_xml-instance_method" title="Axlsx::Workbook#to_xml (method)">#to_xml</a></span> - <small>Axlsx::TableStyles</small> + <small>Axlsx::Workbook</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/Cell.html#to_xml-instance_method" title="Axlsx::Cell#to_xml (method)">#to_xml</a></span> + <span class='object_link'><a href="Axlsx/TableStyleElement.html#to_xml-instance_method" title="Axlsx::TableStyleElement#to_xml (method)">#to_xml</a></span> - <small>Axlsx::Cell</small> + <small>Axlsx::TableStyleElement</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/OneCellAnchor.html#to_xml-instance_method" title="Axlsx::OneCellAnchor#to_xml (method)">#to_xml</a></span> + <span class='object_link'><a href="Axlsx/Marker.html#to_xml-instance_method" title="Axlsx::Marker#to_xml (method)">#to_xml</a></span> - <small>Axlsx::OneCellAnchor</small> + <small>Axlsx::Marker</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/Marker.html#to_xml-instance_method" title="Axlsx::Marker#to_xml (method)">#to_xml</a></span> + <span class='object_link'><a href="Axlsx/TableStyle.html#to_xml-instance_method" title="Axlsx::TableStyle#to_xml (method)">#to_xml</a></span> - <small>Axlsx::Marker</small> + <small>Axlsx::TableStyle</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/Row.html#to_xml-instance_method" title="Axlsx::Row#to_xml (method)">#to_xml</a></span> + <span class='object_link'><a href="Axlsx/CellStyle.html#to_xml-instance_method" title="Axlsx::CellStyle#to_xml (method)">#to_xml</a></span> - <small>Axlsx::Row</small> + <small>Axlsx::CellStyle</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/ContentType.html#to_xml-instance_method" title="Axlsx::ContentType#to_xml (method)">#to_xml</a></span> + <span class='object_link'><a href="Axlsx/Font.html#to_xml-instance_method" title="Axlsx::Font#to_xml (method)">#to_xml</a></span> - <small>Axlsx::ContentType</small> + <small>Axlsx::Font</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/Title.html#to_xml-instance_method" title="Axlsx::Title#to_xml (method)">#to_xml</a></span> + <span class='object_link'><a href="Axlsx/Border.html#to_xml-instance_method" title="Axlsx::Border#to_xml (method)">#to_xml</a></span> - <small>Axlsx::Title</small> + <small>Axlsx::Border</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/CatAxisData.html#to_xml-instance_method" title="Axlsx::CatAxisData#to_xml (method)">#to_xml</a></span> + <span class='object_link'><a href="Axlsx/Worksheet.html#to_xml-instance_method" title="Axlsx::Worksheet#to_xml (method)">#to_xml</a></span> - <small>Axlsx::CatAxisData</small> + <small>Axlsx::Worksheet</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/Pie3DChart.html#to_xml-instance_method" title="Axlsx::Pie3DChart#to_xml (method)">#to_xml</a></span> + <span class='object_link'><a href="Axlsx/CatAxisData.html#to_xml-instance_method" title="Axlsx::CatAxisData#to_xml (method)">#to_xml</a></span> - <small>Axlsx::Pie3DChart</small> + <small>Axlsx::CatAxisData</small> </li> @@ -2633,305 +2473,305 @@ <li class="r1 "> - <span class='object_link'><a href="Axlsx/Default.html#to_xml-instance_method" title="Axlsx::Default#to_xml (method)">#to_xml</a></span> + <span class='object_link'><a href="Axlsx/View3D.html#to_xml-instance_method" title="Axlsx::View3D#to_xml (method)">#to_xml</a></span> - <small>Axlsx::Default</small> + <small>Axlsx::View3D</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/Border.html#to_xml-instance_method" title="Axlsx::Border#to_xml (method)">#to_xml</a></span> + <span class='object_link'><a href="Axlsx/OneCellAnchor.html#to_xml-instance_method" title="Axlsx::OneCellAnchor#to_xml (method)">#to_xml</a></span> - <small>Axlsx::Border</small> + <small>Axlsx::OneCellAnchor</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/Font.html#to_xml-instance_method" title="Axlsx::Font#to_xml (method)">#to_xml</a></span> + <span class='object_link'><a href="Axlsx/Core.html#to_xml-instance_method" title="Axlsx::Core#to_xml (method)">#to_xml</a></span> - <small>Axlsx::Font</small> + <small>Axlsx::Core</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/Styles.html#to_xml-instance_method" title="Axlsx::Styles#to_xml (method)">#to_xml</a></span> + <span class='object_link'><a href="Axlsx/Xf.html#to_xml-instance_method" title="Axlsx::Xf#to_xml (method)">#to_xml</a></span> - <small>Axlsx::Styles</small> + <small>Axlsx::Xf</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/GraphicFrame.html#to_xml-instance_method" title="Axlsx::GraphicFrame#to_xml (method)">#to_xml</a></span> + <span class='object_link'><a href="Axlsx/ValAxis.html#to_xml-instance_method" title="Axlsx::ValAxis#to_xml (method)">#to_xml</a></span> - <small>Axlsx::GraphicFrame</small> + <small>Axlsx::ValAxis</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/View3D.html#to_xml-instance_method" title="Axlsx::View3D#to_xml (method)">#to_xml</a></span> + <span class='object_link'><a href="Axlsx/TableStyles.html#to_xml-instance_method" title="Axlsx::TableStyles#to_xml (method)">#to_xml</a></span> - <small>Axlsx::View3D</small> + <small>Axlsx::TableStyles</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/TableStyle.html#to_xml-instance_method" title="Axlsx::TableStyle#to_xml (method)">#to_xml</a></span> + <span class='object_link'><a href="Axlsx/Line3DChart.html#to_xml-instance_method" title="Axlsx::Line3DChart#to_xml (method)">#to_xml</a></span> - <small>Axlsx::TableStyle</small> + <small>Axlsx::Line3DChart</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/CellAlignment.html#to_xml-instance_method" title="Axlsx::CellAlignment#to_xml (method)">#to_xml</a></span> + <span class='object_link'><a href="Axlsx/SerAxis.html#to_xml-instance_method" title="Axlsx::SerAxis#to_xml (method)">#to_xml</a></span> - <small>Axlsx::CellAlignment</small> + <small>Axlsx::SerAxis</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/Scaling.html#to_xml-instance_method" title="Axlsx::Scaling#to_xml (method)">#to_xml</a></span> + <span class='object_link'><a href="Axlsx/Styles.html#to_xml-instance_method" title="Axlsx::Styles#to_xml (method)">#to_xml</a></span> - <small>Axlsx::Scaling</small> + <small>Axlsx::Styles</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/PieSeries.html#to_xml-instance_method" title="Axlsx::PieSeries#to_xml (method)">#to_xml</a></span> + <span class='object_link'><a href="Axlsx/Color.html#to_xml-instance_method" title="Axlsx::Color#to_xml (method)">#to_xml</a></span> - <small>Axlsx::PieSeries</small> + <small>Axlsx::Color</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/ValAxisData.html#to_xml-instance_method" title="Axlsx::ValAxisData#to_xml (method)">#to_xml</a></span> + <span class='object_link'><a href="Axlsx/Drawing.html#to_xml-instance_method" title="Axlsx::Drawing#to_xml (method)">#to_xml</a></span> - <small>Axlsx::ValAxisData</small> + <small>Axlsx::Drawing</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/SerAxis.html#to_xml-instance_method" title="Axlsx::SerAxis#to_xml (method)">#to_xml</a></span> + <span class='object_link'><a href="Axlsx/Relationship.html#to_xml-instance_method" title="Axlsx::Relationship#to_xml (method)">#to_xml</a></span> - <small>Axlsx::SerAxis</small> + <small>Axlsx::Relationship</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/Line3DChart.html#to_xml-instance_method" title="Axlsx::Line3DChart#to_xml (method)">#to_xml</a></span> + <span class='object_link'><a href="Axlsx/GraphicFrame.html#to_xml-instance_method" title="Axlsx::GraphicFrame#to_xml (method)">#to_xml</a></span> - <small>Axlsx::Line3DChart</small> + <small>Axlsx::GraphicFrame</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/ValAxis.html#to_xml-instance_method" title="Axlsx::ValAxis#to_xml (method)">#to_xml</a></span> + <span class='object_link'><a href="Axlsx/Fill.html#to_xml-instance_method" title="Axlsx::Fill#to_xml (method)">#to_xml</a></span> - <small>Axlsx::ValAxis</small> + <small>Axlsx::Fill</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/PatternFill.html#to_xml-instance_method" title="Axlsx::PatternFill#to_xml (method)">#to_xml</a></span> + <span class='object_link'><a href="Axlsx/Cell.html#to_xml-instance_method" title="Axlsx::Cell#to_xml (method)">#to_xml</a></span> - <small>Axlsx::PatternFill</small> + <small>Axlsx::Cell</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/Drawing.html#to_xml-instance_method" title="Axlsx::Drawing#to_xml (method)">#to_xml</a></span> + <span class='object_link'><a href="Axlsx/CatAxis.html#to_xml-instance_method" title="Axlsx::CatAxis#to_xml (method)">#to_xml</a></span> - <small>Axlsx::Drawing</small> + <small>Axlsx::CatAxis</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/Series.html#to_xml-instance_method" title="Axlsx::Series#to_xml (method)">#to_xml</a></span> + <span class='object_link'><a href="Axlsx/NumFmt.html#to_xml-instance_method" title="Axlsx::NumFmt#to_xml (method)">#to_xml</a></span> - <small>Axlsx::Series</small> + <small>Axlsx::NumFmt</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/Relationship.html#to_xml-instance_method" title="Axlsx::Relationship#to_xml (method)">#to_xml</a></span> + <span class='object_link'><a href="Axlsx/ValAxisData.html#to_xml-instance_method" title="Axlsx::ValAxisData#to_xml (method)">#to_xml</a></span> - <small>Axlsx::Relationship</small> + <small>Axlsx::ValAxisData</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/Relationships.html#to_xml-instance_method" title="Axlsx::Relationships#to_xml (method)">#to_xml</a></span> + <span class='object_link'><a href="Axlsx/Pie3DChart.html#to_xml-instance_method" title="Axlsx::Pie3DChart#to_xml (method)">#to_xml</a></span> - <small>Axlsx::Relationships</small> + <small>Axlsx::Pie3DChart</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/CellStyle.html#to_xml-instance_method" title="Axlsx::CellStyle#to_xml (method)">#to_xml</a></span> + <span class='object_link'><a href="Axlsx/BarSeries.html#to_xml-instance_method" title="Axlsx::BarSeries#to_xml (method)">#to_xml</a></span> - <small>Axlsx::CellStyle</small> + <small>Axlsx::BarSeries</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/Xf.html#to_xml-instance_method" title="Axlsx::Xf#to_xml (method)">#to_xml</a></span> + <span class='object_link'><a href="Axlsx/Chart.html#to_xml-instance_method" title="Axlsx::Chart#to_xml (method)">#to_xml</a></span> - <small>Axlsx::Xf</small> + <small>Axlsx::Chart</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/Fill.html#to_xml-instance_method" title="Axlsx::Fill#to_xml (method)">#to_xml</a></span> + <span class='object_link'><a href="Axlsx/SeriesTitle.html#to_xml-instance_method" title="Axlsx::SeriesTitle#to_xml (method)">#to_xml</a></span> - <small>Axlsx::Fill</small> + <small>Axlsx::SeriesTitle</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/Axis.html#to_xml-instance_method" title="Axlsx::Axis#to_xml (method)">#to_xml</a></span> + <span class='object_link'><a href="Axlsx/TwoCellAnchor.html#to_xml-instance_method" title="Axlsx::TwoCellAnchor#to_xml (method)">#to_xml</a></span> - <small>Axlsx::Axis</small> + <small>Axlsx::TwoCellAnchor</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/NumFmt.html#to_xml-instance_method" title="Axlsx::NumFmt#to_xml (method)">#to_xml</a></span> + <span class='object_link'><a href="Axlsx/Default.html#to_xml-instance_method" title="Axlsx::Default#to_xml (method)">#to_xml</a></span> - <small>Axlsx::NumFmt</small> + <small>Axlsx::Default</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/Chart.html#to_xml-instance_method" title="Axlsx::Chart#to_xml (method)">#to_xml</a></span> + <span class='object_link'><a href="Axlsx/Scaling.html#to_xml-instance_method" title="Axlsx::Scaling#to_xml (method)">#to_xml</a></span> - <small>Axlsx::Chart</small> + <small>Axlsx::Scaling</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/CatAxis.html#to_xml-instance_method" title="Axlsx::CatAxis#to_xml (method)">#to_xml</a></span> + <span class='object_link'><a href="Axlsx/CellProtection.html#to_xml-instance_method" title="Axlsx::CellProtection#to_xml (method)">#to_xml</a></span> - <small>Axlsx::CatAxis</small> + <small>Axlsx::CellProtection</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/Worksheet.html#to_xml-instance_method" title="Axlsx::Worksheet#to_xml (method)">#to_xml</a></span> + <span class='object_link'><a href="Axlsx/Pic.html#to_xml-instance_method" title="Axlsx::Pic#to_xml (method)">#to_xml</a></span> - <small>Axlsx::Worksheet</small> + <small>Axlsx::Pic</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/BorderPr.html#to_xml-instance_method" title="Axlsx::BorderPr#to_xml (method)">#to_xml</a></span> + <span class='object_link'><a href="Axlsx/PatternFill.html#to_xml-instance_method" title="Axlsx::PatternFill#to_xml (method)">#to_xml</a></span> - <small>Axlsx::BorderPr</small> + <small>Axlsx::PatternFill</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/SeriesTitle.html#to_xml-instance_method" title="Axlsx::SeriesTitle#to_xml (method)">#to_xml</a></span> + <span class='object_link'><a href="Axlsx/BorderPr.html#to_xml-instance_method" title="Axlsx::BorderPr#to_xml (method)">#to_xml</a></span> - <small>Axlsx::SeriesTitle</small> + <small>Axlsx::BorderPr</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/Color.html#to_xml-instance_method" title="Axlsx::Color#to_xml (method)">#to_xml</a></span> + <span class='object_link'><a href="Axlsx/GradientFill.html#to_xml-instance_method" title="Axlsx::GradientFill#to_xml (method)">#to_xml</a></span> - <small>Axlsx::Color</small> + <small>Axlsx::GradientFill</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/CellProtection.html#to_xml-instance_method" title="Axlsx::CellProtection#to_xml (method)">#to_xml</a></span> + <span class='object_link'><a href="Axlsx/PieSeries.html#to_xml-instance_method" title="Axlsx::PieSeries#to_xml (method)">#to_xml</a></span> - <small>Axlsx::CellProtection</small> + <small>Axlsx::PieSeries</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/SimpleTypedList.html#to_xml-instance_method" title="Axlsx::SimpleTypedList#to_xml (method)">#to_xml</a></span> + <span class='object_link'><a href="Axlsx/GradientStop.html#to_xml-instance_method" title="Axlsx::GradientStop#to_xml (method)">#to_xml</a></span> - <small>Axlsx::SimpleTypedList</small> + <small>Axlsx::GradientStop</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/Core.html#to_xml-instance_method" title="Axlsx::Core#to_xml (method)">#to_xml</a></span> + <span class='object_link'><a href="Axlsx/ContentType.html#to_xml-instance_method" title="Axlsx::ContentType#to_xml (method)">#to_xml</a></span> - <small>Axlsx::Core</small> + <small>Axlsx::ContentType</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/TableStyleElement.html#to_xml-instance_method" title="Axlsx::TableStyleElement#to_xml (method)">#to_xml</a></span> + <span class='object_link'><a href="Axlsx/Row.html#to_xml-instance_method" title="Axlsx::Row#to_xml (method)">#to_xml</a></span> - <small>Axlsx::TableStyleElement</small> + <small>Axlsx::Row</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/LineSeries.html#to_xml-instance_method" title="Axlsx::LineSeries#to_xml (method)">#to_xml</a></span> + <span class='object_link'><a href="Axlsx/Bar3DChart.html#to_xml-instance_method" title="Axlsx::Bar3DChart#to_xml (method)">#to_xml</a></span> - <small>Axlsx::LineSeries</small> + <small>Axlsx::Bar3DChart</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/BarSeries.html#to_xml-instance_method" title="Axlsx::BarSeries#to_xml (method)">#to_xml</a></span> + <span class='object_link'><a href="Axlsx/CellAlignment.html#to_xml-instance_method" title="Axlsx::CellAlignment#to_xml (method)">#to_xml</a></span> - <small>Axlsx::BarSeries</small> + <small>Axlsx::CellAlignment</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/GradientFill.html#to_xml-instance_method" title="Axlsx::GradientFill#to_xml (method)">#to_xml</a></span> + <span class='object_link'><a href="Axlsx/Axis.html#to_xml-instance_method" title="Axlsx::Axis#to_xml (method)">#to_xml</a></span> - <small>Axlsx::GradientFill</small> + <small>Axlsx::Axis</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/Workbook.html#to_xml-instance_method" title="Axlsx::Workbook#to_xml (method)">#to_xml</a></span> + <span class='object_link'><a href="Axlsx/LineSeries.html#to_xml-instance_method" title="Axlsx::LineSeries#to_xml (method)">#to_xml</a></span> - <small>Axlsx::Workbook</small> + <small>Axlsx::LineSeries</small> </li> @@ -2945,31 +2785,31 @@ <li class="r2 "> - <span class='object_link'><a href="Axlsx/TwoCellAnchor.html#to_xml-instance_method" title="Axlsx::TwoCellAnchor#to_xml (method)">#to_xml</a></span> + <span class='object_link'><a href="Axlsx/Title.html#to_xml-instance_method" title="Axlsx::Title#to_xml (method)">#to_xml</a></span> - <small>Axlsx::TwoCellAnchor</small> + <small>Axlsx::Title</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/Bar3DChart.html#to_xml-instance_method" title="Axlsx::Bar3DChart#to_xml (method)">#to_xml</a></span> + <span class='object_link'><a href="Axlsx/Relationships.html#to_xml-instance_method" title="Axlsx::Relationships#to_xml (method)">#to_xml</a></span> - <small>Axlsx::Bar3DChart</small> + <small>Axlsx::Relationships</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/Pic.html#to_xml-instance_method" title="Axlsx::Pic#to_xml (method)">#to_xml</a></span> + <span class='object_link'><a href="Axlsx/GradientFill.html#top-instance_method" title="Axlsx::GradientFill#top (method)">#top</a></span> - <small>Axlsx::Pic</small> + <small>Axlsx::GradientFill</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx/GradientFill.html#top-instance_method" title="Axlsx::GradientFill#top (method)">#top</a></span> + <span class='object_link'><a href="Axlsx/GradientFill.html#type-instance_method" title="Axlsx::GradientFill#type (method)">#type</a></span> <small>Axlsx::GradientFill</small> @@ -2993,30 +2833,6 @@ <li class="r2 "> - <span class='object_link'><a href="Axlsx/GradientFill.html#type-instance_method" title="Axlsx::GradientFill#type (method)">#type</a></span> - - <small>Axlsx::GradientFill</small> - - </li> - - - <li class="r1 "> - <span class='object_link'><a href="Axlsx/SimpleTypedList.html#unlock-instance_method" title="Axlsx::SimpleTypedList#unlock (method)">#unlock</a></span> - - <small>Axlsx::SimpleTypedList</small> - - </li> - - - <li class="r2 "> - <span class='object_link'><a href="Axlsx/Worksheet.html#update_auto_fit_data-instance_method" title="Axlsx::Worksheet#update_auto_fit_data (method)">#update_auto_fit_data</a></span> - - <small>Axlsx::Worksheet</small> - - </li> - - - <li class="r1 "> <span class='object_link'><a href="Axlsx/Line3DChart.html#valAxis-instance_method" title="Axlsx::Line3DChart#valAxis (method)">#valAxis</a></span> <small>Axlsx::Line3DChart</small> @@ -3024,7 +2840,7 @@ </li> - <li class="r2 "> + <li class="r1 "> <span class='object_link'><a href="Axlsx/Bar3DChart.html#valAxis-instance_method" title="Axlsx::Bar3DChart#valAxis (method)">#valAxis</a></span> <small>Axlsx::Bar3DChart</small> @@ -3032,18 +2848,10 @@ </li> - <li class="r1 "> - <span class='object_link'><a href="Axlsx/RestrictionValidator.html#validate-class_method" title="Axlsx::RestrictionValidator.validate (method)">validate</a></span> - - <small>Axlsx::RestrictionValidator</small> - - </li> - - <li class="r2 "> - <span class='object_link'><a href="Axlsx/RegexValidator.html#validate-class_method" title="Axlsx::RegexValidator.validate (method)">validate</a></span> + <span class='object_link'><a href="Axlsx/Package.html#validate-instance_method" title="Axlsx::Package#validate (method)">#validate</a></span> - <small>Axlsx::RegexValidator</small> + <small>Axlsx::Package</small> </li> @@ -3057,23 +2865,23 @@ <li class="r2 "> - <span class='object_link'><a href="Axlsx/Package.html#validate-instance_method" title="Axlsx::Package#validate (method)">#validate</a></span> + <span class='object_link'><a href="Axlsx/RegexValidator.html#validate-class_method" title="Axlsx::RegexValidator.validate (method)">validate</a></span> - <small>Axlsx::Package</small> + <small>Axlsx::RegexValidator</small> </li> <li class="r1 "> - <span class='object_link'><a href="Axlsx.html#validate_boolean-class_method" title="Axlsx.validate_boolean (method)">validate_boolean</a></span> + <span class='object_link'><a href="Axlsx/RestrictionValidator.html#validate-class_method" title="Axlsx::RestrictionValidator.validate (method)">validate</a></span> - <small>Axlsx</small> + <small>Axlsx::RestrictionValidator</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx.html#validate_content_type-class_method" title="Axlsx.validate_content_type (method)">validate_content_type</a></span> + <span class='object_link'><a href="Axlsx.html#validate_boolean-class_method" title="Axlsx.validate_boolean (method)">validate_boolean</a></span> <small>Axlsx</small> @@ -3081,7 +2889,7 @@ <li class="r1 "> - <span class='object_link'><a href="Axlsx.html#validate_float-class_method" title="Axlsx.validate_float (method)">validate_float</a></span> + <span class='object_link'><a href="Axlsx.html#validate_content_type-class_method" title="Axlsx.validate_content_type (method)">validate_content_type</a></span> <small>Axlsx</small> @@ -3089,7 +2897,7 @@ <li class="r2 "> - <span class='object_link'><a href="Axlsx.html#validate_gradient_type-class_method" title="Axlsx.validate_gradient_type (method)">validate_gradient_type</a></span> + <span class='object_link'><a href="Axlsx.html#validate_float-class_method" title="Axlsx.validate_float (method)">validate_float</a></span> <small>Axlsx</small> @@ -3097,7 +2905,7 @@ <li class="r1 "> - <span class='object_link'><a href="Axlsx.html#validate_horizontal_alignment-class_method" title="Axlsx.validate_horizontal_alignment (method)">validate_horizontal_alignment</a></span> + <span class='object_link'><a href="Axlsx.html#validate_gradient_type-class_method" title="Axlsx.validate_gradient_type (method)">validate_gradient_type</a></span> <small>Axlsx</small> @@ -3105,7 +2913,7 @@ <li class="r2 "> - <span class='object_link'><a href="Axlsx.html#validate_int-class_method" title="Axlsx.validate_int (method)">validate_int</a></span> + <span class='object_link'><a href="Axlsx.html#validate_horizontal_alignment-class_method" title="Axlsx.validate_horizontal_alignment (method)">validate_horizontal_alignment</a></span> <small>Axlsx</small> @@ -3113,7 +2921,7 @@ <li class="r1 "> - <span class='object_link'><a href="Axlsx.html#validate_pattern_type-class_method" title="Axlsx.validate_pattern_type (method)">validate_pattern_type</a></span> + <span class='object_link'><a href="Axlsx.html#validate_int-class_method" title="Axlsx.validate_int (method)">validate_int</a></span> <small>Axlsx</small> @@ -3121,7 +2929,7 @@ <li class="r2 "> - <span class='object_link'><a href="Axlsx.html#validate_relationship_type-class_method" title="Axlsx.validate_relationship_type (method)">validate_relationship_type</a></span> + <span class='object_link'><a href="Axlsx.html#validate_pattern_type-class_method" title="Axlsx.validate_pattern_type (method)">validate_pattern_type</a></span> <small>Axlsx</small> @@ -3129,9 +2937,9 @@ <li class="r1 "> - <span class='object_link'><a href="Axlsx/Package.html#validate_single_doc-instance_method" title="Axlsx::Package#validate_single_doc (method)">#validate_single_doc</a></span> + <span class='object_link'><a href="Axlsx.html#validate_relationship_type-class_method" title="Axlsx.validate_relationship_type (method)">validate_relationship_type</a></span> - <small>Axlsx::Package</small> + <small>Axlsx</small> </li> @@ -3193,6 +3001,14 @@ <li class="r1 "> + <span class='object_link'><a href="Axlsx/Pic.html#width-instance_method" title="Axlsx::Pic#width (method)">#width</a></span> + + <small>Axlsx::Pic</small> + + </li> + + + <li class="r2 "> <span class='object_link'><a href="Axlsx/OneCellAnchor.html#width-instance_method" title="Axlsx::OneCellAnchor#width (method)">#width</a></span> <small>Axlsx::OneCellAnchor</small> @@ -3200,15 +3016,15 @@ </li> - <li class="r2 "> - <span class='object_link'><a href="Axlsx/Pic.html#width-instance_method" title="Axlsx::Pic#width (method)">#width</a></span> + <li class="r1 "> + <span class='object_link'><a href="Axlsx/Pic.html#width%3D-instance_method" title="Axlsx::Pic#width= (method)">#width=</a></span> <small>Axlsx::Pic</small> </li> - <li class="r1 "> + <li class="r2 "> <span class='object_link'><a href="Axlsx/Package.html#workbook-instance_method" title="Axlsx::Package#workbook (method)">#workbook</a></span> <small>Axlsx::Package</small> @@ -3216,7 +3032,7 @@ </li> - <li class="r2 "> + <li class="r1 "> <span class='object_link'><a href="Axlsx/Worksheet.html#workbook-instance_method" title="Axlsx::Worksheet#workbook (method)">#workbook</a></span> <small>Axlsx::Worksheet</small> @@ -3224,6 +3040,14 @@ </li> + <li class="r2 "> + <span class='object_link'><a href="Axlsx/Package.html#workbook%3D-instance_method" title="Axlsx::Package#workbook= (method)">#workbook=</a></span> + + <small>Axlsx::Package</small> + + </li> + + <li class="r1 "> <span class='object_link'><a href="Axlsx/Drawing.html#worksheet-instance_method" title="Axlsx::Drawing#worksheet (method)">#worksheet</a></span> @@ -3257,17 +3081,17 @@ <li class="r1 "> - <span class='object_link'><a href="Axlsx/Xf.html#xfId-instance_method" title="Axlsx::Xf#xfId (method)">#xfId</a></span> + <span class='object_link'><a href="Axlsx/CellStyle.html#xfId-instance_method" title="Axlsx::CellStyle#xfId (method)">#xfId</a></span> - <small>Axlsx::Xf</small> + <small>Axlsx::CellStyle</small> </li> <li class="r2 "> - <span class='object_link'><a href="Axlsx/CellStyle.html#xfId-instance_method" title="Axlsx::CellStyle#xfId (method)">#xfId</a></span> + <span class='object_link'><a href="Axlsx/Xf.html#xfId-instance_method" title="Axlsx::Xf#xfId (method)">#xfId</a></span> - <small>Axlsx::CellStyle</small> + <small>Axlsx::Xf</small> </li> diff --git a/doc/top-level-namespace.html b/doc/top-level-namespace.html index a06413fc..548df99e 100644 --- a/doc/top-level-namespace.html +++ b/doc/top-level-namespace.html @@ -6,7 +6,7 @@ <title> Top Level Namespace - — Documentation by YARD 0.7.3 + — AXLSX </title> @@ -94,9 +94,9 @@ </div> <div id="footer"> - Generated on Wed Nov 23 22:21:05 2011 by + Generated on Sat Nov 26 13:16:40 2011 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.7.3 (ruby-1.8.7). + 0.7.3 (ruby-1.9.3). </div> </body> diff --git a/examples/example.rb b/examples/example.rb index 50a3edb4..e8869f75 100644 --- a/examples/example.rb +++ b/examples/example.rb @@ -1,8 +1,11 @@ # -*- coding: utf-8 -*- +# encoding: utf-8 require 'rubygems' require 'axlsx' + #A Simple Workbook + p = Axlsx::Package.new p.workbook.add_worksheet do |sheet| sheet.add_row ["First", "Second", "Third"] @@ -11,6 +14,7 @@ p.serialize("example1.xlsx") #Generating A Bar Chart + p = Axlsx::Package.new p.workbook.add_worksheet do |sheet| sheet.add_row ["First", "Second", "Third"] @@ -22,6 +26,7 @@ p.serialize("example2.xlsx") #Generating A Pie Chart + p = Axlsx::Package.new p.workbook.add_worksheet do |sheet| sheet.add_row ["First", "Second", "Third"] @@ -91,7 +96,8 @@ p = Axlsx::Package.new p.workbook.add_worksheet do |sheet| - sheet.add_image(:image_src => (File.dirname(__FILE__) + "/image1.png")) do |image| + img = File.expand_path('examples/image1.jpeg') + sheet.add_image(:image_src => img) do |image| image.width=720 image.height=666 image.start_at 2, 2 @@ -100,11 +106,13 @@ p.serialize("example7.xlsx") -#Japanese Support +#Asian Language Support p = Axlsx::Package.new p.workbook.add_worksheet do |sheet| - sheet.add_row ["日本語の表意","ちゃんと出来るかな"] - sheet.add_row ["<div>","escaped?"] + sheet.add_row ["日本語"] + sheet.add_row ["华语/華語"] + sheet.add_row ["한국어/조선말"] end p.serialize("example8.xlsx") + diff --git a/lib/axlsx.rb b/lib/axlsx.rb index 3a665740..aee52b36 100644 --- a/lib/axlsx.rb +++ b/lib/axlsx.rb @@ -1,3 +1,7 @@ + +Encoding::default_internal = 'UTF-8' unless RUBY_VERSION < '1.9' +Encoding::default_external = 'UTF-8' unless RUBY_VERSION < '1.9' + require 'axlsx/util/simple_typed_list.rb' require 'axlsx/util/constants.rb' require 'axlsx/util/validators.rb' @@ -13,26 +17,27 @@ require 'axlsx/workbook/workbook.rb' require 'axlsx/package.rb' -module Axlsx - #required gems - require 'Nokogiri' - require 'active_support/core_ext/object/instance_variables' - require 'active_support/inflector' - require 'rmagick' - require 'zip/zip' +#required gems +require 'Nokogiri' +require 'active_support/core_ext/object/instance_variables' +require 'active_support/inflector' +require 'rmagick' +require 'zip/zip' - #core dependencies - require 'bigdecimal' - require 'time' - require 'CGI' +#core dependencies +require 'bigdecimal' +require 'time' +require 'CGI' +# xlsx generation with charts, images, automated column width, customizable styles and full schema validation. Axlsx excels at helping you generate beautiful Office Open XML Spreadsheet documents without having to understand the entire ECMA specification. Check out the README for some examples of how easy it is. Best of all, you can validate your xlsx file before serialization so you know for sure that anything generated is going to load on your client's machine. +module Axlsx # determines the cell range for the items provided def self.cell_range(items) return "" unless items.first.is_a? Cell - "#{items.first.row.worksheet.name}!" + - "#{items.first.r_abs}:#{items.last.r_abs}" + ref = "#{items.first.row.worksheet.name}!" + + "#{items.first.r_abs}" + ref += ":#{items.last.r_abs}" if items.size > 1 + ref end - - end diff --git a/lib/axlsx/content_type/default.rb b/lib/axlsx/content_type/default.rb index c82e5f7d..5c688568 100644 --- a/lib/axlsx/content_type/default.rb +++ b/lib/axlsx/content_type/default.rb @@ -4,10 +4,11 @@ module Axlsx # The extension of the content type. # @return [String] - attr_accessor :Extension + attr_reader :Extension - # @return [String] ContentType The type of content. TABLE_CT, WORKBOOK_CT, APP_CT, RELS_CT, STYLES_CT, XML_CT, WORKSHEET_CT, SHARED_STRINGS_CT, CORE_CT, CHART_CT, DRAWING_CT are allowed - attr_accessor :ContentType + # The type of content. + # @return [String] + attr_reader :ContentType #Creates a new Default object # @option options [String] Extension @@ -19,7 +20,11 @@ module Axlsx self.send("#{o[0]}=", o[1]) if self.respond_to? "#{o[0]}=" end end + # Sets the file extension for this content type. def Extension=(v) Axlsx::validate_string v; @Extension = v end + + # Sets the content type + # @see Axlsx#validate_content_type def ContentType=(v) Axlsx::validate_content_type v; @ContentType = v end # Serializes the object to xml diff --git a/lib/axlsx/content_type/override.rb b/lib/axlsx/content_type/override.rb index 4d1b008f..362e834b 100644 --- a/lib/axlsx/content_type/override.rb +++ b/lib/axlsx/content_type/override.rb @@ -2,11 +2,13 @@ module Axlsx # An override content part. These parts are automatically created by for you based on the content of your package. class Override - # @return [String] ContentType The type of content. TABLE_CT, WORKBOOK_CT, APP_CT, RELS_CT, STYLES_CT, XML_CT, WORKSHEET_CT, SHARED_STRINGS_CT, CORE_CT, CHART_CT, DRAWING_CT are allowed - attr_accessor :ContentType + # The type of content. + # @return [String] + attr_reader :ContentType - # @return [String] PartName The name and location of the part. - attr_accessor :PartName + # The name and location of the part. + # @return [String] + attr_reader :PartName #Creates a new Override object # @option options [String] PartName @@ -18,7 +20,12 @@ module Axlsx self.send("#{o[0]}=", o[1]) if self.respond_to? "#{o[0]}=" end end + + # The name and location of the part. def PartName=(v) Axlsx::validate_string v; @PartName = v end + + # The content type. + # @see Axlsx#validate_content_type def ContentType=(v) Axlsx::validate_content_type v; @ContentType = v end # Serializes the Override object to xml diff --git a/lib/axlsx/doc_props/app.rb b/lib/axlsx/doc_props/app.rb index 77e7ea42..8e6bea27 100644 --- a/lib/axlsx/doc_props/app.rb +++ b/lib/axlsx/doc_props/app.rb @@ -11,73 +11,73 @@ module Axlsx class App # @return [String] The name of the document template. - attr_accessor :Template + attr_reader :Template # @return [String] The name of the manager for the document. - attr_accessor :Manager + attr_reader :Manager # @return [String] The name of the company generating the document. - attr_accessor :Company + attr_reader :Company # @return [Integer] The number of pages in the document. - attr_accessor :Pages + attr_reader :Pages # @return [Integer] The number of words in the document. - attr_accessor :Words + attr_reader :Words # @return [Integer] The number of characters in the document. - attr_accessor :Characters + attr_reader :Characters # @return [String] The intended format of the presentation. - attr_accessor :PresentationFormat + attr_reader :PresentationFormat # @return [Integer] The number of lines in the document. - attr_accessor :Lines + attr_reader :Lines # @return [Integer] The number of paragraphs in the document - attr_accessor :Paragraphs + attr_reader :Paragraphs # @return [Intger] The number of slides in the document. - attr_accessor :Slides + attr_reader :Slides # @return [Integer] The number of slides that have notes. - attr_accessor :Notes + attr_reader :Notes # @return [Integer] The total amount of time spent editing. - attr_accessor :TotalTime + attr_reader :TotalTime # @return [Integer] The number of hidden slides. - attr_accessor :HiddenSlides + attr_reader :HiddenSlides # @return [Integer] The total number multimedia clips - attr_accessor :MMClips + attr_reader :MMClips # @return [Boolean] The display mode for the document thumbnail. - attr_accessor :ScaleCrop + attr_reader :ScaleCrop # @return [Boolean] The links in the document are up to date. - attr_accessor :LinksUpToDate + attr_reader :LinksUpToDate # @return [Integer] The number of characters in the document including spaces. - attr_accessor :CharactersWithSpaces + attr_reader :CharactersWithSpaces # @return [Boolean] Indicates if the document is shared. - attr_accessor :ShareDoc + attr_reader :ShareDoc # @return [String] The base for hyper links in the document. - attr_accessor :HyperLinkBase + attr_reader :HyperLinkBase # @return [Boolean] Indicates that the hyper links in the document have been changed. - attr_accessor :HyperlinksChanged + attr_reader :HyperlinksChanged # @return [String] The name of the application - attr_accessor :Application + attr_reader :Application # @return [String] The version of the application. - attr_accessor :AppVersion + attr_reader :AppVersion # @return [Integer] Document security - attr_accessor :DocSecurity + attr_reader :DocSecurity # Creates an App object # @option options [String] Template @@ -108,28 +108,58 @@ module Axlsx end end + # Sets the Template property of your app.xml file def Template=(v) Axlsx::validate_string v; @Template = v; end + + # Sets the Manager property of your app.xml file def Manager=(v) Axlsx::validate_string v; @Manager = v; end + + # Sets the Company property of your app.xml file def Company=(v) Axlsx::validate_string v; @Company = v; end + + # Sets the Pages property of your app.xml file def Pages=(v) Axlsx::validate_int v; @Pages = v; end + + # Sets the Words property of your app.xml file def Words=(v) Axlsx::validate_int v; @Words = v; end + + # Sets the Characters property of your app.xml file def Characters=(v) Axlsx::validate_int v; @Characters = v; end + + + # Sets the PresentationFormat property of your app.xml file def PresentationFormat=(v) Axlsx::validate_string v; @PresentationFormat = v; end + # Sets the Lines property of your app.xml file def Lines=(v) Axlsx::validate_int v; @Lines = v; end + # Sets the Paragraphs property of your app.xml file def Paragraphs=(v) Axlsx::validate_int v; @Paragraphs = v; end + # Sets the Slides property of your app.xml file def Slides=(v) Axlsx::validate_int v; @Slides = v; end + # Sets the Notes property of your app.xml file def Notes=(v) Axlsx::validate_int v; @Notes = v; end + # Sets the TotalTime property of your app.xml file def TotalTime=(v) Axlsx::validate_int v; @TotalTime = v; end + # Sets the HiddenSlides property of your app.xml file def HiddenSlides=(v) Axlsx::validate_int v; @HiddenSlides = v; end + # Sets the MMClips property of your app.xml file def MMClips=(v) Axlsx::validate_int v; @MMClips = v; end + # Sets the ScaleCrop property of your app.xml file def ScaleCrop=(v) Axlsx::validate_boolean v; @ScaleCrop = v; end + # Sets the LinksUpToDate property of your app.xml file def LinksUpToDate=(v) Axlsx::validate_boolean v; @LinksUpToDate = v; end + # Sets the CharactersWithSpaces property of your app.xml file def CharactersWithSpaces=(v) Axlsx::validate_int v; @CharactersWithSpaces = v; end + # Sets the ShareDoc property of your app.xml file def ShareDoc=(v) Axlsx::validate_boolean v; @ShareDoc = v; end + # Sets the HyperLinkBase property of your app.xml file def HyperLinkBase=(v) Axlsx::validate_string v; @HyperLinkBase = v; end + # Sets the HyperLinksChanged property of your app.xml file def HyperlinksChanged=(v) Axlsx::validate_boolean v; @HyperlinksChanged = v; end + # Sets the Application property of your app.xml file def Application=(v) Axlsx::validate_string v; @Application = v; end + # Sets the AppVersion property of your app.xml file def AppVersion=(v) Axlsx::validate_string v; @AppVersion = v; end + # Sets the DocSecurity property of your app.xml file def DocSecurity=(v) Axlsx::validate_int v; @DocSecurity = v; end # Generate an app.xml document diff --git a/lib/axlsx/drawing/axis.rb b/lib/axlsx/drawing/axis.rb index 7e48801a..b89ef70c 100644 --- a/lib/axlsx/drawing/axis.rb +++ b/lib/axlsx/drawing/axis.rb @@ -18,22 +18,22 @@ module Axlsx # The position of the axis # must be one of [:l, :r, :t, :b] # @return [Symbol] - attr_accessor :axPos + attr_reader :axPos # the position of the tick labels # must be one of [:nextTo, :high, :low] # @return [Symbol] - attr_accessor :tickLblPos + attr_reader :tickLblPos # The number format format code for this axis # default :General # @return [String] - attr_accessor :format_code + attr_reader :format_code # specifies how the perpendicular axis is crossed # must be one of [:autoZero, :min, :max] # @return [Symbol] - attr_accessor :crosses + attr_reader :crosses # Creates an Axis object # @param [Integer] axId the id of this axis @@ -47,6 +47,7 @@ module Axlsx Axlsx::validate_unsigned_int(crossAx) @axId = axId @crossAx = crossAx + @format_code = "General" @scaling = Scaling.new(:orientation=>:minMax) self.axPos = :l self.tickLblPos = :nextTo @@ -56,10 +57,20 @@ module Axlsx self.send("#{o[0]}=", o[1]) if self.respond_to? "#{o[0]}=" end end - + # The position of the axis + # must be one of [:l, :r, :t, :b] def axPos=(v) RestrictionValidator.validate "#{self.class}.axPos", [:l, :r, :b, :t], v; @axPos = v; end + + # the position of the tick labels + # must be one of [:nextTo, :high, :low1] def tickLblPos=(v) RestrictionValidator.validate "#{self.class}.tickLblPos", [:nextTo, :high, :low], v; @tickLblPos = v; end + + # The number format format code for this axis + # default :General def format_code=(v) Axlsx::validate_string(v); @formatCode = v; end + + # specifies how the perpendicular axis is crossed + # must be one of [:autoZero, :min, :max] def crosses=(v) RestrictionValidator.validate "#{self.class}.crosses", [:autoZero, :min, :max], v; @crosses = v; end # Serializes the common axis diff --git a/lib/axlsx/drawing/bar_3D_chart.rb b/lib/axlsx/drawing/bar_3D_chart.rb index 3d7f6296..6d74022f 100644 --- a/lib/axlsx/drawing/bar_3D_chart.rb +++ b/lib/axlsx/drawing/bar_3D_chart.rb @@ -18,25 +18,25 @@ module Axlsx # The direction of the bars in the chart # must be one of [:bar, :col] # @return [Symbol] - attr_accessor :barDir + attr_reader :barDir # space between bar or column clusters, as a percentage of the bar or column width. # @return [String] - attr_accessor :gapDepth + attr_reader :gapDepth # space between bar or column clusters, as a percentage of the bar or column width. # @return [String] - attr_accessor :gapWidth + attr_reader :gapWidth #grouping for a column, line, or area chart. # must be one of [:percentStacked, :clustered, :standard, :stacked] # @return [Symbol] - attr_accessor :grouping + attr_reader :grouping # The shabe of the bars or columns # must be one of [:cone, :coneToMax, :box, :cylinder, :pyramid, :pyramidToMax] # @return [Symbol] - attr_accessor :shape + attr_reader :shape # validation regex for gap amount percent GAP_AMOUNT_PERCENT = /0*(([0-9])|([1-9][0-9])|([1-4][0-9][0-9])|500)%/ @@ -61,6 +61,7 @@ module Axlsx def initialize(frame, options={}) @barDir = :bar @grouping = :clustered + @gapWidth, @gapDepth, @shape = nil, nil, nil @catAxId = rand(8 ** 8) @valAxId = rand(8 ** 8) @catAxis = CatAxis.new(@catAxId, @valAxId) @@ -69,28 +70,35 @@ module Axlsx @series_type = BarSeries @view3D = View3D.new({:rAngAx=>1}.merge(options)) end - + + # The direction of the bars in the chart + # must be one of [:bar, :col] def barDir=(v) RestrictionValidator.validate "Bar3DChart.barDir", [:bar, :col], v @barDir = v end - + #grouping for a column, line, or area chart. + # must be one of [:percentStacked, :clustered, :standard, :stacked] def grouping=(v) RestrictionValidator.validate "Bar3DChart.grouping", [:percentStacked, :clustered, :standard, :stacked], v @grouping = v end + # space between bar or column clusters, as a percentage of the bar or column width. def gapWidth=(v) RegexValidator.validate "Bar3DChart.gapWidth", GAP_AMOUNT_PERCENT, v @gapWidth=(v) end + # space between bar or column clusters, as a percentage of the bar or column width. def gapDepth=(v) RegexValidator.validate "Bar3DChart.gapWidth", GAP_AMOUNT_PERCENT, v @gapDepth=(v) end + # The shabe of the bars or columns + # must be one of [:cone, :coneToMax, :box, :cylinder, :pyramid, :pyramidToMax] def shape=(v) RestrictionValidator.validate "Bar3DChart.shape", [:cone, :coneToMax, :box, :cylinder, :pyramid, :pyramidToMax], v @shape = v diff --git a/lib/axlsx/drawing/bar_series.rb b/lib/axlsx/drawing/bar_series.rb index c4bffa8c..129a13e8 100644 --- a/lib/axlsx/drawing/bar_series.rb +++ b/lib/axlsx/drawing/bar_series.rb @@ -17,7 +17,7 @@ module Axlsx # The shabe of the bars or columns # must be one of [:percentStacked, :clustered, :standard, :stacked] # @return [Symbol] - attr_accessor :shape + attr_reader :shape # Creates a new series # @option options [Array, SimpleTypedList] data @@ -32,6 +32,8 @@ module Axlsx self.data = ValAxisData.new(options[:data]) unless options[:data].nil? end + # The shabe of the bars or columns + # must be one of [:percentStacked, :clustered, :standard, :stacked] def shape=(v) RestrictionValidator.validate "BarSeries.shape", [:cone, :coneToMax, :box, :cylinder, :pyramid, :pyramidToMax], v @shape = v @@ -41,10 +43,10 @@ module Axlsx # @param [Nokogiri::XML::Builder] xml The document builder instance this objects xml will be added to. # @return [String] def to_xml(xml) - super(xml) do |xml| - @labels.to_xml(xml) unless @labels.nil? - @data.to_xml(xml) unless @data.nil? - xml.send('c:shape', :val=>@shape) + super(xml) do |xml_inner| + @labels.to_xml(xml_inner) unless @labels.nil? + @data.to_xml(xml_inner) unless @data.nil? + xml_inner.send('c:shape', :val=>@shape) end end diff --git a/lib/axlsx/drawing/cat_axis.rb b/lib/axlsx/drawing/cat_axis.rb index 083eac68..54066aa0 100644 --- a/lib/axlsx/drawing/cat_axis.rb +++ b/lib/axlsx/drawing/cat_axis.rb @@ -4,17 +4,17 @@ module Axlsx # From the docs: This element specifies that this axis is a date or text axis based on the data that is used for the axis labels, not a specific choice. # @return [Boolean] - attr_accessor :auto + attr_reader :auto # specifies how the perpendicular axis is crossed # must be one of [:ctr, :l, :r] # @return [Symbol] - attr_accessor :lblAlgn + attr_reader :lblAlgn # The offset of the labels # must be between a string between 0 and 1000 # @return [Integer] - attr_accessor :lblOffset + attr_reader :lblOffset # regex for validating label offset LBL_OFFSET_REGEX = /0*(([0-9])|([1-9][0-9])|([1-9][0-9][0-9])|1000)%/ @@ -35,8 +35,15 @@ module Axlsx super(axId, crossAx, options) end + # From the docs: This element specifies that this axis is a date or text axis based on the data that is used for the axis labels, not a specific choice. def auto=(v) Axlsx::validate_boolean(v); @auto = v; end + + # specifies how the perpendicular axis is crossed + # must be one of [:ctr, :l, :r] def lblAlgn=(v) RestrictionValidator.validate "#{self.class}.lblAlgn", [:ctr, :l, :r], v; @lblAlgn = v; end + + # The offset of the labels + # must be between a string between 0 and 1000 def lblOffset=(v) RegexValidator.validate "#{self.class}.lblOffset", LBL_OFFSET_REGEX, v; @lblOffset = v; end # Serializes the category axis diff --git a/lib/axlsx/drawing/chart.rb b/lib/axlsx/drawing/chart.rb index 6be9cbfe..45c75bda 100644 --- a/lib/axlsx/drawing/chart.rb +++ b/lib/axlsx/drawing/chart.rb @@ -21,29 +21,21 @@ module Axlsx # @return [Series] attr_reader :series_type - # The index of this chart in the workbooks charts collection - # @return [Integer] - attr_reader :index - - # The part name for this chart - # @return [String] - attr_reader :pn - #TODO data labels! - #attr_accessor :dLabls + #attr_reader :dLabls # The title object for the chart. # @return [Title] - attr_accessor :title + attr_reader :title # The style for the chart. # see ECMA Part 1 §21.2.2.196 # @return [Integer] - attr_accessor :style + attr_reader :style # Show the legend in the chart # @return [Boolean] - attr_accessor :show_legend + attr_reader :show_legend # Creates a new chart object # @param [GraphicalFrame] frame The frame that holds this chart. @@ -59,28 +51,42 @@ module Axlsx options.each do |o| self.send("#{o[0]}=", o[1]) if self.respond_to? "#{o[0]}=" end - start_at *options[:start_at] if options[:start_at] - end_at *options[:end_at] if options[:start_at] + start_at(*options[:start_at]) if options[:start_at] + end_at(*options[:end_at]) if options[:start_at] yield self if block_given? end + # The index of this chart in the workbooks charts collection + # @return [Integer] def index @graphic_frame.anchor.drawing.worksheet.workbook.charts.index(self) end + # The part name for this chart + # @return [String] def pn "#{CHART_PN % (index+1)}" end + # The title object for the chart. + # @param [String, Cell] v + # @return [Title] def title=(v) v = Title.new(v) if v.is_a?(String) || v.is_a?(Cell) DataTypeValidator.validate "#{self.class}.title", Title, v @title = v end + # Show the legend in the chart + # @param [Boolean] v + # @return [Boolean] def show_legend=(v) Axlsx::validate_boolean(v); @show_legend = v; end - def style=(v) DataTypeValidator.validate "Chart.style", Integer, v, lambda { |v| v >= 1 && v <= 48 }; @style = v; end + + # The style for the chart. + # see ECMA Part 1 §21.2.2.196 + # @param [Integer] v must be between 1 and 48 + def style=(v) DataTypeValidator.validate "Chart.style", Integer, v, lambda { |arg| arg >= 1 && arg <= 48 }; @style = v; end # backwards compatibility to allow chart.to and chart.from access to anchor markers # @note This will be disconinued in version 2.0.0. Please use the end_at method diff --git a/lib/axlsx/drawing/drawing.rb b/lib/axlsx/drawing/drawing.rb index 17347cd1..4fa7dc11 100644 --- a/lib/axlsx/drawing/drawing.rb +++ b/lib/axlsx/drawing/drawing.rb @@ -47,34 +47,6 @@ module Axlsx # @return [SimpleTypedList] attr_reader :anchors - # An array of charts that are associated with this drawing's anchors - # @return [Array] - attr_reader :charts - - # An array of image objects that are associated with this drawing's anchors - # @return [Array] - attr_reader :images - - # The index of this drawing in the owning workbooks's drawings collection. - # @return [Integer] - attr_reader :index - - # The relation reference id for this drawing - # @return [String] - attr_reader :rId - - # The part name for this drawing - # @return [String] - attr_reader :pn - - # The relational part name for this drawing - # @return [String] - attr_reader :rels_pn - - # The drawing's relationships. - # @return [Relationships] - attr_reader :relationships - # Creates a new Drawing object # @param [Worksheet] worksheet The worksheet that owns this drawing def initialize(worksheet) @@ -99,33 +71,47 @@ module Axlsx TwoCellAnchor.new(self, options) @anchors.last.add_chart(chart_type, options) end - + + # An array of charts that are associated with this drawing's anchors + # @return [Array] def charts charts = @anchors.select { |a| a.object.is_a?(GraphicFrame) } charts.map { |a| a.object.chart } end + # An array of image objects that are associated with this drawing's anchors + # @return [Array] def images images = @anchors.select { |a| a.object.is_a?(Pic) } images.map { |a| a.object } end + # The index of this drawing in the owning workbooks's drawings collection. + # @return [Integer] def index @worksheet.workbook.drawings.index(self) end + # The relation reference id for this drawing + # @return [String] def rId "rId#{index+1}" end + # The part name for this drawing + # @return [String] def pn "#{DRAWING_PN % (index+1)}" end - + + # The relational part name for this drawing + # @return [String] def rels_pn "#{DRAWING_RELS_PN % (index+1)}" end + # The drawing's relationships. + # @return [Relationships] def relationships r = Relationships.new charts.each do |chart| diff --git a/lib/axlsx/drawing/graphic_frame.rb b/lib/axlsx/drawing/graphic_frame.rb index e8e5ba21..0b1f6d14 100644 --- a/lib/axlsx/drawing/graphic_frame.rb +++ b/lib/axlsx/drawing/graphic_frame.rb @@ -12,10 +12,6 @@ module Axlsx # @return [TwoCellAnchor] attr_reader :anchor - # The relationship id for this graphic - # @return [String] - attr_reader :rId - # Creates a new GraphicFrame object # @param [TwoCellAnchor] anchor # @param [Class] chart_type @@ -25,6 +21,8 @@ module Axlsx @chart = chart_type.new(self, options) end + # The relationship id for this graphic + # @return [String] def rId "rId#{@anchor.index+1}" end diff --git a/lib/axlsx/drawing/line_3D_chart.rb b/lib/axlsx/drawing/line_3D_chart.rb index 6fb34afb..af0cac86 100644 --- a/lib/axlsx/drawing/line_3D_chart.rb +++ b/lib/axlsx/drawing/line_3D_chart.rb @@ -34,12 +34,12 @@ module Axlsx # space between bar or column clusters, as a percentage of the bar or column width. # @return [String] - attr_accessor :gapDepth + attr_reader :gapDepth #grouping for a column, line, or area chart. # must be one of [:percentStacked, :clustered, :standard, :stacked] # @return [Symbol] - attr_accessor :grouping + attr_reader :grouping # validation regex for gap amount percent GAP_AMOUNT_PERCENT = /0*(([0-9])|([1-9][0-9])|([1-4][0-9][0-9])|500)%/ @@ -59,6 +59,7 @@ module Axlsx # @see Chart # @see View3D def initialize(frame, options={}) + @gapDepth = nil @grouping = :standard @catAxId = rand(8 ** 8) @valAxId = rand(8 ** 8) @@ -71,11 +72,13 @@ module Axlsx @view3D = View3D.new({:perspective=>30}.merge(options)) end + # @see grouping def grouping=(v) RestrictionValidator.validate "Bar3DChart.grouping", [:percentStacked, :standard, :stacked], v @grouping = v end + # @see gapDepth def gapDepth=(v) RegexValidator.validate "Bar3DChart.gapWidth", GAP_AMOUNT_PERCENT, v @gapDepth=(v) diff --git a/lib/axlsx/drawing/line_series.rb b/lib/axlsx/drawing/line_series.rb index 40beeb84..c56980fc 100644 --- a/lib/axlsx/drawing/line_series.rb +++ b/lib/axlsx/drawing/line_series.rb @@ -18,18 +18,19 @@ module Axlsx # @option options [Array, SimpleTypedList] labels # @param [Chart] chart def initialize(chart, options={}) + @labels, @data = nil, nil super(chart, options) - self.labels = CatAxisData.new(options[:labels]) unless options[:labels].nil? - self.data = ValAxisData.new(options[:data]) unless options[:data].nil? + @labels = CatAxisData.new(options[:labels]) unless options[:labels].nil? + @data = ValAxisData.new(options[:data]) unless options[:data].nil? end # Serializes the series # @param [Nokogiri::XML::Builder] xml The document builder instance this objects xml will be added to. # @return [String] def to_xml(xml) - super(xml) do |xml| - @labels.to_xml(xml) unless @labels.nil? - @data.to_xml(xml) unless @data.nil? + super(xml) do |xml_inner| + @labels.to_xml(xml_inner) unless @labels.nil? + @data.to_xml(xml_inner) unless @data.nil? end end diff --git a/lib/axlsx/drawing/marker.rb b/lib/axlsx/drawing/marker.rb index 019c14d9..6cd7acd6 100644 --- a/lib/axlsx/drawing/marker.rb +++ b/lib/axlsx/drawing/marker.rb @@ -6,19 +6,19 @@ module Axlsx # The column this marker anchors to # @return [Integer] - attr_accessor :col + attr_reader :col # The offset distance from this marker's column # @return [Integer] - attr_accessor :colOff + attr_reader :colOff # The row this marker anchors to # @return [Integer] - attr_accessor :row + attr_reader :row # The offset distance from this marker's row # @return [Integer] - attr_accessor :rowOff + attr_reader :rowOff # Creates a new Marker object # @option options [Integer] col @@ -32,11 +32,15 @@ module Axlsx end end + # @see col def col=(v) Axlsx::validate_unsigned_int v; @col = v end + # @see colOff def colOff=(v) Axlsx::validate_int v; @colOff = v end + # @see row def row=(v) Axlsx::validate_unsigned_int v; @row = v end + # @see rowOff def rowOff=(v) Axlsx::validate_int v; @rowOff = v end - + # shortcut to set the column, row position for this marker # @param col the column for the marker # @param row the row of the marker diff --git a/lib/axlsx/drawing/one_cell_anchor.rb b/lib/axlsx/drawing/one_cell_anchor.rb index caa0edae..0626502e 100644 --- a/lib/axlsx/drawing/one_cell_anchor.rb +++ b/lib/axlsx/drawing/one_cell_anchor.rb @@ -17,20 +17,15 @@ module Axlsx # @return [Drawing] attr_reader :drawing - # The index of this anchor in the drawing - # @return [Integer] - attr_reader :index - - # the width of the graphic object in pixels. # this is converted to EMU at a 92 ppi resolution # @return [Integer] - attr_accessor :width + attr_reader :width # the height of the graphic object in pixels # this is converted to EMU at a 92 ppi resolution # @return [Integer] - attr_accessor :height + attr_reader :height # Creates a new OneCellAnchor object and an Pic associated with it. @@ -53,9 +48,14 @@ module Axlsx @object = Pic.new(self, options) end + # @see height def height=(v) Axlsx::validate_unsigned_int(v); @height = v; end + + # @see width def width=(v) Axlsx::validate_unsigned_int(v); @width = v; end + # The index of this anchor in the drawing + # @return [Integer] def index @drawing.anchors.index(self) end diff --git a/lib/axlsx/drawing/pic.rb b/lib/axlsx/drawing/pic.rb index 7043df35..84e750ce 100644 --- a/lib/axlsx/drawing/pic.rb +++ b/lib/axlsx/drawing/pic.rb @@ -10,50 +10,22 @@ module Axlsx # The name to use for this picture # @return [String] - attr_accessor :name + attr_reader :name - # providing access to the anchor's width attribute - # @param [Integer] v - # @see OneCellAnchor.width - attr_accessor :width - - # providing access to update the anchor's height attribute - # @param [Integer] v - # @see OneCellAnchor.width - attr_accessor :height # A description of the picture # @return [String] - attr_accessor :descr + attr_reader :descr # The path to the image you want to include # Only local images are supported at this time and only jpg support # @return [String] - attr_accessor :image_src + attr_reader :image_src # The anchor for this image # @return [OneCellAnchor] attr_reader :anchor - # returns the extension of image_src without the preceeding '.' - # @return [String] - attr_reader :extname - - # The file name of image_src without any path information - # @return [String] - attr_reader :file_name - - # The part name for this image used in serialization and relationship building - # @return [String] - attr_reader :pn - - # The index of this image in the workbooks images collections - # @return [Index] - attr_reader :index - - # The name of the image file, sans directory info - # @return [String] - attr_reader :file_name # Creates a new Pic(ture) object # @param [Anchor] anchor the anchor that holds this image @@ -69,7 +41,7 @@ module Axlsx options.each do |o| self.send("#{o[0]}=", o[1]) if self.respond_to? "#{o[0]}=" end - start_at *options[:start_at] if options[:start_at] + start_at(*options[:start_at]) if options[:start_at] yield self if block_given? end @@ -80,41 +52,61 @@ module Axlsx @image_src = v end + # @see name def name=(v) Axlsx::validate_string(v); @name = v; end + + # @see descr def descr=(v) Axlsx::validate_string(v); @descr = v; end + + # The file name of image_src without any path information + # @return [String] def file_name File.basename(image_src) unless image_src.nil? end + # returns the extension of image_src without the preceeding '.' + # @return [String] def extname File.extname(image_src).delete('.') unless image_src.nil? end + # The index of this image in the workbooks images collections + # @return [Index] def index @anchor.drawing.worksheet.workbook.images.index(self) end - + + # The part name for this image used in serialization and relationship building + # @return [String] def pn "#{IMAGE_PN % [(index+1), extname]}" end + # providing access to the anchor's width attribute + # @param [Integer] v + # @see OneCellAnchor.width def width @anchor.width end + # @see width def width=(v) @anchor.width = v end - def height=(v) - @anchor.height = v - end - + # providing access to update the anchor's height attribute + # @param [Integer] v + # @see OneCellAnchor.width def height @anchor.height end + # @see height + def height=(v) + @anchor.height = v + end + # This is a short cut method to set the start anchor position # If you need finer granularity in positioning use # graphic_frame.anchor.from.colOff / rowOff diff --git a/lib/axlsx/drawing/pie_series.rb b/lib/axlsx/drawing/pie_series.rb index 1f20058d..f72802f6 100644 --- a/lib/axlsx/drawing/pie_series.rb +++ b/lib/axlsx/drawing/pie_series.rb @@ -15,7 +15,7 @@ module Axlsx # The explosion for this series # @return [Integert] - attr_accessor :explosion + attr_reader :explosion # Creates a new series # @option options [Array, SimpleTypedList] data @@ -24,21 +24,23 @@ module Axlsx # @option options [Integer] explosion # @param [Chart] chart def initialize(chart, options={}) + @explosion = nil super(chart, options) self.labels = CatAxisData.new(options[:labels]) unless options[:labels].nil? self.data = ValAxisData.new(options[:data]) unless options[:data].nil? end + # @see explosion def explosion=(v) Axlsx::validate_unsigned_int(v); @explosion = v; end # Serializes the series # @param [Nokogiri::XML::Builder] xml The document builder instance this objects xml will be added to. # @return [String] def to_xml(xml) - super(xml) do |xml| - xml.send('c:explosion', :val=>@explosion) unless @explosion.nil? - @labels.to_xml(xml) unless @labels.nil? - @data.to_xml(xml) unless @data.nil? + super(xml) do |xml_inner| + xml_inner.send('c:explosion', :val=>@explosion) unless @explosion.nil? + @labels.to_xml(xml_inner) unless @labels.nil? + @data.to_xml(xml_inner) unless @data.nil? end end private diff --git a/lib/axlsx/drawing/scaling.rb b/lib/axlsx/drawing/scaling.rb index c0665463..e89d00f1 100644 --- a/lib/axlsx/drawing/scaling.rb +++ b/lib/axlsx/drawing/scaling.rb @@ -5,20 +5,20 @@ module Axlsx # logarithmic base for a logarithmic axis. # must be between 2 and 1000 # @return [Integer] - attr_accessor :logBase + attr_reader :logBase # the orientation of the axis # must be one of [:minMax, :maxMin] # @return [Symbol] - attr_accessor :orientation + attr_reader :orientation # the maximum scaling # @return [Float] - attr_accessor :max + attr_reader :max # the minimu scaling # @return [Float] - attr_accessor :min + attr_reader :min # creates a new Scaling object # @option options [Integer, Fixnum] logBase @@ -27,14 +27,20 @@ module Axlsx # @option options [Float] min def initialize(options={}) @orientation = :minMax + @logBase, @min, @max = nil, nil, nil options.each do |o| self.send("#{o[0]}=", o[1]) if self.respond_to? "#{o[0]}=" end end - def logBase=(v) DataTypeValidator.validate "Scaling.logBase", [Integer, Fixnum], v, lambda { |v| v >= 2 && v <= 1000}; @logBase = v; end + # @see logBase + def logBase=(v) DataTypeValidator.validate "Scaling.logBase", [Integer, Fixnum], v, lambda { |arg| arg >= 2 && arg <= 1000}; @logBase = v; end + # @see orientation def orientation=(v) RestrictionValidator.validate "Scaling.orientation", [:minMax, :maxMin], v; @orientation = v; end + # @see max def max=(v) DataTypeValidator.validate "Scaling.max", Float, v; @max = v; end + + # @see min def min=(v) DataTypeValidator.validate "Scaling.min", Float, v; @min = v; end # Serializes the axId diff --git a/lib/axlsx/drawing/ser_axis.rb b/lib/axlsx/drawing/ser_axis.rb index a086b23c..077b92d7 100644 --- a/lib/axlsx/drawing/ser_axis.rb +++ b/lib/axlsx/drawing/ser_axis.rb @@ -4,11 +4,11 @@ module Axlsx # The number of tick lables to skip between labels # @return [Integer] - attr_accessor :tickLblSkip + attr_reader :tickLblSkip # The number of tickmarks to be skipped before the next one is rendered. # @return [Boolean] - attr_accessor :tickMarkSkip + attr_reader :tickMarkSkip # Creates a new SerAxis object # @param [Integer] axId the id of this axis. Inherited @@ -19,10 +19,14 @@ module Axlsx # @option options [Integer] tickLblSkip # @option options [Integer] tickMarkSkip def initialize(axId, crossAx, options={}) + @tickLblSkip, @tickMarkSkip = nil, nil super(axId, crossAx, options) end + # @see tickLblSkip def tickLblSkip=(v) Axlsx::validate_unsigned_int(v); @tickLblSkip = v; end + + # @see tickMarkSkip def tickMarkSkip=(v) Axlsx::validate_unsigned_int(v); @tickMarkSkip = v; end # Serializes the series axis diff --git a/lib/axlsx/drawing/series.rb b/lib/axlsx/drawing/series.rb index cb5d6a8d..3647f22e 100644 --- a/lib/axlsx/drawing/series.rb +++ b/lib/axlsx/drawing/series.rb @@ -9,40 +9,40 @@ module Axlsx # @return [Chart] attr_reader :chart - # The index of this series in the chart's series. - # @return [Integer] - attr_reader :index - - # The order of this series in the chart's series. By default the order is the index of the series. - # @return [Integer] - attr_accessor :order - # The title of the series # @return [SeriesTitle] - attr_accessor :title + attr_reader :title # Creates a new series # @param [Chart] chart # @option options [Integer] order # @option options [String] title def initialize(chart, options={}) + @order = nil self.chart = chart @chart.series << self options.each do |o| self.send("#{o[0]}=", o[1]) if self.respond_to? "#{o[0]}=" end end - + + # The index of this series in the chart's series. + # @return [Integer] def index @chart.series.index(self) end - def order=(v) Axlsx::validate_unsigned_int(v); @order = v; end + # The order of this series in the chart's series. By default the order is the index of the series. + # @return [Integer] def order @order || index end + # @see order + def order=(v) Axlsx::validate_unsigned_int(v); @order = v; end + + # @see title def title=(v) v = SeriesTitle.new(v) if v.is_a?(String) || v.is_a?(Cell) DataTypeValidator.validate "#{self.class}.title", SeriesTitle, v diff --git a/lib/axlsx/drawing/series_title.rb b/lib/axlsx/drawing/series_title.rb index bfb1b56f..de977633 100644 --- a/lib/axlsx/drawing/series_title.rb +++ b/lib/axlsx/drawing/series_title.rb @@ -8,7 +8,7 @@ module Axlsx def to_xml(xml) xml.send('c:tx') { xml.send('c:strRef') { - xml.send('c:f', range) + xml.send('c:f', Axlsx::cell_range([@cell])) xml.send('c:strCache') { xml.send('c:ptCount', :val=>1) xml.send('c:pt', :idx=>0) { diff --git a/lib/axlsx/drawing/title.rb b/lib/axlsx/drawing/title.rb index bdbf0e5c..f8c87921 100644 --- a/lib/axlsx/drawing/title.rb +++ b/lib/axlsx/drawing/title.rb @@ -4,11 +4,11 @@ module Axlsx # The text to be shown. Setting this property directly with a string will remove the cell reference. # @return [String] - attr_accessor :text + attr_reader :text # The cell that holds the text for the title. Setting this property will automatically update the text attribute. # @return [Cell] - attr_accessor :cell + attr_reader :cell # Creates a new Title object # @param [String, Cell] title The cell or string to be used for the chart's title @@ -17,6 +17,7 @@ module Axlsx self.text = title.to_s unless title.is_a?(Cell) end + # @see text def text=(v) DataTypeValidator.validate 'Title.text', String, v @text = v @@ -24,6 +25,7 @@ module Axlsx v end + # @see cell def cell=(v) DataTypeValidator.validate 'Title.text', Cell, v @cell = v @@ -43,7 +45,7 @@ module Axlsx xml.send('c:title') { xml.send('c:tx') { xml.send('c:strRef') { - xml.send('c:f', range) + xml.send('c:f', Axlsx::cell_range([@cell])) xml.send('c:strCache') { xml.send('c:ptCount', :val=>1) xml.send('c:pt', :idx=>0) { @@ -55,14 +57,5 @@ module Axlsx } end - private - - # returns the excel style abslute reference for the title when title is a Cell object - # @return [String] - def range - return "" unless @data.is_a?(Cell) - "#{@data.row.worksheet.name}!#{data.row.r_abs}" - end - end end diff --git a/lib/axlsx/drawing/two_cell_anchor.rb b/lib/axlsx/drawing/two_cell_anchor.rb index 73e2fe20..06c0554a 100644 --- a/lib/axlsx/drawing/two_cell_anchor.rb +++ b/lib/axlsx/drawing/two_cell_anchor.rb @@ -24,9 +24,6 @@ module Axlsx # @return [Drawing] attr_reader :drawing - # The index of this anchor in the drawing - # @return [Integer] - attr_reader :index # Creates a new TwoCellAnchor object and sets up a reference to the from and to markers in the # graphic_frame's chart. That means that you can do stuff like @@ -51,6 +48,8 @@ module Axlsx @object.chart end + # The index of this anchor in the drawing + # @return [Integer] def index @drawing.anchors.index(self) end diff --git a/lib/axlsx/drawing/val_axis.rb b/lib/axlsx/drawing/val_axis.rb index 10a070f6..3233bcfd 100644 --- a/lib/axlsx/drawing/val_axis.rb +++ b/lib/axlsx/drawing/val_axis.rb @@ -5,7 +5,7 @@ module Axlsx # This element specifies how the value axis crosses the category axis. # must be one of [:between, :midCat] # @return [Symbol] - attr_accessor :crossBetween + attr_reader :crossBetween # Creates a new ValAxis object # @param [Integer] axId the id of this axis @@ -18,7 +18,7 @@ module Axlsx self.crossBetween = :between super(axId, crossAx, options) end - + # @see crossBetween def crossBetween=(v) RestrictionValidator.validate "ValAxis.crossBetween", [:between, :midCat], v; @crossBetween = v; end # Serializes the value axis diff --git a/lib/axlsx/drawing/view_3D.rb b/lib/axlsx/drawing/view_3D.rb index 1065d778..7a8c115f 100644 --- a/lib/axlsx/drawing/view_3D.rb +++ b/lib/axlsx/drawing/view_3D.rb @@ -11,30 +11,30 @@ module Axlsx # x rotation for the chart # must be between -90 and 90 # @return [Integer] - attr_accessor :rotX + attr_reader :rotX # height of chart as % of chart # must be between 5% and 500% # @return [String] - attr_accessor :hPercent + attr_reader :hPercent # y rotation for the chart # must be between 0 and 360 # @return [Integer] - attr_accessor :rotY + attr_reader :rotY # depth or chart as % of chart width # must be between 20% and 2000% # @return [String] - attr_accessor :depthPercent + attr_reader :depthPercent # Chart axis are at right angles # @return [Boolean] - attr_accessor :rAngAx + attr_reader :rAngAx # field of view angle # @return [Integer] - attr_accessor :perspective + attr_reader :perspective # Creates a new View3D for charts # @option options [Integer] rotX @@ -44,22 +44,29 @@ module Axlsx # @option options [Boolean] rAngAx # @option options [Integer] perspective def initialize(options={}) + @rotX, @hPercent, @rotY, @depthPercent, @rAngAx, @perspective = nil, nil, nil, nil, nil, nil options.each do |o| self.send("#{o[0]}=", o[1]) if self.respond_to? "#{o[0]}=" end end - def rotX=(v) DataTypeValidator.validate "#{self.class}.rotX", [Integer, Fixnum], v, lambda {|v| v >= -90 && v <= 90 }; @rotX = v; end + # @see rotX + def rotX=(v) DataTypeValidator.validate "#{self.class}.rotX", [Integer, Fixnum], v, lambda {|arg| arg >= -90 && arg <= 90 }; @rotX = v; end + # @see hPercent def hPercent=(v) RegexValidator.validate "#{self.class}.rotX", H_PERCENT_REGEX, v; @hPercent = v; end - def rotY=(v) DataTypeValidator.validate "#{self.class}.rotY", [Integer, Fixnum], v, lambda {|v| v >= 0 && v <= 360 }; @rotY = v; end + # @see rotY + def rotY=(v) DataTypeValidator.validate "#{self.class}.rotY", [Integer, Fixnum], v, lambda {|arg| arg >= 0 && arg <= 360 }; @rotY = v; end + # @see depthPercent def depthPercent=(v) RegexValidator.validate "#{self.class}.depthPercent", DEPTH_PERCENT_REGEX, v; @depthPercent = v; end + # @see rAngAx def rAngAx=(v) Axlsx::validate_boolean(v); @rAngAx = v; end - def perspective=(v) DataTypeValidator.validate "#{self.class}.perspective", [Integer, Fixnum], v, lambda {|v| v >= 0 && v <= 240 }; @perspective = v; end + # @see perspective + def perspective=(v) DataTypeValidator.validate "#{self.class}.perspective", [Integer, Fixnum], v, lambda {|arg| arg >= 0 && arg <= 240 }; @perspective = v; end # Serializes the view3D properties # @param [Nokogiri::XML::Builder] xml The document builder instance this objects xml will be added to. diff --git a/lib/axlsx/package.rb b/lib/axlsx/package.rb index 91df81df..d9455f14 100644 --- a/lib/axlsx/package.rb +++ b/lib/axlsx/package.rb @@ -1,12 +1,23 @@ # -*- coding: utf-8 -*- -# Create Office Open XML Spreadsheets (xlsx) with safe and full control over cell styles, automatically resized column widths and 3D pie charts. module Axlsx # Package is responsible for managing all the bits and peices that Open Office XML requires to make a valid # xlsx document including valdation and serialization. class Package + # Initializes your package + # + # @param [Hash] options A hash that you can use to specify the author and workbook for this package. + # @option options [String] :author The author of the document + # @example Package.new :author => 'you!', :workbook => Workbook.new + def initialize(options={}) + @workbook = nil + @core, @app = Core.new, App.new + @core.creator = options[:author] || @core.creator + yield self if block_given? + end + + # The workbook this package will serialize or validate. - # @attribute # @return [Workbook] If no workbook instance has been assigned with this package a new Workbook instance is returned. # @raise ArgumentError if workbook parameter is not a Workbook instance. # @note As there are multiple ways to instantiate a workbook for the package, @@ -18,25 +29,13 @@ module Axlsx # wb = Pacakge.new().workbook # # # set the workbook after creating the package # wb = Package.new().workbook = Workbook.new - attr_accessor :workbook - - # Initializes your package - # - # @param [Hash] options A hash that you can use to specify the author and workbook for this package. - # @option options [String] :author The author of the document - # @example Package.new :author => 'you!', :workbook => Workbook.new - def initialize(options={}) - @core, @app = Core.new, App.new - @core.creator = options[:author] || @core.creator - yield self if block_given? - end - - def workbook=(workbook) DataTypeValidator.validate "Package.workbook", Workbook, workbook; @workbook = workbook; end - def workbook @workbook || @workbook = Workbook.new end + # @see workbook + def workbook=(workbook) DataTypeValidator.validate "Package.workbook", Workbook, workbook; @workbook = workbook; end + # Serialize your workbook to disk as an xlsx document. # # @param [File] output The file you want to serialize your package to @@ -57,18 +56,17 @@ module Axlsx p = parts Zip::ZipOutputStream.open(output) do |zip| p.each do |part| - zip.put_next_entry(part[:entry]); zip.puts(part[:doc]) unless part[:doc].nil? - end - end - Zip::ZipFile.open(output) do |zip| - p.each do |part| - if part[:path] - zip.add(part[:entry], part[:path], &proc{ true }) + unless part[:doc].nil? + zip.put_next_entry(part[:entry]); + zip.puts(part[:doc]) end - end + unless part[:path].nil? + zip.put_next_entry(part[:entry]); + # binread for 1.9.3 + zip.write IO.respond_to?(:binread) ? IO.binread(part[:path]) : IO.read(part[:path]) + end + end end - - true end diff --git a/lib/axlsx/rels/relationship.rb b/lib/axlsx/rels/relationship.rb index a76c0c25..829a724a 100644 --- a/lib/axlsx/rels/relationship.rb +++ b/lib/axlsx/rels/relationship.rb @@ -5,7 +5,7 @@ module Axlsx # The location of the relationship target # @return [String] - attr_accessor :Target + attr_reader :Target # The type of relationship # @note Supported types are defined as constants in Axlsx: @@ -20,13 +20,15 @@ module Axlsx # @see CHART_R # @see DRAWING_R # @return [String] - attr_accessor :Type + attr_reader :Type def initialize(type, target) self.Target=target self.Type=type end + # @see Target def Target=(v) Axlsx::validate_string v; @Target = v end + # @see Type def Type=(v) Axlsx::validate_relationship_type v; @Type = v end # Serializes the relationship diff --git a/lib/axlsx/stylesheet/border.rb b/lib/axlsx/stylesheet/border.rb index 167b42c9..73a873e5 100644 --- a/lib/axlsx/stylesheet/border.rb +++ b/lib/axlsx/stylesheet/border.rb @@ -3,13 +3,13 @@ module Axlsx class Border # @return [Boolean] The diagonal up property for the border that indicates if the border should include a diagonal line from the bottom left to the top right of the cell. - attr_accessor :diagonalUp + attr_reader :diagonalUp # @return [Boolean] The diagonal down property for the border that indicates if the border should include a diagonal line from the top left to the top right of the cell. - attr_accessor :diagonalDown + attr_reader :diagonalDown # @return [Boolean] The outline property for the border indicating that top, left, right and bottom borders should only be applied to the outside border of a range of cells. - attr_accessor :outline + attr_reader :outline # @return [SimpleTypedList] A list of BorderPr objects for this border. attr_reader :prs @@ -35,8 +35,11 @@ module Axlsx end end + # @see diagonalUp def diagonalUp=(v) Axlsx::validate_boolean v; @diagonalUp = v end + # @see diagonalDown def diagonalDown=(v) Axlsx::validate_boolean v; @diagonalDown = v end + # @see outline def outline=(v) Axlsx::validate_boolean v; @outline = v end # Serializes the border element @@ -44,7 +47,9 @@ module Axlsx def to_xml(xml) xml.border(self.instance_values.select{ |k,v| [:diagonalUp, :diagonalDown, :outline].include? k }) { [:start, :end, :left, :right, :top, :bottom, :diagonal, :vertical, :horizontal].each do |k| - @prs.select { |pr| pr.name == k }.each { |pr| pr.to_xml(xml) } + @prs.select { |pr| pr.name == k }.each do |part| + part.to_xml(xml) + end end } end diff --git a/lib/axlsx/stylesheet/border_pr.rb b/lib/axlsx/stylesheet/border_pr.rb index 63a1f9de..cdab5b13 100644 --- a/lib/axlsx/stylesheet/border_pr.rb +++ b/lib/axlsx/stylesheet/border_pr.rb @@ -3,7 +3,7 @@ module Axlsx class BorderPr # @return [Color] The color of this border part. - attr_accessor :color + attr_reader :color # @return [Symbol] The syle of this border part. # @note @@ -22,7 +22,7 @@ module Axlsx # :dashDotDot # :mediumDashDotDot # :slantDashDot - attr_accessor :style + attr_reader :style # @return [Symbol] The name of this border part # @note @@ -36,7 +36,7 @@ module Axlsx # :diagonal # :vertical # :horizontal - attr_accessor :name + attr_reader :name # Creates a new Border Part Object # @option options [Color] color @@ -49,15 +49,18 @@ module Axlsx end end + # @see name def name=(v) RestrictionValidator.validate "BorderPr.name", [:start, :end, :left, :right, :top, :bottom, :diagonal, :vertical, :horizontal], v; @name = v end + # @see color def color=(v) DataTypeValidator.validate(:color, Color, v); @color = v end + # @see style def style=(v) RestrictionValidator.validate "BorderPr.style", [:none, :thin, :medium, :dashed, :dotted, :thick, :double, :hair, :mediumDashed, :dashDot, :mediumDashDot, :dashDotDot, :mediumDashDotDot, :slantDashDot], v; @style = v end # Serializes the border part # @param [Nokogiri::XML::Builder] xml The document builder instance this objects xml will be added to. # @return [String] def to_xml(xml) - xml.send(@name, :style=>@style) { + xml.send(@name, :style => @style) { @color.to_xml(xml) if @color.is_a? Color } end diff --git a/lib/axlsx/stylesheet/cell_alignment.rb b/lib/axlsx/stylesheet/cell_alignment.rb index 071ce68f..75d86e2d 100644 --- a/lib/axlsx/stylesheet/cell_alignment.rb +++ b/lib/axlsx/stylesheet/cell_alignment.rb @@ -15,7 +15,7 @@ module Axlsx # :centerContinuous # :distributed # @return [Symbol] - attr_accessor :horizontal + attr_reader :horizontal # The vertical alignment of the cell. # @note @@ -26,38 +26,38 @@ module Axlsx # :justify # :distributed # @return [Symbol] - attr_accessor :vertical + attr_reader :vertical # The textRotation of the cell. # @return [Integer] - attr_accessor :textRotation + attr_reader :textRotation # Indicate if the text of the cell should wrap # @return [Boolean] - attr_accessor :wrapText + attr_reader :wrapText # The amount of indent # @return [Integer] - attr_accessor :indent + attr_reader :indent # The amount of relativeIndent # @return [Integer] - attr_accessor :relativeIndent + attr_reader :relativeIndent # Indicate if the last line should be justified. # @return [Boolean] - attr_accessor :justifyLastLine + attr_reader :justifyLastLine # Indicate if the text should be shrunk to the fit in the cell. # @return [Boolean] - attr_accessor :shrinkToFit + attr_reader :shrinkToFit # The reading order of the text # 0 Context Dependent # 1 Left-to-Right # 2 Right-to-Left # @return [Integer] - attr_accessor :readingOrder + attr_reader :readingOrder # Create a new cell_alignment object # @option options [Symbol] horizontal @@ -75,14 +75,23 @@ module Axlsx end end + # @see horizontal def horizontal=(v) Axlsx::validate_horizontal_alignment v; @horizontal = v end + # @see vertical def vertical=(v) Axlsx::validate_vertical_alignment v; @vertical = v end + # @see textRotation def textRotation=(v) Axlsx::validate_unsigned_int v; @textRotation = v end + # @see wrapText def wrapText=(v) Axlsx::validate_boolean v; @wrapText = v end + # @see indent def indent=(v) Axlsx::validate_unsigned_int v; @indent = v end + # @see relativeIndent def relativeIndent=(v) Axlsx::validate_int v; @relativeIndent = v end + # @see justifyLastLine def justifyLastLine=(v) Axlsx::validate_boolean v; @justifyLastLine = v end + # @see shrinkToFit def shrinkToFit=(v) Axlsx::validate_boolean v; @shrinkToFit = v end + # @see readingOrder def readingOrder=(v) Axlsx::validate_unsigned_int v; @readingOrder = v end # Serializes the cell alignment diff --git a/lib/axlsx/stylesheet/cell_protection.rb b/lib/axlsx/stylesheet/cell_protection.rb index 7f0f4db8..e1c6183f 100644 --- a/lib/axlsx/stylesheet/cell_protection.rb +++ b/lib/axlsx/stylesheet/cell_protection.rb @@ -6,11 +6,11 @@ module Axlsx # specifies locking for cells that have the style containing this protection # @return [Boolean] - attr_accessor :hidden + attr_reader :hidden # specifies if the cells that have the style containing this protection # @return [Boolean] - attr_accessor :locked + attr_reader :locked # Creates a new CellProtection # @option options [Boolean] hidden value for hidden protection @@ -20,7 +20,10 @@ module Axlsx self.send("#{o[0]}=", o[1]) if self.respond_to? "#{o[0]}=" end end + + # @see hidden def hidden=(v) Axlsx::validate_boolean v; @hidden = v end + # @see locked def locked=(v) Axlsx::validate_boolean v; @locked = v end # Serializes the cell protection diff --git a/lib/axlsx/stylesheet/cell_style.rb b/lib/axlsx/stylesheet/cell_style.rb index 11272075..f11f5193 100644 --- a/lib/axlsx/stylesheet/cell_style.rb +++ b/lib/axlsx/stylesheet/cell_style.rb @@ -5,29 +5,29 @@ module Axlsx class CellStyle # The name of this cell style # @return [String] - attr_accessor :name + attr_reader :name # The formatting record id this named style utilizes # @return [Integer] # @see Axlsx::Xf - attr_accessor :xfId + attr_reader :xfId # The buildinId to use when this named style is applied # @return [Integer] # @see Axlsx::NumFmt - attr_accessor :builtinId + attr_reader :builtinId # Determines if this formatting is for an outline style, and what level of the outline it is to be applied to. # @return [Integer] - attr_accessor :iLevel + attr_reader :iLevel # Determines if this named style should show in the list of styles when using excel # @return [Boolean] - attr_accessor :hidden + attr_reader :hidden # Indicates that the build in style reference has been customized. # @return [Boolean] - attr_accessor :customBuiltin + attr_reader :customBuiltin # Creats a new CellStyle object # @option options [String] name @@ -41,12 +41,17 @@ module Axlsx self.send("#{o[0]}=", o[1]) if self.respond_to? o[0] end end - + # @see name def name=(v) Axlsx::validate_string v; @name = v end + # @see xfId def xfId=(v) Axlsx::validate_unsigned_int v; @xfId = v end + # @see builtinId def builtinId=(v) Axlsx::validate_unsigned_int v; @builtinId = v end + # @see iLivel def iLevel=(v) Axlsx::validate_unsigned_int v; @iLevel = v end + # @see hidden def hidden=(v) Axlsx::validate_boolean v; @hidden = v end + # @see customBuiltin def customBuiltin=(v) Axlsx::validate_boolean v; @customBuiltin = v end # Serializes the cell style diff --git a/lib/axlsx/stylesheet/color.rb b/lib/axlsx/stylesheet/color.rb index 34567cd1..2df70ee8 100644 --- a/lib/axlsx/stylesheet/color.rb +++ b/lib/axlsx/stylesheet/color.rb @@ -3,11 +3,11 @@ module Axlsx class Color # Determines if the color is system color dependant # @return [Boolean] - attr_accessor :auto + attr_reader :auto # Backwards compatability color index # return [Integer] - #attr_accessor :indexed + #attr_reader :indexed # The color as defined in rgb terms. # @note @@ -16,16 +16,16 @@ module Axlsx # "FF000000" is black # "FFFFFFFF" is white # @return [String] - attr_accessor :rgb + attr_reader :rgb # no support for theme just yet # @return [Integer] - #attr_accessor :theme + #attr_reader :theme # The tint value. # @note valid values are between -1.0 and 1.0 # @return [Float] - attr_accessor :tint + attr_reader :tint # Creates a new Color object # @option options [Boolean] auto @@ -37,9 +37,11 @@ module Axlsx self.send("#{o[0]}=", o[1]) if self.respond_to? o[0] end end - + # @see auto def auto=(v) Axlsx::validate_boolean v; @auto = v end + # @see rgb def rgb=(v) Axlsx::validate_string v; @rgb = v end + # @see tint def tint=(v) Axlsx::validate_float v; @tint = v end # This version does not support themes diff --git a/lib/axlsx/stylesheet/fill.rb b/lib/axlsx/stylesheet/fill.rb index b7477a88..ad313679 100644 --- a/lib/axlsx/stylesheet/fill.rb +++ b/lib/axlsx/stylesheet/fill.rb @@ -8,7 +8,7 @@ module Axlsx # The type of fill # @return [PatternFill, GradientFill] - attr_accessor :fill_type + attr_reader :fill_type # Creates a new Fill object # @param [PatternFill, GradientFill] fill_type @@ -24,6 +24,7 @@ module Axlsx xml.fill { @fill_type.to_xml(xml) } end + # @see fill_type def fill_type=(v) DataTypeValidator.validate "Fill.fill_type", [PatternFill, GradientFill], v; @fill_type = v; end diff --git a/lib/axlsx/stylesheet/font.rb b/lib/axlsx/stylesheet/font.rb index fbd369a3..b0c9eaae 100644 --- a/lib/axlsx/stylesheet/font.rb +++ b/lib/axlsx/stylesheet/font.rb @@ -5,7 +5,7 @@ module Axlsx class Font # The name of the font # @return [String] - attr_accessor :name + attr_reader :name # The charset of the font # @return [Integer] @@ -30,7 +30,7 @@ module Axlsx # 222 THAI_CHARSET # 238 EASTEUROPE_CHARSET # 255 OEM_CHARSET - attr_accessor :charset + attr_reader :charset # The font's family # @note @@ -43,43 +43,43 @@ module Axlsx # 5 Decorative # 6..14 Reserved for future use # @return [Integer] - attr_accessor :family + attr_reader :family # Indicates if the font should be rendered in *bold* # @return [Boolean] - attr_accessor :b + attr_reader :b # Indicates if the font should be rendered italicized # @return [Boolean] - attr_accessor :i + attr_reader :i # Indicates if the font should be rendered with a strikthrough # @return [Boolean] - attr_accessor :strike + attr_reader :strike # Indicates if the font should be rendered with an outline # @return [Boolean] - attr_accessor :outline + attr_reader :outline # Indicates if the font should be rendered with a shadow # @return [Boolean] - attr_accessor :shadow + attr_reader :shadow # Indicates if the font should be condensed # @return [Boolean] - attr_accessor :condense + attr_reader :condense # The font's extend property # @return [Boolean] - attr_accessor :extend + attr_reader :extend # The color of the font # @return [Color] - attr_accessor :color + attr_reader :color # The size of the font. # @return [Integer] - attr_accessor :sz + attr_reader :sz # Creates a new Font # @option options [String] name @@ -100,18 +100,29 @@ module Axlsx self.send("#{o[0]}=", o[1]) if self.respond_to? o[0] end end - + # @see name def name=(v) Axlsx::validate_string v; @name = v end + # @see charset def charset=(v) Axlsx::validate_unsigned_int v; @charset = v end + # @see family def family=(v) Axlsx::validate_unsigned_int v; @family = v end + # @see b def b=(v) Axlsx::validate_boolean v; @b = v end + # @see i def i=(v) Axlsx::validate_boolean v; @i = v end + # @see strike def strike=(v) Axlsx::validate_boolean v; @strike = v end + # @see outline def outline=(v) Axlsx::validate_boolean v; @outline = v end + # @see shadow def shadow=(v) Axlsx::validate_boolean v; @shadow = v end + # @see condense def condense=(v) Axlsx::validate_boolean v; @condense = v end + # @see extend def extend=(v) Axlsx::validate_boolean v; @extend = v end + # @see color def color=(v) DataTypeValidator.validate "Font.color", Color, v; @color=v end + # @see sz def sz=(v) Axlsx::validate_unsigned_int v; @sz=v end # Serializes the fill diff --git a/lib/axlsx/stylesheet/gradient_fill.rb b/lib/axlsx/stylesheet/gradient_fill.rb index 8fc41a5d..2b02ac76 100644 --- a/lib/axlsx/stylesheet/gradient_fill.rb +++ b/lib/axlsx/stylesheet/gradient_fill.rb @@ -10,27 +10,27 @@ module Axlsx # :linear # :path # @return [Symbol] - attr_accessor :type + attr_reader :type # Angle of the linear gradient # @return [Float] - attr_accessor :degree + attr_reader :degree # Percentage format left # @return [Float] - attr_accessor :left + attr_reader :left # Percentage format right # @return [Float] - attr_accessor :right + attr_reader :right # Percentage format top # @return [Float] - attr_accessor :top + attr_reader :top # Percentage format bottom # @return [Float] - attr_accessor :bottom + attr_reader :bottom # Collection of stop objects # @return [SimpleTypedList] @@ -51,12 +51,18 @@ module Axlsx @stop = SimpleTypedList.new GradientStop end + # @see type def type=(v) Axlsx::validate_gradient_type v; @type = v end + # @see degree def degree=(v) Axlsx::validate_float v; @degree = v end - def left=(v) DataTypeValidator.validate "GradientFill.left", Float, v, lambda { |v| v >= 0.0 && v <= 1.0}; @left = v end - def right=(v) DataTypeValidator.validate "GradientFill.right", Float, v, lambda { |v| v >= 0.0 && v <= 1.0}; @right = v end - def top=(v) DataTypeValidator.validate "GradientFill.top", Float, v, lambda { |v| v >= 0.0 && v <= 1.0}; @top = v end - def bottom=(v) DataTypeValidator.validate "GradientFill.bottom", Float, v, lambda { |v| v >= 0.0 && v <= 1.0}; @bottom= v end + # @see left + def left=(v) DataTypeValidator.validate "GradientFill.left", Float, v, lambda { |arg| arg >= 0.0 && arg <= 1.0}; @left = v end + # @see right + def right=(v) DataTypeValidator.validate "GradientFill.right", Float, v, lambda { |arg| arg >= 0.0 && arg <= 1.0}; @right = v end + # @see top + def top=(v) DataTypeValidator.validate "GradientFill.top", Float, v, lambda { |arg| arg >= 0.0 && arg <= 1.0}; @top = v end + # @see bottom + def bottom=(v) DataTypeValidator.validate "GradientFill.bottom", Float, v, lambda { |arg| arg >= 0.0 && arg <= 1.0}; @bottom= v end # Serializes the gradientFill # @param [Nokogiri::XML::Builder] xml The document builder instance this objects xml will be added to. diff --git a/lib/axlsx/stylesheet/gradient_stop.rb b/lib/axlsx/stylesheet/gradient_stop.rb index 22786fcb..d493c037 100644 --- a/lib/axlsx/stylesheet/gradient_stop.rb +++ b/lib/axlsx/stylesheet/gradient_stop.rb @@ -6,11 +6,11 @@ module Axlsx # The color for this gradient stop # @return [Color] # @see Color - attr_accessor :color + attr_reader :color # The position of the color # @return [Float] - attr_accessor :position + attr_reader :position # Creates a new GradientStop object # @param [Color] color @@ -20,8 +20,10 @@ module Axlsx self.position = position end + # @see color def color=(v) DataTypeValidator.validate "GradientStop.color", Color, v; @color=v end - def position=(v) DataTypeValidator.validate "GradientStop.position", Float, v, lambda { |v| v >= 0 && v <= 1}; @position = v end + # @see position + def position=(v) DataTypeValidator.validate "GradientStop.position", Float, v, lambda { |arg| arg >= 0 && arg <= 1}; @position = v end # Serializes the gradientStop # @param [Nokogiri::XML::Builder] xml The document builder instance this objects xml will be added to. diff --git a/lib/axlsx/stylesheet/num_fmt.rb b/lib/axlsx/stylesheet/num_fmt.rb index 826599b6..0ed45e5c 100644 --- a/lib/axlsx/stylesheet/num_fmt.rb +++ b/lib/axlsx/stylesheet/num_fmt.rb @@ -37,11 +37,11 @@ module Axlsx # 48 ##0.0E+0 # 49 @ # @see Axlsx - attr_accessor :numFmtId + attr_reader :numFmtId # @return [String] The formatting to use for this number format. # @see http://support.microsoft.com/kb/264372 - attr_accessor :formatCode + attr_reader :formatCode def initialize(options={}) @numFmtId = 0 @formatCode = "" @@ -50,7 +50,9 @@ module Axlsx end end + # @see numFmtId def numFmtId=(v) Axlsx::validate_unsigned_int v; @numFmtId = v end + # @see formatCode def formatCode=(v) Axlsx::validate_string v; @formatCode = v end # Creates a numFmt element applying the instance values of this object as attributes. diff --git a/lib/axlsx/stylesheet/pattern_fill.rb b/lib/axlsx/stylesheet/pattern_fill.rb index 7d674e27..a6a6f6a0 100644 --- a/lib/axlsx/stylesheet/pattern_fill.rb +++ b/lib/axlsx/stylesheet/pattern_fill.rb @@ -6,11 +6,11 @@ module Axlsx # The color to use for the the background in solid fills. # @return [Color] - attr_accessor :fgColor + attr_reader :fgColor # The color to use for the background of the fill when the type is not solid. # @return [Color] - attr_accessor :bgColor + attr_reader :bgColor # The pattern type to use # @note @@ -35,7 +35,7 @@ module Axlsx # :gray125 # :gray0625 # @see Office Open XML Part 1 18.18.55 - attr_accessor :patternType + attr_reader :patternType # Creates a new PatternFill Object # @option options [Symbol] patternType @@ -47,9 +47,11 @@ module Axlsx self.send("#{o[0]}=", o[1]) if self.respond_to? "#{o[0]}=" end end - + # @see fgColor def fgColor=(v) DataTypeValidator.validate "PatternFill.fgColor", Color, v; @fgColor=v end + # @see bgColor def bgColor=(v) DataTypeValidator.validate "PatternFill.bgColor", Color, v; @bgColor=v end + # @see patternType def patternType=(v) Axlsx::validate_pattern_type v; @patternType = v end # Serializes the pattern fill diff --git a/lib/axlsx/stylesheet/styles.rb b/lib/axlsx/stylesheet/styles.rb index 6f428ecd..e06a4026 100644 --- a/lib/axlsx/stylesheet/styles.rb +++ b/lib/axlsx/stylesheet/styles.rb @@ -197,10 +197,10 @@ module Axlsx else options[:num_fmt] || 0 end - + borderId = options[:border] || 0 raise ArgumentError, "Invalid borderId" unless borderId < borders.size - + fill = if options[:bg_color] color = Color.new(:rgb=>options[:bg_color]) pattern = PatternFill.new(:patternType =>:solid, :fgColor=>color) @@ -208,7 +208,7 @@ module Axlsx else 0 end - + fontId = if (options.values_at(:fg_color, :sz, :b, :i, :strike, :outline, :shadow, :charset, :family, :font_name).length) font = Font.new() [:b, :i, :strike, :outline, :shadow, :charset, :family, :sz].each { |k| font.send("#{k}=", options[k]) unless options[k].nil? } @@ -218,11 +218,11 @@ module Axlsx else 0 end - - applyProtection = (options[:hidden] || options[:locked]) ? 1 : 0 - + + applyProtection = (options[:hidden] || options[:locked]) ? 1 : 0 + xf = Xf.new(:fillId => fill, :fontId=>fontId, :applyFill=>1, :applyFont=>1, :numFmtId=>numFmtId, :borderId=>borderId, :applyProtection=>applyProtection) - + if options[:alignment] xf.alignment = CellAlignment.new(options[:alignment]) end @@ -230,16 +230,16 @@ module Axlsx if applyProtection xf.protection = CellProtection.new(options) end - + cellXfs << xf - end - + end + # Serializes the styles document # @return [String] def to_xml() builder = Nokogiri::XML::Builder.new(:encoding => ENCODING) do |xml| xml.styleSheet(:xmlns => XML_NS) { - [:numFmts, :fonts, :fills, :borders, :cellStyleXfs, :cellXfs, :dxfs, :tableStyles].each do |key| + [:numFmts, :fonts, :fills, :borders, :cellStyleXfs, :cellXfs, :cellStyles, :dxfs, :tableStyles].each do |key| self.instance_values[key.to_s].to_xml(xml) end } @@ -280,7 +280,7 @@ module Axlsx @cellStyleXfs.lock @cellStyles = SimpleTypedList.new CellStyle - @cellStyles << CellStyle.new(:name =>"標準", :builtinId =>0, :xfId=>0) + @cellStyles << CellStyle.new(:name =>"Normal", :builtinId =>0, :xfId=>0) @cellStyles.lock @cellXfs = SimpleTypedList.new Xf, "cellXfs" diff --git a/lib/axlsx/stylesheet/table_style.rb b/lib/axlsx/stylesheet/table_style.rb index ca138b1f..77fbd448 100644 --- a/lib/axlsx/stylesheet/table_style.rb +++ b/lib/axlsx/stylesheet/table_style.rb @@ -5,15 +5,15 @@ module Axlsx # The name of this table style # @return [string] - attr_accessor :name + attr_reader :name # indicates if this style should be applied to pivot tables # @return [Boolean] - attr_accessor :pivot + attr_reader :pivot # indicates if this style should be applied to tables # @return [Boolean] - attr_accessor :table + attr_reader :table # creates a new TableStyle object # @raise [ArgumentError] if name option is not provided. @@ -28,8 +28,11 @@ module Axlsx super TableStyleElement end + # @see name def name=(v) Axlsx::validate_string v; @name=v end + # @see pivot def pivot=(v) Axlsx::validate_boolean v; @pivot=v end + # @see table def table=(v) Axlsx::validate_boolean v; @table=v end # Serializes the table style diff --git a/lib/axlsx/stylesheet/table_style_element.rb b/lib/axlsx/stylesheet/table_style_element.rb index 146a6bad..20159788 100644 --- a/lib/axlsx/stylesheet/table_style_element.rb +++ b/lib/axlsx/stylesheet/table_style_element.rb @@ -32,15 +32,15 @@ module Axlsx # :pageFieldLabels # :pageFieldValues # @return [Symbol] - attr_accessor :type + attr_reader :type # Number of rows or columns used in striping when the type is firstRowStripe, secondRowStripe, firstColumnStripe, or secondColumnStripe. # @return [Integer] - attr_accessor :size + attr_reader :size # The dxfId this style element points to # @return [Integer] - attr_accessor :dxfId + attr_reader :dxfId # creates a new TableStyleElement object # @option options [Symbol] type @@ -51,9 +51,14 @@ module Axlsx self.send("#{o[0]}=", o[1]) if self.respond_to? o[0] end end - + + # @see type def type=(v) Axlsx::validate_table_element_type v; @type = v end + + # @see size def size=(v) Axlsx::validate_unsigned_int v; @size = v end + + # @see dxfId def dxfId=(v) Axlsx::validate_unsigned_int v; @dxfId = v end # Serializes the table style element diff --git a/lib/axlsx/stylesheet/table_styles.rb b/lib/axlsx/stylesheet/table_styles.rb index cc2005f6..bfd15261 100644 --- a/lib/axlsx/stylesheet/table_styles.rb +++ b/lib/axlsx/stylesheet/table_styles.rb @@ -5,12 +5,11 @@ module Axlsx # The default table style. The default value is 'TableStyleMedium9' # @return [String] - # - attr_accessor :defaultTableStyle + attr_reader :defaultTableStyle # The default pivot table style. The default value is 'PivotStyleLight6' # @return [String] - attr_accessor :defaultPivotStyle + attr_reader :defaultPivotStyle # Creates a new TableStyles object that is a container for TableStyle objects # @option options [String] defaultTableStyle @@ -20,8 +19,9 @@ module Axlsx @defaultPivotStyle = options[:defaultPivotStyle] || "PivotStyleLight16" super TableStyle end - + # @see defaultTableStyle def defaultTableStyle=(v) Axlsx::validate_string(v); @defaultTableStyle = v; end + # @see defaultPivotStyle def defaultPivotStyle=(v) Axlsx::validate_string(v); @defaultPivotStyle = v; end # Serializes the table styles element diff --git a/lib/axlsx/stylesheet/xf.rb b/lib/axlsx/stylesheet/xf.rb index 905eda2c..3ca1a8a2 100644 --- a/lib/axlsx/stylesheet/xf.rb +++ b/lib/axlsx/stylesheet/xf.rb @@ -1,107 +1,128 @@ module Axlsx - # The Xf class defines a formatting record for use in Styles + # The Xf class defines a formatting record for use in Styles. The recommended way to manage styles for your workbook is with Styles#add_style + # @see Styles#add_style class Xf #does not support extList (ExtensionList) # The cell alignment for this style # @return [CellAlignment] # @see CellAlignment - attr_accessor :alignment + attr_reader :alignment # The cell protection for this style # @return [CellProtection] # @see CellProtection - attr_accessor :protection + attr_reader :protection # id of the numFmt to apply to this style # @return [Integer] - attr_accessor :numFmtId + attr_reader :numFmtId # index (0 based) of the font to be used in this style # @return [Integer] - attr_accessor :fontId + attr_reader :fontId # index (0 based) of the fill to be used in this style # @return [Integer] - attr_accessor :fillId + attr_reader :fillId # index (0 based) of the border to be used in this style # @return [Integer] - attr_accessor :borderId + attr_reader :borderId # index (0 based) of cellStylesXfs item to be used in this style. Only applies to cellXfs items # @return [Integer] - attr_accessor :xfId + attr_reader :xfId # indecates if text should be prefixed by a single quote in the cell # @return [Boolean] - attr_accessor :quotePrefix + attr_reader :quotePrefix # indicates if the cell has a pivot table drop down button # @return [Boolean] - attr_accessor :pivotButton + attr_reader :pivotButton # indicates if the numFmtId should be applied # @return [Boolean] - attr_accessor :applyNumberFormat + attr_reader :applyNumberFormat # indicates if the fontId should be applied # @return [Boolean] - attr_accessor :applyFont + attr_reader :applyFont # indicates if the fillId should be applied # @return [Boolean] - attr_accessor :applyFill + attr_reader :applyFill # indicates if the borderId should be applied # @return [Boolean] - attr_accessor :applyBorder + attr_reader :applyBorder # Indicates if the alignment options should be applied # @return [Boolean] - attr_accessor :applyAlignment + attr_reader :applyAlignment # Indicates if the protection options should be applied # @return [Boolean] - attr_accessor :applyProtection + attr_reader :applyProtection # Creates a new Xf object - # @option [Integer] numFmtId - # @option [Integer] fontId - # @option [Integer] fillId - # @option [Integer] borderId - # @option [Integer] xfId - # @option [Boolean] quotePrefix - # @option [Boolean] pivotButton - # @option [Boolean] applyNumberFormat - # @option [Boolean] applyFont - # @option [Boolean] applyFill - # @option [Boolean] applyBorder - # @option [Boolean] applyAlignment - # @option [Boolean] applyProtection - # @option [CellAlignment] alignment - # @option [CellProtection] protection + # @option options [Integer] numFmtId + # @option options [Integer] fontId + # @option options [Integer] fillId + # @option options [Integer] borderId + # @option options [Integer] xfId + # @option options [Boolean] quotePrefix + # @option options [Boolean] pivotButton + # @option options [Boolean] applyNumberFormat + # @option options [Boolean] applyFont + # @option options [Boolean] applyFill + # @option options [Boolean] applyBorder + # @option options [Boolean] applyAlignment + # @option options [Boolean] applyProtection + # @option options [CellAlignment] alignment + # @option options [CellProtection] protection def initialize(options={}) options.each do |o| self.send("#{o[0]}=", o[1]) if self.respond_to? "#{o[0]}=" end end + # @see Xf#alignment def alignment=(v) DataTypeValidator.validate "Xf.alignment", CellAlignment, v; @alignment = v end + + # @see protection def protection=(v) DataTypeValidator.validate "Xf.protection", CellProtection, v; @protection = v end + # @see numFmtId def numFmtId=(v) Axlsx::validate_unsigned_int v; @numFmtId = v end + + # @see fontId def fontId=(v) Axlsx::validate_unsigned_int v; @fontId = v end + # @see fillId def fillId=(v) Axlsx::validate_unsigned_int v; @fillId = v end + # @see borderId def borderId=(v) Axlsx::validate_unsigned_int v; @borderId = v end + # @see xfId def xfId=(v) Axlsx::validate_unsigned_int v; @xfId = v end + # @see quotePrefix def quotePrefix=(v) Axlsx::validate_boolean v; @quotePrefix = v end + # @see pivotButton def pivotButton=(v) Axlsx::validate_boolean v; @pivotButton = v end + # @see applyNumberFormat def applyNumberFormat=(v) Axlsx::validate_boolean v; @applyNumberFormat = v end + # @see applyFont def applyFont=(v) Axlsx::validate_boolean v; @applyFont = v end + # @see applyFill def applyFill=(v) Axlsx::validate_boolean v; @applyFill = v end + + # @see applyBorder def applyBorder=(v) Axlsx::validate_boolean v; @applyBorder = v end + + # @see applyAlignment def applyAlignment=(v) Axlsx::validate_boolean v; @applyAlignment = v end + + # @see applyProtection def applyProtection=(v) Axlsx::validate_boolean v; @applyProtection = v end # Serializes the xf elemen diff --git a/lib/axlsx/util/validators.rb b/lib/axlsx/util/validators.rb index 827030c7..5e590bbe 100644 --- a/lib/axlsx/util/validators.rb +++ b/lib/axlsx/util/validators.rb @@ -31,7 +31,7 @@ module Axlsx # @raise [ArugumentError] Raised if the class of the value provided is not in the specified array of types or the block passed returns false # @return [Boolean] true if validation succeeds. # @see validate_boolean - def self.validate(name, types, v, other= lambda{|v| true }) + def self.validate(name, types, v, other= lambda{|arg| true }) types = [types] unless types.is_a? Array valid_type = false if v.class == Class @@ -49,7 +49,7 @@ module Axlsx # @raise [ArgumentError] raised if the value is not a Fixnum or Integer value greater or equal to 0 # @return [Boolean] true if the data is valid def self.validate_unsigned_int(v) - DataTypeValidator.validate(:unsigned_int, [Fixnum, Integer], v, lambda { |v| v.respond_to?(:>=) && v >= 0 }) + DataTypeValidator.validate(:unsigned_int, [Fixnum, Integer], v, lambda { |arg| arg.respond_to?(:>=) && arg >= 0 }) end # Requires that the value is a Fixnum or Integer @@ -63,7 +63,7 @@ module Axlsx # it must be one of 0, 1, "true", "false", :true, :false, true, false, "0", or "1" # @param [Any] v The value validated def self.validate_boolean(v) - DataTypeValidator.validate(:boolean, [Fixnum, String, Integer, Symbol, TrueClass, FalseClass], v, lambda { |v| [0, 1, "true", "false", :true, :false, true, false, "0", "1"].include?(v) }) + DataTypeValidator.validate(:boolean, [Fixnum, String, Integer, Symbol, TrueClass, FalseClass], v, lambda { |arg| [0, 1, "true", "false", :true, :false, true, false, "0", "1"].include?(arg) }) end # Requires that the value is a String diff --git a/lib/axlsx/version.rb b/lib/axlsx/version.rb index ed7a1ff1..2ecaf2a9 100644 --- a/lib/axlsx/version.rb +++ b/lib/axlsx/version.rb @@ -1,4 +1,4 @@ module Axlsx # version - VERSION="1.0.8" + VERSION="1.0.9" end diff --git a/lib/axlsx/workbook/workbook.rb b/lib/axlsx/workbook/workbook.rb index 76a3803c..68f9f8b8 100644 --- a/lib/axlsx/workbook/workbook.rb +++ b/lib/axlsx/workbook/workbook.rb @@ -65,13 +65,6 @@ require 'axlsx/workbook/worksheet/worksheet.rb' # @return [Styles] attr_reader :styles - # The workbook relationships. This is managed automatically by the workbook - # @return [Relationships] - attr_reader :relationships - - # Instance level access to the class variable 1904 - # @return [Boolean] - attr_accessor :date1904 # Indicates if the epoc date for serialization should be 1904. If false, 1900 is used. @@ -89,9 +82,13 @@ require 'axlsx/workbook/worksheet/worksheet.rb' yield self if block_given? end - def date1904=(v) Axlsx::validate_boolean v; @@date1904 = v; end + # Instance level access to the class variable 1904 + # @return [Boolean] def date1904() @@date1904; end + # see @date1904 + def date1904=(v) Axlsx::validate_boolean v; @@date1904 = v; end + # Sets the date1904 attribute to the provided boolean # @return [Boolean] def self.date1904=(v) Axlsx::validate_boolean v; @@date1904 = v; end @@ -109,7 +106,9 @@ require 'axlsx/workbook/worksheet/worksheet.rb' yield worksheet if block_given? worksheet end - + + # The workbook relationships. This is managed automatically by the workbook + # @return [Relationships] def relationships r = Relationships.new @worksheets.each do |sheet| diff --git a/lib/axlsx/workbook/worksheet/cell.rb b/lib/axlsx/workbook/worksheet/cell.rb index 5e535721..556a5a89 100644 --- a/lib/axlsx/workbook/worksheet/cell.rb +++ b/lib/axlsx/workbook/worksheet/cell.rb @@ -1,3 +1,4 @@ +# -*- coding: utf-8 -*- module Axlsx # A cell in a worksheet. # Cell stores inforamation requried to serialize a single worksheet cell to xml. You must provde the Row that the cell belongs to and the cells value. The data type will automatically be determed if you do not specify the :type option. The default style will be applied if you do not supply the :style option. Changing the cell's type will recast the value to the type specified. Altering the cell's value via the property accessor will also automatically cast the provided value to the cell's type. @@ -25,7 +26,7 @@ module Axlsx # The index of the cellXfs item to be applied to this cell. # @return [Integer] # @see Axlsx::Styles - attr_accessor :style + attr_reader :style # The row this cell belongs to. # @return [Row] @@ -42,12 +43,24 @@ module Axlsx # :string to :integer or :float, type coversions always return 0 or 0.0 # :string, :integer, or :float to :time conversions always return the original value as a string and set the cells type to :string. # No support is currently implemented for parsing time strings. - # - attr_accessor :type + attr_reader :type + # @see type + def type=(v) + RestrictionValidator.validate "Cell.type", [:time, :float, :integer, :string], v + @type=v + self.value = @value + end + # The value of this cell. # @return casted value based on cell's type attribute. - attr_accessor :value + attr_reader :value + # @see value + def value=(v) + #TODO: consider doing value based type determination first? + @value = cast_value(v) + end + # @param [Row] row The row this cell belongs to. # @param [Any] value The value associated with this cell. @@ -91,16 +104,7 @@ module Axlsx @style = v end - def type=(v) - RestrictionValidator.validate "Cell.type", [:time, :float, :integer, :string], v - @type=v - self.value = @value - end - def value=(v) - #TODO: consider doing value based type determination first? - @value = cast_value(v) - end # Serializes the cell # @param [Nokogiri::XML::Builder] xml The document builder instance this objects xml will be added to. @@ -108,14 +112,19 @@ module Axlsx # @note # Shared Strings are not used in this library. All values are set directly in the each sheet. def to_xml(xml) - if @type == :string - #NOTE not sure why, but xml.t @v renders the text as html entities of unicode data - xml.c(:r => r, :t=>:inlineStr, :s=>style) { xml.is { xml.t value.to_s } } + # Both 1.8 and 1.9 return the same 'fast_xf' + # ニホンゴ + # ニホンゴ + + # however nokogiri does a nice 'force_encoding' which we shall remove! + if @type == :string + xml.c(:r => r, :t=>:inlineStr, :s=>style) { xml.is { xml.t @value.to_s } } else xml.c(:r => r, :s => style) { xml.v value } end end + private # assigns the owning row for this cell. diff --git a/lib/axlsx/workbook/worksheet/row.rb b/lib/axlsx/workbook/worksheet/row.rb index 27e60f38..96a1c3d1 100644 --- a/lib/axlsx/workbook/worksheet/row.rb +++ b/lib/axlsx/workbook/worksheet/row.rb @@ -12,10 +12,6 @@ module Axlsx # @return [SimpleTypedList] attr_reader :cells - # The index of this row in the worksheet - # @return [Integer] - attr_reader :index - # Creates a new row. New Cell objects are created based on the values, types and style options. # A new cell is created for each item in the values array. style and types options are applied as follows: # If the types option is defined and is a symbol it is applied to all the cells created. @@ -37,6 +33,8 @@ module Axlsx array_to_cells(values, options) end + # The index of this row in the worksheet + # @return [Integer] def index worksheet.rows.index(self) end diff --git a/lib/axlsx/workbook/worksheet/worksheet.rb b/lib/axlsx/workbook/worksheet/worksheet.rb index 861bb8ef..6dfbc060 100644 --- a/lib/axlsx/workbook/worksheet/worksheet.rb +++ b/lib/axlsx/workbook/worksheet/worksheet.rb @@ -6,49 +6,24 @@ module Axlsx # The name of the worksheet # @return [String] - attr_accessor :name + attr_reader :name # The workbook that owns this worksheet # @return [Workbook] attr_reader :workbook - # The worksheet relationships. This is managed automatically by the worksheet - # @return [Relationships] - attr_reader :relationships # The rows in this worksheet # @note The recommended way to manage rows is Worksheet#add_row # @return [SimpleTypedList] # @see Worksheet#add_row attr_reader :rows - - # The drawing associated with this worksheet. - # @note the recommended way to work with drawings and charts is Worksheet#add_chart - # @return [Drawing] - # @see Worksheet#add_chart - attr_reader :drawing # An array of content based calculated column widths. # @note a single auto fit data item is a hash with :longest => [String] and :sz=> [Integer] members. # @return [Array] of Hash attr_reader :auto_fit_data - # The part name of this worksheet - # @return [String] - attr_reader :pn - - # The relationship part name of this worksheet - # @return [String] - attr_reader :rels_pn - - # The relationship Id of thiw worksheet - # @return [String] - attr_reader :rId - - # The index of this worksheet in the owning Workbook's worksheets list. - # @return [Integer] - attr_reader :index - # TODO Merge Cells # attr_reader :merge_cells @@ -57,6 +32,7 @@ module Axlsx # @see Workbook#add_worksheet # @option options [String] name The name of this sheet. def initialize(wb, options={}) + @drawing = nil @rows = SimpleTypedList.new Row self.workbook = wb @workbook.worksheets << self @@ -65,25 +41,38 @@ module Axlsx @magick_draw = Magick::Draw.new end - + # The name of the worksheet + # @param [String] v def name=(v) DataTypeValidator.validate "Worksheet.name", String, v; @name=v end - + + # The part name of this worksheet + # @return [String] def pn "#{WORKSHEET_PN % (index+1)}" end + # The relationship part name of this worksheet + # @return [String] def rels_pn "#{WORKSHEET_RELS_PN % (index+1)}" end + # The relationship Id of thiw worksheet + # @return [String] def rId "rId#{index+1}" end - + + # The index of this worksheet in the owning Workbook's worksheets list. + # @return [Integer] def index @workbook.worksheets.index(self) end + # The drawing associated with this worksheet. + # @note the recommended way to work with drawings and charts is Worksheet#add_chart + # @return [Drawing] + # @see Worksheet#add_chart def drawing @drawing || @drawing = Axlsx::Drawing.new(self) end @@ -149,10 +138,11 @@ module Axlsx xml.drawing :"r:id"=>"rId1" if @drawing } end - builder.to_xml(:indent=>0, :save_with=>0) + builder.to_xml end - # The worksheet's relationships. + # The worksheet relationships. This is managed automatically by the worksheet + # @return [Relationships] def relationships r = Relationships.new r << Relationship.new(DRAWING_R, "../#{@drawing.pn}") if @drawing @@ -193,7 +183,7 @@ module Axlsx # From ECMA docs # Column width measured as the number of characters of the maximum digit width of the numbers 0 .. 9 as # rendered in the normal style's font. There are 4 pixels of margin padding (two on each side), plus 1 pixel padding for the gridlines. - # width = Truncate([{Number of Characters} * {Maximum Digit Width} + {5 pixel padding}]/{Maximum Digit Width}*256)/256 + # width = Truncate([!{Number of Characters} * !{Maximum Digit Width} + !{5 pixel padding}]/!{Maximum Digit Width}*256)/256 # @return [Float] # @param [Hash] A hash of auto_fit_data def auto_width(col) @@ -201,6 +191,7 @@ module Axlsx mdw_count = 0 best_guess = 1.5 #direct testing shows the results of the documented formula to be a bit too small. This is a best guess scaling font_scale = col[:sz].to_f / (self.workbook.styles.fonts[0].sz.to_f || 11.0) + col[:longest].scan(/./mu).each do |i| mdw_count +=1 if @magick_draw.get_type_metrics(i).width >= mdw end diff --git a/test/drawing/tc_one_cell_anchor.rb b/test/drawing/tc_one_cell_anchor.rb index d2618622..cab22840 100644 --- a/test/drawing/tc_one_cell_anchor.rb +++ b/test/drawing/tc_one_cell_anchor.rb @@ -30,7 +30,7 @@ class TestOneCellAnchor < Test::Unit::TestCase end def test_index - assert(@anchor.index, @anchor.drawing.anchors.index(@anchor)) + assert_equal(@anchor.index, @anchor.drawing.anchors.index(@anchor)) end def test_width |
