Skip to content
This repository has been archived by the owner on Oct 2, 2020. It is now read-only.

New EC for duplicate graphic elements #37

Open
diggit opened this issue Jul 10, 2016 · 3 comments
Open

New EC for duplicate graphic elements #37

diggit opened this issue Jul 10, 2016 · 3 comments

Comments

@diggit
Copy link
Collaborator

diggit commented Jul 10, 2016

It can easily happen when you are copying same parts of symbol.

  • SIMPLE - check for g. elements with same points

or

  • COMPLEX - find all overlapping lines no matter of what are they part of (polyline, rectangle), no matter of their length

What do you think?

@SchrodingersGat
Copy link
Contributor

I think that the SIMPLE options is a good start, and would be worlds easier to implement.

If you have the time and inclination to implement the COMPLEX option, then go for it, although I can see that raising a lot more false-positives than the SIMPLE one.

@cpresser
Copy link
Contributor

cpresser commented May 5, 2019

This looks like a similar challenge than #286
I think that the code in there can be easily adopted to work for symbols as well.
Is anyone aware of a (real) symbol with this problem that I can use for testing?

@evanshultz
Copy link
Collaborator

I recall seeing a few PRs I merged recently with overlapping or duplicate stuff. I don't recall all the details but I searched a few keywords and they may help:

I could make up a test case if you're looking for one. What did you have in mind to cover?

Note that a polyline and rectangle could overlap. Or the points in a polyline could be in reverse order. Perhaps other geometries can cause duplication of elements with no visual change as well. So doing this thoroughly won't be the same as checking for duplicate lines.

cpresser added a commit to cpresser/kicad-library-utils that referenced this issue Jun 1, 2019
Introduce new rule S3.9 to check if the symbol has duplicate graphical elements.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

6 participants