[cad-linux-dev] Re: layers and styles in sub-directories

  • From: Bruno Postle <bruno@xxxxxxxxxx>
  • To: CAD linux development <cad-linux-dev@xxxxxxxxxxxxx>
  • Date: Mon, 23 Aug 2004 20:59:28 +0100

On Mon 23-Aug-2004 at 14:26 -0500, Eric Wilhelm wrote:
> >
> >Ultimately, layer/style/linetype definitions can be
> >accessed with proper URLs:
> >
> >   layerID: http://www.example.com/standards/layers/5.yml
> 
> hmm. What about modifying layers based on an imported drawing?

That's fine, an imported drawing would almost always have internal
layer definitions.

> Okay, but "layers/" is the default location of layer objects, so can
> we just use a number if it's in there?
> 
>   layerID: 5
> 
> that would direct me to "layers/5.yml"

Because you are limiting your options too early; instead of
hardcoding the "layers" sub-directory into the spec, simply put all
your layer definitions in a layers subdirectory and reference them
there by prefixing the id like so: "layers/5.yml" - Easy to
implement and it allows for future expansion.

> >So, layers/styles/linetypes can be stored in sub-directories because
> >they are only needed when referenced, whereas the geometry should
> >exist in the root of the drawing because the geometry IS the drawing
> 
> I'll buy that, but I'm not sure if it's a good idea yet.  Just looking at how 
> the directory sorts, 
> 
> 0.yml
> 1.yml
> layers
> line_types
> mark_styles
> object_styles
> text_styles
> 
> Our "headers" are now at the bottom.  From a human-interface standpoint, it 
> has problems.

Except the style stuff isn't really headers, it's just some
ancilliary information that may or may not be required to render the
drawing.

There will need to be some standard headers that must be part of any
spec - As a minimum the format-version must live in a file with a
standard location and a standard internal layout that is the same
for all present and future "formats" - This is the one thing that
has to be right at this stage.

-- 
Bruno

Other related posts: