rubyXL 2.3.2 → 2.3.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/Gemfile.lock +6 -6
- data/VERSION +1 -1
- data/lib/rubyXL/cell.rb +0 -10
- data/lib/rubyXL/objects/relationships.rb +46 -14
- data/lib/rubyXL/objects/sheet_data.rb +14 -2
- data/lib/rubyXL/parser.rb +1 -0
- data/lib/rubyXL/workbook.rb +7 -6
- data/rdoc/README_rdoc.html +27 -27
- data/rdoc/RubyXL/AExtensionStorageArea.html +1 -1
- data/rdoc/RubyXL/Alignment.html +1 -1
- data/rdoc/RubyXL/AlternateContent.html +1 -1
- data/rdoc/RubyXL/AutoFilter.html +1 -1
- data/rdoc/RubyXL/AutoFilterColumn.html +1 -1
- data/rdoc/RubyXL/BooleanNode.html +1 -1
- data/rdoc/RubyXL/BooleanValue.html +1 -1
- data/rdoc/RubyXL/Border.html +1 -1
- data/rdoc/RubyXL/BorderEdge.html +1 -1
- data/rdoc/RubyXL/Borders.html +1 -1
- data/rdoc/RubyXL/Break.html +1 -1
- data/rdoc/RubyXL/BreakList.html +1 -1
- data/rdoc/RubyXL/CalculationChain.html +2 -2
- data/rdoc/RubyXL/CalculationChainCell.html +1 -1
- data/rdoc/RubyXL/CalculationProperties.html +1 -1
- data/rdoc/RubyXL/Cell.html +78 -5
- data/rdoc/RubyXL/CellSmartTag.html +1 -1
- data/rdoc/RubyXL/CellSmartTagProperty.html +1 -1
- data/rdoc/RubyXL/CellSmartTags.html +1 -1
- data/rdoc/RubyXL/CellStyle.html +1 -1
- data/rdoc/RubyXL/CellStyleXFs.html +1 -1
- data/rdoc/RubyXL/CellStyles.html +1 -1
- data/rdoc/RubyXL/CellValue.html +1 -1
- data/rdoc/RubyXL/CellWatch.html +1 -1
- data/rdoc/RubyXL/CellWatches.html +1 -1
- data/rdoc/RubyXL/CellXFs.html +1 -1
- data/rdoc/RubyXL/Chartsheet.html +1 -1
- data/rdoc/RubyXL/ChartsheetPageSetup.html +1 -1
- data/rdoc/RubyXL/ChartsheetProperties.html +1 -1
- data/rdoc/RubyXL/ChartsheetProtection.html +1 -1
- data/rdoc/RubyXL/ChartsheetView.html +1 -1
- data/rdoc/RubyXL/ChartsheetViews.html +1 -1
- data/rdoc/RubyXL/Color.html +3 -3
- data/rdoc/RubyXL/ColorFilter.html +1 -1
- data/rdoc/RubyXL/ColorScale.html +1 -1
- data/rdoc/RubyXL/ColorScheme.html +1 -1
- data/rdoc/RubyXL/ColorSet.html +1 -1
- data/rdoc/RubyXL/Colors.html +1 -1
- data/rdoc/RubyXL/ColumnRange.html +1 -1
- data/rdoc/RubyXL/ColumnRanges.html +1 -1
- data/rdoc/RubyXL/ConditionalFormatValue.html +1 -1
- data/rdoc/RubyXL/ConditionalFormatting.html +1 -1
- data/rdoc/RubyXL/ConditionalFormattingRule.html +1 -1
- data/rdoc/RubyXL/CustomFilter.html +1 -1
- data/rdoc/RubyXL/CustomFilters.html +1 -1
- data/rdoc/RubyXL/CustomProperties.html +1 -1
- data/rdoc/RubyXL/CustomProperty.html +1 -1
- data/rdoc/RubyXL/CustomSheetView.html +1 -1
- data/rdoc/RubyXL/CustomSheetViews.html +1 -1
- data/rdoc/RubyXL/CustomWorkbookView.html +1 -1
- data/rdoc/RubyXL/CustomWorkbookViews.html +1 -1
- data/rdoc/RubyXL/DXF.html +1 -1
- data/rdoc/RubyXL/DXFs.html +1 -1
- data/rdoc/RubyXL/DataBar.html +1 -1
- data/rdoc/RubyXL/DataConsolidate.html +1 -1
- data/rdoc/RubyXL/DataConsolidationReference.html +1 -1
- data/rdoc/RubyXL/DataConsolidationReferences.html +1 -1
- data/rdoc/RubyXL/DataValidation.html +1 -1
- data/rdoc/RubyXL/DataValidations.html +1 -1
- data/rdoc/RubyXL/DateGroupItem.html +1 -1
- data/rdoc/RubyXL/DefinedName.html +1 -1
- data/rdoc/RubyXL/DefinedNames.html +1 -1
- data/rdoc/RubyXL/DocumentProperties.html +6 -6
- data/rdoc/RubyXL/DynamicFilter.html +1 -1
- data/rdoc/RubyXL/EmbeddedControl.html +1 -1
- data/rdoc/RubyXL/EmbeddedControls.html +1 -1
- data/rdoc/RubyXL/Extension.html +1 -1
- data/rdoc/RubyXL/ExtensionStorageArea.html +1 -1
- data/rdoc/RubyXL/ExternalReference.html +1 -1
- data/rdoc/RubyXL/ExternalReferences.html +1 -1
- data/rdoc/RubyXL/FieldItem.html +1 -1
- data/rdoc/RubyXL/FileRecoveryProperties.html +1 -1
- data/rdoc/RubyXL/FileSharing.html +1 -1
- data/rdoc/RubyXL/FileVersion.html +1 -1
- data/rdoc/RubyXL/Fill.html +1 -1
- data/rdoc/RubyXL/Fills.html +1 -1
- data/rdoc/RubyXL/FilterContainer.html +1 -1
- data/rdoc/RubyXL/FloatNode.html +1 -1
- data/rdoc/RubyXL/FloatValue.html +1 -1
- data/rdoc/RubyXL/Font.html +1 -1
- data/rdoc/RubyXL/FontScheme.html +1 -1
- data/rdoc/RubyXL/Fonts.html +1 -1
- data/rdoc/RubyXL/FormatScheme.html +1 -1
- data/rdoc/RubyXL/Formula.html +1 -1
- data/rdoc/RubyXL/FunctionGroup.html +1 -1
- data/rdoc/RubyXL/FunctionGroups.html +1 -1
- data/rdoc/RubyXL/GenericStorage.html +4 -4
- data/rdoc/RubyXL/GradientFill.html +1 -1
- data/rdoc/RubyXL/HeaderFooterSettings.html +1 -1
- data/rdoc/RubyXL/Hyperlink.html +1 -1
- data/rdoc/RubyXL/Hyperlinks.html +1 -1
- data/rdoc/RubyXL/IconFilter.html +1 -1
- data/rdoc/RubyXL/IconSet.html +1 -1
- data/rdoc/RubyXL/IgnoredError.html +1 -1
- data/rdoc/RubyXL/IgnoredErrors.html +1 -1
- data/rdoc/RubyXL/IndexedColors.html +1 -1
- data/rdoc/RubyXL/InputCells.html +1 -1
- data/rdoc/RubyXL/IntegerNode.html +1 -1
- data/rdoc/RubyXL/IntegerValue.html +1 -1
- data/rdoc/RubyXL/LegacyCell.html +57 -94
- data/rdoc/RubyXL/LegacyWorkbook.html +53 -38
- data/rdoc/RubyXL/LegacyWorksheet.html +29 -29
- data/rdoc/RubyXL/MRUColors.html +1 -1
- data/rdoc/RubyXL/MergedCell.html +1 -1
- data/rdoc/RubyXL/MergedCells.html +1 -1
- data/rdoc/RubyXL/NumFmt.html +1 -1
- data/rdoc/RubyXL/NumberFormat.html +2 -2
- data/rdoc/RubyXL/NumberFormats.html +1 -1
- data/rdoc/RubyXL/OLEObject.html +1 -1
- data/rdoc/RubyXL/OLEObjects.html +1 -1
- data/rdoc/RubyXL/OLESize.html +1 -1
- data/rdoc/RubyXL/OOXMLContainerObject.html +1 -1
- data/rdoc/RubyXL/OOXMLObject.html +1 -1
- data/rdoc/RubyXL/OOXMLObjectClassMethods.html +12 -12
- data/rdoc/RubyXL/OOXMLObjectInstanceMethods.html +1 -1
- data/rdoc/RubyXL/OOXMLRelationshipsFile.html +238 -0
- data/rdoc/RubyXL/OOXMLTopLevelObject.html +1 -1
- data/rdoc/RubyXL/OutlineProperties.html +1 -1
- data/rdoc/RubyXL/PageMargins.html +1 -1
- data/rdoc/RubyXL/PageSetup.html +1 -1
- data/rdoc/RubyXL/PageSetupProperties.html +1 -1
- data/rdoc/RubyXL/Pane.html +1 -1
- data/rdoc/RubyXL/Parser.html +16 -15
- data/rdoc/RubyXL/PatternFill.html +1 -1
- data/rdoc/RubyXL/PhoneticProperties.html +1 -1
- data/rdoc/RubyXL/PhoneticRun.html +1 -1
- data/rdoc/RubyXL/PivotArea.html +1 -1
- data/rdoc/RubyXL/PivotCache.html +1 -1
- data/rdoc/RubyXL/PivotCaches.html +1 -1
- data/rdoc/RubyXL/PivotReference.html +1 -1
- data/rdoc/RubyXL/PivotReferences.html +1 -1
- data/rdoc/RubyXL/PivotTableSelection.html +1 -1
- data/rdoc/RubyXL/PrintOptions.html +1 -1
- data/rdoc/RubyXL/ProtectedRange.html +1 -1
- data/rdoc/RubyXL/ProtectedRanges.html +1 -1
- data/rdoc/RubyXL/Protection.html +1 -1
- data/rdoc/RubyXL/RID.html +1 -1
- data/rdoc/RubyXL/RawOOXML.html +1 -1
- data/rdoc/RubyXL/Reference.html +5 -5
- data/rdoc/RubyXL/Relationship.html +1 -1
- data/rdoc/RubyXL/RichText.html +1 -1
- data/rdoc/RubyXL/RichTextRun.html +1 -1
- data/rdoc/RubyXL/RootRelationships.html +105 -0
- data/rdoc/RubyXL/Row.html +1 -1
- data/rdoc/RubyXL/RunProperties.html +1 -1
- data/rdoc/RubyXL/Scenario.html +1 -1
- data/rdoc/RubyXL/Scenarios.html +1 -1
- data/rdoc/RubyXL/Selection.html +1 -1
- data/rdoc/RubyXL/SharedStringsTable.html +2 -2
- data/rdoc/RubyXL/Sheet.html +1 -1
- data/rdoc/RubyXL/SheetCalculationProperties.html +1 -1
- data/rdoc/RubyXL/SheetData.html +1 -1
- data/rdoc/RubyXL/Sheets.html +1 -1
- data/rdoc/RubyXL/SmartTagProperties.html +1 -1
- data/rdoc/RubyXL/SmartTagType.html +1 -1
- data/rdoc/RubyXL/SmartTagTypes.html +1 -1
- data/rdoc/RubyXL/SmartTags.html +1 -1
- data/rdoc/RubyXL/SortCondition.html +1 -1
- data/rdoc/RubyXL/SortState.html +1 -1
- data/rdoc/RubyXL/Sqref.html +2 -2
- data/rdoc/RubyXL/Stop.html +1 -1
- data/rdoc/RubyXL/StringNode.html +1 -1
- data/rdoc/RubyXL/StringValue.html +1 -1
- data/rdoc/RubyXL/Stylesheet.html +1 -1
- data/rdoc/RubyXL/TableParts.html +1 -1
- data/rdoc/RubyXL/TableStyle.html +1 -1
- data/rdoc/RubyXL/TableStyles.html +1 -1
- data/rdoc/RubyXL/Text.html +2 -2
- data/rdoc/RubyXL/Theme.html +1 -1
- data/rdoc/RubyXL/ThemeElements.html +1 -1
- data/rdoc/RubyXL/Top10.html +1 -1
- data/rdoc/RubyXL/Variant.html +1 -1
- data/rdoc/RubyXL/Vector.html +1 -1
- data/rdoc/RubyXL/VectorValue.html +1 -1
- data/rdoc/RubyXL/WebPublishObject.html +1 -1
- data/rdoc/RubyXL/WebPublishObjects.html +1 -1
- data/rdoc/RubyXL/WebPublishingItem.html +1 -1
- data/rdoc/RubyXL/WebPublishingItems.html +1 -1
- data/rdoc/RubyXL/WebPublishingProperties.html +1 -1
- data/rdoc/RubyXL/Workbook.html +1 -1
- data/rdoc/RubyXL/WorkbookProperties.html +1 -1
- data/rdoc/RubyXL/WorkbookProtection.html +1 -1
- data/rdoc/RubyXL/WorkbookRelationships.html +2 -213
- data/rdoc/RubyXL/WorkbookView.html +1 -1
- data/rdoc/RubyXL/WorkbookViews.html +1 -1
- data/rdoc/RubyXL/Worksheet.html +1 -1
- data/rdoc/RubyXL/WorksheetDimensions.html +1 -1
- data/rdoc/RubyXL/WorksheetFormatProperties.html +1 -1
- data/rdoc/RubyXL/WorksheetProperties.html +1 -1
- data/rdoc/RubyXL/WorksheetProtection.html +1 -1
- data/rdoc/RubyXL/WorksheetView.html +1 -1
- data/rdoc/RubyXL/WorksheetViews.html +1 -1
- data/rdoc/RubyXL/Writer/ContentTypesWriter.html +53 -53
- data/rdoc/RubyXL/Writer/CoreWriter.html +12 -12
- data/rdoc/RubyXL/Writer/GenericWriter.html +5 -5
- data/rdoc/RubyXL/Writer/StylesWriter.html +2 -2
- data/rdoc/RubyXL/Writer/ThemeWriter.html +5 -5
- data/rdoc/RubyXL/Writer/WorkbookWriter.html +21 -21
- data/rdoc/RubyXL/Writer.html +1 -1
- data/rdoc/RubyXL/XF.html +1 -1
- data/rdoc/RubyXL.html +1 -1
- data/rdoc/created.rid +40 -41
- data/rdoc/index.html +4 -6
- data/rdoc/js/search_index.js +1 -1
- data/rdoc/table_of_contents.html +80 -93
- data/rubyXL.gemspec +5 -5
- metadata +4 -4
- data/lib/rubyXL/writer/root_rels_writer.rb +0 -17
- data/rdoc/RubyXL/Writer/RootRelsWriter.html +0 -193
@@ -4,7 +4,7 @@
|
|
4
4
|
<head>
|
5
5
|
<meta charset="UTF-8">
|
6
6
|
|
7
|
-
<title>class RubyXL::WorkbookRelationships - rubyXL 2.3.
|
7
|
+
<title>class RubyXL::WorkbookRelationships - rubyXL 2.3.3</title>
|
8
8
|
|
9
9
|
<link href="../fonts.css" rel="stylesheet">
|
10
10
|
<link href="../rdoc.css" rel="stylesheet">
|
@@ -61,29 +61,13 @@
|
|
61
61
|
<h3>Parent</h3>
|
62
62
|
|
63
63
|
|
64
|
-
<p class="link"><a href="
|
64
|
+
<p class="link"><a href="OOXMLRelationshipsFile.html">RubyXL::OOXMLRelationshipsFile</a>
|
65
65
|
|
66
66
|
</div>
|
67
67
|
|
68
68
|
|
69
69
|
|
70
|
-
<!-- Method Quickref -->
|
71
|
-
<div id="method-list-section" class="nav-section">
|
72
|
-
<h3>Methods</h3>
|
73
|
-
|
74
|
-
<ul class="link-list" role="directory">
|
75
|
-
|
76
|
-
<li ><a href="#method-c-filepath">::filepath</a>
|
77
|
-
|
78
|
-
<li ><a href="#method-i-before_write_xml">#before_write_xml</a>
|
79
70
|
|
80
|
-
<li ><a href="#method-i-create_relationship">#create_relationship</a>
|
81
|
-
|
82
|
-
<li ><a href="#method-i-find_by_rid">#find_by_rid</a>
|
83
|
-
|
84
|
-
</ul>
|
85
|
-
</div>
|
86
|
-
|
87
71
|
</div>
|
88
72
|
</nav>
|
89
73
|
|
@@ -94,9 +78,6 @@
|
|
94
78
|
|
95
79
|
<section class="description">
|
96
80
|
|
97
|
-
<p><a
|
98
|
-
href="http://www.schemacentral.com/sc/ooxml/e-ssml_calcChain.html">www.schemacentral.com/sc/ooxml/e-ssml_calcChain.html</a></p>
|
99
|
-
|
100
81
|
</section>
|
101
82
|
|
102
83
|
|
@@ -110,200 +91,8 @@ href="http://www.schemacentral.com/sc/ooxml/e-ssml_calcChain.html">www.schemacen
|
|
110
91
|
|
111
92
|
|
112
93
|
|
113
|
-
<section class="attribute-method-details" class="method-section">
|
114
|
-
<header>
|
115
|
-
<h3>Attributes</h3>
|
116
|
-
</header>
|
117
|
-
|
118
|
-
|
119
|
-
<div id="attribute-i-workbook" class="method-detail">
|
120
|
-
<div class="method-heading attribute-method-heading">
|
121
|
-
<span class="method-name">workbook</span><span
|
122
|
-
class="attribute-access-type">[RW]</span>
|
123
|
-
</div>
|
124
|
-
|
125
|
-
<div class="method-description">
|
126
|
-
|
127
|
-
|
128
|
-
|
129
|
-
</div>
|
130
|
-
</div>
|
131
|
-
|
132
|
-
</section>
|
133
|
-
|
134
|
-
|
135
|
-
|
136
|
-
<section id="public-class-5Buntitled-5D-method-details" class="method-section">
|
137
|
-
<header>
|
138
|
-
<h3>Public Class Methods</h3>
|
139
|
-
</header>
|
140
|
-
|
141
|
-
|
142
|
-
<div id="method-c-filepath" class="method-detail ">
|
143
|
-
|
144
|
-
<div class="method-heading">
|
145
|
-
<span class="method-name">filepath</span><span
|
146
|
-
class="method-args">()</span>
|
147
|
-
|
148
|
-
<span class="method-click-advice">click to toggle source</span>
|
149
|
-
|
150
|
-
</div>
|
151
|
-
|
152
|
-
|
153
|
-
<div class="method-description">
|
154
|
-
|
155
|
-
|
156
|
-
|
157
|
-
|
158
|
-
|
159
|
-
|
160
|
-
<div class="method-source-code" id="filepath-source">
|
161
|
-
<pre><span class="ruby-comment"># File lib/rubyXL/objects/relationships.rb, line 59</span>
|
162
|
-
<span class="ruby-keyword">def</span> <span class="ruby-keyword">self</span>.<span class="ruby-identifier">filepath</span>
|
163
|
-
<span class="ruby-constant">File</span>.<span class="ruby-identifier">join</span>(<span class="ruby-string">'xl'</span>, <span class="ruby-string">'_rels'</span>, <span class="ruby-string">'workbook.xml.rels'</span>)
|
164
|
-
<span class="ruby-keyword">end</span></pre>
|
165
|
-
</div>
|
166
|
-
|
167
|
-
</div>
|
168
|
-
|
169
|
-
|
170
|
-
|
171
|
-
|
172
|
-
</div>
|
173
|
-
|
174
|
-
|
175
|
-
</section>
|
176
|
-
|
177
|
-
<section id="public-instance-5Buntitled-5D-method-details" class="method-section">
|
178
|
-
<header>
|
179
|
-
<h3>Public Instance Methods</h3>
|
180
|
-
</header>
|
181
94
|
|
182
95
|
|
183
|
-
<div id="method-i-before_write_xml" class="method-detail ">
|
184
|
-
|
185
|
-
<div class="method-heading">
|
186
|
-
<span class="method-name">before_write_xml</span><span
|
187
|
-
class="method-args">()</span>
|
188
|
-
|
189
|
-
<span class="method-click-advice">click to toggle source</span>
|
190
|
-
|
191
|
-
</div>
|
192
|
-
|
193
|
-
|
194
|
-
<div class="method-description">
|
195
|
-
|
196
|
-
|
197
|
-
|
198
|
-
|
199
|
-
|
200
|
-
|
201
|
-
<div class="method-source-code" id="before_write_xml-source">
|
202
|
-
<pre><span class="ruby-comment"># File lib/rubyXL/objects/relationships.rb, line 30</span>
|
203
|
-
<span class="ruby-keyword">def</span> <span class="ruby-identifier">before_write_xml</span>
|
204
|
-
<span class="ruby-keyword">self</span>.<span class="ruby-identifier">relationships</span> = []
|
205
|
-
|
206
|
-
<span class="ruby-ivar">@workbook</span>.<span class="ruby-identifier">worksheets</span>.<span class="ruby-identifier">each_with_index</span> { <span class="ruby-operator">|</span><span class="ruby-identifier">sheet</span>, <span class="ruby-identifier">i</span><span class="ruby-operator">|</span>
|
207
|
-
<span class="ruby-identifier">relationships</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">create_relationship</span>(<span class="ruby-identifier">sheet</span>.<span class="ruby-identifier">filepath</span>.<span class="ruby-identifier">gsub</span>(<span class="ruby-regexp">/^xl\//</span>, <span class="ruby-string">''</span>), <span class="ruby-identifier">sheet</span>.<span class="ruby-identifier">rel_type</span>)
|
208
|
-
}
|
209
|
-
|
210
|
-
<span class="ruby-ivar">@workbook</span>.<span class="ruby-identifier">external_links</span>.<span class="ruby-identifier">each_key</span> { <span class="ruby-operator">|</span><span class="ruby-identifier">k</span><span class="ruby-operator">|</span>
|
211
|
-
<span class="ruby-identifier">relationships</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">create_relationship</span>(<span class="ruby-node">"externalLinks/#{k}"</span>, <span class="ruby-string">'externalLink'</span>)
|
212
|
-
}
|
213
|
-
|
214
|
-
<span class="ruby-identifier">relationships</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">create_relationship</span>(<span class="ruby-string">'theme/theme1.xml'</span>, <span class="ruby-string">'theme'</span>)
|
215
|
-
<span class="ruby-identifier">relationships</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">create_relationship</span>(<span class="ruby-string">'styles.xml'</span>, <span class="ruby-string">'styles'</span>)
|
216
|
-
|
217
|
-
<span class="ruby-keyword">if</span> <span class="ruby-ivar">@workbook</span>.<span class="ruby-identifier">shared_strings_container</span> <span class="ruby-operator">&&</span> <span class="ruby-operator">!</span><span class="ruby-ivar">@workbook</span>.<span class="ruby-identifier">shared_strings_container</span>.<span class="ruby-identifier">strings</span>.<span class="ruby-identifier">empty?</span> <span class="ruby-keyword">then</span>
|
218
|
-
<span class="ruby-identifier">relationships</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">create_relationship</span>(<span class="ruby-string">'sharedStrings.xml'</span>, <span class="ruby-string">'sharedStrings'</span>)
|
219
|
-
<span class="ruby-keyword">end</span>
|
220
|
-
|
221
|
-
<span class="ruby-keyword">if</span> <span class="ruby-ivar">@workbook</span>.<span class="ruby-identifier">calculation_chain</span> <span class="ruby-operator">&&</span> <span class="ruby-operator">!</span><span class="ruby-ivar">@workbook</span>.<span class="ruby-identifier">calculation_chain</span>.<span class="ruby-identifier">cells</span>.<span class="ruby-identifier">empty?</span> <span class="ruby-keyword">then</span>
|
222
|
-
<span class="ruby-identifier">relationships</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">create_relationship</span>(<span class="ruby-string">'calcChain.xml'</span>, <span class="ruby-string">'calcChain'</span>)
|
223
|
-
<span class="ruby-keyword">end</span>
|
224
|
-
|
225
|
-
<span class="ruby-keyword">true</span>
|
226
|
-
<span class="ruby-keyword">end</span></pre>
|
227
|
-
</div>
|
228
|
-
|
229
|
-
</div>
|
230
|
-
|
231
|
-
|
232
|
-
|
233
|
-
|
234
|
-
</div>
|
235
|
-
|
236
|
-
|
237
|
-
<div id="method-i-create_relationship" class="method-detail ">
|
238
|
-
|
239
|
-
<div class="method-heading">
|
240
|
-
<span class="method-name">create_relationship</span><span
|
241
|
-
class="method-args">(target, type)</span>
|
242
|
-
|
243
|
-
<span class="method-click-advice">click to toggle source</span>
|
244
|
-
|
245
|
-
</div>
|
246
|
-
|
247
|
-
|
248
|
-
<div class="method-description">
|
249
|
-
|
250
|
-
|
251
|
-
|
252
|
-
|
253
|
-
|
254
|
-
|
255
|
-
<div class="method-source-code" id="create_relationship-source">
|
256
|
-
<pre><span class="ruby-comment"># File lib/rubyXL/objects/relationships.rb, line 24</span>
|
257
|
-
<span class="ruby-keyword">def</span> <span class="ruby-identifier">create_relationship</span>(<span class="ruby-identifier">target</span>, <span class="ruby-identifier">type</span>)
|
258
|
-
<span class="ruby-constant">RubyXL</span><span class="ruby-operator">::</span><span class="ruby-constant">Relationship</span>.<span class="ruby-identifier">new</span>(<span class="ruby-value">:id</span> =<span class="ruby-operator">></span> <span class="ruby-node">"rId#{relationships.size + 1}"</span>,
|
259
|
-
<span class="ruby-value">:type</span> =<span class="ruby-operator">></span> <span class="ruby-node">"http://schemas.openxmlformats.org/officeDocument/2006/relationships/#{type}"</span>,
|
260
|
-
<span class="ruby-value">:target</span> =<span class="ruby-operator">></span> <span class="ruby-identifier">target</span>)
|
261
|
-
<span class="ruby-keyword">end</span></pre>
|
262
|
-
</div>
|
263
|
-
|
264
|
-
</div>
|
265
|
-
|
266
|
-
|
267
|
-
|
268
|
-
|
269
|
-
</div>
|
270
|
-
|
271
|
-
|
272
|
-
<div id="method-i-find_by_rid" class="method-detail ">
|
273
|
-
|
274
|
-
<div class="method-heading">
|
275
|
-
<span class="method-name">find_by_rid</span><span
|
276
|
-
class="method-args">(r_id)</span>
|
277
|
-
|
278
|
-
<span class="method-click-advice">click to toggle source</span>
|
279
|
-
|
280
|
-
</div>
|
281
|
-
|
282
|
-
|
283
|
-
<div class="method-description">
|
284
|
-
|
285
|
-
|
286
|
-
|
287
|
-
|
288
|
-
|
289
|
-
|
290
|
-
<div class="method-source-code" id="find_by_rid-source">
|
291
|
-
<pre><span class="ruby-comment"># File lib/rubyXL/objects/relationships.rb, line 55</span>
|
292
|
-
<span class="ruby-keyword">def</span> <span class="ruby-identifier">find_by_rid</span>(<span class="ruby-identifier">r_id</span>)
|
293
|
-
<span class="ruby-identifier">relationships</span>.<span class="ruby-identifier">find</span> { <span class="ruby-operator">|</span><span class="ruby-identifier">r</span><span class="ruby-operator">|</span> <span class="ruby-identifier">r</span>.<span class="ruby-identifier">id</span> <span class="ruby-operator">==</span> <span class="ruby-identifier">r_id</span> }
|
294
|
-
<span class="ruby-keyword">end</span></pre>
|
295
|
-
</div>
|
296
|
-
|
297
|
-
</div>
|
298
|
-
|
299
|
-
|
300
|
-
|
301
|
-
|
302
|
-
</div>
|
303
|
-
|
304
|
-
|
305
|
-
</section>
|
306
|
-
|
307
96
|
</section>
|
308
97
|
</main>
|
309
98
|
|
data/rdoc/RubyXL/Worksheet.html
CHANGED
@@ -4,7 +4,7 @@
|
|
4
4
|
<head>
|
5
5
|
<meta charset="UTF-8">
|
6
6
|
|
7
|
-
<title>class RubyXL::WorksheetFormatProperties - rubyXL 2.3.
|
7
|
+
<title>class RubyXL::WorksheetFormatProperties - rubyXL 2.3.3</title>
|
8
8
|
|
9
9
|
<link href="../fonts.css" rel="stylesheet">
|
10
10
|
<link href="../rdoc.css" rel="stylesheet">
|
@@ -4,7 +4,7 @@
|
|
4
4
|
<head>
|
5
5
|
<meta charset="UTF-8">
|
6
6
|
|
7
|
-
<title>class RubyXL::Writer::ContentTypesWriter - rubyXL 2.3.
|
7
|
+
<title>class RubyXL::Writer::ContentTypesWriter - rubyXL 2.3.3</title>
|
8
8
|
|
9
9
|
<link href="../../fonts.css" rel="stylesheet">
|
10
10
|
<link href="../../rdoc.css" rel="stylesheet">
|
@@ -132,7 +132,7 @@
|
|
132
132
|
<div class="method-source-code" id="filepath-source">
|
133
133
|
<pre><span class="ruby-comment"># File lib/rubyXL/writer/content_types_writer.rb, line 5</span>
|
134
134
|
<span class="ruby-keyword">def</span> <span class="ruby-identifier">filepath</span>
|
135
|
-
<span class="ruby-string"
|
135
|
+
<span class="ruby-string">'[Content_Types].xml'</span>
|
136
136
|
<span class="ruby-keyword">end</span></pre>
|
137
137
|
</div>
|
138
138
|
|
@@ -167,100 +167,100 @@
|
|
167
167
|
<span class="ruby-keyword">def</span> <span class="ruby-identifier">write</span>()
|
168
168
|
|
169
169
|
<span class="ruby-identifier">render_xml</span> <span class="ruby-keyword">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">xml</span><span class="ruby-operator">|</span>
|
170
|
-
<span class="ruby-identifier">xml</span> <span class="ruby-operator"><<</span> (<span class="ruby-identifier">xml</span>.<span class="ruby-identifier">create_element</span>(<span class="ruby-string"
|
171
|
-
<span class="ruby-value">:xmlns</span> =<span class="ruby-operator">></span> <span class="ruby-string"
|
170
|
+
<span class="ruby-identifier">xml</span> <span class="ruby-operator"><<</span> (<span class="ruby-identifier">xml</span>.<span class="ruby-identifier">create_element</span>(<span class="ruby-string">'Types'</span>,
|
171
|
+
<span class="ruby-value">:xmlns</span> =<span class="ruby-operator">></span> <span class="ruby-string">'http://schemas.openxmlformats.org/package/2006/content-types'</span>) { <span class="ruby-operator">|</span><span class="ruby-identifier">root</span><span class="ruby-operator">|</span>
|
172
172
|
|
173
173
|
<span class="ruby-keyword">unless</span> <span class="ruby-ivar">@workbook</span>.<span class="ruby-identifier">printer_settings</span>.<span class="ruby-identifier">empty?</span>
|
174
|
-
<span class="ruby-identifier">root</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">xml</span>.<span class="ruby-identifier">create_element</span>(<span class="ruby-string"
|
175
|
-
<span class="ruby-value">:Extension</span> =<span class="ruby-operator">></span> <span class="ruby-string"
|
176
|
-
<span class="ruby-value">:ContentType</span> =<span class="ruby-operator">></span> <span class="ruby-string"
|
174
|
+
<span class="ruby-identifier">root</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">xml</span>.<span class="ruby-identifier">create_element</span>(<span class="ruby-string">'Default'</span>, {
|
175
|
+
<span class="ruby-value">:Extension</span> =<span class="ruby-operator">></span> <span class="ruby-string">'bin'</span>,
|
176
|
+
<span class="ruby-value">:ContentType</span> =<span class="ruby-operator">></span> <span class="ruby-string">'application/vnd.openxmlformats-officedocument.spreadsheetml.printerSettings'</span> })
|
177
177
|
<span class="ruby-keyword">end</span>
|
178
|
-
<span class="ruby-identifier">root</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">xml</span>.<span class="ruby-identifier">create_element</span>(<span class="ruby-string"
|
179
|
-
<span class="ruby-value">:Extension</span> =<span class="ruby-operator">></span> <span class="ruby-string"
|
180
|
-
<span class="ruby-value">:ContentType</span> =<span class="ruby-operator">></span> <span class="ruby-string"
|
178
|
+
<span class="ruby-identifier">root</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">xml</span>.<span class="ruby-identifier">create_element</span>(<span class="ruby-string">'Default'</span>, {
|
179
|
+
<span class="ruby-value">:Extension</span> =<span class="ruby-operator">></span> <span class="ruby-string">'rels'</span>,
|
180
|
+
<span class="ruby-value">:ContentType</span> =<span class="ruby-operator">></span> <span class="ruby-string">'application/vnd.openxmlformats-package.relationships+xml'</span> })
|
181
181
|
|
182
|
-
<span class="ruby-identifier">root</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">xml</span>.<span class="ruby-identifier">create_element</span>(<span class="ruby-string"
|
183
|
-
<span class="ruby-value">:Extension</span> =<span class="ruby-operator">></span> <span class="ruby-string"
|
184
|
-
<span class="ruby-value">:ContentType</span> =<span class="ruby-operator">></span> <span class="ruby-string"
|
182
|
+
<span class="ruby-identifier">root</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">xml</span>.<span class="ruby-identifier">create_element</span>(<span class="ruby-string">'Default'</span>, {
|
183
|
+
<span class="ruby-value">:Extension</span> =<span class="ruby-operator">></span> <span class="ruby-string">'xml'</span>,
|
184
|
+
<span class="ruby-value">:ContentType</span> =<span class="ruby-operator">></span> <span class="ruby-string">'application/xml'</span> })
|
185
185
|
|
186
|
-
<span class="ruby-identifier">root</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">xml</span>.<span class="ruby-identifier">create_element</span>(<span class="ruby-string"
|
187
|
-
<span class="ruby-value">:Extension</span> =<span class="ruby-operator">></span> <span class="ruby-string"
|
188
|
-
<span class="ruby-value">:ContentType</span> =<span class="ruby-operator">></span> <span class="ruby-string"
|
186
|
+
<span class="ruby-identifier">root</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">xml</span>.<span class="ruby-identifier">create_element</span>(<span class="ruby-string">'Default'</span>, {
|
187
|
+
<span class="ruby-value">:Extension</span> =<span class="ruby-operator">></span> <span class="ruby-string">'jpeg'</span>,
|
188
|
+
<span class="ruby-value">:ContentType</span> =<span class="ruby-operator">></span> <span class="ruby-string">'image/jpeg'</span> })
|
189
189
|
|
190
190
|
<span class="ruby-comment"># if @workbook.macros.nil? && @workbook.drawings.empty?</span>
|
191
|
-
<span class="ruby-identifier">root</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">xml</span>.<span class="ruby-identifier">create_element</span>(<span class="ruby-string"
|
192
|
-
<span class="ruby-value">:PartName</span> =<span class="ruby-operator">></span> <span class="ruby-string"
|
193
|
-
<span class="ruby-value">:ContentType</span> =<span class="ruby-operator">></span> <span class="ruby-string"
|
191
|
+
<span class="ruby-identifier">root</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">xml</span>.<span class="ruby-identifier">create_element</span>(<span class="ruby-string">'Override'</span>, {
|
192
|
+
<span class="ruby-value">:PartName</span> =<span class="ruby-operator">></span> <span class="ruby-string">'/xl/workbook.xml'</span>,
|
193
|
+
<span class="ruby-value">:ContentType</span> =<span class="ruby-operator">></span> <span class="ruby-string">'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet.main+xml'</span> })
|
194
194
|
<span class="ruby-comment"># else</span>
|
195
|
-
<span class="ruby-comment"># xml.Override(
|
196
|
-
<span class="ruby-comment">#
|
195
|
+
<span class="ruby-comment"># xml.Override('PartName'=>'/xl/workbook.xml',</span>
|
196
|
+
<span class="ruby-comment"># 'ContentType'=>"application/vnd.ms-excel.sheet.macroEnabled.main+xml")</span>
|
197
197
|
<span class="ruby-comment"># end</span>
|
198
198
|
|
199
199
|
<span class="ruby-ivar">@workbook</span>.<span class="ruby-identifier">worksheets</span>.<span class="ruby-identifier">each_with_index</span> { <span class="ruby-operator">|</span><span class="ruby-identifier">sheet</span>,<span class="ruby-identifier">i</span><span class="ruby-operator">|</span>
|
200
|
-
<span class="ruby-identifier">root</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">xml</span>.<span class="ruby-identifier">create_element</span>(<span class="ruby-string"
|
200
|
+
<span class="ruby-identifier">root</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">xml</span>.<span class="ruby-identifier">create_element</span>(<span class="ruby-string">'Override'</span>, {
|
201
201
|
<span class="ruby-value">:PartName</span> =<span class="ruby-operator">></span> <span class="ruby-node">"/xl/worksheets/sheet#{i+1}.xml"</span>,
|
202
|
-
<span class="ruby-value">:ContentType</span> =<span class="ruby-operator">></span> <span class="ruby-string"
|
202
|
+
<span class="ruby-value">:ContentType</span> =<span class="ruby-operator">></span> <span class="ruby-string">'application/vnd.openxmlformats-officedocument.spreadsheetml.worksheet+xml'</span> })
|
203
203
|
}
|
204
204
|
|
205
|
-
<span class="ruby-identifier">root</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">xml</span>.<span class="ruby-identifier">create_element</span>(<span class="ruby-string"
|
206
|
-
<span class="ruby-value">:PartName</span> =<span class="ruby-operator">></span> <span class="ruby-string"
|
207
|
-
<span class="ruby-value">:ContentType</span> =<span class="ruby-operator">></span> <span class="ruby-string"
|
205
|
+
<span class="ruby-identifier">root</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">xml</span>.<span class="ruby-identifier">create_element</span>(<span class="ruby-string">'Override'</span>, {
|
206
|
+
<span class="ruby-value">:PartName</span> =<span class="ruby-operator">></span> <span class="ruby-string">'/xl/theme/theme1.xml'</span>,
|
207
|
+
<span class="ruby-value">:ContentType</span> =<span class="ruby-operator">></span> <span class="ruby-string">'application/vnd.openxmlformats-officedocument.theme+xml'</span> })
|
208
208
|
|
209
|
-
<span class="ruby-identifier">root</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">xml</span>.<span class="ruby-identifier">create_element</span>(<span class="ruby-string"
|
210
|
-
<span class="ruby-value">:PartName</span> =<span class="ruby-operator">></span> <span class="ruby-string"
|
211
|
-
<span class="ruby-value">:ContentType</span> =<span class="ruby-operator">></span> <span class="ruby-string"
|
209
|
+
<span class="ruby-identifier">root</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">xml</span>.<span class="ruby-identifier">create_element</span>(<span class="ruby-string">'Override'</span>, {
|
210
|
+
<span class="ruby-value">:PartName</span> =<span class="ruby-operator">></span> <span class="ruby-string">'/xl/styles.xml'</span>,
|
211
|
+
<span class="ruby-value">:ContentType</span> =<span class="ruby-operator">></span> <span class="ruby-string">'application/vnd.openxmlformats-officedocument.spreadsheetml.styles+xml'</span> })
|
212
212
|
|
213
213
|
<span class="ruby-keyword">unless</span> <span class="ruby-ivar">@workbook</span>.<span class="ruby-identifier">shared_strings_container</span>.<span class="ruby-identifier">empty?</span>
|
214
|
-
<span class="ruby-identifier">root</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">xml</span>.<span class="ruby-identifier">create_element</span>(<span class="ruby-string"
|
215
|
-
<span class="ruby-value">:PartName</span> =<span class="ruby-operator">></span> <span class="ruby-string"
|
216
|
-
<span class="ruby-value">:ContentType</span> =<span class="ruby-operator">></span> <span class="ruby-string"
|
214
|
+
<span class="ruby-identifier">root</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">xml</span>.<span class="ruby-identifier">create_element</span>(<span class="ruby-string">'Override'</span>, {
|
215
|
+
<span class="ruby-value">:PartName</span> =<span class="ruby-operator">></span> <span class="ruby-string">'/xl/sharedStrings.xml'</span>,
|
216
|
+
<span class="ruby-value">:ContentType</span> =<span class="ruby-operator">></span> <span class="ruby-string">'application/vnd.openxmlformats-officedocument.spreadsheetml.sharedStrings+xml'</span> })
|
217
217
|
<span class="ruby-keyword">end</span>
|
218
218
|
|
219
219
|
<span class="ruby-ivar">@workbook</span>.<span class="ruby-identifier">drawings</span>.<span class="ruby-identifier">each_pair</span> { <span class="ruby-operator">|</span><span class="ruby-identifier">k</span>, <span class="ruby-identifier">v</span><span class="ruby-operator">|</span>
|
220
|
-
<span class="ruby-identifier">root</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">xml</span>.<span class="ruby-identifier">create_element</span>(<span class="ruby-string"
|
220
|
+
<span class="ruby-identifier">root</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">xml</span>.<span class="ruby-identifier">create_element</span>(<span class="ruby-string">'Override'</span>, {
|
221
221
|
<span class="ruby-value">:PartName</span> =<span class="ruby-operator">></span> <span class="ruby-node">"/#{@workbook.drawings.local_dir_path}/#{k}"</span>,
|
222
|
-
<span class="ruby-value">:ContentType</span> =<span class="ruby-operator">></span> <span class="ruby-string"
|
223
|
-
<span class="ruby-comment"># xml.Default(
|
224
|
-
<span class="ruby-comment">#
|
222
|
+
<span class="ruby-value">:ContentType</span> =<span class="ruby-operator">></span> <span class="ruby-string">'application/vnd.openxmlformats-officedocument.drawing+xml'</span> })
|
223
|
+
<span class="ruby-comment"># xml.Default('Extension'=>'vml',</span>
|
224
|
+
<span class="ruby-comment"># 'ContentType'=>'application/vnd.openxmlformats-officedocument.vmlDrawing')</span>
|
225
225
|
}
|
226
226
|
|
227
227
|
<span class="ruby-ivar">@workbook</span>.<span class="ruby-identifier">charts</span>.<span class="ruby-identifier">each_pair</span> { <span class="ruby-operator">|</span><span class="ruby-identifier">k</span>, <span class="ruby-identifier">v</span><span class="ruby-operator">|</span>
|
228
228
|
<span class="ruby-keyword">case</span> <span class="ruby-identifier">k</span>
|
229
229
|
<span class="ruby-keyword">when</span> <span class="ruby-regexp">/^chart\d*.xml$/</span> <span class="ruby-keyword">then</span>
|
230
|
-
<span class="ruby-identifier">root</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">xml</span>.<span class="ruby-identifier">create_element</span>(<span class="ruby-string"
|
230
|
+
<span class="ruby-identifier">root</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">xml</span>.<span class="ruby-identifier">create_element</span>(<span class="ruby-string">'Override'</span>, {
|
231
231
|
<span class="ruby-value">:PartName</span> =<span class="ruby-operator">></span> <span class="ruby-node">"/#{@workbook.charts.local_dir_path}/#{k}"</span>,
|
232
|
-
<span class="ruby-value">:ContentType</span> =<span class="ruby-operator">></span> <span class="ruby-string"
|
232
|
+
<span class="ruby-value">:ContentType</span> =<span class="ruby-operator">></span> <span class="ruby-string">'application/vnd.openxmlformats-officedocument.drawingml.chart+xml'</span> })
|
233
233
|
<span class="ruby-keyword">when</span> <span class="ruby-regexp">/^style\d*.xml$/</span> <span class="ruby-keyword">then</span>
|
234
|
-
<span class="ruby-identifier">root</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">xml</span>.<span class="ruby-identifier">create_element</span>(<span class="ruby-string"
|
234
|
+
<span class="ruby-identifier">root</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">xml</span>.<span class="ruby-identifier">create_element</span>(<span class="ruby-string">'Override'</span>, {
|
235
235
|
<span class="ruby-value">:PartName</span> =<span class="ruby-operator">></span> <span class="ruby-node">"/#{@workbook.charts.local_dir_path}/#{k}"</span>,
|
236
|
-
<span class="ruby-value">:ContentType</span> =<span class="ruby-operator">></span> <span class="ruby-string"
|
236
|
+
<span class="ruby-value">:ContentType</span> =<span class="ruby-operator">></span> <span class="ruby-string">'application/vnd.ms-office.chartstyle+xml'</span> })
|
237
237
|
<span class="ruby-keyword">when</span> <span class="ruby-regexp">/^colors\d*.xml$/</span> <span class="ruby-keyword">then</span>
|
238
|
-
<span class="ruby-identifier">root</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">xml</span>.<span class="ruby-identifier">create_element</span>(<span class="ruby-string"
|
238
|
+
<span class="ruby-identifier">root</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">xml</span>.<span class="ruby-identifier">create_element</span>(<span class="ruby-string">'Override'</span>, {
|
239
239
|
<span class="ruby-value">:PartName</span> =<span class="ruby-operator">></span> <span class="ruby-node">"/#{@workbook.charts.local_dir_path}/#{k}"</span>,
|
240
|
-
<span class="ruby-value">:ContentType</span> =<span class="ruby-operator">></span> <span class="ruby-string"
|
240
|
+
<span class="ruby-value">:ContentType</span> =<span class="ruby-operator">></span> <span class="ruby-string">'application/vnd.ms-office.chartcolorstyle+xml'</span> })
|
241
241
|
<span class="ruby-keyword">end</span>
|
242
242
|
}
|
243
243
|
|
244
|
-
<span class="ruby-identifier">root</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">xml</span>.<span class="ruby-identifier">create_element</span>(<span class="ruby-string"
|
245
|
-
<span class="ruby-value">:PartName</span> =<span class="ruby-operator">></span> <span class="ruby-string"
|
246
|
-
<span class="ruby-value">:ContentType</span> =<span class="ruby-operator">></span> <span class="ruby-string"
|
244
|
+
<span class="ruby-identifier">root</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">xml</span>.<span class="ruby-identifier">create_element</span>(<span class="ruby-string">'Override'</span>, {
|
245
|
+
<span class="ruby-value">:PartName</span> =<span class="ruby-operator">></span> <span class="ruby-string">'/docProps/core.xml'</span>,
|
246
|
+
<span class="ruby-value">:ContentType</span> =<span class="ruby-operator">></span> <span class="ruby-string">'application/vnd.openxmlformats-package.core-properties+xml'</span> })
|
247
247
|
|
248
|
-
<span class="ruby-identifier">root</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">xml</span>.<span class="ruby-identifier">create_element</span>(<span class="ruby-string"
|
249
|
-
<span class="ruby-value">:PartName</span> =<span class="ruby-operator">></span> <span class="ruby-string"
|
250
|
-
<span class="ruby-value">:ContentType</span> =<span class="ruby-operator">></span> <span class="ruby-string"
|
248
|
+
<span class="ruby-identifier">root</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">xml</span>.<span class="ruby-identifier">create_element</span>(<span class="ruby-string">'Override'</span>, {
|
249
|
+
<span class="ruby-value">:PartName</span> =<span class="ruby-operator">></span> <span class="ruby-string">'/docProps/app.xml'</span>,
|
250
|
+
<span class="ruby-value">:ContentType</span> =<span class="ruby-operator">></span> <span class="ruby-string">'application/vnd.openxmlformats-officedocument.extended-properties+xml'</span> })
|
251
251
|
|
252
252
|
<span class="ruby-keyword">unless</span> <span class="ruby-ivar">@workbook</span>.<span class="ruby-identifier">external_links</span>.<span class="ruby-identifier">nil?</span>
|
253
253
|
<span class="ruby-value">1</span>.<span class="ruby-identifier">upto</span>(<span class="ruby-ivar">@workbook</span>.<span class="ruby-identifier">external_links</span>.<span class="ruby-identifier">size</span><span class="ruby-operator">-</span><span class="ruby-value">1</span>) <span class="ruby-keyword">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">i</span><span class="ruby-operator">|</span>
|
254
|
-
<span class="ruby-identifier">root</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">xml</span>.<span class="ruby-identifier">create_element</span>(<span class="ruby-string"
|
254
|
+
<span class="ruby-identifier">root</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">xml</span>.<span class="ruby-identifier">create_element</span>(<span class="ruby-string">'Override'</span>, {
|
255
255
|
<span class="ruby-value">:PartName</span> =<span class="ruby-operator">></span> <span class="ruby-node">"/xl/externalLinks/externalLink#{i}.xml"</span>,
|
256
|
-
<span class="ruby-value">:ContentType</span> =<span class="ruby-operator">></span> <span class="ruby-string"
|
256
|
+
<span class="ruby-value">:ContentType</span> =<span class="ruby-operator">></span> <span class="ruby-string">'application/vnd.openxmlformats-officedocument.spreadsheetml.externalLink+xml'</span> })
|
257
257
|
<span class="ruby-keyword">end</span>
|
258
258
|
<span class="ruby-keyword">end</span>
|
259
259
|
|
260
260
|
<span class="ruby-keyword">unless</span> <span class="ruby-ivar">@workbook</span>.<span class="ruby-identifier">macros</span>.<span class="ruby-identifier">nil?</span>
|
261
|
-
<span class="ruby-identifier">root</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">xml</span>.<span class="ruby-identifier">create_element</span>(<span class="ruby-string"
|
262
|
-
<span class="ruby-value">:PartName</span> =<span class="ruby-operator">></span> <span class="ruby-string"
|
263
|
-
<span class="ruby-value">:ContentType</span> =<span class="ruby-operator">></span> <span class="ruby-string"
|
261
|
+
<span class="ruby-identifier">root</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">xml</span>.<span class="ruby-identifier">create_element</span>(<span class="ruby-string">'Override'</span>, {
|
262
|
+
<span class="ruby-value">:PartName</span> =<span class="ruby-operator">></span> <span class="ruby-string">'/xl/vbaProject.bin'</span>,
|
263
|
+
<span class="ruby-value">:ContentType</span> =<span class="ruby-operator">></span> <span class="ruby-string">'application/vnd.ms-office.vbaProject'</span> })
|
264
264
|
<span class="ruby-keyword">end</span>
|
265
265
|
})
|
266
266
|
<span class="ruby-keyword">end</span>
|