kozbot / kecb

Python program to generate industrial electrical symbol library.
MIT License
7 stars 3 forks source link

Extents #8

Open kozbot opened 7 years ago

kozbot commented 7 years ago

Any time a draw method is called it should add to a list for that block rectangle coordinates. From that list we can calculate the actual outer extents plus the block rounded extents which will be needed to implement circuits so symbols don't overlap.

kozbot commented 7 years ago

Can probably move the logic from add_rectangle elsewhere to support calculating the raw extents from as list of points as this basically does the same thing.

kozbot commented 6 years ago

Calling this bounds now, and refactoring with this in mind. Going to be integral to each entity type and Groups will return bounds taking into account their children.

kozbot commented 6 years ago

Found that this is blocking SVG and PNG import so moving up in priority. Approximate arc bounds as circles for now so we can get SVG and PNG done. Fix it properly later.