Index: trunk/doc/TODO =================================================================== --- trunk/doc/TODO (revision 27290) +++ trunk/doc/TODO (revision 27291) @@ -21,10 +21,10 @@ - DOC: finish DAD doc (doc/developer/dad/: e.g. run.html is missing) [report: Alain] - FEATURE: no-export attribute: cache a no-export attribute in a bitfield (e.g. flags like no-export for vector outputs, pixel outputs); exporter should set the bits in HID; core rendring should decide what to draw; use case: poly clearance to emulate keep-away on outline, and replace the old zero-width line trick [report: karl] - FEATURE: configure setting: library window filter shouldn't really filter if there's () in the string [report: pskibinski] -- asm() dialog ++ asm() dialog + FEATURE: Add a button to clear the done status from a component. [report: Ade] + FEATURE: Show the status message on a group when minimized to indicate whether the groups components are done, not done or partially done. [report: Ade] - - FEATURE: If a component is out of view when selected then pan the view until it is visible. May need to zoom also if a group is selected. [report: Ade] + + FEATURE: If a component is out of view when selected then pan the view until it is visible. May need to zoom also if a group is selected. [report: Ade] - CAM: - FEATURE: make the drill exporter sort drills by attributes, an user configured table telling which drill (by attribute) ends up in which file (for support for plugged vias/filled vias) [report: Vuokko] - FEATURE: invent a generic API for both the drill attrib config table Index: trunk/src_plugins/asm/asm.c =================================================================== --- trunk/src_plugins/asm/asm.c (revision 27290) +++ trunk/src_plugins/asm/asm.c (revision 27291) @@ -333,13 +333,21 @@ static void select_part(part_t *p) { void *r1, *r2, *r3; + pcb_subc_t *sc; pcb_objtype_t type; + pcb_box_t view; type = pcb_search_obj_by_id_(PCB->Data, &r1, &r2, &r3, p->id, PCB_OBJ_SUBC); if (type != PCB_OBJ_SUBC) return; - pcb_subc_select(PCB, (pcb_subc_t *)r2, PCB_CHGFLG_SET, 1); + sc = (pcb_subc_t *)r2; + pcb_subc_select(PCB, sc, PCB_CHGFLG_SET, 1); + + /* if the part is out of the screen, pan there */ + pcb_gui->view_get(pcb_gui, &view); + if ((view.X2 < sc->BoundingBox.X1) || (view.X1 > sc->BoundingBox.X2) || (view.Y2 < sc->BoundingBox.Y1) || (view.Y1 > sc->BoundingBox.Y2)) + pcb_gui->pan(pcb_gui, (sc->BoundingBox.X1+sc->BoundingBox.X2)/2, (sc->BoundingBox.Y1+sc->BoundingBox.Y2)/2, 0); } static void asm_row_selected(pcb_hid_attribute_t *attrib, void *hid_ctx, pcb_hid_row_t *row)