Integrated: 5074006: Swing JOptionPane shows </html> tag as a string after newline
Prasanta Sadhukhan
psadhukhan at openjdk.org
Mon Oct 31 12:34:38 UTC 2022
On Tue, 30 Aug 2022 12:36:49 GMT, Prasanta Sadhukhan <psadhukhan at openjdk.org> wrote:
> If JOptionPane's message contains both linefeed/cursor return and HTML tag ie, **<html\>" + "This is a test\n" + "</html\>**,
> then "</html\>" will be shown in the JOptionPane dialog box because after every new line it creates a new messageComponent so the characters after the newline ie "</html\>"tag will be considered as a new JLabel string and displayed.
>
> Fix is to ignore closing html tag if appearing after newline from the displayed string.
This pull request has now been integrated.
Changeset: 91072ee3
Author: Prasanta Sadhukhan <psadhukhan at openjdk.org>
URL: https://git.openjdk.org/jdk/commit/91072ee3934616ab2edc4850a59c0a25fd0de3b4
Stats: 158 lines in 2 files changed: 118 ins; 26 del; 14 mod
5074006: Swing JOptionPane shows </html> tag as a string after newline
8042134: JOptionPane bungles HTML messages
Reviewed-by: jdv, tr
-------------
PR: https://git.openjdk.org/jdk/pull/10081
More information about the client-libs-dev
mailing list