Permalink
Browse files

include applyAlignment attribute when adding style

  • Loading branch information...
1 parent f9f5f3c commit 5c680582c20a2f976daeceaaab5b326f70d5f466 @ochko ochko committed Mar 14, 2012
Showing with 3 additions and 2 deletions.
  1. +1 −0 lib/axlsx/stylesheet/styles.rb
  2. +2 −2 test/stylesheet/tc_styles.rb
@@ -230,6 +230,7 @@ def add_style(options={})
if options[:alignment]
xf.alignment = CellAlignment.new(options[:alignment])
+ xf.applyAlignment = true
end
if applyProtection
@@ -49,8 +49,8 @@ def test_add_style
assert_equal(xf.applyProtection, 1, "protection applied")
assert_equal(xf.applyBorder, true, "border applied")
- assert_equal(xf.applyNumberFormat, true, "border applied")
-
+ assert_equal(xf.applyNumberFormat, true, "number format applied")
+ assert_equal(xf.applyAlignment, true, "alignment applied")
end
end

0 comments on commit 5c68058

Please sign in to comment.