pdfbox-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jeferson flamini <jflam...@gmail.com>
Subject difficult to copy elements of some spot color
Date Sat, 05 Jul 2014 02:58:30 GMT
Hi, i have a page that i would like to remove all elements that are not of
some colorspace. This is running well to documents with mediabox = cropbox,
but when they are different, the content of e_form is moved. I would like
to maintan elements on original position.

The code to handle e_form is the same of ElementEdit

case Element.e_form: {
   writer.writeElement(element); // write Form XObject reference to current
stream
   Obj form_obj = element.getXObject();
   if (!visited.contains((int) form_obj.getObjNum())) // if this XObject
has not been processed
   {
       // recursively process the Form XObject
       visited.add((int) form_obj.getObjNum());
       ElementWriter new_writer = new ElementWriter();
       reader.formBegin();
       new_writer.begin(form_obj);
       doIt(type, reader, new_writer);
       new_writer.end();
       reader.end();
   }


Any tip will be appreciated. Thanks in advance.

Jef

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message