[NETBEANS-5927] Switch Windows LAF to the now-standard "Segoe UI" font #3114
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
(Copied from JIRA issue description:)
For the last 14 years (since Windows Vista), the default UI font on Windows has been Segoe UI 12. But Swing's Windows LAF stayed with Tahoma 11, for reasons of backwards compatibility only (see JDK-6669448 and JDK-6723443). This makes NetBeans look a little dated, and the font size smaller than in other Windows applications. In the words of one blogger: "On a related note, this is one of the bigger visual deficiencies of NetBeans running on Vista – the smaller Tahoma font makes it less visually appealing that it could have been." ( https://www.pushing-pixels.org/2008/07/29/matching-desktop-fonts-and-native-font-rasterization.html )
This PR switches the NetBeans Windows LAF to the newer Segoe font, by borrowing logic from FlatLAF to get the actual Windows default font from the "win.messagebox.font" desktop property, which is initialized from the Win32 API. This also avoids one of the problems that were fixed in the earlier PR #1777 , with the Swing Windows LAF using incorrect font sizes on certain HiDPI configurations.
Segoe UI 12 looks similar to Tahoma 11, but with ascenders and descenders that extend one pixel farther up/down. Letters like "j" and "y" have some differences in their shapes.
Note that certain UI elements, notably the menu bar, were already using Segoe UI 12. And FlatLAF is already using Segoe UI 12 on Windows. Note also that this PR should not affect the main code editor font.
See the attached before/after screenshots.