Jump to content

Recommended Posts

Posted

Hey,

 

Is there anyway to zoom in and out or to control the viewport

properties via lisp ?

 

Thanks

Posted (edited)

Zoom with lisp? Why yes you can. Here is a small example as provided by the Lazy Drafter website.

; Zoomout

; Zooms out by a factor of .5x

;

(defun C:zoomout ()

(command “zoom” “.5x”)

)

 

What do you mean by "control the viewport"? The layer it is on? The size? Placement? Whether it is locked or unlocked?

 

Here is another example but this time it is a lisp routine that will lock a viewport.

 

http://www.cadlispandtips.com/2010/11/lisp-lock-viewports.html

 

Make a specific viewport current via lisp.

 

http://usa.autodesk.com/adsk/servlet/ps/dl/item?siteID=123112&id=11740732&linkID=9240617

 

Set viewport scale with DCL/lisp.

 

http://www.cadtutor.net/forum/archive/index.php/t-55165.html?

Edited by ReMark
Posted (edited)

Just a simple one usefull in lisps etc

(command "zoom" "C" pt 100)

zoom about a pick pt for a predefined scale.

Edited by BIGAL
Posted

Also consider the zoom* methods of the Application Object, e.g. vla-zoomwindow

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...