0N/A/*
1879N/A * Copyright (c) 2006, 2007, Oracle and/or its affiliates. All rights reserved.
0N/A * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
0N/A *
0N/A * This code is free software; you can redistribute it and/or modify it
0N/A * under the terms of the GNU General Public License version 2 only, as
0N/A * published by the Free Software Foundation.
0N/A *
0N/A * This code is distributed in the hope that it will be useful, but WITHOUT
0N/A * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
0N/A * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
0N/A * version 2 for more details (a copy is included in the LICENSE file that
0N/A * accompanied this code).
0N/A *
0N/A * You should have received a copy of the GNU General Public License version
0N/A * 2 along with this work; if not, write to the Free Software Foundation,
0N/A * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
0N/A *
1472N/A * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
1472N/A * or visit www.oracle.com if you need additional information or have any
1472N/A * questions.
0N/A */
0N/A
0N/A/*
1879N/A * @test
1879N/A * @bug 6402062 6487891
1879N/A * @summary Tests TitledBorder encoding
1879N/A * @author Sergey Malenkov
1879N/A */
1879N/A
1879N/Aimport java.awt.Color;
1879N/Aimport java.awt.Font;
1879N/Aimport javax.swing.border.EmptyBorder;
1879N/Aimport javax.swing.border.TitledBorder;
1879N/A
1879N/Apublic final class javax_swing_border_TitledBorder extends AbstractTest<TitledBorder> {
0N/A public static void main(String[] args) {
1879N/A new javax_swing_border_TitledBorder().test(true);
0N/A }
0N/A
0N/A protected TitledBorder getObject() {
0N/A return new TitledBorder(
0N/A new EmptyBorder(1, 2, 3, 4),
0N/A "TITLE",
0N/A TitledBorder.CENTER,
0N/A TitledBorder.ABOVE_TOP,
0N/A new Font("Arial", Font.ITALIC, 12),
0N/A Color.RED);
0N/A }
0N/A
0N/A protected TitledBorder getAnotherObject() {
0N/A return null; // TODO: could not update property
0N/A // return new TitledBorder("title");
0N/A }
0N/A}
0N/A