Comment 12 for bug 593962

Revision history for this message
neels (neels) wrote : Re: [Bug 593962] Re: ratsnets coloring/visibility.

On Wed, Oct 31, 2018 at 04:03:34PM -0000, Victor W wrote:
> - Would it be possible to extend this to net classes, in addition to
> specific nets?

Maybe it would even make sense to *only* apply colors by net classes?

I'm thinking about complexity here. For my use-case, I have all nets on the
same netclass and only care about individual nets' colors. For other people,
coloring by netclasses makes more sense (defining a single color for any number
of nets). To support my simpler use case, I can simply create a netclass and
use that for my specific net -- the netclass can remain otherwise identical to
the default net class.

If we want to have both, single-net colors as well as netclass colors, it adds
two tiers of color selection, with complex choices like "use netclass color" or
"use specific color"... Doesn't need to be that complex.

Also I was having conceptual difficulty of figuring out where the ratsnest
color config should go, in terms of board commit / undo. A ratsnest is more of
a volatile thing and not a board item. If it is part of the netclass, I assume
the semantics are more straightforward. So I think that is a good idea.

> - To that end, have you considered moving the colouring rules to the
> "board set up" dialog box?

Yes and no -- so far I was looking for the super simplest GUI solution, to get
it to work minimally. The net selector thing and a brand new dialog was the
quickest way.

But if it is part of the netclass, I guess the Board Setup / Net classes GUI
might be a good place. There, though, it would break up that net classes table
that so far contains only numbers. We could add columns to select colors...

But if we retain the "show when moving" / "when not moving" logic, that should
rather be more verbose, like, one button in the table to open another modal
dialog for the ratsnest config.

We could also open up a whole new section: Board Setup / Layers / Ratsnest,
there define ratsnest coloring classes, and then tie netclasses to those
coloring classes. In a separate dialog, apart from the design rules fu.

I'm completely open, my patch basically just shows how to actually draw the
ratsnest in different colors.

I'm not sure how much time I will find to spend on this. It's been bugging me a
lot, so I wanted to at least show that it can be done. If anyone else is
willing to write up a suggestion, please go ahead!

BTW, if anyone was using this patch and saved the kicad_pcb file, which can now
no longer be parsed by the unpatched pcbnew, the solution is simple: remove the
"(ratsnest...)" sections in the .kicad_pcb file using a text editor.

~N