icecream icon indicating copy to clipboard operation
icecream copied to clipboard

Disable/Delete line wrap

Open KarlRW opened this issue 3 years ago • 1 comments

There are two issues that mention line wrap (linked below). I'm making this issue because I think disabling/deleting line wrap is going to be easier to code than the other two issues. Most editors can handle line wrapping for you. Having a specific wrap hard coded in makes IC not very nice to use.

Even a hacky way to disable/delete it would be nice if someone figured it out.

https://github.com/gruns/icecream/issues/90 - This one has mention of disabling line wrap but its buried under a more complex request. https://github.com/gruns/icecream/issues/60 - The main problem... if we could set line wrap to 2000 it would be the same as disabling.

KarlRW avatar Feb 19 '23 01:02 KarlRW

Copied reply from #60

preferredWidth = 2000
pp = pprint.PrettyPrinter(width=preferredWidth)
ic.configureOutput(argToStringFunction=pp.pformat)
ic.lineWrapWidth = preferredWidth

Gleiphnir avatar Nov 08 '23 17:11 Gleiphnir