每个视口都以某种方式保持着比例,它可能是每个视口的表列表的一部分,一旦您阅读了它,那么很容易复制它,它只是用于绘制多视图的简单lisp,用其他多视图比例值替换sc值。
- (setq sc (getstring "\nScale for this window 1: "))
- (setq sc3 (strcat "1/" sc "xp"))
- (command "_.zoom" "all")
- (setq zc (getpoint "\nPoint to centre of view in Viewport:"))
- (command "_.zoom" "_center" zc sc3)
我在vport上做了一个Entsel,然后查了我的lisp书(是的,真的页面)和assoc等等
- (setq obj (car (entsel "\npick vport boundary ")))
- (setq tpp1 (entget obj))
- (setq pt3 (cdr (assoc 40 tpp1))) ; Height
- (setq pt4 (cdr (assoc 41 tpp1))) ; width
- (setq pt5 (cdr (assoc 42 tpp1))) ; scale
- (princ pt5)
希望这有帮助 |