--- old/src/java.desktop/share/classes/javax/swing/plaf/synth/SynthLabelUI.java 2019-05-02 04:35:19.000000000 -0700 +++ new/src/java.desktop/share/classes/javax/swing/plaf/synth/SynthLabelUI.java 2019-05-02 04:35:18.000000000 -0700 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2002, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2002, 2019, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -115,7 +115,7 @@ } JLabel label = (JLabel)c; String text = label.getText(); - if (text == null || "".equals(text)) { + if (text == null || text.isEmpty()) { return -1; } Insets i = label.getInsets();