Menu

#1961 SCI_SETPRINTWRAPMODE some values ignored

Bug
open
nobody
4
2017-07-19
2017-07-18
No

Hi,

There is a bug in line 6316 of file Editor.cxx

case SCI_SETPRINTWRAPMODE:
    view.printParameters.wrapState = (wParam == SC_WRAP_WORD) ? eWrapWord : eWrapNone;

It is ignoring other wrap modes for printing like eWrapChar. Or the SCI_SETPRINTWRAPMODE documentation is outdated and CHAR is not supported for printing anymore.

BTW, WHITESPACE is also not documented in SCI_SETPRINTWRAPMODE. If it is supported then it is also missing in the same part of the code, and in the documentation.

Best,
Scuri

Discussion

  • Neil Hodgson

    Neil Hodgson - 2017-07-19
    • labels: --> scintilla, print
    • Priority: 5 --> 4
     
  • Neil Hodgson

    Neil Hodgson - 2017-07-19

    The history of this line of code is only of adding layers of structs. It has only ever supported word wrapping.

    printWraps = wParam != 0;
    printWrapState = (wParam == SC_WRAP_WORD) ? eWrapWord : eWrapNone;
    printParameters.wrapState = (wParam == SC_WRAP_WORD) ? eWrapWord : eWrapNone;
    view.printParameters.wrapState = (wParam == SC_WRAP_WORD) ? eWrapWord : eWrapNone;
    

    Its likely the contributor of the character wrapping mode didn't look into the code for wrapping of printing.

     

Log in to post a comment.