buffer.append(formatInt(gridHeight)); buffer.append(", \""); buffer.append(hAlign.abbreviation()); if (hAlign == DEFAULT && layout != null) { buffer.append('='); ? layout.getColumnSpec(gridX) : null; buffer.append(concreteAlignment(hAlign, colSpec).abbreviation()); buffer.append(vAlign.abbreviation()); if (vAlign == DEFAULT && layout != null) { buffer.append('='); ? layout.getRowSpec(gridY) : null; buffer.append(concreteAlignment(vAlign, rowSpec).abbreviation());
setText(CellConstraintsNames.ID_INSETS_RIGHT, String.valueOf(insets.right)); setSelectedItem(CellConstraintsNames.ID_HORIZONTAL_ALIGNMENT, cc.getHorizontalAlignment().toString().toUpperCase()); setSelectedItem(CellConstraintsNames.ID_VERTICAL_ALIGNMENT, cc.getVerticalAlignment().toString().toUpperCase());
buffer.append(formatInt(gridHeight)); buffer.append(", \""); buffer.append(hAlign.abbreviation()); if (hAlign == DEFAULT && layout != null) { buffer.append('='); ? layout.getColumnSpec(gridX) : null; buffer.append(concreteAlignment(hAlign, colSpec).abbreviation()); buffer.append(vAlign.abbreviation()); if (vAlign == DEFAULT && layout != null) { buffer.append('='); ? layout.getRowSpec(gridY) : null; buffer.append(concreteAlignment(vAlign, rowSpec).abbreviation());
buffer.append(formatInt(gridHeight)); buffer.append(", \""); buffer.append(hAlign.abbreviation()); if (hAlign == DEFAULT && layout != null) { buffer.append('='); ColumnSpec colSpec = gridWidth == 1 ? layout.getColumnSpec(gridX) : null; buffer.append(concreteAlignment(hAlign, colSpec).abbreviation()); buffer.append(vAlign.abbreviation()); if (vAlign == DEFAULT && layout != null) { buffer.append('='); RowSpec rowSpec = gridHeight == 1 ? layout.getRowSpec(gridY) : null; buffer.append(concreteAlignment(vAlign, rowSpec).abbreviation());
/** * Creates a <code>CellConstraintsMemento</code> object with the specified * cell constraints. * * @param cc * the cell constraints. */ public CellConstraintsMemento(CellConstraints cc) { m_column = cc.gridX; m_row = cc.gridY; m_colspan = cc.gridWidth; m_rowspan = cc.gridHeight; m_halign = cc.hAlign.toString(); m_valign = cc.vAlign.toString(); m_insets = cc.insets; }
/** * Parses an alignment string description and returns the corresponding * alignment value. * * @param encodedAlignment * the encoded alignment * @return the associated <code>Alignment</code> instance */ private Alignment decodeAlignment(String encodedAlignment) { return Alignment.valueOf(encodedAlignment); }
/** * Parses an alignment string description and * returns the corresponding alignment value. * * @param encodedAlignment the encoded alignment * @return the associated <code>Alignment</code> instance */ private Alignment decodeAlignment(String encodedAlignment) { return Alignment.valueOf(encodedAlignment); }
/** * Parses an alignment string description and * returns the corresponding alignment value. * * @param encodedAlignment the encoded alignment * @return the associated {@code Alignment} instance */ private static Alignment decodeAlignment(String encodedAlignment) { return Alignment.valueOf(encodedAlignment); }