rubyXL 3.3.21 → 3.4.17

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.
Files changed (456) hide show
  1. checksums.yaml +5 -5
  2. data/.circleci/config.yml +60 -0
  3. data/.codeclimate.yml +3 -0
  4. data/Gemfile +3 -2
  5. data/Gemfile.lock +96 -0
  6. data/LICENSE.txt +1 -1
  7. data/README.rdoc +47 -16
  8. data/Rakefile +3 -2
  9. data/VERSION +1 -1
  10. data/lib/rubyXL.rb +1 -0
  11. data/lib/rubyXL/cell.rb +1 -26
  12. data/lib/rubyXL/convenience_methods.rb +5 -982
  13. data/lib/rubyXL/convenience_methods/cell.rb +272 -0
  14. data/lib/rubyXL/convenience_methods/color.rb +160 -0
  15. data/lib/rubyXL/convenience_methods/font.rb +63 -0
  16. data/lib/rubyXL/convenience_methods/workbook.rb +136 -0
  17. data/lib/rubyXL/convenience_methods/worksheet.rb +710 -0
  18. data/lib/rubyXL/objects/border.rb +31 -3
  19. data/lib/rubyXL/objects/calculation_chain.rb +2 -2
  20. data/lib/rubyXL/objects/cell_style.rb +8 -8
  21. data/lib/rubyXL/objects/chartsheet.rb +10 -10
  22. data/lib/rubyXL/objects/color.rb +6 -4
  23. data/lib/rubyXL/objects/column_range.rb +10 -10
  24. data/lib/rubyXL/objects/comments.rb +6 -6
  25. data/lib/rubyXL/objects/connection.rb +175 -0
  26. data/lib/rubyXL/objects/container_nodes.rb +2 -2
  27. data/lib/rubyXL/objects/content_types.rb +2 -2
  28. data/lib/rubyXL/objects/data_validation.rb +4 -2
  29. data/lib/rubyXL/objects/document_properties.rb +3 -3
  30. data/lib/rubyXL/objects/extensions.rb +20 -3
  31. data/lib/rubyXL/objects/external_links.rb +26 -2
  32. data/lib/rubyXL/objects/fill.rb +4 -4
  33. data/lib/rubyXL/objects/filters.rb +12 -12
  34. data/lib/rubyXL/objects/font.rb +2 -60
  35. data/lib/rubyXL/objects/formula.rb +1 -1
  36. data/lib/rubyXL/objects/ooxml_object.rb +15 -3
  37. data/lib/rubyXL/objects/query_table.rb +104 -0
  38. data/lib/rubyXL/objects/relationships.rb +8 -3
  39. data/lib/rubyXL/objects/shared_strings.rb +1 -1
  40. data/lib/rubyXL/objects/sheet_common.rb +4 -4
  41. data/lib/rubyXL/objects/sheet_data.rb +48 -11
  42. data/lib/rubyXL/objects/simple_types.rb +18 -0
  43. data/lib/rubyXL/objects/storage.rb +25 -1
  44. data/lib/rubyXL/objects/stylesheet.rb +14 -14
  45. data/lib/rubyXL/objects/text.rb +8 -8
  46. data/lib/rubyXL/objects/theme.rb +138 -119
  47. data/lib/rubyXL/objects/workbook.rb +153 -43
  48. data/lib/rubyXL/objects/worksheet.rb +118 -107
  49. data/lib/rubyXL/worksheet.rb +19 -13
  50. data/rdoc/README_rdoc.html +109 -103
  51. data/rdoc/RubyXL.html +39 -296
  52. data/rdoc/RubyXL/AExtension.html +21 -60
  53. data/rdoc/RubyXL/AExtensionStorageArea.html +12 -17
  54. data/rdoc/RubyXL/ActiveX.html +154 -0
  55. data/rdoc/RubyXL/ActiveXBinary.html +106 -0
  56. data/rdoc/RubyXL/AdjustHandleList.html +13 -19
  57. data/rdoc/RubyXL/Alignment.html +13 -19
  58. data/rdoc/RubyXL/AlternateContent.html +12 -17
  59. data/rdoc/RubyXL/Authors.html +13 -19
  60. data/rdoc/RubyXL/AutoFilter.html +13 -19
  61. data/rdoc/RubyXL/AutoFilterColumn.html +13 -19
  62. data/rdoc/RubyXL/BinaryImageFile.html +12 -25
  63. data/rdoc/RubyXL/BodyProperties.html +13 -19
  64. data/rdoc/RubyXL/BooleanNode.html +12 -17
  65. data/rdoc/RubyXL/BooleanValue.html +12 -17
  66. data/rdoc/RubyXL/Border.html +76 -53
  67. data/rdoc/RubyXL/BorderEdge.html +71 -17
  68. data/rdoc/RubyXL/Borders.html +19 -39
  69. data/rdoc/RubyXL/Break.html +13 -19
  70. data/rdoc/RubyXL/BreakList.html +13 -19
  71. data/rdoc/RubyXL/CT_AdjPoint2D.html +13 -19
  72. data/rdoc/RubyXL/CT_AlphaBiLevelEffect.html +13 -19
  73. data/rdoc/RubyXL/CT_AlphaModulateEffect.html +13 -19
  74. data/rdoc/RubyXL/CT_AlphaModulateFixedEffect.html +13 -19
  75. data/rdoc/RubyXL/CT_AlphaOutsetEffect.html +13 -19
  76. data/rdoc/RubyXL/CT_AlphaReplaceEffect.html +13 -19
  77. data/rdoc/RubyXL/CT_Backdrop.html +13 -19
  78. data/rdoc/RubyXL/CT_Bevel.html +13 -19
  79. data/rdoc/RubyXL/CT_BiLevelEffect.html +13 -19
  80. data/rdoc/RubyXL/CT_BlendEffect.html +13 -19
  81. data/rdoc/RubyXL/CT_Blip.html +13 -19
  82. data/rdoc/RubyXL/CT_BlipFillProperties.html +13 -19
  83. data/rdoc/RubyXL/CT_BlurEffect.html +13 -19
  84. data/rdoc/RubyXL/CT_Camera.html +13 -19
  85. data/rdoc/RubyXL/CT_Color.html +13 -19
  86. data/rdoc/RubyXL/CT_ColorChangeEffect.html +13 -19
  87. data/rdoc/RubyXL/CT_ColorMapping.html +13 -19
  88. data/rdoc/RubyXL/CT_ColorScheme.html +13 -19
  89. data/rdoc/RubyXL/CT_ColorSchemeAndMapping.html +13 -19
  90. data/rdoc/RubyXL/CT_ConnectionSite.html +13 -19
  91. data/rdoc/RubyXL/CT_ConnectionSiteList.html +13 -19
  92. data/rdoc/RubyXL/CT_DashStop.html +13 -19
  93. data/rdoc/RubyXL/CT_DashStopList.html +13 -19
  94. data/rdoc/RubyXL/CT_DefaultShapeDefinition.html +13 -19
  95. data/rdoc/RubyXL/CT_DuotoneEffect.html +13 -19
  96. data/rdoc/RubyXL/CT_EffectContainer.html +13 -19
  97. data/rdoc/RubyXL/CT_EffectList.html +13 -19
  98. data/rdoc/RubyXL/CT_EffectReference.html +13 -19
  99. data/rdoc/RubyXL/CT_EffectStyleItem.html +13 -19
  100. data/rdoc/RubyXL/CT_EffectStyleList.html +13 -19
  101. data/rdoc/RubyXL/CT_EmbeddedWAVAudioFile.html +13 -19
  102. data/rdoc/RubyXL/CT_FillEffect.html +13 -19
  103. data/rdoc/RubyXL/CT_FillOverlayEffect.html +13 -19
  104. data/rdoc/RubyXL/CT_FillStyleList.html +13 -19
  105. data/rdoc/RubyXL/CT_FlatText.html +13 -19
  106. data/rdoc/RubyXL/CT_FontCollection.html +13 -19
  107. data/rdoc/RubyXL/CT_FontReference.html +13 -19
  108. data/rdoc/RubyXL/CT_GeomGuideList.html +13 -19
  109. data/rdoc/RubyXL/CT_GlowEffect.html +13 -19
  110. data/rdoc/RubyXL/CT_GradientFillProperties.html +13 -19
  111. data/rdoc/RubyXL/CT_GradientStop.html +13 -19
  112. data/rdoc/RubyXL/CT_GradientStopList.html +13 -19
  113. data/rdoc/RubyXL/CT_HSLEffect.html +13 -19
  114. data/rdoc/RubyXL/CT_HslColor.html +13 -19
  115. data/rdoc/RubyXL/CT_Hyperlink.html +13 -19
  116. data/rdoc/RubyXL/CT_InnerShadowEffect.html +13 -19
  117. data/rdoc/RubyXL/CT_LightRig.html +13 -19
  118. data/rdoc/RubyXL/CT_LineEndProperties.html +13 -19
  119. data/rdoc/RubyXL/CT_LineJoinMiterProperties.html +13 -19
  120. data/rdoc/RubyXL/CT_LineProperties.html +13 -19
  121. data/rdoc/RubyXL/CT_LineStyleList.html +13 -19
  122. data/rdoc/RubyXL/CT_LinearShadeProperties.html +13 -19
  123. data/rdoc/RubyXL/CT_LuminanceEffect.html +13 -19
  124. data/rdoc/RubyXL/CT_ObjectStyleDefaults.html +13 -19
  125. data/rdoc/RubyXL/CT_OuterShadowEffect.html +13 -19
  126. data/rdoc/RubyXL/CT_Path2D.html +13 -19
  127. data/rdoc/RubyXL/CT_Path2DArcTo.html +13 -19
  128. data/rdoc/RubyXL/CT_Path2DCubicBezierTo.html +13 -19
  129. data/rdoc/RubyXL/CT_Path2DList.html +13 -19
  130. data/rdoc/RubyXL/CT_Path2DQuadBezierTo.html +13 -19
  131. data/rdoc/RubyXL/CT_Path2DTo.html +13 -19
  132. data/rdoc/RubyXL/CT_PathShadeProperties.html +13 -19
  133. data/rdoc/RubyXL/CT_PatternFillProperties.html +13 -19
  134. data/rdoc/RubyXL/CT_Point3D.html +13 -19
  135. data/rdoc/RubyXL/CT_PolarAdjustHandle.html +13 -19
  136. data/rdoc/RubyXL/CT_PresetColor.html +13 -19
  137. data/rdoc/RubyXL/CT_PresetLineDashProperties.html +13 -19
  138. data/rdoc/RubyXL/CT_PresetShadowEffect.html +13 -19
  139. data/rdoc/RubyXL/CT_PresetTextShape.html +13 -19
  140. data/rdoc/RubyXL/CT_ReflectionEffect.html +13 -19
  141. data/rdoc/RubyXL/CT_RelativeOffsetEffect.html +13 -19
  142. data/rdoc/RubyXL/CT_RelativeRect.html +13 -19
  143. data/rdoc/RubyXL/CT_SRgbColor.html +13 -19
  144. data/rdoc/RubyXL/CT_ScRgbColor.html +13 -19
  145. data/rdoc/RubyXL/CT_Scene3D.html +13 -19
  146. data/rdoc/RubyXL/CT_SchemeColor.html +13 -19
  147. data/rdoc/RubyXL/CT_Shape3D.html +13 -19
  148. data/rdoc/RubyXL/CT_ShapeStyle.html +13 -19
  149. data/rdoc/RubyXL/CT_SoftEdgesEffect.html +13 -19
  150. data/rdoc/RubyXL/CT_SphereCoords.html +13 -19
  151. data/rdoc/RubyXL/CT_StretchInfoProperties.html +13 -19
  152. data/rdoc/RubyXL/CT_StyleMatrix.html +13 -19
  153. data/rdoc/RubyXL/CT_StyleMatrixReference.html +13 -19
  154. data/rdoc/RubyXL/CT_SupplementalFont.html +13 -19
  155. data/rdoc/RubyXL/CT_SystemColor.html +13 -19
  156. data/rdoc/RubyXL/CT_TextAutonumberBullet.html +13 -19
  157. data/rdoc/RubyXL/CT_TextBlipBullet.html +13 -19
  158. data/rdoc/RubyXL/CT_TextCharBullet.html +13 -19
  159. data/rdoc/RubyXL/CT_TextCharacterProperties.html +13 -19
  160. data/rdoc/RubyXL/CT_TextFont.html +13 -19
  161. data/rdoc/RubyXL/CT_TextListStyle.html +13 -19
  162. data/rdoc/RubyXL/CT_TextNormalAutofit.html +13 -19
  163. data/rdoc/RubyXL/CT_TextParagraphProperties.html +13 -19
  164. data/rdoc/RubyXL/CT_TextSpacing.html +13 -19
  165. data/rdoc/RubyXL/CT_TextTabStop.html +13 -19
  166. data/rdoc/RubyXL/CT_TextTabStopList.html +13 -19
  167. data/rdoc/RubyXL/CT_TileInfoProperties.html +13 -19
  168. data/rdoc/RubyXL/CT_TintEffect.html +13 -19
  169. data/rdoc/RubyXL/CT_Transform2D.html +13 -19
  170. data/rdoc/RubyXL/CT_TransformEffect.html +13 -19
  171. data/rdoc/RubyXL/CT_Vector3D.html +13 -19
  172. data/rdoc/RubyXL/CT_XYAdjustHandle.html +13 -19
  173. data/rdoc/RubyXL/CalculationChain.html +17 -45
  174. data/rdoc/RubyXL/CalculationChainCell.html +13 -19
  175. data/rdoc/RubyXL/CalculationProperties.html +13 -19
  176. data/rdoc/RubyXL/Cell.html +144 -204
  177. data/rdoc/RubyXL/CellConvenienceMethods.html +240 -426
  178. data/rdoc/RubyXL/CellExt.html +13 -19
  179. data/rdoc/RubyXL/CellSmartTag.html +13 -19
  180. data/rdoc/RubyXL/CellSmartTagProperty.html +13 -19
  181. data/rdoc/RubyXL/CellSmartTags.html +13 -19
  182. data/rdoc/RubyXL/CellStyle.html +13 -19
  183. data/rdoc/RubyXL/CellStyleXFs.html +18 -38
  184. data/rdoc/RubyXL/CellStyles.html +18 -38
  185. data/rdoc/RubyXL/CellValue.html +18 -38
  186. data/rdoc/RubyXL/CellWatch.html +13 -19
  187. data/rdoc/RubyXL/CellWatches.html +13 -19
  188. data/rdoc/RubyXL/CellXFs.html +19 -39
  189. data/rdoc/RubyXL/ChartColorsFile.html +12 -25
  190. data/rdoc/RubyXL/ChartFile.html +19 -49
  191. data/rdoc/RubyXL/ChartStyleFile.html +12 -25
  192. data/rdoc/RubyXL/ChartUserShapesFile.html +12 -25
  193. data/rdoc/RubyXL/Chartsheet.html +19 -67
  194. data/rdoc/RubyXL/ChartsheetPageSetup.html +13 -19
  195. data/rdoc/RubyXL/ChartsheetProperties.html +13 -19
  196. data/rdoc/RubyXL/ChartsheetProtection.html +13 -19
  197. data/rdoc/RubyXL/ChartsheetView.html +13 -19
  198. data/rdoc/RubyXL/ChartsheetViews.html +13 -19
  199. data/rdoc/RubyXL/Color.html +28 -39
  200. data/rdoc/RubyXL/ColorConvenienceClasses.html +91 -0
  201. data/rdoc/RubyXL/ColorConvenienceClasses/HlsColor.html +242 -0
  202. data/rdoc/RubyXL/ColorConvenienceClasses/RgbColor.html +279 -0
  203. data/rdoc/RubyXL/ColorConvenienceMethods.html +137 -0
  204. data/rdoc/RubyXL/ColorFilter.html +13 -19
  205. data/rdoc/RubyXL/ColorScale.html +13 -19
  206. data/rdoc/RubyXL/ColorSet.html +13 -19
  207. data/rdoc/RubyXL/Colors.html +13 -19
  208. data/rdoc/RubyXL/ColumnRange.html +20 -71
  209. data/rdoc/RubyXL/ColumnRanges.html +20 -79
  210. data/rdoc/RubyXL/Comment.html +13 -19
  211. data/rdoc/RubyXL/CommentList.html +13 -19
  212. data/rdoc/RubyXL/CommentsFile.html +17 -50
  213. data/rdoc/RubyXL/ConditionalFormatValue.html +13 -19
  214. data/rdoc/RubyXL/ConditionalFormatting.html +13 -19
  215. data/rdoc/RubyXL/ConditionalFormattingRule.html +13 -19
  216. data/rdoc/RubyXL/Connection.html +99 -0
  217. data/rdoc/RubyXL/ConnectionTable.html +99 -0
  218. data/rdoc/RubyXL/ConnectionTables.html +99 -0
  219. data/rdoc/RubyXL/ConnectionTextField.html +99 -0
  220. data/rdoc/RubyXL/ConnectionTextFields.html +99 -0
  221. data/rdoc/RubyXL/Connections.html +147 -0
  222. data/rdoc/RubyXL/ContentTypeDefault.html +12 -17
  223. data/rdoc/RubyXL/ContentTypeOverride.html +12 -17
  224. data/rdoc/RubyXL/ContentTypes.html +23 -63
  225. data/rdoc/RubyXL/ControlPropertiesFile.html +14 -22
  226. data/rdoc/RubyXL/CorePropertiesFile.html +26 -162
  227. data/rdoc/RubyXL/CustomColor.html +13 -19
  228. data/rdoc/RubyXL/CustomColorList.html +13 -19
  229. data/rdoc/RubyXL/CustomFilter.html +13 -19
  230. data/rdoc/RubyXL/CustomFilters.html +13 -19
  231. data/rdoc/RubyXL/CustomGeometry.html +13 -19
  232. data/rdoc/RubyXL/CustomProperties.html +13 -19
  233. data/rdoc/RubyXL/CustomPropertiesFile.html +12 -25
  234. data/rdoc/RubyXL/CustomProperty.html +13 -19
  235. data/rdoc/RubyXL/CustomPropertyFile.html +108 -0
  236. data/rdoc/RubyXL/CustomSheetView.html +13 -19
  237. data/rdoc/RubyXL/CustomSheetViews.html +13 -19
  238. data/rdoc/RubyXL/CustomWorkbookView.html +13 -19
  239. data/rdoc/RubyXL/CustomWorkbookViews.html +13 -19
  240. data/rdoc/RubyXL/CustomXMLFile.html +12 -22
  241. data/rdoc/RubyXL/DXF.html +13 -19
  242. data/rdoc/RubyXL/DXFs.html +13 -19
  243. data/rdoc/RubyXL/DataBar.html +13 -19
  244. data/rdoc/RubyXL/DataConsolidate.html +13 -19
  245. data/rdoc/RubyXL/DataConsolidationReference.html +13 -19
  246. data/rdoc/RubyXL/DataConsolidationReferences.html +13 -19
  247. data/rdoc/RubyXL/DataType.html +11 -39
  248. data/rdoc/RubyXL/DataValidation.html +13 -19
  249. data/rdoc/RubyXL/DataValidations.html +13 -19
  250. data/rdoc/RubyXL/DateGroupItem.html +13 -19
  251. data/rdoc/RubyXL/DefinedName.html +13 -19
  252. data/rdoc/RubyXL/DefinedNameExt.html +13 -19
  253. data/rdoc/RubyXL/DefinedNames.html +13 -19
  254. data/rdoc/RubyXL/DefinedNamesExt.html +13 -19
  255. data/rdoc/RubyXL/DocumentPropertiesFile.html +20 -66
  256. data/rdoc/RubyXL/DrawingFile.html +19 -49
  257. data/rdoc/RubyXL/DynamicFilter.html +13 -19
  258. data/rdoc/RubyXL/EmbeddedControl.html +13 -19
  259. data/rdoc/RubyXL/EmbeddedControls.html +13 -19
  260. data/rdoc/RubyXL/Extension.html +13 -19
  261. data/rdoc/RubyXL/ExtensionStorageArea.html +13 -19
  262. data/rdoc/RubyXL/Extents.html +13 -19
  263. data/rdoc/RubyXL/ExternalBook.html +13 -19
  264. data/rdoc/RubyXL/ExternalLinksFile.html +19 -49
  265. data/rdoc/RubyXL/ExternalReference.html +13 -19
  266. data/rdoc/RubyXL/ExternalReferences.html +13 -19
  267. data/rdoc/RubyXL/ExtraColorSchemeList.html +13 -19
  268. data/rdoc/RubyXL/FieldItem.html +13 -19
  269. data/rdoc/RubyXL/FileRecoveryProperties.html +13 -19
  270. data/rdoc/RubyXL/FileSharing.html +13 -19
  271. data/rdoc/RubyXL/FileVersion.html +13 -19
  272. data/rdoc/RubyXL/Fill.html +18 -38
  273. data/rdoc/RubyXL/Fills.html +18 -38
  274. data/rdoc/RubyXL/FilterContainer.html +13 -19
  275. data/rdoc/RubyXL/FloatNode.html +12 -17
  276. data/rdoc/RubyXL/FloatValue.html +12 -17
  277. data/rdoc/RubyXL/Font.html +20 -544
  278. data/rdoc/RubyXL/FontConvenienceMethods.html +414 -0
  279. data/rdoc/RubyXL/FontScheme.html +13 -19
  280. data/rdoc/RubyXL/Fonts.html +19 -39
  281. data/rdoc/RubyXL/Formula.html +13 -19
  282. data/rdoc/RubyXL/FunctionGroup.html +13 -19
  283. data/rdoc/RubyXL/FunctionGroups.html +13 -19
  284. data/rdoc/RubyXL/GenericStorageObject.html +19 -81
  285. data/rdoc/RubyXL/GradientFill.html +13 -19
  286. data/rdoc/RubyXL/HeaderFooterSettings.html +13 -19
  287. data/rdoc/RubyXL/Hyperlink.html +13 -19
  288. data/rdoc/RubyXL/HyperlinkRelFile.html +12 -22
  289. data/rdoc/RubyXL/Hyperlinks.html +13 -19
  290. data/rdoc/RubyXL/IconFilter.html +13 -19
  291. data/rdoc/RubyXL/IconSet.html +13 -19
  292. data/rdoc/RubyXL/IgnoredError.html +13 -19
  293. data/rdoc/RubyXL/IgnoredErrors.html +13 -19
  294. data/rdoc/RubyXL/IndexedColors.html +13 -19
  295. data/rdoc/RubyXL/InputCells.html +13 -19
  296. data/rdoc/RubyXL/IntegerNode.html +12 -17
  297. data/rdoc/RubyXL/IntegerValue.html +12 -17
  298. data/rdoc/RubyXL/LegacyCell.html +14 -66
  299. data/rdoc/RubyXL/LegacyWorksheet.html +40 -100
  300. data/rdoc/RubyXL/MRUColors.html +13 -19
  301. data/rdoc/RubyXL/MacrosFile.html +12 -25
  302. data/rdoc/RubyXL/MergedCell.html +13 -19
  303. data/rdoc/RubyXL/MergedCells.html +13 -19
  304. data/rdoc/RubyXL/NumFmt.html +13 -19
  305. data/rdoc/RubyXL/NumberFormat.html +18 -38
  306. data/rdoc/RubyXL/NumberFormats.html +18 -44
  307. data/rdoc/RubyXL/OLEObject.html +13 -19
  308. data/rdoc/RubyXL/OLEObjectFile.html +12 -25
  309. data/rdoc/RubyXL/OLEObjects.html +13 -19
  310. data/rdoc/RubyXL/OLESize.html +13 -19
  311. data/rdoc/RubyXL/OOXMLContainerObject.html +36 -132
  312. data/rdoc/RubyXL/OOXMLIgnored.html +163 -0
  313. data/rdoc/RubyXL/OOXMLObject.html +15 -25
  314. data/rdoc/RubyXL/OOXMLObjectClassMethods.html +88 -179
  315. data/rdoc/RubyXL/OOXMLObjectInstanceMethods.html +47 -183
  316. data/rdoc/RubyXL/OOXMLRelationshipsFile.html +42 -194
  317. data/rdoc/RubyXL/OOXMLTopLevelObject.html +37 -133
  318. data/rdoc/RubyXL/OdbcOleDbProperties.html +99 -0
  319. data/rdoc/RubyXL/Offset.html +13 -19
  320. data/rdoc/RubyXL/OlapProperties.html +99 -0
  321. data/rdoc/RubyXL/OleItem.html +99 -0
  322. data/rdoc/RubyXL/OleItems.html +99 -0
  323. data/rdoc/RubyXL/OleLink.html +99 -0
  324. data/rdoc/RubyXL/OutlineProperties.html +13 -19
  325. data/rdoc/RubyXL/PageMargins.html +13 -19
  326. data/rdoc/RubyXL/PageSetup.html +13 -19
  327. data/rdoc/RubyXL/PageSetupProperties.html +13 -19
  328. data/rdoc/RubyXL/Pane.html +13 -19
  329. data/rdoc/RubyXL/Parser.html +20 -53
  330. data/rdoc/RubyXL/PatternFill.html +13 -19
  331. data/rdoc/RubyXL/PhoneticProperties.html +13 -19
  332. data/rdoc/RubyXL/PhoneticRun.html +13 -19
  333. data/rdoc/RubyXL/PivotArea.html +13 -19
  334. data/rdoc/RubyXL/PivotCache.html +13 -19
  335. data/rdoc/RubyXL/PivotCacheDefinitionFile.html +14 -30
  336. data/rdoc/RubyXL/PivotCacheRecordsFile.html +12 -25
  337. data/rdoc/RubyXL/PivotCaches.html +13 -19
  338. data/rdoc/RubyXL/PivotReference.html +13 -19
  339. data/rdoc/RubyXL/PivotReferences.html +13 -19
  340. data/rdoc/RubyXL/PivotTableFile.html +14 -30
  341. data/rdoc/RubyXL/PivotTableSelection.html +13 -19
  342. data/rdoc/RubyXL/PresetGeometry.html +13 -19
  343. data/rdoc/RubyXL/PrintOptions.html +13 -19
  344. data/rdoc/RubyXL/PrinterSettingsFile.html +12 -25
  345. data/rdoc/RubyXL/ProtectedRange.html +13 -19
  346. data/rdoc/RubyXL/ProtectedRanges.html +13 -19
  347. data/rdoc/RubyXL/Protection.html +13 -19
  348. data/rdoc/RubyXL/QueryParameter.html +99 -0
  349. data/rdoc/RubyXL/QueryParameters.html +99 -0
  350. data/rdoc/RubyXL/QueryTable.html +155 -0
  351. data/rdoc/RubyXL/QueryTableDeletedField.html +99 -0
  352. data/rdoc/RubyXL/QueryTableDeletedFields.html +99 -0
  353. data/rdoc/RubyXL/QueryTableField.html +99 -0
  354. data/rdoc/RubyXL/QueryTableFields.html +99 -0
  355. data/rdoc/RubyXL/QueryTableRefresh.html +99 -0
  356. data/rdoc/RubyXL/RID.html +12 -17
  357. data/rdoc/RubyXL/RawOOXML.html +19 -58
  358. data/rdoc/RubyXL/Reference.html +31 -215
  359. data/rdoc/RubyXL/Relationship.html +12 -17
  360. data/rdoc/RubyXL/RelationshipSupport.html +32 -126
  361. data/rdoc/RubyXL/RelationshipSupport/ClassMehods.html +15 -33
  362. data/rdoc/RubyXL/RevisionPointer.html +99 -0
  363. data/rdoc/RubyXL/RichText.html +18 -38
  364. data/rdoc/RubyXL/RichTextRun.html +17 -37
  365. data/rdoc/RubyXL/Row.html +53 -152
  366. data/rdoc/RubyXL/RowExt.html +13 -19
  367. data/rdoc/RubyXL/RunProperties.html +13 -19
  368. data/rdoc/RubyXL/Scenario.html +13 -19
  369. data/rdoc/RubyXL/Scenarios.html +13 -19
  370. data/rdoc/RubyXL/Selection.html +20 -40
  371. data/rdoc/RubyXL/ShapeGuide.html +13 -19
  372. data/rdoc/RubyXL/ShapeTextRectangle.html +13 -19
  373. data/rdoc/RubyXL/SharedStringsTable.html +31 -140
  374. data/rdoc/RubyXL/Sheet.html +13 -19
  375. data/rdoc/RubyXL/SheetCalculationProperties.html +13 -19
  376. data/rdoc/RubyXL/SheetData.html +20 -53
  377. data/rdoc/RubyXL/SheetDataExt.html +13 -19
  378. data/rdoc/RubyXL/SheetDataSet.html +13 -19
  379. data/rdoc/RubyXL/SheetName.html +13 -19
  380. data/rdoc/RubyXL/SheetNames.html +13 -19
  381. data/rdoc/RubyXL/Sheets.html +13 -19
  382. data/rdoc/RubyXL/SlicerCacheFile.html +12 -25
  383. data/rdoc/RubyXL/SlicerFile.html +12 -25
  384. data/rdoc/RubyXL/SmartTagProperties.html +13 -19
  385. data/rdoc/RubyXL/SmartTagType.html +13 -19
  386. data/rdoc/RubyXL/SmartTagTypes.html +13 -19
  387. data/rdoc/RubyXL/SmartTags.html +13 -19
  388. data/rdoc/RubyXL/SortCondition.html +13 -19
  389. data/rdoc/RubyXL/SortState.html +13 -19
  390. data/rdoc/RubyXL/Sqref.html +18 -51
  391. data/rdoc/RubyXL/Stop.html +13 -19
  392. data/rdoc/RubyXL/StringNode.html +12 -17
  393. data/rdoc/RubyXL/StringNodeW3C.html +19 -52
  394. data/rdoc/RubyXL/StringValue.html +12 -17
  395. data/rdoc/RubyXL/Stylesheet.html +30 -112
  396. data/rdoc/RubyXL/TableFile.html +12 -25
  397. data/rdoc/RubyXL/TableParts.html +12 -17
  398. data/rdoc/RubyXL/TableStyle.html +13 -19
  399. data/rdoc/RubyXL/TableStyles.html +13 -19
  400. data/rdoc/RubyXL/Text.html +19 -63
  401. data/rdoc/RubyXL/TextImportSettings.html +99 -0
  402. data/rdoc/RubyXL/Theme.html +58 -63
  403. data/rdoc/RubyXL/ThemeElements.html +13 -19
  404. data/rdoc/RubyXL/ThumbnailFile.html +12 -25
  405. data/rdoc/RubyXL/Top10.html +13 -19
  406. data/rdoc/RubyXL/VMLDrawingFile.html +15 -32
  407. data/rdoc/RubyXL/Variant.html +13 -19
  408. data/rdoc/RubyXL/Vector.html +17 -37
  409. data/rdoc/RubyXL/VectorValue.html +12 -17
  410. data/rdoc/RubyXL/VisualProperties.html +13 -19
  411. data/rdoc/RubyXL/WebPublishObject.html +13 -19
  412. data/rdoc/RubyXL/WebPublishObjects.html +13 -19
  413. data/rdoc/RubyXL/WebPublishingItem.html +13 -19
  414. data/rdoc/RubyXL/WebPublishingItems.html +13 -19
  415. data/rdoc/RubyXL/WebPublishingProperties.html +13 -19
  416. data/rdoc/RubyXL/WebQueryProperties.html +99 -0
  417. data/rdoc/RubyXL/Workbook.html +483 -226
  418. data/rdoc/RubyXL/WorkbookConvenienceMethods.html +149 -857
  419. data/rdoc/RubyXL/WorkbookProperties.html +13 -19
  420. data/rdoc/RubyXL/WorkbookProtection.html +13 -19
  421. data/rdoc/RubyXL/WorkbookRoot.html +23 -109
  422. data/rdoc/RubyXL/WorkbookView.html +13 -19
  423. data/rdoc/RubyXL/WorkbookViews.html +13 -19
  424. data/rdoc/RubyXL/Worksheet.html +70 -122
  425. data/rdoc/RubyXL/WorksheetConvenienceMethods.html +398 -1049
  426. data/rdoc/RubyXL/WorksheetDimensions.html +13 -19
  427. data/rdoc/RubyXL/WorksheetFormatProperties.html +12 -17
  428. data/rdoc/RubyXL/WorksheetProperties.html +13 -19
  429. data/rdoc/RubyXL/WorksheetProtection.html +13 -19
  430. data/rdoc/RubyXL/WorksheetView.html +13 -19
  431. data/rdoc/RubyXL/WorksheetViews.html +13 -19
  432. data/rdoc/RubyXL/XF.html +13 -19
  433. data/rdoc/created.rid +45 -38
  434. data/rdoc/css/fonts.css +6 -6
  435. data/rdoc/css/rdoc.css +35 -6
  436. data/rdoc/index.html +43 -363
  437. data/rdoc/js/darkfish.js +23 -100
  438. data/rdoc/js/navigation.js +4 -41
  439. data/rdoc/js/navigation.js.gz +0 -0
  440. data/rdoc/js/search.js +32 -31
  441. data/rdoc/js/search_index.js +1 -1
  442. data/rdoc/js/search_index.js.gz +0 -0
  443. data/rdoc/js/searcher.js +7 -6
  444. data/rdoc/js/searcher.js.gz +0 -0
  445. data/rdoc/table_of_contents.html +368 -75
  446. data/rubyXL.gemspec +60 -26
  447. data/spec/lib/cell_spec.rb +147 -2
  448. data/spec/lib/color_spec.rb +1 -0
  449. data/spec/lib/parser_spec.rb +1 -1
  450. data/spec/lib/rgb_color_spec.rb +16 -0
  451. data/spec/lib/text_spec.rb +8 -0
  452. data/spec/lib/workbook_spec.rb +12 -1
  453. data/spec/lib/worksheet_spec.rb +353 -37
  454. data/test/test_parse_write.rb +15 -15
  455. metadata +63 -9
  456. data/rdoc/js/jquery.js +0 -4
@@ -4,20 +4,23 @@
4
4
  <head>
5
5
  <meta charset="UTF-8">
6
6
 
7
- <title>module RubyXL::WorkbookConvenienceMethods - rubyXL 3.3.21</title>
7
+ <title>module RubyXL::WorkbookConvenienceMethods - rubyXL 3.4.17</title>
8
8
 
9
9
  <script type="text/javascript">
10
10
  var rdoc_rel_prefix = "../";
11
+ var index_rel_prefix = "../";
11
12
  </script>
12
13
 
13
- <script src="../js/jquery.js"></script>
14
- <script src="../js/darkfish.js"></script>
14
+ <script src="../js/navigation.js" defer></script>
15
+ <script src="../js/search.js" defer></script>
16
+ <script src="../js/search_index.js" defer></script>
17
+ <script src="../js/searcher.js" defer></script>
18
+ <script src="../js/darkfish.js" defer></script>
15
19
 
16
20
  <link href="../css/fonts.css" rel="stylesheet">
17
21
  <link href="../css/rdoc.css" rel="stylesheet">
18
22
 
19
23
 
20
-
21
24
  <body id="top" role="document" class="module">
22
25
  <nav role="navigation">
23
26
  <div id="project-navigation">
@@ -57,72 +60,28 @@
57
60
 
58
61
 
59
62
 
60
- <!-- Method Quickref -->
63
+
64
+ <!-- Method Quickref -->
61
65
  <div id="method-list-section" class="nav-section">
62
66
  <h3>Methods</h3>
63
67
 
64
68
  <ul class="link-list" role="directory">
65
-
66
- <li ><a href="#method-i-5B-5D">#[]</a>
67
-
68
- <li ><a href="#method-i-add_worksheet">#add_worksheet</a>
69
-
70
- <li ><a href="#method-i-application">#application</a>
71
-
72
- <li ><a href="#method-i-application-3D">#application=</a>
73
-
74
- <li ><a href="#method-i-appversion">#appversion</a>
75
-
76
- <li ><a href="#method-i-appversion-3D">#appversion=</a>
77
-
78
69
  <li ><a href="#method-i-borders">#borders</a>
79
-
80
70
  <li ><a href="#method-i-cell_xfs">#cell_xfs</a>
81
-
82
- <li ><a href="#method-i-company">#company</a>
83
-
84
- <li ><a href="#method-i-company-3D">#company=</a>
85
-
86
- <li ><a href="#method-i-created_at">#created_at</a>
87
-
88
- <li ><a href="#method-i-created_at-3D">#created_at=</a>
89
-
90
- <li ><a href="#method-i-creator">#creator</a>
91
-
92
- <li ><a href="#method-i-creator-3D">#creator=</a>
93
-
94
- <li ><a href="#method-i-date1904">#date1904</a>
95
-
96
- <li ><a href="#method-i-date1904-3D">#date1904=</a>
97
-
71
+ <li ><a href="#method-i-define_new_name">#define_new_name</a>
98
72
  <li ><a href="#method-i-each">#each</a>
99
-
100
73
  <li ><a href="#method-i-fills">#fills</a>
101
-
102
74
  <li ><a href="#method-i-fonts">#fonts</a>
103
-
75
+ <li ><a href="#method-i-get_defined_name">#get_defined_name</a>
104
76
  <li ><a href="#method-i-get_fill_color">#get_fill_color</a>
105
-
106
- <li ><a href="#method-i-modified_at">#modified_at</a>
107
-
108
- <li ><a href="#method-i-modified_at-3D">#modified_at=</a>
109
-
110
- <li ><a href="#method-i-modifier">#modifier</a>
111
-
112
- <li ><a href="#method-i-modifier-3D">#modifier=</a>
113
-
114
77
  <li ><a href="#method-i-modify_alignment">#modify_alignment</a>
115
-
116
78
  <li ><a href="#method-i-modify_border">#modify_border</a>
117
-
79
+ <li ><a href="#method-i-modify_border_color">#modify_border_color</a>
118
80
  <li ><a href="#method-i-modify_fill">#modify_fill</a>
119
-
81
+ <li ><a href="#method-i-password_hash">#password_hash</a>
120
82
  <li ><a href="#method-i-register_new_fill">#register_new_fill</a>
121
-
122
83
  <li ><a href="#method-i-register_new_font">#register_new_font</a>
123
-
124
84
  <li ><a href="#method-i-register_new_xf">#register_new_xf</a>
125
-
126
85
  </ul>
127
86
  </div>
128
87
 
@@ -130,923 +89,280 @@
130
89
  </nav>
131
90
 
132
91
  <main role="main" aria-labelledby="module-RubyXL::WorkbookConvenienceMethods">
133
- <h1 id="module-RubyXL::WorkbookConvenienceMethods" class="module">
134
- module RubyXL::WorkbookConvenienceMethods
135
- </h1>
136
-
137
- <section class="description">
138
-
139
- </section>
140
-
141
-
142
-
143
-
144
- <section id="5Buntitled-5D" class="documentation-section">
145
-
146
-
147
-
148
-
149
-
150
- <section class="constants-list">
151
- <header>
152
- <h3>Constants</h3>
153
- </header>
154
- <dl>
155
-
156
- <dt id="SHEET_NAME_TEMPLATE">SHEET_NAME_TEMPLATE
157
-
158
- <dd>
159
-
160
-
161
- </dl>
162
- </section>
163
-
164
-
165
-
166
-
167
-
168
- <section id="public-instance-5Buntitled-5D-method-details" class="method-section">
169
- <header>
170
- <h3>Public Instance Methods</h3>
171
- </header>
172
-
173
-
174
- <div id="method-i-5B-5D" class="method-detail ">
175
-
176
- <div class="method-heading">
177
- <span class="method-name">[]</span><span
178
- class="method-args">(ind)</span>
179
-
180
- <span class="method-click-advice">click to toggle source</span>
181
-
182
- </div>
183
-
184
-
185
- <div class="method-description">
186
-
187
- <p>Finds worksheet by its name or numerical index</p>
188
-
189
-
190
-
191
-
192
- <div class="method-source-code" id="5B-5D-source">
193
- <pre><span class="ruby-comment"># File lib/rubyXL/convenience_methods.rb, line 7</span>
194
- <span class="ruby-keyword">def</span> <span class="ruby-operator">[]</span>(<span class="ruby-identifier">ind</span>)
195
- <span class="ruby-keyword">case</span> <span class="ruby-identifier">ind</span>
196
- <span class="ruby-keyword">when</span> <span class="ruby-constant">Integer</span> <span class="ruby-keyword">then</span> <span class="ruby-identifier">worksheets</span>[<span class="ruby-identifier">ind</span>]
197
- <span class="ruby-keyword">when</span> <span class="ruby-constant">String</span> <span class="ruby-keyword">then</span> <span class="ruby-identifier">worksheets</span>.<span class="ruby-identifier">find</span> { <span class="ruby-operator">|</span><span class="ruby-identifier">ws</span><span class="ruby-operator">|</span> <span class="ruby-identifier">ws</span>.<span class="ruby-identifier">sheet_name</span> <span class="ruby-operator">==</span> <span class="ruby-identifier">ind</span> }
198
- <span class="ruby-keyword">end</span>
199
- <span class="ruby-keyword">end</span></pre>
200
- </div>
201
-
202
- </div>
203
-
204
-
205
-
206
-
207
- </div>
208
-
209
-
210
- <div id="method-i-add_worksheet" class="method-detail ">
211
-
212
- <div class="method-heading">
213
- <span class="method-name">add_worksheet</span><span
214
- class="method-args">(name = nil)</span>
215
-
216
- <span class="method-click-advice">click to toggle source</span>
217
-
218
- </div>
219
-
220
-
221
- <div class="method-description">
222
-
223
- <p>Create new simple worksheet and add it to the workbook worksheets</p>
224
-
225
- <p>@param [String] The name for the new worksheet</p>
226
-
227
-
228
-
229
-
230
- <div class="method-source-code" id="add_worksheet-source">
231
- <pre><span class="ruby-comment"># File lib/rubyXL/convenience_methods.rb, line 17</span>
232
- <span class="ruby-keyword">def</span> <span class="ruby-identifier">add_worksheet</span>(<span class="ruby-identifier">name</span> = <span class="ruby-keyword">nil</span>)
233
- <span class="ruby-keyword">if</span> <span class="ruby-identifier">name</span>.<span class="ruby-identifier">nil?</span> <span class="ruby-keyword">then</span>
234
- <span class="ruby-identifier">n</span> = <span class="ruby-value">0</span>
235
-
236
- <span class="ruby-keyword">begin</span>
237
- <span class="ruby-identifier">name</span> = <span class="ruby-constant">SHEET_NAME_TEMPLATE</span> <span class="ruby-operator">%</span> (<span class="ruby-identifier">n</span> <span class="ruby-operator">+=</span> <span class="ruby-value">1</span>)
238
- <span class="ruby-keyword">end</span> <span class="ruby-keyword">until</span> <span class="ruby-keyword">self</span>[<span class="ruby-identifier">name</span>].<span class="ruby-identifier">nil?</span>
239
- <span class="ruby-keyword">end</span>
240
-
241
- <span class="ruby-identifier">new_worksheet</span> = <span class="ruby-constant">Worksheet</span>.<span class="ruby-identifier">new</span>(<span class="ruby-value">:workbook</span> =<span class="ruby-operator">&gt;</span> <span class="ruby-keyword">self</span>, <span class="ruby-value">:sheet_name</span> =<span class="ruby-operator">&gt;</span> <span class="ruby-identifier">name</span>)
242
- <span class="ruby-identifier">worksheets</span> <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-identifier">new_worksheet</span>
243
- <span class="ruby-identifier">new_worksheet</span>
244
- <span class="ruby-keyword">end</span></pre>
245
- </div>
246
-
247
- </div>
248
-
249
-
250
-
251
-
252
- </div>
253
-
254
-
255
- <div id="method-i-application" class="method-detail ">
256
-
257
- <div class="method-heading">
258
- <span class="method-name">application</span><span
259
- class="method-args">()</span>
260
-
261
- <span class="method-click-advice">click to toggle source</span>
262
-
263
- </div>
264
-
265
-
266
- <div class="method-description">
267
-
268
-
269
-
270
-
271
-
272
-
273
- <div class="method-source-code" id="application-source">
274
- <pre><span class="ruby-comment"># File lib/rubyXL/convenience_methods.rb, line 53</span>
275
- <span class="ruby-keyword">def</span> <span class="ruby-identifier">application</span>
276
- <span class="ruby-identifier">root</span>.<span class="ruby-identifier">document_properties</span>.<span class="ruby-identifier">application</span> <span class="ruby-operator">&amp;&amp;</span> <span class="ruby-identifier">root</span>.<span class="ruby-identifier">document_properties</span>.<span class="ruby-identifier">application</span>.<span class="ruby-identifier">value</span>
277
- <span class="ruby-keyword">end</span></pre>
278
- </div>
279
-
280
- </div>
281
-
282
-
283
-
284
-
285
- </div>
286
-
287
-
288
- <div id="method-i-application-3D" class="method-detail ">
289
-
290
- <div class="method-heading">
291
- <span class="method-name">application=</span><span
292
- class="method-args">(v)</span>
293
-
294
- <span class="method-click-advice">click to toggle source</span>
295
-
296
- </div>
297
-
298
-
299
- <div class="method-description">
300
-
301
-
302
-
303
-
304
-
305
-
306
- <div class="method-source-code" id="application-3D-source">
307
- <pre><span class="ruby-comment"># File lib/rubyXL/convenience_methods.rb, line 57</span>
308
- <span class="ruby-keyword">def</span> <span class="ruby-identifier">application=</span>(<span class="ruby-identifier">v</span>)
309
- <span class="ruby-identifier">root</span>.<span class="ruby-identifier">document_properties</span>.<span class="ruby-identifier">application</span> <span class="ruby-operator">||=</span> <span class="ruby-constant">StringNode</span>.<span class="ruby-identifier">new</span>
310
- <span class="ruby-identifier">root</span>.<span class="ruby-identifier">document_properties</span>.<span class="ruby-identifier">application</span>.<span class="ruby-identifier">value</span> = <span class="ruby-identifier">v</span>
311
- <span class="ruby-keyword">end</span></pre>
312
- </div>
313
-
314
- </div>
315
-
316
-
317
-
318
-
319
- </div>
320
-
321
-
322
- <div id="method-i-appversion" class="method-detail ">
323
-
324
- <div class="method-heading">
325
- <span class="method-name">appversion</span><span
326
- class="method-args">()</span>
327
-
328
- <span class="method-click-advice">click to toggle source</span>
329
-
330
- </div>
331
-
332
-
333
- <div class="method-description">
334
-
335
-
336
-
337
-
338
-
339
-
340
- <div class="method-source-code" id="appversion-source">
341
- <pre><span class="ruby-comment"># File lib/rubyXL/convenience_methods.rb, line 62</span>
342
- <span class="ruby-keyword">def</span> <span class="ruby-identifier">appversion</span>
343
- <span class="ruby-identifier">root</span>.<span class="ruby-identifier">document_properties</span>.<span class="ruby-identifier">app_version</span> <span class="ruby-operator">&amp;&amp;</span> <span class="ruby-identifier">root</span>.<span class="ruby-identifier">document_properties</span>.<span class="ruby-identifier">app_version</span>.<span class="ruby-identifier">value</span>
344
- <span class="ruby-keyword">end</span></pre>
345
- </div>
346
-
347
- </div>
348
-
349
-
350
-
351
-
352
- </div>
353
-
354
-
355
- <div id="method-i-appversion-3D" class="method-detail ">
356
-
357
- <div class="method-heading">
358
- <span class="method-name">appversion=</span><span
359
- class="method-args">(v)</span>
360
-
361
- <span class="method-click-advice">click to toggle source</span>
362
-
363
- </div>
364
-
365
-
366
- <div class="method-description">
367
-
368
-
369
-
370
-
371
-
372
-
373
- <div class="method-source-code" id="appversion-3D-source">
374
- <pre><span class="ruby-comment"># File lib/rubyXL/convenience_methods.rb, line 66</span>
375
- <span class="ruby-keyword">def</span> <span class="ruby-identifier">appversion=</span>(<span class="ruby-identifier">v</span>)
376
- <span class="ruby-identifier">root</span>.<span class="ruby-identifier">document_properties</span>.<span class="ruby-identifier">app_version</span> <span class="ruby-operator">||=</span> <span class="ruby-constant">StringNode</span>.<span class="ruby-identifier">new</span>
377
- <span class="ruby-identifier">root</span>.<span class="ruby-identifier">document_properties</span>.<span class="ruby-identifier">app_version</span>.<span class="ruby-identifier">value</span> = <span class="ruby-identifier">v</span>
378
- <span class="ruby-keyword">end</span></pre>
379
- </div>
380
-
381
- </div>
382
-
383
-
384
-
385
-
386
- </div>
387
-
388
-
389
- <div id="method-i-borders" class="method-detail ">
390
-
391
- <div class="method-heading">
392
- <span class="method-name">borders</span><span
393
- class="method-args">()</span>
394
-
395
- <span class="method-click-advice">click to toggle source</span>
396
-
397
- </div>
398
-
399
-
400
- <div class="method-description">
401
-
402
-
403
-
404
-
405
-
406
-
407
- <div class="method-source-code" id="borders-source">
408
- <pre><span class="ruby-comment"># File lib/rubyXL/convenience_methods.rb, line 115</span>
409
- <span class="ruby-keyword">def</span> <span class="ruby-identifier">borders</span> <span class="ruby-comment"># Stylesheet should be pre-filled with defaults on initialize()</span>
410
- <span class="ruby-identifier">stylesheet</span>.<span class="ruby-identifier">borders</span>
411
- <span class="ruby-keyword">end</span></pre>
412
- </div>
413
-
414
- </div>
415
-
416
-
417
-
418
-
419
- </div>
420
-
421
-
422
- <div id="method-i-cell_xfs" class="method-detail ">
423
-
424
- <div class="method-heading">
425
- <span class="method-name">cell_xfs</span><span
426
- class="method-args">()</span>
427
-
428
- <span class="method-click-advice">click to toggle source</span>
429
-
430
- </div>
431
-
432
-
433
- <div class="method-description">
434
-
435
-
436
-
437
-
438
-
439
-
440
- <div class="method-source-code" id="cell_xfs-source">
441
- <pre><span class="ruby-comment"># File lib/rubyXL/convenience_methods.rb, line 103</span>
442
- <span class="ruby-keyword">def</span> <span class="ruby-identifier">cell_xfs</span> <span class="ruby-comment"># Stylesheet should be pre-filled with defaults on initialize()</span>
443
- <span class="ruby-identifier">stylesheet</span>.<span class="ruby-identifier">cell_xfs</span>
444
- <span class="ruby-keyword">end</span></pre>
445
- </div>
446
-
447
- </div>
448
-
449
-
450
-
451
-
452
- </div>
453
-
454
-
455
- <div id="method-i-company" class="method-detail ">
456
-
457
- <div class="method-heading">
458
- <span class="method-name">company</span><span
459
- class="method-args">()</span>
460
-
461
- <span class="method-click-advice">click to toggle source</span>
462
-
463
- </div>
464
-
465
-
466
- <div class="method-description">
467
-
468
-
469
-
470
-
471
-
472
-
473
- <div class="method-source-code" id="company-source">
474
- <pre><span class="ruby-comment"># File lib/rubyXL/convenience_methods.rb, line 44</span>
475
- <span class="ruby-keyword">def</span> <span class="ruby-identifier">company</span>
476
- <span class="ruby-identifier">root</span>.<span class="ruby-identifier">document_properties</span>.<span class="ruby-identifier">company</span> <span class="ruby-operator">&amp;&amp;</span> <span class="ruby-identifier">root</span>.<span class="ruby-identifier">document_properties</span>.<span class="ruby-identifier">company</span>.<span class="ruby-identifier">value</span>
477
- <span class="ruby-keyword">end</span></pre>
478
- </div>
479
-
480
- </div>
481
-
482
-
483
-
484
-
485
- </div>
486
-
487
-
488
- <div id="method-i-company-3D" class="method-detail ">
489
-
490
- <div class="method-heading">
491
- <span class="method-name">company=</span><span
492
- class="method-args">(v)</span>
493
-
494
- <span class="method-click-advice">click to toggle source</span>
495
-
496
- </div>
497
-
498
-
499
- <div class="method-description">
500
-
501
-
502
-
503
-
504
-
505
-
506
- <div class="method-source-code" id="company-3D-source">
507
- <pre><span class="ruby-comment"># File lib/rubyXL/convenience_methods.rb, line 48</span>
508
- <span class="ruby-keyword">def</span> <span class="ruby-identifier">company=</span>(<span class="ruby-identifier">v</span>)
509
- <span class="ruby-identifier">root</span>.<span class="ruby-identifier">document_properties</span>.<span class="ruby-identifier">company</span> <span class="ruby-operator">||=</span> <span class="ruby-constant">StringNode</span>.<span class="ruby-identifier">new</span>
510
- <span class="ruby-identifier">root</span>.<span class="ruby-identifier">document_properties</span>.<span class="ruby-identifier">company</span>.<span class="ruby-identifier">value</span> = <span class="ruby-identifier">v</span>
511
- <span class="ruby-keyword">end</span></pre>
512
- </div>
513
-
514
- </div>
515
-
516
-
517
-
518
-
519
- </div>
520
-
521
-
522
- <div id="method-i-created_at" class="method-detail ">
523
-
524
- <div class="method-heading">
525
- <span class="method-name">created_at</span><span
526
- class="method-args">()</span>
527
-
528
- <span class="method-click-advice">click to toggle source</span>
529
-
530
- </div>
531
-
532
-
533
- <div class="method-description">
534
-
535
-
536
-
537
-
538
-
539
-
540
- <div class="method-source-code" id="created_at-source">
541
- <pre><span class="ruby-comment"># File lib/rubyXL/convenience_methods.rb, line 87</span>
542
- <span class="ruby-keyword">def</span> <span class="ruby-identifier">created_at</span>
543
- <span class="ruby-identifier">root</span>.<span class="ruby-identifier">core_properties</span>.<span class="ruby-identifier">created_at</span>
544
- <span class="ruby-keyword">end</span></pre>
545
- </div>
546
-
547
- </div>
548
-
549
-
550
-
551
-
552
- </div>
553
-
554
-
555
- <div id="method-i-created_at-3D" class="method-detail ">
556
-
557
- <div class="method-heading">
558
- <span class="method-name">created_at=</span><span
559
- class="method-args">(v)</span>
560
-
561
- <span class="method-click-advice">click to toggle source</span>
562
-
563
- </div>
564
-
565
-
566
- <div class="method-description">
567
-
568
-
569
-
570
-
571
-
572
-
573
- <div class="method-source-code" id="created_at-3D-source">
574
- <pre><span class="ruby-comment"># File lib/rubyXL/convenience_methods.rb, line 91</span>
575
- <span class="ruby-keyword">def</span> <span class="ruby-identifier">created_at=</span>(<span class="ruby-identifier">v</span>)
576
- <span class="ruby-identifier">root</span>.<span class="ruby-identifier">core_properties</span>.<span class="ruby-identifier">created_at</span> = <span class="ruby-identifier">v</span>
577
- <span class="ruby-keyword">end</span></pre>
578
- </div>
579
-
580
- </div>
92
+ <h1 id="module-RubyXL::WorkbookConvenienceMethods" class="module">
93
+ module RubyXL::WorkbookConvenienceMethods
94
+ </h1>
581
95
 
582
-
96
+ <section class="description">
97
+
98
+ </section>
583
99
 
584
-
585
- </div>
100
+ <section id="5Buntitled-5D" class="documentation-section">
586
101
 
587
-
588
- <div id="method-i-creator" class="method-detail ">
589
-
590
- <div class="method-heading">
591
- <span class="method-name">creator</span><span
592
- class="method-args">()</span>
593
-
594
- <span class="method-click-advice">click to toggle source</span>
595
-
596
- </div>
597
-
598
102
 
599
- <div class="method-description">
600
-
601
-
602
-
603
-
604
103
 
605
-
606
- <div class="method-source-code" id="creator-source">
607
- <pre><span class="ruby-comment"># File lib/rubyXL/convenience_methods.rb, line 71</span>
608
- <span class="ruby-keyword">def</span> <span class="ruby-identifier">creator</span>
609
- <span class="ruby-identifier">root</span>.<span class="ruby-identifier">core_properties</span>.<span class="ruby-identifier">creator</span>
610
- <span class="ruby-keyword">end</span></pre>
611
- </div>
612
-
613
- </div>
614
104
 
615
-
616
105
 
617
-
618
- </div>
106
+ <section id="public-instance-5Buntitled-5D-method-details" class="method-section">
107
+ <header>
108
+ <h3>Public Instance Methods</h3>
109
+ </header>
619
110
 
620
-
621
- <div id="method-i-creator-3D" class="method-detail ">
622
-
111
+ <div id="method-i-borders" class="method-detail ">
623
112
  <div class="method-heading">
624
- <span class="method-name">creator=</span><span
625
- class="method-args">(v)</span>
626
-
113
+ <span class="method-name">borders</span><span
114
+ class="method-args">()</span>
627
115
  <span class="method-click-advice">click to toggle source</span>
628
-
629
116
  </div>
630
-
631
117
 
632
118
  <div class="method-description">
633
119
 
634
-
635
-
636
-
637
120
 
638
-
639
- <div class="method-source-code" id="creator-3D-source">
640
- <pre><span class="ruby-comment"># File lib/rubyXL/convenience_methods.rb, line 75</span>
641
- <span class="ruby-keyword">def</span> <span class="ruby-identifier">creator=</span>(<span class="ruby-identifier">v</span>)
642
- <span class="ruby-identifier">root</span>.<span class="ruby-identifier">core_properties</span>.<span class="ruby-identifier">creator</span> = <span class="ruby-identifier">v</span>
121
+ <div class="method-source-code" id="borders-source">
122
+ <pre><span class="ruby-comment"># File lib/rubyXL/convenience_methods/workbook.rb, line 21</span>
123
+ <span class="ruby-keyword">def</span> <span class="ruby-identifier ruby-title">borders</span> <span class="ruby-comment"># Stylesheet should be pre-filled with defaults on initialize()</span>
124
+ <span class="ruby-identifier">stylesheet</span>.<span class="ruby-identifier">borders</span>
643
125
  <span class="ruby-keyword">end</span></pre>
644
126
  </div>
645
-
646
127
  </div>
647
128
 
648
-
649
129
 
650
-
651
130
  </div>
652
131
 
653
-
654
- <div id="method-i-date1904" class="method-detail ">
655
-
132
+ <div id="method-i-cell_xfs" class="method-detail ">
656
133
  <div class="method-heading">
657
- <span class="method-name">date1904</span><span
134
+ <span class="method-name">cell_xfs</span><span
658
135
  class="method-args">()</span>
659
-
660
136
  <span class="method-click-advice">click to toggle source</span>
661
-
662
137
  </div>
663
-
664
138
 
665
139
  <div class="method-description">
666
140
 
667
-
668
-
669
-
670
141
 
671
-
672
- <div class="method-source-code" id="date1904-source">
673
- <pre><span class="ruby-comment"># File lib/rubyXL/convenience_methods.rb, line 35</span>
674
- <span class="ruby-keyword">def</span> <span class="ruby-identifier">date1904</span>
675
- <span class="ruby-identifier">workbook_properties</span> <span class="ruby-operator">&amp;&amp;</span> <span class="ruby-identifier">workbook_properties</span>.<span class="ruby-identifier">date1904</span>
142
+ <div class="method-source-code" id="cell_xfs-source">
143
+ <pre><span class="ruby-comment"># File lib/rubyXL/convenience_methods/workbook.rb, line 9</span>
144
+ <span class="ruby-keyword">def</span> <span class="ruby-identifier ruby-title">cell_xfs</span> <span class="ruby-comment"># Stylesheet should be pre-filled with defaults on initialize()</span>
145
+ <span class="ruby-identifier">stylesheet</span>.<span class="ruby-identifier">cell_xfs</span>
676
146
  <span class="ruby-keyword">end</span></pre>
677
147
  </div>
678
-
679
148
  </div>
680
149
 
681
-
682
150
 
683
-
684
151
  </div>
685
152
 
686
-
687
- <div id="method-i-date1904-3D" class="method-detail ">
688
-
153
+ <div id="method-i-define_new_name" class="method-detail ">
689
154
  <div class="method-heading">
690
- <span class="method-name">date1904=</span><span
691
- class="method-args">(v)</span>
692
-
155
+ <span class="method-name">define_new_name</span><span
156
+ class="method-args">(name, reference)</span>
693
157
  <span class="method-click-advice">click to toggle source</span>
694
-
695
158
  </div>
696
-
697
159
 
698
160
  <div class="method-description">
699
161
 
700
-
701
-
702
-
703
162
 
704
-
705
- <div class="method-source-code" id="date1904-3D-source">
706
- <pre><span class="ruby-comment"># File lib/rubyXL/convenience_methods.rb, line 39</span>
707
- <span class="ruby-keyword">def</span> <span class="ruby-identifier">date1904=</span>(<span class="ruby-identifier">v</span>)
708
- <span class="ruby-keyword">self</span>.<span class="ruby-identifier">workbook_properties</span> <span class="ruby-operator">||=</span> <span class="ruby-constant">RubyXL</span><span class="ruby-operator">::</span><span class="ruby-constant">WorkbookProperties</span>.<span class="ruby-identifier">new</span>
709
- <span class="ruby-identifier">workbook_properties</span>.<span class="ruby-identifier">date1904</span> = <span class="ruby-identifier">v</span>
163
+ <div class="method-source-code" id="define_new_name-source">
164
+ <pre><span class="ruby-comment"># File lib/rubyXL/convenience_methods/workbook.rb, line 124</span>
165
+ <span class="ruby-keyword">def</span> <span class="ruby-identifier ruby-title">define_new_name</span>(<span class="ruby-identifier">name</span>, <span class="ruby-identifier">reference</span>)
166
+ <span class="ruby-keyword">self</span>.<span class="ruby-identifier">defined_names</span> <span class="ruby-operator">||=</span> <span class="ruby-constant">RubyXL</span><span class="ruby-operator">::</span><span class="ruby-constant">DefinedNames</span>.<span class="ruby-identifier">new</span>
167
+ <span class="ruby-keyword">self</span>.<span class="ruby-identifier">defined_names</span> <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-constant">RubyXL</span><span class="ruby-operator">::</span><span class="ruby-constant">DefinedName</span>.<span class="ruby-identifier">new</span>({<span class="ruby-value">:name</span> <span class="ruby-operator">=&gt;</span> <span class="ruby-identifier">name</span>, <span class="ruby-value">:reference</span> <span class="ruby-operator">=&gt;</span> <span class="ruby-identifier">reference</span>})
710
168
  <span class="ruby-keyword">end</span></pre>
711
169
  </div>
712
-
713
170
  </div>
714
171
 
715
-
716
172
 
717
-
718
173
  </div>
719
174
 
720
-
721
175
  <div id="method-i-each" class="method-detail ">
722
-
723
176
  <div class="method-heading">
724
177
  <span class="method-name">each</span><span
725
178
  class="method-args">() { |i| ... }</span>
726
-
727
179
  <span class="method-click-advice">click to toggle source</span>
728
-
729
180
  </div>
730
-
731
181
 
732
182
  <div class="method-description">
733
183
 
734
-
735
-
736
-
737
184
 
738
-
739
185
  <div class="method-source-code" id="each-source">
740
- <pre><span class="ruby-comment"># File lib/rubyXL/convenience_methods.rb, line 31</span>
741
- <span class="ruby-keyword">def</span> <span class="ruby-identifier">each</span>
186
+ <pre><span class="ruby-comment"># File lib/rubyXL/convenience_methods/workbook.rb, line 5</span>
187
+ <span class="ruby-keyword">def</span> <span class="ruby-identifier ruby-title">each</span>
742
188
  <span class="ruby-identifier">worksheets</span>.<span class="ruby-identifier">each</span>{ <span class="ruby-operator">|</span><span class="ruby-identifier">i</span><span class="ruby-operator">|</span> <span class="ruby-keyword">yield</span> <span class="ruby-identifier">i</span> }
743
189
  <span class="ruby-keyword">end</span></pre>
744
190
  </div>
745
-
746
191
  </div>
747
192
 
748
-
749
193
 
750
-
751
194
  </div>
752
195
 
753
-
754
196
  <div id="method-i-fills" class="method-detail ">
755
-
756
197
  <div class="method-heading">
757
198
  <span class="method-name">fills</span><span
758
199
  class="method-args">()</span>
759
-
760
200
  <span class="method-click-advice">click to toggle source</span>
761
-
762
201
  </div>
763
-
764
202
 
765
203
  <div class="method-description">
766
204
 
767
-
768
-
769
-
770
205
 
771
-
772
206
  <div class="method-source-code" id="fills-source">
773
- <pre><span class="ruby-comment"># File lib/rubyXL/convenience_methods.rb, line 111</span>
774
- <span class="ruby-keyword">def</span> <span class="ruby-identifier">fills</span> <span class="ruby-comment"># Stylesheet should be pre-filled with defaults on initialize()</span>
207
+ <pre><span class="ruby-comment"># File lib/rubyXL/convenience_methods/workbook.rb, line 17</span>
208
+ <span class="ruby-keyword">def</span> <span class="ruby-identifier ruby-title">fills</span> <span class="ruby-comment"># Stylesheet should be pre-filled with defaults on initialize()</span>
775
209
  <span class="ruby-identifier">stylesheet</span>.<span class="ruby-identifier">fills</span>
776
210
  <span class="ruby-keyword">end</span></pre>
777
211
  </div>
778
-
779
212
  </div>
780
213
 
781
-
782
214
 
783
-
784
215
  </div>
785
216
 
786
-
787
217
  <div id="method-i-fonts" class="method-detail ">
788
-
789
218
  <div class="method-heading">
790
219
  <span class="method-name">fonts</span><span
791
220
  class="method-args">()</span>
792
-
793
221
  <span class="method-click-advice">click to toggle source</span>
794
-
795
222
  </div>
796
-
797
223
 
798
224
  <div class="method-description">
799
225
 
800
-
801
-
802
-
803
226
 
804
-
805
227
  <div class="method-source-code" id="fonts-source">
806
- <pre><span class="ruby-comment"># File lib/rubyXL/convenience_methods.rb, line 107</span>
807
- <span class="ruby-keyword">def</span> <span class="ruby-identifier">fonts</span> <span class="ruby-comment"># Stylesheet should be pre-filled with defaults on initialize()</span>
228
+ <pre><span class="ruby-comment"># File lib/rubyXL/convenience_methods/workbook.rb, line 13</span>
229
+ <span class="ruby-keyword">def</span> <span class="ruby-identifier ruby-title">fonts</span> <span class="ruby-comment"># Stylesheet should be pre-filled with defaults on initialize()</span>
808
230
  <span class="ruby-identifier">stylesheet</span>.<span class="ruby-identifier">fonts</span>
809
231
  <span class="ruby-keyword">end</span></pre>
810
232
  </div>
811
-
812
233
  </div>
813
234
 
814
-
815
235
 
816
-
817
236
  </div>
818
237
 
819
-
820
- <div id="method-i-get_fill_color" class="method-detail ">
821
-
238
+ <div id="method-i-get_defined_name" class="method-detail ">
822
239
  <div class="method-heading">
823
- <span class="method-name">get_fill_color</span><span
824
- class="method-args">(xf)</span>
825
-
240
+ <span class="method-name">get_defined_name</span><span
241
+ class="method-args">(name)</span>
826
242
  <span class="method-click-advice">click to toggle source</span>
827
-
828
243
  </div>
829
-
830
244
 
831
245
  <div class="method-description">
832
246
 
833
-
834
-
835
-
836
247
 
837
-
838
- <div class="method-source-code" id="get_fill_color-source">
839
- <pre><span class="ruby-comment"># File lib/rubyXL/convenience_methods.rb, line 119</span>
840
- <span class="ruby-keyword">def</span> <span class="ruby-identifier">get_fill_color</span>(<span class="ruby-identifier">xf</span>)
841
- <span class="ruby-identifier">fill</span> = <span class="ruby-identifier">fills</span>[<span class="ruby-identifier">xf</span>.<span class="ruby-identifier">fill_id</span>]
842
- <span class="ruby-identifier">pattern</span> = <span class="ruby-identifier">fill</span> <span class="ruby-operator">&amp;&amp;</span> <span class="ruby-identifier">fill</span>.<span class="ruby-identifier">pattern_fill</span>
843
- <span class="ruby-identifier">color</span> = <span class="ruby-identifier">pattern</span> <span class="ruby-operator">&amp;&amp;</span> <span class="ruby-identifier">pattern</span>.<span class="ruby-identifier">fg_color</span>
844
- <span class="ruby-identifier">color</span> <span class="ruby-operator">&amp;&amp;</span> <span class="ruby-identifier">color</span>.<span class="ruby-identifier">rgb</span> <span class="ruby-operator">||</span> <span class="ruby-string">&#39;ffffff&#39;</span>
248
+ <div class="method-source-code" id="get_defined_name-source">
249
+ <pre><span class="ruby-comment"># File lib/rubyXL/convenience_methods/workbook.rb, line 129</span>
250
+ <span class="ruby-keyword">def</span> <span class="ruby-identifier ruby-title">get_defined_name</span>(<span class="ruby-identifier">name</span>)
251
+ <span class="ruby-keyword">self</span>.<span class="ruby-identifier">defined_names</span> <span class="ruby-operator">&amp;&amp;</span> <span class="ruby-keyword">self</span>.<span class="ruby-identifier">defined_names</span>.<span class="ruby-identifier">find</span> { <span class="ruby-operator">|</span><span class="ruby-identifier">n</span><span class="ruby-operator">|</span> <span class="ruby-identifier">n</span>.<span class="ruby-identifier">name</span> <span class="ruby-operator">==</span> <span class="ruby-identifier">name</span> }
845
252
  <span class="ruby-keyword">end</span></pre>
846
253
  </div>
847
-
848
254
  </div>
849
255
 
850
-
851
256
 
852
-
853
257
  </div>
854
258
 
855
-
856
- <div id="method-i-modified_at" class="method-detail ">
857
-
259
+ <div id="method-i-get_fill_color" class="method-detail ">
858
260
  <div class="method-heading">
859
- <span class="method-name">modified_at</span><span
860
- class="method-args">()</span>
861
-
261
+ <span class="method-name">get_fill_color</span><span
262
+ class="method-args">(xf)</span>
862
263
  <span class="method-click-advice">click to toggle source</span>
863
-
864
264
  </div>
865
-
866
265
 
867
266
  <div class="method-description">
868
267
 
869
-
870
-
871
-
872
268
 
873
-
874
- <div class="method-source-code" id="modified_at-source">
875
- <pre><span class="ruby-comment"># File lib/rubyXL/convenience_methods.rb, line 95</span>
876
- <span class="ruby-keyword">def</span> <span class="ruby-identifier">modified_at</span>
877
- <span class="ruby-identifier">root</span>.<span class="ruby-identifier">core_properties</span>.<span class="ruby-identifier">modified_at</span>
269
+ <div class="method-source-code" id="get_fill_color-source">
270
+ <pre><span class="ruby-comment"># File lib/rubyXL/convenience_methods/workbook.rb, line 25</span>
271
+ <span class="ruby-keyword">def</span> <span class="ruby-identifier ruby-title">get_fill_color</span>(<span class="ruby-identifier">xf</span>)
272
+ <span class="ruby-identifier">fill</span> = <span class="ruby-identifier">fills</span>[<span class="ruby-identifier">xf</span>.<span class="ruby-identifier">fill_id</span>]
273
+ <span class="ruby-identifier">pattern</span> = <span class="ruby-identifier">fill</span> <span class="ruby-operator">&amp;&amp;</span> <span class="ruby-identifier">fill</span>.<span class="ruby-identifier">pattern_fill</span>
274
+ <span class="ruby-identifier">color</span> = <span class="ruby-identifier">pattern</span> <span class="ruby-operator">&amp;&amp;</span> <span class="ruby-identifier">pattern</span>.<span class="ruby-identifier">fg_color</span>
275
+ <span class="ruby-identifier">color</span> = <span class="ruby-identifier">color</span> <span class="ruby-operator">&amp;&amp;</span> <span class="ruby-identifier">color</span>.<span class="ruby-identifier">get_rgb</span>(<span class="ruby-keyword">self</span>)
276
+ <span class="ruby-identifier">color</span> <span class="ruby-operator">&amp;&amp;</span> <span class="ruby-identifier">color</span>.<span class="ruby-identifier">to_s</span> <span class="ruby-operator">||</span> <span class="ruby-string">&#39;ffffff&#39;</span>
878
277
  <span class="ruby-keyword">end</span></pre>
879
278
  </div>
880
-
881
279
  </div>
882
280
 
883
-
884
281
 
885
-
886
282
  </div>
887
283
 
888
-
889
- <div id="method-i-modified_at-3D" class="method-detail ">
890
-
284
+ <div id="method-i-modify_alignment" class="method-detail ">
891
285
  <div class="method-heading">
892
- <span class="method-name">modified_at=</span><span
893
- class="method-args">(v)</span>
894
-
286
+ <span class="method-name">modify_alignment</span><span
287
+ class="method-args">(style_index) { |alignment| ... }</span>
895
288
  <span class="method-click-advice">click to toggle source</span>
896
-
897
289
  </div>
898
-
899
290
 
900
291
  <div class="method-description">
901
292
 
902
-
903
-
904
-
905
-
906
-
907
- <div class="method-source-code" id="modified_at-3D-source">
908
- <pre><span class="ruby-comment"># File lib/rubyXL/convenience_methods.rb, line 99</span>
909
- <span class="ruby-keyword">def</span> <span class="ruby-identifier">modified_at=</span>(<span class="ruby-identifier">v</span>)
910
- <span class="ruby-identifier">root</span>.<span class="ruby-identifier">core_properties</span>.<span class="ruby-identifier">modified_at</span> = <span class="ruby-identifier">v</span>
911
- <span class="ruby-keyword">end</span></pre>
912
- </div>
913
-
914
- </div>
915
-
916
-
917
-
918
-
919
- </div>
920
293
 
921
-
922
- <div id="method-i-modifier" class="method-detail ">
923
-
924
- <div class="method-heading">
925
- <span class="method-name">modifier</span><span
926
- class="method-args">()</span>
927
-
928
- <span class="method-click-advice">click to toggle source</span>
929
-
930
- </div>
931
-
294
+ <div class="method-source-code" id="modify_alignment-source">
295
+ <pre><span class="ruby-comment"># File lib/rubyXL/convenience_methods/workbook.rb, line 58</span>
296
+ <span class="ruby-keyword">def</span> <span class="ruby-identifier ruby-title">modify_alignment</span>(<span class="ruby-identifier">style_index</span>, <span class="ruby-operator">&amp;</span><span class="ruby-identifier">block</span>)
297
+ <span class="ruby-identifier">old_xf</span> = <span class="ruby-identifier">cell_xfs</span>[<span class="ruby-identifier">style_index</span> <span class="ruby-operator">||</span> <span class="ruby-value">0</span>]
298
+ <span class="ruby-identifier">new_xf</span> = <span class="ruby-identifier">old_xf</span>.<span class="ruby-identifier">dup</span>
299
+ <span class="ruby-keyword">if</span> <span class="ruby-identifier">old_xf</span>.<span class="ruby-identifier">alignment</span> <span class="ruby-keyword">then</span>
300
+ <span class="ruby-identifier">new_xf</span>.<span class="ruby-identifier">alignment</span> = <span class="ruby-identifier">old_xf</span>.<span class="ruby-identifier">alignment</span>.<span class="ruby-identifier">dup</span>
301
+ <span class="ruby-keyword">else</span>
302
+ <span class="ruby-identifier">new_xf</span>.<span class="ruby-identifier">alignment</span> = <span class="ruby-constant">RubyXL</span><span class="ruby-operator">::</span><span class="ruby-constant">Alignment</span>.<span class="ruby-identifier">new</span>
303
+ <span class="ruby-keyword">end</span>
932
304
 
933
- <div class="method-description">
934
-
935
-
936
-
937
-
305
+ <span class="ruby-keyword">yield</span>(<span class="ruby-identifier">new_xf</span>.<span class="ruby-identifier">alignment</span>)
306
+ <span class="ruby-identifier">new_xf</span>.<span class="ruby-identifier">apply_alignment</span> = <span class="ruby-keyword">true</span>
938
307
 
939
-
940
- <div class="method-source-code" id="modifier-source">
941
- <pre><span class="ruby-comment"># File lib/rubyXL/convenience_methods.rb, line 79</span>
942
- <span class="ruby-keyword">def</span> <span class="ruby-identifier">modifier</span>
943
- <span class="ruby-identifier">root</span>.<span class="ruby-identifier">core_properties</span>.<span class="ruby-identifier">modifier</span>
308
+ <span class="ruby-identifier">register_new_xf</span>(<span class="ruby-identifier">new_xf</span>)
944
309
  <span class="ruby-keyword">end</span></pre>
945
310
  </div>
946
-
947
311
  </div>
948
312
 
949
-
950
313
 
951
-
952
314
  </div>
953
315
 
954
-
955
- <div id="method-i-modifier-3D" class="method-detail ">
956
-
316
+ <div id="method-i-modify_border" class="method-detail ">
957
317
  <div class="method-heading">
958
- <span class="method-name">modifier=</span><span
959
- class="method-args">(v)</span>
960
-
318
+ <span class="method-name">modify_border</span><span
319
+ class="method-args">(style_index, direction, weight)</span>
961
320
  <span class="method-click-advice">click to toggle source</span>
962
-
963
321
  </div>
964
-
965
322
 
966
323
  <div class="method-description">
967
324
 
968
-
969
-
970
-
971
-
972
-
973
- <div class="method-source-code" id="modifier-3D-source">
974
- <pre><span class="ruby-comment"># File lib/rubyXL/convenience_methods.rb, line 83</span>
975
- <span class="ruby-keyword">def</span> <span class="ruby-identifier">modifier=</span>(<span class="ruby-identifier">v</span>)
976
- <span class="ruby-identifier">root</span>.<span class="ruby-identifier">core_properties</span>.<span class="ruby-identifier">modifier</span> = <span class="ruby-identifier">v</span>
977
- <span class="ruby-keyword">end</span></pre>
978
- </div>
979
-
980
- </div>
981
325
 
982
-
983
-
984
-
985
- </div>
326
+ <div class="method-source-code" id="modify_border-source">
327
+ <pre><span class="ruby-comment"># File lib/rubyXL/convenience_methods/workbook.rb, line 81</span>
328
+ <span class="ruby-keyword">def</span> <span class="ruby-identifier ruby-title">modify_border</span>(<span class="ruby-identifier">style_index</span>, <span class="ruby-identifier">direction</span>, <span class="ruby-identifier">weight</span>)
329
+ <span class="ruby-identifier">xf</span> = <span class="ruby-identifier">cell_xfs</span>[<span class="ruby-identifier">style_index</span> <span class="ruby-operator">||</span> <span class="ruby-value">0</span>].<span class="ruby-identifier">dup</span>
330
+ <span class="ruby-identifier">new_border</span> = <span class="ruby-identifier">borders</span>[<span class="ruby-identifier">xf</span>.<span class="ruby-identifier">border_id</span> <span class="ruby-operator">||</span> <span class="ruby-value">0</span>].<span class="ruby-identifier">dup</span>
986
331
 
987
-
988
- <div id="method-i-modify_alignment" class="method-detail ">
989
-
990
- <div class="method-heading">
991
- <span class="method-name">modify_alignment</span><span
992
- class="method-args">(style_index) { |alignment| ... }</span>
993
-
994
- <span class="method-click-advice">click to toggle source</span>
995
-
996
- </div>
997
-
332
+ <span class="ruby-identifier">edge</span> = <span class="ruby-identifier">new_border</span>.<span class="ruby-identifier">send</span>(<span class="ruby-identifier">direction</span>)
333
+ <span class="ruby-identifier">new_border</span>.<span class="ruby-identifier">send</span>(<span class="ruby-node">&quot;#{direction}=&quot;</span>, <span class="ruby-identifier">edge</span>.<span class="ruby-identifier">dup</span>) <span class="ruby-keyword">if</span> <span class="ruby-identifier">edge</span>
998
334
 
999
- <div class="method-description">
1000
-
1001
-
1002
-
1003
-
335
+ <span class="ruby-identifier">new_border</span>.<span class="ruby-identifier">set_edge_style</span>(<span class="ruby-identifier">direction</span>, <span class="ruby-identifier">weight</span>)
1004
336
 
1005
-
1006
- <div class="method-source-code" id="modify_alignment-source">
1007
- <pre><span class="ruby-comment"># File lib/rubyXL/convenience_methods.rb, line 151</span>
1008
- <span class="ruby-keyword">def</span> <span class="ruby-identifier">modify_alignment</span>(<span class="ruby-identifier">style_index</span>, <span class="ruby-operator">&amp;</span><span class="ruby-identifier">block</span>)
1009
- <span class="ruby-identifier">xf</span> = <span class="ruby-identifier">cell_xfs</span>[<span class="ruby-identifier">style_index</span> <span class="ruby-operator">||</span> <span class="ruby-value">0</span>].<span class="ruby-identifier">dup</span>
1010
- <span class="ruby-identifier">xf</span>.<span class="ruby-identifier">alignment</span> <span class="ruby-operator">||=</span> <span class="ruby-constant">RubyXL</span><span class="ruby-operator">::</span><span class="ruby-constant">Alignment</span>.<span class="ruby-identifier">new</span>
1011
- <span class="ruby-keyword">yield</span>(<span class="ruby-identifier">xf</span>.<span class="ruby-identifier">alignment</span>)
1012
- <span class="ruby-identifier">xf</span>.<span class="ruby-identifier">apply_alignment</span> = <span class="ruby-keyword">true</span>
337
+ <span class="ruby-identifier">xf</span>.<span class="ruby-identifier">border_id</span> = <span class="ruby-identifier">borders</span>.<span class="ruby-identifier">find_index</span> { <span class="ruby-operator">|</span><span class="ruby-identifier">x</span><span class="ruby-operator">|</span> <span class="ruby-identifier">x</span> <span class="ruby-operator">==</span> <span class="ruby-identifier">new_border</span> } <span class="ruby-comment"># Reuse existing border, if it exists</span>
338
+ <span class="ruby-identifier">xf</span>.<span class="ruby-identifier">border_id</span> <span class="ruby-operator">||=</span> <span class="ruby-identifier">borders</span>.<span class="ruby-identifier">size</span> <span class="ruby-comment"># If this border has never existed before, add it to collection.</span>
339
+ <span class="ruby-identifier">borders</span>[<span class="ruby-identifier">xf</span>.<span class="ruby-identifier">border_id</span>] = <span class="ruby-identifier">new_border</span>
340
+ <span class="ruby-identifier">xf</span>.<span class="ruby-identifier">apply_border</span> = <span class="ruby-keyword">true</span>
1013
341
 
1014
342
  <span class="ruby-identifier">register_new_xf</span>(<span class="ruby-identifier">xf</span>)
1015
343
  <span class="ruby-keyword">end</span></pre>
1016
344
  </div>
1017
-
1018
345
  </div>
1019
346
 
1020
-
1021
347
 
1022
-
1023
348
  </div>
1024
349
 
1025
-
1026
- <div id="method-i-modify_border" class="method-detail ">
1027
-
350
+ <div id="method-i-modify_border_color" class="method-detail ">
1028
351
  <div class="method-heading">
1029
- <span class="method-name">modify_border</span><span
1030
- class="method-args">(style_index, direction, weight)</span>
1031
-
352
+ <span class="method-name">modify_border_color</span><span
353
+ class="method-args">(style_index, direction, color)</span>
1032
354
  <span class="method-click-advice">click to toggle source</span>
1033
-
1034
355
  </div>
1035
-
1036
356
 
1037
357
  <div class="method-description">
1038
358
 
1039
-
1040
-
1041
-
1042
359
 
1043
-
1044
- <div class="method-source-code" id="modify_border-source">
1045
- <pre><span class="ruby-comment"># File lib/rubyXL/convenience_methods.rb, line 168</span>
1046
- <span class="ruby-keyword">def</span> <span class="ruby-identifier">modify_border</span>(<span class="ruby-identifier">style_index</span>, <span class="ruby-identifier">direction</span>, <span class="ruby-identifier">weight</span>)
360
+ <div class="method-source-code" id="modify_border_color-source">
361
+ <pre><span class="ruby-comment"># File lib/rubyXL/convenience_methods/workbook.rb, line 98</span>
362
+ <span class="ruby-keyword">def</span> <span class="ruby-identifier ruby-title">modify_border_color</span>(<span class="ruby-identifier">style_index</span>, <span class="ruby-identifier">direction</span>, <span class="ruby-identifier">color</span>)
1047
363
  <span class="ruby-identifier">xf</span> = <span class="ruby-identifier">cell_xfs</span>[<span class="ruby-identifier">style_index</span> <span class="ruby-operator">||</span> <span class="ruby-value">0</span>].<span class="ruby-identifier">dup</span>
1048
364
  <span class="ruby-identifier">new_border</span> = <span class="ruby-identifier">borders</span>[<span class="ruby-identifier">xf</span>.<span class="ruby-identifier">border_id</span> <span class="ruby-operator">||</span> <span class="ruby-value">0</span>].<span class="ruby-identifier">dup</span>
1049
- <span class="ruby-identifier">new_border</span>.<span class="ruby-identifier">set_edge_style</span>(<span class="ruby-identifier">direction</span>, <span class="ruby-identifier">weight</span>)
365
+ <span class="ruby-identifier">new_border</span>.<span class="ruby-identifier">set_edge_color</span>(<span class="ruby-identifier">direction</span>, <span class="ruby-identifier">color</span>)
1050
366
 
1051
367
  <span class="ruby-identifier">xf</span>.<span class="ruby-identifier">border_id</span> = <span class="ruby-identifier">borders</span>.<span class="ruby-identifier">find_index</span> { <span class="ruby-operator">|</span><span class="ruby-identifier">x</span><span class="ruby-operator">|</span> <span class="ruby-identifier">x</span> <span class="ruby-operator">==</span> <span class="ruby-identifier">new_border</span> } <span class="ruby-comment"># Reuse existing border, if it exists</span>
1052
368
  <span class="ruby-identifier">xf</span>.<span class="ruby-identifier">border_id</span> <span class="ruby-operator">||=</span> <span class="ruby-identifier">borders</span>.<span class="ruby-identifier">size</span> <span class="ruby-comment"># If this border has never existed before, add it to collection.</span>
@@ -1056,73 +372,77 @@
1056
372
  <span class="ruby-identifier">register_new_xf</span>(<span class="ruby-identifier">xf</span>)
1057
373
  <span class="ruby-keyword">end</span></pre>
1058
374
  </div>
1059
-
1060
375
  </div>
1061
376
 
1062
-
1063
377
 
1064
-
1065
378
  </div>
1066
379
 
1067
-
1068
380
  <div id="method-i-modify_fill" class="method-detail ">
1069
-
1070
381
  <div class="method-heading">
1071
382
  <span class="method-name">modify_fill</span><span
1072
383
  class="method-args">(style_index, rgb)</span>
1073
-
1074
384
  <span class="method-click-advice">click to toggle source</span>
1075
-
1076
385
  </div>
1077
-
1078
386
 
1079
387
  <div class="method-description">
1080
388
 
1081
-
1082
-
1083
-
1084
389
 
1085
-
1086
390
  <div class="method-source-code" id="modify_fill-source">
1087
- <pre><span class="ruby-comment"># File lib/rubyXL/convenience_methods.rb, line 160</span>
1088
- <span class="ruby-keyword">def</span> <span class="ruby-identifier">modify_fill</span>(<span class="ruby-identifier">style_index</span>, <span class="ruby-identifier">rgb</span>)
391
+ <pre><span class="ruby-comment"># File lib/rubyXL/convenience_methods/workbook.rb, line 73</span>
392
+ <span class="ruby-keyword">def</span> <span class="ruby-identifier ruby-title">modify_fill</span>(<span class="ruby-identifier">style_index</span>, <span class="ruby-identifier">rgb</span>)
1089
393
  <span class="ruby-identifier">xf</span> = <span class="ruby-identifier">cell_xfs</span>[<span class="ruby-identifier">style_index</span> <span class="ruby-operator">||</span> <span class="ruby-value">0</span>].<span class="ruby-identifier">dup</span>
1090
- <span class="ruby-identifier">new_fill</span> = <span class="ruby-constant">RubyXL</span><span class="ruby-operator">::</span><span class="ruby-constant">Fill</span>.<span class="ruby-identifier">new</span>(<span class="ruby-value">:pattern_fill</span> =<span class="ruby-operator">&gt;</span>
1091
- <span class="ruby-constant">RubyXL</span><span class="ruby-operator">::</span><span class="ruby-constant">PatternFill</span>.<span class="ruby-identifier">new</span>(<span class="ruby-value">:pattern_type</span> =<span class="ruby-operator">&gt;</span> <span class="ruby-string">&#39;solid&#39;</span>,
1092
- <span class="ruby-value">:fg_color</span> =<span class="ruby-operator">&gt;</span> <span class="ruby-constant">RubyXL</span><span class="ruby-operator">::</span><span class="ruby-constant">Color</span>.<span class="ruby-identifier">new</span>(<span class="ruby-value">:rgb</span> =<span class="ruby-operator">&gt;</span> <span class="ruby-identifier">rgb</span>)))
394
+ <span class="ruby-identifier">new_fill</span> = <span class="ruby-constant">RubyXL</span><span class="ruby-operator">::</span><span class="ruby-constant">Fill</span>.<span class="ruby-identifier">new</span>(<span class="ruby-value">:pattern_fill</span> <span class="ruby-operator">=&gt;</span>
395
+ <span class="ruby-constant">RubyXL</span><span class="ruby-operator">::</span><span class="ruby-constant">PatternFill</span>.<span class="ruby-identifier">new</span>(<span class="ruby-value">:pattern_type</span> <span class="ruby-operator">=&gt;</span> <span class="ruby-string">&#39;solid&#39;</span>,
396
+ <span class="ruby-value">:fg_color</span> <span class="ruby-operator">=&gt;</span> <span class="ruby-constant">RubyXL</span><span class="ruby-operator">::</span><span class="ruby-constant">Color</span>.<span class="ruby-identifier">new</span>(<span class="ruby-value">:rgb</span> <span class="ruby-operator">=&gt;</span> <span class="ruby-identifier">rgb</span>)))
1093
397
  <span class="ruby-identifier">register_new_xf</span>(<span class="ruby-identifier">register_new_fill</span>(<span class="ruby-identifier">new_fill</span>, <span class="ruby-identifier">xf</span>))
1094
398
  <span class="ruby-keyword">end</span></pre>
1095
399
  </div>
1096
-
1097
400
  </div>
1098
401
 
1099
-
1100
402
 
1101
-
1102
403
  </div>
1103
404
 
1104
-
405
+ <div id="method-i-password_hash" class="method-detail ">
406
+ <div class="method-heading">
407
+ <span class="method-name">password_hash</span><span
408
+ class="method-args">(pwd)</span>
409
+ <span class="method-click-advice">click to toggle source</span>
410
+ </div>
411
+
412
+ <div class="method-description">
413
+ <p>Calculate password hash from string for use in &#39;password&#39; fields. <a href="https://www.openoffice.org/sc/excelfileformat.pdf">www.openoffice.org/sc/excelfileformat.pdf</a></p>
414
+
415
+ <div class="method-source-code" id="password_hash-source">
416
+ <pre><span class="ruby-comment"># File lib/rubyXL/convenience_methods/workbook.rb, line 113</span>
417
+ <span class="ruby-keyword">def</span> <span class="ruby-identifier ruby-title">password_hash</span>(<span class="ruby-identifier">pwd</span>)
418
+ <span class="ruby-identifier">hsh</span> = <span class="ruby-value">0</span>
419
+ <span class="ruby-identifier">pwd</span>.<span class="ruby-identifier">reverse</span>.<span class="ruby-identifier">each_char</span> { <span class="ruby-operator">|</span><span class="ruby-identifier">c</span><span class="ruby-operator">|</span>
420
+ <span class="ruby-identifier">hsh</span> = <span class="ruby-identifier">hsh</span> <span class="ruby-operator">^</span> <span class="ruby-identifier">c</span>.<span class="ruby-identifier">ord</span>
421
+ <span class="ruby-identifier">hsh</span> = <span class="ruby-identifier">hsh</span> <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-value">1</span>
422
+ <span class="ruby-identifier">hsh</span> <span class="ruby-operator">-=</span> <span class="ruby-value">0x7fff</span> <span class="ruby-keyword">if</span> <span class="ruby-identifier">hsh</span> <span class="ruby-operator">&gt;</span> <span class="ruby-value">0x7fff</span>
423
+ }
424
+
425
+ (<span class="ruby-identifier">hsh</span> <span class="ruby-operator">^</span> <span class="ruby-identifier">pwd</span>.<span class="ruby-identifier">length</span> <span class="ruby-operator">^</span> <span class="ruby-value">0xCE4B</span>).<span class="ruby-identifier">to_s</span>(<span class="ruby-value">16</span>)
426
+ <span class="ruby-keyword">end</span></pre>
427
+ </div>
428
+ </div>
429
+
430
+
431
+ </div>
432
+
1105
433
  <div id="method-i-register_new_fill" class="method-detail ">
1106
-
1107
434
  <div class="method-heading">
1108
435
  <span class="method-name">register_new_fill</span><span
1109
436
  class="method-args">(new_fill, old_xf)</span>
1110
-
1111
437
  <span class="method-click-advice">click to toggle source</span>
1112
-
1113
438
  </div>
1114
-
1115
439
 
1116
440
  <div class="method-description">
1117
441
 
1118
-
1119
-
1120
-
1121
442
 
1122
-
1123
443
  <div class="method-source-code" id="register_new_fill-source">
1124
- <pre><span class="ruby-comment"># File lib/rubyXL/convenience_methods.rb, line 126</span>
1125
- <span class="ruby-keyword">def</span> <span class="ruby-identifier">register_new_fill</span>(<span class="ruby-identifier">new_fill</span>, <span class="ruby-identifier">old_xf</span>)
444
+ <pre><span class="ruby-comment"># File lib/rubyXL/convenience_methods/workbook.rb, line 33</span>
445
+ <span class="ruby-keyword">def</span> <span class="ruby-identifier ruby-title">register_new_fill</span>(<span class="ruby-identifier">new_fill</span>, <span class="ruby-identifier">old_xf</span>)
1126
446
  <span class="ruby-identifier">new_xf</span> = <span class="ruby-identifier">old_xf</span>.<span class="ruby-identifier">dup</span>
1127
447
  <span class="ruby-identifier">new_xf</span>.<span class="ruby-identifier">apply_fill</span> = <span class="ruby-keyword">true</span>
1128
448
  <span class="ruby-identifier">new_xf</span>.<span class="ruby-identifier">fill_id</span> = <span class="ruby-identifier">fills</span>.<span class="ruby-identifier">find_index</span> { <span class="ruby-operator">|</span><span class="ruby-identifier">x</span><span class="ruby-operator">|</span> <span class="ruby-identifier">x</span> <span class="ruby-operator">==</span> <span class="ruby-identifier">new_fill</span> } <span class="ruby-comment"># Reuse existing fill, if it exists</span>
@@ -1131,36 +451,24 @@
1131
451
  <span class="ruby-identifier">new_xf</span>
1132
452
  <span class="ruby-keyword">end</span></pre>
1133
453
  </div>
1134
-
1135
454
  </div>
1136
455
 
1137
-
1138
456
 
1139
-
1140
457
  </div>
1141
458
 
1142
-
1143
459
  <div id="method-i-register_new_font" class="method-detail ">
1144
-
1145
460
  <div class="method-heading">
1146
461
  <span class="method-name">register_new_font</span><span
1147
462
  class="method-args">(new_font, old_xf)</span>
1148
-
1149
463
  <span class="method-click-advice">click to toggle source</span>
1150
-
1151
464
  </div>
1152
-
1153
465
 
1154
466
  <div class="method-description">
1155
467
 
1156
-
1157
-
1158
-
1159
468
 
1160
-
1161
469
  <div class="method-source-code" id="register_new_font-source">
1162
- <pre><span class="ruby-comment"># File lib/rubyXL/convenience_methods.rb, line 135</span>
1163
- <span class="ruby-keyword">def</span> <span class="ruby-identifier">register_new_font</span>(<span class="ruby-identifier">new_font</span>, <span class="ruby-identifier">old_xf</span>)
470
+ <pre><span class="ruby-comment"># File lib/rubyXL/convenience_methods/workbook.rb, line 42</span>
471
+ <span class="ruby-keyword">def</span> <span class="ruby-identifier ruby-title">register_new_font</span>(<span class="ruby-identifier">new_font</span>, <span class="ruby-identifier">old_xf</span>)
1164
472
  <span class="ruby-identifier">new_xf</span> = <span class="ruby-identifier">old_xf</span>.<span class="ruby-identifier">dup</span>
1165
473
  <span class="ruby-identifier">new_xf</span>.<span class="ruby-identifier">font_id</span> = <span class="ruby-identifier">fonts</span>.<span class="ruby-identifier">find_index</span> { <span class="ruby-operator">|</span><span class="ruby-identifier">x</span><span class="ruby-operator">|</span> <span class="ruby-identifier">x</span> <span class="ruby-operator">==</span> <span class="ruby-identifier">new_font</span> } <span class="ruby-comment"># Reuse existing font, if it exists</span>
1166
474
  <span class="ruby-identifier">new_xf</span>.<span class="ruby-identifier">font_id</span> <span class="ruby-operator">||=</span> <span class="ruby-identifier">fonts</span>.<span class="ruby-identifier">size</span> <span class="ruby-comment"># If this font has never existed before, add it to collection.</span>
@@ -1169,60 +477,44 @@
1169
477
  <span class="ruby-identifier">new_xf</span>
1170
478
  <span class="ruby-keyword">end</span></pre>
1171
479
  </div>
1172
-
1173
480
  </div>
1174
481
 
1175
-
1176
482
 
1177
-
1178
483
  </div>
1179
484
 
1180
-
1181
485
  <div id="method-i-register_new_xf" class="method-detail ">
1182
-
1183
486
  <div class="method-heading">
1184
487
  <span class="method-name">register_new_xf</span><span
1185
488
  class="method-args">(new_xf)</span>
1186
-
1187
489
  <span class="method-click-advice">click to toggle source</span>
1188
-
1189
490
  </div>
1190
-
1191
491
 
1192
492
  <div class="method-description">
1193
493
 
1194
-
1195
-
1196
-
1197
494
 
1198
-
1199
495
  <div class="method-source-code" id="register_new_xf-source">
1200
- <pre><span class="ruby-comment"># File lib/rubyXL/convenience_methods.rb, line 144</span>
1201
- <span class="ruby-keyword">def</span> <span class="ruby-identifier">register_new_xf</span>(<span class="ruby-identifier">new_xf</span>)
496
+ <pre><span class="ruby-comment"># File lib/rubyXL/convenience_methods/workbook.rb, line 51</span>
497
+ <span class="ruby-keyword">def</span> <span class="ruby-identifier ruby-title">register_new_xf</span>(<span class="ruby-identifier">new_xf</span>)
1202
498
  <span class="ruby-identifier">new_xf_id</span> = <span class="ruby-identifier">cell_xfs</span>.<span class="ruby-identifier">find_index</span> { <span class="ruby-operator">|</span><span class="ruby-identifier">xf</span><span class="ruby-operator">|</span> <span class="ruby-identifier">xf</span> <span class="ruby-operator">==</span> <span class="ruby-identifier">new_xf</span> } <span class="ruby-comment"># Reuse existing XF, if it exists</span>
1203
499
  <span class="ruby-identifier">new_xf_id</span> <span class="ruby-operator">||=</span> <span class="ruby-identifier">cell_xfs</span>.<span class="ruby-identifier">size</span> <span class="ruby-comment"># If this XF has never existed before, add it to collection.</span>
1204
500
  <span class="ruby-identifier">cell_xfs</span>[<span class="ruby-identifier">new_xf_id</span>] = <span class="ruby-identifier">new_xf</span>
1205
501
  <span class="ruby-identifier">new_xf_id</span>
1206
502
  <span class="ruby-keyword">end</span></pre>
1207
503
  </div>
1208
-
1209
504
  </div>
1210
505
 
1211
-
1212
506
 
1213
-
1214
507
  </div>
1215
508
 
1216
-
1217
509
  </section>
1218
-
510
+
1219
511
  </section>
1220
512
  </main>
1221
513
 
1222
514
 
1223
515
  <footer id="validator-badges" role="contentinfo">
1224
- <p><a href="http://validator.w3.org/check/referer">Validate</a>
1225
- <p>Generated by <a href="http://docs.seattlerb.org/rdoc/">RDoc</a> 4.2.2.
516
+ <p><a href="https://validator.w3.org/check/referer">Validate</a>
517
+ <p>Generated by <a href="https://ruby.github.io/rdoc/">RDoc</a> 6.3.0.
1226
518
  <p>Based on <a href="http://deveiate.org/projects/Darkfish-RDoc/">Darkfish</a> by <a href="http://deveiate.org">Michael Granger</a>.
1227
519
  </footer>
1228
520