我有一个执行以下操作的脚本:
var document = app.documents.item(0);
var layer = document.layers.itemByName("Normal");
var allTextFrames = toArray(layer.textFrames);
var moved = selectWhere("moved", "label", allTextFrames)[0];
var notMoved = selectWhere("notMoved", "label", allTextFrames)[0];
var instance = selectWhere("instance", "label", allTextFrames)[0];
$.writeln("Moved : " + moved.geometricBounds.join(", "));
$.writeln("Moved overr: " + moved.overriddenMasterPageItem.geometricBounds.join(", "));
$.writeln("notMoved : " + notMoved.geometricBounds.join(", "));
$.writeln("notMoved overr: " + notMoved.overriddenMasterPageItem.geometricBounds.join(", "));
var overr = moved.overriddenMasterPageItem;
moved.geometricBounds = [moved.overriddenMasterPageItem.geometricBounds[0]
,moved.overriddenMasterPageItem.geometricBounds[1]
,moved.overriddenMasterPageItem.geometricBounds[2]
,moved.overriddenMasterPageItem.geometricBounds[3]];
moved.visibleBounds = [moved.overriddenMasterPageItem.visibleBounds[0]
,moved.overriddenMasterPageItem.visibleBounds[1]
,moved.overriddenMasterPageItem.visibleBounds[2]
,moved.overriddenMasterPageItem.visibleBounds[3]];
但是,如果我更改母版页中的文本框架,它不会更新“移动”的文本框架......
例如,pageItem 有一个属性,当设置为“-1”时,它将使用母版页值。我一直在寻找类似的东西,但位置和大小。
fillTint number 只读 PageItem 的填充颜色中使用的色调百分比。(要指定色调百分比,请使用 0 到 100 范围内的数字;要使用继承或覆盖的值,请使用 -1。) src:http: //jongware.mit.edu/iccs5_html_3.0.3d/iccs5/ pc_PageItem.html