红宝石电子表格宝石可以包装文字吗? [英] Can the ruby spreadsheet gem wrap text?
本文介绍了红宝石电子表格宝石可以包装文字吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
谢谢,
- 保罗
PS为了回应两个好的建议,不幸的是不会为我工作,我应该注意:
1)我不能将我的ruby应用程序转换为JRuby在这个时候。
2)我在Linux上开发,而不是Windows开发。
解决方案
请尝试使用Ruby电子表格gem: p>
fmt = Spreadsheet :: Format.new:text_wrap => true
sheet.row(y).set_format(x,fmt)
Is there a way to use the ruby spreadsheet gem to produce a spreadsheet with a cell whose text is wrapped? (If not, is there some other way to do it?)
Thanks, --Paul
p.s. In response to two good suggestions that unfortunately won't work for me, I should note: 1) I cannot convert my ruby application to JRuby at this time. 2) I am developing on Linux, not Windows.
解决方案
Please try this for Ruby spreadsheet gem:
fmt = Spreadsheet::Format.new :text_wrap => true
sheet.row(y).set_format(x, fmt)
form here:
这篇关于红宝石电子表格宝石可以包装文字吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文