Re: RFR: 8012675: Javadoc for javax.swing.text.html.parser.Parser.handleComment() needs to be updated [v14]

2022-06-15 Thread Alexey Ivanov
On Wed, 15 Jun 2022 17:27:53 GMT, Damon Nguyen wrote: >> Updated Parser class doc by appending to the doc regarding lack of support >> for HTML script tags. Adding this information to the "parse" function did >> not seem as consistent for formatting as adding it to the Parser class doc. > > Dam

Re: RFR: 8012675: Javadoc for javax.swing.text.html.parser.Parser.handleComment() needs to be updated [v16]

2022-06-16 Thread Alexey Ivanov
On Thu, 16 Jun 2022 07:59:08 GMT, Damon Nguyen wrote: >> Updated Parser class doc by appending to the doc regarding lack of support >> for HTML script tags. Adding this information to the "parse" function did >> not seem as consistent for formatting as adding it to the Parser class doc. > > Dam

Re: RFR: 8012675: Javadoc for javax.swing.text.html.parser.Parser.handleComment() needs to be updated [v16]

2022-06-16 Thread Alexey Ivanov
On Thu, 16 Jun 2022 20:34:00 GMT, Alexey Ivanov wrote: > The `` tag before `@implNote` is unneeded, javadoc will generate a section > code. It must be removed, it results in `make docs` failure: === Output from failing command(s) repeated here === * For

Re: RFR: 8284672: Collapse identical catch branches in java.desktop [v2]

2022-06-17 Thread Alexey Ivanov
On Thu, 16 Jun 2022 03:49:34 GMT, Sergey Bylokhov wrote: >> Yeah. I think it makes sense to amend behavior here and not catch >> IOException. Callers should be ready for it. > > This getSoundbank method is called when we iterate over providers and check > which can be used, unfortunately, that

Re: RFR: 8284672: Collapse identical catch branches in java.desktop [v2]

2022-06-17 Thread Alexey Ivanov
On Wed, 1 Jun 2022 20:55:30 GMT, Andrey Turbanov wrote: >> Let's take advantage of Java 7 language feature - "Catching Multiple >> Exception Types". >> It simplifies code. Reduces duplication. >> Found by IntelliJ IDEA inspection Identical 'catch' branches in 'try' >> statement > > Andrey Turba

Re: RFR: 8288528: broken links in java.desktop

2022-06-17 Thread Alexey Ivanov
On Fri, 17 Jun 2022 03:45:05 GMT, Prasanta Sadhukhan wrote: > doccheck reports some broken links which are rectified Marked as reviewed by aivanov (Reviewer). src/java.desktop/share/classes/java/awt/doc-files/AWTThreadIssues.html line 124: > 122: > 123: Starting with 1.4, the behavior has ch

Re: RFR: 8012675: Javadoc for javax.swing.text.html.parser.Parser.handleComment() needs to be updated [v17]

2022-06-17 Thread Alexey Ivanov
On Thu, 16 Jun 2022 21:31:45 GMT, Damon Nguyen wrote: >> Updated Parser class doc by appending to the doc regarding lack of support >> for HTML script tags. Adding this information to the "parse" function did >> not seem as consistent for formatting as adding it to the Parser class doc. > > Dam

Re: RFR: 8012675: Javadoc for javax.swing.text.html.parser.Parser.handleComment() needs to be updated [v18]

2022-06-17 Thread Alexey Ivanov
On Fri, 17 Jun 2022 17:43:59 GMT, Damon Nguyen wrote: >> Updated Parser class doc by appending to the doc regarding lack of support >> for HTML script tags. Adding this information to the "parse" function did >> not seem as consistent for formatting as adding it to the Parser class doc. > > Dam

Re: RFR: 8288528: broken links in java.desktop [v2]

2022-06-17 Thread Alexey Ivanov
On Fri, 17 Jun 2022 17:14:56 GMT, Prasanta Sadhukhan wrote: >> doccheck reports some broken links which are rectified > > Prasanta Sadhukhan has updated the pull request incrementally with one > additional commit since the last revision: > > Review comment fix Marked as reviewed by aivanov

Re: RFR: 8012675: Javadoc for javax.swing.text.html.parser.Parser.handleComment() needs to be updated [v18]

2022-06-17 Thread Alexey Ivanov
On Fri, 17 Jun 2022 17:43:59 GMT, Damon Nguyen wrote: >> Updated Parser class doc by appending to the doc regarding lack of support >> for HTML script tags. Adding this information to the "parse" function did >> not seem as consistent for formatting as adding it to the Parser class doc. > > Dam

Re: RFR: 8012675: Javadoc for javax.swing.text.html.parser.Parser.handleComment() needs to be updated [v17]

2022-06-21 Thread Alexey Ivanov
On Fri, 17 Jun 2022 17:37:59 GMT, Damon Nguyen wrote: >> src/java.desktop/share/classes/javax/swing/text/html/HTMLEditorKit.java line >> 1312: >> >>> 1310: * Tags display the tag text as editable text >>> fields. >>> 1311: * The content within the tags will be handled

Re: RFR: 8272998: ImageIO.read() throws incorrect exception type

2022-06-22 Thread Alexey Ivanov
On Thu, 9 Jun 2022 19:53:22 GMT, Phil Race wrote: > ImageIO.read() only documents IOException for any kind of decoding problem > and since > it is a convenience API we don't want to start requiring applications to > handle other RuntimeExceptions. > So in the unlikely case of some problem decod

Re: RFR: 8287609: macOS: SIGSEGV at [CoreFoundation] CFArrayGetCount / sun.font.CFont.getTableBytesNative

2022-06-22 Thread Alexey Ivanov
On Sun, 5 Jun 2022 15:38:21 GMT, Phil Race wrote: >> `CTFontCopyAvailableTables` can return null, which causes subsequent call to >> `CFArrayGetCount` to crash with SEGFAULT, just added a null-check. > > how do to backports is documented here : > https://wiki.openjdk.java.net/display/SKARA/Back

Re: RFR: 8288528: broken links in java.desktop

2022-06-23 Thread Alexey Ivanov
On Tue, 21 Jun 2022 20:13:08 GMT, Alexey Ivanov wrote: > Should the copyright year be updated? This applies to all the files, not only `ExifTIFFTagSet.java`. - PR: https://git.openjdk.org/jdk19/pull/44

Re: RFR: 8288528: broken links in java.desktop

2022-06-23 Thread Alexey Ivanov
On Mon, 20 Jun 2022 07:35:14 GMT, Abhishek Kumar wrote: > doccheck reports some broken links which are rectified. copyright year > updated for files. Should the copyright year be updated? Marked as reviewed by aivanov (Reviewer). src/java.desktop/share/classes/javax/imageio/plugins/tiff/ExifT

Re: RFR: JDK-8288993: Make AwtFramePackTest generic by removing @requires tag [v2]

2022-06-27 Thread Alexey Ivanov
On Fri, 24 Jun 2022 00:53:35 GMT, Harshitha Onkar wrote: >> The following test was changed to generic based on this [Review >> Comment](https://urldefense.com/v3/__https://github.com/openjdk/jdk/pull/9118*discussion_r897553780__;Iw!!ACWV5N9M2RV99hQ!OD1nHoXjAVjPcd0j0DcrLavC4sicxaeyU7EjyHZ14_HypMb

Re: RFR: JDK-8289238: Refactoring changes to PassFailJFrame Test Framework [v2]

2022-06-29 Thread Alexey Ivanov
On Tue, 28 Jun 2022 20:30:36 GMT, Harshitha Onkar wrote: >> Currently PassFailJFrame.positionTestFrame() and >> PassFailJFrame.addTestFrame() take Frame as input parameter, this has been >> changed to Window. >> >> Refactored the above method names to reflect the functionality & input >> para

Re: [jdk19] RFR: 8288854: getLocalGraphicsEnvironment() on for multi-screen setups throws exception NPE

2022-06-29 Thread Alexey Ivanov
On Mon, 27 Jun 2022 21:17:54 GMT, Sergey Bylokhov wrote: > This is the fix for a copy-paste error. The fix JDK-8076313 replaced the > usage of the "screens" array from the parent class to the "devices" where the > list of devices is now maintained. Since "screens" array is never used nor > ini

Re: RFR: JDK-8289238: Refactoring changes to PassFailJFrame Test Framework [v2]

2022-06-29 Thread Alexey Ivanov
On Tue, 28 Jun 2022 20:30:36 GMT, Harshitha Onkar wrote: >> Currently PassFailJFrame.positionTestFrame() and >> PassFailJFrame.addTestFrame() take Frame as input parameter, this has been >> changed to Window. >> >> Refactored the above method names to reflect the functionality & input >> para

Re: RFR: 8065097: [macosx] javax/swing/Popup/TaskbarPositionTest.java fails because Popup is one pixel off

2022-06-29 Thread Alexey Ivanov
On Wed, 29 Jun 2022 08:28:20 GMT, Prasanta Sadhukhan wrote: > Test seems to fail in macOS citing popup location is 1 pixel off compared to > combobox position ie > `p.y 154 cpos.y 155` > > But in macOS, popup location, if 1st entry is selected, is 1 pixel higher > than combobox so it's expect

Re: RFR: JDK-8289238: Refactoring changes to PassFailJFrame Test Framework [v4]

2022-06-29 Thread Alexey Ivanov
On Wed, 29 Jun 2022 17:17:11 GMT, Harshitha Onkar wrote: >> Currently PassFailJFrame.positionTestFrame() and >> PassFailJFrame.addTestFrame() take Frame as input parameter, this has been >> changed to Window. >> >> Refactored the above method names to reflect the functionality & input >> para

Re: RFR: 8288882: JFileChooser - empty (0 bytes) file is displayed as 1 KB

2022-06-29 Thread Alexey Ivanov
On Wed, 29 Jun 2022 13:06:21 GMT, Abhishek Kumar wrote: > JFileChooser - empty file size issue fixed. > For empty file, now the size 0 bytes. > Manual Test Case "ZeroFileSizeCheck.java" created. Changes requested by aivanov (Reviewer). test/jdk/javax/swing/JFileChooser/ZeroFileSizeCheck.java l

Re: RFR: 8288882: JFileChooser - empty (0 bytes) file is displayed as 1 KB

2022-06-29 Thread Alexey Ivanov
On Wed, 29 Jun 2022 15:26:57 GMT, Andy Goryachev wrote: > Also, will this code work correctly for non-English locales? It won't. It has to use `MessageFormat` and it has to add a new string to the resource bundle. - PR: https://git.openjdk.org/jdk/pull/9327

Re: RFR: 8065097: [macosx] javax/swing/Popup/TaskbarPositionTest.java fails because Popup is one pixel off [v3]

2022-06-30 Thread Alexey Ivanov
On Thu, 30 Jun 2022 08:57:16 GMT, Prasanta Sadhukhan wrote: >> Test seems to fail in macOS citing popup location is 1 pixel off compared to >> combobox position ie >> `p.y 154 cpos.y 155` >> >> But in macOS, popup location, if 1st entry is selected, is 1 pixel higher >> than combobox so it's

Re: RFR: 8288882: JFileChooser - empty (0 bytes) file is displayed as 1 KB

2022-06-30 Thread Alexey Ivanov
On Thu, 30 Jun 2022 17:37:30 GMT, Alexey Ivanov wrote: >> It is introduced in JDK12. If this has to be backported to 8, that's not an >> option. > > I think we should follow the current format for the time being and show the > file size similar to how its shown in nat

Re: RFR: 8288882: JFileChooser - empty (0 bytes) file is displayed as 1 KB

2022-06-30 Thread Alexey Ivanov
On Thu, 30 Jun 2022 16:36:41 GMT, Naoto Sato wrote: >> Would java.text.CompactNumberFormat work for java 8? > > It is introduced in JDK12. If this has to be backported to 8, that's not an > option. I think we should follow the current format for the time being and show the file size similar to

Re: RFR: 8288882: JFileChooser - empty (0 bytes) file is displayed as 1 KB

2022-06-30 Thread Alexey Ivanov
On Thu, 30 Jun 2022 16:31:21 GMT, Harshitha Onkar wrote: >> JFileChooser - empty file size issue fixed. >> For empty file, now the size 0 bytes. >> Manual Test Case "ZeroFileSizeCheck.java" created. > > test/jdk/javax/swing/JFileChooser/ZeroFileSizeCheck.java line 74: > >> 72: PassF

Re: RFR: 8065097: [macosx] javax/swing/Popup/TaskbarPositionTest.java fails because Popup is one pixel off [v3]

2022-06-30 Thread Alexey Ivanov
On Thu, 30 Jun 2022 16:41:06 GMT, Alexey Ivanov wrote: > However, the test does not behave as it should on macOS. Additionally, the > position of combo box popups aren't verified (except for the last one). > > Anyway, these other issues are out of scope of this one. I submi

Re: RFR: 8287603: Avoid redundant HashMap.containsKey calls in NimbusDefaults.getDerivedColor

2022-07-04 Thread Alexey Ivanov
On Sat, 30 Apr 2022 09:33:38 GMT, Andrey Turbanov wrote: > The method > `javax.swing.plaf.nimbus.NimbusDefaults#getDerivedColor(String,String,float,float,float,int,boolean)` > could be improved by usage of Map.putIfAbsent instead of separate > `containsKey`/`get`/`put` calls. We known that Has

Re: RFR: 8282578: AIOOBE in javax.sound.sampled.Clip

2022-07-04 Thread Alexey Ivanov
On Fri, 3 Jun 2022 15:43:39 GMT, Alexander Zuev wrote: > Add try/catch clause to ignore an exception since it is harmless for we > isolated > the massge data before passing it ro processor. > Add test case. Marked as reviewed by aivanov (Reviewer). - PR: https://git.openjdk.org/jd

Re: RFR: 8282526: Default icon is not painted properly [v4]

2022-07-05 Thread Alexey Ivanov
On Thu, 9 Jun 2022 10:37:30 GMT, Alexey Ivanov wrote: > > I am not going trough all the experiments with the SHDefExtractIcon again - > > at least not in this pull request. > > I absolutely agree, not in this pull request. > > However, I'm for submitting

Re: RFR: 8288882: JFileChooser - empty (0 bytes) file is displayed as 1 KB [v3]

2022-07-07 Thread Alexey Ivanov
On Wed, 6 Jul 2022 12:30:07 GMT, Abhishek Kumar wrote: > In Windows, it uses ShellFolder to set FileSize column values and it is > returned in terms of bytes in stead of KB (as shown by native tools). This doesn't seem to be true for Windows, I see "0 KB" and "1 KB" for zero-byte and one-byte

Re: RFR: 8288882: JFileChooser - empty (0 bytes) file is displayed as 1 KB [v3]

2022-07-07 Thread Alexey Ivanov
On Thu, 7 Jul 2022 04:43:44 GMT, Abhishek Kumar wrote: >> src/java.desktop/share/classes/com/sun/swing/internal/plaf/basic/resources/basic.properties >> line 80: >> >>> 78: >>> 79: # File Size Units >>> 80: FileChooser.fileSizeBytes={0} bytes >> >> should it be "{0} B" to be consistent with t

Re: RFR: 8288882: JFileChooser - empty (0 bytes) file is displayed as 1 KB [v3]

2022-07-08 Thread Alexey Ivanov
On Wed, 6 Jul 2022 11:59:31 GMT, Abhishek Kumar wrote: >> JFileChooser - empty file size issue fixed. >> For empty file, now the size 0 bytes. >> Manual Test Case "ZeroFileSizeCheck.java" created. > > Abhishek Kumar has updated the pull request incrementally with one additional > commit since t

Re: RFR: 8288882: JFileChooser - empty (0 bytes) file is displayed as 1 KB [v3]

2022-07-08 Thread Alexey Ivanov
On Thu, 7 Jul 2022 14:42:51 GMT, Andy Goryachev wrote: > (better) remove any alignment by using only one space. I'm for using just one space as you would in a regular assignment. - PR: https://git.openjdk.org/jdk/pull/9327

Re: RFR: 8288882: JFileChooser - empty (0 bytes) file is displayed as 1 KB [v3]

2022-07-08 Thread Alexey Ivanov
On Thu, 7 Jul 2022 20:08:50 GMT, Andy Goryachev wrote: >> Shall we handle "1 byte"? > > good point! that's why I suggested "{0} B" > plural rules can be quite complex, see > http://www.unicode.org/cldr/cldr-aux/charts/22/supplemental/language_plural_rules.html > > example: in Arabic, there are

Re: RFR: 8224267: JOptionPane message string with 5000+ newlines produces StackOverflowError

2022-07-08 Thread Alexey Ivanov
On Wed, 6 Jul 2022 05:57:00 GMT, Prasanta Sadhukhan wrote: > BasicOptionPaneUI.addMessageComponents() uses recursion to split message > strings at newlines, generating a StackOverflowError when the message string > contains an unusually large number of newlines. > Fixed by catching StackOverfl

Re: RFR: 8282526: Default icon is not painted properly [v6]

2022-07-08 Thread Alexey Ivanov
On Tue, 21 Jun 2022 03:04:29 GMT, Sergey Bylokhov wrote: > Before the JDK-8182043 we also used the MRI so it should be changed if the > scale was changed from low to hidpi. It adds more variants which could be > used by some other DPI, I think one important new variant is the 64x64 > because i

Re: RFR: 8282526: Default icon is not painted properly [v4]

2022-07-08 Thread Alexey Ivanov
On Thu, 9 Jun 2022 09:52:42 GMT, Alexey Ivanov wrote: >>> No, because in case when current implementation returns bad results this >>> function also returns incorrect results so it is hardly a backup. >> >> Are you sure? That article said the opposite and suggest

Re: RFR: 8282526: Default icon is not painted properly [v7]

2022-07-08 Thread Alexey Ivanov
On Wed, 6 Jul 2022 18:17:41 GMT, Alexander Zuev wrote: >> Detect the situation where we do need to perform interpolation during >> ImageIcon >> painting and set a hint to the rendering to perform bicubic approximation so >> image details are preserved during transition. > > Alexander Zuev has up

Re: RFR: 8224267: JOptionPane message string with 5000+ newlines produces StackOverflowError

2022-07-08 Thread Alexey Ivanov
On Fri, 8 Jul 2022 13:12:19 GMT, Prasanta Sadhukhan wrote: > > Maybe we should rather limit the number of recursive calls? You caught > > `StackOverflowError`, at this stage there's not much space left on the > > stack. It may cause another `StackOverflowError`. > > I thought that but then th

Re: RFR: 8282526: Default icon is not painted properly [v6]

2022-07-08 Thread Alexey Ivanov
On Fri, 8 Jul 2022 15:02:08 GMT, Alexey Ivanov wrote: >>> > That was the whole purpose of the initial 8182043 issue, to provide a >>> > HiDPI(or various DPI) icons for the user. If the user asks for the 16x16 >>> > we will provide them the MRI where t

Re: RFR: 8224267: JOptionPane message string with 5000+ newlines produces StackOverflowError [v3]

2022-07-11 Thread Alexey Ivanov
On Mon, 11 Jul 2022 09:28:22 GMT, Prasanta Sadhukhan wrote: >> BasicOptionPaneUI.addMessageComponents() uses recursion to split message >> strings at newlines, generating a StackOverflowError when the message string >> contains an unusually large number of newlines. >> Fixed by catching StackO

Re: RFR: 8224267: JOptionPane message string with 5000+ newlines produces StackOverflowError [v3]

2022-07-11 Thread Alexey Ivanov
On Mon, 11 Jul 2022 11:34:49 GMT, Prasanta Sadhukhan wrote: > I guess if it's not successive, it will not exercise this condition so it > will not recurse as much > > ``` > if (nl >= 0) { > // break up newlines > if (nl == 0) { > ``` In that sense? I thought ab

Re: RFR: 8224267: JOptionPane message string with 5000+ newlines produces StackOverflowError [v3]

2022-07-11 Thread Alexey Ivanov
On Mon, 11 Jul 2022 09:28:22 GMT, Prasanta Sadhukhan wrote: >> BasicOptionPaneUI.addMessageComponents() uses recursion to split message >> strings at newlines, generating a StackOverflowError when the message string >> contains an unusually large number of newlines. >> Fixed by catching StackO

Re: RFR: 8224267: JOptionPane message string with 5000+ newlines produces StackOverflowError [v3]

2022-07-11 Thread Alexey Ivanov
On Mon, 11 Jul 2022 12:29:43 GMT, Prasanta Sadhukhan wrote: > > Hm… there could be problem: **the counter isn't reset** when the function > > is called again. It's reset only when the limit is reached. Or do I miss > > another case where the counter is reset? > > > > The easiest way could be t

Re: RFR: 8282526: Default icon is not painted properly [v8]

2022-07-18 Thread Alexey Ivanov
On Fri, 15 Jul 2022 19:15:52 GMT, Alexander Zuev wrote: >> Detect the situation where we do need to perform interpolation during >> ImageIcon >> painting and set a hint to the rendering to perform bicubic approximation so >> image details are preserved during transition. > > Alexander Zuev has u

Re: RFR: 8281966: Absolute path of symlink is null in JFileChooser

2022-07-29 Thread Alexey Ivanov
On Thu, 21 Jul 2022 18:31:46 GMT, Tejesh R wrote: > Absolute path of Symbolic Link created in Windows is set to `null` in > `BasicFileChooserUI` class. This happens when propertyChangeListener is > implemented to get the Symbolic link's Absolute path on Mouse click through > JFileChooser. The

Re: RFR: 8281966: Absolute path of symlink is null in JFileChooser

2022-07-29 Thread Alexey Ivanov
On Fri, 29 Jul 2022 18:14:14 GMT, Alexey Ivanov wrote: >> Absolute path of Symbolic Link created in Windows is set to `null` in >> `BasicFileChooserUI` class. This happens when propertyChangeListener is >> implemented to get the Symbolic link's Absolute path

Re: RFR: JDK-8290469: Add new positioning options to PassFailJFrame test framework [v4]

2022-08-02 Thread Alexey Ivanov
On Thu, 21 Jul 2022 00:27:04 GMT, Harshitha Onkar wrote: >> Additional position setting (TOP_LEFT_CORNER) and a method to obtain bounds >> of test instruction frame are added to PassFailJFrame to handle positioning >> of multiple test frames. >> >> In scenarios where multiple test windows migh

Re: RFR: 8281966: Absolute path of symlink is null in JFileChooser [v2]

2022-08-03 Thread Alexey Ivanov
On Mon, 1 Aug 2022 10:27:03 GMT, Tejesh R wrote: >> Absolute path of Symbolic Link created in Windows is set to `null` in >> `BasicFileChooserUI` class. This happens when propertyChangeListener is >> implemented to get the Symbolic link's Absolute path on Mouse click through >> JFileChooser. T

Re: RFR: 8281966: Absolute path of symlink is null in JFileChooser [v2]

2022-08-03 Thread Alexey Ivanov
On Wed, 3 Aug 2022 07:55:33 GMT, Tejesh R wrote: >> test/jdk/javax/swing/JFileChooser/FileChooserSymLinkTest.java line 76: >> >>> 74: 2. Create a Symbolic link targeting the created test >>> directory. >>> 75: ex : mklink /D c:\\link c:\\target >>> 76:

Re: RFR: 8281966: Absolute path of symlink is null in JFileChooser [v3]

2022-08-03 Thread Alexey Ivanov
On Wed, 3 Aug 2022 14:04:34 GMT, Tejesh R wrote: >> Absolute path of Symbolic Link created in Windows is set to `null` in >> `BasicFileChooserUI` class. This happens when propertyChangeListener is >> implemented to get the Symbolic link's Absolute path on Mouse click through >> JFileChooser. T

Re: RFR: 8281966: Absolute path of symlink is null in JFileChooser [v2]

2022-08-04 Thread Alexey Ivanov
On Wed, 3 Aug 2022 15:50:37 GMT, Tejesh R wrote: > In the single-selection case, I see the following output: > > ``` > Absolute Path : null > Absolute Path : C:\filechooser\link > ``` Sorry about that. Upon re-testing, this scenario worked fine with your original changes. > For link it doesn'

Re: RFR: 8281966: Absolute path of symlink is null in JFileChooser [v4]

2022-08-04 Thread Alexey Ivanov
On Thu, 4 Aug 2022 12:08:15 GMT, Tejesh R wrote: >> Absolute path of Symbolic Link created in Windows is set to `null` in >> `BasicFileChooserUI` class. This happens when propertyChangeListener is >> implemented to get the Symbolic link's Absolute path on Mouse click through >> JFileChooser. T

Re: RFR: 8281966: Absolute path of symlink is null in JFileChooser [v5]

2022-08-04 Thread Alexey Ivanov
On Thu, 4 Aug 2022 18:45:21 GMT, Tejesh R wrote: >> Absolute path of Symbolic Link created in Windows is set to `null` in >> `BasicFileChooserUI` class. This happens when propertyChangeListener is >> implemented to get the Symbolic link's Absolute path on Mouse click through >> JFileChooser. T

Re: RFR: 8281966: Absolute path of symlink is null in JFileChooser [v6]

2022-08-05 Thread Alexey Ivanov
On Fri, 5 Aug 2022 05:46:20 GMT, Tejesh R wrote: >> Absolute path of Symbolic Link created in Windows is set to `null` in >> `BasicFileChooserUI` class. This happens when propertyChangeListener is >> implemented to get the Symbolic link's Absolute path on Mouse click through >> JFileChooser. T

Re: RFR: JDK-8292276 : Add named colors from CSS Color Module Level 4 [v29]

2023-05-25 Thread Alexey Ivanov
has updated the pull request incrementally with one additional > commit since the last revision: > > Update src/java.desktop/share/classes/javax/swing/text/html/StyleSheet.java > > Remove space. > > Co-authored-by: Alexey Ivanov It's not a problem even if it gets close

Re: RFR: 8294535 : Add screen capture functionality to PassFailJFrame

2023-05-25 Thread Alexey Ivanov
On Wed, 24 May 2023 23:07:11 GMT, Harshitha Onkar wrote: > Here is a consolidated review and few suggestions - > > Firstly, the use of builder pattern for screenshot capability looks well > structured and clean. It is easy for extensibility and does not break the > existing functionality. Thi

Re: RFR: 8307105: JFileChooser InvalidPathException when selecting some system folders on Windows [v3]

2023-05-25 Thread Alexey Ivanov
On Thu, 25 May 2023 07:15:10 GMT, Tejesh R wrote: > Since `FileSystemView.isFileSystem` is used in many places for particular > Look and Feel, there might be chances of regression. So how about checking > for shell folder first and if yes then can combine the `shell.isFileSystem()` > with `isS

Re: RFR: 8307105: JFileChooser InvalidPathException when selecting some system folders on Windows [v3]

2023-05-25 Thread Alexey Ivanov
On Thu, 25 May 2023 11:39:33 GMT, Alexey Ivanov wrote: >>> I understand that, virtual folders don't have a filesystem path, this is >>> why `fsv.isFileSystem(f)` should handle this situation. The implementation >>> of `FileSystemView.isFileSystem` explicit

Re: RFR: 8294535 : Add screen capture functionality to PassFailJFrame

2023-05-25 Thread Alexey Ivanov
On Thu, 25 May 2023 17:47:59 GMT, Harshitha Onkar wrote: > > It saves the images to _the current directory_. When the test is run by > > jtreg, the current directory is the `scratch` directory. > > For me, the generated screenshot was being saved to the test folder, as I was > running it as st

Re: RFR: 8307105: JFileChooser InvalidPathException when selecting some system folders on Windows [v3]

2023-05-26 Thread Alexey Ivanov
On Thu, 25 May 2023 13:58:17 GMT, Tejesh R wrote: >> As for other Look-and-Feels, `isFileSystem` is used for the same purpose >> that it's used in the code you're modifying: if a selected object in the >> list is a file system object (a directory), the text field to the path of >> the selected

Re: RFR: 8307105: JFileChooser InvalidPathException when selecting some system folders on Windows [v3]

2023-05-26 Thread Alexey Ivanov
On Fri, 26 May 2023 14:00:16 GMT, Alexey Ivanov wrote: > Another option is to modify `isFileSystem` so that it returns `true` for all > filesystem objects, excluding the added condition that it should be not a > link to directory. I assume this is required to ensure `JFileChooser

Re: RFR: 8307105: JFileChooser InvalidPathException when selecting some system folders on Windows [v3]

2023-05-26 Thread Alexey Ivanov
On Fri, 26 May 2023 14:27:22 GMT, Tejesh R wrote: > So now two modifications are required. > > 1. Modify `isLink` of win32ShellFolder class to return true only if its > `.lnk`. This should be enough to fix this bug. And this should enable the support for Windows junctions too. -

Re: RFR: 8307105: JFileChooser InvalidPathException when selecting some system folders on Windows [v3]

2023-05-26 Thread Alexey Ivanov
On Fri, 26 May 2023 14:38:54 GMT, Tejesh R wrote: >>> So now two modifications are required. >>> >>> 1. Modify `isLink` of win32ShellFolder class to return true only if its >>> `.lnk`. >> >> This should be enough to fix this bug. >> >> This should enable the support for Windows junctions too

Re: RFR: 8294535 : Add screen capture functionality to PassFailJFrame

2023-05-26 Thread Alexey Ivanov
On Fri, 26 May 2023 19:30:36 GMT, Harshitha Onkar wrote: > > If the displayed message isn't modal, like a tooltip or a notification > > which disappears automatically after a certain time, it could be better > > appreciated. But it's harder to implement. > > We could use Timer for disappearing

Re: RFR: 8309060: Compilation Error in javax/swing/event/FocusEventCauseTest.java

2023-05-29 Thread Alexey Ivanov
On Mon, 29 May 2023 16:16:57 GMT, Prasanta Sadhukhan wrote: > Inadvertent extraneous semicolon causing compilation error is fixed. Marked as reviewed by aivanov (Reviewer). - PR Review: https://git.openjdk.org/jdk/pull/14206#pullrequestreview-1449776207

Re: RFR: 8309095 : Remove UTF-8 character from TaskbarPositionTest.java

2023-05-30 Thread Alexey Ivanov
On Tue, 30 May 2023 11:22:06 GMT, Renjith Kannath Pariyangad wrote: > Hi Reviewers, > Removed UTF-8 character (↓) from TaskbarPositionTest.java from the testcase. > Please review this > Regards, > Renjith. Marked as reviewed by aivanov (Reviewer). - PR Review: https://git.openjdk

Re: RFR: JDK-8294427 - Check boxes and radio buttons have rendering issues on Windows in High DPI env [v6]

2023-05-30 Thread Alexey Ivanov
On Sun, 28 May 2023 22:23:27 GMT, Rajat Mahajan wrote: >> Problem: >> >> Check boxes and radio buttons in Windows Look-and-Feel have rendering issues >> when window is moved from display with one scale to display with a different >> scale on a multi-monitor setup: >> >> - Scrawly ticks in che

Re: RFR: JDK-8294427 - Check boxes and radio buttons have rendering issues on Windows in High DPI env [v6]

2023-05-30 Thread Alexey Ivanov
On Sun, 28 May 2023 22:23:27 GMT, Rajat Mahajan wrote: >> Problem: >> >> Check boxes and radio buttons in Windows Look-and-Feel have rendering issues >> when window is moved from display with one scale to display with a different >> scale on a multi-monitor setup: >> >> - Scrawly ticks in che

Re: RFR: JDK-8294427 - Check boxes and radio buttons have rendering issues on Windows in High DPI env [v6]

2023-05-30 Thread Alexey Ivanov
On Sun, 28 May 2023 22:23:27 GMT, Rajat Mahajan wrote: >> Problem: >> >> Check boxes and radio buttons in Windows Look-and-Feel have rendering issues >> when window is moved from display with one scale to display with a different >> scale on a multi-monitor setup: >> >> - Scrawly ticks in che

Re: RFR: JDK-8294427 - Check boxes and radio buttons have rendering issues on Windows in High DPI env [v6]

2023-05-30 Thread Alexey Ivanov
On Tue, 30 May 2023 15:43:57 GMT, Alexey Ivanov wrote: >> Rajat Mahajan has updated the pull request incrementally with one additional >> commit since the last revision: >> >> changes as siggested in review > > src/java.desktop/windows/classes/sun/awt/win

Re: RFR: 7083187: Class CSS.CssValue is missing implementations of equals() and hashCode() [v10]

2023-05-30 Thread Alexey Ivanov
On Tue, 30 May 2023 17:18:48 GMT, Prasanta Sadhukhan wrote: >> src/java.desktop/share/classes/javax/swing/text/html/CSS.java line 2225: >> >>> 2223: return val instanceof CSS.FontSize size >>> 2224:&& Objects.equals(size.svalue, svalue); >>> 2225:

Re: RFR: 8307105: JFileChooser InvalidPathException when selecting some system folders on Windows [v7]

2023-05-30 Thread Alexey Ivanov
On Tue, 30 May 2023 07:08:47 GMT, Tejesh R wrote: >> This is a regression from fix >> [JDK-8281966](https://bugs.openjdk.org/browse/JDK-8281966): Absolute path of >> symlink is null in JFileChooser. The fix checks whether the file path is a >> symbolic link using `Files.isSymbolicLink()` metho

Re: RFR: 7083187: Class CSS.CssValue is missing implementations of equals() and hashCode() [v10]

2023-05-31 Thread Alexey Ivanov
On Wed, 31 May 2023 03:09:12 GMT, Prasanta Sadhukhan wrote: > I already told using your suggested code fails the regression test.. Which regression test do you refer to? The one for `AttributeSet.equals` or another? I can't see how implementing `equals` could affect other tests… unless some

Re: RFR: 7083187: Class CSS.CssValue is missing implementations of equals() and hashCode() [v10]

2023-05-31 Thread Alexey Ivanov
On Tue, 30 May 2023 17:18:42 GMT, Prasanta Sadhukhan wrote: >> src/java.desktop/share/classes/javax/swing/text/html/CSS.java line 2219: >> >>> 2217: public int hashCode() { >>> 2218: return Float.hashCode(value); >>> 2219: } >> >> why isn't index and lu part of this

Re: RFR: 8307105: JFileChooser InvalidPathException when selecting some system folders on Windows [v8]

2023-05-31 Thread Alexey Ivanov
On Wed, 31 May 2023 06:13:22 GMT, Tejesh R wrote: >> This is a regression from fix >> [JDK-8281966](https://bugs.openjdk.org/browse/JDK-8281966): Absolute path of >> symlink is null in JFileChooser. The fix checks whether the file path is a >> symbolic link using `Files.isSymbolicLink()` metho

Re: RFR: 7083187: Class CSS.CssValue is missing implementations of equals() and hashCode() [v10]

2023-05-31 Thread Alexey Ivanov
On Wed, 31 May 2023 09:23:38 GMT, Prasanta Sadhukhan wrote: >> Yet `equals` currently just compares `svalue`… It looks weird. > > It might looks weird but it is the one which is working. > For example, for `{"font-size: 42px", "font-size: 22px"}` > > `value` is 0.0 > `svalue` is 42px, 22px > `i

Re: RFR: 8307105: JFileChooser InvalidPathException when selecting some system folders on Windows [v9]

2023-05-31 Thread Alexey Ivanov
On Wed, 31 May 2023 09:52:29 GMT, Tejesh R wrote: >> This is a regression from fix >> [JDK-8281966](https://bugs.openjdk.org/browse/JDK-8281966): Absolute path of >> symlink is null in JFileChooser. The fix checks whether the file path is a >> symbolic link using `Files.isSymbolicLink()` metho

Re: RFR: 8307105: JFileChooser InvalidPathException when selecting some system folders on Windows [v10]

2023-05-31 Thread Alexey Ivanov
On Wed, 31 May 2023 10:01:16 GMT, Tejesh R wrote: >> This is a regression from fix >> [JDK-8281966](https://bugs.openjdk.org/browse/JDK-8281966): Absolute path of >> symlink is null in JFileChooser. The fix checks whether the file path is a >> symbolic link using `Files.isSymbolicLink()` metho

Re: RFR: JDK-8294427 - Check boxes and radio buttons have rendering issues on Windows in High DPI env [v6]

2023-05-31 Thread Alexey Ivanov
On Tue, 30 May 2023 16:04:55 GMT, Alexey Ivanov wrote: >> src/java.desktop/windows/classes/sun/awt/windows/ThemeReader.java line 131: >> >>> 129: } >>> 130: dpiAwareWidgetToT

Re: RFR: JDK-8299052 : ViewportOverlapping test fails intermittently on Win10 & Win11

2023-06-02 Thread Alexey Ivanov
On Fri, 2 Jun 2023 17:56:42 GMT, Harshitha Onkar wrote: > ViewportOverlapping test was failing intermittently during CI runs on Win10 > and Win11. > > Although this intermittent issue wasn't replicable when the individual test > as well as the test group was run multiple times, a defensive fi

Re: RFR: JDK-8299052 : ViewportOverlapping test fails intermittently on Win10 & Win11

2023-06-02 Thread Alexey Ivanov
On Fri, 2 Jun 2023 17:56:42 GMT, Harshitha Onkar wrote: > ViewportOverlapping test was failing intermittently during CI runs on Win10 > and Win11. > > Although this intermittent issue wasn't replicable when the individual test > as well as the test group was run multiple times, a defensive fi

RFR: 8297923: java.awt.ScrollPane broken after multiple scroll up/down

2023-06-06 Thread Alexey Ivanov
**Problem description** If you grab the thumb of the scroll bar of `ScrollPane` and drag it slowly and continuously up and down, you'll notice the UI stops rendering correctly: the child component of the scroll pane will render on the left of the frame itself, the inside of the scroll pane will

Re: RFR: 8297923: java.awt.ScrollPane broken after multiple scroll up/down

2023-06-06 Thread Alexey Ivanov
On Tue, 6 Jun 2023 16:07:53 GMT, Alexey Ivanov wrote: > **Problem description** > > If you grab the thumb of the scroll bar of `ScrollPane` and drag it slowly > and continuously up and down, you'll notice the UI stops rendering correctly: > the child component of the scr

Re: RFR: 8297923: java.awt.ScrollPane broken after multiple scroll up/down

2023-06-06 Thread Alexey Ivanov
On Tue, 6 Jun 2023 18:17:42 GMT, Phil Race wrote: >> **Problem description** >> >> If you grab the thumb of the scroll bar of `ScrollPane` and drag it slowly >> and continuously up and down, you'll notice the UI stops rendering >> correctly: the child component of the scroll pane will render o

Re: RFR: 8297923: java.awt.ScrollPane broken after multiple scroll up/down

2023-06-06 Thread Alexey Ivanov
On Tue, 6 Jun 2023 18:38:10 GMT, Harshitha Onkar wrote: >> src/java.desktop/windows/native/libawt/windows/awt_ScrollPane.cpp line 745: >> >>> 743: ssps->y = y; >>> 744: >>> 745: >>> AwtToolkit::GetInstance().InvokeFunctionLater(AwtScrollPane::_SetScrollPos, >>> ssps); >> >> Whereas i

Re: RFR: 8297923: java.awt.ScrollPane broken after multiple scroll up/down

2023-06-06 Thread Alexey Ivanov
On Tue, 6 Jun 2023 18:38:32 GMT, Harshitha Onkar wrote: > When running the test without the fix, I had to introduce a small delay after > the frame is maximized again to see the light-green block outside the canvas. You can use the test case attached to [JDK-8297923](https://bugs.openjdk.org/b

Re: RFR: JDK-8294427 - Check boxes and radio buttons have rendering issues on Windows in High DPI env [v9]

2023-06-06 Thread Alexey Ivanov
On Thu, 1 Jun 2023 19:56:28 GMT, Rajat Mahajan wrote: >> Problem: >> >> Check boxes and radio buttons in Windows Look-and-Feel have rendering issues >> when window is moved from display with one scale to display with a different >> scale on a multi-monitor setup: >> >> - Scrawly ticks in chec

Re: RFR: JDK-8294427 - Check boxes and radio buttons have rendering issues on Windows in High DPI env [v9]

2023-06-06 Thread Alexey Ivanov
On Tue, 2 May 2023 15:27:16 GMT, Alexey Ivanov wrote: >> Rajat Mahajan has updated the pull request incrementally with one additional >> commit since the last revision: >> >> code changes as per code review > > src/java.desktop/windows/native/libawt/wi

Re: RFR: 8297923: java.awt.ScrollPane broken after multiple scroll up/down

2023-06-07 Thread Alexey Ivanov
On Wed, 7 Jun 2023 03:30:51 GMT, Sergey Bylokhov wrote: > If it is unused can we delete it? It's possible. Yet I'd rather leave it for another time. There's also a specific `WM_AWT_SET_SCROLL_INFO` message to call `::SetScrollInfo`. This message is never used, it can also be removed.

Re: RFR: 8297923: java.awt.ScrollPane broken after multiple scroll up/down

2023-06-07 Thread Alexey Ivanov
On Wed, 7 Jun 2023 04:08:49 GMT, Sergey Bylokhov wrote: > Probably we should update the Java_sun_awt_windows_WScrollbarPeer_setValues > as well? it calls the SetScrollInfo You're right. It needs to be updated too. However, I'd rather do it separately. - PR Comment: https://git.ope

Re: RFR: JDK-8299052 : ViewportOverlapping test fails intermittently on Win10 & Win11 [v2]

2023-06-07 Thread Alexey Ivanov
On Tue, 6 Jun 2023 22:55:06 GMT, Harshitha Onkar wrote: >> test/jdk/java/awt/Mixing/AWT_Mixing/ViewportOverlapping.java line 164: >> >>> 162: OverlappingTestBase.doMain(args); >>> 163: captureScreen("Img_5.png"); >>> 164: } >> >> It is just a test, so no need to over-enginee

Re: RFR: 7083187: Class CSS.CssValue is missing implementations of equals() and hashCode() [v15]

2023-06-07 Thread Alexey Ivanov
On Fri, 2 Jun 2023 08:12:55 GMT, Prasanta Sadhukhan wrote: >> Two CSS AttributeSet-s can be compared using the AttributeSet.isEqual() >> method which can fail due to missing implementation of equals method in CSS >> subclasses. >> In this issue, even when two CSS AttributeSet has same 42 font

Re: RFR: 7083187: Class CSS.CssValue is missing implementations of equals() and hashCode() [v12]

2023-06-07 Thread Alexey Ivanov
On Thu, 1 Jun 2023 02:59:57 GMT, Prasanta Sadhukhan wrote: >> Prasanta Sadhukhan has updated the pull request incrementally with one >> additional commit since the last revision: >> >> Use local objects for FontSize as per review comment > > @prrace @aivanov-jdk Any further comments on this

Re: RFR: 7083187: Class CSS.CssValue is missing implementations of equals() and hashCode() [v15]

2023-06-07 Thread Alexey Ivanov
On Wed, 7 Jun 2023 12:45:12 GMT, Alexey Ivanov wrote: > `BorderWidthValue` (it could be handled automatically by its superclass, > `LengthValue`) Yep, it's handled correctly `"border-width: medium"` passes the test. > This comparison could fail for the case where th

Re: RFR: 7083187: Class CSS.CssValue is missing implementations of equals() and hashCode() [v15]

2023-06-07 Thread Alexey Ivanov
On Fri, 2 Jun 2023 08:12:55 GMT, Prasanta Sadhukhan wrote: >> Two CSS AttributeSet-s can be compared using the AttributeSet.isEqual() >> method which can fail due to missing implementation of equals method in CSS >> subclasses. >> In this issue, even when two CSS AttributeSet has same 42 font

Re: RFR: 7083187: Class CSS.CssValue is missing implementations of equals() and hashCode() [v15]

2023-06-07 Thread Alexey Ivanov
On Wed, 7 Jun 2023 13:55:06 GMT, Alexey Ivanov wrote: >> src/java.desktop/share/classes/javax/swing/text/html/CSS.java line 2684: >> >>> 2682: if (percentage) { >>> 2683: return val instanceof CSS.LengthValue lu >>> 2684:

Re: RFR: 7083187: Class CSS.CssValue is missing implementations of equals() and hashCode() [v15]

2023-06-07 Thread Alexey Ivanov
On Wed, 7 Jun 2023 14:21:08 GMT, Alexey Ivanov wrote: >>> This comparison could fail for the case where there's a space before the >>> `%` in the string. >> >> `FontSize` does handle `{"font-size: 100%", "font-size: 100 %"}` pair, but

  1   2   3   4   5   6   7   8   9   10   >