SketchUp / api-issue-tracker

Public issue tracker for the SketchUp and LayOut's APIs
https://developer.sketchup.com/
38 stars 10 forks source link

ConstructionLine #stipple returns Integer not a String #949

Open dezmoHU opened 3 months ago

dezmoHU commented 3 months ago
  1. SketchUp Version: tested on 2021, 2023
  2. OS Platform: Win

The #stipple method - according the documentation should return String. However it returns Integer.

Execute the example in a doc:

entities = model.active_entities
point1 = Geom::Point3d.new(0, 0, 0)
point2 = Geom::Point3d.new(20, 20, 20)
constline = entities.add_cline(point1, point2)
puts constline.stipple

Returns 65535

constline.stipple = "."
puts constline.stipple

Returns 34952

(The setter returns String or Integer, according the pattern used. )

Background: I wanted to use it like view.line_stipple = constline.stipple to highlight the hovered cline with a same pattern, but it does not work.

Edit: The String : Integer pairs, just in case...: ;-)

""    : 65535
"."   : 34952
"-"   : 13107
"_"   : 61680
"-.-" : 7239