[R] Missing tick marks bug on alpha solved

George White gwhite at bodnext.bio.dfo.ca
Tue Feb 16 16:52:40 CET 1999


On some systems (alpha), tick marks don't appear on plots.  The easiest
way to see the problem is something like:

> plot(0:1,axes=FALSE)
> axis(1,1:2)

The problem is in X11_Line(...) from .../src/unix/devX11.c, which is
so short I've included the whole function below:

static void X11_Line(double x1, double y1, double x2, double y2,
                     int coords, DevDesc *dd)
{
    double xx1, yy1, xx2, yy2;              <----------- should be int!
    x11Desc *xd = (x11Desc *) dd->deviceSpecific;

    /* In-place conversion ok */

    GConvert(&x1, &y1, coords, DEVICE, dd);
    GConvert(&x2, &y2, coords, DEVICE, dd);
    xx1 = (int) x1;
    yy1 = (int) y1;
    xx2 = (int) x2;
    yy2 = (int) y2;

    SetColor(dd->gp.col, dd);
    SetLinetype(dd->gp.lty, dd->gp.lwd, dd);
    XDrawLine(display, xd->window, xd->wgc, xx1, yy1, xx2, yy2);
    XSync(display, 0);
}

--
George White <aa056 at chebucto.ns.ca>  tel: 902.426.8509
  Bedford Inst. of Oceanography, Nova Scotia, Canada.

On Thu, 11 Feb 1999, Albrecht Gebhardt wrote:

> 
> On Thu, 11 Feb 1999, George White wrote:
> 
> > Can you confirm that you don't have a problem with incorrect display of
> > plots using the x11 device?  With our DU 4.0 I don't see tick marks and
> > some other lines, using a "truecolor" display (I haven't tried an 8-bit
> > display) on an OS/2 PC running XFree86.
> 
> I have the same problems. I guess it is caused by the GPretty function in
> src/main/graphics.c.
> 
> Mainly I use my Alphas for doing the number crunching, and then some
> Intel/Linux boxes to do the plots.
> 
> But anyway it should be fixed. It is clearly some error in R and not your
> error at compile time.


-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-help-request at stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._



More information about the R-help mailing list