2529N/A/*
2529N/A * Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved.
2529N/A * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
2529N/A *
2529N/A * This code is free software; you can redistribute it and/or modify it
2529N/A * under the terms of the GNU General Public License version 2 only, as
2529N/A * published by the Free Software Foundation.
2529N/A *
2529N/A * This code is distributed in the hope that it will be useful, but WITHOUT
2529N/A * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
2529N/A * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
2529N/A * version 2 for more details (a copy is included in the LICENSE file that
2529N/A * accompanied this code).
2529N/A *
2529N/A * You should have received a copy of the GNU General Public License version
2529N/A * 2 along with this work; if not, write to the Free Software Foundation,
2529N/A * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
2529N/A *
2529N/A * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
2529N/A * or visit www.oracle.com if you need additional information or have any
2529N/A * questions.
2529N/A */
2529N/A
2529N/A/*
2529N/A * @test
2529N/A * @bug 4760089
2529N/A * @summary Tests that titled border do not paint inner titled border over its caption
2529N/A * @author Sergey Malenkov
2529N/A * @run applet/manual=yesno Test4760089.html
2529N/A */
2529N/A
2529N/Aimport javax.swing.JApplet;
2529N/Aimport javax.swing.JPanel;
2529N/Aimport javax.swing.border.Border;
2529N/Aimport javax.swing.border.EtchedBorder;
2529N/Aimport javax.swing.border.TitledBorder;
2529N/A
2529N/Apublic class Test4760089 extends JApplet {
2529N/A @Override
2529N/A public void init() {
2529N/A Border border = new EtchedBorder();
2529N/A border = new TitledBorder(border, "LEFT", TitledBorder.LEFT, TitledBorder.TOP);
2529N/A border = new TitledBorder(border, "RIGHT", TitledBorder.RIGHT, TitledBorder.TOP);
2529N/A
2529N/A JPanel panel = new JPanel();
2529N/A panel.setBorder(border);
2529N/A getContentPane().add(panel);
2529N/A }
2529N/A}