rubyXL 3.3.1 → 3.3.2
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/VERSION +1 -1
- data/lib/rubyXL/objects/content_types.rb +8 -3
- data/lib/rubyXL/objects/ooxml_object.rb +0 -1
- data/lib/rubyXL/objects/relationships.rb +1 -1
- data/lib/rubyXL/objects/storage.rb +28 -5
- data/lib/rubyXL/objects/text.rb +8 -1
- data/lib/rubyXL/objects/workbook.rb +9 -2
- data/rdoc/README_rdoc.html +179 -152
- data/rdoc/RubyXL.html +7 -10
- data/rdoc/RubyXL/AExtension.html +7 -10
- data/rdoc/RubyXL/AExtensionStorageArea.html +7 -10
- data/rdoc/RubyXL/AdjustHandleList.html +10 -10
- data/rdoc/RubyXL/Alignment.html +7 -10
- data/rdoc/RubyXL/AlternateContent.html +7 -10
- data/rdoc/RubyXL/Authors.html +10 -10
- data/rdoc/RubyXL/AutoFilter.html +10 -10
- data/rdoc/RubyXL/AutoFilterColumn.html +10 -10
- data/rdoc/RubyXL/BinaryImageFile.html +26 -10
- data/rdoc/RubyXL/BodyProperties.html +10 -10
- data/rdoc/RubyXL/BooleanNode.html +7 -10
- data/rdoc/RubyXL/BooleanValue.html +7 -10
- data/rdoc/RubyXL/Border.html +97 -10
- data/rdoc/RubyXL/BorderEdge.html +7 -10
- data/rdoc/RubyXL/Borders.html +61 -10
- data/rdoc/RubyXL/Break.html +10 -10
- data/rdoc/RubyXL/BreakList.html +10 -10
- data/rdoc/RubyXL/CT_AdjPoint2D.html +10 -10
- data/rdoc/RubyXL/CT_AlphaBiLevelEffect.html +10 -10
- data/rdoc/RubyXL/CT_AlphaModulateEffect.html +10 -10
- data/rdoc/RubyXL/CT_AlphaModulateFixedEffect.html +10 -10
- data/rdoc/RubyXL/CT_AlphaOutsetEffect.html +10 -10
- data/rdoc/RubyXL/CT_AlphaReplaceEffect.html +10 -10
- data/rdoc/RubyXL/CT_Backdrop.html +10 -10
- data/rdoc/RubyXL/CT_Bevel.html +10 -10
- data/rdoc/RubyXL/CT_BiLevelEffect.html +10 -10
- data/rdoc/RubyXL/CT_BlendEffect.html +10 -10
- data/rdoc/RubyXL/CT_Blip.html +10 -10
- data/rdoc/RubyXL/CT_BlipFillProperties.html +10 -10
- data/rdoc/RubyXL/CT_BlurEffect.html +10 -10
- data/rdoc/RubyXL/CT_Camera.html +10 -10
- data/rdoc/RubyXL/CT_Color.html +10 -10
- data/rdoc/RubyXL/CT_ColorChangeEffect.html +10 -10
- data/rdoc/RubyXL/CT_ColorMapping.html +10 -10
- data/rdoc/RubyXL/CT_ColorScheme.html +10 -10
- data/rdoc/RubyXL/CT_ColorSchemeAndMapping.html +10 -10
- data/rdoc/RubyXL/CT_ConnectionSite.html +10 -10
- data/rdoc/RubyXL/CT_ConnectionSiteList.html +10 -10
- data/rdoc/RubyXL/CT_DashStop.html +10 -10
- data/rdoc/RubyXL/CT_DashStopList.html +10 -10
- data/rdoc/RubyXL/CT_DefaultShapeDefinition.html +10 -10
- data/rdoc/RubyXL/CT_DuotoneEffect.html +10 -10
- data/rdoc/RubyXL/CT_EffectContainer.html +10 -10
- data/rdoc/RubyXL/CT_EffectList.html +10 -10
- data/rdoc/RubyXL/CT_EffectReference.html +10 -10
- data/rdoc/RubyXL/CT_EffectStyleItem.html +10 -10
- data/rdoc/RubyXL/CT_EffectStyleList.html +10 -10
- data/rdoc/RubyXL/CT_EmbeddedWAVAudioFile.html +10 -10
- data/rdoc/RubyXL/CT_FillEffect.html +10 -10
- data/rdoc/RubyXL/CT_FillOverlayEffect.html +10 -10
- data/rdoc/RubyXL/CT_FillStyleList.html +10 -10
- data/rdoc/RubyXL/CT_FlatText.html +10 -10
- data/rdoc/RubyXL/CT_FontCollection.html +10 -10
- data/rdoc/RubyXL/CT_FontReference.html +10 -10
- data/rdoc/RubyXL/CT_GeomGuideList.html +10 -10
- data/rdoc/RubyXL/CT_GlowEffect.html +10 -10
- data/rdoc/RubyXL/CT_GradientFillProperties.html +10 -10
- data/rdoc/RubyXL/CT_GradientStop.html +10 -10
- data/rdoc/RubyXL/CT_GradientStopList.html +10 -10
- data/rdoc/RubyXL/CT_HSLEffect.html +10 -10
- data/rdoc/RubyXL/CT_HslColor.html +10 -10
- data/rdoc/RubyXL/CT_Hyperlink.html +10 -10
- data/rdoc/RubyXL/CT_InnerShadowEffect.html +10 -10
- data/rdoc/RubyXL/CT_LightRig.html +10 -10
- data/rdoc/RubyXL/CT_LineEndProperties.html +10 -10
- data/rdoc/RubyXL/CT_LineJoinMiterProperties.html +10 -10
- data/rdoc/RubyXL/CT_LineProperties.html +10 -10
- data/rdoc/RubyXL/CT_LineStyleList.html +10 -10
- data/rdoc/RubyXL/CT_LinearShadeProperties.html +10 -10
- data/rdoc/RubyXL/CT_LuminanceEffect.html +10 -10
- data/rdoc/RubyXL/CT_ObjectStyleDefaults.html +10 -10
- data/rdoc/RubyXL/CT_OuterShadowEffect.html +10 -10
- data/rdoc/RubyXL/CT_Path2D.html +10 -10
- data/rdoc/RubyXL/CT_Path2DArcTo.html +10 -10
- data/rdoc/RubyXL/CT_Path2DCubicBezierTo.html +10 -10
- data/rdoc/RubyXL/CT_Path2DList.html +10 -10
- data/rdoc/RubyXL/CT_Path2DQuadBezierTo.html +10 -10
- data/rdoc/RubyXL/CT_Path2DTo.html +10 -10
- data/rdoc/RubyXL/CT_PathShadeProperties.html +10 -10
- data/rdoc/RubyXL/CT_PatternFillProperties.html +10 -10
- data/rdoc/RubyXL/CT_Point3D.html +10 -10
- data/rdoc/RubyXL/CT_PolarAdjustHandle.html +10 -10
- data/rdoc/RubyXL/CT_PresetColor.html +10 -10
- data/rdoc/RubyXL/CT_PresetLineDashProperties.html +10 -10
- data/rdoc/RubyXL/CT_PresetShadowEffect.html +10 -10
- data/rdoc/RubyXL/CT_PresetTextShape.html +10 -10
- data/rdoc/RubyXL/CT_ReflectionEffect.html +10 -10
- data/rdoc/RubyXL/CT_RelativeOffsetEffect.html +10 -10
- data/rdoc/RubyXL/CT_RelativeRect.html +10 -10
- data/rdoc/RubyXL/CT_SRgbColor.html +10 -10
- data/rdoc/RubyXL/CT_ScRgbColor.html +10 -10
- data/rdoc/RubyXL/CT_Scene3D.html +10 -10
- data/rdoc/RubyXL/CT_SchemeColor.html +10 -10
- data/rdoc/RubyXL/CT_Shape3D.html +10 -10
- data/rdoc/RubyXL/CT_ShapeStyle.html +10 -10
- data/rdoc/RubyXL/CT_SoftEdgesEffect.html +10 -10
- data/rdoc/RubyXL/CT_SphereCoords.html +10 -10
- data/rdoc/RubyXL/CT_StretchInfoProperties.html +10 -10
- data/rdoc/RubyXL/CT_StyleMatrix.html +10 -10
- data/rdoc/RubyXL/CT_StyleMatrixReference.html +10 -10
- data/rdoc/RubyXL/CT_SupplementalFont.html +10 -10
- data/rdoc/RubyXL/CT_SystemColor.html +10 -10
- data/rdoc/RubyXL/CT_TextAutonumberBullet.html +10 -10
- data/rdoc/RubyXL/CT_TextBlipBullet.html +10 -10
- data/rdoc/RubyXL/CT_TextCharBullet.html +10 -10
- data/rdoc/RubyXL/CT_TextCharacterProperties.html +10 -10
- data/rdoc/RubyXL/CT_TextFont.html +10 -10
- data/rdoc/RubyXL/CT_TextListStyle.html +10 -10
- data/rdoc/RubyXL/CT_TextNormalAutofit.html +10 -10
- data/rdoc/RubyXL/CT_TextParagraphProperties.html +10 -10
- data/rdoc/RubyXL/CT_TextSpacing.html +10 -10
- data/rdoc/RubyXL/CT_TextTabStop.html +10 -10
- data/rdoc/RubyXL/CT_TextTabStopList.html +10 -10
- data/rdoc/RubyXL/CT_TileInfoProperties.html +10 -10
- data/rdoc/RubyXL/CT_TintEffect.html +10 -10
- data/rdoc/RubyXL/CT_Transform2D.html +10 -10
- data/rdoc/RubyXL/CT_TransformEffect.html +10 -10
- data/rdoc/RubyXL/CT_Vector3D.html +10 -10
- data/rdoc/RubyXL/CT_XYAdjustHandle.html +10 -10
- data/rdoc/RubyXL/CalculationChain.html +7 -10
- data/rdoc/RubyXL/CalculationChainCell.html +7 -10
- data/rdoc/RubyXL/CalculationProperties.html +10 -10
- data/rdoc/RubyXL/Cell.html +9 -11
- data/rdoc/RubyXL/CellConvenienceMethods.html +203 -10
- data/rdoc/RubyXL/CellSmartTag.html +10 -10
- data/rdoc/RubyXL/CellSmartTagProperty.html +10 -10
- data/rdoc/RubyXL/CellSmartTags.html +10 -10
- data/rdoc/RubyXL/CellStyle.html +7 -10
- data/rdoc/RubyXL/CellStyleXFs.html +61 -10
- data/rdoc/RubyXL/CellStyles.html +61 -10
- data/rdoc/RubyXL/CellValue.html +7 -10
- data/rdoc/RubyXL/CellWatch.html +10 -10
- data/rdoc/RubyXL/CellWatches.html +10 -10
- data/rdoc/RubyXL/CellXFs.html +65 -10
- data/rdoc/RubyXL/ChartColorsFile.html +26 -10
- data/rdoc/RubyXL/ChartFile.html +93 -10
- data/rdoc/RubyXL/ChartStyleFile.html +26 -10
- data/rdoc/RubyXL/ChartUserShapesFile.html +26 -10
- data/rdoc/RubyXL/Chartsheet.html +164 -10
- data/rdoc/RubyXL/ChartsheetPageSetup.html +10 -10
- data/rdoc/RubyXL/ChartsheetProperties.html +7 -10
- data/rdoc/RubyXL/ChartsheetProtection.html +7 -10
- data/rdoc/RubyXL/ChartsheetView.html +10 -10
- data/rdoc/RubyXL/ChartsheetViews.html +10 -10
- data/rdoc/RubyXL/Color.html +7 -10
- data/rdoc/RubyXL/ColorFilter.html +10 -10
- data/rdoc/RubyXL/ColorScale.html +10 -10
- data/rdoc/RubyXL/ColorSet.html +10 -10
- data/rdoc/RubyXL/Colors.html +10 -10
- data/rdoc/RubyXL/ColumnRange.html +7 -10
- data/rdoc/RubyXL/ColumnRanges.html +7 -10
- data/rdoc/RubyXL/Comment.html +7 -10
- data/rdoc/RubyXL/CommentList.html +10 -10
- data/rdoc/RubyXL/CommentsFile.html +101 -10
- data/rdoc/RubyXL/ConditionalFormatValue.html +10 -10
- data/rdoc/RubyXL/ConditionalFormatting.html +10 -10
- data/rdoc/RubyXL/ConditionalFormattingRule.html +10 -10
- data/rdoc/RubyXL/ContentTypeDefault.html +7 -10
- data/rdoc/RubyXL/ContentTypeOverride.html +7 -10
- data/rdoc/RubyXL/ContentTypes.html +15 -13
- data/rdoc/RubyXL/ControlPropertiesFile.html +21 -10
- data/rdoc/RubyXL/CorePropertiesFile.html +378 -10
- data/rdoc/RubyXL/CustomColor.html +10 -10
- data/rdoc/RubyXL/CustomColorList.html +10 -10
- data/rdoc/RubyXL/CustomFilter.html +10 -10
- data/rdoc/RubyXL/CustomFilters.html +10 -10
- data/rdoc/RubyXL/CustomGeometry.html +10 -10
- data/rdoc/RubyXL/CustomProperties.html +10 -10
- data/rdoc/RubyXL/CustomPropertiesFile.html +26 -10
- data/rdoc/RubyXL/CustomProperty.html +10 -10
- data/rdoc/RubyXL/CustomSheetView.html +10 -10
- data/rdoc/RubyXL/CustomSheetViews.html +10 -10
- data/rdoc/RubyXL/CustomWorkbookView.html +10 -10
- data/rdoc/RubyXL/CustomWorkbookViews.html +10 -10
- data/rdoc/RubyXL/CustomXMLFile.html +21 -10
- data/rdoc/RubyXL/DXF.html +10 -10
- data/rdoc/RubyXL/DXFs.html +10 -10
- data/rdoc/RubyXL/DataBar.html +10 -10
- data/rdoc/RubyXL/DataConsolidate.html +10 -10
- data/rdoc/RubyXL/DataConsolidationReference.html +10 -10
- data/rdoc/RubyXL/DataConsolidationReferences.html +10 -10
- data/rdoc/RubyXL/DataType.html +7 -10
- data/rdoc/RubyXL/DataValidation.html +7 -10
- data/rdoc/RubyXL/DataValidations.html +10 -10
- data/rdoc/RubyXL/DateGroupItem.html +7 -10
- data/rdoc/RubyXL/DefinedName.html +10 -10
- data/rdoc/RubyXL/DefinedNames.html +10 -10
- data/rdoc/RubyXL/DocumentPropertiesFile.html +7 -10
- data/rdoc/RubyXL/DrawingFile.html +92 -10
- data/rdoc/RubyXL/DynamicFilter.html +10 -10
- data/rdoc/RubyXL/EmbeddedControl.html +10 -10
- data/rdoc/RubyXL/EmbeddedControls.html +10 -10
- data/rdoc/RubyXL/Extension.html +7 -10
- data/rdoc/RubyXL/ExtensionStorageArea.html +7 -10
- data/rdoc/RubyXL/Extents.html +10 -10
- data/rdoc/RubyXL/ExternalLinksFile.html +26 -10
- data/rdoc/RubyXL/ExternalReference.html +10 -10
- data/rdoc/RubyXL/ExternalReferences.html +10 -10
- data/rdoc/RubyXL/ExtraColorSchemeList.html +10 -10
- data/rdoc/RubyXL/FieldItem.html +10 -10
- data/rdoc/RubyXL/FileRecoveryProperties.html +10 -10
- data/rdoc/RubyXL/FileSharing.html +7 -10
- data/rdoc/RubyXL/FileVersion.html +7 -10
- data/rdoc/RubyXL/Fill.html +61 -10
- data/rdoc/RubyXL/Fills.html +61 -10
- data/rdoc/RubyXL/FilterContainer.html +10 -10
- data/rdoc/RubyXL/FloatNode.html +7 -10
- data/rdoc/RubyXL/FloatValue.html +7 -10
- data/rdoc/RubyXL/Font.html +7 -10
- data/rdoc/RubyXL/FontScheme.html +10 -10
- data/rdoc/RubyXL/Fonts.html +61 -10
- data/rdoc/RubyXL/Formula.html +7 -10
- data/rdoc/RubyXL/FunctionGroup.html +10 -10
- data/rdoc/RubyXL/FunctionGroups.html +10 -10
- data/rdoc/RubyXL/GenericStorageObject.html +7 -10
- data/rdoc/RubyXL/GradientFill.html +10 -10
- data/rdoc/RubyXL/HeaderFooterSettings.html +10 -10
- data/rdoc/RubyXL/Hyperlink.html +10 -10
- data/rdoc/RubyXL/HyperlinkRelFile.html +21 -10
- data/rdoc/RubyXL/Hyperlinks.html +10 -10
- data/rdoc/RubyXL/IconFilter.html +10 -10
- data/rdoc/RubyXL/IconSet.html +10 -10
- data/rdoc/RubyXL/IgnoredError.html +10 -10
- data/rdoc/RubyXL/IgnoredErrors.html +10 -10
- data/rdoc/RubyXL/IndexedColors.html +10 -10
- data/rdoc/RubyXL/InputCells.html +10 -10
- data/rdoc/RubyXL/IntegerNode.html +7 -10
- data/rdoc/RubyXL/IntegerValue.html +7 -10
- data/rdoc/RubyXL/LegacyCell.html +7 -10
- data/rdoc/RubyXL/LegacyWorksheet.html +7 -10
- data/rdoc/RubyXL/MRUColors.html +10 -10
- data/rdoc/RubyXL/MacrosFile.html +26 -10
- data/rdoc/RubyXL/MergedCell.html +10 -10
- data/rdoc/RubyXL/MergedCells.html +10 -10
- data/rdoc/RubyXL/NumFmt.html +10 -10
- data/rdoc/RubyXL/NumberFormat.html +7 -10
- data/rdoc/RubyXL/NumberFormats.html +7 -10
- data/rdoc/RubyXL/OLEObject.html +10 -10
- data/rdoc/RubyXL/OLEObjectFile.html +26 -10
- data/rdoc/RubyXL/OLEObjects.html +10 -10
- data/rdoc/RubyXL/OLESize.html +10 -10
- data/rdoc/RubyXL/OOXMLContainerObject.html +298 -10
- data/rdoc/RubyXL/OOXMLObject.html +23 -11
- data/rdoc/RubyXL/OOXMLObjectClassMethods.html +23 -22
- data/rdoc/RubyXL/OOXMLObjectInstanceMethods.html +447 -10
- data/rdoc/RubyXL/OOXMLRelationshipsFile.html +8 -11
- data/rdoc/RubyXL/OOXMLTopLevelObject.html +284 -10
- data/rdoc/RubyXL/Offset.html +10 -10
- data/rdoc/RubyXL/OutlineProperties.html +7 -10
- data/rdoc/RubyXL/PageMargins.html +10 -10
- data/rdoc/RubyXL/PageSetup.html +10 -10
- data/rdoc/RubyXL/PageSetupProperties.html +7 -10
- data/rdoc/RubyXL/Pane.html +10 -10
- data/rdoc/RubyXL/Parser.html +7 -10
- data/rdoc/RubyXL/PatternFill.html +10 -10
- data/rdoc/RubyXL/PhoneticProperties.html +10 -10
- data/rdoc/RubyXL/PhoneticRun.html +10 -10
- data/rdoc/RubyXL/PivotArea.html +10 -10
- data/rdoc/RubyXL/PivotCache.html +10 -10
- data/rdoc/RubyXL/PivotCacheDefinitionFile.html +38 -11
- data/rdoc/RubyXL/PivotCacheRecordsFile.html +121 -0
- data/rdoc/RubyXL/PivotCaches.html +10 -10
- data/rdoc/RubyXL/PivotReference.html +10 -10
- data/rdoc/RubyXL/PivotReferences.html +10 -10
- data/rdoc/RubyXL/PivotTableFile.html +38 -11
- data/rdoc/RubyXL/PivotTableSelection.html +10 -10
- data/rdoc/RubyXL/PresetGeometry.html +10 -10
- data/rdoc/RubyXL/PrintOptions.html +10 -10
- data/rdoc/RubyXL/PrinterSettingsFile.html +26 -10
- data/rdoc/RubyXL/ProtectedRange.html +10 -10
- data/rdoc/RubyXL/ProtectedRanges.html +10 -10
- data/rdoc/RubyXL/Protection.html +10 -10
- data/rdoc/RubyXL/RID.html +7 -10
- data/rdoc/RubyXL/RawOOXML.html +7 -10
- data/rdoc/RubyXL/Reference.html +7 -10
- data/rdoc/RubyXL/Relationship.html +7 -10
- data/rdoc/RubyXL/RelationshipSupport.html +324 -10
- data/rdoc/RubyXL/RelationshipSupport/ClassMehods.html +59 -10
- data/rdoc/RubyXL/RichText.html +63 -10
- data/rdoc/RubyXL/RichTextRun.html +61 -10
- data/rdoc/RubyXL/Row.html +329 -10
- data/rdoc/RubyXL/RunProperties.html +7 -10
- data/rdoc/RubyXL/Scenario.html +10 -10
- data/rdoc/RubyXL/Scenarios.html +10 -10
- data/rdoc/RubyXL/Selection.html +69 -10
- data/rdoc/RubyXL/ShapeGuide.html +10 -10
- data/rdoc/RubyXL/ShapeTextRectangle.html +10 -10
- data/rdoc/RubyXL/SharedStringsTable.html +9 -12
- data/rdoc/RubyXL/Sheet.html +10 -10
- data/rdoc/RubyXL/SheetCalculationProperties.html +10 -10
- data/rdoc/RubyXL/SheetData.html +96 -10
- data/rdoc/RubyXL/Sheets.html +10 -10
- data/rdoc/RubyXL/SlicerCacheFile.html +26 -10
- data/rdoc/RubyXL/SlicerFile.html +26 -10
- data/rdoc/RubyXL/SmartTagProperties.html +10 -10
- data/rdoc/RubyXL/SmartTagType.html +10 -10
- data/rdoc/RubyXL/SmartTagTypes.html +10 -10
- data/rdoc/RubyXL/SmartTags.html +10 -10
- data/rdoc/RubyXL/SortCondition.html +10 -10
- data/rdoc/RubyXL/SortState.html +10 -10
- data/rdoc/RubyXL/Sqref.html +7 -10
- data/rdoc/RubyXL/Stop.html +7 -10
- data/rdoc/RubyXL/StringNode.html +7 -10
- data/rdoc/RubyXL/StringNodeW3C.html +7 -10
- data/rdoc/RubyXL/StringValue.html +7 -10
- data/rdoc/RubyXL/Stylesheet.html +211 -10
- data/rdoc/RubyXL/TableFile.html +26 -10
- data/rdoc/RubyXL/TableParts.html +7 -10
- data/rdoc/RubyXL/TableStyle.html +10 -10
- data/rdoc/RubyXL/TableStyles.html +10 -10
- data/rdoc/RubyXL/Text.html +33 -13
- data/rdoc/RubyXL/Theme.html +439 -10
- data/rdoc/RubyXL/ThemeElements.html +10 -10
- data/rdoc/RubyXL/ThumbnailFile.html +26 -10
- data/rdoc/RubyXL/Top10.html +10 -10
- data/rdoc/RubyXL/VMLDrawingFile.html +39 -11
- data/rdoc/RubyXL/Variant.html +7 -10
- data/rdoc/RubyXL/Vector.html +65 -10
- data/rdoc/RubyXL/VectorValue.html +7 -10
- data/rdoc/RubyXL/VisualProperties.html +10 -10
- data/rdoc/RubyXL/WebPublishObject.html +10 -10
- data/rdoc/RubyXL/WebPublishObjects.html +10 -10
- data/rdoc/RubyXL/WebPublishingItem.html +7 -10
- data/rdoc/RubyXL/WebPublishingItems.html +10 -10
- data/rdoc/RubyXL/WebPublishingProperties.html +10 -10
- data/rdoc/RubyXL/Workbook.html +514 -10
- data/rdoc/RubyXL/WorkbookConvenienceMethods.html +7 -10
- data/rdoc/RubyXL/WorkbookProperties.html +7 -10
- data/rdoc/RubyXL/WorkbookProtection.html +10 -10
- data/rdoc/RubyXL/WorkbookRoot.html +7 -10
- data/rdoc/RubyXL/WorkbookView.html +10 -10
- data/rdoc/RubyXL/WorkbookViews.html +10 -10
- data/rdoc/RubyXL/Worksheet.html +337 -10
- data/rdoc/RubyXL/WorksheetConvenienceMethods.html +2624 -10
- data/rdoc/RubyXL/WorksheetDimensions.html +10 -10
- data/rdoc/RubyXL/WorksheetFormatProperties.html +7 -10
- data/rdoc/RubyXL/WorksheetProperties.html +7 -10
- data/rdoc/RubyXL/WorksheetProtection.html +10 -10
- data/rdoc/RubyXL/WorksheetView.html +10 -10
- data/rdoc/RubyXL/WorksheetViews.html +10 -10
- data/rdoc/RubyXL/XF.html +10 -10
- data/rdoc/created.rid +8 -8
- data/rdoc/{fonts.css → css/fonts.css} +0 -0
- data/rdoc/{rdoc.css → css/rdoc.css} +11 -1
- data/rdoc/index.html +570 -11
- data/rdoc/js/darkfish.js +32 -11
- data/rdoc/js/navigation.js.gz +0 -0
- data/rdoc/js/search_index.js +1 -1
- data/rdoc/js/search_index.js.gz +0 -0
- data/rdoc/js/searcher.js.gz +0 -0
- data/rdoc/table_of_contents.html +1920 -295
- data/rubyXL.gemspec +9 -5
- metadata +8 -4
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA1:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: faa517b01e7209e004e94ee11315a4080b68cdef
|
|
4
|
+
data.tar.gz: 6a560263f6aa97b8e8970c092687c411e311e112
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: e2c8048fd3f3fc0ec15dd3ec5cab2d8cbd8bdeb00301699a41065f16e363ef7077d0cc541818f2c09ffef9b7aa98bedb1f017eabcbc26b6469755dd144780dec
|
|
7
|
+
data.tar.gz: 77a9c24dc08d450c230a33f1369f606d65c7756f3abf879ad7148308704effa35ffeaffeba63a706aeb92b567156c7603e61fb500882efc00a228dd5804e7e73
|
data/VERSION
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
3.3.
|
|
1
|
+
3.3.2
|
|
@@ -56,11 +56,16 @@ module RubyXL
|
|
|
56
56
|
# Add overrides for the files with known extensions but different content types.
|
|
57
57
|
root.rels_hash.each_pair { |klass, objects|
|
|
58
58
|
objects.each { |obj|
|
|
59
|
-
|
|
59
|
+
obj_content_type = case
|
|
60
|
+
when obj.respond_to?(:content_type) then obj.content_type
|
|
61
|
+
when defined?(klass::CONTENT_TYPE) then klass::CONTENT_TYPE
|
|
62
|
+
else next
|
|
63
|
+
end
|
|
64
|
+
|
|
60
65
|
ext = obj.xlsx_path.extname[1..-1]
|
|
61
|
-
next if defaults.any? { |d| (d.extension == ext) && (d.content_type ==
|
|
66
|
+
next if defaults.any? { |d| (d.extension == ext) && (d.content_type == obj_content_type) }
|
|
62
67
|
overrides << RubyXL::ContentTypeOverride.new(:part_name => obj.xlsx_path,
|
|
63
|
-
:content_type =>
|
|
68
|
+
:content_type => obj_content_type)
|
|
64
69
|
}
|
|
65
70
|
}
|
|
66
71
|
|
|
@@ -60,10 +60,19 @@ module RubyXL
|
|
|
60
60
|
|
|
61
61
|
end
|
|
62
62
|
|
|
63
|
+
class BinaryImageFile < GenericStorageObject
|
|
64
|
+
CONTENT_TYPE = 'image/jpeg'
|
|
65
|
+
REL_TYPE = 'http://schemas.openxmlformats.org/officeDocument/2006/relationships/image'
|
|
66
|
+
end
|
|
67
|
+
|
|
63
68
|
class VMLDrawingFile < GenericStorageObject
|
|
64
69
|
CONTENT_TYPE = 'application/vnd.openxmlformats-officedocument.vmlDrawing'
|
|
65
70
|
# CONTENT_TYPE = 'application/vnd.openxmlformats-officedocument.drawingml.chart+xml'
|
|
66
71
|
REL_TYPE = 'http://schemas.openxmlformats.org/officeDocument/2006/relationships/vmlDrawing'
|
|
72
|
+
|
|
73
|
+
include RubyXL::RelationshipSupport
|
|
74
|
+
|
|
75
|
+
define_relationship(RubyXL::BinaryImageFile)
|
|
67
76
|
end
|
|
68
77
|
|
|
69
78
|
class ChartColorsFile < GenericStorageObject
|
|
@@ -77,6 +86,7 @@ module RubyXL
|
|
|
77
86
|
end
|
|
78
87
|
|
|
79
88
|
class TableFile < GenericStorageObject
|
|
89
|
+
CONTENT_TYPE = 'application/vnd.openxmlformats-officedocument.spreadsheetml.table+xml'
|
|
80
90
|
REL_TYPE = 'http://schemas.openxmlformats.org/officeDocument/2006/relationships/table'
|
|
81
91
|
end
|
|
82
92
|
|
|
@@ -84,17 +94,27 @@ module RubyXL
|
|
|
84
94
|
REL_TYPE = 'http://schemas.openxmlformats.org/officeDocument/2006/relationships/ctrlProp'
|
|
85
95
|
end
|
|
86
96
|
|
|
87
|
-
class
|
|
88
|
-
|
|
97
|
+
class PivotCacheRecordsFile < GenericStorageObject
|
|
98
|
+
CONTENT_TYPE = 'application/vnd.openxmlformats-officedocument.spreadsheetml.pivotCacheRecords+xml'
|
|
99
|
+
REL_TYPE = 'http://schemas.openxmlformats.org/officeDocument/2006/relationships/pivotCacheRecords'
|
|
89
100
|
end
|
|
90
101
|
|
|
91
102
|
class PivotCacheDefinitionFile < GenericStorageObject
|
|
103
|
+
CONTENT_TYPE = 'application/vnd.openxmlformats-officedocument.spreadsheetml.pivotCacheDefinition+xml'
|
|
92
104
|
REL_TYPE = 'http://schemas.openxmlformats.org/officeDocument/2006/relationships/pivotCacheDefinition'
|
|
105
|
+
|
|
106
|
+
include RubyXL::RelationshipSupport
|
|
107
|
+
|
|
108
|
+
define_relationship(RubyXL::PivotCacheRecordsFile)
|
|
93
109
|
end
|
|
94
110
|
|
|
95
|
-
class
|
|
96
|
-
CONTENT_TYPE = '
|
|
97
|
-
REL_TYPE = 'http://schemas.openxmlformats.org/officeDocument/2006/relationships/
|
|
111
|
+
class PivotTableFile < GenericStorageObject
|
|
112
|
+
CONTENT_TYPE = 'application/vnd.openxmlformats-officedocument.spreadsheetml.pivotTable+xml'
|
|
113
|
+
REL_TYPE = 'http://schemas.openxmlformats.org/officeDocument/2006/relationships/pivotTable'
|
|
114
|
+
|
|
115
|
+
include RubyXL::RelationshipSupport
|
|
116
|
+
|
|
117
|
+
define_relationship(RubyXL::PivotCacheDefinitionFile)
|
|
98
118
|
end
|
|
99
119
|
|
|
100
120
|
class HyperlinkRelFile < GenericStorageObject
|
|
@@ -131,10 +151,12 @@ module RubyXL
|
|
|
131
151
|
end
|
|
132
152
|
|
|
133
153
|
class SlicerFile < GenericStorageObject
|
|
154
|
+
CONTENT_TYPE = 'application/vnd.ms-excel.slicer+xml'
|
|
134
155
|
REL_TYPE = 'http://schemas.microsoft.com/office/2007/relationships/slicer'
|
|
135
156
|
end
|
|
136
157
|
|
|
137
158
|
class SlicerCacheFile < GenericStorageObject
|
|
159
|
+
CONTENT_TYPE = 'application/vnd.ms-excel.slicerCache+xml'
|
|
138
160
|
REL_TYPE = 'http://schemas.microsoft.com/office/2007/relationships/slicerCache'
|
|
139
161
|
end
|
|
140
162
|
|
|
@@ -144,3 +166,4 @@ module RubyXL
|
|
|
144
166
|
end
|
|
145
167
|
|
|
146
168
|
end
|
|
169
|
+
|
data/lib/rubyXL/objects/text.rb
CHANGED
|
@@ -11,13 +11,20 @@ module RubyXL
|
|
|
11
11
|
define_attribute(:'xml:space', :string)
|
|
12
12
|
define_element_name 't'
|
|
13
13
|
|
|
14
|
+
# http://www.w3.org/TR/REC-xml/#NT-Char:
|
|
15
|
+
# Char ::= #x9 | #xA | #xD | [#x20-#xD7FF] | [#xE000-#xFFFD] | [#x10000-#x10FFFF]
|
|
16
|
+
|
|
17
|
+
INVALID_XML10_CHARS = /([^\x09\x0A\x0D\x20-\uD7FF\uE000-\uFFFD\u10000-\u10FFFF])/
|
|
18
|
+
ESCAPED_UNICODE = /_x([0-9A-F]{4})_/
|
|
19
|
+
|
|
14
20
|
def before_write_xml
|
|
15
21
|
self.xml_space = (value.is_a?(String) && ((value =~ /\A\s/) || (value =~ /\s\Z/) || value.include?("\n"))) ? 'preserve' : nil
|
|
22
|
+
self.value.gsub!(INVALID_XML10_CHARS) { |c| "_x%04x_" % c.ord }
|
|
16
23
|
true
|
|
17
24
|
end
|
|
18
25
|
|
|
19
26
|
def to_s
|
|
20
|
-
value.to_s
|
|
27
|
+
value.to_s.gsub(ESCAPED_UNICODE) { |m| $1.hex.chr }
|
|
21
28
|
end
|
|
22
29
|
end
|
|
23
30
|
|
|
@@ -298,12 +298,18 @@ module RubyXL
|
|
|
298
298
|
# http://www.schemacentral.com/sc/ooxml/e-ssml_workbook.html
|
|
299
299
|
class Workbook < OOXMLTopLevelObject
|
|
300
300
|
CONTENT_TYPE = 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet.main+xml'
|
|
301
|
+
CONTENT_TYPE_MACRO = 'application/vnd.ms-excel.sheet.macroEnabled.main+xml'
|
|
301
302
|
REL_TYPE = 'http://schemas.openxmlformats.org/officeDocument/2006/relationships/officeDocument'
|
|
302
303
|
|
|
303
304
|
include RubyXL::RelationshipSupport
|
|
304
305
|
|
|
306
|
+
def content_type
|
|
307
|
+
if macros then CONTENT_TYPE_MACRO else CONTENT_TYPE end
|
|
308
|
+
end
|
|
309
|
+
|
|
310
|
+
|
|
305
311
|
def related_objects
|
|
306
|
-
[ calculation_chain, stylesheet, theme, shared_strings_container ] + @worksheets
|
|
312
|
+
[ calculation_chain, stylesheet, theme, shared_strings_container, macros ] + @worksheets
|
|
307
313
|
end
|
|
308
314
|
|
|
309
315
|
define_relationship(RubyXL::SharedStringsTable, :shared_strings_container)
|
|
@@ -314,8 +320,9 @@ module RubyXL
|
|
|
314
320
|
define_relationship(RubyXL::Chartsheet, false)
|
|
315
321
|
define_relationship(RubyXL::ExternalLinksFile)
|
|
316
322
|
define_relationship(RubyXL::PivotCacheDefinitionFile)
|
|
323
|
+
define_relationship(RubyXL::PivotCacheRecordsFile)
|
|
317
324
|
define_relationship(RubyXL::CustomXMLFile)
|
|
318
|
-
define_relationship(RubyXL::MacrosFile)
|
|
325
|
+
define_relationship(RubyXL::MacrosFile, :macros)
|
|
319
326
|
define_relationship(RubyXL::SlicerCacheFile)
|
|
320
327
|
|
|
321
328
|
define_child_node(RubyXL::FileVersion)
|
data/rdoc/README_rdoc.html
CHANGED
|
@@ -4,22 +4,19 @@
|
|
|
4
4
|
<head>
|
|
5
5
|
<meta charset="UTF-8">
|
|
6
6
|
|
|
7
|
-
<title>README - rubyXL 3.3.
|
|
8
|
-
|
|
9
|
-
<link href="./fonts.css" rel="stylesheet">
|
|
10
|
-
<link href="./rdoc.css" rel="stylesheet">
|
|
7
|
+
<title>README - rubyXL 3.3.2</title>
|
|
11
8
|
|
|
12
9
|
<script type="text/javascript">
|
|
13
10
|
var rdoc_rel_prefix = "./";
|
|
14
11
|
</script>
|
|
15
12
|
|
|
16
13
|
<script src="./js/jquery.js"></script>
|
|
17
|
-
<script src="./js/navigation.js"></script>
|
|
18
|
-
<script src="./js/search_index.js"></script>
|
|
19
|
-
<script src="./js/search.js"></script>
|
|
20
|
-
<script src="./js/searcher.js"></script>
|
|
21
14
|
<script src="./js/darkfish.js"></script>
|
|
22
15
|
|
|
16
|
+
<link href="./css/fonts.css" rel="stylesheet">
|
|
17
|
+
<link href="./css/rdoc.css" rel="stylesheet">
|
|
18
|
+
|
|
19
|
+
|
|
23
20
|
|
|
24
21
|
<body id="top" role="document" class="file">
|
|
25
22
|
<nav role="navigation">
|
|
@@ -59,14 +56,14 @@
|
|
|
59
56
|
|
|
60
57
|
<ul class="link-list" role="directory">
|
|
61
58
|
<li><a href="#label-rubyXL">rubyXL</a>
|
|
62
|
-
<li><a href="#label-To+Install
|
|
63
|
-
<li><a href="#label-To+Use
|
|
59
|
+
<li><a href="#label-To+Install-3A">To Install:</a>
|
|
60
|
+
<li><a href="#label-To+Use-3A">To Use:</a>
|
|
64
61
|
<li><a href="#label-Parsing+an+existing+workbook">Parsing an existing workbook</a>
|
|
65
62
|
<li><a href="#label-Creating+a+new+Workbook">Creating a new Workbook</a>
|
|
66
63
|
<li><a href="#label-Accessing">Accessing</a>
|
|
67
64
|
<li><a href="#label-Accessing+a+Worksheet">Accessing a Worksheet</a>
|
|
68
65
|
<li><a href="#label-Accessing+just+the+values">Accessing just the values</a>
|
|
69
|
-
<li><a href="#label-Accessing+a+Row
|
|
66
|
+
<li><a href="#label-Accessing+a+Row+-28Array+of+Cells-29">Accessing a Row (Array of Cells)</a>
|
|
70
67
|
<li><a href="#label-Accessing+a+Cell+object">Accessing a Cell object</a>
|
|
71
68
|
<li><a href="#label-Wrappers+for+accessing+Cell+properties">Wrappers for accessing Cell properties</a>
|
|
72
69
|
<li><a href="#label-Wrappers+for+accessing+Row+properties+">Wrappers for accessing Row properties </a>
|
|
@@ -92,7 +89,7 @@
|
|
|
92
89
|
<li><a href="#label-Delete+Column">Delete Column</a>
|
|
93
90
|
<li><a href="#label-Insert+Cell">Insert Cell</a>
|
|
94
91
|
<li><a href="#label-Delete+Cell">Delete Cell</a>
|
|
95
|
-
<li><a href="#label-I
|
|
92
|
+
<li><a href="#label-I-2FO">I/O</a>
|
|
96
93
|
<li><a href="#label-Writing">Writing</a>
|
|
97
94
|
<li><a href="#label-Streaming">Streaming</a>
|
|
98
95
|
<li><a href="#label-Miscellaneous">Miscellaneous</a>
|
|
@@ -119,7 +116,7 @@
|
|
|
119
116
|
|
|
120
117
|
<main role="main" aria-label="Page README.rdoc">
|
|
121
118
|
|
|
122
|
-
<h1 id="label-rubyXL">rubyXL<span><a href="#label-rubyXL">¶</a> <a href="#
|
|
119
|
+
<h1 id="label-rubyXL">rubyXL<span><a href="#label-rubyXL">¶</a> <a href="#top">↑</a></span></h1>
|
|
123
120
|
|
|
124
121
|
<p><a href="http://badge.fury.io/rb/rubyXL"><img
|
|
125
122
|
src="https://badge.fury.io/rb/rubyXL.svg" alt="Gem Version" /></a> <a
|
|
@@ -136,179 +133,200 @@ preserving as much of the structure as possible.</p>
|
|
|
136
133
|
<p>Please note that proprietary binary <code>xls</code> format is
|
|
137
134
|
<strong>not</strong> supported.</p>
|
|
138
135
|
|
|
139
|
-
<h2 id="label-To+Install
|
|
136
|
+
<h2 id="label-To+Install-3A">To Install:<span><a href="#label-To+Install-3A">¶</a> <a href="#top">↑</a></span></h2>
|
|
140
137
|
|
|
141
|
-
<pre>gem install rubyXL</
|
|
138
|
+
<pre class="ruby"><span class="ruby-identifier">gem</span> <span class="ruby-identifier">install</span> <span class="ruby-identifier">rubyXL</span>
|
|
139
|
+
</pre>
|
|
142
140
|
|
|
143
|
-
<h2 id="label-To+Use
|
|
141
|
+
<h2 id="label-To+Use-3A">To Use:<span><a href="#label-To+Use-3A">¶</a> <a href="#top">↑</a></span></h2>
|
|
144
142
|
|
|
145
143
|
<pre class="ruby"><span class="ruby-identifier">require</span> <span class="ruby-string">'rubyXL'</span> <span class="ruby-comment"># Assuming rubygems is already required</span>
|
|
146
144
|
</pre>
|
|
147
145
|
|
|
148
|
-
<h3 id="label-Parsing+an+existing+workbook">Parsing an existing workbook<span><a href="#label-Parsing+an+existing+workbook">¶</a> <a href="#
|
|
146
|
+
<h3 id="label-Parsing+an+existing+workbook">Parsing an existing workbook<span><a href="#label-Parsing+an+existing+workbook">¶</a> <a href="#top">↑</a></span></h3>
|
|
149
147
|
|
|
150
|
-
<pre>workbook = RubyXL
|
|
151
|
-
|
|
152
|
-
<h3 id="label-Creating+a+new+Workbook">Creating a new Workbook<span><a href="#label-Creating+a+new+Workbook">¶</a> <a href="#documentation">↑</a></span></h3>
|
|
148
|
+
<pre class="ruby"><span class="ruby-identifier">workbook</span> = <span class="ruby-constant">RubyXL</span><span class="ruby-operator">::</span><span class="ruby-constant">Parser</span>.<span class="ruby-identifier">parse</span>(<span class="ruby-string">"path/to/Excel/file.xlsx"</span>)
|
|
149
|
+
</pre>
|
|
153
150
|
|
|
154
|
-
<
|
|
151
|
+
<h3 id="label-Creating+a+new+Workbook">Creating a new Workbook<span><a href="#label-Creating+a+new+Workbook">¶</a> <a href="#top">↑</a></span></h3>
|
|
155
152
|
|
|
156
|
-
<
|
|
153
|
+
<pre class="ruby"><span class="ruby-identifier">workbook</span> = <span class="ruby-constant">RubyXL</span><span class="ruby-operator">::</span><span class="ruby-constant">Workbook</span>.<span class="ruby-identifier">new</span>
|
|
154
|
+
</pre>
|
|
157
155
|
|
|
158
|
-
<
|
|
156
|
+
<h3 id="label-Accessing">Accessing<span><a href="#label-Accessing">¶</a> <a href="#top">↑</a></span></h3>
|
|
159
157
|
|
|
160
|
-
<
|
|
161
|
-
workbook[0] # Returns first worksheet
|
|
162
|
-
workbook['Sheet1'] # Finds and returns worksheet titled "Sheet1"</pre>
|
|
158
|
+
<h4 id="label-Accessing+a+Worksheet">Accessing a Worksheet<span><a href="#label-Accessing+a+Worksheet">¶</a> <a href="#top">↑</a></span></h4>
|
|
163
159
|
|
|
164
|
-
<
|
|
160
|
+
<pre class="ruby"><span class="ruby-identifier">workbook</span>.<span class="ruby-identifier">worksheets</span>[<span class="ruby-value">0</span>] <span class="ruby-comment"># Returns first worksheet</span>
|
|
161
|
+
<span class="ruby-identifier">workbook</span>[<span class="ruby-value">0</span>] <span class="ruby-comment"># Returns first worksheet</span>
|
|
162
|
+
<span class="ruby-identifier">workbook</span>[<span class="ruby-string">'Sheet1'</span>] <span class="ruby-comment"># Finds and returns worksheet titled "Sheet1"</span>
|
|
163
|
+
</pre>
|
|
165
164
|
|
|
166
|
-
<
|
|
167
|
-
worksheet.extract_data # Produces a simple rectangular array that consists only of cell values (rather than the Cell objects)</pre>
|
|
165
|
+
<h4 id="label-Accessing+just+the+values">Accessing just the values<span><a href="#label-Accessing+just+the+values">¶</a> <a href="#top">↑</a></span></h4>
|
|
168
166
|
|
|
169
|
-
<
|
|
167
|
+
<pre class="ruby"><span class="ruby-identifier">worksheet</span> = <span class="ruby-identifier">workbook</span>[<span class="ruby-value">0</span>]
|
|
168
|
+
<span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">extract_data</span> <span class="ruby-comment"># Produces a simple rectangular array that consists only of cell values (rather than the Cell objects)</span>
|
|
169
|
+
</pre>
|
|
170
170
|
|
|
171
|
-
<
|
|
172
|
-
worksheet.sheet_data[0] # Returns first row of the worksheet
|
|
173
|
-
worksheet[0] # Returns first row of the worksheet</pre>
|
|
171
|
+
<h4 id="label-Accessing+a+Row+-28Array+of+Cells-29">Accessing a Row (Array of Cells)<span><a href="#label-Accessing+a+Row+-28Array+of+Cells-29">¶</a> <a href="#top">↑</a></span></h4>
|
|
174
172
|
|
|
175
|
-
<
|
|
173
|
+
<pre class="ruby"><span class="ruby-identifier">worksheet</span> = <span class="ruby-identifier">workbook</span>[<span class="ruby-value">0</span>]
|
|
174
|
+
<span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">sheet_data</span>[<span class="ruby-value">0</span>] <span class="ruby-comment"># Returns first row of the worksheet</span>
|
|
175
|
+
<span class="ruby-identifier">worksheet</span>[<span class="ruby-value">0</span>] <span class="ruby-comment"># Returns first row of the worksheet</span>
|
|
176
|
+
</pre>
|
|
176
177
|
|
|
177
|
-
<
|
|
178
|
-
worksheet.sheet_data[0][0] # Returns cell A1 in the worksheet
|
|
179
|
-
worksheet[0][0] # Returns cell A1 in the worksheet</pre>
|
|
178
|
+
<h4 id="label-Accessing+a+Cell+object">Accessing a Cell object<span><a href="#label-Accessing+a+Cell+object">¶</a> <a href="#top">↑</a></span></h4>
|
|
180
179
|
|
|
181
|
-
<
|
|
180
|
+
<pre class="ruby"><span class="ruby-identifier">worksheet</span> = <span class="ruby-identifier">workbook</span>[<span class="ruby-value">0</span>]
|
|
181
|
+
<span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">sheet_data</span>[<span class="ruby-value">0</span>][<span class="ruby-value">0</span>] <span class="ruby-comment"># Returns cell A1 in the worksheet</span>
|
|
182
|
+
<span class="ruby-identifier">worksheet</span>[<span class="ruby-value">0</span>][<span class="ruby-value">0</span>] <span class="ruby-comment"># Returns cell A1 in the worksheet</span>
|
|
183
|
+
</pre>
|
|
182
184
|
|
|
183
|
-
<
|
|
184
|
-
|
|
185
|
-
cell
|
|
186
|
-
cell
|
|
187
|
-
cell
|
|
188
|
-
cell
|
|
189
|
-
cell
|
|
190
|
-
cell
|
|
191
|
-
cell
|
|
185
|
+
<h4 id="label-Wrappers+for+accessing+Cell+properties">Wrappers for accessing Cell properties<span><a href="#label-Wrappers+for+accessing+Cell+properties">¶</a> <a href="#top">↑</a></span></h4>
|
|
186
|
+
|
|
187
|
+
<pre class="ruby"><span class="ruby-identifier">cell</span> = <span class="ruby-identifier">workbook</span>[<span class="ruby-value">0</span>][<span class="ruby-value">0</span>][<span class="ruby-value">0</span>]
|
|
188
|
+
<span class="ruby-identifier">cell</span>.<span class="ruby-identifier">is_struckthrough</span> <span class="ruby-comment"># Returns +true+ if the cell is struckthrough, other boolean properties have same syntax</span>
|
|
189
|
+
<span class="ruby-identifier">cell</span>.<span class="ruby-identifier">font_name</span>
|
|
190
|
+
<span class="ruby-identifier">cell</span>.<span class="ruby-identifier">font_size</span>
|
|
191
|
+
<span class="ruby-identifier">cell</span>.<span class="ruby-identifier">font_color</span>
|
|
192
|
+
<span class="ruby-identifier">cell</span>.<span class="ruby-identifier">fill_color</span>
|
|
193
|
+
<span class="ruby-identifier">cell</span>.<span class="ruby-identifier">horizontal_alignment</span>
|
|
194
|
+
<span class="ruby-identifier">cell</span>.<span class="ruby-identifier">vertical_alignment</span>
|
|
195
|
+
<span class="ruby-identifier">cell</span>.<span class="ruby-identifier">border_top</span>
|
|
196
|
+
</pre>
|
|
192
197
|
|
|
193
|
-
<h4 id="label-Wrappers+for+accessing+Row+properties+">Wrappers for accessing Row properties <span><a href="#label-Wrappers+for+accessing+Row+properties+">¶</a> <a href="#
|
|
198
|
+
<h4 id="label-Wrappers+for+accessing+Row+properties+">Wrappers for accessing Row properties <span><a href="#label-Wrappers+for+accessing+Row+properties+">¶</a> <a href="#top">↑</a></span></h4>
|
|
194
199
|
|
|
195
200
|
<p>Please note: these methods are being phased out in favor of the OOXML
|
|
196
201
|
object model.</p>
|
|
197
202
|
|
|
198
|
-
<pre>worksheet = workbook[0]
|
|
199
|
-
worksheet
|
|
200
|
-
worksheet
|
|
201
|
-
worksheet
|
|
202
|
-
worksheet
|
|
203
|
-
worksheet
|
|
204
|
-
worksheet
|
|
205
|
-
worksheet
|
|
206
|
-
worksheet
|
|
207
|
-
worksheet
|
|
208
|
-
|
|
209
|
-
|
|
203
|
+
<pre class="ruby"><span class="ruby-identifier">worksheet</span> = <span class="ruby-identifier">workbook</span>[<span class="ruby-value">0</span>]
|
|
204
|
+
<span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">get_row_fill</span>(<span class="ruby-value">0</span>)
|
|
205
|
+
<span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">get_row_font_name</span>(<span class="ruby-value">0</span>)
|
|
206
|
+
<span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">get_row_font_size</span>(<span class="ruby-value">0</span>)
|
|
207
|
+
<span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">get_row_font_color</span>(<span class="ruby-value">0</span>)
|
|
208
|
+
<span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">is_row_underlined</span>(<span class="ruby-value">0</span>)
|
|
209
|
+
<span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">get_row_height</span>(<span class="ruby-value">0</span>)
|
|
210
|
+
<span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">get_row_horizontal_alignment</span>(<span class="ruby-value">0</span>)
|
|
211
|
+
<span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">get_row_vertical_alignment</span>(<span class="ruby-value">0</span>)
|
|
212
|
+
<span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">get_row_border_right</span>(<span class="ruby-value">0</span>)
|
|
213
|
+
</pre>
|
|
214
|
+
|
|
215
|
+
<h4 id="label-Accessing+column+properties">Accessing column properties<span><a href="#label-Accessing+column+properties">¶</a> <a href="#top">↑</a></span></h4>
|
|
210
216
|
|
|
211
217
|
<p>Please note: these methods are being phased out in favor of the OOXML
|
|
212
218
|
object model.</p>
|
|
213
219
|
|
|
214
|
-
<pre>worksheet = workbook[0]
|
|
215
|
-
worksheet.get_column_fill(0)
|
|
216
|
-
worksheet.get_column_font_name(0)
|
|
217
|
-
worksheet.get_column_font_size(0)
|
|
218
|
-
worksheet.get_column_font_color(0)
|
|
219
|
-
worksheet.is_column_underlined(0)
|
|
220
|
-
worksheet.get_column_width(0)
|
|
221
|
-
worksheet.get_column_horizontal_alignment(0)
|
|
222
|
-
worksheet.get_column_vertical_alignment(0)
|
|
223
|
-
worksheet.get_column_border_right(0)</pre>
|
|
224
|
-
|
|
225
|
-
<h4 id="label-Table+identification">Table identification<span><a href="#label-Table+identification">¶</a> <a href="#documentation">↑</a></span></h4>
|
|
226
|
-
|
|
227
220
|
<pre class="ruby"><span class="ruby-identifier">worksheet</span> = <span class="ruby-identifier">workbook</span>[<span class="ruby-value">0</span>]
|
|
228
|
-
<span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">
|
|
229
|
-
<span class="ruby-
|
|
221
|
+
<span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">get_column_fill</span>(<span class="ruby-value">0</span>)
|
|
222
|
+
<span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">get_column_font_name</span>(<span class="ruby-value">0</span>)
|
|
223
|
+
<span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">get_column_font_size</span>(<span class="ruby-value">0</span>)
|
|
224
|
+
<span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">get_column_font_color</span>(<span class="ruby-value">0</span>)
|
|
225
|
+
<span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">is_column_underlined</span>(<span class="ruby-value">0</span>)
|
|
226
|
+
<span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">get_column_width</span>(<span class="ruby-value">0</span>)
|
|
227
|
+
<span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">get_column_horizontal_alignment</span>(<span class="ruby-value">0</span>)
|
|
228
|
+
<span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">get_column_vertical_alignment</span>(<span class="ruby-value">0</span>)
|
|
229
|
+
<span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">get_column_border_right</span>(<span class="ruby-value">0</span>)
|
|
230
|
+
</pre>
|
|
231
|
+
|
|
232
|
+
<h4 id="label-Table+identification">Table identification<span><a href="#label-Table+identification">¶</a> <a href="#top">↑</a></span></h4>
|
|
233
|
+
|
|
234
|
+
<pre>worksheet = workbook[0]
|
|
235
|
+
worksheet.get_table(["NAME", "AGE", "HEIGHT"]) # Returns hash of a table in the first worksheet, with the specified strings as headers, accessible by row and column
|
|
236
|
+
#it returns the following structure
|
|
230
237
|
{
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
{
|
|
236
|
-
{
|
|
237
|
-
{
|
|
238
|
+
:Name=>["John", "Jane", "Joe"],
|
|
239
|
+
:Height=>[70, 65, 68],
|
|
240
|
+
:Age=>[30, 25, 35]
|
|
241
|
+
:table=>[
|
|
242
|
+
{:Name=>"John", :Height=>70, :Age=>30},
|
|
243
|
+
{:Name=>"Jane", :Height=>65, :Age=>25},
|
|
244
|
+
{:Name=>"Joe", :Height=>68, :Age=>35}
|
|
238
245
|
]
|
|
239
|
-
}
|
|
240
|
-
</pre>
|
|
246
|
+
}</pre>
|
|
241
247
|
|
|
242
|
-
<h3 id="label-Modifying">Modifying<span><a href="#label-Modifying">¶</a> <a href="#
|
|
248
|
+
<h3 id="label-Modifying">Modifying<span><a href="#label-Modifying">¶</a> <a href="#top">↑</a></span></h3>
|
|
243
249
|
|
|
244
|
-
<h4 id="label-Adding+Worksheets">Adding Worksheets<span><a href="#label-Adding+Worksheets">¶</a> <a href="#
|
|
250
|
+
<h4 id="label-Adding+Worksheets">Adding Worksheets<span><a href="#label-Adding+Worksheets">¶</a> <a href="#top">↑</a></span></h4>
|
|
245
251
|
|
|
246
|
-
<pre>worksheet = workbook
|
|
252
|
+
<pre class="ruby"><span class="ruby-identifier">worksheet</span> = <span class="ruby-identifier">workbook</span>.<span class="ruby-identifier">add_worksheet</span>(<span class="ruby-string">'Sheet2'</span>)
|
|
253
|
+
</pre>
|
|
247
254
|
|
|
248
|
-
<h4 id="label-Renaming+Worksheets">Renaming Worksheets<span><a href="#label-Renaming+Worksheets">¶</a> <a href="#
|
|
255
|
+
<h4 id="label-Renaming+Worksheets">Renaming Worksheets<span><a href="#label-Renaming+Worksheets">¶</a> <a href="#top">↑</a></span></h4>
|
|
249
256
|
|
|
250
|
-
<pre>worksheet
|
|
257
|
+
<pre class="ruby"><span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">sheet_name</span> = <span class="ruby-string">'Cool New Name'</span>
|
|
258
|
+
</pre>
|
|
251
259
|
|
|
252
|
-
<h4 id="label-Adding+Cells">Adding Cells<span><a href="#label-Adding+Cells">¶</a> <a href="#
|
|
260
|
+
<h4 id="label-Adding+Cells">Adding Cells<span><a href="#label-Adding+Cells">¶</a> <a href="#top">↑</a></span></h4>
|
|
253
261
|
|
|
254
|
-
<pre>worksheet
|
|
255
|
-
worksheet
|
|
262
|
+
<pre class="ruby"><span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">add_cell</span>(<span class="ruby-value">0</span>, <span class="ruby-value">0</span>, <span class="ruby-string">'A1'</span>) <span class="ruby-comment"># Sets cell A1 to string "A1"</span>
|
|
263
|
+
<span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">add_cell</span>(<span class="ruby-value">0</span>, <span class="ruby-value">1</span>, <span class="ruby-string">''</span>, <span class="ruby-string">'A1'</span>) <span class="ruby-comment"># Sets formula in the cell B1 to '=A1'</span>
|
|
264
|
+
</pre>
|
|
256
265
|
|
|
257
|
-
<h4 id="label-Changing+Cells">Changing Cells<span><a href="#label-Changing+Cells">¶</a> <a href="#
|
|
266
|
+
<h4 id="label-Changing+Cells">Changing Cells<span><a href="#label-Changing+Cells">¶</a> <a href="#top">↑</a></span></h4>
|
|
258
267
|
|
|
259
|
-
<pre>worksheet[0][0]
|
|
268
|
+
<pre class="ruby"><span class="ruby-identifier">worksheet</span>[<span class="ruby-value">0</span>][<span class="ruby-value">0</span>].<span class="ruby-identifier">change_contents</span>(<span class="ruby-string">""</span>, <span class="ruby-identifier">worksheet</span>[<span class="ruby-value">0</span>][<span class="ruby-value">0</span>].<span class="ruby-identifier">formula</span>) <span class="ruby-comment"># Sets value of cell A1 to empty string, preserves formula</span>
|
|
269
|
+
</pre>
|
|
260
270
|
|
|
261
|
-
<h4 id="label-Changing+Fonts">Changing Fonts<span><a href="#label-Changing+Fonts">¶</a> <a href="#
|
|
271
|
+
<h4 id="label-Changing+Fonts">Changing Fonts<span><a href="#label-Changing+Fonts">¶</a> <a href="#top">↑</a></span></h4>
|
|
262
272
|
|
|
263
|
-
<pre>worksheet
|
|
264
|
-
worksheet
|
|
265
|
-
worksheet
|
|
273
|
+
<pre class="ruby"><span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">sheet_data</span>[<span class="ruby-value">0</span>][<span class="ruby-value">0</span>].<span class="ruby-identifier">change_font_bold</span>(<span class="ruby-keyword">true</span>) <span class="ruby-comment"># Makes A1 bold</span>
|
|
274
|
+
<span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">change_row_italics</span>(<span class="ruby-value">0</span>,<span class="ruby-keyword">true</span>) <span class="ruby-comment"># Makes first row italicized</span>
|
|
275
|
+
<span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">change_column_font_name</span>(<span class="ruby-value">0</span>, <span class="ruby-string">'Courier'</span>) <span class="ruby-comment"># Makes first column have font Courier</span>
|
|
276
|
+
</pre>
|
|
266
277
|
|
|
267
|
-
<h4 id="label-Changing+Fills+++++">Changing Fills <span><a href="#label-Changing+Fills+++++">¶</a> <a href="#
|
|
278
|
+
<h4 id="label-Changing+Fills+++++">Changing Fills <span><a href="#label-Changing+Fills+++++">¶</a> <a href="#top">↑</a></span></h4>
|
|
268
279
|
|
|
269
|
-
<pre>worksheet
|
|
270
|
-
worksheet
|
|
271
|
-
worksheet
|
|
280
|
+
<pre class="ruby"><span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">sheet_data</span>[<span class="ruby-value">0</span>][<span class="ruby-value">0</span>].<span class="ruby-identifier">change_fill</span>(<span class="ruby-string">'0ba53d'</span>) <span class="ruby-comment"># Sets A1 to have fill #0ba53d</span>
|
|
281
|
+
<span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">change_row_fill</span>(<span class="ruby-value">0</span>, <span class="ruby-string">'0ba53d'</span>) <span class="ruby-comment"># Sets first row to have fill #0ba53d</span>
|
|
282
|
+
<span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">change_column_fill</span>(<span class="ruby-value">0</span>, <span class="ruby-string">'0ba53d'</span>) <span class="ruby-comment"># Sets first column to have fill #0ba53d</span>
|
|
283
|
+
</pre>
|
|
272
284
|
|
|
273
|
-
<h4 id="label-Changing+Borders">Changing Borders<span><a href="#label-Changing+Borders">¶</a> <a href="#
|
|
285
|
+
<h4 id="label-Changing+Borders">Changing Borders<span><a href="#label-Changing+Borders">¶</a> <a href="#top">↑</a></span></h4>
|
|
274
286
|
|
|
275
|
-
<pre># Possible weights: hairline, thin, medium, thick
|
|
276
|
-
|
|
277
|
-
worksheet
|
|
278
|
-
worksheet
|
|
279
|
-
worksheet
|
|
287
|
+
<pre class="ruby"><span class="ruby-comment"># Possible weights: hairline, thin, medium, thick</span>
|
|
288
|
+
<span class="ruby-comment"># Possible "directions": top, bottom, left, right, diagonal</span>
|
|
289
|
+
<span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">sheet_data</span>[<span class="ruby-value">0</span>][<span class="ruby-value">0</span>].<span class="ruby-identifier">change_border</span>(:<span class="ruby-identifier">top</span>, <span class="ruby-string">'thin'</span>) <span class="ruby-comment"># Sets A1 to have a top, thin border</span>
|
|
290
|
+
<span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">change_row_border</span>(<span class="ruby-value">0</span>, :<span class="ruby-identifier">left</span>, <span class="ruby-string">'hairline'</span>) <span class="ruby-comment"># Sets first row to have a left, hairline border</span>
|
|
291
|
+
<span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">change_column_border</span>(<span class="ruby-value">0</span>, :<span class="ruby-identifier">diagonal</span>, <span class="ruby-string">'medium'</span>) <span class="ruby-comment"># Sets first column to have diagonal, medium border</span>
|
|
292
|
+
</pre>
|
|
280
293
|
|
|
281
|
-
<h4 id="label-Changing+Alignment">Changing Alignment<span><a href="#label-Changing+Alignment">¶</a> <a href="#
|
|
294
|
+
<h4 id="label-Changing+Alignment">Changing Alignment<span><a href="#label-Changing+Alignment">¶</a> <a href="#top">↑</a></span></h4>
|
|
282
295
|
|
|
283
|
-
<h5 id="label-Horizontal">Horizontal<span><a href="#label-Horizontal">¶</a> <a href="#
|
|
296
|
+
<h5 id="label-Horizontal">Horizontal<span><a href="#label-Horizontal">¶</a> <a href="#top">↑</a></span></h5>
|
|
284
297
|
|
|
285
298
|
<p>center, distributed, justify, left, right</p>
|
|
286
299
|
|
|
287
|
-
<pre>worksheet
|
|
288
|
-
worksheet
|
|
289
|
-
worksheet
|
|
300
|
+
<pre class="ruby"><span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">sheet_data</span>[<span class="ruby-value">0</span>][<span class="ruby-value">0</span>].<span class="ruby-identifier">change_horizontal_alignment</span>(<span class="ruby-string">'center'</span>) <span class="ruby-comment"># Sets A1 to be centered</span>
|
|
301
|
+
<span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">change_row_horizontal_alignment</span>(<span class="ruby-value">0</span>, <span class="ruby-string">'justify'</span>) <span class="ruby-comment"># Sets first row to be justified</span>
|
|
302
|
+
<span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">change_column_horizontal_alignment</span>(<span class="ruby-value">0</span>, <span class="ruby-string">'right'</span>) <span class="ruby-comment"># Sets first column to be right-aligned</span>
|
|
303
|
+
</pre>
|
|
290
304
|
|
|
291
|
-
<h5 id="label-Vertical">Vertical<span><a href="#label-Vertical">¶</a> <a href="#
|
|
305
|
+
<h5 id="label-Vertical">Vertical<span><a href="#label-Vertical">¶</a> <a href="#top">↑</a></span></h5>
|
|
292
306
|
|
|
293
307
|
<p>bottom, center, distributed, top</p>
|
|
294
308
|
|
|
295
|
-
<pre>worksheet
|
|
296
|
-
worksheet
|
|
297
|
-
worksheet
|
|
309
|
+
<pre class="ruby"><span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">sheet_data</span>[<span class="ruby-value">0</span>][<span class="ruby-value">0</span>].<span class="ruby-identifier">change_vertical_alignment</span>(<span class="ruby-string">'bottom'</span>) <span class="ruby-comment"># Sets A1 to be bottom aligned</span>
|
|
310
|
+
<span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">change_row_vertical_alignment</span>(<span class="ruby-value">0</span>, <span class="ruby-string">'distributed'</span>) <span class="ruby-comment"># Sets first row to be distributed vertically</span>
|
|
311
|
+
<span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">change_column_vertical_alignment</span>(<span class="ruby-value">0</span>, <span class="ruby-string">'top'</span>) <span class="ruby-comment"># Sets first column to be top aligned</span>
|
|
312
|
+
</pre>
|
|
298
313
|
|
|
299
|
-
<h4 id="label-Changing+Row+Height">Changing Row Height<span><a href="#label-Changing+Row+Height">¶</a> <a href="#
|
|
314
|
+
<h4 id="label-Changing+Row+Height">Changing Row Height<span><a href="#label-Changing+Row+Height">¶</a> <a href="#top">↑</a></span></h4>
|
|
300
315
|
|
|
301
|
-
<pre>worksheet
|
|
316
|
+
<pre class="ruby"><span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">change_row_height</span>(<span class="ruby-value">0</span>, <span class="ruby-value">30</span>) <span class="ruby-comment"># Sets first row height to 30</span>
|
|
317
|
+
</pre>
|
|
302
318
|
|
|
303
|
-
<h4 id="label-Changing+Column+Width">Changing Column Width<span><a href="#label-Changing+Column+Width">¶</a> <a href="#
|
|
319
|
+
<h4 id="label-Changing+Column+Width">Changing Column Width<span><a href="#label-Changing+Column+Width">¶</a> <a href="#top">↑</a></span></h4>
|
|
304
320
|
|
|
305
|
-
<pre>worksheet
|
|
321
|
+
<pre class="ruby"><span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">change_column_width</span>(<span class="ruby-value">0</span>, <span class="ruby-value">30</span>) <span class="ruby-comment"># Sets first column width to 30</span>
|
|
322
|
+
</pre>
|
|
306
323
|
|
|
307
|
-
<h4 id="label-Merging+Cells">Merging Cells<span><a href="#label-Merging+Cells">¶</a> <a href="#
|
|
324
|
+
<h4 id="label-Merging+Cells">Merging Cells<span><a href="#label-Merging+Cells">¶</a> <a href="#top">↑</a></span></h4>
|
|
308
325
|
|
|
309
|
-
<pre>worksheet
|
|
326
|
+
<pre class="ruby"><span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">merge_cells</span>(<span class="ruby-value">0</span>, <span class="ruby-value">0</span>, <span class="ruby-value">1</span>, <span class="ruby-value">1</span>) <span class="ruby-comment"># Merges A1:B2</span>
|
|
327
|
+
</pre>
|
|
310
328
|
|
|
311
|
-
<h4 id="label-Insert+Row">Insert Row<span><a href="#label-Insert+Row">¶</a> <a href="#
|
|
329
|
+
<h4 id="label-Insert+Row">Insert Row<span><a href="#label-Insert+Row">¶</a> <a href="#top">↑</a></span></h4>
|
|
312
330
|
|
|
313
331
|
<p>This method will insert a row at specified index, pushing all rows below it
|
|
314
332
|
down. It also copies styles from row above.</p>
|
|
@@ -316,9 +334,10 @@ down. It also copies styles from row above.</p>
|
|
|
316
334
|
<p>WARNING: Use of this method WILL break formulas referencing cells which
|
|
317
335
|
have been moved, as the formulas do not adapt to the shifted rows</p>
|
|
318
336
|
|
|
319
|
-
<pre>worksheet
|
|
337
|
+
<pre class="ruby"><span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">insert_row</span>(<span class="ruby-value">1</span>)
|
|
338
|
+
</pre>
|
|
320
339
|
|
|
321
|
-
<h4 id="label-Insert+Column">Insert Column<span><a href="#label-Insert+Column">¶</a> <a href="#
|
|
340
|
+
<h4 id="label-Insert+Column">Insert Column<span><a href="#label-Insert+Column">¶</a> <a href="#top">↑</a></span></h4>
|
|
322
341
|
|
|
323
342
|
<p>This method will insert a column at specified index, pushing all columns to
|
|
324
343
|
the right of it one to the right. It also copies styles from column to the
|
|
@@ -327,9 +346,10 @@ left</p>
|
|
|
327
346
|
<p>WARNING: Use of this method WILL break formulas referencing cells which
|
|
328
347
|
have been moved, as the formulas do not adapt to the shifted columns</p>
|
|
329
348
|
|
|
330
|
-
<pre>worksheet
|
|
349
|
+
<pre class="ruby"><span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">insert_column</span>(<span class="ruby-value">1</span>)
|
|
350
|
+
</pre>
|
|
331
351
|
|
|
332
|
-
<h4 id="label-Delete+Row">Delete Row<span><a href="#label-Delete+Row">¶</a> <a href="#
|
|
352
|
+
<h4 id="label-Delete+Row">Delete Row<span><a href="#label-Delete+Row">¶</a> <a href="#top">↑</a></span></h4>
|
|
333
353
|
|
|
334
354
|
<p>This method will delete a row at specified index, pushing all rows below it
|
|
335
355
|
up.</p>
|
|
@@ -337,9 +357,10 @@ up.</p>
|
|
|
337
357
|
<p>WARNING: Use of this method WILL break formulas referencing cells which
|
|
338
358
|
have been moved, as the formulas do not adapt to the shifted rows</p>
|
|
339
359
|
|
|
340
|
-
<pre>worksheet
|
|
360
|
+
<pre class="ruby"><span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">delete_row</span>(<span class="ruby-value">1</span>)
|
|
361
|
+
</pre>
|
|
341
362
|
|
|
342
|
-
<h4 id="label-Delete+Column">Delete Column<span><a href="#label-Delete+Column">¶</a> <a href="#
|
|
363
|
+
<h4 id="label-Delete+Column">Delete Column<span><a href="#label-Delete+Column">¶</a> <a href="#top">↑</a></span></h4>
|
|
343
364
|
|
|
344
365
|
<p>This method will delete a column at specified index, pushing all columns to
|
|
345
366
|
the right of it left.</p>
|
|
@@ -347,9 +368,10 @@ the right of it left.</p>
|
|
|
347
368
|
<p>WARNING: Use of this method WILL break formulas referencing cells which
|
|
348
369
|
have been moved, as the formulas do not adapt to the shifted columns</p>
|
|
349
370
|
|
|
350
|
-
<pre>worksheet
|
|
371
|
+
<pre class="ruby"><span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">delete_column</span>(<span class="ruby-value">1</span>)
|
|
372
|
+
</pre>
|
|
351
373
|
|
|
352
|
-
<h4 id="label-Insert+Cell">Insert Cell<span><a href="#label-Insert+Cell">¶</a> <a href="#
|
|
374
|
+
<h4 id="label-Insert+Cell">Insert Cell<span><a href="#label-Insert+Cell">¶</a> <a href="#top">↑</a></span></h4>
|
|
353
375
|
|
|
354
376
|
<p>This method will insert a cell at specified position. It takes a :right or
|
|
355
377
|
:down option, to shift cells either left or down upon inserting (nil means
|
|
@@ -358,11 +380,12 @@ replacing the cell)</p>
|
|
|
358
380
|
<p>WARNING: Use of this method WILL break formulas referencing cells which
|
|
359
381
|
have been moved, as the formulas do not adapt to the shifted cells</p>
|
|
360
382
|
|
|
361
|
-
<pre>worksheet
|
|
362
|
-
worksheet
|
|
363
|
-
worksheet
|
|
383
|
+
<pre class="ruby"><span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">insert_cell</span>(<span class="ruby-value">0</span>, <span class="ruby-value">0</span>, <span class="ruby-string">"blah"</span>, <span class="ruby-identifier">formula</span> = <span class="ruby-keyword">nil</span>, :<span class="ruby-identifier">right</span>) <span class="ruby-comment"># Inserts cell at A1, shifts cells in first row right</span>
|
|
384
|
+
<span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">insert_cell</span>(<span class="ruby-value">0</span>, <span class="ruby-value">0</span>, <span class="ruby-string">"blah"</span>, <span class="ruby-identifier">formula</span> = <span class="ruby-keyword">nil</span>, :<span class="ruby-identifier">down</span>) <span class="ruby-comment"># Inserts cell at A1, shifts cells in first column down</span>
|
|
385
|
+
<span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">insert_cell</span>(<span class="ruby-value">0</span>, <span class="ruby-value">0</span>, <span class="ruby-string">"blah"</span>) <span class="ruby-comment"># Inserts cell at A1, shifts nothing</span>
|
|
386
|
+
</pre>
|
|
364
387
|
|
|
365
|
-
<h4 id="label-Delete+Cell">Delete Cell<span><a href="#label-Delete+Cell">¶</a> <a href="#
|
|
388
|
+
<h4 id="label-Delete+Cell">Delete Cell<span><a href="#label-Delete+Cell">¶</a> <a href="#top">↑</a></span></h4>
|
|
366
389
|
|
|
367
390
|
<p>This method will delete a cell at specified position. It takes a :left or
|
|
368
391
|
:up option, to shift cells either up or left upon deletion (nil means
|
|
@@ -371,34 +394,38 @@ simply deleting the cell contents)</p>
|
|
|
371
394
|
<p>WARNING: Use of this method WILL break formulas referencing cells which
|
|
372
395
|
have been moved, as the formulas do not adapt to the shifted cells</p>
|
|
373
396
|
|
|
374
|
-
<pre>worksheet
|
|
375
|
-
worksheet
|
|
376
|
-
worksheet
|
|
397
|
+
<pre class="ruby"><span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">delete_cell</span>(<span class="ruby-value">0</span>, <span class="ruby-value">0</span>, :<span class="ruby-identifier">left</span>) <span class="ruby-comment"># Deletes A1, shifts contents of first row left</span>
|
|
398
|
+
<span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">delete_cell</span>(<span class="ruby-value">0</span>, <span class="ruby-value">0</span>, :<span class="ruby-identifier">up</span>) <span class="ruby-comment"># Deletes A1, shifts contents of first column up</span>
|
|
399
|
+
<span class="ruby-identifier">worksheet</span>.<span class="ruby-identifier">delete_cell</span>(<span class="ruby-value">0</span>, <span class="ruby-value">0</span>) <span class="ruby-comment"># Deletes A1, does not shift cells</span>
|
|
400
|
+
</pre>
|
|
377
401
|
|
|
378
|
-
<h2 id="label-I
|
|
402
|
+
<h2 id="label-I-2FO">I/O<span><a href="#label-I-2FO">¶</a> <a href="#top">↑</a></span></h2>
|
|
379
403
|
|
|
380
|
-
<h3 id="label-Writing">Writing<span><a href="#label-Writing">¶</a> <a href="#
|
|
404
|
+
<h3 id="label-Writing">Writing<span><a href="#label-Writing">¶</a> <a href="#top">↑</a></span></h3>
|
|
381
405
|
|
|
382
|
-
<pre>workbook
|
|
406
|
+
<pre class="ruby"><span class="ruby-identifier">workbook</span>.<span class="ruby-identifier">write</span>(<span class="ruby-string">"path/to/desired/Excel/file.xlsx"</span>)
|
|
407
|
+
</pre>
|
|
383
408
|
|
|
384
|
-
<h3 id="label-Streaming">Streaming<span><a href="#label-Streaming">¶</a> <a href="#
|
|
409
|
+
<h3 id="label-Streaming">Streaming<span><a href="#label-Streaming">¶</a> <a href="#top">↑</a></span></h3>
|
|
385
410
|
|
|
386
411
|
<p>The gem can provide <code>StringIO</code> object containing the resulting
|
|
387
412
|
<code>xlsx</code> file, eliminating the need to save it to disk first. This
|
|
388
413
|
capability comes in handy for web servers.</p>
|
|
389
414
|
|
|
390
|
-
<pre>workbook
|
|
415
|
+
<pre class="ruby"><span class="ruby-identifier">workbook</span>.<span class="ruby-identifier">stream</span>
|
|
416
|
+
</pre>
|
|
391
417
|
|
|
392
|
-
<h2 id="label-Miscellaneous">Miscellaneous<span><a href="#label-Miscellaneous">¶</a> <a href="#
|
|
418
|
+
<h2 id="label-Miscellaneous">Miscellaneous<span><a href="#label-Miscellaneous">¶</a> <a href="#top">↑</a></span></h2>
|
|
393
419
|
|
|
394
|
-
<pre>Reference
|
|
395
|
-
Reference
|
|
420
|
+
<pre class="ruby"><span class="ruby-constant">Reference</span>.<span class="ruby-identifier">ind2ref</span>(<span class="ruby-value">0</span>,<span class="ruby-value">0</span>) <span class="ruby-operator">==</span> <span class="ruby-string">'A1'</span> <span class="ruby-comment"># Converts row and column index to Excel-style cell reference</span>
|
|
421
|
+
<span class="ruby-constant">Reference</span>.<span class="ruby-identifier">ref2ind</span>(<span class="ruby-string">'A1'</span>) <span class="ruby-operator">==</span> [<span class="ruby-value">0</span>, <span class="ruby-value">0</span>] <span class="ruby-comment"># Converts Excel-style cell reference to row and column index</span>
|
|
422
|
+
</pre>
|
|
396
423
|
|
|
397
|
-
<h2 id="label-For+more+information">For more information<span><a href="#label-For+more+information">¶</a> <a href="#
|
|
424
|
+
<h2 id="label-For+more+information">For more information<span><a href="#label-For+more+information">¶</a> <a href="#top">↑</a></span></h2>
|
|
398
425
|
|
|
399
426
|
<p>Take a look at the files in spec/lib/ for rspecs on most methods</p>
|
|
400
427
|
|
|
401
|
-
<h2 id="label-Contributing+to+rubyXL">Contributing to rubyXL<span><a href="#label-Contributing+to+rubyXL">¶</a> <a href="#
|
|
428
|
+
<h2 id="label-Contributing+to+rubyXL">Contributing to rubyXL<span><a href="#label-Contributing+to+rubyXL">¶</a> <a href="#top">↑</a></span></h2>
|
|
402
429
|
<ul><li>
|
|
403
430
|
<p>Check out the latest master to make sure the feature hasn't been
|
|
404
431
|
implemented or the bug hasn't been fixed yet</p>
|
|
@@ -420,7 +447,7 @@ to have your own version, or is otherwise necessary, that is fine, but
|
|
|
420
447
|
please isolate to its own commit so I can cherry-pick around it.</p>
|
|
421
448
|
</li></ul>
|
|
422
449
|
|
|
423
|
-
<h2 id="label-Copyright">Copyright<span><a href="#label-Copyright">¶</a> <a href="#
|
|
450
|
+
<h2 id="label-Copyright">Copyright<span><a href="#label-Copyright">¶</a> <a href="#top">↑</a></span></h2>
|
|
424
451
|
|
|
425
452
|
<p>Copyright © 2011 Vivek Bhagwat, 2013-2014 Wesha. See LICENSE.txt for
|
|
426
453
|
further details.</p>
|
|
@@ -430,7 +457,7 @@ further details.</p>
|
|
|
430
457
|
|
|
431
458
|
<footer id="validator-badges" role="contentinfo">
|
|
432
459
|
<p><a href="http://validator.w3.org/check/referer">Validate</a>
|
|
433
|
-
<p>Generated by <a href="http://
|
|
434
|
-
<p>Based on <a href="http://deveiate.org/projects/Darkfish-
|
|
460
|
+
<p>Generated by <a href="http://docs.seattlerb.org/rdoc/">RDoc</a> 4.2.0.
|
|
461
|
+
<p>Based on <a href="http://deveiate.org/projects/Darkfish-RDoc/">Darkfish</a> by <a href="http://deveiate.org">Michael Granger</a>.
|
|
435
462
|
</footer>
|
|
436
463
|
|