xschem paste command: allow set x and y on cmdline to avoid interactive placement

This commit is contained in:
Stefan Frederik 2021-12-09 20:31:06 +01:00
parent d44c733fae
commit 9e2f3816fd
1 changed files with 6 additions and 0 deletions

View File

@ -1694,8 +1694,14 @@ int xschem(ClientData clientdata, Tcl_Interp *interp, int argc, const char * arg
else if(!strcmp(argv[1],"paste"))
{
xRect boundbox;
cmd_found = 1;
merge_file(2,".sch");
if(argc > 3) {
xctx->deltax = atof(argv[2]);
xctx->deltay = atof(argv[3]);
move_objects(END, 0, 0.0, 0.0);
}
Tcl_ResetResult(interp);
}