rubyXL 3.2.7 → 3.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/Gemfile +2 -0
- data/Rakefile +28 -2
- data/VERSION +1 -1
- data/lib/rubyXL/cell.rb +0 -5
- data/lib/rubyXL/convenience_methods.rb +30 -52
- data/lib/rubyXL/objects/ooxml_object.rb +2 -0
- data/lib/rubyXL/objects/root.rb +16 -2
- data/lib/rubyXL/parser.rb +3 -32
- data/lib/rubyXL/worksheet.rb +29 -91
- data/rdoc/README_rdoc.html +1 -1
- data/rdoc/RubyXL.html +1 -1
- data/rdoc/RubyXL/AExtension.html +1 -1
- data/rdoc/RubyXL/AExtensionStorageArea.html +1 -1
- data/rdoc/RubyXL/AdjustHandleList.html +1 -1
- data/rdoc/RubyXL/Alignment.html +1 -1
- data/rdoc/RubyXL/AlternateContent.html +1 -1
- data/rdoc/RubyXL/Authors.html +1 -1
- data/rdoc/RubyXL/AutoFilter.html +1 -1
- data/rdoc/RubyXL/AutoFilterColumn.html +1 -1
- data/rdoc/RubyXL/BinaryImageFile.html +1 -1
- data/rdoc/RubyXL/BodyProperties.html +1 -1
- data/rdoc/RubyXL/BooleanNode.html +1 -1
- data/rdoc/RubyXL/BooleanValue.html +1 -1
- data/rdoc/RubyXL/Border.html +1 -1
- data/rdoc/RubyXL/BorderEdge.html +1 -1
- data/rdoc/RubyXL/Borders.html +1 -1
- data/rdoc/RubyXL/Break.html +1 -1
- data/rdoc/RubyXL/BreakList.html +1 -1
- data/rdoc/RubyXL/CT_AdjPoint2D.html +1 -1
- data/rdoc/RubyXL/CT_AlphaBiLevelEffect.html +1 -1
- data/rdoc/RubyXL/CT_AlphaModulateEffect.html +1 -1
- data/rdoc/RubyXL/CT_AlphaModulateFixedEffect.html +1 -1
- data/rdoc/RubyXL/CT_AlphaOutsetEffect.html +1 -1
- data/rdoc/RubyXL/CT_AlphaReplaceEffect.html +1 -1
- data/rdoc/RubyXL/CT_Backdrop.html +1 -1
- data/rdoc/RubyXL/CT_Bevel.html +1 -1
- data/rdoc/RubyXL/CT_BiLevelEffect.html +1 -1
- data/rdoc/RubyXL/CT_BlendEffect.html +1 -1
- data/rdoc/RubyXL/CT_Blip.html +1 -1
- data/rdoc/RubyXL/CT_BlipFillProperties.html +1 -1
- data/rdoc/RubyXL/CT_BlurEffect.html +1 -1
- data/rdoc/RubyXL/CT_Camera.html +1 -1
- data/rdoc/RubyXL/CT_Color.html +1 -1
- data/rdoc/RubyXL/CT_ColorChangeEffect.html +1 -1
- data/rdoc/RubyXL/CT_ColorMapping.html +1 -1
- data/rdoc/RubyXL/CT_ColorScheme.html +1 -1
- data/rdoc/RubyXL/CT_ColorSchemeAndMapping.html +1 -1
- data/rdoc/RubyXL/CT_ConnectionSite.html +1 -1
- data/rdoc/RubyXL/CT_ConnectionSiteList.html +1 -1
- data/rdoc/RubyXL/CT_DashStop.html +1 -1
- data/rdoc/RubyXL/CT_DashStopList.html +1 -1
- data/rdoc/RubyXL/CT_DefaultShapeDefinition.html +1 -1
- data/rdoc/RubyXL/CT_DuotoneEffect.html +1 -1
- data/rdoc/RubyXL/CT_EffectContainer.html +1 -1
- data/rdoc/RubyXL/CT_EffectList.html +1 -1
- data/rdoc/RubyXL/CT_EffectReference.html +1 -1
- data/rdoc/RubyXL/CT_EffectStyleItem.html +1 -1
- data/rdoc/RubyXL/CT_EffectStyleList.html +1 -1
- data/rdoc/RubyXL/CT_EmbeddedWAVAudioFile.html +1 -1
- data/rdoc/RubyXL/CT_FillEffect.html +1 -1
- data/rdoc/RubyXL/CT_FillOverlayEffect.html +1 -1
- data/rdoc/RubyXL/CT_FillStyleList.html +1 -1
- data/rdoc/RubyXL/CT_FlatText.html +1 -1
- data/rdoc/RubyXL/CT_FontCollection.html +1 -1
- data/rdoc/RubyXL/CT_FontReference.html +1 -1
- data/rdoc/RubyXL/CT_GeomGuideList.html +1 -1
- data/rdoc/RubyXL/CT_GlowEffect.html +1 -1
- data/rdoc/RubyXL/CT_GradientFillProperties.html +1 -1
- data/rdoc/RubyXL/CT_GradientStop.html +1 -1
- data/rdoc/RubyXL/CT_GradientStopList.html +1 -1
- data/rdoc/RubyXL/CT_HSLEffect.html +1 -1
- data/rdoc/RubyXL/CT_HslColor.html +1 -1
- data/rdoc/RubyXL/CT_Hyperlink.html +1 -1
- data/rdoc/RubyXL/CT_InnerShadowEffect.html +1 -1
- data/rdoc/RubyXL/CT_LightRig.html +1 -1
- data/rdoc/RubyXL/CT_LineEndProperties.html +1 -1
- data/rdoc/RubyXL/CT_LineJoinMiterProperties.html +1 -1
- data/rdoc/RubyXL/CT_LineProperties.html +1 -1
- data/rdoc/RubyXL/CT_LineStyleList.html +1 -1
- data/rdoc/RubyXL/CT_LinearShadeProperties.html +1 -1
- data/rdoc/RubyXL/CT_LuminanceEffect.html +1 -1
- data/rdoc/RubyXL/CT_ObjectStyleDefaults.html +1 -1
- data/rdoc/RubyXL/CT_OuterShadowEffect.html +1 -1
- data/rdoc/RubyXL/CT_Path2D.html +1 -1
- data/rdoc/RubyXL/CT_Path2DArcTo.html +1 -1
- data/rdoc/RubyXL/CT_Path2DCubicBezierTo.html +1 -1
- data/rdoc/RubyXL/CT_Path2DList.html +1 -1
- data/rdoc/RubyXL/CT_Path2DQuadBezierTo.html +1 -1
- data/rdoc/RubyXL/CT_Path2DTo.html +1 -1
- data/rdoc/RubyXL/CT_PathShadeProperties.html +1 -1
- data/rdoc/RubyXL/CT_PatternFillProperties.html +1 -1
- data/rdoc/RubyXL/CT_Point3D.html +1 -1
- data/rdoc/RubyXL/CT_PolarAdjustHandle.html +1 -1
- data/rdoc/RubyXL/CT_PresetColor.html +1 -1
- data/rdoc/RubyXL/CT_PresetLineDashProperties.html +1 -1
- data/rdoc/RubyXL/CT_PresetShadowEffect.html +1 -1
- data/rdoc/RubyXL/CT_PresetTextShape.html +1 -1
- data/rdoc/RubyXL/CT_ReflectionEffect.html +1 -1
- data/rdoc/RubyXL/CT_RelativeOffsetEffect.html +1 -1
- data/rdoc/RubyXL/CT_RelativeRect.html +1 -1
- data/rdoc/RubyXL/CT_SRgbColor.html +1 -1
- data/rdoc/RubyXL/CT_ScRgbColor.html +1 -1
- data/rdoc/RubyXL/CT_Scene3D.html +1 -1
- data/rdoc/RubyXL/CT_SchemeColor.html +1 -1
- data/rdoc/RubyXL/CT_Shape3D.html +1 -1
- data/rdoc/RubyXL/CT_ShapeStyle.html +1 -1
- data/rdoc/RubyXL/CT_SoftEdgesEffect.html +1 -1
- data/rdoc/RubyXL/CT_SphereCoords.html +1 -1
- data/rdoc/RubyXL/CT_StretchInfoProperties.html +1 -1
- data/rdoc/RubyXL/CT_StyleMatrix.html +1 -1
- data/rdoc/RubyXL/CT_StyleMatrixReference.html +1 -1
- data/rdoc/RubyXL/CT_SupplementalFont.html +1 -1
- data/rdoc/RubyXL/CT_SystemColor.html +1 -1
- data/rdoc/RubyXL/CT_TextAutonumberBullet.html +1 -1
- data/rdoc/RubyXL/CT_TextBlipBullet.html +1 -1
- data/rdoc/RubyXL/CT_TextCharBullet.html +1 -1
- data/rdoc/RubyXL/CT_TextCharacterProperties.html +1 -1
- data/rdoc/RubyXL/CT_TextFont.html +1 -1
- data/rdoc/RubyXL/CT_TextListStyle.html +1 -1
- data/rdoc/RubyXL/CT_TextNormalAutofit.html +1 -1
- data/rdoc/RubyXL/CT_TextParagraphProperties.html +1 -1
- data/rdoc/RubyXL/CT_TextSpacing.html +1 -1
- data/rdoc/RubyXL/CT_TextTabStop.html +1 -1
- data/rdoc/RubyXL/CT_TextTabStopList.html +1 -1
- data/rdoc/RubyXL/CT_TileInfoProperties.html +1 -1
- data/rdoc/RubyXL/CT_TintEffect.html +1 -1
- data/rdoc/RubyXL/CT_Transform2D.html +1 -1
- data/rdoc/RubyXL/CT_TransformEffect.html +1 -1
- data/rdoc/RubyXL/CT_Vector3D.html +1 -1
- data/rdoc/RubyXL/CT_XYAdjustHandle.html +1 -1
- data/rdoc/RubyXL/CalculationChain.html +1 -1
- data/rdoc/RubyXL/CalculationChainCell.html +1 -1
- data/rdoc/RubyXL/CalculationProperties.html +1 -1
- data/rdoc/RubyXL/Cell.html +1 -1
- data/rdoc/RubyXL/CellConvenienceMethods.html +1 -1
- data/rdoc/RubyXL/CellSmartTag.html +1 -1
- data/rdoc/RubyXL/CellSmartTagProperty.html +1 -1
- data/rdoc/RubyXL/CellSmartTags.html +1 -1
- data/rdoc/RubyXL/CellStyle.html +1 -1
- data/rdoc/RubyXL/CellStyleXFs.html +1 -1
- data/rdoc/RubyXL/CellStyles.html +1 -1
- data/rdoc/RubyXL/CellValue.html +1 -1
- data/rdoc/RubyXL/CellWatch.html +1 -1
- data/rdoc/RubyXL/CellWatches.html +1 -1
- data/rdoc/RubyXL/CellXFs.html +1 -1
- data/rdoc/RubyXL/ChartColorsFile.html +1 -1
- data/rdoc/RubyXL/ChartFile.html +1 -1
- data/rdoc/RubyXL/ChartStyleFile.html +1 -1
- data/rdoc/RubyXL/ChartUserShapesFile.html +1 -1
- data/rdoc/RubyXL/Chartsheet.html +1 -1
- data/rdoc/RubyXL/ChartsheetPageSetup.html +1 -1
- data/rdoc/RubyXL/ChartsheetProperties.html +1 -1
- data/rdoc/RubyXL/ChartsheetProtection.html +1 -1
- data/rdoc/RubyXL/ChartsheetView.html +1 -1
- data/rdoc/RubyXL/ChartsheetViews.html +1 -1
- data/rdoc/RubyXL/Color.html +1 -1
- data/rdoc/RubyXL/ColorFilter.html +1 -1
- data/rdoc/RubyXL/ColorScale.html +1 -1
- data/rdoc/RubyXL/ColorSet.html +1 -1
- data/rdoc/RubyXL/Colors.html +1 -1
- data/rdoc/RubyXL/ColumnRange.html +1 -1
- data/rdoc/RubyXL/ColumnRanges.html +1 -1
- data/rdoc/RubyXL/Comment.html +1 -1
- data/rdoc/RubyXL/CommentList.html +1 -1
- data/rdoc/RubyXL/CommentsFile.html +1 -1
- data/rdoc/RubyXL/ConditionalFormatValue.html +1 -1
- data/rdoc/RubyXL/ConditionalFormatting.html +1 -1
- data/rdoc/RubyXL/ConditionalFormattingRule.html +1 -1
- data/rdoc/RubyXL/ContentTypeDefault.html +1 -1
- data/rdoc/RubyXL/ContentTypeOverride.html +1 -1
- data/rdoc/RubyXL/ContentTypes.html +1 -1
- data/rdoc/RubyXL/ControlPropertiesFile.html +1 -1
- data/rdoc/RubyXL/CorePropertiesFile.html +1 -1
- data/rdoc/RubyXL/CustomColor.html +1 -1
- data/rdoc/RubyXL/CustomColorList.html +1 -1
- data/rdoc/RubyXL/CustomFilter.html +1 -1
- data/rdoc/RubyXL/CustomFilters.html +1 -1
- data/rdoc/RubyXL/CustomGeometry.html +1 -1
- data/rdoc/RubyXL/CustomProperties.html +1 -1
- data/rdoc/RubyXL/CustomPropertiesFile.html +1 -1
- data/rdoc/RubyXL/CustomProperty.html +1 -1
- data/rdoc/RubyXL/CustomSheetView.html +1 -1
- data/rdoc/RubyXL/CustomSheetViews.html +1 -1
- data/rdoc/RubyXL/CustomWorkbookView.html +1 -1
- data/rdoc/RubyXL/CustomWorkbookViews.html +1 -1
- data/rdoc/RubyXL/CustomXMLFile.html +1 -1
- data/rdoc/RubyXL/DXF.html +1 -1
- data/rdoc/RubyXL/DXFs.html +1 -1
- data/rdoc/RubyXL/DataBar.html +1 -1
- data/rdoc/RubyXL/DataConsolidate.html +1 -1
- data/rdoc/RubyXL/DataConsolidationReference.html +1 -1
- data/rdoc/RubyXL/DataConsolidationReferences.html +1 -1
- data/rdoc/RubyXL/DataType.html +1 -1
- data/rdoc/RubyXL/DataValidation.html +1 -1
- data/rdoc/RubyXL/DataValidations.html +1 -1
- data/rdoc/RubyXL/DateGroupItem.html +1 -1
- data/rdoc/RubyXL/DefinedName.html +1 -1
- data/rdoc/RubyXL/DefinedNames.html +1 -1
- data/rdoc/RubyXL/DocumentPropertiesFile.html +1 -1
- data/rdoc/RubyXL/DrawingFile.html +1 -1
- data/rdoc/RubyXL/DynamicFilter.html +1 -1
- data/rdoc/RubyXL/EmbeddedControl.html +1 -1
- data/rdoc/RubyXL/EmbeddedControls.html +1 -1
- data/rdoc/RubyXL/Extension.html +1 -1
- data/rdoc/RubyXL/ExtensionStorageArea.html +1 -1
- data/rdoc/RubyXL/Extents.html +1 -1
- data/rdoc/RubyXL/ExternalLinksFile.html +1 -1
- data/rdoc/RubyXL/ExternalReference.html +1 -1
- data/rdoc/RubyXL/ExternalReferences.html +1 -1
- data/rdoc/RubyXL/ExtraColorSchemeList.html +1 -1
- data/rdoc/RubyXL/FieldItem.html +1 -1
- data/rdoc/RubyXL/FileRecoveryProperties.html +1 -1
- data/rdoc/RubyXL/FileSharing.html +1 -1
- data/rdoc/RubyXL/FileVersion.html +1 -1
- data/rdoc/RubyXL/Fill.html +1 -1
- data/rdoc/RubyXL/Fills.html +1 -1
- data/rdoc/RubyXL/FilterContainer.html +1 -1
- data/rdoc/RubyXL/FloatNode.html +1 -1
- data/rdoc/RubyXL/FloatValue.html +1 -1
- data/rdoc/RubyXL/Font.html +1 -1
- data/rdoc/RubyXL/FontScheme.html +1 -1
- data/rdoc/RubyXL/Fonts.html +1 -1
- data/rdoc/RubyXL/Formula.html +1 -1
- data/rdoc/RubyXL/FunctionGroup.html +1 -1
- data/rdoc/RubyXL/FunctionGroups.html +1 -1
- data/rdoc/RubyXL/GenericStorageObject.html +1 -1
- data/rdoc/RubyXL/GradientFill.html +1 -1
- data/rdoc/RubyXL/HeaderFooterSettings.html +1 -1
- data/rdoc/RubyXL/Hyperlink.html +1 -1
- data/rdoc/RubyXL/HyperlinkRelFile.html +1 -1
- data/rdoc/RubyXL/Hyperlinks.html +1 -1
- data/rdoc/RubyXL/IconFilter.html +1 -1
- data/rdoc/RubyXL/IconSet.html +1 -1
- data/rdoc/RubyXL/IgnoredError.html +1 -1
- data/rdoc/RubyXL/IgnoredErrors.html +1 -1
- data/rdoc/RubyXL/IndexedColors.html +1 -1
- data/rdoc/RubyXL/InputCells.html +1 -1
- data/rdoc/RubyXL/IntegerNode.html +1 -1
- data/rdoc/RubyXL/IntegerValue.html +1 -1
- data/rdoc/RubyXL/LegacyCell.html +1 -1
- data/rdoc/RubyXL/LegacyWorksheet.html +37 -37
- data/rdoc/RubyXL/MRUColors.html +1 -1
- data/rdoc/RubyXL/MacrosFile.html +1 -1
- data/rdoc/RubyXL/MergedCell.html +1 -1
- data/rdoc/RubyXL/MergedCells.html +1 -1
- data/rdoc/RubyXL/NumFmt.html +1 -1
- data/rdoc/RubyXL/NumberFormat.html +1 -1
- data/rdoc/RubyXL/NumberFormats.html +1 -1
- data/rdoc/RubyXL/OLEObject.html +1 -1
- data/rdoc/RubyXL/OLEObjects.html +1 -1
- data/rdoc/RubyXL/OLESize.html +1 -1
- data/rdoc/RubyXL/OOXMLContainerObject.html +1 -1
- data/rdoc/RubyXL/OOXMLObject.html +1 -1
- data/rdoc/RubyXL/OOXMLObjectClassMethods.html +6 -6
- data/rdoc/RubyXL/OOXMLObjectInstanceMethods.html +1 -1
- data/rdoc/RubyXL/OOXMLRelationshipsFile.html +1 -1
- data/rdoc/RubyXL/OOXMLTopLevelObject.html +1 -1
- data/rdoc/RubyXL/Offset.html +1 -1
- data/rdoc/RubyXL/OutlineProperties.html +1 -1
- data/rdoc/RubyXL/PageMargins.html +1 -1
- data/rdoc/RubyXL/PageSetup.html +1 -1
- data/rdoc/RubyXL/PageSetupProperties.html +1 -1
- data/rdoc/RubyXL/Pane.html +1 -1
- data/rdoc/RubyXL/Parser.html +5 -99
- data/rdoc/RubyXL/PatternFill.html +1 -1
- data/rdoc/RubyXL/PhoneticProperties.html +1 -1
- data/rdoc/RubyXL/PhoneticRun.html +1 -1
- data/rdoc/RubyXL/PivotArea.html +1 -1
- data/rdoc/RubyXL/PivotCache.html +1 -1
- data/rdoc/RubyXL/PivotCacheDefinitionFile.html +1 -1
- data/rdoc/RubyXL/PivotCaches.html +1 -1
- data/rdoc/RubyXL/PivotReference.html +1 -1
- data/rdoc/RubyXL/PivotReferences.html +1 -1
- data/rdoc/RubyXL/PivotTableFile.html +1 -1
- data/rdoc/RubyXL/PivotTableSelection.html +1 -1
- data/rdoc/RubyXL/PresetGeometry.html +1 -1
- data/rdoc/RubyXL/PrintOptions.html +1 -1
- data/rdoc/RubyXL/PrinterSettingsFile.html +1 -1
- data/rdoc/RubyXL/ProtectedRange.html +1 -1
- data/rdoc/RubyXL/ProtectedRanges.html +1 -1
- data/rdoc/RubyXL/Protection.html +1 -1
- data/rdoc/RubyXL/RID.html +1 -1
- data/rdoc/RubyXL/RawOOXML.html +1 -1
- data/rdoc/RubyXL/Reference.html +1 -1
- data/rdoc/RubyXL/Relationship.html +1 -1
- data/rdoc/RubyXL/RelationshipSupport.html +1 -1
- data/rdoc/RubyXL/RelationshipSupport/ClassMehods.html +1 -1
- data/rdoc/RubyXL/RichText.html +1 -1
- data/rdoc/RubyXL/RichTextRun.html +1 -1
- data/rdoc/RubyXL/Row.html +1 -1
- data/rdoc/RubyXL/RunProperties.html +1 -1
- data/rdoc/RubyXL/Scenario.html +1 -1
- data/rdoc/RubyXL/Scenarios.html +1 -1
- data/rdoc/RubyXL/Selection.html +1 -1
- data/rdoc/RubyXL/ShapeGuide.html +1 -1
- data/rdoc/RubyXL/ShapeTextRectangle.html +1 -1
- data/rdoc/RubyXL/SharedStringsTable.html +1 -1
- data/rdoc/RubyXL/Sheet.html +1 -1
- data/rdoc/RubyXL/SheetCalculationProperties.html +1 -1
- data/rdoc/RubyXL/SheetData.html +1 -1
- data/rdoc/RubyXL/Sheets.html +1 -1
- data/rdoc/RubyXL/SlicerCacheFile.html +1 -1
- data/rdoc/RubyXL/SlicerFile.html +1 -1
- data/rdoc/RubyXL/SmartTagProperties.html +1 -1
- data/rdoc/RubyXL/SmartTagType.html +1 -1
- data/rdoc/RubyXL/SmartTagTypes.html +1 -1
- data/rdoc/RubyXL/SmartTags.html +1 -1
- data/rdoc/RubyXL/SortCondition.html +1 -1
- data/rdoc/RubyXL/SortState.html +1 -1
- data/rdoc/RubyXL/Sqref.html +1 -1
- data/rdoc/RubyXL/Stop.html +1 -1
- data/rdoc/RubyXL/StringNode.html +1 -1
- data/rdoc/RubyXL/StringNodeW3C.html +1 -1
- data/rdoc/RubyXL/StringValue.html +1 -1
- data/rdoc/RubyXL/Stylesheet.html +1 -1
- data/rdoc/RubyXL/TableFile.html +1 -1
- data/rdoc/RubyXL/TableParts.html +1 -1
- data/rdoc/RubyXL/TableStyle.html +1 -1
- data/rdoc/RubyXL/TableStyles.html +1 -1
- data/rdoc/RubyXL/Text.html +1 -1
- data/rdoc/RubyXL/Theme.html +1 -1
- data/rdoc/RubyXL/ThemeElements.html +1 -1
- data/rdoc/RubyXL/ThumbnailFile.html +1 -1
- data/rdoc/RubyXL/Top10.html +1 -1
- data/rdoc/RubyXL/VMLDrawingFile.html +1 -1
- data/rdoc/RubyXL/Variant.html +1 -1
- data/rdoc/RubyXL/Vector.html +1 -1
- data/rdoc/RubyXL/VectorValue.html +1 -1
- data/rdoc/RubyXL/VisualProperties.html +1 -1
- data/rdoc/RubyXL/WebPublishObject.html +1 -1
- data/rdoc/RubyXL/WebPublishObjects.html +1 -1
- data/rdoc/RubyXL/WebPublishingItem.html +1 -1
- data/rdoc/RubyXL/WebPublishingItems.html +1 -1
- data/rdoc/RubyXL/WebPublishingProperties.html +1 -1
- data/rdoc/RubyXL/Workbook.html +1 -1
- data/rdoc/RubyXL/WorkbookConvenienceMethods.html +1 -1
- data/rdoc/RubyXL/WorkbookProperties.html +1 -1
- data/rdoc/RubyXL/WorkbookProtection.html +1 -1
- data/rdoc/RubyXL/WorkbookRoot.html +18 -4
- data/rdoc/RubyXL/WorkbookView.html +1 -1
- data/rdoc/RubyXL/WorkbookViews.html +1 -1
- data/rdoc/RubyXL/Worksheet.html +1 -1
- data/rdoc/RubyXL/WorksheetConvenienceMethods.html +1 -1
- data/rdoc/RubyXL/WorksheetDimensions.html +1 -1
- data/rdoc/RubyXL/WorksheetFormatProperties.html +1 -1
- data/rdoc/RubyXL/WorksheetProperties.html +1 -1
- data/rdoc/RubyXL/WorksheetProtection.html +1 -1
- data/rdoc/RubyXL/WorksheetView.html +1 -1
- data/rdoc/RubyXL/WorksheetViews.html +1 -1
- data/rdoc/RubyXL/XF.html +1 -1
- data/rdoc/created.rid +21 -21
- data/rdoc/index.html +2 -2
- data/rdoc/js/search_index.js +1 -1
- data/rdoc/table_of_contents.html +62 -72
- data/rubyXL.gemspec +8 -4
- data/spec/lib/cell_spec.rb +15 -15
- data/spec/lib/parser_spec.rb +0 -8
- data/spec/lib/worksheet_spec.rb +107 -369
- data/tmp/.gitignore +1 -0
- metadata +17 -2
data/rubyXL.gemspec
CHANGED
|
@@ -2,16 +2,16 @@
|
|
|
2
2
|
# DO NOT EDIT THIS FILE DIRECTLY
|
|
3
3
|
# Instead, edit Jeweler::Tasks in Rakefile, and run 'rake gemspec'
|
|
4
4
|
# -*- encoding: utf-8 -*-
|
|
5
|
-
# stub: rubyXL 3.
|
|
5
|
+
# stub: rubyXL 3.3.0 ruby lib
|
|
6
6
|
|
|
7
7
|
Gem::Specification.new do |s|
|
|
8
8
|
s.name = "rubyXL"
|
|
9
|
-
s.version = "3.
|
|
9
|
+
s.version = "3.3.0"
|
|
10
10
|
|
|
11
11
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
|
12
12
|
s.require_paths = ["lib"]
|
|
13
13
|
s.authors = ["Vivek Bhagwat"]
|
|
14
|
-
s.date = "2014-11-
|
|
14
|
+
s.date = "2014-11-25"
|
|
15
15
|
s.description = "rubyXL is a gem which allows the parsing, creation, and manipulation of Microsoft Excel (.xlsx/.xlsm) Documents"
|
|
16
16
|
s.email = "bhagwat.vivek@gmail.com"
|
|
17
17
|
s.extra_rdoc_files = [
|
|
@@ -452,7 +452,8 @@ Gem::Specification.new do |s|
|
|
|
452
452
|
"spec/lib/worksheet_spec.rb",
|
|
453
453
|
"test/input/.gitkeep",
|
|
454
454
|
"test/output/.gitkeep",
|
|
455
|
-
"test/test_parse_write.rb"
|
|
455
|
+
"test/test_parse_write.rb",
|
|
456
|
+
"tmp/.gitignore"
|
|
456
457
|
]
|
|
457
458
|
s.homepage = "http://github.com/gilt/rubyXL"
|
|
458
459
|
s.licenses = ["MIT"]
|
|
@@ -470,6 +471,7 @@ Gem::Specification.new do |s|
|
|
|
470
471
|
s.add_development_dependency(%q<jeweler>, [">= 0"])
|
|
471
472
|
s.add_development_dependency(%q<simplecov>, [">= 0"])
|
|
472
473
|
s.add_development_dependency(%q<rspec>, [">= 1.3.4"])
|
|
474
|
+
s.add_development_dependency(%q<stackprof>, [">= 0"])
|
|
473
475
|
else
|
|
474
476
|
s.add_dependency(%q<nokogiri>, [">= 1.4.4"])
|
|
475
477
|
s.add_dependency(%q<rubyzip>, [">= 1.1.6"])
|
|
@@ -478,6 +480,7 @@ Gem::Specification.new do |s|
|
|
|
478
480
|
s.add_dependency(%q<jeweler>, [">= 0"])
|
|
479
481
|
s.add_dependency(%q<simplecov>, [">= 0"])
|
|
480
482
|
s.add_dependency(%q<rspec>, [">= 1.3.4"])
|
|
483
|
+
s.add_dependency(%q<stackprof>, [">= 0"])
|
|
481
484
|
end
|
|
482
485
|
else
|
|
483
486
|
s.add_dependency(%q<nokogiri>, [">= 1.4.4"])
|
|
@@ -487,6 +490,7 @@ Gem::Specification.new do |s|
|
|
|
487
490
|
s.add_dependency(%q<jeweler>, [">= 0"])
|
|
488
491
|
s.add_dependency(%q<simplecov>, [">= 0"])
|
|
489
492
|
s.add_dependency(%q<rspec>, [">= 1.3.4"])
|
|
493
|
+
s.add_dependency(%q<stackprof>, [">= 0"])
|
|
490
494
|
end
|
|
491
495
|
end
|
|
492
496
|
|
data/spec/lib/cell_spec.rb
CHANGED
|
@@ -139,27 +139,27 @@ describe RubyXL::Cell do
|
|
|
139
139
|
describe '.change_border' do
|
|
140
140
|
it 'should cause cell to have border at top with specified weight' do
|
|
141
141
|
@cell.change_border(:top, 'thin')
|
|
142
|
-
expect(@cell.
|
|
142
|
+
expect(@cell.get_border(:top)).to eq('thin')
|
|
143
143
|
end
|
|
144
144
|
|
|
145
145
|
it 'should cause cell to have border at right with specified weight' do
|
|
146
146
|
@cell.change_border(:right, 'thin')
|
|
147
|
-
expect(@cell.
|
|
147
|
+
expect(@cell.get_border(:right)).to eq('thin')
|
|
148
148
|
end
|
|
149
149
|
|
|
150
150
|
it 'should cause cell to have border at left with specified weight' do
|
|
151
151
|
@cell.change_border(:left, 'thin')
|
|
152
|
-
expect(@cell.
|
|
152
|
+
expect(@cell.get_border(:left)).to eq('thin')
|
|
153
153
|
end
|
|
154
154
|
|
|
155
155
|
it 'should cause cell to have border at bottom with specified weight' do
|
|
156
156
|
@cell.change_border(:bottom, 'thin')
|
|
157
|
-
expect(@cell.
|
|
157
|
+
expect(@cell.get_border(:bottom)).to eq('thin')
|
|
158
158
|
end
|
|
159
159
|
|
|
160
160
|
it 'should cause cell to have border at diagonal with specified weight' do
|
|
161
161
|
@cell.change_border(:diagonal, 'thin')
|
|
162
|
-
expect(@cell.
|
|
162
|
+
expect(@cell.get_border(:diagonal)).to eq('thin')
|
|
163
163
|
end
|
|
164
164
|
end
|
|
165
165
|
|
|
@@ -306,55 +306,55 @@ describe RubyXL::Cell do
|
|
|
306
306
|
describe '.border_top' do
|
|
307
307
|
it 'should correctly return the weight of the border on top for this cell' do
|
|
308
308
|
@cell.change_border(:top, 'thin')
|
|
309
|
-
expect(@cell.
|
|
309
|
+
expect(@cell.get_border(:top)).to eq('thin')
|
|
310
310
|
end
|
|
311
311
|
|
|
312
312
|
it 'should return nil if no top border has been specified for this cell' do
|
|
313
|
-
expect(@cell.
|
|
313
|
+
expect(@cell.get_border(:top)).to be_nil
|
|
314
314
|
end
|
|
315
315
|
end
|
|
316
316
|
|
|
317
317
|
describe '.border_left' do
|
|
318
318
|
it 'should correctly return the weight of the border on left for this cell' do
|
|
319
319
|
@cell.change_border(:left, 'thin')
|
|
320
|
-
expect(@cell.
|
|
320
|
+
expect(@cell.get_border(:left)).to eq('thin')
|
|
321
321
|
end
|
|
322
322
|
|
|
323
323
|
it 'should return nil if no left border has been specified for this cell' do
|
|
324
|
-
expect(@cell.
|
|
324
|
+
expect(@cell.get_border(:left)).to be_nil
|
|
325
325
|
end
|
|
326
326
|
end
|
|
327
327
|
|
|
328
328
|
describe '.border_right' do
|
|
329
329
|
it 'should correctly return the weight of the border on right for this cell' do
|
|
330
330
|
@cell.change_border(:right, 'thin')
|
|
331
|
-
expect(@cell.
|
|
331
|
+
expect(@cell.get_border(:right)).to eq('thin')
|
|
332
332
|
end
|
|
333
333
|
|
|
334
334
|
it 'should return nil if no right border has been specified for this cell' do
|
|
335
|
-
expect(@cell.
|
|
335
|
+
expect(@cell.get_border(:right)).to be_nil
|
|
336
336
|
end
|
|
337
337
|
end
|
|
338
338
|
|
|
339
339
|
describe '.border_bottom' do
|
|
340
340
|
it 'should correctly return the weight of the border on bottom for this cell' do
|
|
341
341
|
@cell.change_border(:bottom, 'thin')
|
|
342
|
-
expect(@cell.
|
|
342
|
+
expect(@cell.get_border(:bottom)).to eq('thin')
|
|
343
343
|
end
|
|
344
344
|
|
|
345
345
|
it 'should return nil if no bottom border has been specified for this cell' do
|
|
346
|
-
expect(@cell.
|
|
346
|
+
expect(@cell.get_border(:bottom)).to be_nil
|
|
347
347
|
end
|
|
348
348
|
end
|
|
349
349
|
|
|
350
350
|
describe '.border_diagonal' do
|
|
351
351
|
it 'should correctly return the weight of the diagonal border for this cell' do
|
|
352
352
|
@cell.change_border(:diagonal, 'thin')
|
|
353
|
-
expect(@cell.
|
|
353
|
+
expect(@cell.get_border(:diagonal)).to eq('thin')
|
|
354
354
|
end
|
|
355
355
|
|
|
356
356
|
it 'should return nil if no diagonal border has been specified for this cell' do
|
|
357
|
-
expect(@cell.
|
|
357
|
+
expect(@cell.get_border(:diagonal)).to be_nil
|
|
358
358
|
end
|
|
359
359
|
end
|
|
360
360
|
|
data/spec/lib/parser_spec.rb
CHANGED
|
@@ -58,14 +58,6 @@ describe RubyXL::Parser do
|
|
|
58
58
|
expect {@workbook2 = RubyXL::Parser.parse("nonexistent_file.tmp")}.to raise_error
|
|
59
59
|
end
|
|
60
60
|
|
|
61
|
-
it 'should only read the data and not any of the styles (for the sake of speed) when passed true' do
|
|
62
|
-
@workbook2 = RubyXL::Parser.parse(@file, :data_only => true)
|
|
63
|
-
|
|
64
|
-
expect(@workbook2.worksheets.size).to eq(@workbook.worksheets.size)
|
|
65
|
-
expect(@workbook2[0].extract_data).to eq(@workbook[0].extract_data)
|
|
66
|
-
expect(@workbook2[0].extract_data).to eq(@workbook[0].extract_data)
|
|
67
|
-
end
|
|
68
|
-
|
|
69
61
|
=begin
|
|
70
62
|
it 'should construct consistent number formats' do
|
|
71
63
|
@workbook2 = RubyXL::Parser.parse(@file)
|
data/spec/lib/worksheet_spec.rb
CHANGED
|
@@ -71,11 +71,11 @@ describe RubyXL::Worksheet do
|
|
|
71
71
|
}.to raise_error
|
|
72
72
|
end
|
|
73
73
|
|
|
74
|
-
it 'should
|
|
75
|
-
expect(@worksheet.sheet_data
|
|
76
|
-
@worksheet.change_row_fill(11,'111111')
|
|
74
|
+
it 'should create a new row if it did not exist before' do
|
|
75
|
+
expect(@worksheet.sheet_data[11]).to be_nil
|
|
76
|
+
@worksheet.change_row_fill(11, '111111')
|
|
77
|
+
expect(@worksheet.sheet_data[11]).to be_a(RubyXL::Row)
|
|
77
78
|
expect(@worksheet.get_row_fill(11)).to eq('111111')
|
|
78
|
-
expect(@worksheet.sheet_data.size).to eq(12)
|
|
79
79
|
end
|
|
80
80
|
end
|
|
81
81
|
|
|
@@ -92,11 +92,11 @@ describe RubyXL::Worksheet do
|
|
|
92
92
|
}.to raise_error
|
|
93
93
|
end
|
|
94
94
|
|
|
95
|
-
it 'should
|
|
96
|
-
expect(@worksheet.sheet_data
|
|
95
|
+
it 'should create a new row if it did not exist before' do
|
|
96
|
+
expect(@worksheet.sheet_data[11]).to be_nil
|
|
97
97
|
@worksheet.change_row_font_name(11, 'Arial')
|
|
98
|
+
expect(@worksheet.sheet_data[11]).to be_a(RubyXL::Row)
|
|
98
99
|
expect(@worksheet.get_row_font_name(11)).to eq("Arial")
|
|
99
|
-
expect(@worksheet.sheet_data.size).to eq(12)
|
|
100
100
|
end
|
|
101
101
|
end
|
|
102
102
|
|
|
@@ -119,11 +119,11 @@ describe RubyXL::Worksheet do
|
|
|
119
119
|
}.to raise_error
|
|
120
120
|
end
|
|
121
121
|
|
|
122
|
-
it 'should
|
|
123
|
-
expect(@worksheet.sheet_data
|
|
122
|
+
it 'should create a new row if it did not exist before' do
|
|
123
|
+
expect(@worksheet.sheet_data[11]).to be_nil
|
|
124
124
|
@worksheet.change_row_font_size(11,20)
|
|
125
|
+
expect(@worksheet.sheet_data[11]).to be_a(RubyXL::Row)
|
|
125
126
|
expect(@worksheet.get_row_font_size(11)).to eq(20)
|
|
126
|
-
expect(@worksheet.sheet_data.size).to eq(12)
|
|
127
127
|
end
|
|
128
128
|
end
|
|
129
129
|
|
|
@@ -152,11 +152,11 @@ describe RubyXL::Worksheet do
|
|
|
152
152
|
}.to raise_error
|
|
153
153
|
end
|
|
154
154
|
|
|
155
|
-
it 'should
|
|
156
|
-
expect(@worksheet.sheet_data
|
|
157
|
-
@worksheet.change_row_font_color(11,'0f0f0f')
|
|
155
|
+
it 'should create a new row if it did not exist before' do
|
|
156
|
+
expect(@worksheet.sheet_data[11]).to be_nil
|
|
157
|
+
@worksheet.change_row_font_color(11, '0f0f0f')
|
|
158
|
+
expect(@worksheet.sheet_data[11]).to be_a(RubyXL::Row)
|
|
158
159
|
expect(@worksheet.get_row_font_color(11)).to eq('0f0f0f')
|
|
159
|
-
expect(@worksheet.sheet_data.size).to eq(12)
|
|
160
160
|
end
|
|
161
161
|
end
|
|
162
162
|
|
|
@@ -169,15 +169,15 @@ describe RubyXL::Worksheet do
|
|
|
169
169
|
|
|
170
170
|
it 'should cause error if a negative argument is passed in' do
|
|
171
171
|
expect {
|
|
172
|
-
@worksheet.change_row_italics(-1,false)
|
|
172
|
+
@worksheet.change_row_italics(-1, false)
|
|
173
173
|
}.to raise_error
|
|
174
174
|
end
|
|
175
175
|
|
|
176
|
-
it 'should
|
|
177
|
-
expect(@worksheet.sheet_data
|
|
176
|
+
it 'should create a new row if it did not exist before' do
|
|
177
|
+
expect(@worksheet.sheet_data[11]).to be_nil
|
|
178
178
|
@worksheet.change_row_italics(11,true)
|
|
179
|
+
expect(@worksheet.sheet_data[11]).to be_a(RubyXL::Row)
|
|
179
180
|
expect(@worksheet.is_row_italicized(11)).to eq(true)
|
|
180
|
-
expect(@worksheet.sheet_data.size).to eq(12)
|
|
181
181
|
end
|
|
182
182
|
end
|
|
183
183
|
|
|
@@ -190,15 +190,15 @@ describe RubyXL::Worksheet do
|
|
|
190
190
|
|
|
191
191
|
it 'should cause error if a negative argument is passed in' do
|
|
192
192
|
expect {
|
|
193
|
-
@worksheet.change_row_bold(-1,false)
|
|
193
|
+
@worksheet.change_row_bold(-1, false)
|
|
194
194
|
}.to raise_error
|
|
195
195
|
end
|
|
196
196
|
|
|
197
|
-
it 'should
|
|
198
|
-
expect(@worksheet.sheet_data
|
|
199
|
-
@worksheet.change_row_bold(11,true)
|
|
197
|
+
it 'should create a new row if it did not exist before' do
|
|
198
|
+
expect(@worksheet.sheet_data[11]).to be_nil
|
|
199
|
+
@worksheet.change_row_bold(11, true)
|
|
200
|
+
expect(@worksheet.sheet_data[11]).to be_a(RubyXL::Row)
|
|
200
201
|
expect(@worksheet.is_row_bolded(11)).to eq(true)
|
|
201
|
-
expect(@worksheet.sheet_data.size).to eq(12)
|
|
202
202
|
end
|
|
203
203
|
end
|
|
204
204
|
|
|
@@ -211,15 +211,15 @@ describe RubyXL::Worksheet do
|
|
|
211
211
|
|
|
212
212
|
it 'should cause error if a negative argument is passed in' do
|
|
213
213
|
expect {
|
|
214
|
-
@worksheet.change_row_underline(-1,false)
|
|
214
|
+
@worksheet.change_row_underline(-1, false)
|
|
215
215
|
}.to raise_error
|
|
216
216
|
end
|
|
217
217
|
|
|
218
|
-
it 'should
|
|
219
|
-
expect(@worksheet.sheet_data
|
|
218
|
+
it 'should create a new row if it did not exist before' do
|
|
219
|
+
expect(@worksheet.sheet_data[11]).to be_nil
|
|
220
220
|
@worksheet.change_row_underline(11,true)
|
|
221
|
+
expect(@worksheet.sheet_data[11]).to be_a(RubyXL::Row)
|
|
221
222
|
expect(@worksheet.is_row_underlined(11)).to eq(true)
|
|
222
|
-
expect(@worksheet.sheet_data.size).to eq(12)
|
|
223
223
|
end
|
|
224
224
|
end
|
|
225
225
|
|
|
@@ -232,15 +232,15 @@ describe RubyXL::Worksheet do
|
|
|
232
232
|
|
|
233
233
|
it 'should cause error if a negative argument is passed in' do
|
|
234
234
|
expect {
|
|
235
|
-
@worksheet.change_row_strikethrough(-1,false)
|
|
235
|
+
@worksheet.change_row_strikethrough(-1, false)
|
|
236
236
|
}.to raise_error
|
|
237
237
|
end
|
|
238
238
|
|
|
239
|
-
it 'should
|
|
240
|
-
expect(@worksheet.sheet_data
|
|
239
|
+
it 'should create a new row if it did not exist before' do
|
|
240
|
+
expect(@worksheet.sheet_data[11]).to be_nil
|
|
241
241
|
@worksheet.change_row_strikethrough(11,true)
|
|
242
|
+
expect(@worksheet.sheet_data[11]).to be_a(RubyXL::Row)
|
|
242
243
|
expect(@worksheet.is_row_struckthrough(11)).to eq(true)
|
|
243
|
-
expect(@worksheet.sheet_data.size).to eq(12)
|
|
244
244
|
end
|
|
245
245
|
end
|
|
246
246
|
|
|
@@ -261,11 +261,11 @@ describe RubyXL::Worksheet do
|
|
|
261
261
|
}.to raise_error
|
|
262
262
|
end
|
|
263
263
|
|
|
264
|
-
it 'should
|
|
265
|
-
expect(@worksheet.sheet_data
|
|
266
|
-
@worksheet.change_row_height(11,30)
|
|
264
|
+
it 'should create a new row if it did not exist before' do
|
|
265
|
+
expect(@worksheet.sheet_data[11]).to be_nil
|
|
266
|
+
@worksheet.change_row_height(11, 30)
|
|
267
|
+
expect(@worksheet.sheet_data[11]).to be_a(RubyXL::Row)
|
|
267
268
|
expect(@worksheet.get_row_height(11)).to eq(30)
|
|
268
|
-
expect(@worksheet.sheet_data.size).to eq(12)
|
|
269
269
|
end
|
|
270
270
|
end
|
|
271
271
|
|
|
@@ -276,18 +276,17 @@ describe RubyXL::Worksheet do
|
|
|
276
276
|
expect(@worksheet[0][5].horizontal_alignment).to eq('center')
|
|
277
277
|
end
|
|
278
278
|
|
|
279
|
-
|
|
280
279
|
it 'should cause error if a negative argument is passed in' do
|
|
281
280
|
expect {
|
|
282
281
|
@worksheet.change_row_horizontal_alignment(-1,'center')
|
|
283
282
|
}.to raise_error
|
|
284
283
|
end
|
|
285
284
|
|
|
286
|
-
it 'should
|
|
287
|
-
expect(@worksheet.sheet_data
|
|
288
|
-
@worksheet.change_row_horizontal_alignment(11,'center')
|
|
285
|
+
it 'should create a new row if it did not exist before' do
|
|
286
|
+
expect(@worksheet.sheet_data[11]).to be_nil
|
|
287
|
+
@worksheet.change_row_horizontal_alignment(11, 'center')
|
|
288
|
+
expect(@worksheet.sheet_data[11]).to be_a(RubyXL::Row)
|
|
289
289
|
expect(@worksheet.get_row_horizontal_alignment(11)).to eq('center')
|
|
290
|
-
expect(@worksheet.sheet_data.size).to eq(12)
|
|
291
290
|
end
|
|
292
291
|
end
|
|
293
292
|
|
|
@@ -304,11 +303,11 @@ describe RubyXL::Worksheet do
|
|
|
304
303
|
}.to raise_error
|
|
305
304
|
end
|
|
306
305
|
|
|
307
|
-
it 'should
|
|
308
|
-
expect(@worksheet.sheet_data
|
|
309
|
-
@worksheet.change_row_vertical_alignment(11,'center')
|
|
306
|
+
it 'should create a new row if it did not exist before' do
|
|
307
|
+
expect(@worksheet.sheet_data[11]).to be_nil
|
|
308
|
+
@worksheet.change_row_vertical_alignment(11, 'center')
|
|
309
|
+
expect(@worksheet.sheet_data[11]).to be_a(RubyXL::Row)
|
|
310
310
|
expect(@worksheet.get_row_vertical_alignment(11)).to eq('center')
|
|
311
|
-
expect(@worksheet.sheet_data.size).to eq(12)
|
|
312
311
|
end
|
|
313
312
|
end
|
|
314
313
|
|
|
@@ -320,41 +319,41 @@ describe RubyXL::Worksheet do
|
|
|
320
319
|
}.to raise_error
|
|
321
320
|
end
|
|
322
321
|
|
|
323
|
-
it 'should
|
|
324
|
-
expect(@worksheet.sheet_data
|
|
322
|
+
it 'should create a new row if it did not exist before' do
|
|
323
|
+
expect(@worksheet.sheet_data[11]).to be_nil
|
|
325
324
|
@worksheet.change_row_border(11, :left, 'thin')
|
|
326
|
-
expect(@worksheet.
|
|
327
|
-
expect(@worksheet.
|
|
325
|
+
expect(@worksheet.sheet_data[11]).to be_a(RubyXL::Row)
|
|
326
|
+
expect(@worksheet.get_row_border(11, :left)).to eq('thin')
|
|
328
327
|
end
|
|
329
328
|
|
|
330
329
|
it 'should cause row and cells to have border at top of specified weight' do
|
|
331
330
|
@worksheet.change_row_border(0, :top, 'thin')
|
|
332
|
-
expect(@worksheet.
|
|
333
|
-
expect(@worksheet[0][5].
|
|
331
|
+
expect(@worksheet.get_row_border(0, :top)).to eq('thin')
|
|
332
|
+
expect(@worksheet[0][5].get_border(:top)).to eq('thin')
|
|
334
333
|
end
|
|
335
334
|
|
|
336
335
|
it 'should cause row and cells to have border at left of specified weight' do
|
|
337
336
|
@worksheet.change_row_border(0, :left, 'thin')
|
|
338
|
-
expect(@worksheet.
|
|
339
|
-
expect(@worksheet[0][5].
|
|
337
|
+
expect(@worksheet.get_row_border(0, :left)).to eq('thin')
|
|
338
|
+
expect(@worksheet[0][5].get_border(:left)).to eq('thin')
|
|
340
339
|
end
|
|
341
340
|
|
|
342
341
|
it 'should cause row and cells to have border at right of specified weight' do
|
|
343
342
|
@worksheet.change_row_border(0, :right, 'thin')
|
|
344
|
-
expect(@worksheet.
|
|
345
|
-
expect(@worksheet[0][5].
|
|
343
|
+
expect(@worksheet.get_row_border(0, :right)).to eq('thin')
|
|
344
|
+
expect(@worksheet[0][5].get_border(:right)).to eq('thin')
|
|
346
345
|
end
|
|
347
346
|
|
|
348
347
|
it 'should cause row to have border at bottom of specified weight' do
|
|
349
348
|
@worksheet.change_row_border(0, :bottom, 'thin')
|
|
350
|
-
expect(@worksheet.
|
|
351
|
-
expect(@worksheet[0][5].
|
|
349
|
+
expect(@worksheet.get_row_border(0, :bottom)).to eq('thin')
|
|
350
|
+
expect(@worksheet[0][5].get_border(:bottom)).to eq('thin')
|
|
352
351
|
end
|
|
353
352
|
|
|
354
353
|
it 'should cause row to have border at diagonal of specified weight' do
|
|
355
354
|
@worksheet.change_row_border(0, :diagonal, 'thin')
|
|
356
|
-
expect(@worksheet.
|
|
357
|
-
expect(@worksheet[0][5].
|
|
355
|
+
expect(@worksheet.get_row_border(0, :diagonal)).to eq('thin')
|
|
356
|
+
expect(@worksheet[0][5].get_border(:diagonal)).to eq('thin')
|
|
358
357
|
end
|
|
359
358
|
end
|
|
360
359
|
|
|
@@ -367,16 +366,9 @@ describe RubyXL::Worksheet do
|
|
|
367
366
|
|
|
368
367
|
it 'should cause error if a negative argument is passed in' do
|
|
369
368
|
expect {
|
|
370
|
-
@worksheet.change_column_font_name(-1,'Arial')
|
|
369
|
+
@worksheet.change_column_font_name(-1, 'Arial')
|
|
371
370
|
}.to raise_error
|
|
372
371
|
end
|
|
373
|
-
|
|
374
|
-
it 'should expand matrix to fit argument if nonnegative' do
|
|
375
|
-
expect(@worksheet.sheet_data[0].size).to eq(11)
|
|
376
|
-
@worksheet.change_column_font_name(11,'Arial')
|
|
377
|
-
expect(@worksheet.get_column_font_name(11)).to eq('Arial')
|
|
378
|
-
expect(@worksheet.sheet_data[0].size).to eq(12)
|
|
379
|
-
end
|
|
380
372
|
end
|
|
381
373
|
|
|
382
374
|
describe '.change_column_font_size' do
|
|
@@ -394,16 +386,9 @@ describe RubyXL::Worksheet do
|
|
|
394
386
|
|
|
395
387
|
it 'should cause error if a negative argument is passed in' do
|
|
396
388
|
expect {
|
|
397
|
-
@worksheet.change_column_font_size(-1,20)
|
|
389
|
+
@worksheet.change_column_font_size(-1, 20)
|
|
398
390
|
}.to raise_error
|
|
399
391
|
end
|
|
400
|
-
|
|
401
|
-
it 'should expand matrix to fit argument if nonnegative'do
|
|
402
|
-
expect(@worksheet.sheet_data[0].size).to eq(11)
|
|
403
|
-
@worksheet.change_column_font_size(11,20)
|
|
404
|
-
expect(@worksheet.get_column_font_size(11)).to eq(20)
|
|
405
|
-
expect(@worksheet.sheet_data[0].size).to eq(12)
|
|
406
|
-
end
|
|
407
392
|
end
|
|
408
393
|
|
|
409
394
|
describe '.change_column_font_color' do
|
|
@@ -430,13 +415,6 @@ describe RubyXL::Worksheet do
|
|
|
430
415
|
@worksheet.change_column_font_color(-1,'0f0f0f')
|
|
431
416
|
}.to raise_error
|
|
432
417
|
end
|
|
433
|
-
|
|
434
|
-
it 'should expand matrix to fit argument if nonnegative'do
|
|
435
|
-
expect(@worksheet.sheet_data[0].size).to eq(11)
|
|
436
|
-
@worksheet.change_column_font_color(11,'0f0f0f')
|
|
437
|
-
expect(@worksheet.get_column_font_color(11)).to eq('0f0f0f')
|
|
438
|
-
expect(@worksheet.sheet_data[0].size).to eq(12)
|
|
439
|
-
end
|
|
440
418
|
end
|
|
441
419
|
|
|
442
420
|
describe '.change_column_italics' do
|
|
@@ -448,16 +426,9 @@ describe RubyXL::Worksheet do
|
|
|
448
426
|
|
|
449
427
|
it 'should cause error if a negative argument is passed in' do
|
|
450
428
|
expect {
|
|
451
|
-
@worksheet.change_column_italicized(-1,false)
|
|
429
|
+
@worksheet.change_column_italicized(-1, false)
|
|
452
430
|
}.to raise_error
|
|
453
431
|
end
|
|
454
|
-
|
|
455
|
-
it 'should expand matrix to fit argument if nonnegative'do
|
|
456
|
-
expect(@worksheet.sheet_data[0].size).to eq(11)
|
|
457
|
-
@worksheet.change_column_italics(11,true)
|
|
458
|
-
expect(@worksheet.is_column_italicized(11)).to eq(true)
|
|
459
|
-
expect(@worksheet.sheet_data[0].size).to eq(12)
|
|
460
|
-
end
|
|
461
432
|
end
|
|
462
433
|
|
|
463
434
|
describe '.change_column_bold' do
|
|
@@ -469,16 +440,9 @@ describe RubyXL::Worksheet do
|
|
|
469
440
|
|
|
470
441
|
it 'should cause error if a negative argument is passed in' do
|
|
471
442
|
expect {
|
|
472
|
-
@worksheet.change_column_bold(-1,false)
|
|
443
|
+
@worksheet.change_column_bold(-1, false)
|
|
473
444
|
}.to raise_error
|
|
474
445
|
end
|
|
475
|
-
|
|
476
|
-
it 'should expand matrix to fit argument if nonnegative'do
|
|
477
|
-
expect(@worksheet.sheet_data[0].size).to eq(11)
|
|
478
|
-
@worksheet.change_column_bold(11,true)
|
|
479
|
-
expect(@worksheet.is_column_bolded(11)).to eq(true)
|
|
480
|
-
expect(@worksheet.sheet_data[0].size).to eq(12)
|
|
481
|
-
end
|
|
482
446
|
end
|
|
483
447
|
|
|
484
448
|
describe '.change_column_underline' do
|
|
@@ -490,16 +454,9 @@ describe RubyXL::Worksheet do
|
|
|
490
454
|
|
|
491
455
|
it 'should cause error if a negative argument is passed in' do
|
|
492
456
|
expect {
|
|
493
|
-
@worksheet.change_column_underline(-1,false)
|
|
457
|
+
@worksheet.change_column_underline(-1, false)
|
|
494
458
|
}.to raise_error
|
|
495
459
|
end
|
|
496
|
-
|
|
497
|
-
it 'should expand matrix to fit argument if nonnegative'do
|
|
498
|
-
expect(@worksheet.sheet_data[0].size).to eq(11)
|
|
499
|
-
@worksheet.change_column_underline(11,true)
|
|
500
|
-
expect(@worksheet.is_column_underlined(11)).to eq(true)
|
|
501
|
-
expect(@worksheet.sheet_data[0].size).to eq(12)
|
|
502
|
-
end
|
|
503
460
|
end
|
|
504
461
|
|
|
505
462
|
describe '.change_column_strikethrough' do
|
|
@@ -511,16 +468,9 @@ describe RubyXL::Worksheet do
|
|
|
511
468
|
|
|
512
469
|
it 'should cause error if a negative argument is passed in' do
|
|
513
470
|
expect {
|
|
514
|
-
@worksheet.change_column_strikethrough(-1,false)
|
|
471
|
+
@worksheet.change_column_strikethrough(-1, false)
|
|
515
472
|
}.to raise_error
|
|
516
473
|
end
|
|
517
|
-
|
|
518
|
-
it 'should expand matrix to fit argument if nonnegative'do
|
|
519
|
-
expect(@worksheet.sheet_data[0].size).to eq(11)
|
|
520
|
-
@worksheet.change_column_strikethrough(11,true)
|
|
521
|
-
expect(@worksheet.is_column_struckthrough(11)).to eq(true)
|
|
522
|
-
expect(@worksheet.sheet_data[0].size).to eq(12)
|
|
523
|
-
end
|
|
524
474
|
end
|
|
525
475
|
|
|
526
476
|
describe '.change_column_width_raw' do
|
|
@@ -534,13 +484,6 @@ describe RubyXL::Worksheet do
|
|
|
534
484
|
@worksheet.change_column_width_raw(-1, 10)
|
|
535
485
|
}.to raise_error
|
|
536
486
|
end
|
|
537
|
-
|
|
538
|
-
it 'should expand matrix to fit argument if nonnegative'do
|
|
539
|
-
expect(@worksheet.sheet_data[0].size).to eq(11)
|
|
540
|
-
@worksheet.change_column_width_raw(11, 30)
|
|
541
|
-
expect(@worksheet.get_column_width_raw(11)).to eq(30)
|
|
542
|
-
expect(@worksheet.sheet_data[0].size).to eq(12)
|
|
543
|
-
end
|
|
544
487
|
end
|
|
545
488
|
|
|
546
489
|
describe '.change_column_fill' do
|
|
@@ -567,19 +510,12 @@ describe RubyXL::Worksheet do
|
|
|
567
510
|
@worksheet.change_column_fill(-1,'111111')
|
|
568
511
|
}.to raise_error
|
|
569
512
|
end
|
|
570
|
-
|
|
571
|
-
it 'should expand matrix to fit argument if nonnegative'do
|
|
572
|
-
expect(@worksheet.sheet_data[0].size).to eq(11)
|
|
573
|
-
@worksheet.change_column_fill(11,'111111')
|
|
574
|
-
expect(@worksheet.get_column_fill(11)).to eq('111111')
|
|
575
|
-
expect(@worksheet.sheet_data[0].size).to eq(12)
|
|
576
|
-
end
|
|
577
513
|
end
|
|
578
514
|
|
|
579
515
|
describe '.change_column_horizontal_alignment' do
|
|
580
516
|
it 'should cause column and cell to horizontally align as specified by the passed in string' do
|
|
581
|
-
@worksheet.change_column_horizontal_alignment(0,'center')
|
|
582
|
-
expect(@worksheet.
|
|
517
|
+
@worksheet.change_column_horizontal_alignment(0, 'center')
|
|
518
|
+
expect(@worksheet.get_column_alignment(0, :horizontal)).to eq('center')
|
|
583
519
|
expect(@worksheet[5][0].horizontal_alignment).to eq('center')
|
|
584
520
|
end
|
|
585
521
|
|
|
@@ -588,19 +524,12 @@ describe RubyXL::Worksheet do
|
|
|
588
524
|
@worksheet.change_column_horizontal_alignment(-1,'center')
|
|
589
525
|
}.to raise_error
|
|
590
526
|
end
|
|
591
|
-
|
|
592
|
-
it 'should expand matrix to fit argument if nonnegative'do
|
|
593
|
-
expect(@worksheet.sheet_data[0].size).to eq(11)
|
|
594
|
-
@worksheet.change_column_horizontal_alignment(11,'center')
|
|
595
|
-
expect(@worksheet.get_column_horizontal_alignment(11)).to eq('center')
|
|
596
|
-
expect(@worksheet.sheet_data[0].size).to eq(12)
|
|
597
|
-
end
|
|
598
527
|
end
|
|
599
528
|
|
|
600
529
|
describe '.change_column_vertical_alignment' do
|
|
601
530
|
it 'should cause column and cell to vertically align as specified by the passed in string' do
|
|
602
531
|
@worksheet.change_column_vertical_alignment(0, 'center')
|
|
603
|
-
expect(@worksheet.
|
|
532
|
+
expect(@worksheet.get_column_alignment(0, :vertical)).to eq('center')
|
|
604
533
|
expect(@worksheet[5][0].vertical_alignment).to eq('center')
|
|
605
534
|
end
|
|
606
535
|
|
|
@@ -610,22 +539,15 @@ describe RubyXL::Worksheet do
|
|
|
610
539
|
}.to raise_error
|
|
611
540
|
end
|
|
612
541
|
|
|
613
|
-
it 'should expand matrix to fit argument if nonnegative'do
|
|
614
|
-
expect(@worksheet.sheet_data[0].size).to eq(11)
|
|
615
|
-
@worksheet.change_column_vertical_alignment(11,'center')
|
|
616
|
-
expect(@worksheet.get_column_vertical_alignment(11)).to eq('center')
|
|
617
|
-
expect(@worksheet.sheet_data[0].size).to eq(12)
|
|
618
|
-
end
|
|
619
|
-
|
|
620
542
|
it 'should set column width if column alignment is changed' do
|
|
621
543
|
test_column = 2
|
|
622
|
-
expect(@worksheet.
|
|
544
|
+
expect(@worksheet.get_column_alignment(test_column, :vertical)).to be_nil
|
|
623
545
|
expect(@worksheet.get_column_width_raw(test_column)).to be_nil
|
|
624
546
|
expect(@worksheet.get_column_width(test_column)).to eq(RubyXL::ColumnRange::DEFAULT_WIDTH)
|
|
625
547
|
@worksheet.change_column_vertical_alignment(test_column, 'top')
|
|
626
548
|
expect(@worksheet.get_column_width_raw(test_column)).not_to be_nil
|
|
627
549
|
expect(@worksheet.get_column_width(test_column)).to eq(RubyXL::ColumnRange::DEFAULT_WIDTH)
|
|
628
|
-
expect(@worksheet.
|
|
550
|
+
expect(@worksheet.get_column_alignment(test_column, :vertical)).to eq('top')
|
|
629
551
|
end
|
|
630
552
|
end
|
|
631
553
|
|
|
@@ -636,43 +558,35 @@ describe RubyXL::Worksheet do
|
|
|
636
558
|
}.to raise_error
|
|
637
559
|
end
|
|
638
560
|
|
|
639
|
-
it 'should expand matrix to fit argument if nonnegative'do
|
|
640
|
-
expect(@worksheet.sheet_data[0].size).to eq(11)
|
|
641
|
-
@worksheet.change_column_border(11, :top, 'thin')
|
|
642
|
-
expect(@worksheet.get_column_border_top(11)).to eq('thin')
|
|
643
|
-
expect(@worksheet.sheet_data[0].size).to eq(12)
|
|
644
|
-
end
|
|
645
|
-
|
|
646
561
|
it 'should cause column and cells within to have border at top of specified weight' do
|
|
647
562
|
@worksheet.change_column_border(0, :top, 'thin')
|
|
648
|
-
expect(@worksheet.
|
|
649
|
-
expect(@worksheet[5][0].
|
|
563
|
+
expect(@worksheet.get_column_border(0, :top)).to eq('thin')
|
|
564
|
+
expect(@worksheet[5][0].get_border(:top)).to eq('thin')
|
|
650
565
|
end
|
|
651
566
|
|
|
652
567
|
it 'should cause column and cells within to have border at left of specified weight' do
|
|
653
568
|
@worksheet.change_column_border(0, :left, 'thin')
|
|
654
|
-
expect(@worksheet.
|
|
655
|
-
expect(@worksheet[5][0].
|
|
569
|
+
expect(@worksheet.get_column_border(0, :left)).to eq('thin')
|
|
570
|
+
expect(@worksheet[5][0].get_border(:left)).to eq('thin')
|
|
656
571
|
end
|
|
657
572
|
|
|
658
573
|
it 'should cause column and cells within to have border at right of specified weight' do
|
|
659
574
|
@worksheet.change_column_border(0, :right, 'thin')
|
|
660
|
-
expect(@worksheet.
|
|
661
|
-
expect(@worksheet[5][0].
|
|
575
|
+
expect(@worksheet.get_column_border(0, :right)).to eq('thin')
|
|
576
|
+
expect(@worksheet[5][0].get_border(:right)).to eq('thin')
|
|
662
577
|
end
|
|
663
578
|
|
|
664
579
|
it 'should cause column and cells within to have border at bottom of specified weight' do
|
|
665
580
|
@worksheet.change_column_border(0, :bottom, 'thin')
|
|
666
|
-
expect(@worksheet.
|
|
667
|
-
expect(@worksheet[5][0].
|
|
581
|
+
expect(@worksheet.get_column_border(0, :bottom)).to eq('thin')
|
|
582
|
+
expect(@worksheet[5][0].get_border(:bottom)).to eq('thin')
|
|
668
583
|
end
|
|
669
584
|
|
|
670
585
|
it 'should cause column and cells within to have border at diagonal of specified weight' do
|
|
671
586
|
@worksheet.change_column_border(0, :diagonal, 'thin')
|
|
672
|
-
expect(@worksheet.
|
|
673
|
-
expect(@worksheet[5][0].
|
|
587
|
+
expect(@worksheet.get_column_border(0, :diagonal)).to eq('thin')
|
|
588
|
+
expect(@worksheet[5][0].get_border(:diagonal)).to eq('thin')
|
|
674
589
|
end
|
|
675
|
-
|
|
676
590
|
end
|
|
677
591
|
|
|
678
592
|
describe '.merge_cells' do
|
|
@@ -863,12 +777,6 @@ describe RubyXL::Worksheet do
|
|
|
863
777
|
@worksheet.insert_column(-1)
|
|
864
778
|
}.to raise_error
|
|
865
779
|
end
|
|
866
|
-
|
|
867
|
-
it 'should expand matrix to fit argument if nonnegative' do
|
|
868
|
-
expect(@worksheet.sheet_data[0].size).to eq(11)
|
|
869
|
-
@worksheet.insert_column(11)
|
|
870
|
-
expect(@worksheet.sheet_data[0].size).to eq(13)
|
|
871
|
-
end
|
|
872
780
|
end
|
|
873
781
|
|
|
874
782
|
describe '.insert_cell' do
|
|
@@ -1056,8 +964,8 @@ describe RubyXL::Worksheet do
|
|
|
1056
964
|
expect(@worksheet.get_row_height(0)).to eq(30)
|
|
1057
965
|
end
|
|
1058
966
|
|
|
1059
|
-
it 'should return
|
|
1060
|
-
expect(@worksheet.get_row_height(11)).to
|
|
967
|
+
it 'should return default row height if a row which does not exist is passed in' do
|
|
968
|
+
expect(@worksheet.get_row_height(11)).to eq(13)
|
|
1061
969
|
end
|
|
1062
970
|
|
|
1063
971
|
it 'should cause error if a negative argument is passed in' do
|
|
@@ -1109,115 +1017,30 @@ describe RubyXL::Worksheet do
|
|
|
1109
1017
|
end
|
|
1110
1018
|
end
|
|
1111
1019
|
|
|
1112
|
-
describe '.
|
|
1020
|
+
describe '.get_row_border' do
|
|
1113
1021
|
it 'should return nil if no border is specified for that row in that direction' do
|
|
1114
|
-
expect(@worksheet.
|
|
1022
|
+
expect(@worksheet.get_row_border(0, :top)).to be_nil
|
|
1115
1023
|
end
|
|
1116
1024
|
|
|
1117
1025
|
it 'should return type of border that this row has on top' do
|
|
1118
1026
|
@worksheet.change_row_border(0, :top, 'thin')
|
|
1119
|
-
expect(@worksheet.
|
|
1120
|
-
end
|
|
1121
|
-
|
|
1122
|
-
it 'should cause error if a negative argument is passed in' do
|
|
1123
|
-
expect {
|
|
1124
|
-
@worksheet.get_row_border_top(-1)
|
|
1125
|
-
}.to raise_error
|
|
1126
|
-
end
|
|
1127
|
-
|
|
1128
|
-
it 'should return nil if a row which does not exist is passed in' do
|
|
1129
|
-
expect(@worksheet.get_row_border_top(11)).to be_nil
|
|
1130
|
-
end
|
|
1131
|
-
end
|
|
1132
|
-
|
|
1133
|
-
describe '.get_row_border_left' do
|
|
1134
|
-
it 'should return nil if no border is specified for that row in that direction' do
|
|
1135
|
-
expect(@worksheet.get_row_border_left(0)).to be_nil
|
|
1136
|
-
end
|
|
1137
|
-
|
|
1138
|
-
it 'should return type of border that this row has on left' do
|
|
1139
|
-
@worksheet.change_row_border(0, :left, 'thin')
|
|
1140
|
-
expect(@worksheet.get_row_border_left(0)).to eq('thin')
|
|
1141
|
-
end
|
|
1142
|
-
|
|
1143
|
-
it 'should cause error if a negative argument is passed in' do
|
|
1144
|
-
expect {
|
|
1145
|
-
@worksheet.get_row_border_left(-1)
|
|
1146
|
-
}.to raise_error
|
|
1147
|
-
end
|
|
1148
|
-
|
|
1149
|
-
it 'should return nil if a row which does not exist is passed in' do
|
|
1150
|
-
expect(@worksheet.get_row_border_left(11)).to be_nil
|
|
1151
|
-
end
|
|
1152
|
-
end
|
|
1153
|
-
|
|
1154
|
-
describe '.get_row_border_right' do
|
|
1155
|
-
it 'should return nil if no border is specified for that row in that direction' do
|
|
1156
|
-
expect(@worksheet.get_row_border_right(0)).to be_nil
|
|
1157
|
-
end
|
|
1158
|
-
|
|
1159
|
-
it 'should return type of border that this row has on right' do
|
|
1160
|
-
@worksheet.change_row_border(0, :right, 'thin')
|
|
1161
|
-
expect(@worksheet.get_row_border_right(0)).to eq('thin')
|
|
1162
|
-
end
|
|
1163
|
-
|
|
1164
|
-
it 'should cause error if a negative argument is passed in' do
|
|
1165
|
-
expect {
|
|
1166
|
-
@worksheet.get_row_border_right(-1)
|
|
1167
|
-
}.to raise_error
|
|
1168
|
-
end
|
|
1169
|
-
|
|
1170
|
-
it 'should return nil if a row which does not exist is passed in' do
|
|
1171
|
-
expect(@worksheet.get_row_border_right(11)).to be_nil
|
|
1172
|
-
end
|
|
1173
|
-
end
|
|
1174
|
-
|
|
1175
|
-
|
|
1176
|
-
describe '.get_row_border_bottom' do
|
|
1177
|
-
it 'should return nil if no border is specified for that row in that direction' do
|
|
1178
|
-
expect(@worksheet.get_row_border_bottom(0)).to be_nil
|
|
1179
|
-
end
|
|
1180
|
-
|
|
1181
|
-
it 'should return type of border that this row has on bottom' do
|
|
1182
|
-
@worksheet.change_row_border(0, :bottom, 'thin')
|
|
1183
|
-
expect(@worksheet.get_row_border_bottom(0)).to eq('thin')
|
|
1184
|
-
end
|
|
1185
|
-
|
|
1186
|
-
it 'should cause error if a negative argument is passed in' do
|
|
1187
|
-
expect {
|
|
1188
|
-
@worksheet.get_row_border_bottom(-1)
|
|
1189
|
-
}.to raise_error
|
|
1190
|
-
end
|
|
1191
|
-
|
|
1192
|
-
it 'should return nil if a row which does not exist is passed in' do
|
|
1193
|
-
expect(@worksheet.get_row_border_bottom(11)).to be_nil
|
|
1194
|
-
end
|
|
1195
|
-
end
|
|
1196
|
-
|
|
1197
|
-
describe '.get_row_border_diagonal' do
|
|
1198
|
-
it 'should return nil if no border is specified for that row in that direction' do
|
|
1199
|
-
expect(@worksheet.get_row_border_diagonal(0)).to be_nil
|
|
1200
|
-
end
|
|
1201
|
-
|
|
1202
|
-
it 'should return type of border that this row has on diagonal' do
|
|
1203
|
-
@worksheet.change_row_border(0, :diagonal, 'thin')
|
|
1204
|
-
expect(@worksheet.get_row_border_diagonal(0)).to eq('thin')
|
|
1027
|
+
expect(@worksheet.get_row_border(0, :top)).to eq('thin')
|
|
1205
1028
|
end
|
|
1206
1029
|
|
|
1207
1030
|
it 'should cause error if a negative argument is passed in' do
|
|
1208
1031
|
expect {
|
|
1209
|
-
@worksheet.
|
|
1032
|
+
@worksheet.get_row_border(-1, :top)
|
|
1210
1033
|
}.to raise_error
|
|
1211
1034
|
end
|
|
1212
1035
|
|
|
1213
1036
|
it 'should return nil if a row which does not exist is passed in' do
|
|
1214
|
-
expect(@worksheet.
|
|
1037
|
+
expect(@worksheet.get_row_border(11, :top)).to be_nil
|
|
1215
1038
|
end
|
|
1216
1039
|
end
|
|
1217
1040
|
|
|
1218
1041
|
describe '.get_column_font_name' do
|
|
1219
1042
|
it 'should correctly reflect font name for column' do
|
|
1220
|
-
@worksheet.change_column_font_name(0,'Courier')
|
|
1043
|
+
@worksheet.change_column_font_name(0, 'Courier')
|
|
1221
1044
|
expect(@worksheet.get_column_font_name(0)).to eq('Courier')
|
|
1222
1045
|
end
|
|
1223
1046
|
|
|
@@ -1227,8 +1050,8 @@ describe RubyXL::Worksheet do
|
|
|
1227
1050
|
}.to raise_error
|
|
1228
1051
|
end
|
|
1229
1052
|
|
|
1230
|
-
it 'should return
|
|
1231
|
-
expect(@worksheet.get_column_font_name(11)).to
|
|
1053
|
+
it 'should return default font if a (nonnegative) column which does not exist is passed in' do
|
|
1054
|
+
expect(@worksheet.get_column_font_name(11)).to eq('Verdana')
|
|
1232
1055
|
end
|
|
1233
1056
|
end
|
|
1234
1057
|
|
|
@@ -1244,8 +1067,8 @@ describe RubyXL::Worksheet do
|
|
|
1244
1067
|
}.to raise_error
|
|
1245
1068
|
end
|
|
1246
1069
|
|
|
1247
|
-
it 'should return
|
|
1248
|
-
expect(@worksheet.get_column_font_size(11)).to
|
|
1070
|
+
it 'should return default font size if a column which does not exist is passed in' do
|
|
1071
|
+
expect(@worksheet.get_column_font_size(11)).to eq(10)
|
|
1249
1072
|
end
|
|
1250
1073
|
end
|
|
1251
1074
|
|
|
@@ -1261,11 +1084,11 @@ describe RubyXL::Worksheet do
|
|
|
1261
1084
|
}.to raise_error
|
|
1262
1085
|
end
|
|
1263
1086
|
|
|
1264
|
-
it 'should return
|
|
1265
|
-
expect(@worksheet.get_column_font_color(11)).to
|
|
1087
|
+
it 'should return default color (000000) if a (nonnegative) column which does not exist is passed in' do
|
|
1088
|
+
expect(@worksheet.get_column_font_color(11)).to eq('000000')
|
|
1266
1089
|
end
|
|
1267
1090
|
|
|
1268
|
-
it 'should return
|
|
1091
|
+
it 'should return default color (000000) if no rgb font color is specified' do
|
|
1269
1092
|
expect(@worksheet.get_column_font_color(0)).to eq('000000')
|
|
1270
1093
|
end
|
|
1271
1094
|
end
|
|
@@ -1391,7 +1214,7 @@ describe RubyXL::Worksheet do
|
|
|
1391
1214
|
end
|
|
1392
1215
|
|
|
1393
1216
|
it 'should return nil if a column which does not exist is passed in' do
|
|
1394
|
-
expect(@worksheet.get_column_fill(11)).to
|
|
1217
|
+
expect(@worksheet.get_column_fill(11)).to eq('ffffff')
|
|
1395
1218
|
end
|
|
1396
1219
|
|
|
1397
1220
|
it 'should cause error if a negative argument is passed in' do
|
|
@@ -1403,152 +1226,67 @@ describe RubyXL::Worksheet do
|
|
|
1403
1226
|
|
|
1404
1227
|
describe '.get_column_horizontal_alignment' do
|
|
1405
1228
|
it 'should return nil if no alignment specified for column' do
|
|
1406
|
-
expect(@worksheet.
|
|
1229
|
+
expect(@worksheet.get_column_alignment(0, :horizontal)).to be_nil
|
|
1407
1230
|
end
|
|
1408
1231
|
|
|
1409
1232
|
it 'should return nil if a column which does not exist is passed in' do
|
|
1410
|
-
expect(@worksheet.
|
|
1233
|
+
expect(@worksheet.get_column_alignment(11, :horizontal)).to be_nil
|
|
1411
1234
|
end
|
|
1412
1235
|
|
|
1413
1236
|
it 'should cause error if a negative argument is passed in' do
|
|
1414
1237
|
expect {
|
|
1415
|
-
@worksheet.
|
|
1238
|
+
@worksheet.get_column_alignment(-1, :horizontal)
|
|
1416
1239
|
}.to raise_error
|
|
1417
1240
|
end
|
|
1418
1241
|
|
|
1419
1242
|
it 'should return correct horizontal alignment if it is set for that column' do
|
|
1420
1243
|
@worksheet.change_column_horizontal_alignment(0, 'center')
|
|
1421
|
-
expect(@worksheet.
|
|
1244
|
+
expect(@worksheet.get_column_alignment(0, :horizontal)).to eq('center')
|
|
1422
1245
|
end
|
|
1423
1246
|
end
|
|
1424
1247
|
|
|
1425
1248
|
describe '.get_column_vertical_alignment' do
|
|
1426
1249
|
it 'should return nil if no alignment specified for column' do
|
|
1427
|
-
expect(@worksheet.
|
|
1250
|
+
expect(@worksheet.get_column_alignment(0, :vertical)).to be_nil
|
|
1428
1251
|
end
|
|
1429
1252
|
|
|
1430
1253
|
it 'should return nil if a column which does not exist is passed in' do
|
|
1431
|
-
expect(@worksheet.
|
|
1254
|
+
expect(@worksheet.get_column_alignment(11, :vertical)).to be_nil
|
|
1432
1255
|
end
|
|
1433
1256
|
|
|
1434
1257
|
it 'should cause error if a negative argument is passed in' do
|
|
1435
1258
|
expect {
|
|
1436
|
-
@worksheet.
|
|
1259
|
+
@worksheet.get_column_alignment(-1, :vertical)
|
|
1437
1260
|
}.to raise_error
|
|
1438
1261
|
end
|
|
1439
1262
|
|
|
1440
1263
|
it 'should return correct vertical alignment if it is set for that column' do
|
|
1441
1264
|
@worksheet.change_column_vertical_alignment(0, 'center')
|
|
1442
|
-
expect(@worksheet.
|
|
1265
|
+
expect(@worksheet.get_column_alignment(0, :vertical)).to eq('center')
|
|
1443
1266
|
end
|
|
1444
1267
|
end
|
|
1445
1268
|
|
|
1446
|
-
describe '.
|
|
1269
|
+
describe '.get_column_border' do
|
|
1447
1270
|
it 'should return nil if no border is specified for that column in that direction' do
|
|
1448
|
-
expect(@worksheet.
|
|
1449
|
-
end
|
|
1450
|
-
|
|
1451
|
-
it 'should return type of border that this column has on top' do
|
|
1452
|
-
@worksheet.change_column_border(0, :top, 'thin')
|
|
1453
|
-
expect(@worksheet.get_column_border_top(0)).to eq('thin')
|
|
1454
|
-
end
|
|
1455
|
-
|
|
1456
|
-
it 'should cause error if a negative argument is passed in' do
|
|
1457
|
-
expect {
|
|
1458
|
-
@worksheet.get_column_border_top(-1)
|
|
1459
|
-
}.to raise_error
|
|
1460
|
-
end
|
|
1461
|
-
|
|
1462
|
-
it 'should return nil if a column which does not exist is passed in' do
|
|
1463
|
-
expect(@worksheet.get_column_border_top(11)).to be_nil
|
|
1464
|
-
end
|
|
1465
|
-
end
|
|
1466
|
-
|
|
1467
|
-
describe '.get_column_border_left' do
|
|
1468
|
-
it 'should return nil if no border is specified for that column in that direction' do
|
|
1469
|
-
expect(@worksheet.get_column_border_left(0)).to be_nil
|
|
1470
|
-
end
|
|
1471
|
-
|
|
1472
|
-
it 'should return type of border that this column has on left' do
|
|
1473
|
-
@worksheet.change_column_border(0, :left, 'thin')
|
|
1474
|
-
expect(@worksheet.get_column_border_left(0)).to eq('thin')
|
|
1475
|
-
end
|
|
1476
|
-
|
|
1477
|
-
it 'should cause error if a negative argument is passed in' do
|
|
1478
|
-
expect {
|
|
1479
|
-
@worksheet.get_column_border_left(-1)
|
|
1480
|
-
}.to raise_error
|
|
1481
|
-
end
|
|
1482
|
-
|
|
1483
|
-
it 'should return nil if a column which does not exist is passed in' do
|
|
1484
|
-
expect(@worksheet.get_column_border_left(11)).to be_nil
|
|
1485
|
-
end
|
|
1486
|
-
end
|
|
1487
|
-
|
|
1488
|
-
describe '.get_column_border_right' do
|
|
1489
|
-
it 'should return nil if no border is specified for that column in that direction' do
|
|
1490
|
-
expect(@worksheet.get_column_border_right(0)).to be_nil
|
|
1491
|
-
end
|
|
1492
|
-
|
|
1493
|
-
it 'should return type of border that this column has on right' do
|
|
1494
|
-
@worksheet.change_column_border(0, :right, 'thin')
|
|
1495
|
-
expect(@worksheet.get_column_border_right(0)).to eq('thin')
|
|
1496
|
-
end
|
|
1497
|
-
|
|
1498
|
-
it 'should cause error if a negative argument is passed in' do
|
|
1499
|
-
expect {
|
|
1500
|
-
@worksheet.get_column_border_right(-1)
|
|
1501
|
-
}.to raise_error
|
|
1502
|
-
end
|
|
1503
|
-
|
|
1504
|
-
it 'should return nil if a column which does not exist is passed in' do
|
|
1505
|
-
expect(@worksheet.get_column_border_right(11)).to be_nil
|
|
1506
|
-
end
|
|
1507
|
-
end
|
|
1508
|
-
|
|
1509
|
-
describe '.get_column_border_bottom' do
|
|
1510
|
-
it 'should return nil if no border is specified for that column in that direction' do
|
|
1511
|
-
expect(@worksheet.get_column_border_bottom(0)).to be_nil
|
|
1512
|
-
end
|
|
1513
|
-
|
|
1514
|
-
it 'should return type of border that this column has on bottom' do
|
|
1515
|
-
@worksheet.change_column_border(0, :bottom, 'thin')
|
|
1516
|
-
expect(@worksheet.get_column_border_bottom(0)).to eq('thin')
|
|
1517
|
-
end
|
|
1518
|
-
|
|
1519
|
-
it 'should cause error if a negative argument is passed in' do
|
|
1520
|
-
expect {
|
|
1521
|
-
@worksheet.get_column_border_bottom(-1)
|
|
1522
|
-
}.to raise_error
|
|
1523
|
-
end
|
|
1524
|
-
|
|
1525
|
-
it 'should return nil if a column which does not exist is passed in' do
|
|
1526
|
-
expect(@worksheet.get_column_border_bottom(11)).to be_nil
|
|
1527
|
-
end
|
|
1528
|
-
end
|
|
1529
|
-
|
|
1530
|
-
describe '.get_column_border_diagonal' do
|
|
1531
|
-
it 'should return nil if no border is specified for that column in that direction' do
|
|
1532
|
-
expect(@worksheet.get_column_border_diagonal(0)).to be_nil
|
|
1271
|
+
expect(@worksheet.get_column_border(0, :diagonal)).to be_nil
|
|
1533
1272
|
end
|
|
1534
1273
|
|
|
1535
1274
|
it 'should return type of border that this column has on diagonal' do
|
|
1536
1275
|
@worksheet.change_column_border(0, :diagonal, 'thin')
|
|
1537
|
-
|
|
1276
|
+
expect(@worksheet.get_column_border(0, :diagonal)).to eq('thin')
|
|
1538
1277
|
end
|
|
1539
1278
|
|
|
1540
1279
|
it 'should cause error if a negative argument is passed in' do
|
|
1541
1280
|
expect {
|
|
1542
|
-
@worksheet.
|
|
1281
|
+
@worksheet.get_column_border(-1, :diagonal)
|
|
1543
1282
|
}.to raise_error
|
|
1544
1283
|
end
|
|
1545
1284
|
|
|
1546
1285
|
it 'should return nil if a column which does not exist is passed in' do
|
|
1547
|
-
expect(@worksheet.
|
|
1286
|
+
expect(@worksheet.get_column_border(11, :diagonal)).to be_nil
|
|
1548
1287
|
end
|
|
1549
1288
|
end
|
|
1550
1289
|
|
|
1551
|
-
|
|
1552
1290
|
describe '@column_range' do
|
|
1553
1291
|
it 'should properly handle range addition and modification' do
|
|
1554
1292
|
# Ranges should be empty for brand new worskeet
|