kicad-developers team mailing list archive
-
kicad-developers team
-
Mailing list archive
-
Message #11339
Re: First impressions on fp-table
On 9/25/2013 11:46 AM, Dick Hollenbeck wrote:
<<< snipped >>>
>>>
>>> At the moment a board is "saved as", then you have a project directory. Since the user
>>> did not load the board, but created it anew, there is no existing project table in the
>>> project directory. This is how I work, again, from the command line. If I then edit fp
>>> lib tables, and save, I would expect that template which was initially loaded from home to
>>> be saved into the new project directory. Because between starting pcbnew and editing the
>>> fp lib tables, I have mated with a BOARD and CWD (i.e. a project directory).
>>>
>>> Thats all it is, very simple. If I don't ever load a board or do a save as, then when I
>>> do edit fp lib table (project directory still unset) the Save (OK BUTTON), puts the
>>> project table back into home.
>>
>> This makes sense to me.
>>
>>>
>>>
>>> Now onto additional justification:
>>>
>>> Remember just last week we talked about having environment variables in the project table.
>>> You wanted to set a known variable, I said don't bother. Both of us agreed that the
>>> project table can *reference* env-variables even if we put the burden of *setting* them
>>> onto the user.
>>>
>>> Since it has environment variables in it, e.g. ${PROJ_LIB_DIR} I could actually use the
>>> same ROW for all projects.
>>>
>>> (name project)(uri ${PROJ_LIB_DIR}/project.pretty)(type Kicad))
>>>
>>> I have a project.pretty, I am free to put that where I want by setting env-var PROJ_LIB_DIR.
>>
>> I'm assuming that you prefer the environment variable to be set
>> internally by Pcbnew per my original suggestion. I'll go ahead and set
>> the path to the project footprint table to the cwd when a board file is
>> loaded, set it to ~/ when no board is loaded, and change it to the new
>> cwd on a save as.
>>
>> I should be able to get these changes done over the weekend.
>
>
> You da man.
>
> Thanks.
>
> BTW, I am not sure about the future of wxApp, as we move to main-module DLL-ization.
> Don't know yet. Might be prudent to establish an interface for "current project"
> identification (or none) as a separate entity. It could be made responsible for all the
> tasks associated with a project change. Don't know, many correct ways to do things.
> Brain cycles exhausted.
>
I just notice that Pcbnew sets the cwd to the path of the last board
loaded when no file is passed to it (see pcbnew.cpp). Is this the
behavior we want? It's not a big deal and I can work around it as far
as saving the project specific footprint library when not board file is
loaded but I just wondering if this makes sense.
Follow ups
References
-
First impressions on fp-table
From: Lorenzo Marcantonio, 2013-09-24
-
Re: First impressions on fp-table
From: Wayne Stambaugh, 2013-09-24
-
Re: First impressions on fp-table
From: Dick Hollenbeck, 2013-09-24
-
Re: First impressions on fp-table
From: Wayne Stambaugh, 2013-09-24
-
Re: First impressions on fp-table
From: Dick Hollenbeck, 2013-09-24
-
Re: First impressions on fp-table
From: Wayne Stambaugh, 2013-09-24
-
Re: First impressions on fp-table
From: Dick Hollenbeck, 2013-09-24
-
Re: First impressions on fp-table
From: Wayne Stambaugh, 2013-09-25
-
Re: First impressions on fp-table
From: Dick Hollenbeck, 2013-09-25
-
Re: First impressions on fp-table
From: Wayne Stambaugh, 2013-09-25
-
Re: First impressions on fp-table
From: Dick Hollenbeck, 2013-09-25