To LUGNET HomepageTo LUGNET News HomepageTo LUGNET Guide Homepage
 Help on Searching
 
Post new message to lugnet.cad.devOpen lugnet.cad.dev in your NNTP NewsreaderTo LUGNET News Traffic PageSign In (Members)
 CAD / Development / 9489
9488  |  9490
Subject: 
Re: LDRAWPREDIRS LDRAWPOSTDIRS - additional search paths
Newsgroups: 
lugnet.cad.dev
Date: 
Wed, 11 Feb 2004 18:24:42 GMT
Viewed: 
3504 times
  
In lugnet.cad.dev, Lars C. Hassing wrote:
Several users have asked for an option to L3P for specifying additional search paths for parts.
LDView already has implemented "Extra Search Dirs" to search after the usual ones.

just for the record. first time I came across custom folder support was in mid
november 2003 doing betatesting for mlcad's new release. for me one of the most
significant improvements in 3.01 'cos for the first time I could separate
unofficial parts from the official release or set up folders for
work-in-progress. at the same time doing also testing for LDView I asked Travis
if he could take over this feature and add support for custom folders to LDView.


I think it would be of common interest and for the benefit of the community if we could agree on

agree


THE way to do it, so I'll make the following proposal (as a starting point):
Two environment variables LDRAWPREDIRS and LDRAWPOSTDIRS
can be used to specify additional search directories.
Each variable can contain multiple directories separated by a |.
The search path will then be:
1. Inside the document if it is an MPD
2. The document's directory (the directory of the main model)
3. Any directories in %LDRAWPREDIRS%
4. %LDRAWDIR%\P
5. %LDRAWDIR%\PARTS
6. %LDRAWDIR%\MODELS
7. Any directories in %LDRAWPOSTDIRS%

MLCad handles the relative path and the scan order by new entries in its
MLCad.ini. it scans the folders at start-up and adds the findings to an internal
list(?). no new parts.lst gets written :-). having two parts of the same name it
ignores the second one: using Tore's boxed parts, the \Parts folder has to be
set above the \Parts\B folder. the custom parts show up or not (depending on the
flag) in the tree parts library as well as the parts preview window and behave
like official once located in the \parts folder. the search path supports
extended ASCII as well as blanks. this is just a short description how it works.
for technical details please ask Mike - I'm just the tester not the guru.


Environment variables are preferred, because they work on all platforms.
However, on Windows, if they are not set, ldraw.ini is then checked.
A sample ldraw.ini may look like this:
[LDraw]
BaseDirectory=C:\LDraw
LgeoDirectory=C:\L2P
PreDirectories=C:\LDrawXtra\MyParts\In Work
PostDirectories=C:\LDrawXtra\MyParts\Done|C:\LDrawXtra\UnOff

Other namings: LDRAWDIRPRE, LDRAWDIRSPRE, - you name it!
/Lars

again, I do not have the technical background and it would be absolutely
hazardous to make suggestions in that direction but wouldn't the ldconfig.ldr
file be the ideal place for such setting. the color meta discussion shows that
the ldconfig.ldr will inevitably become a container for general settings. why
having two distinct files for general system settings?

[thinking aloud mode ON]
Well, may be it's just me, but the limitations backward compatibility to ldraw
inflicts slowly becomes annoying. I really can't see the reason why I have to
separate dithered colors into subparts, because of a prog I never worked with.
[thinking aloud mode OFF]

my 0.02 euro,

w.



Message has 1 Reply:
  Re: LDRAWPREDIRS LDRAWPOSTDIRS - additional search paths
 
(...) No, because you already need the LDRAWDIR environment variable, or ldraw.ini, or some other OS specific method to find the LDRAW directory. And since directory paths have filesystem dependent quirks, it's probably best to keep them out of (...) (21 years ago, 11-Feb-04, to lugnet.cad.dev)

Message is in Reply To:
  LDRAWPREDIRS LDRAWPOSTDIRS - additional search paths
 
Several users have asked for an option to L3P for specifying additional search paths for parts. LDView already has implemented "Extra Search Dirs" to search after the usual ones. I think it would be of common interest and for the benefit of the (...) (21 years ago, 10-Feb-04, to lugnet.cad.dev)

132 Messages in This Thread:
(Inline display suppressed due to large size. Click Dots below to view.)
Entire Thread on One Page:
Nested:  All | Brief | Compact | Dots
Linear:  All | Brief | Compact

This Message and its Replies on One Page:
Nested:  All | Brief | Compact | Dots
Linear:  All | Brief | Compact
    

Custom Search

©2005 LUGNET. All rights reserved. - hosted by steinbruch.info GbR