int used_name_layers[]; string used_name_[]; int offset = 0; string Path="", Name=""; Path = "/home/huytin/Stage/misc/EagleNamePositions/"; Name = "cible.pn"; if (board) { board(B) { B.layers(L) { used_name_[L.number] = L.name; } string fileName = Path + Name ; output(fileName) { printf("T.layer E.name E.value T.x T.y T.angle T.size T.mirror T.ratio\n\n"); B.elements(E) { // smashed texts E.texts(T) { if (T.value == E.name) { //used_name_layers[T.layer]++; int angle = int(T.angle); printf("%-8d %-8s %-8s %-8d %-8d %-8d %-8d %-8d %-8d\n",T.layer, E.name, E.value, T.x, T.y, angle, T.size, T.mirror, T.ratio); //Text(E.name, T.layer, T.x, T.y, T.size, T.angle, T.ratio, T.mirror, T.spin); } } } } } } else { dlgMessageBox("\n Start this ULP in a board\n"); exit(0); }