Java Swing - (Web host sites) O Reilly public static boolean isUnderline(AttributeSet

Java Swing - O Reilly public static boolean isUnderline(AttributeSet a) These methods return the value found in the given set, if there is one. If the key is not found, the default values shown in Table 21.2 are returned. public static void setAlignment(MutableAttributeSet a, int align) public static void setBackground(MutableAttributeSet a, Color bg) public static void setBidiLevel(MutableAttributeSet a, int 0) public static void setBold(MutableAttributeSet a, boolean b) public static void setFirstLineIndent(MutableAttributeSet a, float i) public static void setFontFamily(MutableAttributeSet a, String fam) public static void setFontSize(MutableAttributeSet a, int s) public static void setForeground(MutableAttributeSet a, Color fg) public static void setItalic(MutableAttributeSet a, boolean b) public static void setLeftIndent(MutableAttributeSet a, float i) public static void setLineSpacing(MutableAttributeSet a, float i) public static void setRightIndent(MutableAttributeSet a, float i) public static void setSpaceAbove(MutableAttributeSet a, float i) public static void setSpaceBelow(MutableAttributeSet a, float i) public static void setTabSet(MutableAttributeSet a, TabSet tabs) public static void setUnderline(MutableAttributeSet a, boolean b) These methods add the appropriate attribute to the given set, replacing the existing value if there is one. The next two methods actually set two properties. In addition to setting ComponentAttribute or IconAttribute, they also set the AbstractDocument.Ele-mentNameAttribute. The values used for this property were shown back in Table 21.5. public static void setComponent(MutableAttributeSet a, Component c) public static void setIcon(MutableAttributeSet a, Icon c) 21.1.3 The TabStop Class In the last section, we came across TabSet and TabStop. Now, we’ll take quick detour from our discussion of style to examine them. TabStop, as you might guess, is used to describe a tab position. This information is used by the text view classes to correctly handle the display of tabs encountered in the document model. 21.1.3.1 Properties The TabStop class defines the properties listed in Table 21.6. The alignment property specifies how the text following a tab should be positioned relative to the tab position. The legal values for this property are shown in Table 21.7. The leader property describes what should be displayed leading up to the tab. Legal values for this property are shown in Table 21.6. Currently, none of the Swing text views use the leader property. The position property indicates where the tab should appear (in pixels). Table 21.6, TabStop Properties Property Data Type get is set bound Default Value alignment int ALIGN_LEFT leader int LEAD_NONE - 701
You need excellent and relaible webhost company to host your web applications? Then pay a visit to Inexpensive Web Hosting services.

Leave a Reply