Browse Source

improve plot window handling

pre-master-46
h_vogt 17 years ago
parent
commit
f9630b7d9f
  1. 7
      src/frontend/wdisp/windisp.c

7
src/frontend/wdisp/windisp.c

@ -153,7 +153,7 @@ int WIN_Init( )
/* (attach to window) */ /* (attach to window) */
static GRAPH * pGraph( HWND hwnd) static GRAPH * pGraph( HWND hwnd)
{ {
return (GRAPH *) GetWindowLong( hwnd, 0);
return (GRAPH *) GetWindowLong( hwnd, 0);
} }
/* return line style for plotting */ /* return line style for plotting */
@ -375,7 +375,7 @@ LRESULT CALLBACK PlotWindowProc( HWND hwnd,
/* start plot loop with argument buf */ /* start plot loop with argument buf */
case WM_RBUTTONUP: case WM_RBUTTONUP:
{ {
GRAPH * gr = pGraph( hwnd);
GRAPH * gr = pGraph( hwnd);
InvalidateRect (hwnd, NULL, TRUE) ; InvalidateRect (hwnd, NULL, TRUE) ;
xe = LOWORD (lParam); xe = LOWORD (lParam);
ye = HIWORD (lParam); ye = HIWORD (lParam);
@ -392,7 +392,8 @@ LRESULT CALLBACK PlotWindowProc( HWND hwnd,
if (!eq(plot_cur->pl_typename, buf2)) { if (!eq(plot_cur->pl_typename, buf2)) {
(void) sprintf(buf, (void) sprintf(buf,
"setplot %s; %s xlimit %e %e ylimit %e %e; setplot $curplot\n",
// "setplot %s; %s xlimit %e %e ylimit %e %e; setplot $curplot\n",
"setplot %s; %s xlimit %e %e ylimit %e %e\n",
buf2, gr->commandline, fx0, fxe, fy0, fye); buf2, gr->commandline, fx0, fxe, fy0, fye);
} else { } else {
(void) sprintf(buf, "%s xlimit %e %e ylimit %e %e\n", (void) sprintf(buf, "%s xlimit %e %e ylimit %e %e\n",

Loading…
Cancel
Save