CAD开发者社区

 找回密码
 立即注册

QQ登录

只需一步,快速开始

AutoCAD 2023 开发者帮助

RemoveHiddenLines 属性 (ActiveX)

2024-5-18 18:57| 发布者: admin| 查看: 101| 评论: 0|原作者: admin|来自: AutoCAD

RemoveHiddenLines 属性 (ActiveX)

指定是否要在图纸空间视口上绘制隐藏线。(已过时)

支持的平台:仅限 Windows

签名

VBA:

object.RemoveHiddenLines
对象

类型: PViewport

此属性应用于的对象。

属性值

只读:

类型:布尔

  • True:删除剧情中的隐藏线条。
  • False:不删除绘图中的隐藏线。

言论

此属性已过时,将在将来的版本中删除。

例子

VBA:

Sub Example_RemoveHiddenLines()
    ' This example creates a new paper space viewport.
    ' It then displays the value of RemoveHiddenLines for the viewport.
    
    Dim pviewportObj As AcadPViewport
    Dim center(0 To 2) As Double
    Dim width As Double
    Dim height As Double
    
    ' Define the paper space viewport
    center(0) = 3: center(1) = 3: center(2) = 0
    width = 40
    height = 40
    
    ' Change from model space to paper space
    ThisDrawing.ActiveSpace = acPaperSpace

    ' Create the paper space viewport
    Set pviewportObj = ThisDrawing.PaperSpace.AddPViewport(center, width, height)
    pviewportObj.DISPLAY True
    ThisDrawing.mspace = True
    ThisDrawing.ActivePViewport = pviewportObj
    ThisDrawing.Regen acAllViewports
    
    ' Find the value for RemoveHiddenLines for the viewport
    Dim removeHidden As Boolean
    removeHidden = pviewportObj.RemoveHiddenLines
    MsgBox "The value of the RemoveHiddenLines property for the paperspace viewport is " & pviewportObj.RemoveHiddenLines, , "RemoveHiddenLines Example"

End Sub

可视化 LISP:

(vl-load-com)
(defun c:Example_RemoveHiddenLines()
    ;; This example creates a new paper space viewport.
    ;; It then displays the value of ShadePlot for the viewport.
    ;; ShadePlot replaces RemoveHiddenLines.
    (setq acadObj (vlax-get-acad-object))
    (setq doc (vla-get-ActiveDocument acadObj))
    
    ;; Define the paper space viewport
    (setq center (vlax-3d-point 3 3 0)
          width 40
          height 40)
    
    ;; Change from model space to paper space
    (vla-put-ActiveSpace doc acPaperSpace)

    ;; Create the paper space viewport
    (setq paperSpace (vla-get-PaperSpace doc))
    (setq pviewportObj (vla-AddPViewport paperSpace center width height))

    (vla-Display pviewportObj :vlax-true)
    (vla-put-MSpace doc :vlax-true)
    (vla-put-ActivePViewport doc pviewportObj)
    (vla-Regen doc acAllViewports)
    
    ;; Find the value for ShadePlot for the viewport
    (alert (strcat "The value of the ShadePlot property for the paperspace viewport is " (itoa (vla-get-ShadePlot pviewportObj))))
)

路过

雷人

握手

鲜花

鸡蛋

最新评论

QQ|Archiver|CAD开发者社区 ( 苏ICP备2022047690号-1   苏公网安备32011402011833)

GMT+8, 2024-12-15 22:21

Powered by Discuz! X3.4

Copyright © 2001-2021, Tencent Cloud.

返回顶部