RFR: 8180276: JTextPane getText return extra when mixed with methods of Document [v2]

Tejesh R duke at openjdk.java.net
Fri Apr 8 12:17:38 UTC 2022


On Fri, 8 Apr 2022 11:48:24 GMT, Alexey Ivanov <aivanov at openjdk.org> wrote:

> > > 
> > 
> > 
> > > Why can't the test be automatic?
> > 
> > 
> > Actually had thought about automating the test case, but since endOfLine(Win - '\r\n', linux - '\n') is different for different OS, have made it manual.
> 
> It just means the original issue is observed on Windows only.
> 
> Does it make sense to require Windows to run this test?

Yes, the original issue was observed and raised in Windows alone...... In Mac and Linux the control wont even enters this logic -

  if (endOfLineProperty != null && !endOfLine.equals("\n")) {
            // There is an end of line string that isn't \n, have to iterate
            // through and find all \n's and translate to end of line string.

Hence no issue in Mac and Linux..... The issue is observed only in Windows......

-------------

PR: https://git.openjdk.java.net/jdk/pull/8122



More information about the client-libs-dev mailing list