hi

the patch adds the following function:

it contains a button ("Add thermals") in the net window, right beside of "Rip 
up".

it contrains a function called "netlist_add_thrm_cb" too, which adds the 
thermals to the current layer to the pins of the selected net.

i hope this patch would be accepted, because it adds a handy function to 
process large GND nets.


with kind regards

Christian Riggenbach
Index: src/hid/gtk/gui-netlist-window.c
===================================================================
RCS file: /cvsroot/pcb/pcb/src/hid/gtk/gui-netlist-window.c,v
retrieving revision 1.13
diff -b -r1.13 gui-netlist-window.c
485a486,519
> /* A function to add a thermal to all pins of a net */
> static void
> netlist_add_thrm_cb (GtkWidget * widget, gpointer data)
> {
> 
>   if (!selected_net)
>     return;
>   netlist_find_cb(widget, data);
> 
>   ALLPIN_LOOP (PCB->Data);
>   {
>     if (TEST_FLAG (FOUNDFLAG, pin) && !TEST_FLAG (LOCKFLAG, pin)) {
> 
>       AddObjectToClearPolyUndoList (PIN_TYPE, element, pin, pin, False);
>       RestoreToPolygon (PCB->Data, VIA_TYPE, CURRENT, pin);
>       AddObjectToFlagUndoList (PIN_TYPE, element, pin, pin);
> 
>         ASSIGN_THERM (INDEXOFCURRENT, PCB->ThermStyle, pin);
> 
>       AddObjectToClearPolyUndoList (PIN_TYPE, element, pin, pin, True);
>       ClearFromPolygon (PCB->Data, VIA_TYPE, CURRENT, pin);
>       DrawPin (pin, 0);
> 
>     }
>   }
>   ENDALL_LOOP;
> 
>   ResetFoundPinsViasAndPads (False);
>   ResetFoundLinesAndPolygons (False);
> 
>   ClearAndRedrawOutput ();
> 
> }
> 
681a716,720
>   button = gtk_button_new_with_label (_("Add thermals"));
>   gtk_box_pack_start (GTK_BOX (hbox), button, FALSE, FALSE, 0);
>   g_signal_connect (G_OBJECT (button), "clicked",
> 		    G_CALLBACK (netlist_add_thrm_cb), GINT_TO_POINTER (0));
> 

Attachment: signature.asc
Description: This is a digitally signed message part.


_______________________________________________
geda-dev mailing list
[email protected]
http://www.seul.org/cgi-bin/mailman/listinfo/geda-dev

Reply via email to