PSC Code Manual

util/document.lsp [src]

Functions dealing with VLA Document objects

Functions

Function signature Description
(get-custom-dwgprop key) Returns value of custom drawing property KEY in current acadDoc
(open-and filename readonly func-sym args) Opens drawing FILENAME and executes function pointed to by FUNC-SYM with ARGS
(osnap-off) Suppress object snaps in current acadDoc and set *error* to restore them
(osnap-on) Restore object snaps in current acadDoc
(reset-doc) Resets acadDoc and modelSpace global vars
(set-active-dimstyle name) Sets active dimension style in current acadDoc to NAME
(set-active-layer name) Sets active layer in current acadDoc to NAME
(set-active-textstyle name) Sets active text style in current acadDoc to NAME
(set-custom-dwgprop key val) Sets value of custom drawing property KEY to VAL
(setup-env 3d-p) Ensure necessary layers, linetypes, and text styles are present
(vla-getvar sysvar) Returns the value of SYSVAR in current acadDoc
(vla-setvar sysvar val) Sets the value of SYSVAR in current acadDoc to VAL

(get-custom-dwgprop key)

Returns value of custom drawing property KEY in current acadDoc

VARS:
(KEY STR)

(open-and filename readonly func-sym args)

Opens drawing FILENAME and executes function pointed to by FUNC-SYM with ARGS

If READONLY is non-nil, open the drawing in read-only mode. The drawing is automatically
closed and reset-doc is called after.

VARS:
(FILENAME STR)
(FUNC-SYM SYM (FUNCTION-P (VL-SYMBOL-VALUE FUNC-SYM)))
(ARGS nil (LISTP ARGS))

(osnap-off)

Suppress object snaps in current acadDoc and set *error* to restore them

(osnap-on)

Restore object snaps in current acadDoc

(reset-doc)

Resets acadDoc and modelSpace global vars

(set-active-dimstyle name)

Sets active dimension style in current acadDoc to NAME

VARS:
(NAME STR)

(set-active-layer name)

Sets active layer in current acadDoc to NAME

VARS:
(NAME STR)

(set-active-textstyle name)

Sets active text style in current acadDoc to NAME

VARS:
(NAME STR)

(set-custom-dwgprop key val)

Sets value of custom drawing property KEY to VAL

VARS:
(KEY STR)
(VAL STR)

(setup-env 3d-p)

Ensure necessary layers, linetypes, and text styles are present

Includes different things if 3D-P is non-nil.

(vla-getvar sysvar)

Returns the value of SYSVAR in current acadDoc

VARS:
(SYSVAR (SYM STR))

(vla-setvar sysvar val)

Sets the value of SYSVAR in current acadDoc to VAL

VARS:
(SYSVAR (SYM STR))