【问题标题】:Dynamic Component Attributes of Arc's in SketchupSketchup中Arc的动态组件属性
【发布时间】:2016-03-31 09:27:20
【问题描述】:

我的绘图中有一个 3 点圆弧。标准中提供的动态属性与矩形相同。有没有办法将这 3 个点定义为属性,以便之后能够动态更改它们?

【问题讨论】:

    标签: ruby sketchup


    【解决方案1】:

    您可以使用附加到每个EntityModelAttributeDictionary 来存储自定义属性。

    dictname = "TestDictionary"
    key = "arcs"
    value = ["x", "y", "z"]
    model = Sketchup.active_model
    model.set_attribute dictname, key, value
    
    dict = model.attribute_dictionary dictname
    arcs = dict[key]
    
    // or
    
    arcs = model.get_attribute dictname, key 
    

    【讨论】:

      猜你喜欢
      • 2012-01-20
      • 1970-01-01
      • 1970-01-01
      • 2020-05-21
      • 2016-08-06
      • 2011-01-05
      • 1970-01-01
      • 2023-03-09
      • 2017-01-22
      相关资源
      最近更新 更多