You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@netbeans.apache.org by "Andrianos Papamarkou (Jira)" <ji...@apache.org> on 2020/01/21 13:46:00 UTC

[jira] [Created] (NETBEANS-3723) GuiBuilder: titledborder creates false font definition

Andrianos Papamarkou created NETBEANS-3723:
----------------------------------------------

             Summary: GuiBuilder: titledborder creates false font definition
                 Key: NETBEANS-3723
                 URL: https://issues.apache.org/jira/browse/NETBEANS-3723
             Project: NetBeans
          Issue Type: Bug
          Components: guibuilder - Code
    Affects Versions: 11.0
         Environment: MacOSX Yosemite, Windows 10, JDK 11
            Reporter: Andrianos Papamarkou


I used the Border Dialog of the GuiBuilder to set a TitledBorder on a JTextField. I noticed that every time I change the Title Color , a font definition appears auto-created to the code.

Autocreated code before color change :

{{jTextField1.setBorder(javax.swing.BorderFactory.createTitledBorder(null, bundle.getString("TabStudentInfo.jTextField1.border.title"), javax.swing.border.TitledBorder.DEFAULT_JUSTIFICATION, javax.swing.border.TitledBorder.ABOVE_TOP)); // NOI18N}}

Autocreated false code after color change  :

{{jTextField1.setBorder(javax.swing.BorderFactory.createTitledBorder(null, bundle.getString("TabStudentInfo.jTextField1.border.title"), javax.swing.border.TitledBorder.DEFAULT_JUSTIFICATION, javax.swing.border.TitledBorder.ABOVE_TOP, *new java.awt.Font("Tahoma", 0, 11)*, java.awt.Color.pink)); // NOI18N}}

This font definition should be something like a call to the UI Defaults so we don't have to hard code the font for each component we use TitledBorder .

 



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@netbeans.apache.org
For additional commands, e-mail: commits-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists