Fixes #688 by adding an configuration variable copy_to_clipboard_wysiwyg. When this variable is nonzero :ccopy will act the same way it did before this PR. When it is zero, :ccopy will now copy a full string representation of the selected range by calculating the necessary widths . When copy_to_clipboard_delimited_tab != 0:ccopy already copies a full representation, so we don't calculate anything new in this case. Documentation has been updated accordingly.
The logic for when to emit tabs was inconsistent, so I also fixed that. Tabs are now only emitted when copy_to_clipboard_delimited_tab != 0.
I also fixed a bug in pad_and_align(). There were some uses of wmemset(str_out, ...) which then immediately returned from pad_and_align() without null terminating; this is fixed. I also removed some unecessary calls to wcslen().
Fixes #688 by adding an configuration variable
copy_to_clipboard_wysiwyg
. When this variable is nonzero:ccopy
will act the same way it did before this PR. When it is zero,:ccopy
will now copy a full string representation of the selected range by calculating the necessary widths . Whencopy_to_clipboard_delimited_tab != 0
:ccopy already copies a full representation, so we don't calculate anything new in this case. Documentation has been updated accordingly.The logic for when to emit tabs was inconsistent, so I also fixed that. Tabs are now only emitted when
copy_to_clipboard_delimited_tab != 0
.I also fixed a bug in
pad_and_align()
. There were some uses ofwmemset(str_out, ...)
which then immediately returned frompad_and_align()
without null terminating; this is fixed. I also removed some unecessary calls towcslen()
.I also fixed some grammar in the documentation.