string Content = "One major sticking point is a provision that would allow Americans to buy a federal-run insurance plan if their state allows it. Moderates say they worry the so-called public option will become a huge and costly entitlement program and that other requirements in the bill could cripple businesses.";
如何让上面的Content变量保存到一个文本文件里,且每隔40个字符自动换行:如果是空格, 就直接另起一行, 如果是单词就在39个字符后加一个连接符(-).
类似于:
My Name is Alex, th-
is is a reply that
for the purpose of
solving a text for-
matting issue.
第一行,this之间加一个"-"然后换行
第二行和第三行空格, 直接换行.
最后一行没有超过字符,直接换行.
保存文件已经实现,但是这个自动换行,搞了N就都不对.
1L不懂别乱回答.
//
目前还没有一个能用的. xuzicn也不能用
//xuzicn,你运行小郭不能满足需求.