[PythonCAD] Sample patch for selection highlighting

Art Haas ahaas at airmail.net
Tue Nov 15 20:04:04 CET 2005


On Tue, Nov 15, 2005 at 12:22:47PM -0500, Stuart Brorson wrote:
> Some questions/issues:
> 
> *  Drawing in a new layer seems to draw only white.  The nice yellow
> color which I am used to is not drawn.  All new layers only draw
> white.  Is this the desired behavior? 
 
When you switch from one layer to another the current drawing style,
color, linetype, and thickness should not change, so if you are drawing
yellow lines in one layer, then create a new layer, you should get yellow
lines in it as well.

> *  The new layer doesn't inherit the line width of the parent layer.
> Any ideas about how to fix that?  I guess I can look at it
> myself. . . .
 
The line thickness should not change when you add a new layer. Again,
I'll take a look-see and see if something is going on.

> *  I can add children to "top layer" , but I can't add a layer at the
> same level.  From a philosophical perspective, what does this imply
> about the top layer's role in a drawing?  I guess I am confused about
> why one would have hierarchical layers, unless it's to draw the
> leaders and notes to a drawing on a child layer.  But why aren't
> multiple top layers possible (i.e. different drawings of different
> components in a single file)?

The way to think about it is analagous to the unix file system. The top
level of a drawing is the '/' directory, and you can have any number of
sublayers below it just like there can be lots of subdirectories below
'/', ad infinitum.

To me this arrangement makes sense. When I used AutoCAD many years ago
that program allowed numerous layers in a drawing, but the layers were
not arranged in a hierarchy, just in a sequence. After using AutoCAD I
worked at a company that used ME-10, and it offered the hierarchical
arrangement to nest layers, which they called 'parts'. I found that
setup more flexible and useful than what I could do with AutoCAD, so
I implemented PythonCAD to be similar to ME-10. The drawings in ME-10
were often structured so that certain features or views were in one
layer/part, and the top level of the drawing was named after the
particular part-number of the piece in the drawing. This approach worked
well, and allowed a lot of flexibility.

Art
-- 
Man once surrendering his reason, has no remaining guard against absurdities
the most monstrous, and like a ship without rudder, is the sport of every wind.

-Thomas Jefferson to James Smith, 1822


More information about the PythonCAD mailing list