bch
/
xmem
1
0
Fork 0

Summary: update function definitions

This commit is contained in:
bch 2017-02-26 16:02:48 +00:00
parent a63975b5f9
commit 9484298c47
1 changed files with 15 additions and 37 deletions

View File

@ -51,7 +51,7 @@ static XtResource resources[] = {
#undef offset
static void Initialize(), Destroy(), Redisplay(), MoveChart(), SetPoints();
static void Initialize(), Destroy(), Redisplay(), MoveChart(MemStripChartWidget w, Boolean blit), SetPoints();
static Boolean SetValues();
static int repaint_window();
@ -114,9 +114,7 @@ static void draw_it();
*/
static void
CreateGC(w, which)
MemStripChartWidget w;
unsigned int which;
CreateGC(MemStripChartWidget w, unsigned int which)
{
XGCValues myXGCV;
@ -165,9 +163,7 @@ CreateGC(w, which)
*/
static void
DestroyGC(w, which)
MemStripChartWidget w;
unsigned int which;
DestroyGC(MemStripChartWidget w, unsigned int which)
{
if (which & FOREGROUND)
XtReleaseGC((Widget) w, w->mem_strip_chart.fgGC);
@ -205,9 +201,7 @@ DestroyGC(w, which)
*/
static void
DrawMemStrip(w, x)
MemStripChartWidget w;
unsigned int x;
DrawMemStrip(MemStripChartWidget w, unsigned int x)
{
int top, bottom;
@ -260,10 +254,7 @@ DrawMemStrip(w, x)
}
/* ARGSUSED */
static void Initialize (greq, gnew, args, num_args)
Widget greq, gnew;
ArgList args;
Cardinal *num_args;
static void Initialize (Widget greq, Widget gnew, ArgList args, Cardinal *num_args)
{
MemStripChartWidget w = (MemStripChartWidget)gnew;
@ -281,8 +272,7 @@ static void Initialize (greq, gnew, args, num_args)
SetPoints(w);
}
static void Destroy (gw)
Widget gw;
static void Destroy (Widget gw)
{
MemStripChartWidget w = (MemStripChartWidget)gw;
@ -300,10 +290,7 @@ static void Destroy (gw)
*/
/* ARGSUSED */
static void Redisplay(w, event, region)
Widget w;
XEvent *event;
Region region;
static void Redisplay(Widget w, XEvent *event, Region region)
{
if (event->type == GraphicsExpose)
(void) repaint_window ((MemStripChartWidget)w, event->xgraphicsexpose.x,
@ -315,9 +302,7 @@ static void Redisplay(w, event, region)
/* ARGSUSED */
static void
draw_it(client_data, id)
XtPointer client_data;
XtIntervalId *id; /* unused */
draw_it(XtPointer client_data, XtIntervalId *id)
{
MemStripChartWidget w = (MemStripChartWidget)client_data;
MemStripChartCallbackData value;
@ -356,7 +341,8 @@ draw_it(client_data, id)
w->mem_strip_chart.valuedata[w->mem_strip_chart.interval] = value;
if (XtIsRealized((Widget)w)) {
DrawMemStrip(w, w->mem_strip_chart.interval, value);
/* XXX DrawMemStrip(w, w->mem_strip_chart.interval, value); */
DrawMemStrip(w, w->mem_strip_chart.interval);
/*
* Fill in the graph lines we just painted over.
@ -385,9 +371,7 @@ draw_it(client_data, id)
*/
static int
repaint_window(w, left, width)
MemStripChartWidget w;
int left, width;
repaint_window(MemStripChartWidget w, int left, int width)
{
int i, j;
int next = w->mem_strip_chart.interval;
@ -425,7 +409,7 @@ repaint_window(w, left, width)
/* Draw data point lines. */
for (i = left; i < width; i++) {
DrawMemStrip(w, i, w->mem_strip_chart.valuedata[i]);
DrawMemStrip(w, i);
}
/* Draw graph reference lines */
@ -445,9 +429,7 @@ repaint_window(w, left, width)
*/
static void
MoveChart(w, blit)
MemStripChartWidget w;
Boolean blit;
MoveChart(MemStripChartWidget w, Boolean blit)
{
double old_max;
int left, i, j;
@ -509,10 +491,7 @@ MoveChart(w, blit)
}
/* ARGSUSED */
static Boolean SetValues (current, request, new, args, num_args)
Widget current, request, new;
ArgList args;
Cardinal *num_args;
static Boolean SetValues (Widget current, Widget request, Widget new, ArgList args, Cardinal *num_args)
{
MemStripChartWidget old = (MemStripChartWidget)current;
MemStripChartWidget w = (MemStripChartWidget)new;
@ -583,8 +562,7 @@ static Boolean SetValues (current, request, new, args, num_args)
#define HEIGHT ( (unsigned int) w->core.height)
static void
SetPoints(widget)
Widget widget;
SetPoints(Widget widget)
{
MemStripChartWidget w = (MemStripChartWidget) widget;
XPoint * points;