summaryrefslogtreecommitdiffhomepage
path: root/lib/axlsx/stylesheet/styles.rb
diff options
context:
space:
mode:
authorGeremia Taglialatela <[email protected]>2023-04-10 11:45:57 +0200
committerGeremia Taglialatela <[email protected]>2023-04-10 11:45:57 +0200
commit84a2b255d6fd780f526ac3d9bf99a40f08792986 (patch)
treecea31975973b14e6a7e2879bd43a561ad0bfa59d /lib/axlsx/stylesheet/styles.rb
parent1406b47e64188765f220be86001ec1f543e0157d (diff)
downloadcaxlsx-84a2b255d6fd780f526ac3d9bf99a40f08792986.tar.gz
caxlsx-84a2b255d6fd780f526ac3d9bf99a40f08792986.zip
Fix Layout/LeadingCommentSpace offenses
``` rubocop --only Layout/LeadingCommentSpace -a ```
Diffstat (limited to 'lib/axlsx/stylesheet/styles.rb')
-rw-r--r--lib/axlsx/stylesheet/styles.rb8
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/axlsx/stylesheet/styles.rb b/lib/axlsx/stylesheet/styles.rb
index 2a210776..ca2c7a8c 100644
--- a/lib/axlsx/stylesheet/styles.rb
+++ b/lib/axlsx/stylesheet/styles.rb
@@ -17,7 +17,7 @@ module Axlsx
require 'axlsx/stylesheet/xf.rb'
require 'axlsx/stylesheet/cell_protection.rb'
- #The Styles class manages worksheet styles
+ # The Styles class manages worksheet styles
# In addition to creating the require style objects for a valid xlsx package, this class provides the key mechanism for adding styles to your workbook, and safely applying them to the cells of your worksheet.
# All portions of the stylesheet are implemented here exception colors, which specify legacy and modified pallete colors, and exLst, whic is used as a future feature data storage area.
# @see Office Open XML Part 1 18.8.11 for gory details on how this stuff gets put together
@@ -468,10 +468,10 @@ module Axlsx
def parse_num_fmt_options(options = {})
return if (options.keys & [:format_code, :num_fmt]).empty?
- #When the user provides format_code - we always need to create a new numFmt object
- #When the type is :dxf we always need to create a new numFmt object
+ # When the user provides format_code - we always need to create a new numFmt object
+ # When the type is :dxf we always need to create a new numFmt object
if options[:format_code] || options[:type] == :dxf
- #If this is a standard xf we pull from numFmts the highest current and increment for num_fmt
+ # If this is a standard xf we pull from numFmts the highest current and increment for num_fmt
options[:num_fmt] ||= (@numFmts.map { |num_fmt| num_fmt.numFmtId }.max + 1) if options[:type] != :dxf
numFmt = NumFmt.new(:numFmtId => options[:num_fmt] || 0, :formatCode => options[:format_code].to_s)
options[:type] == :dxf ? numFmt : (numFmts << numFmt; numFmt.numFmtId)