fr.translate(fpt.x,fpt.y);
fr.translate(-fpt.x,-fpt.y);
    public static int getFloatDistance(Box line, List floatsList, BlockFormattingContext bfc) {		//Uu.p("---\n---\ngetting the float distance for line: " + line + " " + line.element);		//Uu.p(floatsList);		//Uu.dump_stack();		// if        if (floatsList.size() == 0) {			//Uu.p("returning nada");            return 0;        }        int xoff = 0;		// create a rectangle for the line we are attempting to adjust		Rectangle lr = new Rectangle(line.x,line.y,line.width,line.height);				// this is a hack to deal with lines w/o width or height. is this valid?		// possibly, since the line doesn't know how long it should be until it's already		// done float adjustments		if(line.width == 0) {			lr.width = 10;		}		if(line.height == 0) {			lr.height = 10;		}		//Uu.p("line rect = " + lr);		Point lpt = new Point(bfc.x, bfc.y);		//Uu.p("trans by: " + lpt);		// convert to abs coords		lr.translate(lpt.x,lpt.y);		//Uu.p("line rect = " + lr);		// josh: note. this code doesn't handle floats on the same line!		// loop through all of the floats        for (int i = 0; i < floatsList.size(); i++) {			// get the current float            Box floater = (Box) floatsList.get(i);			//Uu.p("the floater = " + floater);			// create a rect from the box			Rectangle fr = new Rectangle(floater.x,floater.y,floater.width,floater.height);			//Uu.p("float rect: " + fr);			// get the point where the float was added            Point fpt = bfc.getOffset(floater);			// get the origin of this BFC			//Uu.p("fpt = " + fpt + " lpt = " + lpt);			// convert to abs coords			fr.translate(fpt.x,fpt.y);			//Uu.p("float rect: " + fr);			// subtract the y off the line we want to shift (josh: why?)            //lpt.y -= line.y;			// if the line is lower than bottom of the floater			// josh: is this calc right? shouldn't floater.y be in there somewhere?			/*            if (lpt.y > fpt.y - floater.height) {				// then set xoff to max of last xoff and the floater's width                xoff = Math.max(xoff, floater.width);            }			*/			if(lr.intersects(fr)) {				//Uu.p("it intersects!");				lr.translate(fr.width,0);				xoff+=fr.width;				//Uu.p("new lr = " + lr);			}			//Uu.p("xoff = " + xoff);        }				//Uu.p("final val = " + xoff);        return xoff;    }