axlsx 1.0.8 → 1.0.9

Sign up to get free protection for your applications and to get access to all the features.
Files changed (128) hide show
  1. data/CHANGELOG.md +14 -0
  2. data/README.md +22 -21
  3. data/Rakefile +1 -1
  4. data/axlsx.gemspec +36 -0
  5. data/doc/Axlsx.html +373 -559
  6. data/doc/Axlsx/App.html +257 -360
  7. data/doc/Axlsx/Axis.html +113 -144
  8. data/doc/Axlsx/Bar3DChart.html +122 -152
  9. data/doc/Axlsx/BarSeries.html +67 -81
  10. data/doc/Axlsx/Border.html +96 -119
  11. data/doc/Axlsx/BorderPr.html +89 -114
  12. data/doc/Axlsx/CatAxis.html +79 -104
  13. data/doc/Axlsx/CatAxisData.html +40 -54
  14. data/doc/Axlsx/Cell.html +193 -679
  15. data/doc/Axlsx/CellAlignment.html +116 -157
  16. data/doc/Axlsx/CellProtection.html +50 -68
  17. data/doc/Axlsx/CellStyle.html +78 -106
  18. data/doc/Axlsx/Chart.html +361 -432
  19. data/doc/Axlsx/Color.html +56 -78
  20. data/doc/Axlsx/ContentType.html +28 -41
  21. data/doc/Axlsx/Core.html +43 -55
  22. data/doc/Axlsx/DataTypeValidator.html +34 -43
  23. data/doc/Axlsx/Default.html +55 -81
  24. data/doc/Axlsx/Drawing.html +322 -412
  25. data/doc/Axlsx/Fill.html +34 -47
  26. data/doc/Axlsx/Font.html +157 -207
  27. data/doc/Axlsx/GradientFill.html +90 -122
  28. data/doc/Axlsx/GradientStop.html +36 -50
  29. data/doc/Axlsx/GraphicFrame.html +106 -130
  30. data/doc/Axlsx/Line3DChart.html +108 -134
  31. data/doc/Axlsx/LineSeries.html +58 -67
  32. data/doc/Axlsx/Marker.html +84 -111
  33. data/doc/Axlsx/NumFmt.html +83 -102
  34. data/doc/Axlsx/OneCellAnchor.html +158 -196
  35. data/doc/Axlsx/Override.html +60 -92
  36. data/doc/Axlsx/Package.html +190 -759
  37. data/doc/Axlsx/PatternFill.html +78 -99
  38. data/doc/Axlsx/Pic.html +451 -405
  39. data/doc/Axlsx/Pie3DChart.html +33 -42
  40. data/doc/Axlsx/PieSeries.html +68 -80
  41. data/doc/Axlsx/RegexValidator.html +15 -20
  42. data/doc/Axlsx/Relationship.html +49 -66
  43. data/doc/Axlsx/Relationships.html +28 -41
  44. data/doc/Axlsx/RestrictionValidator.html +23 -32
  45. data/doc/Axlsx/Row.html +132 -161
  46. data/doc/Axlsx/Scaling.html +71 -90
  47. data/doc/Axlsx/SerAxis.html +61 -79
  48. data/doc/Axlsx/Series.html +125 -201
  49. data/doc/Axlsx/SeriesTitle.html +26 -31
  50. data/doc/Axlsx/Styles.html +286 -355
  51. data/doc/Axlsx/TableStyle.html +62 -87
  52. data/doc/Axlsx/TableStyleElement.html +84 -104
  53. data/doc/Axlsx/TableStyles.html +59 -82
  54. data/doc/Axlsx/Title.html +58 -155
  55. data/doc/Axlsx/TwoCellAnchor.html +165 -204
  56. data/doc/Axlsx/ValAxis.html +39 -53
  57. data/doc/Axlsx/ValAxisData.html +29 -39
  58. data/doc/Axlsx/View3D.html +93 -122
  59. data/doc/Axlsx/Workbook.html +359 -362
  60. data/doc/Axlsx/Worksheet.html +471 -816
  61. data/doc/Axlsx/Xf.html +341 -296
  62. data/doc/_index.html +7 -11
  63. data/doc/class_list.html +1 -1
  64. data/doc/file.LICENSE.html +86 -0
  65. data/doc/file.README.html +105 -107
  66. data/doc/file_list.html +3 -0
  67. data/doc/frames.html +1 -1
  68. data/doc/index.html +105 -107
  69. data/doc/method_list.html +426 -602
  70. data/doc/top-level-namespace.html +3 -3
  71. data/examples/example.rb +20 -1
  72. data/lib/axlsx.rb +20 -15
  73. data/lib/axlsx/content_type/default.rb +8 -3
  74. data/lib/axlsx/content_type/override.rb +11 -4
  75. data/lib/axlsx/doc_props/app.rb +53 -23
  76. data/lib/axlsx/drawing/axis.rb +16 -5
  77. data/lib/axlsx/drawing/bar_3D_chart.rb +15 -7
  78. data/lib/axlsx/drawing/bar_series.rb +7 -5
  79. data/lib/axlsx/drawing/cat_axis.rb +10 -3
  80. data/lib/axlsx/drawing/chart.rb +21 -15
  81. data/lib/axlsx/drawing/drawing.rb +16 -30
  82. data/lib/axlsx/drawing/graphic_frame.rb +2 -4
  83. data/lib/axlsx/drawing/line_3D_chart.rb +5 -2
  84. data/lib/axlsx/drawing/line_series.rb +6 -5
  85. data/lib/axlsx/drawing/marker.rb +9 -5
  86. data/lib/axlsx/drawing/one_cell_anchor.rb +7 -7
  87. data/lib/axlsx/drawing/pic.rb +29 -37
  88. data/lib/axlsx/drawing/pie_series.rb +7 -5
  89. data/lib/axlsx/drawing/scaling.rb +11 -5
  90. data/lib/axlsx/drawing/ser_axis.rb +6 -2
  91. data/lib/axlsx/drawing/series.rb +11 -11
  92. data/lib/axlsx/drawing/series_title.rb +1 -1
  93. data/lib/axlsx/drawing/title.rb +5 -12
  94. data/lib/axlsx/drawing/two_cell_anchor.rb +2 -3
  95. data/lib/axlsx/drawing/val_axis.rb +2 -2
  96. data/lib/axlsx/drawing/view_3D.rb +16 -9
  97. data/lib/axlsx/package.rb +25 -27
  98. data/lib/axlsx/rels/relationship.rb +4 -2
  99. data/lib/axlsx/stylesheet/border.rb +9 -4
  100. data/lib/axlsx/stylesheet/border_pr.rb +7 -4
  101. data/lib/axlsx/stylesheet/cell_alignment.rb +18 -9
  102. data/lib/axlsx/stylesheet/cell_protection.rb +5 -2
  103. data/lib/axlsx/stylesheet/cell_style.rb +12 -7
  104. data/lib/axlsx/stylesheet/color.rb +8 -6
  105. data/lib/axlsx/stylesheet/fill.rb +2 -1
  106. data/lib/axlsx/stylesheet/font.rb +24 -13
  107. data/lib/axlsx/stylesheet/gradient_fill.rb +16 -10
  108. data/lib/axlsx/stylesheet/gradient_stop.rb +5 -3
  109. data/lib/axlsx/stylesheet/num_fmt.rb +4 -2
  110. data/lib/axlsx/stylesheet/pattern_fill.rb +6 -4
  111. data/lib/axlsx/stylesheet/styles.rb +12 -12
  112. data/lib/axlsx/stylesheet/table_style.rb +6 -3
  113. data/lib/axlsx/stylesheet/table_style_element.rb +9 -4
  114. data/lib/axlsx/stylesheet/table_styles.rb +4 -4
  115. data/lib/axlsx/stylesheet/xf.rb +52 -31
  116. data/lib/axlsx/util/validators.rb +3 -3
  117. data/lib/axlsx/version.rb +1 -1
  118. data/lib/axlsx/workbook/workbook.rb +8 -9
  119. data/lib/axlsx/workbook/worksheet/cell.rb +25 -16
  120. data/lib/axlsx/workbook/worksheet/row.rb +2 -4
  121. data/lib/axlsx/workbook/worksheet/worksheet.rb +23 -32
  122. data/test/drawing/tc_one_cell_anchor.rb +1 -1
  123. metadata +135 -165
  124. data/doc/Axlsx/SimpleTypedList.html +0 -1686
  125. data/lib/schema/dc.xsd~ +0 -118
  126. data/lib/schema/dcterms.xsd~ +0 -331
  127. data/lib/schema/opc-coreProperties.xsd~ +0 -50
  128. data/test/drawing/tc_line_series.tc~ +0 -34
@@ -6,7 +6,7 @@
6
6
  <title>
7
7
  Class: Axlsx::Worksheet
8
8
 
9
- &mdash; Documentation by YARD 0.7.3
9
+ &mdash; AXLSX
10
10
 
11
11
  </title>
12
12
 
@@ -94,9 +94,8 @@
94
94
 
95
95
  <h2>Overview</h2><div class="docstring">
96
96
  <div class="discussion">
97
- <p>
98
- The Worksheet class represents a worksheet in the workbook.
99
- </p>
97
+
98
+ <p>The Worksheet class represents a worksheet in the workbook.</p>
100
99
 
101
100
 
102
101
  </div>
@@ -128,9 +127,8 @@ The Worksheet class represents a worksheet in the workbook.
128
127
 
129
128
 
130
129
 
131
- <span class="summary_desc"><div class='inline'><p>
132
- An array of content based calculated column widths.
133
- </p>
130
+ <span class="summary_desc"><div class='inline'>
131
+ <p>An array of content based calculated column widths.</p>
134
132
  </div></span>
135
133
 
136
134
  </li>
@@ -139,14 +137,14 @@ An array of content based calculated column widths.
139
137
  <li class="public ">
140
138
  <span class="summary_signature">
141
139
 
142
- <a href="#drawing-instance_method" title="#drawing (instance method)">- (Drawing) <strong>drawing</strong> </a>
140
+ <a href="#name-instance_method" title="#name (instance method)">- (String) <strong>name</strong> </a>
143
141
 
144
142
 
145
143
 
146
144
  </span>
147
145
 
148
146
 
149
- <span class="note title readonly">readonly</span>
147
+
150
148
 
151
149
 
152
150
 
@@ -155,9 +153,8 @@ An array of content based calculated column widths.
155
153
 
156
154
 
157
155
 
158
- <span class="summary_desc"><div class='inline'><p>
159
- The drawing associated with this worksheet.
160
- </p>
156
+ <span class="summary_desc"><div class='inline'>
157
+ <p>The name of the worksheet.</p>
161
158
  </div></span>
162
159
 
163
160
  </li>
@@ -166,7 +163,7 @@ The drawing associated with this worksheet.
166
163
  <li class="public ">
167
164
  <span class="summary_signature">
168
165
 
169
- <a href="#index-instance_method" title="#index (instance method)">- (Integer) <strong>index</strong> </a>
166
+ <a href="#rows-instance_method" title="#rows (instance method)">- (SimpleTypedList) <strong>rows</strong> </a>
170
167
 
171
168
 
172
169
 
@@ -182,9 +179,8 @@ The drawing associated with this worksheet.
182
179
 
183
180
 
184
181
 
185
- <span class="summary_desc"><div class='inline'><p>
186
- The index of this worksheet in the owning Workbook&#8217;s worksheets list.
187
- </p>
182
+ <span class="summary_desc"><div class='inline'>
183
+ <p>The rows in this worksheet.</p>
188
184
  </div></span>
189
185
 
190
186
  </li>
@@ -193,7 +189,7 @@ The index of this worksheet in the owning Workbook&#8217;s worksheets list.
193
189
  <li class="public ">
194
190
  <span class="summary_signature">
195
191
 
196
- <a href="#name-instance_method" title="#name (instance method)">- (String) <strong>name</strong> </a>
192
+ <a href="#workbook-instance_method" title="#workbook (instance method)">- (Workbook) <strong>workbook</strong> </a>
197
193
 
198
194
 
199
195
 
@@ -209,193 +205,122 @@ The index of this worksheet in the owning Workbook&#8217;s worksheets list.
209
205
 
210
206
 
211
207
 
212
- <span class="summary_desc"><div class='inline'><p>
213
- The name of the worksheet.
214
- </p>
208
+ <span class="summary_desc"><div class='inline'>
209
+ <p>The workbook that owns this worksheet.</p>
215
210
  </div></span>
216
211
 
217
212
  </li>
218
213
 
219
214
 
220
- <li class="public ">
221
- <span class="summary_signature">
222
-
223
- <a href="#pn-instance_method" title="#pn (instance method)">- (String) <strong>pn</strong> </a>
224
-
225
-
226
-
227
- </span>
228
-
229
-
230
- <span class="note title readonly">readonly</span>
231
-
232
-
233
-
234
-
235
-
236
-
215
+ </ul>
237
216
 
238
-
239
- <span class="summary_desc"><div class='inline'><p>
240
- The part name of this worksheet.
241
- </p>
242
- </div></span>
243
-
244
- </li>
245
217
 
246
-
247
- <li class="public ">
248
- <span class="summary_signature">
249
-
250
- <a href="#relationships-instance_method" title="#relationships (instance method)">- (Object) <strong>relationships</strong> </a>
251
-
252
218
 
253
-
254
- </span>
255
-
256
-
257
- <span class="note title readonly">readonly</span>
258
-
259
-
260
-
261
-
262
-
263
-
264
219
 
265
220
 
266
- <span class="summary_desc"><div class='inline'><p>
267
- The worksheet&#8217;s relationships.
268
- </p>
269
- </div></span>
270
-
271
- </li>
221
+ <h2>
222
+ Instance Method Summary
223
+ <small>(<a href="#" class="summary_toggle">collapse</a>)</small>
224
+ </h2>
272
225
 
273
-
274
- <li class="public ">
226
+ <ul class="summary">
227
+
228
+ <li class="public ">
275
229
  <span class="summary_signature">
276
230
 
277
- <a href="#rels_pn-instance_method" title="#rels_pn (instance method)">- (String) <strong>rels_pn</strong> </a>
231
+ <a href="#add_chart-instance_method" title="#add_chart (instance method)">- (Object) <strong>add_chart</strong>(chart_type, options = {}) {|chart| ... }</a>
278
232
 
279
233
 
280
234
 
281
235
  </span>
282
236
 
283
237
 
284
- <span class="note title readonly">readonly</span>
285
-
286
-
287
238
 
288
239
 
289
240
 
290
241
 
291
242
 
292
243
 
293
- <span class="summary_desc"><div class='inline'><p>
294
- The relationship part name of this worksheet.
295
- </p>
244
+ <span class="summary_desc"><div class='inline'>
245
+ <p>Adds a chart to this worksheets drawing.</p>
296
246
  </div></span>
297
247
 
298
248
  </li>
299
249
 
300
-
301
- <li class="public ">
250
+
251
+ <li class="public ">
302
252
  <span class="summary_signature">
303
253
 
304
- <a href="#rId-instance_method" title="#rId (instance method)">- (String) <strong>rId</strong> </a>
254
+ <a href="#add_image-instance_method" title="#add_image (instance method)">- (Object) <strong>add_image</strong>(options = {}) {|image| ... }</a>
305
255
 
306
256
 
307
257
 
308
258
  </span>
309
259
 
310
260
 
311
- <span class="note title readonly">readonly</span>
312
-
313
-
314
261
 
315
262
 
316
263
 
317
264
 
318
265
 
319
266
 
320
- <span class="summary_desc"><div class='inline'><p>
321
- The relationship Id of thiw worksheet.
322
- </p>
267
+ <span class="summary_desc"><div class='inline'>
268
+ <p>Adds a media item to the worksheets drawing.</p>
323
269
  </div></span>
324
270
 
325
271
  </li>
326
272
 
327
-
328
- <li class="public ">
273
+
274
+ <li class="public ">
329
275
  <span class="summary_signature">
330
276
 
331
- <a href="#rows-instance_method" title="#rows (instance method)">- (SimpleTypedList) <strong>rows</strong> </a>
277
+ <a href="#add_row-instance_method" title="#add_row (instance method)">- (Row) <strong>add_row</strong>(values = [], options = {}) {|@rows.last| ... }</a>
332
278
 
333
279
 
334
280
 
335
281
  </span>
336
282
 
337
283
 
338
- <span class="note title readonly">readonly</span>
339
-
340
-
341
284
 
342
285
 
343
286
 
344
287
 
345
288
 
346
289
 
347
- <span class="summary_desc"><div class='inline'><p>
348
- The rows in this worksheet.
349
- </p>
290
+ <span class="summary_desc"><div class='inline'>
291
+ <p>Adds a row to the worksheet and updates auto fit data.</p>
350
292
  </div></span>
351
293
 
352
294
  </li>
353
295
 
354
-
355
- <li class="public ">
296
+
297
+ <li class="public ">
356
298
  <span class="summary_signature">
357
299
 
358
- <a href="#workbook-instance_method" title="#workbook (instance method)">- (Workbook) <strong>workbook</strong> </a>
300
+ <a href="#drawing-instance_method" title="#drawing (instance method)">- (Drawing) <strong>drawing</strong> </a>
359
301
 
360
302
 
361
303
 
362
304
  </span>
363
305
 
364
306
 
365
-
366
-
367
-
368
307
 
369
308
 
370
309
 
371
310
 
372
311
 
373
312
 
374
- <span class="summary_desc"><div class='inline'><p>
375
- The workbook that owns this worksheet.
376
- </p>
313
+ <span class="summary_desc"><div class='inline'>
314
+ <p>The drawing associated with this worksheet.</p>
377
315
  </div></span>
378
316
 
379
317
  </li>
380
318
 
381
-
382
- </ul>
383
-
384
-
385
-
386
-
387
-
388
- <h2>
389
- Instance Method Summary
390
- <small>(<a href="#" class="summary_toggle">collapse</a>)</small>
391
- </h2>
392
-
393
- <ul class="summary">
394
319
 
395
320
  <li class="public ">
396
321
  <span class="summary_signature">
397
322
 
398
- <a href="#add_chart-instance_method" title="#add_chart (instance method)">- (Object) <strong>add_chart</strong>(chart_type, options = {}) {|chart| ... }</a>
323
+ <a href="#index-instance_method" title="#index (instance method)">- (Integer) <strong>index</strong> </a>
399
324
 
400
325
 
401
326
 
@@ -408,9 +333,8 @@ The workbook that owns this worksheet.
408
333
 
409
334
 
410
335
 
411
- <span class="summary_desc"><div class='inline'><p>
412
- Adds a chart to this worksheets drawing.
413
- </p>
336
+ <span class="summary_desc"><div class='inline'>
337
+ <p>The index of this worksheet in the owning Workbook's worksheets list.</p>
414
338
  </div></span>
415
339
 
416
340
  </li>
@@ -419,12 +343,14 @@ Adds a chart to this worksheets drawing.
419
343
  <li class="public ">
420
344
  <span class="summary_signature">
421
345
 
422
- <a href="#add_image-instance_method" title="#add_image (instance method)">- (Object) <strong>add_image</strong>(options = {}) {|image| ... }</a>
346
+ <a href="#initialize-instance_method" title="#initialize (instance method)">- (Worksheet) <strong>initialize</strong>(wb, options = {}) </a>
423
347
 
424
348
 
425
349
 
426
350
  </span>
427
351
 
352
+ <span class="note title constructor">constructor</span>
353
+
428
354
 
429
355
 
430
356
 
@@ -432,9 +358,8 @@ Adds a chart to this worksheets drawing.
432
358
 
433
359
 
434
360
 
435
- <span class="summary_desc"><div class='inline'><p>
436
- Adds a media item to the worksheets drawing.
437
- </p>
361
+ <span class="summary_desc"><div class='inline'>
362
+ <p>Creates a new worksheet.</p>
438
363
  </div></span>
439
364
 
440
365
  </li>
@@ -443,7 +368,7 @@ Adds a media item to the worksheets drawing.
443
368
  <li class="public ">
444
369
  <span class="summary_signature">
445
370
 
446
- <a href="#add_row-instance_method" title="#add_row (instance method)">- (Row) <strong>add_row</strong>(values = [], options = {}) {|@rows.last| ... }</a>
371
+ <a href="#pn-instance_method" title="#pn (instance method)">- (String) <strong>pn</strong> </a>
447
372
 
448
373
 
449
374
 
@@ -456,9 +381,8 @@ Adds a media item to the worksheets drawing.
456
381
 
457
382
 
458
383
 
459
- <span class="summary_desc"><div class='inline'><p>
460
- Adds a row to the worksheet and updates auto fit data.
461
- </p>
384
+ <span class="summary_desc"><div class='inline'>
385
+ <p>The part name of this worksheet.</p>
462
386
  </div></span>
463
387
 
464
388
  </li>
@@ -467,7 +391,7 @@ Adds a row to the worksheet and updates auto fit data.
467
391
  <li class="public ">
468
392
  <span class="summary_signature">
469
393
 
470
- <a href="#auto_width-instance_method" title="#auto_width (instance method)">- (Float) <strong>auto_width</strong>(col) </a>
394
+ <a href="#relationships-instance_method" title="#relationships (instance method)">- (Relationships) <strong>relationships</strong> </a>
471
395
 
472
396
 
473
397
 
@@ -480,9 +404,8 @@ Adds a row to the worksheet and updates auto fit data.
480
404
 
481
405
 
482
406
 
483
- <span class="summary_desc"><div class='inline'><p>
484
- Determines the proper width for a column based on content.
485
- </p>
407
+ <span class="summary_desc"><div class='inline'>
408
+ <p>The worksheet relationships.</p>
486
409
  </div></span>
487
410
 
488
411
  </li>
@@ -491,14 +414,12 @@ Determines the proper width for a column based on content.
491
414
  <li class="public ">
492
415
  <span class="summary_signature">
493
416
 
494
- <a href="#initialize-instance_method" title="#initialize (instance method)">- (Worksheet) <strong>initialize</strong>(wb, options = {}) </a>
417
+ <a href="#rels_pn-instance_method" title="#rels_pn (instance method)">- (String) <strong>rels_pn</strong> </a>
495
418
 
496
419
 
497
420
 
498
421
  </span>
499
422
 
500
- <span class="note title constructor">constructor</span>
501
-
502
423
 
503
424
 
504
425
 
@@ -506,9 +427,8 @@ Determines the proper width for a column based on content.
506
427
 
507
428
 
508
429
 
509
- <span class="summary_desc"><div class='inline'><p>
510
- Creates a new worksheet.
511
- </p>
430
+ <span class="summary_desc"><div class='inline'>
431
+ <p>The relationship part name of this worksheet.</p>
512
432
  </div></span>
513
433
 
514
434
  </li>
@@ -517,7 +437,7 @@ Creates a new worksheet.
517
437
  <li class="public ">
518
438
  <span class="summary_signature">
519
439
 
520
- <a href="#to_xml-instance_method" title="#to_xml (instance method)">- (String) <strong>to_xml</strong> </a>
440
+ <a href="#rId-instance_method" title="#rId (instance method)">- (String) <strong>rId</strong> </a>
521
441
 
522
442
 
523
443
 
@@ -530,9 +450,8 @@ Creates a new worksheet.
530
450
 
531
451
 
532
452
 
533
- <span class="summary_desc"><div class='inline'><p>
534
- Serializes the worksheet document.
535
- </p>
453
+ <span class="summary_desc"><div class='inline'>
454
+ <p>The relationship Id of thiw worksheet.</p>
536
455
  </div></span>
537
456
 
538
457
  </li>
@@ -541,7 +460,7 @@ Serializes the worksheet document.
541
460
  <li class="public ">
542
461
  <span class="summary_signature">
543
462
 
544
- <a href="#update_auto_fit_data-instance_method" title="#update_auto_fit_data (instance method)">- (Array) <strong>update_auto_fit_data</strong>(cells) </a>
463
+ <a href="#to_xml-instance_method" title="#to_xml (instance method)">- (String) <strong>to_xml</strong> </a>
545
464
 
546
465
 
547
466
 
@@ -554,9 +473,8 @@ Serializes the worksheet document.
554
473
 
555
474
 
556
475
 
557
- <span class="summary_desc"><div class='inline'><p>
558
- Updates auto fit data.
559
- </p>
476
+ <span class="summary_desc"><div class='inline'>
477
+ <p>Serializes the worksheet document.</p>
560
478
  </div></span>
561
479
 
562
480
  </li>
@@ -580,15 +498,13 @@ Updates auto fit data.
580
498
 
581
499
  <div class="note notetag">
582
500
  <strong>Note:</strong>
583
- <div class='inline'><p>
584
- the recommended way to manage worksheets is Workbook#add_worksheet
585
- </p>
501
+ <div class='inline'>
502
+ <p>the recommended way to manage worksheets is Workbook#add_worksheet</p>
586
503
  </div>
587
504
  </div>
588
505
 
589
- <p>
590
- Creates a new worksheet.
591
- </p>
506
+
507
+ <p>Creates a new worksheet.</p>
592
508
 
593
509
 
594
510
  </div>
@@ -609,9 +525,8 @@ Creates a new worksheet.
609
525
 
610
526
 
611
527
  &mdash;
612
- <div class='inline'><p>
613
- a customizable set of options
614
- </p>
528
+ <div class='inline'>
529
+ <p>a customizable set of options</p>
615
530
  </div>
616
531
 
617
532
  </li>
@@ -632,9 +547,8 @@ a customizable set of options
632
547
  <span class="default">
633
548
 
634
549
  </span>
635
- &mdash; <div class='inline'><p>
636
- The name of this sheet.
637
- </p>
550
+ &mdash; <div class='inline'>
551
+ <p>The name of this sheet.</p>
638
552
  </div>
639
553
  </li>
640
554
 
@@ -655,417 +569,61 @@ The name of this sheet.
655
569
  <pre class="lines">
656
570
 
657
571
 
658
- 59
659
- 60
660
- 61
661
- 62
662
- 63
663
- 64
664
- 65
665
- 66</pre>
666
- </td>
667
- <td>
668
- <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 59</span>
669
-
670
- <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>
671
- <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>
672
- <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>
673
- <span class='@workbook ivar id'>@workbook</span><span class='dot token'>.</span><span class='worksheets identifier id'>worksheets</span> <span class='lshft op'>&lt;&lt;</span> <span class='self self kw'>self</span>
674
- <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>
675
- <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'>&quot;Sheet&quot;</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>
676
- <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>
677
- <span class='end end kw'>end</span>
678
- </pre>
679
- </td>
680
- </tr>
681
- </table>
682
- </div>
683
-
684
- </div>
685
-
686
- <div id="instance_attr_details" class="attr_details">
687
- <h2>Instance Attribute Details</h2>
688
-
689
-
690
- <span id=""></span>
691
- <span id="auto_fit_data-instance_method"></span>
692
- <div class="method_details first">
693
- <p class="signature first" id="auto_fit_data-instance_method">
694
-
695
- - (<tt>Array</tt>) <strong>auto_fit_data</strong> <span class="extras">(readonly)</span>
696
-
697
-
698
-
699
- </p><div class="docstring">
700
- <div class="discussion">
701
-
702
- <div class="note notetag">
703
- <strong>Note:</strong>
704
- <div class='inline'><p>
705
- a single auto fit data item is a hash with :longest =&gt; [String] and
706
- :sz=&gt; [Integer] members.
707
- </p>
708
- </div>
709
- </div>
710
-
711
- <p>
712
- An array of content based calculated column widths.
713
- </p>
714
-
715
-
716
- </div>
717
- </div>
718
- <div class="tags">
719
-
720
- <h3>Returns:</h3>
721
- <ul class="return">
722
-
723
- <li>
724
-
725
-
726
- <span class='type'>(<tt>Array</tt>)</span>
727
-
728
-
729
-
730
- &mdash;
731
- <div class='inline'><p>
732
- of Hash
733
- </p>
734
- </div>
735
-
736
- </li>
737
-
738
- </ul>
739
-
740
- </div><table class="source_code">
741
- <tr>
742
- <td>
743
- <pre class="lines">
744
-
745
-
746
572
  34
747
573
  35
748
- 36</pre>
749
- </td>
750
- <td>
751
- <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 34</span>
752
-
753
- <span class='def def kw'>def</span> <span class='auto_fit_data identifier id'>auto_fit_data</span>
754
- <span class='@auto_fit_data ivar id'>@auto_fit_data</span>
755
- <span class='end end kw'>end</span>
756
- </pre>
757
- </td>
758
- </tr>
759
- </table>
760
- </div>
761
-
762
-
763
- <span id=""></span>
764
- <span id="drawing-instance_method"></span>
765
- <div class="method_details ">
766
- <p class="signature " id="drawing-instance_method">
767
-
768
- - (<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>
769
-
770
-
771
-
772
- </p><div class="docstring">
773
- <div class="discussion">
774
-
775
- <div class="note notetag">
776
- <strong>Note:</strong>
777
- <div class='inline'><p>
778
- the recommended way to work with drawings and charts is Worksheet#add_chart
779
- </p>
780
- </div>
781
- </div>
782
-
783
- <p>
784
- The drawing associated with this worksheet.
785
- </p>
786
-
787
-
788
- </div>
789
- </div>
790
- <div class="tags">
791
-
792
- <h3>Returns:</h3>
793
- <ul class="return">
794
-
795
- <li>
796
-
797
-
798
- <span class='type'>(<tt><span class='object_link'><a href="Drawing.html" title="Axlsx::Drawing (class)">Drawing</a></span></tt>)</span>
799
-
800
-
801
-
802
- </li>
803
-
804
- </ul>
805
-
806
- <h3>See Also:</h3>
807
- <ul class="see">
808
-
809
- <li><span class='object_link'><a href="#add_chart-instance_method" title="Axlsx::Worksheet#add_chart (method)">#add_chart</a></span></li>
810
-
811
- </ul>
812
-
813
- </div><table class="source_code">
814
- <tr>
815
- <td>
816
- <pre class="lines">
817
-
818
-
819
- 29
820
- 30
821
- 31</pre>
822
- </td>
823
- <td>
824
- <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 29</span>
825
-
826
- <span class='def def kw'>def</span> <span class='drawing identifier id'>drawing</span>
827
- <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>
828
- <span class='end end kw'>end</span>
829
- </pre>
830
- </td>
831
- </tr>
832
- </table>
833
- </div>
834
-
835
-
836
- <span id=""></span>
837
- <span id="index-instance_method"></span>
838
- <div class="method_details ">
839
- <p class="signature " id="index-instance_method">
840
-
841
- - (<tt>Integer</tt>) <strong>index</strong> <span class="extras">(readonly)</span>
842
-
843
-
844
-
845
- </p><div class="docstring">
846
- <div class="discussion">
847
- <p>
848
- The index of this worksheet in the owning Workbook&#8217;s worksheets list.
849
- </p>
850
-
851
-
852
- </div>
853
- </div>
854
- <div class="tags">
855
-
856
- <h3>Returns:</h3>
857
- <ul class="return">
858
-
859
- <li>
860
-
861
-
862
- <span class='type'>(<tt>Integer</tt>)</span>
863
-
864
-
865
-
866
- </li>
867
-
868
- </ul>
869
-
870
- </div><table class="source_code">
871
- <tr>
872
- <td>
873
- <pre class="lines">
874
-
875
-
876
- 50
877
- 51
878
- 52</pre>
879
- </td>
880
- <td>
881
- <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 50</span>
882
-
883
- <span class='def def kw'>def</span> <span class='index identifier id'>index</span>
884
- <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>
885
- <span class='end end kw'>end</span>
886
- </pre>
887
- </td>
888
- </tr>
889
- </table>
890
- </div>
891
-
892
-
893
- <span id="name=-instance_method"></span>
894
- <span id="name-instance_method"></span>
895
- <div class="method_details ">
896
- <p class="signature " id="name-instance_method">
897
-
898
- - (<tt>String</tt>) <strong>name</strong>
899
-
900
-
901
-
902
- </p><div class="docstring">
903
- <div class="discussion">
904
- <p>
905
- The name of the worksheet
906
- </p>
907
-
908
-
909
- </div>
910
- </div>
911
- <div class="tags">
912
-
913
- <h3>Returns:</h3>
914
- <ul class="return">
915
-
916
- <li>
917
-
918
-
919
- <span class='type'>(<tt>String</tt>)</span>
920
-
921
-
922
-
923
- </li>
924
-
925
- </ul>
926
-
927
- </div><table class="source_code">
928
- <tr>
929
- <td>
930
- <pre class="lines">
931
-
932
-
933
- 9
934
- 10
935
- 11</pre>
936
- </td>
937
- <td>
938
- <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 9</span>
939
-
940
- <span class='def def kw'>def</span> <span class='name identifier id'>name</span>
941
- <span class='@name ivar id'>@name</span>
942
- <span class='end end kw'>end</span>
943
- </pre>
944
- </td>
945
- </tr>
946
- </table>
947
- </div>
948
-
949
-
950
- <span id=""></span>
951
- <span id="pn-instance_method"></span>
952
- <div class="method_details ">
953
- <p class="signature " id="pn-instance_method">
954
-
955
- - (<tt>String</tt>) <strong>pn</strong> <span class="extras">(readonly)</span>
956
-
957
-
958
-
959
- </p><div class="docstring">
960
- <div class="discussion">
961
- <p>
962
- The part name of this worksheet
963
- </p>
964
-
965
-
966
- </div>
967
- </div>
968
- <div class="tags">
969
-
970
- <h3>Returns:</h3>
971
- <ul class="return">
972
-
973
- <li>
974
-
975
-
976
- <span class='type'>(<tt>String</tt>)</span>
977
-
978
-
979
-
980
- </li>
981
-
982
- </ul>
983
-
984
- </div><table class="source_code">
985
- <tr>
986
- <td>
987
- <pre class="lines">
988
-
989
-
574
+ 36
575
+ 37
990
576
  38
991
577
  39
992
- 40</pre>
578
+ 40
579
+ 41
580
+ 42</pre>
993
581
  </td>
994
582
  <td>
995
- <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 38</span>
583
+ <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 34</span>
996
584
 
997
- <span class='def def kw'>def</span> <span class='pn identifier id'>pn</span>
998
- <span class='dstring node'>&quot;#{WORKSHEET_PN % (index+1)}&quot;</span>
999
- <span class='end end kw'>end</span>
1000
- </pre>
585
+ <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>
586
+ <span class='ivar'>@drawing</span> <span class='op'>=</span> <span class='kw'>nil</span>
587
+ <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>
588
+ <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>
589
+ <span class='ivar'>@workbook</span><span class='period'>.</span><span class='id worksheets'>worksheets</span> <span class='op'>&lt;&lt;</span> <span class='kw'>self</span>
590
+ <span class='ivar'>@auto_fit_data</span> <span class='op'>=</span> <span class='lbracket'>[</span><span class='rbracket'>]</span>
591
+ <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'>&quot;</span><span class='tstring_content'>Sheet</span><span class='tstring_end'>&quot;</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>
592
+ <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>
593
+ <span class='kw'>end</span></pre>
1001
594
  </td>
1002
595
  </tr>
1003
596
  </table>
1004
597
  </div>
1005
-
1006
-
1007
- <span id=""></span>
1008
- <span id="relationships-instance_method"></span>
1009
- <div class="method_details ">
1010
- <p class="signature " id="relationships-instance_method">
1011
598
 
1012
- - (<tt>Object</tt>) <strong>relationships</strong> <span class="extras">(readonly)</span>
1013
-
1014
-
1015
-
1016
- </p><div class="docstring">
1017
- <div class="discussion">
1018
- <p>
1019
- The worksheet&#8217;s relationships.
1020
- </p>
1021
-
1022
-
1023
- </div>
1024
599
  </div>
1025
- <div class="tags">
1026
-
1027
600
 
1028
- </div><table class="source_code">
1029
- <tr>
1030
- <td>
1031
- <pre class="lines">
1032
-
1033
-
1034
- 17
1035
- 18
1036
- 19
1037
- 20
1038
- 21</pre>
1039
- </td>
1040
- <td>
1041
- <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 17</span>
1042
-
1043
- <span class='def def kw'>def</span> <span class='relationships identifier id'>relationships</span>
1044
- <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>
1045
- <span class='r identifier id'>r</span> <span class='lshft op'>&lt;&lt;</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'>&quot;../#{@drawing.pn}&quot;</span><span class='rparen token'>)</span> <span class='if if_mod kw'>if</span> <span class='@drawing ivar id'>@drawing</span>
1046
- <span class='r identifier id'>r</span>
1047
- <span class='end end kw'>end</span>
1048
- </pre>
1049
- </td>
1050
- </tr>
1051
- </table>
1052
- </div>
601
+ <div id="instance_attr_details" class="attr_details">
602
+ <h2>Instance Attribute Details</h2>
1053
603
 
1054
604
 
1055
605
  <span id=""></span>
1056
- <span id="rels_pn-instance_method"></span>
1057
- <div class="method_details ">
1058
- <p class="signature " id="rels_pn-instance_method">
606
+ <span id="auto_fit_data-instance_method"></span>
607
+ <div class="method_details first">
608
+ <p class="signature first" id="auto_fit_data-instance_method">
1059
609
 
1060
- - (<tt>String</tt>) <strong>rels_pn</strong> <span class="extras">(readonly)</span>
610
+ - (<tt>Array</tt>) <strong>auto_fit_data</strong> <span class="extras">(readonly)</span>
1061
611
 
1062
612
 
1063
613
 
1064
614
  </p><div class="docstring">
1065
615
  <div class="discussion">
1066
- <p>
1067
- The relationship part name of this worksheet
1068
- </p>
616
+
617
+ <div class="note notetag">
618
+ <strong>Note:</strong>
619
+ <div class='inline'>
620
+ <p>a single auto fit data item is a hash with :longest =&gt; [String] and
621
+ :sz=&gt; [Integer] members.</p>
622
+ </div>
623
+ </div>
624
+
625
+
626
+ <p>An array of content based calculated column widths.</p>
1069
627
 
1070
628
 
1071
629
  </div>
@@ -1078,9 +636,14 @@ The relationship part name of this worksheet
1078
636
  <li>
1079
637
 
1080
638
 
1081
- <span class='type'>(<tt>String</tt>)</span>
639
+ <span class='type'>(<tt>Array</tt>)</span>
640
+
1082
641
 
1083
642
 
643
+ &mdash;
644
+ <div class='inline'>
645
+ <p>of Hash</p>
646
+ </div>
1084
647
 
1085
648
  </li>
1086
649
 
@@ -1092,37 +655,35 @@ The relationship part name of this worksheet
1092
655
  <pre class="lines">
1093
656
 
1094
657
 
1095
- 42
1096
- 43
1097
- 44</pre>
658
+ 25
659
+ 26
660
+ 27</pre>
1098
661
  </td>
1099
662
  <td>
1100
- <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 42</span>
663
+ <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 25</span>
1101
664
 
1102
- <span class='def def kw'>def</span> <span class='rels_pn identifier id'>rels_pn</span>
1103
- <span class='dstring node'>&quot;#{WORKSHEET_RELS_PN % (index+1)}&quot;</span>
1104
- <span class='end end kw'>end</span>
1105
- </pre>
665
+ <span class='kw'>def</span> <span class='id auto_fit_data'>auto_fit_data</span>
666
+ <span class='ivar'>@auto_fit_data</span>
667
+ <span class='kw'>end</span></pre>
1106
668
  </td>
1107
669
  </tr>
1108
670
  </table>
1109
671
  </div>
1110
672
 
1111
673
 
1112
- <span id=""></span>
1113
- <span id="rId-instance_method"></span>
674
+ <span id="name=-instance_method"></span>
675
+ <span id="name-instance_method"></span>
1114
676
  <div class="method_details ">
1115
- <p class="signature " id="rId-instance_method">
677
+ <p class="signature " id="name-instance_method">
1116
678
 
1117
- - (<tt>String</tt>) <strong>rId</strong> <span class="extras">(readonly)</span>
679
+ - (<tt>String</tt>) <strong>name</strong>
1118
680
 
1119
681
 
1120
682
 
1121
683
  </p><div class="docstring">
1122
684
  <div class="discussion">
1123
- <p>
1124
- The relationship Id of thiw worksheet
1125
- </p>
685
+
686
+ <p>The name of the worksheet</p>
1126
687
 
1127
688
 
1128
689
  </div>
@@ -1149,17 +710,16 @@ The relationship Id of thiw worksheet
1149
710
  <pre class="lines">
1150
711
 
1151
712
 
1152
- 46
1153
- 47
1154
- 48</pre>
713
+ 9
714
+ 10
715
+ 11</pre>
1155
716
  </td>
1156
717
  <td>
1157
- <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 46</span>
718
+ <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 9</span>
1158
719
 
1159
- <span class='def def kw'>def</span> <span class='rId identifier id'>rId</span>
1160
- <span class='dstring node'>&quot;rId#{index+1}&quot;</span>
1161
- <span class='end end kw'>end</span>
1162
- </pre>
720
+ <span class='kw'>def</span> <span class='id name'>name</span>
721
+ <span class='ivar'>@name</span>
722
+ <span class='kw'>end</span></pre>
1163
723
  </td>
1164
724
  </tr>
1165
725
  </table>
@@ -1180,15 +740,13 @@ The relationship Id of thiw worksheet
1180
740
 
1181
741
  <div class="note notetag">
1182
742
  <strong>Note:</strong>
1183
- <div class='inline'><p>
1184
- The recommended way to manage rows is Worksheet#add_row
1185
- </p>
743
+ <div class='inline'>
744
+ <p>The recommended way to manage rows is Worksheet#add_row</p>
1186
745
  </div>
1187
746
  </div>
1188
747
 
1189
- <p>
1190
- The rows in this worksheet
1191
- </p>
748
+
749
+ <p>The rows in this worksheet</p>
1192
750
 
1193
751
 
1194
752
  </div>
@@ -1222,17 +780,16 @@ The rows in this worksheet
1222
780
  <pre class="lines">
1223
781
 
1224
782
 
1225
- 23
1226
- 24
1227
- 25</pre>
783
+ 20
784
+ 21
785
+ 22</pre>
1228
786
  </td>
1229
787
  <td>
1230
- <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 23</span>
788
+ <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 20</span>
1231
789
 
1232
- <span class='def def kw'>def</span> <span class='rows identifier id'>rows</span>
1233
- <span class='@rows ivar id'>@rows</span>
1234
- <span class='end end kw'>end</span>
1235
- </pre>
790
+ <span class='kw'>def</span> <span class='id rows'>rows</span>
791
+ <span class='ivar'>@rows</span>
792
+ <span class='kw'>end</span></pre>
1236
793
  </td>
1237
794
  </tr>
1238
795
  </table>
@@ -1250,9 +807,8 @@ The rows in this worksheet
1250
807
 
1251
808
  </p><div class="docstring">
1252
809
  <div class="discussion">
1253
- <p>
1254
- The workbook that owns this worksheet
1255
- </p>
810
+
811
+ <p>The workbook that owns this worksheet</p>
1256
812
 
1257
813
 
1258
814
  </div>
@@ -1286,10 +842,9 @@ The workbook that owns this worksheet
1286
842
  <td>
1287
843
  <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 13</span>
1288
844
 
1289
- <span class='def def kw'>def</span> <span class='workbook identifier id'>workbook</span>
1290
- <span class='@workbook ivar id'>@workbook</span>
1291
- <span class='end end kw'>end</span>
1292
- </pre>
845
+ <span class='kw'>def</span> <span class='id workbook'>workbook</span>
846
+ <span class='ivar'>@workbook</span>
847
+ <span class='kw'>end</span></pre>
1293
848
  </td>
1294
849
  </tr>
1295
850
  </table>
@@ -1314,18 +869,16 @@ The workbook that owns this worksheet
1314
869
 
1315
870
  <div class="note notetag">
1316
871
  <strong>Note:</strong>
1317
- <div class='inline'><p>
1318
- each chart type also specifies additional options
1319
- </p>
872
+ <div class='inline'>
873
+ <p>each chart type also specifies additional options</p>
1320
874
  </div>
1321
875
  </div>
1322
876
 
1323
- <p>
1324
- Adds a chart to this worksheets drawing. This is the recommended way to
877
+
878
+ <p>Adds a chart to this worksheets drawing. This is the recommended way to
1325
879
  create charts for your worksheet. This method wraps the complexity of
1326
880
  dealing with ooxml drawing, anchors, markers graphic frames chart objects
1327
- and all the other dirty details.
1328
- </p>
881
+ and all the other dirty details.</p>
1329
882
 
1330
883
 
1331
884
  </div>
@@ -1357,9 +910,8 @@ and all the other dirty details.
1357
910
 
1358
911
 
1359
912
  &mdash;
1360
- <div class='inline'><p>
1361
- a customizable set of options
1362
- </p>
913
+ <div class='inline'>
914
+ <p>a customizable set of options</p>
1363
915
  </div>
1364
916
 
1365
917
  </li>
@@ -1457,21 +1009,20 @@ a customizable set of options
1457
1009
  <pre class="lines">
1458
1010
 
1459
1011
 
1460
- 116
1461
- 117
1462
- 118
1463
- 119
1464
- 120</pre>
1012
+ 105
1013
+ 106
1014
+ 107
1015
+ 108
1016
+ 109</pre>
1465
1017
  </td>
1466
1018
  <td>
1467
- <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 116</span>
1468
-
1469
- <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>
1470
- <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>
1471
- <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>
1472
- <span class='chart identifier id'>chart</span>
1473
- <span class='end end kw'>end</span>
1474
- </pre>
1019
+ <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 105</span>
1020
+
1021
+ <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>
1022
+ <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>
1023
+ <span class='kw'>yield</span> <span class='id chart'>chart</span> <span class='kw'>if</span> <span class='id block_given?'>block_given?</span>
1024
+ <span class='id chart'>chart</span>
1025
+ <span class='kw'>end</span></pre>
1475
1026
  </td>
1476
1027
  </tr>
1477
1028
  </table>
@@ -1486,9 +1037,8 @@ a customizable set of options
1486
1037
 
1487
1038
  </p><div class="docstring">
1488
1039
  <div class="discussion">
1489
- <p>
1490
- Adds a media item to the worksheets drawing
1491
- </p>
1040
+
1041
+ <p>Adds a media item to the worksheets drawing</p>
1492
1042
 
1493
1043
 
1494
1044
  </div>
@@ -1520,9 +1070,8 @@ Adds a media item to the worksheets drawing
1520
1070
 
1521
1071
 
1522
1072
  &mdash;
1523
- <div class='inline'><p>
1524
- a customizable set of options
1525
- </p>
1073
+ <div class='inline'>
1074
+ <p>a customizable set of options</p>
1526
1075
  </div>
1527
1076
 
1528
1077
  </li>
@@ -1541,9 +1090,8 @@ a customizable set of options
1541
1090
  <span class="default">
1542
1091
 
1543
1092
  </span>
1544
- &mdash; <div class='inline'><p>
1545
- unknown
1546
- </p>
1093
+ &mdash; <div class='inline'>
1094
+ <p>unknown</p>
1547
1095
  </div>
1548
1096
  </li>
1549
1097
 
@@ -1570,21 +1118,20 @@ unknown
1570
1118
  <pre class="lines">
1571
1119
 
1572
1120
 
1573
- 125
1574
- 126
1575
- 127
1576
- 128
1577
- 129</pre>
1121
+ 114
1122
+ 115
1123
+ 116
1124
+ 117
1125
+ 118</pre>
1578
1126
  </td>
1579
1127
  <td>
1580
- <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 125</span>
1581
-
1582
- <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>
1583
- <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>
1584
- <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>
1585
- <span class='image identifier id'>image</span>
1586
- <span class='end end kw'>end</span>
1587
- </pre>
1128
+ <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 114</span>
1129
+
1130
+ <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>
1131
+ <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>
1132
+ <span class='kw'>yield</span> <span class='id image'>image</span> <span class='kw'>if</span> <span class='id block_given?'>block_given?</span>
1133
+ <span class='id image'>image</span>
1134
+ <span class='kw'>end</span></pre>
1588
1135
  </td>
1589
1136
  </tr>
1590
1137
  </table>
@@ -1599,9 +1146,8 @@ unknown
1599
1146
 
1600
1147
  </p><div class="docstring">
1601
1148
  <div class="discussion">
1602
- <p>
1603
- Adds a row to the worksheet and updates auto fit data
1604
- </p>
1149
+
1150
+ <p>Adds a row to the worksheet and updates auto fit data</p>
1605
1151
 
1606
1152
 
1607
1153
  </div>
@@ -1622,9 +1168,8 @@ Adds a row to the worksheet and updates auto fit data
1622
1168
 
1623
1169
 
1624
1170
  &mdash;
1625
- <div class='inline'><p>
1626
- a customizable set of options
1627
- </p>
1171
+ <div class='inline'>
1172
+ <p>a customizable set of options</p>
1628
1173
  </div>
1629
1174
 
1630
1175
  </li>
@@ -1702,32 +1247,31 @@ a customizable set of options
1702
1247
  <pre class="lines">
1703
1248
 
1704
1249
 
1705
- 96
1706
- 97
1707
- 98
1708
- 99
1709
- 100
1710
- 101</pre>
1250
+ 85
1251
+ 86
1252
+ 87
1253
+ 88
1254
+ 89
1255
+ 90</pre>
1711
1256
  </td>
1712
1257
  <td>
1713
- <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 96</span>
1714
-
1715
- <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>
1716
- <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>
1717
- <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>
1718
- <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>
1719
- <span class='@rows ivar id'>@rows</span><span class='dot token'>.</span><span class='last identifier id'>last</span>
1720
- <span class='end end kw'>end</span>
1721
- </pre>
1258
+ <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 85</span>
1259
+
1260
+ <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>
1261
+ <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>
1262
+ <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>
1263
+ <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>
1264
+ <span class='ivar'>@rows</span><span class='period'>.</span><span class='id last'>last</span>
1265
+ <span class='kw'>end</span></pre>
1722
1266
  </td>
1723
1267
  </tr>
1724
1268
  </table>
1725
1269
  </div>
1726
1270
 
1727
1271
  <div class="method_details ">
1728
- <p class="signature " id="auto_width-instance_method">
1272
+ <p class="signature " id="drawing-instance_method">
1729
1273
 
1730
- - (<tt>Float</tt>) <strong>auto_width</strong>(col)
1274
+ - (<tt><span class='object_link'><a href="Drawing.html" title="Axlsx::Drawing (class)">Drawing</a></span></tt>) <strong>drawing</strong>
1731
1275
 
1732
1276
 
1733
1277
 
@@ -1736,54 +1280,137 @@ a customizable set of options
1736
1280
 
1737
1281
  <div class="note notetag">
1738
1282
  <strong>Note:</strong>
1739
- <div class='inline'><p>
1740
- From ECMA docs
1741
- </p>
1742
- <pre class="code">
1743
- <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>
1744
- <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.
1745
- width = Truncate([{Number of Characters} * {Maximum Digit Width} + {5 pixel padding}]/{Maximum Digit Width}*256)/256
1746
- </span></pre>
1283
+ <div class='inline'>
1284
+ <p>the recommended way to work with drawings and charts is Worksheet#add_chart</p>
1747
1285
  </div>
1748
1286
  </div>
1749
1287
 
1750
- <p>
1751
- Determines the proper width for a column based on content.
1752
- </p>
1288
+
1289
+ <p>The drawing associated with this worksheet.</p>
1753
1290
 
1754
1291
 
1755
1292
  </div>
1756
1293
  </div>
1757
1294
  <div class="tags">
1758
- <h3>Parameters:</h3>
1759
- <ul class="param">
1295
+
1296
+ <h3>Returns:</h3>
1297
+ <ul class="return">
1760
1298
 
1761
1299
  <li>
1762
1300
 
1763
- <span class='name'>A</span>
1764
1301
 
1765
-
1766
- <span class='type'>(<tt>Hash</tt>)</span>
1302
+ <span class='type'>(<tt><span class='object_link'><a href="Drawing.html" title="Axlsx::Drawing (class)">Drawing</a></span></tt>)</span>
1767
1303
 
1768
1304
 
1769
1305
 
1770
- &mdash;
1771
- <div class='inline'><p>
1772
- hash of auto_fit_data
1773
- </p>
1306
+ </li>
1307
+
1308
+ </ul>
1309
+
1310
+ <h3>See Also:</h3>
1311
+ <ul class="see">
1312
+
1313
+ <li><span class='object_link'><a href="#add_chart-instance_method" title="Axlsx::Worksheet#add_chart (method)">#add_chart</a></span></li>
1314
+
1315
+ </ul>
1316
+
1317
+ </div><table class="source_code">
1318
+ <tr>
1319
+ <td>
1320
+ <pre class="lines">
1321
+
1322
+
1323
+ 76
1324
+ 77
1325
+ 78</pre>
1326
+ </td>
1327
+ <td>
1328
+ <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 76</span>
1329
+
1330
+ <span class='kw'>def</span> <span class='id drawing'>drawing</span>
1331
+ <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>
1332
+ <span class='kw'>end</span></pre>
1333
+ </td>
1334
+ </tr>
1335
+ </table>
1336
+ </div>
1337
+
1338
+ <div class="method_details ">
1339
+ <p class="signature " id="index-instance_method">
1340
+
1341
+ - (<tt>Integer</tt>) <strong>index</strong>
1342
+
1343
+
1344
+
1345
+ </p><div class="docstring">
1346
+ <div class="discussion">
1347
+
1348
+ <p>The index of this worksheet in the owning Workbook's worksheets list.</p>
1349
+
1350
+
1351
+ </div>
1774
1352
  </div>
1353
+ <div class="tags">
1354
+
1355
+ <h3>Returns:</h3>
1356
+ <ul class="return">
1357
+
1358
+ <li>
1359
+
1360
+
1361
+ <span class='type'>(<tt>Integer</tt>)</span>
1362
+
1363
+
1775
1364
 
1776
1365
  </li>
1777
1366
 
1778
1367
  </ul>
1779
1368
 
1369
+ </div><table class="source_code">
1370
+ <tr>
1371
+ <td>
1372
+ <pre class="lines">
1373
+
1374
+
1375
+ 68
1376
+ 69
1377
+ 70</pre>
1378
+ </td>
1379
+ <td>
1380
+ <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 68</span>
1381
+
1382
+ <span class='kw'>def</span> <span class='id index'>index</span>
1383
+ <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>
1384
+ <span class='kw'>end</span></pre>
1385
+ </td>
1386
+ </tr>
1387
+ </table>
1388
+ </div>
1389
+
1390
+ <div class="method_details ">
1391
+ <p class="signature " id="pn-instance_method">
1392
+
1393
+ - (<tt>String</tt>) <strong>pn</strong>
1394
+
1395
+
1396
+
1397
+ </p><div class="docstring">
1398
+ <div class="discussion">
1399
+
1400
+ <p>The part name of this worksheet</p>
1401
+
1402
+
1403
+ </div>
1404
+ </div>
1405
+ <div class="tags">
1406
+
1780
1407
  <h3>Returns:</h3>
1781
1408
  <ul class="return">
1782
1409
 
1783
1410
  <li>
1784
1411
 
1785
1412
 
1786
- <span class='type'>(<tt>Float</tt>)</span>
1413
+ <span class='type'>(<tt>String</tt>)</span>
1787
1414
 
1788
1415
 
1789
1416
 
@@ -1797,48 +1424,32 @@ hash of auto_fit_data
1797
1424
  <pre class="lines">
1798
1425
 
1799
1426
 
1800
- 199
1801
- 200
1802
- 201
1803
- 202
1804
- 203
1805
- 204
1806
- 205
1807
- 206
1808
- 207
1809
- 208</pre>
1427
+ 50
1428
+ 51
1429
+ 52</pre>
1810
1430
  </td>
1811
1431
  <td>
1812
- <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 199</span>
1813
-
1814
- <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>
1815
- <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>
1816
- <span class='mdw_count identifier id'>mdw_count</span> <span class='assign token'>=</span> <span class='integer val'>0</span>
1817
- <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>
1818
- <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>
1819
- <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>
1820
- <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'>&gt;=</span> <span class='mdw identifier id'>mdw</span>
1821
- <span class='end end kw'>end</span>
1822
- <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>
1823
- <span class='end end kw'>end</span>
1824
- </pre>
1432
+ <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 50</span>
1433
+
1434
+ <span class='kw'>def</span> <span class='id pn'>pn</span>
1435
+ <span class='tstring'><span class='tstring_beg'>&quot;</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'>&quot;</span></span>
1436
+ <span class='kw'>end</span></pre>
1825
1437
  </td>
1826
1438
  </tr>
1827
1439
  </table>
1828
1440
  </div>
1829
1441
 
1830
1442
  <div class="method_details ">
1831
- <p class="signature " id="to_xml-instance_method">
1443
+ <p class="signature " id="relationships-instance_method">
1832
1444
 
1833
- - (<tt>String</tt>) <strong>to_xml</strong>
1445
+ - (<tt><span class='object_link'><a href="Relationships.html" title="Axlsx::Relationships (class)">Relationships</a></span></tt>) <strong>relationships</strong>
1834
1446
 
1835
1447
 
1836
1448
 
1837
1449
  </p><div class="docstring">
1838
1450
  <div class="discussion">
1839
- <p>
1840
- Serializes the worksheet document
1841
- </p>
1451
+
1452
+ <p>The worksheet relationships. This is managed automatically by the worksheet</p>
1842
1453
 
1843
1454
 
1844
1455
  </div>
@@ -1851,7 +1462,7 @@ Serializes the worksheet document
1851
1462
  <li>
1852
1463
 
1853
1464
 
1854
- <span class='type'>(<tt>String</tt>)</span>
1465
+ <span class='type'>(<tt><span class='object_link'><a href="Relationships.html" title="Axlsx::Relationships (class)">Relationships</a></span></tt>)</span>
1855
1466
 
1856
1467
 
1857
1468
 
@@ -1865,114 +1476,155 @@ Serializes the worksheet document
1865
1476
  <pre class="lines">
1866
1477
 
1867
1478
 
1868
- 133
1869
- 134
1870
- 135
1871
- 136
1872
- 137
1873
- 138
1874
- 139
1875
- 140
1876
- 141
1877
- 142
1878
- 143
1879
- 144
1880
- 145
1881
1479
  146
1882
1480
  147
1883
1481
  148
1884
1482
  149
1885
- 150
1886
- 151
1887
- 152
1888
- 153</pre>
1483
+ 150</pre>
1889
1484
  </td>
1890
1485
  <td>
1891
- <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 133</span>
1892
-
1893
- <span class='def def kw'>def</span> <span class='to_xml identifier id'>to_xml</span>
1894
- <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'>&gt;</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>
1895
- <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'>&gt;</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'>&gt;</span> <span class='XML_NS_R constant id'>XML_NS_R</span><span class='rparen token'>)</span> <span class='lbrace token'>{</span>
1896
- <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'>&gt;</span> <span class='integer val'>0</span>
1897
- <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='cols identifier id'>cols</span> <span class='lbrace token'>{</span>
1898
- <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>
1899
- <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>
1900
- <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'>&gt;</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'>&gt;</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'>&gt;</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'>&gt;</span><span class='string val'>&quot;true&quot;</span><span class='rparen token'>)</span>
1901
- <span class='end end kw'>end</span>
1902
- <span class='rbrace token'>}</span>
1903
- <span class='end end kw'>end</span>
1904
- <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='sheetData identifier id'>sheetData</span> <span class='lbrace token'>{</span>
1905
- <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>
1906
- <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>
1907
- <span class='end end kw'>end</span>
1908
- <span class='rbrace token'>}</span>
1909
- <span class='xml identifier id'>xml</span><span class='dot token'>.</span><span class='drawing identifier id'>drawing</span> <span class='symbol val'>:&quot;r:id&quot;</span><span class='assign token'>=</span><span class='gt op'>&gt;</span><span class='string val'>&quot;rId1&quot;</span> <span class='if if_mod kw'>if</span> <span class='@drawing ivar id'>@drawing</span>
1910
- <span class='rbrace token'>}</span>
1911
- <span class='end end kw'>end</span>
1912
- <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'>&gt;</span><span class='integer val'>0</span><span class='comma token'>,</span> <span class='symbol val'>:save_with=</span><span class='gt op'>&gt;</span><span class='integer val'>0</span><span class='rparen token'>)</span>
1913
- <span class='end end kw'>end</span>
1914
- </pre>
1486
+ <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 146</span>
1487
+
1488
+ <span class='kw'>def</span> <span class='id relationships'>relationships</span>
1489
+ <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>
1490
+ <span class='id r'>r</span> <span class='op'>&lt;&lt;</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'>&quot;</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'>&quot;</span></span><span class='rparen'>)</span> <span class='kw'>if</span> <span class='ivar'>@drawing</span>
1491
+ <span class='id r'>r</span>
1492
+ <span class='kw'>end</span></pre>
1915
1493
  </td>
1916
1494
  </tr>
1917
1495
  </table>
1918
1496
  </div>
1919
1497
 
1920
1498
  <div class="method_details ">
1921
- <p class="signature " id="update_auto_fit_data-instance_method">
1499
+ <p class="signature " id="rels_pn-instance_method">
1922
1500
 
1923
- - (<tt>Array</tt>) <strong>update_auto_fit_data</strong>(cells)
1501
+ - (<tt>String</tt>) <strong>rels_pn</strong>
1924
1502
 
1925
1503
 
1926
1504
 
1927
1505
  </p><div class="docstring">
1928
1506
  <div class="discussion">
1929
- <p>
1930
- Updates auto fit data. Autofit data attempts to determine the cell in a
1931
- column that has the greatest width by comparing the length of the text
1932
- multiplied by the size of the font.
1933
- </p>
1507
+
1508
+ <p>The relationship part name of this worksheet</p>
1934
1509
 
1935
1510
 
1936
1511
  </div>
1937
1512
  </div>
1938
1513
  <div class="tags">
1939
- <h3>Parameters:</h3>
1940
- <ul class="param">
1514
+
1515
+ <h3>Returns:</h3>
1516
+ <ul class="return">
1941
1517
 
1942
1518
  <li>
1943
1519
 
1944
- <span class='name'>cells</span>
1945
-
1946
-
1947
- <span class='type'>(<tt>Array</tt>)</span>
1948
1520
 
1521
+ <span class='type'>(<tt>String</tt>)</span>
1949
1522
 
1950
1523
 
1951
- &mdash;
1952
- <div class='inline'><p>
1953
- an array of cells
1954
- </p>
1955
- </div>
1956
1524
 
1957
1525
  </li>
1958
1526
 
1959
1527
  </ul>
1960
1528
 
1529
+ </div><table class="source_code">
1530
+ <tr>
1531
+ <td>
1532
+ <pre class="lines">
1533
+
1534
+
1535
+ 56
1536
+ 57
1537
+ 58</pre>
1538
+ </td>
1539
+ <td>
1540
+ <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 56</span>
1541
+
1542
+ <span class='kw'>def</span> <span class='id rels_pn'>rels_pn</span>
1543
+ <span class='tstring'><span class='tstring_beg'>&quot;</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'>&quot;</span></span>
1544
+ <span class='kw'>end</span></pre>
1545
+ </td>
1546
+ </tr>
1547
+ </table>
1548
+ </div>
1549
+
1550
+ <div class="method_details ">
1551
+ <p class="signature " id="rId-instance_method">
1552
+
1553
+ - (<tt>String</tt>) <strong>rId</strong>
1554
+
1555
+
1556
+
1557
+ </p><div class="docstring">
1558
+ <div class="discussion">
1559
+
1560
+ <p>The relationship Id of thiw worksheet</p>
1561
+
1562
+
1563
+ </div>
1564
+ </div>
1565
+ <div class="tags">
1566
+
1961
1567
  <h3>Returns:</h3>
1962
1568
  <ul class="return">
1963
1569
 
1964
1570
  <li>
1965
1571
 
1966
1572
 
1967
- <span class='type'>(<tt>Array</tt>)</span>
1573
+ <span class='type'>(<tt>String</tt>)</span>
1968
1574
 
1969
1575
 
1970
1576
 
1971
- &mdash;
1972
- <div class='inline'><p>
1973
- of Cell objects
1974
- </p>
1577
+ </li>
1578
+
1579
+ </ul>
1580
+
1581
+ </div><table class="source_code">
1582
+ <tr>
1583
+ <td>
1584
+ <pre class="lines">
1585
+
1586
+
1587
+ 62
1588
+ 63
1589
+ 64</pre>
1590
+ </td>
1591
+ <td>
1592
+ <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 62</span>
1593
+
1594
+ <span class='kw'>def</span> <span class='id rId'>rId</span>
1595
+ <span class='tstring'><span class='tstring_beg'>&quot;</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'>&quot;</span></span>
1596
+ <span class='kw'>end</span></pre>
1597
+ </td>
1598
+ </tr>
1599
+ </table>
1600
+ </div>
1601
+
1602
+ <div class="method_details ">
1603
+ <p class="signature " id="to_xml-instance_method">
1604
+
1605
+ - (<tt>String</tt>) <strong>to_xml</strong>
1606
+
1607
+
1608
+
1609
+ </p><div class="docstring">
1610
+ <div class="discussion">
1611
+
1612
+ <p>Serializes the worksheet document</p>
1613
+
1614
+
1615
+ </div>
1975
1616
  </div>
1617
+ <div class="tags">
1618
+
1619
+ <h3>Returns:</h3>
1620
+ <ul class="return">
1621
+
1622
+ <li>
1623
+
1624
+
1625
+ <span class='type'>(<tt>String</tt>)</span>
1626
+
1627
+
1976
1628
 
1977
1629
  </li>
1978
1630
 
@@ -1984,49 +1636,52 @@ of Cell objects
1984
1636
  <pre class="lines">
1985
1637
 
1986
1638
 
1987
- 171
1988
- 172
1989
- 173
1990
- 174
1991
- 175
1992
- 176
1993
- 177
1994
- 178
1995
- 179
1996
- 180
1997
- 181
1998
- 182
1999
- 183
2000
- 184
2001
- 185
2002
- 186
2003
- 187
2004
- 188
2005
- 189</pre>
1639
+ 122
1640
+ 123
1641
+ 124
1642
+ 125
1643
+ 126
1644
+ 127
1645
+ 128
1646
+ 129
1647
+ 130
1648
+ 131
1649
+ 132
1650
+ 133
1651
+ 134
1652
+ 135
1653
+ 136
1654
+ 137
1655
+ 138
1656
+ 139
1657
+ 140
1658
+ 141
1659
+ 142</pre>
2006
1660
  </td>
2007
1661
  <td>
2008
- <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 171</span>
2009
-
2010
- <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>
2011
- <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>
2012
- <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>
2013
- <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>
2014
-
2015
- <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>
2016
- <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'>&gt;</span><span class='string val'>&quot;&quot;</span><span class='comma token'>,</span> <span class='symbol val'>:sz=</span><span class='gt op'>&gt;</span><span class='sz identifier id'>sz</span><span class='rbrace token'>}</span>
2017
- <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>
2018
- <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>
2019
- <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>
2020
-
2021
- <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'>&lt;</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>
2022
- <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>
2023
- <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>
2024
- <span class='end end kw'>end</span>
2025
- <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>
2026
- <span class='end end kw'>end</span>
2027
- <span class='cells identifier id'>cells</span>
2028
- <span class='end end kw'>end</span>
2029
- </pre>
1662
+ <pre class="code"><span class="info file"># File 'lib/axlsx/workbook/worksheet/worksheet.rb', line 122</span>
1663
+
1664
+ <span class='kw'>def</span> <span class='id to_xml'>to_xml</span>
1665
+ <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'>=&gt;</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>
1666
+ <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'>=&gt;</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'>=&gt;</span> <span class='const'>XML_NS_R</span><span class='rparen'>)</span> <span class='lbrace'>{</span>
1667
+ <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'>&gt;</span> <span class='int'>0</span>
1668
+ <span class='id xml'>xml</span><span class='period'>.</span><span class='id cols'>cols</span> <span class='lbrace'>{</span>
1669
+ <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>
1670
+ <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>
1671
+ <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'>=&gt;</span><span class='id min_max'>min_max</span><span class='comma'>,</span> <span class='symbol'>:max</span><span class='op'>=&gt;</span><span class='id min_max'>min_max</span><span class='comma'>,</span> <span class='symbol'>:width</span> <span class='op'>=&gt;</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'>=&gt;</span><span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>true</span><span class='tstring_end'>&quot;</span></span><span class='rparen'>)</span>
1672
+ <span class='kw'>end</span>
1673
+ <span class='rbrace'>}</span>
1674
+ <span class='kw'>end</span>
1675
+ <span class='id xml'>xml</span><span class='period'>.</span><span class='id sheetData'>sheetData</span> <span class='lbrace'>{</span>
1676
+ <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>
1677
+ <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>
1678
+ <span class='kw'>end</span>
1679
+ <span class='rbrace'>}</span>
1680
+ <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'>&quot;</span></span><span class='op'>=&gt;</span><span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>rId1</span><span class='tstring_end'>&quot;</span></span> <span class='kw'>if</span> <span class='ivar'>@drawing</span>
1681
+ <span class='rbrace'>}</span>
1682
+ <span class='kw'>end</span>
1683
+ <span class='id builder'>builder</span><span class='period'>.</span><span class='id to_xml'>to_xml</span>
1684
+ <span class='kw'>end</span></pre>
2030
1685
  </td>
2031
1686
  </tr>
2032
1687
  </table>
@@ -2037,9 +1692,9 @@ of Cell objects
2037
1692
  </div>
2038
1693
 
2039
1694
  <div id="footer">
2040
- Generated on Wed Nov 23 21:47:51 2011 by
1695
+ Generated on Sat Nov 26 13:16:40 2011 by
2041
1696
  <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
2042
- 0.7.3 (ruby-1.8.7).
1697
+ 0.7.3 (ruby-1.9.3).
2043
1698
  </div>
2044
1699
 
2045
1700
  </body>