Re: text wrap

2015-09-19 Thread Doxin via Digitalmars-d-learn
On Sunday, 20 September 2015 at 00:22:17 UTC, Joel wrote: What is simple way to wrap a string into strings? Eg from: I went for a walk and fell down a hole. To (6 max width): I went for a walk and fell down a hole. a common method works as follows. first you split your string into chunks

Re: text wrap

2015-09-19 Thread Doxin via Digitalmars-d-learn
On Sunday, 20 September 2015 at 00:28:23 UTC, Doxin wrote: I'll get to work on some example code. here you go: http://dpaste.dzfl.pl/e6e715c54c1b do mind that this code has a couple issues, for example handing it a word longer than the break width will make it loop infinitely. word wrap