[Bugfix]: Additional fix to address the issue from previous bugfix. 'drawtemp_manhattanlines()' function will no longer force the use of 'orthogonal_wiring'-style dynamic 'manhattan_lines' value for every operation (it will need to be specified whether it needs to be forced or not in the function arguments).
This commit is contained in:
parent
9d7acdd78d
commit
56d125413f
|
|
@ -3183,11 +3183,11 @@ void new_wire(int what, double mx_snap, double my_snap)
|
|||
xctx->ui_state &= ~STARTWIRE;
|
||||
}
|
||||
if( (what & RUBBER) ) {
|
||||
drawtemp_manhattanline(xctx->gctiled, NOW, xctx->nl_x1, xctx->nl_y1, xctx->nl_x2, xctx->nl_y2);
|
||||
drawtemp_manhattanline(xctx->gctiled, NOW, xctx->nl_x1, xctx->nl_y1, xctx->nl_x2, xctx->nl_y2, 0);
|
||||
restore_selection(xctx->nl_x1, xctx->nl_y1, xctx->nl_x2, xctx->nl_y2);
|
||||
xctx->nl_x2 = mx_snap; xctx->nl_y2 = my_snap;
|
||||
if(!(what & CLEAR)) {
|
||||
drawtemp_manhattanline(xctx->gc[WIRELAYER], NOW, xctx->nl_x1, xctx->nl_y1, xctx->nl_x2, xctx->nl_y2);
|
||||
drawtemp_manhattanline(xctx->gc[WIRELAYER], NOW, xctx->nl_x1, xctx->nl_y1, xctx->nl_x2, xctx->nl_y2, 0);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1375,11 +1375,11 @@ void drawtempline(GC gc, int what, double linex1,double liney1,double linex2,dou
|
|||
}
|
||||
}
|
||||
|
||||
void drawtemp_manhattanline(GC gc, int what, double x1, double y1, double x2, double y2)
|
||||
void drawtemp_manhattanline(GC gc, int what, double x1, double y1, double x2, double y2, int force_manhattan)
|
||||
{
|
||||
double nl_xx1, nl_yy1, nl_xx2, nl_yy2;
|
||||
double origin_shifted_x2, origin_shifted_y2;
|
||||
if(tclgetboolvar("orthogonal_wiring")) {
|
||||
if(tclgetboolvar("orthogonal_wiring") && force_manhattan) {
|
||||
/* Origin shift the cartesian coordinate p2(x2,y2) w.r.t. p1(x1,y1) */
|
||||
origin_shifted_x2 = x2 - x1;
|
||||
origin_shifted_y2 = y2 - y1;
|
||||
|
|
|
|||
12
src/move.c
12
src/move.c
|
|
@ -379,24 +379,24 @@ void draw_selection(GC g, int interruptable)
|
|||
{
|
||||
if(xctx->wire[n].bus)
|
||||
drawtemp_manhattanline(g, THICK, xctx->rx1+xctx->deltax, xctx->ry1+xctx->deltay,
|
||||
xctx->rx2+xctx->deltax, xctx->ry2+xctx->deltay);
|
||||
xctx->rx2+xctx->deltax, xctx->ry2+xctx->deltay, 1);
|
||||
else
|
||||
drawtemp_manhattanline(g, ADD, xctx->rx1+xctx->deltax, xctx->ry1+xctx->deltay,
|
||||
xctx->rx2+xctx->deltax, xctx->ry2+xctx->deltay);
|
||||
xctx->rx2+xctx->deltax, xctx->ry2+xctx->deltay, 1);
|
||||
}
|
||||
else if(xctx->wire[n].sel==SELECTED1)
|
||||
{
|
||||
if(xctx->wire[n].bus)
|
||||
drawtemp_manhattanline(g, THICK, xctx->rx1+xctx->deltax, xctx->ry1+xctx->deltay, xctx->rx2, xctx->ry2);
|
||||
drawtemp_manhattanline(g, THICK, xctx->rx1+xctx->deltax, xctx->ry1+xctx->deltay, xctx->rx2, xctx->ry2, 1);
|
||||
else
|
||||
drawtemp_manhattanline(g, ADD, xctx->rx1+xctx->deltax, xctx->ry1+xctx->deltay, xctx->rx2, xctx->ry2);
|
||||
drawtemp_manhattanline(g, ADD, xctx->rx1+xctx->deltax, xctx->ry1+xctx->deltay, xctx->rx2, xctx->ry2, 1);
|
||||
}
|
||||
else if(xctx->wire[n].sel==SELECTED2)
|
||||
{
|
||||
if(xctx->wire[n].bus)
|
||||
drawtemp_manhattanline(g, THICK, xctx->rx1, xctx->ry1, xctx->rx2+xctx->deltax, xctx->ry2+xctx->deltay);
|
||||
drawtemp_manhattanline(g, THICK, xctx->rx1, xctx->ry1, xctx->rx2+xctx->deltax, xctx->ry2+xctx->deltay, 1);
|
||||
else
|
||||
drawtemp_manhattanline(g, ADD, xctx->rx1, xctx->ry1, xctx->rx2+xctx->deltax, xctx->ry2+xctx->deltay);
|
||||
drawtemp_manhattanline(g, ADD, xctx->rx1, xctx->ry1, xctx->rx2+xctx->deltax, xctx->ry2+xctx->deltay, 1);
|
||||
}
|
||||
break;
|
||||
case LINE:
|
||||
|
|
|
|||
|
|
@ -1428,7 +1428,7 @@ extern void filledrect(int c, int what, double rectx1,double recty1,
|
|||
|
||||
|
||||
extern void drawtempline(GC gc, int what, double x1,double y1,double x2,double y2);
|
||||
extern void drawtemp_manhattanline(GC gc, int what, double x1,double y1,double x2,double y2);
|
||||
extern void drawtemp_manhattanline(GC gc, int what, double x1,double y1,double x2,double y2, int force_manhattan);
|
||||
|
||||
/* instead of doing a drawtemprect(xctx->gctiled, NOW, ....) do 4
|
||||
* XCopy Area operations. Used if fix_broken_tiled_fill is set */
|
||||
|
|
|
|||
Loading…
Reference in New Issue