Index: trunk/src/action_helper.c =================================================================== --- trunk/src/action_helper.c (revision 4770) +++ trunk/src/action_helper.c (revision 4771) @@ -66,8 +66,8 @@ { switch (type) { case PCB_TYPE_VIA: - *x = ((PinTypePtr) ptr2)->X; - *y = ((PinTypePtr) ptr2)->Y; + *x = ((pcb_pin_t *) ptr2)->X; + *y = ((pcb_pin_t *) ptr2)->Y; break; case PCB_TYPE_LINE: *x = ((pcb_line_t *) ptr2)->Point1.X; @@ -513,8 +513,8 @@ LookupConnection(Crosshair.X, Crosshair.Y, pcb_true, 1, PCB_FLAG_FOUND); } if (type == PCB_TYPE_PIN || type == PCB_TYPE_VIA) { - Crosshair.AttachedLine.Point1.X = Crosshair.AttachedLine.Point2.X = ((PinTypePtr) ptr2)->X; - Crosshair.AttachedLine.Point1.Y = Crosshair.AttachedLine.Point2.Y = ((PinTypePtr) ptr2)->Y; + Crosshair.AttachedLine.Point1.X = Crosshair.AttachedLine.Point2.X = ((pcb_pin_t *) ptr2)->X; + Crosshair.AttachedLine.Point1.Y = Crosshair.AttachedLine.Point2.Y = ((pcb_pin_t *) ptr2)->Y; } else if (type == PCB_TYPE_PAD) { pcb_pad_t *pad = (pcb_pad_t *) ptr2; @@ -599,13 +599,13 @@ */ for (test = (SELECT_TYPES | MOVE_TYPES) & ~PCB_TYPE_RATLINE; test; test &= ~type) { type = SearchScreen(Note.X, Note.Y, test, &ptr1, &ptr2, &ptr3); - if (!Note.Hit && (type & MOVE_TYPES) && !TEST_FLAG(PCB_FLAG_LOCK, (PinTypePtr) ptr2)) { + if (!Note.Hit && (type & MOVE_TYPES) && !TEST_FLAG(PCB_FLAG_LOCK, (pcb_pin_t *) ptr2)) { Note.Hit = type; Note.ptr1 = ptr1; Note.ptr2 = ptr2; Note.ptr3 = ptr3; } - if (!Note.Moving && (type & SELECT_TYPES) && TEST_FLAG(PCB_FLAG_SELECTED, (PinTypePtr) ptr2)) + if (!Note.Moving && (type & SELECT_TYPES) && TEST_FLAG(PCB_FLAG_SELECTED, (pcb_pin_t *) ptr2)) Note.Moving = pcb_true; if ((Note.Hit && Note.Moving) || type == PCB_TYPE_NONE) break; @@ -615,7 +615,7 @@ case PCB_MODE_VIA: { - PinTypePtr via; + pcb_pin_t *via; if (!PCB->ViaOn) { Message(PCB_MSG_DEFAULT, _("You must turn via visibility on before\n" "you can place vias\n")); @@ -744,15 +744,15 @@ case PCB_MODE_THERMAL: { if (((type = SearchScreen(Note.X, Note.Y, PCB_TYPEMASK_PIN, &ptr1, &ptr2, &ptr3)) != PCB_TYPE_NONE) - && !TEST_FLAG(PCB_FLAG_HOLE, (PinTypePtr) ptr3)) { + && !TEST_FLAG(PCB_FLAG_HOLE, (pcb_pin_t *) ptr3)) { if (gui->shift_is_pressed()) { - int tstyle = GET_THERM(INDEXOFCURRENT, (PinTypePtr) ptr3); + int tstyle = GET_THERM(INDEXOFCURRENT, (pcb_pin_t *) ptr3); tstyle++; if (tstyle > 5) tstyle = 1; ChangeObjectThermal(type, ptr1, ptr2, ptr3, tstyle); } - else if (GET_THERM(INDEXOFCURRENT, (PinTypePtr) ptr3)) + else if (GET_THERM(INDEXOFCURRENT, (pcb_pin_t *) ptr3)) ChangeObjectThermal(type, ptr1, ptr2, ptr3, 0); else ChangeObjectThermal(type, ptr1, ptr2, ptr3, PCB->ThermStyle); @@ -827,7 +827,7 @@ 2 * conf_core.design.clearance, MakeFlags(maybe_found_flag | (conf_core.editor.clear_line ? PCB_FLAG_CLEARLINE : 0)))) != NULL) { - PinTypePtr via; + pcb_pin_t *via; addedLines++; AddObjectToCreateUndoList(PCB_TYPE_LINE, CURRENT, line, line); @@ -1170,7 +1170,7 @@ SearchScreen(Note.X, Note.Y, types, &Crosshair.AttachedObject.Ptr1, &Crosshair.AttachedObject.Ptr2, &Crosshair.AttachedObject.Ptr3); if (Crosshair.AttachedObject.Type != PCB_TYPE_NONE) { - if (conf_core.editor.mode == PCB_MODE_MOVE && TEST_FLAG(PCB_FLAG_LOCK, (PinTypePtr) + if (conf_core.editor.mode == PCB_MODE_MOVE && TEST_FLAG(PCB_FLAG_LOCK, (pcb_pin_t *) Crosshair.AttachedObject.Ptr2)) { Message(PCB_MSG_DEFAULT, _("Sorry, the object is locked\n")); Crosshair.AttachedObject.Type = PCB_TYPE_NONE; Index: trunk/src/board.c =================================================================== --- trunk/src/board.c (revision 4770) +++ trunk/src/board.c (revision 4771) @@ -194,7 +194,7 @@ static r_dir_t hole_counting_callback(const pcb_box_t * b, void *cl) { - PinTypePtr pin = (PinTypePtr) b; + pcb_pin_t *pin = (pcb_pin_t *) b; HoleCountStruct *hcs = (HoleCountStruct *) cl; if (TEST_FLAG(PCB_FLAG_HOLE, pin)) hcs->nunplated++; Index: trunk/src/change.c =================================================================== --- trunk/src/change.c (revision 4770) +++ trunk/src/change.c (revision 4771) @@ -1203,15 +1203,15 @@ break; case PCB_TYPE_VIA: - name = gui->prompt_for(_("Vianame:"), EMPTY(((PinTypePtr) Ptr2)->Name)); + name = gui->prompt_for(_("Vianame:"), EMPTY(((pcb_pin_t *) Ptr2)->Name)); break; case PCB_TYPE_PIN: if (pinnum) - sprintf(msg, _("%s Pin Number:"), EMPTY(((PinTypePtr) Ptr2)->Number)); + sprintf(msg, _("%s Pin Number:"), EMPTY(((pcb_pin_t *) Ptr2)->Number)); else - sprintf(msg, _("%s Pin Name:"), EMPTY(((PinTypePtr) Ptr2)->Number)); - name = gui->prompt_for(msg, EMPTY(((PinTypePtr) Ptr2)->Name)); + sprintf(msg, _("%s Pin Name:"), EMPTY(((pcb_pin_t *) Ptr2)->Number)); + name = gui->prompt_for(msg, EMPTY(((pcb_pin_t *) Ptr2)->Name)); break; case PCB_TYPE_PAD: Index: trunk/src/change_act.c =================================================================== --- trunk/src/change_act.c (revision 4770) +++ trunk/src/change_act.c (revision 4771) @@ -197,7 +197,7 @@ void *ptr1, *ptr2, *ptr3; if ((type = SearchScreen(Crosshair.X, Crosshair.Y, CHANGESIZE_TYPES, &ptr1, &ptr2, &ptr3)) != PCB_TYPE_NONE) - if (TEST_FLAG(PCB_FLAG_LOCK, (PinTypePtr) ptr2)) + if (TEST_FLAG(PCB_FLAG_LOCK, (pcb_pin_t *) ptr2)) Message(PCB_MSG_DEFAULT, _("Sorry, the object is locked\n")); if (set_object(type, ptr1, ptr2, ptr3)) SetChangedFlag(pcb_true); @@ -272,7 +272,7 @@ void *ptr1, *ptr2, *ptr3; gui->get_coords(_("Select an Object"), &x, &y); - if ((type = SearchScreen(x, y, PCB_TYPE_VIA, &ptr1, &ptr2, &ptr3)) != PCB_TYPE_NONE && ChangeHole((PinTypePtr) ptr3)) + if ((type = SearchScreen(x, y, PCB_TYPE_VIA, &ptr1, &ptr2, &ptr3)) != PCB_TYPE_NONE && ChangeHole((pcb_pin_t *) ptr3)) IncrementUndoSerialNumber(); break; } @@ -409,7 +409,7 @@ case F_Object: { if (type != PCB_TYPE_NONE) - if (TEST_FLAG(PCB_FLAG_LOCK, (PinTypePtr) ptr2)) + if (TEST_FLAG(PCB_FLAG_LOCK, (pcb_pin_t *) ptr2)) Message(PCB_MSG_DEFAULT, _("Sorry, the object is locked\n")); if (tostyle) { if (ChangeObject1stSize(type, ptr1, ptr2, ptr3, value, absolute)) @@ -840,7 +840,7 @@ type = SearchScreen(x, y, CHANGESQUARE_TYPES, &ptr1, &ptr2, &ptr3); if (ptr3 != NULL) { - int qstyle = GET_SQUARE((PinTypePtr) ptr3); + int qstyle = GET_SQUARE((pcb_pin_t *) ptr3); qstyle++; if (qstyle > 17) qstyle = 0; @@ -1413,7 +1413,7 @@ case F_Object: { if (type != PCB_TYPE_NONE) { - if (TEST_FLAG(PCB_FLAG_LOCK, (PinTypePtr) ptr2)) + if (TEST_FLAG(PCB_FLAG_LOCK, (pcb_pin_t *) ptr2)) Message(PCB_MSG_DEFAULT, _("Sorry, the object is locked\n")); else { if (ChangeObjectAngle(type, ptr1, ptr2, ptr3, which, value, absolute)) @@ -1476,7 +1476,7 @@ case F_Object: { if (type != PCB_TYPE_NONE) { - if (TEST_FLAG(PCB_FLAG_LOCK, (PinTypePtr) ptr2)) + if (TEST_FLAG(PCB_FLAG_LOCK, (pcb_pin_t *) ptr2)) Message(PCB_MSG_DEFAULT, _("Sorry, the object is locked\n")); else { if (ChangeObjectRadius(type, ptr1, ptr2, ptr3, which, value, absolute)) Index: trunk/src/crosshair.c =================================================================== --- trunk/src/crosshair.c (revision 4770) +++ trunk/src/crosshair.c (revision 4771) @@ -61,10 +61,10 @@ static void XORDrawAttachedLine(Coord, Coord, Coord, Coord, Coord); static void XORDrawAttachedArc(Coord); -static void thindraw_moved_pv(PinType * pv, Coord x, Coord y) +static void thindraw_moved_pv(pcb_pin_t * pv, Coord x, Coord y) { /* Make a copy of the pin structure, moved to the correct position */ - PinType moved_pv = *pv; + pcb_pin_t moved_pv = *pv; moved_pv.X += x; moved_pv.Y += y; @@ -363,7 +363,7 @@ switch (Crosshair.AttachedObject.Type) { case PCB_TYPE_VIA: { - PinTypePtr via = (PinTypePtr) Crosshair.AttachedObject.Ptr1; + pcb_pin_t *via = (pcb_pin_t *) Crosshair.AttachedObject.Ptr1; thindraw_moved_pv(via, dx, dy); break; } @@ -492,7 +492,7 @@ case PCB_MODE_VIA: { /* Make a dummy via structure to draw from */ - PinType via; + pcb_pin_t via; via.X = Crosshair.X; via.Y = Crosshair.Y; via.Thickness = conf_core.design.via_thickness; @@ -1087,7 +1087,7 @@ ans = PCB_TYPE_NONE; if (ans != PCB_TYPE_NONE) { - PinType *pin = (PinType *) ptr2; + pcb_pin_t *pin = (pcb_pin_t *) ptr2; check_snap_object(&snap_data, pin->X, pin->Y, pcb_true); } @@ -1100,7 +1100,7 @@ ans = PCB_TYPE_NONE; if (ans != PCB_TYPE_NONE) { - PinType *pin = (PinType *) ptr2; + pcb_pin_t *pin = (pcb_pin_t *) ptr2; check_snap_object(&snap_data, pin->X, pin->Y, pcb_true); } Index: trunk/src/data.c =================================================================== --- trunk/src/data.c (revision 4770) +++ trunk/src/data.c (revision 4771) @@ -191,7 +191,7 @@ free(via->Name); } END_LOOP; - list_map0(&data->Via, PinType, RemoveFreeVia); + list_map0(&data->Via, pcb_pin_t, RemoveFreeVia); ELEMENT_LOOP(data); { FreeElementMemory(element); Index: trunk/src/data.h =================================================================== --- trunk/src/data.h (revision 4770) +++ trunk/src/data.h (revision 4771) @@ -99,11 +99,11 @@ typedef void (*pcb_eline_cb_t)(void *ctx, pcb_board_t *pcb, ElementType *element, pcb_line_t *line); typedef void (*pcb_earc_cb_t)(void *ctx, pcb_board_t *pcb, ElementType *element, pcb_arc_t *arc); typedef void (*pcb_etext_cb_t)(void *ctx, pcb_board_t *pcb, ElementType *element, TextType *text); -typedef void (*pcb_epin_cb_t)(void *ctx, pcb_board_t *pcb, ElementType *element, PinType *pin); +typedef void (*pcb_epin_cb_t)(void *ctx, pcb_board_t *pcb, ElementType *element, pcb_pin_t *pin); typedef void (*pcb_epad_cb_t)(void *ctx, pcb_board_t *pcb, ElementType *element, pcb_pad_t *pad); /* via callbacks */ -typedef void (*pcb_via_cb_t)(void *ctx, pcb_board_t *pcb, PinType *via); +typedef void (*pcb_via_cb_t)(void *ctx, pcb_board_t *pcb, pcb_pin_t *via); /* Loop over all layer objects on each layer. Layer is the outer loop. */ void pcb_loop_layers(void *ctx, pcb_layer_cb_t lacb, pcb_line_cb_t lcb, pcb_arc_cb_t acb, pcb_text_cb_t tcb, pcb_poly_cb_t pocb); Index: trunk/src/draw.c =================================================================== --- trunk/src/draw.c (revision 4770) +++ trunk/src/draw.c (revision 4771) @@ -496,7 +496,7 @@ switch (type) { case PCB_TYPE_VIA: case PCB_TYPE_PIN: - ErasePin((PinTypePtr) ptr); + ErasePin((pcb_pin_t *) ptr); break; case PCB_TYPE_TEXT: case PCB_TYPE_ELEMENT_NAME: @@ -531,7 +531,7 @@ switch (type) { case PCB_TYPE_VIA: if (PCB->ViaOn) - DrawVia((PinTypePtr) ptr2); + DrawVia((pcb_pin_t *) ptr2); break; case PCB_TYPE_LINE: if (((pcb_layer_t *) ptr1)->On) @@ -559,7 +559,7 @@ break; case PCB_TYPE_PIN: if (PCB->PinOn) - DrawPin((PinTypePtr) ptr2); + DrawPin((pcb_pin_t *) ptr2); break; case PCB_TYPE_PAD: if (PCB->PinOn) Index: trunk/src/find.c =================================================================== --- trunk/src/find.c (revision 4770) +++ trunk/src/find.c (revision 4771) @@ -110,7 +110,7 @@ (((pcb_polygon_t **)PolygonList[(L)].Data)[(I)]) #define PVLIST_ENTRY(I) \ - (((PinTypePtr *)PVList.Data)[(I)]) + (((pcb_pin_t **)PVList.Data)[(I)]) /* --------------------------------------------------------------------------- * some local types Index: trunk/src/find.h =================================================================== --- trunk/src/find.h (revision 4770) +++ trunk/src/find.h (revision 4771) @@ -62,7 +62,7 @@ pcb_bool LineLineIntersect(pcb_line_t *, pcb_line_t *); pcb_bool LineArcIntersect(pcb_line_t *, pcb_arc_t *); -pcb_bool PinLineIntersect(PinTypePtr, pcb_line_t *); +pcb_bool PinLineIntersect(pcb_pin_t *, pcb_line_t *); pcb_bool LinePadIntersect(pcb_line_t *, pcb_pad_t *); pcb_bool ArcPadIntersect(pcb_arc_t *, pcb_pad_t *); pcb_bool IsPolygonInPolygon(pcb_polygon_t *, pcb_polygon_t *); Index: trunk/src/find_debug.c =================================================================== --- trunk/src/find_debug.c (revision 4770) +++ trunk/src/find_debug.c (revision 4771) @@ -113,7 +113,7 @@ static void PrintPinConnections(FILE * FP, pcb_bool IsFirst) { pcb_cardinal_t i; - PinTypePtr pv; + pcb_pin_t *pv; if (!PVList.Number) return; Index: trunk/src/find_drc.c =================================================================== --- trunk/src/find_drc.c (revision 4770) +++ trunk/src/find_drc.c (revision 4771) @@ -154,7 +154,7 @@ case PCB_TYPE_PIN: case PCB_TYPE_VIA: { - PinTypePtr pin = (PinTypePtr) thing_ptr3; + pcb_pin_t *pin = (pcb_pin_t *) thing_ptr3; *x = pin->X; *y = pin->Y; break; @@ -234,7 +234,7 @@ pcb_line_t *line = (pcb_line_t *) ptr2; pcb_arc_t *arc = (pcb_arc_t *) ptr2; - PinTypePtr pin = (PinTypePtr) ptr2; + pcb_pin_t *pin = (pcb_pin_t *) ptr2; pcb_pad_t *pad = (pcb_pad_t *) ptr2; thing_type = type; Index: trunk/src/find_geo.c =================================================================== --- trunk/src/find_geo.c (revision 4770) +++ trunk/src/find_geo.c (revision 4771) @@ -623,7 +623,7 @@ return LinePadIntersect((pcb_line_t *) p1, p2); } -static inline pcb_bool PV_TOUCH_PV(PinTypePtr PV1, PinTypePtr PV2) +static inline pcb_bool PV_TOUCH_PV(pcb_pin_t *PV1, pcb_pin_t *PV2) { double t1, t2; pcb_box_t b1, b2; @@ -665,7 +665,7 @@ return BoxBoxIntersection(&b1, &b2); } -pcb_bool PinLineIntersect(PinTypePtr PV, pcb_line_t *Line) +pcb_bool PinLineIntersect(pcb_pin_t *PV, pcb_line_t *Line) { if (TEST_FLAG(PCB_FLAG_SQUARE, PV)) { int shape = GET_SQUARE(PV); Index: trunk/src/find_lookup.c =================================================================== --- trunk/src/find_lookup.c (revision 4770) +++ trunk/src/find_lookup.c (revision 4771) @@ -47,7 +47,7 @@ /* Connection lookup functions */ -static pcb_bool ADD_PV_TO_LIST(PinTypePtr Pin, int from_type, void *from_ptr, found_conn_type_t type) +static pcb_bool ADD_PV_TO_LIST(pcb_pin_t *Pin, int from_type, void *from_ptr, found_conn_type_t type) { if (User) AddObjectToFlagUndoList(Pin->Element ? PCB_TYPE_PIN : PCB_TYPE_VIA, Pin->Element ? Pin->Element : Pin, Pin, Pin); @@ -273,7 +273,7 @@ else TotalV = 0; /* allocate memory for 'new PV to check' list and clear struct */ - PVList.Data = (void **) calloc(TotalP + TotalV, sizeof(PinTypePtr)); + PVList.Data = (void **) calloc(TotalP + TotalV, sizeof(pcb_pin_t *)); PVList.Size = TotalP + TotalV; PVList.Location = 0; PVList.DrawLocation = 0; @@ -288,7 +288,7 @@ struct pv_info { pcb_cardinal_t layer; - PinType pv; + pcb_pin_t pv; jmp_buf env; }; @@ -531,7 +531,7 @@ static r_dir_t pv_pv_callback(const pcb_box_t * b, void *cl) { - PinTypePtr pin = (PinTypePtr) b; + pcb_pin_t *pin = (pcb_pin_t *) b; struct pv_info *i = (struct pv_info *) cl; if (!TEST_FLAG(TheFlag, pin) && PV_TOUCH_PV(&i->pv, pin)) { @@ -562,7 +562,7 @@ save_place = PVList.Location; while (PVList.Location < PVList.Number) { int ic; - PinType *orig_pin; + pcb_pin_t *orig_pin; /* get pointer to data */ orig_pin = (PVLIST_ENTRY(PVList.Location)); info.pv = *orig_pin; @@ -610,7 +610,7 @@ static r_dir_t pv_line_callback(const pcb_box_t * b, void *cl) { - PinTypePtr pv = (PinTypePtr) b; + pcb_pin_t *pv = (pcb_pin_t *) b; struct lo_info *i = (struct lo_info *) cl; if (!TEST_FLAG(TheFlag, pv) && PinLineIntersect(pv, &i->line)) { @@ -627,7 +627,7 @@ static r_dir_t pv_pad_callback(const pcb_box_t * b, void *cl) { - PinTypePtr pv = (PinTypePtr) b; + pcb_pin_t *pv = (pcb_pin_t *) b; struct lo_info *i = (struct lo_info *) cl; if (!TEST_FLAG(TheFlag, pv) && IS_PV_ON_PAD(pv, &i->pad)) { @@ -644,7 +644,7 @@ static r_dir_t pv_arc_callback(const pcb_box_t * b, void *cl) { - PinTypePtr pv = (PinTypePtr) b; + pcb_pin_t *pv = (pcb_pin_t *) b; struct lo_info *i = (struct lo_info *) cl; if (!TEST_FLAG(TheFlag, pv) && IS_PV_ON_ARC(pv, &i->arc)) { @@ -661,7 +661,7 @@ static r_dir_t pv_poly_callback(const pcb_box_t * b, void *cl) { - PinTypePtr pv = (PinTypePtr) b; + pcb_pin_t *pv = (pcb_pin_t *) b; struct lo_info *i = (struct lo_info *) cl; /* note that holes in polygons are ok, so they don't generate warnings. */ @@ -693,7 +693,7 @@ static r_dir_t pv_rat_callback(const pcb_box_t * b, void *cl) { - PinTypePtr pv = (PinTypePtr) b; + pcb_pin_t *pv = (pcb_pin_t *) b; struct lo_info *i = (struct lo_info *) cl; /* rats can't cause DRC so there is no early exit */ @@ -817,7 +817,7 @@ r_dir_t pv_touch_callback(const pcb_box_t * b, void *cl) { - PinTypePtr pin = (PinTypePtr) b; + pcb_pin_t *pin = (pcb_pin_t *) b; struct lo_info *i = (struct lo_info *) cl; if (!TEST_FLAG(TheFlag, pin) && PinLineIntersect(pin, &i->line)) Index: trunk/src/find_misc.c =================================================================== --- trunk/src/find_misc.c (revision 4770) +++ trunk/src/find_misc.c (revision 4771) @@ -125,7 +125,7 @@ * sorted array pointers to PV data */ while (PVList.DrawLocation < PVList.Number) { - PinTypePtr pv = PVLIST_ENTRY(PVList.DrawLocation); + pcb_pin_t *pv = PVLIST_ENTRY(PVList.DrawLocation); if (TEST_FLAG(PCB_FLAG_PIN, pv)) { if (PCB->PinOn) @@ -154,7 +154,7 @@ case PCB_TYPE_PIN: case PCB_TYPE_VIA: { - if (ADD_PV_TO_LIST((PinTypePtr) ptr2, 0, NULL, FCT_START)) + if (ADD_PV_TO_LIST((pcb_pin_t *) ptr2, 0, NULL, FCT_START)) return pcb_true; break; } Index: trunk/src/global_typedefs.h =================================================================== --- trunk/src/global_typedefs.h (revision 4770) +++ trunk/src/global_typedefs.h (revision 4771) @@ -41,7 +41,7 @@ typedef struct pcb_polygon_s pcb_polygon_t; typedef struct pad_st pcb_pad_t; -typedef struct pin_st PinType, *PinTypePtr, **PinTypeHandle; +typedef struct pin_st pcb_pin_t; typedef struct rtree rtree_t; typedef struct rats_patch_line_s rats_patch_line_t; typedef struct element_st ElementType, *ElementTypePtr, **ElementTypeHandle; Index: trunk/src/gui_act.c =================================================================== --- trunk/src/gui_act.c (revision 4770) +++ trunk/src/gui_act.c (revision 4771) @@ -485,12 +485,12 @@ break; case PCB_TYPE_PIN: - if (TEST_FLAG(PCB_FLAG_DISPLAYNAME, (PinTypePtr) ptr2)) - ErasePinName((PinTypePtr) ptr2); + if (TEST_FLAG(PCB_FLAG_DISPLAYNAME, (pcb_pin_t *) ptr2)) + ErasePinName((pcb_pin_t *) ptr2); else - DrawPinName((PinTypePtr) ptr2); + DrawPinName((pcb_pin_t *) ptr2); AddObjectToFlagUndoList(PCB_TYPE_PIN, ptr1, ptr2, ptr3); - TOGGLE_FLAG(PCB_FLAG_DISPLAYNAME, (PinTypePtr) ptr2); + TOGGLE_FLAG(PCB_FLAG_DISPLAYNAME, (pcb_pin_t *) ptr2); SetChangedFlag(pcb_true); IncrementUndoSerialNumber(); Draw(); @@ -508,12 +508,12 @@ Draw(); break; case PCB_TYPE_VIA: - if (TEST_FLAG(PCB_FLAG_DISPLAYNAME, (PinTypePtr) ptr2)) - EraseViaName((PinTypePtr) ptr2); + if (TEST_FLAG(PCB_FLAG_DISPLAYNAME, (pcb_pin_t *) ptr2)) + EraseViaName((pcb_pin_t *) ptr2); else - DrawViaName((PinTypePtr) ptr2); + DrawViaName((pcb_pin_t *) ptr2); AddObjectToFlagUndoList(PCB_TYPE_VIA, ptr1, ptr2, ptr3); - TOGGLE_FLAG(PCB_FLAG_DISPLAYNAME, (PinTypePtr) ptr2); + TOGGLE_FLAG(PCB_FLAG_DISPLAYNAME, (pcb_pin_t *) ptr2); SetChangedFlag(pcb_true); IncrementUndoSerialNumber(); Draw(); @@ -1164,7 +1164,7 @@ case PCB_TYPE_VIA: notify_crosshair_change(pcb_false); - set_same_(0, ((PinTypePtr) ptr2)->Thickness, ((PinTypePtr) ptr2)->DrillingHole, ((PinTypePtr) ptr2)->Clearance / 2, NULL); + set_same_(0, ((pcb_pin_t *) ptr2)->Thickness, ((pcb_pin_t *) ptr2)->DrillingHole, ((pcb_pin_t *) ptr2)->Clearance / 2, NULL); if (conf_core.editor.mode != PCB_MODE_VIA) SetMode(PCB_MODE_VIA); notify_crosshair_change(pcb_true); Index: trunk/src/hid.h =================================================================== --- trunk/src/hid.h (revision 4770) +++ trunk/src/hid.h (revision 4771) @@ -288,8 +288,8 @@ void (*thindraw_pcb_polygon) (hidGC gc_, pcb_polygon_t * poly, const pcb_box_t * clip_box); void (*fill_pcb_pad) (hidGC gc_, pcb_pad_t * pad, pcb_bool clip, pcb_bool mask); void (*thindraw_pcb_pad) (hidGC gc_, pcb_pad_t * pad, pcb_bool clip, pcb_bool mask); - void (*fill_pcb_pv) (hidGC fg_gc, hidGC bg_gc, PinType * pv, pcb_bool drawHole, pcb_bool mask); - void (*thindraw_pcb_pv) (hidGC fg_gc, hidGC bg_gc, PinType * pv, pcb_bool drawHole, pcb_bool mask); + void (*fill_pcb_pv) (hidGC fg_gc, hidGC bg_gc, pcb_pin_t * pv, pcb_bool drawHole, pcb_bool mask); + void (*thindraw_pcb_pv) (hidGC fg_gc, hidGC bg_gc, pcb_pin_t * pv, pcb_bool drawHole, pcb_bool mask); void (*fill_rect) (hidGC gc_, Coord x1_, Coord y1_, Coord x2_, Coord y2_); Index: trunk/src/hid_draw_helpers.c =================================================================== --- trunk/src/hid_draw_helpers.c (revision 4770) +++ trunk/src/hid_draw_helpers.c (revision 4771) @@ -342,7 +342,7 @@ } -void common_fill_pcb_pv(hidGC fg_gc, hidGC bg_gc, PinType * pv, pcb_bool drawHole, pcb_bool mask) +void common_fill_pcb_pv(hidGC fg_gc, hidGC bg_gc, pcb_pin_t * pv, pcb_bool drawHole, pcb_bool mask) { Coord w = mask ? pv->Mask : pv->Thickness; Coord r = w / 2; @@ -381,7 +381,7 @@ gui->fill_circle(bg_gc, pv->X, pv->Y, pv->DrillingHole / 2); } -void common_thindraw_pcb_pv(hidGC fg_gc, hidGC bg_gc, PinType * pv, pcb_bool drawHole, pcb_bool mask) +void common_thindraw_pcb_pv(hidGC fg_gc, hidGC bg_gc, pcb_pin_t * pv, pcb_bool drawHole, pcb_bool mask) { Coord w = mask ? pv->Mask : pv->Thickness; Coord r = w / 2; Index: trunk/src/hid_draw_helpers.h =================================================================== --- trunk/src/hid_draw_helpers.h (revision 4770) +++ trunk/src/hid_draw_helpers.h (revision 4771) @@ -4,7 +4,7 @@ void common_thindraw_pcb_polygon(hidGC gc, pcb_polygon_t * poly, const pcb_box_t * clip_box); void common_fill_pcb_pad(hidGC gc, pcb_pad_t * pad, pcb_bool clear, pcb_bool mask); void common_thindraw_pcb_pad(hidGC gc, pcb_pad_t * pad, pcb_bool clear, pcb_bool mask); -void common_fill_pcb_pv(hidGC gc, PinType * pv, pcb_bool drawHole, pcb_bool mask); -void common_thindraw_pcb_pv(hidGC fg_gc, hidGC bg_gc, PinType * pv, pcb_bool drawHole, pcb_bool mask); +void common_fill_pcb_pv(hidGC gc, pcb_pin_t * pv, pcb_bool drawHole, pcb_bool mask); +void common_thindraw_pcb_pv(hidGC fg_gc, hidGC bg_gc, pcb_pin_t * pv, pcb_bool drawHole, pcb_bool mask); void common_draw_helpers_init(HID * hid); #endif Index: trunk/src/hid_nogui.c =================================================================== --- trunk/src/hid_nogui.c (revision 4770) +++ trunk/src/hid_nogui.c (revision 4771) @@ -133,12 +133,12 @@ CRASH("thindraw_pcb_pad"); } -static void nogui_fill_pcb_pv(hidGC fg_gc, hidGC bg_gc, PinType * pad, pcb_bool drawHole, pcb_bool mask) +static void nogui_fill_pcb_pv(hidGC fg_gc, hidGC bg_gc, pcb_pin_t * pad, pcb_bool drawHole, pcb_bool mask) { CRASH("fill_pcb_pv"); } -static void nogui_thindraw_pcb_pv(hidGC fg_gc, hidGC bg_gc, PinType * pad, pcb_bool drawHole, pcb_bool mask) +static void nogui_thindraw_pcb_pv(hidGC fg_gc, hidGC bg_gc, pcb_pin_t * pad, pcb_bool drawHole, pcb_bool mask) { CRASH("thindraw_pcb_pv"); } Index: trunk/src/ht_element.c =================================================================== --- trunk/src/ht_element.c (revision 4770) +++ trunk/src/ht_element.c (revision 4771) @@ -34,7 +34,7 @@ #define h_str(s) ((s) == NULL ? 0 : strhash(s)) -int pcb_pin_eq(const ElementType *e1, const PinType *p1, const ElementType *e2, const PinType *p2) +int pcb_pin_eq(const ElementType *e1, const pcb_pin_t *p1, const ElementType *e2, const pcb_pin_t *p2) { if (neq(p1, p2, Thickness) || neq(p1, p2, Clearance)) return 0; if (neq(p1, p2, Mask) || neq(p1, p2, DrillingHole)) return 0; @@ -44,7 +44,7 @@ return 1; } -unsigned int pcb_pin_hash(const ElementType *e, const PinType *p) +unsigned int pcb_pin_hash(const ElementType *e, const pcb_pin_t *p) { return h_coord(p->Thickness) ^ h_coord(p->Clearance) ^ @@ -122,7 +122,7 @@ gdl_iterator_t it; { - PinType *p; + pcb_pin_t *p; pinlist_foreach(&e->Pin, &it, p) { val ^= pcb_pin_hash(e, p); } @@ -157,7 +157,7 @@ /* Require the same objects in the same order - bail out at the first mismatch */ { - PinType *p1, *p2; + pcb_pin_t *p1, *p2; p1 = pinlist_first((pinlist_t *)&e1->Pin); p2 = pinlist_first((pinlist_t *)&e2->Pin); for(;;) { Index: trunk/src/move.c =================================================================== --- trunk/src/move.c (revision 4770) +++ trunk/src/move.c (revision 4771) @@ -167,7 +167,7 @@ * moves the selected layers to a new index in the layer list. */ -static void move_one_thermal(int old_index, int new_index, PinType * pin) +static void move_one_thermal(int old_index, int new_index, pcb_pin_t * pin) { int t1 = 0, i; int oi = old_index, ni = new_index; Index: trunk/src/netlist.c =================================================================== --- trunk/src/netlist.c (revision 4770) +++ trunk/src/netlist.c (revision 4771) @@ -104,8 +104,8 @@ return 1; switch (conn.type) { case PCB_TYPE_PIN: - *x = ((PinType *) (conn.ptr2))->X; - *y = ((PinType *) (conn.ptr2))->Y; + *x = ((pcb_pin_t *) (conn.ptr2))->X; + *y = ((pcb_pin_t *) (conn.ptr2))->Y; return 0; case PCB_TYPE_PAD: *x = ((pcb_pad_t *) (conn.ptr2))->Point1.X; @@ -220,7 +220,7 @@ return pcb_netlist_find_net4pinname(pcb, pinname); } -LibraryMenuTypePtr pcb_netlist_find_net4pin(pcb_board_t *pcb, const PinType *pin) +LibraryMenuTypePtr pcb_netlist_find_net4pin(pcb_board_t *pcb, const pcb_pin_t *pin) { const ElementType *e = pin->Element; Index: trunk/src/netlist.h =================================================================== --- trunk/src/netlist.h (revision 4770) +++ trunk/src/netlist.h (revision 4771) @@ -69,7 +69,7 @@ LibraryMenuTypePtr pcb_netlist_find_net4pinname(pcb_board_t *pcb, const char *pinname); /* Same as pcb_netlist_find_net4pinname but with pin pointer */ -LibraryMenuTypePtr pcb_netlist_find_net4pin(pcb_board_t *pcb, const PinType *pin); +LibraryMenuTypePtr pcb_netlist_find_net4pin(pcb_board_t *pcb, const pcb_pin_t *pin); LibraryMenuTypePtr pcb_netlist_find_net4pad(pcb_board_t *pcb, const pcb_pad_t *pad); Index: trunk/src/obj_any.h =================================================================== --- trunk/src/obj_any.h (revision 4770) +++ trunk/src/obj_any.h (revision 4771) @@ -85,8 +85,8 @@ pcb_arc_t *arc; pcb_rat_t *rat; pcb_pad_t *pad; - PinType *pin; - PinType *via; + pcb_pin_t *pin; + pcb_pin_t *via; ElementType *element; pcb_net_t *net; pcb_layer_t *layer; Index: trunk/src/obj_elem.c =================================================================== --- trunk/src/obj_elem.c (revision 4770) +++ trunk/src/obj_elem.c (revision 4771) @@ -99,7 +99,7 @@ } END_LOOP; - list_map0(&element->Pin, PinType, RemoveFreePin); + list_map0(&element->Pin, pcb_pin_t, RemoveFreePin); list_map0(&element->Pad, pcb_pad_t, RemoveFreePad); list_map0(&element->Line, pcb_line_t, RemoveFreeLine); list_map0(&element->Arc, pcb_arc_t, RemoveFreeArc); @@ -1759,7 +1759,7 @@ return; if (pinlist_length(&e->Pin) != 0) { - PinType *pin0 = pinlist_first(&e->Pin); + pcb_pin_t *pin0 = pinlist_first(&e->Pin); if (TEST_FLAG(PCB_FLAG_HOLE, pin0)) mark_size = MIN(mark_size, pin0->DrillingHole / 2); else Index: trunk/src/obj_line.c =================================================================== --- trunk/src/obj_line.c (revision 4770) +++ trunk/src/obj_line.c (revision 4771) @@ -466,7 +466,7 @@ static r_dir_t moveline_callback(const pcb_box_t * b, void *cl) { struct via_info *i = (struct via_info *) cl; - PinTypePtr via; + pcb_pin_t *via; if ((via = CreateNewVia(PCB->Data, i->X, i->Y, Index: trunk/src/obj_line_drcenf.c =================================================================== --- trunk/src/obj_line_drcenf.c (revision 4770) +++ trunk/src/obj_line_drcenf.c (revision 4771) @@ -201,7 +201,7 @@ static r_dir_t drcVia_callback(const pcb_box_t * b, void *cl) { - PinTypePtr via = (PinTypePtr) b; + pcb_pin_t *via = (pcb_pin_t *) b; struct drc_info *i = (struct drc_info *) cl; if (!TEST_FLAG(PCB_FLAG_FOUND, via) && PinLineIntersect(via, i->line)) Index: trunk/src/obj_pinvia.c =================================================================== --- trunk/src/obj_pinvia.c (revision 4770) +++ trunk/src/obj_pinvia.c (revision 4771) @@ -47,17 +47,17 @@ /*** allocation ***/ /* get next slot for a via, allocates memory if necessary */ -PinType *GetViaMemory(pcb_data_t * data) +pcb_pin_t *GetViaMemory(pcb_data_t * data) { - PinType *new_obj; + pcb_pin_t *new_obj; - new_obj = calloc(sizeof(PinType), 1); + new_obj = calloc(sizeof(pcb_pin_t), 1); pinlist_append(&data->Via, new_obj); return new_obj; } -void RemoveFreeVia(PinType * data) +void RemoveFreeVia(pcb_pin_t * data) { pinlist_remove(data); free(data); @@ -64,17 +64,17 @@ } /* get next slot for a pin, allocates memory if necessary */ -PinType *GetPinMemory(ElementType * element) +pcb_pin_t *GetPinMemory(ElementType * element) { - PinType *new_obj; + pcb_pin_t *new_obj; - new_obj = calloc(sizeof(PinType), 1); + new_obj = calloc(sizeof(pcb_pin_t), 1); pinlist_append(&element->Pin, new_obj); return new_obj; } -void RemoveFreePin(PinType * data) +void RemoveFreePin(pcb_pin_t * data) { pinlist_remove(data); free(data); @@ -85,9 +85,9 @@ /*** utility ***/ /* creates a new via */ -PinTypePtr CreateNewVia(pcb_data_t *Data, Coord X, Coord Y, Coord Thickness, Coord Clearance, Coord Mask, Coord DrillingHole, const char *Name, FlagType Flags) +pcb_pin_t *CreateNewVia(pcb_data_t *Data, Coord X, Coord Y, Coord Thickness, Coord Clearance, Coord Mask, Coord DrillingHole, const char *Name, FlagType Flags) { - PinTypePtr Via; + pcb_pin_t *Via; if (!pcb_create_be_lenient) { VIA_LOOP(Data); @@ -138,9 +138,9 @@ } /* creates a new pin in an element */ -PinTypePtr CreateNewPin(ElementTypePtr Element, Coord X, Coord Y, Coord Thickness, Coord Clearance, Coord Mask, Coord DrillingHole, char *Name, char *Number, FlagType Flags) +pcb_pin_t *CreateNewPin(ElementTypePtr Element, Coord X, Coord Y, Coord Thickness, Coord Clearance, Coord Mask, Coord DrillingHole, char *Name, char *Number, FlagType Flags) { - PinTypePtr pin = GetPinMemory(Element); + pcb_pin_t *pin = GetPinMemory(Element); /* copy values */ pin->X = X; @@ -195,7 +195,7 @@ -void pcb_add_via(pcb_data_t *Data, PinType *Via) +void pcb_add_via(pcb_data_t *Data, pcb_pin_t *Via) { SetPinBoundingBox(Via); if (!Data->via_tree) @@ -204,7 +204,7 @@ } /* sets the bounding box of a pin or via */ -void SetPinBoundingBox(PinTypePtr Pin) +void SetPinBoundingBox(pcb_pin_t *Pin) { Coord width; @@ -233,13 +233,13 @@ /*** ops ***/ /* copies a via to paste buffer */ -void *AddViaToBuffer(pcb_opctx_t *ctx, PinTypePtr Via) +void *AddViaToBuffer(pcb_opctx_t *ctx, pcb_pin_t *Via) { return (CreateNewVia(ctx->buffer.dst, Via->X, Via->Y, Via->Thickness, Via->Clearance, Via->Mask, Via->DrillingHole, Via->Name, MaskFlags(Via->Flags, PCB_FLAG_FOUND | ctx->buffer.extraflg))); } /* moves a via to paste buffer without allocating memory for the name */ -void *MoveViaToBuffer(pcb_opctx_t *ctx, PinType * via) +void *MoveViaToBuffer(pcb_opctx_t *ctx, pcb_pin_t * via) { RestoreToPolygon(ctx->buffer.src, PCB_TYPE_VIA, via, via); @@ -257,7 +257,7 @@ } /* changes the thermal on a via */ -void *ChangeViaThermal(pcb_opctx_t *ctx, PinTypePtr Via) +void *ChangeViaThermal(pcb_opctx_t *ctx, pcb_pin_t *Via) { AddObjectToClearPolyUndoList(PCB_TYPE_VIA, Via, Via, Via, pcb_false); RestoreToPolygon(PCB->Data, PCB_TYPE_VIA, CURRENT, Via); @@ -273,7 +273,7 @@ } /* changes the thermal on a pin */ -void *ChangePinThermal(pcb_opctx_t *ctx, ElementTypePtr element, PinTypePtr Pin) +void *ChangePinThermal(pcb_opctx_t *ctx, ElementTypePtr element, pcb_pin_t *Pin) { AddObjectToClearPolyUndoList(PCB_TYPE_PIN, element, Pin, Pin, pcb_false); RestoreToPolygon(PCB->Data, PCB_TYPE_VIA, CURRENT, Pin); @@ -289,7 +289,7 @@ } /* changes the size of a via */ -void *ChangeViaSize(pcb_opctx_t *ctx, PinTypePtr Via) +void *ChangeViaSize(pcb_opctx_t *ctx, pcb_pin_t *Via) { Coord value = ctx->chgsize.absolute ? ctx->chgsize.absolute : Via->Thickness + ctx->chgsize.delta; @@ -316,7 +316,7 @@ } /* changes the drilling hole of a via */ -void *ChangeVia2ndSize(pcb_opctx_t *ctx, PinTypePtr Via) +void *ChangeVia2ndSize(pcb_opctx_t *ctx, pcb_pin_t *Via) { Coord value = (ctx->chgsize.absolute) ? ctx->chgsize.absolute : Via->DrillingHole + ctx->chgsize.delta; @@ -341,7 +341,7 @@ } /* changes the drilling hole of a pin */ -void *ChangePin2ndSize(pcb_opctx_t *ctx, ElementTypePtr Element, PinTypePtr Pin) +void *ChangePin2ndSize(pcb_opctx_t *ctx, ElementTypePtr Element, pcb_pin_t *Pin) { Coord value = (ctx->chgsize.absolute) ? ctx->chgsize.absolute : Pin->DrillingHole + ctx->chgsize.delta; @@ -367,7 +367,7 @@ /* changes the clearance size of a via */ -void *ChangeViaClearSize(pcb_opctx_t *ctx, PinTypePtr Via) +void *ChangeViaClearSize(pcb_opctx_t *ctx, pcb_pin_t *Via) { Coord value = (ctx->chgsize.absolute) ? ctx->chgsize.absolute : Via->Clearance + ctx->chgsize.delta; @@ -397,7 +397,7 @@ /* changes the size of a pin */ -void *ChangePinSize(pcb_opctx_t *ctx, ElementTypePtr Element, PinTypePtr Pin) +void *ChangePinSize(pcb_opctx_t *ctx, ElementTypePtr Element, pcb_pin_t *Pin) { Coord value = (ctx->chgsize.absolute) ? ctx->chgsize.absolute : Pin->Thickness + ctx->chgsize.delta; @@ -422,7 +422,7 @@ } /* changes the clearance size of a pin */ -void *ChangePinClearSize(pcb_opctx_t *ctx, ElementTypePtr Element, PinTypePtr Pin) +void *ChangePinClearSize(pcb_opctx_t *ctx, ElementTypePtr Element, pcb_pin_t *Pin) { Coord value = (ctx->chgsize.absolute) ? ctx->chgsize.absolute : Pin->Clearance + ctx->chgsize.delta; @@ -450,7 +450,7 @@ } /* changes the name of a via */ -void *ChangeViaName(pcb_opctx_t *ctx, PinTypePtr Via) +void *ChangeViaName(pcb_opctx_t *ctx, pcb_pin_t *Via) { char *old = Via->Name; @@ -465,7 +465,7 @@ } /* changes the name of a pin */ -void *ChangePinName(pcb_opctx_t *ctx, ElementTypePtr Element, PinTypePtr Pin) +void *ChangePinName(pcb_opctx_t *ctx, ElementTypePtr Element, pcb_pin_t *Pin) { char *old = Pin->Name; @@ -481,7 +481,7 @@ } /* changes the number of a pin */ -void *ChangePinNum(pcb_opctx_t *ctx, ElementTypePtr Element, PinTypePtr Pin) +void *ChangePinNum(pcb_opctx_t *ctx, ElementTypePtr Element, pcb_pin_t *Pin) { char *old = Pin->Number; @@ -498,7 +498,7 @@ /* changes the square flag of a via */ -void *ChangeViaSquare(pcb_opctx_t *ctx, PinTypePtr Via) +void *ChangeViaSquare(pcb_opctx_t *ctx, pcb_pin_t *Via) { if (TEST_FLAG(PCB_FLAG_LOCK, Via)) return (NULL); @@ -519,7 +519,7 @@ } /* changes the square flag of a pin */ -void *ChangePinSquare(pcb_opctx_t *ctx, ElementTypePtr Element, PinTypePtr Pin) +void *ChangePinSquare(pcb_opctx_t *ctx, ElementTypePtr Element, pcb_pin_t *Pin) { if (TEST_FLAG(PCB_FLAG_LOCK, Pin)) return (NULL); @@ -540,7 +540,7 @@ } /* sets the square flag of a pin */ -void *SetPinSquare(pcb_opctx_t *ctx, ElementTypePtr Element, PinTypePtr Pin) +void *SetPinSquare(pcb_opctx_t *ctx, ElementTypePtr Element, pcb_pin_t *Pin) { if (TEST_FLAG(PCB_FLAG_LOCK, Pin) || TEST_FLAG(PCB_FLAG_SQUARE, Pin)) return (NULL); @@ -549,7 +549,7 @@ } /* clears the square flag of a pin */ -void *ClrPinSquare(pcb_opctx_t *ctx, ElementTypePtr Element, PinTypePtr Pin) +void *ClrPinSquare(pcb_opctx_t *ctx, ElementTypePtr Element, pcb_pin_t *Pin) { if (TEST_FLAG(PCB_FLAG_LOCK, Pin) || !TEST_FLAG(PCB_FLAG_SQUARE, Pin)) return (NULL); @@ -558,7 +558,7 @@ } /* changes the octagon flag of a via */ -void *ChangeViaOctagon(pcb_opctx_t *ctx, PinTypePtr Via) +void *ChangeViaOctagon(pcb_opctx_t *ctx, pcb_pin_t *Via) { if (TEST_FLAG(PCB_FLAG_LOCK, Via)) return (NULL); @@ -574,7 +574,7 @@ } /* sets the octagon flag of a via */ -void *SetViaOctagon(pcb_opctx_t *ctx, PinTypePtr Via) +void *SetViaOctagon(pcb_opctx_t *ctx, pcb_pin_t *Via) { if (TEST_FLAG(PCB_FLAG_LOCK, Via) || TEST_FLAG(PCB_FLAG_OCTAGON, Via)) return (NULL); @@ -583,7 +583,7 @@ } /* clears the octagon flag of a via */ -void *ClrViaOctagon(pcb_opctx_t *ctx, PinTypePtr Via) +void *ClrViaOctagon(pcb_opctx_t *ctx, pcb_pin_t *Via) { if (TEST_FLAG(PCB_FLAG_LOCK, Via) || !TEST_FLAG(PCB_FLAG_OCTAGON, Via)) return (NULL); @@ -592,7 +592,7 @@ } /* changes the octagon flag of a pin */ -void *ChangePinOctagon(pcb_opctx_t *ctx, ElementTypePtr Element, PinTypePtr Pin) +void *ChangePinOctagon(pcb_opctx_t *ctx, ElementTypePtr Element, pcb_pin_t *Pin) { if (TEST_FLAG(PCB_FLAG_LOCK, Pin)) return (NULL); @@ -608,7 +608,7 @@ } /* sets the octagon flag of a pin */ -void *SetPinOctagon(pcb_opctx_t *ctx, ElementTypePtr Element, PinTypePtr Pin) +void *SetPinOctagon(pcb_opctx_t *ctx, ElementTypePtr Element, pcb_pin_t *Pin) { if (TEST_FLAG(PCB_FLAG_LOCK, Pin) || TEST_FLAG(PCB_FLAG_OCTAGON, Pin)) return (NULL); @@ -617,7 +617,7 @@ } /* clears the octagon flag of a pin */ -void *ClrPinOctagon(pcb_opctx_t *ctx, ElementTypePtr Element, PinTypePtr Pin) +void *ClrPinOctagon(pcb_opctx_t *ctx, ElementTypePtr Element, pcb_pin_t *Pin) { if (TEST_FLAG(PCB_FLAG_LOCK, Pin) || !TEST_FLAG(PCB_FLAG_OCTAGON, Pin)) return (NULL); @@ -626,7 +626,7 @@ } /* changes the hole flag of a via */ -pcb_bool ChangeHole(PinTypePtr Via) +pcb_bool ChangeHole(pcb_pin_t *Via) { if (TEST_FLAG(PCB_FLAG_LOCK, Via)) return (pcb_false); @@ -660,7 +660,7 @@ } /* changes the mask size of a pin */ -void *ChangePinMaskSize(pcb_opctx_t *ctx, ElementTypePtr Element, PinTypePtr Pin) +void *ChangePinMaskSize(pcb_opctx_t *ctx, ElementTypePtr Element, pcb_pin_t *Pin) { Coord value = (ctx->chgsize.absolute) ? ctx->chgsize.absolute : Pin->Mask + ctx->chgsize.delta; @@ -680,7 +680,7 @@ } /* changes the mask size of a via */ -void *ChangeViaMaskSize(pcb_opctx_t *ctx, PinTypePtr Via) +void *ChangeViaMaskSize(pcb_opctx_t *ctx, pcb_pin_t *Via) { Coord value; @@ -700,9 +700,9 @@ } /* copies a via */ -void *CopyVia(pcb_opctx_t *ctx, PinTypePtr Via) +void *CopyVia(pcb_opctx_t *ctx, pcb_pin_t *Via) { - PinTypePtr via; + pcb_pin_t *via; via = CreateNewVia(PCB->Data, Via->X + ctx->copy.DeltaX, Via->Y + ctx->copy.DeltaY, Via->Thickness, Via->Clearance, Via->Mask, Via->DrillingHole, Via->Name, MaskFlags(Via->Flags, PCB_FLAG_FOUND)); @@ -714,7 +714,7 @@ } /* moves a via */ -void *MoveVia(pcb_opctx_t *ctx, PinTypePtr Via) +void *MoveVia(pcb_opctx_t *ctx, pcb_pin_t *Via) { r_delete_entry(PCB->Data->via_tree, (pcb_box_t *) Via); RestoreToPolygon(PCB->Data, PCB_TYPE_VIA, Via, Via); @@ -731,7 +731,7 @@ } /* destroys a via */ -void *DestroyVia(pcb_opctx_t *ctx, PinTypePtr Via) +void *DestroyVia(pcb_opctx_t *ctx, pcb_pin_t *Via) { r_delete_entry(ctx->remove.destroy_target->via_tree, (pcb_box_t *) Via); free(Via->Name); @@ -741,7 +741,7 @@ } /* removes a via */ -void *RemoveVia(pcb_opctx_t *ctx, PinTypePtr Via) +void *RemoveVia(pcb_opctx_t *ctx, pcb_pin_t *Via) { /* erase from screen and memory */ if (PCB->ViaOn) { @@ -756,7 +756,7 @@ /*** draw ***/ /* setup color for pin or via */ -static void SetPVColor(PinTypePtr Pin, int Type) +static void SetPVColor(pcb_pin_t *Pin, int Type) { char *color; char buf[sizeof("#XXXXXX")]; @@ -801,7 +801,7 @@ gui->set_color(Output.fgGC, color); } -static void _draw_pv_name(PinType * pv) +static void _draw_pv_name(pcb_pin_t * pv) { pcb_box_t box; pcb_bool vert; @@ -847,7 +847,7 @@ pcb_draw_doing_pinout--; } -static void _draw_pv(PinTypePtr pv, pcb_bool draw_hole) +static void _draw_pv(pcb_pin_t *pv, pcb_bool draw_hole) { if (conf_core.editor.thin_draw) gui->thindraw_pcb_pv(Output.fgGC, Output.fgGC, pv, draw_hole, pcb_false); @@ -858,7 +858,7 @@ _draw_pv_name(pv); } -void draw_pin(PinTypePtr pin, pcb_bool draw_hole) +void draw_pin(pcb_pin_t *pin, pcb_bool draw_hole) { SetPVColor(pin, PCB_TYPE_PIN); _draw_pv(pin, draw_hole); @@ -866,13 +866,13 @@ r_dir_t draw_pin_callback(const pcb_box_t * b, void *cl) { - draw_pin((PinType *) b, pcb_false); + draw_pin((pcb_pin_t *) b, pcb_false); return R_DIR_FOUND_CONTINUE; } r_dir_t clear_pin_callback(const pcb_box_t * b, void *cl) { - PinType *pin = (PinTypePtr) b; + pcb_pin_t *pin = (pcb_pin_t *) b; if (conf_core.editor.thin_draw || conf_core.editor.thin_draw_poly) gui->thindraw_pcb_pv(Output.pmGC, Output.pmGC, pin, pcb_false, pcb_true); else @@ -881,7 +881,7 @@ } -static void draw_via(PinTypePtr via, pcb_bool draw_hole) +static void draw_via(pcb_pin_t *via, pcb_bool draw_hole) { SetPVColor(via, PCB_TYPE_VIA); _draw_pv(via, draw_hole); @@ -889,13 +889,13 @@ r_dir_t draw_via_callback(const pcb_box_t * b, void *cl) { - draw_via((PinType *) b, pcb_false); + draw_via((pcb_pin_t *) b, pcb_false); return R_DIR_FOUND_CONTINUE; } r_dir_t draw_hole_callback(const pcb_box_t * b, void *cl) { - PinTypePtr pv = (PinTypePtr) b; + pcb_pin_t *pv = (pcb_pin_t *) b; int plated = cl ? *(int *) cl : -1; const char *color; char buf[sizeof("#XXXXXX")]; @@ -935,7 +935,7 @@ return R_DIR_FOUND_CONTINUE; } -static void GatherPVName(PinTypePtr Ptr) +static void GatherPVName(pcb_pin_t *Ptr) { pcb_box_t box; pcb_bool vert = TEST_FLAG(PCB_FLAG_EDGE2, Ptr); @@ -960,7 +960,7 @@ pcb_draw_invalidate(&box); } -void EraseVia(PinTypePtr Via) +void EraseVia(pcb_pin_t *Via) { pcb_draw_invalidate(Via); if (TEST_FLAG(PCB_FLAG_DISPLAYNAME, Via)) @@ -968,12 +968,12 @@ EraseFlags(&Via->Flags); } -void EraseViaName(PinTypePtr Via) +void EraseViaName(pcb_pin_t *Via) { GatherPVName(Via); } -void ErasePin(PinTypePtr Pin) +void ErasePin(pcb_pin_t *Pin) { pcb_draw_invalidate(Pin); if (TEST_FLAG(PCB_FLAG_DISPLAYNAME, Pin)) @@ -981,12 +981,12 @@ EraseFlags(&Pin->Flags); } -void ErasePinName(PinTypePtr Pin) +void ErasePinName(pcb_pin_t *Pin) { GatherPVName(Pin); } -void DrawVia(PinTypePtr Via) +void DrawVia(pcb_pin_t *Via) { pcb_draw_invalidate(Via); if (!TEST_FLAG(PCB_FLAG_HOLE, Via) && TEST_FLAG(PCB_FLAG_DISPLAYNAME, Via)) @@ -993,12 +993,12 @@ DrawViaName(Via); } -void DrawViaName(PinTypePtr Via) +void DrawViaName(pcb_pin_t *Via) { GatherPVName(Via); } -void DrawPin(PinTypePtr Pin) +void DrawPin(pcb_pin_t *Pin) { pcb_draw_invalidate(Pin); if ((!TEST_FLAG(PCB_FLAG_HOLE, Pin) && TEST_FLAG(PCB_FLAG_DISPLAYNAME, Pin)) @@ -1006,7 +1006,7 @@ DrawPinName(Pin); } -void DrawPinName(PinTypePtr Pin) +void DrawPinName(pcb_pin_t *Pin) { GatherPVName(Pin); } Index: trunk/src/obj_pinvia.h =================================================================== --- trunk/src/obj_pinvia.h (revision 4770) +++ trunk/src/obj_pinvia.h (revision 4771) @@ -42,16 +42,16 @@ }; -PinType *GetViaMemory(pcb_data_t * data); -void RemoveFreeVia(PinType * data); -PinType *GetPinMemory(ElementType * element); -void RemoveFreePin(PinType * data); +pcb_pin_t *GetViaMemory(pcb_data_t * data); +void RemoveFreeVia(pcb_pin_t * data); +pcb_pin_t *GetPinMemory(ElementType * element); +void RemoveFreePin(pcb_pin_t * data); -PinTypePtr CreateNewVia(pcb_data_t *Data, Coord X, Coord Y, Coord Thickness, Coord Clearance, Coord Mask, Coord DrillingHole, const char *Name, FlagType Flags); -PinTypePtr CreateNewPin(ElementTypePtr Element, Coord X, Coord Y, Coord Thickness, Coord Clearance, Coord Mask, Coord DrillingHole, char *Name, char *Number, FlagType Flags); -void pcb_add_via(pcb_data_t *Data, PinType *Via); -void SetPinBoundingBox(PinTypePtr Pin); -pcb_bool ChangeHole(PinTypePtr Via); +pcb_pin_t *CreateNewVia(pcb_data_t *Data, Coord X, Coord Y, Coord Thickness, Coord Clearance, Coord Mask, Coord DrillingHole, const char *Name, FlagType Flags); +pcb_pin_t *CreateNewPin(ElementTypePtr Element, Coord X, Coord Y, Coord Thickness, Coord Clearance, Coord Mask, Coord DrillingHole, char *Name, char *Number, FlagType Flags); +void pcb_add_via(pcb_data_t *Data, pcb_pin_t *Via); +void SetPinBoundingBox(pcb_pin_t *Pin); +pcb_bool ChangeHole(pcb_pin_t *Via); /* This is the extents of a Pin or Via, depending on whether it's a hole or not. */ @@ -75,12 +75,12 @@ #define VIA_LOOP(top) do { \ - PinType *via; \ + pcb_pin_t *via; \ gdl_iterator_t __it__; \ pinlist_foreach(&(top)->Via, &__it__, via) { #define PIN_LOOP(element) do { \ - PinType *pin; \ + pcb_pin_t *pin; \ gdl_iterator_t __it__; \ pinlist_foreach(&(element)->Pin, &__it__, pin) { Index: trunk/src/obj_pinvia_draw.h =================================================================== --- trunk/src/obj_pinvia_draw.h (revision 4770) +++ trunk/src/obj_pinvia_draw.h (revision 4771) @@ -35,12 +35,12 @@ #endif -void draw_pin(PinTypePtr pin, pcb_bool draw_hole); -void EraseVia(PinTypePtr Via); -void EraseViaName(PinTypePtr Via); -void ErasePin(PinTypePtr Pin); -void ErasePinName(PinTypePtr Pin); -void DrawVia(PinTypePtr Via); -void DrawViaName(PinTypePtr Via); -void DrawPin(PinTypePtr Pin); -void DrawPinName(PinTypePtr Pin); +void draw_pin(pcb_pin_t *pin, pcb_bool draw_hole); +void EraseVia(pcb_pin_t *Via); +void EraseViaName(pcb_pin_t *Via); +void ErasePin(pcb_pin_t *Pin); +void ErasePinName(pcb_pin_t *Pin); +void DrawVia(pcb_pin_t *Via); +void DrawViaName(pcb_pin_t *Via); +void DrawPin(pcb_pin_t *Pin); +void DrawPinName(pcb_pin_t *Pin); Index: trunk/src/obj_pinvia_list.h =================================================================== --- trunk/src/obj_pinvia_list.h (revision 4770) +++ trunk/src/obj_pinvia_list.h (revision 4771) @@ -28,7 +28,7 @@ /* List of Pins */ #define TDL(x) pinlist_ ## x #define TDL_LIST_T pinlist_t -#define TDL_ITEM_T PinType +#define TDL_ITEM_T pcb_pin_t #define TDL_FIELD link #define TDL_SIZE_T size_t #define TDL_FUNC Index: trunk/src/obj_pinvia_op.h =================================================================== --- trunk/src/obj_pinvia_op.h (revision 4770) +++ trunk/src/obj_pinvia_op.h (revision 4771) @@ -28,33 +28,33 @@ #include "operation.h" -void *AddViaToBuffer(pcb_opctx_t *ctx, PinTypePtr Via); -void *MoveViaToBuffer(pcb_opctx_t *ctx, PinType * via); -void *ChangeViaThermal(pcb_opctx_t *ctx, PinTypePtr Via); -void *ChangePinThermal(pcb_opctx_t *ctx, ElementTypePtr element, PinTypePtr Pin); -void *ChangeViaSize(pcb_opctx_t *ctx, PinTypePtr Via); -void *ChangeVia2ndSize(pcb_opctx_t *ctx, PinTypePtr Via); -void *ChangePin2ndSize(pcb_opctx_t *ctx, ElementTypePtr Element, PinTypePtr Pin); -void *ChangeViaClearSize(pcb_opctx_t *ctx, PinTypePtr Via); -void *ChangePinSize(pcb_opctx_t *ctx, ElementTypePtr Element, PinTypePtr Pin); -void *ChangePinClearSize(pcb_opctx_t *ctx, ElementTypePtr Element, PinTypePtr Pin); -void *ChangeViaName(pcb_opctx_t *ctx, PinTypePtr Via); -void *ChangePinName(pcb_opctx_t *ctx, ElementTypePtr Element, PinTypePtr Pin); -void *ChangePinNum(pcb_opctx_t *ctx, ElementTypePtr Element, PinTypePtr Pin); -void *ChangeViaSquare(pcb_opctx_t *ctx, PinTypePtr Via); -void *ChangePinSquare(pcb_opctx_t *ctx, ElementTypePtr Element, PinTypePtr Pin); -void *SetPinSquare(pcb_opctx_t *ctx, ElementTypePtr Element, PinTypePtr Pin); -void *ClrPinSquare(pcb_opctx_t *ctx, ElementTypePtr Element, PinTypePtr Pin); -void *ChangeViaOctagon(pcb_opctx_t *ctx, PinTypePtr Via); -void *SetViaOctagon(pcb_opctx_t *ctx, PinTypePtr Via); -void *ClrViaOctagon(pcb_opctx_t *ctx, PinTypePtr Via); -void *ChangePinOctagon(pcb_opctx_t *ctx, ElementTypePtr Element, PinTypePtr Pin); -void *SetPinOctagon(pcb_opctx_t *ctx, ElementTypePtr Element, PinTypePtr Pin); -void *ClrPinOctagon(pcb_opctx_t *ctx, ElementTypePtr Element, PinTypePtr Pin); -pcb_bool ChangeHole(PinTypePtr Via); -void *ChangePinMaskSize(pcb_opctx_t *ctx, ElementTypePtr Element, PinTypePtr Pin); -void *ChangeViaMaskSize(pcb_opctx_t *ctx, PinTypePtr Via); -void *CopyVia(pcb_opctx_t *ctx, PinTypePtr Via); -void *MoveVia(pcb_opctx_t *ctx, PinTypePtr Via); -void *DestroyVia(pcb_opctx_t *ctx, PinTypePtr Via); -void *RemoveVia(pcb_opctx_t *ctx, PinTypePtr Via); +void *AddViaToBuffer(pcb_opctx_t *ctx, pcb_pin_t *Via); +void *MoveViaToBuffer(pcb_opctx_t *ctx, pcb_pin_t * via); +void *ChangeViaThermal(pcb_opctx_t *ctx, pcb_pin_t *Via); +void *ChangePinThermal(pcb_opctx_t *ctx, ElementTypePtr element, pcb_pin_t *Pin); +void *ChangeViaSize(pcb_opctx_t *ctx, pcb_pin_t *Via); +void *ChangeVia2ndSize(pcb_opctx_t *ctx, pcb_pin_t *Via); +void *ChangePin2ndSize(pcb_opctx_t *ctx, ElementTypePtr Element, pcb_pin_t *Pin); +void *ChangeViaClearSize(pcb_opctx_t *ctx, pcb_pin_t *Via); +void *ChangePinSize(pcb_opctx_t *ctx, ElementTypePtr Element, pcb_pin_t *Pin); +void *ChangePinClearSize(pcb_opctx_t *ctx, ElementTypePtr Element, pcb_pin_t *Pin); +void *ChangeViaName(pcb_opctx_t *ctx, pcb_pin_t *Via); +void *ChangePinName(pcb_opctx_t *ctx, ElementTypePtr Element, pcb_pin_t *Pin); +void *ChangePinNum(pcb_opctx_t *ctx, ElementTypePtr Element, pcb_pin_t *Pin); +void *ChangeViaSquare(pcb_opctx_t *ctx, pcb_pin_t *Via); +void *ChangePinSquare(pcb_opctx_t *ctx, ElementTypePtr Element, pcb_pin_t *Pin); +void *SetPinSquare(pcb_opctx_t *ctx, ElementTypePtr Element, pcb_pin_t *Pin); +void *ClrPinSquare(pcb_opctx_t *ctx, ElementTypePtr Element, pcb_pin_t *Pin); +void *ChangeViaOctagon(pcb_opctx_t *ctx, pcb_pin_t *Via); +void *SetViaOctagon(pcb_opctx_t *ctx, pcb_pin_t *Via); +void *ClrViaOctagon(pcb_opctx_t *ctx, pcb_pin_t *Via); +void *ChangePinOctagon(pcb_opctx_t *ctx, ElementTypePtr Element, pcb_pin_t *Pin); +void *SetPinOctagon(pcb_opctx_t *ctx, ElementTypePtr Element, pcb_pin_t *Pin); +void *ClrPinOctagon(pcb_opctx_t *ctx, ElementTypePtr Element, pcb_pin_t *Pin); +pcb_bool ChangeHole(pcb_pin_t *Via); +void *ChangePinMaskSize(pcb_opctx_t *ctx, ElementTypePtr Element, pcb_pin_t *Pin); +void *ChangeViaMaskSize(pcb_opctx_t *ctx, pcb_pin_t *Via); +void *CopyVia(pcb_opctx_t *ctx, pcb_pin_t *Via); +void *MoveVia(pcb_opctx_t *ctx, pcb_pin_t *Via); +void *DestroyVia(pcb_opctx_t *ctx, pcb_pin_t *Via); +void *RemoveVia(pcb_opctx_t *ctx, pcb_pin_t *Via); Index: trunk/src/obj_pinvia_therm.c =================================================================== --- trunk/src/obj_pinvia_therm.c (revision 4770) +++ trunk/src/obj_pinvia_therm.c (revision 4771) @@ -82,7 +82,7 @@ return ContourToPoly(c); } -static POLYAREA *square_therm(PinTypePtr pin, pcb_cardinal_t style) +static POLYAREA *square_therm(pcb_pin_t *pin, pcb_cardinal_t style) { POLYAREA *p, *p2; PLINE *c; @@ -309,7 +309,7 @@ } } -static POLYAREA *oct_therm(PinTypePtr pin, pcb_cardinal_t style) +static POLYAREA *oct_therm(pcb_pin_t *pin, pcb_cardinal_t style) { POLYAREA *p, *p2, *m; Coord t = 0.5 * pcb->ThermScale * pin->Clearance; @@ -353,7 +353,7 @@ * Usually this is 4 disjoint regions. * */ -POLYAREA *ThermPoly(pcb_board_t *p, PinTypePtr pin, pcb_cardinal_t laynum) +POLYAREA *ThermPoly(pcb_board_t *p, pcb_pin_t *pin, pcb_cardinal_t laynum) { pcb_arc_t a; POLYAREA *pa, *arc; Index: trunk/src/obj_pinvia_therm.h =================================================================== --- trunk/src/obj_pinvia_therm.h (revision 4770) +++ trunk/src/obj_pinvia_therm.h (revision 4771) @@ -39,6 +39,6 @@ #include #include "config.h" -POLYAREA *ThermPoly(pcb_board_t *, PinTypePtr, pcb_cardinal_t); +POLYAREA *ThermPoly(pcb_board_t *, pcb_pin_t *, pcb_cardinal_t); #endif Index: trunk/src/obj_poly.c =================================================================== --- trunk/src/obj_poly.c (revision 4770) +++ trunk/src/obj_poly.c (revision 4771) @@ -410,7 +410,7 @@ r_dir_t mptl_pin_callback(const pcb_box_t * b, void *cl) { struct mptlc *d = (struct mptlc *) cl; - PinTypePtr pin = (PinTypePtr) b; + pcb_pin_t *pin = (pcb_pin_t *) b; if (!TEST_THERM(d->snum, pin) || !IsPointInPolygon(pin->X, pin->Y, pin->Thickness + pin->Clearance + 2, d->polygon)) return R_DIR_NOT_FOUND; if (d->type == PCB_TYPE_PIN) Index: trunk/src/operation.h =================================================================== --- trunk/src/operation.h (revision 4770) +++ trunk/src/operation.h (revision 4771) @@ -113,10 +113,10 @@ void *(*Line)(pcb_opctx_t *ctx, pcb_layer_t *, pcb_line_t *); void *(*Text)(pcb_opctx_t *ctx, pcb_layer_t *, TextTypePtr); void *(*Polygon)(pcb_opctx_t *ctx, pcb_layer_t *, pcb_polygon_t *); - void *(*Via)(pcb_opctx_t *ctx, PinTypePtr); + void *(*Via)(pcb_opctx_t *ctx, pcb_pin_t *); void *(*Element)(pcb_opctx_t *ctx, ElementTypePtr); void *(*ElementName)(pcb_opctx_t *ctx, ElementTypePtr); - void *(*Pin)(pcb_opctx_t *ctx, ElementTypePtr, PinTypePtr); + void *(*Pin)(pcb_opctx_t *ctx, ElementTypePtr, pcb_pin_t *); void *(*Pad)(pcb_opctx_t *ctx, ElementTypePtr, pcb_pad_t *); void *(*LinePoint)(pcb_opctx_t *ctx, pcb_layer_t *, pcb_line_t *, pcb_point_t *); void *(*Point)(pcb_opctx_t *ctx, pcb_layer_t *, pcb_polygon_t *, pcb_point_t *); Index: trunk/src/polygon.c =================================================================== --- trunk/src/polygon.c (revision 4770) +++ trunk/src/polygon.c (revision 4771) @@ -733,7 +733,7 @@ } /* create a polygon of the pin clearance */ -POLYAREA *PinPoly(PinType * pin, Coord thick, Coord clear) +POLYAREA *PinPoly(pcb_pin_t * pin, Coord thick, Coord clear) { int size; @@ -763,7 +763,7 @@ } /* return the clearance polygon for a pin */ -static POLYAREA *pin_clearance_poly(pcb_cardinal_t layernum, pcb_board_t *pcb, PinType * pin) +static POLYAREA *pin_clearance_poly(pcb_cardinal_t layernum, pcb_board_t *pcb, pcb_pin_t * pin) { POLYAREA *np; if (TEST_THERM(layernum, pin)) @@ -774,7 +774,7 @@ } /* remove the pin clearance from the polygon */ -static int SubtractPin(pcb_data_t * d, PinType * pin, pcb_layer_t * l, pcb_polygon_t * p) +static int SubtractPin(pcb_data_t * d, pcb_pin_t * pin, pcb_layer_t * l, pcb_polygon_t * p) { POLYAREA *np; pcb_cardinal_t i; @@ -869,7 +869,7 @@ static r_dir_t pin_sub_callback(const pcb_box_t * b, void *cl) { - PinTypePtr pin = (PinTypePtr) b; + pcb_pin_t *pin = (pcb_pin_t *) b; struct cpInfo *info = (struct cpInfo *) cl; pcb_polygon_t *polygon; POLYAREA *np; @@ -1084,7 +1084,7 @@ return 0; } -static int UnsubtractPin(PinType * pin, pcb_layer_t * l, pcb_polygon_t * p) +static int UnsubtractPin(pcb_pin_t * pin, pcb_layer_t * l, pcb_polygon_t * p) { POLYAREA *np; @@ -1400,7 +1400,7 @@ switch (type) { case PCB_TYPE_PIN: case PCB_TYPE_VIA: - SubtractPin(Data, (PinTypePtr) ptr2, Layer, Polygon); + SubtractPin(Data, (pcb_pin_t *) ptr2, Layer, Polygon); Polygon->NoHolesValid = 0; return R_DIR_FOUND_CONTINUE; case PCB_TYPE_LINE: @@ -1428,7 +1428,7 @@ switch (type) { case PCB_TYPE_PIN: case PCB_TYPE_VIA: - UnsubtractPin((PinTypePtr) ptr2, Layer, Polygon); + UnsubtractPin((pcb_pin_t *) ptr2, Layer, Polygon); return R_DIR_FOUND_CONTINUE; case PCB_TYPE_LINE: UnsubtractLine((pcb_line_t *) ptr2, Layer, Polygon); @@ -1460,7 +1460,7 @@ PlowsPolygon(pcb_data_t * Data, int type, void *ptr1, void *ptr2, r_dir_t (*call_back) (pcb_data_t *data, pcb_layer_t *lay, pcb_polygon_t *poly, int type, void *ptr1, void *ptr2)) { - pcb_box_t sb = ((PinTypePtr) ptr2)->BoundingBox; + pcb_box_t sb = ((pcb_pin_t *) ptr2)->BoundingBox; int r = 0, seen; struct plow_info info; Index: trunk/src/polygon.h =================================================================== --- trunk/src/polygon.h (revision 4770) +++ trunk/src/polygon.h (revision 4771) @@ -72,7 +72,7 @@ POLYAREA *OctagonPoly(Coord x, Coord y, Coord radius, int style); POLYAREA *LinePoly(pcb_line_t * l, Coord thick); POLYAREA *ArcPoly(pcb_arc_t * l, Coord thick); -POLYAREA *PinPoly(PinType * l, Coord thick, Coord clear); +POLYAREA *PinPoly(pcb_pin_t * l, Coord thick, Coord clear); POLYAREA *BoxPolyBloated(pcb_box_t * box, Coord radius); void frac_circle(PLINE *, Coord, Coord, Vector, int); int InitClip(pcb_data_t * d, pcb_layer_t * l, pcb_polygon_t * p); Index: trunk/src/rats.c =================================================================== --- trunk/src/rats.c (revision 4770) +++ trunk/src/rats.c (revision 4771) @@ -110,7 +110,7 @@ ElementTypePtr element; gdl_iterator_t it; pcb_pad_t *pad; - PinType *pin; + pcb_pin_t *pin; if ((element = SearchElementByName(PCB->Data, ElementName)) == NULL) return pcb_false; @@ -232,12 +232,12 @@ ENTRY_LOOP(menu); { if (SeekPad(entry, &LastPoint, pcb_false)) { - if (TEST_FLAG(PCB_FLAG_DRC, (PinTypePtr) LastPoint.ptr2)) + if (TEST_FLAG(PCB_FLAG_DRC, (pcb_pin_t *) LastPoint.ptr2)) Message(PCB_MSG_DEFAULT, _ ("Error! Element %s pin %s appears multiple times in the netlist file.\n"), NAMEONPCB_NAME((ElementTypePtr) LastPoint.ptr1), (LastPoint.type == - PCB_TYPE_PIN) ? ((PinTypePtr) LastPoint.ptr2)->Number : ((pcb_pad_t *) LastPoint.ptr2)->Number); + PCB_TYPE_PIN) ? ((pcb_pin_t *) LastPoint.ptr2)->Number : ((pcb_pad_t *) LastPoint.ptr2)->Number); else { connection = GetConnectionMemory(net); *connection = LastPoint; @@ -244,9 +244,9 @@ /* indicate expect net */ connection->menu = menu; /* mark as visited */ - SET_FLAG(PCB_FLAG_DRC, (PinTypePtr) LastPoint.ptr2); + SET_FLAG(PCB_FLAG_DRC, (pcb_pin_t *) LastPoint.ptr2); if (LastPoint.type == PCB_TYPE_PIN) - ((PinTypePtr) LastPoint.ptr2)->Spare = (void *) menu; + ((pcb_pin_t *) LastPoint.ptr2)->Spare = (void *) menu; else ((pcb_pad_t *) LastPoint.ptr2)->Spare = (void *) menu; } @@ -260,9 +260,9 @@ /* indicate expect net */ connection->menu = menu; /* mark as visited */ - SET_FLAG(PCB_FLAG_DRC, (PinTypePtr) LastPoint.ptr2); + SET_FLAG(PCB_FLAG_DRC, (pcb_pin_t *) LastPoint.ptr2); if (LastPoint.type == PCB_TYPE_PIN) - ((PinTypePtr) LastPoint.ptr2)->Spare = (void *) menu; + ((pcb_pin_t *) LastPoint.ptr2)->Spare = (void *) menu; else ((pcb_pad_t *) LastPoint.ptr2)->Spare = (void *) menu; } @@ -406,12 +406,12 @@ RatFindHook(a->Connection[0].type, a->Connection[0].ptr1, a->Connection[0].ptr2, a->Connection[0].ptr2, pcb_false, AndRats); /* now anybody connected to the first point has PCB_FLAG_DRC set */ /* so move those to this subnet */ - CLEAR_FLAG(PCB_FLAG_DRC, (PinTypePtr) a->Connection[0].ptr2); + CLEAR_FLAG(PCB_FLAG_DRC, (pcb_pin_t *) a->Connection[0].ptr2); for (n = m + 1; n < Netl->NetN; n++) { b = &Netl->Net[n]; /* There can be only one connection in net b */ - if (TEST_FLAG(PCB_FLAG_DRC, (PinTypePtr) b->Connection[0].ptr2)) { - CLEAR_FLAG(PCB_FLAG_DRC, (PinTypePtr) b->Connection[0].ptr2); + if (TEST_FLAG(PCB_FLAG_DRC, (pcb_pin_t *) b->Connection[0].ptr2)) { + CLEAR_FLAG(PCB_FLAG_DRC, (pcb_pin_t *) b->Connection[0].ptr2); TransferNet(Netl, b, a); /* back up since new subnet is now at old index */ n--; @@ -683,7 +683,7 @@ { CONNECTION_LOOP(net); { - if (!SelectedOnly || TEST_FLAG(PCB_FLAG_SELECTED, (PinTypePtr) connection->ptr2)) { + if (!SelectedOnly || TEST_FLAG(PCB_FLAG_SELECTED, (pcb_pin_t *) connection->ptr2)) { lonesome = GetNetMemory(Nets); onepin = GetConnectionMemory(lonesome); *onepin = *connection; @@ -768,7 +768,7 @@ Nets = GetNetListMemory(&result); CONNECTION_LOOP(net); { - if (!SelectedOnly || TEST_FLAG(PCB_FLAG_SELECTED, (PinTypePtr) connection->ptr2)) { + if (!SelectedOnly || TEST_FLAG(PCB_FLAG_SELECTED, (pcb_pin_t *) connection->ptr2)) { lonesome = GetNetMemory(Nets); onepin = GetConnectionMemory(lonesome); *onepin = *connection; @@ -911,7 +911,7 @@ switch (type) { case PCB_TYPE_PIN: - num = ((PinTypePtr) ptr2)->Number; + num = ((pcb_pin_t *) ptr2)->Number; break; case PCB_TYPE_PAD: num = ((pcb_pad_t *) ptr2)->Number; Index: trunk/src/rubberband.c =================================================================== --- trunk/src/rubberband.c (revision 4770) +++ trunk/src/rubberband.c (revision 4771) @@ -43,7 +43,7 @@ * some local prototypes */ static void CheckPadForRubberbandConnection(pcb_pad_t *); -static void CheckPinForRubberbandConnection(PinTypePtr); +static void CheckPinForRubberbandConnection(pcb_pin_t *); static void CheckLinePointForRubberbandConnection(pcb_layer_t *, pcb_line_t *, pcb_point_t *, pcb_bool); static void CheckPolygonForRubberbandConnection(pcb_layer_t *, pcb_polygon_t *); static void CheckLinePointForRat(pcb_layer_t *, pcb_point_t *); @@ -205,7 +205,7 @@ struct rinfo { int type; pcb_cardinal_t group; - PinTypePtr pin; + pcb_pin_t *pin; pcb_pad_t *pad; pcb_point_t *point; }; @@ -265,7 +265,7 @@ r_search(PCB->Data->rat_tree, &Pad->BoundingBox, NULL, rat_callback, &info, NULL); } -static void CheckPinForRat(PinTypePtr Pin) +static void CheckPinForRat(pcb_pin_t *Pin) { struct rinfo info; @@ -292,7 +292,7 @@ * and readability is more important then the few % * of failures that are immediately recognized */ -static void CheckPinForRubberbandConnection(PinTypePtr Pin) +static void CheckPinForRubberbandConnection(pcb_pin_t *Pin) { struct rubber_info info; pcb_cardinal_t n; @@ -438,7 +438,7 @@ break; case PCB_TYPE_VIA: - CheckPinForRubberbandConnection((PinTypePtr) Ptr1); + CheckPinForRubberbandConnection((pcb_pin_t *) Ptr1); break; case PCB_TYPE_POLYGON: @@ -483,7 +483,7 @@ break; case PCB_TYPE_VIA: - CheckPinForRat((PinTypePtr) Ptr1); + CheckPinForRat((pcb_pin_t *) Ptr1); break; } } Index: trunk/src/search.c =================================================================== --- trunk/src/search.c (revision 4770) +++ trunk/src/search.c (revision 4771) @@ -58,9 +58,9 @@ static pcb_bool SearchRatLineByLocation(int, pcb_rat_t **, pcb_rat_t **, pcb_rat_t **); static pcb_bool SearchTextByLocation(int, pcb_layer_t **, TextTypePtr *, TextTypePtr *); static pcb_bool SearchPolygonByLocation(int, pcb_layer_t **, pcb_polygon_t **, pcb_polygon_t **); -static pcb_bool SearchPinByLocation(int, ElementTypePtr *, PinTypePtr *, PinTypePtr *); +static pcb_bool SearchPinByLocation(int, ElementTypePtr *, pcb_pin_t **, pcb_pin_t **); static pcb_bool SearchPadByLocation(int, ElementTypePtr *, pcb_pad_t **, pcb_pad_t **, pcb_bool); -static pcb_bool SearchViaByLocation(int, PinTypePtr *, PinTypePtr *, PinTypePtr *); +static pcb_bool SearchViaByLocation(int, pcb_pin_t **, pcb_pin_t **, pcb_pin_t **); static pcb_bool SearchElementNameByLocation(int, ElementTypePtr *, TextTypePtr *, TextTypePtr *, pcb_bool); static pcb_bool SearchLinePointByLocation(int, pcb_layer_t **, pcb_line_t **, pcb_point_t **); static pcb_bool SearchPointByLocation(int, pcb_layer_t **, pcb_polygon_t **, pcb_point_t **); @@ -79,7 +79,7 @@ static r_dir_t pinorvia_callback(const pcb_box_t * box, void *cl) { struct ans_info *i = (struct ans_info *) cl; - PinTypePtr pin = (PinTypePtr) box; + pcb_pin_t *pin = (pcb_pin_t *) box; AnyObjectType *ptr1 = pin->Element ? pin->Element : pin; if (TEST_FLAG(i->locked, ptr1)) @@ -92,7 +92,7 @@ return R_DIR_CANCEL; /* found, stop searching */ } -static pcb_bool SearchViaByLocation(int locked, PinTypePtr * Via, PinTypePtr * Dummy1, PinTypePtr * Dummy2) +static pcb_bool SearchViaByLocation(int locked, pcb_pin_t ** Via, pcb_pin_t ** Dummy1, pcb_pin_t ** Dummy2) { struct ans_info info; @@ -114,7 +114,7 @@ * searches a pin * starts with the newest element */ -static pcb_bool SearchPinByLocation(int locked, ElementTypePtr * Element, PinTypePtr * Pin, PinTypePtr * Dummy) +static pcb_bool SearchPinByLocation(int locked, ElementTypePtr * Element, pcb_pin_t ** Pin, pcb_pin_t ** Dummy) { struct ans_info info; @@ -522,7 +522,7 @@ /* --------------------------------------------------------------------------- * checks if a point is on a pin */ -pcb_bool IsPointOnPin(Coord X, Coord Y, Coord Radius, PinTypePtr pin) +pcb_bool IsPointOnPin(Coord X, Coord Y, Coord Radius, pcb_pin_t *pin) { Coord t = PIN_SIZE(pin) / 2; if (TEST_FLAG(PCB_FLAG_SQUARE, pin)) { @@ -1000,10 +1000,10 @@ SearchRatLineByLocation(locked, (pcb_rat_t **) Result1, (pcb_rat_t **) Result2, (pcb_rat_t **) Result3)) return (PCB_TYPE_RATLINE); - if (Type & PCB_TYPE_VIA && SearchViaByLocation(locked, (PinTypePtr *) Result1, (PinTypePtr *) Result2, (PinTypePtr *) Result3)) + if (Type & PCB_TYPE_VIA && SearchViaByLocation(locked, (pcb_pin_t **) Result1, (pcb_pin_t **) Result2, (pcb_pin_t **) Result3)) return (PCB_TYPE_VIA); - if (Type & PCB_TYPE_PIN && SearchPinByLocation(locked, (ElementTypePtr *) pr1, (PinTypePtr *) pr2, (PinTypePtr *) pr3)) + if (Type & PCB_TYPE_PIN && SearchPinByLocation(locked, (ElementTypePtr *) pr1, (pcb_pin_t **) pr2, (pcb_pin_t **) pr3)) HigherAvail = PCB_TYPE_PIN; if (!HigherAvail && Type & PCB_TYPE_PAD && Index: trunk/src/search.h =================================================================== --- trunk/src/search.h (revision 4770) +++ trunk/src/search.h (revision 4771) @@ -146,7 +146,7 @@ * prototypes */ pcb_bool IsPointOnLine(Coord, Coord, Coord, pcb_line_t *); -pcb_bool IsPointOnPin(Coord, Coord, Coord, PinTypePtr); +pcb_bool IsPointOnPin(Coord, Coord, Coord, pcb_pin_t *); pcb_bool IsPointOnArc(Coord, Coord, Coord, pcb_arc_t *); pcb_bool IsPointOnLineEnd(Coord, Coord, pcb_rat_t *); pcb_bool IsLineInRectangle(Coord, Coord, Coord, Coord, pcb_line_t *); Index: trunk/src/select.c =================================================================== --- trunk/src/select.c (revision 4770) +++ trunk/src/select.c (revision 4771) @@ -116,13 +116,13 @@ pcb_bool changed = pcb_true; type = SearchScreen(Crosshair.X, Crosshair.Y, SELECT_TYPES, &ptr1, &ptr2, &ptr3); - if (type == PCB_TYPE_NONE || TEST_FLAG(PCB_FLAG_LOCK, (PinTypePtr) ptr2)) + if (type == PCB_TYPE_NONE || TEST_FLAG(PCB_FLAG_LOCK, (pcb_pin_t *) ptr2)) return (pcb_false); switch (type) { case PCB_TYPE_VIA: AddObjectToFlagUndoList(PCB_TYPE_VIA, ptr1, ptr1, ptr1); - TOGGLE_FLAG(PCB_FLAG_SELECTED, (PinTypePtr) ptr1); - DrawVia((PinTypePtr) ptr1); + TOGGLE_FLAG(PCB_FLAG_SELECTED, (pcb_pin_t *) ptr1); + DrawVia((pcb_pin_t *) ptr1); break; case PCB_TYPE_LINE: @@ -182,8 +182,8 @@ case PCB_TYPE_PIN: AddObjectToFlagUndoList(PCB_TYPE_PIN, ptr1, ptr2, ptr2); - TOGGLE_FLAG(PCB_FLAG_SELECTED, (PinTypePtr) ptr2); - DrawPin((PinTypePtr) ptr2); + TOGGLE_FLAG(PCB_FLAG_SELECTED, (pcb_pin_t *) ptr2); + DrawPin((pcb_pin_t *) ptr2); break; case PCB_TYPE_PAD: @@ -519,7 +519,7 @@ case PCB_TYPE_VIA: if (F->Via) - return (F->Via(ctx, (PinTypePtr) Ptr1)); + return (F->Via(ctx, (pcb_pin_t *) Ptr1)); break; case PCB_TYPE_ELEMENT: @@ -529,7 +529,7 @@ case PCB_TYPE_PIN: if (F->Pin) - return (F->Pin(ctx, (ElementTypePtr) Ptr1, (PinTypePtr) Ptr2)); + return (F->Pin(ctx, (ElementTypePtr) Ptr1, (pcb_pin_t *) Ptr2)); break; case PCB_TYPE_PAD: Index: trunk/src/stub_mincut.c =================================================================== --- trunk/src/stub_mincut.c (revision 4770) +++ trunk/src/stub_mincut.c (revision 4771) @@ -30,7 +30,7 @@ { } -static void stub_rat_found_short_dummy(PinType * pin, pcb_pad_t * pad, const char *with_net) +static void stub_rat_found_short_dummy(pcb_pin_t * pin, pcb_pad_t * pad, const char *with_net) { /* original behavior: just warn at random pins/pads */ if (pin != NULL) @@ -41,5 +41,5 @@ stub_rat_proc_shorts_dummy(); } -void (*stub_rat_found_short)(PinType * pin, pcb_pad_t * pad, const char *with_net) = stub_rat_found_short_dummy; +void (*stub_rat_found_short)(pcb_pin_t * pin, pcb_pad_t * pad, const char *with_net) = stub_rat_found_short_dummy; void (*stub_rat_proc_shorts)(void) = stub_rat_proc_shorts_dummy; Index: trunk/src/stub_mincut.h =================================================================== --- trunk/src/stub_mincut.h (revision 4770) +++ trunk/src/stub_mincut.h (revision 4771) @@ -22,6 +22,6 @@ #include "global_typedefs.h" -extern void (*stub_rat_found_short)(PinType * pin, pcb_pad_t * pad, const char *with_net); +extern void (*stub_rat_found_short)(pcb_pin_t * pin, pcb_pad_t * pad, const char *with_net); extern void (*stub_rat_proc_shorts)(void); Index: trunk/src/undo.c =================================================================== --- trunk/src/undo.c (revision 4770) +++ trunk/src/undo.c (revision 4771) @@ -344,10 +344,10 @@ /* lookup entry by ID */ type = SearchObjectByID(PCB->Data, &ptr1, &ptr2, &ptr3, Entry->ID, Entry->Kind); if (type != PCB_TYPE_NONE) { - swap = ((PinTypePtr) ptr2)->DrillingHole; + swap = ((pcb_pin_t *) ptr2)->DrillingHole; if (andDraw) EraseObject(type, ptr1, ptr2); - ((PinTypePtr) ptr2)->DrillingHole = Entry->Data.Size; + ((pcb_pin_t *) ptr2)->DrillingHole = Entry->Data.Size; Entry->Data.Size = swap; DrawObject(type, ptr1, ptr2); return (pcb_true); @@ -429,11 +429,11 @@ /* lookup entry by ID */ type = SearchObjectByID(PCB->Data, &ptr1, &ptr2, &ptr3, Entry->ID, Entry->Kind); if (type != PCB_TYPE_NONE) { - swap = ((PinTypePtr) ptr2)->Clearance; + swap = ((pcb_pin_t *) ptr2)->Clearance; RestoreToPolygon(PCB->Data, type, ptr1, ptr2); if (andDraw) EraseObject(type, ptr1, ptr2); - ((PinTypePtr) ptr2)->Clearance = Entry->Data.Size; + ((pcb_pin_t *) ptr2)->Clearance = Entry->Data.Size; ClearFromPolygon(PCB->Data, type, ptr1, ptr2); Entry->Data.Size = swap; if (andDraw) @@ -455,13 +455,13 @@ /* lookup entry by ID */ type = SearchObjectByID(PCB->Data, &ptr1, &ptr2, &ptr3, Entry->ID, Entry->Kind); if (type & (PCB_TYPE_VIA | PCB_TYPE_PIN | PCB_TYPE_PAD)) { - swap = (type == PCB_TYPE_PAD ? ((pcb_pad_t *) ptr2)->Mask : ((PinTypePtr) ptr2)->Mask); + swap = (type == PCB_TYPE_PAD ? ((pcb_pad_t *) ptr2)->Mask : ((pcb_pin_t *) ptr2)->Mask); if (andDraw) EraseObject(type, ptr1, ptr2); if (type == PCB_TYPE_PAD) ((pcb_pad_t *) ptr2)->Mask = Entry->Data.Size; else - ((PinTypePtr) ptr2)->Mask = Entry->Data.Size; + ((pcb_pin_t *) ptr2)->Mask = Entry->Data.Size; Entry->Data.Size = swap; if (andDraw) DrawObject(type, ptr1, ptr2); @@ -490,11 +490,11 @@ if (type != PCB_TYPE_NONE) { /* Wow! can any object be treated as a pin type for size change?? */ /* pins, vias, lines, and arcs can. Text can't but it has it's own mechanism */ - swap = ((PinTypePtr) ptr2)->Thickness; + swap = ((pcb_pin_t *) ptr2)->Thickness; RestoreToPolygon(PCB->Data, type, ptr1, ptr2); if ((andDraw) && (ptr1e != NULL)) EraseObject(type, ptr1e, ptr2); - ((PinTypePtr) ptr2)->Thickness = Entry->Data.Size; + ((pcb_pin_t *) ptr2)->Thickness = Entry->Data.Size; Entry->Data.Size = swap; ClearFromPolygon(PCB->Data, type, ptr1, ptr2); if (andDraw) @@ -518,7 +518,7 @@ type = SearchObjectByID(PCB->Data, &ptr1, &ptr2, &ptr3, Entry->ID, Entry->Kind); if (type != PCB_TYPE_NONE) { FlagType f1, f2; - PinTypePtr pin = (PinTypePtr) ptr2; + pcb_pin_t *pin = (pcb_pin_t *) ptr2; if ((type == PCB_TYPE_ELEMENT) || (type == PCB_TYPE_ELEMENT_NAME)) ptr1e = NULL; @@ -1389,7 +1389,7 @@ if (!Locked) { undo = GetUndoSlot(UNDO_FLAG, OBJECT_ID(Ptr2), Type); - undo->Data.Flags = ((PinTypePtr) Ptr2)->Flags; + undo->Data.Flags = ((pcb_pin_t *) Ptr2)->Flags; } } @@ -1405,7 +1405,7 @@ switch (Type) { case PCB_TYPE_PIN: case PCB_TYPE_VIA: - undo->Data.Size = ((PinTypePtr) ptr2)->Thickness; + undo->Data.Size = ((pcb_pin_t *) ptr2)->Thickness; break; case PCB_TYPE_LINE: case PCB_TYPE_ELEMENT_LINE: @@ -1438,7 +1438,7 @@ switch (Type) { case PCB_TYPE_PIN: case PCB_TYPE_VIA: - undo->Data.Size = ((PinTypePtr) ptr2)->Clearance; + undo->Data.Size = ((pcb_pin_t *) ptr2)->Clearance; break; case PCB_TYPE_LINE: undo->Data.Size = ((pcb_line_t *) ptr2)->Clearance; @@ -1465,7 +1465,7 @@ switch (Type) { case PCB_TYPE_PIN: case PCB_TYPE_VIA: - undo->Data.Size = ((PinTypePtr) ptr2)->Mask; + undo->Data.Size = ((pcb_pin_t *) ptr2)->Mask; break; case PCB_TYPE_PAD: undo->Data.Size = ((pcb_pad_t *) ptr2)->Mask; @@ -1484,7 +1484,7 @@ if (!Locked) { undo = GetUndoSlot(UNDO_CHANGE2NDSIZE, OBJECT_ID(ptr2), Type); if (Type == PCB_TYPE_PIN || Type == PCB_TYPE_VIA) - undo->Data.Size = ((PinTypePtr) ptr2)->DrillingHole; + undo->Data.Size = ((pcb_pin_t *) ptr2)->DrillingHole; } } Index: trunk/src_plugins/autocrop/autocrop.c =================================================================== --- trunk/src_plugins/autocrop/autocrop.c (revision 4770) +++ trunk/src_plugins/autocrop/autocrop.c (revision 4771) @@ -61,7 +61,7 @@ #include "box.h" #include "hid_actions.h" -static void *MyMoveViaLowLevel(pcb_data_t * Data, PinType * Via, Coord dx, Coord dy) +static void *MyMoveViaLowLevel(pcb_data_t * Data, pcb_pin_t * Via, Coord dx, Coord dy) { if (Data) { RestoreToPolygon(Data, PCB_TYPE_VIA, Via, Via); Index: trunk/src_plugins/autoplace/autoplace.c =================================================================== --- trunk/src_plugins/autoplace/autoplace.c (revision 4770) +++ trunk/src_plugins/autoplace/autoplace.c (revision 4771) @@ -160,8 +160,8 @@ break; case PCB_TYPE_PIN: c->group = SLayer; /* any layer will do */ - c->X = ((PinTypePtr) c->ptr2)->X; - c->Y = ((PinTypePtr) c->ptr2)->Y; + c->X = ((pcb_pin_t *) c->ptr2)->X; + c->Y = ((pcb_pin_t *) c->ptr2)->Y; break; default: Message(PCB_MSG_DEFAULT, "Odd connection type encountered in " "UpdateXY"); Index: trunk/src_plugins/autoroute/autoroute.c =================================================================== --- trunk/src_plugins/autoroute/autoroute.c (revision 4770) +++ trunk/src_plugins/autoroute/autoroute.c (revision 4771) @@ -223,10 +223,10 @@ pcb_box_t box, sbox; union { pcb_pad_t *pad; - PinTypePtr pin; - PinTypePtr via; + pcb_pin_t *pin; + pcb_pin_t *via; struct routebox *via_shadow; /* points to the via in r-tree which - * points to the PinType in the PCB. */ + * points to the pcb_pin_t in the PCB. */ pcb_line_t *line; void *generic; /* 'other' is polygon, arc, text */ struct routebox *expansion_area; /* previous expansion area in search */ @@ -292,7 +292,7 @@ /* circular lists with connectivity information. */ routebox_list same_net, same_subnet, original_subnet, different_net; union { - PinType *via; + pcb_pin_t *via; pcb_line_t *line; } livedraw_obj; } routebox_t; @@ -584,7 +584,7 @@ * routedata initialization functions. */ -static routebox_t *AddPin(PointerListType layergroupboxes[], PinTypePtr pin, pcb_bool is_via, RouteStyleType * style) +static routebox_t *AddPin(PointerListType layergroupboxes[], pcb_pin_t *pin, pcb_bool is_via, RouteStyleType * style) { routebox_t **rbpp, *lastrb = NULL; int i, ht; @@ -953,7 +953,7 @@ CONNECTION_LOOP(net); { routebox_t *rb = NULL; - SET_FLAG(PCB_FLAG_DRC, (PinTypePtr) connection->ptr2); + SET_FLAG(PCB_FLAG_DRC, (pcb_pin_t *) connection->ptr2); if (connection->type == PCB_TYPE_LINE) { pcb_line_t *line = (pcb_line_t *) connection->ptr2; @@ -998,10 +998,10 @@ rb = AddPad(layergroupboxes, (ElementType *) connection->ptr1, (pcb_pad_t *) connection->ptr2, rd->styles[j]); break; case PCB_TYPE_PIN: - rb = AddPin(layergroupboxes, (PinType *) connection->ptr2, pcb_false, rd->styles[j]); + rb = AddPin(layergroupboxes, (pcb_pin_t *) connection->ptr2, pcb_false, rd->styles[j]); break; case PCB_TYPE_VIA: - rb = AddPin(layergroupboxes, (PinType *) connection->ptr2, pcb_true, rd->styles[j]); + rb = AddPin(layergroupboxes, (pcb_pin_t *) connection->ptr2, pcb_true, rd->styles[j]); break; case PCB_TYPE_POLYGON: rb = @@ -2855,7 +2855,7 @@ routebox_t *rb, *first_via = NULL; int i; int ka = AutoRouteParameters.style->Clearance; - PinType *live_via = NULL; + pcb_pin_t *live_via = NULL; if (conf_core.editor.live_routing) { live_via = CreateNewVia(PCB->Data, X, Y, radius * 2, @@ -4386,7 +4386,7 @@ } struct fpin_info { - PinTypePtr pin; + pcb_pin_t *pin; Coord X, Y; jmp_buf env; }; @@ -4393,16 +4393,16 @@ static r_dir_t fpin_rect(const pcb_box_t * b, void *cl) { - PinTypePtr pin = (PinTypePtr) b; + pcb_pin_t *pin = (pcb_pin_t *) b; struct fpin_info *info = (struct fpin_info *) cl; if (pin->X == info->X && pin->Y == info->Y) { - info->pin = (PinTypePtr) b; + info->pin = (pcb_pin_t *) b; longjmp(info->env, 1); } return R_DIR_NOT_FOUND; } -static int FindPin(const pcb_box_t * box, PinTypePtr * pin) +static int FindPin(const pcb_box_t * box, pcb_pin_t ** pin) { struct fpin_info info; @@ -4515,7 +4515,7 @@ LIST_LOOP(net, same_net, p); { if (p->type == THERMAL) { - PinTypePtr pin = NULL; + pcb_pin_t *pin = NULL; /* thermals are alread a single point search, no need to shrink */ int type = FindPin(&p->box, &pin); if (pin) { Index: trunk/src_plugins/djopt/djopt.c =================================================================== --- trunk/src_plugins/djopt/djopt.c (revision 4770) +++ trunk/src_plugins/djopt/djopt.c (revision 4771) @@ -86,9 +86,9 @@ struct corner_s *next; int x, y; int net; - PinType *via; + pcb_pin_t *via; pcb_pad_t *pad; - PinType *pin; + pcb_pin_t *pin; int miter; int n_lines; struct line_s **lines; @@ -737,7 +737,7 @@ static void move_corner(corner_s * c, int x, int y) { - PinType *via; + pcb_pin_t *via; int i; corner_s *pad; @@ -2237,7 +2237,7 @@ corner_s *best_c[MAX_LAYER + 1]; int l, got_one; int left = 0, right = 0, top = 0, bottom = 0; - PinType *pin; + pcb_pin_t *pin; int again = 1; int close = 0; Index: trunk/src_plugins/gpmi/pcb-gpmi/gpmi_plugin/gpmi_pkg/hid/hid_callbacks.c =================================================================== --- trunk/src_plugins/gpmi/pcb-gpmi/gpmi_plugin/gpmi_pkg/hid/hid_callbacks.c (revision 4770) +++ trunk/src_plugins/gpmi/pcb-gpmi/gpmi_plugin/gpmi_pkg/hid/hid_callbacks.c (revision 4771) @@ -168,7 +168,7 @@ gpmi_event(h->module, HIDE_use_mask, h, use_it); } -void gpmi_hid_fill_pcb_pv(hidGC fg_gc, hidGC bg_gc, PinType *pad, pcb_bool drawHole, pcb_bool mask) +void gpmi_hid_fill_pcb_pv(hidGC fg_gc, hidGC bg_gc, pcb_pin_t *pad, pcb_bool drawHole, pcb_bool mask) { hid_t *h = hid_gpmi_data_get(exporter); gpmi_event(h->module, HIDE_fill_pcb_pv, h, fg_gc, bg_gc, pad, drawHole, mask); Index: trunk/src_plugins/gpmi/pcb-gpmi/gpmi_plugin/gpmi_pkg/hid/hid_callbacks.h =================================================================== --- trunk/src_plugins/gpmi/pcb-gpmi/gpmi_plugin/gpmi_pkg/hid/hid_callbacks.h (revision 4770) +++ trunk/src_plugins/gpmi/pcb-gpmi/gpmi_plugin/gpmi_pkg/hid/hid_callbacks.h (revision 4771) @@ -17,6 +17,6 @@ void gpmi_hid_fill_polygon(hidGC gc, int n_coords, Coord *x, Coord *y); void gpmi_hid_fill_pcb_polygon(hidGC gc, pcb_polygon_t *poly, const pcb_box_t *clip_box); void gpmi_hid_fill_rect(hidGC gc, Coord x1, Coord y1, Coord x2, Coord y2); -void gpmi_hid_fill_pcb_pv(hidGC fg_gc, hidGC bg_gc, PinType *pad, pcb_bool drawHole, pcb_bool mask); +void gpmi_hid_fill_pcb_pv(hidGC fg_gc, hidGC bg_gc, pcb_pin_t *pad, pcb_bool drawHole, pcb_bool mask); void gpmi_hid_fill_pcb_pad(hidGC gc, pcb_pad_t * pad, pcb_bool clear, pcb_bool mask); void gpmi_hid_use_mask(int use_it); Index: trunk/src_plugins/gpmi/pcb-gpmi/gpmi_plugin/gpmi_pkg/layout/layout.h =================================================================== --- trunk/src_plugins/gpmi/pcb-gpmi/gpmi_plugin/gpmi_pkg/layout/layout.h (revision 4770) +++ trunk/src_plugins/gpmi/pcb-gpmi/gpmi_plugin/gpmi_pkg/layout/layout.h (revision 4771) @@ -85,8 +85,8 @@ TextType *t; pcb_polygon_t *p; pcb_arc_t *a; - PinType *v; - PinType *pin; + pcb_pin_t *v; + pcb_pin_t *pin; } obj; int layer; } layout_object_t; @@ -261,7 +261,7 @@ void thindraw_pcb_polygon(dctx_t *ctx, pcb_polygon_t *poly, const pcb_box_t *clip_box); void fill_pcb_pad(dctx_t *ctx, pcb_pad_t *pad, pcb_bool clip, pcb_bool mask); void thindraw_pcb_pad(dctx_t *ctx, pcb_pad_t *pad, pcb_bool clip, pcb_bool mask); -void fill_pcb_pv(hidGC fg_gc, hidGC bg_gc, PinType *pv, pcb_bool drawHole, pcb_bool mask); -void thindraw_pcb_pv(hidGC fg_gc, hidGC bg_gc, PinType *pv, pcb_bool drawHole, pcb_bool mask); +void fill_pcb_pv(hidGC fg_gc, hidGC bg_gc, pcb_pin_t *pv, pcb_bool drawHole, pcb_bool mask); +void thindraw_pcb_pv(hidGC fg_gc, hidGC bg_gc, pcb_pin_t *pv, pcb_bool drawHole, pcb_bool mask); void fill_rect(dctx_t *ctx, int x1_, int y1_, int x2_, int y2_); */ Index: trunk/src_plugins/hid_gtk/gui-netlist-window.c =================================================================== --- trunk/src_plugins/hid_gtk/gui-netlist-window.c (revision 4770) +++ trunk/src_plugins/hid_gtk/gui-netlist-window.c (revision 4771) @@ -267,7 +267,7 @@ switch (conn.type) { case PCB_TYPE_PIN: { - PinTypePtr pin = (PinTypePtr) conn.ptr2; + pcb_pin_t *pin = (pcb_pin_t *) conn.ptr2; x = pin->X; y = pin->Y; gui->set_crosshair(x, y, 0); Index: trunk/src_plugins/io_kicad/write.c =================================================================== --- trunk/src_plugins/io_kicad/write.c (revision 4770) +++ trunk/src_plugins/io_kicad/write.c (revision 4771) @@ -505,7 +505,7 @@ int write_kicad_layout_vias(FILE * FP, pcb_data_t *Data, Coord xOffset, Coord yOffset, pcb_cardinal_t indentation) { gdl_iterator_t it; - PinType *via; + pcb_pin_t *via; /* write information about vias */ pinlist_foreach(&Data->Via, &it, via) { fprintf(FP, "%*s", indentation,""); @@ -817,7 +817,7 @@ elementlist_foreach(&Data->Element, &eit, element) { gdl_iterator_t it; - PinType *pin; + pcb_pin_t *pin; pcb_pad_t *pad; elementlist_dedup_skip(ededup, element); /* skip duplicate elements */ @@ -1060,7 +1060,7 @@ elementlist_foreach(&Data->Element, &eit, element) { gdl_iterator_t it; - PinType *pin; + pcb_pin_t *pin; pcb_pad_t *pad; /* elementlist_dedup_skip(ededup, element); */ Index: trunk/src_plugins/io_kicad_legacy/write.c =================================================================== --- trunk/src_plugins/io_kicad_legacy/write.c (revision 4770) +++ trunk/src_plugins/io_kicad_legacy/write.c (revision 4771) @@ -508,7 +508,7 @@ int write_kicad_legacy_layout_vias(FILE * FP, pcb_data_t *Data, Coord xOffset, Coord yOffset) { gdl_iterator_t it; - PinType *via; + pcb_pin_t *via; /* write information about vias */ pinlist_foreach(&Data->Via, &it, via) { /* pcb_fprintf(FP, "Po 3 %.3mm %.3mm %.3mm %.3mm %.3mm\n", @@ -777,7 +777,7 @@ elementlist_foreach(&Data->Element, &eit, element) { gdl_iterator_t it; - PinType *pin; + pcb_pin_t *pin; pcb_pad_t *pad; elementlist_dedup_skip(ededup, element); /* skip duplicate elements */ @@ -1012,7 +1012,7 @@ elementlist_foreach(&Data->Element, &eit, element) { gdl_iterator_t it; - PinType *pin; + pcb_pin_t *pin; pcb_pad_t *pad; /* elementlist_dedup_skip(ededup, element); */ Index: trunk/src_plugins/io_lihata/read.c =================================================================== --- trunk/src_plugins/io_lihata/read.c (revision 4770) +++ trunk/src_plugins/io_lihata/read.c (revision 4771) @@ -582,7 +582,7 @@ /* If el == NULL and dt != NULL it is a via (for now). */ static int parse_pin(pcb_data_t *dt, ElementType *el, lht_node_t *obj, Coord dx, Coord dy) { - PinType *via; + pcb_pin_t *via; if (dt != NULL) via = GetViaMemory(dt); Index: trunk/src_plugins/io_lihata/write.c =================================================================== --- trunk/src_plugins/io_lihata/write.c (revision 4770) +++ trunk/src_plugins/io_lihata/write.c (revision 4771) @@ -273,7 +273,7 @@ return obj; } -static lht_node_t *build_pin(PinType *pin, int is_via, Coord dx, Coord dy) +static lht_node_t *build_pin(pcb_pin_t *pin, int is_via, Coord dx, Coord dy) { char buff[128]; lht_node_t *obj; @@ -380,7 +380,7 @@ char buff[128]; pcb_line_t *li; pcb_arc_t *ar; - PinType *pi; + pcb_pin_t *pi; pcb_pad_t *pa; lht_node_t *obj, *lst; @@ -484,7 +484,7 @@ static lht_node_t *build_data(pcb_data_t *data) { lht_node_t *grp, *ndt; - PinType *pi; + pcb_pin_t *pi; ElementType *el; gdl_iterator_t it; pcb_rat_t *line; Index: trunk/src_plugins/io_pcb/file.c =================================================================== --- trunk/src_plugins/io_pcb/file.c (revision 4770) +++ trunk/src_plugins/io_pcb/file.c (revision 4771) @@ -295,7 +295,7 @@ static void WriteViaData(FILE * FP, pcb_data_t *Data) { gdl_iterator_t it; - PinType *via; + pcb_pin_t *via; /* write information about vias */ pinlist_foreach(&Data->Via, &it, via) { @@ -376,7 +376,7 @@ pcb_printf_slot[0] = ((io_pcb_ctx_t *)(ctx->plugin_data))->write_coord_fmt; elementlist_foreach(&Data->Element, &eit, element) { gdl_iterator_t it; - PinType *pin; + pcb_pin_t *pin; pcb_pad_t *pad; /* only non empty elements */ Index: trunk/src_plugins/loghid/hid-logger.c =================================================================== --- trunk/src_plugins/loghid/hid-logger.c (revision 4770) +++ trunk/src_plugins/loghid/hid-logger.c (revision 4771) @@ -156,13 +156,13 @@ delegatee_->thindraw_pcb_pad(gc, pad, clip, mask); } -static void log_fill_pcb_pv(hidGC fg, hidGC bg, PinType *pv, pcb_bool drawHole, pcb_bool mask) { +static void log_fill_pcb_pv(hidGC fg, hidGC bg, pcb_pin_t *pv, pcb_bool drawHole, pcb_bool mask) { pcb_fprintf(out_, "fill_pcb_pv(fg, bg, (%mm, %mm), draw_hole=%s, mask=%s)\n", pv->X, pv->Y, drawHole ? "true" : "false", mask ? "true" : "false"); delegatee_->fill_pcb_pv(fg, bg, pv, drawHole, mask); } -static void log_thindraw_pcb_pv(hidGC fg, hidGC bg, PinType *pv, pcb_bool drawHole, pcb_bool mask) { +static void log_thindraw_pcb_pv(hidGC fg, hidGC bg, pcb_pin_t *pv, pcb_bool drawHole, pcb_bool mask) { pcb_fprintf(out_, "thindraw_pcb_pv(fg, bg, (%mm, %mm), draw_hole=%s, mask=%s)\n", pv->X, pv->Y, drawHole ? "true" : "false", mask ? "true" : "false"); delegatee_->thindraw_pcb_pv(fg, bg, pv, drawHole, mask); Index: trunk/src_plugins/mincut/rats_mincut.c =================================================================== --- trunk/src_plugins/mincut/rats_mincut.c (revision 4770) +++ trunk/src_plugins/mincut/rats_mincut.c (revision 4771) @@ -97,7 +97,7 @@ } /* returns 0 on succes */ -static int proc_short(PinType * pin, pcb_pad_t * pad, int ignore) +static int proc_short(pcb_pin_t * pin, pcb_pad_t * pad, int ignore) { find_callback_t old_cb; Coord x, y; @@ -172,11 +172,11 @@ switch (n->to_type) { case PCB_TYPE_PIN: typ = "pin"; - parent = ((PinType *) (n->to))->Element; + parent = ((pcb_pin_t *) (n->to))->Element; break; case PCB_TYPE_VIA: typ = "via"; - parent = ((PinType *) (n->to))->Element; + parent = ((pcb_pin_t *) (n->to))->Element; break; case PCB_TYPE_PAD: typ = "pad"; @@ -237,7 +237,7 @@ spare = NULL; if (n->to_type == PCB_TYPE_PIN) - spare = ((PinType *) n->to)->Spare; + spare = ((pcb_pin_t *) n->to)->Spare; if (n->to_type == PCB_TYPE_PAD) spare = ((pcb_pad_t *) n->to)->Spare; if (spare != NULL) { @@ -338,7 +338,7 @@ typedef struct pinpad_s pinpad_t; struct pinpad_s { int ignore; /* if 1, changed our mind, do not check */ - PinType *pin; + pcb_pin_t *pin; pcb_pad_t *pad; const char *with_net; /* the name of the net this pin/pad is in short with */ pinpad_t *next; @@ -346,7 +346,7 @@ static pinpad_t *shorts = NULL; -void rat_found_short(PinType * pin, pcb_pad_t * pad, const char *with_net) +void rat_found_short(pcb_pin_t * pin, pcb_pad_t * pad, const char *with_net) { pinpad_t *pp; pp = malloc(sizeof(pinpad_t)); Index: trunk/src_plugins/mincut/rats_mincut.h =================================================================== --- trunk/src_plugins/mincut/rats_mincut.h (revision 4770) +++ trunk/src_plugins/mincut/rats_mincut.h (revision 4771) @@ -23,5 +23,5 @@ * */ -void rat_found_short(PinType * pin, pcb_pad_t * pad, const char *with_net); +void rat_found_short(pcb_pin_t * pin, pcb_pad_t * pad, const char *with_net); void rat_proc_shorts(void); Index: trunk/src_plugins/propedit/propsel.c =================================================================== --- trunk/src_plugins/propedit/propsel.c (revision 4770) +++ trunk/src_plugins/propedit/propsel.c (revision 4771) @@ -145,7 +145,7 @@ map_attr(ctx, &text->Attributes); } -static void map_epin_cb(void *ctx, pcb_board_t *pcb, ElementType *element, PinType *pin) +static void map_epin_cb(void *ctx, pcb_board_t *pcb, ElementType *element, pcb_pin_t *pin) { map_chk_skip(ctx, pin); map_add_prop(ctx, "p/pin/thickness", Coord, pin->Thickness); @@ -164,7 +164,7 @@ -static void map_via_cb(void *ctx, pcb_board_t *pcb, PinType *via) +static void map_via_cb(void *ctx, pcb_board_t *pcb, pcb_pin_t *via) { map_chk_skip(ctx, via); map_add_prop(ctx, "p/via/thickness", Coord, via->Thickness); @@ -352,7 +352,7 @@ set_text_cb_any(ctx, pcb, PCB_TYPE_ELEMENT_NAME, element, text); } -static void set_epin_cb(void *ctx, pcb_board_t *pcb, ElementType *element, PinType *pin) +static void set_epin_cb(void *ctx, pcb_board_t *pcb, ElementType *element, pcb_pin_t *pin) { set_ctx_t *st = (set_ctx_t *)ctx; const char *pn = st->name + 6; @@ -393,7 +393,7 @@ ChangeObjectMaskSize(PCB_TYPE_PAD, pad->Element, pad, NULL, st->c, st->c_absolute)) DONE; } -static void set_via_cb(void *ctx, pcb_board_t *pcb, PinType *via) +static void set_via_cb(void *ctx, pcb_board_t *pcb, pcb_pin_t *via) { set_ctx_t *st = (set_ctx_t *)ctx; const char *pn = st->name + 6; @@ -528,7 +528,7 @@ del_attr(ctx, &text->Attributes); } -static void del_epin_cb(void *ctx, pcb_board_t *pcb, ElementType *element, PinType *pin) +static void del_epin_cb(void *ctx, pcb_board_t *pcb, ElementType *element, pcb_pin_t *pin) { map_chk_skip(ctx, pin); del_attr(ctx, &pin->Attributes); @@ -540,7 +540,7 @@ del_attr(ctx, &pad->Attributes); } -static void del_via_cb(void *ctx, pcb_board_t *pcb, PinType *via) +static void del_via_cb(void *ctx, pcb_board_t *pcb, pcb_pin_t *via) { map_chk_skip(ctx, via); del_attr(ctx, &via->Attributes); Index: trunk/src_plugins/puller/puller.c =================================================================== --- trunk/src_plugins/puller/puller.c (revision 4770) +++ trunk/src_plugins/puller/puller.c (revision 4771) @@ -730,7 +730,7 @@ r_search(CURRENT->arc_tree, &b, NULL, find_pair_arc_callback, &fpcs, NULL); } -static int check_point_in_pin(PinTypePtr pin, int x, int y, End * e) +static int check_point_in_pin(pcb_pin_t *pin, int x, int y, End * e) { int inside_p; int t = (pin->Thickness + 1) / 2; @@ -752,7 +752,7 @@ static r_dir_t find_pair_pinline_callback(const pcb_box_t * b, void *cl) { pcb_line_t *line = (pcb_line_t *) b; - PinTypePtr pin = (PinTypePtr) cl; + pcb_pin_t *pin = (pcb_pin_t *) cl; Extra *e = LINE2EXTRA(line); int hits; @@ -784,7 +784,7 @@ static r_dir_t find_pair_pinarc_callback(const pcb_box_t * b, void *cl) { pcb_arc_t *arc = (pcb_arc_t *) b; - PinTypePtr pin = (PinTypePtr) cl; + pcb_pin_t *pin = (pcb_pin_t *) cl; Extra *e = ARC2EXTRA(arc); int hits; @@ -1553,7 +1553,7 @@ static r_dir_t gp_pin_cb(const pcb_box_t * b, void *cb) { - const PinTypePtr p = (PinTypePtr) b; + const pcb_pin_t *p = (pcb_pin_t *) b; int t2 = (p->Thickness + 1) / 2; if (p == start_pinpad || p == end_pinpad) Index: trunk/src_plugins/query/query_access.c =================================================================== --- trunk/src_plugins/query/query_access.c (revision 4770) +++ trunk/src_plugins/query/query_access.c (revision 4771) @@ -91,7 +91,7 @@ APPEND(ctx, PCB_OBJ_ETEXT, text, PCB_PARENT_ELEMENT, element); } -static void list_epin_cb(void *ctx, pcb_board_t *pcb, ElementType *element, PinType *pin) +static void list_epin_cb(void *ctx, pcb_board_t *pcb, ElementType *element, pcb_pin_t *pin) { APPEND(ctx, PCB_OBJ_PIN, pin, PCB_PARENT_ELEMENT, element); } @@ -101,7 +101,7 @@ APPEND(ctx, PCB_OBJ_PAD, pad, PCB_PARENT_ELEMENT, element); } -static void list_via_cb(void *ctx, pcb_board_t *pcb, PinType *via) +static void list_via_cb(void *ctx, pcb_board_t *pcb, pcb_pin_t *via) { APPEND(ctx, PCB_OBJ_VIA, via, PCB_PARENT_DATA, pcb->Data); } @@ -457,7 +457,7 @@ static int field_via(pcb_obj_t *obj, pcb_qry_node_t *fld, pcb_qry_val_t *res) { - PinType *p = obj->data.via; + pcb_pin_t *p = obj->data.via; query_fields_keys_t fh1; fld2hash_req(fh1, fld, 0); Index: trunk/src_plugins/report/drill.c =================================================================== --- trunk/src_plugins/report/drill.c (revision 4770) +++ trunk/src_plugins/report/drill.c (revision 4771) @@ -39,15 +39,15 @@ /* * some local prototypes */ -static void FillDrill(DrillTypePtr, ElementTypePtr, PinTypePtr); -static void InitializeDrill(DrillTypePtr, PinTypePtr, ElementTypePtr); +static void FillDrill(DrillTypePtr, ElementTypePtr, pcb_pin_t *); +static void InitializeDrill(DrillTypePtr, pcb_pin_t *, ElementTypePtr); -static void FillDrill(DrillTypePtr Drill, ElementTypePtr Element, PinTypePtr Pin) +static void FillDrill(DrillTypePtr Drill, ElementTypePtr Element, pcb_pin_t *Pin) { pcb_cardinal_t n; ElementTypeHandle ptr; - PinTypeHandle pin; + pcb_pin_t ** pin; pin = GetDrillPinMemory(Drill); *pin = Pin; @@ -67,7 +67,7 @@ Drill->UnplatedCount++; } -static void InitializeDrill(DrillTypePtr drill, PinTypePtr pin, ElementTypePtr element) +static void InitializeDrill(DrillTypePtr drill, pcb_pin_t *pin, ElementTypePtr element) { void *ptr; @@ -82,7 +82,7 @@ drill->Pin = NULL; drill->PinMax = 0; ptr = (void *) GetDrillPinMemory(drill); - *((PinTypeHandle) ptr) = pin; + *((pcb_pin_t **) ptr) = pin; if (element) { ptr = (void *) GetDrillElementMemory(drill); *((ElementTypeHandle) ptr) = element; @@ -215,8 +215,8 @@ d->Drill[i + 1].Element = NULL; d->Drill[i].PinMax = d->Drill[i].PinN + d->Drill[i + 1].PinN; - d->Drill[i].Pin = (PinTypePtr *) realloc(d->Drill[i].Pin, d->Drill[i].PinMax * sizeof(PinTypePtr)); - memcpy(d->Drill[i].Pin + d->Drill[i].PinN, d->Drill[i + 1].Pin, d->Drill[i + 1].PinN * sizeof(PinTypePtr)); + d->Drill[i].Pin = (pcb_pin_t **) realloc(d->Drill[i].Pin, d->Drill[i].PinMax * sizeof(pcb_pin_t *)); + memcpy(d->Drill[i].Pin + d->Drill[i].PinN, d->Drill[i + 1].Pin, d->Drill[i + 1].PinN * sizeof(pcb_pin_t *)); d->Drill[i].PinN += d->Drill[i + 1].PinN; free(d->Drill[i + 1].Pin); d->Drill[i + 1].Pin = NULL; @@ -269,9 +269,9 @@ /* --------------------------------------------------------------------------- * get next slot for a DrillPoint, allocates memory if necessary */ -PinTypeHandle GetDrillPinMemory(DrillTypePtr Drill) +pcb_pin_t ** GetDrillPinMemory(DrillTypePtr Drill) { - PinTypePtr *pin; + pcb_pin_t **pin; pin = Drill->Pin; @@ -278,9 +278,9 @@ /* realloc new memory if necessary and clear it */ if (Drill->PinN >= Drill->PinMax) { Drill->PinMax += STEP_POINT; - pin = (PinTypePtr *) realloc(pin, Drill->PinMax * sizeof(PinTypeHandle)); + pin = (pcb_pin_t **) realloc(pin, Drill->PinMax * sizeof(pcb_pin_t **)); Drill->Pin = pin; - memset(pin + Drill->PinN, 0, STEP_POINT * sizeof(PinTypeHandle)); + memset(pin + Drill->PinN, 0, STEP_POINT * sizeof(pcb_pin_t **)); } return (pin + Drill->PinN++); } Index: trunk/src_plugins/report/drill.h =================================================================== --- trunk/src_plugins/report/drill.h (revision 4770) +++ trunk/src_plugins/report/drill.h (revision 4771) @@ -37,7 +37,7 @@ UnplatedCount, /* number of these holes that are unplated */ PinN, /* number of drill coordinates in the list */ PinMax; /* max number of coordinates from malloc() */ - PinTypePtr *Pin; /* coordinates to drill */ + pcb_pin_t **Pin; /* coordinates to drill */ ElementTypePtr *Element; /* a pointer to an array of element pointers */ } DrillType, *DrillTypePtr; @@ -51,7 +51,7 @@ void FreeDrillInfo(DrillInfoTypePtr); void RoundDrillInfo(DrillInfoTypePtr, int); DrillTypePtr GetDrillInfoDrillMemory(DrillInfoTypePtr); -PinTypeHandle GetDrillPinMemory(DrillTypePtr); +pcb_pin_t **GetDrillPinMemory(DrillTypePtr); ElementTypeHandle GetDrillElementMemory(DrillTypePtr); #define DRILL_LOOP(top) do { \ Index: trunk/src_plugins/report/report.c =================================================================== --- trunk/src_plugins/report/report.c (revision 4770) +++ trunk/src_plugins/report/report.c (revision 4771) @@ -135,7 +135,7 @@ switch (type) { case PCB_TYPE_VIA: { - PinTypePtr via; + pcb_pin_t *via; #ifndef NDEBUG if (gui->shift_is_pressed()) { __r_dump_tree(PCB->Data->via_tree->root, 0); @@ -142,7 +142,7 @@ return 0; } #endif - via = (PinTypePtr) ptr2; + via = (pcb_pin_t *) ptr2; if (TEST_FLAG(PCB_FLAG_HOLE, via)) report = pcb_strdup_printf("%m+VIA ID# %ld; Flags:%s\n" "(X,Y) = %$mD.\n" @@ -170,7 +170,7 @@ } case PCB_TYPE_PIN: { - PinTypePtr Pin; + pcb_pin_t *Pin; ElementTypePtr element; #ifndef NDEBUG if (gui->shift_is_pressed()) { @@ -178,7 +178,7 @@ return 0; } #endif - Pin = (PinTypePtr) ptr2; + Pin = (pcb_pin_t *) ptr2; element = (ElementTypePtr) ptr1; PIN_LOOP(element); @@ -767,8 +767,8 @@ if (SeekPad(net->Entry, &conn, pcb_false)) { switch (conn.type) { case PCB_TYPE_PIN: - x = ((PinType *) (conn.ptr2))->X; - y = ((PinType *) (conn.ptr2))->Y; + x = ((pcb_pin_t *) (conn.ptr2))->X; + y = ((pcb_pin_t *) (conn.ptr2))->Y; net_found = 1; break; case PCB_TYPE_PAD: Index: trunk/src_plugins/teardrops/teardrops.c =================================================================== --- trunk/src_plugins/teardrops/teardrops.c (revision 4770) +++ trunk/src_plugins/teardrops/teardrops.c (revision 4771) @@ -36,7 +36,7 @@ /* 1 mm */ /* #define MAX_DISTANCE 1000000 */ -static PinType *pin; +static pcb_pin_t *pin; static pcb_pad_t *pad; static int layer; static int px, py; @@ -192,7 +192,7 @@ return 1; } -static void check_pin(PinType * _pin) +static void check_pin(pcb_pin_t * _pin) { pcb_box_t spot; @@ -220,7 +220,7 @@ } } -static void check_via(PinType * _pin) +static void check_via(pcb_pin_t * _pin) { pcb_box_t spot; Index: trunk/src_plugins/toporouter/toporouter.c =================================================================== --- trunk/src_plugins/toporouter/toporouter.c (revision 4770) +++ trunk/src_plugins/toporouter/toporouter.c (revision 4771) @@ -305,7 +305,7 @@ #if TOPO_OUTPUT_ENABLED drawing_context_t *dc = (drawing_context_t *) data; toporouter_vertex_t *tv; - PinType *pin; + pcb_pin_t *pin; pcb_pad_t *pad; gdouble blue; @@ -334,7 +334,7 @@ /* printf("tv->type = %d\n", tv->type); */ if (!dc->mode) { if (tv->bbox) { - pin = (PinType *) tv->bbox->data; + pin = (pcb_pin_t *) tv->bbox->data; pad = (pcb_pad_t *) tv->bbox->data; blue = 0.0f; @@ -597,12 +597,12 @@ } else { if (box->type == PIN || box->type == VIA) { - PinType *pin = (PinType *) box->data; + pcb_pin_t *pin = (pcb_pin_t *) box->data; if (TEST_FLAG(PCB_FLAG_SQUARE, pin) || TEST_FLAG(PCB_FLAG_OCTAGON, pin)) { return 0.; } -/* return ((PinType *)box->data)->Thickness + 1.;*/ - return ((PinType *) box->data)->Thickness; +/* return ((pcb_pin_t *)box->data)->Thickness + 1.;*/ + return ((pcb_pin_t *) box->data)->Thickness; } else if (box->type == PAD) { pcb_pad_t *pad = (pcb_pad_t *) box->data; @@ -644,7 +644,7 @@ } else { /* if(box->type == PIN || box->type == VIA) - return ((PinType *)box->data)->Clearance; + return ((pcb_pin_t *)box->data)->Clearance; else if(box->type == PAD) return ((pcb_pad_t *)box->data)->Clearance; */ @@ -1754,7 +1754,7 @@ return (lookup_thickness(pad->Name) / 2.) + lookup_clearance(pad->Name); } -static inline gdouble pin_rad(PinType * pin) +static inline gdouble pin_rad(pcb_pin_t * pin) { return (lookup_thickness(pin->Name) / 2.) + lookup_clearance(pin->Name); } @@ -2021,7 +2021,7 @@ if (TEST_FLAG(PCB_FLAG_SQUARE, via)) { - vlist = rect_with_attachments(pin_rad((PinType *) via), + vlist = rect_with_attachments(pin_rad((pcb_pin_t *) via), x - t, y - t, x - t, y + t, x + t, y + t, x + t, y - t, l - r->layers); bbox = toporouter_bbox_create(l - r->layers, vlist, VIA, via); r->bboxes = g_slist_prepend(r->bboxes, bbox); @@ -2036,7 +2036,7 @@ } else { - vlist = rect_with_attachments(pin_rad((PinType *) via), + vlist = rect_with_attachments(pin_rad((pcb_pin_t *) via), x - t, y - t, x - t, y + t, x + t, y + t, x + t, y - t, l - r->layers); bbox = toporouter_bbox_create(l - r->layers, vlist, VIA, via); r->bboxes = g_slist_prepend(r->bboxes, bbox); @@ -2736,7 +2736,7 @@ else if (connection->type == PCB_TYPE_PIN) { guint m; for (m = 0; m < groupcount(); m++) { - PinType *pin = (PinType *) connection->ptr2; + pcb_pin_t *pin = (pcb_pin_t *) connection->ptr2; toporouter_bbox_t *box = toporouter_bbox_locate(r, PIN, pin, connection->X, connection->Y, m); cluster_join_bbox(cluster, box); } @@ -2748,7 +2748,7 @@ else if (connection->type == PCB_TYPE_VIA) { guint m; for (m = 0; m < groupcount(); m++) { - PinType *pin = (PinType *) connection->ptr2; + pcb_pin_t *pin = (pcb_pin_t *) connection->ptr2; toporouter_bbox_t *box = toporouter_bbox_locate(r, VIA, pin, connection->X, connection->Y, m); cluster_join_bbox(cluster, box); } @@ -8148,7 +8148,7 @@ ALLPAD_LOOP(PCB->Data); { if (TEST_FLAG(PCB_FLAG_SELECTED, pad)) { - PinTypePtr via; + pcb_pin_t *via; pcb_line_t *line; pcb_pad_t *pad0 = element->Pad->data;