← Back to team overview

geda-developers team mailing list archive

Re: [geda-user] Revert "Reset refdes number to the question mark when parts are copied"

 

On Sun, 2013-09-08 at 17:49 +0100, Peter Clifton wrote:
> On Sun, 2013-09-08 at 09:23 -0700, Edward Hennessy wrote:
> 
> > This functionality was requested in launchpad bug #698748 and also matches
> > the behavior in commercial package I've used.
> 
> Which package is that? (I was going to ask if there is any precedent for
> that behaviour in other tools)
> 
> > Do you intend to check your script in, so the functionality is present in
> > geda-gaf, and the user can select it in a configuration file?
> 
> 
> I'll attach it to the bug, but currently do not have the time to add it
> to the build. (TBH, I need to make sure it still _works_ after all the
> scheme API work).


And the answer is that it half works. (IE, it functions, but it does not
do what we want...)

Changes have been made to the hooks system since my script was written,
although looking at it.. I'm wondering if it was written before I added
true clipboard cut, copy + paste support.

The "copy-component-hook" is actually invoked with the underlying
"paste-objects-hook", and at that stage, we cannot distinguish between a
Copy+paste or a cut+paste. (There is never any sense in resetting refdes
for a cut+paste).


A better solution all round might be to strip the refdes numbering from
any pasted component which clashes. If that were the case, I'd not even
have noticed it today!


-- 
Peter Clifton <peter.clifton@xxxxxxxxxxxxxxxxxxxxxxxxx>

Clifton Electronics



References