|
|
@ -1,15 +1,13 @@ |
|
|
|
package com.fr.design.gui.style; |
|
|
|
package com.fr.design.gui.style; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
import com.fine.theme.utils.FineComponentsFactory; |
|
|
|
import com.fine.theme.utils.FineUIStyle; |
|
|
|
import com.fine.theme.utils.FineUIStyle; |
|
|
|
import com.fine.theme.utils.FineUIUtils; |
|
|
|
|
|
|
|
import com.fr.base.CoreDecimalFormat; |
|
|
|
import com.fr.base.CoreDecimalFormat; |
|
|
|
import com.fr.base.Style; |
|
|
|
import com.fr.base.Style; |
|
|
|
import com.fr.base.TextFormat; |
|
|
|
import com.fr.base.TextFormat; |
|
|
|
import com.fr.data.core.FormatField; |
|
|
|
import com.fr.data.core.FormatField; |
|
|
|
import com.fr.data.core.FormatField.FormatContents; |
|
|
|
import com.fr.data.core.FormatField.FormatContents; |
|
|
|
import com.fr.design.border.UIRoundedBorder; |
|
|
|
|
|
|
|
import com.fr.design.constants.LayoutConstants; |
|
|
|
import com.fr.design.constants.LayoutConstants; |
|
|
|
import com.fr.design.constants.UIConstants; |
|
|
|
|
|
|
|
import com.fr.design.event.GlobalNameListener; |
|
|
|
import com.fr.design.event.GlobalNameListener; |
|
|
|
import com.fr.design.event.GlobalNameObserver; |
|
|
|
import com.fr.design.event.GlobalNameObserver; |
|
|
|
import com.fr.design.event.UIObserverListener; |
|
|
|
import com.fr.design.event.UIObserverListener; |
|
|
@ -22,17 +20,11 @@ import com.fr.design.i18n.Toolkit; |
|
|
|
import com.fr.general.ComparatorUtils; |
|
|
|
import com.fr.general.ComparatorUtils; |
|
|
|
import com.fr.stable.StringUtils; |
|
|
|
import com.fr.stable.StringUtils; |
|
|
|
|
|
|
|
|
|
|
|
import javax.swing.BorderFactory; |
|
|
|
|
|
|
|
import javax.swing.JLabel; |
|
|
|
import javax.swing.JLabel; |
|
|
|
import javax.swing.JList; |
|
|
|
import javax.swing.JList; |
|
|
|
import javax.swing.UIManager; |
|
|
|
|
|
|
|
import javax.swing.border.Border; |
|
|
|
|
|
|
|
import javax.swing.border.TitledBorder; |
|
|
|
|
|
|
|
import java.awt.BorderLayout; |
|
|
|
import java.awt.BorderLayout; |
|
|
|
import java.awt.Color; |
|
|
|
import java.awt.Color; |
|
|
|
import java.awt.Component; |
|
|
|
import java.awt.Component; |
|
|
|
import java.awt.FontMetrics; |
|
|
|
|
|
|
|
import java.awt.Graphics; |
|
|
|
|
|
|
|
import java.awt.event.ItemEvent; |
|
|
|
import java.awt.event.ItemEvent; |
|
|
|
import java.awt.event.ItemListener; |
|
|
|
import java.awt.event.ItemListener; |
|
|
|
import java.math.RoundingMode; |
|
|
|
import java.math.RoundingMode; |
|
|
@ -112,14 +104,7 @@ public class TextFormatPane extends AbstractBasicStylePane implements GlobalName |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
private void initPreviewLabel4GeneralFormat() { |
|
|
|
private void initPreviewLabel4GeneralFormat() { |
|
|
|
Color labelColor = FineUIUtils.getUIColor("Label.tipColor", "inactiveCaption"); |
|
|
|
previewLabel = FineComponentsFactory.createSampleLabel(); |
|
|
|
Border interBorder = new UIRoundedBorder(UIConstants.LINE_COLOR, 0, 4); |
|
|
|
|
|
|
|
String title = Toolkit.i18nText("Fine-Design_Report_Base_StyleFormat_Sample"); |
|
|
|
|
|
|
|
Border border = BorderFactory.createTitledBorder(interBorder, title, TitledBorder.ABOVE_TOP, 0, null, labelColor); |
|
|
|
|
|
|
|
previewLabel = new UILabel(FormatField.getInstance().getFormatValue()); |
|
|
|
|
|
|
|
previewLabel.setHorizontalAlignment(UILabel.CENTER); |
|
|
|
|
|
|
|
previewLabel.setBorder(border); |
|
|
|
|
|
|
|
FineUIStyle.setStyle(previewLabel, FineUIStyle.LABEL_TIP); |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
protected void initLayout() { |
|
|
|
protected void initLayout() { |
|
|
|