fix: missing graph borders
This commit is contained in:
parent
70adb61410
commit
d423545ccc
|
|
@ -286,6 +286,12 @@
|
|||
<Component Id="CMPUTILE3">
|
||||
<File Id="UTILE3" KeyPath="yes" Source="../../src/utile/utile3" />
|
||||
</Component>
|
||||
<Component Id="CMPUTILEBAT">
|
||||
<File Id="UTILEBAT" KeyPath="yes" Source="../../src/utile/utile.bat" />
|
||||
</Component>
|
||||
<Component Id="CMPUTILE3BAT">
|
||||
<File Id="UTILE3BAT" KeyPath="yes" Source="../../src/utile/utile3.bat" />
|
||||
</Component>
|
||||
<Component Id="CMPUTILETCL">
|
||||
<File Id="UTILETCL" KeyPath="yes" Source="../../src/utile/utile.tcl" />
|
||||
</Component>
|
||||
|
|
@ -356,6 +362,8 @@
|
|||
<ComponentRef Id="CMPTEMPLATESTIMULI" />
|
||||
<ComponentRef Id="CMPUTILE" />
|
||||
<ComponentRef Id="CMPUTILE3" />
|
||||
<ComponentRef Id="CMPUTILEBAT" />
|
||||
<ComponentRef Id="CMPUTILE3BAT" />
|
||||
<ComponentRef Id="CMPUTILETCL" />
|
||||
<ComponentRef Id="CMPUTILETXT" />
|
||||
</ComponentGroup>
|
||||
|
|
|
|||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
|
|
@ -280,7 +280,7 @@ static int waves_callback(int event, int mx, int my, KeySym key, int button, int
|
|||
}
|
||||
}
|
||||
|
||||
if(need_redraw) draw_graph(c, n, 1); /* draw data in each graph box */
|
||||
if(need_redraw) draw_graph(c, n, 3); /* draw data in each graph box */
|
||||
|
||||
}
|
||||
draw_selection(xctx->gc[SELLAYER], 0);
|
||||
|
|
|
|||
13
src/draw.c
13
src/draw.c
|
|
@ -1837,8 +1837,10 @@ void draw_graph(int c, int i, int flags)
|
|||
txtsizelab = marginy / 100;
|
||||
|
||||
/* background */
|
||||
filledrect(0, NOW, rx1, ry1, rx2, ry2);
|
||||
drawrect(c, NOW, rx1, ry1, rx2, ry2, 1);
|
||||
if((flags & 2) ) {
|
||||
filledrect(0, NOW, rx1, ry1, rx2, ry2);
|
||||
drawrect(c, NOW, rx1, ry1, rx2, ry2, 1);
|
||||
}
|
||||
|
||||
/* vertical grid lines */
|
||||
deltax = axis_increment((wx2 - wx1), divx);
|
||||
|
|
@ -1860,7 +1862,7 @@ void draw_graph(int c, int i, int flags)
|
|||
my_snprintf(lab, S(lab), "%.4g", wx * unitx);
|
||||
draw_string(3, NOW, lab, 0, 0, 1, 0, W_X(wx), y2 + 30 * txtsizex, txtsizex, txtsizex);
|
||||
}
|
||||
/* first and last box delimiters */
|
||||
/* first and last vertical box delimiters */
|
||||
drawline(2, ADD, W_X(wx1), W_Y(wy2), W_X(wx1), W_Y(wy1), 0);
|
||||
drawline(2, ADD, W_X(wx2), W_Y(wy2), W_X(wx2), W_Y(wy1), 0);
|
||||
/* horizontal grid lines */
|
||||
|
|
@ -1882,7 +1884,7 @@ void draw_graph(int c, int i, int flags)
|
|||
my_snprintf(lab, S(lab), "%.4g", wy * unity);
|
||||
draw_string(3, NOW, lab, 0, 1, 0, 1, x1 - 2 - 30 * txtsizey, W_Y(wy), txtsizey, txtsizey);
|
||||
}
|
||||
/* first and last box delimiters */
|
||||
/* first and last horizontal box delimiters */
|
||||
drawline(2, ADD, W_X(wx1), W_Y(wy1), W_X(wx2), W_Y(wy1), 0);
|
||||
drawline(2, ADD, W_X(wx1), W_Y(wy2), W_X(wx2), W_Y(wy2), 0);
|
||||
/* Horizontal axis (if in viewport) */
|
||||
|
|
@ -1994,6 +1996,7 @@ void draw_graph(int c, int i, int flags)
|
|||
* 1: do final XCopyArea (copy 2nd buffer areas to screen)
|
||||
* If draw_waves() is called from draw() no need to do XCopyArea, as draw() does it already.
|
||||
* This makes drawing faster and removes a 'tearing' effect when moving around.
|
||||
* 2: do not draw background (when called from draw() this is already done)
|
||||
*/
|
||||
void draw_waves(int flags)
|
||||
{
|
||||
|
|
@ -2089,7 +2092,7 @@ void draw(void)
|
|||
}
|
||||
if(xctx->enable_layer[c]) for(i=0;i<xctx->rects[c];i++) {
|
||||
xRect *r = &xctx->rect[c][i];
|
||||
if(c != 2 || r->flags != 1 /* || !schematic_waves_loaded() */) {
|
||||
if( (c != 2 || r->flags != 1) || schematic_waves_loaded() ) {
|
||||
drawrect(c, ADD, r->x1, r->y1, r->x2, r->y2, r->dash);
|
||||
filledrect(c, ADD, r->x1, r->y1, r->x2, r->y2);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -2002,15 +2002,11 @@ int xschem(ClientData clientdata, Tcl_Interp *interp, int argc, const char * arg
|
|||
if(!strcmp(argv[1], "raw_read"))
|
||||
{
|
||||
cmd_found = 1;
|
||||
if(argc > 2) {
|
||||
|
||||
|
||||
if(schematic_waves_loaded()) {
|
||||
free_rawfile();
|
||||
} else {
|
||||
free_rawfile();
|
||||
read_rawfile(argv[2]);
|
||||
}
|
||||
if(schematic_waves_loaded()) {
|
||||
free_rawfile();
|
||||
} else if(argc > 2) {
|
||||
free_rawfile();
|
||||
read_rawfile(argv[2]);
|
||||
}
|
||||
Tcl_ResetResult(interp);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -181,7 +181,13 @@ proc help_window {w filename} {
|
|||
}
|
||||
|
||||
proc translate {f} {
|
||||
eval exec "utile $f"
|
||||
global tcl_platform
|
||||
set OS [lindex $tcl_platform(os) 0]
|
||||
if {$OS == "Windows"} {
|
||||
eval exec "utile.bat $f"
|
||||
} else {
|
||||
eval exec "utile $f"
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -1109,12 +1109,18 @@ proc utile_translate {schname} {
|
|||
|
||||
proc utile_gui {schname} {
|
||||
global netlist_dir debug_var XSCHEM_SHAREDIR
|
||||
global utile_gui_path utile_cmd_path
|
||||
global utile_gui_path OS
|
||||
|
||||
simuldir
|
||||
set tmpname [file rootname "$schname"]
|
||||
eval exec {sh -c "cd \"$netlist_dir\"; \
|
||||
XSCHEM_SHAREDIR=\"$XSCHEM_SHAREDIR\" \"$utile_gui_path\" stimuli.$tmpname"} &
|
||||
if {$OS == "Windows"} {
|
||||
eval exec {cmd /V /C "cd $netlist_dir && \
|
||||
set XSCHEM_SHAREDIR=$XSCHEM_SHAREDIR&&set GUI_PATH=$utile_gui_path.bat&& \
|
||||
!GUI_PATH! stimuli.$tmpname"}
|
||||
} else {
|
||||
eval exec {sh -c "cd \"$netlist_dir\"; \
|
||||
XSCHEM_SHAREDIR=\"$XSCHEM_SHAREDIR\" \"$utile_gui_path\" stimuli.$tmpname"} &
|
||||
}
|
||||
}
|
||||
|
||||
proc utile_edit {schname} {
|
||||
|
|
|
|||
Loading…
Reference in New Issue