0001: /*
0002: * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
0003: *
0004: * Copyright 1997-2007 Sun Microsystems, Inc. All rights reserved.
0005: *
0006: * The contents of this file are subject to the terms of either the GNU
0007: * General Public License Version 2 only ("GPL") or the Common
0008: * Development and Distribution License("CDDL") (collectively, the
0009: * "License"). You may not use this file except in compliance with the
0010: * License. You can obtain a copy of the License at
0011: * http://www.netbeans.org/cddl-gplv2.html
0012: * or nbbuild/licenses/CDDL-GPL-2-CP. See the License for the
0013: * specific language governing permissions and limitations under the
0014: * License. When distributing the software, include this License Header
0015: * Notice in each file and include the License file at
0016: * nbbuild/licenses/CDDL-GPL-2-CP. Sun designates this
0017: * particular file as subject to the "Classpath" exception as provided
0018: * by Sun in the GPL Version 2 section of the License file that
0019: * accompanied this code. If applicable, add the following below the
0020: * License Header, with the fields enclosed by brackets [] replaced by
0021: * your own identifying information:
0022: * "Portions Copyrighted [year] [name of copyright owner]"
0023: *
0024: * Contributor(s):
0025: *
0026: * The Original Software is NetBeans. The Initial Developer of the Original
0027: * Software is Sun Microsystems, Inc. Portions Copyright 1997-2007 Sun
0028: * Microsystems, Inc. All Rights Reserved.
0029: *
0030: * If you wish your version of this file to be governed by only the CDDL
0031: * or only the GPL Version 2, indicate your decision by adding
0032: * "[Contributor] elects to include this software in this distribution
0033: * under the [CDDL or GPL Version 2] license." If you do not indicate a
0034: * single choice of license, a recipient has the option to distribute
0035: * your version of this file under either the CDDL, the GPL Version 2 or
0036: * to extend the choice of license to its licensees as provided above.
0037: * However, if you add GPL Version 2 code and therefore, elected the GPL
0038: * Version 2 license, then the option applies only if the new code is
0039: * made subject to such option by the copyright holder.
0040: */
0041: package org.netbeans.modules.visualweb.propertyeditors.css;
0042:
0043: import org.netbeans.modules.visualweb.propertyeditors.css.model.CssStyleData;
0044: import org.netbeans.modules.visualweb.propertyeditors.css.model.PropertyData;
0045: import org.netbeans.modules.visualweb.propertyeditors.css.model.PropertyWithUnitData;
0046: import org.netbeans.modules.visualweb.propertyeditors.css.model.TextBlockData;
0047: import org.netbeans.modules.visualweb.propertyeditors.css.model.TextBlockModel;
0048: import org.netbeans.modules.visualweb.propertyeditors.css.model.Utils;
0049: import java.awt.event.FocusAdapter;
0050: import java.awt.event.FocusEvent;
0051: import javax.swing.DefaultComboBoxModel;
0052: import javax.swing.Icon;
0053: import javax.swing.JPanel;
0054: import javax.swing.JTextField;
0055: import javax.swing.SwingUtilities;
0056: import org.openide.util.NbBundle;
0057:
0058: /**
0059: * Text Block Style editor.
0060: * @author Winston Prakash
0061: * Jeff Hoffman (HIE design)
0062: */
0063: public class TextBlockStyleEditor extends StyleEditor {
0064:
0065: CssStyleData cssStyleData = null;
0066: PropertyData directionData = new PropertyData();
0067: PropertyData textAlignData = new PropertyData();
0068: PropertyData verticalAlignData = new PropertyWithUnitData();
0069: PropertyWithUnitData wordSpacingData = new PropertyWithUnitData();
0070: PropertyWithUnitData letterSpacingData = new PropertyWithUnitData();
0071: PropertyWithUnitData lineHeightData = new PropertyWithUnitData();
0072: PropertyWithUnitData textIndentData = new PropertyWithUnitData();
0073:
0074: /** Creates new form FontStyleEditor */
0075: public TextBlockStyleEditor(CssStyleData styleData) {
0076: cssStyleData = styleData;
0077: setName("textBlockStyleEditor"); //NOI18N
0078: setDisplayName(NbBundle.getMessage(StyleBuilderDialog.class,
0079: "TEXTBLOCK_EDITOR_DISPNAME"));
0080: initComponents();
0081: initialize();
0082:
0083: // Add editor listeners to the border width combobox
0084: final JTextField textIndentComboEditor = (JTextField) textIndentCombo
0085: .getEditor().getEditorComponent();
0086: textIndentComboEditor
0087: .addKeyListener(new java.awt.event.KeyAdapter() {
0088: public void keyTyped(java.awt.event.KeyEvent evt) {
0089: SwingUtilities.invokeLater(new Runnable() {
0090: public void run() {
0091: textIndentUnitCombo
0092: .setEnabled(Utils
0093: .isInteger(textIndentComboEditor
0094: .getText()));
0095: }
0096: });
0097: }
0098: });
0099:
0100: // Add editor listeners to the border width combobox
0101: final JTextField wordSpacingComboEditor = (JTextField) wordSpacingCombo
0102: .getEditor().getEditorComponent();
0103: wordSpacingComboEditor
0104: .addKeyListener(new java.awt.event.KeyAdapter() {
0105: public void keyTyped(java.awt.event.KeyEvent evt) {
0106: SwingUtilities.invokeLater(new Runnable() {
0107: public void run() {
0108: wordSpacingUnitCombo
0109: .setEnabled(Utils
0110: .isInteger(wordSpacingComboEditor
0111: .getText()));
0112: }
0113: });
0114: }
0115: });
0116:
0117: // Add editor listeners to the border width combobox
0118: final JTextField letterSpacingComboEditor = (JTextField) letterSpacingCombo
0119: .getEditor().getEditorComponent();
0120: letterSpacingComboEditor
0121: .addKeyListener(new java.awt.event.KeyAdapter() {
0122: public void keyTyped(java.awt.event.KeyEvent evt) {
0123: SwingUtilities.invokeLater(new Runnable() {
0124: public void run() {
0125: letterSpacingUnitCombo
0126: .setEnabled(Utils
0127: .isInteger(letterSpacingComboEditor
0128: .getText()));
0129: }
0130: });
0131: }
0132: });
0133:
0134: // Add editor listeners to the border width combobox
0135: final JTextField lineHeightComboEditor = (JTextField) lineHeightCombo
0136: .getEditor().getEditorComponent();
0137: lineHeightComboEditor
0138: .addKeyListener(new java.awt.event.KeyAdapter() {
0139: public void keyTyped(java.awt.event.KeyEvent evt) {
0140: SwingUtilities.invokeLater(new Runnable() {
0141: public void run() {
0142: lineHeightUnitCombo
0143: .setEnabled(Utils
0144: .isInteger(lineHeightComboEditor
0145: .getText()));
0146: }
0147: });
0148: }
0149: });
0150: }
0151:
0152: private void initialize() {
0153: TextBlockModel textBlockModel = new TextBlockModel();
0154: TextBlockData textBlockData = new TextBlockData();
0155:
0156: // Set the Horizontal Alignment to the GUI
0157: DefaultComboBoxModel horizontalAlignList = textBlockModel
0158: .getHorizontalAlignmentList();
0159: horizontalAlignCombo.setModel(horizontalAlignList);
0160: String horizontalAlign = cssStyleData
0161: .getProperty(CssStyleData.TEXT_ALIGN);
0162: if (horizontalAlign != null) {
0163: horizontalAlignCombo.setSelectedItem(horizontalAlign);
0164: } else {
0165: horizontalAlignCombo.setSelectedIndex(0);
0166: }
0167:
0168: // Set the Vertical Alignment to the GUI
0169: DefaultComboBoxModel verticalAlignList = textBlockModel
0170: .getVerticalAlignmentList();
0171: verticalAlignCombo.setModel(verticalAlignList);
0172: String verticalAlign = cssStyleData
0173: .getProperty(CssStyleData.VERTICAL_ALIGN);
0174: if (verticalAlign != null) {
0175: textBlockData.setVerticalAlign(verticalAlign);
0176: verticalAlignCombo.setSelectedItem(textBlockData
0177: .getVerticalAlignValue());
0178: } else {
0179: verticalAlignCombo.setSelectedIndex(0);
0180: }
0181:
0182: // Set the Indentation to the GUI
0183: DefaultComboBoxModel indentationList = textBlockModel
0184: .getIndentationList();
0185: textIndentCombo.setModel(indentationList);
0186: textIndentUnitCombo.setModel(textBlockModel
0187: .getTextBlockUnitList());
0188: String indentation = cssStyleData
0189: .getProperty(CssStyleData.TEXT_INDENT);
0190: if (indentation != null) {
0191: textBlockData.setIndentation(indentation);
0192: textIndentCombo.setSelectedItem(textBlockData
0193: .getIndentationValue());
0194: textIndentUnitCombo.setSelectedItem(textBlockData
0195: .getIndentationUnit());
0196: } else {
0197: textIndentCombo.setSelectedIndex(0);
0198: textIndentUnitCombo.setSelectedIndex(0);
0199: }
0200:
0201: // Set the Text Direction to the GUI
0202: DefaultComboBoxModel textDirectionList = textBlockModel
0203: .getTextDirectionList();
0204: directionCombo.setModel(textDirectionList);
0205: String textDirection = cssStyleData
0206: .getProperty(CssStyleData.DIRECTION);
0207: if (textDirection != null) {
0208: directionCombo.setSelectedItem(textDirection);
0209: } else {
0210: directionCombo.setSelectedIndex(0);
0211: }
0212:
0213: // Set the Word Spacing to the GUI
0214: DefaultComboBoxModel wordSpacingList = textBlockModel
0215: .getWordSpacingList();
0216: wordSpacingCombo.setModel(wordSpacingList);
0217: wordSpacingUnitCombo.setModel(textBlockModel
0218: .getTextBlockUnitList());
0219: String wordSpacing = cssStyleData
0220: .getProperty(CssStyleData.WORD_SPACING);
0221: if (wordSpacing != null) {
0222: textBlockData.setWordSpacing(wordSpacing);
0223: wordSpacingCombo.setSelectedItem(textBlockData
0224: .getWordSpacingValue());
0225: wordSpacingUnitCombo.setSelectedItem(textBlockData
0226: .getWordSpacingUnit());
0227: } else {
0228: wordSpacingCombo.setSelectedIndex(0);
0229: wordSpacingUnitCombo.setSelectedIndex(0);
0230: }
0231:
0232: // Set the Letter Spacing to the GUI
0233: DefaultComboBoxModel letterSpacingList = textBlockModel
0234: .getLetterSpacingList();
0235: letterSpacingCombo.setModel(letterSpacingList);
0236: letterSpacingUnitCombo.setModel(textBlockModel
0237: .getTextBlockUnitList());
0238: String letterSpacing = cssStyleData
0239: .getProperty(CssStyleData.LETTER_SPACING);
0240: if (letterSpacing != null) {
0241: textBlockData.setLetterSpacing(letterSpacing);
0242: letterSpacingCombo.setSelectedItem(textBlockData
0243: .getLetterSpacingValue());
0244: letterSpacingUnitCombo.setSelectedItem(textBlockData
0245: .getLetterSpacingUnit());
0246: } else {
0247: letterSpacingCombo.setSelectedIndex(0);
0248: letterSpacingUnitCombo.setSelectedIndex(0);
0249: }
0250:
0251: // Set the Letter Spacing to the GUI
0252: DefaultComboBoxModel lineHeightList = textBlockModel
0253: .getLineHeightList();
0254: lineHeightCombo.setModel(lineHeightList);
0255: lineHeightUnitCombo.setModel(textBlockModel
0256: .getTextBlockUnitList());
0257: String lineHeight = cssStyleData
0258: .getProperty(CssStyleData.LINE_HEIGHT);
0259: if (lineHeight != null) {
0260: textBlockData.setLineHeight(lineHeight);
0261: lineHeightCombo.setSelectedItem(textBlockData
0262: .getLineHeightValue());
0263: lineHeightUnitCombo.setSelectedItem(textBlockData
0264: .getLineHeightUnit());
0265: } else {
0266: lineHeightCombo.setSelectedIndex(0);
0267: lineHeightUnitCombo.setSelectedIndex(0);
0268: }
0269:
0270: textIndentCombo.getEditor().getEditorComponent()
0271: .addFocusListener(new FocusAdapter() {
0272: public void focusGained(FocusEvent evt) {
0273: errorLabel
0274: .setText(CssStyleData.PREVIEW_NOT_SUPPORTED);
0275: }
0276:
0277: public void focusLost(FocusEvent evt) {
0278: errorLabel.setText("");
0279: }
0280: });
0281:
0282: directionCombo.addFocusListener(new FocusAdapter() {
0283: public void focusGained(FocusEvent evt) {
0284: errorLabel.setText(CssStyleData.PREVIEW_NOT_SUPPORTED);
0285: }
0286:
0287: public void focusLost(FocusEvent evt) {
0288: errorLabel.setText("");
0289: }
0290: });
0291:
0292: letterSpacingCombo.getEditor().getEditorComponent()
0293: .addFocusListener(new FocusAdapter() {
0294: public void focusGained(FocusEvent evt) {
0295: errorLabel
0296: .setText(CssStyleData.PREVIEW_NOT_SUPPORTED);
0297: }
0298:
0299: public void focusLost(FocusEvent evt) {
0300: errorLabel.setText("");
0301: }
0302: });
0303:
0304: wordSpacingCombo.getEditor().getEditorComponent()
0305: .addFocusListener(new FocusAdapter() {
0306: public void focusGained(FocusEvent evt) {
0307: errorLabel
0308: .setText(CssStyleData.PREVIEW_NOT_SUPPORTED);
0309: }
0310:
0311: public void focusLost(FocusEvent evt) {
0312: errorLabel.setText("");
0313: }
0314: });
0315: }
0316:
0317: // <editor-fold defaultstate="collapsed" desc=" Generated Code ">//GEN-BEGIN:initComponents
0318: private void initComponents() {
0319: java.awt.GridBagConstraints gridBagConstraints;
0320:
0321: textBlockPanel = new javax.swing.JPanel();
0322: decorationLabel = new javax.swing.JLabel();
0323: imageScroll = new javax.swing.JLabel();
0324: directionCombo = new javax.swing.JComboBox();
0325: horizontalAlignCombo = new javax.swing.JComboBox();
0326: textAlignLabel = new javax.swing.JLabel();
0327: jLabel2 = new javax.swing.JLabel();
0328: textIndentCombo = new javax.swing.JComboBox();
0329: verticalAlignCombo = new javax.swing.JComboBox();
0330: wordSpacingUnitCombo = new javax.swing.JComboBox();
0331: imageScroll1 = new javax.swing.JLabel();
0332: wordSpacingCombo = new javax.swing.JComboBox();
0333: imageScroll2 = new javax.swing.JLabel();
0334: letterSpacingCombo = new javax.swing.JComboBox();
0335: letterSpacingUnitCombo = new javax.swing.JComboBox();
0336: textIndentUnitCombo = new javax.swing.JComboBox();
0337: lineHeightLabel = new javax.swing.JLabel();
0338: lineHeightCombo = new javax.swing.JComboBox();
0339: lineHeightUnitCombo = new javax.swing.JComboBox();
0340: errorPanel = new javax.swing.JPanel();
0341: errorLabel = new javax.swing.JLabel();
0342:
0343: setLayout(new java.awt.BorderLayout());
0344:
0345: textBlockPanel.setLayout(new java.awt.GridBagLayout());
0346:
0347: textBlockPanel.setBorder(javax.swing.BorderFactory
0348: .createEmptyBorder(5, 5, 5, 5));
0349: decorationLabel.setText(org.openide.util.NbBundle.getMessage(
0350: TextBlockStyleEditor.class, "TEXT_INDENTATION"));
0351: gridBagConstraints = new java.awt.GridBagConstraints();
0352: gridBagConstraints.gridx = 0;
0353: gridBagConstraints.gridy = 2;
0354: gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
0355: gridBagConstraints.insets = new java.awt.Insets(10, 0, 0, 10);
0356: textBlockPanel.add(decorationLabel, gridBagConstraints);
0357:
0358: imageScroll.setText(org.openide.util.NbBundle.getMessage(
0359: TextBlockStyleEditor.class, "TEXT_DIRECTION"));
0360: gridBagConstraints = new java.awt.GridBagConstraints();
0361: gridBagConstraints.gridx = 0;
0362: gridBagConstraints.gridy = 3;
0363: gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
0364: gridBagConstraints.insets = new java.awt.Insets(5, 0, 0, 10);
0365: textBlockPanel.add(imageScroll, gridBagConstraints);
0366:
0367: directionCombo
0368: .addItemListener(new java.awt.event.ItemListener() {
0369: public void itemStateChanged(
0370: java.awt.event.ItemEvent evt) {
0371: directionComboItemStateChanged(evt);
0372: }
0373: });
0374:
0375: gridBagConstraints = new java.awt.GridBagConstraints();
0376: gridBagConstraints.gridx = 1;
0377: gridBagConstraints.gridy = 3;
0378: gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
0379: gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
0380: gridBagConstraints.insets = new java.awt.Insets(5, 0, 0, 0);
0381: textBlockPanel.add(directionCombo, gridBagConstraints);
0382: directionCombo
0383: .getAccessibleContext()
0384: .setAccessibleName(
0385: java.util.ResourceBundle
0386: .getBundle(
0387: "org/netbeans/modules/visualweb/propertyeditors/css/Bundle")
0388: .getString("DIRECTION_ACCESS_NAME"));
0389: directionCombo
0390: .getAccessibleContext()
0391: .setAccessibleDescription(
0392: java.util.ResourceBundle
0393: .getBundle(
0394: "org/netbeans/modules/visualweb/propertyeditors/css/Bundle")
0395: .getString("DIRECTION_ACCESS_DESC"));
0396:
0397: horizontalAlignCombo
0398: .addFocusListener(new java.awt.event.FocusAdapter() {
0399: public void focusLost(java.awt.event.FocusEvent evt) {
0400: horizontalAlignComboFocusLost(evt);
0401: }
0402: });
0403: horizontalAlignCombo
0404: .addItemListener(new java.awt.event.ItemListener() {
0405: public void itemStateChanged(
0406: java.awt.event.ItemEvent evt) {
0407: horizontalAlignComboItemStateChanged(evt);
0408: }
0409: });
0410:
0411: gridBagConstraints = new java.awt.GridBagConstraints();
0412: gridBagConstraints.gridx = 1;
0413: gridBagConstraints.gridy = 0;
0414: gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
0415: gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
0416: gridBagConstraints.insets = new java.awt.Insets(6, 0, 0, 0);
0417: textBlockPanel.add(horizontalAlignCombo, gridBagConstraints);
0418: horizontalAlignCombo
0419: .getAccessibleContext()
0420: .setAccessibleName(
0421: java.util.ResourceBundle
0422: .getBundle(
0423: "org/netbeans/modules/visualweb/propertyeditors/css/Bundle")
0424: .getString(
0425: "HORIZONTAL_ALIGNMENT_COMBOBOX_ACCESS_NAME"));
0426: horizontalAlignCombo
0427: .getAccessibleContext()
0428: .setAccessibleDescription(
0429: java.util.ResourceBundle
0430: .getBundle(
0431: "org/netbeans/modules/visualweb/propertyeditors/css/Bundle")
0432: .getString(
0433: "HORIZONTAL_ALIGNMENT_COMBOBOX_ACCESS_DESC"));
0434:
0435: textAlignLabel.setText(org.openide.util.NbBundle.getMessage(
0436: TextBlockStyleEditor.class, "TEXT_HORIZ_ALIGN"));
0437: gridBagConstraints = new java.awt.GridBagConstraints();
0438: gridBagConstraints.gridx = 0;
0439: gridBagConstraints.gridy = 0;
0440: gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
0441: gridBagConstraints.insets = new java.awt.Insets(6, 0, 0, 10);
0442: textBlockPanel.add(textAlignLabel, gridBagConstraints);
0443:
0444: jLabel2.setText(org.openide.util.NbBundle.getMessage(
0445: TextBlockStyleEditor.class, "TEXT_VERTICAL_ALIGN"));
0446: gridBagConstraints = new java.awt.GridBagConstraints();
0447: gridBagConstraints.gridx = 0;
0448: gridBagConstraints.gridy = 1;
0449: gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
0450: gridBagConstraints.insets = new java.awt.Insets(5, 0, 0, 10);
0451: textBlockPanel.add(jLabel2, gridBagConstraints);
0452:
0453: textIndentCombo.setEditable(true);
0454: textIndentCombo
0455: .addActionListener(new java.awt.event.ActionListener() {
0456: public void actionPerformed(
0457: java.awt.event.ActionEvent evt) {
0458: textIndentComboActionPerformed(evt);
0459: }
0460: });
0461: textIndentCombo
0462: .addFocusListener(new java.awt.event.FocusAdapter() {
0463: public void focusLost(java.awt.event.FocusEvent evt) {
0464: textIndentComboFocusLost(evt);
0465: }
0466: });
0467: textIndentCombo
0468: .addItemListener(new java.awt.event.ItemListener() {
0469: public void itemStateChanged(
0470: java.awt.event.ItemEvent evt) {
0471: textIndentComboItemStateChanged(evt);
0472: }
0473: });
0474:
0475: gridBagConstraints = new java.awt.GridBagConstraints();
0476: gridBagConstraints.gridx = 1;
0477: gridBagConstraints.gridy = 2;
0478: gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
0479: gridBagConstraints.weightx = 1.0;
0480: gridBagConstraints.insets = new java.awt.Insets(10, 0, 0, 0);
0481: textBlockPanel.add(textIndentCombo, gridBagConstraints);
0482: textIndentCombo
0483: .getAccessibleContext()
0484: .setAccessibleName(
0485: java.util.ResourceBundle
0486: .getBundle(
0487: "org/netbeans/modules/visualweb/propertyeditors/css/Bundle")
0488: .getString("INDENT_ACCESS_NAME"));
0489: textIndentCombo
0490: .getAccessibleContext()
0491: .setAccessibleDescription(
0492: java.util.ResourceBundle
0493: .getBundle(
0494: "org/netbeans/modules/visualweb/propertyeditors/css/Bundle")
0495: .getString("INDENT_ACCESS_DESC"));
0496:
0497: verticalAlignCombo.setEditable(true);
0498: verticalAlignCombo
0499: .addActionListener(new java.awt.event.ActionListener() {
0500: public void actionPerformed(
0501: java.awt.event.ActionEvent evt) {
0502: verticalAlignComboActionPerformed(evt);
0503: }
0504: });
0505: verticalAlignCombo
0506: .addFocusListener(new java.awt.event.FocusAdapter() {
0507: public void focusLost(java.awt.event.FocusEvent evt) {
0508: verticalAlignComboFocusLost(evt);
0509: }
0510: });
0511: verticalAlignCombo
0512: .addItemListener(new java.awt.event.ItemListener() {
0513: public void itemStateChanged(
0514: java.awt.event.ItemEvent evt) {
0515: verticalAlignComboItemStateChanged(evt);
0516: }
0517: });
0518:
0519: gridBagConstraints = new java.awt.GridBagConstraints();
0520: gridBagConstraints.gridx = 1;
0521: gridBagConstraints.gridy = 1;
0522: gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
0523: gridBagConstraints.weightx = 1.0;
0524: gridBagConstraints.insets = new java.awt.Insets(5, 0, 0, 0);
0525: textBlockPanel.add(verticalAlignCombo, gridBagConstraints);
0526: verticalAlignCombo
0527: .getAccessibleContext()
0528: .setAccessibleName(
0529: java.util.ResourceBundle
0530: .getBundle(
0531: "org/netbeans/modules/visualweb/propertyeditors/css/Bundle")
0532: .getString("VERTICAL_ALIGN_ACCESS_NAME"));
0533: verticalAlignCombo
0534: .getAccessibleContext()
0535: .setAccessibleDescription(
0536: java.util.ResourceBundle
0537: .getBundle(
0538: "org/netbeans/modules/visualweb/propertyeditors/css/Bundle")
0539: .getString("VERTICAL_ALIGN_ACCESS_DESC"));
0540:
0541: wordSpacingUnitCombo
0542: .addItemListener(new java.awt.event.ItemListener() {
0543: public void itemStateChanged(
0544: java.awt.event.ItemEvent evt) {
0545: wordSpacingUnitComboItemStateChanged(evt);
0546: }
0547: });
0548:
0549: gridBagConstraints = new java.awt.GridBagConstraints();
0550: gridBagConstraints.gridx = 2;
0551: gridBagConstraints.gridy = 4;
0552: gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
0553: gridBagConstraints.insets = new java.awt.Insets(10, 10, 0, 0);
0554: textBlockPanel.add(wordSpacingUnitCombo, gridBagConstraints);
0555: wordSpacingUnitCombo
0556: .getAccessibleContext()
0557: .setAccessibleName(
0558: java.util.ResourceBundle
0559: .getBundle(
0560: "org/netbeans/modules/visualweb/propertyeditors/css/Bundle")
0561: .getString(
0562: "LETTER_SPACING_UNIT_ACCESS_NAME"));
0563: wordSpacingUnitCombo
0564: .getAccessibleContext()
0565: .setAccessibleDescription(
0566: java.util.ResourceBundle
0567: .getBundle(
0568: "org/netbeans/modules/visualweb/propertyeditors/css/Bundle")
0569: .getString(
0570: "WORD_SPACING_UNIT_ACCESS_DESC"));
0571:
0572: imageScroll1.setText(org.openide.util.NbBundle.getMessage(
0573: TextBlockStyleEditor.class, "WORD_SPACING"));
0574: gridBagConstraints = new java.awt.GridBagConstraints();
0575: gridBagConstraints.gridx = 0;
0576: gridBagConstraints.gridy = 4;
0577: gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
0578: gridBagConstraints.insets = new java.awt.Insets(10, 0, 0, 10);
0579: textBlockPanel.add(imageScroll1, gridBagConstraints);
0580:
0581: wordSpacingCombo.setEditable(true);
0582: wordSpacingCombo
0583: .addActionListener(new java.awt.event.ActionListener() {
0584: public void actionPerformed(
0585: java.awt.event.ActionEvent evt) {
0586: wordSpacingComboActionPerformed(evt);
0587: }
0588: });
0589: wordSpacingCombo
0590: .addFocusListener(new java.awt.event.FocusAdapter() {
0591: public void focusLost(java.awt.event.FocusEvent evt) {
0592: wordSpacingComboFocusLost(evt);
0593: }
0594: });
0595: wordSpacingCombo
0596: .addItemListener(new java.awt.event.ItemListener() {
0597: public void itemStateChanged(
0598: java.awt.event.ItemEvent evt) {
0599: wordSpacingComboItemStateChanged(evt);
0600: }
0601: });
0602:
0603: gridBagConstraints = new java.awt.GridBagConstraints();
0604: gridBagConstraints.gridx = 1;
0605: gridBagConstraints.gridy = 4;
0606: gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
0607: gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
0608: gridBagConstraints.insets = new java.awt.Insets(10, 0, 0, 0);
0609: textBlockPanel.add(wordSpacingCombo, gridBagConstraints);
0610: wordSpacingCombo
0611: .getAccessibleContext()
0612: .setAccessibleName(
0613: java.util.ResourceBundle
0614: .getBundle(
0615: "org/netbeans/modules/visualweb/propertyeditors/css/Bundle")
0616: .getString("WORD_SPACING_ACCESS_NAME"));
0617: wordSpacingCombo
0618: .getAccessibleContext()
0619: .setAccessibleDescription(
0620: java.util.ResourceBundle
0621: .getBundle(
0622: "org/netbeans/modules/visualweb/propertyeditors/css/Bundle")
0623: .getString("WORD_SPACING_ACCESS_DESC"));
0624:
0625: imageScroll2.setText(org.openide.util.NbBundle.getMessage(
0626: TextBlockStyleEditor.class, "LETTER_SPACING"));
0627: gridBagConstraints = new java.awt.GridBagConstraints();
0628: gridBagConstraints.gridx = 0;
0629: gridBagConstraints.gridy = 5;
0630: gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
0631: gridBagConstraints.insets = new java.awt.Insets(5, 0, 0, 10);
0632: textBlockPanel.add(imageScroll2, gridBagConstraints);
0633:
0634: letterSpacingCombo.setEditable(true);
0635: letterSpacingCombo
0636: .addActionListener(new java.awt.event.ActionListener() {
0637: public void actionPerformed(
0638: java.awt.event.ActionEvent evt) {
0639: letterSpacingComboActionPerformed(evt);
0640: }
0641: });
0642: letterSpacingCombo
0643: .addFocusListener(new java.awt.event.FocusAdapter() {
0644: public void focusLost(java.awt.event.FocusEvent evt) {
0645: letterSpacingComboFocusLost(evt);
0646: }
0647: });
0648: letterSpacingCombo
0649: .addItemListener(new java.awt.event.ItemListener() {
0650: public void itemStateChanged(
0651: java.awt.event.ItemEvent evt) {
0652: letterSpacingComboItemStateChanged(evt);
0653: }
0654: });
0655:
0656: gridBagConstraints = new java.awt.GridBagConstraints();
0657: gridBagConstraints.gridx = 1;
0658: gridBagConstraints.gridy = 5;
0659: gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
0660: gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
0661: gridBagConstraints.insets = new java.awt.Insets(5, 0, 0, 0);
0662: textBlockPanel.add(letterSpacingCombo, gridBagConstraints);
0663: letterSpacingCombo
0664: .getAccessibleContext()
0665: .setAccessibleName(
0666: java.util.ResourceBundle
0667: .getBundle(
0668: "org/netbeans/modules/visualweb/propertyeditors/css/Bundle")
0669: .getString("LETTER_SPACING_ACCESS_NAME"));
0670: letterSpacingCombo
0671: .getAccessibleContext()
0672: .setAccessibleDescription(
0673: java.util.ResourceBundle
0674: .getBundle(
0675: "org/netbeans/modules/visualweb/propertyeditors/css/Bundle")
0676: .getString("LETTER_SPACING_ACCESS_DESC"));
0677:
0678: letterSpacingUnitCombo
0679: .addItemListener(new java.awt.event.ItemListener() {
0680: public void itemStateChanged(
0681: java.awt.event.ItemEvent evt) {
0682: letterSpacingUnitComboItemStateChanged(evt);
0683: }
0684: });
0685:
0686: gridBagConstraints = new java.awt.GridBagConstraints();
0687: gridBagConstraints.gridx = 2;
0688: gridBagConstraints.gridy = 5;
0689: gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
0690: gridBagConstraints.insets = new java.awt.Insets(5, 10, 0, 0);
0691: textBlockPanel.add(letterSpacingUnitCombo, gridBagConstraints);
0692: letterSpacingUnitCombo
0693: .getAccessibleContext()
0694: .setAccessibleName(
0695: java.util.ResourceBundle
0696: .getBundle(
0697: "org/netbeans/modules/visualweb/propertyeditors/css/Bundle")
0698: .getString(
0699: "LETTER_SPACING_UNIT_ACCESS_NAME"));
0700: letterSpacingUnitCombo
0701: .getAccessibleContext()
0702: .setAccessibleDescription(
0703: java.util.ResourceBundle
0704: .getBundle(
0705: "org/netbeans/modules/visualweb/propertyeditors/css/Bundle")
0706: .getString(
0707: "LETTER_SPACING_UNIT_ACCESS_DESC"));
0708:
0709: textIndentUnitCombo
0710: .addItemListener(new java.awt.event.ItemListener() {
0711: public void itemStateChanged(
0712: java.awt.event.ItemEvent evt) {
0713: textIndentUnitComboItemStateChanged(evt);
0714: }
0715: });
0716:
0717: gridBagConstraints = new java.awt.GridBagConstraints();
0718: gridBagConstraints.gridx = 2;
0719: gridBagConstraints.gridy = 2;
0720: gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
0721: gridBagConstraints.insets = new java.awt.Insets(10, 10, 0, 0);
0722: textBlockPanel.add(textIndentUnitCombo, gridBagConstraints);
0723: textIndentUnitCombo
0724: .getAccessibleContext()
0725: .setAccessibleName(
0726: java.util.ResourceBundle
0727: .getBundle(
0728: "org/netbeans/modules/visualweb/propertyeditors/css/Bundle")
0729: .getString("INDENT_UNIT_ACCESS_NAME"));
0730: textIndentUnitCombo
0731: .getAccessibleContext()
0732: .setAccessibleDescription(
0733: java.util.ResourceBundle
0734: .getBundle(
0735: "org/netbeans/modules/visualweb/propertyeditors/css/Bundle")
0736: .getString("INDENT_UNIT_ACCESS_DESC"));
0737:
0738: lineHeightLabel.setText(org.openide.util.NbBundle.getMessage(
0739: TextBlockStyleEditor.class, "LINE_HEIGHT"));
0740: gridBagConstraints = new java.awt.GridBagConstraints();
0741: gridBagConstraints.gridx = 0;
0742: gridBagConstraints.gridy = 6;
0743: gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
0744: gridBagConstraints.insets = new java.awt.Insets(6, 0, 0, 10);
0745: textBlockPanel.add(lineHeightLabel, gridBagConstraints);
0746:
0747: lineHeightCombo.setEditable(true);
0748: lineHeightCombo
0749: .addActionListener(new java.awt.event.ActionListener() {
0750: public void actionPerformed(
0751: java.awt.event.ActionEvent evt) {
0752: lineHeightComboActionPerformed(evt);
0753: }
0754: });
0755: lineHeightCombo
0756: .addFocusListener(new java.awt.event.FocusAdapter() {
0757: public void focusLost(java.awt.event.FocusEvent evt) {
0758: lineHeightComboFocusLost(evt);
0759: }
0760: });
0761: lineHeightCombo
0762: .addItemListener(new java.awt.event.ItemListener() {
0763: public void itemStateChanged(
0764: java.awt.event.ItemEvent evt) {
0765: lineHeightComboItemStateChanged(evt);
0766: }
0767: });
0768:
0769: gridBagConstraints = new java.awt.GridBagConstraints();
0770: gridBagConstraints.gridx = 1;
0771: gridBagConstraints.gridy = 6;
0772: gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
0773: gridBagConstraints.insets = new java.awt.Insets(5, 0, 0, 0);
0774: textBlockPanel.add(lineHeightCombo, gridBagConstraints);
0775: lineHeightCombo
0776: .getAccessibleContext()
0777: .setAccessibleName(
0778: java.util.ResourceBundle
0779: .getBundle(
0780: "org/netbeans/modules/visualweb/propertyeditors/css/Bundle")
0781: .getString("LINE_HEIGHT_ACCESS_NAME"));
0782: lineHeightCombo
0783: .getAccessibleContext()
0784: .setAccessibleDescription(
0785: java.util.ResourceBundle
0786: .getBundle(
0787: "org/netbeans/modules/visualweb/propertyeditors/css/Bundle")
0788: .getString("LINE_HEIGHT_ACCESS_DESC"));
0789:
0790: lineHeightUnitCombo
0791: .addItemListener(new java.awt.event.ItemListener() {
0792: public void itemStateChanged(
0793: java.awt.event.ItemEvent evt) {
0794: lineHeightUnitComboItemStateChanged(evt);
0795: }
0796: });
0797:
0798: gridBagConstraints = new java.awt.GridBagConstraints();
0799: gridBagConstraints.gridx = 2;
0800: gridBagConstraints.gridy = 6;
0801: gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
0802: gridBagConstraints.insets = new java.awt.Insets(5, 10, 0, 0);
0803: textBlockPanel.add(lineHeightUnitCombo, gridBagConstraints);
0804: lineHeightUnitCombo
0805: .getAccessibleContext()
0806: .setAccessibleName(
0807: java.util.ResourceBundle
0808: .getBundle(
0809: "org/netbeans/modules/visualweb/propertyeditors/css/Bundle")
0810: .getString(
0811: "LINE_HEIGHT_UNIT_ACCESS_NAME"));
0812: lineHeightUnitCombo
0813: .getAccessibleContext()
0814: .setAccessibleDescription(
0815: java.util.ResourceBundle
0816: .getBundle(
0817: "org/netbeans/modules/visualweb/propertyeditors/css/Bundle")
0818: .getString(
0819: "LINE_HEIGHT_UNIT_ACCESS_DESC"));
0820:
0821: add(textBlockPanel, java.awt.BorderLayout.NORTH);
0822:
0823: errorPanel.setLayout(new java.awt.BorderLayout());
0824:
0825: errorPanel.setBorder(javax.swing.BorderFactory
0826: .createEmptyBorder(1, 10, 1, 1));
0827: errorLabel.setForeground(new java.awt.Color(0, 0, 153));
0828: errorLabel.setMinimumSize(new java.awt.Dimension(200, 20));
0829: errorLabel.setPreferredSize(new java.awt.Dimension(200, 20));
0830: errorPanel.add(errorLabel, java.awt.BorderLayout.CENTER);
0831:
0832: add(errorPanel, java.awt.BorderLayout.SOUTH);
0833:
0834: }// </editor-fold>//GEN-END:initComponents
0835:
0836: private void letterSpacingUnitComboItemStateChanged(
0837: java.awt.event.ItemEvent evt) {//GEN-FIRST:event_letterSpacingUnitComboItemStateChanged
0838: if (evt.getStateChange() != evt.DESELECTED) {
0839: setLetterSpacing();
0840: }
0841: }//GEN-LAST:event_letterSpacingUnitComboItemStateChanged
0842:
0843: private void letterSpacingComboFocusLost(
0844: java.awt.event.FocusEvent evt) {//GEN-FIRST:event_letterSpacingComboFocusLost
0845: setLetterSpacing();
0846: }//GEN-LAST:event_letterSpacingComboFocusLost
0847:
0848: private void letterSpacingComboItemStateChanged(
0849: java.awt.event.ItemEvent evt) {//GEN-FIRST:event_letterSpacingComboItemStateChanged
0850: if (evt.getStateChange() != evt.DESELECTED) {
0851: setLetterSpacing();
0852: }
0853: }//GEN-LAST:event_letterSpacingComboItemStateChanged
0854:
0855: private void letterSpacingComboActionPerformed(
0856: java.awt.event.ActionEvent evt) {//GEN-FIRST:event_letterSpacingComboActionPerformed
0857: setLetterSpacing();
0858: }//GEN-LAST:event_letterSpacingComboActionPerformed
0859:
0860: private void wordSpacingUnitComboItemStateChanged(
0861: java.awt.event.ItemEvent evt) {//GEN-FIRST:event_wordSpacingUnitComboItemStateChanged
0862: if (evt.getStateChange() != evt.DESELECTED) {
0863: setWordSpacing();
0864: }
0865: }//GEN-LAST:event_wordSpacingUnitComboItemStateChanged
0866:
0867: private void wordSpacingComboFocusLost(java.awt.event.FocusEvent evt) {//GEN-FIRST:event_wordSpacingComboFocusLost
0868: setWordSpacing();
0869: }//GEN-LAST:event_wordSpacingComboFocusLost
0870:
0871: private void wordSpacingComboItemStateChanged(
0872: java.awt.event.ItemEvent evt) {//GEN-FIRST:event_wordSpacingComboItemStateChanged
0873: if (evt.getStateChange() != evt.DESELECTED) {
0874: setWordSpacing();
0875: }
0876: }//GEN-LAST:event_wordSpacingComboItemStateChanged
0877:
0878: private void wordSpacingComboActionPerformed(
0879: java.awt.event.ActionEvent evt) {//GEN-FIRST:event_wordSpacingComboActionPerformed
0880: setWordSpacing();
0881: }//GEN-LAST:event_wordSpacingComboActionPerformed
0882:
0883: private void directionComboItemStateChanged(
0884: java.awt.event.ItemEvent evt) {//GEN-FIRST:event_directionComboItemStateChanged
0885: setDirection();
0886: }//GEN-LAST:event_directionComboItemStateChanged
0887:
0888: private void textIndentUnitComboItemStateChanged(
0889: java.awt.event.ItemEvent evt) {//GEN-FIRST:event_textIndentUnitComboItemStateChanged
0890: if (evt.getStateChange() != evt.DESELECTED) {
0891: setTextIndent();
0892: }
0893: }//GEN-LAST:event_textIndentUnitComboItemStateChanged
0894:
0895: private void textIndentComboFocusLost(java.awt.event.FocusEvent evt) {//GEN-FIRST:event_textIndentComboFocusLost
0896: setTextIndent();
0897: }//GEN-LAST:event_textIndentComboFocusLost
0898:
0899: private void textIndentComboItemStateChanged(
0900: java.awt.event.ItemEvent evt) {//GEN-FIRST:event_textIndentComboItemStateChanged
0901: if (evt.getStateChange() != evt.DESELECTED) {
0902: setTextIndent();
0903: }
0904: }//GEN-LAST:event_textIndentComboItemStateChanged
0905:
0906: private void textIndentComboActionPerformed(
0907: java.awt.event.ActionEvent evt) {//GEN-FIRST:event_textIndentComboActionPerformed
0908: setTextIndent();
0909: }//GEN-LAST:event_textIndentComboActionPerformed
0910:
0911: private void verticalAlignComboFocusLost(
0912: java.awt.event.FocusEvent evt) {//GEN-FIRST:event_verticalAlignComboFocusLost
0913: setVerticalAlign();
0914: }//GEN-LAST:event_verticalAlignComboFocusLost
0915:
0916: private void horizontalAlignComboFocusLost(
0917: java.awt.event.FocusEvent evt) {//GEN-FIRST:event_horizontalAlignComboFocusLost
0918: setTextAlign();
0919: }//GEN-LAST:event_horizontalAlignComboFocusLost
0920:
0921: private void verticalAlignComboItemStateChanged(
0922: java.awt.event.ItemEvent evt) {//GEN-FIRST:event_verticalAlignComboItemStateChanged
0923: if (evt.getStateChange() != evt.DESELECTED) {
0924: setVerticalAlign();
0925: }
0926: }//GEN-LAST:event_verticalAlignComboItemStateChanged
0927:
0928: private void verticalAlignComboActionPerformed(
0929: java.awt.event.ActionEvent evt) {//GEN-FIRST:event_verticalAlignComboActionPerformed
0930: setVerticalAlign();
0931: }//GEN-LAST:event_verticalAlignComboActionPerformed
0932:
0933: private void horizontalAlignComboItemStateChanged(
0934: java.awt.event.ItemEvent evt) {//GEN-FIRST:event_horizontalAlignComboItemStateChanged
0935: if (evt.getStateChange() != evt.DESELECTED) {
0936: setTextAlign();
0937: }
0938: }//GEN-LAST:event_horizontalAlignComboItemStateChanged
0939:
0940: private void lineHeightUnitComboItemStateChanged(
0941: java.awt.event.ItemEvent evt) {//GEN-FIRST:event_lineHeightUnitComboItemStateChanged
0942: if (evt.getStateChange() != evt.DESELECTED) {
0943: setLineHeight();
0944: }
0945: }//GEN-LAST:event_lineHeightUnitComboItemStateChanged
0946:
0947: private void lineHeightComboItemStateChanged(
0948: java.awt.event.ItemEvent evt) {//GEN-FIRST:event_lineHeightComboItemStateChanged
0949: if (evt.getStateChange() != evt.DESELECTED) {
0950: setLineHeight();
0951: }
0952: }//GEN-LAST:event_lineHeightComboItemStateChanged
0953:
0954: private void lineHeightComboFocusLost(java.awt.event.FocusEvent evt) {//GEN-FIRST:event_lineHeightComboFocusLost
0955: setLineHeight();
0956: }//GEN-LAST:event_lineHeightComboFocusLost
0957:
0958: private void lineHeightComboActionPerformed(
0959: java.awt.event.ActionEvent evt) {//GEN-FIRST:event_lineHeightComboActionPerformed
0960: setLineHeight();
0961: }//GEN-LAST:event_lineHeightComboActionPerformed
0962:
0963: private void setLineHeight() {
0964: lineHeightData.setUnit(lineHeightUnitCombo.getSelectedItem()
0965: .toString());
0966: lineHeightData.setValue(lineHeightCombo.getSelectedItem()
0967: .toString());
0968: cssStyleData.modifyProperty(CssStyleData.LINE_HEIGHT,
0969: lineHeightData.toString());
0970: lineHeightUnitCombo.setEnabled(lineHeightData.isValueInteger());
0971: }
0972:
0973: private void setLetterSpacing() {
0974: letterSpacingData.setUnit(letterSpacingUnitCombo
0975: .getSelectedItem().toString());
0976: letterSpacingData.setValue(letterSpacingCombo.getSelectedItem()
0977: .toString());
0978: cssStyleData.modifyProperty(CssStyleData.LETTER_SPACING,
0979: letterSpacingData.toString());
0980: letterSpacingUnitCombo.setEnabled(letterSpacingData
0981: .isValueInteger());
0982: }
0983:
0984: private void setWordSpacing() {
0985: wordSpacingData.setUnit(wordSpacingUnitCombo.getSelectedItem()
0986: .toString());
0987: wordSpacingData.setValue(wordSpacingCombo.getSelectedItem()
0988: .toString());
0989: cssStyleData.modifyProperty(CssStyleData.WORD_SPACING,
0990: wordSpacingData.toString());
0991: wordSpacingUnitCombo.setEnabled(wordSpacingData
0992: .isValueInteger());
0993: }
0994:
0995: private void setDirection() {
0996: directionData.setValue(directionCombo.getSelectedItem()
0997: .toString());
0998: cssStyleData.modifyProperty(CssStyleData.DIRECTION,
0999: directionData.toString());
1000: }
1001:
1002: private void setTextIndent() {
1003: textIndentData.setUnit(textIndentUnitCombo.getSelectedItem()
1004: .toString());
1005: textIndentData.setValue(textIndentCombo.getSelectedItem()
1006: .toString());
1007: cssStyleData.modifyProperty(CssStyleData.TEXT_INDENT,
1008: textIndentData.toString());
1009: textIndentUnitCombo.setEnabled(textIndentData.isValueInteger());
1010: }
1011:
1012: private void setVerticalAlign() {
1013: verticalAlignData.setValue(verticalAlignCombo.getSelectedItem()
1014: .toString());
1015: cssStyleData.modifyProperty(CssStyleData.VERTICAL_ALIGN,
1016: verticalAlignData.toString());
1017: }
1018:
1019: private void setTextAlign() {
1020: textAlignData.setValue(horizontalAlignCombo.getSelectedItem()
1021: .toString());
1022: cssStyleData.modifyProperty(CssStyleData.TEXT_ALIGN,
1023: textAlignData.toString());
1024: }
1025:
1026: // Variables declaration - do not modify//GEN-BEGIN:variables
1027: private javax.swing.JLabel decorationLabel;
1028: private javax.swing.JComboBox directionCombo;
1029: private javax.swing.JLabel errorLabel;
1030: private javax.swing.JPanel errorPanel;
1031: private javax.swing.JComboBox horizontalAlignCombo;
1032: private javax.swing.JLabel imageScroll;
1033: private javax.swing.JLabel imageScroll1;
1034: private javax.swing.JLabel imageScroll2;
1035: private javax.swing.JLabel jLabel2;
1036: private javax.swing.JComboBox letterSpacingCombo;
1037: private javax.swing.JComboBox letterSpacingUnitCombo;
1038: private javax.swing.JComboBox lineHeightCombo;
1039: private javax.swing.JLabel lineHeightLabel;
1040: private javax.swing.JComboBox lineHeightUnitCombo;
1041: private javax.swing.JLabel textAlignLabel;
1042: private javax.swing.JPanel textBlockPanel;
1043: private javax.swing.JComboBox textIndentCombo;
1044: private javax.swing.JComboBox textIndentUnitCombo;
1045: private javax.swing.JComboBox verticalAlignCombo;
1046: private javax.swing.JComboBox wordSpacingCombo;
1047: private javax.swing.JComboBox wordSpacingUnitCombo;
1048: // End of variables declaration//GEN-END:variables
1049:
1050: }
|