aboutsummaryrefslogtreecommitdiff
path: root/src/new_fields/Doc.ts
diff options
context:
space:
mode:
authorbob <bcz@cs.brown.edu>2019-10-01 15:10:22 -0400
committerbob <bcz@cs.brown.edu>2019-10-01 15:10:22 -0400
commit69e4a936c4eb0cc2e35e4e7f3258aed1f72b8da7 (patch)
tree6a0343d5ac284db8f20ecf6f2457f0dd924b7c6e /src/new_fields/Doc.ts
parentfaaff9fe8aab3bd5d116eab8bd85198a0756fe30 (diff)
fixed a bunch of pdf related things with stacking views.
Diffstat (limited to 'src/new_fields/Doc.ts')
-rw-r--r--src/new_fields/Doc.ts1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/new_fields/Doc.ts b/src/new_fields/Doc.ts
index 4a03fed08..a68692732 100644
--- a/src/new_fields/Doc.ts
+++ b/src/new_fields/Doc.ts
@@ -712,6 +712,7 @@ export namespace Doc {
}
Scripting.addGlobal(function renameAlias(doc: any, n: any) { return StrCast(Doc.GetProto(doc).title).replace(/\([0-9]*\)/, "") + `(${n})`; });
Scripting.addGlobal(function getProto(doc: any) { return Doc.GetProto(doc); });
+Scripting.addGlobal(function getAlias(doc: any) { return Doc.MakeAlias(doc); });
Scripting.addGlobal(function copyField(field: any) { return ObjectField.MakeCopy(field); });
Scripting.addGlobal(function aliasDocs(field: any) { return new List<Doc>(field.map((d: any) => Doc.MakeAlias(d))); });
Scripting.addGlobal(function docList(field: any) { return DocListCast(field); }); \ No newline at end of file