Enum VerticalAlignment

VerticalAlignment

サポートされている垂直方向の配置タイプの列挙型。

列挙型を呼び出すには、親クラス、名前、プロパティを呼び出します。たとえば、 DocumentApp.VerticalAlignment.BOTTOM です。

表のセルの垂直方向の配置を設定するには、VerticalAlignment 列挙型を使用します。

var body = DocumentApp.getActiveDocument().getBody();

// Append table containing two cells.
var table = body.appendTable([['Top', 'Center', 'Bottom']]);

// Align the first cell's contents to the top.
table.getCell(0, 0).setVerticalAlignment(DocumentApp.VerticalAlignment.TOP);

// Align the second cell's contents to the center.
table.getCell(0, 1).setVerticalAlignment(DocumentApp.VerticalAlignment.CENTER);

// Align the third cell's contents to the bottom.
table.getCell(0, 2).setVerticalAlignment(DocumentApp.VerticalAlignment.BOTTOM);

プロパティ

プロパティ種類説明
BOTTOMEnum下揃えのオプション。
CENTEREnum中央揃えのオプション。
TOPEnum上揃えのオプション。