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