9596979899100101102103104105
float sy = pos.height / h; ctx = null; gen.commentln("%FOPBeginSVG"); gen.saveGraphicsState(); final boolean clip = false; if (clip) { /* * Clip to the svg area. * Note: To have the svg overlay (under) a text area then use
121122123124125126127128129130131
//Draw using Java2D when no native fonts are available textRun.getLayout().draw(g2d); return; } gen.saveGraphicsState(); gen.concatMatrix(g2d.getTransform()); Shape imclip = g2d.getClip(); clip(ps, imclip); gen.writeln("BT"); //beginTextObject()
119120121122123124125126127128129
//Color and Font state g2d.establishColor(g2d.getColor()); establishCurrentFont(); PSGenerator gen = getPSGenerator(); gen.saveGraphicsState(); //Clip Shape imclip = g2d.getClip(); g2d.writeClip(imclip);
283284285286287288289290291292293
ctx = null; try { gen.commentln("%FOPBeginSVG"); gen.saveGraphicsState(); /* * Clip to the svg area. * Note: To have the svg overlay (under) a text area then use * an fo:block-container */
303304305306307308309310311312313
* @throws IOException if an I/O error occurs */ protected void beginTextObject() throws IOException { if (!inTextMode) { PSGenerator generator = getGenerator(); generator.saveGraphicsState(); generator.writeln("BT"); inTextMode = true; } }
6364656667686970717273
float sx = fwidth / (float)imw; float sy = fheight / (float)imh; gen.commentln("%FOPBeginGraphics2D"); gen.saveGraphicsState(); // Clip to the image area. gen.writeln("newpath"); gen.defineRect(fx, fy, fwidth, fheight); gen.writeln("clip");
287288289290291292293294295296297
ctx = null; builder = null; try { gen.commentln("%FOPBeginSVG"); gen.saveGraphicsState(); /* * Clip to the svg area. * Note: To have the svg overlay (under) a text area then use * an fo:block-container */
6263646566676869707172
118119120121122123124125126127128