You are viewing a plain text version of this content. The canonical link for it is here.
Posted to fop-users@xmlgraphics.apache.org by "Oscar.Flores" <fa...@hotmail.com> on 2011/06/03 17:47:32 UTC

Problems with FOP and image

hi there i have another problem i hope you can help me the pdf that i create
with foe has no image, it dont show any of them, the xsl seems to be rigth i
tested with EditX and the pdf show me the image, what can it be, i have
xmlgraphics-commons-1.5svn, fop 1.0, fop-pdf-images 2.0.1 Snapshot for the
render of the image but it don work please help!!!  :,(
-- 
View this message in context: http://old.nabble.com/Problems-with-FOP-and-image-tp31766430p31766430.html
Sent from the FOP - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Problems with FOP and image

Posted by Rob Sargent <rs...@xmission.com>.
Great news!


On 06/30/2011 02:27 PM, Oscar.Flores wrote:
> Jejeje guest what it works now i update my JVM to 6.26 and my JDK to 6.26,
> NetBeans 7.0 and put the build.xml and now really add all the libraries that
> needs my program to work in the console yeeeeeeah!!! after weeks jejeje
> thanks so much Rob you have been so much helpfull!!thanks man!!  
>
> Rob Sargent-4 wrote:


---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Problems with FOP and image

Posted by "Oscar.Flores" <fa...@hotmail.com>.
Jejeje guest what it works now i update my JVM to 6.26 and my JDK to 6.26,
NetBeans 7.0 and put the build.xml and now really add all the libraries that
needs my program to work in the console yeeeeeeah!!! after weeks jejeje
thanks so much Rob you have been so much helpfull!!thanks man!!  

Rob Sargent-4 wrote:
> 
> Are netbeans and your command-line using the same installation of java?
> 
> Can you isolate you image handling code for us?
> 
> 
> 
> On 06/27/2011 03:28 PM, Oscar.Flores wrote:
>> yeah i add the imageio.jar and the clibwrap.jar that comes in the bundle
>> to
>> the classpath and put them in the jdk/jre bin and lib  like in the
>> instruction says 
>> Windows
>> The jar file must be placed in jre\lib\ext and the native library in
>> jre\bin. 
>> but still got the same issues 
>>
>>
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
> 
> 
> 

-- 
View this message in context: http://old.nabble.com/Problems-with-FOP-and-image-tp31766430p31967729.html
Sent from the FOP - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Problems with FOP and image

Posted by Rob Sargent <rs...@xmission.com>.
Are netbeans and your command-line using the same installation of java?

Can you isolate you image handling code for us?



On 06/27/2011 03:28 PM, Oscar.Flores wrote:
> yeah i add the imageio.jar and the clibwrap.jar that comes in the bundle to
> the classpath and put them in the jdk/jre bin and lib  like in the
> instruction says 
> Windows
> The jar file must be placed in jre\lib\ext and the native library in
> jre\bin. 
> but still got the same issues 
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Problems with FOP and image

Posted by "Oscar.Flores" <fa...@hotmail.com>.
yeah i add the imageio.jar and the clibwrap.jar that comes in the bundle to
the classpath and put them in the jdk/jre bin and lib  like in the
instruction says 
Windows
The jar file must be placed in jre\lib\ext and the native library in
jre\bin. 
but still got the same issues 


Rob Sargent-4 wrote:
> 
> Have you gone through this page:
> http://xmlgraphics.apache.org/commons/image-loader.html
> 
> Especially this part:
> 
> If you are loading bitmap images and you get an error like "Cannot load
> image (no suitable loader/converter combination available) for
> myimage.tif (image/tiff), you maybe be missing the necessary ImageIO
> codec to decode the image. A number of well-written codecs can be found
> in JAI Image I/O Tools Project <https://jai-imageio.dev.java.net/>. Just
> download the distribution and add the JAR to the classpath. ImageIO will
> automatically pick up the new codecs and they will subsequently be
> available to the image framework.
> 
> On 06/23/2011 03:06 PM, Oscar.Flores wrote:
>> i am sorry Pascal, the main subjet here it that something it wrong in the
>> main code of my app but i can find out what it is, and of course you have
>> been so much helpful Rob without you i cant even have a pdf generated in
>> java so and you are the only one answering my question Thanks a lot dude
>> ,
>> and i dont know if it the console or what because its still have the same
>> issues with my java app 
>>
>> org.apache.xmlgraphics.image.loader.ImageException: Cannot load image (no
>> suitable loader/converter combination available) for I:\cfd\rfc.jpg
>> (image/jpeg)
>>  *** this its not only in this image its in everyone of them bmp.jpg. etc
>>
>> y.y
>>  
>>
>> Rob Sargent-4 wrote:
>>> Hello Pascal,
>>>
>>> This entire thread relates to a single failure, at least in the sense 
>>> Oscar cannot generate the desired pdf from his command-line app. Perhaps 
>>> the recent drift to problems with his xsl are not strictly related to 
>>> "FOP and image".  I hesitate to suggest that Oscar and I take this 
>>> off-list because so far at least I haven't been much help to Oscar and 
>>> maybe others will spot the real problem or perhaps ask the right
>>> questions.
>>>
>>> Cheers,
>>> rjs
>>>
>>> Pascal Sancho wrote:
>>>> Hi Rob & Oscar,
>>>>
>>>> I'm not sure that the initial topic of this thread is still on
>>>> discussion (see Subject).
>>>> Please, if it is the case, don't hack an existing one, but open a new
>>>> thread with the right Subject, to avoid confusion for other users.
>>>>
>>>> Le 22/06/2011 18:49, Rob Sargent a écrit :
>>>>   
>>>>> It's a little tough for me to follow your xsl, but I'm suspicious of
>>>>> your loop template: It looks to me as though you are writing empty
>>>>> lines.  I don't think you can rely on the empty lines to be "the right
>>>>> size". Maybe some non-breaking white space would help?
>>>>>
>>>>> Have you found the log file? If there's a problem, there's a report.
>>>>> Turn up your logging if necessary.
>>>>>
>>>>> You might want to use the .bat file to generate the "fo" file.  This
>>>>> shows exactly what your xsl transformation generated and is the best
>>>>> bet
>>>>> at understanding any problem the fop engine is having.  The smart
>>>>> people
>>>>> on this list are more likely to look at your fo than your xsl.
>>>>>
>>>>> On 06/21/2011 01:23 PM, Oscar.Flores wrote:
>>>>>     
>>>>>> Hi there yeah its the pdf that give me the fop.bat i dont know why it
>>>>>> works
>>>>>> this way and not from my java program anyway i am using fixed
>>>>>> position
>>>>>> i
>>>>>> show you my xlst to see if you can help me to correct the size
>>>>>>
>>>>>> http://old.nabble.com/file/p31897144/FacturasOMF.xsl FacturasOMF.xsl
>>>>>>
>>>>>>
>>>>>> Rob Sargent-4 wrote:
>>>>>>       
>>>>>>> Is the pdf you posted made via the .bat file then?  And it has all
>>>>>>> the
>>>>>>> images you need? Which image is giving you all the trouble?
>>>>>>>
>>>>>>> I see that you are incorrectly sizing the area into which you are
>>>>>>> putting the address of the client. Alternatively you have placed the
>>>>>>> table of items too high.  Are you using fixed positions?
>>>>>>> Those to pieces (client-address and invoice-items) should be in
>>>>>>> consecutive blocks.
>>>>>>> On 06/17/2011 09:52 AM, Oscar.Flores wrote:
>>>>>>>         
>>>>>>>> No i still can print the images in pdf in console what i do for now
>>>>>>>> is
>>>>>>>> call a
>>>>>>>> bat to make the transformation with fo until i figure out what the
>>>>>>>> problem
>>>>>>>> is in log appear that can find a proper converter for the images
>>>>>>>>
>>>>>>>>
>>>>>>>> also another problem its that the table its to big it dont fit to
>>>>>>>> the
>>>>>>>> data
>>>>>>>> here its the pdf that result
>>>>>>>> http://old.nabble.com/file/p31870136/Prueba3.pdf Prueba3.pdf
>>>>>>>>
>>>>>>>>   Warning(1979/26): fo:table, table-layout="auto" is currently not
>>>>>>>> supported
>>>>>>>>           
>>>>>>>>> by FOP
>>>>>>>>> but in my xslt it ike this<fo:table table-layout="fixed"
>>>>>>>>> width="100%">
>>>>>>>>>             
>>>>>>>> the version of fop i use its 1.0
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>           
>>>>>>>>> I don't think you want to read and write to the same place. If the
>>>>>>>>> file
>>>>>>>>> is where you want it to be and it's otherwise in perfect shape you
>>>>>>>>> should be fine.  But if you do want to read it in and write it to
>>>>>>>>> some
>>>>>>>>> deployed area the that's what you want to do. Almost:
>>>>>>>>>       ImageIO.write(*newImage*, "JPEG", jpegImageFile);
>>>>>>>>>
>>>>>>>>> So without adding the ImageIO.write() call, are you getting the
>>>>>>>>> pdf
>>>>>>>>> you
>>>>>>>>> want yet?
>>>>>>>>> If not, what actual errors are you seeing in the logs.
>>>>>>>>>
>>>>>>>>> The warning about fo:table is not causing you any trouble.  What
>>>>>>>>> version
>>>>>>>>> of fop are you running (sorry I've forgotten)
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> On 06/15/2011 02:51 PM, Oscar.Flores wrote:
>>>>>>>>>             
>>>>>>>>>> Hi thanks for the help yeah i haven see that its was .java and
>>>>>>>>>> not
>>>>>>>>>> .class, ok
>>>>>>>>>> then if i follow correctly what you are saying then it has to be
>>>>>>>>>> something
>>>>>>>>>> like this
>>>>>>>>>>
>>>>>>>>>> BufferedImage newImage = new BufferedImage ("C:\Logo.jpg")
>>>>>>>>>> ImageIO.write(BufferedImage, "JPEG", jpegImageFile) jpegImageFile
>>>>>>>>>> will
>>>>>>>>>> be
>>>>>>>>>> the XML call rigth something like "C:\Logo.jpg")
>>>>>>>>>>
>>>>>>>>>> and another thing
>>>>>>>>>>
>>>>>>>>>>     Warning(1979/26): fo:table, table-layout="auto" is currently
>>>>>>>>>> not
>>>>>>>>>> supported
>>>>>>>>>> by FOP
>>>>>>>>>> but in my xslt it ike this<fo:table table-layout="fixed"
>>>>>>>>>> width="100%">
>>>>>>>>>> so
>>>>>>>>>> i dont now what its causing the ploblem
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>               
>>>>>>>>>>> On 06/14/2011 11:06 AM, Oscar.Flores wrote:
>>>>>>>>>>>                 
>>>>>>>>>>>> Yeah i do the class is in jai-imageio-1.1-sources.jar, the
>>>>>>>>>>>> enviroment
>>>>>>>>>>>> is
>>>>>>>>>>>> just
>>>>>>>>>>>>                   
>>>>>>>>>>> Having the file in the "...sources.jar" won't do the runtime
>>>>>>>>>>> world
>>>>>>>>>>> much
>>>>>>>>>>> good. You need the jar of .class files for jai-imageio, not
>>>>>>>>>>> .java
>>>>>>>>>>> files
>>>>>>>>>>>                 
>>>>>>>>>>>> windows xp, and the bufferedImage will be the path of the
>>>>>>>>>>>> image??
>>>>>>>>>>>>                   
>>>>>>>>>>> No, the bufferedImage is an in-memory instance of BufferedImage
>>>>>>>>>>> holding
>>>>>>>>>>> the bits of the image.  In the case that you have to read it
>>>>>>>>>>> from
>>>>>>>>>>> one
>>>>>>>>>>> place and write it to another.
>>>>>>>>>>>                 
>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>                   
>>>>>>>>>>>>> Did you go through all your jars looking for
>>>>>>>>>>>>> 'CLibJPEGImageReaderSpi'.
>>>>>>>>>>>>> My greatest suspicion is that you don't have all your jars
>>>>>>>>>>>>> lined
>>>>>>>>>>>>> up.
>>>>>>>>>>>>> Which jar(s) do you think supplies these?
>>>>>>>>>>>>>
>>>>>>>>>>>>> What is your environment: just windows or do you have any
>>>>>>>>>>>>> tools
>>>>>>>>>>>>> like
>>>>>>>>>>>>> cygwin?
>>>>>>>>>>>>>
>>>>>>>>>>>>> The "jpegImageFile" would be the filename in your xsl the
>>>>>>>>>>>>> external-resource.  If you're just using a file that is
>>>>>>>>>>>>> already
>>>>>>>>>>>>> in
>>>>>>>>>>>>> place
>>>>>>>>>>>>> you don't have to re-write it.
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> On 06/14/2011 08:29 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>                     
>>>>>>>>>>>>>> No i dont, and that weird jejeje netbeans seems to do that
>>>>>>>>>>>>>> for
>>>>>>>>>>>>>> me,
>>>>>>>>>>>>>> so
>>>>>>>>>>>>>> the
>>>>>>>>>>>>>> calls like ImageIO.write(BufferedImage, "JPEG",
>>>>>>>>>>>>>> jpegImageFile)?
>>>>>>>>>>>>>> do
>>>>>>>>>>>>>> i
>>>>>>>>>>>>>> have
>>>>>>>>>>>>>> to
>>>>>>>>>>>>>> do it in every image that i put in the pdf?? and the image is
>>>>>>>>>>>>>> gererate
>>>>>>>>>>>>>> directly in the pdf??how can i do it??
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>                       
>>>>>>>>>>>>>>> Some jar to which netbeans has access has those classes. 
>>>>>>>>>>>>>>> Look
>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>> output of jar tvf<each of your jars>     and see if any of
>>>>>>>>>>>>>>> those
>>>>>>>>>>>>>>> has
>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>> named classes.  If you find a jar with those classes make
>>>>>>>>>>>>>>> sure
>>>>>>>>>>>>>>> it's
>>>>>>>>>>>>>>> part
>>>>>>>>>>>>>>> of your classpath for you app.
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> Are you making any calls like ImageIO.write(BufferedImage,
>>>>>>>>>>>>>>> "JPEG",
>>>>>>>>>>>>>>> jpegImageFile)?
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> On 06/13/2011 05:31 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>                         
>>>>>>>>>>>>>>>> ok i made a test and tell me that the class is missign but
>>>>>>>>>>>>>>>> maybe
>>>>>>>>>>>>>>>> what
>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>> say
>>>>>>>>>>>>>>>> its rigth and it register the handler
>>>>>>>>>>>>>>>> so i gonna register the services so i do this
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>       public static void main(String[] args) throws
>>>>>>>>>>>>>>>> Exception
>>>>>>>>>>>>>>>> {
>>>>>>>>>>>>>>>>               DOMConfigurator.configure("D:/Mis
>>>>>>>>>>>>>>>> documentos/NetBeansProjects/Factura/src/factura/log4j.xml");
>>>>>>>>>>>>>>>>               logger.info("Entering application.");
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>>>>> CLibJPEGImageReaderSpi());
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>>>>> CLibJPEGImageWriterSpi());
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> also after register my services it telling me that the
>>>>>>>>>>>>>>>> class
>>>>>>>>>>>>>>>> CLibJPEGImageReaderSpi() and CLibJPEGImageWriterSpi() is
>>>>>>>>>>>>>>>> missing
>>>>>>>>>>>>>>>> but
>>>>>>>>>>>>>>>> only
>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>> command
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> after register mi service, something more has to be done??
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>                           
>>>>>>>>>>>>>>>>> I'm not sure I'm following correctly: does removing the
>>>>>>>>>>>>>>>>> xmlgraphics
>>>>>>>>>>>>>>>>> jar
>>>>>>>>>>>>>>>>> cause netbeans to behave the same as the command-line run
>>>>>>>>>>>>>>>>> of
>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>> app?
>>>>>>>>>>>>>>>>> If
>>>>>>>>>>>>>>>>> so, I suspect netbeans is registering services for you. 
>>>>>>>>>>>>>>>>> Your
>>>>>>>>>>>>>>>>> own
>>>>>>>>>>>>>>>>> code
>>>>>>>>>>>>>>>>> will have to make a call to one of the
>>>>>>>>>>>>>>>>> IIORegistry.registerServiceProvider() methods.
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> On 06/13/2011 05:02 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>                             
>>>>>>>>>>>>>>>>>> Ok aaaa i get it, actually the ImageIO library i added
>>>>>>>>>>>>>>>>>> because
>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>> read
>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>> xmlgrapics that if something like the message
>>>>>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException:
>>>>>>>>>>>>>>>>>> Cannot
>>>>>>>>>>>>>>>>>> load
>>>>>>>>>>>>>>>>>> image
>>>>>>>>>>>>>>>>>> (no
>>>>>>>>>>>>>>>>>> suitable loader/converter combination available)appear i
>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>> add
>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>> jar
>>>>>>>>>>>>>>>>>> file to the classpath but that all it say no
>>>>>>>>>>>>>>>>>> configuration
>>>>>>>>>>>>>>>>>> or
>>>>>>>>>>>>>>>>>> anything,
>>>>>>>>>>>>>>>>>> then
>>>>>>>>>>>>>>>>>> i delete the imagenIO libs and still i have the same
>>>>>>>>>>>>>>>>>> output
>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>> netbeans
>>>>>>>>>>>>>>>>>> so
>>>>>>>>>>>>>>>>>> xmlgrapics seem to have the problem in the plugins or i
>>>>>>>>>>>>>>>>>> have to
>>>>>>>>>>>>>>>>>> configure
>>>>>>>>>>>>>>>>>> something
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>                               
>>>>>>>>>>>>>>>>>>> Then it seems to me netbeans (if it's producing good
>>>>>>>>>>>>>>>>>>> output ==
>>>>>>>>>>>>>>>>>>> assumptionA) is still using something that the
>>>>>>>>>>>>>>>>>>> command-line
>>>>>>>>>>>>>>>>>>> isn't.
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> And given assumptionA, you're java code is correct in
>>>>>>>>>>>>>>>>>>> terms of
>>>>>>>>>>>>>>>>>>> FOP
>>>>>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>>>>>> your configuration isn't for ImageIO.  Show your ImageIO
>>>>>>>>>>>>>>>>>>> related
>>>>>>>>>>>>>>>>>>> code
>>>>>>>>>>>>>>>>>>> and are you sure it's in your app.  Use the logger to
>>>>>>>>>>>>>>>>>>> show
>>>>>>>>>>>>>>>>>>> a
>>>>>>>>>>>>>>>>>>> message
>>>>>>>>>>>>>>>>>>> when you add  your loader.  Or list all ImageIO
>>>>>>>>>>>>>>>>>>> services:
>>>>>>>>>>>>>>>>>>> IIORegistry.getServiceProviders()
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> On 06/13/2011 03:01 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>                                 
>>>>>>>>>>>>>>>>>>>> ok well i put the xml in scr of my proyect i see that i
>>>>>>>>>>>>>>>>>>>> still
>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>> same
>>>>>>>>>>>>>>>>>>>> issues of the image render of any image i dont now if
>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>> xml
>>>>>>>>>>>>>>>>>>>> its
>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>> place i
>>>>>>>>>>>>>>>>>>>> put the code down to see if something its missing
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> 15:45:07,827 ERROR [render] Error while processing
>>>>>>>>>>>>>>>>>>>> image:
>>>>>>>>>>>>>>>>>>>> c:\cfd\nombregp.bmp (i
>>>>>>>>>>>>>>>>>>>> mage/bmp)
>>>>>>>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException:
>>>>>>>>>>>>>>>>>>>> Cannot
>>>>>>>>>>>>>>>>>>>> load
>>>>>>>>>>>>>>>>>>>> image
>>>>>>>>>>>>>>>>>>>> (no
>>>>>>>>>>>>>>>>>>>> suitab
>>>>>>>>>>>>>>>>>>>> le loader/converter combination available) for
>>>>>>>>>>>>>>>>>>>> c:\cfd\nombregp.bmp
>>>>>>>>>>>>>>>>>>>> (image/bmp)
>>>>>>>>>>>>>>>>>>>>                at
>>>>>>>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageManager.getImage(ImageManage
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> import mx.bigdata.sat.cfd.schema.Comprobante;
>>>>>>>>>>>>>>>>>>>> import mx.bigdata.sat.cfd.CFDv2;
>>>>>>>>>>>>>>>>>>>> import mx.bigdata.sat.security.KeyLoader;
>>>>>>>>>>>>>>>>>>>> import org.jdom.*;
>>>>>>>>>>>>>>>>>>>> import org.jdom.input.SAXBuilder;
>>>>>>>>>>>>>>>>>>>> import org.jdom.output.XMLOutputter;
>>>>>>>>>>>>>>>>>>>> import org.jdom.output.Format;
>>>>>>>>>>>>>>>>>>>> import org.jdom.transform.JDOMSource;
>>>>>>>>>>>>>>>>>>>> //Java
>>>>>>>>>>>>>>>>>>>>         import java.io.File;
>>>>>>>>>>>>>>>>>>>>         import java.io.OutputStream;
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>         //JAXP
>>>>>>>>>>>>>>>>>>>>         import javax.xml.transform.Transformer;
>>>>>>>>>>>>>>>>>>>>         import javax.xml.transform.TransformerFactory;
>>>>>>>>>>>>>>>>>>>>         import javax.xml.transform.Source;
>>>>>>>>>>>>>>>>>>>>         import javax.xml.transform.Result;
>>>>>>>>>>>>>>>>>>>>         import javax.xml.transform.stream.StreamSource;
>>>>>>>>>>>>>>>>>>>>         import javax.xml.transform.sax.SAXResult;
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>         //FOP
>>>>>>>>>>>>>>>>>>>>         import org.apache.fop.apps.FOUserAgent;
>>>>>>>>>>>>>>>>>>>>         import org.apache.fop.apps.Fop;
>>>>>>>>>>>>>>>>>>>>         import org.apache.fop.apps.FopFactory;
>>>>>>>>>>>>>>>>>>>>         import org.apache.fop.apps.MimeConstants;
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>         //log4j
>>>>>>>>>>>>>>>>>>>>         import org.apache.log4j.*;
>>>>>>>>>>>>>>>>>>>>         import org.apache.log4j.xml.DOMConfigurator;
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> public final class Main {
>>>>>>>>>>>>>>>>>>>>            @SuppressWarnings("unchecked")
>>>>>>>>>>>>>>>>>>>>            static Logger logger =
>>>>>>>>>>>>>>>>>>>> Logger.getLogger(Main.class);
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>            public static void main(String[] args)
>>>>>>>>>>>>>>>>>>>> throws
>>>>>>>>>>>>>>>>>>>> Exception
>>>>>>>>>>>>>>>>>>>> {
>>>>>>>>>>>>>>>>>>>>                 DOMConfigurator.configure("D:/Mis
>>>>>>>>>>>>>>>>>>>> documentos/NetBeansProjects/Factura/src/factura/log4j.xml");
>>>>>>>>>>>>>>>>>>>>                 logger.info("Entering application.");
>>>>>>>>>>>>>>>>>>>>                 try {
>>>>>>>>>>>>>>>>>>>>                    File file = new File(args[0]);
>>>>>>>>>>>>>>>>>>>>                    Comprobante comp =
>>>>>>>>>>>>>>>>>>>> CFDv2.newComprobante(new
>>>>>>>>>>>>>>>>>>>> FileInputStream(file));
>>>>>>>>>>>>>>>>>>>>                    CFDv2 cfd = new CFDv2(comp);
>>>>>>>>>>>>>>>>>>>>                    PrivateKey key =
>>>>>>>>>>>>>>>>>>>> KeyLoader.loadPKCS8PrivateKey(new
>>>>>>>>>>>>>>>>>>>> FileInputStream(args[1]),(args[2]));
>>>>>>>>>>>>>>>>>>>>                    X509Certificate cert =
>>>>>>>>>>>>>>>>>>>> KeyLoader.loadX509Certificate(new
>>>>>>>>>>>>>>>>>>>> FileInputStream(args[3]));
>>>>>>>>>>>>>>>>>>>>                    Comprobante sellado =
>>>>>>>>>>>>>>>>>>>> cfd.sellarComprobante(key,
>>>>>>>>>>>>>>>>>>>> cert);
>>>>>>>>>>>>>>>>>>>>                    String cadena =
>>>>>>>>>>>>>>>>>>>> cfd.getCadenaOriginal();
>>>>>>>>>>>>>>>>>>>>                    String sello = sellado.getSello();
>>>>>>>>>>>>>>>>>>>>                    // Creamos el builder basado en SAX
>>>>>>>>>>>>>>>>>>>>                    SAXBuilder builder = new
>>>>>>>>>>>>>>>>>>>> SAXBuilder();
>>>>>>>>>>>>>>>>>>>>                    // Construimos el arbol DOM a partir
>>>>>>>>>>>>>>>>>>>> del
>>>>>>>>>>>>>>>>>>>> fichero
>>>>>>>>>>>>>>>>>>>> xml
>>>>>>>>>>>>>>>>>>>>                    Document documentJDOM =
>>>>>>>>>>>>>>>>>>>> builder.build(new
>>>>>>>>>>>>>>>>>>>> FileInputStream(args[0]));
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>                    Element raiz =
>>>>>>>>>>>>>>>>>>>> documentJDOM.getRootElement();//toma
>>>>>>>>>>>>>>>>>>>> el
>>>>>>>>>>>>>>>>>>>> nodo
>>>>>>>>>>>>>>>>>>>> raiz
>>>>>>>>>>>>>>>>>>>> del documento.
>>>>>>>>>>>>>>>>>>>>                    raiz.setAttribute("sello", sello);
>>>>>>>>>>>>>>>>>>>>                    raiz.setAttribute("certificado",
>>>>>>>>>>>>>>>>>>>> sellado.getCertificado());
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> //System.out.println(raiz.getAttributeValue("sello"));
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> //System.out.println(raiz.getAttributeValue("certificado"));
>>>>>>>>>>>>>>>>>>>>                    // Recorremos los hijos de la
>>>>>>>>>>>>>>>>>>>> etiqueta
>>>>>>>>>>>>>>>>>>>> raíz
>>>>>>>>>>>>>>>>>>>>                    List<Element>        hijosRaiz =
>>>>>>>>>>>>>>>>>>>> raiz.getChildren();
>>>>>>>>>>>>>>>>>>>>                    boolean Bandera=false;
>>>>>>>>>>>>>>>>>>>>                    for(Element hijo: hijosRaiz)
>>>>>>>>>>>>>>>>>>>>                    {
>>>>>>>>>>>>>>>>>>>>                        // Obtenemos el nombre y su
>>>>>>>>>>>>>>>>>>>> contenido
>>>>>>>>>>>>>>>>>>>> de
>>>>>>>>>>>>>>>>>>>> tipo
>>>>>>>>>>>>>>>>>>>> texto
>>>>>>>>>>>>>>>>>>>>                        String nombre = hijo.getName();
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>                        if (nombre.equals("Addenda"))
>>>>>>>>>>>>>>>>>>>>                        {   List<Element>        subHijo
>>>>>>>>>>>>>>>>>>>> =
>>>>>>>>>>>>>>>>>>>> hijo.getChildren();
>>>>>>>>>>>>>>>>>>>>                            for(Element hij: subHijo)
>>>>>>>>>>>>>>>>>>>>                                {
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> hij.setAttribute("CadenaOriginal",
>>>>>>>>>>>>>>>>>>>> cadena);
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> //System.out.println("CadenaOriginal:
>>>>>>>>>>>>>>>>>>>> "+hij.getAttributeValue("CadenaOriginal"));
>>>>>>>>>>>>>>>>>>>>                                Bandera=true;
>>>>>>>>>>>>>>>>>>>>                                break;
>>>>>>>>>>>>>>>>>>>>                                }
>>>>>>>>>>>>>>>>>>>>                        }
>>>>>>>>>>>>>>>>>>>>                        if (Bandera)
>>>>>>>>>>>>>>>>>>>>                        {
>>>>>>>>>>>>>>>>>>>>                            XMLOutputter out = new
>>>>>>>>>>>>>>>>>>>> XMLOutputter(Format.getPrettyFormat());
>>>>>>>>>>>>>>>>>>>>                            File nuevoXML = new
>>>>>>>>>>>>>>>>>>>> File(args[0]);
>>>>>>>>>>>>>>>>>>>>                            try{
>>>>>>>>>>>>>>>>>>>>                                FileOutputStream
>>>>>>>>>>>>>>>>>>>> archivoXML=
>>>>>>>>>>>>>>>>>>>> new
>>>>>>>>>>>>>>>>>>>> FileOutputStream
>>>>>>>>>>>>>>>>>>>> (nuevoXML);
>>>>>>>>>>>>>>>>>>>>                                out.output(documentJDOM,
>>>>>>>>>>>>>>>>>>>> archivoXML);
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>                               }
>>>>>>>>>>>>>>>>>>>>                            catch (Exception
>>>>>>>>>>>>>>>>>>>> ex){System.out.println(ex.getMessage());}
>>>>>>>>>>>>>>>>>>>>                            // Para generar el pdf a
>>>>>>>>>>>>>>>>>>>> partir de
>>>>>>>>>>>>>>>>>>>> un
>>>>>>>>>>>>>>>>>>>> archivo.xsl
>>>>>>>>>>>>>>>>>>>> y
>>>>>>>>>>>>>>>>>>>> un
>>>>>>>>>>>>>>>>>>>>                            // archivo.xml
>>>>>>>>>>>>>>>>>>>>                        }
>>>>>>>>>>>>>>>>>>>>                      }
>>>>>>>>>>>>>>>>>>>>                  // configure fopFactory as desired
>>>>>>>>>>>>>>>>>>>>                  FopFactory fopFactory =
>>>>>>>>>>>>>>>>>>>> FopFactory.newInstance();
>>>>>>>>>>>>>>>>>>>>                  FOUserAgent foUserAgent =
>>>>>>>>>>>>>>>>>>>> fopFactory.newFOUserAgent();
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>                  // configure foUserAgent as desired
>>>>>>>>>>>>>>>>>>>>                  // Setup output
>>>>>>>>>>>>>>>>>>>>                 File pdffile = new File(args[5]);
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>                 OutputStream out = new
>>>>>>>>>>>>>>>>>>>> java.io.FileOutputStream(pdffile);
>>>>>>>>>>>>>>>>>>>>                 out = new
>>>>>>>>>>>>>>>>>>>> java.io.BufferedOutputStream(out);
>>>>>>>>>>>>>>>>>>>>                 try {
>>>>>>>>>>>>>>>>>>>>                        // Construct fop with desired
>>>>>>>>>>>>>>>>>>>> output
>>>>>>>>>>>>>>>>>>>> format
>>>>>>>>>>>>>>>>>>>>                         Fop fop =
>>>>>>>>>>>>>>>>>>>> fopFactory.newFop(MimeConstants.MIME_PDF,
>>>>>>>>>>>>>>>>>>>> foUserAgent, out);
>>>>>>>>>>>>>>>>>>>>                        // Setup XSLT
>>>>>>>>>>>>>>>>>>>>                        TransformerFactory factory =
>>>>>>>>>>>>>>>>>>>> TransformerFactory.newInstance();
>>>>>>>>>>>>>>>>>>>>                        Transformer transformer =
>>>>>>>>>>>>>>>>>>>> factory.newTransformer(new
>>>>>>>>>>>>>>>>>>>> StreamSource(args[4]));
>>>>>>>>>>>>>>>>>>>>                        // Set the value of a  in the
>>>>>>>>>>>>>>>>>>>> stylesheet
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> transformer.setParameter("versionParam",
>>>>>>>>>>>>>>>>>>>> "2.0");
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>                       // Setup input for XSLT
>>>>>>>>>>>>>>>>>>>> transformation
>>>>>>>>>>>>>>>>>>>>                        Source src = new
>>>>>>>>>>>>>>>>>>>> JDOMSource(documentJDOM);
>>>>>>>>>>>>>>>>>>>>                         // Resulting SAX events (the
>>>>>>>>>>>>>>>>>>>> generated
>>>>>>>>>>>>>>>>>>>> FO)
>>>>>>>>>>>>>>>>>>>> must
>>>>>>>>>>>>>>>>>>>> be
>>>>>>>>>>>>>>>>>>>> piped
>>>>>>>>>>>>>>>>>>>> through to FOP
>>>>>>>>>>>>>>>>>>>>                        Result res = new
>>>>>>>>>>>>>>>>>>>> SAXResult(fop.getDefaultHandler());
>>>>>>>>>>>>>>>>>>>>                         // Start XSLT transformation
>>>>>>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>>>>>>> FOP
>>>>>>>>>>>>>>>>>>>> processing
>>>>>>>>>>>>>>>>>>>>                       //
>>>>>>>>>>>>>>>>>>>> System.setProperty("java.awt.headless",
>>>>>>>>>>>>>>>>>>>> "true");
>>>>>>>>>>>>>>>>>>>>                            transformer.transform(src,
>>>>>>>>>>>>>>>>>>>> res);
>>>>>>>>>>>>>>>>>>>>                        } finally {
>>>>>>>>>>>>>>>>>>>>                         out.close();
>>>>>>>>>>>>>>>>>>>>                    }
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>                  System.out.println("Success!");
>>>>>>>>>>>>>>>>>>>>                 } catch (Exception e) {
>>>>>>>>>>>>>>>>>>>>                  e.printStackTrace(System.err);
>>>>>>>>>>>>>>>>>>>>                  System.exit(-1);
>>>>>>>>>>>>>>>>>>>>               }
>>>>>>>>>>>>>>>>>>>>             logger.info("Exiting application.");
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>          }
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>                                   
>>>>>>>>>>>>>>>>>>>>> Try this log4j.xml: Place it at the root of your jar
>>>>>>>>>>>>>>>>>>>>> file
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> <?xml version="1.0" encoding="UTF-8"?>
>>>>>>>>>>>>>>>>>>>>> <!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> <log4j:configuration
>>>>>>>>>>>>>>>>>>>>> xmlns:log4j="http://jakarta.apache.org/log4j/"
>>>>>>>>>>>>>>>>>>>>> debug="false">
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> <appender name="CONSOLE"
>>>>>>>>>>>>>>>>>>>>> class="org.apache.log4j.ConsoleAppender">
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> <layout class="org.apache.log4j.PatternLayout">
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> </layout>
>>>>>>>>>>>>>>>>>>>>> </appender>
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> <category name="org">
>>>>>>>>>>>>>>>>>>>>> <priority value="DEBUG"/>
>>>>>>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>>>>>>> <category name="org.apache">
>>>>>>>>>>>>>>>>>>>>> <priority value="WARN"/>
>>>>>>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>>>>>>> <category name="org.springframework">
>>>>>>>>>>>>>>>>>>>>> <priority value="WARN"/>
>>>>>>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>>>>>>> <category name="org.hibernate">
>>>>>>>>>>>>>>>>>>>>> <priority value="DEBUG"/>
>>>>>>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>>>>>>> <category name="net">
>>>>>>>>>>>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>>>>>>> <category name="javax">
>>>>>>>>>>>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>>>>>>> <category name="java">
>>>>>>>>>>>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>>>>>>> <category name="sun">
>>>>>>>>>>>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>>>>>>> <category name="org.jboss">
>>>>>>>>>>>>>>>>>>>>> <priority value="INFO"/>
>>>>>>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>>>>>>> <category name="org.jboss.seam">
>>>>>>>>>>>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>>>>>>> <root>
>>>>>>>>>>>>>>>>>>>>> <appender-ref ref="CONSOLE"/>
>>>>>>>>>>>>>>>>>>>>> </root>
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> </log4j:configuration>
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> On 06/13/2011 11:06 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>                                     
>>>>>>>>>>>>>>>>>>>>>> ok i dont thik i have a configuracion file i find the
>>>>>>>>>>>>>>>>>>>>>> code
>>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>> put
>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>> other post i think its the basic
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>                                       
>>>>>>>>>>>>>>>>>>>>>>> Do you have a config file for log4j.  Usually it's
>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>> a
>>>>>>>>>>>>>>>>>>>>>>> resource
>>>>>>>>>>>>>>>>>>>>>>> tree.
>>>>>>>>>>>>>>>>>>>>>>> Are you copying that to your deployment? Is your ant
>>>>>>>>>>>>>>>>>>>>>>> script
>>>>>>>>>>>>>>>>>>>>>>> including
>>>>>>>>>>>>>>>>>>>>>>> the config file in the jar of your application?
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> On 06/13/2011 10:12 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>                                         
>>>>>>>>>>>>>>>>>>>>>>>> Ok yeah the log4j its having isuees to find the
>>>>>>>>>>>>>>>>>>>>>>>> configuration
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> log4j:WARN No appenders could be found for logger
>>>>>>>>>>>>>>>>>>>>>>>> (org.apache.fop.util.ContentHandlerFactoryRegistry).
>>>>>>>>>>>>>>>>>>>>>>>> log4j:WARN Please initialize the log4j system
>>>>>>>>>>>>>>>>>>>>>>>> properly.
>>>>>>>>>>>>>>>>>>>>>>>> log4j:WARN See
>>>>>>>>>>>>>>>>>>>>>>>> http://logging.apache.org/log4j/1.2/faq.html#noconfig
>>>>>>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>>>>>>> more info.
>>>>>>>>>>>>>>>>>>>>>>>> i go to the faq guide and it say try loading the
>>>>>>>>>>>>>>>>>>>>>>>> class or
>>>>>>>>>>>>>>>>>>>>>>>> resource
>>>>>>>>>>>>>>>>>>>>>>>> yourself.
>>>>>>>>>>>>>>>>>>>>>>>> If you can't find it, neither will log4j.
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> aaa i dont know where to set this
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> also here its my xlst
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> http://old.nabble.com/file/p31835645/FacturasOMF.xsl
>>>>>>>>>>>>>>>>>>>>>>>> FacturasOMF.xsl
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> and the fo file that generate the editix
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> http://old.nabble.com/file/p31835645/Prueba.fo
>>>>>>>>>>>>>>>>>>>>>>>> Prueba.fo
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>                                           
>>>>>>>>>>>>>>>>>>>>>>>>> The first thing is to really dig into what you did
>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>> netbeans
>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>> get
>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>> to work...
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> I've forgotten what your stylesheet looked like,
>>>>>>>>>>>>>>>>>>>>>>>>> so
>>>>>>>>>>>>>>>>>>>>>>>>> maybe
>>>>>>>>>>>>>>>>>>>>>>>>> if
>>>>>>>>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>>>>>>>>> show
>>>>>>>>>>>>>>>>>>>>>>>>> us
>>>>>>>>>>>>>>>>>>>>>>>>> again how you're referencing your images we might
>>>>>>>>>>>>>>>>>>>>>>>>> notice
>>>>>>>>>>>>>>>>>>>>>>>>> a
>>>>>>>>>>>>>>>>>>>>>>>>> problem.
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> It might also help to see the "fo" generated
>>>>>>>>>>>>>>>>>>>>>>>>> during
>>>>>>>>>>>>>>>>>>>>>>>>> your
>>>>>>>>>>>>>>>>>>>>>>>>> transformation.
>>>>>>>>>>>>>>>>>>>>>>>>> Can you grab that just after xslt and just before
>>>>>>>>>>>>>>>>>>>>>>>>> fop
>>>>>>>>>>>>>>>>>>>>>>>>> calls.
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> Are you sure there is no error being logged
>>>>>>>>>>>>>>>>>>>>>>>>> somewhere
>>>>>>>>>>>>>>>>>>>>>>>>> when
>>>>>>>>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>>>>>>>>> run
>>>>>>>>>>>>>>>>>>>>>>>>> from
>>>>>>>>>>>>>>>>>>>>>>>>> the command line? (Where is log4j writing and at
>>>>>>>>>>>>>>>>>>>>>>>>> what
>>>>>>>>>>>>>>>>>>>>>>>>> level?)
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>                                             
>>>>>>>>>>>>>>>>>>>>>>>>>> You where absolutly rigth i miss a few libraries
>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>> add
>>>>>>>>>>>>>>>>>>>>>>>>>> into
>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>> jar
>>>>>>>>>>>>>>>>>>>>>>>>>> file, i
>>>>>>>>>>>>>>>>>>>>>>>>>> modified the build.xml to add the package and jar
>>>>>>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>> need,
>>>>>>>>>>>>>>>>>>>>>>>>>> now
>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>> error
>>>>>>>>>>>>>>>>>>>>>>>>>> message is not there but still the images dont
>>>>>>>>>>>>>>>>>>>>>>>>>> show
>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>> remeber
>>>>>>>>>>>>>>>>>>>>>>>>>> that i do something in netbeans so they can add
>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>>>>>>>>>> but
>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>> cant
>>>>>>>>>>>>>>>>>>>>>>>>>> remeber i dont now if there is still a library
>>>>>>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>>>>>>>>>> missing
>>>>>>>>>>>>>>>>>>>>>>>>>> or
>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>> am
>>>>>>>>>>>>>>>>>>>>>>>>>> adding more than it should be
>>>>>>>>>>>>>>>>>>>>>>>>>> This is what i use :
>>>>>>>>>>>>>>>>>>>>>>>>>> cfdi-base-0.1.6-SNAPSHOT.jar
>>>>>>>>>>>>>>>>>>>>>>>>>> guava-r09.jar
>>>>>>>>>>>>>>>>>>>>>>>>>> guava-r09-gwt.jar
>>>>>>>>>>>>>>>>>>>>>>>>>> jaxb-impl-2.1.10.jar
>>>>>>>>>>>>>>>>>>>>>>>>>> avalon-framework-api-4.3.jar
>>>>>>>>>>>>>>>>>>>>>>>>>> avalon-framework-cvs-20020806.jar
>>>>>>>>>>>>>>>>>>>>>>>>>> avalon-logkit-2.1.jar
>>>>>>>>>>>>>>>>>>>>>>>>>> not-yet-commons-ssl-0.3.11.jar
>>>>>>>>>>>>>>>>>>>>>>>>>> commons-codec-1.5.jar
>>>>>>>>>>>>>>>>>>>>>>>>>> commons-codec-1.5-sources.jar
>>>>>>>>>>>>>>>>>>>>>>>>>> log4j-1.2.16.jar
>>>>>>>>>>>>>>>>>>>>>>>>>> fop.jar
>>>>>>>>>>>>>>>>>>>>>>>>>> jdom.jar
>>>>>>>>>>>>>>>>>>>>>>>>>> xmlgraphics-commons-1.4.jar
>>>>>>>>>>>>>>>>>>>>>>>>>> commons-io-1.3.1.jar
>>>>>>>>>>>>>>>>>>>>>>>>>> fop-pdf-images-2.0.1.SNAPSHOT.jar
>>>>>>>>>>>>>>>>>>>>>>>>>> pdfbox-app-1.5.0.jar
>>>>>>>>>>>>>>>>>>>>>>>>>> fontbox-1.3.1.jar
>>>>>>>>>>>>>>>>>>>>>>>>>> jempbox-1.3.1.jar
>>>>>>>>>>>>>>>>>>>>>>>>>> xercesImpl-2.7.1.jar
>>>>>>>>>>>>>>>>>>>>>>>>>> batik-all-1.7.jar
>>>>>>>>>>>>>>>>>>>>>>>>>> xml-apis-1.3.04.jar
>>>>>>>>>>>>>>>>>>>>>>>>>> xml-apis-ext-1.3.04.jar
>>>>>>>>>>>>>>>>>>>>>>>>>>           avalon-framework-4.2.0.jar
>>>>>>>>>>>>>>>>>>>>>>>>>>           xalan-2.7.0.jar
>>>>>>>>>>>>>>>>>>>>>>>>>>           serializer-2.7.0.jar
>>>>>>>>>>>>>>>>>>>>>>>>>>           commons-logging-1.0.4.jar
>>>>>>>>>>>>>>>>>>>>>>>>>>           jai_codec.jar
>>>>>>>>>>>>>>>>>>>>>>>>>>           jai_core.jar
>>>>>>>>>>>>>>>>>>>>>>>>>>           batik-ext.jar
>>>>>>>>>>>>>>>>>>>>>>>>>>           jai_imageio-1.1-sources.jar
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> Thanks Rob for the help
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>                                               
>>>>>>>>>>>>>>>>>>>>>>>>>>> I suspect running from your jar does not
>>>>>>>>>>>>>>>>>>>>>>>>>>> have/use
>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>> same
>>>>>>>>>>>>>>>>>>>>>>>>>>> classpath
>>>>>>>>>>>>>>>>>>>>>>>>>>> that is in effect while you're in the debugger.
>>>>>>>>>>>>>>>>>>>>>>>>>>> By what mechanism do you generate the jar?
>>>>>>>>>>>>>>>>>>>>>>>>>>> Is it an executable jar or are you running java
>>>>>>>>>>>>>>>>>>>>>>>>>>> -classpath
>>>>>>>>>>>>>>>>>>>>>>>>>>> <your-jar-here:other-jars>          Main?
>>>>>>>>>>>>>>>>>>>>>>>>>>> Make your IDE (netbeans) display the classpath 
>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>> uses
>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>> run
>>>>>>>>>>>>>>>>>>>>>>>>>>> your
>>>>>>>>>>>>>>>>>>>>>>>>>>> app
>>>>>>>>>>>>>>>>>>>>>>>>>>> and compare that with the above.
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/09/2011 07:21 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                 
>>>>>>>>>>>>>>>>>>>>>>>>>>>> aaa ok well my problem is that when i do the
>>>>>>>>>>>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>> netbean
>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>>>>>>>>>>>> fine
>>>>>>>>>>>>>>>>>>>>>>>>>>>> with images and evething but when i run the jar
>>>>>>>>>>>>>>>>>>>>>>>>>>>> file
>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>> command
>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>> give
>>>>>>>>>>>>>>>>>>>>>>>>>>>> me a
>>>>>>>>>>>>>>>>>>>>>>>>>>>> error
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> GRAVE: Error while processing image:
>>>>>>>>>>>>>>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException:
>>>>>>>>>>>>>>>>>>>>>>>>>>>> Cannot
>>>>>>>>>>>>>>>>>>>>>>>>>>>> load
>>>>>>>>>>>>>>>>>>>>>>>>>>>>            image (no suitable loader/converter
>>>>>>>>>>>>>>>>>>>>>>>>>>>> combination
>>>>>>>>>>>>>>>>>>>>>>>>>>>> available)
>>>>>>>>>>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>>>>>>>>>            (image/jpeg)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> so i dont no what its not working and if i have
>>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>>> add
>>>>>>>>>>>>>>>>>>>>>>>>>>>> something
>>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>>> my
>>>>>>>>>>>>>>>>>>>>>>>>>>>> code
>>>>>>>>>>>>>>>>>>>>>>>>>>>> so the images can load i am soooo desperate
>>>>>>>>>>>>>>>>>>>>>>>>>>>> what
>>>>>>>>>>>>>>>>>>>>>>>>>>>> i am
>>>>>>>>>>>>>>>>>>>>>>>>>>>> doing
>>>>>>>>>>>>>>>>>>>>>>>>>>>> wrong??
>>>>>>>>>>>>>>>>>>>>>>>>>>>> i am sorry for the trouble and if a dont
>>>>>>>>>>>>>>>>>>>>>>>>>>>> explain
>>>>>>>>>>>>>>>>>>>>>>>>>>>> my
>>>>>>>>>>>>>>>>>>>>>>>>>>>> self
>>>>>>>>>>>>>>>>>>>>>>>>>>>> very
>>>>>>>>>>>>>>>>>>>>>>>>>>>> good
>>>>>>>>>>>>>>>>>>>>>>>>>>>> jejeje
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                   
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Not at all sure what your problem is.  All I
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> do
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> show
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> what
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> works for us.
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Our source xml looks like this:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> <image image-id="381623861"
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> reference-id="ref-220"
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> width="750"
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> height="750" image-space-id="space-1"
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> position="5"
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                        
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> image-pool-position="31"
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> pos="4"
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                        
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> file="ref_10_1002108221">
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> <!--
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> an
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> actual
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> file
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> (.jpeg
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> copied the working directory of the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> transformer
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> -->
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> <fields />
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> <caption />
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> <annotations>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> <arrow_positions origHeight="750"
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> origWidth="750" />
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> </annotations>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> </image>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Our xslt looks like this for each image
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> needed.
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> <xsl:template name="image">
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> <xsl:param name="img"/>           <!-- This is
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> xml
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> node
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> from
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> source
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> xml
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> above -->
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> <xsl:param name="width"/>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> <xsl:param name="height" select="$width"/>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> <xsl:param
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> name="ignoreHeight">false</xsl:param>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> <fo:block>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> <fo:external-graphic src="{$img/@file}"
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> height="{$height}"
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> width="{$width}" content-height="scale-to-fit"
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> content-width="scale-to-fit"
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> border="0.5pt solid black"
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> border-collapse="separate">
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> <xsl:if test="$ignoreHeight != 'true'">
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> <xsl:attribute name="height">
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> <xsl:value-of select="$height"/>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> </xsl:attribute>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> </xsl:if>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> </fo:external-graphic>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> </fo:block>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> </xsl:template>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Our generated fo looks like this:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> <fo:table-cell>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> <fo:block>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> <fo:external-graphic
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> border-collapse="separate"
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> border="0.5pt
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> solid
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> black" content-width="scale-to-fit"
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> content-height="scale-to-fit"
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> width="2.5in" height="2.5in"
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> src="ref_10_1002108221"
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> />
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> </fo:block>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> </fo:table-cell>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> And the generated pdfs include the image and
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> are
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> shipped
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> printer.
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> How does this stack up with what you have?
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/09/2011 01:19 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                     
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Hi there well i still got the problem but
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> searching
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> IN
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> INTERNET
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> find
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> a
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> JPEG
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> renderer output for FOP its here
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> http://marc.info/?l=fop-user&m=125986752706366&w=2
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the cuestion is can i render the image that i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> want
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> put
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> pdf,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> then add to the xsl the render jpeg it will
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> work??
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> and here explaints how use the render when he
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> say
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> uses
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> as
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> normal
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> case
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> what does it mean
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> what else have to add to the code?? i hope
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> help
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> me
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Thanks!!
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> // OutputStream out = what you want
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                        FopFactory fopFactory
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> =
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> FopFactory.newInstance();
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                        RendererFactory
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> rendererFactory
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> =
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> null;
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                        FOUserAgent
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> foUserAgent
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> =
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> null;
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                        rendererFactory =
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fopFactory.getRendererFactory();
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> rendererFactory.addRendererMaker(new
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> MultiRendererMaker("jpeg"));
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                        foUserAgent =
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fopFactory.newFOUserAgent();
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> rendererFactory.createRenderer(foUserAgent,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> "image/jpeg");
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                        Fop fop =
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fopFactory.newFop("image/jpeg",
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> foUserAgent,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> out);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> //Use fop as normal case
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                       
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Since you're now into xmlgraphics, I think
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> you're
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> best
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> bet
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> here
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> <http://xmlgraphics.apache.org/commons/image-loader.html>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/07/2011 10:18 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                         
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Hi ok this is for generate images that dont
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> need
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> be
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> decompress
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> later??
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the result image i put in my xsl ?? then it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> should
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> work,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> aaa
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> change
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> 1.0 and xml communs 1.4 and its the same
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> jejeje
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> dont
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> find
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> image
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> preload
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> org.apache.fop.fo.flow.ExternalGraphic bind
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> SEVERE: Image not available: The file
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> format
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> not
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> supported.
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> No
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ImagePreloader for *.jpg or *.bmp
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                           
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ImageIO.write(bufferedImage, "JPEG",
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> file);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/07/2011 08:21 AM, Oscar.Flores
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                             
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Ok i actually register the handler now
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> what
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> do
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> setup
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> this
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> handler or not?? and how can i do that,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> also it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> seem
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> bmp
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> its
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> not
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> recognice also what can i do?? thanks for
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> help
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> rob
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> also i am trying to convert the images to
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> see
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> if
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> helps
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                               
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/06/2011 02:29 PM, Oscar.Flores
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                 
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Hi what can be the difference between
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> execute
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> program
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> netbeans
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> (where
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it works and print the images and the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> jar
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> console)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                   
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Different classes being loaded by
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Netbeans
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> than
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> console
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> app.
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Get
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Netbeans to show you the full classpath
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it's
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> using
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it's
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> "%classpath"
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> variable
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                 
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> also i tried the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> imageIO.getImageReadersBySuffix but i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> cant
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> interpretate
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> data
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> y.y,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> its
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> that or always its true in the boolean
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> variable,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> how
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> register
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> handler??
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                   
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Talk to IIORegistry, some thing like
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> CLibJPEGImageReaderSpi());
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> CLibJPEGImageWriterSpi());
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Note: those are not necessarily the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> services
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> your
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> setup.
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                 
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Thanks
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                   
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> See the javadoc on IIORegistry. With
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ImageIO
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> may
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> register
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> your handler(s). What does
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ImageIO.getImageReadersBySuffix()
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> give
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> you.
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For certain jpegs we don't use
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ImageIO,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> rather
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> classes
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> com.sun.image.codec.jpeg:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                        try {
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                           
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> FileOutputStream
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fos
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> =
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> new
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> FileOutputStream(file);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                           
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> JPEGImageEncoder
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> encoder =
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> JPEGCodec.createJPEGEncoder(fos);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                           
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> JPEGEncodeParam
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> param =
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> encoder.getDefaultJPEGEncodeParam(image.getRaster(),
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> JPEGDecodeParam.COLOR_ID_CMYK);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> param.setQuality(1,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> false);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> encoder.encode(image.getRaster(),
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> param);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                           
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fos.close();
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                        } catch
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> (Throwable t)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> {
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> logger.debug(t.getMessage());
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                        }
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> But generally we use ImageIO
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/06/2011 08:29 AM, Oscar.Flores
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                     
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Yeah i think i need your help again i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> tried
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> tu
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> run
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> .jar
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> file
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> console it work but without images
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> this
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> what
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> appears
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> GRAVE: Error while processing image:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Cannot
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> load
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> image
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> (no
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> suitable loader/converter combination
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> available)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i tried  download the jai-imagio add
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> class
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> path
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> but
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> dont
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> work
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                       
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Very odd.  I'm having no problems
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> getting
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> images
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> into
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> pdfs
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> using
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-1.0.
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/03/2011 11:04 AM, Oscar.Flores
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                         
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> aaa hey thanks for the help the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> other
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> day,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> resolve
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> problem
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> changing
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> version of FOP for the 0.95beta
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> instead
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> of
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> 1.0,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> works
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> now
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> prints
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the image and its good, thanks and
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> we
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> are
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> touch
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> if
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> anything
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> else
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fails
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> jejeje
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                           
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Nothing in the log from the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> transformer?
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/03/2011 09:47 AM,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Oscar.Flores
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                             
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> hi there i have another problem i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> hope
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> help
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> me
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> create
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> with foe has no image, it dont
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> show
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> any
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> of
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> them,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> xsl
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> seems
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> be
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> rigth i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> tested with EditX and the pdf
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> show
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> me
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> image,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> what
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> be,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> xmlgraphics-commons-1.5svn, fop
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> 1.0,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-pdf-images
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> 2.0.1
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Snapshot
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> render of the image but it don
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> work
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> please
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> help!!!
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> :,(
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                               
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                             
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                         
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                     
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                 
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> :-):confused::confused::confused::confused:=)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                               
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                             
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                     
>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                 
>>>>>>>>>>>>>>>>>>>>>>>>>> http://old.nabble.com/file/p31822059/libraries.jpeg
>>>>>>>>>>>>>>>>>>>>>>>>>> http://old.nabble.com/file/p31822059/libraries.bmp
>>>>>>>>>>>>>>>>>>>>>>>>>> libraries.bmp
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>                                               
>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>                                             
>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>                                         
>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>                                     
>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>                                 
>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>                             
>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>                         
>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>                     
>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>                 
>>>>>>> ---------------------------------------------------------------------
>>>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>> For additional commands, e-mail:
>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>         
>>>>> ---------------------------------------------------------------------
>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>>>
>>>>>     
>>>>   
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>
>>>
>>>
> 
> 

-- 
View this message in context: http://old.nabble.com/Problems-with-FOP-and-image-tp31766430p31941526.html
Sent from the FOP - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Problems with FOP and image

Posted by Rob Sargent <rs...@xmission.com>.
Have you gone through this page:
http://xmlgraphics.apache.org/commons/image-loader.html

Especially this part:

If you are loading bitmap images and you get an error like "Cannot load
image (no suitable loader/converter combination available) for
myimage.tif (image/tiff), you maybe be missing the necessary ImageIO
codec to decode the image. A number of well-written codecs can be found
in JAI Image I/O Tools Project <https://jai-imageio.dev.java.net/>. Just
download the distribution and add the JAR to the classpath. ImageIO will
automatically pick up the new codecs and they will subsequently be
available to the image framework.

On 06/23/2011 03:06 PM, Oscar.Flores wrote:
> i am sorry Pascal, the main subjet here it that something it wrong in the
> main code of my app but i can find out what it is, and of course you have
> been so much helpful Rob without you i cant even have a pdf generated in
> java so and you are the only one answering my question Thanks a lot dude ,
> and i dont know if it the console or what because its still have the same
> issues with my java app 
>
> org.apache.xmlgraphics.image.loader.ImageException: Cannot load image (no
> suitable loader/converter combination available) for I:\cfd\rfc.jpg
> (image/jpeg)
>  *** this its not only in this image its in everyone of them bmp.jpg. etc
>
> y.y
>  
>
> Rob Sargent-4 wrote:
>> Hello Pascal,
>>
>> This entire thread relates to a single failure, at least in the sense 
>> Oscar cannot generate the desired pdf from his command-line app. Perhaps 
>> the recent drift to problems with his xsl are not strictly related to 
>> "FOP and image".  I hesitate to suggest that Oscar and I take this 
>> off-list because so far at least I haven't been much help to Oscar and 
>> maybe others will spot the real problem or perhaps ask the right
>> questions.
>>
>> Cheers,
>> rjs
>>
>> Pascal Sancho wrote:
>>> Hi Rob & Oscar,
>>>
>>> I'm not sure that the initial topic of this thread is still on
>>> discussion (see Subject).
>>> Please, if it is the case, don't hack an existing one, but open a new
>>> thread with the right Subject, to avoid confusion for other users.
>>>
>>> Le 22/06/2011 18:49, Rob Sargent a écrit :
>>>   
>>>> It's a little tough for me to follow your xsl, but I'm suspicious of
>>>> your loop template: It looks to me as though you are writing empty
>>>> lines.  I don't think you can rely on the empty lines to be "the right
>>>> size". Maybe some non-breaking white space would help?
>>>>
>>>> Have you found the log file? If there's a problem, there's a report.
>>>> Turn up your logging if necessary.
>>>>
>>>> You might want to use the .bat file to generate the "fo" file.  This
>>>> shows exactly what your xsl transformation generated and is the best bet
>>>> at understanding any problem the fop engine is having.  The smart people
>>>> on this list are more likely to look at your fo than your xsl.
>>>>
>>>> On 06/21/2011 01:23 PM, Oscar.Flores wrote:
>>>>     
>>>>> Hi there yeah its the pdf that give me the fop.bat i dont know why it
>>>>> works
>>>>> this way and not from my java program anyway i am using fixed position
>>>>> i
>>>>> show you my xlst to see if you can help me to correct the size
>>>>>
>>>>> http://old.nabble.com/file/p31897144/FacturasOMF.xsl FacturasOMF.xsl
>>>>>
>>>>>
>>>>> Rob Sargent-4 wrote:
>>>>>       
>>>>>> Is the pdf you posted made via the .bat file then?  And it has all the
>>>>>> images you need? Which image is giving you all the trouble?
>>>>>>
>>>>>> I see that you are incorrectly sizing the area into which you are
>>>>>> putting the address of the client. Alternatively you have placed the
>>>>>> table of items too high.  Are you using fixed positions?
>>>>>> Those to pieces (client-address and invoice-items) should be in
>>>>>> consecutive blocks.
>>>>>> On 06/17/2011 09:52 AM, Oscar.Flores wrote:
>>>>>>         
>>>>>>> No i still can print the images in pdf in console what i do for now
>>>>>>> is
>>>>>>> call a
>>>>>>> bat to make the transformation with fo until i figure out what the
>>>>>>> problem
>>>>>>> is in log appear that can find a proper converter for the images
>>>>>>>
>>>>>>>
>>>>>>> also another problem its that the table its to big it dont fit to the
>>>>>>> data
>>>>>>> here its the pdf that result
>>>>>>> http://old.nabble.com/file/p31870136/Prueba3.pdf Prueba3.pdf
>>>>>>>
>>>>>>>   Warning(1979/26): fo:table, table-layout="auto" is currently not
>>>>>>> supported
>>>>>>>           
>>>>>>>> by FOP
>>>>>>>> but in my xslt it ike this<fo:table table-layout="fixed"
>>>>>>>> width="100%">
>>>>>>>>             
>>>>>>> the version of fop i use its 1.0
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> Rob Sargent-4 wrote:
>>>>>>>           
>>>>>>>> I don't think you want to read and write to the same place. If the
>>>>>>>> file
>>>>>>>> is where you want it to be and it's otherwise in perfect shape you
>>>>>>>> should be fine.  But if you do want to read it in and write it to
>>>>>>>> some
>>>>>>>> deployed area the that's what you want to do. Almost:
>>>>>>>>       ImageIO.write(*newImage*, "JPEG", jpegImageFile);
>>>>>>>>
>>>>>>>> So without adding the ImageIO.write() call, are you getting the pdf
>>>>>>>> you
>>>>>>>> want yet?
>>>>>>>> If not, what actual errors are you seeing in the logs.
>>>>>>>>
>>>>>>>> The warning about fo:table is not causing you any trouble.  What
>>>>>>>> version
>>>>>>>> of fop are you running (sorry I've forgotten)
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> On 06/15/2011 02:51 PM, Oscar.Flores wrote:
>>>>>>>>             
>>>>>>>>> Hi thanks for the help yeah i haven see that its was .java and not
>>>>>>>>> .class, ok
>>>>>>>>> then if i follow correctly what you are saying then it has to be
>>>>>>>>> something
>>>>>>>>> like this
>>>>>>>>>
>>>>>>>>> BufferedImage newImage = new BufferedImage ("C:\Logo.jpg")
>>>>>>>>> ImageIO.write(BufferedImage, "JPEG", jpegImageFile) jpegImageFile
>>>>>>>>> will
>>>>>>>>> be
>>>>>>>>> the XML call rigth something like "C:\Logo.jpg")
>>>>>>>>>
>>>>>>>>> and another thing
>>>>>>>>>
>>>>>>>>>     Warning(1979/26): fo:table, table-layout="auto" is currently
>>>>>>>>> not
>>>>>>>>> supported
>>>>>>>>> by FOP
>>>>>>>>> but in my xslt it ike this<fo:table table-layout="fixed"
>>>>>>>>> width="100%">
>>>>>>>>> so
>>>>>>>>> i dont now what its causing the ploblem
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>               
>>>>>>>>>> On 06/14/2011 11:06 AM, Oscar.Flores wrote:
>>>>>>>>>>                 
>>>>>>>>>>> Yeah i do the class is in jai-imageio-1.1-sources.jar, the
>>>>>>>>>>> enviroment
>>>>>>>>>>> is
>>>>>>>>>>> just
>>>>>>>>>>>                   
>>>>>>>>>> Having the file in the "...sources.jar" won't do the runtime world
>>>>>>>>>> much
>>>>>>>>>> good. You need the jar of .class files for jai-imageio, not .java
>>>>>>>>>> files
>>>>>>>>>>                 
>>>>>>>>>>> windows xp, and the bufferedImage will be the path of the image??
>>>>>>>>>>>                   
>>>>>>>>>> No, the bufferedImage is an in-memory instance of BufferedImage
>>>>>>>>>> holding
>>>>>>>>>> the bits of the image.  In the case that you have to read it from
>>>>>>>>>> one
>>>>>>>>>> place and write it to another.
>>>>>>>>>>                 
>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>                   
>>>>>>>>>>>> Did you go through all your jars looking for
>>>>>>>>>>>> 'CLibJPEGImageReaderSpi'.
>>>>>>>>>>>> My greatest suspicion is that you don't have all your jars lined
>>>>>>>>>>>> up.
>>>>>>>>>>>> Which jar(s) do you think supplies these?
>>>>>>>>>>>>
>>>>>>>>>>>> What is your environment: just windows or do you have any tools
>>>>>>>>>>>> like
>>>>>>>>>>>> cygwin?
>>>>>>>>>>>>
>>>>>>>>>>>> The "jpegImageFile" would be the filename in your xsl the
>>>>>>>>>>>> external-resource.  If you're just using a file that is already
>>>>>>>>>>>> in
>>>>>>>>>>>> place
>>>>>>>>>>>> you don't have to re-write it.
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> On 06/14/2011 08:29 AM, Oscar.Flores wrote:
>>>>>>>>>>>>                     
>>>>>>>>>>>>> No i dont, and that weird jejeje netbeans seems to do that for
>>>>>>>>>>>>> me,
>>>>>>>>>>>>> so
>>>>>>>>>>>>> the
>>>>>>>>>>>>> calls like ImageIO.write(BufferedImage, "JPEG", jpegImageFile)?
>>>>>>>>>>>>> do
>>>>>>>>>>>>> i
>>>>>>>>>>>>> have
>>>>>>>>>>>>> to
>>>>>>>>>>>>> do it in every image that i put in the pdf?? and the image is
>>>>>>>>>>>>> gererate
>>>>>>>>>>>>> directly in the pdf??how can i do it??
>>>>>>>>>>>>>
>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>                       
>>>>>>>>>>>>>> Some jar to which netbeans has access has those classes.  Look
>>>>>>>>>>>>>> in
>>>>>>>>>>>>>> the
>>>>>>>>>>>>>> output of jar tvf<each of your jars>     and see if any of
>>>>>>>>>>>>>> those
>>>>>>>>>>>>>> has
>>>>>>>>>>>>>> the
>>>>>>>>>>>>>> named classes.  If you find a jar with those classes make sure
>>>>>>>>>>>>>> it's
>>>>>>>>>>>>>> part
>>>>>>>>>>>>>> of your classpath for you app.
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> Are you making any calls like ImageIO.write(BufferedImage,
>>>>>>>>>>>>>> "JPEG",
>>>>>>>>>>>>>> jpegImageFile)?
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> On 06/13/2011 05:31 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>                         
>>>>>>>>>>>>>>> ok i made a test and tell me that the class is missign but
>>>>>>>>>>>>>>> maybe
>>>>>>>>>>>>>>> what
>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>> say
>>>>>>>>>>>>>>> its rigth and it register the handler
>>>>>>>>>>>>>>> so i gonna register the services so i do this
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>       public static void main(String[] args) throws Exception
>>>>>>>>>>>>>>> {
>>>>>>>>>>>>>>>               DOMConfigurator.configure("D:/Mis
>>>>>>>>>>>>>>> documentos/NetBeansProjects/Factura/src/factura/log4j.xml");
>>>>>>>>>>>>>>>               logger.info("Entering application.");
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>>>> CLibJPEGImageReaderSpi());
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>>>> CLibJPEGImageWriterSpi());
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> also after register my services it telling me that the class
>>>>>>>>>>>>>>> CLibJPEGImageReaderSpi() and CLibJPEGImageWriterSpi() is
>>>>>>>>>>>>>>> missing
>>>>>>>>>>>>>>> but
>>>>>>>>>>>>>>> only
>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>> command
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> after register mi service, something more has to be done??
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>                           
>>>>>>>>>>>>>>>> I'm not sure I'm following correctly: does removing the
>>>>>>>>>>>>>>>> xmlgraphics
>>>>>>>>>>>>>>>> jar
>>>>>>>>>>>>>>>> cause netbeans to behave the same as the command-line run of
>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>> app?
>>>>>>>>>>>>>>>> If
>>>>>>>>>>>>>>>> so, I suspect netbeans is registering services for you. 
>>>>>>>>>>>>>>>> Your
>>>>>>>>>>>>>>>> own
>>>>>>>>>>>>>>>> code
>>>>>>>>>>>>>>>> will have to make a call to one of the
>>>>>>>>>>>>>>>> IIORegistry.registerServiceProvider() methods.
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> On 06/13/2011 05:02 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>                             
>>>>>>>>>>>>>>>>> Ok aaaa i get it, actually the ImageIO library i added
>>>>>>>>>>>>>>>>> because
>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>> read
>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>> xmlgrapics that if something like the message
>>>>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException: Cannot
>>>>>>>>>>>>>>>>> load
>>>>>>>>>>>>>>>>> image
>>>>>>>>>>>>>>>>> (no
>>>>>>>>>>>>>>>>> suitable loader/converter combination available)appear i
>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>> add
>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>> jar
>>>>>>>>>>>>>>>>> file to the classpath but that all it say no configuration
>>>>>>>>>>>>>>>>> or
>>>>>>>>>>>>>>>>> anything,
>>>>>>>>>>>>>>>>> then
>>>>>>>>>>>>>>>>> i delete the imagenIO libs and still i have the same output
>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>> netbeans
>>>>>>>>>>>>>>>>> so
>>>>>>>>>>>>>>>>> xmlgrapics seem to have the problem in the plugins or i
>>>>>>>>>>>>>>>>> have to
>>>>>>>>>>>>>>>>> configure
>>>>>>>>>>>>>>>>> something
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>                               
>>>>>>>>>>>>>>>>>> Then it seems to me netbeans (if it's producing good
>>>>>>>>>>>>>>>>>> output ==
>>>>>>>>>>>>>>>>>> assumptionA) is still using something that the
>>>>>>>>>>>>>>>>>> command-line
>>>>>>>>>>>>>>>>>> isn't.
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> And given assumptionA, you're java code is correct in
>>>>>>>>>>>>>>>>>> terms of
>>>>>>>>>>>>>>>>>> FOP
>>>>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>>>>> your configuration isn't for ImageIO.  Show your ImageIO
>>>>>>>>>>>>>>>>>> related
>>>>>>>>>>>>>>>>>> code
>>>>>>>>>>>>>>>>>> and are you sure it's in your app.  Use the logger to show
>>>>>>>>>>>>>>>>>> a
>>>>>>>>>>>>>>>>>> message
>>>>>>>>>>>>>>>>>> when you add  your loader.  Or list all ImageIO services:
>>>>>>>>>>>>>>>>>> IIORegistry.getServiceProviders()
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> On 06/13/2011 03:01 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>                                 
>>>>>>>>>>>>>>>>>>> ok well i put the xml in scr of my proyect i see that i
>>>>>>>>>>>>>>>>>>> still
>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>> same
>>>>>>>>>>>>>>>>>>> issues of the image render of any image i dont now if the
>>>>>>>>>>>>>>>>>>> xml
>>>>>>>>>>>>>>>>>>> its
>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>> place i
>>>>>>>>>>>>>>>>>>> put the code down to see if something its missing
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> 15:45:07,827 ERROR [render] Error while processing image:
>>>>>>>>>>>>>>>>>>> c:\cfd\nombregp.bmp (i
>>>>>>>>>>>>>>>>>>> mage/bmp)
>>>>>>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException:
>>>>>>>>>>>>>>>>>>> Cannot
>>>>>>>>>>>>>>>>>>> load
>>>>>>>>>>>>>>>>>>> image
>>>>>>>>>>>>>>>>>>> (no
>>>>>>>>>>>>>>>>>>> suitab
>>>>>>>>>>>>>>>>>>> le loader/converter combination available) for
>>>>>>>>>>>>>>>>>>> c:\cfd\nombregp.bmp
>>>>>>>>>>>>>>>>>>> (image/bmp)
>>>>>>>>>>>>>>>>>>>                at
>>>>>>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageManager.getImage(ImageManage
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> import mx.bigdata.sat.cfd.schema.Comprobante;
>>>>>>>>>>>>>>>>>>> import mx.bigdata.sat.cfd.CFDv2;
>>>>>>>>>>>>>>>>>>> import mx.bigdata.sat.security.KeyLoader;
>>>>>>>>>>>>>>>>>>> import org.jdom.*;
>>>>>>>>>>>>>>>>>>> import org.jdom.input.SAXBuilder;
>>>>>>>>>>>>>>>>>>> import org.jdom.output.XMLOutputter;
>>>>>>>>>>>>>>>>>>> import org.jdom.output.Format;
>>>>>>>>>>>>>>>>>>> import org.jdom.transform.JDOMSource;
>>>>>>>>>>>>>>>>>>> //Java
>>>>>>>>>>>>>>>>>>>         import java.io.File;
>>>>>>>>>>>>>>>>>>>         import java.io.OutputStream;
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>         //JAXP
>>>>>>>>>>>>>>>>>>>         import javax.xml.transform.Transformer;
>>>>>>>>>>>>>>>>>>>         import javax.xml.transform.TransformerFactory;
>>>>>>>>>>>>>>>>>>>         import javax.xml.transform.Source;
>>>>>>>>>>>>>>>>>>>         import javax.xml.transform.Result;
>>>>>>>>>>>>>>>>>>>         import javax.xml.transform.stream.StreamSource;
>>>>>>>>>>>>>>>>>>>         import javax.xml.transform.sax.SAXResult;
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>         //FOP
>>>>>>>>>>>>>>>>>>>         import org.apache.fop.apps.FOUserAgent;
>>>>>>>>>>>>>>>>>>>         import org.apache.fop.apps.Fop;
>>>>>>>>>>>>>>>>>>>         import org.apache.fop.apps.FopFactory;
>>>>>>>>>>>>>>>>>>>         import org.apache.fop.apps.MimeConstants;
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>         //log4j
>>>>>>>>>>>>>>>>>>>         import org.apache.log4j.*;
>>>>>>>>>>>>>>>>>>>         import org.apache.log4j.xml.DOMConfigurator;
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> public final class Main {
>>>>>>>>>>>>>>>>>>>            @SuppressWarnings("unchecked")
>>>>>>>>>>>>>>>>>>>            static Logger logger =
>>>>>>>>>>>>>>>>>>> Logger.getLogger(Main.class);
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>            public static void main(String[] args) throws
>>>>>>>>>>>>>>>>>>> Exception
>>>>>>>>>>>>>>>>>>> {
>>>>>>>>>>>>>>>>>>>                 DOMConfigurator.configure("D:/Mis
>>>>>>>>>>>>>>>>>>> documentos/NetBeansProjects/Factura/src/factura/log4j.xml");
>>>>>>>>>>>>>>>>>>>                 logger.info("Entering application.");
>>>>>>>>>>>>>>>>>>>                 try {
>>>>>>>>>>>>>>>>>>>                    File file = new File(args[0]);
>>>>>>>>>>>>>>>>>>>                    Comprobante comp =
>>>>>>>>>>>>>>>>>>> CFDv2.newComprobante(new
>>>>>>>>>>>>>>>>>>> FileInputStream(file));
>>>>>>>>>>>>>>>>>>>                    CFDv2 cfd = new CFDv2(comp);
>>>>>>>>>>>>>>>>>>>                    PrivateKey key =
>>>>>>>>>>>>>>>>>>> KeyLoader.loadPKCS8PrivateKey(new
>>>>>>>>>>>>>>>>>>> FileInputStream(args[1]),(args[2]));
>>>>>>>>>>>>>>>>>>>                    X509Certificate cert =
>>>>>>>>>>>>>>>>>>> KeyLoader.loadX509Certificate(new
>>>>>>>>>>>>>>>>>>> FileInputStream(args[3]));
>>>>>>>>>>>>>>>>>>>                    Comprobante sellado =
>>>>>>>>>>>>>>>>>>> cfd.sellarComprobante(key,
>>>>>>>>>>>>>>>>>>> cert);
>>>>>>>>>>>>>>>>>>>                    String cadena =
>>>>>>>>>>>>>>>>>>> cfd.getCadenaOriginal();
>>>>>>>>>>>>>>>>>>>                    String sello = sellado.getSello();
>>>>>>>>>>>>>>>>>>>                    // Creamos el builder basado en SAX
>>>>>>>>>>>>>>>>>>>                    SAXBuilder builder = new SAXBuilder();
>>>>>>>>>>>>>>>>>>>                    // Construimos el arbol DOM a partir
>>>>>>>>>>>>>>>>>>> del
>>>>>>>>>>>>>>>>>>> fichero
>>>>>>>>>>>>>>>>>>> xml
>>>>>>>>>>>>>>>>>>>                    Document documentJDOM =
>>>>>>>>>>>>>>>>>>> builder.build(new
>>>>>>>>>>>>>>>>>>> FileInputStream(args[0]));
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>                    Element raiz =
>>>>>>>>>>>>>>>>>>> documentJDOM.getRootElement();//toma
>>>>>>>>>>>>>>>>>>> el
>>>>>>>>>>>>>>>>>>> nodo
>>>>>>>>>>>>>>>>>>> raiz
>>>>>>>>>>>>>>>>>>> del documento.
>>>>>>>>>>>>>>>>>>>                    raiz.setAttribute("sello", sello);
>>>>>>>>>>>>>>>>>>>                    raiz.setAttribute("certificado",
>>>>>>>>>>>>>>>>>>> sellado.getCertificado());
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> //System.out.println(raiz.getAttributeValue("sello"));
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> //System.out.println(raiz.getAttributeValue("certificado"));
>>>>>>>>>>>>>>>>>>>                    // Recorremos los hijos de la etiqueta
>>>>>>>>>>>>>>>>>>> raíz
>>>>>>>>>>>>>>>>>>>                    List<Element>        hijosRaiz =
>>>>>>>>>>>>>>>>>>> raiz.getChildren();
>>>>>>>>>>>>>>>>>>>                    boolean Bandera=false;
>>>>>>>>>>>>>>>>>>>                    for(Element hijo: hijosRaiz)
>>>>>>>>>>>>>>>>>>>                    {
>>>>>>>>>>>>>>>>>>>                        // Obtenemos el nombre y su
>>>>>>>>>>>>>>>>>>> contenido
>>>>>>>>>>>>>>>>>>> de
>>>>>>>>>>>>>>>>>>> tipo
>>>>>>>>>>>>>>>>>>> texto
>>>>>>>>>>>>>>>>>>>                        String nombre = hijo.getName();
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>                        if (nombre.equals("Addenda"))
>>>>>>>>>>>>>>>>>>>                        {   List<Element>        subHijo =
>>>>>>>>>>>>>>>>>>> hijo.getChildren();
>>>>>>>>>>>>>>>>>>>                            for(Element hij: subHijo)
>>>>>>>>>>>>>>>>>>>                                {
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> hij.setAttribute("CadenaOriginal",
>>>>>>>>>>>>>>>>>>> cadena);
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> //System.out.println("CadenaOriginal:
>>>>>>>>>>>>>>>>>>> "+hij.getAttributeValue("CadenaOriginal"));
>>>>>>>>>>>>>>>>>>>                                Bandera=true;
>>>>>>>>>>>>>>>>>>>                                break;
>>>>>>>>>>>>>>>>>>>                                }
>>>>>>>>>>>>>>>>>>>                        }
>>>>>>>>>>>>>>>>>>>                        if (Bandera)
>>>>>>>>>>>>>>>>>>>                        {
>>>>>>>>>>>>>>>>>>>                            XMLOutputter out = new
>>>>>>>>>>>>>>>>>>> XMLOutputter(Format.getPrettyFormat());
>>>>>>>>>>>>>>>>>>>                            File nuevoXML = new
>>>>>>>>>>>>>>>>>>> File(args[0]);
>>>>>>>>>>>>>>>>>>>                            try{
>>>>>>>>>>>>>>>>>>>                                FileOutputStream
>>>>>>>>>>>>>>>>>>> archivoXML=
>>>>>>>>>>>>>>>>>>> new
>>>>>>>>>>>>>>>>>>> FileOutputStream
>>>>>>>>>>>>>>>>>>> (nuevoXML);
>>>>>>>>>>>>>>>>>>>                                out.output(documentJDOM,
>>>>>>>>>>>>>>>>>>> archivoXML);
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>                               }
>>>>>>>>>>>>>>>>>>>                            catch (Exception
>>>>>>>>>>>>>>>>>>> ex){System.out.println(ex.getMessage());}
>>>>>>>>>>>>>>>>>>>                            // Para generar el pdf a
>>>>>>>>>>>>>>>>>>> partir de
>>>>>>>>>>>>>>>>>>> un
>>>>>>>>>>>>>>>>>>> archivo.xsl
>>>>>>>>>>>>>>>>>>> y
>>>>>>>>>>>>>>>>>>> un
>>>>>>>>>>>>>>>>>>>                            // archivo.xml
>>>>>>>>>>>>>>>>>>>                        }
>>>>>>>>>>>>>>>>>>>                      }
>>>>>>>>>>>>>>>>>>>                  // configure fopFactory as desired
>>>>>>>>>>>>>>>>>>>                  FopFactory fopFactory =
>>>>>>>>>>>>>>>>>>> FopFactory.newInstance();
>>>>>>>>>>>>>>>>>>>                  FOUserAgent foUserAgent =
>>>>>>>>>>>>>>>>>>> fopFactory.newFOUserAgent();
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>                  // configure foUserAgent as desired
>>>>>>>>>>>>>>>>>>>                  // Setup output
>>>>>>>>>>>>>>>>>>>                 File pdffile = new File(args[5]);
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>                 OutputStream out = new
>>>>>>>>>>>>>>>>>>> java.io.FileOutputStream(pdffile);
>>>>>>>>>>>>>>>>>>>                 out = new
>>>>>>>>>>>>>>>>>>> java.io.BufferedOutputStream(out);
>>>>>>>>>>>>>>>>>>>                 try {
>>>>>>>>>>>>>>>>>>>                        // Construct fop with desired
>>>>>>>>>>>>>>>>>>> output
>>>>>>>>>>>>>>>>>>> format
>>>>>>>>>>>>>>>>>>>                         Fop fop =
>>>>>>>>>>>>>>>>>>> fopFactory.newFop(MimeConstants.MIME_PDF,
>>>>>>>>>>>>>>>>>>> foUserAgent, out);
>>>>>>>>>>>>>>>>>>>                        // Setup XSLT
>>>>>>>>>>>>>>>>>>>                        TransformerFactory factory =
>>>>>>>>>>>>>>>>>>> TransformerFactory.newInstance();
>>>>>>>>>>>>>>>>>>>                        Transformer transformer =
>>>>>>>>>>>>>>>>>>> factory.newTransformer(new
>>>>>>>>>>>>>>>>>>> StreamSource(args[4]));
>>>>>>>>>>>>>>>>>>>                        // Set the value of a  in the
>>>>>>>>>>>>>>>>>>> stylesheet
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> transformer.setParameter("versionParam",
>>>>>>>>>>>>>>>>>>> "2.0");
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>                       // Setup input for XSLT
>>>>>>>>>>>>>>>>>>> transformation
>>>>>>>>>>>>>>>>>>>                        Source src = new
>>>>>>>>>>>>>>>>>>> JDOMSource(documentJDOM);
>>>>>>>>>>>>>>>>>>>                         // Resulting SAX events (the
>>>>>>>>>>>>>>>>>>> generated
>>>>>>>>>>>>>>>>>>> FO)
>>>>>>>>>>>>>>>>>>> must
>>>>>>>>>>>>>>>>>>> be
>>>>>>>>>>>>>>>>>>> piped
>>>>>>>>>>>>>>>>>>> through to FOP
>>>>>>>>>>>>>>>>>>>                        Result res = new
>>>>>>>>>>>>>>>>>>> SAXResult(fop.getDefaultHandler());
>>>>>>>>>>>>>>>>>>>                         // Start XSLT transformation and
>>>>>>>>>>>>>>>>>>> FOP
>>>>>>>>>>>>>>>>>>> processing
>>>>>>>>>>>>>>>>>>>                       //
>>>>>>>>>>>>>>>>>>> System.setProperty("java.awt.headless",
>>>>>>>>>>>>>>>>>>> "true");
>>>>>>>>>>>>>>>>>>>                            transformer.transform(src,
>>>>>>>>>>>>>>>>>>> res);
>>>>>>>>>>>>>>>>>>>                        } finally {
>>>>>>>>>>>>>>>>>>>                         out.close();
>>>>>>>>>>>>>>>>>>>                    }
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>                  System.out.println("Success!");
>>>>>>>>>>>>>>>>>>>                 } catch (Exception e) {
>>>>>>>>>>>>>>>>>>>                  e.printStackTrace(System.err);
>>>>>>>>>>>>>>>>>>>                  System.exit(-1);
>>>>>>>>>>>>>>>>>>>               }
>>>>>>>>>>>>>>>>>>>             logger.info("Exiting application.");
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>          }
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>                                   
>>>>>>>>>>>>>>>>>>>> Try this log4j.xml: Place it at the root of your jar
>>>>>>>>>>>>>>>>>>>> file
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> <?xml version="1.0" encoding="UTF-8"?>
>>>>>>>>>>>>>>>>>>>> <!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> <log4j:configuration
>>>>>>>>>>>>>>>>>>>> xmlns:log4j="http://jakarta.apache.org/log4j/"
>>>>>>>>>>>>>>>>>>>> debug="false">
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> <appender name="CONSOLE"
>>>>>>>>>>>>>>>>>>>> class="org.apache.log4j.ConsoleAppender">
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> <layout class="org.apache.log4j.PatternLayout">
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> </layout>
>>>>>>>>>>>>>>>>>>>> </appender>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> <category name="org">
>>>>>>>>>>>>>>>>>>>> <priority value="DEBUG"/>
>>>>>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>>>>>> <category name="org.apache">
>>>>>>>>>>>>>>>>>>>> <priority value="WARN"/>
>>>>>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>>>>>> <category name="org.springframework">
>>>>>>>>>>>>>>>>>>>> <priority value="WARN"/>
>>>>>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>>>>>> <category name="org.hibernate">
>>>>>>>>>>>>>>>>>>>> <priority value="DEBUG"/>
>>>>>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>>>>>> <category name="net">
>>>>>>>>>>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>>>>>> <category name="javax">
>>>>>>>>>>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>>>>>> <category name="java">
>>>>>>>>>>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>>>>>> <category name="sun">
>>>>>>>>>>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>>>>>> <category name="org.jboss">
>>>>>>>>>>>>>>>>>>>> <priority value="INFO"/>
>>>>>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>>>>>> <category name="org.jboss.seam">
>>>>>>>>>>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>>>>>> <root>
>>>>>>>>>>>>>>>>>>>> <appender-ref ref="CONSOLE"/>
>>>>>>>>>>>>>>>>>>>> </root>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> </log4j:configuration>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> On 06/13/2011 11:06 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>                                     
>>>>>>>>>>>>>>>>>>>>> ok i dont thik i have a configuracion file i find the
>>>>>>>>>>>>>>>>>>>>> code
>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>> put
>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>> other post i think its the basic
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>                                       
>>>>>>>>>>>>>>>>>>>>>> Do you have a config file for log4j.  Usually it's in
>>>>>>>>>>>>>>>>>>>>>> a
>>>>>>>>>>>>>>>>>>>>>> resource
>>>>>>>>>>>>>>>>>>>>>> tree.
>>>>>>>>>>>>>>>>>>>>>> Are you copying that to your deployment? Is your ant
>>>>>>>>>>>>>>>>>>>>>> script
>>>>>>>>>>>>>>>>>>>>>> including
>>>>>>>>>>>>>>>>>>>>>> the config file in the jar of your application?
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> On 06/13/2011 10:12 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>                                         
>>>>>>>>>>>>>>>>>>>>>>> Ok yeah the log4j its having isuees to find the
>>>>>>>>>>>>>>>>>>>>>>> configuration
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> log4j:WARN No appenders could be found for logger
>>>>>>>>>>>>>>>>>>>>>>> (org.apache.fop.util.ContentHandlerFactoryRegistry).
>>>>>>>>>>>>>>>>>>>>>>> log4j:WARN Please initialize the log4j system
>>>>>>>>>>>>>>>>>>>>>>> properly.
>>>>>>>>>>>>>>>>>>>>>>> log4j:WARN See
>>>>>>>>>>>>>>>>>>>>>>> http://logging.apache.org/log4j/1.2/faq.html#noconfig
>>>>>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>>>>>> more info.
>>>>>>>>>>>>>>>>>>>>>>> i go to the faq guide and it say try loading the
>>>>>>>>>>>>>>>>>>>>>>> class or
>>>>>>>>>>>>>>>>>>>>>>> resource
>>>>>>>>>>>>>>>>>>>>>>> yourself.
>>>>>>>>>>>>>>>>>>>>>>> If you can't find it, neither will log4j.
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> aaa i dont know where to set this
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> also here its my xlst
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> http://old.nabble.com/file/p31835645/FacturasOMF.xsl
>>>>>>>>>>>>>>>>>>>>>>> FacturasOMF.xsl
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> and the fo file that generate the editix
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> http://old.nabble.com/file/p31835645/Prueba.fo
>>>>>>>>>>>>>>>>>>>>>>> Prueba.fo
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>                                           
>>>>>>>>>>>>>>>>>>>>>>>> The first thing is to really dig into what you did
>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>> netbeans
>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>> get
>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>> to work...
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> I've forgotten what your stylesheet looked like, so
>>>>>>>>>>>>>>>>>>>>>>>> maybe
>>>>>>>>>>>>>>>>>>>>>>>> if
>>>>>>>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>>>>>>>> show
>>>>>>>>>>>>>>>>>>>>>>>> us
>>>>>>>>>>>>>>>>>>>>>>>> again how you're referencing your images we might
>>>>>>>>>>>>>>>>>>>>>>>> notice
>>>>>>>>>>>>>>>>>>>>>>>> a
>>>>>>>>>>>>>>>>>>>>>>>> problem.
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> It might also help to see the "fo" generated during
>>>>>>>>>>>>>>>>>>>>>>>> your
>>>>>>>>>>>>>>>>>>>>>>>> transformation.
>>>>>>>>>>>>>>>>>>>>>>>> Can you grab that just after xslt and just before
>>>>>>>>>>>>>>>>>>>>>>>> fop
>>>>>>>>>>>>>>>>>>>>>>>> calls.
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> Are you sure there is no error being logged
>>>>>>>>>>>>>>>>>>>>>>>> somewhere
>>>>>>>>>>>>>>>>>>>>>>>> when
>>>>>>>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>>>>>>>> run
>>>>>>>>>>>>>>>>>>>>>>>> from
>>>>>>>>>>>>>>>>>>>>>>>> the command line? (Where is log4j writing and at
>>>>>>>>>>>>>>>>>>>>>>>> what
>>>>>>>>>>>>>>>>>>>>>>>> level?)
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>                                             
>>>>>>>>>>>>>>>>>>>>>>>>> You where absolutly rigth i miss a few libraries to
>>>>>>>>>>>>>>>>>>>>>>>>> add
>>>>>>>>>>>>>>>>>>>>>>>>> into
>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>> jar
>>>>>>>>>>>>>>>>>>>>>>>>> file, i
>>>>>>>>>>>>>>>>>>>>>>>>> modified the build.xml to add the package and jar
>>>>>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>> need,
>>>>>>>>>>>>>>>>>>>>>>>>> now
>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>> error
>>>>>>>>>>>>>>>>>>>>>>>>> message is not there but still the images dont show
>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>> remeber
>>>>>>>>>>>>>>>>>>>>>>>>> that i do something in netbeans so they can add to
>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>>>>>>>>> but
>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>> cant
>>>>>>>>>>>>>>>>>>>>>>>>> remeber i dont now if there is still a library that
>>>>>>>>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>>>>>>>>> missing
>>>>>>>>>>>>>>>>>>>>>>>>> or
>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>> am
>>>>>>>>>>>>>>>>>>>>>>>>> adding more than it should be
>>>>>>>>>>>>>>>>>>>>>>>>> This is what i use :
>>>>>>>>>>>>>>>>>>>>>>>>> cfdi-base-0.1.6-SNAPSHOT.jar
>>>>>>>>>>>>>>>>>>>>>>>>> guava-r09.jar
>>>>>>>>>>>>>>>>>>>>>>>>> guava-r09-gwt.jar
>>>>>>>>>>>>>>>>>>>>>>>>> jaxb-impl-2.1.10.jar
>>>>>>>>>>>>>>>>>>>>>>>>> avalon-framework-api-4.3.jar
>>>>>>>>>>>>>>>>>>>>>>>>> avalon-framework-cvs-20020806.jar
>>>>>>>>>>>>>>>>>>>>>>>>> avalon-logkit-2.1.jar
>>>>>>>>>>>>>>>>>>>>>>>>> not-yet-commons-ssl-0.3.11.jar
>>>>>>>>>>>>>>>>>>>>>>>>> commons-codec-1.5.jar
>>>>>>>>>>>>>>>>>>>>>>>>> commons-codec-1.5-sources.jar
>>>>>>>>>>>>>>>>>>>>>>>>> log4j-1.2.16.jar
>>>>>>>>>>>>>>>>>>>>>>>>> fop.jar
>>>>>>>>>>>>>>>>>>>>>>>>> jdom.jar
>>>>>>>>>>>>>>>>>>>>>>>>> xmlgraphics-commons-1.4.jar
>>>>>>>>>>>>>>>>>>>>>>>>> commons-io-1.3.1.jar
>>>>>>>>>>>>>>>>>>>>>>>>> fop-pdf-images-2.0.1.SNAPSHOT.jar
>>>>>>>>>>>>>>>>>>>>>>>>> pdfbox-app-1.5.0.jar
>>>>>>>>>>>>>>>>>>>>>>>>> fontbox-1.3.1.jar
>>>>>>>>>>>>>>>>>>>>>>>>> jempbox-1.3.1.jar
>>>>>>>>>>>>>>>>>>>>>>>>> xercesImpl-2.7.1.jar
>>>>>>>>>>>>>>>>>>>>>>>>> batik-all-1.7.jar
>>>>>>>>>>>>>>>>>>>>>>>>> xml-apis-1.3.04.jar
>>>>>>>>>>>>>>>>>>>>>>>>> xml-apis-ext-1.3.04.jar
>>>>>>>>>>>>>>>>>>>>>>>>>           avalon-framework-4.2.0.jar
>>>>>>>>>>>>>>>>>>>>>>>>>           xalan-2.7.0.jar
>>>>>>>>>>>>>>>>>>>>>>>>>           serializer-2.7.0.jar
>>>>>>>>>>>>>>>>>>>>>>>>>           commons-logging-1.0.4.jar
>>>>>>>>>>>>>>>>>>>>>>>>>           jai_codec.jar
>>>>>>>>>>>>>>>>>>>>>>>>>           jai_core.jar
>>>>>>>>>>>>>>>>>>>>>>>>>           batik-ext.jar
>>>>>>>>>>>>>>>>>>>>>>>>>           jai_imageio-1.1-sources.jar
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> Thanks Rob for the help
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>                                               
>>>>>>>>>>>>>>>>>>>>>>>>>> I suspect running from your jar does not have/use
>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>> same
>>>>>>>>>>>>>>>>>>>>>>>>>> classpath
>>>>>>>>>>>>>>>>>>>>>>>>>> that is in effect while you're in the debugger.
>>>>>>>>>>>>>>>>>>>>>>>>>> By what mechanism do you generate the jar?
>>>>>>>>>>>>>>>>>>>>>>>>>> Is it an executable jar or are you running java
>>>>>>>>>>>>>>>>>>>>>>>>>> -classpath
>>>>>>>>>>>>>>>>>>>>>>>>>> <your-jar-here:other-jars>          Main?
>>>>>>>>>>>>>>>>>>>>>>>>>> Make your IDE (netbeans) display the classpath  it
>>>>>>>>>>>>>>>>>>>>>>>>>> uses
>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>> run
>>>>>>>>>>>>>>>>>>>>>>>>>> your
>>>>>>>>>>>>>>>>>>>>>>>>>> app
>>>>>>>>>>>>>>>>>>>>>>>>>> and compare that with the above.
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/09/2011 07:21 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>                                                 
>>>>>>>>>>>>>>>>>>>>>>>>>>> aaa ok well my problem is that when i do the pdf
>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>> netbean
>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>>>>>>>>>>> fine
>>>>>>>>>>>>>>>>>>>>>>>>>>> with images and evething but when i run the jar
>>>>>>>>>>>>>>>>>>>>>>>>>>> file
>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>> command
>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>> give
>>>>>>>>>>>>>>>>>>>>>>>>>>> me a
>>>>>>>>>>>>>>>>>>>>>>>>>>> error
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> GRAVE: Error while processing image:
>>>>>>>>>>>>>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException:
>>>>>>>>>>>>>>>>>>>>>>>>>>> Cannot
>>>>>>>>>>>>>>>>>>>>>>>>>>> load
>>>>>>>>>>>>>>>>>>>>>>>>>>>            image (no suitable loader/converter
>>>>>>>>>>>>>>>>>>>>>>>>>>> combination
>>>>>>>>>>>>>>>>>>>>>>>>>>> available)
>>>>>>>>>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>>>>>>>>            (image/jpeg)
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> so i dont no what its not working and if i have
>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>> add
>>>>>>>>>>>>>>>>>>>>>>>>>>> something
>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>> my
>>>>>>>>>>>>>>>>>>>>>>>>>>> code
>>>>>>>>>>>>>>>>>>>>>>>>>>> so the images can load i am soooo desperate what
>>>>>>>>>>>>>>>>>>>>>>>>>>> i am
>>>>>>>>>>>>>>>>>>>>>>>>>>> doing
>>>>>>>>>>>>>>>>>>>>>>>>>>> wrong??
>>>>>>>>>>>>>>>>>>>>>>>>>>> i am sorry for the trouble and if a dont explain
>>>>>>>>>>>>>>>>>>>>>>>>>>> my
>>>>>>>>>>>>>>>>>>>>>>>>>>> self
>>>>>>>>>>>>>>>>>>>>>>>>>>> very
>>>>>>>>>>>>>>>>>>>>>>>>>>> good
>>>>>>>>>>>>>>>>>>>>>>>>>>> jejeje
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                   
>>>>>>>>>>>>>>>>>>>>>>>>>>>> Not at all sure what your problem is.  All I can
>>>>>>>>>>>>>>>>>>>>>>>>>>>> do
>>>>>>>>>>>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>>>>>>>>>>>> show
>>>>>>>>>>>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>>>>>>>>>>>> what
>>>>>>>>>>>>>>>>>>>>>>>>>>>> works for us.
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> Our source xml looks like this:
>>>>>>>>>>>>>>>>>>>>>>>>>>>> <image image-id="381623861"
>>>>>>>>>>>>>>>>>>>>>>>>>>>> reference-id="ref-220"
>>>>>>>>>>>>>>>>>>>>>>>>>>>> width="750"
>>>>>>>>>>>>>>>>>>>>>>>>>>>> height="750" image-space-id="space-1"
>>>>>>>>>>>>>>>>>>>>>>>>>>>> position="5"
>>>>>>>>>>>>>>>>>>>>>>>>>>>>                         image-pool-position="31"
>>>>>>>>>>>>>>>>>>>>>>>>>>>> pos="4"
>>>>>>>>>>>>>>>>>>>>>>>>>>>>                        
>>>>>>>>>>>>>>>>>>>>>>>>>>>> file="ref_10_1002108221">
>>>>>>>>>>>>>>>>>>>>>>>>>>>> <!--
>>>>>>>>>>>>>>>>>>>>>>>>>>>> an
>>>>>>>>>>>>>>>>>>>>>>>>>>>> actual
>>>>>>>>>>>>>>>>>>>>>>>>>>>> file
>>>>>>>>>>>>>>>>>>>>>>>>>>>> (.jpeg
>>>>>>>>>>>>>>>>>>>>>>>>>>>> copied the working directory of the transformer
>>>>>>>>>>>>>>>>>>>>>>>>>>>> -->
>>>>>>>>>>>>>>>>>>>>>>>>>>>> <fields />
>>>>>>>>>>>>>>>>>>>>>>>>>>>> <caption />
>>>>>>>>>>>>>>>>>>>>>>>>>>>> <annotations>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> <arrow_positions origHeight="750"
>>>>>>>>>>>>>>>>>>>>>>>>>>>> origWidth="750" />
>>>>>>>>>>>>>>>>>>>>>>>>>>>> </annotations>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> </image>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> Our xslt looks like this for each image needed.
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> <xsl:template name="image">
>>>>>>>>>>>>>>>>>>>>>>>>>>>> <xsl:param name="img"/>           <!-- This is
>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>> xml
>>>>>>>>>>>>>>>>>>>>>>>>>>>> node
>>>>>>>>>>>>>>>>>>>>>>>>>>>> from
>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>> source
>>>>>>>>>>>>>>>>>>>>>>>>>>>> xml
>>>>>>>>>>>>>>>>>>>>>>>>>>>> above -->
>>>>>>>>>>>>>>>>>>>>>>>>>>>> <xsl:param name="width"/>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> <xsl:param name="height" select="$width"/>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> <xsl:param name="ignoreHeight">false</xsl:param>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> <fo:block>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> <fo:external-graphic src="{$img/@file}"
>>>>>>>>>>>>>>>>>>>>>>>>>>>> height="{$height}"
>>>>>>>>>>>>>>>>>>>>>>>>>>>> width="{$width}" content-height="scale-to-fit"
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> content-width="scale-to-fit"
>>>>>>>>>>>>>>>>>>>>>>>>>>>> border="0.5pt solid black"
>>>>>>>>>>>>>>>>>>>>>>>>>>>> border-collapse="separate">
>>>>>>>>>>>>>>>>>>>>>>>>>>>> <xsl:if test="$ignoreHeight != 'true'">
>>>>>>>>>>>>>>>>>>>>>>>>>>>> <xsl:attribute name="height">
>>>>>>>>>>>>>>>>>>>>>>>>>>>> <xsl:value-of select="$height"/>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> </xsl:attribute>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> </xsl:if>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> </fo:external-graphic>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> </fo:block>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> </xsl:template>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> Our generated fo looks like this:
>>>>>>>>>>>>>>>>>>>>>>>>>>>> <fo:table-cell>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> <fo:block>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> <fo:external-graphic border-collapse="separate"
>>>>>>>>>>>>>>>>>>>>>>>>>>>> border="0.5pt
>>>>>>>>>>>>>>>>>>>>>>>>>>>> solid
>>>>>>>>>>>>>>>>>>>>>>>>>>>> black" content-width="scale-to-fit"
>>>>>>>>>>>>>>>>>>>>>>>>>>>> content-height="scale-to-fit"
>>>>>>>>>>>>>>>>>>>>>>>>>>>> width="2.5in" height="2.5in"
>>>>>>>>>>>>>>>>>>>>>>>>>>>> src="ref_10_1002108221"
>>>>>>>>>>>>>>>>>>>>>>>>>>>> />
>>>>>>>>>>>>>>>>>>>>>>>>>>>> </fo:block>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> </fo:table-cell>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> And the generated pdfs include the image and are
>>>>>>>>>>>>>>>>>>>>>>>>>>>> shipped
>>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>> printer.
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> How does this stack up with what you have?
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/09/2011 01:19 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                     
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Hi there well i still got the problem but
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> searching
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> IN
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> INTERNET
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> find
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> a
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> JPEG
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> renderer output for FOP its here
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> http://marc.info/?l=fop-user&m=125986752706366&w=2
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the cuestion is can i render the image that i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> want
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> put
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> pdf,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> then add to the xsl the render jpeg it will
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> work??
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> and here explaints how use the render when he
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> say
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> uses
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> as
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> normal
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> case
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> what does it mean
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> what else have to add to the code?? i hope you
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> help
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> me
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Thanks!!
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> // OutputStream out = what you want
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                        FopFactory fopFactory =
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> FopFactory.newInstance();
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                        RendererFactory
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> rendererFactory
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> =
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> null;
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                        FOUserAgent foUserAgent
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> =
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> null;
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                        rendererFactory =
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fopFactory.getRendererFactory();
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> rendererFactory.addRendererMaker(new
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> MultiRendererMaker("jpeg"));
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                        foUserAgent =
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fopFactory.newFOUserAgent();
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> rendererFactory.createRenderer(foUserAgent,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> "image/jpeg");
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                        Fop fop =
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fopFactory.newFop("image/jpeg",
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> foUserAgent,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> out);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> //Use fop as normal case
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                       
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Since you're now into xmlgraphics, I think
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> you're
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> best
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> bet
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> here
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> <http://xmlgraphics.apache.org/commons/image-loader.html>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/07/2011 10:18 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                         
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Hi ok this is for generate images that dont
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> need
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> be
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> decompress
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> later??
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the result image i put in my xsl ?? then it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> should
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> work,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> aaa
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> change
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> 1.0 and xml communs 1.4 and its the same
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> jejeje
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> dont
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> find
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> image
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> preload
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> org.apache.fop.fo.flow.ExternalGraphic bind
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> SEVERE: Image not available: The file format
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> not
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> supported.
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> No
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ImagePreloader for *.jpg or *.bmp
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                           
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ImageIO.write(bufferedImage, "JPEG", file);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/07/2011 08:21 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                             
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Ok i actually register the handler now what
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> do
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> setup
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> this
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> handler or not?? and how can i do that,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> also it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> seem
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> bmp
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> its
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> not
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> recognice also what can i do?? thanks for
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> help
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> rob
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> also i am trying to convert the images to
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> see
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> if
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> helps
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                               
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/06/2011 02:29 PM, Oscar.Flores
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                 
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Hi what can be the difference between
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> execute
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> program
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> netbeans
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> (where
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it works and print the images and the jar
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> console)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                   
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Different classes being loaded by Netbeans
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> than
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> console
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> app.
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Get
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Netbeans to show you the full classpath
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it's
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> using
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it's
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> "%classpath"
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> variable
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                 
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> also i tried the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> imageIO.getImageReadersBySuffix but i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> cant
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> interpretate
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> data
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> y.y,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> its
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> that or always its true in the boolean
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> variable,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> how
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> register
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> handler??
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                   
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Talk to IIORegistry, some thing like
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> CLibJPEGImageReaderSpi());
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> CLibJPEGImageWriterSpi());
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Note: those are not necessarily the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> services
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> your
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> setup.
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                 
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Thanks
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                   
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> See the javadoc on IIORegistry. With
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ImageIO
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> may
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> register
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> your handler(s). What does
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ImageIO.getImageReadersBySuffix()
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> give
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> you.
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For certain jpegs we don't use ImageIO,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> rather
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> classes
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> com.sun.image.codec.jpeg:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                        try {
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                           
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> FileOutputStream
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fos
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> =
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> new
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> FileOutputStream(file);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                           
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> JPEGImageEncoder
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> encoder =
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> JPEGCodec.createJPEGEncoder(fos);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                           
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> JPEGEncodeParam
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> param =
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> encoder.getDefaultJPEGEncodeParam(image.getRaster(),
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> JPEGDecodeParam.COLOR_ID_CMYK);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> param.setQuality(1,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> false);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> encoder.encode(image.getRaster(),
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> param);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                            fos.close();
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                        } catch
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> (Throwable t)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> {
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> logger.debug(t.getMessage());
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                        }
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> But generally we use ImageIO
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/06/2011 08:29 AM, Oscar.Flores
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                     
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Yeah i think i need your help again i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> tried
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> tu
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> run
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> .jar
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> file
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> console it work but without images this
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> what
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> appears
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> GRAVE: Error while processing image:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Cannot
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> load
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> image
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> (no
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> suitable loader/converter combination
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> available)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i tried  download the jai-imagio add to
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> class
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> path
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> but
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> dont
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> work
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                       
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Very odd.  I'm having no problems
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> getting
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> images
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> into
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> pdfs
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> using
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-1.0.
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/03/2011 11:04 AM, Oscar.Flores
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                         
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> aaa hey thanks for the help the other
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> day,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> resolve
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> problem
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> changing
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> version of FOP for the 0.95beta
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> instead
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> of
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> 1.0,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> works
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> now
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> prints
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the image and its good, thanks and we
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> are
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> touch
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> if
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> anything
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> else
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fails
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> jejeje
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                           
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Nothing in the log from the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> transformer?
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/03/2011 09:47 AM, Oscar.Flores
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                             
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> hi there i have another problem i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> hope
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> help
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> me
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> create
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> with foe has no image, it dont show
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> any
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> of
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> them,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> xsl
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> seems
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> be
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> rigth i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> tested with EditX and the pdf show
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> me
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> image,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> what
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> be,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> xmlgraphics-commons-1.5svn, fop
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> 1.0,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-pdf-images
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> 2.0.1
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Snapshot
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> render of the image but it don work
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> please
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> help!!!
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> :,(
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                               
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                             
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                         
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                     
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                 
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> :-):confused::confused::confused::confused:=)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                               
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                             
>>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                     
>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>                                                 
>>>>>>>>>>>>>>>>>>>>>>>>> http://old.nabble.com/file/p31822059/libraries.jpeg
>>>>>>>>>>>>>>>>>>>>>>>>> http://old.nabble.com/file/p31822059/libraries.bmp
>>>>>>>>>>>>>>>>>>>>>>>>> libraries.bmp
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>                                               
>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>                                             
>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>                                         
>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>                                     
>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>                                 
>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>                             
>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>                         
>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>                     
>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>                 
>>>>>> ---------------------------------------------------------------------
>>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>>>>
>>>>>>
>>>>>>
>>>>>>         
>>>> ---------------------------------------------------------------------
>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>>
>>>>     
>>>   
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>
>>
>>

Re: Problems with FOP and image

Posted by "Oscar.Flores" <fa...@hotmail.com>.
i am sorry Pascal, the main subjet here it that something it wrong in the
main code of my app but i can find out what it is, and of course you have
been so much helpful Rob without you i cant even have a pdf generated in
java so and you are the only one answering my question Thanks a lot dude ,
and i dont know if it the console or what because its still have the same
issues with my java app 

org.apache.xmlgraphics.image.loader.ImageException: Cannot load image (no
suitable loader/converter combination available) for I:\cfd\rfc.jpg
(image/jpeg)
 *** this its not only in this image its in everyone of them bmp.jpg. etc

y.y
 

Rob Sargent-4 wrote:
> 
> Hello Pascal,
> 
> This entire thread relates to a single failure, at least in the sense 
> Oscar cannot generate the desired pdf from his command-line app. Perhaps 
> the recent drift to problems with his xsl are not strictly related to 
> "FOP and image".  I hesitate to suggest that Oscar and I take this 
> off-list because so far at least I haven't been much help to Oscar and 
> maybe others will spot the real problem or perhaps ask the right
> questions.
> 
> Cheers,
> rjs
> 
> Pascal Sancho wrote:
>> Hi Rob & Oscar,
>>
>> I'm not sure that the initial topic of this thread is still on
>> discussion (see Subject).
>> Please, if it is the case, don't hack an existing one, but open a new
>> thread with the right Subject, to avoid confusion for other users.
>>
>> Le 22/06/2011 18:49, Rob Sargent a écrit :
>>   
>>> It's a little tough for me to follow your xsl, but I'm suspicious of
>>> your loop template: It looks to me as though you are writing empty
>>> lines.  I don't think you can rely on the empty lines to be "the right
>>> size". Maybe some non-breaking white space would help?
>>>
>>> Have you found the log file? If there's a problem, there's a report.
>>> Turn up your logging if necessary.
>>>
>>> You might want to use the .bat file to generate the "fo" file.  This
>>> shows exactly what your xsl transformation generated and is the best bet
>>> at understanding any problem the fop engine is having.  The smart people
>>> on this list are more likely to look at your fo than your xsl.
>>>
>>> On 06/21/2011 01:23 PM, Oscar.Flores wrote:
>>>     
>>>> Hi there yeah its the pdf that give me the fop.bat i dont know why it
>>>> works
>>>> this way and not from my java program anyway i am using fixed position
>>>> i
>>>> show you my xlst to see if you can help me to correct the size
>>>>
>>>> http://old.nabble.com/file/p31897144/FacturasOMF.xsl FacturasOMF.xsl
>>>>
>>>>
>>>> Rob Sargent-4 wrote:
>>>>       
>>>>> Is the pdf you posted made via the .bat file then?  And it has all the
>>>>> images you need? Which image is giving you all the trouble?
>>>>>
>>>>> I see that you are incorrectly sizing the area into which you are
>>>>> putting the address of the client. Alternatively you have placed the
>>>>> table of items too high.  Are you using fixed positions?
>>>>> Those to pieces (client-address and invoice-items) should be in
>>>>> consecutive blocks.
>>>>> On 06/17/2011 09:52 AM, Oscar.Flores wrote:
>>>>>         
>>>>>> No i still can print the images in pdf in console what i do for now
>>>>>> is
>>>>>> call a
>>>>>> bat to make the transformation with fo until i figure out what the
>>>>>> problem
>>>>>> is in log appear that can find a proper converter for the images
>>>>>>
>>>>>>
>>>>>> also another problem its that the table its to big it dont fit to the
>>>>>> data
>>>>>> here its the pdf that result
>>>>>> http://old.nabble.com/file/p31870136/Prueba3.pdf Prueba3.pdf
>>>>>>
>>>>>>   Warning(1979/26): fo:table, table-layout="auto" is currently not
>>>>>> supported
>>>>>>           
>>>>>>> by FOP
>>>>>>> but in my xslt it ike this<fo:table table-layout="fixed"
>>>>>>> width="100%">
>>>>>>>             
>>>>>> the version of fop i use its 1.0
>>>>>>
>>>>>>
>>>>>>
>>>>>> Rob Sargent-4 wrote:
>>>>>>           
>>>>>>> I don't think you want to read and write to the same place. If the
>>>>>>> file
>>>>>>> is where you want it to be and it's otherwise in perfect shape you
>>>>>>> should be fine.  But if you do want to read it in and write it to
>>>>>>> some
>>>>>>> deployed area the that's what you want to do. Almost:
>>>>>>>       ImageIO.write(*newImage*, "JPEG", jpegImageFile);
>>>>>>>
>>>>>>> So without adding the ImageIO.write() call, are you getting the pdf
>>>>>>> you
>>>>>>> want yet?
>>>>>>> If not, what actual errors are you seeing in the logs.
>>>>>>>
>>>>>>> The warning about fo:table is not causing you any trouble.  What
>>>>>>> version
>>>>>>> of fop are you running (sorry I've forgotten)
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> On 06/15/2011 02:51 PM, Oscar.Flores wrote:
>>>>>>>             
>>>>>>>> Hi thanks for the help yeah i haven see that its was .java and not
>>>>>>>> .class, ok
>>>>>>>> then if i follow correctly what you are saying then it has to be
>>>>>>>> something
>>>>>>>> like this
>>>>>>>>
>>>>>>>> BufferedImage newImage = new BufferedImage ("C:\Logo.jpg")
>>>>>>>> ImageIO.write(BufferedImage, "JPEG", jpegImageFile) jpegImageFile
>>>>>>>> will
>>>>>>>> be
>>>>>>>> the XML call rigth something like "C:\Logo.jpg")
>>>>>>>>
>>>>>>>> and another thing
>>>>>>>>
>>>>>>>>     Warning(1979/26): fo:table, table-layout="auto" is currently
>>>>>>>> not
>>>>>>>> supported
>>>>>>>> by FOP
>>>>>>>> but in my xslt it ike this<fo:table table-layout="fixed"
>>>>>>>> width="100%">
>>>>>>>> so
>>>>>>>> i dont now what its causing the ploblem
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>               
>>>>>>>>> On 06/14/2011 11:06 AM, Oscar.Flores wrote:
>>>>>>>>>                 
>>>>>>>>>> Yeah i do the class is in jai-imageio-1.1-sources.jar, the
>>>>>>>>>> enviroment
>>>>>>>>>> is
>>>>>>>>>> just
>>>>>>>>>>                   
>>>>>>>>> Having the file in the "...sources.jar" won't do the runtime world
>>>>>>>>> much
>>>>>>>>> good. You need the jar of .class files for jai-imageio, not .java
>>>>>>>>> files
>>>>>>>>>                 
>>>>>>>>>> windows xp, and the bufferedImage will be the path of the image??
>>>>>>>>>>                   
>>>>>>>>> No, the bufferedImage is an in-memory instance of BufferedImage
>>>>>>>>> holding
>>>>>>>>> the bits of the image.  In the case that you have to read it from
>>>>>>>>> one
>>>>>>>>> place and write it to another.
>>>>>>>>>                 
>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>                   
>>>>>>>>>>> Did you go through all your jars looking for
>>>>>>>>>>> 'CLibJPEGImageReaderSpi'.
>>>>>>>>>>> My greatest suspicion is that you don't have all your jars lined
>>>>>>>>>>> up.
>>>>>>>>>>> Which jar(s) do you think supplies these?
>>>>>>>>>>>
>>>>>>>>>>> What is your environment: just windows or do you have any tools
>>>>>>>>>>> like
>>>>>>>>>>> cygwin?
>>>>>>>>>>>
>>>>>>>>>>> The "jpegImageFile" would be the filename in your xsl the
>>>>>>>>>>> external-resource.  If you're just using a file that is already
>>>>>>>>>>> in
>>>>>>>>>>> place
>>>>>>>>>>> you don't have to re-write it.
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> On 06/14/2011 08:29 AM, Oscar.Flores wrote:
>>>>>>>>>>>                     
>>>>>>>>>>>> No i dont, and that weird jejeje netbeans seems to do that for
>>>>>>>>>>>> me,
>>>>>>>>>>>> so
>>>>>>>>>>>> the
>>>>>>>>>>>> calls like ImageIO.write(BufferedImage, "JPEG", jpegImageFile)?
>>>>>>>>>>>> do
>>>>>>>>>>>> i
>>>>>>>>>>>> have
>>>>>>>>>>>> to
>>>>>>>>>>>> do it in every image that i put in the pdf?? and the image is
>>>>>>>>>>>> gererate
>>>>>>>>>>>> directly in the pdf??how can i do it??
>>>>>>>>>>>>
>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>                       
>>>>>>>>>>>>> Some jar to which netbeans has access has those classes.  Look
>>>>>>>>>>>>> in
>>>>>>>>>>>>> the
>>>>>>>>>>>>> output of jar tvf<each of your jars>     and see if any of
>>>>>>>>>>>>> those
>>>>>>>>>>>>> has
>>>>>>>>>>>>> the
>>>>>>>>>>>>> named classes.  If you find a jar with those classes make sure
>>>>>>>>>>>>> it's
>>>>>>>>>>>>> part
>>>>>>>>>>>>> of your classpath for you app.
>>>>>>>>>>>>>
>>>>>>>>>>>>> Are you making any calls like ImageIO.write(BufferedImage,
>>>>>>>>>>>>> "JPEG",
>>>>>>>>>>>>> jpegImageFile)?
>>>>>>>>>>>>>
>>>>>>>>>>>>> On 06/13/2011 05:31 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>                         
>>>>>>>>>>>>>> ok i made a test and tell me that the class is missign but
>>>>>>>>>>>>>> maybe
>>>>>>>>>>>>>> what
>>>>>>>>>>>>>> you
>>>>>>>>>>>>>> say
>>>>>>>>>>>>>> its rigth and it register the handler
>>>>>>>>>>>>>> so i gonna register the services so i do this
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>       public static void main(String[] args) throws Exception
>>>>>>>>>>>>>> {
>>>>>>>>>>>>>>               DOMConfigurator.configure("D:/Mis
>>>>>>>>>>>>>> documentos/NetBeansProjects/Factura/src/factura/log4j.xml");
>>>>>>>>>>>>>>               logger.info("Entering application.");
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>>> CLibJPEGImageReaderSpi());
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>>> CLibJPEGImageWriterSpi());
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> also after register my services it telling me that the class
>>>>>>>>>>>>>> CLibJPEGImageReaderSpi() and CLibJPEGImageWriterSpi() is
>>>>>>>>>>>>>> missing
>>>>>>>>>>>>>> but
>>>>>>>>>>>>>> only
>>>>>>>>>>>>>> in
>>>>>>>>>>>>>> command
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> after register mi service, something more has to be done??
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>                           
>>>>>>>>>>>>>>> I'm not sure I'm following correctly: does removing the
>>>>>>>>>>>>>>> xmlgraphics
>>>>>>>>>>>>>>> jar
>>>>>>>>>>>>>>> cause netbeans to behave the same as the command-line run of
>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>> app?
>>>>>>>>>>>>>>> If
>>>>>>>>>>>>>>> so, I suspect netbeans is registering services for you. 
>>>>>>>>>>>>>>> Your
>>>>>>>>>>>>>>> own
>>>>>>>>>>>>>>> code
>>>>>>>>>>>>>>> will have to make a call to one of the
>>>>>>>>>>>>>>> IIORegistry.registerServiceProvider() methods.
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> On 06/13/2011 05:02 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>                             
>>>>>>>>>>>>>>>> Ok aaaa i get it, actually the ImageIO library i added
>>>>>>>>>>>>>>>> because
>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>> read
>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>> xmlgrapics that if something like the message
>>>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException: Cannot
>>>>>>>>>>>>>>>> load
>>>>>>>>>>>>>>>> image
>>>>>>>>>>>>>>>> (no
>>>>>>>>>>>>>>>> suitable loader/converter combination available)appear i
>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>> add
>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>> jar
>>>>>>>>>>>>>>>> file to the classpath but that all it say no configuration
>>>>>>>>>>>>>>>> or
>>>>>>>>>>>>>>>> anything,
>>>>>>>>>>>>>>>> then
>>>>>>>>>>>>>>>> i delete the imagenIO libs and still i have the same output
>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>> netbeans
>>>>>>>>>>>>>>>> so
>>>>>>>>>>>>>>>> xmlgrapics seem to have the problem in the plugins or i
>>>>>>>>>>>>>>>> have to
>>>>>>>>>>>>>>>> configure
>>>>>>>>>>>>>>>> something
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>                               
>>>>>>>>>>>>>>>>> Then it seems to me netbeans (if it's producing good
>>>>>>>>>>>>>>>>> output ==
>>>>>>>>>>>>>>>>> assumptionA) is still using something that the
>>>>>>>>>>>>>>>>> command-line
>>>>>>>>>>>>>>>>> isn't.
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> And given assumptionA, you're java code is correct in
>>>>>>>>>>>>>>>>> terms of
>>>>>>>>>>>>>>>>> FOP
>>>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>>>> your configuration isn't for ImageIO.  Show your ImageIO
>>>>>>>>>>>>>>>>> related
>>>>>>>>>>>>>>>>> code
>>>>>>>>>>>>>>>>> and are you sure it's in your app.  Use the logger to show
>>>>>>>>>>>>>>>>> a
>>>>>>>>>>>>>>>>> message
>>>>>>>>>>>>>>>>> when you add  your loader.  Or list all ImageIO services:
>>>>>>>>>>>>>>>>> IIORegistry.getServiceProviders()
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> On 06/13/2011 03:01 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>                                 
>>>>>>>>>>>>>>>>>> ok well i put the xml in scr of my proyect i see that i
>>>>>>>>>>>>>>>>>> still
>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>> same
>>>>>>>>>>>>>>>>>> issues of the image render of any image i dont now if the
>>>>>>>>>>>>>>>>>> xml
>>>>>>>>>>>>>>>>>> its
>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>> place i
>>>>>>>>>>>>>>>>>> put the code down to see if something its missing
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> 15:45:07,827 ERROR [render] Error while processing image:
>>>>>>>>>>>>>>>>>> c:\cfd\nombregp.bmp (i
>>>>>>>>>>>>>>>>>> mage/bmp)
>>>>>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException:
>>>>>>>>>>>>>>>>>> Cannot
>>>>>>>>>>>>>>>>>> load
>>>>>>>>>>>>>>>>>> image
>>>>>>>>>>>>>>>>>> (no
>>>>>>>>>>>>>>>>>> suitab
>>>>>>>>>>>>>>>>>> le loader/converter combination available) for
>>>>>>>>>>>>>>>>>> c:\cfd\nombregp.bmp
>>>>>>>>>>>>>>>>>> (image/bmp)
>>>>>>>>>>>>>>>>>>                at
>>>>>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageManager.getImage(ImageManage
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> import mx.bigdata.sat.cfd.schema.Comprobante;
>>>>>>>>>>>>>>>>>> import mx.bigdata.sat.cfd.CFDv2;
>>>>>>>>>>>>>>>>>> import mx.bigdata.sat.security.KeyLoader;
>>>>>>>>>>>>>>>>>> import org.jdom.*;
>>>>>>>>>>>>>>>>>> import org.jdom.input.SAXBuilder;
>>>>>>>>>>>>>>>>>> import org.jdom.output.XMLOutputter;
>>>>>>>>>>>>>>>>>> import org.jdom.output.Format;
>>>>>>>>>>>>>>>>>> import org.jdom.transform.JDOMSource;
>>>>>>>>>>>>>>>>>> //Java
>>>>>>>>>>>>>>>>>>         import java.io.File;
>>>>>>>>>>>>>>>>>>         import java.io.OutputStream;
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>         //JAXP
>>>>>>>>>>>>>>>>>>         import javax.xml.transform.Transformer;
>>>>>>>>>>>>>>>>>>         import javax.xml.transform.TransformerFactory;
>>>>>>>>>>>>>>>>>>         import javax.xml.transform.Source;
>>>>>>>>>>>>>>>>>>         import javax.xml.transform.Result;
>>>>>>>>>>>>>>>>>>         import javax.xml.transform.stream.StreamSource;
>>>>>>>>>>>>>>>>>>         import javax.xml.transform.sax.SAXResult;
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>         //FOP
>>>>>>>>>>>>>>>>>>         import org.apache.fop.apps.FOUserAgent;
>>>>>>>>>>>>>>>>>>         import org.apache.fop.apps.Fop;
>>>>>>>>>>>>>>>>>>         import org.apache.fop.apps.FopFactory;
>>>>>>>>>>>>>>>>>>         import org.apache.fop.apps.MimeConstants;
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>         //log4j
>>>>>>>>>>>>>>>>>>         import org.apache.log4j.*;
>>>>>>>>>>>>>>>>>>         import org.apache.log4j.xml.DOMConfigurator;
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> public final class Main {
>>>>>>>>>>>>>>>>>>            @SuppressWarnings("unchecked")
>>>>>>>>>>>>>>>>>>            static Logger logger =
>>>>>>>>>>>>>>>>>> Logger.getLogger(Main.class);
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>            public static void main(String[] args) throws
>>>>>>>>>>>>>>>>>> Exception
>>>>>>>>>>>>>>>>>> {
>>>>>>>>>>>>>>>>>>                 DOMConfigurator.configure("D:/Mis
>>>>>>>>>>>>>>>>>> documentos/NetBeansProjects/Factura/src/factura/log4j.xml");
>>>>>>>>>>>>>>>>>>                 logger.info("Entering application.");
>>>>>>>>>>>>>>>>>>                 try {
>>>>>>>>>>>>>>>>>>                    File file = new File(args[0]);
>>>>>>>>>>>>>>>>>>                    Comprobante comp =
>>>>>>>>>>>>>>>>>> CFDv2.newComprobante(new
>>>>>>>>>>>>>>>>>> FileInputStream(file));
>>>>>>>>>>>>>>>>>>                    CFDv2 cfd = new CFDv2(comp);
>>>>>>>>>>>>>>>>>>                    PrivateKey key =
>>>>>>>>>>>>>>>>>> KeyLoader.loadPKCS8PrivateKey(new
>>>>>>>>>>>>>>>>>> FileInputStream(args[1]),(args[2]));
>>>>>>>>>>>>>>>>>>                    X509Certificate cert =
>>>>>>>>>>>>>>>>>> KeyLoader.loadX509Certificate(new
>>>>>>>>>>>>>>>>>> FileInputStream(args[3]));
>>>>>>>>>>>>>>>>>>                    Comprobante sellado =
>>>>>>>>>>>>>>>>>> cfd.sellarComprobante(key,
>>>>>>>>>>>>>>>>>> cert);
>>>>>>>>>>>>>>>>>>                    String cadena =
>>>>>>>>>>>>>>>>>> cfd.getCadenaOriginal();
>>>>>>>>>>>>>>>>>>                    String sello = sellado.getSello();
>>>>>>>>>>>>>>>>>>                    // Creamos el builder basado en SAX
>>>>>>>>>>>>>>>>>>                    SAXBuilder builder = new SAXBuilder();
>>>>>>>>>>>>>>>>>>                    // Construimos el arbol DOM a partir
>>>>>>>>>>>>>>>>>> del
>>>>>>>>>>>>>>>>>> fichero
>>>>>>>>>>>>>>>>>> xml
>>>>>>>>>>>>>>>>>>                    Document documentJDOM =
>>>>>>>>>>>>>>>>>> builder.build(new
>>>>>>>>>>>>>>>>>> FileInputStream(args[0]));
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>                    Element raiz =
>>>>>>>>>>>>>>>>>> documentJDOM.getRootElement();//toma
>>>>>>>>>>>>>>>>>> el
>>>>>>>>>>>>>>>>>> nodo
>>>>>>>>>>>>>>>>>> raiz
>>>>>>>>>>>>>>>>>> del documento.
>>>>>>>>>>>>>>>>>>                    raiz.setAttribute("sello", sello);
>>>>>>>>>>>>>>>>>>                    raiz.setAttribute("certificado",
>>>>>>>>>>>>>>>>>> sellado.getCertificado());
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> //System.out.println(raiz.getAttributeValue("sello"));
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> //System.out.println(raiz.getAttributeValue("certificado"));
>>>>>>>>>>>>>>>>>>                    // Recorremos los hijos de la etiqueta
>>>>>>>>>>>>>>>>>> raíz
>>>>>>>>>>>>>>>>>>                    List<Element>        hijosRaiz =
>>>>>>>>>>>>>>>>>> raiz.getChildren();
>>>>>>>>>>>>>>>>>>                    boolean Bandera=false;
>>>>>>>>>>>>>>>>>>                    for(Element hijo: hijosRaiz)
>>>>>>>>>>>>>>>>>>                    {
>>>>>>>>>>>>>>>>>>                        // Obtenemos el nombre y su
>>>>>>>>>>>>>>>>>> contenido
>>>>>>>>>>>>>>>>>> de
>>>>>>>>>>>>>>>>>> tipo
>>>>>>>>>>>>>>>>>> texto
>>>>>>>>>>>>>>>>>>                        String nombre = hijo.getName();
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>                        if (nombre.equals("Addenda"))
>>>>>>>>>>>>>>>>>>                        {   List<Element>        subHijo =
>>>>>>>>>>>>>>>>>> hijo.getChildren();
>>>>>>>>>>>>>>>>>>                            for(Element hij: subHijo)
>>>>>>>>>>>>>>>>>>                                {
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> hij.setAttribute("CadenaOriginal",
>>>>>>>>>>>>>>>>>> cadena);
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> //System.out.println("CadenaOriginal:
>>>>>>>>>>>>>>>>>> "+hij.getAttributeValue("CadenaOriginal"));
>>>>>>>>>>>>>>>>>>                                Bandera=true;
>>>>>>>>>>>>>>>>>>                                break;
>>>>>>>>>>>>>>>>>>                                }
>>>>>>>>>>>>>>>>>>                        }
>>>>>>>>>>>>>>>>>>                        if (Bandera)
>>>>>>>>>>>>>>>>>>                        {
>>>>>>>>>>>>>>>>>>                            XMLOutputter out = new
>>>>>>>>>>>>>>>>>> XMLOutputter(Format.getPrettyFormat());
>>>>>>>>>>>>>>>>>>                            File nuevoXML = new
>>>>>>>>>>>>>>>>>> File(args[0]);
>>>>>>>>>>>>>>>>>>                            try{
>>>>>>>>>>>>>>>>>>                                FileOutputStream
>>>>>>>>>>>>>>>>>> archivoXML=
>>>>>>>>>>>>>>>>>> new
>>>>>>>>>>>>>>>>>> FileOutputStream
>>>>>>>>>>>>>>>>>> (nuevoXML);
>>>>>>>>>>>>>>>>>>                                out.output(documentJDOM,
>>>>>>>>>>>>>>>>>> archivoXML);
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>                               }
>>>>>>>>>>>>>>>>>>                            catch (Exception
>>>>>>>>>>>>>>>>>> ex){System.out.println(ex.getMessage());}
>>>>>>>>>>>>>>>>>>                            // Para generar el pdf a
>>>>>>>>>>>>>>>>>> partir de
>>>>>>>>>>>>>>>>>> un
>>>>>>>>>>>>>>>>>> archivo.xsl
>>>>>>>>>>>>>>>>>> y
>>>>>>>>>>>>>>>>>> un
>>>>>>>>>>>>>>>>>>                            // archivo.xml
>>>>>>>>>>>>>>>>>>                        }
>>>>>>>>>>>>>>>>>>                      }
>>>>>>>>>>>>>>>>>>                  // configure fopFactory as desired
>>>>>>>>>>>>>>>>>>                  FopFactory fopFactory =
>>>>>>>>>>>>>>>>>> FopFactory.newInstance();
>>>>>>>>>>>>>>>>>>                  FOUserAgent foUserAgent =
>>>>>>>>>>>>>>>>>> fopFactory.newFOUserAgent();
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>                  // configure foUserAgent as desired
>>>>>>>>>>>>>>>>>>                  // Setup output
>>>>>>>>>>>>>>>>>>                 File pdffile = new File(args[5]);
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>                 OutputStream out = new
>>>>>>>>>>>>>>>>>> java.io.FileOutputStream(pdffile);
>>>>>>>>>>>>>>>>>>                 out = new
>>>>>>>>>>>>>>>>>> java.io.BufferedOutputStream(out);
>>>>>>>>>>>>>>>>>>                 try {
>>>>>>>>>>>>>>>>>>                        // Construct fop with desired
>>>>>>>>>>>>>>>>>> output
>>>>>>>>>>>>>>>>>> format
>>>>>>>>>>>>>>>>>>                         Fop fop =
>>>>>>>>>>>>>>>>>> fopFactory.newFop(MimeConstants.MIME_PDF,
>>>>>>>>>>>>>>>>>> foUserAgent, out);
>>>>>>>>>>>>>>>>>>                        // Setup XSLT
>>>>>>>>>>>>>>>>>>                        TransformerFactory factory =
>>>>>>>>>>>>>>>>>> TransformerFactory.newInstance();
>>>>>>>>>>>>>>>>>>                        Transformer transformer =
>>>>>>>>>>>>>>>>>> factory.newTransformer(new
>>>>>>>>>>>>>>>>>> StreamSource(args[4]));
>>>>>>>>>>>>>>>>>>                        // Set the value of a  in the
>>>>>>>>>>>>>>>>>> stylesheet
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> transformer.setParameter("versionParam",
>>>>>>>>>>>>>>>>>> "2.0");
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>                       // Setup input for XSLT
>>>>>>>>>>>>>>>>>> transformation
>>>>>>>>>>>>>>>>>>                        Source src = new
>>>>>>>>>>>>>>>>>> JDOMSource(documentJDOM);
>>>>>>>>>>>>>>>>>>                         // Resulting SAX events (the
>>>>>>>>>>>>>>>>>> generated
>>>>>>>>>>>>>>>>>> FO)
>>>>>>>>>>>>>>>>>> must
>>>>>>>>>>>>>>>>>> be
>>>>>>>>>>>>>>>>>> piped
>>>>>>>>>>>>>>>>>> through to FOP
>>>>>>>>>>>>>>>>>>                        Result res = new
>>>>>>>>>>>>>>>>>> SAXResult(fop.getDefaultHandler());
>>>>>>>>>>>>>>>>>>                         // Start XSLT transformation and
>>>>>>>>>>>>>>>>>> FOP
>>>>>>>>>>>>>>>>>> processing
>>>>>>>>>>>>>>>>>>                       //
>>>>>>>>>>>>>>>>>> System.setProperty("java.awt.headless",
>>>>>>>>>>>>>>>>>> "true");
>>>>>>>>>>>>>>>>>>                            transformer.transform(src,
>>>>>>>>>>>>>>>>>> res);
>>>>>>>>>>>>>>>>>>                        } finally {
>>>>>>>>>>>>>>>>>>                         out.close();
>>>>>>>>>>>>>>>>>>                    }
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>                  System.out.println("Success!");
>>>>>>>>>>>>>>>>>>                 } catch (Exception e) {
>>>>>>>>>>>>>>>>>>                  e.printStackTrace(System.err);
>>>>>>>>>>>>>>>>>>                  System.exit(-1);
>>>>>>>>>>>>>>>>>>               }
>>>>>>>>>>>>>>>>>>             logger.info("Exiting application.");
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>          }
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>                                   
>>>>>>>>>>>>>>>>>>> Try this log4j.xml: Place it at the root of your jar
>>>>>>>>>>>>>>>>>>> file
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> <?xml version="1.0" encoding="UTF-8"?>
>>>>>>>>>>>>>>>>>>> <!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> <log4j:configuration
>>>>>>>>>>>>>>>>>>> xmlns:log4j="http://jakarta.apache.org/log4j/"
>>>>>>>>>>>>>>>>>>> debug="false">
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> <appender name="CONSOLE"
>>>>>>>>>>>>>>>>>>> class="org.apache.log4j.ConsoleAppender">
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> <layout class="org.apache.log4j.PatternLayout">
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> </layout>
>>>>>>>>>>>>>>>>>>> </appender>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> <category name="org">
>>>>>>>>>>>>>>>>>>> <priority value="DEBUG"/>
>>>>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>>>>> <category name="org.apache">
>>>>>>>>>>>>>>>>>>> <priority value="WARN"/>
>>>>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>>>>> <category name="org.springframework">
>>>>>>>>>>>>>>>>>>> <priority value="WARN"/>
>>>>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>>>>> <category name="org.hibernate">
>>>>>>>>>>>>>>>>>>> <priority value="DEBUG"/>
>>>>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>>>>> <category name="net">
>>>>>>>>>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>>>>> <category name="javax">
>>>>>>>>>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>>>>> <category name="java">
>>>>>>>>>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>>>>> <category name="sun">
>>>>>>>>>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>>>>> <category name="org.jboss">
>>>>>>>>>>>>>>>>>>> <priority value="INFO"/>
>>>>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>>>>> <category name="org.jboss.seam">
>>>>>>>>>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>>>>> <root>
>>>>>>>>>>>>>>>>>>> <appender-ref ref="CONSOLE"/>
>>>>>>>>>>>>>>>>>>> </root>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> </log4j:configuration>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> On 06/13/2011 11:06 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>                                     
>>>>>>>>>>>>>>>>>>>> ok i dont thik i have a configuracion file i find the
>>>>>>>>>>>>>>>>>>>> code
>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>> put
>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>> other post i think its the basic
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>                                       
>>>>>>>>>>>>>>>>>>>>> Do you have a config file for log4j.  Usually it's in
>>>>>>>>>>>>>>>>>>>>> a
>>>>>>>>>>>>>>>>>>>>> resource
>>>>>>>>>>>>>>>>>>>>> tree.
>>>>>>>>>>>>>>>>>>>>> Are you copying that to your deployment? Is your ant
>>>>>>>>>>>>>>>>>>>>> script
>>>>>>>>>>>>>>>>>>>>> including
>>>>>>>>>>>>>>>>>>>>> the config file in the jar of your application?
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> On 06/13/2011 10:12 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>                                         
>>>>>>>>>>>>>>>>>>>>>> Ok yeah the log4j its having isuees to find the
>>>>>>>>>>>>>>>>>>>>>> configuration
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> log4j:WARN No appenders could be found for logger
>>>>>>>>>>>>>>>>>>>>>> (org.apache.fop.util.ContentHandlerFactoryRegistry).
>>>>>>>>>>>>>>>>>>>>>> log4j:WARN Please initialize the log4j system
>>>>>>>>>>>>>>>>>>>>>> properly.
>>>>>>>>>>>>>>>>>>>>>> log4j:WARN See
>>>>>>>>>>>>>>>>>>>>>> http://logging.apache.org/log4j/1.2/faq.html#noconfig
>>>>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>>>>> more info.
>>>>>>>>>>>>>>>>>>>>>> i go to the faq guide and it say try loading the
>>>>>>>>>>>>>>>>>>>>>> class or
>>>>>>>>>>>>>>>>>>>>>> resource
>>>>>>>>>>>>>>>>>>>>>> yourself.
>>>>>>>>>>>>>>>>>>>>>> If you can't find it, neither will log4j.
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> aaa i dont know where to set this
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> also here its my xlst
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> http://old.nabble.com/file/p31835645/FacturasOMF.xsl
>>>>>>>>>>>>>>>>>>>>>> FacturasOMF.xsl
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> and the fo file that generate the editix
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> http://old.nabble.com/file/p31835645/Prueba.fo
>>>>>>>>>>>>>>>>>>>>>> Prueba.fo
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>                                           
>>>>>>>>>>>>>>>>>>>>>>> The first thing is to really dig into what you did
>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>> netbeans
>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>> get
>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>> to work...
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> I've forgotten what your stylesheet looked like, so
>>>>>>>>>>>>>>>>>>>>>>> maybe
>>>>>>>>>>>>>>>>>>>>>>> if
>>>>>>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>>>>>>> show
>>>>>>>>>>>>>>>>>>>>>>> us
>>>>>>>>>>>>>>>>>>>>>>> again how you're referencing your images we might
>>>>>>>>>>>>>>>>>>>>>>> notice
>>>>>>>>>>>>>>>>>>>>>>> a
>>>>>>>>>>>>>>>>>>>>>>> problem.
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> It might also help to see the "fo" generated during
>>>>>>>>>>>>>>>>>>>>>>> your
>>>>>>>>>>>>>>>>>>>>>>> transformation.
>>>>>>>>>>>>>>>>>>>>>>> Can you grab that just after xslt and just before
>>>>>>>>>>>>>>>>>>>>>>> fop
>>>>>>>>>>>>>>>>>>>>>>> calls.
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> Are you sure there is no error being logged
>>>>>>>>>>>>>>>>>>>>>>> somewhere
>>>>>>>>>>>>>>>>>>>>>>> when
>>>>>>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>>>>>>> run
>>>>>>>>>>>>>>>>>>>>>>> from
>>>>>>>>>>>>>>>>>>>>>>> the command line? (Where is log4j writing and at
>>>>>>>>>>>>>>>>>>>>>>> what
>>>>>>>>>>>>>>>>>>>>>>> level?)
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>                                             
>>>>>>>>>>>>>>>>>>>>>>>> You where absolutly rigth i miss a few libraries to
>>>>>>>>>>>>>>>>>>>>>>>> add
>>>>>>>>>>>>>>>>>>>>>>>> into
>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>> jar
>>>>>>>>>>>>>>>>>>>>>>>> file, i
>>>>>>>>>>>>>>>>>>>>>>>> modified the build.xml to add the package and jar
>>>>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>> need,
>>>>>>>>>>>>>>>>>>>>>>>> now
>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>> error
>>>>>>>>>>>>>>>>>>>>>>>> message is not there but still the images dont show
>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>> remeber
>>>>>>>>>>>>>>>>>>>>>>>> that i do something in netbeans so they can add to
>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>>>>>>>> but
>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>> cant
>>>>>>>>>>>>>>>>>>>>>>>> remeber i dont now if there is still a library that
>>>>>>>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>>>>>>>> missing
>>>>>>>>>>>>>>>>>>>>>>>> or
>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>> am
>>>>>>>>>>>>>>>>>>>>>>>> adding more than it should be
>>>>>>>>>>>>>>>>>>>>>>>> This is what i use :
>>>>>>>>>>>>>>>>>>>>>>>> cfdi-base-0.1.6-SNAPSHOT.jar
>>>>>>>>>>>>>>>>>>>>>>>> guava-r09.jar
>>>>>>>>>>>>>>>>>>>>>>>> guava-r09-gwt.jar
>>>>>>>>>>>>>>>>>>>>>>>> jaxb-impl-2.1.10.jar
>>>>>>>>>>>>>>>>>>>>>>>> avalon-framework-api-4.3.jar
>>>>>>>>>>>>>>>>>>>>>>>> avalon-framework-cvs-20020806.jar
>>>>>>>>>>>>>>>>>>>>>>>> avalon-logkit-2.1.jar
>>>>>>>>>>>>>>>>>>>>>>>> not-yet-commons-ssl-0.3.11.jar
>>>>>>>>>>>>>>>>>>>>>>>> commons-codec-1.5.jar
>>>>>>>>>>>>>>>>>>>>>>>> commons-codec-1.5-sources.jar
>>>>>>>>>>>>>>>>>>>>>>>> log4j-1.2.16.jar
>>>>>>>>>>>>>>>>>>>>>>>> fop.jar
>>>>>>>>>>>>>>>>>>>>>>>> jdom.jar
>>>>>>>>>>>>>>>>>>>>>>>> xmlgraphics-commons-1.4.jar
>>>>>>>>>>>>>>>>>>>>>>>> commons-io-1.3.1.jar
>>>>>>>>>>>>>>>>>>>>>>>> fop-pdf-images-2.0.1.SNAPSHOT.jar
>>>>>>>>>>>>>>>>>>>>>>>> pdfbox-app-1.5.0.jar
>>>>>>>>>>>>>>>>>>>>>>>> fontbox-1.3.1.jar
>>>>>>>>>>>>>>>>>>>>>>>> jempbox-1.3.1.jar
>>>>>>>>>>>>>>>>>>>>>>>> xercesImpl-2.7.1.jar
>>>>>>>>>>>>>>>>>>>>>>>> batik-all-1.7.jar
>>>>>>>>>>>>>>>>>>>>>>>> xml-apis-1.3.04.jar
>>>>>>>>>>>>>>>>>>>>>>>> xml-apis-ext-1.3.04.jar
>>>>>>>>>>>>>>>>>>>>>>>>           avalon-framework-4.2.0.jar
>>>>>>>>>>>>>>>>>>>>>>>>           xalan-2.7.0.jar
>>>>>>>>>>>>>>>>>>>>>>>>           serializer-2.7.0.jar
>>>>>>>>>>>>>>>>>>>>>>>>           commons-logging-1.0.4.jar
>>>>>>>>>>>>>>>>>>>>>>>>           jai_codec.jar
>>>>>>>>>>>>>>>>>>>>>>>>           jai_core.jar
>>>>>>>>>>>>>>>>>>>>>>>>           batik-ext.jar
>>>>>>>>>>>>>>>>>>>>>>>>           jai_imageio-1.1-sources.jar
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> Thanks Rob for the help
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>                                               
>>>>>>>>>>>>>>>>>>>>>>>>> I suspect running from your jar does not have/use
>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>> same
>>>>>>>>>>>>>>>>>>>>>>>>> classpath
>>>>>>>>>>>>>>>>>>>>>>>>> that is in effect while you're in the debugger.
>>>>>>>>>>>>>>>>>>>>>>>>> By what mechanism do you generate the jar?
>>>>>>>>>>>>>>>>>>>>>>>>> Is it an executable jar or are you running java
>>>>>>>>>>>>>>>>>>>>>>>>> -classpath
>>>>>>>>>>>>>>>>>>>>>>>>> <your-jar-here:other-jars>          Main?
>>>>>>>>>>>>>>>>>>>>>>>>> Make your IDE (netbeans) display the classpath  it
>>>>>>>>>>>>>>>>>>>>>>>>> uses
>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>> run
>>>>>>>>>>>>>>>>>>>>>>>>> your
>>>>>>>>>>>>>>>>>>>>>>>>> app
>>>>>>>>>>>>>>>>>>>>>>>>> and compare that with the above.
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> On 06/09/2011 07:21 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>                                                 
>>>>>>>>>>>>>>>>>>>>>>>>>> aaa ok well my problem is that when i do the pdf
>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>> netbean
>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>>>>>>>>>> fine
>>>>>>>>>>>>>>>>>>>>>>>>>> with images and evething but when i run the jar
>>>>>>>>>>>>>>>>>>>>>>>>>> file
>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>> command
>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>> give
>>>>>>>>>>>>>>>>>>>>>>>>>> me a
>>>>>>>>>>>>>>>>>>>>>>>>>> error
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> GRAVE: Error while processing image:
>>>>>>>>>>>>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException:
>>>>>>>>>>>>>>>>>>>>>>>>>> Cannot
>>>>>>>>>>>>>>>>>>>>>>>>>> load
>>>>>>>>>>>>>>>>>>>>>>>>>>            image (no suitable loader/converter
>>>>>>>>>>>>>>>>>>>>>>>>>> combination
>>>>>>>>>>>>>>>>>>>>>>>>>> available)
>>>>>>>>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>>>>>>>            (image/jpeg)
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> so i dont no what its not working and if i have
>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>> add
>>>>>>>>>>>>>>>>>>>>>>>>>> something
>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>> my
>>>>>>>>>>>>>>>>>>>>>>>>>> code
>>>>>>>>>>>>>>>>>>>>>>>>>> so the images can load i am soooo desperate what
>>>>>>>>>>>>>>>>>>>>>>>>>> i am
>>>>>>>>>>>>>>>>>>>>>>>>>> doing
>>>>>>>>>>>>>>>>>>>>>>>>>> wrong??
>>>>>>>>>>>>>>>>>>>>>>>>>> i am sorry for the trouble and if a dont explain
>>>>>>>>>>>>>>>>>>>>>>>>>> my
>>>>>>>>>>>>>>>>>>>>>>>>>> self
>>>>>>>>>>>>>>>>>>>>>>>>>> very
>>>>>>>>>>>>>>>>>>>>>>>>>> good
>>>>>>>>>>>>>>>>>>>>>>>>>> jejeje
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>                                                   
>>>>>>>>>>>>>>>>>>>>>>>>>>> Not at all sure what your problem is.  All I can
>>>>>>>>>>>>>>>>>>>>>>>>>>> do
>>>>>>>>>>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>>>>>>>>>>> show
>>>>>>>>>>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>>>>>>>>>>> what
>>>>>>>>>>>>>>>>>>>>>>>>>>> works for us.
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> Our source xml looks like this:
>>>>>>>>>>>>>>>>>>>>>>>>>>> <image image-id="381623861"
>>>>>>>>>>>>>>>>>>>>>>>>>>> reference-id="ref-220"
>>>>>>>>>>>>>>>>>>>>>>>>>>> width="750"
>>>>>>>>>>>>>>>>>>>>>>>>>>> height="750" image-space-id="space-1"
>>>>>>>>>>>>>>>>>>>>>>>>>>> position="5"
>>>>>>>>>>>>>>>>>>>>>>>>>>>                         image-pool-position="31"
>>>>>>>>>>>>>>>>>>>>>>>>>>> pos="4"
>>>>>>>>>>>>>>>>>>>>>>>>>>>                        
>>>>>>>>>>>>>>>>>>>>>>>>>>> file="ref_10_1002108221">
>>>>>>>>>>>>>>>>>>>>>>>>>>> <!--
>>>>>>>>>>>>>>>>>>>>>>>>>>> an
>>>>>>>>>>>>>>>>>>>>>>>>>>> actual
>>>>>>>>>>>>>>>>>>>>>>>>>>> file
>>>>>>>>>>>>>>>>>>>>>>>>>>> (.jpeg
>>>>>>>>>>>>>>>>>>>>>>>>>>> copied the working directory of the transformer
>>>>>>>>>>>>>>>>>>>>>>>>>>> -->
>>>>>>>>>>>>>>>>>>>>>>>>>>> <fields />
>>>>>>>>>>>>>>>>>>>>>>>>>>> <caption />
>>>>>>>>>>>>>>>>>>>>>>>>>>> <annotations>
>>>>>>>>>>>>>>>>>>>>>>>>>>> <arrow_positions origHeight="750"
>>>>>>>>>>>>>>>>>>>>>>>>>>> origWidth="750" />
>>>>>>>>>>>>>>>>>>>>>>>>>>> </annotations>
>>>>>>>>>>>>>>>>>>>>>>>>>>> </image>
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> Our xslt looks like this for each image needed.
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> <xsl:template name="image">
>>>>>>>>>>>>>>>>>>>>>>>>>>> <xsl:param name="img"/>           <!-- This is
>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>> xml
>>>>>>>>>>>>>>>>>>>>>>>>>>> node
>>>>>>>>>>>>>>>>>>>>>>>>>>> from
>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>> source
>>>>>>>>>>>>>>>>>>>>>>>>>>> xml
>>>>>>>>>>>>>>>>>>>>>>>>>>> above -->
>>>>>>>>>>>>>>>>>>>>>>>>>>> <xsl:param name="width"/>
>>>>>>>>>>>>>>>>>>>>>>>>>>> <xsl:param name="height" select="$width"/>
>>>>>>>>>>>>>>>>>>>>>>>>>>> <xsl:param name="ignoreHeight">false</xsl:param>
>>>>>>>>>>>>>>>>>>>>>>>>>>> <fo:block>
>>>>>>>>>>>>>>>>>>>>>>>>>>> <fo:external-graphic src="{$img/@file}"
>>>>>>>>>>>>>>>>>>>>>>>>>>> height="{$height}"
>>>>>>>>>>>>>>>>>>>>>>>>>>> width="{$width}" content-height="scale-to-fit"
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> content-width="scale-to-fit"
>>>>>>>>>>>>>>>>>>>>>>>>>>> border="0.5pt solid black"
>>>>>>>>>>>>>>>>>>>>>>>>>>> border-collapse="separate">
>>>>>>>>>>>>>>>>>>>>>>>>>>> <xsl:if test="$ignoreHeight != 'true'">
>>>>>>>>>>>>>>>>>>>>>>>>>>> <xsl:attribute name="height">
>>>>>>>>>>>>>>>>>>>>>>>>>>> <xsl:value-of select="$height"/>
>>>>>>>>>>>>>>>>>>>>>>>>>>> </xsl:attribute>
>>>>>>>>>>>>>>>>>>>>>>>>>>> </xsl:if>
>>>>>>>>>>>>>>>>>>>>>>>>>>> </fo:external-graphic>
>>>>>>>>>>>>>>>>>>>>>>>>>>> </fo:block>
>>>>>>>>>>>>>>>>>>>>>>>>>>> </xsl:template>
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> Our generated fo looks like this:
>>>>>>>>>>>>>>>>>>>>>>>>>>> <fo:table-cell>
>>>>>>>>>>>>>>>>>>>>>>>>>>> <fo:block>
>>>>>>>>>>>>>>>>>>>>>>>>>>> <fo:external-graphic border-collapse="separate"
>>>>>>>>>>>>>>>>>>>>>>>>>>> border="0.5pt
>>>>>>>>>>>>>>>>>>>>>>>>>>> solid
>>>>>>>>>>>>>>>>>>>>>>>>>>> black" content-width="scale-to-fit"
>>>>>>>>>>>>>>>>>>>>>>>>>>> content-height="scale-to-fit"
>>>>>>>>>>>>>>>>>>>>>>>>>>> width="2.5in" height="2.5in"
>>>>>>>>>>>>>>>>>>>>>>>>>>> src="ref_10_1002108221"
>>>>>>>>>>>>>>>>>>>>>>>>>>> />
>>>>>>>>>>>>>>>>>>>>>>>>>>> </fo:block>
>>>>>>>>>>>>>>>>>>>>>>>>>>> </fo:table-cell>
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> And the generated pdfs include the image and are
>>>>>>>>>>>>>>>>>>>>>>>>>>> shipped
>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>> printer.
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> How does this stack up with what you have?
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/09/2011 01:19 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                     
>>>>>>>>>>>>>>>>>>>>>>>>>>>> Hi there well i still got the problem but
>>>>>>>>>>>>>>>>>>>>>>>>>>>> searching
>>>>>>>>>>>>>>>>>>>>>>>>>>>> IN
>>>>>>>>>>>>>>>>>>>>>>>>>>>> INTERNET
>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>> find
>>>>>>>>>>>>>>>>>>>>>>>>>>>> a
>>>>>>>>>>>>>>>>>>>>>>>>>>>> JPEG
>>>>>>>>>>>>>>>>>>>>>>>>>>>> renderer output for FOP its here
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> http://marc.info/?l=fop-user&m=125986752706366&w=2
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> the cuestion is can i render the image that i
>>>>>>>>>>>>>>>>>>>>>>>>>>>> want
>>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>>> put
>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>> pdf,
>>>>>>>>>>>>>>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>>>>>>>>>>>>>>> then add to the xsl the render jpeg it will
>>>>>>>>>>>>>>>>>>>>>>>>>>>> work??
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> and here explaints how use the render when he
>>>>>>>>>>>>>>>>>>>>>>>>>>>> say
>>>>>>>>>>>>>>>>>>>>>>>>>>>> uses
>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop
>>>>>>>>>>>>>>>>>>>>>>>>>>>> as
>>>>>>>>>>>>>>>>>>>>>>>>>>>> normal
>>>>>>>>>>>>>>>>>>>>>>>>>>>> case
>>>>>>>>>>>>>>>>>>>>>>>>>>>> what does it mean
>>>>>>>>>>>>>>>>>>>>>>>>>>>> what else have to add to the code?? i hope you
>>>>>>>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>>>>>>>> help
>>>>>>>>>>>>>>>>>>>>>>>>>>>> me
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> Thanks!!
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> // OutputStream out = what you want
>>>>>>>>>>>>>>>>>>>>>>>>>>>>                        FopFactory fopFactory =
>>>>>>>>>>>>>>>>>>>>>>>>>>>> FopFactory.newInstance();
>>>>>>>>>>>>>>>>>>>>>>>>>>>>                        RendererFactory
>>>>>>>>>>>>>>>>>>>>>>>>>>>> rendererFactory
>>>>>>>>>>>>>>>>>>>>>>>>>>>> =
>>>>>>>>>>>>>>>>>>>>>>>>>>>> null;
>>>>>>>>>>>>>>>>>>>>>>>>>>>>                        FOUserAgent foUserAgent
>>>>>>>>>>>>>>>>>>>>>>>>>>>> =
>>>>>>>>>>>>>>>>>>>>>>>>>>>> null;
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>                        rendererFactory =
>>>>>>>>>>>>>>>>>>>>>>>>>>>> fopFactory.getRendererFactory();
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> rendererFactory.addRendererMaker(new
>>>>>>>>>>>>>>>>>>>>>>>>>>>> MultiRendererMaker("jpeg"));
>>>>>>>>>>>>>>>>>>>>>>>>>>>>                        foUserAgent =
>>>>>>>>>>>>>>>>>>>>>>>>>>>> fopFactory.newFOUserAgent();
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> rendererFactory.createRenderer(foUserAgent,
>>>>>>>>>>>>>>>>>>>>>>>>>>>> "image/jpeg");
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>                        Fop fop =
>>>>>>>>>>>>>>>>>>>>>>>>>>>> fopFactory.newFop("image/jpeg",
>>>>>>>>>>>>>>>>>>>>>>>>>>>> foUserAgent,
>>>>>>>>>>>>>>>>>>>>>>>>>>>> out);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> //Use fop as normal case
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                       
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Since you're now into xmlgraphics, I think
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> you're
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> best
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> bet
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> here
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> <http://xmlgraphics.apache.org/commons/image-loader.html>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/07/2011 10:18 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                         
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Hi ok this is for generate images that dont
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> need
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> be
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> decompress
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> later??
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the result image i put in my xsl ?? then it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> should
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> work,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> aaa
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> change
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> 1.0 and xml communs 1.4 and its the same
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> jejeje
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> dont
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> find
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> image
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> preload
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> org.apache.fop.fo.flow.ExternalGraphic bind
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> SEVERE: Image not available: The file format
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> not
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> supported.
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> No
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ImagePreloader for *.jpg or *.bmp
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                           
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ImageIO.write(bufferedImage, "JPEG", file);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/07/2011 08:21 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                             
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Ok i actually register the handler now what
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> do
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> setup
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> this
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> handler or not?? and how can i do that,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> also it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> seem
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> bmp
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> its
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> not
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> recognice also what can i do?? thanks for
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> help
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> rob
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> also i am trying to convert the images to
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> see
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> if
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> helps
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                               
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/06/2011 02:29 PM, Oscar.Flores
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                 
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Hi what can be the difference between
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> execute
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> program
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> netbeans
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> (where
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it works and print the images and the jar
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> console)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                   
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Different classes being loaded by Netbeans
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> than
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> console
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> app.
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Get
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Netbeans to show you the full classpath
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it's
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> using
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it's
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> "%classpath"
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> variable
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                 
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> also i tried the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> imageIO.getImageReadersBySuffix but i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> cant
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> interpretate
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> data
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> y.y,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> its
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> that or always its true in the boolean
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> variable,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> how
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> register
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> handler??
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                   
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Talk to IIORegistry, some thing like
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> CLibJPEGImageReaderSpi());
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> CLibJPEGImageWriterSpi());
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Note: those are not necessarily the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> services
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> your
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> setup.
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                 
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Thanks
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                   
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> See the javadoc on IIORegistry. With
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ImageIO
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> may
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> register
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> your handler(s). What does
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ImageIO.getImageReadersBySuffix()
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> give
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> you.
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For certain jpegs we don't use ImageIO,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> rather
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> classes
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> com.sun.image.codec.jpeg:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                        try {
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                           
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> FileOutputStream
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fos
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> =
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> new
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> FileOutputStream(file);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                           
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> JPEGImageEncoder
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> encoder =
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> JPEGCodec.createJPEGEncoder(fos);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                           
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> JPEGEncodeParam
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> param =
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> encoder.getDefaultJPEGEncodeParam(image.getRaster(),
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> JPEGDecodeParam.COLOR_ID_CMYK);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> param.setQuality(1,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> false);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> encoder.encode(image.getRaster(),
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> param);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                            fos.close();
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                        } catch
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> (Throwable t)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> {
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> logger.debug(t.getMessage());
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                        }
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> But generally we use ImageIO
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/06/2011 08:29 AM, Oscar.Flores
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                     
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Yeah i think i need your help again i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> tried
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> tu
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> run
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> .jar
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> file
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> console it work but without images this
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> what
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> appears
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> GRAVE: Error while processing image:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Cannot
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> load
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> image
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> (no
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> suitable loader/converter combination
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> available)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i tried  download the jai-imagio add to
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> class
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> path
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> but
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> dont
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> work
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                       
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Very odd.  I'm having no problems
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> getting
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> images
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> into
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> pdfs
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> using
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-1.0.
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/03/2011 11:04 AM, Oscar.Flores
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                         
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> aaa hey thanks for the help the other
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> day,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> resolve
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> problem
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> changing
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> version of FOP for the 0.95beta
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> instead
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> of
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> 1.0,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> works
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> now
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> prints
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the image and its good, thanks and we
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> are
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> touch
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> if
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> anything
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> else
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fails
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> jejeje
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                           
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Nothing in the log from the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> transformer?
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/03/2011 09:47 AM, Oscar.Flores
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                             
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> hi there i have another problem i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> hope
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> help
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> me
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> create
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> with foe has no image, it dont show
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> any
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> of
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> them,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> xsl
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> seems
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> be
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> rigth i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> tested with EditX and the pdf show
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> me
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> image,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> what
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> be,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> xmlgraphics-commons-1.5svn, fop
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> 1.0,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-pdf-images
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> 2.0.1
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Snapshot
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> render of the image but it don work
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> please
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> help!!!
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> :,(
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                               
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                             
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                         
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                     
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                 
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> :-):confused::confused::confused::confused:=)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                               
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                             
>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                     
>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>                                                 
>>>>>>>>>>>>>>>>>>>>>>>> http://old.nabble.com/file/p31822059/libraries.jpeg
>>>>>>>>>>>>>>>>>>>>>>>> http://old.nabble.com/file/p31822059/libraries.bmp
>>>>>>>>>>>>>>>>>>>>>>>> libraries.bmp
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>                                               
>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>                                             
>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>                                         
>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>                                     
>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>                                 
>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>                             
>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>                         
>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>                     
>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>> For additional commands, e-mail:
>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>                 
>>>>> ---------------------------------------------------------------------
>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>>>
>>>>>
>>>>>
>>>>>         
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>
>>>     
>>
>>   
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
> 
> 
> 

-- 
View this message in context: http://old.nabble.com/Problems-with-FOP-and-image-tp31766430p31914806.html
Sent from the FOP - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Problems with FOP and image

Posted by Rob Sargent <rs...@xmission.com>.
Hello Pascal,

This entire thread relates to a single failure, at least in the sense 
Oscar cannot generate the desired pdf from his command-line app. Perhaps 
the recent drift to problems with his xsl are not strictly related to 
"FOP and image".  I hesitate to suggest that Oscar and I take this 
off-list because so far at least I haven't been much help to Oscar and 
maybe others will spot the real problem or perhaps ask the right questions.

Cheers,
rjs

Pascal Sancho wrote:
> Hi Rob & Oscar,
>
> I'm not sure that the initial topic of this thread is still on
> discussion (see Subject).
> Please, if it is the case, don't hack an existing one, but open a new
> thread with the right Subject, to avoid confusion for other users.
>
> Le 22/06/2011 18:49, Rob Sargent a écrit :
>   
>> It's a little tough for me to follow your xsl, but I'm suspicious of
>> your loop template: It looks to me as though you are writing empty
>> lines.  I don't think you can rely on the empty lines to be "the right
>> size". Maybe some non-breaking white space would help?
>>
>> Have you found the log file? If there's a problem, there's a report.
>> Turn up your logging if necessary.
>>
>> You might want to use the .bat file to generate the "fo" file.  This
>> shows exactly what your xsl transformation generated and is the best bet
>> at understanding any problem the fop engine is having.  The smart people
>> on this list are more likely to look at your fo than your xsl.
>>
>> On 06/21/2011 01:23 PM, Oscar.Flores wrote:
>>     
>>> Hi there yeah its the pdf that give me the fop.bat i dont know why it works
>>> this way and not from my java program anyway i am using fixed position i
>>> show you my xlst to see if you can help me to correct the size
>>>
>>> http://old.nabble.com/file/p31897144/FacturasOMF.xsl FacturasOMF.xsl
>>>
>>>
>>> Rob Sargent-4 wrote:
>>>       
>>>> Is the pdf you posted made via the .bat file then?  And it has all the
>>>> images you need? Which image is giving you all the trouble?
>>>>
>>>> I see that you are incorrectly sizing the area into which you are
>>>> putting the address of the client. Alternatively you have placed the
>>>> table of items too high.  Are you using fixed positions?
>>>> Those to pieces (client-address and invoice-items) should be in
>>>> consecutive blocks.
>>>> On 06/17/2011 09:52 AM, Oscar.Flores wrote:
>>>>         
>>>>> No i still can print the images in pdf in console what i do for now is
>>>>> call a
>>>>> bat to make the transformation with fo until i figure out what the
>>>>> problem
>>>>> is in log appear that can find a proper converter for the images
>>>>>
>>>>>
>>>>> also another problem its that the table its to big it dont fit to the
>>>>> data
>>>>> here its the pdf that result
>>>>> http://old.nabble.com/file/p31870136/Prueba3.pdf Prueba3.pdf
>>>>>
>>>>>   Warning(1979/26): fo:table, table-layout="auto" is currently not
>>>>> supported
>>>>>           
>>>>>> by FOP
>>>>>> but in my xslt it ike this<fo:table table-layout="fixed" width="100%">
>>>>>>             
>>>>> the version of fop i use its 1.0
>>>>>
>>>>>
>>>>>
>>>>> Rob Sargent-4 wrote:
>>>>>           
>>>>>> I don't think you want to read and write to the same place. If the file
>>>>>> is where you want it to be and it's otherwise in perfect shape you
>>>>>> should be fine.  But if you do want to read it in and write it to some
>>>>>> deployed area the that's what you want to do. Almost:
>>>>>>       ImageIO.write(*newImage*, "JPEG", jpegImageFile);
>>>>>>
>>>>>> So without adding the ImageIO.write() call, are you getting the pdf you
>>>>>> want yet?
>>>>>> If not, what actual errors are you seeing in the logs.
>>>>>>
>>>>>> The warning about fo:table is not causing you any trouble.  What version
>>>>>> of fop are you running (sorry I've forgotten)
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>> On 06/15/2011 02:51 PM, Oscar.Flores wrote:
>>>>>>             
>>>>>>> Hi thanks for the help yeah i haven see that its was .java and not
>>>>>>> .class, ok
>>>>>>> then if i follow correctly what you are saying then it has to be
>>>>>>> something
>>>>>>> like this
>>>>>>>
>>>>>>> BufferedImage newImage = new BufferedImage ("C:\Logo.jpg")
>>>>>>> ImageIO.write(BufferedImage, "JPEG", jpegImageFile) jpegImageFile will
>>>>>>> be
>>>>>>> the XML call rigth something like "C:\Logo.jpg")
>>>>>>>
>>>>>>> and another thing
>>>>>>>
>>>>>>>     Warning(1979/26): fo:table, table-layout="auto" is currently not
>>>>>>> supported
>>>>>>> by FOP
>>>>>>> but in my xslt it ike this<fo:table table-layout="fixed" width="100%">
>>>>>>> so
>>>>>>> i dont now what its causing the ploblem
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> Rob Sargent-4 wrote:
>>>>>>>               
>>>>>>>> On 06/14/2011 11:06 AM, Oscar.Flores wrote:
>>>>>>>>                 
>>>>>>>>> Yeah i do the class is in jai-imageio-1.1-sources.jar, the enviroment
>>>>>>>>> is
>>>>>>>>> just
>>>>>>>>>                   
>>>>>>>> Having the file in the "...sources.jar" won't do the runtime world
>>>>>>>> much
>>>>>>>> good. You need the jar of .class files for jai-imageio, not .java
>>>>>>>> files
>>>>>>>>                 
>>>>>>>>> windows xp, and the bufferedImage will be the path of the image??
>>>>>>>>>                   
>>>>>>>> No, the bufferedImage is an in-memory instance of BufferedImage
>>>>>>>> holding
>>>>>>>> the bits of the image.  In the case that you have to read it from one
>>>>>>>> place and write it to another.
>>>>>>>>                 
>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>                   
>>>>>>>>>> Did you go through all your jars looking for
>>>>>>>>>> 'CLibJPEGImageReaderSpi'.
>>>>>>>>>> My greatest suspicion is that you don't have all your jars lined up.
>>>>>>>>>> Which jar(s) do you think supplies these?
>>>>>>>>>>
>>>>>>>>>> What is your environment: just windows or do you have any tools like
>>>>>>>>>> cygwin?
>>>>>>>>>>
>>>>>>>>>> The "jpegImageFile" would be the filename in your xsl the
>>>>>>>>>> external-resource.  If you're just using a file that is already in
>>>>>>>>>> place
>>>>>>>>>> you don't have to re-write it.
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> On 06/14/2011 08:29 AM, Oscar.Flores wrote:
>>>>>>>>>>                     
>>>>>>>>>>> No i dont, and that weird jejeje netbeans seems to do that for me,
>>>>>>>>>>> so
>>>>>>>>>>> the
>>>>>>>>>>> calls like ImageIO.write(BufferedImage, "JPEG", jpegImageFile)? do
>>>>>>>>>>> i
>>>>>>>>>>> have
>>>>>>>>>>> to
>>>>>>>>>>> do it in every image that i put in the pdf?? and the image is
>>>>>>>>>>> gererate
>>>>>>>>>>> directly in the pdf??how can i do it??
>>>>>>>>>>>
>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>                       
>>>>>>>>>>>> Some jar to which netbeans has access has those classes.  Look in
>>>>>>>>>>>> the
>>>>>>>>>>>> output of jar tvf<each of your jars>     and see if any of those
>>>>>>>>>>>> has
>>>>>>>>>>>> the
>>>>>>>>>>>> named classes.  If you find a jar with those classes make sure
>>>>>>>>>>>> it's
>>>>>>>>>>>> part
>>>>>>>>>>>> of your classpath for you app.
>>>>>>>>>>>>
>>>>>>>>>>>> Are you making any calls like ImageIO.write(BufferedImage, "JPEG",
>>>>>>>>>>>> jpegImageFile)?
>>>>>>>>>>>>
>>>>>>>>>>>> On 06/13/2011 05:31 PM, Oscar.Flores wrote:
>>>>>>>>>>>>                         
>>>>>>>>>>>>> ok i made a test and tell me that the class is missign but maybe
>>>>>>>>>>>>> what
>>>>>>>>>>>>> you
>>>>>>>>>>>>> say
>>>>>>>>>>>>> its rigth and it register the handler
>>>>>>>>>>>>> so i gonna register the services so i do this
>>>>>>>>>>>>>
>>>>>>>>>>>>>       public static void main(String[] args) throws Exception {
>>>>>>>>>>>>>               DOMConfigurator.configure("D:/Mis
>>>>>>>>>>>>> documentos/NetBeansProjects/Factura/src/factura/log4j.xml");
>>>>>>>>>>>>>               logger.info("Entering application.");
>>>>>>>>>>>>>
>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>> CLibJPEGImageReaderSpi());
>>>>>>>>>>>>>
>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>> CLibJPEGImageWriterSpi());
>>>>>>>>>>>>>
>>>>>>>>>>>>> also after register my services it telling me that the class
>>>>>>>>>>>>> CLibJPEGImageReaderSpi() and CLibJPEGImageWriterSpi() is missing
>>>>>>>>>>>>> but
>>>>>>>>>>>>> only
>>>>>>>>>>>>> in
>>>>>>>>>>>>> command
>>>>>>>>>>>>>
>>>>>>>>>>>>> after register mi service, something more has to be done??
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>                           
>>>>>>>>>>>>>> I'm not sure I'm following correctly: does removing the
>>>>>>>>>>>>>> xmlgraphics
>>>>>>>>>>>>>> jar
>>>>>>>>>>>>>> cause netbeans to behave the same as the command-line run of you
>>>>>>>>>>>>>> app?
>>>>>>>>>>>>>> If
>>>>>>>>>>>>>> so, I suspect netbeans is registering services for you.  Your
>>>>>>>>>>>>>> own
>>>>>>>>>>>>>> code
>>>>>>>>>>>>>> will have to make a call to one of the
>>>>>>>>>>>>>> IIORegistry.registerServiceProvider() methods.
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> On 06/13/2011 05:02 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>                             
>>>>>>>>>>>>>>> Ok aaaa i get it, actually the ImageIO library i added because
>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>> read
>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>> xmlgrapics that if something like the message
>>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException: Cannot load
>>>>>>>>>>>>>>> image
>>>>>>>>>>>>>>> (no
>>>>>>>>>>>>>>> suitable loader/converter combination available)appear i have
>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>> add
>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>> jar
>>>>>>>>>>>>>>> file to the classpath but that all it say no configuration or
>>>>>>>>>>>>>>> anything,
>>>>>>>>>>>>>>> then
>>>>>>>>>>>>>>> i delete the imagenIO libs and still i have the same output in
>>>>>>>>>>>>>>> netbeans
>>>>>>>>>>>>>>> so
>>>>>>>>>>>>>>> xmlgrapics seem to have the problem in the plugins or i have to
>>>>>>>>>>>>>>> configure
>>>>>>>>>>>>>>> something
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>                               
>>>>>>>>>>>>>>>> Then it seems to me netbeans (if it's producing good output ==
>>>>>>>>>>>>>>>> assumptionA) is still using something that the command-line
>>>>>>>>>>>>>>>> isn't.
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> And given assumptionA, you're java code is correct in terms of
>>>>>>>>>>>>>>>> FOP
>>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>>> your configuration isn't for ImageIO.  Show your ImageIO
>>>>>>>>>>>>>>>> related
>>>>>>>>>>>>>>>> code
>>>>>>>>>>>>>>>> and are you sure it's in your app.  Use the logger to show a
>>>>>>>>>>>>>>>> message
>>>>>>>>>>>>>>>> when you add  your loader.  Or list all ImageIO services:
>>>>>>>>>>>>>>>> IIORegistry.getServiceProviders()
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> On 06/13/2011 03:01 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>                                 
>>>>>>>>>>>>>>>>> ok well i put the xml in scr of my proyect i see that i still
>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>> same
>>>>>>>>>>>>>>>>> issues of the image render of any image i dont now if the xml
>>>>>>>>>>>>>>>>> its
>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>> place i
>>>>>>>>>>>>>>>>> put the code down to see if something its missing
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> 15:45:07,827 ERROR [render] Error while processing image:
>>>>>>>>>>>>>>>>> c:\cfd\nombregp.bmp (i
>>>>>>>>>>>>>>>>> mage/bmp)
>>>>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException: Cannot
>>>>>>>>>>>>>>>>> load
>>>>>>>>>>>>>>>>> image
>>>>>>>>>>>>>>>>> (no
>>>>>>>>>>>>>>>>> suitab
>>>>>>>>>>>>>>>>> le loader/converter combination available) for
>>>>>>>>>>>>>>>>> c:\cfd\nombregp.bmp
>>>>>>>>>>>>>>>>> (image/bmp)
>>>>>>>>>>>>>>>>>                at
>>>>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageManager.getImage(ImageManage
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> import mx.bigdata.sat.cfd.schema.Comprobante;
>>>>>>>>>>>>>>>>> import mx.bigdata.sat.cfd.CFDv2;
>>>>>>>>>>>>>>>>> import mx.bigdata.sat.security.KeyLoader;
>>>>>>>>>>>>>>>>> import org.jdom.*;
>>>>>>>>>>>>>>>>> import org.jdom.input.SAXBuilder;
>>>>>>>>>>>>>>>>> import org.jdom.output.XMLOutputter;
>>>>>>>>>>>>>>>>> import org.jdom.output.Format;
>>>>>>>>>>>>>>>>> import org.jdom.transform.JDOMSource;
>>>>>>>>>>>>>>>>> //Java
>>>>>>>>>>>>>>>>>         import java.io.File;
>>>>>>>>>>>>>>>>>         import java.io.OutputStream;
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>         //JAXP
>>>>>>>>>>>>>>>>>         import javax.xml.transform.Transformer;
>>>>>>>>>>>>>>>>>         import javax.xml.transform.TransformerFactory;
>>>>>>>>>>>>>>>>>         import javax.xml.transform.Source;
>>>>>>>>>>>>>>>>>         import javax.xml.transform.Result;
>>>>>>>>>>>>>>>>>         import javax.xml.transform.stream.StreamSource;
>>>>>>>>>>>>>>>>>         import javax.xml.transform.sax.SAXResult;
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>         //FOP
>>>>>>>>>>>>>>>>>         import org.apache.fop.apps.FOUserAgent;
>>>>>>>>>>>>>>>>>         import org.apache.fop.apps.Fop;
>>>>>>>>>>>>>>>>>         import org.apache.fop.apps.FopFactory;
>>>>>>>>>>>>>>>>>         import org.apache.fop.apps.MimeConstants;
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>         //log4j
>>>>>>>>>>>>>>>>>         import org.apache.log4j.*;
>>>>>>>>>>>>>>>>>         import org.apache.log4j.xml.DOMConfigurator;
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> public final class Main {
>>>>>>>>>>>>>>>>>            @SuppressWarnings("unchecked")
>>>>>>>>>>>>>>>>>            static Logger logger =
>>>>>>>>>>>>>>>>> Logger.getLogger(Main.class);
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>            public static void main(String[] args) throws
>>>>>>>>>>>>>>>>> Exception
>>>>>>>>>>>>>>>>> {
>>>>>>>>>>>>>>>>>                 DOMConfigurator.configure("D:/Mis
>>>>>>>>>>>>>>>>> documentos/NetBeansProjects/Factura/src/factura/log4j.xml");
>>>>>>>>>>>>>>>>>                 logger.info("Entering application.");
>>>>>>>>>>>>>>>>>                 try {
>>>>>>>>>>>>>>>>>                    File file = new File(args[0]);
>>>>>>>>>>>>>>>>>                    Comprobante comp =
>>>>>>>>>>>>>>>>> CFDv2.newComprobante(new
>>>>>>>>>>>>>>>>> FileInputStream(file));
>>>>>>>>>>>>>>>>>                    CFDv2 cfd = new CFDv2(comp);
>>>>>>>>>>>>>>>>>                    PrivateKey key =
>>>>>>>>>>>>>>>>> KeyLoader.loadPKCS8PrivateKey(new
>>>>>>>>>>>>>>>>> FileInputStream(args[1]),(args[2]));
>>>>>>>>>>>>>>>>>                    X509Certificate cert =
>>>>>>>>>>>>>>>>> KeyLoader.loadX509Certificate(new
>>>>>>>>>>>>>>>>> FileInputStream(args[3]));
>>>>>>>>>>>>>>>>>                    Comprobante sellado =
>>>>>>>>>>>>>>>>> cfd.sellarComprobante(key,
>>>>>>>>>>>>>>>>> cert);
>>>>>>>>>>>>>>>>>                    String cadena = cfd.getCadenaOriginal();
>>>>>>>>>>>>>>>>>                    String sello = sellado.getSello();
>>>>>>>>>>>>>>>>>                    // Creamos el builder basado en SAX
>>>>>>>>>>>>>>>>>                    SAXBuilder builder = new SAXBuilder();
>>>>>>>>>>>>>>>>>                    // Construimos el arbol DOM a partir del
>>>>>>>>>>>>>>>>> fichero
>>>>>>>>>>>>>>>>> xml
>>>>>>>>>>>>>>>>>                    Document documentJDOM = builder.build(new
>>>>>>>>>>>>>>>>> FileInputStream(args[0]));
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>                    Element raiz =
>>>>>>>>>>>>>>>>> documentJDOM.getRootElement();//toma
>>>>>>>>>>>>>>>>> el
>>>>>>>>>>>>>>>>> nodo
>>>>>>>>>>>>>>>>> raiz
>>>>>>>>>>>>>>>>> del documento.
>>>>>>>>>>>>>>>>>                    raiz.setAttribute("sello", sello);
>>>>>>>>>>>>>>>>>                    raiz.setAttribute("certificado",
>>>>>>>>>>>>>>>>> sellado.getCertificado());
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> //System.out.println(raiz.getAttributeValue("sello"));
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> //System.out.println(raiz.getAttributeValue("certificado"));
>>>>>>>>>>>>>>>>>                    // Recorremos los hijos de la etiqueta
>>>>>>>>>>>>>>>>> raíz
>>>>>>>>>>>>>>>>>                    List<Element>        hijosRaiz =
>>>>>>>>>>>>>>>>> raiz.getChildren();
>>>>>>>>>>>>>>>>>                    boolean Bandera=false;
>>>>>>>>>>>>>>>>>                    for(Element hijo: hijosRaiz)
>>>>>>>>>>>>>>>>>                    {
>>>>>>>>>>>>>>>>>                        // Obtenemos el nombre y su contenido
>>>>>>>>>>>>>>>>> de
>>>>>>>>>>>>>>>>> tipo
>>>>>>>>>>>>>>>>> texto
>>>>>>>>>>>>>>>>>                        String nombre = hijo.getName();
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>                        if (nombre.equals("Addenda"))
>>>>>>>>>>>>>>>>>                        {   List<Element>        subHijo =
>>>>>>>>>>>>>>>>> hijo.getChildren();
>>>>>>>>>>>>>>>>>                            for(Element hij: subHijo)
>>>>>>>>>>>>>>>>>                                {
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> hij.setAttribute("CadenaOriginal",
>>>>>>>>>>>>>>>>> cadena);
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> //System.out.println("CadenaOriginal:
>>>>>>>>>>>>>>>>> "+hij.getAttributeValue("CadenaOriginal"));
>>>>>>>>>>>>>>>>>                                Bandera=true;
>>>>>>>>>>>>>>>>>                                break;
>>>>>>>>>>>>>>>>>                                }
>>>>>>>>>>>>>>>>>                        }
>>>>>>>>>>>>>>>>>                        if (Bandera)
>>>>>>>>>>>>>>>>>                        {
>>>>>>>>>>>>>>>>>                            XMLOutputter out = new
>>>>>>>>>>>>>>>>> XMLOutputter(Format.getPrettyFormat());
>>>>>>>>>>>>>>>>>                            File nuevoXML = new File(args[0]);
>>>>>>>>>>>>>>>>>                            try{
>>>>>>>>>>>>>>>>>                                FileOutputStream archivoXML=
>>>>>>>>>>>>>>>>> new
>>>>>>>>>>>>>>>>> FileOutputStream
>>>>>>>>>>>>>>>>> (nuevoXML);
>>>>>>>>>>>>>>>>>                                out.output(documentJDOM,
>>>>>>>>>>>>>>>>> archivoXML);
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>                               }
>>>>>>>>>>>>>>>>>                            catch (Exception
>>>>>>>>>>>>>>>>> ex){System.out.println(ex.getMessage());}
>>>>>>>>>>>>>>>>>                            // Para generar el pdf a partir de
>>>>>>>>>>>>>>>>> un
>>>>>>>>>>>>>>>>> archivo.xsl
>>>>>>>>>>>>>>>>> y
>>>>>>>>>>>>>>>>> un
>>>>>>>>>>>>>>>>>                            // archivo.xml
>>>>>>>>>>>>>>>>>                        }
>>>>>>>>>>>>>>>>>                      }
>>>>>>>>>>>>>>>>>                  // configure fopFactory as desired
>>>>>>>>>>>>>>>>>                  FopFactory fopFactory =
>>>>>>>>>>>>>>>>> FopFactory.newInstance();
>>>>>>>>>>>>>>>>>                  FOUserAgent foUserAgent =
>>>>>>>>>>>>>>>>> fopFactory.newFOUserAgent();
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>                  // configure foUserAgent as desired
>>>>>>>>>>>>>>>>>                  // Setup output
>>>>>>>>>>>>>>>>>                 File pdffile = new File(args[5]);
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>                 OutputStream out = new
>>>>>>>>>>>>>>>>> java.io.FileOutputStream(pdffile);
>>>>>>>>>>>>>>>>>                 out = new java.io.BufferedOutputStream(out);
>>>>>>>>>>>>>>>>>                 try {
>>>>>>>>>>>>>>>>>                        // Construct fop with desired output
>>>>>>>>>>>>>>>>> format
>>>>>>>>>>>>>>>>>                         Fop fop =
>>>>>>>>>>>>>>>>> fopFactory.newFop(MimeConstants.MIME_PDF,
>>>>>>>>>>>>>>>>> foUserAgent, out);
>>>>>>>>>>>>>>>>>                        // Setup XSLT
>>>>>>>>>>>>>>>>>                        TransformerFactory factory =
>>>>>>>>>>>>>>>>> TransformerFactory.newInstance();
>>>>>>>>>>>>>>>>>                        Transformer transformer =
>>>>>>>>>>>>>>>>> factory.newTransformer(new
>>>>>>>>>>>>>>>>> StreamSource(args[4]));
>>>>>>>>>>>>>>>>>                        // Set the value of a  in the
>>>>>>>>>>>>>>>>> stylesheet
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> transformer.setParameter("versionParam",
>>>>>>>>>>>>>>>>> "2.0");
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>                       // Setup input for XSLT transformation
>>>>>>>>>>>>>>>>>                        Source src = new
>>>>>>>>>>>>>>>>> JDOMSource(documentJDOM);
>>>>>>>>>>>>>>>>>                         // Resulting SAX events (the
>>>>>>>>>>>>>>>>> generated
>>>>>>>>>>>>>>>>> FO)
>>>>>>>>>>>>>>>>> must
>>>>>>>>>>>>>>>>> be
>>>>>>>>>>>>>>>>> piped
>>>>>>>>>>>>>>>>> through to FOP
>>>>>>>>>>>>>>>>>                        Result res = new
>>>>>>>>>>>>>>>>> SAXResult(fop.getDefaultHandler());
>>>>>>>>>>>>>>>>>                         // Start XSLT transformation and FOP
>>>>>>>>>>>>>>>>> processing
>>>>>>>>>>>>>>>>>                       //
>>>>>>>>>>>>>>>>> System.setProperty("java.awt.headless",
>>>>>>>>>>>>>>>>> "true");
>>>>>>>>>>>>>>>>>                            transformer.transform(src, res);
>>>>>>>>>>>>>>>>>                        } finally {
>>>>>>>>>>>>>>>>>                         out.close();
>>>>>>>>>>>>>>>>>                    }
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>                  System.out.println("Success!");
>>>>>>>>>>>>>>>>>                 } catch (Exception e) {
>>>>>>>>>>>>>>>>>                  e.printStackTrace(System.err);
>>>>>>>>>>>>>>>>>                  System.exit(-1);
>>>>>>>>>>>>>>>>>               }
>>>>>>>>>>>>>>>>>             logger.info("Exiting application.");
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>          }
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>                                   
>>>>>>>>>>>>>>>>>> Try this log4j.xml: Place it at the root of your jar file
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> <?xml version="1.0" encoding="UTF-8"?>
>>>>>>>>>>>>>>>>>> <!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> <log4j:configuration
>>>>>>>>>>>>>>>>>> xmlns:log4j="http://jakarta.apache.org/log4j/"
>>>>>>>>>>>>>>>>>> debug="false">
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> <appender name="CONSOLE"
>>>>>>>>>>>>>>>>>> class="org.apache.log4j.ConsoleAppender">
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> <layout class="org.apache.log4j.PatternLayout">
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> </layout>
>>>>>>>>>>>>>>>>>> </appender>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> <category name="org">
>>>>>>>>>>>>>>>>>> <priority value="DEBUG"/>
>>>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>>>> <category name="org.apache">
>>>>>>>>>>>>>>>>>> <priority value="WARN"/>
>>>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>>>> <category name="org.springframework">
>>>>>>>>>>>>>>>>>> <priority value="WARN"/>
>>>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>>>> <category name="org.hibernate">
>>>>>>>>>>>>>>>>>> <priority value="DEBUG"/>
>>>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>>>> <category name="net">
>>>>>>>>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>>>> <category name="javax">
>>>>>>>>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>>>> <category name="java">
>>>>>>>>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>>>> <category name="sun">
>>>>>>>>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>>>> <category name="org.jboss">
>>>>>>>>>>>>>>>>>> <priority value="INFO"/>
>>>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>>>> <category name="org.jboss.seam">
>>>>>>>>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>>>> <root>
>>>>>>>>>>>>>>>>>> <appender-ref ref="CONSOLE"/>
>>>>>>>>>>>>>>>>>> </root>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> </log4j:configuration>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> On 06/13/2011 11:06 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>                                     
>>>>>>>>>>>>>>>>>>> ok i dont thik i have a configuracion file i find the code
>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>> put
>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>> other post i think its the basic
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>                                       
>>>>>>>>>>>>>>>>>>>> Do you have a config file for log4j.  Usually it's in a
>>>>>>>>>>>>>>>>>>>> resource
>>>>>>>>>>>>>>>>>>>> tree.
>>>>>>>>>>>>>>>>>>>> Are you copying that to your deployment? Is your ant
>>>>>>>>>>>>>>>>>>>> script
>>>>>>>>>>>>>>>>>>>> including
>>>>>>>>>>>>>>>>>>>> the config file in the jar of your application?
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> On 06/13/2011 10:12 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>                                         
>>>>>>>>>>>>>>>>>>>>> Ok yeah the log4j its having isuees to find the
>>>>>>>>>>>>>>>>>>>>> configuration
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> log4j:WARN No appenders could be found for logger
>>>>>>>>>>>>>>>>>>>>> (org.apache.fop.util.ContentHandlerFactoryRegistry).
>>>>>>>>>>>>>>>>>>>>> log4j:WARN Please initialize the log4j system properly.
>>>>>>>>>>>>>>>>>>>>> log4j:WARN See
>>>>>>>>>>>>>>>>>>>>> http://logging.apache.org/log4j/1.2/faq.html#noconfig
>>>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>>>> more info.
>>>>>>>>>>>>>>>>>>>>> i go to the faq guide and it say try loading the class or
>>>>>>>>>>>>>>>>>>>>> resource
>>>>>>>>>>>>>>>>>>>>> yourself.
>>>>>>>>>>>>>>>>>>>>> If you can't find it, neither will log4j.
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> aaa i dont know where to set this
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> also here its my xlst
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> http://old.nabble.com/file/p31835645/FacturasOMF.xsl
>>>>>>>>>>>>>>>>>>>>> FacturasOMF.xsl
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> and the fo file that generate the editix
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> http://old.nabble.com/file/p31835645/Prueba.fo Prueba.fo
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>                                           
>>>>>>>>>>>>>>>>>>>>>> The first thing is to really dig into what you did to
>>>>>>>>>>>>>>>>>>>>>> netbeans
>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>> get
>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>> to work...
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> I've forgotten what your stylesheet looked like, so
>>>>>>>>>>>>>>>>>>>>>> maybe
>>>>>>>>>>>>>>>>>>>>>> if
>>>>>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>>>>>> show
>>>>>>>>>>>>>>>>>>>>>> us
>>>>>>>>>>>>>>>>>>>>>> again how you're referencing your images we might notice
>>>>>>>>>>>>>>>>>>>>>> a
>>>>>>>>>>>>>>>>>>>>>> problem.
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> It might also help to see the "fo" generated during your
>>>>>>>>>>>>>>>>>>>>>> transformation.
>>>>>>>>>>>>>>>>>>>>>> Can you grab that just after xslt and just before fop
>>>>>>>>>>>>>>>>>>>>>> calls.
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> Are you sure there is no error being logged somewhere
>>>>>>>>>>>>>>>>>>>>>> when
>>>>>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>>>>>> run
>>>>>>>>>>>>>>>>>>>>>> from
>>>>>>>>>>>>>>>>>>>>>> the command line? (Where is log4j writing and at what
>>>>>>>>>>>>>>>>>>>>>> level?)
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>                                             
>>>>>>>>>>>>>>>>>>>>>>> You where absolutly rigth i miss a few libraries to add
>>>>>>>>>>>>>>>>>>>>>>> into
>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>> jar
>>>>>>>>>>>>>>>>>>>>>>> file, i
>>>>>>>>>>>>>>>>>>>>>>> modified the build.xml to add the package and jar that
>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>> need,
>>>>>>>>>>>>>>>>>>>>>>> now
>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>> error
>>>>>>>>>>>>>>>>>>>>>>> message is not there but still the images dont show in
>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>> remeber
>>>>>>>>>>>>>>>>>>>>>>> that i do something in netbeans so they can add to the
>>>>>>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>>>>>>> but
>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>> cant
>>>>>>>>>>>>>>>>>>>>>>> remeber i dont now if there is still a library that is
>>>>>>>>>>>>>>>>>>>>>>> missing
>>>>>>>>>>>>>>>>>>>>>>> or
>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>> am
>>>>>>>>>>>>>>>>>>>>>>> adding more than it should be
>>>>>>>>>>>>>>>>>>>>>>> This is what i use :
>>>>>>>>>>>>>>>>>>>>>>> cfdi-base-0.1.6-SNAPSHOT.jar
>>>>>>>>>>>>>>>>>>>>>>> guava-r09.jar
>>>>>>>>>>>>>>>>>>>>>>> guava-r09-gwt.jar
>>>>>>>>>>>>>>>>>>>>>>> jaxb-impl-2.1.10.jar
>>>>>>>>>>>>>>>>>>>>>>> avalon-framework-api-4.3.jar
>>>>>>>>>>>>>>>>>>>>>>> avalon-framework-cvs-20020806.jar
>>>>>>>>>>>>>>>>>>>>>>> avalon-logkit-2.1.jar
>>>>>>>>>>>>>>>>>>>>>>> not-yet-commons-ssl-0.3.11.jar
>>>>>>>>>>>>>>>>>>>>>>> commons-codec-1.5.jar
>>>>>>>>>>>>>>>>>>>>>>> commons-codec-1.5-sources.jar
>>>>>>>>>>>>>>>>>>>>>>> log4j-1.2.16.jar
>>>>>>>>>>>>>>>>>>>>>>> fop.jar
>>>>>>>>>>>>>>>>>>>>>>> jdom.jar
>>>>>>>>>>>>>>>>>>>>>>> xmlgraphics-commons-1.4.jar
>>>>>>>>>>>>>>>>>>>>>>> commons-io-1.3.1.jar
>>>>>>>>>>>>>>>>>>>>>>> fop-pdf-images-2.0.1.SNAPSHOT.jar
>>>>>>>>>>>>>>>>>>>>>>> pdfbox-app-1.5.0.jar
>>>>>>>>>>>>>>>>>>>>>>> fontbox-1.3.1.jar
>>>>>>>>>>>>>>>>>>>>>>> jempbox-1.3.1.jar
>>>>>>>>>>>>>>>>>>>>>>> xercesImpl-2.7.1.jar
>>>>>>>>>>>>>>>>>>>>>>> batik-all-1.7.jar
>>>>>>>>>>>>>>>>>>>>>>> xml-apis-1.3.04.jar
>>>>>>>>>>>>>>>>>>>>>>> xml-apis-ext-1.3.04.jar
>>>>>>>>>>>>>>>>>>>>>>>           avalon-framework-4.2.0.jar
>>>>>>>>>>>>>>>>>>>>>>>           xalan-2.7.0.jar
>>>>>>>>>>>>>>>>>>>>>>>           serializer-2.7.0.jar
>>>>>>>>>>>>>>>>>>>>>>>           commons-logging-1.0.4.jar
>>>>>>>>>>>>>>>>>>>>>>>           jai_codec.jar
>>>>>>>>>>>>>>>>>>>>>>>           jai_core.jar
>>>>>>>>>>>>>>>>>>>>>>>           batik-ext.jar
>>>>>>>>>>>>>>>>>>>>>>>           jai_imageio-1.1-sources.jar
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> Thanks Rob for the help
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>                                               
>>>>>>>>>>>>>>>>>>>>>>>> I suspect running from your jar does not have/use the
>>>>>>>>>>>>>>>>>>>>>>>> same
>>>>>>>>>>>>>>>>>>>>>>>> classpath
>>>>>>>>>>>>>>>>>>>>>>>> that is in effect while you're in the debugger.
>>>>>>>>>>>>>>>>>>>>>>>> By what mechanism do you generate the jar?
>>>>>>>>>>>>>>>>>>>>>>>> Is it an executable jar or are you running java
>>>>>>>>>>>>>>>>>>>>>>>> -classpath
>>>>>>>>>>>>>>>>>>>>>>>> <your-jar-here:other-jars>          Main?
>>>>>>>>>>>>>>>>>>>>>>>> Make your IDE (netbeans) display the classpath  it
>>>>>>>>>>>>>>>>>>>>>>>> uses
>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>> run
>>>>>>>>>>>>>>>>>>>>>>>> your
>>>>>>>>>>>>>>>>>>>>>>>> app
>>>>>>>>>>>>>>>>>>>>>>>> and compare that with the above.
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> On 06/09/2011 07:21 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>                                                 
>>>>>>>>>>>>>>>>>>>>>>>>> aaa ok well my problem is that when i do the pdf in
>>>>>>>>>>>>>>>>>>>>>>>>> netbean
>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>>>>>>>>> fine
>>>>>>>>>>>>>>>>>>>>>>>>> with images and evething but when i run the jar file
>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>> command
>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>> give
>>>>>>>>>>>>>>>>>>>>>>>>> me a
>>>>>>>>>>>>>>>>>>>>>>>>> error
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> GRAVE: Error while processing image: I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException:
>>>>>>>>>>>>>>>>>>>>>>>>> Cannot
>>>>>>>>>>>>>>>>>>>>>>>>> load
>>>>>>>>>>>>>>>>>>>>>>>>>            image (no suitable loader/converter
>>>>>>>>>>>>>>>>>>>>>>>>> combination
>>>>>>>>>>>>>>>>>>>>>>>>> available)
>>>>>>>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>>>>>>            (image/jpeg)
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> so i dont no what its not working and if i have to
>>>>>>>>>>>>>>>>>>>>>>>>> add
>>>>>>>>>>>>>>>>>>>>>>>>> something
>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>> my
>>>>>>>>>>>>>>>>>>>>>>>>> code
>>>>>>>>>>>>>>>>>>>>>>>>> so the images can load i am soooo desperate what i am
>>>>>>>>>>>>>>>>>>>>>>>>> doing
>>>>>>>>>>>>>>>>>>>>>>>>> wrong??
>>>>>>>>>>>>>>>>>>>>>>>>> i am sorry for the trouble and if a dont explain my
>>>>>>>>>>>>>>>>>>>>>>>>> self
>>>>>>>>>>>>>>>>>>>>>>>>> very
>>>>>>>>>>>>>>>>>>>>>>>>> good
>>>>>>>>>>>>>>>>>>>>>>>>> jejeje
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>                                                   
>>>>>>>>>>>>>>>>>>>>>>>>>> Not at all sure what your problem is.  All I can do
>>>>>>>>>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>>>>>>>>>> show
>>>>>>>>>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>>>>>>>>>> what
>>>>>>>>>>>>>>>>>>>>>>>>>> works for us.
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> Our source xml looks like this:
>>>>>>>>>>>>>>>>>>>>>>>>>> <image image-id="381623861" reference-id="ref-220"
>>>>>>>>>>>>>>>>>>>>>>>>>> width="750"
>>>>>>>>>>>>>>>>>>>>>>>>>> height="750" image-space-id="space-1" position="5"
>>>>>>>>>>>>>>>>>>>>>>>>>>                         image-pool-position="31"
>>>>>>>>>>>>>>>>>>>>>>>>>> pos="4"
>>>>>>>>>>>>>>>>>>>>>>>>>>                         file="ref_10_1002108221">
>>>>>>>>>>>>>>>>>>>>>>>>>> <!--
>>>>>>>>>>>>>>>>>>>>>>>>>> an
>>>>>>>>>>>>>>>>>>>>>>>>>> actual
>>>>>>>>>>>>>>>>>>>>>>>>>> file
>>>>>>>>>>>>>>>>>>>>>>>>>> (.jpeg
>>>>>>>>>>>>>>>>>>>>>>>>>> copied the working directory of the transformer -->
>>>>>>>>>>>>>>>>>>>>>>>>>> <fields />
>>>>>>>>>>>>>>>>>>>>>>>>>> <caption />
>>>>>>>>>>>>>>>>>>>>>>>>>> <annotations>
>>>>>>>>>>>>>>>>>>>>>>>>>> <arrow_positions origHeight="750" origWidth="750" />
>>>>>>>>>>>>>>>>>>>>>>>>>> </annotations>
>>>>>>>>>>>>>>>>>>>>>>>>>> </image>
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> Our xslt looks like this for each image needed.
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> <xsl:template name="image">
>>>>>>>>>>>>>>>>>>>>>>>>>> <xsl:param name="img"/>           <!-- This is the
>>>>>>>>>>>>>>>>>>>>>>>>>> xml
>>>>>>>>>>>>>>>>>>>>>>>>>> node
>>>>>>>>>>>>>>>>>>>>>>>>>> from
>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>> source
>>>>>>>>>>>>>>>>>>>>>>>>>> xml
>>>>>>>>>>>>>>>>>>>>>>>>>> above -->
>>>>>>>>>>>>>>>>>>>>>>>>>> <xsl:param name="width"/>
>>>>>>>>>>>>>>>>>>>>>>>>>> <xsl:param name="height" select="$width"/>
>>>>>>>>>>>>>>>>>>>>>>>>>> <xsl:param name="ignoreHeight">false</xsl:param>
>>>>>>>>>>>>>>>>>>>>>>>>>> <fo:block>
>>>>>>>>>>>>>>>>>>>>>>>>>> <fo:external-graphic src="{$img/@file}"
>>>>>>>>>>>>>>>>>>>>>>>>>> height="{$height}"
>>>>>>>>>>>>>>>>>>>>>>>>>> width="{$width}" content-height="scale-to-fit"
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> content-width="scale-to-fit"
>>>>>>>>>>>>>>>>>>>>>>>>>> border="0.5pt solid black"
>>>>>>>>>>>>>>>>>>>>>>>>>> border-collapse="separate">
>>>>>>>>>>>>>>>>>>>>>>>>>> <xsl:if test="$ignoreHeight != 'true'">
>>>>>>>>>>>>>>>>>>>>>>>>>> <xsl:attribute name="height">
>>>>>>>>>>>>>>>>>>>>>>>>>> <xsl:value-of select="$height"/>
>>>>>>>>>>>>>>>>>>>>>>>>>> </xsl:attribute>
>>>>>>>>>>>>>>>>>>>>>>>>>> </xsl:if>
>>>>>>>>>>>>>>>>>>>>>>>>>> </fo:external-graphic>
>>>>>>>>>>>>>>>>>>>>>>>>>> </fo:block>
>>>>>>>>>>>>>>>>>>>>>>>>>> </xsl:template>
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> Our generated fo looks like this:
>>>>>>>>>>>>>>>>>>>>>>>>>> <fo:table-cell>
>>>>>>>>>>>>>>>>>>>>>>>>>> <fo:block>
>>>>>>>>>>>>>>>>>>>>>>>>>> <fo:external-graphic border-collapse="separate"
>>>>>>>>>>>>>>>>>>>>>>>>>> border="0.5pt
>>>>>>>>>>>>>>>>>>>>>>>>>> solid
>>>>>>>>>>>>>>>>>>>>>>>>>> black" content-width="scale-to-fit"
>>>>>>>>>>>>>>>>>>>>>>>>>> content-height="scale-to-fit"
>>>>>>>>>>>>>>>>>>>>>>>>>> width="2.5in" height="2.5in" src="ref_10_1002108221"
>>>>>>>>>>>>>>>>>>>>>>>>>> />
>>>>>>>>>>>>>>>>>>>>>>>>>> </fo:block>
>>>>>>>>>>>>>>>>>>>>>>>>>> </fo:table-cell>
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> And the generated pdfs include the image and are
>>>>>>>>>>>>>>>>>>>>>>>>>> shipped
>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>> printer.
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> How does this stack up with what you have?
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/09/2011 01:19 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>                                                     
>>>>>>>>>>>>>>>>>>>>>>>>>>> Hi there well i still got the problem but searching
>>>>>>>>>>>>>>>>>>>>>>>>>>> IN
>>>>>>>>>>>>>>>>>>>>>>>>>>> INTERNET
>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>> find
>>>>>>>>>>>>>>>>>>>>>>>>>>> a
>>>>>>>>>>>>>>>>>>>>>>>>>>> JPEG
>>>>>>>>>>>>>>>>>>>>>>>>>>> renderer output for FOP its here
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> http://marc.info/?l=fop-user&m=125986752706366&w=2
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> the cuestion is can i render the image that i want
>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>> put
>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>> pdf,
>>>>>>>>>>>>>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>>>>>>>>>>>>>> then add to the xsl the render jpeg it will work??
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> and here explaints how use the render when he say
>>>>>>>>>>>>>>>>>>>>>>>>>>> uses
>>>>>>>>>>>>>>>>>>>>>>>>>>> fop
>>>>>>>>>>>>>>>>>>>>>>>>>>> as
>>>>>>>>>>>>>>>>>>>>>>>>>>> normal
>>>>>>>>>>>>>>>>>>>>>>>>>>> case
>>>>>>>>>>>>>>>>>>>>>>>>>>> what does it mean
>>>>>>>>>>>>>>>>>>>>>>>>>>> what else have to add to the code?? i hope you can
>>>>>>>>>>>>>>>>>>>>>>>>>>> help
>>>>>>>>>>>>>>>>>>>>>>>>>>> me
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> Thanks!!
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> // OutputStream out = what you want
>>>>>>>>>>>>>>>>>>>>>>>>>>>                        FopFactory fopFactory =
>>>>>>>>>>>>>>>>>>>>>>>>>>> FopFactory.newInstance();
>>>>>>>>>>>>>>>>>>>>>>>>>>>                        RendererFactory
>>>>>>>>>>>>>>>>>>>>>>>>>>> rendererFactory
>>>>>>>>>>>>>>>>>>>>>>>>>>> =
>>>>>>>>>>>>>>>>>>>>>>>>>>> null;
>>>>>>>>>>>>>>>>>>>>>>>>>>>                        FOUserAgent foUserAgent =
>>>>>>>>>>>>>>>>>>>>>>>>>>> null;
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>                        rendererFactory =
>>>>>>>>>>>>>>>>>>>>>>>>>>> fopFactory.getRendererFactory();
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> rendererFactory.addRendererMaker(new
>>>>>>>>>>>>>>>>>>>>>>>>>>> MultiRendererMaker("jpeg"));
>>>>>>>>>>>>>>>>>>>>>>>>>>>                        foUserAgent =
>>>>>>>>>>>>>>>>>>>>>>>>>>> fopFactory.newFOUserAgent();
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> rendererFactory.createRenderer(foUserAgent,
>>>>>>>>>>>>>>>>>>>>>>>>>>> "image/jpeg");
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>                        Fop fop =
>>>>>>>>>>>>>>>>>>>>>>>>>>> fopFactory.newFop("image/jpeg",
>>>>>>>>>>>>>>>>>>>>>>>>>>> foUserAgent,
>>>>>>>>>>>>>>>>>>>>>>>>>>> out);
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> //Use fop as normal case
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                       
>>>>>>>>>>>>>>>>>>>>>>>>>>>> Since you're now into xmlgraphics, I think you're
>>>>>>>>>>>>>>>>>>>>>>>>>>>> best
>>>>>>>>>>>>>>>>>>>>>>>>>>>> bet
>>>>>>>>>>>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>>>>>>>>>>>> here
>>>>>>>>>>>>>>>>>>>>>>>>>>>> <http://xmlgraphics.apache.org/commons/image-loader.html>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/07/2011 10:18 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                         
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Hi ok this is for generate images that dont need
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> be
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> decompress
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> later??
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the result image i put in my xsl ?? then it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> should
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> work,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> aaa
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> change
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> 1.0 and xml communs 1.4 and its the same jejeje
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> dont
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> find
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> image
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> preload
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> org.apache.fop.fo.flow.ExternalGraphic bind
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> SEVERE: Image not available: The file format is
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> not
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> supported.
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> No
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ImagePreloader for *.jpg or *.bmp
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                           
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ImageIO.write(bufferedImage, "JPEG", file);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/07/2011 08:21 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                             
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Ok i actually register the handler now what i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> do
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> setup
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> this
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> handler or not?? and how can i do that, also it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> seem
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> bmp
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> its
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> not
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> recognice also what can i do?? thanks for the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> help
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> rob
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> also i am trying to convert the images to see
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> if
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> helps
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                               
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/06/2011 02:29 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                 
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Hi what can be the difference between execute
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> program
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> netbeans
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> (where
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it works and print the images and the jar in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> console)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                   
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Different classes being loaded by Netbeans
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> than
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> console
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> app.
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Get
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Netbeans to show you the full classpath it's
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> using
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it's
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> "%classpath"
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> variable
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                 
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> also i tried the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> imageIO.getImageReadersBySuffix but i cant
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> interpretate
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> data
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> y.y,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> its
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> that or always its true in the boolean
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> variable,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> how
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> register
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> handler??
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                   
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Talk to IIORegistry, some thing like
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> CLibJPEGImageReaderSpi());
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> CLibJPEGImageWriterSpi());
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Note: those are not necessarily the services
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> your
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> setup.
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                 
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Thanks
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                   
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> See the javadoc on IIORegistry. With ImageIO
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> may
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> register
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> your handler(s). What does
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ImageIO.getImageReadersBySuffix()
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> give
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> you.
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For certain jpegs we don't use ImageIO,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> rather
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> classes
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> com.sun.image.codec.jpeg:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                        try {
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                            FileOutputStream
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fos
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> =
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> new
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> FileOutputStream(file);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                            JPEGImageEncoder
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> encoder =
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> JPEGCodec.createJPEGEncoder(fos);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                            JPEGEncodeParam
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> param =
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> encoder.getDefaultJPEGEncodeParam(image.getRaster(),
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> JPEGDecodeParam.COLOR_ID_CMYK);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> param.setQuality(1,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> false);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> encoder.encode(image.getRaster(),
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> param);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                            fos.close();
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                        } catch (Throwable t)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> {
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> logger.debug(t.getMessage());
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                        }
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> But generally we use ImageIO
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/06/2011 08:29 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                     
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Yeah i think i need your help again i tried
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> tu
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> run
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> .jar
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> file
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> console it work but without images this it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> what
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> appears
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> GRAVE: Error while processing image:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Cannot
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> load
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> image
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> (no
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> suitable loader/converter combination
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> available)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i tried  download the jai-imagio add to the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> class
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> path
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> but
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> dont
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> work
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                       
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Very odd.  I'm having no problems getting
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> images
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> into
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> pdfs
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> using
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-1.0.
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/03/2011 11:04 AM, Oscar.Flores
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                         
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> aaa hey thanks for the help the other
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> day,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> resolve
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> problem
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> changing
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> version of FOP for the 0.95beta instead
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> of
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> 1.0,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> works
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> now
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> prints
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the image and its good, thanks and we are
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> touch
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> if
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> anything
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> else
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fails
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> jejeje
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                           
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Nothing in the log from the transformer?
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/03/2011 09:47 AM, Oscar.Flores
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                             
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> hi there i have another problem i hope
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> help
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> me
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> create
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> with foe has no image, it dont show any
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> of
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> them,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> xsl
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> seems
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> be
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> rigth i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> tested with EditX and the pdf show me
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> image,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> what
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> be,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> xmlgraphics-commons-1.5svn, fop 1.0,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-pdf-images
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> 2.0.1
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Snapshot
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> render of the image but it don work
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> please
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> help!!!
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> :,(
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                               
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                             
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                         
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                     
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                                 
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> :-):confused::confused::confused::confused:=)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                               
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                                                             
>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>                                                     
>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>                                                 
>>>>>>>>>>>>>>>>>>>>>>> http://old.nabble.com/file/p31822059/libraries.jpeg
>>>>>>>>>>>>>>>>>>>>>>> http://old.nabble.com/file/p31822059/libraries.bmp
>>>>>>>>>>>>>>>>>>>>>>> libraries.bmp
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>                                               
>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>                                             
>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>                                         
>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>                                     
>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>                                 
>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>                             
>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>                         
>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>                     
>>>>>>>> ---------------------------------------------------------------------
>>>>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>                 
>>>> ---------------------------------------------------------------------
>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>>
>>>>
>>>>
>>>>         
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>
>>     
>
>   

---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Problems with FOP and image

Posted by Pascal Sancho <pa...@takoma.fr>.
Hi Rob & Oscar,

I'm not sure that the initial topic of this thread is still on
discussion (see Subject).
Please, if it is the case, don't hack an existing one, but open a new
thread with the right Subject, to avoid confusion for other users.

Le 22/06/2011 18:49, Rob Sargent a écrit :
> It's a little tough for me to follow your xsl, but I'm suspicious of
> your loop template: It looks to me as though you are writing empty
> lines.  I don't think you can rely on the empty lines to be "the right
> size". Maybe some non-breaking white space would help?
> 
> Have you found the log file? If there's a problem, there's a report.
> Turn up your logging if necessary.
> 
> You might want to use the .bat file to generate the "fo" file.  This
> shows exactly what your xsl transformation generated and is the best bet
> at understanding any problem the fop engine is having.  The smart people
> on this list are more likely to look at your fo than your xsl.
> 
> On 06/21/2011 01:23 PM, Oscar.Flores wrote:
>> Hi there yeah its the pdf that give me the fop.bat i dont know why it works
>> this way and not from my java program anyway i am using fixed position i
>> show you my xlst to see if you can help me to correct the size
>>
>> http://old.nabble.com/file/p31897144/FacturasOMF.xsl FacturasOMF.xsl
>>
>>
>> Rob Sargent-4 wrote:
>>> Is the pdf you posted made via the .bat file then?  And it has all the
>>> images you need? Which image is giving you all the trouble?
>>>
>>> I see that you are incorrectly sizing the area into which you are
>>> putting the address of the client. Alternatively you have placed the
>>> table of items too high.  Are you using fixed positions?
>>> Those to pieces (client-address and invoice-items) should be in
>>> consecutive blocks.
>>> On 06/17/2011 09:52 AM, Oscar.Flores wrote:
>>>> No i still can print the images in pdf in console what i do for now is
>>>> call a
>>>> bat to make the transformation with fo until i figure out what the
>>>> problem
>>>> is in log appear that can find a proper converter for the images
>>>>
>>>>
>>>> also another problem its that the table its to big it dont fit to the
>>>> data
>>>> here its the pdf that result
>>>> http://old.nabble.com/file/p31870136/Prueba3.pdf Prueba3.pdf
>>>>
>>>>   Warning(1979/26): fo:table, table-layout="auto" is currently not
>>>> supported
>>>>> by FOP
>>>>> but in my xslt it ike this<fo:table table-layout="fixed" width="100%">
>>>> the version of fop i use its 1.0
>>>>
>>>>
>>>>
>>>> Rob Sargent-4 wrote:
>>>>> I don't think you want to read and write to the same place. If the file
>>>>> is where you want it to be and it's otherwise in perfect shape you
>>>>> should be fine.  But if you do want to read it in and write it to some
>>>>> deployed area the that's what you want to do. Almost:
>>>>>       ImageIO.write(*newImage*, "JPEG", jpegImageFile);
>>>>>
>>>>> So without adding the ImageIO.write() call, are you getting the pdf you
>>>>> want yet?
>>>>> If not, what actual errors are you seeing in the logs.
>>>>>
>>>>> The warning about fo:table is not causing you any trouble.  What version
>>>>> of fop are you running (sorry I've forgotten)
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>> On 06/15/2011 02:51 PM, Oscar.Flores wrote:
>>>>>> Hi thanks for the help yeah i haven see that its was .java and not
>>>>>> .class, ok
>>>>>> then if i follow correctly what you are saying then it has to be
>>>>>> something
>>>>>> like this
>>>>>>
>>>>>> BufferedImage newImage = new BufferedImage ("C:\Logo.jpg")
>>>>>> ImageIO.write(BufferedImage, "JPEG", jpegImageFile) jpegImageFile will
>>>>>> be
>>>>>> the XML call rigth something like "C:\Logo.jpg")
>>>>>>
>>>>>> and another thing
>>>>>>
>>>>>>     Warning(1979/26): fo:table, table-layout="auto" is currently not
>>>>>> supported
>>>>>> by FOP
>>>>>> but in my xslt it ike this<fo:table table-layout="fixed" width="100%">
>>>>>> so
>>>>>> i dont now what its causing the ploblem
>>>>>>
>>>>>>
>>>>>>
>>>>>> Rob Sargent-4 wrote:
>>>>>>> On 06/14/2011 11:06 AM, Oscar.Flores wrote:
>>>>>>>> Yeah i do the class is in jai-imageio-1.1-sources.jar, the enviroment
>>>>>>>> is
>>>>>>>> just
>>>>>>> Having the file in the "...sources.jar" won't do the runtime world
>>>>>>> much
>>>>>>> good. You need the jar of .class files for jai-imageio, not .java
>>>>>>> files
>>>>>>>> windows xp, and the bufferedImage will be the path of the image??
>>>>>>> No, the bufferedImage is an in-memory instance of BufferedImage
>>>>>>> holding
>>>>>>> the bits of the image.  In the case that you have to read it from one
>>>>>>> place and write it to another.
>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>> Did you go through all your jars looking for
>>>>>>>>> 'CLibJPEGImageReaderSpi'.
>>>>>>>>> My greatest suspicion is that you don't have all your jars lined up.
>>>>>>>>> Which jar(s) do you think supplies these?
>>>>>>>>>
>>>>>>>>> What is your environment: just windows or do you have any tools like
>>>>>>>>> cygwin?
>>>>>>>>>
>>>>>>>>> The "jpegImageFile" would be the filename in your xsl the
>>>>>>>>> external-resource.  If you're just using a file that is already in
>>>>>>>>> place
>>>>>>>>> you don't have to re-write it.
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> On 06/14/2011 08:29 AM, Oscar.Flores wrote:
>>>>>>>>>> No i dont, and that weird jejeje netbeans seems to do that for me,
>>>>>>>>>> so
>>>>>>>>>> the
>>>>>>>>>> calls like ImageIO.write(BufferedImage, "JPEG", jpegImageFile)? do
>>>>>>>>>> i
>>>>>>>>>> have
>>>>>>>>>> to
>>>>>>>>>> do it in every image that i put in the pdf?? and the image is
>>>>>>>>>> gererate
>>>>>>>>>> directly in the pdf??how can i do it??
>>>>>>>>>>
>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>> Some jar to which netbeans has access has those classes.  Look in
>>>>>>>>>>> the
>>>>>>>>>>> output of jar tvf<each of your jars>     and see if any of those
>>>>>>>>>>> has
>>>>>>>>>>> the
>>>>>>>>>>> named classes.  If you find a jar with those classes make sure
>>>>>>>>>>> it's
>>>>>>>>>>> part
>>>>>>>>>>> of your classpath for you app.
>>>>>>>>>>>
>>>>>>>>>>> Are you making any calls like ImageIO.write(BufferedImage, "JPEG",
>>>>>>>>>>> jpegImageFile)?
>>>>>>>>>>>
>>>>>>>>>>> On 06/13/2011 05:31 PM, Oscar.Flores wrote:
>>>>>>>>>>>> ok i made a test and tell me that the class is missign but maybe
>>>>>>>>>>>> what
>>>>>>>>>>>> you
>>>>>>>>>>>> say
>>>>>>>>>>>> its rigth and it register the handler
>>>>>>>>>>>> so i gonna register the services so i do this
>>>>>>>>>>>>
>>>>>>>>>>>>       public static void main(String[] args) throws Exception {
>>>>>>>>>>>>               DOMConfigurator.configure("D:/Mis
>>>>>>>>>>>> documentos/NetBeansProjects/Factura/src/factura/log4j.xml");
>>>>>>>>>>>>               logger.info("Entering application.");
>>>>>>>>>>>>
>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>> CLibJPEGImageReaderSpi());
>>>>>>>>>>>>
>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>> CLibJPEGImageWriterSpi());
>>>>>>>>>>>>
>>>>>>>>>>>> also after register my services it telling me that the class
>>>>>>>>>>>> CLibJPEGImageReaderSpi() and CLibJPEGImageWriterSpi() is missing
>>>>>>>>>>>> but
>>>>>>>>>>>> only
>>>>>>>>>>>> in
>>>>>>>>>>>> command
>>>>>>>>>>>>
>>>>>>>>>>>> after register mi service, something more has to be done??
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>> I'm not sure I'm following correctly: does removing the
>>>>>>>>>>>>> xmlgraphics
>>>>>>>>>>>>> jar
>>>>>>>>>>>>> cause netbeans to behave the same as the command-line run of you
>>>>>>>>>>>>> app?
>>>>>>>>>>>>> If
>>>>>>>>>>>>> so, I suspect netbeans is registering services for you.  Your
>>>>>>>>>>>>> own
>>>>>>>>>>>>> code
>>>>>>>>>>>>> will have to make a call to one of the
>>>>>>>>>>>>> IIORegistry.registerServiceProvider() methods.
>>>>>>>>>>>>>
>>>>>>>>>>>>> On 06/13/2011 05:02 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>> Ok aaaa i get it, actually the ImageIO library i added because
>>>>>>>>>>>>>> i
>>>>>>>>>>>>>> read
>>>>>>>>>>>>>> in
>>>>>>>>>>>>>> the
>>>>>>>>>>>>>> xmlgrapics that if something like the message
>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException: Cannot load
>>>>>>>>>>>>>> image
>>>>>>>>>>>>>> (no
>>>>>>>>>>>>>> suitable loader/converter combination available)appear i have
>>>>>>>>>>>>>> to
>>>>>>>>>>>>>> add
>>>>>>>>>>>>>> the
>>>>>>>>>>>>>> jar
>>>>>>>>>>>>>> file to the classpath but that all it say no configuration or
>>>>>>>>>>>>>> anything,
>>>>>>>>>>>>>> then
>>>>>>>>>>>>>> i delete the imagenIO libs and still i have the same output in
>>>>>>>>>>>>>> netbeans
>>>>>>>>>>>>>> so
>>>>>>>>>>>>>> xmlgrapics seem to have the problem in the plugins or i have to
>>>>>>>>>>>>>> configure
>>>>>>>>>>>>>> something
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>> Then it seems to me netbeans (if it's producing good output ==
>>>>>>>>>>>>>>> assumptionA) is still using something that the command-line
>>>>>>>>>>>>>>> isn't.
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> And given assumptionA, you're java code is correct in terms of
>>>>>>>>>>>>>>> FOP
>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>> your configuration isn't for ImageIO.  Show your ImageIO
>>>>>>>>>>>>>>> related
>>>>>>>>>>>>>>> code
>>>>>>>>>>>>>>> and are you sure it's in your app.  Use the logger to show a
>>>>>>>>>>>>>>> message
>>>>>>>>>>>>>>> when you add  your loader.  Or list all ImageIO services:
>>>>>>>>>>>>>>> IIORegistry.getServiceProviders()
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> On 06/13/2011 03:01 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>> ok well i put the xml in scr of my proyect i see that i still
>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>> same
>>>>>>>>>>>>>>>> issues of the image render of any image i dont now if the xml
>>>>>>>>>>>>>>>> its
>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>> place i
>>>>>>>>>>>>>>>> put the code down to see if something its missing
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> 15:45:07,827 ERROR [render] Error while processing image:
>>>>>>>>>>>>>>>> c:\cfd\nombregp.bmp (i
>>>>>>>>>>>>>>>> mage/bmp)
>>>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException: Cannot
>>>>>>>>>>>>>>>> load
>>>>>>>>>>>>>>>> image
>>>>>>>>>>>>>>>> (no
>>>>>>>>>>>>>>>> suitab
>>>>>>>>>>>>>>>> le loader/converter combination available) for
>>>>>>>>>>>>>>>> c:\cfd\nombregp.bmp
>>>>>>>>>>>>>>>> (image/bmp)
>>>>>>>>>>>>>>>>                at
>>>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageManager.getImage(ImageManage
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> import mx.bigdata.sat.cfd.schema.Comprobante;
>>>>>>>>>>>>>>>> import mx.bigdata.sat.cfd.CFDv2;
>>>>>>>>>>>>>>>> import mx.bigdata.sat.security.KeyLoader;
>>>>>>>>>>>>>>>> import org.jdom.*;
>>>>>>>>>>>>>>>> import org.jdom.input.SAXBuilder;
>>>>>>>>>>>>>>>> import org.jdom.output.XMLOutputter;
>>>>>>>>>>>>>>>> import org.jdom.output.Format;
>>>>>>>>>>>>>>>> import org.jdom.transform.JDOMSource;
>>>>>>>>>>>>>>>> //Java
>>>>>>>>>>>>>>>>         import java.io.File;
>>>>>>>>>>>>>>>>         import java.io.OutputStream;
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>         //JAXP
>>>>>>>>>>>>>>>>         import javax.xml.transform.Transformer;
>>>>>>>>>>>>>>>>         import javax.xml.transform.TransformerFactory;
>>>>>>>>>>>>>>>>         import javax.xml.transform.Source;
>>>>>>>>>>>>>>>>         import javax.xml.transform.Result;
>>>>>>>>>>>>>>>>         import javax.xml.transform.stream.StreamSource;
>>>>>>>>>>>>>>>>         import javax.xml.transform.sax.SAXResult;
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>         //FOP
>>>>>>>>>>>>>>>>         import org.apache.fop.apps.FOUserAgent;
>>>>>>>>>>>>>>>>         import org.apache.fop.apps.Fop;
>>>>>>>>>>>>>>>>         import org.apache.fop.apps.FopFactory;
>>>>>>>>>>>>>>>>         import org.apache.fop.apps.MimeConstants;
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>         //log4j
>>>>>>>>>>>>>>>>         import org.apache.log4j.*;
>>>>>>>>>>>>>>>>         import org.apache.log4j.xml.DOMConfigurator;
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> public final class Main {
>>>>>>>>>>>>>>>>            @SuppressWarnings("unchecked")
>>>>>>>>>>>>>>>>            static Logger logger =
>>>>>>>>>>>>>>>> Logger.getLogger(Main.class);
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>            public static void main(String[] args) throws
>>>>>>>>>>>>>>>> Exception
>>>>>>>>>>>>>>>> {
>>>>>>>>>>>>>>>>                 DOMConfigurator.configure("D:/Mis
>>>>>>>>>>>>>>>> documentos/NetBeansProjects/Factura/src/factura/log4j.xml");
>>>>>>>>>>>>>>>>                 logger.info("Entering application.");
>>>>>>>>>>>>>>>>                 try {
>>>>>>>>>>>>>>>>                    File file = new File(args[0]);
>>>>>>>>>>>>>>>>                    Comprobante comp =
>>>>>>>>>>>>>>>> CFDv2.newComprobante(new
>>>>>>>>>>>>>>>> FileInputStream(file));
>>>>>>>>>>>>>>>>                    CFDv2 cfd = new CFDv2(comp);
>>>>>>>>>>>>>>>>                    PrivateKey key =
>>>>>>>>>>>>>>>> KeyLoader.loadPKCS8PrivateKey(new
>>>>>>>>>>>>>>>> FileInputStream(args[1]),(args[2]));
>>>>>>>>>>>>>>>>                    X509Certificate cert =
>>>>>>>>>>>>>>>> KeyLoader.loadX509Certificate(new
>>>>>>>>>>>>>>>> FileInputStream(args[3]));
>>>>>>>>>>>>>>>>                    Comprobante sellado =
>>>>>>>>>>>>>>>> cfd.sellarComprobante(key,
>>>>>>>>>>>>>>>> cert);
>>>>>>>>>>>>>>>>                    String cadena = cfd.getCadenaOriginal();
>>>>>>>>>>>>>>>>                    String sello = sellado.getSello();
>>>>>>>>>>>>>>>>                    // Creamos el builder basado en SAX
>>>>>>>>>>>>>>>>                    SAXBuilder builder = new SAXBuilder();
>>>>>>>>>>>>>>>>                    // Construimos el arbol DOM a partir del
>>>>>>>>>>>>>>>> fichero
>>>>>>>>>>>>>>>> xml
>>>>>>>>>>>>>>>>                    Document documentJDOM = builder.build(new
>>>>>>>>>>>>>>>> FileInputStream(args[0]));
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>                    Element raiz =
>>>>>>>>>>>>>>>> documentJDOM.getRootElement();//toma
>>>>>>>>>>>>>>>> el
>>>>>>>>>>>>>>>> nodo
>>>>>>>>>>>>>>>> raiz
>>>>>>>>>>>>>>>> del documento.
>>>>>>>>>>>>>>>>                    raiz.setAttribute("sello", sello);
>>>>>>>>>>>>>>>>                    raiz.setAttribute("certificado",
>>>>>>>>>>>>>>>> sellado.getCertificado());
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> //System.out.println(raiz.getAttributeValue("sello"));
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> //System.out.println(raiz.getAttributeValue("certificado"));
>>>>>>>>>>>>>>>>                    // Recorremos los hijos de la etiqueta
>>>>>>>>>>>>>>>> raíz
>>>>>>>>>>>>>>>>                    List<Element>        hijosRaiz =
>>>>>>>>>>>>>>>> raiz.getChildren();
>>>>>>>>>>>>>>>>                    boolean Bandera=false;
>>>>>>>>>>>>>>>>                    for(Element hijo: hijosRaiz)
>>>>>>>>>>>>>>>>                    {
>>>>>>>>>>>>>>>>                        // Obtenemos el nombre y su contenido
>>>>>>>>>>>>>>>> de
>>>>>>>>>>>>>>>> tipo
>>>>>>>>>>>>>>>> texto
>>>>>>>>>>>>>>>>                        String nombre = hijo.getName();
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>                        if (nombre.equals("Addenda"))
>>>>>>>>>>>>>>>>                        {   List<Element>        subHijo =
>>>>>>>>>>>>>>>> hijo.getChildren();
>>>>>>>>>>>>>>>>                            for(Element hij: subHijo)
>>>>>>>>>>>>>>>>                                {
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> hij.setAttribute("CadenaOriginal",
>>>>>>>>>>>>>>>> cadena);
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> //System.out.println("CadenaOriginal:
>>>>>>>>>>>>>>>> "+hij.getAttributeValue("CadenaOriginal"));
>>>>>>>>>>>>>>>>                                Bandera=true;
>>>>>>>>>>>>>>>>                                break;
>>>>>>>>>>>>>>>>                                }
>>>>>>>>>>>>>>>>                        }
>>>>>>>>>>>>>>>>                        if (Bandera)
>>>>>>>>>>>>>>>>                        {
>>>>>>>>>>>>>>>>                            XMLOutputter out = new
>>>>>>>>>>>>>>>> XMLOutputter(Format.getPrettyFormat());
>>>>>>>>>>>>>>>>                            File nuevoXML = new File(args[0]);
>>>>>>>>>>>>>>>>                            try{
>>>>>>>>>>>>>>>>                                FileOutputStream archivoXML=
>>>>>>>>>>>>>>>> new
>>>>>>>>>>>>>>>> FileOutputStream
>>>>>>>>>>>>>>>> (nuevoXML);
>>>>>>>>>>>>>>>>                                out.output(documentJDOM,
>>>>>>>>>>>>>>>> archivoXML);
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>                               }
>>>>>>>>>>>>>>>>                            catch (Exception
>>>>>>>>>>>>>>>> ex){System.out.println(ex.getMessage());}
>>>>>>>>>>>>>>>>                            // Para generar el pdf a partir de
>>>>>>>>>>>>>>>> un
>>>>>>>>>>>>>>>> archivo.xsl
>>>>>>>>>>>>>>>> y
>>>>>>>>>>>>>>>> un
>>>>>>>>>>>>>>>>                            // archivo.xml
>>>>>>>>>>>>>>>>                        }
>>>>>>>>>>>>>>>>                      }
>>>>>>>>>>>>>>>>                  // configure fopFactory as desired
>>>>>>>>>>>>>>>>                  FopFactory fopFactory =
>>>>>>>>>>>>>>>> FopFactory.newInstance();
>>>>>>>>>>>>>>>>                  FOUserAgent foUserAgent =
>>>>>>>>>>>>>>>> fopFactory.newFOUserAgent();
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>                  // configure foUserAgent as desired
>>>>>>>>>>>>>>>>                  // Setup output
>>>>>>>>>>>>>>>>                 File pdffile = new File(args[5]);
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>                 OutputStream out = new
>>>>>>>>>>>>>>>> java.io.FileOutputStream(pdffile);
>>>>>>>>>>>>>>>>                 out = new java.io.BufferedOutputStream(out);
>>>>>>>>>>>>>>>>                 try {
>>>>>>>>>>>>>>>>                        // Construct fop with desired output
>>>>>>>>>>>>>>>> format
>>>>>>>>>>>>>>>>                         Fop fop =
>>>>>>>>>>>>>>>> fopFactory.newFop(MimeConstants.MIME_PDF,
>>>>>>>>>>>>>>>> foUserAgent, out);
>>>>>>>>>>>>>>>>                        // Setup XSLT
>>>>>>>>>>>>>>>>                        TransformerFactory factory =
>>>>>>>>>>>>>>>> TransformerFactory.newInstance();
>>>>>>>>>>>>>>>>                        Transformer transformer =
>>>>>>>>>>>>>>>> factory.newTransformer(new
>>>>>>>>>>>>>>>> StreamSource(args[4]));
>>>>>>>>>>>>>>>>                        // Set the value of a  in the
>>>>>>>>>>>>>>>> stylesheet
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> transformer.setParameter("versionParam",
>>>>>>>>>>>>>>>> "2.0");
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>                       // Setup input for XSLT transformation
>>>>>>>>>>>>>>>>                        Source src = new
>>>>>>>>>>>>>>>> JDOMSource(documentJDOM);
>>>>>>>>>>>>>>>>                         // Resulting SAX events (the
>>>>>>>>>>>>>>>> generated
>>>>>>>>>>>>>>>> FO)
>>>>>>>>>>>>>>>> must
>>>>>>>>>>>>>>>> be
>>>>>>>>>>>>>>>> piped
>>>>>>>>>>>>>>>> through to FOP
>>>>>>>>>>>>>>>>                        Result res = new
>>>>>>>>>>>>>>>> SAXResult(fop.getDefaultHandler());
>>>>>>>>>>>>>>>>                         // Start XSLT transformation and FOP
>>>>>>>>>>>>>>>> processing
>>>>>>>>>>>>>>>>                       //
>>>>>>>>>>>>>>>> System.setProperty("java.awt.headless",
>>>>>>>>>>>>>>>> "true");
>>>>>>>>>>>>>>>>                            transformer.transform(src, res);
>>>>>>>>>>>>>>>>                        } finally {
>>>>>>>>>>>>>>>>                         out.close();
>>>>>>>>>>>>>>>>                    }
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>                  System.out.println("Success!");
>>>>>>>>>>>>>>>>                 } catch (Exception e) {
>>>>>>>>>>>>>>>>                  e.printStackTrace(System.err);
>>>>>>>>>>>>>>>>                  System.exit(-1);
>>>>>>>>>>>>>>>>               }
>>>>>>>>>>>>>>>>             logger.info("Exiting application.");
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>          }
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>> Try this log4j.xml: Place it at the root of your jar file
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> <?xml version="1.0" encoding="UTF-8"?>
>>>>>>>>>>>>>>>>> <!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> <log4j:configuration
>>>>>>>>>>>>>>>>> xmlns:log4j="http://jakarta.apache.org/log4j/"
>>>>>>>>>>>>>>>>> debug="false">
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> <appender name="CONSOLE"
>>>>>>>>>>>>>>>>> class="org.apache.log4j.ConsoleAppender">
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> <layout class="org.apache.log4j.PatternLayout">
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> </layout>
>>>>>>>>>>>>>>>>> </appender>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> <category name="org">
>>>>>>>>>>>>>>>>> <priority value="DEBUG"/>
>>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>>> <category name="org.apache">
>>>>>>>>>>>>>>>>> <priority value="WARN"/>
>>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>>> <category name="org.springframework">
>>>>>>>>>>>>>>>>> <priority value="WARN"/>
>>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>>> <category name="org.hibernate">
>>>>>>>>>>>>>>>>> <priority value="DEBUG"/>
>>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>>> <category name="net">
>>>>>>>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>>> <category name="javax">
>>>>>>>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>>> <category name="java">
>>>>>>>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>>> <category name="sun">
>>>>>>>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>>> <category name="org.jboss">
>>>>>>>>>>>>>>>>> <priority value="INFO"/>
>>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>>> <category name="org.jboss.seam">
>>>>>>>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>>> <root>
>>>>>>>>>>>>>>>>> <appender-ref ref="CONSOLE"/>
>>>>>>>>>>>>>>>>> </root>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> </log4j:configuration>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> On 06/13/2011 11:06 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>> ok i dont thik i have a configuracion file i find the code
>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>> put
>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>> other post i think its the basic
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>> Do you have a config file for log4j.  Usually it's in a
>>>>>>>>>>>>>>>>>>> resource
>>>>>>>>>>>>>>>>>>> tree.
>>>>>>>>>>>>>>>>>>> Are you copying that to your deployment? Is your ant
>>>>>>>>>>>>>>>>>>> script
>>>>>>>>>>>>>>>>>>> including
>>>>>>>>>>>>>>>>>>> the config file in the jar of your application?
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> On 06/13/2011 10:12 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>> Ok yeah the log4j its having isuees to find the
>>>>>>>>>>>>>>>>>>>> configuration
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> log4j:WARN No appenders could be found for logger
>>>>>>>>>>>>>>>>>>>> (org.apache.fop.util.ContentHandlerFactoryRegistry).
>>>>>>>>>>>>>>>>>>>> log4j:WARN Please initialize the log4j system properly.
>>>>>>>>>>>>>>>>>>>> log4j:WARN See
>>>>>>>>>>>>>>>>>>>> http://logging.apache.org/log4j/1.2/faq.html#noconfig
>>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>>> more info.
>>>>>>>>>>>>>>>>>>>> i go to the faq guide and it say try loading the class or
>>>>>>>>>>>>>>>>>>>> resource
>>>>>>>>>>>>>>>>>>>> yourself.
>>>>>>>>>>>>>>>>>>>> If you can't find it, neither will log4j.
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> aaa i dont know where to set this
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> also here its my xlst
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> http://old.nabble.com/file/p31835645/FacturasOMF.xsl
>>>>>>>>>>>>>>>>>>>> FacturasOMF.xsl
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> and the fo file that generate the editix
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> http://old.nabble.com/file/p31835645/Prueba.fo Prueba.fo
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>> The first thing is to really dig into what you did to
>>>>>>>>>>>>>>>>>>>>> netbeans
>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>> get
>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>> to work...
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> I've forgotten what your stylesheet looked like, so
>>>>>>>>>>>>>>>>>>>>> maybe
>>>>>>>>>>>>>>>>>>>>> if
>>>>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>>>>> show
>>>>>>>>>>>>>>>>>>>>> us
>>>>>>>>>>>>>>>>>>>>> again how you're referencing your images we might notice
>>>>>>>>>>>>>>>>>>>>> a
>>>>>>>>>>>>>>>>>>>>> problem.
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> It might also help to see the "fo" generated during your
>>>>>>>>>>>>>>>>>>>>> transformation.
>>>>>>>>>>>>>>>>>>>>> Can you grab that just after xslt and just before fop
>>>>>>>>>>>>>>>>>>>>> calls.
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> Are you sure there is no error being logged somewhere
>>>>>>>>>>>>>>>>>>>>> when
>>>>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>>>>> run
>>>>>>>>>>>>>>>>>>>>> from
>>>>>>>>>>>>>>>>>>>>> the command line? (Where is log4j writing and at what
>>>>>>>>>>>>>>>>>>>>> level?)
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>> You where absolutly rigth i miss a few libraries to add
>>>>>>>>>>>>>>>>>>>>>> into
>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>> jar
>>>>>>>>>>>>>>>>>>>>>> file, i
>>>>>>>>>>>>>>>>>>>>>> modified the build.xml to add the package and jar that
>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>> need,
>>>>>>>>>>>>>>>>>>>>>> now
>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>> error
>>>>>>>>>>>>>>>>>>>>>> message is not there but still the images dont show in
>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>> remeber
>>>>>>>>>>>>>>>>>>>>>> that i do something in netbeans so they can add to the
>>>>>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>>>>>> but
>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>> cant
>>>>>>>>>>>>>>>>>>>>>> remeber i dont now if there is still a library that is
>>>>>>>>>>>>>>>>>>>>>> missing
>>>>>>>>>>>>>>>>>>>>>> or
>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>> am
>>>>>>>>>>>>>>>>>>>>>> adding more than it should be
>>>>>>>>>>>>>>>>>>>>>> This is what i use :
>>>>>>>>>>>>>>>>>>>>>> cfdi-base-0.1.6-SNAPSHOT.jar
>>>>>>>>>>>>>>>>>>>>>> guava-r09.jar
>>>>>>>>>>>>>>>>>>>>>> guava-r09-gwt.jar
>>>>>>>>>>>>>>>>>>>>>> jaxb-impl-2.1.10.jar
>>>>>>>>>>>>>>>>>>>>>> avalon-framework-api-4.3.jar
>>>>>>>>>>>>>>>>>>>>>> avalon-framework-cvs-20020806.jar
>>>>>>>>>>>>>>>>>>>>>> avalon-logkit-2.1.jar
>>>>>>>>>>>>>>>>>>>>>> not-yet-commons-ssl-0.3.11.jar
>>>>>>>>>>>>>>>>>>>>>> commons-codec-1.5.jar
>>>>>>>>>>>>>>>>>>>>>> commons-codec-1.5-sources.jar
>>>>>>>>>>>>>>>>>>>>>> log4j-1.2.16.jar
>>>>>>>>>>>>>>>>>>>>>> fop.jar
>>>>>>>>>>>>>>>>>>>>>> jdom.jar
>>>>>>>>>>>>>>>>>>>>>> xmlgraphics-commons-1.4.jar
>>>>>>>>>>>>>>>>>>>>>> commons-io-1.3.1.jar
>>>>>>>>>>>>>>>>>>>>>> fop-pdf-images-2.0.1.SNAPSHOT.jar
>>>>>>>>>>>>>>>>>>>>>> pdfbox-app-1.5.0.jar
>>>>>>>>>>>>>>>>>>>>>> fontbox-1.3.1.jar
>>>>>>>>>>>>>>>>>>>>>> jempbox-1.3.1.jar
>>>>>>>>>>>>>>>>>>>>>> xercesImpl-2.7.1.jar
>>>>>>>>>>>>>>>>>>>>>> batik-all-1.7.jar
>>>>>>>>>>>>>>>>>>>>>> xml-apis-1.3.04.jar
>>>>>>>>>>>>>>>>>>>>>> xml-apis-ext-1.3.04.jar
>>>>>>>>>>>>>>>>>>>>>>           avalon-framework-4.2.0.jar
>>>>>>>>>>>>>>>>>>>>>>           xalan-2.7.0.jar
>>>>>>>>>>>>>>>>>>>>>>           serializer-2.7.0.jar
>>>>>>>>>>>>>>>>>>>>>>           commons-logging-1.0.4.jar
>>>>>>>>>>>>>>>>>>>>>>           jai_codec.jar
>>>>>>>>>>>>>>>>>>>>>>           jai_core.jar
>>>>>>>>>>>>>>>>>>>>>>           batik-ext.jar
>>>>>>>>>>>>>>>>>>>>>>           jai_imageio-1.1-sources.jar
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> Thanks Rob for the help
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> I suspect running from your jar does not have/use the
>>>>>>>>>>>>>>>>>>>>>>> same
>>>>>>>>>>>>>>>>>>>>>>> classpath
>>>>>>>>>>>>>>>>>>>>>>> that is in effect while you're in the debugger.
>>>>>>>>>>>>>>>>>>>>>>> By what mechanism do you generate the jar?
>>>>>>>>>>>>>>>>>>>>>>> Is it an executable jar or are you running java
>>>>>>>>>>>>>>>>>>>>>>> -classpath
>>>>>>>>>>>>>>>>>>>>>>> <your-jar-here:other-jars>          Main?
>>>>>>>>>>>>>>>>>>>>>>> Make your IDE (netbeans) display the classpath  it
>>>>>>>>>>>>>>>>>>>>>>> uses
>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>> run
>>>>>>>>>>>>>>>>>>>>>>> your
>>>>>>>>>>>>>>>>>>>>>>> app
>>>>>>>>>>>>>>>>>>>>>>> and compare that with the above.
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> On 06/09/2011 07:21 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> aaa ok well my problem is that when i do the pdf in
>>>>>>>>>>>>>>>>>>>>>>>> netbean
>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>>>>>>>> fine
>>>>>>>>>>>>>>>>>>>>>>>> with images and evething but when i run the jar file
>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>> command
>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>> give
>>>>>>>>>>>>>>>>>>>>>>>> me a
>>>>>>>>>>>>>>>>>>>>>>>> error
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> GRAVE: Error while processing image: I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException:
>>>>>>>>>>>>>>>>>>>>>>>> Cannot
>>>>>>>>>>>>>>>>>>>>>>>> load
>>>>>>>>>>>>>>>>>>>>>>>>            image (no suitable loader/converter
>>>>>>>>>>>>>>>>>>>>>>>> combination
>>>>>>>>>>>>>>>>>>>>>>>> available)
>>>>>>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>>>>>            (image/jpeg)
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> so i dont no what its not working and if i have to
>>>>>>>>>>>>>>>>>>>>>>>> add
>>>>>>>>>>>>>>>>>>>>>>>> something
>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>> my
>>>>>>>>>>>>>>>>>>>>>>>> code
>>>>>>>>>>>>>>>>>>>>>>>> so the images can load i am soooo desperate what i am
>>>>>>>>>>>>>>>>>>>>>>>> doing
>>>>>>>>>>>>>>>>>>>>>>>> wrong??
>>>>>>>>>>>>>>>>>>>>>>>> i am sorry for the trouble and if a dont explain my
>>>>>>>>>>>>>>>>>>>>>>>> self
>>>>>>>>>>>>>>>>>>>>>>>> very
>>>>>>>>>>>>>>>>>>>>>>>> good
>>>>>>>>>>>>>>>>>>>>>>>> jejeje
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> Not at all sure what your problem is.  All I can do
>>>>>>>>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>>>>>>>>> show
>>>>>>>>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>>>>>>>>> what
>>>>>>>>>>>>>>>>>>>>>>>>> works for us.
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> Our source xml looks like this:
>>>>>>>>>>>>>>>>>>>>>>>>> <image image-id="381623861" reference-id="ref-220"
>>>>>>>>>>>>>>>>>>>>>>>>> width="750"
>>>>>>>>>>>>>>>>>>>>>>>>> height="750" image-space-id="space-1" position="5"
>>>>>>>>>>>>>>>>>>>>>>>>>                         image-pool-position="31"
>>>>>>>>>>>>>>>>>>>>>>>>> pos="4"
>>>>>>>>>>>>>>>>>>>>>>>>>                         file="ref_10_1002108221">
>>>>>>>>>>>>>>>>>>>>>>>>> <!--
>>>>>>>>>>>>>>>>>>>>>>>>> an
>>>>>>>>>>>>>>>>>>>>>>>>> actual
>>>>>>>>>>>>>>>>>>>>>>>>> file
>>>>>>>>>>>>>>>>>>>>>>>>> (.jpeg
>>>>>>>>>>>>>>>>>>>>>>>>> copied the working directory of the transformer -->
>>>>>>>>>>>>>>>>>>>>>>>>> <fields />
>>>>>>>>>>>>>>>>>>>>>>>>> <caption />
>>>>>>>>>>>>>>>>>>>>>>>>> <annotations>
>>>>>>>>>>>>>>>>>>>>>>>>> <arrow_positions origHeight="750" origWidth="750" />
>>>>>>>>>>>>>>>>>>>>>>>>> </annotations>
>>>>>>>>>>>>>>>>>>>>>>>>> </image>
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> Our xslt looks like this for each image needed.
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> <xsl:template name="image">
>>>>>>>>>>>>>>>>>>>>>>>>> <xsl:param name="img"/>           <!-- This is the
>>>>>>>>>>>>>>>>>>>>>>>>> xml
>>>>>>>>>>>>>>>>>>>>>>>>> node
>>>>>>>>>>>>>>>>>>>>>>>>> from
>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>> source
>>>>>>>>>>>>>>>>>>>>>>>>> xml
>>>>>>>>>>>>>>>>>>>>>>>>> above -->
>>>>>>>>>>>>>>>>>>>>>>>>> <xsl:param name="width"/>
>>>>>>>>>>>>>>>>>>>>>>>>> <xsl:param name="height" select="$width"/>
>>>>>>>>>>>>>>>>>>>>>>>>> <xsl:param name="ignoreHeight">false</xsl:param>
>>>>>>>>>>>>>>>>>>>>>>>>> <fo:block>
>>>>>>>>>>>>>>>>>>>>>>>>> <fo:external-graphic src="{$img/@file}"
>>>>>>>>>>>>>>>>>>>>>>>>> height="{$height}"
>>>>>>>>>>>>>>>>>>>>>>>>> width="{$width}" content-height="scale-to-fit"
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> content-width="scale-to-fit"
>>>>>>>>>>>>>>>>>>>>>>>>> border="0.5pt solid black"
>>>>>>>>>>>>>>>>>>>>>>>>> border-collapse="separate">
>>>>>>>>>>>>>>>>>>>>>>>>> <xsl:if test="$ignoreHeight != 'true'">
>>>>>>>>>>>>>>>>>>>>>>>>> <xsl:attribute name="height">
>>>>>>>>>>>>>>>>>>>>>>>>> <xsl:value-of select="$height"/>
>>>>>>>>>>>>>>>>>>>>>>>>> </xsl:attribute>
>>>>>>>>>>>>>>>>>>>>>>>>> </xsl:if>
>>>>>>>>>>>>>>>>>>>>>>>>> </fo:external-graphic>
>>>>>>>>>>>>>>>>>>>>>>>>> </fo:block>
>>>>>>>>>>>>>>>>>>>>>>>>> </xsl:template>
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> Our generated fo looks like this:
>>>>>>>>>>>>>>>>>>>>>>>>> <fo:table-cell>
>>>>>>>>>>>>>>>>>>>>>>>>> <fo:block>
>>>>>>>>>>>>>>>>>>>>>>>>> <fo:external-graphic border-collapse="separate"
>>>>>>>>>>>>>>>>>>>>>>>>> border="0.5pt
>>>>>>>>>>>>>>>>>>>>>>>>> solid
>>>>>>>>>>>>>>>>>>>>>>>>> black" content-width="scale-to-fit"
>>>>>>>>>>>>>>>>>>>>>>>>> content-height="scale-to-fit"
>>>>>>>>>>>>>>>>>>>>>>>>> width="2.5in" height="2.5in" src="ref_10_1002108221"
>>>>>>>>>>>>>>>>>>>>>>>>> />
>>>>>>>>>>>>>>>>>>>>>>>>> </fo:block>
>>>>>>>>>>>>>>>>>>>>>>>>> </fo:table-cell>
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> And the generated pdfs include the image and are
>>>>>>>>>>>>>>>>>>>>>>>>> shipped
>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>> printer.
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> How does this stack up with what you have?
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> On 06/09/2011 01:19 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> Hi there well i still got the problem but searching
>>>>>>>>>>>>>>>>>>>>>>>>>> IN
>>>>>>>>>>>>>>>>>>>>>>>>>> INTERNET
>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>> find
>>>>>>>>>>>>>>>>>>>>>>>>>> a
>>>>>>>>>>>>>>>>>>>>>>>>>> JPEG
>>>>>>>>>>>>>>>>>>>>>>>>>> renderer output for FOP its here
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> http://marc.info/?l=fop-user&m=125986752706366&w=2
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> the cuestion is can i render the image that i want
>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>> put
>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>> pdf,
>>>>>>>>>>>>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>>>>>>>>>>>>> then add to the xsl the render jpeg it will work??
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> and here explaints how use the render when he say
>>>>>>>>>>>>>>>>>>>>>>>>>> uses
>>>>>>>>>>>>>>>>>>>>>>>>>> fop
>>>>>>>>>>>>>>>>>>>>>>>>>> as
>>>>>>>>>>>>>>>>>>>>>>>>>> normal
>>>>>>>>>>>>>>>>>>>>>>>>>> case
>>>>>>>>>>>>>>>>>>>>>>>>>> what does it mean
>>>>>>>>>>>>>>>>>>>>>>>>>> what else have to add to the code?? i hope you can
>>>>>>>>>>>>>>>>>>>>>>>>>> help
>>>>>>>>>>>>>>>>>>>>>>>>>> me
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> Thanks!!
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> // OutputStream out = what you want
>>>>>>>>>>>>>>>>>>>>>>>>>>                        FopFactory fopFactory =
>>>>>>>>>>>>>>>>>>>>>>>>>> FopFactory.newInstance();
>>>>>>>>>>>>>>>>>>>>>>>>>>                        RendererFactory
>>>>>>>>>>>>>>>>>>>>>>>>>> rendererFactory
>>>>>>>>>>>>>>>>>>>>>>>>>> =
>>>>>>>>>>>>>>>>>>>>>>>>>> null;
>>>>>>>>>>>>>>>>>>>>>>>>>>                        FOUserAgent foUserAgent =
>>>>>>>>>>>>>>>>>>>>>>>>>> null;
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>                        rendererFactory =
>>>>>>>>>>>>>>>>>>>>>>>>>> fopFactory.getRendererFactory();
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> rendererFactory.addRendererMaker(new
>>>>>>>>>>>>>>>>>>>>>>>>>> MultiRendererMaker("jpeg"));
>>>>>>>>>>>>>>>>>>>>>>>>>>                        foUserAgent =
>>>>>>>>>>>>>>>>>>>>>>>>>> fopFactory.newFOUserAgent();
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> rendererFactory.createRenderer(foUserAgent,
>>>>>>>>>>>>>>>>>>>>>>>>>> "image/jpeg");
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>                        Fop fop =
>>>>>>>>>>>>>>>>>>>>>>>>>> fopFactory.newFop("image/jpeg",
>>>>>>>>>>>>>>>>>>>>>>>>>> foUserAgent,
>>>>>>>>>>>>>>>>>>>>>>>>>> out);
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> //Use fop as normal case
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> Since you're now into xmlgraphics, I think you're
>>>>>>>>>>>>>>>>>>>>>>>>>>> best
>>>>>>>>>>>>>>>>>>>>>>>>>>> bet
>>>>>>>>>>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>>>>>>>>>>> here
>>>>>>>>>>>>>>>>>>>>>>>>>>> <http://xmlgraphics.apache.org/commons/image-loader.html>
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/07/2011 10:18 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> Hi ok this is for generate images that dont need
>>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>>> be
>>>>>>>>>>>>>>>>>>>>>>>>>>>> decompress
>>>>>>>>>>>>>>>>>>>>>>>>>>>> later??
>>>>>>>>>>>>>>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>>>>>>>>>>>>>>> the result image i put in my xsl ?? then it
>>>>>>>>>>>>>>>>>>>>>>>>>>>> should
>>>>>>>>>>>>>>>>>>>>>>>>>>>> work,
>>>>>>>>>>>>>>>>>>>>>>>>>>>> aaa
>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>> change
>>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop
>>>>>>>>>>>>>>>>>>>>>>>>>>>> 1.0 and xml communs 1.4 and its the same jejeje
>>>>>>>>>>>>>>>>>>>>>>>>>>>> dont
>>>>>>>>>>>>>>>>>>>>>>>>>>>> find
>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>> image
>>>>>>>>>>>>>>>>>>>>>>>>>>>> preload
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> org.apache.fop.fo.flow.ExternalGraphic bind
>>>>>>>>>>>>>>>>>>>>>>>>>>>> SEVERE: Image not available: The file format is
>>>>>>>>>>>>>>>>>>>>>>>>>>>> not
>>>>>>>>>>>>>>>>>>>>>>>>>>>> supported.
>>>>>>>>>>>>>>>>>>>>>>>>>>>> No
>>>>>>>>>>>>>>>>>>>>>>>>>>>> ImagePreloader for *.jpg or *.bmp
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ImageIO.write(bufferedImage, "JPEG", file);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/07/2011 08:21 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Ok i actually register the handler now what i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> do
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> setup
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> this
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> handler or not?? and how can i do that, also it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> seem
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> bmp
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> its
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> not
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> recognice also what can i do?? thanks for the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> help
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> rob
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> also i am trying to convert the images to see
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> if
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> helps
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/06/2011 02:29 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Hi what can be the difference between execute
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> program
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> netbeans
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> (where
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it works and print the images and the jar in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> console)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Different classes being loaded by Netbeans
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> than
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> console
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> app.
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Get
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Netbeans to show you the full classpath it's
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> using
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it's
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> "%classpath"
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> variable
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> also i tried the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> imageIO.getImageReadersBySuffix but i cant
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> interpretate
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> data
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> y.y,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> its
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> that or always its true in the boolean
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> variable,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> how
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> register
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> handler??
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Talk to IIORegistry, some thing like
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> CLibJPEGImageReaderSpi());
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> CLibJPEGImageWriterSpi());
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Note: those are not necessarily the services
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> your
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> setup.
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Thanks
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> See the javadoc on IIORegistry. With ImageIO
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> may
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> register
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> your handler(s). What does
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ImageIO.getImageReadersBySuffix()
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> give
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> you.
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For certain jpegs we don't use ImageIO,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> rather
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> classes
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> com.sun.image.codec.jpeg:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                        try {
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                            FileOutputStream
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fos
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> =
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> new
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> FileOutputStream(file);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                            JPEGImageEncoder
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> encoder =
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> JPEGCodec.createJPEGEncoder(fos);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                            JPEGEncodeParam
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> param =
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> encoder.getDefaultJPEGEncodeParam(image.getRaster(),
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> JPEGDecodeParam.COLOR_ID_CMYK);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> param.setQuality(1,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> false);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> encoder.encode(image.getRaster(),
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> param);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                            fos.close();
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                        } catch (Throwable t)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> {
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> logger.debug(t.getMessage());
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                        }
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> But generally we use ImageIO
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/06/2011 08:29 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Yeah i think i need your help again i tried
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> tu
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> run
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> .jar
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> file
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> console it work but without images this it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> what
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> appears
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> GRAVE: Error while processing image:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Cannot
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> load
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> image
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> (no
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> suitable loader/converter combination
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> available)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i tried  download the jai-imagio add to the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> class
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> path
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> but
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> dont
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> work
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Very odd.  I'm having no problems getting
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> images
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> into
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> pdfs
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> using
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-1.0.
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/03/2011 11:04 AM, Oscar.Flores
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> aaa hey thanks for the help the other
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> day,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> resolve
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> problem
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> changing
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> version of FOP for the 0.95beta instead
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> of
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> 1.0,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> works
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> now
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> prints
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the image and its good, thanks and we are
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> touch
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> if
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> anything
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> else
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fails
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> jejeje
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Nothing in the log from the transformer?
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/03/2011 09:47 AM, Oscar.Flores
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> hi there i have another problem i hope
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> help
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> me
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> create
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> with foe has no image, it dont show any
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> of
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> them,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> xsl
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> seems
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> be
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> rigth i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> tested with EditX and the pdf show me
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> image,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> what
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> be,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> xmlgraphics-commons-1.5svn, fop 1.0,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-pdf-images
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> 2.0.1
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Snapshot
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> render of the image but it don work
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> please
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> help!!!
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> :,(
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> :-):confused::confused::confused::confused:=)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> http://old.nabble.com/file/p31822059/libraries.jpeg
>>>>>>>>>>>>>>>>>>>>>> http://old.nabble.com/file/p31822059/libraries.bmp
>>>>>>>>>>>>>>>>>>>>>> libraries.bmp
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>> For additional commands, e-mail:
>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>> ---------------------------------------------------------------------
>>>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>>>>>
>>>>>>>
>>>>>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>
>>>
>>>
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
> 

-- 
Pascal

---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Problems with FOP and image

Posted by Rob Sargent <rs...@xmission.com>.
It's a little tough for me to follow your xsl, but I'm suspicious of
your loop template: It looks to me as though you are writing empty
lines.  I don't think you can rely on the empty lines to be "the right
size". Maybe some non-breaking white space would help?

Have you found the log file? If there's a problem, there's a report. 
Turn up your logging if necessary.

You might want to use the .bat file to generate the "fo" file.  This
shows exactly what your xsl transformation generated and is the best bet
at understanding any problem the fop engine is having.  The smart people
on this list are more likely to look at your fo than your xsl.

On 06/21/2011 01:23 PM, Oscar.Flores wrote:
> Hi there yeah its the pdf that give me the fop.bat i dont know why it works
> this way and not from my java program anyway i am using fixed position i
> show you my xlst to see if you can help me to correct the size 
>
> http://old.nabble.com/file/p31897144/FacturasOMF.xsl FacturasOMF.xsl 
>   
>
> Rob Sargent-4 wrote:
>> Is the pdf you posted made via the .bat file then?  And it has all the 
>> images you need? Which image is giving you all the trouble?
>>
>> I see that you are incorrectly sizing the area into which you are 
>> putting the address of the client. Alternatively you have placed the 
>> table of items too high.  Are you using fixed positions?
>> Those to pieces (client-address and invoice-items) should be in 
>> consecutive blocks.
>> On 06/17/2011 09:52 AM, Oscar.Flores wrote:
>>> No i still can print the images in pdf in console what i do for now is
>>> call a
>>> bat to make the transformation with fo until i figure out what the
>>> problem
>>> is in log appear that can find a proper converter for the images
>>>
>>>
>>> also another problem its that the table its to big it dont fit to the
>>> data
>>> here its the pdf that result
>>> http://old.nabble.com/file/p31870136/Prueba3.pdf Prueba3.pdf
>>>
>>>   Warning(1979/26): fo:table, table-layout="auto" is currently not
>>> supported
>>>> by FOP
>>>> but in my xslt it ike this<fo:table table-layout="fixed" width="100%">
>>> the version of fop i use its 1.0
>>>
>>>
>>>
>>> Rob Sargent-4 wrote:
>>>> I don't think you want to read and write to the same place. If the file
>>>> is where you want it to be and it's otherwise in perfect shape you
>>>> should be fine.  But if you do want to read it in and write it to some
>>>> deployed area the that's what you want to do. Almost:
>>>>       ImageIO.write(*newImage*, "JPEG", jpegImageFile);
>>>>
>>>> So without adding the ImageIO.write() call, are you getting the pdf you
>>>> want yet?
>>>> If not, what actual errors are you seeing in the logs.
>>>>
>>>> The warning about fo:table is not causing you any trouble.  What version
>>>> of fop are you running (sorry I've forgotten)
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>> On 06/15/2011 02:51 PM, Oscar.Flores wrote:
>>>>> Hi thanks for the help yeah i haven see that its was .java and not
>>>>> .class, ok
>>>>> then if i follow correctly what you are saying then it has to be
>>>>> something
>>>>> like this
>>>>>
>>>>> BufferedImage newImage = new BufferedImage ("C:\Logo.jpg")
>>>>> ImageIO.write(BufferedImage, "JPEG", jpegImageFile) jpegImageFile will
>>>>> be
>>>>> the XML call rigth something like "C:\Logo.jpg")
>>>>>
>>>>> and another thing
>>>>>
>>>>>     Warning(1979/26): fo:table, table-layout="auto" is currently not
>>>>> supported
>>>>> by FOP
>>>>> but in my xslt it ike this<fo:table table-layout="fixed" width="100%">
>>>>> so
>>>>> i dont now what its causing the ploblem
>>>>>
>>>>>
>>>>>
>>>>> Rob Sargent-4 wrote:
>>>>>> On 06/14/2011 11:06 AM, Oscar.Flores wrote:
>>>>>>> Yeah i do the class is in jai-imageio-1.1-sources.jar, the enviroment
>>>>>>> is
>>>>>>> just
>>>>>> Having the file in the "...sources.jar" won't do the runtime world
>>>>>> much
>>>>>> good. You need the jar of .class files for jai-imageio, not .java
>>>>>> files
>>>>>>> windows xp, and the bufferedImage will be the path of the image??
>>>>>> No, the bufferedImage is an in-memory instance of BufferedImage
>>>>>> holding
>>>>>> the bits of the image.  In the case that you have to read it from one
>>>>>> place and write it to another.
>>>>>>> Rob Sargent-4 wrote:
>>>>>>>> Did you go through all your jars looking for
>>>>>>>> 'CLibJPEGImageReaderSpi'.
>>>>>>>> My greatest suspicion is that you don't have all your jars lined up.
>>>>>>>> Which jar(s) do you think supplies these?
>>>>>>>>
>>>>>>>> What is your environment: just windows or do you have any tools like
>>>>>>>> cygwin?
>>>>>>>>
>>>>>>>> The "jpegImageFile" would be the filename in your xsl the
>>>>>>>> external-resource.  If you're just using a file that is already in
>>>>>>>> place
>>>>>>>> you don't have to re-write it.
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> On 06/14/2011 08:29 AM, Oscar.Flores wrote:
>>>>>>>>> No i dont, and that weird jejeje netbeans seems to do that for me,
>>>>>>>>> so
>>>>>>>>> the
>>>>>>>>> calls like ImageIO.write(BufferedImage, "JPEG", jpegImageFile)? do
>>>>>>>>> i
>>>>>>>>> have
>>>>>>>>> to
>>>>>>>>> do it in every image that i put in the pdf?? and the image is
>>>>>>>>> gererate
>>>>>>>>> directly in the pdf??how can i do it??
>>>>>>>>>
>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>> Some jar to which netbeans has access has those classes.  Look in
>>>>>>>>>> the
>>>>>>>>>> output of jar tvf<each of your jars>     and see if any of those
>>>>>>>>>> has
>>>>>>>>>> the
>>>>>>>>>> named classes.  If you find a jar with those classes make sure
>>>>>>>>>> it's
>>>>>>>>>> part
>>>>>>>>>> of your classpath for you app.
>>>>>>>>>>
>>>>>>>>>> Are you making any calls like ImageIO.write(BufferedImage, "JPEG",
>>>>>>>>>> jpegImageFile)?
>>>>>>>>>>
>>>>>>>>>> On 06/13/2011 05:31 PM, Oscar.Flores wrote:
>>>>>>>>>>> ok i made a test and tell me that the class is missign but maybe
>>>>>>>>>>> what
>>>>>>>>>>> you
>>>>>>>>>>> say
>>>>>>>>>>> its rigth and it register the handler
>>>>>>>>>>> so i gonna register the services so i do this
>>>>>>>>>>>
>>>>>>>>>>>       public static void main(String[] args) throws Exception {
>>>>>>>>>>>               DOMConfigurator.configure("D:/Mis
>>>>>>>>>>> documentos/NetBeansProjects/Factura/src/factura/log4j.xml");
>>>>>>>>>>>               logger.info("Entering application.");
>>>>>>>>>>>
>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>> CLibJPEGImageReaderSpi());
>>>>>>>>>>>
>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>> CLibJPEGImageWriterSpi());
>>>>>>>>>>>
>>>>>>>>>>> also after register my services it telling me that the class
>>>>>>>>>>> CLibJPEGImageReaderSpi() and CLibJPEGImageWriterSpi() is missing
>>>>>>>>>>> but
>>>>>>>>>>> only
>>>>>>>>>>> in
>>>>>>>>>>> command
>>>>>>>>>>>
>>>>>>>>>>> after register mi service, something more has to be done??
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>> I'm not sure I'm following correctly: does removing the
>>>>>>>>>>>> xmlgraphics
>>>>>>>>>>>> jar
>>>>>>>>>>>> cause netbeans to behave the same as the command-line run of you
>>>>>>>>>>>> app?
>>>>>>>>>>>> If
>>>>>>>>>>>> so, I suspect netbeans is registering services for you.  Your
>>>>>>>>>>>> own
>>>>>>>>>>>> code
>>>>>>>>>>>> will have to make a call to one of the
>>>>>>>>>>>> IIORegistry.registerServiceProvider() methods.
>>>>>>>>>>>>
>>>>>>>>>>>> On 06/13/2011 05:02 PM, Oscar.Flores wrote:
>>>>>>>>>>>>> Ok aaaa i get it, actually the ImageIO library i added because
>>>>>>>>>>>>> i
>>>>>>>>>>>>> read
>>>>>>>>>>>>> in
>>>>>>>>>>>>> the
>>>>>>>>>>>>> xmlgrapics that if something like the message
>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException: Cannot load
>>>>>>>>>>>>> image
>>>>>>>>>>>>> (no
>>>>>>>>>>>>> suitable loader/converter combination available)appear i have
>>>>>>>>>>>>> to
>>>>>>>>>>>>> add
>>>>>>>>>>>>> the
>>>>>>>>>>>>> jar
>>>>>>>>>>>>> file to the classpath but that all it say no configuration or
>>>>>>>>>>>>> anything,
>>>>>>>>>>>>> then
>>>>>>>>>>>>> i delete the imagenIO libs and still i have the same output in
>>>>>>>>>>>>> netbeans
>>>>>>>>>>>>> so
>>>>>>>>>>>>> xmlgrapics seem to have the problem in the plugins or i have to
>>>>>>>>>>>>> configure
>>>>>>>>>>>>> something
>>>>>>>>>>>>>
>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>> Then it seems to me netbeans (if it's producing good output ==
>>>>>>>>>>>>>> assumptionA) is still using something that the command-line
>>>>>>>>>>>>>> isn't.
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> And given assumptionA, you're java code is correct in terms of
>>>>>>>>>>>>>> FOP
>>>>>>>>>>>>>> and
>>>>>>>>>>>>>> your configuration isn't for ImageIO.  Show your ImageIO
>>>>>>>>>>>>>> related
>>>>>>>>>>>>>> code
>>>>>>>>>>>>>> and are you sure it's in your app.  Use the logger to show a
>>>>>>>>>>>>>> message
>>>>>>>>>>>>>> when you add  your loader.  Or list all ImageIO services:
>>>>>>>>>>>>>> IIORegistry.getServiceProviders()
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> On 06/13/2011 03:01 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>> ok well i put the xml in scr of my proyect i see that i still
>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>> same
>>>>>>>>>>>>>>> issues of the image render of any image i dont now if the xml
>>>>>>>>>>>>>>> its
>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>> place i
>>>>>>>>>>>>>>> put the code down to see if something its missing
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> 15:45:07,827 ERROR [render] Error while processing image:
>>>>>>>>>>>>>>> c:\cfd\nombregp.bmp (i
>>>>>>>>>>>>>>> mage/bmp)
>>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException: Cannot
>>>>>>>>>>>>>>> load
>>>>>>>>>>>>>>> image
>>>>>>>>>>>>>>> (no
>>>>>>>>>>>>>>> suitab
>>>>>>>>>>>>>>> le loader/converter combination available) for
>>>>>>>>>>>>>>> c:\cfd\nombregp.bmp
>>>>>>>>>>>>>>> (image/bmp)
>>>>>>>>>>>>>>>                at
>>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageManager.getImage(ImageManage
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> import mx.bigdata.sat.cfd.schema.Comprobante;
>>>>>>>>>>>>>>> import mx.bigdata.sat.cfd.CFDv2;
>>>>>>>>>>>>>>> import mx.bigdata.sat.security.KeyLoader;
>>>>>>>>>>>>>>> import org.jdom.*;
>>>>>>>>>>>>>>> import org.jdom.input.SAXBuilder;
>>>>>>>>>>>>>>> import org.jdom.output.XMLOutputter;
>>>>>>>>>>>>>>> import org.jdom.output.Format;
>>>>>>>>>>>>>>> import org.jdom.transform.JDOMSource;
>>>>>>>>>>>>>>> //Java
>>>>>>>>>>>>>>>         import java.io.File;
>>>>>>>>>>>>>>>         import java.io.OutputStream;
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>         //JAXP
>>>>>>>>>>>>>>>         import javax.xml.transform.Transformer;
>>>>>>>>>>>>>>>         import javax.xml.transform.TransformerFactory;
>>>>>>>>>>>>>>>         import javax.xml.transform.Source;
>>>>>>>>>>>>>>>         import javax.xml.transform.Result;
>>>>>>>>>>>>>>>         import javax.xml.transform.stream.StreamSource;
>>>>>>>>>>>>>>>         import javax.xml.transform.sax.SAXResult;
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>         //FOP
>>>>>>>>>>>>>>>         import org.apache.fop.apps.FOUserAgent;
>>>>>>>>>>>>>>>         import org.apache.fop.apps.Fop;
>>>>>>>>>>>>>>>         import org.apache.fop.apps.FopFactory;
>>>>>>>>>>>>>>>         import org.apache.fop.apps.MimeConstants;
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>         //log4j
>>>>>>>>>>>>>>>         import org.apache.log4j.*;
>>>>>>>>>>>>>>>         import org.apache.log4j.xml.DOMConfigurator;
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> public final class Main {
>>>>>>>>>>>>>>>            @SuppressWarnings("unchecked")
>>>>>>>>>>>>>>>            static Logger logger =
>>>>>>>>>>>>>>> Logger.getLogger(Main.class);
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>            public static void main(String[] args) throws
>>>>>>>>>>>>>>> Exception
>>>>>>>>>>>>>>> {
>>>>>>>>>>>>>>>                 DOMConfigurator.configure("D:/Mis
>>>>>>>>>>>>>>> documentos/NetBeansProjects/Factura/src/factura/log4j.xml");
>>>>>>>>>>>>>>>                 logger.info("Entering application.");
>>>>>>>>>>>>>>>                 try {
>>>>>>>>>>>>>>>                    File file = new File(args[0]);
>>>>>>>>>>>>>>>                    Comprobante comp =
>>>>>>>>>>>>>>> CFDv2.newComprobante(new
>>>>>>>>>>>>>>> FileInputStream(file));
>>>>>>>>>>>>>>>                    CFDv2 cfd = new CFDv2(comp);
>>>>>>>>>>>>>>>                    PrivateKey key =
>>>>>>>>>>>>>>> KeyLoader.loadPKCS8PrivateKey(new
>>>>>>>>>>>>>>> FileInputStream(args[1]),(args[2]));
>>>>>>>>>>>>>>>                    X509Certificate cert =
>>>>>>>>>>>>>>> KeyLoader.loadX509Certificate(new
>>>>>>>>>>>>>>> FileInputStream(args[3]));
>>>>>>>>>>>>>>>                    Comprobante sellado =
>>>>>>>>>>>>>>> cfd.sellarComprobante(key,
>>>>>>>>>>>>>>> cert);
>>>>>>>>>>>>>>>                    String cadena = cfd.getCadenaOriginal();
>>>>>>>>>>>>>>>                    String sello = sellado.getSello();
>>>>>>>>>>>>>>>                    // Creamos el builder basado en SAX
>>>>>>>>>>>>>>>                    SAXBuilder builder = new SAXBuilder();
>>>>>>>>>>>>>>>                    // Construimos el arbol DOM a partir del
>>>>>>>>>>>>>>> fichero
>>>>>>>>>>>>>>> xml
>>>>>>>>>>>>>>>                    Document documentJDOM = builder.build(new
>>>>>>>>>>>>>>> FileInputStream(args[0]));
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>                    Element raiz =
>>>>>>>>>>>>>>> documentJDOM.getRootElement();//toma
>>>>>>>>>>>>>>> el
>>>>>>>>>>>>>>> nodo
>>>>>>>>>>>>>>> raiz
>>>>>>>>>>>>>>> del documento.
>>>>>>>>>>>>>>>                    raiz.setAttribute("sello", sello);
>>>>>>>>>>>>>>>                    raiz.setAttribute("certificado",
>>>>>>>>>>>>>>> sellado.getCertificado());
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> //System.out.println(raiz.getAttributeValue("sello"));
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> //System.out.println(raiz.getAttributeValue("certificado"));
>>>>>>>>>>>>>>>                    // Recorremos los hijos de la etiqueta
>>>>>>>>>>>>>>> raíz
>>>>>>>>>>>>>>>                    List<Element>        hijosRaiz =
>>>>>>>>>>>>>>> raiz.getChildren();
>>>>>>>>>>>>>>>                    boolean Bandera=false;
>>>>>>>>>>>>>>>                    for(Element hijo: hijosRaiz)
>>>>>>>>>>>>>>>                    {
>>>>>>>>>>>>>>>                        // Obtenemos el nombre y su contenido
>>>>>>>>>>>>>>> de
>>>>>>>>>>>>>>> tipo
>>>>>>>>>>>>>>> texto
>>>>>>>>>>>>>>>                        String nombre = hijo.getName();
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>                        if (nombre.equals("Addenda"))
>>>>>>>>>>>>>>>                        {   List<Element>        subHijo =
>>>>>>>>>>>>>>> hijo.getChildren();
>>>>>>>>>>>>>>>                            for(Element hij: subHijo)
>>>>>>>>>>>>>>>                                {
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> hij.setAttribute("CadenaOriginal",
>>>>>>>>>>>>>>> cadena);
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> //System.out.println("CadenaOriginal:
>>>>>>>>>>>>>>> "+hij.getAttributeValue("CadenaOriginal"));
>>>>>>>>>>>>>>>                                Bandera=true;
>>>>>>>>>>>>>>>                                break;
>>>>>>>>>>>>>>>                                }
>>>>>>>>>>>>>>>                        }
>>>>>>>>>>>>>>>                        if (Bandera)
>>>>>>>>>>>>>>>                        {
>>>>>>>>>>>>>>>                            XMLOutputter out = new
>>>>>>>>>>>>>>> XMLOutputter(Format.getPrettyFormat());
>>>>>>>>>>>>>>>                            File nuevoXML = new File(args[0]);
>>>>>>>>>>>>>>>                            try{
>>>>>>>>>>>>>>>                                FileOutputStream archivoXML=
>>>>>>>>>>>>>>> new
>>>>>>>>>>>>>>> FileOutputStream
>>>>>>>>>>>>>>> (nuevoXML);
>>>>>>>>>>>>>>>                                out.output(documentJDOM,
>>>>>>>>>>>>>>> archivoXML);
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>                               }
>>>>>>>>>>>>>>>                            catch (Exception
>>>>>>>>>>>>>>> ex){System.out.println(ex.getMessage());}
>>>>>>>>>>>>>>>                            // Para generar el pdf a partir de
>>>>>>>>>>>>>>> un
>>>>>>>>>>>>>>> archivo.xsl
>>>>>>>>>>>>>>> y
>>>>>>>>>>>>>>> un
>>>>>>>>>>>>>>>                            // archivo.xml
>>>>>>>>>>>>>>>                        }
>>>>>>>>>>>>>>>                      }
>>>>>>>>>>>>>>>                  // configure fopFactory as desired
>>>>>>>>>>>>>>>                  FopFactory fopFactory =
>>>>>>>>>>>>>>> FopFactory.newInstance();
>>>>>>>>>>>>>>>                  FOUserAgent foUserAgent =
>>>>>>>>>>>>>>> fopFactory.newFOUserAgent();
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>                  // configure foUserAgent as desired
>>>>>>>>>>>>>>>                  // Setup output
>>>>>>>>>>>>>>>                 File pdffile = new File(args[5]);
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>                 OutputStream out = new
>>>>>>>>>>>>>>> java.io.FileOutputStream(pdffile);
>>>>>>>>>>>>>>>                 out = new java.io.BufferedOutputStream(out);
>>>>>>>>>>>>>>>                 try {
>>>>>>>>>>>>>>>                        // Construct fop with desired output
>>>>>>>>>>>>>>> format
>>>>>>>>>>>>>>>                         Fop fop =
>>>>>>>>>>>>>>> fopFactory.newFop(MimeConstants.MIME_PDF,
>>>>>>>>>>>>>>> foUserAgent, out);
>>>>>>>>>>>>>>>                        // Setup XSLT
>>>>>>>>>>>>>>>                        TransformerFactory factory =
>>>>>>>>>>>>>>> TransformerFactory.newInstance();
>>>>>>>>>>>>>>>                        Transformer transformer =
>>>>>>>>>>>>>>> factory.newTransformer(new
>>>>>>>>>>>>>>> StreamSource(args[4]));
>>>>>>>>>>>>>>>                        // Set the value of a  in the
>>>>>>>>>>>>>>> stylesheet
>>>>>>>>>>>>>>>                       
>>>>>>>>>>>>>>> transformer.setParameter("versionParam",
>>>>>>>>>>>>>>> "2.0");
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>                       // Setup input for XSLT transformation
>>>>>>>>>>>>>>>                        Source src = new
>>>>>>>>>>>>>>> JDOMSource(documentJDOM);
>>>>>>>>>>>>>>>                         // Resulting SAX events (the
>>>>>>>>>>>>>>> generated
>>>>>>>>>>>>>>> FO)
>>>>>>>>>>>>>>> must
>>>>>>>>>>>>>>> be
>>>>>>>>>>>>>>> piped
>>>>>>>>>>>>>>> through to FOP
>>>>>>>>>>>>>>>                        Result res = new
>>>>>>>>>>>>>>> SAXResult(fop.getDefaultHandler());
>>>>>>>>>>>>>>>                         // Start XSLT transformation and FOP
>>>>>>>>>>>>>>> processing
>>>>>>>>>>>>>>>                       //
>>>>>>>>>>>>>>> System.setProperty("java.awt.headless",
>>>>>>>>>>>>>>> "true");
>>>>>>>>>>>>>>>                            transformer.transform(src, res);
>>>>>>>>>>>>>>>                        } finally {
>>>>>>>>>>>>>>>                         out.close();
>>>>>>>>>>>>>>>                    }
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>                  System.out.println("Success!");
>>>>>>>>>>>>>>>                 } catch (Exception e) {
>>>>>>>>>>>>>>>                  e.printStackTrace(System.err);
>>>>>>>>>>>>>>>                  System.exit(-1);
>>>>>>>>>>>>>>>               }
>>>>>>>>>>>>>>>             logger.info("Exiting application.");
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>          }
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>> Try this log4j.xml: Place it at the root of your jar file
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> <?xml version="1.0" encoding="UTF-8"?>
>>>>>>>>>>>>>>>> <!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> <log4j:configuration
>>>>>>>>>>>>>>>> xmlns:log4j="http://jakarta.apache.org/log4j/"
>>>>>>>>>>>>>>>> debug="false">
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> <appender name="CONSOLE"
>>>>>>>>>>>>>>>> class="org.apache.log4j.ConsoleAppender">
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> <layout class="org.apache.log4j.PatternLayout">
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> </layout>
>>>>>>>>>>>>>>>> </appender>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> <category name="org">
>>>>>>>>>>>>>>>> <priority value="DEBUG"/>
>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>> <category name="org.apache">
>>>>>>>>>>>>>>>> <priority value="WARN"/>
>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>> <category name="org.springframework">
>>>>>>>>>>>>>>>> <priority value="WARN"/>
>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>> <category name="org.hibernate">
>>>>>>>>>>>>>>>> <priority value="DEBUG"/>
>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>> <category name="net">
>>>>>>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>> <category name="javax">
>>>>>>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>> <category name="java">
>>>>>>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>> <category name="sun">
>>>>>>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>> <category name="org.jboss">
>>>>>>>>>>>>>>>> <priority value="INFO"/>
>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>> <category name="org.jboss.seam">
>>>>>>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>>> <root>
>>>>>>>>>>>>>>>> <appender-ref ref="CONSOLE"/>
>>>>>>>>>>>>>>>> </root>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> </log4j:configuration>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> On 06/13/2011 11:06 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>> ok i dont thik i have a configuracion file i find the code
>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>> put
>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>> other post i think its the basic
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>> Do you have a config file for log4j.  Usually it's in a
>>>>>>>>>>>>>>>>>> resource
>>>>>>>>>>>>>>>>>> tree.
>>>>>>>>>>>>>>>>>> Are you copying that to your deployment? Is your ant
>>>>>>>>>>>>>>>>>> script
>>>>>>>>>>>>>>>>>> including
>>>>>>>>>>>>>>>>>> the config file in the jar of your application?
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> On 06/13/2011 10:12 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>> Ok yeah the log4j its having isuees to find the
>>>>>>>>>>>>>>>>>>> configuration
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> log4j:WARN No appenders could be found for logger
>>>>>>>>>>>>>>>>>>> (org.apache.fop.util.ContentHandlerFactoryRegistry).
>>>>>>>>>>>>>>>>>>> log4j:WARN Please initialize the log4j system properly.
>>>>>>>>>>>>>>>>>>> log4j:WARN See
>>>>>>>>>>>>>>>>>>> http://logging.apache.org/log4j/1.2/faq.html#noconfig
>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>> more info.
>>>>>>>>>>>>>>>>>>> i go to the faq guide and it say try loading the class or
>>>>>>>>>>>>>>>>>>> resource
>>>>>>>>>>>>>>>>>>> yourself.
>>>>>>>>>>>>>>>>>>> If you can't find it, neither will log4j.
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> aaa i dont know where to set this
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> also here its my xlst
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> http://old.nabble.com/file/p31835645/FacturasOMF.xsl
>>>>>>>>>>>>>>>>>>> FacturasOMF.xsl
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> and the fo file that generate the editix
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> http://old.nabble.com/file/p31835645/Prueba.fo Prueba.fo
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>> The first thing is to really dig into what you did to
>>>>>>>>>>>>>>>>>>>> netbeans
>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>> get
>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>> to work...
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> I've forgotten what your stylesheet looked like, so
>>>>>>>>>>>>>>>>>>>> maybe
>>>>>>>>>>>>>>>>>>>> if
>>>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>>>> show
>>>>>>>>>>>>>>>>>>>> us
>>>>>>>>>>>>>>>>>>>> again how you're referencing your images we might notice
>>>>>>>>>>>>>>>>>>>> a
>>>>>>>>>>>>>>>>>>>> problem.
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> It might also help to see the "fo" generated during your
>>>>>>>>>>>>>>>>>>>> transformation.
>>>>>>>>>>>>>>>>>>>> Can you grab that just after xslt and just before fop
>>>>>>>>>>>>>>>>>>>> calls.
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> Are you sure there is no error being logged somewhere
>>>>>>>>>>>>>>>>>>>> when
>>>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>>>> run
>>>>>>>>>>>>>>>>>>>> from
>>>>>>>>>>>>>>>>>>>> the command line? (Where is log4j writing and at what
>>>>>>>>>>>>>>>>>>>> level?)
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>> You where absolutly rigth i miss a few libraries to add
>>>>>>>>>>>>>>>>>>>>> into
>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>> jar
>>>>>>>>>>>>>>>>>>>>> file, i
>>>>>>>>>>>>>>>>>>>>> modified the build.xml to add the package and jar that
>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>> need,
>>>>>>>>>>>>>>>>>>>>> now
>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>> error
>>>>>>>>>>>>>>>>>>>>> message is not there but still the images dont show in
>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>> remeber
>>>>>>>>>>>>>>>>>>>>> that i do something in netbeans so they can add to the
>>>>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>>>>> but
>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>> cant
>>>>>>>>>>>>>>>>>>>>> remeber i dont now if there is still a library that is
>>>>>>>>>>>>>>>>>>>>> missing
>>>>>>>>>>>>>>>>>>>>> or
>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>> am
>>>>>>>>>>>>>>>>>>>>> adding more than it should be
>>>>>>>>>>>>>>>>>>>>> This is what i use :
>>>>>>>>>>>>>>>>>>>>> cfdi-base-0.1.6-SNAPSHOT.jar
>>>>>>>>>>>>>>>>>>>>> guava-r09.jar
>>>>>>>>>>>>>>>>>>>>> guava-r09-gwt.jar
>>>>>>>>>>>>>>>>>>>>> jaxb-impl-2.1.10.jar
>>>>>>>>>>>>>>>>>>>>> avalon-framework-api-4.3.jar
>>>>>>>>>>>>>>>>>>>>> avalon-framework-cvs-20020806.jar
>>>>>>>>>>>>>>>>>>>>> avalon-logkit-2.1.jar
>>>>>>>>>>>>>>>>>>>>> not-yet-commons-ssl-0.3.11.jar
>>>>>>>>>>>>>>>>>>>>> commons-codec-1.5.jar
>>>>>>>>>>>>>>>>>>>>> commons-codec-1.5-sources.jar
>>>>>>>>>>>>>>>>>>>>> log4j-1.2.16.jar
>>>>>>>>>>>>>>>>>>>>> fop.jar
>>>>>>>>>>>>>>>>>>>>> jdom.jar
>>>>>>>>>>>>>>>>>>>>> xmlgraphics-commons-1.4.jar
>>>>>>>>>>>>>>>>>>>>> commons-io-1.3.1.jar
>>>>>>>>>>>>>>>>>>>>> fop-pdf-images-2.0.1.SNAPSHOT.jar
>>>>>>>>>>>>>>>>>>>>> pdfbox-app-1.5.0.jar
>>>>>>>>>>>>>>>>>>>>> fontbox-1.3.1.jar
>>>>>>>>>>>>>>>>>>>>> jempbox-1.3.1.jar
>>>>>>>>>>>>>>>>>>>>> xercesImpl-2.7.1.jar
>>>>>>>>>>>>>>>>>>>>> batik-all-1.7.jar
>>>>>>>>>>>>>>>>>>>>> xml-apis-1.3.04.jar
>>>>>>>>>>>>>>>>>>>>> xml-apis-ext-1.3.04.jar
>>>>>>>>>>>>>>>>>>>>>           avalon-framework-4.2.0.jar
>>>>>>>>>>>>>>>>>>>>>           xalan-2.7.0.jar
>>>>>>>>>>>>>>>>>>>>>           serializer-2.7.0.jar
>>>>>>>>>>>>>>>>>>>>>           commons-logging-1.0.4.jar
>>>>>>>>>>>>>>>>>>>>>           jai_codec.jar
>>>>>>>>>>>>>>>>>>>>>           jai_core.jar
>>>>>>>>>>>>>>>>>>>>>           batik-ext.jar
>>>>>>>>>>>>>>>>>>>>>           jai_imageio-1.1-sources.jar
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> Thanks Rob for the help
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> I suspect running from your jar does not have/use the
>>>>>>>>>>>>>>>>>>>>>> same
>>>>>>>>>>>>>>>>>>>>>> classpath
>>>>>>>>>>>>>>>>>>>>>> that is in effect while you're in the debugger.
>>>>>>>>>>>>>>>>>>>>>> By what mechanism do you generate the jar?
>>>>>>>>>>>>>>>>>>>>>> Is it an executable jar or are you running java
>>>>>>>>>>>>>>>>>>>>>> -classpath
>>>>>>>>>>>>>>>>>>>>>> <your-jar-here:other-jars>          Main?
>>>>>>>>>>>>>>>>>>>>>> Make your IDE (netbeans) display the classpath  it
>>>>>>>>>>>>>>>>>>>>>> uses
>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>> run
>>>>>>>>>>>>>>>>>>>>>> your
>>>>>>>>>>>>>>>>>>>>>> app
>>>>>>>>>>>>>>>>>>>>>> and compare that with the above.
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> On 06/09/2011 07:21 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> aaa ok well my problem is that when i do the pdf in
>>>>>>>>>>>>>>>>>>>>>>> netbean
>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>>>>>>> fine
>>>>>>>>>>>>>>>>>>>>>>> with images and evething but when i run the jar file
>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>> command
>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>> give
>>>>>>>>>>>>>>>>>>>>>>> me a
>>>>>>>>>>>>>>>>>>>>>>> error
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> GRAVE: Error while processing image: I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException:
>>>>>>>>>>>>>>>>>>>>>>> Cannot
>>>>>>>>>>>>>>>>>>>>>>> load
>>>>>>>>>>>>>>>>>>>>>>>            image (no suitable loader/converter
>>>>>>>>>>>>>>>>>>>>>>> combination
>>>>>>>>>>>>>>>>>>>>>>> available)
>>>>>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>>>>            (image/jpeg)
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> so i dont no what its not working and if i have to
>>>>>>>>>>>>>>>>>>>>>>> add
>>>>>>>>>>>>>>>>>>>>>>> something
>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>> my
>>>>>>>>>>>>>>>>>>>>>>> code
>>>>>>>>>>>>>>>>>>>>>>> so the images can load i am soooo desperate what i am
>>>>>>>>>>>>>>>>>>>>>>> doing
>>>>>>>>>>>>>>>>>>>>>>> wrong??
>>>>>>>>>>>>>>>>>>>>>>> i am sorry for the trouble and if a dont explain my
>>>>>>>>>>>>>>>>>>>>>>> self
>>>>>>>>>>>>>>>>>>>>>>> very
>>>>>>>>>>>>>>>>>>>>>>> good
>>>>>>>>>>>>>>>>>>>>>>> jejeje
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> Not at all sure what your problem is.  All I can do
>>>>>>>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>>>>>>>> show
>>>>>>>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>>>>>>>> what
>>>>>>>>>>>>>>>>>>>>>>>> works for us.
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> Our source xml looks like this:
>>>>>>>>>>>>>>>>>>>>>>>> <image image-id="381623861" reference-id="ref-220"
>>>>>>>>>>>>>>>>>>>>>>>> width="750"
>>>>>>>>>>>>>>>>>>>>>>>> height="750" image-space-id="space-1" position="5"
>>>>>>>>>>>>>>>>>>>>>>>>                         image-pool-position="31"
>>>>>>>>>>>>>>>>>>>>>>>> pos="4"
>>>>>>>>>>>>>>>>>>>>>>>>                         file="ref_10_1002108221">
>>>>>>>>>>>>>>>>>>>>>>>> <!--
>>>>>>>>>>>>>>>>>>>>>>>> an
>>>>>>>>>>>>>>>>>>>>>>>> actual
>>>>>>>>>>>>>>>>>>>>>>>> file
>>>>>>>>>>>>>>>>>>>>>>>> (.jpeg
>>>>>>>>>>>>>>>>>>>>>>>> copied the working directory of the transformer -->
>>>>>>>>>>>>>>>>>>>>>>>> <fields />
>>>>>>>>>>>>>>>>>>>>>>>> <caption />
>>>>>>>>>>>>>>>>>>>>>>>> <annotations>
>>>>>>>>>>>>>>>>>>>>>>>> <arrow_positions origHeight="750" origWidth="750" />
>>>>>>>>>>>>>>>>>>>>>>>> </annotations>
>>>>>>>>>>>>>>>>>>>>>>>> </image>
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> Our xslt looks like this for each image needed.
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> <xsl:template name="image">
>>>>>>>>>>>>>>>>>>>>>>>> <xsl:param name="img"/>           <!-- This is the
>>>>>>>>>>>>>>>>>>>>>>>> xml
>>>>>>>>>>>>>>>>>>>>>>>> node
>>>>>>>>>>>>>>>>>>>>>>>> from
>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>> source
>>>>>>>>>>>>>>>>>>>>>>>> xml
>>>>>>>>>>>>>>>>>>>>>>>> above -->
>>>>>>>>>>>>>>>>>>>>>>>> <xsl:param name="width"/>
>>>>>>>>>>>>>>>>>>>>>>>> <xsl:param name="height" select="$width"/>
>>>>>>>>>>>>>>>>>>>>>>>> <xsl:param name="ignoreHeight">false</xsl:param>
>>>>>>>>>>>>>>>>>>>>>>>> <fo:block>
>>>>>>>>>>>>>>>>>>>>>>>> <fo:external-graphic src="{$img/@file}"
>>>>>>>>>>>>>>>>>>>>>>>> height="{$height}"
>>>>>>>>>>>>>>>>>>>>>>>> width="{$width}" content-height="scale-to-fit"
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> content-width="scale-to-fit"
>>>>>>>>>>>>>>>>>>>>>>>> border="0.5pt solid black"
>>>>>>>>>>>>>>>>>>>>>>>> border-collapse="separate">
>>>>>>>>>>>>>>>>>>>>>>>> <xsl:if test="$ignoreHeight != 'true'">
>>>>>>>>>>>>>>>>>>>>>>>> <xsl:attribute name="height">
>>>>>>>>>>>>>>>>>>>>>>>> <xsl:value-of select="$height"/>
>>>>>>>>>>>>>>>>>>>>>>>> </xsl:attribute>
>>>>>>>>>>>>>>>>>>>>>>>> </xsl:if>
>>>>>>>>>>>>>>>>>>>>>>>> </fo:external-graphic>
>>>>>>>>>>>>>>>>>>>>>>>> </fo:block>
>>>>>>>>>>>>>>>>>>>>>>>> </xsl:template>
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> Our generated fo looks like this:
>>>>>>>>>>>>>>>>>>>>>>>> <fo:table-cell>
>>>>>>>>>>>>>>>>>>>>>>>> <fo:block>
>>>>>>>>>>>>>>>>>>>>>>>> <fo:external-graphic border-collapse="separate"
>>>>>>>>>>>>>>>>>>>>>>>> border="0.5pt
>>>>>>>>>>>>>>>>>>>>>>>> solid
>>>>>>>>>>>>>>>>>>>>>>>> black" content-width="scale-to-fit"
>>>>>>>>>>>>>>>>>>>>>>>> content-height="scale-to-fit"
>>>>>>>>>>>>>>>>>>>>>>>> width="2.5in" height="2.5in" src="ref_10_1002108221"
>>>>>>>>>>>>>>>>>>>>>>>> />
>>>>>>>>>>>>>>>>>>>>>>>> </fo:block>
>>>>>>>>>>>>>>>>>>>>>>>> </fo:table-cell>
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> And the generated pdfs include the image and are
>>>>>>>>>>>>>>>>>>>>>>>> shipped
>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>> printer.
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> How does this stack up with what you have?
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> On 06/09/2011 01:19 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> Hi there well i still got the problem but searching
>>>>>>>>>>>>>>>>>>>>>>>>> IN
>>>>>>>>>>>>>>>>>>>>>>>>> INTERNET
>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>> find
>>>>>>>>>>>>>>>>>>>>>>>>> a
>>>>>>>>>>>>>>>>>>>>>>>>> JPEG
>>>>>>>>>>>>>>>>>>>>>>>>> renderer output for FOP its here
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> http://marc.info/?l=fop-user&m=125986752706366&w=2
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> the cuestion is can i render the image that i want
>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>> put
>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>> pdf,
>>>>>>>>>>>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>>>>>>>>>>>> then add to the xsl the render jpeg it will work??
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> and here explaints how use the render when he say
>>>>>>>>>>>>>>>>>>>>>>>>> uses
>>>>>>>>>>>>>>>>>>>>>>>>> fop
>>>>>>>>>>>>>>>>>>>>>>>>> as
>>>>>>>>>>>>>>>>>>>>>>>>> normal
>>>>>>>>>>>>>>>>>>>>>>>>> case
>>>>>>>>>>>>>>>>>>>>>>>>> what does it mean
>>>>>>>>>>>>>>>>>>>>>>>>> what else have to add to the code?? i hope you can
>>>>>>>>>>>>>>>>>>>>>>>>> help
>>>>>>>>>>>>>>>>>>>>>>>>> me
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> Thanks!!
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> // OutputStream out = what you want
>>>>>>>>>>>>>>>>>>>>>>>>>                        FopFactory fopFactory =
>>>>>>>>>>>>>>>>>>>>>>>>> FopFactory.newInstance();
>>>>>>>>>>>>>>>>>>>>>>>>>                        RendererFactory
>>>>>>>>>>>>>>>>>>>>>>>>> rendererFactory
>>>>>>>>>>>>>>>>>>>>>>>>> =
>>>>>>>>>>>>>>>>>>>>>>>>> null;
>>>>>>>>>>>>>>>>>>>>>>>>>                        FOUserAgent foUserAgent =
>>>>>>>>>>>>>>>>>>>>>>>>> null;
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>                        rendererFactory =
>>>>>>>>>>>>>>>>>>>>>>>>> fopFactory.getRendererFactory();
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> rendererFactory.addRendererMaker(new
>>>>>>>>>>>>>>>>>>>>>>>>> MultiRendererMaker("jpeg"));
>>>>>>>>>>>>>>>>>>>>>>>>>                        foUserAgent =
>>>>>>>>>>>>>>>>>>>>>>>>> fopFactory.newFOUserAgent();
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> rendererFactory.createRenderer(foUserAgent,
>>>>>>>>>>>>>>>>>>>>>>>>> "image/jpeg");
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>                        Fop fop =
>>>>>>>>>>>>>>>>>>>>>>>>> fopFactory.newFop("image/jpeg",
>>>>>>>>>>>>>>>>>>>>>>>>> foUserAgent,
>>>>>>>>>>>>>>>>>>>>>>>>> out);
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> //Use fop as normal case
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> Since you're now into xmlgraphics, I think you're
>>>>>>>>>>>>>>>>>>>>>>>>>> best
>>>>>>>>>>>>>>>>>>>>>>>>>> bet
>>>>>>>>>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>>>>>>>>>> here
>>>>>>>>>>>>>>>>>>>>>>>>>> <http://xmlgraphics.apache.org/commons/image-loader.html>
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/07/2011 10:18 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> Hi ok this is for generate images that dont need
>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>> be
>>>>>>>>>>>>>>>>>>>>>>>>>>> decompress
>>>>>>>>>>>>>>>>>>>>>>>>>>> later??
>>>>>>>>>>>>>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>>>>>>>>>>>>>> the result image i put in my xsl ?? then it
>>>>>>>>>>>>>>>>>>>>>>>>>>> should
>>>>>>>>>>>>>>>>>>>>>>>>>>> work,
>>>>>>>>>>>>>>>>>>>>>>>>>>> aaa
>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>> change
>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>> fop
>>>>>>>>>>>>>>>>>>>>>>>>>>> 1.0 and xml communs 1.4 and its the same jejeje
>>>>>>>>>>>>>>>>>>>>>>>>>>> dont
>>>>>>>>>>>>>>>>>>>>>>>>>>> find
>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>> image
>>>>>>>>>>>>>>>>>>>>>>>>>>> preload
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> org.apache.fop.fo.flow.ExternalGraphic bind
>>>>>>>>>>>>>>>>>>>>>>>>>>> SEVERE: Image not available: The file format is
>>>>>>>>>>>>>>>>>>>>>>>>>>> not
>>>>>>>>>>>>>>>>>>>>>>>>>>> supported.
>>>>>>>>>>>>>>>>>>>>>>>>>>> No
>>>>>>>>>>>>>>>>>>>>>>>>>>> ImagePreloader for *.jpg or *.bmp
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> ImageIO.write(bufferedImage, "JPEG", file);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/07/2011 08:21 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Ok i actually register the handler now what i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> do
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> setup
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> this
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> handler or not?? and how can i do that, also it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> seem
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> bmp
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> its
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> not
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> recognice also what can i do?? thanks for the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> help
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> rob
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> also i am trying to convert the images to see
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> if
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> helps
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/06/2011 02:29 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Hi what can be the difference between execute
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> program
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> netbeans
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> (where
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it works and print the images and the jar in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> console)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Different classes being loaded by Netbeans
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> than
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> console
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> app.
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Get
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Netbeans to show you the full classpath it's
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> using
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it's
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> "%classpath"
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> variable
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> also i tried the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> imageIO.getImageReadersBySuffix but i cant
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> interpretate
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> data
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> y.y,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> its
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> that or always its true in the boolean
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> variable,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> how
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> register
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> handler??
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Talk to IIORegistry, some thing like
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> CLibJPEGImageReaderSpi());
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> CLibJPEGImageWriterSpi());
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Note: those are not necessarily the services
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> your
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> setup.
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Thanks
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> See the javadoc on IIORegistry. With ImageIO
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> may
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> register
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> your handler(s). What does
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ImageIO.getImageReadersBySuffix()
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> give
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> you.
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For certain jpegs we don't use ImageIO,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> rather
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> classes
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> com.sun.image.codec.jpeg:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                        try {
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                            FileOutputStream
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fos
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> =
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> new
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> FileOutputStream(file);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                            JPEGImageEncoder
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> encoder =
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> JPEGCodec.createJPEGEncoder(fos);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                            JPEGEncodeParam
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> param =
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> encoder.getDefaultJPEGEncodeParam(image.getRaster(),
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> JPEGDecodeParam.COLOR_ID_CMYK);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                           
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> param.setQuality(1,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> false);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> encoder.encode(image.getRaster(),
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> param);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                            fos.close();
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                        } catch (Throwable t)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> {
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> logger.debug(t.getMessage());
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                        }
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> But generally we use ImageIO
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/06/2011 08:29 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Yeah i think i need your help again i tried
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> tu
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> run
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> .jar
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> file
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> console it work but without images this it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> what
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> appears
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> GRAVE: Error while processing image:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Cannot
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> load
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> image
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> (no
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> suitable loader/converter combination
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> available)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i tried  download the jai-imagio add to the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> class
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> path
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> but
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> dont
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> work
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Very odd.  I'm having no problems getting
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> images
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> into
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> pdfs
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> using
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-1.0.
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/03/2011 11:04 AM, Oscar.Flores
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> aaa hey thanks for the help the other
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> day,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> resolve
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> problem
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> changing
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> version of FOP for the 0.95beta instead
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> of
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> 1.0,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> works
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> now
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> prints
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the image and its good, thanks and we are
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> touch
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> if
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> anything
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> else
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fails
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> jejeje
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Nothing in the log from the transformer?
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/03/2011 09:47 AM, Oscar.Flores
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> hi there i have another problem i hope
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> help
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> me
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> create
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> with foe has no image, it dont show any
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> of
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> them,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> xsl
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> seems
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> be
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> rigth i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> tested with EditX and the pdf show me
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> image,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> what
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> be,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> xmlgraphics-commons-1.5svn, fop 1.0,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-pdf-images
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> 2.0.1
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Snapshot
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> render of the image but it don work
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> please
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> help!!!
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> :,(
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> :-):confused::confused::confused::confused:=)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> http://old.nabble.com/file/p31822059/libraries.jpeg
>>>>>>>>>>>>>>>>>>>>> http://old.nabble.com/file/p31822059/libraries.bmp
>>>>>>>>>>>>>>>>>>>>> libraries.bmp
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>> ---------------------------------------------------------------------
>>>>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>> For additional commands, e-mail:
>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>> ---------------------------------------------------------------------
>>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>>>>
>>>>>>
>>>>>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>
>>
>>

---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Problems with FOP and image

Posted by "Oscar.Flores" <fa...@hotmail.com>.
Hi there yeah its the pdf that give me the fop.bat i dont know why it works
this way and not from my java program anyway i am using fixed position i
show you my xlst to see if you can help me to correct the size 

http://old.nabble.com/file/p31897144/FacturasOMF.xsl FacturasOMF.xsl 
  

Rob Sargent-4 wrote:
> 
> Is the pdf you posted made via the .bat file then?  And it has all the 
> images you need? Which image is giving you all the trouble?
> 
> I see that you are incorrectly sizing the area into which you are 
> putting the address of the client. Alternatively you have placed the 
> table of items too high.  Are you using fixed positions?
> Those to pieces (client-address and invoice-items) should be in 
> consecutive blocks.
> On 06/17/2011 09:52 AM, Oscar.Flores wrote:
>> No i still can print the images in pdf in console what i do for now is
>> call a
>> bat to make the transformation with fo until i figure out what the
>> problem
>> is in log appear that can find a proper converter for the images
>>
>>
>> also another problem its that the table its to big it dont fit to the
>> data
>> here its the pdf that result
>> http://old.nabble.com/file/p31870136/Prueba3.pdf Prueba3.pdf
>>
>>   Warning(1979/26): fo:table, table-layout="auto" is currently not
>> supported
>>> by FOP
>>> but in my xslt it ike this<fo:table table-layout="fixed" width="100%">
>> the version of fop i use its 1.0
>>
>>
>>
>> Rob Sargent-4 wrote:
>>> I don't think you want to read and write to the same place. If the file
>>> is where you want it to be and it's otherwise in perfect shape you
>>> should be fine.  But if you do want to read it in and write it to some
>>> deployed area the that's what you want to do. Almost:
>>>       ImageIO.write(*newImage*, "JPEG", jpegImageFile);
>>>
>>> So without adding the ImageIO.write() call, are you getting the pdf you
>>> want yet?
>>> If not, what actual errors are you seeing in the logs.
>>>
>>> The warning about fo:table is not causing you any trouble.  What version
>>> of fop are you running (sorry I've forgotten)
>>>
>>>
>>>
>>>
>>>
>>>
>>> On 06/15/2011 02:51 PM, Oscar.Flores wrote:
>>>> Hi thanks for the help yeah i haven see that its was .java and not
>>>> .class, ok
>>>> then if i follow correctly what you are saying then it has to be
>>>> something
>>>> like this
>>>>
>>>> BufferedImage newImage = new BufferedImage ("C:\Logo.jpg")
>>>> ImageIO.write(BufferedImage, "JPEG", jpegImageFile) jpegImageFile will
>>>> be
>>>> the XML call rigth something like "C:\Logo.jpg")
>>>>
>>>> and another thing
>>>>
>>>>     Warning(1979/26): fo:table, table-layout="auto" is currently not
>>>> supported
>>>> by FOP
>>>> but in my xslt it ike this<fo:table table-layout="fixed" width="100%">
>>>> so
>>>> i dont now what its causing the ploblem
>>>>
>>>>
>>>>
>>>> Rob Sargent-4 wrote:
>>>>>
>>>>> On 06/14/2011 11:06 AM, Oscar.Flores wrote:
>>>>>> Yeah i do the class is in jai-imageio-1.1-sources.jar, the enviroment
>>>>>> is
>>>>>> just
>>>>> Having the file in the "...sources.jar" won't do the runtime world
>>>>> much
>>>>> good. You need the jar of .class files for jai-imageio, not .java
>>>>> files
>>>>>> windows xp, and the bufferedImage will be the path of the image??
>>>>> No, the bufferedImage is an in-memory instance of BufferedImage
>>>>> holding
>>>>> the bits of the image.  In the case that you have to read it from one
>>>>> place and write it to another.
>>>>>> Rob Sargent-4 wrote:
>>>>>>> Did you go through all your jars looking for
>>>>>>> 'CLibJPEGImageReaderSpi'.
>>>>>>> My greatest suspicion is that you don't have all your jars lined up.
>>>>>>> Which jar(s) do you think supplies these?
>>>>>>>
>>>>>>> What is your environment: just windows or do you have any tools like
>>>>>>> cygwin?
>>>>>>>
>>>>>>> The "jpegImageFile" would be the filename in your xsl the
>>>>>>> external-resource.  If you're just using a file that is already in
>>>>>>> place
>>>>>>> you don't have to re-write it.
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> On 06/14/2011 08:29 AM, Oscar.Flores wrote:
>>>>>>>> No i dont, and that weird jejeje netbeans seems to do that for me,
>>>>>>>> so
>>>>>>>> the
>>>>>>>> calls like ImageIO.write(BufferedImage, "JPEG", jpegImageFile)? do
>>>>>>>> i
>>>>>>>> have
>>>>>>>> to
>>>>>>>> do it in every image that i put in the pdf?? and the image is
>>>>>>>> gererate
>>>>>>>> directly in the pdf??how can i do it??
>>>>>>>>
>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>> Some jar to which netbeans has access has those classes.  Look in
>>>>>>>>> the
>>>>>>>>> output of jar tvf<each of your jars>     and see if any of those
>>>>>>>>> has
>>>>>>>>> the
>>>>>>>>> named classes.  If you find a jar with those classes make sure
>>>>>>>>> it's
>>>>>>>>> part
>>>>>>>>> of your classpath for you app.
>>>>>>>>>
>>>>>>>>> Are you making any calls like ImageIO.write(BufferedImage, "JPEG",
>>>>>>>>> jpegImageFile)?
>>>>>>>>>
>>>>>>>>> On 06/13/2011 05:31 PM, Oscar.Flores wrote:
>>>>>>>>>> ok i made a test and tell me that the class is missign but maybe
>>>>>>>>>> what
>>>>>>>>>> you
>>>>>>>>>> say
>>>>>>>>>> its rigth and it register the handler
>>>>>>>>>> so i gonna register the services so i do this
>>>>>>>>>>
>>>>>>>>>>       public static void main(String[] args) throws Exception {
>>>>>>>>>>               DOMConfigurator.configure("D:/Mis
>>>>>>>>>> documentos/NetBeansProjects/Factura/src/factura/log4j.xml");
>>>>>>>>>>               logger.info("Entering application.");
>>>>>>>>>>
>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>> CLibJPEGImageReaderSpi());
>>>>>>>>>>
>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>> CLibJPEGImageWriterSpi());
>>>>>>>>>>
>>>>>>>>>> also after register my services it telling me that the class
>>>>>>>>>> CLibJPEGImageReaderSpi() and CLibJPEGImageWriterSpi() is missing
>>>>>>>>>> but
>>>>>>>>>> only
>>>>>>>>>> in
>>>>>>>>>> command
>>>>>>>>>>
>>>>>>>>>> after register mi service, something more has to be done??
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>> I'm not sure I'm following correctly: does removing the
>>>>>>>>>>> xmlgraphics
>>>>>>>>>>> jar
>>>>>>>>>>> cause netbeans to behave the same as the command-line run of you
>>>>>>>>>>> app?
>>>>>>>>>>> If
>>>>>>>>>>> so, I suspect netbeans is registering services for you.  Your
>>>>>>>>>>> own
>>>>>>>>>>> code
>>>>>>>>>>> will have to make a call to one of the
>>>>>>>>>>> IIORegistry.registerServiceProvider() methods.
>>>>>>>>>>>
>>>>>>>>>>> On 06/13/2011 05:02 PM, Oscar.Flores wrote:
>>>>>>>>>>>> Ok aaaa i get it, actually the ImageIO library i added because
>>>>>>>>>>>> i
>>>>>>>>>>>> read
>>>>>>>>>>>> in
>>>>>>>>>>>> the
>>>>>>>>>>>> xmlgrapics that if something like the message
>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException: Cannot load
>>>>>>>>>>>> image
>>>>>>>>>>>> (no
>>>>>>>>>>>> suitable loader/converter combination available)appear i have
>>>>>>>>>>>> to
>>>>>>>>>>>> add
>>>>>>>>>>>> the
>>>>>>>>>>>> jar
>>>>>>>>>>>> file to the classpath but that all it say no configuration or
>>>>>>>>>>>> anything,
>>>>>>>>>>>> then
>>>>>>>>>>>> i delete the imagenIO libs and still i have the same output in
>>>>>>>>>>>> netbeans
>>>>>>>>>>>> so
>>>>>>>>>>>> xmlgrapics seem to have the problem in the plugins or i have to
>>>>>>>>>>>> configure
>>>>>>>>>>>> something
>>>>>>>>>>>>
>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>> Then it seems to me netbeans (if it's producing good output ==
>>>>>>>>>>>>> assumptionA) is still using something that the command-line
>>>>>>>>>>>>> isn't.
>>>>>>>>>>>>>
>>>>>>>>>>>>> And given assumptionA, you're java code is correct in terms of
>>>>>>>>>>>>> FOP
>>>>>>>>>>>>> and
>>>>>>>>>>>>> your configuration isn't for ImageIO.  Show your ImageIO
>>>>>>>>>>>>> related
>>>>>>>>>>>>> code
>>>>>>>>>>>>> and are you sure it's in your app.  Use the logger to show a
>>>>>>>>>>>>> message
>>>>>>>>>>>>> when you add  your loader.  Or list all ImageIO services:
>>>>>>>>>>>>> IIORegistry.getServiceProviders()
>>>>>>>>>>>>>
>>>>>>>>>>>>> On 06/13/2011 03:01 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>> ok well i put the xml in scr of my proyect i see that i still
>>>>>>>>>>>>>> have
>>>>>>>>>>>>>> the
>>>>>>>>>>>>>> same
>>>>>>>>>>>>>> issues of the image render of any image i dont now if the xml
>>>>>>>>>>>>>> its
>>>>>>>>>>>>>> in
>>>>>>>>>>>>>> place i
>>>>>>>>>>>>>> put the code down to see if something its missing
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> 15:45:07,827 ERROR [render] Error while processing image:
>>>>>>>>>>>>>> c:\cfd\nombregp.bmp (i
>>>>>>>>>>>>>> mage/bmp)
>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException: Cannot
>>>>>>>>>>>>>> load
>>>>>>>>>>>>>> image
>>>>>>>>>>>>>> (no
>>>>>>>>>>>>>> suitab
>>>>>>>>>>>>>> le loader/converter combination available) for
>>>>>>>>>>>>>> c:\cfd\nombregp.bmp
>>>>>>>>>>>>>> (image/bmp)
>>>>>>>>>>>>>>                at
>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageManager.getImage(ImageManage
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> import mx.bigdata.sat.cfd.schema.Comprobante;
>>>>>>>>>>>>>> import mx.bigdata.sat.cfd.CFDv2;
>>>>>>>>>>>>>> import mx.bigdata.sat.security.KeyLoader;
>>>>>>>>>>>>>> import org.jdom.*;
>>>>>>>>>>>>>> import org.jdom.input.SAXBuilder;
>>>>>>>>>>>>>> import org.jdom.output.XMLOutputter;
>>>>>>>>>>>>>> import org.jdom.output.Format;
>>>>>>>>>>>>>> import org.jdom.transform.JDOMSource;
>>>>>>>>>>>>>> //Java
>>>>>>>>>>>>>>         import java.io.File;
>>>>>>>>>>>>>>         import java.io.OutputStream;
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>         //JAXP
>>>>>>>>>>>>>>         import javax.xml.transform.Transformer;
>>>>>>>>>>>>>>         import javax.xml.transform.TransformerFactory;
>>>>>>>>>>>>>>         import javax.xml.transform.Source;
>>>>>>>>>>>>>>         import javax.xml.transform.Result;
>>>>>>>>>>>>>>         import javax.xml.transform.stream.StreamSource;
>>>>>>>>>>>>>>         import javax.xml.transform.sax.SAXResult;
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>         //FOP
>>>>>>>>>>>>>>         import org.apache.fop.apps.FOUserAgent;
>>>>>>>>>>>>>>         import org.apache.fop.apps.Fop;
>>>>>>>>>>>>>>         import org.apache.fop.apps.FopFactory;
>>>>>>>>>>>>>>         import org.apache.fop.apps.MimeConstants;
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>         //log4j
>>>>>>>>>>>>>>         import org.apache.log4j.*;
>>>>>>>>>>>>>>         import org.apache.log4j.xml.DOMConfigurator;
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> public final class Main {
>>>>>>>>>>>>>>            @SuppressWarnings("unchecked")
>>>>>>>>>>>>>>            static Logger logger =
>>>>>>>>>>>>>> Logger.getLogger(Main.class);
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>            public static void main(String[] args) throws
>>>>>>>>>>>>>> Exception
>>>>>>>>>>>>>> {
>>>>>>>>>>>>>>                 DOMConfigurator.configure("D:/Mis
>>>>>>>>>>>>>> documentos/NetBeansProjects/Factura/src/factura/log4j.xml");
>>>>>>>>>>>>>>                 logger.info("Entering application.");
>>>>>>>>>>>>>>                 try {
>>>>>>>>>>>>>>                    File file = new File(args[0]);
>>>>>>>>>>>>>>                    Comprobante comp =
>>>>>>>>>>>>>> CFDv2.newComprobante(new
>>>>>>>>>>>>>> FileInputStream(file));
>>>>>>>>>>>>>>                    CFDv2 cfd = new CFDv2(comp);
>>>>>>>>>>>>>>                    PrivateKey key =
>>>>>>>>>>>>>> KeyLoader.loadPKCS8PrivateKey(new
>>>>>>>>>>>>>> FileInputStream(args[1]),(args[2]));
>>>>>>>>>>>>>>                    X509Certificate cert =
>>>>>>>>>>>>>> KeyLoader.loadX509Certificate(new
>>>>>>>>>>>>>> FileInputStream(args[3]));
>>>>>>>>>>>>>>                    Comprobante sellado =
>>>>>>>>>>>>>> cfd.sellarComprobante(key,
>>>>>>>>>>>>>> cert);
>>>>>>>>>>>>>>                    String cadena = cfd.getCadenaOriginal();
>>>>>>>>>>>>>>                    String sello = sellado.getSello();
>>>>>>>>>>>>>>                    // Creamos el builder basado en SAX
>>>>>>>>>>>>>>                    SAXBuilder builder = new SAXBuilder();
>>>>>>>>>>>>>>                    // Construimos el arbol DOM a partir del
>>>>>>>>>>>>>> fichero
>>>>>>>>>>>>>> xml
>>>>>>>>>>>>>>                    Document documentJDOM = builder.build(new
>>>>>>>>>>>>>> FileInputStream(args[0]));
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>                    Element raiz =
>>>>>>>>>>>>>> documentJDOM.getRootElement();//toma
>>>>>>>>>>>>>> el
>>>>>>>>>>>>>> nodo
>>>>>>>>>>>>>> raiz
>>>>>>>>>>>>>> del documento.
>>>>>>>>>>>>>>                    raiz.setAttribute("sello", sello);
>>>>>>>>>>>>>>                    raiz.setAttribute("certificado",
>>>>>>>>>>>>>> sellado.getCertificado());
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> //System.out.println(raiz.getAttributeValue("sello"));
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> //System.out.println(raiz.getAttributeValue("certificado"));
>>>>>>>>>>>>>>                    // Recorremos los hijos de la etiqueta
>>>>>>>>>>>>>> raíz
>>>>>>>>>>>>>>                    List<Element>        hijosRaiz =
>>>>>>>>>>>>>> raiz.getChildren();
>>>>>>>>>>>>>>                    boolean Bandera=false;
>>>>>>>>>>>>>>                    for(Element hijo: hijosRaiz)
>>>>>>>>>>>>>>                    {
>>>>>>>>>>>>>>                        // Obtenemos el nombre y su contenido
>>>>>>>>>>>>>> de
>>>>>>>>>>>>>> tipo
>>>>>>>>>>>>>> texto
>>>>>>>>>>>>>>                        String nombre = hijo.getName();
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>                        if (nombre.equals("Addenda"))
>>>>>>>>>>>>>>                        {   List<Element>        subHijo =
>>>>>>>>>>>>>> hijo.getChildren();
>>>>>>>>>>>>>>                            for(Element hij: subHijo)
>>>>>>>>>>>>>>                                {
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> hij.setAttribute("CadenaOriginal",
>>>>>>>>>>>>>> cadena);
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> //System.out.println("CadenaOriginal:
>>>>>>>>>>>>>> "+hij.getAttributeValue("CadenaOriginal"));
>>>>>>>>>>>>>>                                Bandera=true;
>>>>>>>>>>>>>>                                break;
>>>>>>>>>>>>>>                                }
>>>>>>>>>>>>>>                        }
>>>>>>>>>>>>>>                        if (Bandera)
>>>>>>>>>>>>>>                        {
>>>>>>>>>>>>>>                            XMLOutputter out = new
>>>>>>>>>>>>>> XMLOutputter(Format.getPrettyFormat());
>>>>>>>>>>>>>>                            File nuevoXML = new File(args[0]);
>>>>>>>>>>>>>>                            try{
>>>>>>>>>>>>>>                                FileOutputStream archivoXML=
>>>>>>>>>>>>>> new
>>>>>>>>>>>>>> FileOutputStream
>>>>>>>>>>>>>> (nuevoXML);
>>>>>>>>>>>>>>                                out.output(documentJDOM,
>>>>>>>>>>>>>> archivoXML);
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>                               }
>>>>>>>>>>>>>>                            catch (Exception
>>>>>>>>>>>>>> ex){System.out.println(ex.getMessage());}
>>>>>>>>>>>>>>                            // Para generar el pdf a partir de
>>>>>>>>>>>>>> un
>>>>>>>>>>>>>> archivo.xsl
>>>>>>>>>>>>>> y
>>>>>>>>>>>>>> un
>>>>>>>>>>>>>>                            // archivo.xml
>>>>>>>>>>>>>>                        }
>>>>>>>>>>>>>>                      }
>>>>>>>>>>>>>>                  // configure fopFactory as desired
>>>>>>>>>>>>>>                  FopFactory fopFactory =
>>>>>>>>>>>>>> FopFactory.newInstance();
>>>>>>>>>>>>>>                  FOUserAgent foUserAgent =
>>>>>>>>>>>>>> fopFactory.newFOUserAgent();
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>                  // configure foUserAgent as desired
>>>>>>>>>>>>>>                  // Setup output
>>>>>>>>>>>>>>                 File pdffile = new File(args[5]);
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>                 OutputStream out = new
>>>>>>>>>>>>>> java.io.FileOutputStream(pdffile);
>>>>>>>>>>>>>>                 out = new java.io.BufferedOutputStream(out);
>>>>>>>>>>>>>>                 try {
>>>>>>>>>>>>>>                        // Construct fop with desired output
>>>>>>>>>>>>>> format
>>>>>>>>>>>>>>                         Fop fop =
>>>>>>>>>>>>>> fopFactory.newFop(MimeConstants.MIME_PDF,
>>>>>>>>>>>>>> foUserAgent, out);
>>>>>>>>>>>>>>                        // Setup XSLT
>>>>>>>>>>>>>>                        TransformerFactory factory =
>>>>>>>>>>>>>> TransformerFactory.newInstance();
>>>>>>>>>>>>>>                        Transformer transformer =
>>>>>>>>>>>>>> factory.newTransformer(new
>>>>>>>>>>>>>> StreamSource(args[4]));
>>>>>>>>>>>>>>                        // Set the value of a  in the
>>>>>>>>>>>>>> stylesheet
>>>>>>>>>>>>>>                       
>>>>>>>>>>>>>> transformer.setParameter("versionParam",
>>>>>>>>>>>>>> "2.0");
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>                       // Setup input for XSLT transformation
>>>>>>>>>>>>>>                        Source src = new
>>>>>>>>>>>>>> JDOMSource(documentJDOM);
>>>>>>>>>>>>>>                         // Resulting SAX events (the
>>>>>>>>>>>>>> generated
>>>>>>>>>>>>>> FO)
>>>>>>>>>>>>>> must
>>>>>>>>>>>>>> be
>>>>>>>>>>>>>> piped
>>>>>>>>>>>>>> through to FOP
>>>>>>>>>>>>>>                        Result res = new
>>>>>>>>>>>>>> SAXResult(fop.getDefaultHandler());
>>>>>>>>>>>>>>                         // Start XSLT transformation and FOP
>>>>>>>>>>>>>> processing
>>>>>>>>>>>>>>                       //
>>>>>>>>>>>>>> System.setProperty("java.awt.headless",
>>>>>>>>>>>>>> "true");
>>>>>>>>>>>>>>                            transformer.transform(src, res);
>>>>>>>>>>>>>>                        } finally {
>>>>>>>>>>>>>>                         out.close();
>>>>>>>>>>>>>>                    }
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>                  System.out.println("Success!");
>>>>>>>>>>>>>>                 } catch (Exception e) {
>>>>>>>>>>>>>>                  e.printStackTrace(System.err);
>>>>>>>>>>>>>>                  System.exit(-1);
>>>>>>>>>>>>>>               }
>>>>>>>>>>>>>>             logger.info("Exiting application.");
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>          }
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>> Try this log4j.xml: Place it at the root of your jar file
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> <?xml version="1.0" encoding="UTF-8"?>
>>>>>>>>>>>>>>> <!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> <log4j:configuration
>>>>>>>>>>>>>>> xmlns:log4j="http://jakarta.apache.org/log4j/"
>>>>>>>>>>>>>>> debug="false">
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> <appender name="CONSOLE"
>>>>>>>>>>>>>>> class="org.apache.log4j.ConsoleAppender">
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> <layout class="org.apache.log4j.PatternLayout">
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> </layout>
>>>>>>>>>>>>>>> </appender>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> <category name="org">
>>>>>>>>>>>>>>> <priority value="DEBUG"/>
>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>> <category name="org.apache">
>>>>>>>>>>>>>>> <priority value="WARN"/>
>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>> <category name="org.springframework">
>>>>>>>>>>>>>>> <priority value="WARN"/>
>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>> <category name="org.hibernate">
>>>>>>>>>>>>>>> <priority value="DEBUG"/>
>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>> <category name="net">
>>>>>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>> <category name="javax">
>>>>>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>> <category name="java">
>>>>>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>> <category name="sun">
>>>>>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>> <category name="org.jboss">
>>>>>>>>>>>>>>> <priority value="INFO"/>
>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>> <category name="org.jboss.seam">
>>>>>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>>> <root>
>>>>>>>>>>>>>>> <appender-ref ref="CONSOLE"/>
>>>>>>>>>>>>>>> </root>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> </log4j:configuration>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> On 06/13/2011 11:06 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>> ok i dont thik i have a configuracion file i find the code
>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>> put
>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>> other post i think its the basic
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>> Do you have a config file for log4j.  Usually it's in a
>>>>>>>>>>>>>>>>> resource
>>>>>>>>>>>>>>>>> tree.
>>>>>>>>>>>>>>>>> Are you copying that to your deployment? Is your ant
>>>>>>>>>>>>>>>>> script
>>>>>>>>>>>>>>>>> including
>>>>>>>>>>>>>>>>> the config file in the jar of your application?
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> On 06/13/2011 10:12 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>> Ok yeah the log4j its having isuees to find the
>>>>>>>>>>>>>>>>>> configuration
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> log4j:WARN No appenders could be found for logger
>>>>>>>>>>>>>>>>>> (org.apache.fop.util.ContentHandlerFactoryRegistry).
>>>>>>>>>>>>>>>>>> log4j:WARN Please initialize the log4j system properly.
>>>>>>>>>>>>>>>>>> log4j:WARN See
>>>>>>>>>>>>>>>>>> http://logging.apache.org/log4j/1.2/faq.html#noconfig
>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>> more info.
>>>>>>>>>>>>>>>>>> i go to the faq guide and it say try loading the class or
>>>>>>>>>>>>>>>>>> resource
>>>>>>>>>>>>>>>>>> yourself.
>>>>>>>>>>>>>>>>>> If you can't find it, neither will log4j.
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> aaa i dont know where to set this
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> also here its my xlst
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> http://old.nabble.com/file/p31835645/FacturasOMF.xsl
>>>>>>>>>>>>>>>>>> FacturasOMF.xsl
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> and the fo file that generate the editix
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> http://old.nabble.com/file/p31835645/Prueba.fo Prueba.fo
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>> The first thing is to really dig into what you did to
>>>>>>>>>>>>>>>>>>> netbeans
>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>> get
>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>> to work...
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> I've forgotten what your stylesheet looked like, so
>>>>>>>>>>>>>>>>>>> maybe
>>>>>>>>>>>>>>>>>>> if
>>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>>> show
>>>>>>>>>>>>>>>>>>> us
>>>>>>>>>>>>>>>>>>> again how you're referencing your images we might notice
>>>>>>>>>>>>>>>>>>> a
>>>>>>>>>>>>>>>>>>> problem.
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> It might also help to see the "fo" generated during your
>>>>>>>>>>>>>>>>>>> transformation.
>>>>>>>>>>>>>>>>>>> Can you grab that just after xslt and just before fop
>>>>>>>>>>>>>>>>>>> calls.
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> Are you sure there is no error being logged somewhere
>>>>>>>>>>>>>>>>>>> when
>>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>>> run
>>>>>>>>>>>>>>>>>>> from
>>>>>>>>>>>>>>>>>>> the command line? (Where is log4j writing and at what
>>>>>>>>>>>>>>>>>>> level?)
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>> You where absolutly rigth i miss a few libraries to add
>>>>>>>>>>>>>>>>>>>> into
>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>> jar
>>>>>>>>>>>>>>>>>>>> file, i
>>>>>>>>>>>>>>>>>>>> modified the build.xml to add the package and jar that
>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>> need,
>>>>>>>>>>>>>>>>>>>> now
>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>> error
>>>>>>>>>>>>>>>>>>>> message is not there but still the images dont show in
>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>> remeber
>>>>>>>>>>>>>>>>>>>> that i do something in netbeans so they can add to the
>>>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>>>> but
>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>> cant
>>>>>>>>>>>>>>>>>>>> remeber i dont now if there is still a library that is
>>>>>>>>>>>>>>>>>>>> missing
>>>>>>>>>>>>>>>>>>>> or
>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>> am
>>>>>>>>>>>>>>>>>>>> adding more than it should be
>>>>>>>>>>>>>>>>>>>> This is what i use :
>>>>>>>>>>>>>>>>>>>> cfdi-base-0.1.6-SNAPSHOT.jar
>>>>>>>>>>>>>>>>>>>> guava-r09.jar
>>>>>>>>>>>>>>>>>>>> guava-r09-gwt.jar
>>>>>>>>>>>>>>>>>>>> jaxb-impl-2.1.10.jar
>>>>>>>>>>>>>>>>>>>> avalon-framework-api-4.3.jar
>>>>>>>>>>>>>>>>>>>> avalon-framework-cvs-20020806.jar
>>>>>>>>>>>>>>>>>>>> avalon-logkit-2.1.jar
>>>>>>>>>>>>>>>>>>>> not-yet-commons-ssl-0.3.11.jar
>>>>>>>>>>>>>>>>>>>> commons-codec-1.5.jar
>>>>>>>>>>>>>>>>>>>> commons-codec-1.5-sources.jar
>>>>>>>>>>>>>>>>>>>> log4j-1.2.16.jar
>>>>>>>>>>>>>>>>>>>> fop.jar
>>>>>>>>>>>>>>>>>>>> jdom.jar
>>>>>>>>>>>>>>>>>>>> xmlgraphics-commons-1.4.jar
>>>>>>>>>>>>>>>>>>>> commons-io-1.3.1.jar
>>>>>>>>>>>>>>>>>>>> fop-pdf-images-2.0.1.SNAPSHOT.jar
>>>>>>>>>>>>>>>>>>>> pdfbox-app-1.5.0.jar
>>>>>>>>>>>>>>>>>>>> fontbox-1.3.1.jar
>>>>>>>>>>>>>>>>>>>> jempbox-1.3.1.jar
>>>>>>>>>>>>>>>>>>>> xercesImpl-2.7.1.jar
>>>>>>>>>>>>>>>>>>>> batik-all-1.7.jar
>>>>>>>>>>>>>>>>>>>> xml-apis-1.3.04.jar
>>>>>>>>>>>>>>>>>>>> xml-apis-ext-1.3.04.jar
>>>>>>>>>>>>>>>>>>>>           avalon-framework-4.2.0.jar
>>>>>>>>>>>>>>>>>>>>           xalan-2.7.0.jar
>>>>>>>>>>>>>>>>>>>>           serializer-2.7.0.jar
>>>>>>>>>>>>>>>>>>>>           commons-logging-1.0.4.jar
>>>>>>>>>>>>>>>>>>>>           jai_codec.jar
>>>>>>>>>>>>>>>>>>>>           jai_core.jar
>>>>>>>>>>>>>>>>>>>>           batik-ext.jar
>>>>>>>>>>>>>>>>>>>>           jai_imageio-1.1-sources.jar
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> Thanks Rob for the help
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> I suspect running from your jar does not have/use the
>>>>>>>>>>>>>>>>>>>>> same
>>>>>>>>>>>>>>>>>>>>> classpath
>>>>>>>>>>>>>>>>>>>>> that is in effect while you're in the debugger.
>>>>>>>>>>>>>>>>>>>>> By what mechanism do you generate the jar?
>>>>>>>>>>>>>>>>>>>>> Is it an executable jar or are you running java
>>>>>>>>>>>>>>>>>>>>> -classpath
>>>>>>>>>>>>>>>>>>>>> <your-jar-here:other-jars>          Main?
>>>>>>>>>>>>>>>>>>>>> Make your IDE (netbeans) display the classpath  it
>>>>>>>>>>>>>>>>>>>>> uses
>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>> run
>>>>>>>>>>>>>>>>>>>>> your
>>>>>>>>>>>>>>>>>>>>> app
>>>>>>>>>>>>>>>>>>>>> and compare that with the above.
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> On 06/09/2011 07:21 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> aaa ok well my problem is that when i do the pdf in
>>>>>>>>>>>>>>>>>>>>>> netbean
>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>>>>>> fine
>>>>>>>>>>>>>>>>>>>>>> with images and evething but when i run the jar file
>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>> command
>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>> give
>>>>>>>>>>>>>>>>>>>>>> me a
>>>>>>>>>>>>>>>>>>>>>> error
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> GRAVE: Error while processing image: I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException:
>>>>>>>>>>>>>>>>>>>>>> Cannot
>>>>>>>>>>>>>>>>>>>>>> load
>>>>>>>>>>>>>>>>>>>>>>            image (no suitable loader/converter
>>>>>>>>>>>>>>>>>>>>>> combination
>>>>>>>>>>>>>>>>>>>>>> available)
>>>>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>>>            (image/jpeg)
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> so i dont no what its not working and if i have to
>>>>>>>>>>>>>>>>>>>>>> add
>>>>>>>>>>>>>>>>>>>>>> something
>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>> my
>>>>>>>>>>>>>>>>>>>>>> code
>>>>>>>>>>>>>>>>>>>>>> so the images can load i am soooo desperate what i am
>>>>>>>>>>>>>>>>>>>>>> doing
>>>>>>>>>>>>>>>>>>>>>> wrong??
>>>>>>>>>>>>>>>>>>>>>> i am sorry for the trouble and if a dont explain my
>>>>>>>>>>>>>>>>>>>>>> self
>>>>>>>>>>>>>>>>>>>>>> very
>>>>>>>>>>>>>>>>>>>>>> good
>>>>>>>>>>>>>>>>>>>>>> jejeje
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> Not at all sure what your problem is.  All I can do
>>>>>>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>>>>>>> show
>>>>>>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>>>>>>> what
>>>>>>>>>>>>>>>>>>>>>>> works for us.
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> Our source xml looks like this:
>>>>>>>>>>>>>>>>>>>>>>> <image image-id="381623861" reference-id="ref-220"
>>>>>>>>>>>>>>>>>>>>>>> width="750"
>>>>>>>>>>>>>>>>>>>>>>> height="750" image-space-id="space-1" position="5"
>>>>>>>>>>>>>>>>>>>>>>>                         image-pool-position="31"
>>>>>>>>>>>>>>>>>>>>>>> pos="4"
>>>>>>>>>>>>>>>>>>>>>>>                         file="ref_10_1002108221">
>>>>>>>>>>>>>>>>>>>>>>> <!--
>>>>>>>>>>>>>>>>>>>>>>> an
>>>>>>>>>>>>>>>>>>>>>>> actual
>>>>>>>>>>>>>>>>>>>>>>> file
>>>>>>>>>>>>>>>>>>>>>>> (.jpeg
>>>>>>>>>>>>>>>>>>>>>>> copied the working directory of the transformer -->
>>>>>>>>>>>>>>>>>>>>>>> <fields />
>>>>>>>>>>>>>>>>>>>>>>> <caption />
>>>>>>>>>>>>>>>>>>>>>>> <annotations>
>>>>>>>>>>>>>>>>>>>>>>> <arrow_positions origHeight="750" origWidth="750" />
>>>>>>>>>>>>>>>>>>>>>>> </annotations>
>>>>>>>>>>>>>>>>>>>>>>> </image>
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> Our xslt looks like this for each image needed.
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> <xsl:template name="image">
>>>>>>>>>>>>>>>>>>>>>>> <xsl:param name="img"/>           <!-- This is the
>>>>>>>>>>>>>>>>>>>>>>> xml
>>>>>>>>>>>>>>>>>>>>>>> node
>>>>>>>>>>>>>>>>>>>>>>> from
>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>> source
>>>>>>>>>>>>>>>>>>>>>>> xml
>>>>>>>>>>>>>>>>>>>>>>> above -->
>>>>>>>>>>>>>>>>>>>>>>> <xsl:param name="width"/>
>>>>>>>>>>>>>>>>>>>>>>> <xsl:param name="height" select="$width"/>
>>>>>>>>>>>>>>>>>>>>>>> <xsl:param name="ignoreHeight">false</xsl:param>
>>>>>>>>>>>>>>>>>>>>>>> <fo:block>
>>>>>>>>>>>>>>>>>>>>>>> <fo:external-graphic src="{$img/@file}"
>>>>>>>>>>>>>>>>>>>>>>> height="{$height}"
>>>>>>>>>>>>>>>>>>>>>>> width="{$width}" content-height="scale-to-fit"
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> content-width="scale-to-fit"
>>>>>>>>>>>>>>>>>>>>>>> border="0.5pt solid black"
>>>>>>>>>>>>>>>>>>>>>>> border-collapse="separate">
>>>>>>>>>>>>>>>>>>>>>>> <xsl:if test="$ignoreHeight != 'true'">
>>>>>>>>>>>>>>>>>>>>>>> <xsl:attribute name="height">
>>>>>>>>>>>>>>>>>>>>>>> <xsl:value-of select="$height"/>
>>>>>>>>>>>>>>>>>>>>>>> </xsl:attribute>
>>>>>>>>>>>>>>>>>>>>>>> </xsl:if>
>>>>>>>>>>>>>>>>>>>>>>> </fo:external-graphic>
>>>>>>>>>>>>>>>>>>>>>>> </fo:block>
>>>>>>>>>>>>>>>>>>>>>>> </xsl:template>
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> Our generated fo looks like this:
>>>>>>>>>>>>>>>>>>>>>>> <fo:table-cell>
>>>>>>>>>>>>>>>>>>>>>>> <fo:block>
>>>>>>>>>>>>>>>>>>>>>>> <fo:external-graphic border-collapse="separate"
>>>>>>>>>>>>>>>>>>>>>>> border="0.5pt
>>>>>>>>>>>>>>>>>>>>>>> solid
>>>>>>>>>>>>>>>>>>>>>>> black" content-width="scale-to-fit"
>>>>>>>>>>>>>>>>>>>>>>> content-height="scale-to-fit"
>>>>>>>>>>>>>>>>>>>>>>> width="2.5in" height="2.5in" src="ref_10_1002108221"
>>>>>>>>>>>>>>>>>>>>>>> />
>>>>>>>>>>>>>>>>>>>>>>> </fo:block>
>>>>>>>>>>>>>>>>>>>>>>> </fo:table-cell>
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> And the generated pdfs include the image and are
>>>>>>>>>>>>>>>>>>>>>>> shipped
>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>> printer.
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> How does this stack up with what you have?
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> On 06/09/2011 01:19 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> Hi there well i still got the problem but searching
>>>>>>>>>>>>>>>>>>>>>>>> IN
>>>>>>>>>>>>>>>>>>>>>>>> INTERNET
>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>> find
>>>>>>>>>>>>>>>>>>>>>>>> a
>>>>>>>>>>>>>>>>>>>>>>>> JPEG
>>>>>>>>>>>>>>>>>>>>>>>> renderer output for FOP its here
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> http://marc.info/?l=fop-user&m=125986752706366&w=2
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> the cuestion is can i render the image that i want
>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>> put
>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>> pdf,
>>>>>>>>>>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>>>>>>>>>>> then add to the xsl the render jpeg it will work??
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> and here explaints how use the render when he say
>>>>>>>>>>>>>>>>>>>>>>>> uses
>>>>>>>>>>>>>>>>>>>>>>>> fop
>>>>>>>>>>>>>>>>>>>>>>>> as
>>>>>>>>>>>>>>>>>>>>>>>> normal
>>>>>>>>>>>>>>>>>>>>>>>> case
>>>>>>>>>>>>>>>>>>>>>>>> what does it mean
>>>>>>>>>>>>>>>>>>>>>>>> what else have to add to the code?? i hope you can
>>>>>>>>>>>>>>>>>>>>>>>> help
>>>>>>>>>>>>>>>>>>>>>>>> me
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> Thanks!!
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> // OutputStream out = what you want
>>>>>>>>>>>>>>>>>>>>>>>>                        FopFactory fopFactory =
>>>>>>>>>>>>>>>>>>>>>>>> FopFactory.newInstance();
>>>>>>>>>>>>>>>>>>>>>>>>                        RendererFactory
>>>>>>>>>>>>>>>>>>>>>>>> rendererFactory
>>>>>>>>>>>>>>>>>>>>>>>> =
>>>>>>>>>>>>>>>>>>>>>>>> null;
>>>>>>>>>>>>>>>>>>>>>>>>                        FOUserAgent foUserAgent =
>>>>>>>>>>>>>>>>>>>>>>>> null;
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>                        rendererFactory =
>>>>>>>>>>>>>>>>>>>>>>>> fopFactory.getRendererFactory();
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> rendererFactory.addRendererMaker(new
>>>>>>>>>>>>>>>>>>>>>>>> MultiRendererMaker("jpeg"));
>>>>>>>>>>>>>>>>>>>>>>>>                        foUserAgent =
>>>>>>>>>>>>>>>>>>>>>>>> fopFactory.newFOUserAgent();
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> rendererFactory.createRenderer(foUserAgent,
>>>>>>>>>>>>>>>>>>>>>>>> "image/jpeg");
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>                        Fop fop =
>>>>>>>>>>>>>>>>>>>>>>>> fopFactory.newFop("image/jpeg",
>>>>>>>>>>>>>>>>>>>>>>>> foUserAgent,
>>>>>>>>>>>>>>>>>>>>>>>> out);
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> //Use fop as normal case
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> Since you're now into xmlgraphics, I think you're
>>>>>>>>>>>>>>>>>>>>>>>>> best
>>>>>>>>>>>>>>>>>>>>>>>>> bet
>>>>>>>>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>>>>>>>>> here
>>>>>>>>>>>>>>>>>>>>>>>>> <http://xmlgraphics.apache.org/commons/image-loader.html>
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> On 06/07/2011 10:18 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> Hi ok this is for generate images that dont need
>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>> be
>>>>>>>>>>>>>>>>>>>>>>>>>> decompress
>>>>>>>>>>>>>>>>>>>>>>>>>> later??
>>>>>>>>>>>>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>>>>>>>>>>>>> the result image i put in my xsl ?? then it
>>>>>>>>>>>>>>>>>>>>>>>>>> should
>>>>>>>>>>>>>>>>>>>>>>>>>> work,
>>>>>>>>>>>>>>>>>>>>>>>>>> aaa
>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>> change
>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>> fop
>>>>>>>>>>>>>>>>>>>>>>>>>> 1.0 and xml communs 1.4 and its the same jejeje
>>>>>>>>>>>>>>>>>>>>>>>>>> dont
>>>>>>>>>>>>>>>>>>>>>>>>>> find
>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>> image
>>>>>>>>>>>>>>>>>>>>>>>>>> preload
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> org.apache.fop.fo.flow.ExternalGraphic bind
>>>>>>>>>>>>>>>>>>>>>>>>>> SEVERE: Image not available: The file format is
>>>>>>>>>>>>>>>>>>>>>>>>>> not
>>>>>>>>>>>>>>>>>>>>>>>>>> supported.
>>>>>>>>>>>>>>>>>>>>>>>>>> No
>>>>>>>>>>>>>>>>>>>>>>>>>> ImagePreloader for *.jpg or *.bmp
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> ImageIO.write(bufferedImage, "JPEG", file);
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/07/2011 08:21 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> Ok i actually register the handler now what i
>>>>>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>>> do
>>>>>>>>>>>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>>>>>>>>>>>> setup
>>>>>>>>>>>>>>>>>>>>>>>>>>>> this
>>>>>>>>>>>>>>>>>>>>>>>>>>>> handler or not?? and how can i do that, also it
>>>>>>>>>>>>>>>>>>>>>>>>>>>> seem
>>>>>>>>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>> bmp
>>>>>>>>>>>>>>>>>>>>>>>>>>>> its
>>>>>>>>>>>>>>>>>>>>>>>>>>>> not
>>>>>>>>>>>>>>>>>>>>>>>>>>>> recognice also what can i do?? thanks for the
>>>>>>>>>>>>>>>>>>>>>>>>>>>> help
>>>>>>>>>>>>>>>>>>>>>>>>>>>> rob
>>>>>>>>>>>>>>>>>>>>>>>>>>>> also i am trying to convert the images to see
>>>>>>>>>>>>>>>>>>>>>>>>>>>> if
>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>>>>>>>>> helps
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/06/2011 02:29 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Hi what can be the difference between execute
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> program
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> netbeans
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> (where
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it works and print the images and the jar in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> console)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Different classes being loaded by Netbeans
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> than
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> console
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> app.
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Get
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Netbeans to show you the full classpath it's
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> using
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it's
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> "%classpath"
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> variable
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> also i tried the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> imageIO.getImageReadersBySuffix but i cant
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> interpretate
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> data
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> y.y,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> its
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> that or always its true in the boolean
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> variable,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> how
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> register
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> handler??
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Talk to IIORegistry, some thing like
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> CLibJPEGImageReaderSpi());
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> CLibJPEGImageWriterSpi());
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Note: those are not necessarily the services
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> your
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> setup.
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Thanks
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> See the javadoc on IIORegistry. With ImageIO
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> may
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> register
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> your handler(s). What does
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ImageIO.getImageReadersBySuffix()
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> give
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> you.
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For certain jpegs we don't use ImageIO,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> rather
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> classes
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> com.sun.image.codec.jpeg:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                        try {
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                            FileOutputStream
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fos
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> =
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> new
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> FileOutputStream(file);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                            JPEGImageEncoder
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> encoder =
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> JPEGCodec.createJPEGEncoder(fos);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                            JPEGEncodeParam
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> param =
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> encoder.getDefaultJPEGEncodeParam(image.getRaster(),
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> JPEGDecodeParam.COLOR_ID_CMYK);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                           
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> param.setQuality(1,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> false);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> encoder.encode(image.getRaster(),
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> param);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                            fos.close();
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                        } catch (Throwable t)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> {
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> logger.debug(t.getMessage());
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                        }
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> But generally we use ImageIO
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/06/2011 08:29 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Yeah i think i need your help again i tried
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> tu
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> run
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> .jar
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> file
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> console it work but without images this it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> what
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> appears
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> GRAVE: Error while processing image:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Cannot
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> load
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> image
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> (no
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> suitable loader/converter combination
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> available)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i tried  download the jai-imagio add to the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> class
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> path
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> but
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> dont
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> work
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Very odd.  I'm having no problems getting
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> images
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> into
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> pdfs
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> using
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-1.0.
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/03/2011 11:04 AM, Oscar.Flores
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> aaa hey thanks for the help the other
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> day,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> resolve
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> problem
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> changing
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> version of FOP for the 0.95beta instead
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> of
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> 1.0,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> works
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> now
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> prints
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the image and its good, thanks and we are
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> touch
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> if
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> anything
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> else
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fails
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> jejeje
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Nothing in the log from the transformer?
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/03/2011 09:47 AM, Oscar.Flores
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> hi there i have another problem i hope
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> help
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> me
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> create
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> with foe has no image, it dont show any
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> of
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> them,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> xsl
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> seems
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> be
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> rigth i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> tested with EditX and the pdf show me
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> image,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> what
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> be,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> xmlgraphics-commons-1.5svn, fop 1.0,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-pdf-images
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> 2.0.1
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Snapshot
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> render of the image but it don work
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> please
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> help!!!
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> :,(
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> :-):confused::confused::confused::confused:=)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> http://old.nabble.com/file/p31822059/libraries.jpeg
>>>>>>>>>>>>>>>>>>>> http://old.nabble.com/file/p31822059/libraries.bmp
>>>>>>>>>>>>>>>>>>>> libraries.bmp
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>> For additional commands, e-mail:
>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>> ---------------------------------------------------------------------
>>>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>> For additional commands, e-mail:
>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>
>>>>>>>
>>>>>>>
>>>>> ---------------------------------------------------------------------
>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>>>
>>>>>
>>>>>
>>>
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
> 
> 
> 

-- 
View this message in context: http://old.nabble.com/Problems-with-FOP-and-image-tp31766430p31897144.html
Sent from the FOP - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Problems with FOP and image

Posted by Rob Sargent <rs...@xmission.com>.
Is the pdf you posted made via the .bat file then?  And it has all the 
images you need? Which image is giving you all the trouble?

I see that you are incorrectly sizing the area into which you are 
putting the address of the client. Alternatively you have placed the 
table of items too high.  Are you using fixed positions?
Those to pieces (client-address and invoice-items) should be in 
consecutive blocks.
On 06/17/2011 09:52 AM, Oscar.Flores wrote:
> No i still can print the images in pdf in console what i do for now is call a
> bat to make the transformation with fo until i figure out what the problem
> is in log appear that can find a proper converter for the images
>
>
> also another problem its that the table its to big it dont fit to the data
> here its the pdf that result
> http://old.nabble.com/file/p31870136/Prueba3.pdf Prueba3.pdf
>
>   Warning(1979/26): fo:table, table-layout="auto" is currently not supported
>> by FOP
>> but in my xslt it ike this<fo:table table-layout="fixed" width="100%">
> the version of fop i use its 1.0
>
>
>
> Rob Sargent-4 wrote:
>> I don't think you want to read and write to the same place. If the file
>> is where you want it to be and it's otherwise in perfect shape you
>> should be fine.  But if you do want to read it in and write it to some
>> deployed area the that's what you want to do. Almost:
>>       ImageIO.write(*newImage*, "JPEG", jpegImageFile);
>>
>> So without adding the ImageIO.write() call, are you getting the pdf you
>> want yet?
>> If not, what actual errors are you seeing in the logs.
>>
>> The warning about fo:table is not causing you any trouble.  What version
>> of fop are you running (sorry I've forgotten)
>>
>>
>>
>>
>>
>>
>> On 06/15/2011 02:51 PM, Oscar.Flores wrote:
>>> Hi thanks for the help yeah i haven see that its was .java and not
>>> .class, ok
>>> then if i follow correctly what you are saying then it has to be
>>> something
>>> like this
>>>
>>> BufferedImage newImage = new BufferedImage ("C:\Logo.jpg")
>>> ImageIO.write(BufferedImage, "JPEG", jpegImageFile) jpegImageFile will be
>>> the XML call rigth something like "C:\Logo.jpg")
>>>
>>> and another thing
>>>
>>>     Warning(1979/26): fo:table, table-layout="auto" is currently not
>>> supported
>>> by FOP
>>> but in my xslt it ike this<fo:table table-layout="fixed" width="100%">
>>> so
>>> i dont now what its causing the ploblem
>>>
>>>
>>>
>>> Rob Sargent-4 wrote:
>>>>
>>>> On 06/14/2011 11:06 AM, Oscar.Flores wrote:
>>>>> Yeah i do the class is in jai-imageio-1.1-sources.jar, the enviroment
>>>>> is
>>>>> just
>>>> Having the file in the "...sources.jar" won't do the runtime world much
>>>> good. You need the jar of .class files for jai-imageio, not .java files
>>>>> windows xp, and the bufferedImage will be the path of the image??
>>>> No, the bufferedImage is an in-memory instance of BufferedImage holding
>>>> the bits of the image.  In the case that you have to read it from one
>>>> place and write it to another.
>>>>> Rob Sargent-4 wrote:
>>>>>> Did you go through all your jars looking for
>>>>>> 'CLibJPEGImageReaderSpi'.
>>>>>> My greatest suspicion is that you don't have all your jars lined up.
>>>>>> Which jar(s) do you think supplies these?
>>>>>>
>>>>>> What is your environment: just windows or do you have any tools like
>>>>>> cygwin?
>>>>>>
>>>>>> The "jpegImageFile" would be the filename in your xsl the
>>>>>> external-resource.  If you're just using a file that is already in
>>>>>> place
>>>>>> you don't have to re-write it.
>>>>>>
>>>>>>
>>>>>>
>>>>>> On 06/14/2011 08:29 AM, Oscar.Flores wrote:
>>>>>>> No i dont, and that weird jejeje netbeans seems to do that for me, so
>>>>>>> the
>>>>>>> calls like ImageIO.write(BufferedImage, "JPEG", jpegImageFile)? do i
>>>>>>> have
>>>>>>> to
>>>>>>> do it in every image that i put in the pdf?? and the image is
>>>>>>> gererate
>>>>>>> directly in the pdf??how can i do it??
>>>>>>>
>>>>>>> Rob Sargent-4 wrote:
>>>>>>>> Some jar to which netbeans has access has those classes.  Look in
>>>>>>>> the
>>>>>>>> output of jar tvf<each of your jars>     and see if any of those has
>>>>>>>> the
>>>>>>>> named classes.  If you find a jar with those classes make sure it's
>>>>>>>> part
>>>>>>>> of your classpath for you app.
>>>>>>>>
>>>>>>>> Are you making any calls like ImageIO.write(BufferedImage, "JPEG",
>>>>>>>> jpegImageFile)?
>>>>>>>>
>>>>>>>> On 06/13/2011 05:31 PM, Oscar.Flores wrote:
>>>>>>>>> ok i made a test and tell me that the class is missign but maybe
>>>>>>>>> what
>>>>>>>>> you
>>>>>>>>> say
>>>>>>>>> its rigth and it register the handler
>>>>>>>>> so i gonna register the services so i do this
>>>>>>>>>
>>>>>>>>>       public static void main(String[] args) throws Exception {
>>>>>>>>>               DOMConfigurator.configure("D:/Mis
>>>>>>>>> documentos/NetBeansProjects/Factura/src/factura/log4j.xml");
>>>>>>>>>               logger.info("Entering application.");
>>>>>>>>>
>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>> CLibJPEGImageReaderSpi());
>>>>>>>>>
>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>> CLibJPEGImageWriterSpi());
>>>>>>>>>
>>>>>>>>> also after register my services it telling me that the class
>>>>>>>>> CLibJPEGImageReaderSpi() and CLibJPEGImageWriterSpi() is missing
>>>>>>>>> but
>>>>>>>>> only
>>>>>>>>> in
>>>>>>>>> command
>>>>>>>>>
>>>>>>>>> after register mi service, something more has to be done??
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>> I'm not sure I'm following correctly: does removing the
>>>>>>>>>> xmlgraphics
>>>>>>>>>> jar
>>>>>>>>>> cause netbeans to behave the same as the command-line run of you
>>>>>>>>>> app?
>>>>>>>>>> If
>>>>>>>>>> so, I suspect netbeans is registering services for you.  Your own
>>>>>>>>>> code
>>>>>>>>>> will have to make a call to one of the
>>>>>>>>>> IIORegistry.registerServiceProvider() methods.
>>>>>>>>>>
>>>>>>>>>> On 06/13/2011 05:02 PM, Oscar.Flores wrote:
>>>>>>>>>>> Ok aaaa i get it, actually the ImageIO library i added because i
>>>>>>>>>>> read
>>>>>>>>>>> in
>>>>>>>>>>> the
>>>>>>>>>>> xmlgrapics that if something like the message
>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException: Cannot load
>>>>>>>>>>> image
>>>>>>>>>>> (no
>>>>>>>>>>> suitable loader/converter combination available)appear i have to
>>>>>>>>>>> add
>>>>>>>>>>> the
>>>>>>>>>>> jar
>>>>>>>>>>> file to the classpath but that all it say no configuration or
>>>>>>>>>>> anything,
>>>>>>>>>>> then
>>>>>>>>>>> i delete the imagenIO libs and still i have the same output in
>>>>>>>>>>> netbeans
>>>>>>>>>>> so
>>>>>>>>>>> xmlgrapics seem to have the problem in the plugins or i have to
>>>>>>>>>>> configure
>>>>>>>>>>> something
>>>>>>>>>>>
>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>> Then it seems to me netbeans (if it's producing good output ==
>>>>>>>>>>>> assumptionA) is still using something that the command-line
>>>>>>>>>>>> isn't.
>>>>>>>>>>>>
>>>>>>>>>>>> And given assumptionA, you're java code is correct in terms of
>>>>>>>>>>>> FOP
>>>>>>>>>>>> and
>>>>>>>>>>>> your configuration isn't for ImageIO.  Show your ImageIO related
>>>>>>>>>>>> code
>>>>>>>>>>>> and are you sure it's in your app.  Use the logger to show a
>>>>>>>>>>>> message
>>>>>>>>>>>> when you add  your loader.  Or list all ImageIO services:
>>>>>>>>>>>> IIORegistry.getServiceProviders()
>>>>>>>>>>>>
>>>>>>>>>>>> On 06/13/2011 03:01 PM, Oscar.Flores wrote:
>>>>>>>>>>>>> ok well i put the xml in scr of my proyect i see that i still
>>>>>>>>>>>>> have
>>>>>>>>>>>>> the
>>>>>>>>>>>>> same
>>>>>>>>>>>>> issues of the image render of any image i dont now if the xml
>>>>>>>>>>>>> its
>>>>>>>>>>>>> in
>>>>>>>>>>>>> place i
>>>>>>>>>>>>> put the code down to see if something its missing
>>>>>>>>>>>>>
>>>>>>>>>>>>> 15:45:07,827 ERROR [render] Error while processing image:
>>>>>>>>>>>>> c:\cfd\nombregp.bmp (i
>>>>>>>>>>>>> mage/bmp)
>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException: Cannot load
>>>>>>>>>>>>> image
>>>>>>>>>>>>> (no
>>>>>>>>>>>>> suitab
>>>>>>>>>>>>> le loader/converter combination available) for
>>>>>>>>>>>>> c:\cfd\nombregp.bmp
>>>>>>>>>>>>> (image/bmp)
>>>>>>>>>>>>>                at
>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageManager.getImage(ImageManage
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> import mx.bigdata.sat.cfd.schema.Comprobante;
>>>>>>>>>>>>> import mx.bigdata.sat.cfd.CFDv2;
>>>>>>>>>>>>> import mx.bigdata.sat.security.KeyLoader;
>>>>>>>>>>>>> import org.jdom.*;
>>>>>>>>>>>>> import org.jdom.input.SAXBuilder;
>>>>>>>>>>>>> import org.jdom.output.XMLOutputter;
>>>>>>>>>>>>> import org.jdom.output.Format;
>>>>>>>>>>>>> import org.jdom.transform.JDOMSource;
>>>>>>>>>>>>> //Java
>>>>>>>>>>>>>         import java.io.File;
>>>>>>>>>>>>>         import java.io.OutputStream;
>>>>>>>>>>>>>
>>>>>>>>>>>>>         //JAXP
>>>>>>>>>>>>>         import javax.xml.transform.Transformer;
>>>>>>>>>>>>>         import javax.xml.transform.TransformerFactory;
>>>>>>>>>>>>>         import javax.xml.transform.Source;
>>>>>>>>>>>>>         import javax.xml.transform.Result;
>>>>>>>>>>>>>         import javax.xml.transform.stream.StreamSource;
>>>>>>>>>>>>>         import javax.xml.transform.sax.SAXResult;
>>>>>>>>>>>>>
>>>>>>>>>>>>>         //FOP
>>>>>>>>>>>>>         import org.apache.fop.apps.FOUserAgent;
>>>>>>>>>>>>>         import org.apache.fop.apps.Fop;
>>>>>>>>>>>>>         import org.apache.fop.apps.FopFactory;
>>>>>>>>>>>>>         import org.apache.fop.apps.MimeConstants;
>>>>>>>>>>>>>
>>>>>>>>>>>>>         //log4j
>>>>>>>>>>>>>         import org.apache.log4j.*;
>>>>>>>>>>>>>         import org.apache.log4j.xml.DOMConfigurator;
>>>>>>>>>>>>>
>>>>>>>>>>>>> public final class Main {
>>>>>>>>>>>>>            @SuppressWarnings("unchecked")
>>>>>>>>>>>>>            static Logger logger = Logger.getLogger(Main.class);
>>>>>>>>>>>>>
>>>>>>>>>>>>>            public static void main(String[] args) throws
>>>>>>>>>>>>> Exception
>>>>>>>>>>>>> {
>>>>>>>>>>>>>                 DOMConfigurator.configure("D:/Mis
>>>>>>>>>>>>> documentos/NetBeansProjects/Factura/src/factura/log4j.xml");
>>>>>>>>>>>>>                 logger.info("Entering application.");
>>>>>>>>>>>>>                 try {
>>>>>>>>>>>>>                    File file = new File(args[0]);
>>>>>>>>>>>>>                    Comprobante comp = CFDv2.newComprobante(new
>>>>>>>>>>>>> FileInputStream(file));
>>>>>>>>>>>>>                    CFDv2 cfd = new CFDv2(comp);
>>>>>>>>>>>>>                    PrivateKey key =
>>>>>>>>>>>>> KeyLoader.loadPKCS8PrivateKey(new
>>>>>>>>>>>>> FileInputStream(args[1]),(args[2]));
>>>>>>>>>>>>>                    X509Certificate cert =
>>>>>>>>>>>>> KeyLoader.loadX509Certificate(new
>>>>>>>>>>>>> FileInputStream(args[3]));
>>>>>>>>>>>>>                    Comprobante sellado =
>>>>>>>>>>>>> cfd.sellarComprobante(key,
>>>>>>>>>>>>> cert);
>>>>>>>>>>>>>                    String cadena = cfd.getCadenaOriginal();
>>>>>>>>>>>>>                    String sello = sellado.getSello();
>>>>>>>>>>>>>                    // Creamos el builder basado en SAX
>>>>>>>>>>>>>                    SAXBuilder builder = new SAXBuilder();
>>>>>>>>>>>>>                    // Construimos el arbol DOM a partir del
>>>>>>>>>>>>> fichero
>>>>>>>>>>>>> xml
>>>>>>>>>>>>>                    Document documentJDOM = builder.build(new
>>>>>>>>>>>>> FileInputStream(args[0]));
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>                    Element raiz =
>>>>>>>>>>>>> documentJDOM.getRootElement();//toma
>>>>>>>>>>>>> el
>>>>>>>>>>>>> nodo
>>>>>>>>>>>>> raiz
>>>>>>>>>>>>> del documento.
>>>>>>>>>>>>>                    raiz.setAttribute("sello", sello);
>>>>>>>>>>>>>                    raiz.setAttribute("certificado",
>>>>>>>>>>>>> sellado.getCertificado());
>>>>>>>>>>>>>
>>>>>>>>>>>>> //System.out.println(raiz.getAttributeValue("sello"));
>>>>>>>>>>>>>
>>>>>>>>>>>>> //System.out.println(raiz.getAttributeValue("certificado"));
>>>>>>>>>>>>>                    // Recorremos los hijos de la etiqueta raíz
>>>>>>>>>>>>>                    List<Element>        hijosRaiz =
>>>>>>>>>>>>> raiz.getChildren();
>>>>>>>>>>>>>                    boolean Bandera=false;
>>>>>>>>>>>>>                    for(Element hijo: hijosRaiz)
>>>>>>>>>>>>>                    {
>>>>>>>>>>>>>                        // Obtenemos el nombre y su contenido de
>>>>>>>>>>>>> tipo
>>>>>>>>>>>>> texto
>>>>>>>>>>>>>                        String nombre = hijo.getName();
>>>>>>>>>>>>>
>>>>>>>>>>>>>                        if (nombre.equals("Addenda"))
>>>>>>>>>>>>>                        {   List<Element>        subHijo =
>>>>>>>>>>>>> hijo.getChildren();
>>>>>>>>>>>>>                            for(Element hij: subHijo)
>>>>>>>>>>>>>                                {
>>>>>>>>>>>>>
>>>>>>>>>>>>> hij.setAttribute("CadenaOriginal",
>>>>>>>>>>>>> cadena);
>>>>>>>>>>>>>
>>>>>>>>>>>>> //System.out.println("CadenaOriginal:
>>>>>>>>>>>>> "+hij.getAttributeValue("CadenaOriginal"));
>>>>>>>>>>>>>                                Bandera=true;
>>>>>>>>>>>>>                                break;
>>>>>>>>>>>>>                                }
>>>>>>>>>>>>>                        }
>>>>>>>>>>>>>                        if (Bandera)
>>>>>>>>>>>>>                        {
>>>>>>>>>>>>>                            XMLOutputter out = new
>>>>>>>>>>>>> XMLOutputter(Format.getPrettyFormat());
>>>>>>>>>>>>>                            File nuevoXML = new File(args[0]);
>>>>>>>>>>>>>                            try{
>>>>>>>>>>>>>                                FileOutputStream archivoXML= new
>>>>>>>>>>>>> FileOutputStream
>>>>>>>>>>>>> (nuevoXML);
>>>>>>>>>>>>>                                out.output(documentJDOM,
>>>>>>>>>>>>> archivoXML);
>>>>>>>>>>>>>
>>>>>>>>>>>>>                               }
>>>>>>>>>>>>>                            catch (Exception
>>>>>>>>>>>>> ex){System.out.println(ex.getMessage());}
>>>>>>>>>>>>>                            // Para generar el pdf a partir de un
>>>>>>>>>>>>> archivo.xsl
>>>>>>>>>>>>> y
>>>>>>>>>>>>> un
>>>>>>>>>>>>>                            // archivo.xml
>>>>>>>>>>>>>                        }
>>>>>>>>>>>>>                      }
>>>>>>>>>>>>>                  // configure fopFactory as desired
>>>>>>>>>>>>>                  FopFactory fopFactory =
>>>>>>>>>>>>> FopFactory.newInstance();
>>>>>>>>>>>>>                  FOUserAgent foUserAgent =
>>>>>>>>>>>>> fopFactory.newFOUserAgent();
>>>>>>>>>>>>>
>>>>>>>>>>>>>                  // configure foUserAgent as desired
>>>>>>>>>>>>>                  // Setup output
>>>>>>>>>>>>>                 File pdffile = new File(args[5]);
>>>>>>>>>>>>>
>>>>>>>>>>>>>                 OutputStream out = new
>>>>>>>>>>>>> java.io.FileOutputStream(pdffile);
>>>>>>>>>>>>>                 out = new java.io.BufferedOutputStream(out);
>>>>>>>>>>>>>                 try {
>>>>>>>>>>>>>                        // Construct fop with desired output
>>>>>>>>>>>>> format
>>>>>>>>>>>>>                         Fop fop =
>>>>>>>>>>>>> fopFactory.newFop(MimeConstants.MIME_PDF,
>>>>>>>>>>>>> foUserAgent, out);
>>>>>>>>>>>>>                        // Setup XSLT
>>>>>>>>>>>>>                        TransformerFactory factory =
>>>>>>>>>>>>> TransformerFactory.newInstance();
>>>>>>>>>>>>>                        Transformer transformer =
>>>>>>>>>>>>> factory.newTransformer(new
>>>>>>>>>>>>> StreamSource(args[4]));
>>>>>>>>>>>>>                        // Set the value of a  in the stylesheet
>>>>>>>>>>>>>                        transformer.setParameter("versionParam",
>>>>>>>>>>>>> "2.0");
>>>>>>>>>>>>>
>>>>>>>>>>>>>                       // Setup input for XSLT transformation
>>>>>>>>>>>>>                        Source src = new
>>>>>>>>>>>>> JDOMSource(documentJDOM);
>>>>>>>>>>>>>                         // Resulting SAX events (the generated
>>>>>>>>>>>>> FO)
>>>>>>>>>>>>> must
>>>>>>>>>>>>> be
>>>>>>>>>>>>> piped
>>>>>>>>>>>>> through to FOP
>>>>>>>>>>>>>                        Result res = new
>>>>>>>>>>>>> SAXResult(fop.getDefaultHandler());
>>>>>>>>>>>>>                         // Start XSLT transformation and FOP
>>>>>>>>>>>>> processing
>>>>>>>>>>>>>                       // System.setProperty("java.awt.headless",
>>>>>>>>>>>>> "true");
>>>>>>>>>>>>>                            transformer.transform(src, res);
>>>>>>>>>>>>>                        } finally {
>>>>>>>>>>>>>                         out.close();
>>>>>>>>>>>>>                    }
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>                  System.out.println("Success!");
>>>>>>>>>>>>>                 } catch (Exception e) {
>>>>>>>>>>>>>                  e.printStackTrace(System.err);
>>>>>>>>>>>>>                  System.exit(-1);
>>>>>>>>>>>>>               }
>>>>>>>>>>>>>             logger.info("Exiting application.");
>>>>>>>>>>>>>
>>>>>>>>>>>>>          }
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>> Try this log4j.xml: Place it at the root of your jar file
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> <?xml version="1.0" encoding="UTF-8"?>
>>>>>>>>>>>>>> <!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> <log4j:configuration
>>>>>>>>>>>>>> xmlns:log4j="http://jakarta.apache.org/log4j/"
>>>>>>>>>>>>>> debug="false">
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> <appender name="CONSOLE"
>>>>>>>>>>>>>> class="org.apache.log4j.ConsoleAppender">
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> <layout class="org.apache.log4j.PatternLayout">
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> </layout>
>>>>>>>>>>>>>> </appender>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> <category name="org">
>>>>>>>>>>>>>> <priority value="DEBUG"/>
>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>> <category name="org.apache">
>>>>>>>>>>>>>> <priority value="WARN"/>
>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>> <category name="org.springframework">
>>>>>>>>>>>>>> <priority value="WARN"/>
>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>> <category name="org.hibernate">
>>>>>>>>>>>>>> <priority value="DEBUG"/>
>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>> <category name="net">
>>>>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>> <category name="javax">
>>>>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>> <category name="java">
>>>>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>> <category name="sun">
>>>>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>> <category name="org.jboss">
>>>>>>>>>>>>>> <priority value="INFO"/>
>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>> <category name="org.jboss.seam">
>>>>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>>>>> </category>
>>>>>>>>>>>>>> <root>
>>>>>>>>>>>>>> <appender-ref ref="CONSOLE"/>
>>>>>>>>>>>>>> </root>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> </log4j:configuration>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> On 06/13/2011 11:06 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>> ok i dont thik i have a configuracion file i find the code
>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>> put
>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>> other post i think its the basic
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>> Do you have a config file for log4j.  Usually it's in a
>>>>>>>>>>>>>>>> resource
>>>>>>>>>>>>>>>> tree.
>>>>>>>>>>>>>>>> Are you copying that to your deployment? Is your ant script
>>>>>>>>>>>>>>>> including
>>>>>>>>>>>>>>>> the config file in the jar of your application?
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> On 06/13/2011 10:12 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>> Ok yeah the log4j its having isuees to find the
>>>>>>>>>>>>>>>>> configuration
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> log4j:WARN No appenders could be found for logger
>>>>>>>>>>>>>>>>> (org.apache.fop.util.ContentHandlerFactoryRegistry).
>>>>>>>>>>>>>>>>> log4j:WARN Please initialize the log4j system properly.
>>>>>>>>>>>>>>>>> log4j:WARN See
>>>>>>>>>>>>>>>>> http://logging.apache.org/log4j/1.2/faq.html#noconfig
>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>> more info.
>>>>>>>>>>>>>>>>> i go to the faq guide and it say try loading the class or
>>>>>>>>>>>>>>>>> resource
>>>>>>>>>>>>>>>>> yourself.
>>>>>>>>>>>>>>>>> If you can't find it, neither will log4j.
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> aaa i dont know where to set this
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> also here its my xlst
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> http://old.nabble.com/file/p31835645/FacturasOMF.xsl
>>>>>>>>>>>>>>>>> FacturasOMF.xsl
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> and the fo file that generate the editix
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> http://old.nabble.com/file/p31835645/Prueba.fo Prueba.fo
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>> The first thing is to really dig into what you did to
>>>>>>>>>>>>>>>>>> netbeans
>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>> get
>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>> to work...
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> I've forgotten what your stylesheet looked like, so maybe
>>>>>>>>>>>>>>>>>> if
>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>> show
>>>>>>>>>>>>>>>>>> us
>>>>>>>>>>>>>>>>>> again how you're referencing your images we might notice a
>>>>>>>>>>>>>>>>>> problem.
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> It might also help to see the "fo" generated during your
>>>>>>>>>>>>>>>>>> transformation.
>>>>>>>>>>>>>>>>>> Can you grab that just after xslt and just before fop
>>>>>>>>>>>>>>>>>> calls.
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> Are you sure there is no error being logged somewhere when
>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>> run
>>>>>>>>>>>>>>>>>> from
>>>>>>>>>>>>>>>>>> the command line? (Where is log4j writing and at what
>>>>>>>>>>>>>>>>>> level?)
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>> You where absolutly rigth i miss a few libraries to add
>>>>>>>>>>>>>>>>>>> into
>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>> jar
>>>>>>>>>>>>>>>>>>> file, i
>>>>>>>>>>>>>>>>>>> modified the build.xml to add the package and jar that i
>>>>>>>>>>>>>>>>>>> need,
>>>>>>>>>>>>>>>>>>> now
>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>> error
>>>>>>>>>>>>>>>>>>> message is not there but still the images dont show in
>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>> remeber
>>>>>>>>>>>>>>>>>>> that i do something in netbeans so they can add to the
>>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>>> but
>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>> cant
>>>>>>>>>>>>>>>>>>> remeber i dont now if there is still a library that is
>>>>>>>>>>>>>>>>>>> missing
>>>>>>>>>>>>>>>>>>> or
>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>> am
>>>>>>>>>>>>>>>>>>> adding more than it should be
>>>>>>>>>>>>>>>>>>> This is what i use :
>>>>>>>>>>>>>>>>>>> cfdi-base-0.1.6-SNAPSHOT.jar
>>>>>>>>>>>>>>>>>>> guava-r09.jar
>>>>>>>>>>>>>>>>>>> guava-r09-gwt.jar
>>>>>>>>>>>>>>>>>>> jaxb-impl-2.1.10.jar
>>>>>>>>>>>>>>>>>>> avalon-framework-api-4.3.jar
>>>>>>>>>>>>>>>>>>> avalon-framework-cvs-20020806.jar
>>>>>>>>>>>>>>>>>>> avalon-logkit-2.1.jar
>>>>>>>>>>>>>>>>>>> not-yet-commons-ssl-0.3.11.jar
>>>>>>>>>>>>>>>>>>> commons-codec-1.5.jar
>>>>>>>>>>>>>>>>>>> commons-codec-1.5-sources.jar
>>>>>>>>>>>>>>>>>>> log4j-1.2.16.jar
>>>>>>>>>>>>>>>>>>> fop.jar
>>>>>>>>>>>>>>>>>>> jdom.jar
>>>>>>>>>>>>>>>>>>> xmlgraphics-commons-1.4.jar
>>>>>>>>>>>>>>>>>>> commons-io-1.3.1.jar
>>>>>>>>>>>>>>>>>>> fop-pdf-images-2.0.1.SNAPSHOT.jar
>>>>>>>>>>>>>>>>>>> pdfbox-app-1.5.0.jar
>>>>>>>>>>>>>>>>>>> fontbox-1.3.1.jar
>>>>>>>>>>>>>>>>>>> jempbox-1.3.1.jar
>>>>>>>>>>>>>>>>>>> xercesImpl-2.7.1.jar
>>>>>>>>>>>>>>>>>>> batik-all-1.7.jar
>>>>>>>>>>>>>>>>>>> xml-apis-1.3.04.jar
>>>>>>>>>>>>>>>>>>> xml-apis-ext-1.3.04.jar
>>>>>>>>>>>>>>>>>>>           avalon-framework-4.2.0.jar
>>>>>>>>>>>>>>>>>>>           xalan-2.7.0.jar
>>>>>>>>>>>>>>>>>>>           serializer-2.7.0.jar
>>>>>>>>>>>>>>>>>>>           commons-logging-1.0.4.jar
>>>>>>>>>>>>>>>>>>>           jai_codec.jar
>>>>>>>>>>>>>>>>>>>           jai_core.jar
>>>>>>>>>>>>>>>>>>>           batik-ext.jar
>>>>>>>>>>>>>>>>>>>           jai_imageio-1.1-sources.jar
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> Thanks Rob for the help
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> I suspect running from your jar does not have/use the
>>>>>>>>>>>>>>>>>>>> same
>>>>>>>>>>>>>>>>>>>> classpath
>>>>>>>>>>>>>>>>>>>> that is in effect while you're in the debugger.
>>>>>>>>>>>>>>>>>>>> By what mechanism do you generate the jar?
>>>>>>>>>>>>>>>>>>>> Is it an executable jar or are you running java
>>>>>>>>>>>>>>>>>>>> -classpath
>>>>>>>>>>>>>>>>>>>> <your-jar-here:other-jars>          Main?
>>>>>>>>>>>>>>>>>>>> Make your IDE (netbeans) display the classpath  it uses
>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>> run
>>>>>>>>>>>>>>>>>>>> your
>>>>>>>>>>>>>>>>>>>> app
>>>>>>>>>>>>>>>>>>>> and compare that with the above.
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> On 06/09/2011 07:21 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> aaa ok well my problem is that when i do the pdf in
>>>>>>>>>>>>>>>>>>>>> netbean
>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>>>>> fine
>>>>>>>>>>>>>>>>>>>>> with images and evething but when i run the jar file in
>>>>>>>>>>>>>>>>>>>>> command
>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>> give
>>>>>>>>>>>>>>>>>>>>> me a
>>>>>>>>>>>>>>>>>>>>> error
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> GRAVE: Error while processing image: I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException:
>>>>>>>>>>>>>>>>>>>>> Cannot
>>>>>>>>>>>>>>>>>>>>> load
>>>>>>>>>>>>>>>>>>>>>            image (no suitable loader/converter
>>>>>>>>>>>>>>>>>>>>> combination
>>>>>>>>>>>>>>>>>>>>> available)
>>>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>>            (image/jpeg)
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> so i dont no what its not working and if i have to add
>>>>>>>>>>>>>>>>>>>>> something
>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>> my
>>>>>>>>>>>>>>>>>>>>> code
>>>>>>>>>>>>>>>>>>>>> so the images can load i am soooo desperate what i am
>>>>>>>>>>>>>>>>>>>>> doing
>>>>>>>>>>>>>>>>>>>>> wrong??
>>>>>>>>>>>>>>>>>>>>> i am sorry for the trouble and if a dont explain my
>>>>>>>>>>>>>>>>>>>>> self
>>>>>>>>>>>>>>>>>>>>> very
>>>>>>>>>>>>>>>>>>>>> good
>>>>>>>>>>>>>>>>>>>>> jejeje
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> Not at all sure what your problem is.  All I can do is
>>>>>>>>>>>>>>>>>>>>>> show
>>>>>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>>>>>> what
>>>>>>>>>>>>>>>>>>>>>> works for us.
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> Our source xml looks like this:
>>>>>>>>>>>>>>>>>>>>>> <image image-id="381623861" reference-id="ref-220"
>>>>>>>>>>>>>>>>>>>>>> width="750"
>>>>>>>>>>>>>>>>>>>>>> height="750" image-space-id="space-1" position="5"
>>>>>>>>>>>>>>>>>>>>>>                         image-pool-position="31"
>>>>>>>>>>>>>>>>>>>>>> pos="4"
>>>>>>>>>>>>>>>>>>>>>>                         file="ref_10_1002108221">
>>>>>>>>>>>>>>>>>>>>>> <!--
>>>>>>>>>>>>>>>>>>>>>> an
>>>>>>>>>>>>>>>>>>>>>> actual
>>>>>>>>>>>>>>>>>>>>>> file
>>>>>>>>>>>>>>>>>>>>>> (.jpeg
>>>>>>>>>>>>>>>>>>>>>> copied the working directory of the transformer -->
>>>>>>>>>>>>>>>>>>>>>> <fields />
>>>>>>>>>>>>>>>>>>>>>> <caption />
>>>>>>>>>>>>>>>>>>>>>> <annotations>
>>>>>>>>>>>>>>>>>>>>>> <arrow_positions origHeight="750" origWidth="750" />
>>>>>>>>>>>>>>>>>>>>>> </annotations>
>>>>>>>>>>>>>>>>>>>>>> </image>
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> Our xslt looks like this for each image needed.
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> <xsl:template name="image">
>>>>>>>>>>>>>>>>>>>>>> <xsl:param name="img"/>           <!-- This is the xml
>>>>>>>>>>>>>>>>>>>>>> node
>>>>>>>>>>>>>>>>>>>>>> from
>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>> source
>>>>>>>>>>>>>>>>>>>>>> xml
>>>>>>>>>>>>>>>>>>>>>> above -->
>>>>>>>>>>>>>>>>>>>>>> <xsl:param name="width"/>
>>>>>>>>>>>>>>>>>>>>>> <xsl:param name="height" select="$width"/>
>>>>>>>>>>>>>>>>>>>>>> <xsl:param name="ignoreHeight">false</xsl:param>
>>>>>>>>>>>>>>>>>>>>>> <fo:block>
>>>>>>>>>>>>>>>>>>>>>> <fo:external-graphic src="{$img/@file}"
>>>>>>>>>>>>>>>>>>>>>> height="{$height}"
>>>>>>>>>>>>>>>>>>>>>> width="{$width}" content-height="scale-to-fit"
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> content-width="scale-to-fit"
>>>>>>>>>>>>>>>>>>>>>> border="0.5pt solid black" border-collapse="separate">
>>>>>>>>>>>>>>>>>>>>>> <xsl:if test="$ignoreHeight != 'true'">
>>>>>>>>>>>>>>>>>>>>>> <xsl:attribute name="height">
>>>>>>>>>>>>>>>>>>>>>> <xsl:value-of select="$height"/>
>>>>>>>>>>>>>>>>>>>>>> </xsl:attribute>
>>>>>>>>>>>>>>>>>>>>>> </xsl:if>
>>>>>>>>>>>>>>>>>>>>>> </fo:external-graphic>
>>>>>>>>>>>>>>>>>>>>>> </fo:block>
>>>>>>>>>>>>>>>>>>>>>> </xsl:template>
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> Our generated fo looks like this:
>>>>>>>>>>>>>>>>>>>>>> <fo:table-cell>
>>>>>>>>>>>>>>>>>>>>>> <fo:block>
>>>>>>>>>>>>>>>>>>>>>> <fo:external-graphic border-collapse="separate"
>>>>>>>>>>>>>>>>>>>>>> border="0.5pt
>>>>>>>>>>>>>>>>>>>>>> solid
>>>>>>>>>>>>>>>>>>>>>> black" content-width="scale-to-fit"
>>>>>>>>>>>>>>>>>>>>>> content-height="scale-to-fit"
>>>>>>>>>>>>>>>>>>>>>> width="2.5in" height="2.5in" src="ref_10_1002108221"
>>>>>>>>>>>>>>>>>>>>>> />
>>>>>>>>>>>>>>>>>>>>>> </fo:block>
>>>>>>>>>>>>>>>>>>>>>> </fo:table-cell>
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> And the generated pdfs include the image and are
>>>>>>>>>>>>>>>>>>>>>> shipped
>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>> printer.
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> How does this stack up with what you have?
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> On 06/09/2011 01:19 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> Hi there well i still got the problem but searching
>>>>>>>>>>>>>>>>>>>>>>> IN
>>>>>>>>>>>>>>>>>>>>>>> INTERNET
>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>> find
>>>>>>>>>>>>>>>>>>>>>>> a
>>>>>>>>>>>>>>>>>>>>>>> JPEG
>>>>>>>>>>>>>>>>>>>>>>> renderer output for FOP its here
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> http://marc.info/?l=fop-user&m=125986752706366&w=2
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> the cuestion is can i render the image that i want to
>>>>>>>>>>>>>>>>>>>>>>> put
>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>> pdf,
>>>>>>>>>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>>>>>>>>>> then add to the xsl the render jpeg it will work??
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> and here explaints how use the render when he say
>>>>>>>>>>>>>>>>>>>>>>> uses
>>>>>>>>>>>>>>>>>>>>>>> fop
>>>>>>>>>>>>>>>>>>>>>>> as
>>>>>>>>>>>>>>>>>>>>>>> normal
>>>>>>>>>>>>>>>>>>>>>>> case
>>>>>>>>>>>>>>>>>>>>>>> what does it mean
>>>>>>>>>>>>>>>>>>>>>>> what else have to add to the code?? i hope you can
>>>>>>>>>>>>>>>>>>>>>>> help
>>>>>>>>>>>>>>>>>>>>>>> me
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> Thanks!!
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> // OutputStream out = what you want
>>>>>>>>>>>>>>>>>>>>>>>                        FopFactory fopFactory =
>>>>>>>>>>>>>>>>>>>>>>> FopFactory.newInstance();
>>>>>>>>>>>>>>>>>>>>>>>                        RendererFactory rendererFactory
>>>>>>>>>>>>>>>>>>>>>>> =
>>>>>>>>>>>>>>>>>>>>>>> null;
>>>>>>>>>>>>>>>>>>>>>>>                        FOUserAgent foUserAgent = null;
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>                        rendererFactory =
>>>>>>>>>>>>>>>>>>>>>>> fopFactory.getRendererFactory();
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> rendererFactory.addRendererMaker(new
>>>>>>>>>>>>>>>>>>>>>>> MultiRendererMaker("jpeg"));
>>>>>>>>>>>>>>>>>>>>>>>                        foUserAgent =
>>>>>>>>>>>>>>>>>>>>>>> fopFactory.newFOUserAgent();
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> rendererFactory.createRenderer(foUserAgent,
>>>>>>>>>>>>>>>>>>>>>>> "image/jpeg");
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>                        Fop fop =
>>>>>>>>>>>>>>>>>>>>>>> fopFactory.newFop("image/jpeg",
>>>>>>>>>>>>>>>>>>>>>>> foUserAgent,
>>>>>>>>>>>>>>>>>>>>>>> out);
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> //Use fop as normal case
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> Since you're now into xmlgraphics, I think you're
>>>>>>>>>>>>>>>>>>>>>>>> best
>>>>>>>>>>>>>>>>>>>>>>>> bet
>>>>>>>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>>>>>>>> here
>>>>>>>>>>>>>>>>>>>>>>>> <http://xmlgraphics.apache.org/commons/image-loader.html>
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> On 06/07/2011 10:18 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> Hi ok this is for generate images that dont need to
>>>>>>>>>>>>>>>>>>>>>>>>> be
>>>>>>>>>>>>>>>>>>>>>>>>> decompress
>>>>>>>>>>>>>>>>>>>>>>>>> later??
>>>>>>>>>>>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>>>>>>>>>>>> the result image i put in my xsl ?? then it should
>>>>>>>>>>>>>>>>>>>>>>>>> work,
>>>>>>>>>>>>>>>>>>>>>>>>> aaa
>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>> change
>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>> fop
>>>>>>>>>>>>>>>>>>>>>>>>> 1.0 and xml communs 1.4 and its the same jejeje
>>>>>>>>>>>>>>>>>>>>>>>>> dont
>>>>>>>>>>>>>>>>>>>>>>>>> find
>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>> image
>>>>>>>>>>>>>>>>>>>>>>>>> preload
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> org.apache.fop.fo.flow.ExternalGraphic bind
>>>>>>>>>>>>>>>>>>>>>>>>> SEVERE: Image not available: The file format is not
>>>>>>>>>>>>>>>>>>>>>>>>> supported.
>>>>>>>>>>>>>>>>>>>>>>>>> No
>>>>>>>>>>>>>>>>>>>>>>>>> ImagePreloader for *.jpg or *.bmp
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> ImageIO.write(bufferedImage, "JPEG", file);
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/07/2011 08:21 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> Ok i actually register the handler now what i
>>>>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>> do
>>>>>>>>>>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>>>>>>>>>>> setup
>>>>>>>>>>>>>>>>>>>>>>>>>>> this
>>>>>>>>>>>>>>>>>>>>>>>>>>> handler or not?? and how can i do that, also it
>>>>>>>>>>>>>>>>>>>>>>>>>>> seem
>>>>>>>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>> bmp
>>>>>>>>>>>>>>>>>>>>>>>>>>> its
>>>>>>>>>>>>>>>>>>>>>>>>>>> not
>>>>>>>>>>>>>>>>>>>>>>>>>>> recognice also what can i do?? thanks for the
>>>>>>>>>>>>>>>>>>>>>>>>>>> help
>>>>>>>>>>>>>>>>>>>>>>>>>>> rob
>>>>>>>>>>>>>>>>>>>>>>>>>>> also i am trying to convert the images to see if
>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>>>>>>>> helps
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/06/2011 02:29 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Hi what can be the difference between execute
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> program
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> netbeans
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> (where
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it works and print the images and the jar in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> console)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> Different classes being loaded by Netbeans than
>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>> console
>>>>>>>>>>>>>>>>>>>>>>>>>>>> app.
>>>>>>>>>>>>>>>>>>>>>>>>>>>> Get
>>>>>>>>>>>>>>>>>>>>>>>>>>>> Netbeans to show you the full classpath it's
>>>>>>>>>>>>>>>>>>>>>>>>>>>> using
>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>> it's
>>>>>>>>>>>>>>>>>>>>>>>>>>>> "%classpath"
>>>>>>>>>>>>>>>>>>>>>>>>>>>> variable
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> also i tried the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> imageIO.getImageReadersBySuffix but i cant
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> interpretate
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> data
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> y.y,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> its
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> that or always its true in the boolean
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> variable,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> how
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> register
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> handler??
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> Talk to IIORegistry, some thing like
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>>>>>>>>>>>>>>>>> CLibJPEGImageReaderSpi());
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>>>>>>>>>>>>>>>>> CLibJPEGImageWriterSpi());
>>>>>>>>>>>>>>>>>>>>>>>>>>>> Note: those are not necessarily the services you
>>>>>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>> your
>>>>>>>>>>>>>>>>>>>>>>>>>>>> setup.
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Thanks
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> See the javadoc on IIORegistry. With ImageIO
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> may
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> register
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> your handler(s). What does
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ImageIO.getImageReadersBySuffix()
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> give
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> you.
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For certain jpegs we don't use ImageIO, rather
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> classes
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> com.sun.image.codec.jpeg:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                        try {
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                            FileOutputStream fos
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> =
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> new
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> FileOutputStream(file);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                            JPEGImageEncoder
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> encoder =
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> JPEGCodec.createJPEGEncoder(fos);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                            JPEGEncodeParam
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> param =
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> encoder.getDefaultJPEGEncodeParam(image.getRaster(),
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> JPEGDecodeParam.COLOR_ID_CMYK);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                            param.setQuality(1,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> false);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> encoder.encode(image.getRaster(),
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> param);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                            fos.close();
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                        } catch (Throwable t) {
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> logger.debug(t.getMessage());
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                        }
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> But generally we use ImageIO
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/06/2011 08:29 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Yeah i think i need your help again i tried
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> tu
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> run
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> .jar
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> file
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> console it work but without images this it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> what
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> appears
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> GRAVE: Error while processing image:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Cannot
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> load
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> image
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> (no
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> suitable loader/converter combination
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> available)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i tried  download the jai-imagio add to the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> class
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> path
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> but
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> dont
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> work
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Very odd.  I'm having no problems getting
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> images
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> into
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> pdfs
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> using
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-1.0.
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/03/2011 11:04 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> aaa hey thanks for the help the other day,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> resolve
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> problem
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> changing
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> version of FOP for the 0.95beta instead of
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> 1.0,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> works
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> now
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> prints
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the image and its good, thanks and we are
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> touch
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> if
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> anything
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> else
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fails
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> jejeje
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Nothing in the log from the transformer?
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/03/2011 09:47 AM, Oscar.Flores
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> hi there i have another problem i hope
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> help
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> me
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> create
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> with foe has no image, it dont show any
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> of
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> them,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> xsl
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> seems
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> be
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> rigth i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> tested with EditX and the pdf show me the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> image,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> what
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> be,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> xmlgraphics-commons-1.5svn, fop 1.0,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-pdf-images
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> 2.0.1
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Snapshot
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> render of the image but it don work
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> please
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> help!!!
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> :,(
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> :-):confused::confused::confused::confused:=)
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> http://old.nabble.com/file/p31822059/libraries.jpeg
>>>>>>>>>>>>>>>>>>> http://old.nabble.com/file/p31822059/libraries.bmp
>>>>>>>>>>>>>>>>>>> libraries.bmp
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>> ---------------------------------------------------------------------
>>>>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>> For additional commands, e-mail:
>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>> ---------------------------------------------------------------------
>>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>>>>
>>>>>>
>>>>>>
>>>> ---------------------------------------------------------------------
>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>>
>>>>
>>>>
>>

---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Problems with FOP and image

Posted by "Oscar.Flores" <fa...@hotmail.com>.
No i still can print the images in pdf in console what i do for now is call a
bat to make the transformation with fo until i figure out what the problem
is in log appear that can find a proper converter for the images

 
also another problem its that the table its to big it dont fit to the data
here its the pdf that result 
http://old.nabble.com/file/p31870136/Prueba3.pdf Prueba3.pdf 

 Warning(1979/26): fo:table, table-layout="auto" is currently not supported
> by FOP
> but in my xslt it ike this<fo:table table-layout="fixed" width="100%">

the version of fop i use its 1.0 
 
    

Rob Sargent-4 wrote:
> 
> I don't think you want to read and write to the same place. If the file 
> is where you want it to be and it's otherwise in perfect shape you 
> should be fine.  But if you do want to read it in and write it to some 
> deployed area the that's what you want to do. Almost:
>      ImageIO.write(*newImage*, "JPEG", jpegImageFile);
> 
> So without adding the ImageIO.write() call, are you getting the pdf you 
> want yet?
> If not, what actual errors are you seeing in the logs.
> 
> The warning about fo:table is not causing you any trouble.  What version 
> of fop are you running (sorry I've forgotten)
> 
> 
> 
> 
> 
> 
> On 06/15/2011 02:51 PM, Oscar.Flores wrote:
>> Hi thanks for the help yeah i haven see that its was .java and not
>> .class, ok
>> then if i follow correctly what you are saying then it has to be
>> something
>> like this
>>
>> BufferedImage newImage = new BufferedImage ("C:\Logo.jpg")
>> ImageIO.write(BufferedImage, "JPEG", jpegImageFile) jpegImageFile will be
>> the XML call rigth something like "C:\Logo.jpg")
>>
>> and another thing
>>
>>    Warning(1979/26): fo:table, table-layout="auto" is currently not
>> supported
>> by FOP
>> but in my xslt it ike this<fo:table table-layout="fixed" width="100%"> 
>> so
>> i dont now what its causing the ploblem
>>
>>
>>
>> Rob Sargent-4 wrote:
>>>
>>>
>>> On 06/14/2011 11:06 AM, Oscar.Flores wrote:
>>>> Yeah i do the class is in jai-imageio-1.1-sources.jar, the enviroment
>>>> is
>>>> just
>>> Having the file in the "...sources.jar" won't do the runtime world much
>>> good. You need the jar of .class files for jai-imageio, not .java files
>>>> windows xp, and the bufferedImage will be the path of the image??
>>> No, the bufferedImage is an in-memory instance of BufferedImage holding
>>> the bits of the image.  In the case that you have to read it from one
>>> place and write it to another.
>>>> Rob Sargent-4 wrote:
>>>>> Did you go through all your jars looking for 
>>>>> 'CLibJPEGImageReaderSpi'.
>>>>> My greatest suspicion is that you don't have all your jars lined up.
>>>>> Which jar(s) do you think supplies these?
>>>>>
>>>>> What is your environment: just windows or do you have any tools like
>>>>> cygwin?
>>>>>
>>>>> The "jpegImageFile" would be the filename in your xsl the
>>>>> external-resource.  If you're just using a file that is already in
>>>>> place
>>>>> you don't have to re-write it.
>>>>>
>>>>>
>>>>>
>>>>> On 06/14/2011 08:29 AM, Oscar.Flores wrote:
>>>>>> No i dont, and that weird jejeje netbeans seems to do that for me, so
>>>>>> the
>>>>>> calls like ImageIO.write(BufferedImage, "JPEG", jpegImageFile)? do i
>>>>>> have
>>>>>> to
>>>>>> do it in every image that i put in the pdf?? and the image is
>>>>>> gererate
>>>>>> directly in the pdf??how can i do it??
>>>>>>
>>>>>> Rob Sargent-4 wrote:
>>>>>>> Some jar to which netbeans has access has those classes.  Look in
>>>>>>> the
>>>>>>> output of jar tvf<each of your jars>    and see if any of those has
>>>>>>> the
>>>>>>> named classes.  If you find a jar with those classes make sure it's
>>>>>>> part
>>>>>>> of your classpath for you app.
>>>>>>>
>>>>>>> Are you making any calls like ImageIO.write(BufferedImage, "JPEG",
>>>>>>> jpegImageFile)?
>>>>>>>
>>>>>>> On 06/13/2011 05:31 PM, Oscar.Flores wrote:
>>>>>>>> ok i made a test and tell me that the class is missign but maybe
>>>>>>>> what
>>>>>>>> you
>>>>>>>> say
>>>>>>>> its rigth and it register the handler
>>>>>>>> so i gonna register the services so i do this
>>>>>>>>
>>>>>>>>      public static void main(String[] args) throws Exception {
>>>>>>>>              DOMConfigurator.configure("D:/Mis
>>>>>>>> documentos/NetBeansProjects/Factura/src/factura/log4j.xml");
>>>>>>>>              logger.info("Entering application.");
>>>>>>>>
>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>> CLibJPEGImageReaderSpi());
>>>>>>>>
>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>> CLibJPEGImageWriterSpi());
>>>>>>>>
>>>>>>>> also after register my services it telling me that the class
>>>>>>>> CLibJPEGImageReaderSpi() and CLibJPEGImageWriterSpi() is missing
>>>>>>>> but
>>>>>>>> only
>>>>>>>> in
>>>>>>>> command
>>>>>>>>
>>>>>>>> after register mi service, something more has to be done??
>>>>>>>>
>>>>>>>>
>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>> I'm not sure I'm following correctly: does removing the
>>>>>>>>> xmlgraphics
>>>>>>>>> jar
>>>>>>>>> cause netbeans to behave the same as the command-line run of you
>>>>>>>>> app?
>>>>>>>>> If
>>>>>>>>> so, I suspect netbeans is registering services for you.  Your own
>>>>>>>>> code
>>>>>>>>> will have to make a call to one of the
>>>>>>>>> IIORegistry.registerServiceProvider() methods.
>>>>>>>>>
>>>>>>>>> On 06/13/2011 05:02 PM, Oscar.Flores wrote:
>>>>>>>>>> Ok aaaa i get it, actually the ImageIO library i added because i
>>>>>>>>>> read
>>>>>>>>>> in
>>>>>>>>>> the
>>>>>>>>>> xmlgrapics that if something like the message
>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException: Cannot load
>>>>>>>>>> image
>>>>>>>>>> (no
>>>>>>>>>> suitable loader/converter combination available)appear i have to
>>>>>>>>>> add
>>>>>>>>>> the
>>>>>>>>>> jar
>>>>>>>>>> file to the classpath but that all it say no configuration or
>>>>>>>>>> anything,
>>>>>>>>>> then
>>>>>>>>>> i delete the imagenIO libs and still i have the same output in
>>>>>>>>>> netbeans
>>>>>>>>>> so
>>>>>>>>>> xmlgrapics seem to have the problem in the plugins or i have to
>>>>>>>>>> configure
>>>>>>>>>> something
>>>>>>>>>>
>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>> Then it seems to me netbeans (if it's producing good output ==
>>>>>>>>>>> assumptionA) is still using something that the command-line
>>>>>>>>>>> isn't.
>>>>>>>>>>>
>>>>>>>>>>> And given assumptionA, you're java code is correct in terms of
>>>>>>>>>>> FOP
>>>>>>>>>>> and
>>>>>>>>>>> your configuration isn't for ImageIO.  Show your ImageIO related
>>>>>>>>>>> code
>>>>>>>>>>> and are you sure it's in your app.  Use the logger to show a
>>>>>>>>>>> message
>>>>>>>>>>> when you add  your loader.  Or list all ImageIO services:
>>>>>>>>>>> IIORegistry.getServiceProviders()
>>>>>>>>>>>
>>>>>>>>>>> On 06/13/2011 03:01 PM, Oscar.Flores wrote:
>>>>>>>>>>>> ok well i put the xml in scr of my proyect i see that i still
>>>>>>>>>>>> have
>>>>>>>>>>>> the
>>>>>>>>>>>> same
>>>>>>>>>>>> issues of the image render of any image i dont now if the xml
>>>>>>>>>>>> its
>>>>>>>>>>>> in
>>>>>>>>>>>> place i
>>>>>>>>>>>> put the code down to see if something its missing
>>>>>>>>>>>>
>>>>>>>>>>>> 15:45:07,827 ERROR [render] Error while processing image:
>>>>>>>>>>>> c:\cfd\nombregp.bmp (i
>>>>>>>>>>>> mage/bmp)
>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException: Cannot load
>>>>>>>>>>>> image
>>>>>>>>>>>> (no
>>>>>>>>>>>> suitab
>>>>>>>>>>>> le loader/converter combination available) for
>>>>>>>>>>>> c:\cfd\nombregp.bmp
>>>>>>>>>>>> (image/bmp)
>>>>>>>>>>>>               at
>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageManager.getImage(ImageManage
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> import mx.bigdata.sat.cfd.schema.Comprobante;
>>>>>>>>>>>> import mx.bigdata.sat.cfd.CFDv2;
>>>>>>>>>>>> import mx.bigdata.sat.security.KeyLoader;
>>>>>>>>>>>> import org.jdom.*;
>>>>>>>>>>>> import org.jdom.input.SAXBuilder;
>>>>>>>>>>>> import org.jdom.output.XMLOutputter;
>>>>>>>>>>>> import org.jdom.output.Format;
>>>>>>>>>>>> import org.jdom.transform.JDOMSource;
>>>>>>>>>>>> //Java
>>>>>>>>>>>>        import java.io.File;
>>>>>>>>>>>>        import java.io.OutputStream;
>>>>>>>>>>>>
>>>>>>>>>>>>        //JAXP
>>>>>>>>>>>>        import javax.xml.transform.Transformer;
>>>>>>>>>>>>        import javax.xml.transform.TransformerFactory;
>>>>>>>>>>>>        import javax.xml.transform.Source;
>>>>>>>>>>>>        import javax.xml.transform.Result;
>>>>>>>>>>>>        import javax.xml.transform.stream.StreamSource;
>>>>>>>>>>>>        import javax.xml.transform.sax.SAXResult;
>>>>>>>>>>>>
>>>>>>>>>>>>        //FOP
>>>>>>>>>>>>        import org.apache.fop.apps.FOUserAgent;
>>>>>>>>>>>>        import org.apache.fop.apps.Fop;
>>>>>>>>>>>>        import org.apache.fop.apps.FopFactory;
>>>>>>>>>>>>        import org.apache.fop.apps.MimeConstants;
>>>>>>>>>>>>
>>>>>>>>>>>>        //log4j
>>>>>>>>>>>>        import org.apache.log4j.*;
>>>>>>>>>>>>        import org.apache.log4j.xml.DOMConfigurator;
>>>>>>>>>>>>
>>>>>>>>>>>> public final class Main {
>>>>>>>>>>>>           @SuppressWarnings("unchecked")
>>>>>>>>>>>>           static Logger logger = Logger.getLogger(Main.class);
>>>>>>>>>>>>
>>>>>>>>>>>>           public static void main(String[] args) throws
>>>>>>>>>>>> Exception
>>>>>>>>>>>> {
>>>>>>>>>>>>                DOMConfigurator.configure("D:/Mis
>>>>>>>>>>>> documentos/NetBeansProjects/Factura/src/factura/log4j.xml");
>>>>>>>>>>>>                logger.info("Entering application.");
>>>>>>>>>>>>                try {
>>>>>>>>>>>>                   File file = new File(args[0]);
>>>>>>>>>>>>                   Comprobante comp = CFDv2.newComprobante(new
>>>>>>>>>>>> FileInputStream(file));
>>>>>>>>>>>>                   CFDv2 cfd = new CFDv2(comp);
>>>>>>>>>>>>                   PrivateKey key =
>>>>>>>>>>>> KeyLoader.loadPKCS8PrivateKey(new
>>>>>>>>>>>> FileInputStream(args[1]),(args[2]));
>>>>>>>>>>>>                   X509Certificate cert =
>>>>>>>>>>>> KeyLoader.loadX509Certificate(new
>>>>>>>>>>>> FileInputStream(args[3]));
>>>>>>>>>>>>                   Comprobante sellado =
>>>>>>>>>>>> cfd.sellarComprobante(key,
>>>>>>>>>>>> cert);
>>>>>>>>>>>>                   String cadena = cfd.getCadenaOriginal();
>>>>>>>>>>>>                   String sello = sellado.getSello();
>>>>>>>>>>>>                   // Creamos el builder basado en SAX
>>>>>>>>>>>>                   SAXBuilder builder = new SAXBuilder();
>>>>>>>>>>>>                   // Construimos el arbol DOM a partir del
>>>>>>>>>>>> fichero
>>>>>>>>>>>> xml
>>>>>>>>>>>>                   Document documentJDOM = builder.build(new
>>>>>>>>>>>> FileInputStream(args[0]));
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>                   Element raiz =
>>>>>>>>>>>> documentJDOM.getRootElement();//toma
>>>>>>>>>>>> el
>>>>>>>>>>>> nodo
>>>>>>>>>>>> raiz
>>>>>>>>>>>> del documento.
>>>>>>>>>>>>                   raiz.setAttribute("sello", sello);
>>>>>>>>>>>>                   raiz.setAttribute("certificado",
>>>>>>>>>>>> sellado.getCertificado());
>>>>>>>>>>>>
>>>>>>>>>>>> //System.out.println(raiz.getAttributeValue("sello"));
>>>>>>>>>>>>
>>>>>>>>>>>> //System.out.println(raiz.getAttributeValue("certificado"));
>>>>>>>>>>>>                   // Recorremos los hijos de la etiqueta raíz
>>>>>>>>>>>>                   List<Element>       hijosRaiz =
>>>>>>>>>>>> raiz.getChildren();
>>>>>>>>>>>>                   boolean Bandera=false;
>>>>>>>>>>>>                   for(Element hijo: hijosRaiz)
>>>>>>>>>>>>                   {
>>>>>>>>>>>>                       // Obtenemos el nombre y su contenido de
>>>>>>>>>>>> tipo
>>>>>>>>>>>> texto
>>>>>>>>>>>>                       String nombre = hijo.getName();
>>>>>>>>>>>>
>>>>>>>>>>>>                       if (nombre.equals("Addenda"))
>>>>>>>>>>>>                       {   List<Element>       subHijo =
>>>>>>>>>>>> hijo.getChildren();
>>>>>>>>>>>>                           for(Element hij: subHijo)
>>>>>>>>>>>>                               {
>>>>>>>>>>>>                              
>>>>>>>>>>>> hij.setAttribute("CadenaOriginal",
>>>>>>>>>>>> cadena);
>>>>>>>>>>>>
>>>>>>>>>>>> //System.out.println("CadenaOriginal:
>>>>>>>>>>>> "+hij.getAttributeValue("CadenaOriginal"));
>>>>>>>>>>>>                               Bandera=true;
>>>>>>>>>>>>                               break;
>>>>>>>>>>>>                               }
>>>>>>>>>>>>                       }
>>>>>>>>>>>>                       if (Bandera)
>>>>>>>>>>>>                       {
>>>>>>>>>>>>                           XMLOutputter out = new
>>>>>>>>>>>> XMLOutputter(Format.getPrettyFormat());
>>>>>>>>>>>>                           File nuevoXML = new File(args[0]);
>>>>>>>>>>>>                           try{
>>>>>>>>>>>>                               FileOutputStream archivoXML= new
>>>>>>>>>>>> FileOutputStream
>>>>>>>>>>>> (nuevoXML);
>>>>>>>>>>>>                               out.output(documentJDOM,
>>>>>>>>>>>> archivoXML);
>>>>>>>>>>>>
>>>>>>>>>>>>                              }
>>>>>>>>>>>>                           catch (Exception
>>>>>>>>>>>> ex){System.out.println(ex.getMessage());}
>>>>>>>>>>>>                           // Para generar el pdf a partir de un
>>>>>>>>>>>> archivo.xsl
>>>>>>>>>>>> y
>>>>>>>>>>>> un
>>>>>>>>>>>>                           // archivo.xml
>>>>>>>>>>>>                       }
>>>>>>>>>>>>                     }
>>>>>>>>>>>>                 // configure fopFactory as desired
>>>>>>>>>>>>                 FopFactory fopFactory =
>>>>>>>>>>>> FopFactory.newInstance();
>>>>>>>>>>>>                 FOUserAgent foUserAgent =
>>>>>>>>>>>> fopFactory.newFOUserAgent();
>>>>>>>>>>>>
>>>>>>>>>>>>                 // configure foUserAgent as desired
>>>>>>>>>>>>                 // Setup output
>>>>>>>>>>>>                File pdffile = new File(args[5]);
>>>>>>>>>>>>
>>>>>>>>>>>>                OutputStream out = new
>>>>>>>>>>>> java.io.FileOutputStream(pdffile);
>>>>>>>>>>>>                out = new java.io.BufferedOutputStream(out);
>>>>>>>>>>>>                try {
>>>>>>>>>>>>                       // Construct fop with desired output
>>>>>>>>>>>> format
>>>>>>>>>>>>                        Fop fop =
>>>>>>>>>>>> fopFactory.newFop(MimeConstants.MIME_PDF,
>>>>>>>>>>>> foUserAgent, out);
>>>>>>>>>>>>                       // Setup XSLT
>>>>>>>>>>>>                       TransformerFactory factory =
>>>>>>>>>>>> TransformerFactory.newInstance();
>>>>>>>>>>>>                       Transformer transformer =
>>>>>>>>>>>> factory.newTransformer(new
>>>>>>>>>>>> StreamSource(args[4]));
>>>>>>>>>>>>                       // Set the value of a  in the stylesheet
>>>>>>>>>>>>                       transformer.setParameter("versionParam",
>>>>>>>>>>>> "2.0");
>>>>>>>>>>>>
>>>>>>>>>>>>                      // Setup input for XSLT transformation
>>>>>>>>>>>>                       Source src = new
>>>>>>>>>>>> JDOMSource(documentJDOM);
>>>>>>>>>>>>                        // Resulting SAX events (the generated
>>>>>>>>>>>> FO)
>>>>>>>>>>>> must
>>>>>>>>>>>> be
>>>>>>>>>>>> piped
>>>>>>>>>>>> through to FOP
>>>>>>>>>>>>                       Result res = new
>>>>>>>>>>>> SAXResult(fop.getDefaultHandler());
>>>>>>>>>>>>                        // Start XSLT transformation and FOP
>>>>>>>>>>>> processing
>>>>>>>>>>>>                      // System.setProperty("java.awt.headless",
>>>>>>>>>>>> "true");
>>>>>>>>>>>>                           transformer.transform(src, res);
>>>>>>>>>>>>                       } finally {
>>>>>>>>>>>>                        out.close();
>>>>>>>>>>>>                   }
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>                 System.out.println("Success!");
>>>>>>>>>>>>                } catch (Exception e) {
>>>>>>>>>>>>                 e.printStackTrace(System.err);
>>>>>>>>>>>>                 System.exit(-1);
>>>>>>>>>>>>              }
>>>>>>>>>>>>            logger.info("Exiting application.");
>>>>>>>>>>>>
>>>>>>>>>>>>         }
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>> Try this log4j.xml: Place it at the root of your jar file
>>>>>>>>>>>>>
>>>>>>>>>>>>> <?xml version="1.0" encoding="UTF-8"?>
>>>>>>>>>>>>> <!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">
>>>>>>>>>>>>>
>>>>>>>>>>>>> <log4j:configuration
>>>>>>>>>>>>> xmlns:log4j="http://jakarta.apache.org/log4j/"
>>>>>>>>>>>>> debug="false">
>>>>>>>>>>>>>
>>>>>>>>>>>>> <appender name="CONSOLE"
>>>>>>>>>>>>> class="org.apache.log4j.ConsoleAppender">
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> <layout class="org.apache.log4j.PatternLayout">
>>>>>>>>>>>>>
>>>>>>>>>>>>> </layout>
>>>>>>>>>>>>> </appender>
>>>>>>>>>>>>>
>>>>>>>>>>>>> <category name="org">
>>>>>>>>>>>>> <priority value="DEBUG"/>
>>>>>>>>>>>>> </category>
>>>>>>>>>>>>> <category name="org.apache">
>>>>>>>>>>>>> <priority value="WARN"/>
>>>>>>>>>>>>> </category>
>>>>>>>>>>>>> <category name="org.springframework">
>>>>>>>>>>>>> <priority value="WARN"/>
>>>>>>>>>>>>> </category>
>>>>>>>>>>>>> <category name="org.hibernate">
>>>>>>>>>>>>> <priority value="DEBUG"/>
>>>>>>>>>>>>> </category>
>>>>>>>>>>>>> <category name="net">
>>>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>>>> </category>
>>>>>>>>>>>>> <category name="javax">
>>>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>>>> </category>
>>>>>>>>>>>>> <category name="java">
>>>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>>>> </category>
>>>>>>>>>>>>> <category name="sun">
>>>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>>>> </category>
>>>>>>>>>>>>> <category name="org.jboss">
>>>>>>>>>>>>> <priority value="INFO"/>
>>>>>>>>>>>>> </category>
>>>>>>>>>>>>> <category name="org.jboss.seam">
>>>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>>>> </category>
>>>>>>>>>>>>> <root>
>>>>>>>>>>>>> <appender-ref ref="CONSOLE"/>
>>>>>>>>>>>>> </root>
>>>>>>>>>>>>>
>>>>>>>>>>>>> </log4j:configuration>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> On 06/13/2011 11:06 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>> ok i dont thik i have a configuracion file i find the code
>>>>>>>>>>>>>> that
>>>>>>>>>>>>>> i
>>>>>>>>>>>>>> put
>>>>>>>>>>>>>> in
>>>>>>>>>>>>>> the
>>>>>>>>>>>>>> other post i think its the basic
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>> Do you have a config file for log4j.  Usually it's in a
>>>>>>>>>>>>>>> resource
>>>>>>>>>>>>>>> tree.
>>>>>>>>>>>>>>> Are you copying that to your deployment? Is your ant script
>>>>>>>>>>>>>>> including
>>>>>>>>>>>>>>> the config file in the jar of your application?
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> On 06/13/2011 10:12 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>> Ok yeah the log4j its having isuees to find the
>>>>>>>>>>>>>>>> configuration
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> log4j:WARN No appenders could be found for logger
>>>>>>>>>>>>>>>> (org.apache.fop.util.ContentHandlerFactoryRegistry).
>>>>>>>>>>>>>>>> log4j:WARN Please initialize the log4j system properly.
>>>>>>>>>>>>>>>> log4j:WARN See
>>>>>>>>>>>>>>>> http://logging.apache.org/log4j/1.2/faq.html#noconfig
>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>> more info.
>>>>>>>>>>>>>>>> i go to the faq guide and it say try loading the class or
>>>>>>>>>>>>>>>> resource
>>>>>>>>>>>>>>>> yourself.
>>>>>>>>>>>>>>>> If you can't find it, neither will log4j.
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> aaa i dont know where to set this
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> also here its my xlst
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> http://old.nabble.com/file/p31835645/FacturasOMF.xsl
>>>>>>>>>>>>>>>> FacturasOMF.xsl
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> and the fo file that generate the editix
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> http://old.nabble.com/file/p31835645/Prueba.fo Prueba.fo
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>> The first thing is to really dig into what you did to
>>>>>>>>>>>>>>>>> netbeans
>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>> get
>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>> to work...
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> I've forgotten what your stylesheet looked like, so maybe
>>>>>>>>>>>>>>>>> if
>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>> show
>>>>>>>>>>>>>>>>> us
>>>>>>>>>>>>>>>>> again how you're referencing your images we might notice a
>>>>>>>>>>>>>>>>> problem.
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> It might also help to see the "fo" generated during your
>>>>>>>>>>>>>>>>> transformation.
>>>>>>>>>>>>>>>>> Can you grab that just after xslt and just before fop
>>>>>>>>>>>>>>>>> calls.
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> Are you sure there is no error being logged somewhere when
>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>> run
>>>>>>>>>>>>>>>>> from
>>>>>>>>>>>>>>>>> the command line? (Where is log4j writing and at what
>>>>>>>>>>>>>>>>> level?)
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>> You where absolutly rigth i miss a few libraries to add
>>>>>>>>>>>>>>>>>> into
>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>> jar
>>>>>>>>>>>>>>>>>> file, i
>>>>>>>>>>>>>>>>>> modified the build.xml to add the package and jar that i
>>>>>>>>>>>>>>>>>> need,
>>>>>>>>>>>>>>>>>> now
>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>> error
>>>>>>>>>>>>>>>>>> message is not there but still the images dont show in
>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>> remeber
>>>>>>>>>>>>>>>>>> that i do something in netbeans so they can add to the
>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>> but
>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>> cant
>>>>>>>>>>>>>>>>>> remeber i dont now if there is still a library that is
>>>>>>>>>>>>>>>>>> missing
>>>>>>>>>>>>>>>>>> or
>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>> am
>>>>>>>>>>>>>>>>>> adding more than it should be
>>>>>>>>>>>>>>>>>> This is what i use :
>>>>>>>>>>>>>>>>>> cfdi-base-0.1.6-SNAPSHOT.jar
>>>>>>>>>>>>>>>>>> guava-r09.jar
>>>>>>>>>>>>>>>>>> guava-r09-gwt.jar
>>>>>>>>>>>>>>>>>> jaxb-impl-2.1.10.jar
>>>>>>>>>>>>>>>>>> avalon-framework-api-4.3.jar
>>>>>>>>>>>>>>>>>> avalon-framework-cvs-20020806.jar
>>>>>>>>>>>>>>>>>> avalon-logkit-2.1.jar
>>>>>>>>>>>>>>>>>> not-yet-commons-ssl-0.3.11.jar
>>>>>>>>>>>>>>>>>> commons-codec-1.5.jar
>>>>>>>>>>>>>>>>>> commons-codec-1.5-sources.jar
>>>>>>>>>>>>>>>>>> log4j-1.2.16.jar
>>>>>>>>>>>>>>>>>> fop.jar
>>>>>>>>>>>>>>>>>> jdom.jar
>>>>>>>>>>>>>>>>>> xmlgraphics-commons-1.4.jar
>>>>>>>>>>>>>>>>>> commons-io-1.3.1.jar
>>>>>>>>>>>>>>>>>> fop-pdf-images-2.0.1.SNAPSHOT.jar
>>>>>>>>>>>>>>>>>> pdfbox-app-1.5.0.jar
>>>>>>>>>>>>>>>>>> fontbox-1.3.1.jar
>>>>>>>>>>>>>>>>>> jempbox-1.3.1.jar
>>>>>>>>>>>>>>>>>> xercesImpl-2.7.1.jar
>>>>>>>>>>>>>>>>>> batik-all-1.7.jar
>>>>>>>>>>>>>>>>>> xml-apis-1.3.04.jar
>>>>>>>>>>>>>>>>>> xml-apis-ext-1.3.04.jar
>>>>>>>>>>>>>>>>>>          avalon-framework-4.2.0.jar
>>>>>>>>>>>>>>>>>>          xalan-2.7.0.jar
>>>>>>>>>>>>>>>>>>          serializer-2.7.0.jar
>>>>>>>>>>>>>>>>>>          commons-logging-1.0.4.jar
>>>>>>>>>>>>>>>>>>          jai_codec.jar
>>>>>>>>>>>>>>>>>>          jai_core.jar
>>>>>>>>>>>>>>>>>>          batik-ext.jar
>>>>>>>>>>>>>>>>>>          jai_imageio-1.1-sources.jar
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> Thanks Rob for the help
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> I suspect running from your jar does not have/use the
>>>>>>>>>>>>>>>>>>> same
>>>>>>>>>>>>>>>>>>> classpath
>>>>>>>>>>>>>>>>>>> that is in effect while you're in the debugger.
>>>>>>>>>>>>>>>>>>> By what mechanism do you generate the jar?
>>>>>>>>>>>>>>>>>>> Is it an executable jar or are you running java
>>>>>>>>>>>>>>>>>>> -classpath
>>>>>>>>>>>>>>>>>>> <your-jar-here:other-jars>         Main?
>>>>>>>>>>>>>>>>>>> Make your IDE (netbeans) display the classpath  it uses
>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>> run
>>>>>>>>>>>>>>>>>>> your
>>>>>>>>>>>>>>>>>>> app
>>>>>>>>>>>>>>>>>>> and compare that with the above.
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> On 06/09/2011 07:21 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> aaa ok well my problem is that when i do the pdf in
>>>>>>>>>>>>>>>>>>>> netbean
>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>>>> fine
>>>>>>>>>>>>>>>>>>>> with images and evething but when i run the jar file in
>>>>>>>>>>>>>>>>>>>> command
>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>> give
>>>>>>>>>>>>>>>>>>>> me a
>>>>>>>>>>>>>>>>>>>> error
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> GRAVE: Error while processing image: I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException:
>>>>>>>>>>>>>>>>>>>> Cannot
>>>>>>>>>>>>>>>>>>>> load
>>>>>>>>>>>>>>>>>>>>           image (no suitable loader/converter
>>>>>>>>>>>>>>>>>>>> combination
>>>>>>>>>>>>>>>>>>>> available)
>>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>           (image/jpeg)
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> so i dont no what its not working and if i have to add
>>>>>>>>>>>>>>>>>>>> something
>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>> my
>>>>>>>>>>>>>>>>>>>> code
>>>>>>>>>>>>>>>>>>>> so the images can load i am soooo desperate what i am
>>>>>>>>>>>>>>>>>>>> doing
>>>>>>>>>>>>>>>>>>>> wrong??
>>>>>>>>>>>>>>>>>>>> i am sorry for the trouble and if a dont explain my
>>>>>>>>>>>>>>>>>>>> self
>>>>>>>>>>>>>>>>>>>> very
>>>>>>>>>>>>>>>>>>>> good
>>>>>>>>>>>>>>>>>>>> jejeje
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> Not at all sure what your problem is.  All I can do is
>>>>>>>>>>>>>>>>>>>>> show
>>>>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>>>>> what
>>>>>>>>>>>>>>>>>>>>> works for us.
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> Our source xml looks like this:
>>>>>>>>>>>>>>>>>>>>> <image image-id="381623861" reference-id="ref-220"
>>>>>>>>>>>>>>>>>>>>> width="750"
>>>>>>>>>>>>>>>>>>>>> height="750" image-space-id="space-1" position="5"
>>>>>>>>>>>>>>>>>>>>>                        image-pool-position="31"
>>>>>>>>>>>>>>>>>>>>> pos="4"
>>>>>>>>>>>>>>>>>>>>>                        file="ref_10_1002108221">
>>>>>>>>>>>>>>>>>>>>> <!--
>>>>>>>>>>>>>>>>>>>>> an
>>>>>>>>>>>>>>>>>>>>> actual
>>>>>>>>>>>>>>>>>>>>> file
>>>>>>>>>>>>>>>>>>>>> (.jpeg
>>>>>>>>>>>>>>>>>>>>> copied the working directory of the transformer -->
>>>>>>>>>>>>>>>>>>>>> <fields />
>>>>>>>>>>>>>>>>>>>>> <caption />
>>>>>>>>>>>>>>>>>>>>> <annotations>
>>>>>>>>>>>>>>>>>>>>> <arrow_positions origHeight="750" origWidth="750" />
>>>>>>>>>>>>>>>>>>>>> </annotations>
>>>>>>>>>>>>>>>>>>>>> </image>
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> Our xslt looks like this for each image needed.
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> <xsl:template name="image">
>>>>>>>>>>>>>>>>>>>>> <xsl:param name="img"/>          <!-- This is the xml
>>>>>>>>>>>>>>>>>>>>> node
>>>>>>>>>>>>>>>>>>>>> from
>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>> source
>>>>>>>>>>>>>>>>>>>>> xml
>>>>>>>>>>>>>>>>>>>>> above -->
>>>>>>>>>>>>>>>>>>>>> <xsl:param name="width"/>
>>>>>>>>>>>>>>>>>>>>> <xsl:param name="height" select="$width"/>
>>>>>>>>>>>>>>>>>>>>> <xsl:param name="ignoreHeight">false</xsl:param>
>>>>>>>>>>>>>>>>>>>>> <fo:block>
>>>>>>>>>>>>>>>>>>>>> <fo:external-graphic src="{$img/@file}"
>>>>>>>>>>>>>>>>>>>>> height="{$height}"
>>>>>>>>>>>>>>>>>>>>> width="{$width}" content-height="scale-to-fit"
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> content-width="scale-to-fit"
>>>>>>>>>>>>>>>>>>>>> border="0.5pt solid black" border-collapse="separate">
>>>>>>>>>>>>>>>>>>>>> <xsl:if test="$ignoreHeight != 'true'">
>>>>>>>>>>>>>>>>>>>>> <xsl:attribute name="height">
>>>>>>>>>>>>>>>>>>>>> <xsl:value-of select="$height"/>
>>>>>>>>>>>>>>>>>>>>> </xsl:attribute>
>>>>>>>>>>>>>>>>>>>>> </xsl:if>
>>>>>>>>>>>>>>>>>>>>> </fo:external-graphic>
>>>>>>>>>>>>>>>>>>>>> </fo:block>
>>>>>>>>>>>>>>>>>>>>> </xsl:template>
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> Our generated fo looks like this:
>>>>>>>>>>>>>>>>>>>>> <fo:table-cell>
>>>>>>>>>>>>>>>>>>>>> <fo:block>
>>>>>>>>>>>>>>>>>>>>> <fo:external-graphic border-collapse="separate"
>>>>>>>>>>>>>>>>>>>>> border="0.5pt
>>>>>>>>>>>>>>>>>>>>> solid
>>>>>>>>>>>>>>>>>>>>> black" content-width="scale-to-fit"
>>>>>>>>>>>>>>>>>>>>> content-height="scale-to-fit"
>>>>>>>>>>>>>>>>>>>>> width="2.5in" height="2.5in" src="ref_10_1002108221"
>>>>>>>>>>>>>>>>>>>>> />
>>>>>>>>>>>>>>>>>>>>> </fo:block>
>>>>>>>>>>>>>>>>>>>>> </fo:table-cell>
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> And the generated pdfs include the image and are
>>>>>>>>>>>>>>>>>>>>> shipped
>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>> printer.
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> How does this stack up with what you have?
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> On 06/09/2011 01:19 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> Hi there well i still got the problem but searching
>>>>>>>>>>>>>>>>>>>>>> IN
>>>>>>>>>>>>>>>>>>>>>> INTERNET
>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>> find
>>>>>>>>>>>>>>>>>>>>>> a
>>>>>>>>>>>>>>>>>>>>>> JPEG
>>>>>>>>>>>>>>>>>>>>>> renderer output for FOP its here
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> http://marc.info/?l=fop-user&m=125986752706366&w=2
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> the cuestion is can i render the image that i want to
>>>>>>>>>>>>>>>>>>>>>> put
>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>> pdf,
>>>>>>>>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>>>>>>>>> then add to the xsl the render jpeg it will work??
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> and here explaints how use the render when he say
>>>>>>>>>>>>>>>>>>>>>> uses
>>>>>>>>>>>>>>>>>>>>>> fop
>>>>>>>>>>>>>>>>>>>>>> as
>>>>>>>>>>>>>>>>>>>>>> normal
>>>>>>>>>>>>>>>>>>>>>> case
>>>>>>>>>>>>>>>>>>>>>> what does it mean
>>>>>>>>>>>>>>>>>>>>>> what else have to add to the code?? i hope you can
>>>>>>>>>>>>>>>>>>>>>> help
>>>>>>>>>>>>>>>>>>>>>> me
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> Thanks!!
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> // OutputStream out = what you want
>>>>>>>>>>>>>>>>>>>>>>                       FopFactory fopFactory =
>>>>>>>>>>>>>>>>>>>>>> FopFactory.newInstance();
>>>>>>>>>>>>>>>>>>>>>>                       RendererFactory rendererFactory
>>>>>>>>>>>>>>>>>>>>>> =
>>>>>>>>>>>>>>>>>>>>>> null;
>>>>>>>>>>>>>>>>>>>>>>                       FOUserAgent foUserAgent = null;
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>                       rendererFactory =
>>>>>>>>>>>>>>>>>>>>>> fopFactory.getRendererFactory();
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> rendererFactory.addRendererMaker(new
>>>>>>>>>>>>>>>>>>>>>> MultiRendererMaker("jpeg"));
>>>>>>>>>>>>>>>>>>>>>>                       foUserAgent =
>>>>>>>>>>>>>>>>>>>>>> fopFactory.newFOUserAgent();
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> rendererFactory.createRenderer(foUserAgent,
>>>>>>>>>>>>>>>>>>>>>> "image/jpeg");
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>                       Fop fop =
>>>>>>>>>>>>>>>>>>>>>> fopFactory.newFop("image/jpeg",
>>>>>>>>>>>>>>>>>>>>>> foUserAgent,
>>>>>>>>>>>>>>>>>>>>>> out);
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> //Use fop as normal case
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> Since you're now into xmlgraphics, I think you're
>>>>>>>>>>>>>>>>>>>>>>> best
>>>>>>>>>>>>>>>>>>>>>>> bet
>>>>>>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>>>>>>> here
>>>>>>>>>>>>>>>>>>>>>>> <http://xmlgraphics.apache.org/commons/image-loader.html>
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> On 06/07/2011 10:18 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> Hi ok this is for generate images that dont need to
>>>>>>>>>>>>>>>>>>>>>>>> be
>>>>>>>>>>>>>>>>>>>>>>>> decompress
>>>>>>>>>>>>>>>>>>>>>>>> later??
>>>>>>>>>>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>>>>>>>>>>> the result image i put in my xsl ?? then it should
>>>>>>>>>>>>>>>>>>>>>>>> work,
>>>>>>>>>>>>>>>>>>>>>>>> aaa
>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>> change
>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>> fop
>>>>>>>>>>>>>>>>>>>>>>>> 1.0 and xml communs 1.4 and its the same jejeje
>>>>>>>>>>>>>>>>>>>>>>>> dont
>>>>>>>>>>>>>>>>>>>>>>>> find
>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>> image
>>>>>>>>>>>>>>>>>>>>>>>> preload
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> org.apache.fop.fo.flow.ExternalGraphic bind
>>>>>>>>>>>>>>>>>>>>>>>> SEVERE: Image not available: The file format is not
>>>>>>>>>>>>>>>>>>>>>>>> supported.
>>>>>>>>>>>>>>>>>>>>>>>> No
>>>>>>>>>>>>>>>>>>>>>>>> ImagePreloader for *.jpg or *.bmp
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> ImageIO.write(bufferedImage, "JPEG", file);
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> On 06/07/2011 08:21 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> Ok i actually register the handler now what i
>>>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>> do
>>>>>>>>>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>>>>>>>>>> setup
>>>>>>>>>>>>>>>>>>>>>>>>>> this
>>>>>>>>>>>>>>>>>>>>>>>>>> handler or not?? and how can i do that, also it
>>>>>>>>>>>>>>>>>>>>>>>>>> seem
>>>>>>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>> bmp
>>>>>>>>>>>>>>>>>>>>>>>>>> its
>>>>>>>>>>>>>>>>>>>>>>>>>> not
>>>>>>>>>>>>>>>>>>>>>>>>>> recognice also what can i do?? thanks for the
>>>>>>>>>>>>>>>>>>>>>>>>>> help
>>>>>>>>>>>>>>>>>>>>>>>>>> rob
>>>>>>>>>>>>>>>>>>>>>>>>>> also i am trying to convert the images to see if
>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>>>>>>> helps
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/06/2011 02:29 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> Hi what can be the difference between execute
>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>> program
>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>> netbeans
>>>>>>>>>>>>>>>>>>>>>>>>>>>> (where
>>>>>>>>>>>>>>>>>>>>>>>>>>>> it works and print the images and the jar in
>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>> console)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> Different classes being loaded by Netbeans than
>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>> console
>>>>>>>>>>>>>>>>>>>>>>>>>>> app.
>>>>>>>>>>>>>>>>>>>>>>>>>>> Get
>>>>>>>>>>>>>>>>>>>>>>>>>>> Netbeans to show you the full classpath it's
>>>>>>>>>>>>>>>>>>>>>>>>>>> using
>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>> it's
>>>>>>>>>>>>>>>>>>>>>>>>>>> "%classpath"
>>>>>>>>>>>>>>>>>>>>>>>>>>> variable
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> also i tried the
>>>>>>>>>>>>>>>>>>>>>>>>>>>> imageIO.getImageReadersBySuffix but i cant
>>>>>>>>>>>>>>>>>>>>>>>>>>>> interpretate
>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>> data
>>>>>>>>>>>>>>>>>>>>>>>>>>>> y.y,
>>>>>>>>>>>>>>>>>>>>>>>>>>>> its
>>>>>>>>>>>>>>>>>>>>>>>>>>>> that or always its true in the boolean
>>>>>>>>>>>>>>>>>>>>>>>>>>>> variable,
>>>>>>>>>>>>>>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>>>>>>>>>>>>>>> how
>>>>>>>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>> register
>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>> handler??
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> Talk to IIORegistry, some thing like
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>>>>>>>>>>>>>>>> CLibJPEGImageReaderSpi());
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>>>>>>>>>>>>>>>> CLibJPEGImageWriterSpi());
>>>>>>>>>>>>>>>>>>>>>>>>>>> Note: those are not necessarily the services you
>>>>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>> your
>>>>>>>>>>>>>>>>>>>>>>>>>>> setup.
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> Thanks
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> See the javadoc on IIORegistry. With ImageIO
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> may
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> register
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> your handler(s). What does
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ImageIO.getImageReadersBySuffix()
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> give
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> you.
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For certain jpegs we don't use ImageIO, rather
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> classes
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> com.sun.image.codec.jpeg:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                       try {
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                           FileOutputStream fos
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> =
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> new
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> FileOutputStream(file);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                           JPEGImageEncoder
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> encoder =
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> JPEGCodec.createJPEGEncoder(fos);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                           JPEGEncodeParam
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> param =
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> encoder.getDefaultJPEGEncodeParam(image.getRaster(),
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> JPEGDecodeParam.COLOR_ID_CMYK);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                           param.setQuality(1,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> false);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> encoder.encode(image.getRaster(),
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> param);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                           fos.close();
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                       } catch (Throwable t) {
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> logger.debug(t.getMessage());
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>                       }
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> But generally we use ImageIO
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/06/2011 08:29 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Yeah i think i need your help again i tried
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> tu
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> run
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> .jar
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> file
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> console it work but without images this it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> what
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> appears
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> GRAVE: Error while processing image:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Cannot
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> load
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> image
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> (no
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> suitable loader/converter combination
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> available)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i tried  download the jai-imagio add to the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> class
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> path
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> but
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> dont
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> work
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Very odd.  I'm having no problems getting
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> images
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> into
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> pdfs
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> using
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-1.0.
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/03/2011 11:04 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> aaa hey thanks for the help the other day,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> resolve
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> problem
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> changing
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> version of FOP for the 0.95beta instead of
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> 1.0,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> works
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> now
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> prints
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the image and its good, thanks and we are
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> touch
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> if
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> anything
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> else
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fails
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> jejeje
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Nothing in the log from the transformer?
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/03/2011 09:47 AM, Oscar.Flores
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> hi there i have another problem i hope
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> help
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> me
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> create
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> with foe has no image, it dont show any
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> of
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> them,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> xsl
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> seems
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> be
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> rigth i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> tested with EditX and the pdf show me the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> image,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> what
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> be,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> xmlgraphics-commons-1.5svn, fop 1.0,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-pdf-images
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> 2.0.1
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Snapshot
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> render of the image but it don work
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> please
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> help!!!
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> :,(
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> :-):confused::confused::confused::confused:=)
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> http://old.nabble.com/file/p31822059/libraries.jpeg
>>>>>>>>>>>>>>>>>> http://old.nabble.com/file/p31822059/libraries.bmp
>>>>>>>>>>>>>>>>>> libraries.bmp
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>> For additional commands, e-mail:
>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>> ---------------------------------------------------------------------
>>>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>> For additional commands, e-mail:
>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>
>>>>>>>
>>>>>>>
>>>>> ---------------------------------------------------------------------
>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>>>
>>>>>
>>>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>
>>>
>>>
> 
> 

-- 
View this message in context: http://old.nabble.com/Problems-with-FOP-and-image-tp31766430p31870136.html
Sent from the FOP - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Problems with FOP and image

Posted by Rob Sargent <rs...@xmission.com>.
I don't think you want to read and write to the same place. If the file 
is where you want it to be and it's otherwise in perfect shape you 
should be fine.  But if you do want to read it in and write it to some 
deployed area the that's what you want to do. Almost:
     ImageIO.write(*newImage*, "JPEG", jpegImageFile);

So without adding the ImageIO.write() call, are you getting the pdf you 
want yet?
If not, what actual errors are you seeing in the logs.

The warning about fo:table is not causing you any trouble.  What version 
of fop are you running (sorry I've forgotten)






On 06/15/2011 02:51 PM, Oscar.Flores wrote:
> Hi thanks for the help yeah i haven see that its was .java and not .class, ok
> then if i follow correctly what you are saying then it has to be something
> like this
>
> BufferedImage newImage = new BufferedImage ("C:\Logo.jpg")
> ImageIO.write(BufferedImage, "JPEG", jpegImageFile) jpegImageFile will be
> the XML call rigth something like "C:\Logo.jpg")
>
> and another thing
>
>    Warning(1979/26): fo:table, table-layout="auto" is currently not supported
> by FOP
> but in my xslt it ike this<fo:table table-layout="fixed" width="100%">  so
> i dont now what its causing the ploblem
>
>
>
> Rob Sargent-4 wrote:
>>
>>
>> On 06/14/2011 11:06 AM, Oscar.Flores wrote:
>>> Yeah i do the class is in jai-imageio-1.1-sources.jar, the enviroment is
>>> just
>> Having the file in the "...sources.jar" won't do the runtime world much
>> good. You need the jar of .class files for jai-imageio, not .java files
>>> windows xp, and the bufferedImage will be the path of the image??
>> No, the bufferedImage is an in-memory instance of BufferedImage holding
>> the bits of the image.  In the case that you have to read it from one
>> place and write it to another.
>>> Rob Sargent-4 wrote:
>>>> Did you go through all your jars looking for  'CLibJPEGImageReaderSpi'.
>>>> My greatest suspicion is that you don't have all your jars lined up.
>>>> Which jar(s) do you think supplies these?
>>>>
>>>> What is your environment: just windows or do you have any tools like
>>>> cygwin?
>>>>
>>>> The "jpegImageFile" would be the filename in your xsl the
>>>> external-resource.  If you're just using a file that is already in place
>>>> you don't have to re-write it.
>>>>
>>>>
>>>>
>>>> On 06/14/2011 08:29 AM, Oscar.Flores wrote:
>>>>> No i dont, and that weird jejeje netbeans seems to do that for me, so
>>>>> the
>>>>> calls like ImageIO.write(BufferedImage, "JPEG", jpegImageFile)? do i
>>>>> have
>>>>> to
>>>>> do it in every image that i put in the pdf?? and the image is gererate
>>>>> directly in the pdf??how can i do it??
>>>>>
>>>>> Rob Sargent-4 wrote:
>>>>>> Some jar to which netbeans has access has those classes.  Look in the
>>>>>> output of jar tvf<each of your jars>    and see if any of those has the
>>>>>> named classes.  If you find a jar with those classes make sure it's
>>>>>> part
>>>>>> of your classpath for you app.
>>>>>>
>>>>>> Are you making any calls like ImageIO.write(BufferedImage, "JPEG",
>>>>>> jpegImageFile)?
>>>>>>
>>>>>> On 06/13/2011 05:31 PM, Oscar.Flores wrote:
>>>>>>> ok i made a test and tell me that the class is missign but maybe what
>>>>>>> you
>>>>>>> say
>>>>>>> its rigth and it register the handler
>>>>>>> so i gonna register the services so i do this
>>>>>>>
>>>>>>>      public static void main(String[] args) throws Exception {
>>>>>>>              DOMConfigurator.configure("D:/Mis
>>>>>>> documentos/NetBeansProjects/Factura/src/factura/log4j.xml");
>>>>>>>              logger.info("Entering application.");
>>>>>>>
>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>> CLibJPEGImageReaderSpi());
>>>>>>>
>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>> CLibJPEGImageWriterSpi());
>>>>>>>
>>>>>>> also after register my services it telling me that the class
>>>>>>> CLibJPEGImageReaderSpi() and CLibJPEGImageWriterSpi() is missing but
>>>>>>> only
>>>>>>> in
>>>>>>> command
>>>>>>>
>>>>>>> after register mi service, something more has to be done??
>>>>>>>
>>>>>>>
>>>>>>> Rob Sargent-4 wrote:
>>>>>>>> I'm not sure I'm following correctly: does removing the xmlgraphics
>>>>>>>> jar
>>>>>>>> cause netbeans to behave the same as the command-line run of you
>>>>>>>> app?
>>>>>>>> If
>>>>>>>> so, I suspect netbeans is registering services for you.  Your own
>>>>>>>> code
>>>>>>>> will have to make a call to one of the
>>>>>>>> IIORegistry.registerServiceProvider() methods.
>>>>>>>>
>>>>>>>> On 06/13/2011 05:02 PM, Oscar.Flores wrote:
>>>>>>>>> Ok aaaa i get it, actually the ImageIO library i added because i
>>>>>>>>> read
>>>>>>>>> in
>>>>>>>>> the
>>>>>>>>> xmlgrapics that if something like the message
>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException: Cannot load
>>>>>>>>> image
>>>>>>>>> (no
>>>>>>>>> suitable loader/converter combination available)appear i have to
>>>>>>>>> add
>>>>>>>>> the
>>>>>>>>> jar
>>>>>>>>> file to the classpath but that all it say no configuration or
>>>>>>>>> anything,
>>>>>>>>> then
>>>>>>>>> i delete the imagenIO libs and still i have the same output in
>>>>>>>>> netbeans
>>>>>>>>> so
>>>>>>>>> xmlgrapics seem to have the problem in the plugins or i have to
>>>>>>>>> configure
>>>>>>>>> something
>>>>>>>>>
>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>> Then it seems to me netbeans (if it's producing good output ==
>>>>>>>>>> assumptionA) is still using something that the command-line isn't.
>>>>>>>>>>
>>>>>>>>>> And given assumptionA, you're java code is correct in terms of FOP
>>>>>>>>>> and
>>>>>>>>>> your configuration isn't for ImageIO.  Show your ImageIO related
>>>>>>>>>> code
>>>>>>>>>> and are you sure it's in your app.  Use the logger to show a
>>>>>>>>>> message
>>>>>>>>>> when you add  your loader.  Or list all ImageIO services:
>>>>>>>>>> IIORegistry.getServiceProviders()
>>>>>>>>>>
>>>>>>>>>> On 06/13/2011 03:01 PM, Oscar.Flores wrote:
>>>>>>>>>>> ok well i put the xml in scr of my proyect i see that i still
>>>>>>>>>>> have
>>>>>>>>>>> the
>>>>>>>>>>> same
>>>>>>>>>>> issues of the image render of any image i dont now if the xml its
>>>>>>>>>>> in
>>>>>>>>>>> place i
>>>>>>>>>>> put the code down to see if something its missing
>>>>>>>>>>>
>>>>>>>>>>> 15:45:07,827 ERROR [render] Error while processing image:
>>>>>>>>>>> c:\cfd\nombregp.bmp (i
>>>>>>>>>>> mage/bmp)
>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException: Cannot load
>>>>>>>>>>> image
>>>>>>>>>>> (no
>>>>>>>>>>> suitab
>>>>>>>>>>> le loader/converter combination available) for
>>>>>>>>>>> c:\cfd\nombregp.bmp
>>>>>>>>>>> (image/bmp)
>>>>>>>>>>>               at
>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageManager.getImage(ImageManage
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> import mx.bigdata.sat.cfd.schema.Comprobante;
>>>>>>>>>>> import mx.bigdata.sat.cfd.CFDv2;
>>>>>>>>>>> import mx.bigdata.sat.security.KeyLoader;
>>>>>>>>>>> import org.jdom.*;
>>>>>>>>>>> import org.jdom.input.SAXBuilder;
>>>>>>>>>>> import org.jdom.output.XMLOutputter;
>>>>>>>>>>> import org.jdom.output.Format;
>>>>>>>>>>> import org.jdom.transform.JDOMSource;
>>>>>>>>>>> //Java
>>>>>>>>>>>        import java.io.File;
>>>>>>>>>>>        import java.io.OutputStream;
>>>>>>>>>>>
>>>>>>>>>>>        //JAXP
>>>>>>>>>>>        import javax.xml.transform.Transformer;
>>>>>>>>>>>        import javax.xml.transform.TransformerFactory;
>>>>>>>>>>>        import javax.xml.transform.Source;
>>>>>>>>>>>        import javax.xml.transform.Result;
>>>>>>>>>>>        import javax.xml.transform.stream.StreamSource;
>>>>>>>>>>>        import javax.xml.transform.sax.SAXResult;
>>>>>>>>>>>
>>>>>>>>>>>        //FOP
>>>>>>>>>>>        import org.apache.fop.apps.FOUserAgent;
>>>>>>>>>>>        import org.apache.fop.apps.Fop;
>>>>>>>>>>>        import org.apache.fop.apps.FopFactory;
>>>>>>>>>>>        import org.apache.fop.apps.MimeConstants;
>>>>>>>>>>>
>>>>>>>>>>>        //log4j
>>>>>>>>>>>        import org.apache.log4j.*;
>>>>>>>>>>>        import org.apache.log4j.xml.DOMConfigurator;
>>>>>>>>>>>
>>>>>>>>>>> public final class Main {
>>>>>>>>>>>           @SuppressWarnings("unchecked")
>>>>>>>>>>>           static Logger logger = Logger.getLogger(Main.class);
>>>>>>>>>>>
>>>>>>>>>>>           public static void main(String[] args) throws Exception
>>>>>>>>>>> {
>>>>>>>>>>>                DOMConfigurator.configure("D:/Mis
>>>>>>>>>>> documentos/NetBeansProjects/Factura/src/factura/log4j.xml");
>>>>>>>>>>>                logger.info("Entering application.");
>>>>>>>>>>>                try {
>>>>>>>>>>>                   File file = new File(args[0]);
>>>>>>>>>>>                   Comprobante comp = CFDv2.newComprobante(new
>>>>>>>>>>> FileInputStream(file));
>>>>>>>>>>>                   CFDv2 cfd = new CFDv2(comp);
>>>>>>>>>>>                   PrivateKey key =
>>>>>>>>>>> KeyLoader.loadPKCS8PrivateKey(new
>>>>>>>>>>> FileInputStream(args[1]),(args[2]));
>>>>>>>>>>>                   X509Certificate cert =
>>>>>>>>>>> KeyLoader.loadX509Certificate(new
>>>>>>>>>>> FileInputStream(args[3]));
>>>>>>>>>>>                   Comprobante sellado = cfd.sellarComprobante(key,
>>>>>>>>>>> cert);
>>>>>>>>>>>                   String cadena = cfd.getCadenaOriginal();
>>>>>>>>>>>                   String sello = sellado.getSello();
>>>>>>>>>>>                   // Creamos el builder basado en SAX
>>>>>>>>>>>                   SAXBuilder builder = new SAXBuilder();
>>>>>>>>>>>                   // Construimos el arbol DOM a partir del fichero
>>>>>>>>>>> xml
>>>>>>>>>>>                   Document documentJDOM = builder.build(new
>>>>>>>>>>> FileInputStream(args[0]));
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>                   Element raiz =
>>>>>>>>>>> documentJDOM.getRootElement();//toma
>>>>>>>>>>> el
>>>>>>>>>>> nodo
>>>>>>>>>>> raiz
>>>>>>>>>>> del documento.
>>>>>>>>>>>                   raiz.setAttribute("sello", sello);
>>>>>>>>>>>                   raiz.setAttribute("certificado",
>>>>>>>>>>> sellado.getCertificado());
>>>>>>>>>>>
>>>>>>>>>>> //System.out.println(raiz.getAttributeValue("sello"));
>>>>>>>>>>>
>>>>>>>>>>> //System.out.println(raiz.getAttributeValue("certificado"));
>>>>>>>>>>>                   // Recorremos los hijos de la etiqueta raíz
>>>>>>>>>>>                   List<Element>       hijosRaiz =
>>>>>>>>>>> raiz.getChildren();
>>>>>>>>>>>                   boolean Bandera=false;
>>>>>>>>>>>                   for(Element hijo: hijosRaiz)
>>>>>>>>>>>                   {
>>>>>>>>>>>                       // Obtenemos el nombre y su contenido de
>>>>>>>>>>> tipo
>>>>>>>>>>> texto
>>>>>>>>>>>                       String nombre = hijo.getName();
>>>>>>>>>>>
>>>>>>>>>>>                       if (nombre.equals("Addenda"))
>>>>>>>>>>>                       {   List<Element>       subHijo =
>>>>>>>>>>> hijo.getChildren();
>>>>>>>>>>>                           for(Element hij: subHijo)
>>>>>>>>>>>                               {
>>>>>>>>>>>                               hij.setAttribute("CadenaOriginal",
>>>>>>>>>>> cadena);
>>>>>>>>>>>
>>>>>>>>>>> //System.out.println("CadenaOriginal:
>>>>>>>>>>> "+hij.getAttributeValue("CadenaOriginal"));
>>>>>>>>>>>                               Bandera=true;
>>>>>>>>>>>                               break;
>>>>>>>>>>>                               }
>>>>>>>>>>>                       }
>>>>>>>>>>>                       if (Bandera)
>>>>>>>>>>>                       {
>>>>>>>>>>>                           XMLOutputter out = new
>>>>>>>>>>> XMLOutputter(Format.getPrettyFormat());
>>>>>>>>>>>                           File nuevoXML = new File(args[0]);
>>>>>>>>>>>                           try{
>>>>>>>>>>>                               FileOutputStream archivoXML= new
>>>>>>>>>>> FileOutputStream
>>>>>>>>>>> (nuevoXML);
>>>>>>>>>>>                               out.output(documentJDOM,
>>>>>>>>>>> archivoXML);
>>>>>>>>>>>
>>>>>>>>>>>                              }
>>>>>>>>>>>                           catch (Exception
>>>>>>>>>>> ex){System.out.println(ex.getMessage());}
>>>>>>>>>>>                           // Para generar el pdf a partir de un
>>>>>>>>>>> archivo.xsl
>>>>>>>>>>> y
>>>>>>>>>>> un
>>>>>>>>>>>                           // archivo.xml
>>>>>>>>>>>                       }
>>>>>>>>>>>                     }
>>>>>>>>>>>                 // configure fopFactory as desired
>>>>>>>>>>>                 FopFactory fopFactory = FopFactory.newInstance();
>>>>>>>>>>>                 FOUserAgent foUserAgent =
>>>>>>>>>>> fopFactory.newFOUserAgent();
>>>>>>>>>>>
>>>>>>>>>>>                 // configure foUserAgent as desired
>>>>>>>>>>>                 // Setup output
>>>>>>>>>>>                File pdffile = new File(args[5]);
>>>>>>>>>>>
>>>>>>>>>>>                OutputStream out = new
>>>>>>>>>>> java.io.FileOutputStream(pdffile);
>>>>>>>>>>>                out = new java.io.BufferedOutputStream(out);
>>>>>>>>>>>                try {
>>>>>>>>>>>                       // Construct fop with desired output format
>>>>>>>>>>>                        Fop fop =
>>>>>>>>>>> fopFactory.newFop(MimeConstants.MIME_PDF,
>>>>>>>>>>> foUserAgent, out);
>>>>>>>>>>>                       // Setup XSLT
>>>>>>>>>>>                       TransformerFactory factory =
>>>>>>>>>>> TransformerFactory.newInstance();
>>>>>>>>>>>                       Transformer transformer =
>>>>>>>>>>> factory.newTransformer(new
>>>>>>>>>>> StreamSource(args[4]));
>>>>>>>>>>>                       // Set the value of a  in the stylesheet
>>>>>>>>>>>                       transformer.setParameter("versionParam",
>>>>>>>>>>> "2.0");
>>>>>>>>>>>
>>>>>>>>>>>                      // Setup input for XSLT transformation
>>>>>>>>>>>                       Source src = new JDOMSource(documentJDOM);
>>>>>>>>>>>                        // Resulting SAX events (the generated FO)
>>>>>>>>>>> must
>>>>>>>>>>> be
>>>>>>>>>>> piped
>>>>>>>>>>> through to FOP
>>>>>>>>>>>                       Result res = new
>>>>>>>>>>> SAXResult(fop.getDefaultHandler());
>>>>>>>>>>>                        // Start XSLT transformation and FOP
>>>>>>>>>>> processing
>>>>>>>>>>>                      // System.setProperty("java.awt.headless",
>>>>>>>>>>> "true");
>>>>>>>>>>>                           transformer.transform(src, res);
>>>>>>>>>>>                       } finally {
>>>>>>>>>>>                        out.close();
>>>>>>>>>>>                   }
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>                 System.out.println("Success!");
>>>>>>>>>>>                } catch (Exception e) {
>>>>>>>>>>>                 e.printStackTrace(System.err);
>>>>>>>>>>>                 System.exit(-1);
>>>>>>>>>>>              }
>>>>>>>>>>>            logger.info("Exiting application.");
>>>>>>>>>>>
>>>>>>>>>>>         }
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>> Try this log4j.xml: Place it at the root of your jar file
>>>>>>>>>>>>
>>>>>>>>>>>> <?xml version="1.0" encoding="UTF-8"?>
>>>>>>>>>>>> <!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">
>>>>>>>>>>>>
>>>>>>>>>>>> <log4j:configuration
>>>>>>>>>>>> xmlns:log4j="http://jakarta.apache.org/log4j/"
>>>>>>>>>>>> debug="false">
>>>>>>>>>>>>
>>>>>>>>>>>> <appender name="CONSOLE"
>>>>>>>>>>>> class="org.apache.log4j.ConsoleAppender">
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> <layout class="org.apache.log4j.PatternLayout">
>>>>>>>>>>>>
>>>>>>>>>>>> </layout>
>>>>>>>>>>>> </appender>
>>>>>>>>>>>>
>>>>>>>>>>>> <category name="org">
>>>>>>>>>>>> <priority value="DEBUG"/>
>>>>>>>>>>>> </category>
>>>>>>>>>>>> <category name="org.apache">
>>>>>>>>>>>> <priority value="WARN"/>
>>>>>>>>>>>> </category>
>>>>>>>>>>>> <category name="org.springframework">
>>>>>>>>>>>> <priority value="WARN"/>
>>>>>>>>>>>> </category>
>>>>>>>>>>>> <category name="org.hibernate">
>>>>>>>>>>>> <priority value="DEBUG"/>
>>>>>>>>>>>> </category>
>>>>>>>>>>>> <category name="net">
>>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>>> </category>
>>>>>>>>>>>> <category name="javax">
>>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>>> </category>
>>>>>>>>>>>> <category name="java">
>>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>>> </category>
>>>>>>>>>>>> <category name="sun">
>>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>>> </category>
>>>>>>>>>>>> <category name="org.jboss">
>>>>>>>>>>>> <priority value="INFO"/>
>>>>>>>>>>>> </category>
>>>>>>>>>>>> <category name="org.jboss.seam">
>>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>>> </category>
>>>>>>>>>>>> <root>
>>>>>>>>>>>> <appender-ref ref="CONSOLE"/>
>>>>>>>>>>>> </root>
>>>>>>>>>>>>
>>>>>>>>>>>> </log4j:configuration>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> On 06/13/2011 11:06 AM, Oscar.Flores wrote:
>>>>>>>>>>>>> ok i dont thik i have a configuracion file i find the code that
>>>>>>>>>>>>> i
>>>>>>>>>>>>> put
>>>>>>>>>>>>> in
>>>>>>>>>>>>> the
>>>>>>>>>>>>> other post i think its the basic
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>> Do you have a config file for log4j.  Usually it's in a
>>>>>>>>>>>>>> resource
>>>>>>>>>>>>>> tree.
>>>>>>>>>>>>>> Are you copying that to your deployment? Is your ant script
>>>>>>>>>>>>>> including
>>>>>>>>>>>>>> the config file in the jar of your application?
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> On 06/13/2011 10:12 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>> Ok yeah the log4j its having isuees to find the configuration
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> log4j:WARN No appenders could be found for logger
>>>>>>>>>>>>>>> (org.apache.fop.util.ContentHandlerFactoryRegistry).
>>>>>>>>>>>>>>> log4j:WARN Please initialize the log4j system properly.
>>>>>>>>>>>>>>> log4j:WARN See
>>>>>>>>>>>>>>> http://logging.apache.org/log4j/1.2/faq.html#noconfig
>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>> more info.
>>>>>>>>>>>>>>> i go to the faq guide and it say try loading the class or
>>>>>>>>>>>>>>> resource
>>>>>>>>>>>>>>> yourself.
>>>>>>>>>>>>>>> If you can't find it, neither will log4j.
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> aaa i dont know where to set this
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> also here its my xlst
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> http://old.nabble.com/file/p31835645/FacturasOMF.xsl
>>>>>>>>>>>>>>> FacturasOMF.xsl
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> and the fo file that generate the editix
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> http://old.nabble.com/file/p31835645/Prueba.fo Prueba.fo
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>> The first thing is to really dig into what you did to
>>>>>>>>>>>>>>>> netbeans
>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>> get
>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>> to work...
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> I've forgotten what your stylesheet looked like, so maybe if
>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>> show
>>>>>>>>>>>>>>>> us
>>>>>>>>>>>>>>>> again how you're referencing your images we might notice a
>>>>>>>>>>>>>>>> problem.
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> It might also help to see the "fo" generated during your
>>>>>>>>>>>>>>>> transformation.
>>>>>>>>>>>>>>>> Can you grab that just after xslt and just before fop calls.
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> Are you sure there is no error being logged somewhere when
>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>> run
>>>>>>>>>>>>>>>> from
>>>>>>>>>>>>>>>> the command line? (Where is log4j writing and at what
>>>>>>>>>>>>>>>> level?)
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> Oscar.Flores wrote:
>>>>>>>>>>>>>>>>> You where absolutly rigth i miss a few libraries to add
>>>>>>>>>>>>>>>>> into
>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>> jar
>>>>>>>>>>>>>>>>> file, i
>>>>>>>>>>>>>>>>> modified the build.xml to add the package and jar that i
>>>>>>>>>>>>>>>>> need,
>>>>>>>>>>>>>>>>> now
>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>> error
>>>>>>>>>>>>>>>>> message is not there but still the images dont show in the
>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>> remeber
>>>>>>>>>>>>>>>>> that i do something in netbeans so they can add to the pdf
>>>>>>>>>>>>>>>>> but
>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>> cant
>>>>>>>>>>>>>>>>> remeber i dont now if there is still a library that is
>>>>>>>>>>>>>>>>> missing
>>>>>>>>>>>>>>>>> or
>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>> am
>>>>>>>>>>>>>>>>> adding more than it should be
>>>>>>>>>>>>>>>>> This is what i use :
>>>>>>>>>>>>>>>>> cfdi-base-0.1.6-SNAPSHOT.jar
>>>>>>>>>>>>>>>>> guava-r09.jar
>>>>>>>>>>>>>>>>> guava-r09-gwt.jar
>>>>>>>>>>>>>>>>> jaxb-impl-2.1.10.jar
>>>>>>>>>>>>>>>>> avalon-framework-api-4.3.jar
>>>>>>>>>>>>>>>>> avalon-framework-cvs-20020806.jar
>>>>>>>>>>>>>>>>> avalon-logkit-2.1.jar
>>>>>>>>>>>>>>>>> not-yet-commons-ssl-0.3.11.jar
>>>>>>>>>>>>>>>>> commons-codec-1.5.jar
>>>>>>>>>>>>>>>>> commons-codec-1.5-sources.jar
>>>>>>>>>>>>>>>>> log4j-1.2.16.jar
>>>>>>>>>>>>>>>>> fop.jar
>>>>>>>>>>>>>>>>> jdom.jar
>>>>>>>>>>>>>>>>> xmlgraphics-commons-1.4.jar
>>>>>>>>>>>>>>>>> commons-io-1.3.1.jar
>>>>>>>>>>>>>>>>> fop-pdf-images-2.0.1.SNAPSHOT.jar
>>>>>>>>>>>>>>>>> pdfbox-app-1.5.0.jar
>>>>>>>>>>>>>>>>> fontbox-1.3.1.jar
>>>>>>>>>>>>>>>>> jempbox-1.3.1.jar
>>>>>>>>>>>>>>>>> xercesImpl-2.7.1.jar
>>>>>>>>>>>>>>>>> batik-all-1.7.jar
>>>>>>>>>>>>>>>>> xml-apis-1.3.04.jar
>>>>>>>>>>>>>>>>> xml-apis-ext-1.3.04.jar
>>>>>>>>>>>>>>>>>          avalon-framework-4.2.0.jar
>>>>>>>>>>>>>>>>>          xalan-2.7.0.jar
>>>>>>>>>>>>>>>>>          serializer-2.7.0.jar
>>>>>>>>>>>>>>>>>          commons-logging-1.0.4.jar
>>>>>>>>>>>>>>>>>          jai_codec.jar
>>>>>>>>>>>>>>>>>          jai_core.jar
>>>>>>>>>>>>>>>>>          batik-ext.jar
>>>>>>>>>>>>>>>>>          jai_imageio-1.1-sources.jar
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> Thanks Rob for the help
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> I suspect running from your jar does not have/use the same
>>>>>>>>>>>>>>>>>> classpath
>>>>>>>>>>>>>>>>>> that is in effect while you're in the debugger.
>>>>>>>>>>>>>>>>>> By what mechanism do you generate the jar?
>>>>>>>>>>>>>>>>>> Is it an executable jar or are you running java -classpath
>>>>>>>>>>>>>>>>>> <your-jar-here:other-jars>         Main?
>>>>>>>>>>>>>>>>>> Make your IDE (netbeans) display the classpath  it uses to
>>>>>>>>>>>>>>>>>> run
>>>>>>>>>>>>>>>>>> your
>>>>>>>>>>>>>>>>>> app
>>>>>>>>>>>>>>>>>> and compare that with the above.
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> On 06/09/2011 07:21 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> aaa ok well my problem is that when i do the pdf in
>>>>>>>>>>>>>>>>>>> netbean
>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>>> fine
>>>>>>>>>>>>>>>>>>> with images and evething but when i run the jar file in
>>>>>>>>>>>>>>>>>>> command
>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>> give
>>>>>>>>>>>>>>>>>>> me a
>>>>>>>>>>>>>>>>>>> error
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> GRAVE: Error while processing image: I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException:
>>>>>>>>>>>>>>>>>>> Cannot
>>>>>>>>>>>>>>>>>>> load
>>>>>>>>>>>>>>>>>>>           image (no suitable loader/converter combination
>>>>>>>>>>>>>>>>>>> available)
>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>           (image/jpeg)
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> so i dont no what its not working and if i have to add
>>>>>>>>>>>>>>>>>>> something
>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>> my
>>>>>>>>>>>>>>>>>>> code
>>>>>>>>>>>>>>>>>>> so the images can load i am soooo desperate what i am
>>>>>>>>>>>>>>>>>>> doing
>>>>>>>>>>>>>>>>>>> wrong??
>>>>>>>>>>>>>>>>>>> i am sorry for the trouble and if a dont explain my self
>>>>>>>>>>>>>>>>>>> very
>>>>>>>>>>>>>>>>>>> good
>>>>>>>>>>>>>>>>>>> jejeje
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> Not at all sure what your problem is.  All I can do is
>>>>>>>>>>>>>>>>>>>> show
>>>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>>>> what
>>>>>>>>>>>>>>>>>>>> works for us.
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> Our source xml looks like this:
>>>>>>>>>>>>>>>>>>>> <image image-id="381623861" reference-id="ref-220"
>>>>>>>>>>>>>>>>>>>> width="750"
>>>>>>>>>>>>>>>>>>>> height="750" image-space-id="space-1" position="5"
>>>>>>>>>>>>>>>>>>>>                        image-pool-position="31" pos="4"
>>>>>>>>>>>>>>>>>>>>                        file="ref_10_1002108221">
>>>>>>>>>>>>>>>>>>>> <!--
>>>>>>>>>>>>>>>>>>>> an
>>>>>>>>>>>>>>>>>>>> actual
>>>>>>>>>>>>>>>>>>>> file
>>>>>>>>>>>>>>>>>>>> (.jpeg
>>>>>>>>>>>>>>>>>>>> copied the working directory of the transformer -->
>>>>>>>>>>>>>>>>>>>> <fields />
>>>>>>>>>>>>>>>>>>>> <caption />
>>>>>>>>>>>>>>>>>>>> <annotations>
>>>>>>>>>>>>>>>>>>>> <arrow_positions origHeight="750" origWidth="750" />
>>>>>>>>>>>>>>>>>>>> </annotations>
>>>>>>>>>>>>>>>>>>>> </image>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> Our xslt looks like this for each image needed.
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> <xsl:template name="image">
>>>>>>>>>>>>>>>>>>>> <xsl:param name="img"/>          <!-- This is the xml
>>>>>>>>>>>>>>>>>>>> node
>>>>>>>>>>>>>>>>>>>> from
>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>> source
>>>>>>>>>>>>>>>>>>>> xml
>>>>>>>>>>>>>>>>>>>> above -->
>>>>>>>>>>>>>>>>>>>> <xsl:param name="width"/>
>>>>>>>>>>>>>>>>>>>> <xsl:param name="height" select="$width"/>
>>>>>>>>>>>>>>>>>>>> <xsl:param name="ignoreHeight">false</xsl:param>
>>>>>>>>>>>>>>>>>>>> <fo:block>
>>>>>>>>>>>>>>>>>>>> <fo:external-graphic src="{$img/@file}"
>>>>>>>>>>>>>>>>>>>> height="{$height}"
>>>>>>>>>>>>>>>>>>>> width="{$width}" content-height="scale-to-fit"
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> content-width="scale-to-fit"
>>>>>>>>>>>>>>>>>>>> border="0.5pt solid black" border-collapse="separate">
>>>>>>>>>>>>>>>>>>>> <xsl:if test="$ignoreHeight != 'true'">
>>>>>>>>>>>>>>>>>>>> <xsl:attribute name="height">
>>>>>>>>>>>>>>>>>>>> <xsl:value-of select="$height"/>
>>>>>>>>>>>>>>>>>>>> </xsl:attribute>
>>>>>>>>>>>>>>>>>>>> </xsl:if>
>>>>>>>>>>>>>>>>>>>> </fo:external-graphic>
>>>>>>>>>>>>>>>>>>>> </fo:block>
>>>>>>>>>>>>>>>>>>>> </xsl:template>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> Our generated fo looks like this:
>>>>>>>>>>>>>>>>>>>> <fo:table-cell>
>>>>>>>>>>>>>>>>>>>> <fo:block>
>>>>>>>>>>>>>>>>>>>> <fo:external-graphic border-collapse="separate"
>>>>>>>>>>>>>>>>>>>> border="0.5pt
>>>>>>>>>>>>>>>>>>>> solid
>>>>>>>>>>>>>>>>>>>> black" content-width="scale-to-fit"
>>>>>>>>>>>>>>>>>>>> content-height="scale-to-fit"
>>>>>>>>>>>>>>>>>>>> width="2.5in" height="2.5in" src="ref_10_1002108221" />
>>>>>>>>>>>>>>>>>>>> </fo:block>
>>>>>>>>>>>>>>>>>>>> </fo:table-cell>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> And the generated pdfs include the image and are shipped
>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>> printer.
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> How does this stack up with what you have?
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> On 06/09/2011 01:19 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> Hi there well i still got the problem but searching IN
>>>>>>>>>>>>>>>>>>>>> INTERNET
>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>> find
>>>>>>>>>>>>>>>>>>>>> a
>>>>>>>>>>>>>>>>>>>>> JPEG
>>>>>>>>>>>>>>>>>>>>> renderer output for FOP its here
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> http://marc.info/?l=fop-user&m=125986752706366&w=2
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> the cuestion is can i render the image that i want to
>>>>>>>>>>>>>>>>>>>>> put
>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>> pdf,
>>>>>>>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>>>>>>>> then add to the xsl the render jpeg it will work??
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> and here explaints how use the render when he say uses
>>>>>>>>>>>>>>>>>>>>> fop
>>>>>>>>>>>>>>>>>>>>> as
>>>>>>>>>>>>>>>>>>>>> normal
>>>>>>>>>>>>>>>>>>>>> case
>>>>>>>>>>>>>>>>>>>>> what does it mean
>>>>>>>>>>>>>>>>>>>>> what else have to add to the code?? i hope you can help
>>>>>>>>>>>>>>>>>>>>> me
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> Thanks!!
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> // OutputStream out = what you want
>>>>>>>>>>>>>>>>>>>>>                       FopFactory fopFactory =
>>>>>>>>>>>>>>>>>>>>> FopFactory.newInstance();
>>>>>>>>>>>>>>>>>>>>>                       RendererFactory rendererFactory =
>>>>>>>>>>>>>>>>>>>>> null;
>>>>>>>>>>>>>>>>>>>>>                       FOUserAgent foUserAgent = null;
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>                       rendererFactory =
>>>>>>>>>>>>>>>>>>>>> fopFactory.getRendererFactory();
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> rendererFactory.addRendererMaker(new
>>>>>>>>>>>>>>>>>>>>> MultiRendererMaker("jpeg"));
>>>>>>>>>>>>>>>>>>>>>                       foUserAgent =
>>>>>>>>>>>>>>>>>>>>> fopFactory.newFOUserAgent();
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> rendererFactory.createRenderer(foUserAgent,
>>>>>>>>>>>>>>>>>>>>> "image/jpeg");
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>                       Fop fop =
>>>>>>>>>>>>>>>>>>>>> fopFactory.newFop("image/jpeg",
>>>>>>>>>>>>>>>>>>>>> foUserAgent,
>>>>>>>>>>>>>>>>>>>>> out);
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> //Use fop as normal case
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> Since you're now into xmlgraphics, I think you're best
>>>>>>>>>>>>>>>>>>>>>> bet
>>>>>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>>>>>> here
>>>>>>>>>>>>>>>>>>>>>> <http://xmlgraphics.apache.org/commons/image-loader.html>
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> On 06/07/2011 10:18 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> Hi ok this is for generate images that dont need to
>>>>>>>>>>>>>>>>>>>>>>> be
>>>>>>>>>>>>>>>>>>>>>>> decompress
>>>>>>>>>>>>>>>>>>>>>>> later??
>>>>>>>>>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>>>>>>>>>> the result image i put in my xsl ?? then it should
>>>>>>>>>>>>>>>>>>>>>>> work,
>>>>>>>>>>>>>>>>>>>>>>> aaa
>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>> change
>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>> fop
>>>>>>>>>>>>>>>>>>>>>>> 1.0 and xml communs 1.4 and its the same jejeje
>>>>>>>>>>>>>>>>>>>>>>> dont
>>>>>>>>>>>>>>>>>>>>>>> find
>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>> image
>>>>>>>>>>>>>>>>>>>>>>> preload
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> org.apache.fop.fo.flow.ExternalGraphic bind
>>>>>>>>>>>>>>>>>>>>>>> SEVERE: Image not available: The file format is not
>>>>>>>>>>>>>>>>>>>>>>> supported.
>>>>>>>>>>>>>>>>>>>>>>> No
>>>>>>>>>>>>>>>>>>>>>>> ImagePreloader for *.jpg or *.bmp
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> ImageIO.write(bufferedImage, "JPEG", file);
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> On 06/07/2011 08:21 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> Ok i actually register the handler now what i have
>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>> do
>>>>>>>>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>>>>>>>>> setup
>>>>>>>>>>>>>>>>>>>>>>>>> this
>>>>>>>>>>>>>>>>>>>>>>>>> handler or not?? and how can i do that, also it
>>>>>>>>>>>>>>>>>>>>>>>>> seem
>>>>>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>> bmp
>>>>>>>>>>>>>>>>>>>>>>>>> its
>>>>>>>>>>>>>>>>>>>>>>>>> not
>>>>>>>>>>>>>>>>>>>>>>>>> recognice also what can i do?? thanks for the help
>>>>>>>>>>>>>>>>>>>>>>>>> rob
>>>>>>>>>>>>>>>>>>>>>>>>> also i am trying to convert the images to see if it
>>>>>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>>>>>> helps
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/06/2011 02:29 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> Hi what can be the difference between execute the
>>>>>>>>>>>>>>>>>>>>>>>>>>> program
>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>> netbeans
>>>>>>>>>>>>>>>>>>>>>>>>>>> (where
>>>>>>>>>>>>>>>>>>>>>>>>>>> it works and print the images and the jar in the
>>>>>>>>>>>>>>>>>>>>>>>>>>> console)
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> Different classes being loaded by Netbeans than
>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>> console
>>>>>>>>>>>>>>>>>>>>>>>>>> app.
>>>>>>>>>>>>>>>>>>>>>>>>>> Get
>>>>>>>>>>>>>>>>>>>>>>>>>> Netbeans to show you the full classpath it's using
>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>> it's
>>>>>>>>>>>>>>>>>>>>>>>>>> "%classpath"
>>>>>>>>>>>>>>>>>>>>>>>>>> variable
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> also i tried the
>>>>>>>>>>>>>>>>>>>>>>>>>>> imageIO.getImageReadersBySuffix but i cant
>>>>>>>>>>>>>>>>>>>>>>>>>>> interpretate
>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>> data
>>>>>>>>>>>>>>>>>>>>>>>>>>> y.y,
>>>>>>>>>>>>>>>>>>>>>>>>>>> its
>>>>>>>>>>>>>>>>>>>>>>>>>>> that or always its true in the boolean variable,
>>>>>>>>>>>>>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>>>>>>>>>>>>>> how
>>>>>>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>> register
>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>> handler??
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> Talk to IIORegistry, some thing like
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>>>>>>>>>>>>>>> CLibJPEGImageReaderSpi());
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>>>>>>>>>>>>>>> CLibJPEGImageWriterSpi());
>>>>>>>>>>>>>>>>>>>>>>>>>> Note: those are not necessarily the services you
>>>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>> your
>>>>>>>>>>>>>>>>>>>>>>>>>> setup.
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> Thanks
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> See the javadoc on IIORegistry. With ImageIO you
>>>>>>>>>>>>>>>>>>>>>>>>>>>> may
>>>>>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>>> register
>>>>>>>>>>>>>>>>>>>>>>>>>>>> your handler(s). What does
>>>>>>>>>>>>>>>>>>>>>>>>>>>> ImageIO.getImageReadersBySuffix()
>>>>>>>>>>>>>>>>>>>>>>>>>>>> give
>>>>>>>>>>>>>>>>>>>>>>>>>>>> you.
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> For certain jpegs we don't use ImageIO, rather
>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>> classes
>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>> com.sun.image.codec.jpeg:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>                       try {
>>>>>>>>>>>>>>>>>>>>>>>>>>>>                           FileOutputStream fos =
>>>>>>>>>>>>>>>>>>>>>>>>>>>> new
>>>>>>>>>>>>>>>>>>>>>>>>>>>> FileOutputStream(file);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>                           JPEGImageEncoder
>>>>>>>>>>>>>>>>>>>>>>>>>>>> encoder =
>>>>>>>>>>>>>>>>>>>>>>>>>>>> JPEGCodec.createJPEGEncoder(fos);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>                           JPEGEncodeParam param =
>>>>>>>>>>>>>>>>>>>>>>>>>>>> encoder.getDefaultJPEGEncodeParam(image.getRaster(),
>>>>>>>>>>>>>>>>>>>>>>>>>>>> JPEGDecodeParam.COLOR_ID_CMYK);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>                           param.setQuality(1,
>>>>>>>>>>>>>>>>>>>>>>>>>>>> false);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> encoder.encode(image.getRaster(),
>>>>>>>>>>>>>>>>>>>>>>>>>>>> param);
>>>>>>>>>>>>>>>>>>>>>>>>>>>>                           fos.close();
>>>>>>>>>>>>>>>>>>>>>>>>>>>>                       } catch (Throwable t) {
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> logger.debug(t.getMessage());
>>>>>>>>>>>>>>>>>>>>>>>>>>>>                       }
>>>>>>>>>>>>>>>>>>>>>>>>>>>> But generally we use ImageIO
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/06/2011 08:29 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Yeah i think i need your help again i tried tu
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> run
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> .jar
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> file
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> console it work but without images this it what
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> appears
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> GRAVE: Error while processing image:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Cannot
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> load
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> image
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> (no
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> suitable loader/converter combination
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> available)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i tried  download the jai-imagio add to the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> class
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> path
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> but
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> dont
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> work
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Very odd.  I'm having no problems getting
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> images
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> into
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> pdfs
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> using
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-1.0.
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/03/2011 11:04 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> aaa hey thanks for the help the other day, i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> resolve
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> problem
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> changing
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> version of FOP for the 0.95beta instead of
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> 1.0,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> works
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> now
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> prints
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the image and its good, thanks and we are in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> touch
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> if
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> anything
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> else
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fails
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> jejeje
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Nothing in the log from the transformer?
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/03/2011 09:47 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> hi there i have another problem i hope you
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> help
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> me
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> create
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> with foe has no image, it dont show any of
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> them,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> xsl
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> seems
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> be
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> rigth i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> tested with EditX and the pdf show me the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> image,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> what
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> be,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> xmlgraphics-commons-1.5svn, fop 1.0,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-pdf-images
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> 2.0.1
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Snapshot
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> render of the image but it don work please
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> help!!!
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> :,(
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> :-):confused::confused::confused::confused:=)
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> http://old.nabble.com/file/p31822059/libraries.jpeg
>>>>>>>>>>>>>>>>> http://old.nabble.com/file/p31822059/libraries.bmp
>>>>>>>>>>>>>>>>> libraries.bmp
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>> ---------------------------------------------------------------------
>>>>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>> For additional commands, e-mail:
>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>> ---------------------------------------------------------------------
>>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>>>>
>>>>>>
>>>>>>
>>>> ---------------------------------------------------------------------
>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>>
>>>>
>>>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>
>>
>>

Re: Problems with FOP and image

Posted by "Oscar.Flores" <fa...@hotmail.com>.
Hi thanks for the help yeah i haven see that its was .java and not .class, ok
then if i follow correctly what you are saying then it has to be something
like this 

BufferedImage newImage = new BufferedImage ("C:\Logo.jpg")
ImageIO.write(BufferedImage, "JPEG", jpegImageFile) jpegImageFile will be
the XML call rigth something like "C:\Logo.jpg")

and another thing 

  Warning(1979/26): fo:table, table-layout="auto" is currently not supported
by FOP 
but in my xslt it ike this <fo:table table-layout="fixed" width="100%" > so
i dont now what its causing the ploblem

                                                     

Rob Sargent-4 wrote:
> 
> 
> 
> On 06/14/2011 11:06 AM, Oscar.Flores wrote:
>> Yeah i do the class is in jai-imageio-1.1-sources.jar, the enviroment is
>> just
> Having the file in the "...sources.jar" won't do the runtime world much 
> good. You need the jar of .class files for jai-imageio, not .java files
>> windows xp, and the bufferedImage will be the path of the image??
> No, the bufferedImage is an in-memory instance of BufferedImage holding 
> the bits of the image.  In the case that you have to read it from one 
> place and write it to another.
>> Rob Sargent-4 wrote:
>>> Did you go through all your jars looking for  'CLibJPEGImageReaderSpi'.
>>> My greatest suspicion is that you don't have all your jars lined up.
>>> Which jar(s) do you think supplies these?
>>>
>>> What is your environment: just windows or do you have any tools like
>>> cygwin?
>>>
>>> The "jpegImageFile" would be the filename in your xsl the
>>> external-resource.  If you're just using a file that is already in place
>>> you don't have to re-write it.
>>>
>>>
>>>
>>> On 06/14/2011 08:29 AM, Oscar.Flores wrote:
>>>> No i dont, and that weird jejeje netbeans seems to do that for me, so
>>>> the
>>>> calls like ImageIO.write(BufferedImage, "JPEG", jpegImageFile)? do i
>>>> have
>>>> to
>>>> do it in every image that i put in the pdf?? and the image is gererate
>>>> directly in the pdf??how can i do it??
>>>>
>>>> Rob Sargent-4 wrote:
>>>>> Some jar to which netbeans has access has those classes.  Look in the
>>>>> output of jar tvf<each of your jars>   and see if any of those has the
>>>>> named classes.  If you find a jar with those classes make sure it's
>>>>> part
>>>>> of your classpath for you app.
>>>>>
>>>>> Are you making any calls like ImageIO.write(BufferedImage, "JPEG",
>>>>> jpegImageFile)?
>>>>>
>>>>> On 06/13/2011 05:31 PM, Oscar.Flores wrote:
>>>>>> ok i made a test and tell me that the class is missign but maybe what
>>>>>> you
>>>>>> say
>>>>>> its rigth and it register the handler
>>>>>> so i gonna register the services so i do this
>>>>>>
>>>>>>     public static void main(String[] args) throws Exception {
>>>>>>             DOMConfigurator.configure("D:/Mis
>>>>>> documentos/NetBeansProjects/Factura/src/factura/log4j.xml");
>>>>>>             logger.info("Entering application.");
>>>>>>
>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>> CLibJPEGImageReaderSpi());
>>>>>>
>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>> CLibJPEGImageWriterSpi());
>>>>>>
>>>>>> also after register my services it telling me that the class
>>>>>> CLibJPEGImageReaderSpi() and CLibJPEGImageWriterSpi() is missing but
>>>>>> only
>>>>>> in
>>>>>> command
>>>>>>
>>>>>> after register mi service, something more has to be done??
>>>>>>
>>>>>>
>>>>>> Rob Sargent-4 wrote:
>>>>>>> I'm not sure I'm following correctly: does removing the xmlgraphics
>>>>>>> jar
>>>>>>> cause netbeans to behave the same as the command-line run of you
>>>>>>> app?
>>>>>>> If
>>>>>>> so, I suspect netbeans is registering services for you.  Your own
>>>>>>> code
>>>>>>> will have to make a call to one of the
>>>>>>> IIORegistry.registerServiceProvider() methods.
>>>>>>>
>>>>>>> On 06/13/2011 05:02 PM, Oscar.Flores wrote:
>>>>>>>> Ok aaaa i get it, actually the ImageIO library i added because i
>>>>>>>> read
>>>>>>>> in
>>>>>>>> the
>>>>>>>> xmlgrapics that if something like the message
>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException: Cannot load
>>>>>>>> image
>>>>>>>> (no
>>>>>>>> suitable loader/converter combination available)appear i have to
>>>>>>>> add
>>>>>>>> the
>>>>>>>> jar
>>>>>>>> file to the classpath but that all it say no configuration or
>>>>>>>> anything,
>>>>>>>> then
>>>>>>>> i delete the imagenIO libs and still i have the same output in
>>>>>>>> netbeans
>>>>>>>> so
>>>>>>>> xmlgrapics seem to have the problem in the plugins or i have to
>>>>>>>> configure
>>>>>>>> something
>>>>>>>>
>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>> Then it seems to me netbeans (if it's producing good output ==
>>>>>>>>> assumptionA) is still using something that the command-line isn't.
>>>>>>>>>
>>>>>>>>> And given assumptionA, you're java code is correct in terms of FOP
>>>>>>>>> and
>>>>>>>>> your configuration isn't for ImageIO.  Show your ImageIO related
>>>>>>>>> code
>>>>>>>>> and are you sure it's in your app.  Use the logger to show a
>>>>>>>>> message
>>>>>>>>> when you add  your loader.  Or list all ImageIO services:
>>>>>>>>> IIORegistry.getServiceProviders()
>>>>>>>>>
>>>>>>>>> On 06/13/2011 03:01 PM, Oscar.Flores wrote:
>>>>>>>>>> ok well i put the xml in scr of my proyect i see that i still
>>>>>>>>>> have
>>>>>>>>>> the
>>>>>>>>>> same
>>>>>>>>>> issues of the image render of any image i dont now if the xml its
>>>>>>>>>> in
>>>>>>>>>> place i
>>>>>>>>>> put the code down to see if something its missing
>>>>>>>>>>
>>>>>>>>>> 15:45:07,827 ERROR [render] Error while processing image:
>>>>>>>>>> c:\cfd\nombregp.bmp (i
>>>>>>>>>> mage/bmp)
>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException: Cannot load
>>>>>>>>>> image
>>>>>>>>>> (no
>>>>>>>>>> suitab
>>>>>>>>>> le loader/converter combination available) for
>>>>>>>>>> c:\cfd\nombregp.bmp
>>>>>>>>>> (image/bmp)
>>>>>>>>>>              at
>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageManager.getImage(ImageManage
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> import mx.bigdata.sat.cfd.schema.Comprobante;
>>>>>>>>>> import mx.bigdata.sat.cfd.CFDv2;
>>>>>>>>>> import mx.bigdata.sat.security.KeyLoader;
>>>>>>>>>> import org.jdom.*;
>>>>>>>>>> import org.jdom.input.SAXBuilder;
>>>>>>>>>> import org.jdom.output.XMLOutputter;
>>>>>>>>>> import org.jdom.output.Format;
>>>>>>>>>> import org.jdom.transform.JDOMSource;
>>>>>>>>>> //Java
>>>>>>>>>>       import java.io.File;
>>>>>>>>>>       import java.io.OutputStream;
>>>>>>>>>>
>>>>>>>>>>       //JAXP
>>>>>>>>>>       import javax.xml.transform.Transformer;
>>>>>>>>>>       import javax.xml.transform.TransformerFactory;
>>>>>>>>>>       import javax.xml.transform.Source;
>>>>>>>>>>       import javax.xml.transform.Result;
>>>>>>>>>>       import javax.xml.transform.stream.StreamSource;
>>>>>>>>>>       import javax.xml.transform.sax.SAXResult;
>>>>>>>>>>
>>>>>>>>>>       //FOP
>>>>>>>>>>       import org.apache.fop.apps.FOUserAgent;
>>>>>>>>>>       import org.apache.fop.apps.Fop;
>>>>>>>>>>       import org.apache.fop.apps.FopFactory;
>>>>>>>>>>       import org.apache.fop.apps.MimeConstants;
>>>>>>>>>>
>>>>>>>>>>       //log4j
>>>>>>>>>>       import org.apache.log4j.*;
>>>>>>>>>>       import org.apache.log4j.xml.DOMConfigurator;
>>>>>>>>>>
>>>>>>>>>> public final class Main {
>>>>>>>>>>          @SuppressWarnings("unchecked")
>>>>>>>>>>          static Logger logger = Logger.getLogger(Main.class);
>>>>>>>>>>
>>>>>>>>>>          public static void main(String[] args) throws Exception
>>>>>>>>>> {
>>>>>>>>>>               DOMConfigurator.configure("D:/Mis
>>>>>>>>>> documentos/NetBeansProjects/Factura/src/factura/log4j.xml");
>>>>>>>>>>               logger.info("Entering application.");
>>>>>>>>>>               try {
>>>>>>>>>>                  File file = new File(args[0]);
>>>>>>>>>>                  Comprobante comp = CFDv2.newComprobante(new
>>>>>>>>>> FileInputStream(file));
>>>>>>>>>>                  CFDv2 cfd = new CFDv2(comp);
>>>>>>>>>>                  PrivateKey key =
>>>>>>>>>> KeyLoader.loadPKCS8PrivateKey(new
>>>>>>>>>> FileInputStream(args[1]),(args[2]));
>>>>>>>>>>                  X509Certificate cert =
>>>>>>>>>> KeyLoader.loadX509Certificate(new
>>>>>>>>>> FileInputStream(args[3]));
>>>>>>>>>>                  Comprobante sellado = cfd.sellarComprobante(key,
>>>>>>>>>> cert);
>>>>>>>>>>                  String cadena = cfd.getCadenaOriginal();
>>>>>>>>>>                  String sello = sellado.getSello();
>>>>>>>>>>                  // Creamos el builder basado en SAX
>>>>>>>>>>                  SAXBuilder builder = new SAXBuilder();
>>>>>>>>>>                  // Construimos el arbol DOM a partir del fichero
>>>>>>>>>> xml
>>>>>>>>>>                  Document documentJDOM = builder.build(new
>>>>>>>>>> FileInputStream(args[0]));
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>                  Element raiz =
>>>>>>>>>> documentJDOM.getRootElement();//toma
>>>>>>>>>> el
>>>>>>>>>> nodo
>>>>>>>>>> raiz
>>>>>>>>>> del documento.
>>>>>>>>>>                  raiz.setAttribute("sello", sello);
>>>>>>>>>>                  raiz.setAttribute("certificado",
>>>>>>>>>> sellado.getCertificado());
>>>>>>>>>>
>>>>>>>>>> //System.out.println(raiz.getAttributeValue("sello"));
>>>>>>>>>>
>>>>>>>>>> //System.out.println(raiz.getAttributeValue("certificado"));
>>>>>>>>>>                  // Recorremos los hijos de la etiqueta raíz
>>>>>>>>>>                  List<Element>      hijosRaiz =
>>>>>>>>>> raiz.getChildren();
>>>>>>>>>>                  boolean Bandera=false;
>>>>>>>>>>                  for(Element hijo: hijosRaiz)
>>>>>>>>>>                  {
>>>>>>>>>>                      // Obtenemos el nombre y su contenido de
>>>>>>>>>> tipo
>>>>>>>>>> texto
>>>>>>>>>>                      String nombre = hijo.getName();
>>>>>>>>>>
>>>>>>>>>>                      if (nombre.equals("Addenda"))
>>>>>>>>>>                      {   List<Element>      subHijo =
>>>>>>>>>> hijo.getChildren();
>>>>>>>>>>                          for(Element hij: subHijo)
>>>>>>>>>>                              {
>>>>>>>>>>                              hij.setAttribute("CadenaOriginal",
>>>>>>>>>> cadena);
>>>>>>>>>>                             
>>>>>>>>>> //System.out.println("CadenaOriginal:
>>>>>>>>>> "+hij.getAttributeValue("CadenaOriginal"));
>>>>>>>>>>                              Bandera=true;
>>>>>>>>>>                              break;
>>>>>>>>>>                              }
>>>>>>>>>>                      }
>>>>>>>>>>                      if (Bandera)
>>>>>>>>>>                      {
>>>>>>>>>>                          XMLOutputter out = new
>>>>>>>>>> XMLOutputter(Format.getPrettyFormat());
>>>>>>>>>>                          File nuevoXML = new File(args[0]);
>>>>>>>>>>                          try{
>>>>>>>>>>                              FileOutputStream archivoXML= new
>>>>>>>>>> FileOutputStream
>>>>>>>>>> (nuevoXML);
>>>>>>>>>>                              out.output(documentJDOM,
>>>>>>>>>> archivoXML);
>>>>>>>>>>
>>>>>>>>>>                             }
>>>>>>>>>>                          catch (Exception
>>>>>>>>>> ex){System.out.println(ex.getMessage());}
>>>>>>>>>>                          // Para generar el pdf a partir de un
>>>>>>>>>> archivo.xsl
>>>>>>>>>> y
>>>>>>>>>> un
>>>>>>>>>>                          // archivo.xml
>>>>>>>>>>                      }
>>>>>>>>>>                    }
>>>>>>>>>>                // configure fopFactory as desired
>>>>>>>>>>                FopFactory fopFactory = FopFactory.newInstance();
>>>>>>>>>>                FOUserAgent foUserAgent =
>>>>>>>>>> fopFactory.newFOUserAgent();
>>>>>>>>>>
>>>>>>>>>>                // configure foUserAgent as desired
>>>>>>>>>>                // Setup output
>>>>>>>>>>               File pdffile = new File(args[5]);
>>>>>>>>>>
>>>>>>>>>>               OutputStream out = new
>>>>>>>>>> java.io.FileOutputStream(pdffile);
>>>>>>>>>>               out = new java.io.BufferedOutputStream(out);
>>>>>>>>>>               try {
>>>>>>>>>>                      // Construct fop with desired output format
>>>>>>>>>>                       Fop fop =
>>>>>>>>>> fopFactory.newFop(MimeConstants.MIME_PDF,
>>>>>>>>>> foUserAgent, out);
>>>>>>>>>>                      // Setup XSLT
>>>>>>>>>>                      TransformerFactory factory =
>>>>>>>>>> TransformerFactory.newInstance();
>>>>>>>>>>                      Transformer transformer =
>>>>>>>>>> factory.newTransformer(new
>>>>>>>>>> StreamSource(args[4]));
>>>>>>>>>>                      // Set the value of a  in the stylesheet
>>>>>>>>>>                      transformer.setParameter("versionParam",
>>>>>>>>>> "2.0");
>>>>>>>>>>
>>>>>>>>>>                     // Setup input for XSLT transformation
>>>>>>>>>>                      Source src = new JDOMSource(documentJDOM);
>>>>>>>>>>                       // Resulting SAX events (the generated FO)
>>>>>>>>>> must
>>>>>>>>>> be
>>>>>>>>>> piped
>>>>>>>>>> through to FOP
>>>>>>>>>>                      Result res = new
>>>>>>>>>> SAXResult(fop.getDefaultHandler());
>>>>>>>>>>                       // Start XSLT transformation and FOP
>>>>>>>>>> processing
>>>>>>>>>>                     // System.setProperty("java.awt.headless",
>>>>>>>>>> "true");
>>>>>>>>>>                          transformer.transform(src, res);
>>>>>>>>>>                      } finally {
>>>>>>>>>>                       out.close();
>>>>>>>>>>                  }
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>                System.out.println("Success!");
>>>>>>>>>>               } catch (Exception e) {
>>>>>>>>>>                e.printStackTrace(System.err);
>>>>>>>>>>                System.exit(-1);
>>>>>>>>>>             }
>>>>>>>>>>           logger.info("Exiting application.");
>>>>>>>>>>
>>>>>>>>>>        }
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>> Try this log4j.xml: Place it at the root of your jar file
>>>>>>>>>>>
>>>>>>>>>>> <?xml version="1.0" encoding="UTF-8"?>
>>>>>>>>>>> <!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">
>>>>>>>>>>>
>>>>>>>>>>> <log4j:configuration
>>>>>>>>>>> xmlns:log4j="http://jakarta.apache.org/log4j/"
>>>>>>>>>>> debug="false">
>>>>>>>>>>>
>>>>>>>>>>> <appender name="CONSOLE"
>>>>>>>>>>> class="org.apache.log4j.ConsoleAppender">
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> <layout class="org.apache.log4j.PatternLayout">
>>>>>>>>>>>
>>>>>>>>>>> </layout>
>>>>>>>>>>> </appender>
>>>>>>>>>>>
>>>>>>>>>>> <category name="org">
>>>>>>>>>>> <priority value="DEBUG"/>
>>>>>>>>>>> </category>
>>>>>>>>>>> <category name="org.apache">
>>>>>>>>>>> <priority value="WARN"/>
>>>>>>>>>>> </category>
>>>>>>>>>>> <category name="org.springframework">
>>>>>>>>>>> <priority value="WARN"/>
>>>>>>>>>>> </category>
>>>>>>>>>>> <category name="org.hibernate">
>>>>>>>>>>> <priority value="DEBUG"/>
>>>>>>>>>>> </category>
>>>>>>>>>>> <category name="net">
>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>> </category>
>>>>>>>>>>> <category name="javax">
>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>> </category>
>>>>>>>>>>> <category name="java">
>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>> </category>
>>>>>>>>>>> <category name="sun">
>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>> </category>
>>>>>>>>>>> <category name="org.jboss">
>>>>>>>>>>> <priority value="INFO"/>
>>>>>>>>>>> </category>
>>>>>>>>>>> <category name="org.jboss.seam">
>>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>>> </category>
>>>>>>>>>>> <root>
>>>>>>>>>>> <appender-ref ref="CONSOLE"/>
>>>>>>>>>>> </root>
>>>>>>>>>>>
>>>>>>>>>>> </log4j:configuration>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> On 06/13/2011 11:06 AM, Oscar.Flores wrote:
>>>>>>>>>>>> ok i dont thik i have a configuracion file i find the code that
>>>>>>>>>>>> i
>>>>>>>>>>>> put
>>>>>>>>>>>> in
>>>>>>>>>>>> the
>>>>>>>>>>>> other post i think its the basic
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>> Do you have a config file for log4j.  Usually it's in a
>>>>>>>>>>>>> resource
>>>>>>>>>>>>> tree.
>>>>>>>>>>>>> Are you copying that to your deployment? Is your ant script
>>>>>>>>>>>>> including
>>>>>>>>>>>>> the config file in the jar of your application?
>>>>>>>>>>>>>
>>>>>>>>>>>>> On 06/13/2011 10:12 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>> Ok yeah the log4j its having isuees to find the configuration
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> log4j:WARN No appenders could be found for logger
>>>>>>>>>>>>>> (org.apache.fop.util.ContentHandlerFactoryRegistry).
>>>>>>>>>>>>>> log4j:WARN Please initialize the log4j system properly.
>>>>>>>>>>>>>> log4j:WARN See
>>>>>>>>>>>>>> http://logging.apache.org/log4j/1.2/faq.html#noconfig
>>>>>>>>>>>>>> for
>>>>>>>>>>>>>> more info.
>>>>>>>>>>>>>> i go to the faq guide and it say try loading the class or
>>>>>>>>>>>>>> resource
>>>>>>>>>>>>>> yourself.
>>>>>>>>>>>>>> If you can't find it, neither will log4j.
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> aaa i dont know where to set this
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> also here its my xlst
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> http://old.nabble.com/file/p31835645/FacturasOMF.xsl
>>>>>>>>>>>>>> FacturasOMF.xsl
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> and the fo file that generate the editix
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> http://old.nabble.com/file/p31835645/Prueba.fo Prueba.fo
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>> The first thing is to really dig into what you did to
>>>>>>>>>>>>>>> netbeans
>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>> get
>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>> to work...
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> I've forgotten what your stylesheet looked like, so maybe if
>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>> show
>>>>>>>>>>>>>>> us
>>>>>>>>>>>>>>> again how you're referencing your images we might notice a
>>>>>>>>>>>>>>> problem.
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> It might also help to see the "fo" generated during your
>>>>>>>>>>>>>>> transformation.
>>>>>>>>>>>>>>> Can you grab that just after xslt and just before fop calls.
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> Are you sure there is no error being logged somewhere when
>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>> run
>>>>>>>>>>>>>>> from
>>>>>>>>>>>>>>> the command line? (Where is log4j writing and at what
>>>>>>>>>>>>>>> level?)
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> Oscar.Flores wrote:
>>>>>>>>>>>>>>>> You where absolutly rigth i miss a few libraries to add
>>>>>>>>>>>>>>>> into
>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>> jar
>>>>>>>>>>>>>>>> file, i
>>>>>>>>>>>>>>>> modified the build.xml to add the package and jar that i
>>>>>>>>>>>>>>>> need,
>>>>>>>>>>>>>>>> now
>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>> error
>>>>>>>>>>>>>>>> message is not there but still the images dont show in the
>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>> remeber
>>>>>>>>>>>>>>>> that i do something in netbeans so they can add to the pdf
>>>>>>>>>>>>>>>> but
>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>> cant
>>>>>>>>>>>>>>>> remeber i dont now if there is still a library that is
>>>>>>>>>>>>>>>> missing
>>>>>>>>>>>>>>>> or
>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>> am
>>>>>>>>>>>>>>>> adding more than it should be
>>>>>>>>>>>>>>>> This is what i use :
>>>>>>>>>>>>>>>> cfdi-base-0.1.6-SNAPSHOT.jar
>>>>>>>>>>>>>>>> guava-r09.jar
>>>>>>>>>>>>>>>> guava-r09-gwt.jar
>>>>>>>>>>>>>>>> jaxb-impl-2.1.10.jar
>>>>>>>>>>>>>>>> avalon-framework-api-4.3.jar
>>>>>>>>>>>>>>>> avalon-framework-cvs-20020806.jar
>>>>>>>>>>>>>>>> avalon-logkit-2.1.jar
>>>>>>>>>>>>>>>> not-yet-commons-ssl-0.3.11.jar
>>>>>>>>>>>>>>>> commons-codec-1.5.jar
>>>>>>>>>>>>>>>> commons-codec-1.5-sources.jar
>>>>>>>>>>>>>>>> log4j-1.2.16.jar
>>>>>>>>>>>>>>>> fop.jar
>>>>>>>>>>>>>>>> jdom.jar
>>>>>>>>>>>>>>>> xmlgraphics-commons-1.4.jar
>>>>>>>>>>>>>>>> commons-io-1.3.1.jar
>>>>>>>>>>>>>>>> fop-pdf-images-2.0.1.SNAPSHOT.jar
>>>>>>>>>>>>>>>> pdfbox-app-1.5.0.jar
>>>>>>>>>>>>>>>> fontbox-1.3.1.jar
>>>>>>>>>>>>>>>> jempbox-1.3.1.jar
>>>>>>>>>>>>>>>> xercesImpl-2.7.1.jar
>>>>>>>>>>>>>>>> batik-all-1.7.jar
>>>>>>>>>>>>>>>> xml-apis-1.3.04.jar
>>>>>>>>>>>>>>>> xml-apis-ext-1.3.04.jar
>>>>>>>>>>>>>>>>         avalon-framework-4.2.0.jar
>>>>>>>>>>>>>>>>         xalan-2.7.0.jar
>>>>>>>>>>>>>>>>         serializer-2.7.0.jar
>>>>>>>>>>>>>>>>         commons-logging-1.0.4.jar
>>>>>>>>>>>>>>>>         jai_codec.jar
>>>>>>>>>>>>>>>>         jai_core.jar
>>>>>>>>>>>>>>>>         batik-ext.jar
>>>>>>>>>>>>>>>>         jai_imageio-1.1-sources.jar
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> Thanks Rob for the help
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> I suspect running from your jar does not have/use the same
>>>>>>>>>>>>>>>>> classpath
>>>>>>>>>>>>>>>>> that is in effect while you're in the debugger.
>>>>>>>>>>>>>>>>> By what mechanism do you generate the jar?
>>>>>>>>>>>>>>>>> Is it an executable jar or are you running java -classpath
>>>>>>>>>>>>>>>>> <your-jar-here:other-jars>        Main?
>>>>>>>>>>>>>>>>> Make your IDE (netbeans) display the classpath  it uses to
>>>>>>>>>>>>>>>>> run
>>>>>>>>>>>>>>>>> your
>>>>>>>>>>>>>>>>> app
>>>>>>>>>>>>>>>>> and compare that with the above.
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> On 06/09/2011 07:21 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> aaa ok well my problem is that when i do the pdf in
>>>>>>>>>>>>>>>>>> netbean
>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>> fine
>>>>>>>>>>>>>>>>>> with images and evething but when i run the jar file in
>>>>>>>>>>>>>>>>>> command
>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>> give
>>>>>>>>>>>>>>>>>> me a
>>>>>>>>>>>>>>>>>> error
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> GRAVE: Error while processing image: I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>>         
>>>>>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException:
>>>>>>>>>>>>>>>>>> Cannot
>>>>>>>>>>>>>>>>>> load
>>>>>>>>>>>>>>>>>>          image (no suitable loader/converter combination
>>>>>>>>>>>>>>>>>> available)
>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>          (image/jpeg)
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> so i dont no what its not working and if i have to add
>>>>>>>>>>>>>>>>>> something
>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>> my
>>>>>>>>>>>>>>>>>> code
>>>>>>>>>>>>>>>>>> so the images can load i am soooo desperate what i am
>>>>>>>>>>>>>>>>>> doing
>>>>>>>>>>>>>>>>>> wrong??
>>>>>>>>>>>>>>>>>> i am sorry for the trouble and if a dont explain my self
>>>>>>>>>>>>>>>>>> very
>>>>>>>>>>>>>>>>>> good
>>>>>>>>>>>>>>>>>> jejeje
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> Not at all sure what your problem is.  All I can do is
>>>>>>>>>>>>>>>>>>> show
>>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>>> what
>>>>>>>>>>>>>>>>>>> works for us.
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> Our source xml looks like this:
>>>>>>>>>>>>>>>>>>> <image image-id="381623861" reference-id="ref-220"
>>>>>>>>>>>>>>>>>>> width="750"
>>>>>>>>>>>>>>>>>>> height="750" image-space-id="space-1" position="5"
>>>>>>>>>>>>>>>>>>>                       image-pool-position="31" pos="4"
>>>>>>>>>>>>>>>>>>>                       file="ref_10_1002108221">        
>>>>>>>>>>>>>>>>>>> <!--
>>>>>>>>>>>>>>>>>>> an
>>>>>>>>>>>>>>>>>>> actual
>>>>>>>>>>>>>>>>>>> file
>>>>>>>>>>>>>>>>>>> (.jpeg
>>>>>>>>>>>>>>>>>>> copied the working directory of the transformer -->
>>>>>>>>>>>>>>>>>>> <fields />
>>>>>>>>>>>>>>>>>>> <caption />
>>>>>>>>>>>>>>>>>>> <annotations>
>>>>>>>>>>>>>>>>>>> <arrow_positions origHeight="750" origWidth="750" />
>>>>>>>>>>>>>>>>>>> </annotations>
>>>>>>>>>>>>>>>>>>> </image>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> Our xslt looks like this for each image needed.
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> <xsl:template name="image">
>>>>>>>>>>>>>>>>>>> <xsl:param name="img"/>         <!-- This is the xml
>>>>>>>>>>>>>>>>>>> node
>>>>>>>>>>>>>>>>>>> from
>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>> source
>>>>>>>>>>>>>>>>>>> xml
>>>>>>>>>>>>>>>>>>> above -->
>>>>>>>>>>>>>>>>>>> <xsl:param name="width"/>
>>>>>>>>>>>>>>>>>>> <xsl:param name="height" select="$width"/>
>>>>>>>>>>>>>>>>>>> <xsl:param name="ignoreHeight">false</xsl:param>
>>>>>>>>>>>>>>>>>>> <fo:block>
>>>>>>>>>>>>>>>>>>> <fo:external-graphic src="{$img/@file}"
>>>>>>>>>>>>>>>>>>> height="{$height}"
>>>>>>>>>>>>>>>>>>> width="{$width}" content-height="scale-to-fit"
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> content-width="scale-to-fit"
>>>>>>>>>>>>>>>>>>> border="0.5pt solid black" border-collapse="separate">
>>>>>>>>>>>>>>>>>>> <xsl:if test="$ignoreHeight != 'true'">
>>>>>>>>>>>>>>>>>>> <xsl:attribute name="height">
>>>>>>>>>>>>>>>>>>> <xsl:value-of select="$height"/>
>>>>>>>>>>>>>>>>>>> </xsl:attribute>
>>>>>>>>>>>>>>>>>>> </xsl:if>
>>>>>>>>>>>>>>>>>>> </fo:external-graphic>
>>>>>>>>>>>>>>>>>>> </fo:block>
>>>>>>>>>>>>>>>>>>> </xsl:template>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> Our generated fo looks like this:
>>>>>>>>>>>>>>>>>>> <fo:table-cell>
>>>>>>>>>>>>>>>>>>> <fo:block>
>>>>>>>>>>>>>>>>>>> <fo:external-graphic border-collapse="separate"
>>>>>>>>>>>>>>>>>>> border="0.5pt
>>>>>>>>>>>>>>>>>>> solid
>>>>>>>>>>>>>>>>>>> black" content-width="scale-to-fit"
>>>>>>>>>>>>>>>>>>> content-height="scale-to-fit"
>>>>>>>>>>>>>>>>>>> width="2.5in" height="2.5in" src="ref_10_1002108221" />
>>>>>>>>>>>>>>>>>>> </fo:block>
>>>>>>>>>>>>>>>>>>> </fo:table-cell>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> And the generated pdfs include the image and are shipped
>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>> printer.
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> How does this stack up with what you have?
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> On 06/09/2011 01:19 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> Hi there well i still got the problem but searching IN
>>>>>>>>>>>>>>>>>>>> INTERNET
>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>> find
>>>>>>>>>>>>>>>>>>>> a
>>>>>>>>>>>>>>>>>>>> JPEG
>>>>>>>>>>>>>>>>>>>> renderer output for FOP its here
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> http://marc.info/?l=fop-user&m=125986752706366&w=2
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> the cuestion is can i render the image that i want to
>>>>>>>>>>>>>>>>>>>> put
>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>> pdf,
>>>>>>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>>>>>>> then add to the xsl the render jpeg it will work??
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> and here explaints how use the render when he say uses
>>>>>>>>>>>>>>>>>>>> fop
>>>>>>>>>>>>>>>>>>>> as
>>>>>>>>>>>>>>>>>>>> normal
>>>>>>>>>>>>>>>>>>>> case
>>>>>>>>>>>>>>>>>>>> what does it mean
>>>>>>>>>>>>>>>>>>>> what else have to add to the code?? i hope you can help
>>>>>>>>>>>>>>>>>>>> me
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> Thanks!!
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> // OutputStream out = what you want
>>>>>>>>>>>>>>>>>>>>                      FopFactory fopFactory =
>>>>>>>>>>>>>>>>>>>> FopFactory.newInstance();
>>>>>>>>>>>>>>>>>>>>                      RendererFactory rendererFactory =
>>>>>>>>>>>>>>>>>>>> null;
>>>>>>>>>>>>>>>>>>>>                      FOUserAgent foUserAgent = null;
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>                      rendererFactory =
>>>>>>>>>>>>>>>>>>>> fopFactory.getRendererFactory();
>>>>>>>>>>>>>>>>>>>>                     
>>>>>>>>>>>>>>>>>>>> rendererFactory.addRendererMaker(new
>>>>>>>>>>>>>>>>>>>> MultiRendererMaker("jpeg"));
>>>>>>>>>>>>>>>>>>>>                      foUserAgent =
>>>>>>>>>>>>>>>>>>>> fopFactory.newFOUserAgent();
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> rendererFactory.createRenderer(foUserAgent,
>>>>>>>>>>>>>>>>>>>> "image/jpeg");
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>                      Fop fop =
>>>>>>>>>>>>>>>>>>>> fopFactory.newFop("image/jpeg",
>>>>>>>>>>>>>>>>>>>> foUserAgent,
>>>>>>>>>>>>>>>>>>>> out);
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> //Use fop as normal case
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> Since you're now into xmlgraphics, I think you're best
>>>>>>>>>>>>>>>>>>>>> bet
>>>>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>>>>> here
>>>>>>>>>>>>>>>>>>>>> <http://xmlgraphics.apache.org/commons/image-loader.html>
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> On 06/07/2011 10:18 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> Hi ok this is for generate images that dont need to
>>>>>>>>>>>>>>>>>>>>>> be
>>>>>>>>>>>>>>>>>>>>>> decompress
>>>>>>>>>>>>>>>>>>>>>> later??
>>>>>>>>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>>>>>>>>> the result image i put in my xsl ?? then it should
>>>>>>>>>>>>>>>>>>>>>> work,
>>>>>>>>>>>>>>>>>>>>>> aaa
>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>> change
>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>> fop
>>>>>>>>>>>>>>>>>>>>>> 1.0 and xml communs 1.4 and its the same jejeje  
>>>>>>>>>>>>>>>>>>>>>> dont
>>>>>>>>>>>>>>>>>>>>>> find
>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>> image
>>>>>>>>>>>>>>>>>>>>>> preload
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> org.apache.fop.fo.flow.ExternalGraphic bind
>>>>>>>>>>>>>>>>>>>>>> SEVERE: Image not available: The file format is not
>>>>>>>>>>>>>>>>>>>>>> supported.
>>>>>>>>>>>>>>>>>>>>>> No
>>>>>>>>>>>>>>>>>>>>>> ImagePreloader for *.jpg or *.bmp
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> ImageIO.write(bufferedImage, "JPEG", file);
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> On 06/07/2011 08:21 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> Ok i actually register the handler now what i have
>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>> do
>>>>>>>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>>>>>>>> setup
>>>>>>>>>>>>>>>>>>>>>>>> this
>>>>>>>>>>>>>>>>>>>>>>>> handler or not?? and how can i do that, also it
>>>>>>>>>>>>>>>>>>>>>>>> seem
>>>>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>> bmp
>>>>>>>>>>>>>>>>>>>>>>>> its
>>>>>>>>>>>>>>>>>>>>>>>> not
>>>>>>>>>>>>>>>>>>>>>>>> recognice also what can i do?? thanks for the help
>>>>>>>>>>>>>>>>>>>>>>>> rob
>>>>>>>>>>>>>>>>>>>>>>>> also i am trying to convert the images to see if it
>>>>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>>>>> helps
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> On 06/06/2011 02:29 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> Hi what can be the difference between execute the
>>>>>>>>>>>>>>>>>>>>>>>>>> program
>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>> netbeans
>>>>>>>>>>>>>>>>>>>>>>>>>> (where
>>>>>>>>>>>>>>>>>>>>>>>>>> it works and print the images and the jar in the
>>>>>>>>>>>>>>>>>>>>>>>>>> console)
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> Different classes being loaded by Netbeans than
>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>> console
>>>>>>>>>>>>>>>>>>>>>>>>> app.
>>>>>>>>>>>>>>>>>>>>>>>>> Get
>>>>>>>>>>>>>>>>>>>>>>>>> Netbeans to show you the full classpath it's using
>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>> it's
>>>>>>>>>>>>>>>>>>>>>>>>> "%classpath"
>>>>>>>>>>>>>>>>>>>>>>>>> variable
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> also i tried the
>>>>>>>>>>>>>>>>>>>>>>>>>> imageIO.getImageReadersBySuffix but i cant
>>>>>>>>>>>>>>>>>>>>>>>>>> interpretate
>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>> data
>>>>>>>>>>>>>>>>>>>>>>>>>> y.y,
>>>>>>>>>>>>>>>>>>>>>>>>>> its
>>>>>>>>>>>>>>>>>>>>>>>>>> that or always its true in the boolean variable,
>>>>>>>>>>>>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>>>>>>>>>>>>> how
>>>>>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>> register
>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>> handler??
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> Talk to IIORegistry, some thing like
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>>>>>>>>>>>>>> CLibJPEGImageReaderSpi());
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>>>>>>>>>>>>>> CLibJPEGImageWriterSpi());
>>>>>>>>>>>>>>>>>>>>>>>>> Note: those are not necessarily the services you
>>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>> your
>>>>>>>>>>>>>>>>>>>>>>>>> setup.
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> Thanks
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> See the javadoc on IIORegistry. With ImageIO you
>>>>>>>>>>>>>>>>>>>>>>>>>>> may
>>>>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>> register
>>>>>>>>>>>>>>>>>>>>>>>>>>> your handler(s). What does
>>>>>>>>>>>>>>>>>>>>>>>>>>> ImageIO.getImageReadersBySuffix()
>>>>>>>>>>>>>>>>>>>>>>>>>>> give
>>>>>>>>>>>>>>>>>>>>>>>>>>> you.
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> For certain jpegs we don't use ImageIO, rather
>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>> classes
>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>> com.sun.image.codec.jpeg:
>>>>>>>>>>>>>>>>>>>>>>>>>>>                      try {
>>>>>>>>>>>>>>>>>>>>>>>>>>>                          FileOutputStream fos =
>>>>>>>>>>>>>>>>>>>>>>>>>>> new
>>>>>>>>>>>>>>>>>>>>>>>>>>> FileOutputStream(file);
>>>>>>>>>>>>>>>>>>>>>>>>>>>                          JPEGImageEncoder
>>>>>>>>>>>>>>>>>>>>>>>>>>> encoder =
>>>>>>>>>>>>>>>>>>>>>>>>>>> JPEGCodec.createJPEGEncoder(fos);
>>>>>>>>>>>>>>>>>>>>>>>>>>>                          JPEGEncodeParam param =
>>>>>>>>>>>>>>>>>>>>>>>>>>> encoder.getDefaultJPEGEncodeParam(image.getRaster(),
>>>>>>>>>>>>>>>>>>>>>>>>>>> JPEGDecodeParam.COLOR_ID_CMYK);
>>>>>>>>>>>>>>>>>>>>>>>>>>>                          param.setQuality(1,
>>>>>>>>>>>>>>>>>>>>>>>>>>> false);
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> encoder.encode(image.getRaster(),
>>>>>>>>>>>>>>>>>>>>>>>>>>> param);
>>>>>>>>>>>>>>>>>>>>>>>>>>>                          fos.close();
>>>>>>>>>>>>>>>>>>>>>>>>>>>                      } catch (Throwable t) {
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> logger.debug(t.getMessage());
>>>>>>>>>>>>>>>>>>>>>>>>>>>                      }
>>>>>>>>>>>>>>>>>>>>>>>>>>> But generally we use ImageIO
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/06/2011 08:29 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> Yeah i think i need your help again i tried tu
>>>>>>>>>>>>>>>>>>>>>>>>>>>> run
>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>> .jar
>>>>>>>>>>>>>>>>>>>>>>>>>>>> file
>>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>> console it work but without images this it what
>>>>>>>>>>>>>>>>>>>>>>>>>>>> appears
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> GRAVE: Error while processing image:
>>>>>>>>>>>>>>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException:
>>>>>>>>>>>>>>>>>>>>>>>>>>>> Cannot
>>>>>>>>>>>>>>>>>>>>>>>>>>>> load
>>>>>>>>>>>>>>>>>>>>>>>>>>>> image
>>>>>>>>>>>>>>>>>>>>>>>>>>>> (no
>>>>>>>>>>>>>>>>>>>>>>>>>>>> suitable loader/converter combination
>>>>>>>>>>>>>>>>>>>>>>>>>>>> available)
>>>>>>>>>>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> i tried  download the jai-imagio add to the
>>>>>>>>>>>>>>>>>>>>>>>>>>>> class
>>>>>>>>>>>>>>>>>>>>>>>>>>>> path
>>>>>>>>>>>>>>>>>>>>>>>>>>>> but
>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>> dont
>>>>>>>>>>>>>>>>>>>>>>>>>>>> work
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Very odd.  I'm having no problems getting
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> images
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> into
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> pdfs
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> using
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-1.0.
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/03/2011 11:04 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> aaa hey thanks for the help the other day, i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> resolve
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> problem
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> changing
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> version of FOP for the 0.95beta instead of
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> 1.0,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> works
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> now
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> prints
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the image and its good, thanks and we are in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> touch
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> if
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> anything
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> else
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fails
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> jejeje
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Nothing in the log from the transformer?
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/03/2011 09:47 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> hi there i have another problem i hope you
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> help
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> me
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> create
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> with foe has no image, it dont show any of
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> them,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> xsl
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> seems
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> be
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> rigth i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> tested with EditX and the pdf show me the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> image,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> what
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> be,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> xmlgraphics-commons-1.5svn, fop 1.0,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-pdf-images
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> 2.0.1
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Snapshot
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> render of the image but it don work please
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> help!!!
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> :,(
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> :-):confused::confused::confused::confused:=)
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> http://old.nabble.com/file/p31822059/libraries.jpeg
>>>>>>>>>>>>>>>> http://old.nabble.com/file/p31822059/libraries.bmp
>>>>>>>>>>>>>>>> libraries.bmp
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>> For additional commands, e-mail:
>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>> ---------------------------------------------------------------------
>>>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>> For additional commands, e-mail:
>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>
>>>>>>>
>>>>>>>
>>>>> ---------------------------------------------------------------------
>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>>>
>>>>>
>>>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>
>>>
>>>
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
> 
> 
> 

-- 
View this message in context: http://old.nabble.com/Problems-with-FOP-and-image-tp31766430p31855097.html
Sent from the FOP - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Problems with FOP and image

Posted by Rob Sargent <rs...@xmission.com>.

On 06/14/2011 11:06 AM, Oscar.Flores wrote:
> Yeah i do the class is in jai-imageio-1.1-sources.jar, the enviroment is just
Having the file in the "...sources.jar" won't do the runtime world much 
good. You need the jar of .class files for jai-imageio, not .java files
> windows xp, and the bufferedImage will be the path of the image??
No, the bufferedImage is an in-memory instance of BufferedImage holding 
the bits of the image.  In the case that you have to read it from one 
place and write it to another.
> Rob Sargent-4 wrote:
>> Did you go through all your jars looking for  'CLibJPEGImageReaderSpi'.
>> My greatest suspicion is that you don't have all your jars lined up.
>> Which jar(s) do you think supplies these?
>>
>> What is your environment: just windows or do you have any tools like
>> cygwin?
>>
>> The "jpegImageFile" would be the filename in your xsl the
>> external-resource.  If you're just using a file that is already in place
>> you don't have to re-write it.
>>
>>
>>
>> On 06/14/2011 08:29 AM, Oscar.Flores wrote:
>>> No i dont, and that weird jejeje netbeans seems to do that for me, so the
>>> calls like ImageIO.write(BufferedImage, "JPEG", jpegImageFile)? do i have
>>> to
>>> do it in every image that i put in the pdf?? and the image is gererate
>>> directly in the pdf??how can i do it??
>>>
>>> Rob Sargent-4 wrote:
>>>> Some jar to which netbeans has access has those classes.  Look in the
>>>> output of jar tvf<each of your jars>   and see if any of those has the
>>>> named classes.  If you find a jar with those classes make sure it's part
>>>> of your classpath for you app.
>>>>
>>>> Are you making any calls like ImageIO.write(BufferedImage, "JPEG",
>>>> jpegImageFile)?
>>>>
>>>> On 06/13/2011 05:31 PM, Oscar.Flores wrote:
>>>>> ok i made a test and tell me that the class is missign but maybe what
>>>>> you
>>>>> say
>>>>> its rigth and it register the handler
>>>>> so i gonna register the services so i do this
>>>>>
>>>>>     public static void main(String[] args) throws Exception {
>>>>>             DOMConfigurator.configure("D:/Mis
>>>>> documentos/NetBeansProjects/Factura/src/factura/log4j.xml");
>>>>>             logger.info("Entering application.");
>>>>>
>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>> CLibJPEGImageReaderSpi());
>>>>>
>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>> CLibJPEGImageWriterSpi());
>>>>>
>>>>> also after register my services it telling me that the class
>>>>> CLibJPEGImageReaderSpi() and CLibJPEGImageWriterSpi() is missing but
>>>>> only
>>>>> in
>>>>> command
>>>>>
>>>>> after register mi service, something more has to be done??
>>>>>
>>>>>
>>>>> Rob Sargent-4 wrote:
>>>>>> I'm not sure I'm following correctly: does removing the xmlgraphics
>>>>>> jar
>>>>>> cause netbeans to behave the same as the command-line run of you app?
>>>>>> If
>>>>>> so, I suspect netbeans is registering services for you.  Your own code
>>>>>> will have to make a call to one of the
>>>>>> IIORegistry.registerServiceProvider() methods.
>>>>>>
>>>>>> On 06/13/2011 05:02 PM, Oscar.Flores wrote:
>>>>>>> Ok aaaa i get it, actually the ImageIO library i added because i read
>>>>>>> in
>>>>>>> the
>>>>>>> xmlgrapics that if something like the message
>>>>>>> org.apache.xmlgraphics.image.loader.ImageException: Cannot load image
>>>>>>> (no
>>>>>>> suitable loader/converter combination available)appear i have to add
>>>>>>> the
>>>>>>> jar
>>>>>>> file to the classpath but that all it say no configuration or
>>>>>>> anything,
>>>>>>> then
>>>>>>> i delete the imagenIO libs and still i have the same output in
>>>>>>> netbeans
>>>>>>> so
>>>>>>> xmlgrapics seem to have the problem in the plugins or i have to
>>>>>>> configure
>>>>>>> something
>>>>>>>
>>>>>>> Rob Sargent-4 wrote:
>>>>>>>> Then it seems to me netbeans (if it's producing good output ==
>>>>>>>> assumptionA) is still using something that the command-line isn't.
>>>>>>>>
>>>>>>>> And given assumptionA, you're java code is correct in terms of FOP
>>>>>>>> and
>>>>>>>> your configuration isn't for ImageIO.  Show your ImageIO related
>>>>>>>> code
>>>>>>>> and are you sure it's in your app.  Use the logger to show a message
>>>>>>>> when you add  your loader.  Or list all ImageIO services:
>>>>>>>> IIORegistry.getServiceProviders()
>>>>>>>>
>>>>>>>> On 06/13/2011 03:01 PM, Oscar.Flores wrote:
>>>>>>>>> ok well i put the xml in scr of my proyect i see that i still have
>>>>>>>>> the
>>>>>>>>> same
>>>>>>>>> issues of the image render of any image i dont now if the xml its
>>>>>>>>> in
>>>>>>>>> place i
>>>>>>>>> put the code down to see if something its missing
>>>>>>>>>
>>>>>>>>> 15:45:07,827 ERROR [render] Error while processing image:
>>>>>>>>> c:\cfd\nombregp.bmp (i
>>>>>>>>> mage/bmp)
>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException: Cannot load
>>>>>>>>> image
>>>>>>>>> (no
>>>>>>>>> suitab
>>>>>>>>> le loader/converter combination available) for c:\cfd\nombregp.bmp
>>>>>>>>> (image/bmp)
>>>>>>>>>              at
>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageManager.getImage(ImageManage
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> import mx.bigdata.sat.cfd.schema.Comprobante;
>>>>>>>>> import mx.bigdata.sat.cfd.CFDv2;
>>>>>>>>> import mx.bigdata.sat.security.KeyLoader;
>>>>>>>>> import org.jdom.*;
>>>>>>>>> import org.jdom.input.SAXBuilder;
>>>>>>>>> import org.jdom.output.XMLOutputter;
>>>>>>>>> import org.jdom.output.Format;
>>>>>>>>> import org.jdom.transform.JDOMSource;
>>>>>>>>> //Java
>>>>>>>>>       import java.io.File;
>>>>>>>>>       import java.io.OutputStream;
>>>>>>>>>
>>>>>>>>>       //JAXP
>>>>>>>>>       import javax.xml.transform.Transformer;
>>>>>>>>>       import javax.xml.transform.TransformerFactory;
>>>>>>>>>       import javax.xml.transform.Source;
>>>>>>>>>       import javax.xml.transform.Result;
>>>>>>>>>       import javax.xml.transform.stream.StreamSource;
>>>>>>>>>       import javax.xml.transform.sax.SAXResult;
>>>>>>>>>
>>>>>>>>>       //FOP
>>>>>>>>>       import org.apache.fop.apps.FOUserAgent;
>>>>>>>>>       import org.apache.fop.apps.Fop;
>>>>>>>>>       import org.apache.fop.apps.FopFactory;
>>>>>>>>>       import org.apache.fop.apps.MimeConstants;
>>>>>>>>>
>>>>>>>>>       //log4j
>>>>>>>>>       import org.apache.log4j.*;
>>>>>>>>>       import org.apache.log4j.xml.DOMConfigurator;
>>>>>>>>>
>>>>>>>>> public final class Main {
>>>>>>>>>          @SuppressWarnings("unchecked")
>>>>>>>>>          static Logger logger = Logger.getLogger(Main.class);
>>>>>>>>>
>>>>>>>>>          public static void main(String[] args) throws Exception {
>>>>>>>>>               DOMConfigurator.configure("D:/Mis
>>>>>>>>> documentos/NetBeansProjects/Factura/src/factura/log4j.xml");
>>>>>>>>>               logger.info("Entering application.");
>>>>>>>>>               try {
>>>>>>>>>                  File file = new File(args[0]);
>>>>>>>>>                  Comprobante comp = CFDv2.newComprobante(new
>>>>>>>>> FileInputStream(file));
>>>>>>>>>                  CFDv2 cfd = new CFDv2(comp);
>>>>>>>>>                  PrivateKey key = KeyLoader.loadPKCS8PrivateKey(new
>>>>>>>>> FileInputStream(args[1]),(args[2]));
>>>>>>>>>                  X509Certificate cert =
>>>>>>>>> KeyLoader.loadX509Certificate(new
>>>>>>>>> FileInputStream(args[3]));
>>>>>>>>>                  Comprobante sellado = cfd.sellarComprobante(key,
>>>>>>>>> cert);
>>>>>>>>>                  String cadena = cfd.getCadenaOriginal();
>>>>>>>>>                  String sello = sellado.getSello();
>>>>>>>>>                  // Creamos el builder basado en SAX
>>>>>>>>>                  SAXBuilder builder = new SAXBuilder();
>>>>>>>>>                  // Construimos el arbol DOM a partir del fichero
>>>>>>>>> xml
>>>>>>>>>                  Document documentJDOM = builder.build(new
>>>>>>>>> FileInputStream(args[0]));
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>                  Element raiz = documentJDOM.getRootElement();//toma
>>>>>>>>> el
>>>>>>>>> nodo
>>>>>>>>> raiz
>>>>>>>>> del documento.
>>>>>>>>>                  raiz.setAttribute("sello", sello);
>>>>>>>>>                  raiz.setAttribute("certificado",
>>>>>>>>> sellado.getCertificado());
>>>>>>>>>
>>>>>>>>> //System.out.println(raiz.getAttributeValue("sello"));
>>>>>>>>>
>>>>>>>>> //System.out.println(raiz.getAttributeValue("certificado"));
>>>>>>>>>                  // Recorremos los hijos de la etiqueta raíz
>>>>>>>>>                  List<Element>      hijosRaiz = raiz.getChildren();
>>>>>>>>>                  boolean Bandera=false;
>>>>>>>>>                  for(Element hijo: hijosRaiz)
>>>>>>>>>                  {
>>>>>>>>>                      // Obtenemos el nombre y su contenido de tipo
>>>>>>>>> texto
>>>>>>>>>                      String nombre = hijo.getName();
>>>>>>>>>
>>>>>>>>>                      if (nombre.equals("Addenda"))
>>>>>>>>>                      {   List<Element>      subHijo =
>>>>>>>>> hijo.getChildren();
>>>>>>>>>                          for(Element hij: subHijo)
>>>>>>>>>                              {
>>>>>>>>>                              hij.setAttribute("CadenaOriginal",
>>>>>>>>> cadena);
>>>>>>>>>                              //System.out.println("CadenaOriginal:
>>>>>>>>> "+hij.getAttributeValue("CadenaOriginal"));
>>>>>>>>>                              Bandera=true;
>>>>>>>>>                              break;
>>>>>>>>>                              }
>>>>>>>>>                      }
>>>>>>>>>                      if (Bandera)
>>>>>>>>>                      {
>>>>>>>>>                          XMLOutputter out = new
>>>>>>>>> XMLOutputter(Format.getPrettyFormat());
>>>>>>>>>                          File nuevoXML = new File(args[0]);
>>>>>>>>>                          try{
>>>>>>>>>                              FileOutputStream archivoXML= new
>>>>>>>>> FileOutputStream
>>>>>>>>> (nuevoXML);
>>>>>>>>>                              out.output(documentJDOM, archivoXML);
>>>>>>>>>
>>>>>>>>>                             }
>>>>>>>>>                          catch (Exception
>>>>>>>>> ex){System.out.println(ex.getMessage());}
>>>>>>>>>                          // Para generar el pdf a partir de un
>>>>>>>>> archivo.xsl
>>>>>>>>> y
>>>>>>>>> un
>>>>>>>>>                          // archivo.xml
>>>>>>>>>                      }
>>>>>>>>>                    }
>>>>>>>>>                // configure fopFactory as desired
>>>>>>>>>                FopFactory fopFactory = FopFactory.newInstance();
>>>>>>>>>                FOUserAgent foUserAgent =
>>>>>>>>> fopFactory.newFOUserAgent();
>>>>>>>>>
>>>>>>>>>                // configure foUserAgent as desired
>>>>>>>>>                // Setup output
>>>>>>>>>               File pdffile = new File(args[5]);
>>>>>>>>>
>>>>>>>>>               OutputStream out = new
>>>>>>>>> java.io.FileOutputStream(pdffile);
>>>>>>>>>               out = new java.io.BufferedOutputStream(out);
>>>>>>>>>               try {
>>>>>>>>>                      // Construct fop with desired output format
>>>>>>>>>                       Fop fop =
>>>>>>>>> fopFactory.newFop(MimeConstants.MIME_PDF,
>>>>>>>>> foUserAgent, out);
>>>>>>>>>                      // Setup XSLT
>>>>>>>>>                      TransformerFactory factory =
>>>>>>>>> TransformerFactory.newInstance();
>>>>>>>>>                      Transformer transformer =
>>>>>>>>> factory.newTransformer(new
>>>>>>>>> StreamSource(args[4]));
>>>>>>>>>                      // Set the value of a  in the stylesheet
>>>>>>>>>                      transformer.setParameter("versionParam",
>>>>>>>>> "2.0");
>>>>>>>>>
>>>>>>>>>                     // Setup input for XSLT transformation
>>>>>>>>>                      Source src = new JDOMSource(documentJDOM);
>>>>>>>>>                       // Resulting SAX events (the generated FO)
>>>>>>>>> must
>>>>>>>>> be
>>>>>>>>> piped
>>>>>>>>> through to FOP
>>>>>>>>>                      Result res = new
>>>>>>>>> SAXResult(fop.getDefaultHandler());
>>>>>>>>>                       // Start XSLT transformation and FOP
>>>>>>>>> processing
>>>>>>>>>                     // System.setProperty("java.awt.headless",
>>>>>>>>> "true");
>>>>>>>>>                          transformer.transform(src, res);
>>>>>>>>>                      } finally {
>>>>>>>>>                       out.close();
>>>>>>>>>                  }
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>                System.out.println("Success!");
>>>>>>>>>               } catch (Exception e) {
>>>>>>>>>                e.printStackTrace(System.err);
>>>>>>>>>                System.exit(-1);
>>>>>>>>>             }
>>>>>>>>>           logger.info("Exiting application.");
>>>>>>>>>
>>>>>>>>>        }
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>> Try this log4j.xml: Place it at the root of your jar file
>>>>>>>>>>
>>>>>>>>>> <?xml version="1.0" encoding="UTF-8"?>
>>>>>>>>>> <!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">
>>>>>>>>>>
>>>>>>>>>> <log4j:configuration
>>>>>>>>>> xmlns:log4j="http://jakarta.apache.org/log4j/"
>>>>>>>>>> debug="false">
>>>>>>>>>>
>>>>>>>>>> <appender name="CONSOLE" class="org.apache.log4j.ConsoleAppender">
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> <layout class="org.apache.log4j.PatternLayout">
>>>>>>>>>>
>>>>>>>>>> </layout>
>>>>>>>>>> </appender>
>>>>>>>>>>
>>>>>>>>>> <category name="org">
>>>>>>>>>> <priority value="DEBUG"/>
>>>>>>>>>> </category>
>>>>>>>>>> <category name="org.apache">
>>>>>>>>>> <priority value="WARN"/>
>>>>>>>>>> </category>
>>>>>>>>>> <category name="org.springframework">
>>>>>>>>>> <priority value="WARN"/>
>>>>>>>>>> </category>
>>>>>>>>>> <category name="org.hibernate">
>>>>>>>>>> <priority value="DEBUG"/>
>>>>>>>>>> </category>
>>>>>>>>>> <category name="net">
>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>> </category>
>>>>>>>>>> <category name="javax">
>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>> </category>
>>>>>>>>>> <category name="java">
>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>> </category>
>>>>>>>>>> <category name="sun">
>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>> </category>
>>>>>>>>>> <category name="org.jboss">
>>>>>>>>>> <priority value="INFO"/>
>>>>>>>>>> </category>
>>>>>>>>>> <category name="org.jboss.seam">
>>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>>> </category>
>>>>>>>>>> <root>
>>>>>>>>>> <appender-ref ref="CONSOLE"/>
>>>>>>>>>> </root>
>>>>>>>>>>
>>>>>>>>>> </log4j:configuration>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> On 06/13/2011 11:06 AM, Oscar.Flores wrote:
>>>>>>>>>>> ok i dont thik i have a configuracion file i find the code that i
>>>>>>>>>>> put
>>>>>>>>>>> in
>>>>>>>>>>> the
>>>>>>>>>>> other post i think its the basic
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>> Do you have a config file for log4j.  Usually it's in a resource
>>>>>>>>>>>> tree.
>>>>>>>>>>>> Are you copying that to your deployment? Is your ant script
>>>>>>>>>>>> including
>>>>>>>>>>>> the config file in the jar of your application?
>>>>>>>>>>>>
>>>>>>>>>>>> On 06/13/2011 10:12 AM, Oscar.Flores wrote:
>>>>>>>>>>>>> Ok yeah the log4j its having isuees to find the configuration
>>>>>>>>>>>>>
>>>>>>>>>>>>> log4j:WARN No appenders could be found for logger
>>>>>>>>>>>>> (org.apache.fop.util.ContentHandlerFactoryRegistry).
>>>>>>>>>>>>> log4j:WARN Please initialize the log4j system properly.
>>>>>>>>>>>>> log4j:WARN See
>>>>>>>>>>>>> http://logging.apache.org/log4j/1.2/faq.html#noconfig
>>>>>>>>>>>>> for
>>>>>>>>>>>>> more info.
>>>>>>>>>>>>> i go to the faq guide and it say try loading the class or
>>>>>>>>>>>>> resource
>>>>>>>>>>>>> yourself.
>>>>>>>>>>>>> If you can't find it, neither will log4j.
>>>>>>>>>>>>>
>>>>>>>>>>>>> aaa i dont know where to set this
>>>>>>>>>>>>>
>>>>>>>>>>>>> also here its my xlst
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> http://old.nabble.com/file/p31835645/FacturasOMF.xsl
>>>>>>>>>>>>> FacturasOMF.xsl
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> and the fo file that generate the editix
>>>>>>>>>>>>>
>>>>>>>>>>>>> http://old.nabble.com/file/p31835645/Prueba.fo Prueba.fo
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>> The first thing is to really dig into what you did to netbeans
>>>>>>>>>>>>>> to
>>>>>>>>>>>>>> get
>>>>>>>>>>>>>> it
>>>>>>>>>>>>>> to work...
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> I've forgotten what your stylesheet looked like, so maybe if
>>>>>>>>>>>>>> you
>>>>>>>>>>>>>> show
>>>>>>>>>>>>>> us
>>>>>>>>>>>>>> again how you're referencing your images we might notice a
>>>>>>>>>>>>>> problem.
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> It might also help to see the "fo" generated during your
>>>>>>>>>>>>>> transformation.
>>>>>>>>>>>>>> Can you grab that just after xslt and just before fop calls.
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> Are you sure there is no error being logged somewhere when you
>>>>>>>>>>>>>> run
>>>>>>>>>>>>>> from
>>>>>>>>>>>>>> the command line? (Where is log4j writing and at what level?)
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> Oscar.Flores wrote:
>>>>>>>>>>>>>>> You where absolutly rigth i miss a few libraries to add into
>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>> jar
>>>>>>>>>>>>>>> file, i
>>>>>>>>>>>>>>> modified the build.xml to add the package and jar that i
>>>>>>>>>>>>>>> need,
>>>>>>>>>>>>>>> now
>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>> error
>>>>>>>>>>>>>>> message is not there but still the images dont show in the
>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>> remeber
>>>>>>>>>>>>>>> that i do something in netbeans so they can add to the pdf
>>>>>>>>>>>>>>> but
>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>> cant
>>>>>>>>>>>>>>> remeber i dont now if there is still a library that is
>>>>>>>>>>>>>>> missing
>>>>>>>>>>>>>>> or
>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>> am
>>>>>>>>>>>>>>> adding more than it should be
>>>>>>>>>>>>>>> This is what i use :
>>>>>>>>>>>>>>> cfdi-base-0.1.6-SNAPSHOT.jar
>>>>>>>>>>>>>>> guava-r09.jar
>>>>>>>>>>>>>>> guava-r09-gwt.jar
>>>>>>>>>>>>>>> jaxb-impl-2.1.10.jar
>>>>>>>>>>>>>>> avalon-framework-api-4.3.jar
>>>>>>>>>>>>>>> avalon-framework-cvs-20020806.jar
>>>>>>>>>>>>>>> avalon-logkit-2.1.jar
>>>>>>>>>>>>>>> not-yet-commons-ssl-0.3.11.jar
>>>>>>>>>>>>>>> commons-codec-1.5.jar
>>>>>>>>>>>>>>> commons-codec-1.5-sources.jar
>>>>>>>>>>>>>>> log4j-1.2.16.jar
>>>>>>>>>>>>>>> fop.jar
>>>>>>>>>>>>>>> jdom.jar
>>>>>>>>>>>>>>> xmlgraphics-commons-1.4.jar
>>>>>>>>>>>>>>> commons-io-1.3.1.jar
>>>>>>>>>>>>>>> fop-pdf-images-2.0.1.SNAPSHOT.jar
>>>>>>>>>>>>>>> pdfbox-app-1.5.0.jar
>>>>>>>>>>>>>>> fontbox-1.3.1.jar
>>>>>>>>>>>>>>> jempbox-1.3.1.jar
>>>>>>>>>>>>>>> xercesImpl-2.7.1.jar
>>>>>>>>>>>>>>> batik-all-1.7.jar
>>>>>>>>>>>>>>> xml-apis-1.3.04.jar
>>>>>>>>>>>>>>> xml-apis-ext-1.3.04.jar
>>>>>>>>>>>>>>>         avalon-framework-4.2.0.jar
>>>>>>>>>>>>>>>         xalan-2.7.0.jar
>>>>>>>>>>>>>>>         serializer-2.7.0.jar
>>>>>>>>>>>>>>>         commons-logging-1.0.4.jar
>>>>>>>>>>>>>>>         jai_codec.jar
>>>>>>>>>>>>>>>         jai_core.jar
>>>>>>>>>>>>>>>         batik-ext.jar
>>>>>>>>>>>>>>>         jai_imageio-1.1-sources.jar
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> Thanks Rob for the help
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> I suspect running from your jar does not have/use the same
>>>>>>>>>>>>>>>> classpath
>>>>>>>>>>>>>>>> that is in effect while you're in the debugger.
>>>>>>>>>>>>>>>> By what mechanism do you generate the jar?
>>>>>>>>>>>>>>>> Is it an executable jar or are you running java -classpath
>>>>>>>>>>>>>>>> <your-jar-here:other-jars>        Main?
>>>>>>>>>>>>>>>> Make your IDE (netbeans) display the classpath  it uses to
>>>>>>>>>>>>>>>> run
>>>>>>>>>>>>>>>> your
>>>>>>>>>>>>>>>> app
>>>>>>>>>>>>>>>> and compare that with the above.
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> On 06/09/2011 07:21 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> aaa ok well my problem is that when i do the pdf in netbean
>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>> fine
>>>>>>>>>>>>>>>>> with images and evething but when i run the jar file in
>>>>>>>>>>>>>>>>> command
>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>> give
>>>>>>>>>>>>>>>>> me a
>>>>>>>>>>>>>>>>> error
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> GRAVE: Error while processing image: I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>          org.apache.xmlgraphics.image.loader.ImageException:
>>>>>>>>>>>>>>>>> Cannot
>>>>>>>>>>>>>>>>> load
>>>>>>>>>>>>>>>>>          image (no suitable loader/converter combination
>>>>>>>>>>>>>>>>> available)
>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>          (image/jpeg)
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> so i dont no what its not working and if i have to add
>>>>>>>>>>>>>>>>> something
>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>> my
>>>>>>>>>>>>>>>>> code
>>>>>>>>>>>>>>>>> so the images can load i am soooo desperate what i am doing
>>>>>>>>>>>>>>>>> wrong??
>>>>>>>>>>>>>>>>> i am sorry for the trouble and if a dont explain my self
>>>>>>>>>>>>>>>>> very
>>>>>>>>>>>>>>>>> good
>>>>>>>>>>>>>>>>> jejeje
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> Not at all sure what your problem is.  All I can do is
>>>>>>>>>>>>>>>>>> show
>>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>>> what
>>>>>>>>>>>>>>>>>> works for us.
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> Our source xml looks like this:
>>>>>>>>>>>>>>>>>> <image image-id="381623861" reference-id="ref-220"
>>>>>>>>>>>>>>>>>> width="750"
>>>>>>>>>>>>>>>>>> height="750" image-space-id="space-1" position="5"
>>>>>>>>>>>>>>>>>>                       image-pool-position="31" pos="4"
>>>>>>>>>>>>>>>>>>                       file="ref_10_1002108221">         <!--
>>>>>>>>>>>>>>>>>> an
>>>>>>>>>>>>>>>>>> actual
>>>>>>>>>>>>>>>>>> file
>>>>>>>>>>>>>>>>>> (.jpeg
>>>>>>>>>>>>>>>>>> copied the working directory of the transformer -->
>>>>>>>>>>>>>>>>>> <fields />
>>>>>>>>>>>>>>>>>> <caption />
>>>>>>>>>>>>>>>>>> <annotations>
>>>>>>>>>>>>>>>>>> <arrow_positions origHeight="750" origWidth="750" />
>>>>>>>>>>>>>>>>>> </annotations>
>>>>>>>>>>>>>>>>>> </image>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> Our xslt looks like this for each image needed.
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> <xsl:template name="image">
>>>>>>>>>>>>>>>>>> <xsl:param name="img"/>         <!-- This is the xml node
>>>>>>>>>>>>>>>>>> from
>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>> source
>>>>>>>>>>>>>>>>>> xml
>>>>>>>>>>>>>>>>>> above -->
>>>>>>>>>>>>>>>>>> <xsl:param name="width"/>
>>>>>>>>>>>>>>>>>> <xsl:param name="height" select="$width"/>
>>>>>>>>>>>>>>>>>> <xsl:param name="ignoreHeight">false</xsl:param>
>>>>>>>>>>>>>>>>>> <fo:block>
>>>>>>>>>>>>>>>>>> <fo:external-graphic src="{$img/@file}" height="{$height}"
>>>>>>>>>>>>>>>>>> width="{$width}" content-height="scale-to-fit"
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> content-width="scale-to-fit"
>>>>>>>>>>>>>>>>>> border="0.5pt solid black" border-collapse="separate">
>>>>>>>>>>>>>>>>>> <xsl:if test="$ignoreHeight != 'true'">
>>>>>>>>>>>>>>>>>> <xsl:attribute name="height">
>>>>>>>>>>>>>>>>>> <xsl:value-of select="$height"/>
>>>>>>>>>>>>>>>>>> </xsl:attribute>
>>>>>>>>>>>>>>>>>> </xsl:if>
>>>>>>>>>>>>>>>>>> </fo:external-graphic>
>>>>>>>>>>>>>>>>>> </fo:block>
>>>>>>>>>>>>>>>>>> </xsl:template>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> Our generated fo looks like this:
>>>>>>>>>>>>>>>>>> <fo:table-cell>
>>>>>>>>>>>>>>>>>> <fo:block>
>>>>>>>>>>>>>>>>>> <fo:external-graphic border-collapse="separate"
>>>>>>>>>>>>>>>>>> border="0.5pt
>>>>>>>>>>>>>>>>>> solid
>>>>>>>>>>>>>>>>>> black" content-width="scale-to-fit"
>>>>>>>>>>>>>>>>>> content-height="scale-to-fit"
>>>>>>>>>>>>>>>>>> width="2.5in" height="2.5in" src="ref_10_1002108221" />
>>>>>>>>>>>>>>>>>> </fo:block>
>>>>>>>>>>>>>>>>>> </fo:table-cell>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> And the generated pdfs include the image and are shipped
>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>> printer.
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> How does this stack up with what you have?
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> On 06/09/2011 01:19 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> Hi there well i still got the problem but searching IN
>>>>>>>>>>>>>>>>>>> INTERNET
>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>> find
>>>>>>>>>>>>>>>>>>> a
>>>>>>>>>>>>>>>>>>> JPEG
>>>>>>>>>>>>>>>>>>> renderer output for FOP its here
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> http://marc.info/?l=fop-user&m=125986752706366&w=2
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> the cuestion is can i render the image that i want to put
>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>> pdf,
>>>>>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>>>>>> then add to the xsl the render jpeg it will work??
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> and here explaints how use the render when he say uses
>>>>>>>>>>>>>>>>>>> fop
>>>>>>>>>>>>>>>>>>> as
>>>>>>>>>>>>>>>>>>> normal
>>>>>>>>>>>>>>>>>>> case
>>>>>>>>>>>>>>>>>>> what does it mean
>>>>>>>>>>>>>>>>>>> what else have to add to the code?? i hope you can help
>>>>>>>>>>>>>>>>>>> me
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> Thanks!!
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> // OutputStream out = what you want
>>>>>>>>>>>>>>>>>>>                      FopFactory fopFactory =
>>>>>>>>>>>>>>>>>>> FopFactory.newInstance();
>>>>>>>>>>>>>>>>>>>                      RendererFactory rendererFactory =
>>>>>>>>>>>>>>>>>>> null;
>>>>>>>>>>>>>>>>>>>                      FOUserAgent foUserAgent = null;
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>                      rendererFactory =
>>>>>>>>>>>>>>>>>>> fopFactory.getRendererFactory();
>>>>>>>>>>>>>>>>>>>                      rendererFactory.addRendererMaker(new
>>>>>>>>>>>>>>>>>>> MultiRendererMaker("jpeg"));
>>>>>>>>>>>>>>>>>>>                      foUserAgent =
>>>>>>>>>>>>>>>>>>> fopFactory.newFOUserAgent();
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> rendererFactory.createRenderer(foUserAgent,
>>>>>>>>>>>>>>>>>>> "image/jpeg");
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>                      Fop fop =
>>>>>>>>>>>>>>>>>>> fopFactory.newFop("image/jpeg",
>>>>>>>>>>>>>>>>>>> foUserAgent,
>>>>>>>>>>>>>>>>>>> out);
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> //Use fop as normal case
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> Since you're now into xmlgraphics, I think you're best
>>>>>>>>>>>>>>>>>>>> bet
>>>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>>>> here
>>>>>>>>>>>>>>>>>>>> <http://xmlgraphics.apache.org/commons/image-loader.html>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> On 06/07/2011 10:18 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> Hi ok this is for generate images that dont need to be
>>>>>>>>>>>>>>>>>>>>> decompress
>>>>>>>>>>>>>>>>>>>>> later??
>>>>>>>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>>>>>>>> the result image i put in my xsl ?? then it should
>>>>>>>>>>>>>>>>>>>>> work,
>>>>>>>>>>>>>>>>>>>>> aaa
>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>> change
>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>> fop
>>>>>>>>>>>>>>>>>>>>> 1.0 and xml communs 1.4 and its the same jejeje   dont
>>>>>>>>>>>>>>>>>>>>> find
>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>> image
>>>>>>>>>>>>>>>>>>>>> preload
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> org.apache.fop.fo.flow.ExternalGraphic bind
>>>>>>>>>>>>>>>>>>>>> SEVERE: Image not available: The file format is not
>>>>>>>>>>>>>>>>>>>>> supported.
>>>>>>>>>>>>>>>>>>>>> No
>>>>>>>>>>>>>>>>>>>>> ImagePreloader for *.jpg or *.bmp
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> ImageIO.write(bufferedImage, "JPEG", file);
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> On 06/07/2011 08:21 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> Ok i actually register the handler now what i have to
>>>>>>>>>>>>>>>>>>>>>>> do
>>>>>>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>>>>>>> setup
>>>>>>>>>>>>>>>>>>>>>>> this
>>>>>>>>>>>>>>>>>>>>>>> handler or not?? and how can i do that, also it seem
>>>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>> bmp
>>>>>>>>>>>>>>>>>>>>>>> its
>>>>>>>>>>>>>>>>>>>>>>> not
>>>>>>>>>>>>>>>>>>>>>>> recognice also what can i do?? thanks for the help
>>>>>>>>>>>>>>>>>>>>>>> rob
>>>>>>>>>>>>>>>>>>>>>>> also i am trying to convert the images to see if it
>>>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>>>> helps
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> On 06/06/2011 02:29 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> Hi what can be the difference between execute the
>>>>>>>>>>>>>>>>>>>>>>>>> program
>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>> netbeans
>>>>>>>>>>>>>>>>>>>>>>>>> (where
>>>>>>>>>>>>>>>>>>>>>>>>> it works and print the images and the jar in the
>>>>>>>>>>>>>>>>>>>>>>>>> console)
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> Different classes being loaded by Netbeans than the
>>>>>>>>>>>>>>>>>>>>>>>> console
>>>>>>>>>>>>>>>>>>>>>>>> app.
>>>>>>>>>>>>>>>>>>>>>>>> Get
>>>>>>>>>>>>>>>>>>>>>>>> Netbeans to show you the full classpath it's using
>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>> it's
>>>>>>>>>>>>>>>>>>>>>>>> "%classpath"
>>>>>>>>>>>>>>>>>>>>>>>> variable
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> also i tried the
>>>>>>>>>>>>>>>>>>>>>>>>> imageIO.getImageReadersBySuffix but i cant
>>>>>>>>>>>>>>>>>>>>>>>>> interpretate
>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>> data
>>>>>>>>>>>>>>>>>>>>>>>>> y.y,
>>>>>>>>>>>>>>>>>>>>>>>>> its
>>>>>>>>>>>>>>>>>>>>>>>>> that or always its true in the boolean variable,
>>>>>>>>>>>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>>>>>>>>>>>> how
>>>>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>> register
>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>> handler??
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> Talk to IIORegistry, some thing like
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>>>>>>>>>>>>> CLibJPEGImageReaderSpi());
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>>>>>>>>>>>>> CLibJPEGImageWriterSpi());
>>>>>>>>>>>>>>>>>>>>>>>> Note: those are not necessarily the services you
>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>> your
>>>>>>>>>>>>>>>>>>>>>>>> setup.
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> Thanks
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> See the javadoc on IIORegistry. With ImageIO you
>>>>>>>>>>>>>>>>>>>>>>>>>> may
>>>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>> register
>>>>>>>>>>>>>>>>>>>>>>>>>> your handler(s). What does
>>>>>>>>>>>>>>>>>>>>>>>>>> ImageIO.getImageReadersBySuffix()
>>>>>>>>>>>>>>>>>>>>>>>>>> give
>>>>>>>>>>>>>>>>>>>>>>>>>> you.
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> For certain jpegs we don't use ImageIO, rather the
>>>>>>>>>>>>>>>>>>>>>>>>>> classes
>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>> com.sun.image.codec.jpeg:
>>>>>>>>>>>>>>>>>>>>>>>>>>                      try {
>>>>>>>>>>>>>>>>>>>>>>>>>>                          FileOutputStream fos = new
>>>>>>>>>>>>>>>>>>>>>>>>>> FileOutputStream(file);
>>>>>>>>>>>>>>>>>>>>>>>>>>                          JPEGImageEncoder encoder =
>>>>>>>>>>>>>>>>>>>>>>>>>> JPEGCodec.createJPEGEncoder(fos);
>>>>>>>>>>>>>>>>>>>>>>>>>>                          JPEGEncodeParam param =
>>>>>>>>>>>>>>>>>>>>>>>>>> encoder.getDefaultJPEGEncodeParam(image.getRaster(),
>>>>>>>>>>>>>>>>>>>>>>>>>> JPEGDecodeParam.COLOR_ID_CMYK);
>>>>>>>>>>>>>>>>>>>>>>>>>>                          param.setQuality(1,
>>>>>>>>>>>>>>>>>>>>>>>>>> false);
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> encoder.encode(image.getRaster(),
>>>>>>>>>>>>>>>>>>>>>>>>>> param);
>>>>>>>>>>>>>>>>>>>>>>>>>>                          fos.close();
>>>>>>>>>>>>>>>>>>>>>>>>>>                      } catch (Throwable t) {
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> logger.debug(t.getMessage());
>>>>>>>>>>>>>>>>>>>>>>>>>>                      }
>>>>>>>>>>>>>>>>>>>>>>>>>> But generally we use ImageIO
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/06/2011 08:29 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> Yeah i think i need your help again i tried tu
>>>>>>>>>>>>>>>>>>>>>>>>>>> run
>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>> .jar
>>>>>>>>>>>>>>>>>>>>>>>>>>> file
>>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>> console it work but without images this it what
>>>>>>>>>>>>>>>>>>>>>>>>>>> appears
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> GRAVE: Error while processing image:
>>>>>>>>>>>>>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException:
>>>>>>>>>>>>>>>>>>>>>>>>>>> Cannot
>>>>>>>>>>>>>>>>>>>>>>>>>>> load
>>>>>>>>>>>>>>>>>>>>>>>>>>> image
>>>>>>>>>>>>>>>>>>>>>>>>>>> (no
>>>>>>>>>>>>>>>>>>>>>>>>>>> suitable loader/converter combination available)
>>>>>>>>>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> i tried  download the jai-imagio add to the class
>>>>>>>>>>>>>>>>>>>>>>>>>>> path
>>>>>>>>>>>>>>>>>>>>>>>>>>> but
>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>> dont
>>>>>>>>>>>>>>>>>>>>>>>>>>> work
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> Very odd.  I'm having no problems getting images
>>>>>>>>>>>>>>>>>>>>>>>>>>>> into
>>>>>>>>>>>>>>>>>>>>>>>>>>>> pdfs
>>>>>>>>>>>>>>>>>>>>>>>>>>>> using
>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-1.0.
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/03/2011 11:04 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> aaa hey thanks for the help the other day, i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> resolve
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> problem
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> changing
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> version of FOP for the 0.95beta instead of the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> 1.0,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> works
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> now
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> prints
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the image and its good, thanks and we are in
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> touch
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> if
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> anything
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> else
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fails
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> jejeje
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Nothing in the log from the transformer?
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/03/2011 09:47 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> hi there i have another problem i hope you
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> help
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> me
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> create
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> with foe has no image, it dont show any of
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> them,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> xsl
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> seems
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> be
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> rigth i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> tested with EditX and the pdf show me the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> image,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> what
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> be,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> xmlgraphics-commons-1.5svn, fop 1.0,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-pdf-images
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> 2.0.1
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Snapshot
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> render of the image but it don work please
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> help!!!
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> :,(
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> :-):confused::confused::confused::confused:=)
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> http://old.nabble.com/file/p31822059/libraries.jpeg
>>>>>>>>>>>>>>> http://old.nabble.com/file/p31822059/libraries.bmp
>>>>>>>>>>>>>>> libraries.bmp
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>> ---------------------------------------------------------------------
>>>>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>> For additional commands, e-mail:
>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>> ---------------------------------------------------------------------
>>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>>>>
>>>>>>
>>>>>>
>>>> ---------------------------------------------------------------------
>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>>
>>>>
>>>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>
>>
>>

---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Problems with FOP and image

Posted by "Oscar.Flores" <fa...@hotmail.com>.
Yeah i do the class is in jai-imageio-1.1-sources.jar, the enviroment is just
windows xp, and the bufferedImage will be the path of the image?? 

Rob Sargent-4 wrote:
> 
> Did you go through all your jars looking for  'CLibJPEGImageReaderSpi'. 
> My greatest suspicion is that you don't have all your jars lined up.  
> Which jar(s) do you think supplies these?
> 
> What is your environment: just windows or do you have any tools like
> cygwin?
> 
> The "jpegImageFile" would be the filename in your xsl the 
> external-resource.  If you're just using a file that is already in place 
> you don't have to re-write it.
> 
> 
> 
> On 06/14/2011 08:29 AM, Oscar.Flores wrote:
>> No i dont, and that weird jejeje netbeans seems to do that for me, so the
>> calls like ImageIO.write(BufferedImage, "JPEG", jpegImageFile)? do i have
>> to
>> do it in every image that i put in the pdf?? and the image is gererate
>> directly in the pdf??how can i do it??
>>
>> Rob Sargent-4 wrote:
>>> Some jar to which netbeans has access has those classes.  Look in the
>>> output of jar tvf<each of your jars>  and see if any of those has the
>>> named classes.  If you find a jar with those classes make sure it's part
>>> of your classpath for you app.
>>>
>>> Are you making any calls like ImageIO.write(BufferedImage, "JPEG",
>>> jpegImageFile)?
>>>
>>> On 06/13/2011 05:31 PM, Oscar.Flores wrote:
>>>> ok i made a test and tell me that the class is missign but maybe what
>>>> you
>>>> say
>>>> its rigth and it register the handler
>>>> so i gonna register the services so i do this
>>>>
>>>>    public static void main(String[] args) throws Exception {
>>>>            DOMConfigurator.configure("D:/Mis
>>>> documentos/NetBeansProjects/Factura/src/factura/log4j.xml");
>>>>            logger.info("Entering application.");
>>>>            
>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>> CLibJPEGImageReaderSpi());
>>>>            
>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>> CLibJPEGImageWriterSpi());
>>>>
>>>> also after register my services it telling me that the class
>>>> CLibJPEGImageReaderSpi() and CLibJPEGImageWriterSpi() is missing but
>>>> only
>>>> in
>>>> command
>>>>
>>>> after register mi service, something more has to be done??
>>>>
>>>>
>>>> Rob Sargent-4 wrote:
>>>>> I'm not sure I'm following correctly: does removing the xmlgraphics
>>>>> jar
>>>>> cause netbeans to behave the same as the command-line run of you app?
>>>>> If
>>>>> so, I suspect netbeans is registering services for you.  Your own code
>>>>> will have to make a call to one of the
>>>>> IIORegistry.registerServiceProvider() methods.
>>>>>
>>>>> On 06/13/2011 05:02 PM, Oscar.Flores wrote:
>>>>>> Ok aaaa i get it, actually the ImageIO library i added because i read
>>>>>> in
>>>>>> the
>>>>>> xmlgrapics that if something like the message
>>>>>> org.apache.xmlgraphics.image.loader.ImageException: Cannot load image
>>>>>> (no
>>>>>> suitable loader/converter combination available)appear i have to add
>>>>>> the
>>>>>> jar
>>>>>> file to the classpath but that all it say no configuration or
>>>>>> anything,
>>>>>> then
>>>>>> i delete the imagenIO libs and still i have the same output in
>>>>>> netbeans
>>>>>> so
>>>>>> xmlgrapics seem to have the problem in the plugins or i have to
>>>>>> configure
>>>>>> something
>>>>>>
>>>>>> Rob Sargent-4 wrote:
>>>>>>> Then it seems to me netbeans (if it's producing good output ==
>>>>>>> assumptionA) is still using something that the command-line isn't.
>>>>>>>
>>>>>>> And given assumptionA, you're java code is correct in terms of FOP
>>>>>>> and
>>>>>>> your configuration isn't for ImageIO.  Show your ImageIO related
>>>>>>> code
>>>>>>> and are you sure it's in your app.  Use the logger to show a message
>>>>>>> when you add  your loader.  Or list all ImageIO services:
>>>>>>> IIORegistry.getServiceProviders()
>>>>>>>
>>>>>>> On 06/13/2011 03:01 PM, Oscar.Flores wrote:
>>>>>>>> ok well i put the xml in scr of my proyect i see that i still have
>>>>>>>> the
>>>>>>>> same
>>>>>>>> issues of the image render of any image i dont now if the xml its
>>>>>>>> in
>>>>>>>> place i
>>>>>>>> put the code down to see if something its missing
>>>>>>>>
>>>>>>>> 15:45:07,827 ERROR [render] Error while processing image:
>>>>>>>> c:\cfd\nombregp.bmp (i
>>>>>>>> mage/bmp)
>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException: Cannot load
>>>>>>>> image
>>>>>>>> (no
>>>>>>>> suitab
>>>>>>>> le loader/converter combination available) for c:\cfd\nombregp.bmp
>>>>>>>> (image/bmp)
>>>>>>>>             at
>>>>>>>> org.apache.xmlgraphics.image.loader.ImageManager.getImage(ImageManage
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> import mx.bigdata.sat.cfd.schema.Comprobante;
>>>>>>>> import mx.bigdata.sat.cfd.CFDv2;
>>>>>>>> import mx.bigdata.sat.security.KeyLoader;
>>>>>>>> import org.jdom.*;
>>>>>>>> import org.jdom.input.SAXBuilder;
>>>>>>>> import org.jdom.output.XMLOutputter;
>>>>>>>> import org.jdom.output.Format;
>>>>>>>> import org.jdom.transform.JDOMSource;
>>>>>>>> //Java
>>>>>>>>      import java.io.File;
>>>>>>>>      import java.io.OutputStream;
>>>>>>>>
>>>>>>>>      //JAXP
>>>>>>>>      import javax.xml.transform.Transformer;
>>>>>>>>      import javax.xml.transform.TransformerFactory;
>>>>>>>>      import javax.xml.transform.Source;
>>>>>>>>      import javax.xml.transform.Result;
>>>>>>>>      import javax.xml.transform.stream.StreamSource;
>>>>>>>>      import javax.xml.transform.sax.SAXResult;
>>>>>>>>
>>>>>>>>      //FOP
>>>>>>>>      import org.apache.fop.apps.FOUserAgent;
>>>>>>>>      import org.apache.fop.apps.Fop;
>>>>>>>>      import org.apache.fop.apps.FopFactory;
>>>>>>>>      import org.apache.fop.apps.MimeConstants;
>>>>>>>>
>>>>>>>>      //log4j
>>>>>>>>      import org.apache.log4j.*;
>>>>>>>>      import org.apache.log4j.xml.DOMConfigurator;
>>>>>>>>
>>>>>>>> public final class Main {
>>>>>>>>         @SuppressWarnings("unchecked")
>>>>>>>>         static Logger logger = Logger.getLogger(Main.class);
>>>>>>>>
>>>>>>>>         public static void main(String[] args) throws Exception {
>>>>>>>>              DOMConfigurator.configure("D:/Mis
>>>>>>>> documentos/NetBeansProjects/Factura/src/factura/log4j.xml");
>>>>>>>>              logger.info("Entering application.");
>>>>>>>>              try {
>>>>>>>>                 File file = new File(args[0]);
>>>>>>>>                 Comprobante comp = CFDv2.newComprobante(new
>>>>>>>> FileInputStream(file));
>>>>>>>>                 CFDv2 cfd = new CFDv2(comp);
>>>>>>>>                 PrivateKey key = KeyLoader.loadPKCS8PrivateKey(new
>>>>>>>> FileInputStream(args[1]),(args[2]));
>>>>>>>>                 X509Certificate cert =
>>>>>>>> KeyLoader.loadX509Certificate(new
>>>>>>>> FileInputStream(args[3]));
>>>>>>>>                 Comprobante sellado = cfd.sellarComprobante(key,
>>>>>>>> cert);
>>>>>>>>                 String cadena = cfd.getCadenaOriginal();
>>>>>>>>                 String sello = sellado.getSello();
>>>>>>>>                 // Creamos el builder basado en SAX
>>>>>>>>                 SAXBuilder builder = new SAXBuilder();
>>>>>>>>                 // Construimos el arbol DOM a partir del fichero
>>>>>>>> xml
>>>>>>>>                 Document documentJDOM = builder.build(new
>>>>>>>> FileInputStream(args[0]));
>>>>>>>>
>>>>>>>>
>>>>>>>>                 Element raiz = documentJDOM.getRootElement();//toma
>>>>>>>> el
>>>>>>>> nodo
>>>>>>>> raiz
>>>>>>>> del documento.
>>>>>>>>                 raiz.setAttribute("sello", sello);
>>>>>>>>                 raiz.setAttribute("certificado",
>>>>>>>> sellado.getCertificado());
>>>>>>>>                
>>>>>>>> //System.out.println(raiz.getAttributeValue("sello"));
>>>>>>>>
>>>>>>>> //System.out.println(raiz.getAttributeValue("certificado"));
>>>>>>>>                 // Recorremos los hijos de la etiqueta raíz
>>>>>>>>                 List<Element>     hijosRaiz = raiz.getChildren();
>>>>>>>>                 boolean Bandera=false;
>>>>>>>>                 for(Element hijo: hijosRaiz)
>>>>>>>>                 {
>>>>>>>>                     // Obtenemos el nombre y su contenido de tipo
>>>>>>>> texto
>>>>>>>>                     String nombre = hijo.getName();
>>>>>>>>
>>>>>>>>                     if (nombre.equals("Addenda"))
>>>>>>>>                     {   List<Element>     subHijo =
>>>>>>>> hijo.getChildren();
>>>>>>>>                         for(Element hij: subHijo)
>>>>>>>>                             {
>>>>>>>>                             hij.setAttribute("CadenaOriginal",
>>>>>>>> cadena);
>>>>>>>>                             //System.out.println("CadenaOriginal:
>>>>>>>> "+hij.getAttributeValue("CadenaOriginal"));
>>>>>>>>                             Bandera=true;
>>>>>>>>                             break;
>>>>>>>>                             }
>>>>>>>>                     }
>>>>>>>>                     if (Bandera)
>>>>>>>>                     {
>>>>>>>>                         XMLOutputter out = new
>>>>>>>> XMLOutputter(Format.getPrettyFormat());
>>>>>>>>                         File nuevoXML = new File(args[0]);
>>>>>>>>                         try{
>>>>>>>>                             FileOutputStream archivoXML= new
>>>>>>>> FileOutputStream
>>>>>>>> (nuevoXML);
>>>>>>>>                             out.output(documentJDOM, archivoXML);
>>>>>>>>
>>>>>>>>                            }
>>>>>>>>                         catch (Exception
>>>>>>>> ex){System.out.println(ex.getMessage());}
>>>>>>>>                         // Para generar el pdf a partir de un
>>>>>>>> archivo.xsl
>>>>>>>> y
>>>>>>>> un
>>>>>>>>                         // archivo.xml
>>>>>>>>                     }
>>>>>>>>                   }
>>>>>>>>               // configure fopFactory as desired
>>>>>>>>               FopFactory fopFactory = FopFactory.newInstance();
>>>>>>>>               FOUserAgent foUserAgent =
>>>>>>>> fopFactory.newFOUserAgent();
>>>>>>>>
>>>>>>>>               // configure foUserAgent as desired
>>>>>>>>               // Setup output
>>>>>>>>              File pdffile = new File(args[5]);
>>>>>>>>
>>>>>>>>              OutputStream out = new
>>>>>>>> java.io.FileOutputStream(pdffile);
>>>>>>>>              out = new java.io.BufferedOutputStream(out);
>>>>>>>>              try {
>>>>>>>>                     // Construct fop with desired output format
>>>>>>>>                      Fop fop =
>>>>>>>> fopFactory.newFop(MimeConstants.MIME_PDF,
>>>>>>>> foUserAgent, out);
>>>>>>>>                     // Setup XSLT
>>>>>>>>                     TransformerFactory factory =
>>>>>>>> TransformerFactory.newInstance();
>>>>>>>>                     Transformer transformer =
>>>>>>>> factory.newTransformer(new
>>>>>>>> StreamSource(args[4]));
>>>>>>>>                     // Set the value of a  in the stylesheet
>>>>>>>>                     transformer.setParameter("versionParam",
>>>>>>>> "2.0");
>>>>>>>>
>>>>>>>>                    // Setup input for XSLT transformation
>>>>>>>>                     Source src = new JDOMSource(documentJDOM);
>>>>>>>>                      // Resulting SAX events (the generated FO)
>>>>>>>> must
>>>>>>>> be
>>>>>>>> piped
>>>>>>>> through to FOP
>>>>>>>>                     Result res = new
>>>>>>>> SAXResult(fop.getDefaultHandler());
>>>>>>>>                      // Start XSLT transformation and FOP
>>>>>>>> processing
>>>>>>>>                    // System.setProperty("java.awt.headless",
>>>>>>>> "true");
>>>>>>>>                         transformer.transform(src, res);
>>>>>>>>                     } finally {
>>>>>>>>                      out.close();
>>>>>>>>                 }
>>>>>>>>
>>>>>>>>
>>>>>>>>               System.out.println("Success!");
>>>>>>>>              } catch (Exception e) {
>>>>>>>>               e.printStackTrace(System.err);
>>>>>>>>               System.exit(-1);
>>>>>>>>            }
>>>>>>>>          logger.info("Exiting application.");
>>>>>>>>
>>>>>>>>       }
>>>>>>>>
>>>>>>>>
>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>> Try this log4j.xml: Place it at the root of your jar file
>>>>>>>>>
>>>>>>>>> <?xml version="1.0" encoding="UTF-8"?>
>>>>>>>>> <!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">
>>>>>>>>>
>>>>>>>>> <log4j:configuration
>>>>>>>>> xmlns:log4j="http://jakarta.apache.org/log4j/"
>>>>>>>>> debug="false">
>>>>>>>>>
>>>>>>>>> <appender name="CONSOLE" class="org.apache.log4j.ConsoleAppender">
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> <layout class="org.apache.log4j.PatternLayout">
>>>>>>>>>
>>>>>>>>> </layout>
>>>>>>>>> </appender>
>>>>>>>>>
>>>>>>>>> <category name="org">
>>>>>>>>> <priority value="DEBUG"/>
>>>>>>>>> </category>
>>>>>>>>> <category name="org.apache">
>>>>>>>>> <priority value="WARN"/>
>>>>>>>>> </category>
>>>>>>>>> <category name="org.springframework">
>>>>>>>>> <priority value="WARN"/>
>>>>>>>>> </category>
>>>>>>>>> <category name="org.hibernate">
>>>>>>>>> <priority value="DEBUG"/>
>>>>>>>>> </category>
>>>>>>>>> <category name="net">
>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>> </category>
>>>>>>>>> <category name="javax">
>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>> </category>
>>>>>>>>> <category name="java">
>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>> </category>
>>>>>>>>> <category name="sun">
>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>> </category>
>>>>>>>>> <category name="org.jboss">
>>>>>>>>> <priority value="INFO"/>
>>>>>>>>> </category>
>>>>>>>>> <category name="org.jboss.seam">
>>>>>>>>> <priority value="ERROR"/>
>>>>>>>>> </category>
>>>>>>>>> <root>
>>>>>>>>> <appender-ref ref="CONSOLE"/>
>>>>>>>>> </root>
>>>>>>>>>
>>>>>>>>> </log4j:configuration>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> On 06/13/2011 11:06 AM, Oscar.Flores wrote:
>>>>>>>>>> ok i dont thik i have a configuracion file i find the code that i
>>>>>>>>>> put
>>>>>>>>>> in
>>>>>>>>>> the
>>>>>>>>>> other post i think its the basic
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>> Do you have a config file for log4j.  Usually it's in a resource
>>>>>>>>>>> tree.
>>>>>>>>>>> Are you copying that to your deployment? Is your ant script
>>>>>>>>>>> including
>>>>>>>>>>> the config file in the jar of your application?
>>>>>>>>>>>
>>>>>>>>>>> On 06/13/2011 10:12 AM, Oscar.Flores wrote:
>>>>>>>>>>>> Ok yeah the log4j its having isuees to find the configuration
>>>>>>>>>>>>
>>>>>>>>>>>> log4j:WARN No appenders could be found for logger
>>>>>>>>>>>> (org.apache.fop.util.ContentHandlerFactoryRegistry).
>>>>>>>>>>>> log4j:WARN Please initialize the log4j system properly.
>>>>>>>>>>>> log4j:WARN See
>>>>>>>>>>>> http://logging.apache.org/log4j/1.2/faq.html#noconfig
>>>>>>>>>>>> for
>>>>>>>>>>>> more info.
>>>>>>>>>>>> i go to the faq guide and it say try loading the class or
>>>>>>>>>>>> resource
>>>>>>>>>>>> yourself.
>>>>>>>>>>>> If you can't find it, neither will log4j.
>>>>>>>>>>>>
>>>>>>>>>>>> aaa i dont know where to set this
>>>>>>>>>>>>
>>>>>>>>>>>> also here its my xlst
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> http://old.nabble.com/file/p31835645/FacturasOMF.xsl
>>>>>>>>>>>> FacturasOMF.xsl
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> and the fo file that generate the editix
>>>>>>>>>>>>
>>>>>>>>>>>> http://old.nabble.com/file/p31835645/Prueba.fo Prueba.fo
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>> The first thing is to really dig into what you did to netbeans
>>>>>>>>>>>>> to
>>>>>>>>>>>>> get
>>>>>>>>>>>>> it
>>>>>>>>>>>>> to work...
>>>>>>>>>>>>>
>>>>>>>>>>>>> I've forgotten what your stylesheet looked like, so maybe if
>>>>>>>>>>>>> you
>>>>>>>>>>>>> show
>>>>>>>>>>>>> us
>>>>>>>>>>>>> again how you're referencing your images we might notice a
>>>>>>>>>>>>> problem.
>>>>>>>>>>>>>
>>>>>>>>>>>>> It might also help to see the "fo" generated during your
>>>>>>>>>>>>> transformation.
>>>>>>>>>>>>> Can you grab that just after xslt and just before fop calls.
>>>>>>>>>>>>>
>>>>>>>>>>>>> Are you sure there is no error being logged somewhere when you
>>>>>>>>>>>>> run
>>>>>>>>>>>>> from
>>>>>>>>>>>>> the command line? (Where is log4j writing and at what level?)
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> Oscar.Flores wrote:
>>>>>>>>>>>>>> You where absolutly rigth i miss a few libraries to add into
>>>>>>>>>>>>>> the
>>>>>>>>>>>>>> jar
>>>>>>>>>>>>>> file, i
>>>>>>>>>>>>>> modified the build.xml to add the package and jar that i
>>>>>>>>>>>>>> need,
>>>>>>>>>>>>>> now
>>>>>>>>>>>>>> the
>>>>>>>>>>>>>> error
>>>>>>>>>>>>>> message is not there but still the images dont show in the
>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>> i
>>>>>>>>>>>>>> remeber
>>>>>>>>>>>>>> that i do something in netbeans so they can add to the pdf
>>>>>>>>>>>>>> but
>>>>>>>>>>>>>> i
>>>>>>>>>>>>>> cant
>>>>>>>>>>>>>> remeber i dont now if there is still a library that is
>>>>>>>>>>>>>> missing
>>>>>>>>>>>>>> or
>>>>>>>>>>>>>> i
>>>>>>>>>>>>>> am
>>>>>>>>>>>>>> adding more than it should be
>>>>>>>>>>>>>> This is what i use :
>>>>>>>>>>>>>> cfdi-base-0.1.6-SNAPSHOT.jar
>>>>>>>>>>>>>> guava-r09.jar
>>>>>>>>>>>>>> guava-r09-gwt.jar
>>>>>>>>>>>>>> jaxb-impl-2.1.10.jar
>>>>>>>>>>>>>> avalon-framework-api-4.3.jar
>>>>>>>>>>>>>> avalon-framework-cvs-20020806.jar
>>>>>>>>>>>>>> avalon-logkit-2.1.jar
>>>>>>>>>>>>>> not-yet-commons-ssl-0.3.11.jar
>>>>>>>>>>>>>> commons-codec-1.5.jar
>>>>>>>>>>>>>> commons-codec-1.5-sources.jar
>>>>>>>>>>>>>> log4j-1.2.16.jar
>>>>>>>>>>>>>> fop.jar
>>>>>>>>>>>>>> jdom.jar
>>>>>>>>>>>>>> xmlgraphics-commons-1.4.jar
>>>>>>>>>>>>>> commons-io-1.3.1.jar
>>>>>>>>>>>>>> fop-pdf-images-2.0.1.SNAPSHOT.jar
>>>>>>>>>>>>>> pdfbox-app-1.5.0.jar
>>>>>>>>>>>>>> fontbox-1.3.1.jar
>>>>>>>>>>>>>> jempbox-1.3.1.jar
>>>>>>>>>>>>>> xercesImpl-2.7.1.jar
>>>>>>>>>>>>>> batik-all-1.7.jar
>>>>>>>>>>>>>> xml-apis-1.3.04.jar
>>>>>>>>>>>>>> xml-apis-ext-1.3.04.jar
>>>>>>>>>>>>>>        avalon-framework-4.2.0.jar
>>>>>>>>>>>>>>        xalan-2.7.0.jar
>>>>>>>>>>>>>>        serializer-2.7.0.jar
>>>>>>>>>>>>>>        commons-logging-1.0.4.jar
>>>>>>>>>>>>>>        jai_codec.jar
>>>>>>>>>>>>>>        jai_core.jar
>>>>>>>>>>>>>>        batik-ext.jar
>>>>>>>>>>>>>>        jai_imageio-1.1-sources.jar
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> Thanks Rob for the help
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> I suspect running from your jar does not have/use the same
>>>>>>>>>>>>>>> classpath
>>>>>>>>>>>>>>> that is in effect while you're in the debugger.
>>>>>>>>>>>>>>> By what mechanism do you generate the jar?
>>>>>>>>>>>>>>> Is it an executable jar or are you running java -classpath
>>>>>>>>>>>>>>> <your-jar-here:other-jars>       Main?
>>>>>>>>>>>>>>> Make your IDE (netbeans) display the classpath  it uses to
>>>>>>>>>>>>>>> run
>>>>>>>>>>>>>>> your
>>>>>>>>>>>>>>> app
>>>>>>>>>>>>>>> and compare that with the above.
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> On 06/09/2011 07:21 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> aaa ok well my problem is that when i do the pdf in netbean
>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>> fine
>>>>>>>>>>>>>>>> with images and evething but when i run the jar file in
>>>>>>>>>>>>>>>> command
>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>> give
>>>>>>>>>>>>>>>> me a
>>>>>>>>>>>>>>>> error
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> GRAVE: Error while processing image: I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>         org.apache.xmlgraphics.image.loader.ImageException:
>>>>>>>>>>>>>>>> Cannot
>>>>>>>>>>>>>>>> load
>>>>>>>>>>>>>>>>         image (no suitable loader/converter combination
>>>>>>>>>>>>>>>> available)
>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>         (image/jpeg)
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> so i dont no what its not working and if i have to add
>>>>>>>>>>>>>>>> something
>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>> my
>>>>>>>>>>>>>>>> code
>>>>>>>>>>>>>>>> so the images can load i am soooo desperate what i am doing
>>>>>>>>>>>>>>>> wrong??
>>>>>>>>>>>>>>>> i am sorry for the trouble and if a dont explain my self
>>>>>>>>>>>>>>>> very
>>>>>>>>>>>>>>>> good
>>>>>>>>>>>>>>>> jejeje
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> Not at all sure what your problem is.  All I can do is
>>>>>>>>>>>>>>>>> show
>>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>>> what
>>>>>>>>>>>>>>>>> works for us.
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> Our source xml looks like this:
>>>>>>>>>>>>>>>>> <image image-id="381623861" reference-id="ref-220"
>>>>>>>>>>>>>>>>> width="750"
>>>>>>>>>>>>>>>>> height="750" image-space-id="space-1" position="5"
>>>>>>>>>>>>>>>>>                      image-pool-position="31" pos="4"
>>>>>>>>>>>>>>>>>                      file="ref_10_1002108221">        <!--
>>>>>>>>>>>>>>>>> an
>>>>>>>>>>>>>>>>> actual
>>>>>>>>>>>>>>>>> file
>>>>>>>>>>>>>>>>> (.jpeg
>>>>>>>>>>>>>>>>> copied the working directory of the transformer -->
>>>>>>>>>>>>>>>>> <fields />
>>>>>>>>>>>>>>>>> <caption />
>>>>>>>>>>>>>>>>> <annotations>
>>>>>>>>>>>>>>>>> <arrow_positions origHeight="750" origWidth="750" />
>>>>>>>>>>>>>>>>> </annotations>
>>>>>>>>>>>>>>>>> </image>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> Our xslt looks like this for each image needed.
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> <xsl:template name="image">
>>>>>>>>>>>>>>>>> <xsl:param name="img"/>        <!-- This is the xml node
>>>>>>>>>>>>>>>>> from
>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>> source
>>>>>>>>>>>>>>>>> xml
>>>>>>>>>>>>>>>>> above -->
>>>>>>>>>>>>>>>>> <xsl:param name="width"/>
>>>>>>>>>>>>>>>>> <xsl:param name="height" select="$width"/>
>>>>>>>>>>>>>>>>> <xsl:param name="ignoreHeight">false</xsl:param>
>>>>>>>>>>>>>>>>> <fo:block>
>>>>>>>>>>>>>>>>> <fo:external-graphic src="{$img/@file}" height="{$height}"
>>>>>>>>>>>>>>>>> width="{$width}" content-height="scale-to-fit"
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> content-width="scale-to-fit"
>>>>>>>>>>>>>>>>> border="0.5pt solid black" border-collapse="separate">
>>>>>>>>>>>>>>>>> <xsl:if test="$ignoreHeight != 'true'">
>>>>>>>>>>>>>>>>> <xsl:attribute name="height">
>>>>>>>>>>>>>>>>> <xsl:value-of select="$height"/>
>>>>>>>>>>>>>>>>> </xsl:attribute>
>>>>>>>>>>>>>>>>> </xsl:if>
>>>>>>>>>>>>>>>>> </fo:external-graphic>
>>>>>>>>>>>>>>>>> </fo:block>
>>>>>>>>>>>>>>>>> </xsl:template>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> Our generated fo looks like this:
>>>>>>>>>>>>>>>>> <fo:table-cell>
>>>>>>>>>>>>>>>>> <fo:block>
>>>>>>>>>>>>>>>>> <fo:external-graphic border-collapse="separate"
>>>>>>>>>>>>>>>>> border="0.5pt
>>>>>>>>>>>>>>>>> solid
>>>>>>>>>>>>>>>>> black" content-width="scale-to-fit"
>>>>>>>>>>>>>>>>> content-height="scale-to-fit"
>>>>>>>>>>>>>>>>> width="2.5in" height="2.5in" src="ref_10_1002108221" />
>>>>>>>>>>>>>>>>> </fo:block>
>>>>>>>>>>>>>>>>> </fo:table-cell>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> And the generated pdfs include the image and are shipped
>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>> printer.
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> How does this stack up with what you have?
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> On 06/09/2011 01:19 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> Hi there well i still got the problem but searching IN
>>>>>>>>>>>>>>>>>> INTERNET
>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>> find
>>>>>>>>>>>>>>>>>> a
>>>>>>>>>>>>>>>>>> JPEG
>>>>>>>>>>>>>>>>>> renderer output for FOP its here
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> http://marc.info/?l=fop-user&m=125986752706366&w=2
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> the cuestion is can i render the image that i want to put
>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>> pdf,
>>>>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>>>>> then add to the xsl the render jpeg it will work??
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> and here explaints how use the render when he say uses
>>>>>>>>>>>>>>>>>> fop
>>>>>>>>>>>>>>>>>> as
>>>>>>>>>>>>>>>>>> normal
>>>>>>>>>>>>>>>>>> case
>>>>>>>>>>>>>>>>>> what does it mean
>>>>>>>>>>>>>>>>>> what else have to add to the code?? i hope you can help
>>>>>>>>>>>>>>>>>> me
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> Thanks!!
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> // OutputStream out = what you want
>>>>>>>>>>>>>>>>>>                     FopFactory fopFactory =
>>>>>>>>>>>>>>>>>> FopFactory.newInstance();
>>>>>>>>>>>>>>>>>>                     RendererFactory rendererFactory =
>>>>>>>>>>>>>>>>>> null;
>>>>>>>>>>>>>>>>>>                     FOUserAgent foUserAgent = null;
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>                     rendererFactory =
>>>>>>>>>>>>>>>>>> fopFactory.getRendererFactory();
>>>>>>>>>>>>>>>>>>                     rendererFactory.addRendererMaker(new
>>>>>>>>>>>>>>>>>> MultiRendererMaker("jpeg"));
>>>>>>>>>>>>>>>>>>                     foUserAgent =
>>>>>>>>>>>>>>>>>> fopFactory.newFOUserAgent();
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> rendererFactory.createRenderer(foUserAgent,
>>>>>>>>>>>>>>>>>> "image/jpeg");
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>                     Fop fop =
>>>>>>>>>>>>>>>>>> fopFactory.newFop("image/jpeg",
>>>>>>>>>>>>>>>>>> foUserAgent,
>>>>>>>>>>>>>>>>>> out);
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> //Use fop as normal case
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> Since you're now into xmlgraphics, I think you're best
>>>>>>>>>>>>>>>>>>> bet
>>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>>> here
>>>>>>>>>>>>>>>>>>> <http://xmlgraphics.apache.org/commons/image-loader.html>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> On 06/07/2011 10:18 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> Hi ok this is for generate images that dont need to be
>>>>>>>>>>>>>>>>>>>> decompress
>>>>>>>>>>>>>>>>>>>> later??
>>>>>>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>>>>>>> the result image i put in my xsl ?? then it should
>>>>>>>>>>>>>>>>>>>> work,
>>>>>>>>>>>>>>>>>>>> aaa
>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>> change
>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>> fop
>>>>>>>>>>>>>>>>>>>> 1.0 and xml communs 1.4 and its the same jejeje   dont
>>>>>>>>>>>>>>>>>>>> find
>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>> image
>>>>>>>>>>>>>>>>>>>> preload
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> org.apache.fop.fo.flow.ExternalGraphic bind
>>>>>>>>>>>>>>>>>>>> SEVERE: Image not available: The file format is not
>>>>>>>>>>>>>>>>>>>> supported.
>>>>>>>>>>>>>>>>>>>> No
>>>>>>>>>>>>>>>>>>>> ImagePreloader for *.jpg or *.bmp
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> ImageIO.write(bufferedImage, "JPEG", file);
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> On 06/07/2011 08:21 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> Ok i actually register the handler now what i have to
>>>>>>>>>>>>>>>>>>>>>> do
>>>>>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>>>>>> setup
>>>>>>>>>>>>>>>>>>>>>> this
>>>>>>>>>>>>>>>>>>>>>> handler or not?? and how can i do that, also it seem
>>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>> bmp
>>>>>>>>>>>>>>>>>>>>>> its
>>>>>>>>>>>>>>>>>>>>>> not
>>>>>>>>>>>>>>>>>>>>>> recognice also what can i do?? thanks for the help
>>>>>>>>>>>>>>>>>>>>>> rob
>>>>>>>>>>>>>>>>>>>>>> also i am trying to convert the images to see if it
>>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>>> helps
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> On 06/06/2011 02:29 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> Hi what can be the difference between execute the
>>>>>>>>>>>>>>>>>>>>>>>> program
>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>> netbeans
>>>>>>>>>>>>>>>>>>>>>>>> (where
>>>>>>>>>>>>>>>>>>>>>>>> it works and print the images and the jar in the
>>>>>>>>>>>>>>>>>>>>>>>> console)
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> Different classes being loaded by Netbeans than the
>>>>>>>>>>>>>>>>>>>>>>> console
>>>>>>>>>>>>>>>>>>>>>>> app.
>>>>>>>>>>>>>>>>>>>>>>> Get
>>>>>>>>>>>>>>>>>>>>>>> Netbeans to show you the full classpath it's using
>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>> it's
>>>>>>>>>>>>>>>>>>>>>>> "%classpath"
>>>>>>>>>>>>>>>>>>>>>>> variable
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> also i tried the
>>>>>>>>>>>>>>>>>>>>>>>> imageIO.getImageReadersBySuffix but i cant
>>>>>>>>>>>>>>>>>>>>>>>> interpretate
>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>> data
>>>>>>>>>>>>>>>>>>>>>>>> y.y,
>>>>>>>>>>>>>>>>>>>>>>>> its
>>>>>>>>>>>>>>>>>>>>>>>> that or always its true in the boolean variable,
>>>>>>>>>>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>>>>>>>>>>> how
>>>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>> register
>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>> handler??
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> Talk to IIORegistry, some thing like
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>>>>>>>>>>>> CLibJPEGImageReaderSpi());
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>>>>>>>>>>>> CLibJPEGImageWriterSpi());
>>>>>>>>>>>>>>>>>>>>>>> Note: those are not necessarily the services you
>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>> your
>>>>>>>>>>>>>>>>>>>>>>> setup.
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> Thanks
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> See the javadoc on IIORegistry. With ImageIO you
>>>>>>>>>>>>>>>>>>>>>>>>> may
>>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>> register
>>>>>>>>>>>>>>>>>>>>>>>>> your handler(s). What does
>>>>>>>>>>>>>>>>>>>>>>>>> ImageIO.getImageReadersBySuffix()
>>>>>>>>>>>>>>>>>>>>>>>>> give
>>>>>>>>>>>>>>>>>>>>>>>>> you.
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> For certain jpegs we don't use ImageIO, rather the
>>>>>>>>>>>>>>>>>>>>>>>>> classes
>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>> com.sun.image.codec.jpeg:
>>>>>>>>>>>>>>>>>>>>>>>>>                     try {
>>>>>>>>>>>>>>>>>>>>>>>>>                         FileOutputStream fos = new
>>>>>>>>>>>>>>>>>>>>>>>>> FileOutputStream(file);
>>>>>>>>>>>>>>>>>>>>>>>>>                         JPEGImageEncoder encoder =
>>>>>>>>>>>>>>>>>>>>>>>>> JPEGCodec.createJPEGEncoder(fos);
>>>>>>>>>>>>>>>>>>>>>>>>>                         JPEGEncodeParam param =
>>>>>>>>>>>>>>>>>>>>>>>>> encoder.getDefaultJPEGEncodeParam(image.getRaster(),
>>>>>>>>>>>>>>>>>>>>>>>>> JPEGDecodeParam.COLOR_ID_CMYK);
>>>>>>>>>>>>>>>>>>>>>>>>>                         param.setQuality(1,
>>>>>>>>>>>>>>>>>>>>>>>>> false);
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> encoder.encode(image.getRaster(),
>>>>>>>>>>>>>>>>>>>>>>>>> param);
>>>>>>>>>>>>>>>>>>>>>>>>>                         fos.close();
>>>>>>>>>>>>>>>>>>>>>>>>>                     } catch (Throwable t) {
>>>>>>>>>>>>>>>>>>>>>>>>>                        
>>>>>>>>>>>>>>>>>>>>>>>>> logger.debug(t.getMessage());
>>>>>>>>>>>>>>>>>>>>>>>>>                     }
>>>>>>>>>>>>>>>>>>>>>>>>> But generally we use ImageIO
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> On 06/06/2011 08:29 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> Yeah i think i need your help again i tried tu
>>>>>>>>>>>>>>>>>>>>>>>>>> run
>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>> .jar
>>>>>>>>>>>>>>>>>>>>>>>>>> file
>>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>> console it work but without images this it what
>>>>>>>>>>>>>>>>>>>>>>>>>> appears
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> GRAVE: Error while processing image:
>>>>>>>>>>>>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException:
>>>>>>>>>>>>>>>>>>>>>>>>>> Cannot
>>>>>>>>>>>>>>>>>>>>>>>>>> load
>>>>>>>>>>>>>>>>>>>>>>>>>> image
>>>>>>>>>>>>>>>>>>>>>>>>>> (no
>>>>>>>>>>>>>>>>>>>>>>>>>> suitable loader/converter combination available)
>>>>>>>>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> i tried  download the jai-imagio add to the class
>>>>>>>>>>>>>>>>>>>>>>>>>> path
>>>>>>>>>>>>>>>>>>>>>>>>>> but
>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>> dont
>>>>>>>>>>>>>>>>>>>>>>>>>> work
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> Very odd.  I'm having no problems getting images
>>>>>>>>>>>>>>>>>>>>>>>>>>> into
>>>>>>>>>>>>>>>>>>>>>>>>>>> pdfs
>>>>>>>>>>>>>>>>>>>>>>>>>>> using
>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-1.0.
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/03/2011 11:04 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> aaa hey thanks for the help the other day, i
>>>>>>>>>>>>>>>>>>>>>>>>>>>> resolve
>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>> problem
>>>>>>>>>>>>>>>>>>>>>>>>>>>> changing
>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>> version of FOP for the 0.95beta instead of the
>>>>>>>>>>>>>>>>>>>>>>>>>>>> 1.0,
>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>> works
>>>>>>>>>>>>>>>>>>>>>>>>>>>> now
>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>> prints
>>>>>>>>>>>>>>>>>>>>>>>>>>>> the image and its good, thanks and we are in
>>>>>>>>>>>>>>>>>>>>>>>>>>>> touch
>>>>>>>>>>>>>>>>>>>>>>>>>>>> if
>>>>>>>>>>>>>>>>>>>>>>>>>>>> anything
>>>>>>>>>>>>>>>>>>>>>>>>>>>> else
>>>>>>>>>>>>>>>>>>>>>>>>>>>> fails
>>>>>>>>>>>>>>>>>>>>>>>>>>>> jejeje
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Nothing in the log from the transformer?
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/03/2011 09:47 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> hi there i have another problem i hope you
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> help
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> me
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> create
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> with foe has no image, it dont show any of
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> them,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> xsl
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> seems
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> be
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> rigth i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> tested with EditX and the pdf show me the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> image,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> what
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> be,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> xmlgraphics-commons-1.5svn, fop 1.0,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-pdf-images
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> 2.0.1
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Snapshot
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> render of the image but it don work please
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> help!!!
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> :,(
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> :-):confused::confused::confused::confused:=)
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>> http://old.nabble.com/file/p31822059/libraries.jpeg
>>>>>>>>>>>>>> http://old.nabble.com/file/p31822059/libraries.bmp
>>>>>>>>>>>>>> libraries.bmp
>>>>>>>>>>>>>>
>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>> For additional commands, e-mail:
>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>> ---------------------------------------------------------------------
>>>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>> For additional commands, e-mail:
>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>
>>>>>>>
>>>>>>>
>>>>> ---------------------------------------------------------------------
>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>>>
>>>>>
>>>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>
>>>
>>>
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
> 
> 
> 

-- 
View this message in context: http://old.nabble.com/Problems-with-FOP-and-image-tp31766430p31844725.html
Sent from the FOP - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Problems with FOP and image

Posted by Rob Sargent <rs...@xmission.com>.
Did you go through all your jars looking for  'CLibJPEGImageReaderSpi'. 
My greatest suspicion is that you don't have all your jars lined up.  
Which jar(s) do you think supplies these?

What is your environment: just windows or do you have any tools like cygwin?

The "jpegImageFile" would be the filename in your xsl the 
external-resource.  If you're just using a file that is already in place 
you don't have to re-write it.



On 06/14/2011 08:29 AM, Oscar.Flores wrote:
> No i dont, and that weird jejeje netbeans seems to do that for me, so the
> calls like ImageIO.write(BufferedImage, "JPEG", jpegImageFile)? do i have to
> do it in every image that i put in the pdf?? and the image is gererate
> directly in the pdf??how can i do it??
>
> Rob Sargent-4 wrote:
>> Some jar to which netbeans has access has those classes.  Look in the
>> output of jar tvf<each of your jars>  and see if any of those has the
>> named classes.  If you find a jar with those classes make sure it's part
>> of your classpath for you app.
>>
>> Are you making any calls like ImageIO.write(BufferedImage, "JPEG",
>> jpegImageFile)?
>>
>> On 06/13/2011 05:31 PM, Oscar.Flores wrote:
>>> ok i made a test and tell me that the class is missign but maybe what you
>>> say
>>> its rigth and it register the handler
>>> so i gonna register the services so i do this
>>>
>>>    public static void main(String[] args) throws Exception {
>>>            DOMConfigurator.configure("D:/Mis
>>> documentos/NetBeansProjects/Factura/src/factura/log4j.xml");
>>>            logger.info("Entering application.");
>>>             IIORegistry.getDefaultInstance().registerServiceProvider(new
>>> CLibJPEGImageReaderSpi());
>>>             IIORegistry.getDefaultInstance().registerServiceProvider(new
>>> CLibJPEGImageWriterSpi());
>>>
>>> also after register my services it telling me that the class
>>> CLibJPEGImageReaderSpi() and CLibJPEGImageWriterSpi() is missing but only
>>> in
>>> command
>>>
>>> after register mi service, something more has to be done??
>>>
>>>
>>> Rob Sargent-4 wrote:
>>>> I'm not sure I'm following correctly: does removing the xmlgraphics jar
>>>> cause netbeans to behave the same as the command-line run of you app? If
>>>> so, I suspect netbeans is registering services for you.  Your own code
>>>> will have to make a call to one of the
>>>> IIORegistry.registerServiceProvider() methods.
>>>>
>>>> On 06/13/2011 05:02 PM, Oscar.Flores wrote:
>>>>> Ok aaaa i get it, actually the ImageIO library i added because i read
>>>>> in
>>>>> the
>>>>> xmlgrapics that if something like the message
>>>>> org.apache.xmlgraphics.image.loader.ImageException: Cannot load image
>>>>> (no
>>>>> suitable loader/converter combination available)appear i have to add
>>>>> the
>>>>> jar
>>>>> file to the classpath but that all it say no configuration or anything,
>>>>> then
>>>>> i delete the imagenIO libs and still i have the same output in netbeans
>>>>> so
>>>>> xmlgrapics seem to have the problem in the plugins or i have to
>>>>> configure
>>>>> something
>>>>>
>>>>> Rob Sargent-4 wrote:
>>>>>> Then it seems to me netbeans (if it's producing good output ==
>>>>>> assumptionA) is still using something that the command-line isn't.
>>>>>>
>>>>>> And given assumptionA, you're java code is correct in terms of FOP and
>>>>>> your configuration isn't for ImageIO.  Show your ImageIO related code
>>>>>> and are you sure it's in your app.  Use the logger to show a message
>>>>>> when you add  your loader.  Or list all ImageIO services:
>>>>>> IIORegistry.getServiceProviders()
>>>>>>
>>>>>> On 06/13/2011 03:01 PM, Oscar.Flores wrote:
>>>>>>> ok well i put the xml in scr of my proyect i see that i still have
>>>>>>> the
>>>>>>> same
>>>>>>> issues of the image render of any image i dont now if the xml its in
>>>>>>> place i
>>>>>>> put the code down to see if something its missing
>>>>>>>
>>>>>>> 15:45:07,827 ERROR [render] Error while processing image:
>>>>>>> c:\cfd\nombregp.bmp (i
>>>>>>> mage/bmp)
>>>>>>> org.apache.xmlgraphics.image.loader.ImageException: Cannot load image
>>>>>>> (no
>>>>>>> suitab
>>>>>>> le loader/converter combination available) for c:\cfd\nombregp.bmp
>>>>>>> (image/bmp)
>>>>>>>             at
>>>>>>> org.apache.xmlgraphics.image.loader.ImageManager.getImage(ImageManage
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> import mx.bigdata.sat.cfd.schema.Comprobante;
>>>>>>> import mx.bigdata.sat.cfd.CFDv2;
>>>>>>> import mx.bigdata.sat.security.KeyLoader;
>>>>>>> import org.jdom.*;
>>>>>>> import org.jdom.input.SAXBuilder;
>>>>>>> import org.jdom.output.XMLOutputter;
>>>>>>> import org.jdom.output.Format;
>>>>>>> import org.jdom.transform.JDOMSource;
>>>>>>> //Java
>>>>>>>      import java.io.File;
>>>>>>>      import java.io.OutputStream;
>>>>>>>
>>>>>>>      //JAXP
>>>>>>>      import javax.xml.transform.Transformer;
>>>>>>>      import javax.xml.transform.TransformerFactory;
>>>>>>>      import javax.xml.transform.Source;
>>>>>>>      import javax.xml.transform.Result;
>>>>>>>      import javax.xml.transform.stream.StreamSource;
>>>>>>>      import javax.xml.transform.sax.SAXResult;
>>>>>>>
>>>>>>>      //FOP
>>>>>>>      import org.apache.fop.apps.FOUserAgent;
>>>>>>>      import org.apache.fop.apps.Fop;
>>>>>>>      import org.apache.fop.apps.FopFactory;
>>>>>>>      import org.apache.fop.apps.MimeConstants;
>>>>>>>
>>>>>>>      //log4j
>>>>>>>      import org.apache.log4j.*;
>>>>>>>      import org.apache.log4j.xml.DOMConfigurator;
>>>>>>>
>>>>>>> public final class Main {
>>>>>>>         @SuppressWarnings("unchecked")
>>>>>>>         static Logger logger = Logger.getLogger(Main.class);
>>>>>>>
>>>>>>>         public static void main(String[] args) throws Exception {
>>>>>>>              DOMConfigurator.configure("D:/Mis
>>>>>>> documentos/NetBeansProjects/Factura/src/factura/log4j.xml");
>>>>>>>              logger.info("Entering application.");
>>>>>>>              try {
>>>>>>>                 File file = new File(args[0]);
>>>>>>>                 Comprobante comp = CFDv2.newComprobante(new
>>>>>>> FileInputStream(file));
>>>>>>>                 CFDv2 cfd = new CFDv2(comp);
>>>>>>>                 PrivateKey key = KeyLoader.loadPKCS8PrivateKey(new
>>>>>>> FileInputStream(args[1]),(args[2]));
>>>>>>>                 X509Certificate cert =
>>>>>>> KeyLoader.loadX509Certificate(new
>>>>>>> FileInputStream(args[3]));
>>>>>>>                 Comprobante sellado = cfd.sellarComprobante(key,
>>>>>>> cert);
>>>>>>>                 String cadena = cfd.getCadenaOriginal();
>>>>>>>                 String sello = sellado.getSello();
>>>>>>>                 // Creamos el builder basado en SAX
>>>>>>>                 SAXBuilder builder = new SAXBuilder();
>>>>>>>                 // Construimos el arbol DOM a partir del fichero xml
>>>>>>>                 Document documentJDOM = builder.build(new
>>>>>>> FileInputStream(args[0]));
>>>>>>>
>>>>>>>
>>>>>>>                 Element raiz = documentJDOM.getRootElement();//toma el
>>>>>>> nodo
>>>>>>> raiz
>>>>>>> del documento.
>>>>>>>                 raiz.setAttribute("sello", sello);
>>>>>>>                 raiz.setAttribute("certificado",
>>>>>>> sellado.getCertificado());
>>>>>>>                 //System.out.println(raiz.getAttributeValue("sello"));
>>>>>>>
>>>>>>> //System.out.println(raiz.getAttributeValue("certificado"));
>>>>>>>                 // Recorremos los hijos de la etiqueta raíz
>>>>>>>                 List<Element>     hijosRaiz = raiz.getChildren();
>>>>>>>                 boolean Bandera=false;
>>>>>>>                 for(Element hijo: hijosRaiz)
>>>>>>>                 {
>>>>>>>                     // Obtenemos el nombre y su contenido de tipo
>>>>>>> texto
>>>>>>>                     String nombre = hijo.getName();
>>>>>>>
>>>>>>>                     if (nombre.equals("Addenda"))
>>>>>>>                     {   List<Element>     subHijo = hijo.getChildren();
>>>>>>>                         for(Element hij: subHijo)
>>>>>>>                             {
>>>>>>>                             hij.setAttribute("CadenaOriginal",
>>>>>>> cadena);
>>>>>>>                             //System.out.println("CadenaOriginal:
>>>>>>> "+hij.getAttributeValue("CadenaOriginal"));
>>>>>>>                             Bandera=true;
>>>>>>>                             break;
>>>>>>>                             }
>>>>>>>                     }
>>>>>>>                     if (Bandera)
>>>>>>>                     {
>>>>>>>                         XMLOutputter out = new
>>>>>>> XMLOutputter(Format.getPrettyFormat());
>>>>>>>                         File nuevoXML = new File(args[0]);
>>>>>>>                         try{
>>>>>>>                             FileOutputStream archivoXML= new
>>>>>>> FileOutputStream
>>>>>>> (nuevoXML);
>>>>>>>                             out.output(documentJDOM, archivoXML);
>>>>>>>
>>>>>>>                            }
>>>>>>>                         catch (Exception
>>>>>>> ex){System.out.println(ex.getMessage());}
>>>>>>>                         // Para generar el pdf a partir de un
>>>>>>> archivo.xsl
>>>>>>> y
>>>>>>> un
>>>>>>>                         // archivo.xml
>>>>>>>                     }
>>>>>>>                   }
>>>>>>>               // configure fopFactory as desired
>>>>>>>               FopFactory fopFactory = FopFactory.newInstance();
>>>>>>>               FOUserAgent foUserAgent = fopFactory.newFOUserAgent();
>>>>>>>
>>>>>>>               // configure foUserAgent as desired
>>>>>>>               // Setup output
>>>>>>>              File pdffile = new File(args[5]);
>>>>>>>
>>>>>>>              OutputStream out = new java.io.FileOutputStream(pdffile);
>>>>>>>              out = new java.io.BufferedOutputStream(out);
>>>>>>>              try {
>>>>>>>                     // Construct fop with desired output format
>>>>>>>                      Fop fop =
>>>>>>> fopFactory.newFop(MimeConstants.MIME_PDF,
>>>>>>> foUserAgent, out);
>>>>>>>                     // Setup XSLT
>>>>>>>                     TransformerFactory factory =
>>>>>>> TransformerFactory.newInstance();
>>>>>>>                     Transformer transformer =
>>>>>>> factory.newTransformer(new
>>>>>>> StreamSource(args[4]));
>>>>>>>                     // Set the value of a  in the stylesheet
>>>>>>>                     transformer.setParameter("versionParam", "2.0");
>>>>>>>
>>>>>>>                    // Setup input for XSLT transformation
>>>>>>>                     Source src = new JDOMSource(documentJDOM);
>>>>>>>                      // Resulting SAX events (the generated FO) must
>>>>>>> be
>>>>>>> piped
>>>>>>> through to FOP
>>>>>>>                     Result res = new
>>>>>>> SAXResult(fop.getDefaultHandler());
>>>>>>>                      // Start XSLT transformation and FOP processing
>>>>>>>                    // System.setProperty("java.awt.headless", "true");
>>>>>>>                         transformer.transform(src, res);
>>>>>>>                     } finally {
>>>>>>>                      out.close();
>>>>>>>                 }
>>>>>>>
>>>>>>>
>>>>>>>               System.out.println("Success!");
>>>>>>>              } catch (Exception e) {
>>>>>>>               e.printStackTrace(System.err);
>>>>>>>               System.exit(-1);
>>>>>>>            }
>>>>>>>          logger.info("Exiting application.");
>>>>>>>
>>>>>>>       }
>>>>>>>
>>>>>>>
>>>>>>> Rob Sargent-4 wrote:
>>>>>>>> Try this log4j.xml: Place it at the root of your jar file
>>>>>>>>
>>>>>>>> <?xml version="1.0" encoding="UTF-8"?>
>>>>>>>> <!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">
>>>>>>>>
>>>>>>>> <log4j:configuration xmlns:log4j="http://jakarta.apache.org/log4j/"
>>>>>>>> debug="false">
>>>>>>>>
>>>>>>>> <appender name="CONSOLE" class="org.apache.log4j.ConsoleAppender">
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> <layout class="org.apache.log4j.PatternLayout">
>>>>>>>>
>>>>>>>> </layout>
>>>>>>>> </appender>
>>>>>>>>
>>>>>>>> <category name="org">
>>>>>>>> <priority value="DEBUG"/>
>>>>>>>> </category>
>>>>>>>> <category name="org.apache">
>>>>>>>> <priority value="WARN"/>
>>>>>>>> </category>
>>>>>>>> <category name="org.springframework">
>>>>>>>> <priority value="WARN"/>
>>>>>>>> </category>
>>>>>>>> <category name="org.hibernate">
>>>>>>>> <priority value="DEBUG"/>
>>>>>>>> </category>
>>>>>>>> <category name="net">
>>>>>>>> <priority value="ERROR"/>
>>>>>>>> </category>
>>>>>>>> <category name="javax">
>>>>>>>> <priority value="ERROR"/>
>>>>>>>> </category>
>>>>>>>> <category name="java">
>>>>>>>> <priority value="ERROR"/>
>>>>>>>> </category>
>>>>>>>> <category name="sun">
>>>>>>>> <priority value="ERROR"/>
>>>>>>>> </category>
>>>>>>>> <category name="org.jboss">
>>>>>>>> <priority value="INFO"/>
>>>>>>>> </category>
>>>>>>>> <category name="org.jboss.seam">
>>>>>>>> <priority value="ERROR"/>
>>>>>>>> </category>
>>>>>>>> <root>
>>>>>>>> <appender-ref ref="CONSOLE"/>
>>>>>>>> </root>
>>>>>>>>
>>>>>>>> </log4j:configuration>
>>>>>>>>
>>>>>>>>
>>>>>>>> On 06/13/2011 11:06 AM, Oscar.Flores wrote:
>>>>>>>>> ok i dont thik i have a configuracion file i find the code that i
>>>>>>>>> put
>>>>>>>>> in
>>>>>>>>> the
>>>>>>>>> other post i think its the basic
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>> Do you have a config file for log4j.  Usually it's in a resource
>>>>>>>>>> tree.
>>>>>>>>>> Are you copying that to your deployment? Is your ant script
>>>>>>>>>> including
>>>>>>>>>> the config file in the jar of your application?
>>>>>>>>>>
>>>>>>>>>> On 06/13/2011 10:12 AM, Oscar.Flores wrote:
>>>>>>>>>>> Ok yeah the log4j its having isuees to find the configuration
>>>>>>>>>>>
>>>>>>>>>>> log4j:WARN No appenders could be found for logger
>>>>>>>>>>> (org.apache.fop.util.ContentHandlerFactoryRegistry).
>>>>>>>>>>> log4j:WARN Please initialize the log4j system properly.
>>>>>>>>>>> log4j:WARN See
>>>>>>>>>>> http://logging.apache.org/log4j/1.2/faq.html#noconfig
>>>>>>>>>>> for
>>>>>>>>>>> more info.
>>>>>>>>>>> i go to the faq guide and it say try loading the class or
>>>>>>>>>>> resource
>>>>>>>>>>> yourself.
>>>>>>>>>>> If you can't find it, neither will log4j.
>>>>>>>>>>>
>>>>>>>>>>> aaa i dont know where to set this
>>>>>>>>>>>
>>>>>>>>>>> also here its my xlst
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> http://old.nabble.com/file/p31835645/FacturasOMF.xsl
>>>>>>>>>>> FacturasOMF.xsl
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> and the fo file that generate the editix
>>>>>>>>>>>
>>>>>>>>>>> http://old.nabble.com/file/p31835645/Prueba.fo Prueba.fo
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>> The first thing is to really dig into what you did to netbeans
>>>>>>>>>>>> to
>>>>>>>>>>>> get
>>>>>>>>>>>> it
>>>>>>>>>>>> to work...
>>>>>>>>>>>>
>>>>>>>>>>>> I've forgotten what your stylesheet looked like, so maybe if you
>>>>>>>>>>>> show
>>>>>>>>>>>> us
>>>>>>>>>>>> again how you're referencing your images we might notice a
>>>>>>>>>>>> problem.
>>>>>>>>>>>>
>>>>>>>>>>>> It might also help to see the "fo" generated during your
>>>>>>>>>>>> transformation.
>>>>>>>>>>>> Can you grab that just after xslt and just before fop calls.
>>>>>>>>>>>>
>>>>>>>>>>>> Are you sure there is no error being logged somewhere when you
>>>>>>>>>>>> run
>>>>>>>>>>>> from
>>>>>>>>>>>> the command line? (Where is log4j writing and at what level?)
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> Oscar.Flores wrote:
>>>>>>>>>>>>> You where absolutly rigth i miss a few libraries to add into
>>>>>>>>>>>>> the
>>>>>>>>>>>>> jar
>>>>>>>>>>>>> file, i
>>>>>>>>>>>>> modified the build.xml to add the package and jar that i need,
>>>>>>>>>>>>> now
>>>>>>>>>>>>> the
>>>>>>>>>>>>> error
>>>>>>>>>>>>> message is not there but still the images dont show in the pdf
>>>>>>>>>>>>> i
>>>>>>>>>>>>> remeber
>>>>>>>>>>>>> that i do something in netbeans so they can add to the pdf but
>>>>>>>>>>>>> i
>>>>>>>>>>>>> cant
>>>>>>>>>>>>> remeber i dont now if there is still a library that is missing
>>>>>>>>>>>>> or
>>>>>>>>>>>>> i
>>>>>>>>>>>>> am
>>>>>>>>>>>>> adding more than it should be
>>>>>>>>>>>>> This is what i use :
>>>>>>>>>>>>> cfdi-base-0.1.6-SNAPSHOT.jar
>>>>>>>>>>>>> guava-r09.jar
>>>>>>>>>>>>> guava-r09-gwt.jar
>>>>>>>>>>>>> jaxb-impl-2.1.10.jar
>>>>>>>>>>>>> avalon-framework-api-4.3.jar
>>>>>>>>>>>>> avalon-framework-cvs-20020806.jar
>>>>>>>>>>>>> avalon-logkit-2.1.jar
>>>>>>>>>>>>> not-yet-commons-ssl-0.3.11.jar
>>>>>>>>>>>>> commons-codec-1.5.jar
>>>>>>>>>>>>> commons-codec-1.5-sources.jar
>>>>>>>>>>>>> log4j-1.2.16.jar
>>>>>>>>>>>>> fop.jar
>>>>>>>>>>>>> jdom.jar
>>>>>>>>>>>>> xmlgraphics-commons-1.4.jar
>>>>>>>>>>>>> commons-io-1.3.1.jar
>>>>>>>>>>>>> fop-pdf-images-2.0.1.SNAPSHOT.jar
>>>>>>>>>>>>> pdfbox-app-1.5.0.jar
>>>>>>>>>>>>> fontbox-1.3.1.jar
>>>>>>>>>>>>> jempbox-1.3.1.jar
>>>>>>>>>>>>> xercesImpl-2.7.1.jar
>>>>>>>>>>>>> batik-all-1.7.jar
>>>>>>>>>>>>> xml-apis-1.3.04.jar
>>>>>>>>>>>>> xml-apis-ext-1.3.04.jar
>>>>>>>>>>>>>        avalon-framework-4.2.0.jar
>>>>>>>>>>>>>        xalan-2.7.0.jar
>>>>>>>>>>>>>        serializer-2.7.0.jar
>>>>>>>>>>>>>        commons-logging-1.0.4.jar
>>>>>>>>>>>>>        jai_codec.jar
>>>>>>>>>>>>>        jai_core.jar
>>>>>>>>>>>>>        batik-ext.jar
>>>>>>>>>>>>>        jai_imageio-1.1-sources.jar
>>>>>>>>>>>>>
>>>>>>>>>>>>> Thanks Rob for the help
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>
>>>>>>>>>>>>>> I suspect running from your jar does not have/use the same
>>>>>>>>>>>>>> classpath
>>>>>>>>>>>>>> that is in effect while you're in the debugger.
>>>>>>>>>>>>>> By what mechanism do you generate the jar?
>>>>>>>>>>>>>> Is it an executable jar or are you running java -classpath
>>>>>>>>>>>>>> <your-jar-here:other-jars>       Main?
>>>>>>>>>>>>>> Make your IDE (netbeans) display the classpath  it uses to run
>>>>>>>>>>>>>> your
>>>>>>>>>>>>>> app
>>>>>>>>>>>>>> and compare that with the above.
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> On 06/09/2011 07:21 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> aaa ok well my problem is that when i do the pdf in netbean
>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>> fine
>>>>>>>>>>>>>>> with images and evething but when i run the jar file in
>>>>>>>>>>>>>>> command
>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>> give
>>>>>>>>>>>>>>> me a
>>>>>>>>>>>>>>> error
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> GRAVE: Error while processing image: I:\cfd\rfc.jpg
>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>         org.apache.xmlgraphics.image.loader.ImageException:
>>>>>>>>>>>>>>> Cannot
>>>>>>>>>>>>>>> load
>>>>>>>>>>>>>>>         image (no suitable loader/converter combination
>>>>>>>>>>>>>>> available)
>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>         (image/jpeg)
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> so i dont no what its not working and if i have to add
>>>>>>>>>>>>>>> something
>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>> my
>>>>>>>>>>>>>>> code
>>>>>>>>>>>>>>> so the images can load i am soooo desperate what i am doing
>>>>>>>>>>>>>>> wrong??
>>>>>>>>>>>>>>> i am sorry for the trouble and if a dont explain my self very
>>>>>>>>>>>>>>> good
>>>>>>>>>>>>>>> jejeje
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> Not at all sure what your problem is.  All I can do is show
>>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>>> what
>>>>>>>>>>>>>>>> works for us.
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> Our source xml looks like this:
>>>>>>>>>>>>>>>> <image image-id="381623861" reference-id="ref-220"
>>>>>>>>>>>>>>>> width="750"
>>>>>>>>>>>>>>>> height="750" image-space-id="space-1" position="5"
>>>>>>>>>>>>>>>>                      image-pool-position="31" pos="4"
>>>>>>>>>>>>>>>>                      file="ref_10_1002108221">        <!-- an
>>>>>>>>>>>>>>>> actual
>>>>>>>>>>>>>>>> file
>>>>>>>>>>>>>>>> (.jpeg
>>>>>>>>>>>>>>>> copied the working directory of the transformer -->
>>>>>>>>>>>>>>>> <fields />
>>>>>>>>>>>>>>>> <caption />
>>>>>>>>>>>>>>>> <annotations>
>>>>>>>>>>>>>>>> <arrow_positions origHeight="750" origWidth="750" />
>>>>>>>>>>>>>>>> </annotations>
>>>>>>>>>>>>>>>> </image>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> Our xslt looks like this for each image needed.
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> <xsl:template name="image">
>>>>>>>>>>>>>>>> <xsl:param name="img"/>        <!-- This is the xml node from
>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>> source
>>>>>>>>>>>>>>>> xml
>>>>>>>>>>>>>>>> above -->
>>>>>>>>>>>>>>>> <xsl:param name="width"/>
>>>>>>>>>>>>>>>> <xsl:param name="height" select="$width"/>
>>>>>>>>>>>>>>>> <xsl:param name="ignoreHeight">false</xsl:param>
>>>>>>>>>>>>>>>> <fo:block>
>>>>>>>>>>>>>>>> <fo:external-graphic src="{$img/@file}" height="{$height}"
>>>>>>>>>>>>>>>> width="{$width}" content-height="scale-to-fit"
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> content-width="scale-to-fit"
>>>>>>>>>>>>>>>> border="0.5pt solid black" border-collapse="separate">
>>>>>>>>>>>>>>>> <xsl:if test="$ignoreHeight != 'true'">
>>>>>>>>>>>>>>>> <xsl:attribute name="height">
>>>>>>>>>>>>>>>> <xsl:value-of select="$height"/>
>>>>>>>>>>>>>>>> </xsl:attribute>
>>>>>>>>>>>>>>>> </xsl:if>
>>>>>>>>>>>>>>>> </fo:external-graphic>
>>>>>>>>>>>>>>>> </fo:block>
>>>>>>>>>>>>>>>> </xsl:template>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> Our generated fo looks like this:
>>>>>>>>>>>>>>>> <fo:table-cell>
>>>>>>>>>>>>>>>> <fo:block>
>>>>>>>>>>>>>>>> <fo:external-graphic border-collapse="separate"
>>>>>>>>>>>>>>>> border="0.5pt
>>>>>>>>>>>>>>>> solid
>>>>>>>>>>>>>>>> black" content-width="scale-to-fit"
>>>>>>>>>>>>>>>> content-height="scale-to-fit"
>>>>>>>>>>>>>>>> width="2.5in" height="2.5in" src="ref_10_1002108221" />
>>>>>>>>>>>>>>>> </fo:block>
>>>>>>>>>>>>>>>> </fo:table-cell>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> And the generated pdfs include the image and are shipped to
>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>> printer.
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> How does this stack up with what you have?
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> On 06/09/2011 01:19 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> Hi there well i still got the problem but searching IN
>>>>>>>>>>>>>>>>> INTERNET
>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>> find
>>>>>>>>>>>>>>>>> a
>>>>>>>>>>>>>>>>> JPEG
>>>>>>>>>>>>>>>>> renderer output for FOP its here
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> http://marc.info/?l=fop-user&m=125986752706366&w=2
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> the cuestion is can i render the image that i want to put
>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>> pdf,
>>>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>>>> then add to the xsl the render jpeg it will work??
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> and here explaints how use the render when he say uses fop
>>>>>>>>>>>>>>>>> as
>>>>>>>>>>>>>>>>> normal
>>>>>>>>>>>>>>>>> case
>>>>>>>>>>>>>>>>> what does it mean
>>>>>>>>>>>>>>>>> what else have to add to the code?? i hope you can help me
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> Thanks!!
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> // OutputStream out = what you want
>>>>>>>>>>>>>>>>>                     FopFactory fopFactory =
>>>>>>>>>>>>>>>>> FopFactory.newInstance();
>>>>>>>>>>>>>>>>>                     RendererFactory rendererFactory = null;
>>>>>>>>>>>>>>>>>                     FOUserAgent foUserAgent = null;
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>                     rendererFactory =
>>>>>>>>>>>>>>>>> fopFactory.getRendererFactory();
>>>>>>>>>>>>>>>>>                     rendererFactory.addRendererMaker(new
>>>>>>>>>>>>>>>>> MultiRendererMaker("jpeg"));
>>>>>>>>>>>>>>>>>                     foUserAgent =
>>>>>>>>>>>>>>>>> fopFactory.newFOUserAgent();
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> rendererFactory.createRenderer(foUserAgent,
>>>>>>>>>>>>>>>>> "image/jpeg");
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>                     Fop fop =
>>>>>>>>>>>>>>>>> fopFactory.newFop("image/jpeg",
>>>>>>>>>>>>>>>>> foUserAgent,
>>>>>>>>>>>>>>>>> out);
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> //Use fop as normal case
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> Since you're now into xmlgraphics, I think you're best bet
>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>> here
>>>>>>>>>>>>>>>>>> <http://xmlgraphics.apache.org/commons/image-loader.html>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> On 06/07/2011 10:18 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> Hi ok this is for generate images that dont need to be
>>>>>>>>>>>>>>>>>>> decompress
>>>>>>>>>>>>>>>>>>> later??
>>>>>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>>>>>> the result image i put in my xsl ?? then it should work,
>>>>>>>>>>>>>>>>>>> aaa
>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>> change
>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>> fop
>>>>>>>>>>>>>>>>>>> 1.0 and xml communs 1.4 and its the same jejeje   dont
>>>>>>>>>>>>>>>>>>> find
>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>> image
>>>>>>>>>>>>>>>>>>> preload
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> org.apache.fop.fo.flow.ExternalGraphic bind
>>>>>>>>>>>>>>>>>>> SEVERE: Image not available: The file format is not
>>>>>>>>>>>>>>>>>>> supported.
>>>>>>>>>>>>>>>>>>> No
>>>>>>>>>>>>>>>>>>> ImagePreloader for *.jpg or *.bmp
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> ImageIO.write(bufferedImage, "JPEG", file);
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> On 06/07/2011 08:21 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> Ok i actually register the handler now what i have to
>>>>>>>>>>>>>>>>>>>>> do
>>>>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>>>>> setup
>>>>>>>>>>>>>>>>>>>>> this
>>>>>>>>>>>>>>>>>>>>> handler or not?? and how can i do that, also it seem
>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>> bmp
>>>>>>>>>>>>>>>>>>>>> its
>>>>>>>>>>>>>>>>>>>>> not
>>>>>>>>>>>>>>>>>>>>> recognice also what can i do?? thanks for the help rob
>>>>>>>>>>>>>>>>>>>>> also i am trying to convert the images to see if it
>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>> helps
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> On 06/06/2011 02:29 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> Hi what can be the difference between execute the
>>>>>>>>>>>>>>>>>>>>>>> program
>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>> netbeans
>>>>>>>>>>>>>>>>>>>>>>> (where
>>>>>>>>>>>>>>>>>>>>>>> it works and print the images and the jar in the
>>>>>>>>>>>>>>>>>>>>>>> console)
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> Different classes being loaded by Netbeans than the
>>>>>>>>>>>>>>>>>>>>>> console
>>>>>>>>>>>>>>>>>>>>>> app.
>>>>>>>>>>>>>>>>>>>>>> Get
>>>>>>>>>>>>>>>>>>>>>> Netbeans to show you the full classpath it's using in
>>>>>>>>>>>>>>>>>>>>>> it's
>>>>>>>>>>>>>>>>>>>>>> "%classpath"
>>>>>>>>>>>>>>>>>>>>>> variable
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> also i tried the
>>>>>>>>>>>>>>>>>>>>>>> imageIO.getImageReadersBySuffix but i cant
>>>>>>>>>>>>>>>>>>>>>>> interpretate
>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>> data
>>>>>>>>>>>>>>>>>>>>>>> y.y,
>>>>>>>>>>>>>>>>>>>>>>> its
>>>>>>>>>>>>>>>>>>>>>>> that or always its true in the boolean variable, and
>>>>>>>>>>>>>>>>>>>>>>> how
>>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>> register
>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>> handler??
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> Talk to IIORegistry, some thing like
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>>>>>>>>>>> CLibJPEGImageReaderSpi());
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>>>>>>>>>>> CLibJPEGImageWriterSpi());
>>>>>>>>>>>>>>>>>>>>>> Note: those are not necessarily the services you have
>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>> your
>>>>>>>>>>>>>>>>>>>>>> setup.
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> Thanks
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> See the javadoc on IIORegistry. With ImageIO you may
>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>> register
>>>>>>>>>>>>>>>>>>>>>>>> your handler(s). What does
>>>>>>>>>>>>>>>>>>>>>>>> ImageIO.getImageReadersBySuffix()
>>>>>>>>>>>>>>>>>>>>>>>> give
>>>>>>>>>>>>>>>>>>>>>>>> you.
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> For certain jpegs we don't use ImageIO, rather the
>>>>>>>>>>>>>>>>>>>>>>>> classes
>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>> com.sun.image.codec.jpeg:
>>>>>>>>>>>>>>>>>>>>>>>>                     try {
>>>>>>>>>>>>>>>>>>>>>>>>                         FileOutputStream fos = new
>>>>>>>>>>>>>>>>>>>>>>>> FileOutputStream(file);
>>>>>>>>>>>>>>>>>>>>>>>>                         JPEGImageEncoder encoder =
>>>>>>>>>>>>>>>>>>>>>>>> JPEGCodec.createJPEGEncoder(fos);
>>>>>>>>>>>>>>>>>>>>>>>>                         JPEGEncodeParam param =
>>>>>>>>>>>>>>>>>>>>>>>> encoder.getDefaultJPEGEncodeParam(image.getRaster(),
>>>>>>>>>>>>>>>>>>>>>>>> JPEGDecodeParam.COLOR_ID_CMYK);
>>>>>>>>>>>>>>>>>>>>>>>>                         param.setQuality(1, false);
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> encoder.encode(image.getRaster(),
>>>>>>>>>>>>>>>>>>>>>>>> param);
>>>>>>>>>>>>>>>>>>>>>>>>                         fos.close();
>>>>>>>>>>>>>>>>>>>>>>>>                     } catch (Throwable t) {
>>>>>>>>>>>>>>>>>>>>>>>>                         logger.debug(t.getMessage());
>>>>>>>>>>>>>>>>>>>>>>>>                     }
>>>>>>>>>>>>>>>>>>>>>>>> But generally we use ImageIO
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> On 06/06/2011 08:29 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> Yeah i think i need your help again i tried tu run
>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>> .jar
>>>>>>>>>>>>>>>>>>>>>>>>> file
>>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>> console it work but without images this it what
>>>>>>>>>>>>>>>>>>>>>>>>> appears
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> GRAVE: Error while processing image: I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException:
>>>>>>>>>>>>>>>>>>>>>>>>> Cannot
>>>>>>>>>>>>>>>>>>>>>>>>> load
>>>>>>>>>>>>>>>>>>>>>>>>> image
>>>>>>>>>>>>>>>>>>>>>>>>> (no
>>>>>>>>>>>>>>>>>>>>>>>>> suitable loader/converter combination available)
>>>>>>>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> i tried  download the jai-imagio add to the class
>>>>>>>>>>>>>>>>>>>>>>>>> path
>>>>>>>>>>>>>>>>>>>>>>>>> but
>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>> dont
>>>>>>>>>>>>>>>>>>>>>>>>> work
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> Very odd.  I'm having no problems getting images
>>>>>>>>>>>>>>>>>>>>>>>>>> into
>>>>>>>>>>>>>>>>>>>>>>>>>> pdfs
>>>>>>>>>>>>>>>>>>>>>>>>>> using
>>>>>>>>>>>>>>>>>>>>>>>>>> fop-1.0.
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/03/2011 11:04 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> aaa hey thanks for the help the other day, i
>>>>>>>>>>>>>>>>>>>>>>>>>>> resolve
>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>> problem
>>>>>>>>>>>>>>>>>>>>>>>>>>> changing
>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>> version of FOP for the 0.95beta instead of the
>>>>>>>>>>>>>>>>>>>>>>>>>>> 1.0,
>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>> works
>>>>>>>>>>>>>>>>>>>>>>>>>>> now
>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>> prints
>>>>>>>>>>>>>>>>>>>>>>>>>>> the image and its good, thanks and we are in
>>>>>>>>>>>>>>>>>>>>>>>>>>> touch
>>>>>>>>>>>>>>>>>>>>>>>>>>> if
>>>>>>>>>>>>>>>>>>>>>>>>>>> anything
>>>>>>>>>>>>>>>>>>>>>>>>>>> else
>>>>>>>>>>>>>>>>>>>>>>>>>>> fails
>>>>>>>>>>>>>>>>>>>>>>>>>>> jejeje
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> Nothing in the log from the transformer?
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/03/2011 09:47 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> hi there i have another problem i hope you can
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> help
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> me
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> create
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> with foe has no image, it dont show any of
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> them,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> xsl
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> seems
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> be
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> rigth i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> tested with EditX and the pdf show me the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> image,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> what
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> be,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> xmlgraphics-commons-1.5svn, fop 1.0,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-pdf-images
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> 2.0.1
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Snapshot
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> render of the image but it don work please
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> help!!!
>>>>>>>>>>>>>>>>>>>>>>>>>>>>> :,(
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> :-):confused::confused::confused::confused:=)
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>> http://old.nabble.com/file/p31822059/libraries.jpeg
>>>>>>>>>>>>> http://old.nabble.com/file/p31822059/libraries.bmp
>>>>>>>>>>>>> libraries.bmp
>>>>>>>>>>>>>
>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>> ---------------------------------------------------------------------
>>>>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>> For additional commands, e-mail:
>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>> ---------------------------------------------------------------------
>>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>>>>
>>>>>>
>>>>>>
>>>> ---------------------------------------------------------------------
>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>>
>>>>
>>>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>
>>
>>

---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Problems with FOP and image

Posted by "Oscar.Flores" <fa...@hotmail.com>.
No i dont, and that weird jejeje netbeans seems to do that for me, so the
calls like ImageIO.write(BufferedImage, "JPEG", jpegImageFile)? do i have to
do it in every image that i put in the pdf?? and the image is gererate
directly in the pdf??how can i do it??  

Rob Sargent-4 wrote:
> 
> Some jar to which netbeans has access has those classes.  Look in the 
> output of jar tvf <each of your jars> and see if any of those has the 
> named classes.  If you find a jar with those classes make sure it's part 
> of your classpath for you app.
> 
> Are you making any calls like ImageIO.write(BufferedImage, "JPEG", 
> jpegImageFile)?
> 
> On 06/13/2011 05:31 PM, Oscar.Flores wrote:
>> ok i made a test and tell me that the class is missign but maybe what you
>> say
>> its rigth and it register the handler
>> so i gonna register the services so i do this
>>
>>   public static void main(String[] args) throws Exception {
>>           DOMConfigurator.configure("D:/Mis
>> documentos/NetBeansProjects/Factura/src/factura/log4j.xml");
>>           logger.info("Entering application.");
>>            IIORegistry.getDefaultInstance().registerServiceProvider(new
>> CLibJPEGImageReaderSpi());
>>            IIORegistry.getDefaultInstance().registerServiceProvider(new
>> CLibJPEGImageWriterSpi());
>>
>> also after register my services it telling me that the class
>> CLibJPEGImageReaderSpi() and CLibJPEGImageWriterSpi() is missing but only
>> in
>> command
>>
>> after register mi service, something more has to be done??
>>
>>
>> Rob Sargent-4 wrote:
>>> I'm not sure I'm following correctly: does removing the xmlgraphics jar
>>> cause netbeans to behave the same as the command-line run of you app? If
>>> so, I suspect netbeans is registering services for you.  Your own code
>>> will have to make a call to one of the
>>> IIORegistry.registerServiceProvider() methods.
>>>
>>> On 06/13/2011 05:02 PM, Oscar.Flores wrote:
>>>> Ok aaaa i get it, actually the ImageIO library i added because i read
>>>> in
>>>> the
>>>> xmlgrapics that if something like the message
>>>> org.apache.xmlgraphics.image.loader.ImageException: Cannot load image
>>>> (no
>>>> suitable loader/converter combination available)appear i have to add
>>>> the
>>>> jar
>>>> file to the classpath but that all it say no configuration or anything,
>>>> then
>>>> i delete the imagenIO libs and still i have the same output in netbeans
>>>> so
>>>> xmlgrapics seem to have the problem in the plugins or i have to
>>>> configure
>>>> something
>>>>
>>>> Rob Sargent-4 wrote:
>>>>> Then it seems to me netbeans (if it's producing good output ==
>>>>> assumptionA) is still using something that the command-line isn't.
>>>>>
>>>>> And given assumptionA, you're java code is correct in terms of FOP and
>>>>> your configuration isn't for ImageIO.  Show your ImageIO related code
>>>>> and are you sure it's in your app.  Use the logger to show a message
>>>>> when you add  your loader.  Or list all ImageIO services:
>>>>> IIORegistry.getServiceProviders()
>>>>>
>>>>> On 06/13/2011 03:01 PM, Oscar.Flores wrote:
>>>>>> ok well i put the xml in scr of my proyect i see that i still have
>>>>>> the
>>>>>> same
>>>>>> issues of the image render of any image i dont now if the xml its in
>>>>>> place i
>>>>>> put the code down to see if something its missing
>>>>>>
>>>>>> 15:45:07,827 ERROR [render] Error while processing image:
>>>>>> c:\cfd\nombregp.bmp (i
>>>>>> mage/bmp)
>>>>>> org.apache.xmlgraphics.image.loader.ImageException: Cannot load image
>>>>>> (no
>>>>>> suitab
>>>>>> le loader/converter combination available) for c:\cfd\nombregp.bmp
>>>>>> (image/bmp)
>>>>>>            at
>>>>>> org.apache.xmlgraphics.image.loader.ImageManager.getImage(ImageManage
>>>>>>
>>>>>>
>>>>>>
>>>>>> import mx.bigdata.sat.cfd.schema.Comprobante;
>>>>>> import mx.bigdata.sat.cfd.CFDv2;
>>>>>> import mx.bigdata.sat.security.KeyLoader;
>>>>>> import org.jdom.*;
>>>>>> import org.jdom.input.SAXBuilder;
>>>>>> import org.jdom.output.XMLOutputter;
>>>>>> import org.jdom.output.Format;
>>>>>> import org.jdom.transform.JDOMSource;
>>>>>> //Java
>>>>>>     import java.io.File;
>>>>>>     import java.io.OutputStream;
>>>>>>
>>>>>>     //JAXP
>>>>>>     import javax.xml.transform.Transformer;
>>>>>>     import javax.xml.transform.TransformerFactory;
>>>>>>     import javax.xml.transform.Source;
>>>>>>     import javax.xml.transform.Result;
>>>>>>     import javax.xml.transform.stream.StreamSource;
>>>>>>     import javax.xml.transform.sax.SAXResult;
>>>>>>
>>>>>>     //FOP
>>>>>>     import org.apache.fop.apps.FOUserAgent;
>>>>>>     import org.apache.fop.apps.Fop;
>>>>>>     import org.apache.fop.apps.FopFactory;
>>>>>>     import org.apache.fop.apps.MimeConstants;
>>>>>>
>>>>>>     //log4j
>>>>>>     import org.apache.log4j.*;
>>>>>>     import org.apache.log4j.xml.DOMConfigurator;
>>>>>>
>>>>>> public final class Main {
>>>>>>        @SuppressWarnings("unchecked")
>>>>>>        static Logger logger = Logger.getLogger(Main.class);
>>>>>>
>>>>>>        public static void main(String[] args) throws Exception {
>>>>>>             DOMConfigurator.configure("D:/Mis
>>>>>> documentos/NetBeansProjects/Factura/src/factura/log4j.xml");
>>>>>>             logger.info("Entering application.");
>>>>>>             try {
>>>>>>                File file = new File(args[0]);
>>>>>>                Comprobante comp = CFDv2.newComprobante(new
>>>>>> FileInputStream(file));
>>>>>>                CFDv2 cfd = new CFDv2(comp);
>>>>>>                PrivateKey key = KeyLoader.loadPKCS8PrivateKey(new
>>>>>> FileInputStream(args[1]),(args[2]));
>>>>>>                X509Certificate cert =
>>>>>> KeyLoader.loadX509Certificate(new
>>>>>> FileInputStream(args[3]));
>>>>>>                Comprobante sellado = cfd.sellarComprobante(key,
>>>>>> cert);
>>>>>>                String cadena = cfd.getCadenaOriginal();
>>>>>>                String sello = sellado.getSello();
>>>>>>                // Creamos el builder basado en SAX
>>>>>>                SAXBuilder builder = new SAXBuilder();
>>>>>>                // Construimos el arbol DOM a partir del fichero xml
>>>>>>                Document documentJDOM = builder.build(new
>>>>>> FileInputStream(args[0]));
>>>>>>
>>>>>>
>>>>>>                Element raiz = documentJDOM.getRootElement();//toma el
>>>>>> nodo
>>>>>> raiz
>>>>>> del documento.
>>>>>>                raiz.setAttribute("sello", sello);
>>>>>>                raiz.setAttribute("certificado",
>>>>>> sellado.getCertificado());
>>>>>>                //System.out.println(raiz.getAttributeValue("sello"));
>>>>>>
>>>>>> //System.out.println(raiz.getAttributeValue("certificado"));
>>>>>>                // Recorremos los hijos de la etiqueta raíz
>>>>>>                List<Element>    hijosRaiz = raiz.getChildren();
>>>>>>                boolean Bandera=false;
>>>>>>                for(Element hijo: hijosRaiz)
>>>>>>                {
>>>>>>                    // Obtenemos el nombre y su contenido de tipo
>>>>>> texto
>>>>>>                    String nombre = hijo.getName();
>>>>>>
>>>>>>                    if (nombre.equals("Addenda"))
>>>>>>                    {   List<Element>    subHijo = hijo.getChildren();
>>>>>>                        for(Element hij: subHijo)
>>>>>>                            {
>>>>>>                            hij.setAttribute("CadenaOriginal",
>>>>>> cadena);
>>>>>>                            //System.out.println("CadenaOriginal:
>>>>>> "+hij.getAttributeValue("CadenaOriginal"));
>>>>>>                            Bandera=true;
>>>>>>                            break;
>>>>>>                            }
>>>>>>                    }
>>>>>>                    if (Bandera)
>>>>>>                    {
>>>>>>                        XMLOutputter out = new
>>>>>> XMLOutputter(Format.getPrettyFormat());
>>>>>>                        File nuevoXML = new File(args[0]);
>>>>>>                        try{
>>>>>>                            FileOutputStream archivoXML= new
>>>>>> FileOutputStream
>>>>>> (nuevoXML);
>>>>>>                            out.output(documentJDOM, archivoXML);
>>>>>>
>>>>>>                           }
>>>>>>                        catch (Exception
>>>>>> ex){System.out.println(ex.getMessage());}
>>>>>>                        // Para generar el pdf a partir de un
>>>>>> archivo.xsl
>>>>>> y
>>>>>> un
>>>>>>                        // archivo.xml
>>>>>>                    }
>>>>>>                  }
>>>>>>              // configure fopFactory as desired
>>>>>>              FopFactory fopFactory = FopFactory.newInstance();
>>>>>>              FOUserAgent foUserAgent = fopFactory.newFOUserAgent();
>>>>>>
>>>>>>              // configure foUserAgent as desired
>>>>>>              // Setup output
>>>>>>             File pdffile = new File(args[5]);
>>>>>>
>>>>>>             OutputStream out = new java.io.FileOutputStream(pdffile);
>>>>>>             out = new java.io.BufferedOutputStream(out);
>>>>>>             try {
>>>>>>                    // Construct fop with desired output format
>>>>>>                     Fop fop =
>>>>>> fopFactory.newFop(MimeConstants.MIME_PDF,
>>>>>> foUserAgent, out);
>>>>>>                    // Setup XSLT
>>>>>>                    TransformerFactory factory =
>>>>>> TransformerFactory.newInstance();
>>>>>>                    Transformer transformer =
>>>>>> factory.newTransformer(new
>>>>>> StreamSource(args[4]));
>>>>>>                    // Set the value of a  in the stylesheet
>>>>>>                    transformer.setParameter("versionParam", "2.0");
>>>>>>
>>>>>>                   // Setup input for XSLT transformation
>>>>>>                    Source src = new JDOMSource(documentJDOM);
>>>>>>                     // Resulting SAX events (the generated FO) must
>>>>>> be
>>>>>> piped
>>>>>> through to FOP
>>>>>>                    Result res = new
>>>>>> SAXResult(fop.getDefaultHandler());
>>>>>>                     // Start XSLT transformation and FOP processing
>>>>>>                   // System.setProperty("java.awt.headless", "true");
>>>>>>                        transformer.transform(src, res);
>>>>>>                    } finally {
>>>>>>                     out.close();
>>>>>>                }
>>>>>>
>>>>>>
>>>>>>              System.out.println("Success!");
>>>>>>             } catch (Exception e) {
>>>>>>              e.printStackTrace(System.err);
>>>>>>              System.exit(-1);
>>>>>>           }
>>>>>>         logger.info("Exiting application.");
>>>>>>
>>>>>>      }
>>>>>>
>>>>>>
>>>>>> Rob Sargent-4 wrote:
>>>>>>> Try this log4j.xml: Place it at the root of your jar file
>>>>>>>
>>>>>>> <?xml version="1.0" encoding="UTF-8"?>
>>>>>>> <!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">
>>>>>>>
>>>>>>> <log4j:configuration xmlns:log4j="http://jakarta.apache.org/log4j/"
>>>>>>> debug="false">
>>>>>>>
>>>>>>> <appender name="CONSOLE" class="org.apache.log4j.ConsoleAppender">
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> <layout class="org.apache.log4j.PatternLayout">
>>>>>>>
>>>>>>> </layout>
>>>>>>> </appender>
>>>>>>>
>>>>>>> <category name="org">
>>>>>>> <priority value="DEBUG"/>
>>>>>>> </category>
>>>>>>> <category name="org.apache">
>>>>>>> <priority value="WARN"/>
>>>>>>> </category>
>>>>>>> <category name="org.springframework">
>>>>>>> <priority value="WARN"/>
>>>>>>> </category>
>>>>>>> <category name="org.hibernate">
>>>>>>> <priority value="DEBUG"/>
>>>>>>> </category>
>>>>>>> <category name="net">
>>>>>>> <priority value="ERROR"/>
>>>>>>> </category>
>>>>>>> <category name="javax">
>>>>>>> <priority value="ERROR"/>
>>>>>>> </category>
>>>>>>> <category name="java">
>>>>>>> <priority value="ERROR"/>
>>>>>>> </category>
>>>>>>> <category name="sun">
>>>>>>> <priority value="ERROR"/>
>>>>>>> </category>
>>>>>>> <category name="org.jboss">
>>>>>>> <priority value="INFO"/>
>>>>>>> </category>
>>>>>>> <category name="org.jboss.seam">
>>>>>>> <priority value="ERROR"/>
>>>>>>> </category>
>>>>>>> <root>
>>>>>>> <appender-ref ref="CONSOLE"/>
>>>>>>> </root>
>>>>>>>
>>>>>>> </log4j:configuration>
>>>>>>>
>>>>>>>
>>>>>>> On 06/13/2011 11:06 AM, Oscar.Flores wrote:
>>>>>>>> ok i dont thik i have a configuracion file i find the code that i
>>>>>>>> put
>>>>>>>> in
>>>>>>>> the
>>>>>>>> other post i think its the basic
>>>>>>>>
>>>>>>>>
>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>> Do you have a config file for log4j.  Usually it's in a resource
>>>>>>>>> tree.
>>>>>>>>> Are you copying that to your deployment? Is your ant script
>>>>>>>>> including
>>>>>>>>> the config file in the jar of your application?
>>>>>>>>>
>>>>>>>>> On 06/13/2011 10:12 AM, Oscar.Flores wrote:
>>>>>>>>>> Ok yeah the log4j its having isuees to find the configuration
>>>>>>>>>>
>>>>>>>>>> log4j:WARN No appenders could be found for logger
>>>>>>>>>> (org.apache.fop.util.ContentHandlerFactoryRegistry).
>>>>>>>>>> log4j:WARN Please initialize the log4j system properly.
>>>>>>>>>> log4j:WARN See
>>>>>>>>>> http://logging.apache.org/log4j/1.2/faq.html#noconfig
>>>>>>>>>> for
>>>>>>>>>> more info.
>>>>>>>>>> i go to the faq guide and it say try loading the class or
>>>>>>>>>> resource
>>>>>>>>>> yourself.
>>>>>>>>>> If you can't find it, neither will log4j.
>>>>>>>>>>
>>>>>>>>>> aaa i dont know where to set this
>>>>>>>>>>
>>>>>>>>>> also here its my xlst
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> http://old.nabble.com/file/p31835645/FacturasOMF.xsl
>>>>>>>>>> FacturasOMF.xsl
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> and the fo file that generate the editix
>>>>>>>>>>
>>>>>>>>>> http://old.nabble.com/file/p31835645/Prueba.fo Prueba.fo
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>> The first thing is to really dig into what you did to netbeans
>>>>>>>>>>> to
>>>>>>>>>>> get
>>>>>>>>>>> it
>>>>>>>>>>> to work...
>>>>>>>>>>>
>>>>>>>>>>> I've forgotten what your stylesheet looked like, so maybe if you
>>>>>>>>>>> show
>>>>>>>>>>> us
>>>>>>>>>>> again how you're referencing your images we might notice a
>>>>>>>>>>> problem.
>>>>>>>>>>>
>>>>>>>>>>> It might also help to see the "fo" generated during your
>>>>>>>>>>> transformation.
>>>>>>>>>>> Can you grab that just after xslt and just before fop calls.
>>>>>>>>>>>
>>>>>>>>>>> Are you sure there is no error being logged somewhere when you
>>>>>>>>>>> run
>>>>>>>>>>> from
>>>>>>>>>>> the command line? (Where is log4j writing and at what level?)
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> Oscar.Flores wrote:
>>>>>>>>>>>> You where absolutly rigth i miss a few libraries to add into
>>>>>>>>>>>> the
>>>>>>>>>>>> jar
>>>>>>>>>>>> file, i
>>>>>>>>>>>> modified the build.xml to add the package and jar that i need,
>>>>>>>>>>>> now
>>>>>>>>>>>> the
>>>>>>>>>>>> error
>>>>>>>>>>>> message is not there but still the images dont show in the pdf
>>>>>>>>>>>> i
>>>>>>>>>>>> remeber
>>>>>>>>>>>> that i do something in netbeans so they can add to the pdf but
>>>>>>>>>>>> i
>>>>>>>>>>>> cant
>>>>>>>>>>>> remeber i dont now if there is still a library that is missing
>>>>>>>>>>>> or
>>>>>>>>>>>> i
>>>>>>>>>>>> am
>>>>>>>>>>>> adding more than it should be
>>>>>>>>>>>> This is what i use :
>>>>>>>>>>>> cfdi-base-0.1.6-SNAPSHOT.jar
>>>>>>>>>>>> guava-r09.jar
>>>>>>>>>>>> guava-r09-gwt.jar
>>>>>>>>>>>> jaxb-impl-2.1.10.jar
>>>>>>>>>>>> avalon-framework-api-4.3.jar
>>>>>>>>>>>> avalon-framework-cvs-20020806.jar
>>>>>>>>>>>> avalon-logkit-2.1.jar
>>>>>>>>>>>> not-yet-commons-ssl-0.3.11.jar
>>>>>>>>>>>> commons-codec-1.5.jar
>>>>>>>>>>>> commons-codec-1.5-sources.jar
>>>>>>>>>>>> log4j-1.2.16.jar
>>>>>>>>>>>> fop.jar
>>>>>>>>>>>> jdom.jar
>>>>>>>>>>>> xmlgraphics-commons-1.4.jar
>>>>>>>>>>>> commons-io-1.3.1.jar
>>>>>>>>>>>> fop-pdf-images-2.0.1.SNAPSHOT.jar
>>>>>>>>>>>> pdfbox-app-1.5.0.jar
>>>>>>>>>>>> fontbox-1.3.1.jar
>>>>>>>>>>>> jempbox-1.3.1.jar
>>>>>>>>>>>> xercesImpl-2.7.1.jar
>>>>>>>>>>>> batik-all-1.7.jar
>>>>>>>>>>>> xml-apis-1.3.04.jar
>>>>>>>>>>>> xml-apis-ext-1.3.04.jar
>>>>>>>>>>>>       avalon-framework-4.2.0.jar
>>>>>>>>>>>>       xalan-2.7.0.jar
>>>>>>>>>>>>       serializer-2.7.0.jar
>>>>>>>>>>>>       commons-logging-1.0.4.jar
>>>>>>>>>>>>       jai_codec.jar
>>>>>>>>>>>>       jai_core.jar
>>>>>>>>>>>>       batik-ext.jar
>>>>>>>>>>>>       jai_imageio-1.1-sources.jar
>>>>>>>>>>>>
>>>>>>>>>>>> Thanks Rob for the help
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>
>>>>>>>>>>>>> I suspect running from your jar does not have/use the same
>>>>>>>>>>>>> classpath
>>>>>>>>>>>>> that is in effect while you're in the debugger.
>>>>>>>>>>>>> By what mechanism do you generate the jar?
>>>>>>>>>>>>> Is it an executable jar or are you running java -classpath
>>>>>>>>>>>>> <your-jar-here:other-jars>      Main?
>>>>>>>>>>>>> Make your IDE (netbeans) display the classpath  it uses to run
>>>>>>>>>>>>> your
>>>>>>>>>>>>> app
>>>>>>>>>>>>> and compare that with the above.
>>>>>>>>>>>>>
>>>>>>>>>>>>> On 06/09/2011 07:21 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>
>>>>>>>>>>>>>> aaa ok well my problem is that when i do the pdf in netbean
>>>>>>>>>>>>>> the
>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>> is
>>>>>>>>>>>>>> fine
>>>>>>>>>>>>>> with images and evething but when i run the jar file in
>>>>>>>>>>>>>> command
>>>>>>>>>>>>>> it
>>>>>>>>>>>>>> give
>>>>>>>>>>>>>> me a
>>>>>>>>>>>>>> error
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> GRAVE: Error while processing image: I:\cfd\rfc.jpg
>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>        org.apache.xmlgraphics.image.loader.ImageException:
>>>>>>>>>>>>>> Cannot
>>>>>>>>>>>>>> load
>>>>>>>>>>>>>>        image (no suitable loader/converter combination
>>>>>>>>>>>>>> available)
>>>>>>>>>>>>>> for
>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>        (image/jpeg)
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> so i dont no what its not working and if i have to add
>>>>>>>>>>>>>> something
>>>>>>>>>>>>>> to
>>>>>>>>>>>>>> my
>>>>>>>>>>>>>> code
>>>>>>>>>>>>>> so the images can load i am soooo desperate what i am doing
>>>>>>>>>>>>>> wrong??
>>>>>>>>>>>>>> i am sorry for the trouble and if a dont explain my self very
>>>>>>>>>>>>>> good
>>>>>>>>>>>>>> jejeje
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> Not at all sure what your problem is.  All I can do is show
>>>>>>>>>>>>>>> you
>>>>>>>>>>>>>>> what
>>>>>>>>>>>>>>> works for us.
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> Our source xml looks like this:
>>>>>>>>>>>>>>> <image image-id="381623861" reference-id="ref-220"
>>>>>>>>>>>>>>> width="750"
>>>>>>>>>>>>>>> height="750" image-space-id="space-1" position="5"
>>>>>>>>>>>>>>>                     image-pool-position="31" pos="4"
>>>>>>>>>>>>>>>                     file="ref_10_1002108221">       <!-- an
>>>>>>>>>>>>>>> actual
>>>>>>>>>>>>>>> file
>>>>>>>>>>>>>>> (.jpeg
>>>>>>>>>>>>>>> copied the working directory of the transformer -->
>>>>>>>>>>>>>>> <fields />
>>>>>>>>>>>>>>> <caption />
>>>>>>>>>>>>>>> <annotations>
>>>>>>>>>>>>>>> <arrow_positions origHeight="750" origWidth="750" />
>>>>>>>>>>>>>>> </annotations>
>>>>>>>>>>>>>>> </image>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> Our xslt looks like this for each image needed.
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> <xsl:template name="image">
>>>>>>>>>>>>>>> <xsl:param name="img"/>       <!-- This is the xml node from
>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>> source
>>>>>>>>>>>>>>> xml
>>>>>>>>>>>>>>> above -->
>>>>>>>>>>>>>>> <xsl:param name="width"/>
>>>>>>>>>>>>>>> <xsl:param name="height" select="$width"/>
>>>>>>>>>>>>>>> <xsl:param name="ignoreHeight">false</xsl:param>
>>>>>>>>>>>>>>> <fo:block>
>>>>>>>>>>>>>>> <fo:external-graphic src="{$img/@file}" height="{$height}"
>>>>>>>>>>>>>>> width="{$width}" content-height="scale-to-fit"
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> content-width="scale-to-fit"
>>>>>>>>>>>>>>> border="0.5pt solid black" border-collapse="separate">
>>>>>>>>>>>>>>> <xsl:if test="$ignoreHeight != 'true'">
>>>>>>>>>>>>>>> <xsl:attribute name="height">
>>>>>>>>>>>>>>> <xsl:value-of select="$height"/>
>>>>>>>>>>>>>>> </xsl:attribute>
>>>>>>>>>>>>>>> </xsl:if>
>>>>>>>>>>>>>>> </fo:external-graphic>
>>>>>>>>>>>>>>> </fo:block>
>>>>>>>>>>>>>>> </xsl:template>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> Our generated fo looks like this:
>>>>>>>>>>>>>>> <fo:table-cell>
>>>>>>>>>>>>>>> <fo:block>
>>>>>>>>>>>>>>> <fo:external-graphic border-collapse="separate"
>>>>>>>>>>>>>>> border="0.5pt
>>>>>>>>>>>>>>> solid
>>>>>>>>>>>>>>> black" content-width="scale-to-fit"
>>>>>>>>>>>>>>> content-height="scale-to-fit"
>>>>>>>>>>>>>>> width="2.5in" height="2.5in" src="ref_10_1002108221" />
>>>>>>>>>>>>>>> </fo:block>
>>>>>>>>>>>>>>> </fo:table-cell>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> And the generated pdfs include the image and are shipped to
>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>> printer.
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> How does this stack up with what you have?
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> On 06/09/2011 01:19 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> Hi there well i still got the problem but searching IN
>>>>>>>>>>>>>>>> INTERNET
>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>> find
>>>>>>>>>>>>>>>> a
>>>>>>>>>>>>>>>> JPEG
>>>>>>>>>>>>>>>> renderer output for FOP its here
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> http://marc.info/?l=fop-user&m=125986752706366&w=2
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> the cuestion is can i render the image that i want to put
>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>> pdf,
>>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>>> then add to the xsl the render jpeg it will work??
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> and here explaints how use the render when he say uses fop
>>>>>>>>>>>>>>>> as
>>>>>>>>>>>>>>>> normal
>>>>>>>>>>>>>>>> case
>>>>>>>>>>>>>>>> what does it mean
>>>>>>>>>>>>>>>> what else have to add to the code?? i hope you can help me
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> Thanks!!
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> // OutputStream out = what you want
>>>>>>>>>>>>>>>>                    FopFactory fopFactory =
>>>>>>>>>>>>>>>> FopFactory.newInstance();
>>>>>>>>>>>>>>>>                    RendererFactory rendererFactory = null;
>>>>>>>>>>>>>>>>                    FOUserAgent foUserAgent = null;
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>                    rendererFactory =
>>>>>>>>>>>>>>>> fopFactory.getRendererFactory();
>>>>>>>>>>>>>>>>                    rendererFactory.addRendererMaker(new
>>>>>>>>>>>>>>>> MultiRendererMaker("jpeg"));
>>>>>>>>>>>>>>>>                    foUserAgent =
>>>>>>>>>>>>>>>> fopFactory.newFOUserAgent();
>>>>>>>>>>>>>>>>                   
>>>>>>>>>>>>>>>> rendererFactory.createRenderer(foUserAgent,
>>>>>>>>>>>>>>>> "image/jpeg");
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>                    Fop fop =
>>>>>>>>>>>>>>>> fopFactory.newFop("image/jpeg",
>>>>>>>>>>>>>>>> foUserAgent,
>>>>>>>>>>>>>>>> out);
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> //Use fop as normal case
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> Since you're now into xmlgraphics, I think you're best bet
>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>> here
>>>>>>>>>>>>>>>>> <http://xmlgraphics.apache.org/commons/image-loader.html>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> On 06/07/2011 10:18 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> Hi ok this is for generate images that dont need to be
>>>>>>>>>>>>>>>>>> decompress
>>>>>>>>>>>>>>>>>> later??
>>>>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>>>>> the result image i put in my xsl ?? then it should work,
>>>>>>>>>>>>>>>>>> aaa
>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>> change
>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>> fop
>>>>>>>>>>>>>>>>>> 1.0 and xml communs 1.4 and its the same jejeje   dont
>>>>>>>>>>>>>>>>>> find
>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>> image
>>>>>>>>>>>>>>>>>> preload
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> org.apache.fop.fo.flow.ExternalGraphic bind
>>>>>>>>>>>>>>>>>> SEVERE: Image not available: The file format is not
>>>>>>>>>>>>>>>>>> supported.
>>>>>>>>>>>>>>>>>> No
>>>>>>>>>>>>>>>>>> ImagePreloader for *.jpg or *.bmp
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> ImageIO.write(bufferedImage, "JPEG", file);
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> On 06/07/2011 08:21 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> Ok i actually register the handler now what i have to
>>>>>>>>>>>>>>>>>>>> do
>>>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>>>> setup
>>>>>>>>>>>>>>>>>>>> this
>>>>>>>>>>>>>>>>>>>> handler or not?? and how can i do that, also it seem
>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>> bmp
>>>>>>>>>>>>>>>>>>>> its
>>>>>>>>>>>>>>>>>>>> not
>>>>>>>>>>>>>>>>>>>> recognice also what can i do?? thanks for the help rob
>>>>>>>>>>>>>>>>>>>> also i am trying to convert the images to see if it
>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>> helps
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> On 06/06/2011 02:29 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> Hi what can be the difference between execute the
>>>>>>>>>>>>>>>>>>>>>> program
>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>> netbeans
>>>>>>>>>>>>>>>>>>>>>> (where
>>>>>>>>>>>>>>>>>>>>>> it works and print the images and the jar in the
>>>>>>>>>>>>>>>>>>>>>> console)
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> Different classes being loaded by Netbeans than the
>>>>>>>>>>>>>>>>>>>>> console
>>>>>>>>>>>>>>>>>>>>> app.
>>>>>>>>>>>>>>>>>>>>> Get
>>>>>>>>>>>>>>>>>>>>> Netbeans to show you the full classpath it's using in
>>>>>>>>>>>>>>>>>>>>> it's
>>>>>>>>>>>>>>>>>>>>> "%classpath"
>>>>>>>>>>>>>>>>>>>>> variable
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> also i tried the
>>>>>>>>>>>>>>>>>>>>>> imageIO.getImageReadersBySuffix but i cant
>>>>>>>>>>>>>>>>>>>>>> interpretate
>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>> data
>>>>>>>>>>>>>>>>>>>>>> y.y,
>>>>>>>>>>>>>>>>>>>>>> its
>>>>>>>>>>>>>>>>>>>>>> that or always its true in the boolean variable, and
>>>>>>>>>>>>>>>>>>>>>> how
>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>> register
>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>> handler??
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> Talk to IIORegistry, some thing like
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>>>>>>>>>> CLibJPEGImageReaderSpi());
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>>>>>>>>>> CLibJPEGImageWriterSpi());
>>>>>>>>>>>>>>>>>>>>> Note: those are not necessarily the services you have
>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>> your
>>>>>>>>>>>>>>>>>>>>> setup.
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> Thanks
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> See the javadoc on IIORegistry. With ImageIO you may
>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>> register
>>>>>>>>>>>>>>>>>>>>>>> your handler(s). What does
>>>>>>>>>>>>>>>>>>>>>>> ImageIO.getImageReadersBySuffix()
>>>>>>>>>>>>>>>>>>>>>>> give
>>>>>>>>>>>>>>>>>>>>>>> you.
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> For certain jpegs we don't use ImageIO, rather the
>>>>>>>>>>>>>>>>>>>>>>> classes
>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>> com.sun.image.codec.jpeg:
>>>>>>>>>>>>>>>>>>>>>>>                    try {
>>>>>>>>>>>>>>>>>>>>>>>                        FileOutputStream fos = new
>>>>>>>>>>>>>>>>>>>>>>> FileOutputStream(file);
>>>>>>>>>>>>>>>>>>>>>>>                        JPEGImageEncoder encoder =
>>>>>>>>>>>>>>>>>>>>>>> JPEGCodec.createJPEGEncoder(fos);
>>>>>>>>>>>>>>>>>>>>>>>                        JPEGEncodeParam param =
>>>>>>>>>>>>>>>>>>>>>>> encoder.getDefaultJPEGEncodeParam(image.getRaster(),
>>>>>>>>>>>>>>>>>>>>>>> JPEGDecodeParam.COLOR_ID_CMYK);
>>>>>>>>>>>>>>>>>>>>>>>                        param.setQuality(1, false);
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> encoder.encode(image.getRaster(),
>>>>>>>>>>>>>>>>>>>>>>> param);
>>>>>>>>>>>>>>>>>>>>>>>                        fos.close();
>>>>>>>>>>>>>>>>>>>>>>>                    } catch (Throwable t) {
>>>>>>>>>>>>>>>>>>>>>>>                        logger.debug(t.getMessage());
>>>>>>>>>>>>>>>>>>>>>>>                    }
>>>>>>>>>>>>>>>>>>>>>>> But generally we use ImageIO
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> On 06/06/2011 08:29 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> Yeah i think i need your help again i tried tu run
>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>> .jar
>>>>>>>>>>>>>>>>>>>>>>>> file
>>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>> console it work but without images this it what
>>>>>>>>>>>>>>>>>>>>>>>> appears
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> GRAVE: Error while processing image: I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException:
>>>>>>>>>>>>>>>>>>>>>>>> Cannot
>>>>>>>>>>>>>>>>>>>>>>>> load
>>>>>>>>>>>>>>>>>>>>>>>> image
>>>>>>>>>>>>>>>>>>>>>>>> (no
>>>>>>>>>>>>>>>>>>>>>>>> suitable loader/converter combination available)
>>>>>>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> i tried  download the jai-imagio add to the class
>>>>>>>>>>>>>>>>>>>>>>>> path
>>>>>>>>>>>>>>>>>>>>>>>> but
>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>> dont
>>>>>>>>>>>>>>>>>>>>>>>> work
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> Very odd.  I'm having no problems getting images
>>>>>>>>>>>>>>>>>>>>>>>>> into
>>>>>>>>>>>>>>>>>>>>>>>>> pdfs
>>>>>>>>>>>>>>>>>>>>>>>>> using
>>>>>>>>>>>>>>>>>>>>>>>>> fop-1.0.
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> On 06/03/2011 11:04 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> aaa hey thanks for the help the other day, i
>>>>>>>>>>>>>>>>>>>>>>>>>> resolve
>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>> problem
>>>>>>>>>>>>>>>>>>>>>>>>>> changing
>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>> version of FOP for the 0.95beta instead of the
>>>>>>>>>>>>>>>>>>>>>>>>>> 1.0,
>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>> works
>>>>>>>>>>>>>>>>>>>>>>>>>> now
>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>> prints
>>>>>>>>>>>>>>>>>>>>>>>>>> the image and its good, thanks and we are in
>>>>>>>>>>>>>>>>>>>>>>>>>> touch
>>>>>>>>>>>>>>>>>>>>>>>>>> if
>>>>>>>>>>>>>>>>>>>>>>>>>> anything
>>>>>>>>>>>>>>>>>>>>>>>>>> else
>>>>>>>>>>>>>>>>>>>>>>>>>> fails
>>>>>>>>>>>>>>>>>>>>>>>>>> jejeje
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> Nothing in the log from the transformer?
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/03/2011 09:47 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>> hi there i have another problem i hope you can
>>>>>>>>>>>>>>>>>>>>>>>>>>>> help
>>>>>>>>>>>>>>>>>>>>>>>>>>>> me
>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>> create
>>>>>>>>>>>>>>>>>>>>>>>>>>>> with foe has no image, it dont show any of
>>>>>>>>>>>>>>>>>>>>>>>>>>>> them,
>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>> xsl
>>>>>>>>>>>>>>>>>>>>>>>>>>>> seems
>>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>>> be
>>>>>>>>>>>>>>>>>>>>>>>>>>>> rigth i
>>>>>>>>>>>>>>>>>>>>>>>>>>>> tested with EditX and the pdf show me the
>>>>>>>>>>>>>>>>>>>>>>>>>>>> image,
>>>>>>>>>>>>>>>>>>>>>>>>>>>> what
>>>>>>>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>>> be,
>>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>>>>>> xmlgraphics-commons-1.5svn, fop 1.0,
>>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-pdf-images
>>>>>>>>>>>>>>>>>>>>>>>>>>>> 2.0.1
>>>>>>>>>>>>>>>>>>>>>>>>>>>> Snapshot
>>>>>>>>>>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>>> render of the image but it don work please
>>>>>>>>>>>>>>>>>>>>>>>>>>>> help!!!
>>>>>>>>>>>>>>>>>>>>>>>>>>>> :,(
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> :-):confused::confused::confused::confused:=)
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>> http://old.nabble.com/file/p31822059/libraries.jpeg
>>>>>>>>>>>> http://old.nabble.com/file/p31822059/libraries.bmp
>>>>>>>>>>>> libraries.bmp
>>>>>>>>>>>>
>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>> For additional commands, e-mail:
>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>> ---------------------------------------------------------------------
>>>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>> For additional commands, e-mail:
>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>
>>>>>>>
>>>>>>>
>>>>> ---------------------------------------------------------------------
>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>>>
>>>>>
>>>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>
>>>
>>>
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
> 
> 
> 

-- 
View this message in context: http://old.nabble.com/Problems-with-FOP-and-image-tp31766430p31843326.html
Sent from the FOP - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Problems with FOP and image

Posted by Rob Sargent <rs...@xmission.com>.
Some jar to which netbeans has access has those classes.  Look in the 
output of jar tvf <each of your jars> and see if any of those has the 
named classes.  If you find a jar with those classes make sure it's part 
of your classpath for you app.

Are you making any calls like ImageIO.write(BufferedImage, "JPEG", 
jpegImageFile)?

On 06/13/2011 05:31 PM, Oscar.Flores wrote:
> ok i made a test and tell me that the class is missign but maybe what you say
> its rigth and it register the handler
> so i gonna register the services so i do this
>
>   public static void main(String[] args) throws Exception {
>           DOMConfigurator.configure("D:/Mis
> documentos/NetBeansProjects/Factura/src/factura/log4j.xml");
>           logger.info("Entering application.");
>            IIORegistry.getDefaultInstance().registerServiceProvider(new
> CLibJPEGImageReaderSpi());
>            IIORegistry.getDefaultInstance().registerServiceProvider(new
> CLibJPEGImageWriterSpi());
>
> also after register my services it telling me that the class
> CLibJPEGImageReaderSpi() and CLibJPEGImageWriterSpi() is missing but only in
> command
>
> after register mi service, something more has to be done??
>
>
> Rob Sargent-4 wrote:
>> I'm not sure I'm following correctly: does removing the xmlgraphics jar
>> cause netbeans to behave the same as the command-line run of you app? If
>> so, I suspect netbeans is registering services for you.  Your own code
>> will have to make a call to one of the
>> IIORegistry.registerServiceProvider() methods.
>>
>> On 06/13/2011 05:02 PM, Oscar.Flores wrote:
>>> Ok aaaa i get it, actually the ImageIO library i added because i read in
>>> the
>>> xmlgrapics that if something like the message
>>> org.apache.xmlgraphics.image.loader.ImageException: Cannot load image (no
>>> suitable loader/converter combination available)appear i have to add the
>>> jar
>>> file to the classpath but that all it say no configuration or anything,
>>> then
>>> i delete the imagenIO libs and still i have the same output in netbeans
>>> so
>>> xmlgrapics seem to have the problem in the plugins or i have to configure
>>> something
>>>
>>> Rob Sargent-4 wrote:
>>>> Then it seems to me netbeans (if it's producing good output ==
>>>> assumptionA) is still using something that the command-line isn't.
>>>>
>>>> And given assumptionA, you're java code is correct in terms of FOP and
>>>> your configuration isn't for ImageIO.  Show your ImageIO related code
>>>> and are you sure it's in your app.  Use the logger to show a message
>>>> when you add  your loader.  Or list all ImageIO services:
>>>> IIORegistry.getServiceProviders()
>>>>
>>>> On 06/13/2011 03:01 PM, Oscar.Flores wrote:
>>>>> ok well i put the xml in scr of my proyect i see that i still have the
>>>>> same
>>>>> issues of the image render of any image i dont now if the xml its in
>>>>> place i
>>>>> put the code down to see if something its missing
>>>>>
>>>>> 15:45:07,827 ERROR [render] Error while processing image:
>>>>> c:\cfd\nombregp.bmp (i
>>>>> mage/bmp)
>>>>> org.apache.xmlgraphics.image.loader.ImageException: Cannot load image
>>>>> (no
>>>>> suitab
>>>>> le loader/converter combination available) for c:\cfd\nombregp.bmp
>>>>> (image/bmp)
>>>>>            at
>>>>> org.apache.xmlgraphics.image.loader.ImageManager.getImage(ImageManage
>>>>>
>>>>>
>>>>>
>>>>> import mx.bigdata.sat.cfd.schema.Comprobante;
>>>>> import mx.bigdata.sat.cfd.CFDv2;
>>>>> import mx.bigdata.sat.security.KeyLoader;
>>>>> import org.jdom.*;
>>>>> import org.jdom.input.SAXBuilder;
>>>>> import org.jdom.output.XMLOutputter;
>>>>> import org.jdom.output.Format;
>>>>> import org.jdom.transform.JDOMSource;
>>>>> //Java
>>>>>     import java.io.File;
>>>>>     import java.io.OutputStream;
>>>>>
>>>>>     //JAXP
>>>>>     import javax.xml.transform.Transformer;
>>>>>     import javax.xml.transform.TransformerFactory;
>>>>>     import javax.xml.transform.Source;
>>>>>     import javax.xml.transform.Result;
>>>>>     import javax.xml.transform.stream.StreamSource;
>>>>>     import javax.xml.transform.sax.SAXResult;
>>>>>
>>>>>     //FOP
>>>>>     import org.apache.fop.apps.FOUserAgent;
>>>>>     import org.apache.fop.apps.Fop;
>>>>>     import org.apache.fop.apps.FopFactory;
>>>>>     import org.apache.fop.apps.MimeConstants;
>>>>>
>>>>>     //log4j
>>>>>     import org.apache.log4j.*;
>>>>>     import org.apache.log4j.xml.DOMConfigurator;
>>>>>
>>>>> public final class Main {
>>>>>        @SuppressWarnings("unchecked")
>>>>>        static Logger logger = Logger.getLogger(Main.class);
>>>>>
>>>>>        public static void main(String[] args) throws Exception {
>>>>>             DOMConfigurator.configure("D:/Mis
>>>>> documentos/NetBeansProjects/Factura/src/factura/log4j.xml");
>>>>>             logger.info("Entering application.");
>>>>>             try {
>>>>>                File file = new File(args[0]);
>>>>>                Comprobante comp = CFDv2.newComprobante(new
>>>>> FileInputStream(file));
>>>>>                CFDv2 cfd = new CFDv2(comp);
>>>>>                PrivateKey key = KeyLoader.loadPKCS8PrivateKey(new
>>>>> FileInputStream(args[1]),(args[2]));
>>>>>                X509Certificate cert = KeyLoader.loadX509Certificate(new
>>>>> FileInputStream(args[3]));
>>>>>                Comprobante sellado = cfd.sellarComprobante(key, cert);
>>>>>                String cadena = cfd.getCadenaOriginal();
>>>>>                String sello = sellado.getSello();
>>>>>                // Creamos el builder basado en SAX
>>>>>                SAXBuilder builder = new SAXBuilder();
>>>>>                // Construimos el arbol DOM a partir del fichero xml
>>>>>                Document documentJDOM = builder.build(new
>>>>> FileInputStream(args[0]));
>>>>>
>>>>>
>>>>>                Element raiz = documentJDOM.getRootElement();//toma el
>>>>> nodo
>>>>> raiz
>>>>> del documento.
>>>>>                raiz.setAttribute("sello", sello);
>>>>>                raiz.setAttribute("certificado",
>>>>> sellado.getCertificado());
>>>>>                //System.out.println(raiz.getAttributeValue("sello"));
>>>>>
>>>>> //System.out.println(raiz.getAttributeValue("certificado"));
>>>>>                // Recorremos los hijos de la etiqueta raíz
>>>>>                List<Element>    hijosRaiz = raiz.getChildren();
>>>>>                boolean Bandera=false;
>>>>>                for(Element hijo: hijosRaiz)
>>>>>                {
>>>>>                    // Obtenemos el nombre y su contenido de tipo texto
>>>>>                    String nombre = hijo.getName();
>>>>>
>>>>>                    if (nombre.equals("Addenda"))
>>>>>                    {   List<Element>    subHijo = hijo.getChildren();
>>>>>                        for(Element hij: subHijo)
>>>>>                            {
>>>>>                            hij.setAttribute("CadenaOriginal", cadena);
>>>>>                            //System.out.println("CadenaOriginal:
>>>>> "+hij.getAttributeValue("CadenaOriginal"));
>>>>>                            Bandera=true;
>>>>>                            break;
>>>>>                            }
>>>>>                    }
>>>>>                    if (Bandera)
>>>>>                    {
>>>>>                        XMLOutputter out = new
>>>>> XMLOutputter(Format.getPrettyFormat());
>>>>>                        File nuevoXML = new File(args[0]);
>>>>>                        try{
>>>>>                            FileOutputStream archivoXML= new
>>>>> FileOutputStream
>>>>> (nuevoXML);
>>>>>                            out.output(documentJDOM, archivoXML);
>>>>>
>>>>>                           }
>>>>>                        catch (Exception
>>>>> ex){System.out.println(ex.getMessage());}
>>>>>                        // Para generar el pdf a partir de un archivo.xsl
>>>>> y
>>>>> un
>>>>>                        // archivo.xml
>>>>>                    }
>>>>>                  }
>>>>>              // configure fopFactory as desired
>>>>>              FopFactory fopFactory = FopFactory.newInstance();
>>>>>              FOUserAgent foUserAgent = fopFactory.newFOUserAgent();
>>>>>
>>>>>              // configure foUserAgent as desired
>>>>>              // Setup output
>>>>>             File pdffile = new File(args[5]);
>>>>>
>>>>>             OutputStream out = new java.io.FileOutputStream(pdffile);
>>>>>             out = new java.io.BufferedOutputStream(out);
>>>>>             try {
>>>>>                    // Construct fop with desired output format
>>>>>                     Fop fop = fopFactory.newFop(MimeConstants.MIME_PDF,
>>>>> foUserAgent, out);
>>>>>                    // Setup XSLT
>>>>>                    TransformerFactory factory =
>>>>> TransformerFactory.newInstance();
>>>>>                    Transformer transformer = factory.newTransformer(new
>>>>> StreamSource(args[4]));
>>>>>                    // Set the value of a  in the stylesheet
>>>>>                    transformer.setParameter("versionParam", "2.0");
>>>>>
>>>>>                   // Setup input for XSLT transformation
>>>>>                    Source src = new JDOMSource(documentJDOM);
>>>>>                     // Resulting SAX events (the generated FO) must be
>>>>> piped
>>>>> through to FOP
>>>>>                    Result res = new SAXResult(fop.getDefaultHandler());
>>>>>                     // Start XSLT transformation and FOP processing
>>>>>                   // System.setProperty("java.awt.headless", "true");
>>>>>                        transformer.transform(src, res);
>>>>>                    } finally {
>>>>>                     out.close();
>>>>>                }
>>>>>
>>>>>
>>>>>              System.out.println("Success!");
>>>>>             } catch (Exception e) {
>>>>>              e.printStackTrace(System.err);
>>>>>              System.exit(-1);
>>>>>           }
>>>>>         logger.info("Exiting application.");
>>>>>
>>>>>      }
>>>>>
>>>>>
>>>>> Rob Sargent-4 wrote:
>>>>>> Try this log4j.xml: Place it at the root of your jar file
>>>>>>
>>>>>> <?xml version="1.0" encoding="UTF-8"?>
>>>>>> <!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">
>>>>>>
>>>>>> <log4j:configuration xmlns:log4j="http://jakarta.apache.org/log4j/"
>>>>>> debug="false">
>>>>>>
>>>>>> <appender name="CONSOLE" class="org.apache.log4j.ConsoleAppender">
>>>>>>
>>>>>>
>>>>>>
>>>>>> <layout class="org.apache.log4j.PatternLayout">
>>>>>>
>>>>>> </layout>
>>>>>> </appender>
>>>>>>
>>>>>> <category name="org">
>>>>>> <priority value="DEBUG"/>
>>>>>> </category>
>>>>>> <category name="org.apache">
>>>>>> <priority value="WARN"/>
>>>>>> </category>
>>>>>> <category name="org.springframework">
>>>>>> <priority value="WARN"/>
>>>>>> </category>
>>>>>> <category name="org.hibernate">
>>>>>> <priority value="DEBUG"/>
>>>>>> </category>
>>>>>> <category name="net">
>>>>>> <priority value="ERROR"/>
>>>>>> </category>
>>>>>> <category name="javax">
>>>>>> <priority value="ERROR"/>
>>>>>> </category>
>>>>>> <category name="java">
>>>>>> <priority value="ERROR"/>
>>>>>> </category>
>>>>>> <category name="sun">
>>>>>> <priority value="ERROR"/>
>>>>>> </category>
>>>>>> <category name="org.jboss">
>>>>>> <priority value="INFO"/>
>>>>>> </category>
>>>>>> <category name="org.jboss.seam">
>>>>>> <priority value="ERROR"/>
>>>>>> </category>
>>>>>> <root>
>>>>>> <appender-ref ref="CONSOLE"/>
>>>>>> </root>
>>>>>>
>>>>>> </log4j:configuration>
>>>>>>
>>>>>>
>>>>>> On 06/13/2011 11:06 AM, Oscar.Flores wrote:
>>>>>>> ok i dont thik i have a configuracion file i find the code that i put
>>>>>>> in
>>>>>>> the
>>>>>>> other post i think its the basic
>>>>>>>
>>>>>>>
>>>>>>> Rob Sargent-4 wrote:
>>>>>>>> Do you have a config file for log4j.  Usually it's in a resource
>>>>>>>> tree.
>>>>>>>> Are you copying that to your deployment? Is your ant script
>>>>>>>> including
>>>>>>>> the config file in the jar of your application?
>>>>>>>>
>>>>>>>> On 06/13/2011 10:12 AM, Oscar.Flores wrote:
>>>>>>>>> Ok yeah the log4j its having isuees to find the configuration
>>>>>>>>>
>>>>>>>>> log4j:WARN No appenders could be found for logger
>>>>>>>>> (org.apache.fop.util.ContentHandlerFactoryRegistry).
>>>>>>>>> log4j:WARN Please initialize the log4j system properly.
>>>>>>>>> log4j:WARN See
>>>>>>>>> http://logging.apache.org/log4j/1.2/faq.html#noconfig
>>>>>>>>> for
>>>>>>>>> more info.
>>>>>>>>> i go to the faq guide and it say try loading the class or resource
>>>>>>>>> yourself.
>>>>>>>>> If you can't find it, neither will log4j.
>>>>>>>>>
>>>>>>>>> aaa i dont know where to set this
>>>>>>>>>
>>>>>>>>> also here its my xlst
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> http://old.nabble.com/file/p31835645/FacturasOMF.xsl
>>>>>>>>> FacturasOMF.xsl
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> and the fo file that generate the editix
>>>>>>>>>
>>>>>>>>> http://old.nabble.com/file/p31835645/Prueba.fo Prueba.fo
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>> The first thing is to really dig into what you did to netbeans to
>>>>>>>>>> get
>>>>>>>>>> it
>>>>>>>>>> to work...
>>>>>>>>>>
>>>>>>>>>> I've forgotten what your stylesheet looked like, so maybe if you
>>>>>>>>>> show
>>>>>>>>>> us
>>>>>>>>>> again how you're referencing your images we might notice a
>>>>>>>>>> problem.
>>>>>>>>>>
>>>>>>>>>> It might also help to see the "fo" generated during your
>>>>>>>>>> transformation.
>>>>>>>>>> Can you grab that just after xslt and just before fop calls.
>>>>>>>>>>
>>>>>>>>>> Are you sure there is no error being logged somewhere when you run
>>>>>>>>>> from
>>>>>>>>>> the command line? (Where is log4j writing and at what level?)
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> Oscar.Flores wrote:
>>>>>>>>>>> You where absolutly rigth i miss a few libraries to add into the
>>>>>>>>>>> jar
>>>>>>>>>>> file, i
>>>>>>>>>>> modified the build.xml to add the package and jar that i need,
>>>>>>>>>>> now
>>>>>>>>>>> the
>>>>>>>>>>> error
>>>>>>>>>>> message is not there but still the images dont show in the pdf i
>>>>>>>>>>> remeber
>>>>>>>>>>> that i do something in netbeans so they can add to the pdf but i
>>>>>>>>>>> cant
>>>>>>>>>>> remeber i dont now if there is still a library that is missing or
>>>>>>>>>>> i
>>>>>>>>>>> am
>>>>>>>>>>> adding more than it should be
>>>>>>>>>>> This is what i use :
>>>>>>>>>>> cfdi-base-0.1.6-SNAPSHOT.jar
>>>>>>>>>>> guava-r09.jar
>>>>>>>>>>> guava-r09-gwt.jar
>>>>>>>>>>> jaxb-impl-2.1.10.jar
>>>>>>>>>>> avalon-framework-api-4.3.jar
>>>>>>>>>>> avalon-framework-cvs-20020806.jar
>>>>>>>>>>> avalon-logkit-2.1.jar
>>>>>>>>>>> not-yet-commons-ssl-0.3.11.jar
>>>>>>>>>>> commons-codec-1.5.jar
>>>>>>>>>>> commons-codec-1.5-sources.jar
>>>>>>>>>>> log4j-1.2.16.jar
>>>>>>>>>>> fop.jar
>>>>>>>>>>> jdom.jar
>>>>>>>>>>> xmlgraphics-commons-1.4.jar
>>>>>>>>>>> commons-io-1.3.1.jar
>>>>>>>>>>> fop-pdf-images-2.0.1.SNAPSHOT.jar
>>>>>>>>>>> pdfbox-app-1.5.0.jar
>>>>>>>>>>> fontbox-1.3.1.jar
>>>>>>>>>>> jempbox-1.3.1.jar
>>>>>>>>>>> xercesImpl-2.7.1.jar
>>>>>>>>>>> batik-all-1.7.jar
>>>>>>>>>>> xml-apis-1.3.04.jar
>>>>>>>>>>> xml-apis-ext-1.3.04.jar
>>>>>>>>>>>       avalon-framework-4.2.0.jar
>>>>>>>>>>>       xalan-2.7.0.jar
>>>>>>>>>>>       serializer-2.7.0.jar
>>>>>>>>>>>       commons-logging-1.0.4.jar
>>>>>>>>>>>       jai_codec.jar
>>>>>>>>>>>       jai_core.jar
>>>>>>>>>>>       batik-ext.jar
>>>>>>>>>>>       jai_imageio-1.1-sources.jar
>>>>>>>>>>>
>>>>>>>>>>> Thanks Rob for the help
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>
>>>>>>>>>>>> I suspect running from your jar does not have/use the same
>>>>>>>>>>>> classpath
>>>>>>>>>>>> that is in effect while you're in the debugger.
>>>>>>>>>>>> By what mechanism do you generate the jar?
>>>>>>>>>>>> Is it an executable jar or are you running java -classpath
>>>>>>>>>>>> <your-jar-here:other-jars>      Main?
>>>>>>>>>>>> Make your IDE (netbeans) display the classpath  it uses to run
>>>>>>>>>>>> your
>>>>>>>>>>>> app
>>>>>>>>>>>> and compare that with the above.
>>>>>>>>>>>>
>>>>>>>>>>>> On 06/09/2011 07:21 PM, Oscar.Flores wrote:
>>>>>>>>>>>>
>>>>>>>>>>>>> aaa ok well my problem is that when i do the pdf in netbean the
>>>>>>>>>>>>> pdf
>>>>>>>>>>>>> is
>>>>>>>>>>>>> fine
>>>>>>>>>>>>> with images and evething but when i run the jar file in command
>>>>>>>>>>>>> it
>>>>>>>>>>>>> give
>>>>>>>>>>>>> me a
>>>>>>>>>>>>> error
>>>>>>>>>>>>>
>>>>>>>>>>>>> GRAVE: Error while processing image: I:\cfd\rfc.jpg
>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>        org.apache.xmlgraphics.image.loader.ImageException:
>>>>>>>>>>>>> Cannot
>>>>>>>>>>>>> load
>>>>>>>>>>>>>        image (no suitable loader/converter combination
>>>>>>>>>>>>> available)
>>>>>>>>>>>>> for
>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>        (image/jpeg)
>>>>>>>>>>>>>
>>>>>>>>>>>>> so i dont no what its not working and if i have to add
>>>>>>>>>>>>> something
>>>>>>>>>>>>> to
>>>>>>>>>>>>> my
>>>>>>>>>>>>> code
>>>>>>>>>>>>> so the images can load i am soooo desperate what i am doing
>>>>>>>>>>>>> wrong??
>>>>>>>>>>>>> i am sorry for the trouble and if a dont explain my self very
>>>>>>>>>>>>> good
>>>>>>>>>>>>> jejeje
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>
>>>>>>>>>>>>>> Not at all sure what your problem is.  All I can do is show
>>>>>>>>>>>>>> you
>>>>>>>>>>>>>> what
>>>>>>>>>>>>>> works for us.
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> Our source xml looks like this:
>>>>>>>>>>>>>> <image image-id="381623861" reference-id="ref-220" width="750"
>>>>>>>>>>>>>> height="750" image-space-id="space-1" position="5"
>>>>>>>>>>>>>>                     image-pool-position="31" pos="4"
>>>>>>>>>>>>>>                     file="ref_10_1002108221">       <!-- an
>>>>>>>>>>>>>> actual
>>>>>>>>>>>>>> file
>>>>>>>>>>>>>> (.jpeg
>>>>>>>>>>>>>> copied the working directory of the transformer -->
>>>>>>>>>>>>>> <fields />
>>>>>>>>>>>>>> <caption />
>>>>>>>>>>>>>> <annotations>
>>>>>>>>>>>>>> <arrow_positions origHeight="750" origWidth="750" />
>>>>>>>>>>>>>> </annotations>
>>>>>>>>>>>>>> </image>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> Our xslt looks like this for each image needed.
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> <xsl:template name="image">
>>>>>>>>>>>>>> <xsl:param name="img"/>       <!-- This is the xml node from
>>>>>>>>>>>>>> the
>>>>>>>>>>>>>> source
>>>>>>>>>>>>>> xml
>>>>>>>>>>>>>> above -->
>>>>>>>>>>>>>> <xsl:param name="width"/>
>>>>>>>>>>>>>> <xsl:param name="height" select="$width"/>
>>>>>>>>>>>>>> <xsl:param name="ignoreHeight">false</xsl:param>
>>>>>>>>>>>>>> <fo:block>
>>>>>>>>>>>>>> <fo:external-graphic src="{$img/@file}" height="{$height}"
>>>>>>>>>>>>>> width="{$width}" content-height="scale-to-fit"
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> content-width="scale-to-fit"
>>>>>>>>>>>>>> border="0.5pt solid black" border-collapse="separate">
>>>>>>>>>>>>>> <xsl:if test="$ignoreHeight != 'true'">
>>>>>>>>>>>>>> <xsl:attribute name="height">
>>>>>>>>>>>>>> <xsl:value-of select="$height"/>
>>>>>>>>>>>>>> </xsl:attribute>
>>>>>>>>>>>>>> </xsl:if>
>>>>>>>>>>>>>> </fo:external-graphic>
>>>>>>>>>>>>>> </fo:block>
>>>>>>>>>>>>>> </xsl:template>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> Our generated fo looks like this:
>>>>>>>>>>>>>> <fo:table-cell>
>>>>>>>>>>>>>> <fo:block>
>>>>>>>>>>>>>> <fo:external-graphic border-collapse="separate" border="0.5pt
>>>>>>>>>>>>>> solid
>>>>>>>>>>>>>> black" content-width="scale-to-fit"
>>>>>>>>>>>>>> content-height="scale-to-fit"
>>>>>>>>>>>>>> width="2.5in" height="2.5in" src="ref_10_1002108221" />
>>>>>>>>>>>>>> </fo:block>
>>>>>>>>>>>>>> </fo:table-cell>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> And the generated pdfs include the image and are shipped to
>>>>>>>>>>>>>> the
>>>>>>>>>>>>>> printer.
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> How does this stack up with what you have?
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> On 06/09/2011 01:19 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> Hi there well i still got the problem but searching IN
>>>>>>>>>>>>>>> INTERNET
>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>> find
>>>>>>>>>>>>>>> a
>>>>>>>>>>>>>>> JPEG
>>>>>>>>>>>>>>> renderer output for FOP its here
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> http://marc.info/?l=fop-user&m=125986752706366&w=2
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> the cuestion is can i render the image that i want to put in
>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>> pdf,
>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>> then add to the xsl the render jpeg it will work??
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> and here explaints how use the render when he say uses fop as
>>>>>>>>>>>>>>> normal
>>>>>>>>>>>>>>> case
>>>>>>>>>>>>>>> what does it mean
>>>>>>>>>>>>>>> what else have to add to the code?? i hope you can help me
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> Thanks!!
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> // OutputStream out = what you want
>>>>>>>>>>>>>>>                    FopFactory fopFactory =
>>>>>>>>>>>>>>> FopFactory.newInstance();
>>>>>>>>>>>>>>>                    RendererFactory rendererFactory = null;
>>>>>>>>>>>>>>>                    FOUserAgent foUserAgent = null;
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>                    rendererFactory =
>>>>>>>>>>>>>>> fopFactory.getRendererFactory();
>>>>>>>>>>>>>>>                    rendererFactory.addRendererMaker(new
>>>>>>>>>>>>>>> MultiRendererMaker("jpeg"));
>>>>>>>>>>>>>>>                    foUserAgent = fopFactory.newFOUserAgent();
>>>>>>>>>>>>>>>                    rendererFactory.createRenderer(foUserAgent,
>>>>>>>>>>>>>>> "image/jpeg");
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>                    Fop fop = fopFactory.newFop("image/jpeg",
>>>>>>>>>>>>>>> foUserAgent,
>>>>>>>>>>>>>>> out);
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> //Use fop as normal case
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> Since you're now into xmlgraphics, I think you're best bet
>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>> here
>>>>>>>>>>>>>>>> <http://xmlgraphics.apache.org/commons/image-loader.html>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> On 06/07/2011 10:18 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> Hi ok this is for generate images that dont need to be
>>>>>>>>>>>>>>>>> decompress
>>>>>>>>>>>>>>>>> later??
>>>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>>>> the result image i put in my xsl ?? then it should work,
>>>>>>>>>>>>>>>>> aaa
>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>> change
>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>> fop
>>>>>>>>>>>>>>>>> 1.0 and xml communs 1.4 and its the same jejeje   dont find
>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>> image
>>>>>>>>>>>>>>>>> preload
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> org.apache.fop.fo.flow.ExternalGraphic bind
>>>>>>>>>>>>>>>>> SEVERE: Image not available: The file format is not
>>>>>>>>>>>>>>>>> supported.
>>>>>>>>>>>>>>>>> No
>>>>>>>>>>>>>>>>> ImagePreloader for *.jpg or *.bmp
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> ImageIO.write(bufferedImage, "JPEG", file);
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> On 06/07/2011 08:21 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> Ok i actually register the handler now what i have to do
>>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>>> setup
>>>>>>>>>>>>>>>>>>> this
>>>>>>>>>>>>>>>>>>> handler or not?? and how can i do that, also it seem that
>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>> bmp
>>>>>>>>>>>>>>>>>>> its
>>>>>>>>>>>>>>>>>>> not
>>>>>>>>>>>>>>>>>>> recognice also what can i do?? thanks for the help rob
>>>>>>>>>>>>>>>>>>> also i am trying to convert the images to see if it that
>>>>>>>>>>>>>>>>>>> helps
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> On 06/06/2011 02:29 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> Hi what can be the difference between execute the
>>>>>>>>>>>>>>>>>>>>> program
>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>> netbeans
>>>>>>>>>>>>>>>>>>>>> (where
>>>>>>>>>>>>>>>>>>>>> it works and print the images and the jar in the
>>>>>>>>>>>>>>>>>>>>> console)
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> Different classes being loaded by Netbeans than the
>>>>>>>>>>>>>>>>>>>> console
>>>>>>>>>>>>>>>>>>>> app.
>>>>>>>>>>>>>>>>>>>> Get
>>>>>>>>>>>>>>>>>>>> Netbeans to show you the full classpath it's using in
>>>>>>>>>>>>>>>>>>>> it's
>>>>>>>>>>>>>>>>>>>> "%classpath"
>>>>>>>>>>>>>>>>>>>> variable
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> also i tried the
>>>>>>>>>>>>>>>>>>>>> imageIO.getImageReadersBySuffix but i cant interpretate
>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>> data
>>>>>>>>>>>>>>>>>>>>> y.y,
>>>>>>>>>>>>>>>>>>>>> its
>>>>>>>>>>>>>>>>>>>>> that or always its true in the boolean variable, and
>>>>>>>>>>>>>>>>>>>>> how
>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>> register
>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>> handler??
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> Talk to IIORegistry, some thing like
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>>>>>>>>> CLibJPEGImageReaderSpi());
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>>>>>>>>> CLibJPEGImageWriterSpi());
>>>>>>>>>>>>>>>>>>>> Note: those are not necessarily the services you have in
>>>>>>>>>>>>>>>>>>>> your
>>>>>>>>>>>>>>>>>>>> setup.
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> Thanks
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> See the javadoc on IIORegistry. With ImageIO you may
>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>> register
>>>>>>>>>>>>>>>>>>>>>> your handler(s). What does
>>>>>>>>>>>>>>>>>>>>>> ImageIO.getImageReadersBySuffix()
>>>>>>>>>>>>>>>>>>>>>> give
>>>>>>>>>>>>>>>>>>>>>> you.
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> For certain jpegs we don't use ImageIO, rather the
>>>>>>>>>>>>>>>>>>>>>> classes
>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>> com.sun.image.codec.jpeg:
>>>>>>>>>>>>>>>>>>>>>>                    try {
>>>>>>>>>>>>>>>>>>>>>>                        FileOutputStream fos = new
>>>>>>>>>>>>>>>>>>>>>> FileOutputStream(file);
>>>>>>>>>>>>>>>>>>>>>>                        JPEGImageEncoder encoder =
>>>>>>>>>>>>>>>>>>>>>> JPEGCodec.createJPEGEncoder(fos);
>>>>>>>>>>>>>>>>>>>>>>                        JPEGEncodeParam param =
>>>>>>>>>>>>>>>>>>>>>> encoder.getDefaultJPEGEncodeParam(image.getRaster(),
>>>>>>>>>>>>>>>>>>>>>> JPEGDecodeParam.COLOR_ID_CMYK);
>>>>>>>>>>>>>>>>>>>>>>                        param.setQuality(1, false);
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> encoder.encode(image.getRaster(),
>>>>>>>>>>>>>>>>>>>>>> param);
>>>>>>>>>>>>>>>>>>>>>>                        fos.close();
>>>>>>>>>>>>>>>>>>>>>>                    } catch (Throwable t) {
>>>>>>>>>>>>>>>>>>>>>>                        logger.debug(t.getMessage());
>>>>>>>>>>>>>>>>>>>>>>                    }
>>>>>>>>>>>>>>>>>>>>>> But generally we use ImageIO
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> On 06/06/2011 08:29 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> Yeah i think i need your help again i tried tu run
>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>> .jar
>>>>>>>>>>>>>>>>>>>>>>> file
>>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>> console it work but without images this it what
>>>>>>>>>>>>>>>>>>>>>>> appears
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> GRAVE: Error while processing image: I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException:
>>>>>>>>>>>>>>>>>>>>>>> Cannot
>>>>>>>>>>>>>>>>>>>>>>> load
>>>>>>>>>>>>>>>>>>>>>>> image
>>>>>>>>>>>>>>>>>>>>>>> (no
>>>>>>>>>>>>>>>>>>>>>>> suitable loader/converter combination available) for
>>>>>>>>>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> i tried  download the jai-imagio add to the class
>>>>>>>>>>>>>>>>>>>>>>> path
>>>>>>>>>>>>>>>>>>>>>>> but
>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>> dont
>>>>>>>>>>>>>>>>>>>>>>> work
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> Very odd.  I'm having no problems getting images
>>>>>>>>>>>>>>>>>>>>>>>> into
>>>>>>>>>>>>>>>>>>>>>>>> pdfs
>>>>>>>>>>>>>>>>>>>>>>>> using
>>>>>>>>>>>>>>>>>>>>>>>> fop-1.0.
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> On 06/03/2011 11:04 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> aaa hey thanks for the help the other day, i
>>>>>>>>>>>>>>>>>>>>>>>>> resolve
>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>> problem
>>>>>>>>>>>>>>>>>>>>>>>>> changing
>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>> version of FOP for the 0.95beta instead of the 1.0,
>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>> works
>>>>>>>>>>>>>>>>>>>>>>>>> now
>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>> prints
>>>>>>>>>>>>>>>>>>>>>>>>> the image and its good, thanks and we are in touch
>>>>>>>>>>>>>>>>>>>>>>>>> if
>>>>>>>>>>>>>>>>>>>>>>>>> anything
>>>>>>>>>>>>>>>>>>>>>>>>> else
>>>>>>>>>>>>>>>>>>>>>>>>> fails
>>>>>>>>>>>>>>>>>>>>>>>>> jejeje
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> Nothing in the log from the transformer?
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> On 06/03/2011 09:47 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>> hi there i have another problem i hope you can
>>>>>>>>>>>>>>>>>>>>>>>>>>> help
>>>>>>>>>>>>>>>>>>>>>>>>>>> me
>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>> create
>>>>>>>>>>>>>>>>>>>>>>>>>>> with foe has no image, it dont show any of them,
>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>> xsl
>>>>>>>>>>>>>>>>>>>>>>>>>>> seems
>>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>>> be
>>>>>>>>>>>>>>>>>>>>>>>>>>> rigth i
>>>>>>>>>>>>>>>>>>>>>>>>>>> tested with EditX and the pdf show me the image,
>>>>>>>>>>>>>>>>>>>>>>>>>>> what
>>>>>>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>>> be,
>>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>>>>> xmlgraphics-commons-1.5svn, fop 1.0,
>>>>>>>>>>>>>>>>>>>>>>>>>>> fop-pdf-images
>>>>>>>>>>>>>>>>>>>>>>>>>>> 2.0.1
>>>>>>>>>>>>>>>>>>>>>>>>>>> Snapshot
>>>>>>>>>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>>> render of the image but it don work please
>>>>>>>>>>>>>>>>>>>>>>>>>>> help!!!
>>>>>>>>>>>>>>>>>>>>>>>>>>> :,(
>>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> :-):confused::confused::confused::confused:=)
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>> http://old.nabble.com/file/p31822059/libraries.jpeg
>>>>>>>>>>> http://old.nabble.com/file/p31822059/libraries.bmp libraries.bmp
>>>>>>>>>>>
>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>> ---------------------------------------------------------------------
>>>>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>> For additional commands, e-mail:
>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>> ---------------------------------------------------------------------
>>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>>>>
>>>>>>
>>>>>>
>>>> ---------------------------------------------------------------------
>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>>
>>>>
>>>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>
>>
>>

---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Problems with FOP and image

Posted by "Oscar.Flores" <fa...@hotmail.com>.
ok i made a test and tell me that the class is missign but maybe what you say
its rigth and it register the handler 
so i gonna register the services so i do this 

 public static void main(String[] args) throws Exception {
         DOMConfigurator.configure("D:/Mis
documentos/NetBeansProjects/Factura/src/factura/log4j.xml");
         logger.info("Entering application.");
          IIORegistry.getDefaultInstance().registerServiceProvider(new
CLibJPEGImageReaderSpi());
          IIORegistry.getDefaultInstance().registerServiceProvider(new
CLibJPEGImageWriterSpi());

also after register my services it telling me that the class
CLibJPEGImageReaderSpi() and CLibJPEGImageWriterSpi() is missing but only in
command

after register mi service, something more has to be done??


Rob Sargent-4 wrote:
> 
> I'm not sure I'm following correctly: does removing the xmlgraphics jar 
> cause netbeans to behave the same as the command-line run of you app? If 
> so, I suspect netbeans is registering services for you.  Your own code 
> will have to make a call to one of the 
> IIORegistry.registerServiceProvider() methods.
> 
> On 06/13/2011 05:02 PM, Oscar.Flores wrote:
>> Ok aaaa i get it, actually the ImageIO library i added because i read in
>> the
>> xmlgrapics that if something like the message
>> org.apache.xmlgraphics.image.loader.ImageException: Cannot load image (no
>> suitable loader/converter combination available)appear i have to add the
>> jar
>> file to the classpath but that all it say no configuration or anything,
>> then
>> i delete the imagenIO libs and still i have the same output in netbeans
>> so
>> xmlgrapics seem to have the problem in the plugins or i have to configure
>> something
>>
>> Rob Sargent-4 wrote:
>>> Then it seems to me netbeans (if it's producing good output ==
>>> assumptionA) is still using something that the command-line isn't.
>>>
>>> And given assumptionA, you're java code is correct in terms of FOP and
>>> your configuration isn't for ImageIO.  Show your ImageIO related code
>>> and are you sure it's in your app.  Use the logger to show a message
>>> when you add  your loader.  Or list all ImageIO services:
>>> IIORegistry.getServiceProviders()
>>>
>>> On 06/13/2011 03:01 PM, Oscar.Flores wrote:
>>>> ok well i put the xml in scr of my proyect i see that i still have the
>>>> same
>>>> issues of the image render of any image i dont now if the xml its in
>>>> place i
>>>> put the code down to see if something its missing
>>>>
>>>> 15:45:07,827 ERROR [render] Error while processing image:
>>>> c:\cfd\nombregp.bmp (i
>>>> mage/bmp)
>>>> org.apache.xmlgraphics.image.loader.ImageException: Cannot load image
>>>> (no
>>>> suitab
>>>> le loader/converter combination available) for c:\cfd\nombregp.bmp
>>>> (image/bmp)
>>>>           at
>>>> org.apache.xmlgraphics.image.loader.ImageManager.getImage(ImageManage
>>>>
>>>>
>>>>
>>>> import mx.bigdata.sat.cfd.schema.Comprobante;
>>>> import mx.bigdata.sat.cfd.CFDv2;
>>>> import mx.bigdata.sat.security.KeyLoader;
>>>> import org.jdom.*;
>>>> import org.jdom.input.SAXBuilder;
>>>> import org.jdom.output.XMLOutputter;
>>>> import org.jdom.output.Format;
>>>> import org.jdom.transform.JDOMSource;
>>>> //Java
>>>>    import java.io.File;
>>>>    import java.io.OutputStream;
>>>>
>>>>    //JAXP
>>>>    import javax.xml.transform.Transformer;
>>>>    import javax.xml.transform.TransformerFactory;
>>>>    import javax.xml.transform.Source;
>>>>    import javax.xml.transform.Result;
>>>>    import javax.xml.transform.stream.StreamSource;
>>>>    import javax.xml.transform.sax.SAXResult;
>>>>
>>>>    //FOP
>>>>    import org.apache.fop.apps.FOUserAgent;
>>>>    import org.apache.fop.apps.Fop;
>>>>    import org.apache.fop.apps.FopFactory;
>>>>    import org.apache.fop.apps.MimeConstants;
>>>>
>>>>    //log4j
>>>>    import org.apache.log4j.*;
>>>>    import org.apache.log4j.xml.DOMConfigurator;
>>>>
>>>> public final class Main {
>>>>       @SuppressWarnings("unchecked")
>>>>       static Logger logger = Logger.getLogger(Main.class);
>>>>
>>>>       public static void main(String[] args) throws Exception {
>>>>            DOMConfigurator.configure("D:/Mis
>>>> documentos/NetBeansProjects/Factura/src/factura/log4j.xml");
>>>>            logger.info("Entering application.");
>>>>            try {
>>>>               File file = new File(args[0]);
>>>>               Comprobante comp = CFDv2.newComprobante(new
>>>> FileInputStream(file));
>>>>               CFDv2 cfd = new CFDv2(comp);
>>>>               PrivateKey key = KeyLoader.loadPKCS8PrivateKey(new
>>>> FileInputStream(args[1]),(args[2]));
>>>>               X509Certificate cert = KeyLoader.loadX509Certificate(new
>>>> FileInputStream(args[3]));
>>>>               Comprobante sellado = cfd.sellarComprobante(key, cert);
>>>>               String cadena = cfd.getCadenaOriginal();
>>>>               String sello = sellado.getSello();
>>>>               // Creamos el builder basado en SAX
>>>>               SAXBuilder builder = new SAXBuilder();
>>>>               // Construimos el arbol DOM a partir del fichero xml
>>>>               Document documentJDOM = builder.build(new
>>>> FileInputStream(args[0]));
>>>>
>>>>
>>>>               Element raiz = documentJDOM.getRootElement();//toma el
>>>> nodo
>>>> raiz
>>>> del documento.
>>>>               raiz.setAttribute("sello", sello);
>>>>               raiz.setAttribute("certificado",
>>>> sellado.getCertificado());
>>>>               //System.out.println(raiz.getAttributeValue("sello"));
>>>>              
>>>> //System.out.println(raiz.getAttributeValue("certificado"));
>>>>               // Recorremos los hijos de la etiqueta raíz
>>>>               List<Element>   hijosRaiz = raiz.getChildren();
>>>>               boolean Bandera=false;
>>>>               for(Element hijo: hijosRaiz)
>>>>               {
>>>>                   // Obtenemos el nombre y su contenido de tipo texto
>>>>                   String nombre = hijo.getName();
>>>>
>>>>                   if (nombre.equals("Addenda"))
>>>>                   {   List<Element>   subHijo = hijo.getChildren();
>>>>                       for(Element hij: subHijo)
>>>>                           {
>>>>                           hij.setAttribute("CadenaOriginal", cadena);
>>>>                           //System.out.println("CadenaOriginal:
>>>> "+hij.getAttributeValue("CadenaOriginal"));
>>>>                           Bandera=true;
>>>>                           break;
>>>>                           }
>>>>                   }
>>>>                   if (Bandera)
>>>>                   {
>>>>                       XMLOutputter out = new
>>>> XMLOutputter(Format.getPrettyFormat());
>>>>                       File nuevoXML = new File(args[0]);
>>>>                       try{
>>>>                           FileOutputStream archivoXML= new
>>>> FileOutputStream
>>>> (nuevoXML);
>>>>                           out.output(documentJDOM, archivoXML);
>>>>
>>>>                          }
>>>>                       catch (Exception
>>>> ex){System.out.println(ex.getMessage());}
>>>>                       // Para generar el pdf a partir de un archivo.xsl
>>>> y
>>>> un
>>>>                       // archivo.xml
>>>>                   }
>>>>                 }
>>>>             // configure fopFactory as desired
>>>>             FopFactory fopFactory = FopFactory.newInstance();
>>>>             FOUserAgent foUserAgent = fopFactory.newFOUserAgent();
>>>>
>>>>             // configure foUserAgent as desired
>>>>             // Setup output
>>>>            File pdffile = new File(args[5]);
>>>>
>>>>            OutputStream out = new java.io.FileOutputStream(pdffile);
>>>>            out = new java.io.BufferedOutputStream(out);
>>>>            try {
>>>>                   // Construct fop with desired output format
>>>>                    Fop fop = fopFactory.newFop(MimeConstants.MIME_PDF,
>>>> foUserAgent, out);
>>>>                   // Setup XSLT
>>>>                   TransformerFactory factory =
>>>> TransformerFactory.newInstance();
>>>>                   Transformer transformer = factory.newTransformer(new
>>>> StreamSource(args[4]));
>>>>                   // Set the value of a  in the stylesheet
>>>>                   transformer.setParameter("versionParam", "2.0");
>>>>
>>>>                  // Setup input for XSLT transformation
>>>>                   Source src = new JDOMSource(documentJDOM);
>>>>                    // Resulting SAX events (the generated FO) must be
>>>> piped
>>>> through to FOP
>>>>                   Result res = new SAXResult(fop.getDefaultHandler());
>>>>                    // Start XSLT transformation and FOP processing
>>>>                  // System.setProperty("java.awt.headless", "true");
>>>>                       transformer.transform(src, res);
>>>>                   } finally {
>>>>                    out.close();
>>>>               }
>>>>
>>>>
>>>>             System.out.println("Success!");
>>>>            } catch (Exception e) {
>>>>             e.printStackTrace(System.err);
>>>>             System.exit(-1);
>>>>          }
>>>>        logger.info("Exiting application.");
>>>>
>>>>     }
>>>>
>>>>
>>>> Rob Sargent-4 wrote:
>>>>> Try this log4j.xml: Place it at the root of your jar file
>>>>>
>>>>> <?xml version="1.0" encoding="UTF-8"?>
>>>>> <!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">
>>>>>
>>>>> <log4j:configuration xmlns:log4j="http://jakarta.apache.org/log4j/"
>>>>> debug="false">
>>>>>
>>>>> <appender name="CONSOLE" class="org.apache.log4j.ConsoleAppender">
>>>>>
>>>>>
>>>>>
>>>>> <layout class="org.apache.log4j.PatternLayout">
>>>>>
>>>>> </layout>
>>>>> </appender>
>>>>>
>>>>> <category name="org">
>>>>> <priority value="DEBUG"/>
>>>>> </category>
>>>>> <category name="org.apache">
>>>>> <priority value="WARN"/>
>>>>> </category>
>>>>> <category name="org.springframework">
>>>>> <priority value="WARN"/>
>>>>> </category>
>>>>> <category name="org.hibernate">
>>>>> <priority value="DEBUG"/>
>>>>> </category>
>>>>> <category name="net">
>>>>> <priority value="ERROR"/>
>>>>> </category>
>>>>> <category name="javax">
>>>>> <priority value="ERROR"/>
>>>>> </category>
>>>>> <category name="java">
>>>>> <priority value="ERROR"/>
>>>>> </category>
>>>>> <category name="sun">
>>>>> <priority value="ERROR"/>
>>>>> </category>
>>>>> <category name="org.jboss">
>>>>> <priority value="INFO"/>
>>>>> </category>
>>>>> <category name="org.jboss.seam">
>>>>> <priority value="ERROR"/>
>>>>> </category>
>>>>> <root>
>>>>> <appender-ref ref="CONSOLE"/>
>>>>> </root>
>>>>>
>>>>> </log4j:configuration>
>>>>>
>>>>>
>>>>> On 06/13/2011 11:06 AM, Oscar.Flores wrote:
>>>>>> ok i dont thik i have a configuracion file i find the code that i put
>>>>>> in
>>>>>> the
>>>>>> other post i think its the basic
>>>>>>
>>>>>>
>>>>>> Rob Sargent-4 wrote:
>>>>>>> Do you have a config file for log4j.  Usually it's in a resource
>>>>>>> tree.
>>>>>>> Are you copying that to your deployment? Is your ant script
>>>>>>> including
>>>>>>> the config file in the jar of your application?
>>>>>>>
>>>>>>> On 06/13/2011 10:12 AM, Oscar.Flores wrote:
>>>>>>>> Ok yeah the log4j its having isuees to find the configuration
>>>>>>>>
>>>>>>>> log4j:WARN No appenders could be found for logger
>>>>>>>> (org.apache.fop.util.ContentHandlerFactoryRegistry).
>>>>>>>> log4j:WARN Please initialize the log4j system properly.
>>>>>>>> log4j:WARN See
>>>>>>>> http://logging.apache.org/log4j/1.2/faq.html#noconfig
>>>>>>>> for
>>>>>>>> more info.
>>>>>>>> i go to the faq guide and it say try loading the class or resource
>>>>>>>> yourself.
>>>>>>>> If you can't find it, neither will log4j.
>>>>>>>>
>>>>>>>> aaa i dont know where to set this
>>>>>>>>
>>>>>>>> also here its my xlst
>>>>>>>>
>>>>>>>>
>>>>>>>> http://old.nabble.com/file/p31835645/FacturasOMF.xsl
>>>>>>>> FacturasOMF.xsl
>>>>>>>>
>>>>>>>>
>>>>>>>> and the fo file that generate the editix
>>>>>>>>
>>>>>>>> http://old.nabble.com/file/p31835645/Prueba.fo Prueba.fo
>>>>>>>>
>>>>>>>>
>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>> The first thing is to really dig into what you did to netbeans to
>>>>>>>>> get
>>>>>>>>> it
>>>>>>>>> to work...
>>>>>>>>>
>>>>>>>>> I've forgotten what your stylesheet looked like, so maybe if you
>>>>>>>>> show
>>>>>>>>> us
>>>>>>>>> again how you're referencing your images we might notice a
>>>>>>>>> problem.
>>>>>>>>>
>>>>>>>>> It might also help to see the "fo" generated during your
>>>>>>>>> transformation.
>>>>>>>>> Can you grab that just after xslt and just before fop calls.
>>>>>>>>>
>>>>>>>>> Are you sure there is no error being logged somewhere when you run
>>>>>>>>> from
>>>>>>>>> the command line? (Where is log4j writing and at what level?)
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> Oscar.Flores wrote:
>>>>>>>>>> You where absolutly rigth i miss a few libraries to add into the
>>>>>>>>>> jar
>>>>>>>>>> file, i
>>>>>>>>>> modified the build.xml to add the package and jar that i need,
>>>>>>>>>> now
>>>>>>>>>> the
>>>>>>>>>> error
>>>>>>>>>> message is not there but still the images dont show in the pdf i
>>>>>>>>>> remeber
>>>>>>>>>> that i do something in netbeans so they can add to the pdf but i
>>>>>>>>>> cant
>>>>>>>>>> remeber i dont now if there is still a library that is missing or
>>>>>>>>>> i
>>>>>>>>>> am
>>>>>>>>>> adding more than it should be
>>>>>>>>>> This is what i use :
>>>>>>>>>> cfdi-base-0.1.6-SNAPSHOT.jar
>>>>>>>>>> guava-r09.jar
>>>>>>>>>> guava-r09-gwt.jar
>>>>>>>>>> jaxb-impl-2.1.10.jar
>>>>>>>>>> avalon-framework-api-4.3.jar
>>>>>>>>>> avalon-framework-cvs-20020806.jar
>>>>>>>>>> avalon-logkit-2.1.jar
>>>>>>>>>> not-yet-commons-ssl-0.3.11.jar
>>>>>>>>>> commons-codec-1.5.jar
>>>>>>>>>> commons-codec-1.5-sources.jar
>>>>>>>>>> log4j-1.2.16.jar
>>>>>>>>>> fop.jar
>>>>>>>>>> jdom.jar
>>>>>>>>>> xmlgraphics-commons-1.4.jar
>>>>>>>>>> commons-io-1.3.1.jar
>>>>>>>>>> fop-pdf-images-2.0.1.SNAPSHOT.jar
>>>>>>>>>> pdfbox-app-1.5.0.jar
>>>>>>>>>> fontbox-1.3.1.jar
>>>>>>>>>> jempbox-1.3.1.jar
>>>>>>>>>> xercesImpl-2.7.1.jar
>>>>>>>>>> batik-all-1.7.jar
>>>>>>>>>> xml-apis-1.3.04.jar
>>>>>>>>>> xml-apis-ext-1.3.04.jar
>>>>>>>>>>      avalon-framework-4.2.0.jar
>>>>>>>>>>      xalan-2.7.0.jar
>>>>>>>>>>      serializer-2.7.0.jar
>>>>>>>>>>      commons-logging-1.0.4.jar
>>>>>>>>>>      jai_codec.jar
>>>>>>>>>>      jai_core.jar
>>>>>>>>>>      batik-ext.jar
>>>>>>>>>>      jai_imageio-1.1-sources.jar
>>>>>>>>>>
>>>>>>>>>> Thanks Rob for the help
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>
>>>>>>>>>>> I suspect running from your jar does not have/use the same
>>>>>>>>>>> classpath
>>>>>>>>>>> that is in effect while you're in the debugger.
>>>>>>>>>>> By what mechanism do you generate the jar?
>>>>>>>>>>> Is it an executable jar or are you running java -classpath
>>>>>>>>>>> <your-jar-here:other-jars>     Main?
>>>>>>>>>>> Make your IDE (netbeans) display the classpath  it uses to run
>>>>>>>>>>> your
>>>>>>>>>>> app
>>>>>>>>>>> and compare that with the above.
>>>>>>>>>>>
>>>>>>>>>>> On 06/09/2011 07:21 PM, Oscar.Flores wrote:
>>>>>>>>>>>
>>>>>>>>>>>> aaa ok well my problem is that when i do the pdf in netbean the
>>>>>>>>>>>> pdf
>>>>>>>>>>>> is
>>>>>>>>>>>> fine
>>>>>>>>>>>> with images and evething but when i run the jar file in command
>>>>>>>>>>>> it
>>>>>>>>>>>> give
>>>>>>>>>>>> me a
>>>>>>>>>>>> error
>>>>>>>>>>>>
>>>>>>>>>>>> GRAVE: Error while processing image: I:\cfd\rfc.jpg
>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>       org.apache.xmlgraphics.image.loader.ImageException:
>>>>>>>>>>>> Cannot
>>>>>>>>>>>> load
>>>>>>>>>>>>       image (no suitable loader/converter combination
>>>>>>>>>>>> available)
>>>>>>>>>>>> for
>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>       (image/jpeg)
>>>>>>>>>>>>
>>>>>>>>>>>> so i dont no what its not working and if i have to add
>>>>>>>>>>>> something
>>>>>>>>>>>> to
>>>>>>>>>>>> my
>>>>>>>>>>>> code
>>>>>>>>>>>> so the images can load i am soooo desperate what i am doing
>>>>>>>>>>>> wrong??
>>>>>>>>>>>> i am sorry for the trouble and if a dont explain my self very
>>>>>>>>>>>> good
>>>>>>>>>>>> jejeje
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>
>>>>>>>>>>>>> Not at all sure what your problem is.  All I can do is show
>>>>>>>>>>>>> you
>>>>>>>>>>>>> what
>>>>>>>>>>>>> works for us.
>>>>>>>>>>>>>
>>>>>>>>>>>>> Our source xml looks like this:
>>>>>>>>>>>>> <image image-id="381623861" reference-id="ref-220" width="750"
>>>>>>>>>>>>> height="750" image-space-id="space-1" position="5"
>>>>>>>>>>>>>                    image-pool-position="31" pos="4"
>>>>>>>>>>>>>                    file="ref_10_1002108221">      <!-- an
>>>>>>>>>>>>> actual
>>>>>>>>>>>>> file
>>>>>>>>>>>>> (.jpeg
>>>>>>>>>>>>> copied the working directory of the transformer -->
>>>>>>>>>>>>> <fields />
>>>>>>>>>>>>> <caption />
>>>>>>>>>>>>> <annotations>
>>>>>>>>>>>>> <arrow_positions origHeight="750" origWidth="750" />
>>>>>>>>>>>>> </annotations>
>>>>>>>>>>>>> </image>
>>>>>>>>>>>>>
>>>>>>>>>>>>> Our xslt looks like this for each image needed.
>>>>>>>>>>>>>
>>>>>>>>>>>>> <xsl:template name="image">
>>>>>>>>>>>>> <xsl:param name="img"/>      <!-- This is the xml node from
>>>>>>>>>>>>> the
>>>>>>>>>>>>> source
>>>>>>>>>>>>> xml
>>>>>>>>>>>>> above -->
>>>>>>>>>>>>> <xsl:param name="width"/>
>>>>>>>>>>>>> <xsl:param name="height" select="$width"/>
>>>>>>>>>>>>> <xsl:param name="ignoreHeight">false</xsl:param>
>>>>>>>>>>>>> <fo:block>
>>>>>>>>>>>>> <fo:external-graphic src="{$img/@file}" height="{$height}"
>>>>>>>>>>>>> width="{$width}" content-height="scale-to-fit"
>>>>>>>>>>>>>
>>>>>>>>>>>>> content-width="scale-to-fit"
>>>>>>>>>>>>> border="0.5pt solid black" border-collapse="separate">
>>>>>>>>>>>>> <xsl:if test="$ignoreHeight != 'true'">
>>>>>>>>>>>>> <xsl:attribute name="height">
>>>>>>>>>>>>> <xsl:value-of select="$height"/>
>>>>>>>>>>>>> </xsl:attribute>
>>>>>>>>>>>>> </xsl:if>
>>>>>>>>>>>>> </fo:external-graphic>
>>>>>>>>>>>>> </fo:block>
>>>>>>>>>>>>> </xsl:template>
>>>>>>>>>>>>>
>>>>>>>>>>>>> Our generated fo looks like this:
>>>>>>>>>>>>> <fo:table-cell>
>>>>>>>>>>>>> <fo:block>
>>>>>>>>>>>>> <fo:external-graphic border-collapse="separate" border="0.5pt
>>>>>>>>>>>>> solid
>>>>>>>>>>>>> black" content-width="scale-to-fit"
>>>>>>>>>>>>> content-height="scale-to-fit"
>>>>>>>>>>>>> width="2.5in" height="2.5in" src="ref_10_1002108221" />
>>>>>>>>>>>>> </fo:block>
>>>>>>>>>>>>> </fo:table-cell>
>>>>>>>>>>>>>
>>>>>>>>>>>>> And the generated pdfs include the image and are shipped to
>>>>>>>>>>>>> the
>>>>>>>>>>>>> printer.
>>>>>>>>>>>>>
>>>>>>>>>>>>> How does this stack up with what you have?
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> On 06/09/2011 01:19 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>
>>>>>>>>>>>>>> Hi there well i still got the problem but searching IN
>>>>>>>>>>>>>> INTERNET
>>>>>>>>>>>>>> i
>>>>>>>>>>>>>> find
>>>>>>>>>>>>>> a
>>>>>>>>>>>>>> JPEG
>>>>>>>>>>>>>> renderer output for FOP its here
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> http://marc.info/?l=fop-user&m=125986752706366&w=2
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> the cuestion is can i render the image that i want to put in
>>>>>>>>>>>>>> the
>>>>>>>>>>>>>> pdf,
>>>>>>>>>>>>>> and
>>>>>>>>>>>>>> then add to the xsl the render jpeg it will work??
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> and here explaints how use the render when he say uses fop as
>>>>>>>>>>>>>> normal
>>>>>>>>>>>>>> case
>>>>>>>>>>>>>> what does it mean
>>>>>>>>>>>>>> what else have to add to the code?? i hope you can help me
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> Thanks!!
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> // OutputStream out = what you want
>>>>>>>>>>>>>>                   FopFactory fopFactory =
>>>>>>>>>>>>>> FopFactory.newInstance();
>>>>>>>>>>>>>>                   RendererFactory rendererFactory = null;
>>>>>>>>>>>>>>                   FOUserAgent foUserAgent = null;
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>                   rendererFactory =
>>>>>>>>>>>>>> fopFactory.getRendererFactory();
>>>>>>>>>>>>>>                   rendererFactory.addRendererMaker(new
>>>>>>>>>>>>>> MultiRendererMaker("jpeg"));
>>>>>>>>>>>>>>                   foUserAgent = fopFactory.newFOUserAgent();
>>>>>>>>>>>>>>                   rendererFactory.createRenderer(foUserAgent,
>>>>>>>>>>>>>> "image/jpeg");
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>                   Fop fop = fopFactory.newFop("image/jpeg",
>>>>>>>>>>>>>> foUserAgent,
>>>>>>>>>>>>>> out);
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> //Use fop as normal case
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> Since you're now into xmlgraphics, I think you're best bet
>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>> here
>>>>>>>>>>>>>>> <http://xmlgraphics.apache.org/commons/image-loader.html>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> On 06/07/2011 10:18 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> Hi ok this is for generate images that dont need to be
>>>>>>>>>>>>>>>> decompress
>>>>>>>>>>>>>>>> later??
>>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>>> the result image i put in my xsl ?? then it should work,
>>>>>>>>>>>>>>>> aaa
>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>> change
>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>> fop
>>>>>>>>>>>>>>>> 1.0 and xml communs 1.4 and its the same jejeje   dont find
>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>> image
>>>>>>>>>>>>>>>> preload
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> org.apache.fop.fo.flow.ExternalGraphic bind
>>>>>>>>>>>>>>>> SEVERE: Image not available: The file format is not
>>>>>>>>>>>>>>>> supported.
>>>>>>>>>>>>>>>> No
>>>>>>>>>>>>>>>> ImagePreloader for *.jpg or *.bmp
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> ImageIO.write(bufferedImage, "JPEG", file);
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> On 06/07/2011 08:21 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> Ok i actually register the handler now what i have to do
>>>>>>>>>>>>>>>>>> is
>>>>>>>>>>>>>>>>>> setup
>>>>>>>>>>>>>>>>>> this
>>>>>>>>>>>>>>>>>> handler or not?? and how can i do that, also it seem that
>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>> bmp
>>>>>>>>>>>>>>>>>> its
>>>>>>>>>>>>>>>>>> not
>>>>>>>>>>>>>>>>>> recognice also what can i do?? thanks for the help rob
>>>>>>>>>>>>>>>>>> also i am trying to convert the images to see if it that
>>>>>>>>>>>>>>>>>> helps
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> On 06/06/2011 02:29 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> Hi what can be the difference between execute the
>>>>>>>>>>>>>>>>>>>> program
>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>> netbeans
>>>>>>>>>>>>>>>>>>>> (where
>>>>>>>>>>>>>>>>>>>> it works and print the images and the jar in the
>>>>>>>>>>>>>>>>>>>> console)
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> Different classes being loaded by Netbeans than the
>>>>>>>>>>>>>>>>>>> console
>>>>>>>>>>>>>>>>>>> app.
>>>>>>>>>>>>>>>>>>> Get
>>>>>>>>>>>>>>>>>>> Netbeans to show you the full classpath it's using in
>>>>>>>>>>>>>>>>>>> it's
>>>>>>>>>>>>>>>>>>> "%classpath"
>>>>>>>>>>>>>>>>>>> variable
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> also i tried the
>>>>>>>>>>>>>>>>>>>> imageIO.getImageReadersBySuffix but i cant interpretate
>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>> data
>>>>>>>>>>>>>>>>>>>> y.y,
>>>>>>>>>>>>>>>>>>>> its
>>>>>>>>>>>>>>>>>>>> that or always its true in the boolean variable, and
>>>>>>>>>>>>>>>>>>>> how
>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>> register
>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>> handler??
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> Talk to IIORegistry, some thing like
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>>>>>>>> CLibJPEGImageReaderSpi());
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>>>>>>>> CLibJPEGImageWriterSpi());
>>>>>>>>>>>>>>>>>>> Note: those are not necessarily the services you have in
>>>>>>>>>>>>>>>>>>> your
>>>>>>>>>>>>>>>>>>> setup.
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> Thanks
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> See the javadoc on IIORegistry. With ImageIO you may
>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>> register
>>>>>>>>>>>>>>>>>>>>> your handler(s). What does
>>>>>>>>>>>>>>>>>>>>> ImageIO.getImageReadersBySuffix()
>>>>>>>>>>>>>>>>>>>>> give
>>>>>>>>>>>>>>>>>>>>> you.
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> For certain jpegs we don't use ImageIO, rather the
>>>>>>>>>>>>>>>>>>>>> classes
>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>> com.sun.image.codec.jpeg:
>>>>>>>>>>>>>>>>>>>>>                   try {
>>>>>>>>>>>>>>>>>>>>>                       FileOutputStream fos = new
>>>>>>>>>>>>>>>>>>>>> FileOutputStream(file);
>>>>>>>>>>>>>>>>>>>>>                       JPEGImageEncoder encoder =
>>>>>>>>>>>>>>>>>>>>> JPEGCodec.createJPEGEncoder(fos);
>>>>>>>>>>>>>>>>>>>>>                       JPEGEncodeParam param =
>>>>>>>>>>>>>>>>>>>>> encoder.getDefaultJPEGEncodeParam(image.getRaster(),
>>>>>>>>>>>>>>>>>>>>> JPEGDecodeParam.COLOR_ID_CMYK);
>>>>>>>>>>>>>>>>>>>>>                       param.setQuality(1, false);
>>>>>>>>>>>>>>>>>>>>>                      
>>>>>>>>>>>>>>>>>>>>> encoder.encode(image.getRaster(),
>>>>>>>>>>>>>>>>>>>>> param);
>>>>>>>>>>>>>>>>>>>>>                       fos.close();
>>>>>>>>>>>>>>>>>>>>>                   } catch (Throwable t) {
>>>>>>>>>>>>>>>>>>>>>                       logger.debug(t.getMessage());
>>>>>>>>>>>>>>>>>>>>>                   }
>>>>>>>>>>>>>>>>>>>>> But generally we use ImageIO
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> On 06/06/2011 08:29 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> Yeah i think i need your help again i tried tu run
>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>> .jar
>>>>>>>>>>>>>>>>>>>>>> file
>>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>> console it work but without images this it what
>>>>>>>>>>>>>>>>>>>>>> appears
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> GRAVE: Error while processing image: I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException:
>>>>>>>>>>>>>>>>>>>>>> Cannot
>>>>>>>>>>>>>>>>>>>>>> load
>>>>>>>>>>>>>>>>>>>>>> image
>>>>>>>>>>>>>>>>>>>>>> (no
>>>>>>>>>>>>>>>>>>>>>> suitable loader/converter combination available) for
>>>>>>>>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> i tried  download the jai-imagio add to the class
>>>>>>>>>>>>>>>>>>>>>> path
>>>>>>>>>>>>>>>>>>>>>> but
>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>> dont
>>>>>>>>>>>>>>>>>>>>>> work
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> Very odd.  I'm having no problems getting images
>>>>>>>>>>>>>>>>>>>>>>> into
>>>>>>>>>>>>>>>>>>>>>>> pdfs
>>>>>>>>>>>>>>>>>>>>>>> using
>>>>>>>>>>>>>>>>>>>>>>> fop-1.0.
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> On 06/03/2011 11:04 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> aaa hey thanks for the help the other day, i
>>>>>>>>>>>>>>>>>>>>>>>> resolve
>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>> problem
>>>>>>>>>>>>>>>>>>>>>>>> changing
>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>> version of FOP for the 0.95beta instead of the 1.0,
>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>> works
>>>>>>>>>>>>>>>>>>>>>>>> now
>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>> prints
>>>>>>>>>>>>>>>>>>>>>>>> the image and its good, thanks and we are in touch
>>>>>>>>>>>>>>>>>>>>>>>> if
>>>>>>>>>>>>>>>>>>>>>>>> anything
>>>>>>>>>>>>>>>>>>>>>>>> else
>>>>>>>>>>>>>>>>>>>>>>>> fails
>>>>>>>>>>>>>>>>>>>>>>>> jejeje
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> Nothing in the log from the transformer?
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> On 06/03/2011 09:47 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>> hi there i have another problem i hope you can
>>>>>>>>>>>>>>>>>>>>>>>>>> help
>>>>>>>>>>>>>>>>>>>>>>>>>> me
>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>> create
>>>>>>>>>>>>>>>>>>>>>>>>>> with foe has no image, it dont show any of them,
>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>> xsl
>>>>>>>>>>>>>>>>>>>>>>>>>> seems
>>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>>> be
>>>>>>>>>>>>>>>>>>>>>>>>>> rigth i
>>>>>>>>>>>>>>>>>>>>>>>>>> tested with EditX and the pdf show me the image,
>>>>>>>>>>>>>>>>>>>>>>>>>> what
>>>>>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>>> be,
>>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>>>> xmlgraphics-commons-1.5svn, fop 1.0,
>>>>>>>>>>>>>>>>>>>>>>>>>> fop-pdf-images
>>>>>>>>>>>>>>>>>>>>>>>>>> 2.0.1
>>>>>>>>>>>>>>>>>>>>>>>>>> Snapshot
>>>>>>>>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>>> render of the image but it don work please
>>>>>>>>>>>>>>>>>>>>>>>>>> help!!!
>>>>>>>>>>>>>>>>>>>>>>>>>> :,(
>>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> :-):confused::confused::confused::confused:=)
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>> http://old.nabble.com/file/p31822059/libraries.jpeg
>>>>>>>>>> http://old.nabble.com/file/p31822059/libraries.bmp libraries.bmp
>>>>>>>>>>
>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>> For additional commands, e-mail:
>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>> ---------------------------------------------------------------------
>>>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>> For additional commands, e-mail:
>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>
>>>>>>>
>>>>>>>
>>>>> ---------------------------------------------------------------------
>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>>>
>>>>>
>>>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>
>>>
>>>
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
> 
> 
> 

-- 
View this message in context: http://old.nabble.com/Problems-with-FOP-and-image-tp31766430p31838683.html
Sent from the FOP - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Problems with FOP and image

Posted by Rob Sargent <rs...@xmission.com>.
I'm not sure I'm following correctly: does removing the xmlgraphics jar 
cause netbeans to behave the same as the command-line run of you app? If 
so, I suspect netbeans is registering services for you.  Your own code 
will have to make a call to one of the 
IIORegistry.registerServiceProvider() methods.

On 06/13/2011 05:02 PM, Oscar.Flores wrote:
> Ok aaaa i get it, actually the ImageIO library i added because i read in the
> xmlgrapics that if something like the message
> org.apache.xmlgraphics.image.loader.ImageException: Cannot load image (no
> suitable loader/converter combination available)appear i have to add the jar
> file to the classpath but that all it say no configuration or anything, then
> i delete the imagenIO libs and still i have the same output in netbeans so
> xmlgrapics seem to have the problem in the plugins or i have to configure
> something
>
> Rob Sargent-4 wrote:
>> Then it seems to me netbeans (if it's producing good output ==
>> assumptionA) is still using something that the command-line isn't.
>>
>> And given assumptionA, you're java code is correct in terms of FOP and
>> your configuration isn't for ImageIO.  Show your ImageIO related code
>> and are you sure it's in your app.  Use the logger to show a message
>> when you add  your loader.  Or list all ImageIO services:
>> IIORegistry.getServiceProviders()
>>
>> On 06/13/2011 03:01 PM, Oscar.Flores wrote:
>>> ok well i put the xml in scr of my proyect i see that i still have the
>>> same
>>> issues of the image render of any image i dont now if the xml its in
>>> place i
>>> put the code down to see if something its missing
>>>
>>> 15:45:07,827 ERROR [render] Error while processing image:
>>> c:\cfd\nombregp.bmp (i
>>> mage/bmp)
>>> org.apache.xmlgraphics.image.loader.ImageException: Cannot load image (no
>>> suitab
>>> le loader/converter combination available) for c:\cfd\nombregp.bmp
>>> (image/bmp)
>>>           at
>>> org.apache.xmlgraphics.image.loader.ImageManager.getImage(ImageManage
>>>
>>>
>>>
>>> import mx.bigdata.sat.cfd.schema.Comprobante;
>>> import mx.bigdata.sat.cfd.CFDv2;
>>> import mx.bigdata.sat.security.KeyLoader;
>>> import org.jdom.*;
>>> import org.jdom.input.SAXBuilder;
>>> import org.jdom.output.XMLOutputter;
>>> import org.jdom.output.Format;
>>> import org.jdom.transform.JDOMSource;
>>> //Java
>>>    import java.io.File;
>>>    import java.io.OutputStream;
>>>
>>>    //JAXP
>>>    import javax.xml.transform.Transformer;
>>>    import javax.xml.transform.TransformerFactory;
>>>    import javax.xml.transform.Source;
>>>    import javax.xml.transform.Result;
>>>    import javax.xml.transform.stream.StreamSource;
>>>    import javax.xml.transform.sax.SAXResult;
>>>
>>>    //FOP
>>>    import org.apache.fop.apps.FOUserAgent;
>>>    import org.apache.fop.apps.Fop;
>>>    import org.apache.fop.apps.FopFactory;
>>>    import org.apache.fop.apps.MimeConstants;
>>>
>>>    //log4j
>>>    import org.apache.log4j.*;
>>>    import org.apache.log4j.xml.DOMConfigurator;
>>>
>>> public final class Main {
>>>       @SuppressWarnings("unchecked")
>>>       static Logger logger = Logger.getLogger(Main.class);
>>>
>>>       public static void main(String[] args) throws Exception {
>>>            DOMConfigurator.configure("D:/Mis
>>> documentos/NetBeansProjects/Factura/src/factura/log4j.xml");
>>>            logger.info("Entering application.");
>>>            try {
>>>               File file = new File(args[0]);
>>>               Comprobante comp = CFDv2.newComprobante(new
>>> FileInputStream(file));
>>>               CFDv2 cfd = new CFDv2(comp);
>>>               PrivateKey key = KeyLoader.loadPKCS8PrivateKey(new
>>> FileInputStream(args[1]),(args[2]));
>>>               X509Certificate cert = KeyLoader.loadX509Certificate(new
>>> FileInputStream(args[3]));
>>>               Comprobante sellado = cfd.sellarComprobante(key, cert);
>>>               String cadena = cfd.getCadenaOriginal();
>>>               String sello = sellado.getSello();
>>>               // Creamos el builder basado en SAX
>>>               SAXBuilder builder = new SAXBuilder();
>>>               // Construimos el arbol DOM a partir del fichero xml
>>>               Document documentJDOM = builder.build(new
>>> FileInputStream(args[0]));
>>>
>>>
>>>               Element raiz = documentJDOM.getRootElement();//toma el nodo
>>> raiz
>>> del documento.
>>>               raiz.setAttribute("sello", sello);
>>>               raiz.setAttribute("certificado", sellado.getCertificado());
>>>               //System.out.println(raiz.getAttributeValue("sello"));
>>>               //System.out.println(raiz.getAttributeValue("certificado"));
>>>               // Recorremos los hijos de la etiqueta raíz
>>>               List<Element>   hijosRaiz = raiz.getChildren();
>>>               boolean Bandera=false;
>>>               for(Element hijo: hijosRaiz)
>>>               {
>>>                   // Obtenemos el nombre y su contenido de tipo texto
>>>                   String nombre = hijo.getName();
>>>
>>>                   if (nombre.equals("Addenda"))
>>>                   {   List<Element>   subHijo = hijo.getChildren();
>>>                       for(Element hij: subHijo)
>>>                           {
>>>                           hij.setAttribute("CadenaOriginal", cadena);
>>>                           //System.out.println("CadenaOriginal:
>>> "+hij.getAttributeValue("CadenaOriginal"));
>>>                           Bandera=true;
>>>                           break;
>>>                           }
>>>                   }
>>>                   if (Bandera)
>>>                   {
>>>                       XMLOutputter out = new
>>> XMLOutputter(Format.getPrettyFormat());
>>>                       File nuevoXML = new File(args[0]);
>>>                       try{
>>>                           FileOutputStream archivoXML= new
>>> FileOutputStream
>>> (nuevoXML);
>>>                           out.output(documentJDOM, archivoXML);
>>>
>>>                          }
>>>                       catch (Exception
>>> ex){System.out.println(ex.getMessage());}
>>>                       // Para generar el pdf a partir de un archivo.xsl y
>>> un
>>>                       // archivo.xml
>>>                   }
>>>                 }
>>>             // configure fopFactory as desired
>>>             FopFactory fopFactory = FopFactory.newInstance();
>>>             FOUserAgent foUserAgent = fopFactory.newFOUserAgent();
>>>
>>>             // configure foUserAgent as desired
>>>             // Setup output
>>>            File pdffile = new File(args[5]);
>>>
>>>            OutputStream out = new java.io.FileOutputStream(pdffile);
>>>            out = new java.io.BufferedOutputStream(out);
>>>            try {
>>>                   // Construct fop with desired output format
>>>                    Fop fop = fopFactory.newFop(MimeConstants.MIME_PDF,
>>> foUserAgent, out);
>>>                   // Setup XSLT
>>>                   TransformerFactory factory =
>>> TransformerFactory.newInstance();
>>>                   Transformer transformer = factory.newTransformer(new
>>> StreamSource(args[4]));
>>>                   // Set the value of a  in the stylesheet
>>>                   transformer.setParameter("versionParam", "2.0");
>>>
>>>                  // Setup input for XSLT transformation
>>>                   Source src = new JDOMSource(documentJDOM);
>>>                    // Resulting SAX events (the generated FO) must be
>>> piped
>>> through to FOP
>>>                   Result res = new SAXResult(fop.getDefaultHandler());
>>>                    // Start XSLT transformation and FOP processing
>>>                  // System.setProperty("java.awt.headless", "true");
>>>                       transformer.transform(src, res);
>>>                   } finally {
>>>                    out.close();
>>>               }
>>>
>>>
>>>             System.out.println("Success!");
>>>            } catch (Exception e) {
>>>             e.printStackTrace(System.err);
>>>             System.exit(-1);
>>>          }
>>>        logger.info("Exiting application.");
>>>
>>>     }
>>>
>>>
>>> Rob Sargent-4 wrote:
>>>> Try this log4j.xml: Place it at the root of your jar file
>>>>
>>>> <?xml version="1.0" encoding="UTF-8"?>
>>>> <!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">
>>>>
>>>> <log4j:configuration xmlns:log4j="http://jakarta.apache.org/log4j/"
>>>> debug="false">
>>>>
>>>> <appender name="CONSOLE" class="org.apache.log4j.ConsoleAppender">
>>>>
>>>>
>>>>
>>>> <layout class="org.apache.log4j.PatternLayout">
>>>>
>>>> </layout>
>>>> </appender>
>>>>
>>>> <category name="org">
>>>> <priority value="DEBUG"/>
>>>> </category>
>>>> <category name="org.apache">
>>>> <priority value="WARN"/>
>>>> </category>
>>>> <category name="org.springframework">
>>>> <priority value="WARN"/>
>>>> </category>
>>>> <category name="org.hibernate">
>>>> <priority value="DEBUG"/>
>>>> </category>
>>>> <category name="net">
>>>> <priority value="ERROR"/>
>>>> </category>
>>>> <category name="javax">
>>>> <priority value="ERROR"/>
>>>> </category>
>>>> <category name="java">
>>>> <priority value="ERROR"/>
>>>> </category>
>>>> <category name="sun">
>>>> <priority value="ERROR"/>
>>>> </category>
>>>> <category name="org.jboss">
>>>> <priority value="INFO"/>
>>>> </category>
>>>> <category name="org.jboss.seam">
>>>> <priority value="ERROR"/>
>>>> </category>
>>>> <root>
>>>> <appender-ref ref="CONSOLE"/>
>>>> </root>
>>>>
>>>> </log4j:configuration>
>>>>
>>>>
>>>> On 06/13/2011 11:06 AM, Oscar.Flores wrote:
>>>>> ok i dont thik i have a configuracion file i find the code that i put
>>>>> in
>>>>> the
>>>>> other post i think its the basic
>>>>>
>>>>>
>>>>> Rob Sargent-4 wrote:
>>>>>> Do you have a config file for log4j.  Usually it's in a resource tree.
>>>>>> Are you copying that to your deployment? Is your ant script including
>>>>>> the config file in the jar of your application?
>>>>>>
>>>>>> On 06/13/2011 10:12 AM, Oscar.Flores wrote:
>>>>>>> Ok yeah the log4j its having isuees to find the configuration
>>>>>>>
>>>>>>> log4j:WARN No appenders could be found for logger
>>>>>>> (org.apache.fop.util.ContentHandlerFactoryRegistry).
>>>>>>> log4j:WARN Please initialize the log4j system properly.
>>>>>>> log4j:WARN See http://logging.apache.org/log4j/1.2/faq.html#noconfig
>>>>>>> for
>>>>>>> more info.
>>>>>>> i go to the faq guide and it say try loading the class or resource
>>>>>>> yourself.
>>>>>>> If you can't find it, neither will log4j.
>>>>>>>
>>>>>>> aaa i dont know where to set this
>>>>>>>
>>>>>>> also here its my xlst
>>>>>>>
>>>>>>>
>>>>>>> http://old.nabble.com/file/p31835645/FacturasOMF.xsl FacturasOMF.xsl
>>>>>>>
>>>>>>>
>>>>>>> and the fo file that generate the editix
>>>>>>>
>>>>>>> http://old.nabble.com/file/p31835645/Prueba.fo Prueba.fo
>>>>>>>
>>>>>>>
>>>>>>> Rob Sargent-4 wrote:
>>>>>>>> The first thing is to really dig into what you did to netbeans to
>>>>>>>> get
>>>>>>>> it
>>>>>>>> to work...
>>>>>>>>
>>>>>>>> I've forgotten what your stylesheet looked like, so maybe if you
>>>>>>>> show
>>>>>>>> us
>>>>>>>> again how you're referencing your images we might notice a problem.
>>>>>>>>
>>>>>>>> It might also help to see the "fo" generated during your
>>>>>>>> transformation.
>>>>>>>> Can you grab that just after xslt and just before fop calls.
>>>>>>>>
>>>>>>>> Are you sure there is no error being logged somewhere when you run
>>>>>>>> from
>>>>>>>> the command line? (Where is log4j writing and at what level?)
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> Oscar.Flores wrote:
>>>>>>>>> You where absolutly rigth i miss a few libraries to add into the
>>>>>>>>> jar
>>>>>>>>> file, i
>>>>>>>>> modified the build.xml to add the package and jar that i need, now
>>>>>>>>> the
>>>>>>>>> error
>>>>>>>>> message is not there but still the images dont show in the pdf i
>>>>>>>>> remeber
>>>>>>>>> that i do something in netbeans so they can add to the pdf but i
>>>>>>>>> cant
>>>>>>>>> remeber i dont now if there is still a library that is missing or i
>>>>>>>>> am
>>>>>>>>> adding more than it should be
>>>>>>>>> This is what i use :
>>>>>>>>> cfdi-base-0.1.6-SNAPSHOT.jar
>>>>>>>>> guava-r09.jar
>>>>>>>>> guava-r09-gwt.jar
>>>>>>>>> jaxb-impl-2.1.10.jar
>>>>>>>>> avalon-framework-api-4.3.jar
>>>>>>>>> avalon-framework-cvs-20020806.jar
>>>>>>>>> avalon-logkit-2.1.jar
>>>>>>>>> not-yet-commons-ssl-0.3.11.jar
>>>>>>>>> commons-codec-1.5.jar
>>>>>>>>> commons-codec-1.5-sources.jar
>>>>>>>>> log4j-1.2.16.jar
>>>>>>>>> fop.jar
>>>>>>>>> jdom.jar
>>>>>>>>> xmlgraphics-commons-1.4.jar
>>>>>>>>> commons-io-1.3.1.jar
>>>>>>>>> fop-pdf-images-2.0.1.SNAPSHOT.jar
>>>>>>>>> pdfbox-app-1.5.0.jar
>>>>>>>>> fontbox-1.3.1.jar
>>>>>>>>> jempbox-1.3.1.jar
>>>>>>>>> xercesImpl-2.7.1.jar
>>>>>>>>> batik-all-1.7.jar
>>>>>>>>> xml-apis-1.3.04.jar
>>>>>>>>> xml-apis-ext-1.3.04.jar
>>>>>>>>>      avalon-framework-4.2.0.jar
>>>>>>>>>      xalan-2.7.0.jar
>>>>>>>>>      serializer-2.7.0.jar
>>>>>>>>>      commons-logging-1.0.4.jar
>>>>>>>>>      jai_codec.jar
>>>>>>>>>      jai_core.jar
>>>>>>>>>      batik-ext.jar
>>>>>>>>>      jai_imageio-1.1-sources.jar
>>>>>>>>>
>>>>>>>>> Thanks Rob for the help
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>
>>>>>>>>>> I suspect running from your jar does not have/use the same
>>>>>>>>>> classpath
>>>>>>>>>> that is in effect while you're in the debugger.
>>>>>>>>>> By what mechanism do you generate the jar?
>>>>>>>>>> Is it an executable jar or are you running java -classpath
>>>>>>>>>> <your-jar-here:other-jars>     Main?
>>>>>>>>>> Make your IDE (netbeans) display the classpath  it uses to run
>>>>>>>>>> your
>>>>>>>>>> app
>>>>>>>>>> and compare that with the above.
>>>>>>>>>>
>>>>>>>>>> On 06/09/2011 07:21 PM, Oscar.Flores wrote:
>>>>>>>>>>
>>>>>>>>>>> aaa ok well my problem is that when i do the pdf in netbean the
>>>>>>>>>>> pdf
>>>>>>>>>>> is
>>>>>>>>>>> fine
>>>>>>>>>>> with images and evething but when i run the jar file in command
>>>>>>>>>>> it
>>>>>>>>>>> give
>>>>>>>>>>> me a
>>>>>>>>>>> error
>>>>>>>>>>>
>>>>>>>>>>> GRAVE: Error while processing image: I:\cfd\rfc.jpg (image/jpeg)
>>>>>>>>>>>       org.apache.xmlgraphics.image.loader.ImageException: Cannot
>>>>>>>>>>> load
>>>>>>>>>>>       image (no suitable loader/converter combination available)
>>>>>>>>>>> for
>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>       (image/jpeg)
>>>>>>>>>>>
>>>>>>>>>>> so i dont no what its not working and if i have to add something
>>>>>>>>>>> to
>>>>>>>>>>> my
>>>>>>>>>>> code
>>>>>>>>>>> so the images can load i am soooo desperate what i am doing
>>>>>>>>>>> wrong??
>>>>>>>>>>> i am sorry for the trouble and if a dont explain my self very
>>>>>>>>>>> good
>>>>>>>>>>> jejeje
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>
>>>>>>>>>>>> Not at all sure what your problem is.  All I can do is show you
>>>>>>>>>>>> what
>>>>>>>>>>>> works for us.
>>>>>>>>>>>>
>>>>>>>>>>>> Our source xml looks like this:
>>>>>>>>>>>> <image image-id="381623861" reference-id="ref-220" width="750"
>>>>>>>>>>>> height="750" image-space-id="space-1" position="5"
>>>>>>>>>>>>                    image-pool-position="31" pos="4"
>>>>>>>>>>>>                    file="ref_10_1002108221">      <!-- an actual
>>>>>>>>>>>> file
>>>>>>>>>>>> (.jpeg
>>>>>>>>>>>> copied the working directory of the transformer -->
>>>>>>>>>>>> <fields />
>>>>>>>>>>>> <caption />
>>>>>>>>>>>> <annotations>
>>>>>>>>>>>> <arrow_positions origHeight="750" origWidth="750" />
>>>>>>>>>>>> </annotations>
>>>>>>>>>>>> </image>
>>>>>>>>>>>>
>>>>>>>>>>>> Our xslt looks like this for each image needed.
>>>>>>>>>>>>
>>>>>>>>>>>> <xsl:template name="image">
>>>>>>>>>>>> <xsl:param name="img"/>      <!-- This is the xml node from the
>>>>>>>>>>>> source
>>>>>>>>>>>> xml
>>>>>>>>>>>> above -->
>>>>>>>>>>>> <xsl:param name="width"/>
>>>>>>>>>>>> <xsl:param name="height" select="$width"/>
>>>>>>>>>>>> <xsl:param name="ignoreHeight">false</xsl:param>
>>>>>>>>>>>> <fo:block>
>>>>>>>>>>>> <fo:external-graphic src="{$img/@file}" height="{$height}"
>>>>>>>>>>>> width="{$width}" content-height="scale-to-fit"
>>>>>>>>>>>>
>>>>>>>>>>>> content-width="scale-to-fit"
>>>>>>>>>>>> border="0.5pt solid black" border-collapse="separate">
>>>>>>>>>>>> <xsl:if test="$ignoreHeight != 'true'">
>>>>>>>>>>>> <xsl:attribute name="height">
>>>>>>>>>>>> <xsl:value-of select="$height"/>
>>>>>>>>>>>> </xsl:attribute>
>>>>>>>>>>>> </xsl:if>
>>>>>>>>>>>> </fo:external-graphic>
>>>>>>>>>>>> </fo:block>
>>>>>>>>>>>> </xsl:template>
>>>>>>>>>>>>
>>>>>>>>>>>> Our generated fo looks like this:
>>>>>>>>>>>> <fo:table-cell>
>>>>>>>>>>>> <fo:block>
>>>>>>>>>>>> <fo:external-graphic border-collapse="separate" border="0.5pt
>>>>>>>>>>>> solid
>>>>>>>>>>>> black" content-width="scale-to-fit"
>>>>>>>>>>>> content-height="scale-to-fit"
>>>>>>>>>>>> width="2.5in" height="2.5in" src="ref_10_1002108221" />
>>>>>>>>>>>> </fo:block>
>>>>>>>>>>>> </fo:table-cell>
>>>>>>>>>>>>
>>>>>>>>>>>> And the generated pdfs include the image and are shipped to the
>>>>>>>>>>>> printer.
>>>>>>>>>>>>
>>>>>>>>>>>> How does this stack up with what you have?
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> On 06/09/2011 01:19 PM, Oscar.Flores wrote:
>>>>>>>>>>>>
>>>>>>>>>>>>> Hi there well i still got the problem but searching IN INTERNET
>>>>>>>>>>>>> i
>>>>>>>>>>>>> find
>>>>>>>>>>>>> a
>>>>>>>>>>>>> JPEG
>>>>>>>>>>>>> renderer output for FOP its here
>>>>>>>>>>>>>
>>>>>>>>>>>>> http://marc.info/?l=fop-user&m=125986752706366&w=2
>>>>>>>>>>>>>
>>>>>>>>>>>>> the cuestion is can i render the image that i want to put in
>>>>>>>>>>>>> the
>>>>>>>>>>>>> pdf,
>>>>>>>>>>>>> and
>>>>>>>>>>>>> then add to the xsl the render jpeg it will work??
>>>>>>>>>>>>>
>>>>>>>>>>>>> and here explaints how use the render when he say uses fop as
>>>>>>>>>>>>> normal
>>>>>>>>>>>>> case
>>>>>>>>>>>>> what does it mean
>>>>>>>>>>>>> what else have to add to the code?? i hope you can help me
>>>>>>>>>>>>>
>>>>>>>>>>>>> Thanks!!
>>>>>>>>>>>>>
>>>>>>>>>>>>> // OutputStream out = what you want
>>>>>>>>>>>>>                   FopFactory fopFactory =
>>>>>>>>>>>>> FopFactory.newInstance();
>>>>>>>>>>>>>                   RendererFactory rendererFactory = null;
>>>>>>>>>>>>>                   FOUserAgent foUserAgent = null;
>>>>>>>>>>>>>
>>>>>>>>>>>>>                   rendererFactory =
>>>>>>>>>>>>> fopFactory.getRendererFactory();
>>>>>>>>>>>>>                   rendererFactory.addRendererMaker(new
>>>>>>>>>>>>> MultiRendererMaker("jpeg"));
>>>>>>>>>>>>>                   foUserAgent = fopFactory.newFOUserAgent();
>>>>>>>>>>>>>                   rendererFactory.createRenderer(foUserAgent,
>>>>>>>>>>>>> "image/jpeg");
>>>>>>>>>>>>>
>>>>>>>>>>>>>                   Fop fop = fopFactory.newFop("image/jpeg",
>>>>>>>>>>>>> foUserAgent,
>>>>>>>>>>>>> out);
>>>>>>>>>>>>>
>>>>>>>>>>>>> //Use fop as normal case
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>
>>>>>>>>>>>>>> Since you're now into xmlgraphics, I think you're best bet is
>>>>>>>>>>>>>> here
>>>>>>>>>>>>>> <http://xmlgraphics.apache.org/commons/image-loader.html>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> On 06/07/2011 10:18 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> Hi ok this is for generate images that dont need to be
>>>>>>>>>>>>>>> decompress
>>>>>>>>>>>>>>> later??
>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>> the result image i put in my xsl ?? then it should work, aaa
>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>> change
>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>> fop
>>>>>>>>>>>>>>> 1.0 and xml communs 1.4 and its the same jejeje   dont find
>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>> image
>>>>>>>>>>>>>>> preload
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> org.apache.fop.fo.flow.ExternalGraphic bind
>>>>>>>>>>>>>>> SEVERE: Image not available: The file format is not
>>>>>>>>>>>>>>> supported.
>>>>>>>>>>>>>>> No
>>>>>>>>>>>>>>> ImagePreloader for *.jpg or *.bmp
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> ImageIO.write(bufferedImage, "JPEG", file);
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> On 06/07/2011 08:21 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> Ok i actually register the handler now what i have to do is
>>>>>>>>>>>>>>>>> setup
>>>>>>>>>>>>>>>>> this
>>>>>>>>>>>>>>>>> handler or not?? and how can i do that, also it seem that
>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>> bmp
>>>>>>>>>>>>>>>>> its
>>>>>>>>>>>>>>>>> not
>>>>>>>>>>>>>>>>> recognice also what can i do?? thanks for the help rob
>>>>>>>>>>>>>>>>> also i am trying to convert the images to see if it that
>>>>>>>>>>>>>>>>> helps
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> On 06/06/2011 02:29 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> Hi what can be the difference between execute the program
>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>> netbeans
>>>>>>>>>>>>>>>>>>> (where
>>>>>>>>>>>>>>>>>>> it works and print the images and the jar in the console)
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> Different classes being loaded by Netbeans than the
>>>>>>>>>>>>>>>>>> console
>>>>>>>>>>>>>>>>>> app.
>>>>>>>>>>>>>>>>>> Get
>>>>>>>>>>>>>>>>>> Netbeans to show you the full classpath it's using in it's
>>>>>>>>>>>>>>>>>> "%classpath"
>>>>>>>>>>>>>>>>>> variable
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> also i tried the
>>>>>>>>>>>>>>>>>>> imageIO.getImageReadersBySuffix but i cant interpretate
>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>> data
>>>>>>>>>>>>>>>>>>> y.y,
>>>>>>>>>>>>>>>>>>> its
>>>>>>>>>>>>>>>>>>> that or always its true in the boolean variable, and how
>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>> register
>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>> handler??
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> Talk to IIORegistry, some thing like
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>>>>>>> CLibJPEGImageReaderSpi());
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>>>>>>> CLibJPEGImageWriterSpi());
>>>>>>>>>>>>>>>>>> Note: those are not necessarily the services you have in
>>>>>>>>>>>>>>>>>> your
>>>>>>>>>>>>>>>>>> setup.
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> Thanks
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> See the javadoc on IIORegistry. With ImageIO you may
>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>> register
>>>>>>>>>>>>>>>>>>>> your handler(s). What does
>>>>>>>>>>>>>>>>>>>> ImageIO.getImageReadersBySuffix()
>>>>>>>>>>>>>>>>>>>> give
>>>>>>>>>>>>>>>>>>>> you.
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> For certain jpegs we don't use ImageIO, rather the
>>>>>>>>>>>>>>>>>>>> classes
>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>> com.sun.image.codec.jpeg:
>>>>>>>>>>>>>>>>>>>>                   try {
>>>>>>>>>>>>>>>>>>>>                       FileOutputStream fos = new
>>>>>>>>>>>>>>>>>>>> FileOutputStream(file);
>>>>>>>>>>>>>>>>>>>>                       JPEGImageEncoder encoder =
>>>>>>>>>>>>>>>>>>>> JPEGCodec.createJPEGEncoder(fos);
>>>>>>>>>>>>>>>>>>>>                       JPEGEncodeParam param =
>>>>>>>>>>>>>>>>>>>> encoder.getDefaultJPEGEncodeParam(image.getRaster(),
>>>>>>>>>>>>>>>>>>>> JPEGDecodeParam.COLOR_ID_CMYK);
>>>>>>>>>>>>>>>>>>>>                       param.setQuality(1, false);
>>>>>>>>>>>>>>>>>>>>                       encoder.encode(image.getRaster(),
>>>>>>>>>>>>>>>>>>>> param);
>>>>>>>>>>>>>>>>>>>>                       fos.close();
>>>>>>>>>>>>>>>>>>>>                   } catch (Throwable t) {
>>>>>>>>>>>>>>>>>>>>                       logger.debug(t.getMessage());
>>>>>>>>>>>>>>>>>>>>                   }
>>>>>>>>>>>>>>>>>>>> But generally we use ImageIO
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> On 06/06/2011 08:29 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> Yeah i think i need your help again i tried tu run the
>>>>>>>>>>>>>>>>>>>>> .jar
>>>>>>>>>>>>>>>>>>>>> file
>>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>> console it work but without images this it what appears
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> GRAVE: Error while processing image: I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException:
>>>>>>>>>>>>>>>>>>>>> Cannot
>>>>>>>>>>>>>>>>>>>>> load
>>>>>>>>>>>>>>>>>>>>> image
>>>>>>>>>>>>>>>>>>>>> (no
>>>>>>>>>>>>>>>>>>>>> suitable loader/converter combination available) for
>>>>>>>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> i tried  download the jai-imagio add to the class path
>>>>>>>>>>>>>>>>>>>>> but
>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>> dont
>>>>>>>>>>>>>>>>>>>>> work
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> Very odd.  I'm having no problems getting images into
>>>>>>>>>>>>>>>>>>>>>> pdfs
>>>>>>>>>>>>>>>>>>>>>> using
>>>>>>>>>>>>>>>>>>>>>> fop-1.0.
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> On 06/03/2011 11:04 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> aaa hey thanks for the help the other day, i resolve
>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>> problem
>>>>>>>>>>>>>>>>>>>>>>> changing
>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>> version of FOP for the 0.95beta instead of the 1.0,
>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>> works
>>>>>>>>>>>>>>>>>>>>>>> now
>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>> prints
>>>>>>>>>>>>>>>>>>>>>>> the image and its good, thanks and we are in touch if
>>>>>>>>>>>>>>>>>>>>>>> anything
>>>>>>>>>>>>>>>>>>>>>>> else
>>>>>>>>>>>>>>>>>>>>>>> fails
>>>>>>>>>>>>>>>>>>>>>>> jejeje
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> Nothing in the log from the transformer?
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> On 06/03/2011 09:47 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>> hi there i have another problem i hope you can help
>>>>>>>>>>>>>>>>>>>>>>>>> me
>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>> create
>>>>>>>>>>>>>>>>>>>>>>>>> with foe has no image, it dont show any of them,
>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>> xsl
>>>>>>>>>>>>>>>>>>>>>>>>> seems
>>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>>> be
>>>>>>>>>>>>>>>>>>>>>>>>> rigth i
>>>>>>>>>>>>>>>>>>>>>>>>> tested with EditX and the pdf show me the image,
>>>>>>>>>>>>>>>>>>>>>>>>> what
>>>>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>>> be,
>>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>>> xmlgraphics-commons-1.5svn, fop 1.0, fop-pdf-images
>>>>>>>>>>>>>>>>>>>>>>>>> 2.0.1
>>>>>>>>>>>>>>>>>>>>>>>>> Snapshot
>>>>>>>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>>> render of the image but it don work please help!!!
>>>>>>>>>>>>>>>>>>>>>>>>> :,(
>>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> :-):confused::confused::confused::confused:=)
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>> http://old.nabble.com/file/p31822059/libraries.jpeg
>>>>>>>>> http://old.nabble.com/file/p31822059/libraries.bmp libraries.bmp
>>>>>>>>>
>>>>>>>> ---------------------------------------------------------------------
>>>>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>> For additional commands, e-mail:
>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>> ---------------------------------------------------------------------
>>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>>>>
>>>>>>
>>>>>>
>>>> ---------------------------------------------------------------------
>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>>
>>>>
>>>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>
>>
>>

---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Problems with FOP and image

Posted by "Oscar.Flores" <fa...@hotmail.com>.
Ok aaaa i get it, actually the ImageIO library i added because i read in the
xmlgrapics that if something like the message 
org.apache.xmlgraphics.image.loader.ImageException: Cannot load image (no
suitable loader/converter combination available)appear i have to add the jar
file to the classpath but that all it say no configuration or anything, then
i delete the imagenIO libs and still i have the same output in netbeans so
xmlgrapics seem to have the problem in the plugins or i have to configure
something 

Rob Sargent-4 wrote:
> 
> Then it seems to me netbeans (if it's producing good output == 
> assumptionA) is still using something that the command-line isn't.
> 
> And given assumptionA, you're java code is correct in terms of FOP and 
> your configuration isn't for ImageIO.  Show your ImageIO related code 
> and are you sure it's in your app.  Use the logger to show a message 
> when you add  your loader.  Or list all ImageIO services: 
> IIORegistry.getServiceProviders()
> 
> On 06/13/2011 03:01 PM, Oscar.Flores wrote:
>> ok well i put the xml in scr of my proyect i see that i still have the
>> same
>> issues of the image render of any image i dont now if the xml its in
>> place i
>> put the code down to see if something its missing
>>
>> 15:45:07,827 ERROR [render] Error while processing image:
>> c:\cfd\nombregp.bmp (i
>> mage/bmp)
>> org.apache.xmlgraphics.image.loader.ImageException: Cannot load image (no
>> suitab
>> le loader/converter combination available) for c:\cfd\nombregp.bmp
>> (image/bmp)
>>          at
>> org.apache.xmlgraphics.image.loader.ImageManager.getImage(ImageManage
>>
>>
>>
>> import mx.bigdata.sat.cfd.schema.Comprobante;
>> import mx.bigdata.sat.cfd.CFDv2;
>> import mx.bigdata.sat.security.KeyLoader;
>> import org.jdom.*;
>> import org.jdom.input.SAXBuilder;
>> import org.jdom.output.XMLOutputter;
>> import org.jdom.output.Format;
>> import org.jdom.transform.JDOMSource;
>> //Java
>>   import java.io.File;
>>   import java.io.OutputStream;
>>
>>   //JAXP
>>   import javax.xml.transform.Transformer;
>>   import javax.xml.transform.TransformerFactory;
>>   import javax.xml.transform.Source;
>>   import javax.xml.transform.Result;
>>   import javax.xml.transform.stream.StreamSource;
>>   import javax.xml.transform.sax.SAXResult;
>>
>>   //FOP
>>   import org.apache.fop.apps.FOUserAgent;
>>   import org.apache.fop.apps.Fop;
>>   import org.apache.fop.apps.FopFactory;
>>   import org.apache.fop.apps.MimeConstants;
>>
>>   //log4j
>>   import org.apache.log4j.*;
>>   import org.apache.log4j.xml.DOMConfigurator;
>>
>> public final class Main {
>>      @SuppressWarnings("unchecked")
>>      static Logger logger = Logger.getLogger(Main.class);
>>
>>      public static void main(String[] args) throws Exception {
>>           DOMConfigurator.configure("D:/Mis
>> documentos/NetBeansProjects/Factura/src/factura/log4j.xml");
>>           logger.info("Entering application.");
>>           try {
>>              File file = new File(args[0]);
>>              Comprobante comp = CFDv2.newComprobante(new
>> FileInputStream(file));
>>              CFDv2 cfd = new CFDv2(comp);
>>              PrivateKey key = KeyLoader.loadPKCS8PrivateKey(new
>> FileInputStream(args[1]),(args[2]));
>>              X509Certificate cert = KeyLoader.loadX509Certificate(new
>> FileInputStream(args[3]));
>>              Comprobante sellado = cfd.sellarComprobante(key, cert);
>>              String cadena = cfd.getCadenaOriginal();
>>              String sello = sellado.getSello();
>>              // Creamos el builder basado en SAX
>>              SAXBuilder builder = new SAXBuilder();
>>              // Construimos el arbol DOM a partir del fichero xml
>>              Document documentJDOM = builder.build(new
>> FileInputStream(args[0]));
>>
>>
>>              Element raiz = documentJDOM.getRootElement();//toma el nodo
>> raiz
>> del documento.
>>              raiz.setAttribute("sello", sello);
>>              raiz.setAttribute("certificado", sellado.getCertificado());
>>              //System.out.println(raiz.getAttributeValue("sello"));
>>              //System.out.println(raiz.getAttributeValue("certificado"));
>>              // Recorremos los hijos de la etiqueta raíz
>>              List<Element>  hijosRaiz = raiz.getChildren();
>>              boolean Bandera=false;
>>              for(Element hijo: hijosRaiz)
>>              {
>>                  // Obtenemos el nombre y su contenido de tipo texto
>>                  String nombre = hijo.getName();
>>
>>                  if (nombre.equals("Addenda"))
>>                  {   List<Element>  subHijo = hijo.getChildren();
>>                      for(Element hij: subHijo)
>>                          {
>>                          hij.setAttribute("CadenaOriginal", cadena);
>>                          //System.out.println("CadenaOriginal:
>> "+hij.getAttributeValue("CadenaOriginal"));
>>                          Bandera=true;
>>                          break;
>>                          }
>>                  }
>>                  if (Bandera)
>>                  {
>>                      XMLOutputter out = new
>> XMLOutputter(Format.getPrettyFormat());
>>                      File nuevoXML = new File(args[0]);
>>                      try{
>>                          FileOutputStream archivoXML= new
>> FileOutputStream
>> (nuevoXML);
>>                          out.output(documentJDOM, archivoXML);
>>
>>                         }
>>                      catch (Exception
>> ex){System.out.println(ex.getMessage());}
>>                      // Para generar el pdf a partir de un archivo.xsl y
>> un
>>                      // archivo.xml
>>                  }
>>                }
>>            // configure fopFactory as desired
>>            FopFactory fopFactory = FopFactory.newInstance();
>>            FOUserAgent foUserAgent = fopFactory.newFOUserAgent();
>>
>>            // configure foUserAgent as desired
>>            // Setup output
>>           File pdffile = new File(args[5]);
>>
>>           OutputStream out = new java.io.FileOutputStream(pdffile);
>>           out = new java.io.BufferedOutputStream(out);
>>           try {
>>                  // Construct fop with desired output format
>>                   Fop fop = fopFactory.newFop(MimeConstants.MIME_PDF,
>> foUserAgent, out);
>>                  // Setup XSLT
>>                  TransformerFactory factory =
>> TransformerFactory.newInstance();
>>                  Transformer transformer = factory.newTransformer(new
>> StreamSource(args[4]));
>>                  // Set the value of a  in the stylesheet
>>                  transformer.setParameter("versionParam", "2.0");
>>
>>                 // Setup input for XSLT transformation
>>                  Source src = new JDOMSource(documentJDOM);
>>                   // Resulting SAX events (the generated FO) must be
>> piped
>> through to FOP
>>                  Result res = new SAXResult(fop.getDefaultHandler());
>>                   // Start XSLT transformation and FOP processing
>>                 // System.setProperty("java.awt.headless", "true");
>>                      transformer.transform(src, res);
>>                  } finally {
>>                   out.close();
>>              }
>>
>>
>>            System.out.println("Success!");
>>           } catch (Exception e) {
>>            e.printStackTrace(System.err);
>>            System.exit(-1);
>>         }
>>       logger.info("Exiting application.");
>>
>>    }
>>
>>
>> Rob Sargent-4 wrote:
>>> Try this log4j.xml: Place it at the root of your jar file
>>>
>>> <?xml version="1.0" encoding="UTF-8"?>
>>> <!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">
>>>
>>> <log4j:configuration xmlns:log4j="http://jakarta.apache.org/log4j/"
>>> debug="false">
>>>
>>> <appender name="CONSOLE" class="org.apache.log4j.ConsoleAppender">
>>>
>>>
>>>
>>> <layout class="org.apache.log4j.PatternLayout">
>>>
>>> </layout>
>>> </appender>
>>>
>>> <category name="org">
>>> <priority value="DEBUG"/>
>>> </category>
>>> <category name="org.apache">
>>> <priority value="WARN"/>
>>> </category>
>>> <category name="org.springframework">
>>> <priority value="WARN"/>
>>> </category>
>>> <category name="org.hibernate">
>>> <priority value="DEBUG"/>
>>> </category>
>>> <category name="net">
>>> <priority value="ERROR"/>
>>> </category>
>>> <category name="javax">
>>> <priority value="ERROR"/>
>>> </category>
>>> <category name="java">
>>> <priority value="ERROR"/>
>>> </category>
>>> <category name="sun">
>>> <priority value="ERROR"/>
>>> </category>
>>> <category name="org.jboss">
>>> <priority value="INFO"/>
>>> </category>
>>> <category name="org.jboss.seam">
>>> <priority value="ERROR"/>
>>> </category>
>>> <root>
>>> <appender-ref ref="CONSOLE"/>
>>> </root>
>>>
>>> </log4j:configuration>
>>>
>>>
>>> On 06/13/2011 11:06 AM, Oscar.Flores wrote:
>>>> ok i dont thik i have a configuracion file i find the code that i put
>>>> in
>>>> the
>>>> other post i think its the basic
>>>>
>>>>
>>>> Rob Sargent-4 wrote:
>>>>> Do you have a config file for log4j.  Usually it's in a resource tree.
>>>>> Are you copying that to your deployment? Is your ant script including
>>>>> the config file in the jar of your application?
>>>>>
>>>>> On 06/13/2011 10:12 AM, Oscar.Flores wrote:
>>>>>> Ok yeah the log4j its having isuees to find the configuration
>>>>>>
>>>>>> log4j:WARN No appenders could be found for logger
>>>>>> (org.apache.fop.util.ContentHandlerFactoryRegistry).
>>>>>> log4j:WARN Please initialize the log4j system properly.
>>>>>> log4j:WARN See http://logging.apache.org/log4j/1.2/faq.html#noconfig
>>>>>> for
>>>>>> more info.
>>>>>> i go to the faq guide and it say try loading the class or resource
>>>>>> yourself.
>>>>>> If you can't find it, neither will log4j.
>>>>>>
>>>>>> aaa i dont know where to set this
>>>>>>
>>>>>> also here its my xlst
>>>>>>
>>>>>>
>>>>>> http://old.nabble.com/file/p31835645/FacturasOMF.xsl FacturasOMF.xsl
>>>>>>
>>>>>>
>>>>>> and the fo file that generate the editix
>>>>>>
>>>>>> http://old.nabble.com/file/p31835645/Prueba.fo Prueba.fo
>>>>>>
>>>>>>
>>>>>> Rob Sargent-4 wrote:
>>>>>>> The first thing is to really dig into what you did to netbeans to
>>>>>>> get
>>>>>>> it
>>>>>>> to work...
>>>>>>>
>>>>>>> I've forgotten what your stylesheet looked like, so maybe if you
>>>>>>> show
>>>>>>> us
>>>>>>> again how you're referencing your images we might notice a problem.
>>>>>>>
>>>>>>> It might also help to see the "fo" generated during your
>>>>>>> transformation.
>>>>>>> Can you grab that just after xslt and just before fop calls.
>>>>>>>
>>>>>>> Are you sure there is no error being logged somewhere when you run
>>>>>>> from
>>>>>>> the command line? (Where is log4j writing and at what level?)
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> Oscar.Flores wrote:
>>>>>>>> You where absolutly rigth i miss a few libraries to add into the
>>>>>>>> jar
>>>>>>>> file, i
>>>>>>>> modified the build.xml to add the package and jar that i need, now
>>>>>>>> the
>>>>>>>> error
>>>>>>>> message is not there but still the images dont show in the pdf i
>>>>>>>> remeber
>>>>>>>> that i do something in netbeans so they can add to the pdf but i
>>>>>>>> cant
>>>>>>>> remeber i dont now if there is still a library that is missing or i
>>>>>>>> am
>>>>>>>> adding more than it should be
>>>>>>>> This is what i use :
>>>>>>>> cfdi-base-0.1.6-SNAPSHOT.jar
>>>>>>>> guava-r09.jar
>>>>>>>> guava-r09-gwt.jar
>>>>>>>> jaxb-impl-2.1.10.jar
>>>>>>>> avalon-framework-api-4.3.jar
>>>>>>>> avalon-framework-cvs-20020806.jar
>>>>>>>> avalon-logkit-2.1.jar
>>>>>>>> not-yet-commons-ssl-0.3.11.jar
>>>>>>>> commons-codec-1.5.jar
>>>>>>>> commons-codec-1.5-sources.jar
>>>>>>>> log4j-1.2.16.jar
>>>>>>>> fop.jar
>>>>>>>> jdom.jar
>>>>>>>> xmlgraphics-commons-1.4.jar
>>>>>>>> commons-io-1.3.1.jar
>>>>>>>> fop-pdf-images-2.0.1.SNAPSHOT.jar
>>>>>>>> pdfbox-app-1.5.0.jar
>>>>>>>> fontbox-1.3.1.jar
>>>>>>>> jempbox-1.3.1.jar
>>>>>>>> xercesImpl-2.7.1.jar
>>>>>>>> batik-all-1.7.jar
>>>>>>>> xml-apis-1.3.04.jar
>>>>>>>> xml-apis-ext-1.3.04.jar
>>>>>>>>     avalon-framework-4.2.0.jar
>>>>>>>>     xalan-2.7.0.jar
>>>>>>>>     serializer-2.7.0.jar
>>>>>>>>     commons-logging-1.0.4.jar
>>>>>>>>     jai_codec.jar
>>>>>>>>     jai_core.jar
>>>>>>>>     batik-ext.jar
>>>>>>>>     jai_imageio-1.1-sources.jar
>>>>>>>>
>>>>>>>> Thanks Rob for the help
>>>>>>>>
>>>>>>>>
>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>
>>>>>>>>> I suspect running from your jar does not have/use the same
>>>>>>>>> classpath
>>>>>>>>> that is in effect while you're in the debugger.
>>>>>>>>> By what mechanism do you generate the jar?
>>>>>>>>> Is it an executable jar or are you running java -classpath
>>>>>>>>> <your-jar-here:other-jars>    Main?
>>>>>>>>> Make your IDE (netbeans) display the classpath  it uses to run
>>>>>>>>> your
>>>>>>>>> app
>>>>>>>>> and compare that with the above.
>>>>>>>>>
>>>>>>>>> On 06/09/2011 07:21 PM, Oscar.Flores wrote:
>>>>>>>>>
>>>>>>>>>> aaa ok well my problem is that when i do the pdf in netbean the
>>>>>>>>>> pdf
>>>>>>>>>> is
>>>>>>>>>> fine
>>>>>>>>>> with images and evething but when i run the jar file in command
>>>>>>>>>> it
>>>>>>>>>> give
>>>>>>>>>> me a
>>>>>>>>>> error
>>>>>>>>>>
>>>>>>>>>> GRAVE: Error while processing image: I:\cfd\rfc.jpg (image/jpeg)
>>>>>>>>>>      org.apache.xmlgraphics.image.loader.ImageException: Cannot
>>>>>>>>>> load
>>>>>>>>>>      image (no suitable loader/converter combination available)
>>>>>>>>>> for
>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>      (image/jpeg)
>>>>>>>>>>
>>>>>>>>>> so i dont no what its not working and if i have to add something
>>>>>>>>>> to
>>>>>>>>>> my
>>>>>>>>>> code
>>>>>>>>>> so the images can load i am soooo desperate what i am doing
>>>>>>>>>> wrong??
>>>>>>>>>> i am sorry for the trouble and if a dont explain my self very
>>>>>>>>>> good
>>>>>>>>>> jejeje
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>
>>>>>>>>>>> Not at all sure what your problem is.  All I can do is show you
>>>>>>>>>>> what
>>>>>>>>>>> works for us.
>>>>>>>>>>>
>>>>>>>>>>> Our source xml looks like this:
>>>>>>>>>>> <image image-id="381623861" reference-id="ref-220" width="750"
>>>>>>>>>>> height="750" image-space-id="space-1" position="5"
>>>>>>>>>>>                   image-pool-position="31" pos="4"
>>>>>>>>>>>                   file="ref_10_1002108221">     <!-- an actual
>>>>>>>>>>> file
>>>>>>>>>>> (.jpeg
>>>>>>>>>>> copied the working directory of the transformer -->
>>>>>>>>>>> <fields />
>>>>>>>>>>> <caption />
>>>>>>>>>>> <annotations>
>>>>>>>>>>> <arrow_positions origHeight="750" origWidth="750" />
>>>>>>>>>>> </annotations>
>>>>>>>>>>> </image>
>>>>>>>>>>>
>>>>>>>>>>> Our xslt looks like this for each image needed.
>>>>>>>>>>>
>>>>>>>>>>> <xsl:template name="image">
>>>>>>>>>>> <xsl:param name="img"/>     <!-- This is the xml node from the
>>>>>>>>>>> source
>>>>>>>>>>> xml
>>>>>>>>>>> above -->
>>>>>>>>>>> <xsl:param name="width"/>
>>>>>>>>>>> <xsl:param name="height" select="$width"/>
>>>>>>>>>>> <xsl:param name="ignoreHeight">false</xsl:param>
>>>>>>>>>>> <fo:block>
>>>>>>>>>>> <fo:external-graphic src="{$img/@file}" height="{$height}"
>>>>>>>>>>> width="{$width}" content-height="scale-to-fit"
>>>>>>>>>>>                                      
>>>>>>>>>>> content-width="scale-to-fit"
>>>>>>>>>>> border="0.5pt solid black" border-collapse="separate">
>>>>>>>>>>> <xsl:if test="$ignoreHeight != 'true'">
>>>>>>>>>>> <xsl:attribute name="height">
>>>>>>>>>>> <xsl:value-of select="$height"/>
>>>>>>>>>>> </xsl:attribute>
>>>>>>>>>>> </xsl:if>
>>>>>>>>>>> </fo:external-graphic>
>>>>>>>>>>> </fo:block>
>>>>>>>>>>> </xsl:template>
>>>>>>>>>>>
>>>>>>>>>>> Our generated fo looks like this:
>>>>>>>>>>> <fo:table-cell>
>>>>>>>>>>> <fo:block>
>>>>>>>>>>> <fo:external-graphic border-collapse="separate" border="0.5pt
>>>>>>>>>>> solid
>>>>>>>>>>> black" content-width="scale-to-fit"
>>>>>>>>>>> content-height="scale-to-fit"
>>>>>>>>>>> width="2.5in" height="2.5in" src="ref_10_1002108221" />
>>>>>>>>>>> </fo:block>
>>>>>>>>>>> </fo:table-cell>
>>>>>>>>>>>
>>>>>>>>>>> And the generated pdfs include the image and are shipped to the
>>>>>>>>>>> printer.
>>>>>>>>>>>
>>>>>>>>>>> How does this stack up with what you have?
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> On 06/09/2011 01:19 PM, Oscar.Flores wrote:
>>>>>>>>>>>
>>>>>>>>>>>> Hi there well i still got the problem but searching IN INTERNET
>>>>>>>>>>>> i
>>>>>>>>>>>> find
>>>>>>>>>>>> a
>>>>>>>>>>>> JPEG
>>>>>>>>>>>> renderer output for FOP its here
>>>>>>>>>>>>
>>>>>>>>>>>> http://marc.info/?l=fop-user&m=125986752706366&w=2
>>>>>>>>>>>>
>>>>>>>>>>>> the cuestion is can i render the image that i want to put in
>>>>>>>>>>>> the
>>>>>>>>>>>> pdf,
>>>>>>>>>>>> and
>>>>>>>>>>>> then add to the xsl the render jpeg it will work??
>>>>>>>>>>>>
>>>>>>>>>>>> and here explaints how use the render when he say uses fop as
>>>>>>>>>>>> normal
>>>>>>>>>>>> case
>>>>>>>>>>>> what does it mean
>>>>>>>>>>>> what else have to add to the code?? i hope you can help me
>>>>>>>>>>>>
>>>>>>>>>>>> Thanks!!
>>>>>>>>>>>>
>>>>>>>>>>>> // OutputStream out = what you want
>>>>>>>>>>>>                  FopFactory fopFactory =
>>>>>>>>>>>> FopFactory.newInstance();
>>>>>>>>>>>>                  RendererFactory rendererFactory = null;
>>>>>>>>>>>>                  FOUserAgent foUserAgent = null;
>>>>>>>>>>>>
>>>>>>>>>>>>                  rendererFactory =
>>>>>>>>>>>> fopFactory.getRendererFactory();
>>>>>>>>>>>>                  rendererFactory.addRendererMaker(new
>>>>>>>>>>>> MultiRendererMaker("jpeg"));
>>>>>>>>>>>>                  foUserAgent = fopFactory.newFOUserAgent();
>>>>>>>>>>>>                  rendererFactory.createRenderer(foUserAgent,
>>>>>>>>>>>> "image/jpeg");
>>>>>>>>>>>>
>>>>>>>>>>>>                  Fop fop = fopFactory.newFop("image/jpeg",
>>>>>>>>>>>> foUserAgent,
>>>>>>>>>>>> out);
>>>>>>>>>>>>
>>>>>>>>>>>> //Use fop as normal case
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>
>>>>>>>>>>>>> Since you're now into xmlgraphics, I think you're best bet is
>>>>>>>>>>>>> here
>>>>>>>>>>>>> <http://xmlgraphics.apache.org/commons/image-loader.html>
>>>>>>>>>>>>>
>>>>>>>>>>>>> On 06/07/2011 10:18 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>
>>>>>>>>>>>>>> Hi ok this is for generate images that dont need to be
>>>>>>>>>>>>>> decompress
>>>>>>>>>>>>>> later??
>>>>>>>>>>>>>> and
>>>>>>>>>>>>>> the result image i put in my xsl ?? then it should work, aaa
>>>>>>>>>>>>>> i
>>>>>>>>>>>>>> change
>>>>>>>>>>>>>> to
>>>>>>>>>>>>>> fop
>>>>>>>>>>>>>> 1.0 and xml communs 1.4 and its the same jejeje   dont find
>>>>>>>>>>>>>> the
>>>>>>>>>>>>>> image
>>>>>>>>>>>>>> preload
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> org.apache.fop.fo.flow.ExternalGraphic bind
>>>>>>>>>>>>>> SEVERE: Image not available: The file format is not
>>>>>>>>>>>>>> supported.
>>>>>>>>>>>>>> No
>>>>>>>>>>>>>> ImagePreloader for *.jpg or *.bmp
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> ImageIO.write(bufferedImage, "JPEG", file);
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> On 06/07/2011 08:21 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> Ok i actually register the handler now what i have to do is
>>>>>>>>>>>>>>>> setup
>>>>>>>>>>>>>>>> this
>>>>>>>>>>>>>>>> handler or not?? and how can i do that, also it seem that
>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>> bmp
>>>>>>>>>>>>>>>> its
>>>>>>>>>>>>>>>> not
>>>>>>>>>>>>>>>> recognice also what can i do?? thanks for the help rob
>>>>>>>>>>>>>>>> also i am trying to convert the images to see if it that
>>>>>>>>>>>>>>>> helps
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> On 06/06/2011 02:29 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> Hi what can be the difference between execute the program
>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>> netbeans
>>>>>>>>>>>>>>>>>> (where
>>>>>>>>>>>>>>>>>> it works and print the images and the jar in the console)
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> Different classes being loaded by Netbeans than the
>>>>>>>>>>>>>>>>> console
>>>>>>>>>>>>>>>>> app.
>>>>>>>>>>>>>>>>> Get
>>>>>>>>>>>>>>>>> Netbeans to show you the full classpath it's using in it's
>>>>>>>>>>>>>>>>> "%classpath"
>>>>>>>>>>>>>>>>> variable
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> also i tried the
>>>>>>>>>>>>>>>>>> imageIO.getImageReadersBySuffix but i cant interpretate
>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>> data
>>>>>>>>>>>>>>>>>> y.y,
>>>>>>>>>>>>>>>>>> its
>>>>>>>>>>>>>>>>>> that or always its true in the boolean variable, and how
>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>> register
>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>> handler??
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> Talk to IIORegistry, some thing like
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>>>>>> CLibJPEGImageReaderSpi());
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>>>>>> CLibJPEGImageWriterSpi());
>>>>>>>>>>>>>>>>> Note: those are not necessarily the services you have in
>>>>>>>>>>>>>>>>> your
>>>>>>>>>>>>>>>>> setup.
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> Thanks
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> See the javadoc on IIORegistry. With ImageIO you may
>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>> register
>>>>>>>>>>>>>>>>>>> your handler(s). What does
>>>>>>>>>>>>>>>>>>> ImageIO.getImageReadersBySuffix()
>>>>>>>>>>>>>>>>>>> give
>>>>>>>>>>>>>>>>>>> you.
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> For certain jpegs we don't use ImageIO, rather the
>>>>>>>>>>>>>>>>>>> classes
>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>> com.sun.image.codec.jpeg:
>>>>>>>>>>>>>>>>>>>                  try {
>>>>>>>>>>>>>>>>>>>                      FileOutputStream fos = new
>>>>>>>>>>>>>>>>>>> FileOutputStream(file);
>>>>>>>>>>>>>>>>>>>                      JPEGImageEncoder encoder =
>>>>>>>>>>>>>>>>>>> JPEGCodec.createJPEGEncoder(fos);
>>>>>>>>>>>>>>>>>>>                      JPEGEncodeParam param =
>>>>>>>>>>>>>>>>>>> encoder.getDefaultJPEGEncodeParam(image.getRaster(),
>>>>>>>>>>>>>>>>>>> JPEGDecodeParam.COLOR_ID_CMYK);
>>>>>>>>>>>>>>>>>>>                      param.setQuality(1, false);
>>>>>>>>>>>>>>>>>>>                      encoder.encode(image.getRaster(),
>>>>>>>>>>>>>>>>>>> param);
>>>>>>>>>>>>>>>>>>>                      fos.close();
>>>>>>>>>>>>>>>>>>>                  } catch (Throwable t) {
>>>>>>>>>>>>>>>>>>>                      logger.debug(t.getMessage());
>>>>>>>>>>>>>>>>>>>                  }
>>>>>>>>>>>>>>>>>>> But generally we use ImageIO
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> On 06/06/2011 08:29 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> Yeah i think i need your help again i tried tu run the
>>>>>>>>>>>>>>>>>>>> .jar
>>>>>>>>>>>>>>>>>>>> file
>>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>> console it work but without images this it what appears
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> GRAVE: Error while processing image: I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException:
>>>>>>>>>>>>>>>>>>>> Cannot
>>>>>>>>>>>>>>>>>>>> load
>>>>>>>>>>>>>>>>>>>> image
>>>>>>>>>>>>>>>>>>>> (no
>>>>>>>>>>>>>>>>>>>> suitable loader/converter combination available) for
>>>>>>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> i tried  download the jai-imagio add to the class path
>>>>>>>>>>>>>>>>>>>> but
>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>> dont
>>>>>>>>>>>>>>>>>>>> work
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> Very odd.  I'm having no problems getting images into
>>>>>>>>>>>>>>>>>>>>> pdfs
>>>>>>>>>>>>>>>>>>>>> using
>>>>>>>>>>>>>>>>>>>>> fop-1.0.
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> On 06/03/2011 11:04 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> aaa hey thanks for the help the other day, i resolve
>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>> problem
>>>>>>>>>>>>>>>>>>>>>> changing
>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>> version of FOP for the 0.95beta instead of the 1.0,
>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>> works
>>>>>>>>>>>>>>>>>>>>>> now
>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>> prints
>>>>>>>>>>>>>>>>>>>>>> the image and its good, thanks and we are in touch if
>>>>>>>>>>>>>>>>>>>>>> anything
>>>>>>>>>>>>>>>>>>>>>> else
>>>>>>>>>>>>>>>>>>>>>> fails
>>>>>>>>>>>>>>>>>>>>>> jejeje
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> Nothing in the log from the transformer?
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> On 06/03/2011 09:47 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>> hi there i have another problem i hope you can help
>>>>>>>>>>>>>>>>>>>>>>>> me
>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>> create
>>>>>>>>>>>>>>>>>>>>>>>> with foe has no image, it dont show any of them,
>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>> xsl
>>>>>>>>>>>>>>>>>>>>>>>> seems
>>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>>> be
>>>>>>>>>>>>>>>>>>>>>>>> rigth i
>>>>>>>>>>>>>>>>>>>>>>>> tested with EditX and the pdf show me the image,
>>>>>>>>>>>>>>>>>>>>>>>> what
>>>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>>> be,
>>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>>> xmlgraphics-commons-1.5svn, fop 1.0, fop-pdf-images
>>>>>>>>>>>>>>>>>>>>>>>> 2.0.1
>>>>>>>>>>>>>>>>>>>>>>>> Snapshot
>>>>>>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>>> render of the image but it don work please help!!!
>>>>>>>>>>>>>>>>>>>>>>>> :,(
>>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> :-):confused::confused::confused::confused:=)
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>> For additional commands, e-mail:
>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>> http://old.nabble.com/file/p31822059/libraries.jpeg
>>>>>>>> http://old.nabble.com/file/p31822059/libraries.bmp libraries.bmp
>>>>>>>>
>>>>>>> ---------------------------------------------------------------------
>>>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>> For additional commands, e-mail:
>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>
>>>>>>>
>>>>>>>
>>>>> ---------------------------------------------------------------------
>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>>>
>>>>>
>>>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>
>>>
>>>
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
> 
> 
> 

-- 
View this message in context: http://old.nabble.com/Problems-with-FOP-and-image-tp31766430p31838560.html
Sent from the FOP - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Problems with FOP and image

Posted by Rob Sargent <rs...@xmission.com>.
Then it seems to me netbeans (if it's producing good output == 
assumptionA) is still using something that the command-line isn't.

And given assumptionA, you're java code is correct in terms of FOP and 
your configuration isn't for ImageIO.  Show your ImageIO related code 
and are you sure it's in your app.  Use the logger to show a message 
when you add  your loader.  Or list all ImageIO services: 
IIORegistry.getServiceProviders()

On 06/13/2011 03:01 PM, Oscar.Flores wrote:
> ok well i put the xml in scr of my proyect i see that i still have the same
> issues of the image render of any image i dont now if the xml its in place i
> put the code down to see if something its missing
>
> 15:45:07,827 ERROR [render] Error while processing image:
> c:\cfd\nombregp.bmp (i
> mage/bmp)
> org.apache.xmlgraphics.image.loader.ImageException: Cannot load image (no
> suitab
> le loader/converter combination available) for c:\cfd\nombregp.bmp
> (image/bmp)
>          at
> org.apache.xmlgraphics.image.loader.ImageManager.getImage(ImageManage
>
>
>
> import mx.bigdata.sat.cfd.schema.Comprobante;
> import mx.bigdata.sat.cfd.CFDv2;
> import mx.bigdata.sat.security.KeyLoader;
> import org.jdom.*;
> import org.jdom.input.SAXBuilder;
> import org.jdom.output.XMLOutputter;
> import org.jdom.output.Format;
> import org.jdom.transform.JDOMSource;
> //Java
>   import java.io.File;
>   import java.io.OutputStream;
>
>   //JAXP
>   import javax.xml.transform.Transformer;
>   import javax.xml.transform.TransformerFactory;
>   import javax.xml.transform.Source;
>   import javax.xml.transform.Result;
>   import javax.xml.transform.stream.StreamSource;
>   import javax.xml.transform.sax.SAXResult;
>
>   //FOP
>   import org.apache.fop.apps.FOUserAgent;
>   import org.apache.fop.apps.Fop;
>   import org.apache.fop.apps.FopFactory;
>   import org.apache.fop.apps.MimeConstants;
>
>   //log4j
>   import org.apache.log4j.*;
>   import org.apache.log4j.xml.DOMConfigurator;
>
> public final class Main {
>      @SuppressWarnings("unchecked")
>      static Logger logger = Logger.getLogger(Main.class);
>
>      public static void main(String[] args) throws Exception {
>           DOMConfigurator.configure("D:/Mis
> documentos/NetBeansProjects/Factura/src/factura/log4j.xml");
>           logger.info("Entering application.");
>           try {
>              File file = new File(args[0]);
>              Comprobante comp = CFDv2.newComprobante(new
> FileInputStream(file));
>              CFDv2 cfd = new CFDv2(comp);
>              PrivateKey key = KeyLoader.loadPKCS8PrivateKey(new
> FileInputStream(args[1]),(args[2]));
>              X509Certificate cert = KeyLoader.loadX509Certificate(new
> FileInputStream(args[3]));
>              Comprobante sellado = cfd.sellarComprobante(key, cert);
>              String cadena = cfd.getCadenaOriginal();
>              String sello = sellado.getSello();
>              // Creamos el builder basado en SAX
>              SAXBuilder builder = new SAXBuilder();
>              // Construimos el arbol DOM a partir del fichero xml
>              Document documentJDOM = builder.build(new
> FileInputStream(args[0]));
>
>
>              Element raiz = documentJDOM.getRootElement();//toma el nodo raiz
> del documento.
>              raiz.setAttribute("sello", sello);
>              raiz.setAttribute("certificado", sellado.getCertificado());
>              //System.out.println(raiz.getAttributeValue("sello"));
>              //System.out.println(raiz.getAttributeValue("certificado"));
>              // Recorremos los hijos de la etiqueta raíz
>              List<Element>  hijosRaiz = raiz.getChildren();
>              boolean Bandera=false;
>              for(Element hijo: hijosRaiz)
>              {
>                  // Obtenemos el nombre y su contenido de tipo texto
>                  String nombre = hijo.getName();
>
>                  if (nombre.equals("Addenda"))
>                  {   List<Element>  subHijo = hijo.getChildren();
>                      for(Element hij: subHijo)
>                          {
>                          hij.setAttribute("CadenaOriginal", cadena);
>                          //System.out.println("CadenaOriginal:
> "+hij.getAttributeValue("CadenaOriginal"));
>                          Bandera=true;
>                          break;
>                          }
>                  }
>                  if (Bandera)
>                  {
>                      XMLOutputter out = new
> XMLOutputter(Format.getPrettyFormat());
>                      File nuevoXML = new File(args[0]);
>                      try{
>                          FileOutputStream archivoXML= new FileOutputStream
> (nuevoXML);
>                          out.output(documentJDOM, archivoXML);
>
>                         }
>                      catch (Exception
> ex){System.out.println(ex.getMessage());}
>                      // Para generar el pdf a partir de un archivo.xsl y un
>                      // archivo.xml
>                  }
>                }
>            // configure fopFactory as desired
>            FopFactory fopFactory = FopFactory.newInstance();
>            FOUserAgent foUserAgent = fopFactory.newFOUserAgent();
>
>            // configure foUserAgent as desired
>            // Setup output
>           File pdffile = new File(args[5]);
>
>           OutputStream out = new java.io.FileOutputStream(pdffile);
>           out = new java.io.BufferedOutputStream(out);
>           try {
>                  // Construct fop with desired output format
>                   Fop fop = fopFactory.newFop(MimeConstants.MIME_PDF,
> foUserAgent, out);
>                  // Setup XSLT
>                  TransformerFactory factory =
> TransformerFactory.newInstance();
>                  Transformer transformer = factory.newTransformer(new
> StreamSource(args[4]));
>                  // Set the value of a  in the stylesheet
>                  transformer.setParameter("versionParam", "2.0");
>
>                 // Setup input for XSLT transformation
>                  Source src = new JDOMSource(documentJDOM);
>                   // Resulting SAX events (the generated FO) must be piped
> through to FOP
>                  Result res = new SAXResult(fop.getDefaultHandler());
>                   // Start XSLT transformation and FOP processing
>                 // System.setProperty("java.awt.headless", "true");
>                      transformer.transform(src, res);
>                  } finally {
>                   out.close();
>              }
>
>
>            System.out.println("Success!");
>           } catch (Exception e) {
>            e.printStackTrace(System.err);
>            System.exit(-1);
>         }
>       logger.info("Exiting application.");
>
>    }
>
>
> Rob Sargent-4 wrote:
>> Try this log4j.xml: Place it at the root of your jar file
>>
>> <?xml version="1.0" encoding="UTF-8"?>
>> <!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">
>>
>> <log4j:configuration xmlns:log4j="http://jakarta.apache.org/log4j/"
>> debug="false">
>>
>> <appender name="CONSOLE" class="org.apache.log4j.ConsoleAppender">
>>
>>
>>
>> <layout class="org.apache.log4j.PatternLayout">
>>
>> </layout>
>> </appender>
>>
>> <category name="org">
>> <priority value="DEBUG"/>
>> </category>
>> <category name="org.apache">
>> <priority value="WARN"/>
>> </category>
>> <category name="org.springframework">
>> <priority value="WARN"/>
>> </category>
>> <category name="org.hibernate">
>> <priority value="DEBUG"/>
>> </category>
>> <category name="net">
>> <priority value="ERROR"/>
>> </category>
>> <category name="javax">
>> <priority value="ERROR"/>
>> </category>
>> <category name="java">
>> <priority value="ERROR"/>
>> </category>
>> <category name="sun">
>> <priority value="ERROR"/>
>> </category>
>> <category name="org.jboss">
>> <priority value="INFO"/>
>> </category>
>> <category name="org.jboss.seam">
>> <priority value="ERROR"/>
>> </category>
>> <root>
>> <appender-ref ref="CONSOLE"/>
>> </root>
>>
>> </log4j:configuration>
>>
>>
>> On 06/13/2011 11:06 AM, Oscar.Flores wrote:
>>> ok i dont thik i have a configuracion file i find the code that i put in
>>> the
>>> other post i think its the basic
>>>
>>>
>>> Rob Sargent-4 wrote:
>>>> Do you have a config file for log4j.  Usually it's in a resource tree.
>>>> Are you copying that to your deployment? Is your ant script including
>>>> the config file in the jar of your application?
>>>>
>>>> On 06/13/2011 10:12 AM, Oscar.Flores wrote:
>>>>> Ok yeah the log4j its having isuees to find the configuration
>>>>>
>>>>> log4j:WARN No appenders could be found for logger
>>>>> (org.apache.fop.util.ContentHandlerFactoryRegistry).
>>>>> log4j:WARN Please initialize the log4j system properly.
>>>>> log4j:WARN See http://logging.apache.org/log4j/1.2/faq.html#noconfig
>>>>> for
>>>>> more info.
>>>>> i go to the faq guide and it say try loading the class or resource
>>>>> yourself.
>>>>> If you can't find it, neither will log4j.
>>>>>
>>>>> aaa i dont know where to set this
>>>>>
>>>>> also here its my xlst
>>>>>
>>>>>
>>>>> http://old.nabble.com/file/p31835645/FacturasOMF.xsl FacturasOMF.xsl
>>>>>
>>>>>
>>>>> and the fo file that generate the editix
>>>>>
>>>>> http://old.nabble.com/file/p31835645/Prueba.fo Prueba.fo
>>>>>
>>>>>
>>>>> Rob Sargent-4 wrote:
>>>>>> The first thing is to really dig into what you did to netbeans to get
>>>>>> it
>>>>>> to work...
>>>>>>
>>>>>> I've forgotten what your stylesheet looked like, so maybe if you show
>>>>>> us
>>>>>> again how you're referencing your images we might notice a problem.
>>>>>>
>>>>>> It might also help to see the "fo" generated during your
>>>>>> transformation.
>>>>>> Can you grab that just after xslt and just before fop calls.
>>>>>>
>>>>>> Are you sure there is no error being logged somewhere when you run
>>>>>> from
>>>>>> the command line? (Where is log4j writing and at what level?)
>>>>>>
>>>>>>
>>>>>>
>>>>>> Oscar.Flores wrote:
>>>>>>> You where absolutly rigth i miss a few libraries to add into the jar
>>>>>>> file, i
>>>>>>> modified the build.xml to add the package and jar that i need, now
>>>>>>> the
>>>>>>> error
>>>>>>> message is not there but still the images dont show in the pdf i
>>>>>>> remeber
>>>>>>> that i do something in netbeans so they can add to the pdf but i cant
>>>>>>> remeber i dont now if there is still a library that is missing or i
>>>>>>> am
>>>>>>> adding more than it should be
>>>>>>> This is what i use :
>>>>>>> cfdi-base-0.1.6-SNAPSHOT.jar
>>>>>>> guava-r09.jar
>>>>>>> guava-r09-gwt.jar
>>>>>>> jaxb-impl-2.1.10.jar
>>>>>>> avalon-framework-api-4.3.jar
>>>>>>> avalon-framework-cvs-20020806.jar
>>>>>>> avalon-logkit-2.1.jar
>>>>>>> not-yet-commons-ssl-0.3.11.jar
>>>>>>> commons-codec-1.5.jar
>>>>>>> commons-codec-1.5-sources.jar
>>>>>>> log4j-1.2.16.jar
>>>>>>> fop.jar
>>>>>>> jdom.jar
>>>>>>> xmlgraphics-commons-1.4.jar
>>>>>>> commons-io-1.3.1.jar
>>>>>>> fop-pdf-images-2.0.1.SNAPSHOT.jar
>>>>>>> pdfbox-app-1.5.0.jar
>>>>>>> fontbox-1.3.1.jar
>>>>>>> jempbox-1.3.1.jar
>>>>>>> xercesImpl-2.7.1.jar
>>>>>>> batik-all-1.7.jar
>>>>>>> xml-apis-1.3.04.jar
>>>>>>> xml-apis-ext-1.3.04.jar
>>>>>>>     avalon-framework-4.2.0.jar
>>>>>>>     xalan-2.7.0.jar
>>>>>>>     serializer-2.7.0.jar
>>>>>>>     commons-logging-1.0.4.jar
>>>>>>>     jai_codec.jar
>>>>>>>     jai_core.jar
>>>>>>>     batik-ext.jar
>>>>>>>     jai_imageio-1.1-sources.jar
>>>>>>>
>>>>>>> Thanks Rob for the help
>>>>>>>
>>>>>>>
>>>>>>> Rob Sargent-4 wrote:
>>>>>>>
>>>>>>>> I suspect running from your jar does not have/use the same classpath
>>>>>>>> that is in effect while you're in the debugger.
>>>>>>>> By what mechanism do you generate the jar?
>>>>>>>> Is it an executable jar or are you running java -classpath
>>>>>>>> <your-jar-here:other-jars>    Main?
>>>>>>>> Make your IDE (netbeans) display the classpath  it uses to run your
>>>>>>>> app
>>>>>>>> and compare that with the above.
>>>>>>>>
>>>>>>>> On 06/09/2011 07:21 PM, Oscar.Flores wrote:
>>>>>>>>
>>>>>>>>> aaa ok well my problem is that when i do the pdf in netbean the pdf
>>>>>>>>> is
>>>>>>>>> fine
>>>>>>>>> with images and evething but when i run the jar file in command it
>>>>>>>>> give
>>>>>>>>> me a
>>>>>>>>> error
>>>>>>>>>
>>>>>>>>> GRAVE: Error while processing image: I:\cfd\rfc.jpg (image/jpeg)
>>>>>>>>>      org.apache.xmlgraphics.image.loader.ImageException: Cannot load
>>>>>>>>>      image (no suitable loader/converter combination available) for
>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>      (image/jpeg)
>>>>>>>>>
>>>>>>>>> so i dont no what its not working and if i have to add something to
>>>>>>>>> my
>>>>>>>>> code
>>>>>>>>> so the images can load i am soooo desperate what i am doing wrong??
>>>>>>>>> i am sorry for the trouble and if a dont explain my self very good
>>>>>>>>> jejeje
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>
>>>>>>>>>> Not at all sure what your problem is.  All I can do is show you
>>>>>>>>>> what
>>>>>>>>>> works for us.
>>>>>>>>>>
>>>>>>>>>> Our source xml looks like this:
>>>>>>>>>> <image image-id="381623861" reference-id="ref-220" width="750"
>>>>>>>>>> height="750" image-space-id="space-1" position="5"
>>>>>>>>>>                   image-pool-position="31" pos="4"
>>>>>>>>>>                   file="ref_10_1002108221">     <!-- an actual file
>>>>>>>>>> (.jpeg
>>>>>>>>>> copied the working directory of the transformer -->
>>>>>>>>>> <fields />
>>>>>>>>>> <caption />
>>>>>>>>>> <annotations>
>>>>>>>>>> <arrow_positions origHeight="750" origWidth="750" />
>>>>>>>>>> </annotations>
>>>>>>>>>> </image>
>>>>>>>>>>
>>>>>>>>>> Our xslt looks like this for each image needed.
>>>>>>>>>>
>>>>>>>>>> <xsl:template name="image">
>>>>>>>>>> <xsl:param name="img"/>     <!-- This is the xml node from the
>>>>>>>>>> source
>>>>>>>>>> xml
>>>>>>>>>> above -->
>>>>>>>>>> <xsl:param name="width"/>
>>>>>>>>>> <xsl:param name="height" select="$width"/>
>>>>>>>>>> <xsl:param name="ignoreHeight">false</xsl:param>
>>>>>>>>>> <fo:block>
>>>>>>>>>> <fo:external-graphic src="{$img/@file}" height="{$height}"
>>>>>>>>>> width="{$width}" content-height="scale-to-fit"
>>>>>>>>>>                                       content-width="scale-to-fit"
>>>>>>>>>> border="0.5pt solid black" border-collapse="separate">
>>>>>>>>>> <xsl:if test="$ignoreHeight != 'true'">
>>>>>>>>>> <xsl:attribute name="height">
>>>>>>>>>> <xsl:value-of select="$height"/>
>>>>>>>>>> </xsl:attribute>
>>>>>>>>>> </xsl:if>
>>>>>>>>>> </fo:external-graphic>
>>>>>>>>>> </fo:block>
>>>>>>>>>> </xsl:template>
>>>>>>>>>>
>>>>>>>>>> Our generated fo looks like this:
>>>>>>>>>> <fo:table-cell>
>>>>>>>>>> <fo:block>
>>>>>>>>>> <fo:external-graphic border-collapse="separate" border="0.5pt
>>>>>>>>>> solid
>>>>>>>>>> black" content-width="scale-to-fit" content-height="scale-to-fit"
>>>>>>>>>> width="2.5in" height="2.5in" src="ref_10_1002108221" />
>>>>>>>>>> </fo:block>
>>>>>>>>>> </fo:table-cell>
>>>>>>>>>>
>>>>>>>>>> And the generated pdfs include the image and are shipped to the
>>>>>>>>>> printer.
>>>>>>>>>>
>>>>>>>>>> How does this stack up with what you have?
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> On 06/09/2011 01:19 PM, Oscar.Flores wrote:
>>>>>>>>>>
>>>>>>>>>>> Hi there well i still got the problem but searching IN INTERNET i
>>>>>>>>>>> find
>>>>>>>>>>> a
>>>>>>>>>>> JPEG
>>>>>>>>>>> renderer output for FOP its here
>>>>>>>>>>>
>>>>>>>>>>> http://marc.info/?l=fop-user&m=125986752706366&w=2
>>>>>>>>>>>
>>>>>>>>>>> the cuestion is can i render the image that i want to put in the
>>>>>>>>>>> pdf,
>>>>>>>>>>> and
>>>>>>>>>>> then add to the xsl the render jpeg it will work??
>>>>>>>>>>>
>>>>>>>>>>> and here explaints how use the render when he say uses fop as
>>>>>>>>>>> normal
>>>>>>>>>>> case
>>>>>>>>>>> what does it mean
>>>>>>>>>>> what else have to add to the code?? i hope you can help me
>>>>>>>>>>>
>>>>>>>>>>> Thanks!!
>>>>>>>>>>>
>>>>>>>>>>> // OutputStream out = what you want
>>>>>>>>>>>                  FopFactory fopFactory = FopFactory.newInstance();
>>>>>>>>>>>                  RendererFactory rendererFactory = null;
>>>>>>>>>>>                  FOUserAgent foUserAgent = null;
>>>>>>>>>>>
>>>>>>>>>>>                  rendererFactory =
>>>>>>>>>>> fopFactory.getRendererFactory();
>>>>>>>>>>>                  rendererFactory.addRendererMaker(new
>>>>>>>>>>> MultiRendererMaker("jpeg"));
>>>>>>>>>>>                  foUserAgent = fopFactory.newFOUserAgent();
>>>>>>>>>>>                  rendererFactory.createRenderer(foUserAgent,
>>>>>>>>>>> "image/jpeg");
>>>>>>>>>>>
>>>>>>>>>>>                  Fop fop = fopFactory.newFop("image/jpeg",
>>>>>>>>>>> foUserAgent,
>>>>>>>>>>> out);
>>>>>>>>>>>
>>>>>>>>>>> //Use fop as normal case
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>
>>>>>>>>>>>> Since you're now into xmlgraphics, I think you're best bet is
>>>>>>>>>>>> here
>>>>>>>>>>>> <http://xmlgraphics.apache.org/commons/image-loader.html>
>>>>>>>>>>>>
>>>>>>>>>>>> On 06/07/2011 10:18 AM, Oscar.Flores wrote:
>>>>>>>>>>>>
>>>>>>>>>>>>> Hi ok this is for generate images that dont need to be
>>>>>>>>>>>>> decompress
>>>>>>>>>>>>> later??
>>>>>>>>>>>>> and
>>>>>>>>>>>>> the result image i put in my xsl ?? then it should work, aaa i
>>>>>>>>>>>>> change
>>>>>>>>>>>>> to
>>>>>>>>>>>>> fop
>>>>>>>>>>>>> 1.0 and xml communs 1.4 and its the same jejeje   dont find the
>>>>>>>>>>>>> image
>>>>>>>>>>>>> preload
>>>>>>>>>>>>>
>>>>>>>>>>>>> org.apache.fop.fo.flow.ExternalGraphic bind
>>>>>>>>>>>>> SEVERE: Image not available: The file format is not supported.
>>>>>>>>>>>>> No
>>>>>>>>>>>>> ImagePreloader for *.jpg or *.bmp
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>
>>>>>>>>>>>>>> ImageIO.write(bufferedImage, "JPEG", file);
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> On 06/07/2011 08:21 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> Ok i actually register the handler now what i have to do is
>>>>>>>>>>>>>>> setup
>>>>>>>>>>>>>>> this
>>>>>>>>>>>>>>> handler or not?? and how can i do that, also it seem that the
>>>>>>>>>>>>>>> bmp
>>>>>>>>>>>>>>> its
>>>>>>>>>>>>>>> not
>>>>>>>>>>>>>>> recognice also what can i do?? thanks for the help rob
>>>>>>>>>>>>>>> also i am trying to convert the images to see if it that
>>>>>>>>>>>>>>> helps
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> On 06/06/2011 02:29 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> Hi what can be the difference between execute the program
>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>> netbeans
>>>>>>>>>>>>>>>>> (where
>>>>>>>>>>>>>>>>> it works and print the images and the jar in the console)
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> Different classes being loaded by Netbeans than the console
>>>>>>>>>>>>>>>> app.
>>>>>>>>>>>>>>>> Get
>>>>>>>>>>>>>>>> Netbeans to show you the full classpath it's using in it's
>>>>>>>>>>>>>>>> "%classpath"
>>>>>>>>>>>>>>>> variable
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> also i tried the
>>>>>>>>>>>>>>>>> imageIO.getImageReadersBySuffix but i cant interpretate the
>>>>>>>>>>>>>>>>> data
>>>>>>>>>>>>>>>>> y.y,
>>>>>>>>>>>>>>>>> its
>>>>>>>>>>>>>>>>> that or always its true in the boolean variable, and how
>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>> register
>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>> handler??
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> Talk to IIORegistry, some thing like
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>>>>> CLibJPEGImageReaderSpi());
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>>>>> CLibJPEGImageWriterSpi());
>>>>>>>>>>>>>>>> Note: those are not necessarily the services you have in
>>>>>>>>>>>>>>>> your
>>>>>>>>>>>>>>>> setup.
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> Thanks
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> See the javadoc on IIORegistry. With ImageIO you may have
>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>> register
>>>>>>>>>>>>>>>>>> your handler(s). What does
>>>>>>>>>>>>>>>>>> ImageIO.getImageReadersBySuffix()
>>>>>>>>>>>>>>>>>> give
>>>>>>>>>>>>>>>>>> you.
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> For certain jpegs we don't use ImageIO, rather the classes
>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>> com.sun.image.codec.jpeg:
>>>>>>>>>>>>>>>>>>                  try {
>>>>>>>>>>>>>>>>>>                      FileOutputStream fos = new
>>>>>>>>>>>>>>>>>> FileOutputStream(file);
>>>>>>>>>>>>>>>>>>                      JPEGImageEncoder encoder =
>>>>>>>>>>>>>>>>>> JPEGCodec.createJPEGEncoder(fos);
>>>>>>>>>>>>>>>>>>                      JPEGEncodeParam param =
>>>>>>>>>>>>>>>>>> encoder.getDefaultJPEGEncodeParam(image.getRaster(),
>>>>>>>>>>>>>>>>>> JPEGDecodeParam.COLOR_ID_CMYK);
>>>>>>>>>>>>>>>>>>                      param.setQuality(1, false);
>>>>>>>>>>>>>>>>>>                      encoder.encode(image.getRaster(),
>>>>>>>>>>>>>>>>>> param);
>>>>>>>>>>>>>>>>>>                      fos.close();
>>>>>>>>>>>>>>>>>>                  } catch (Throwable t) {
>>>>>>>>>>>>>>>>>>                      logger.debug(t.getMessage());
>>>>>>>>>>>>>>>>>>                  }
>>>>>>>>>>>>>>>>>> But generally we use ImageIO
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> On 06/06/2011 08:29 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> Yeah i think i need your help again i tried tu run the
>>>>>>>>>>>>>>>>>>> .jar
>>>>>>>>>>>>>>>>>>> file
>>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>> console it work but without images this it what appears
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> GRAVE: Error while processing image: I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException:
>>>>>>>>>>>>>>>>>>> Cannot
>>>>>>>>>>>>>>>>>>> load
>>>>>>>>>>>>>>>>>>> image
>>>>>>>>>>>>>>>>>>> (no
>>>>>>>>>>>>>>>>>>> suitable loader/converter combination available) for
>>>>>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> i tried  download the jai-imagio add to the class path
>>>>>>>>>>>>>>>>>>> but
>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>> dont
>>>>>>>>>>>>>>>>>>> work
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> Very odd.  I'm having no problems getting images into
>>>>>>>>>>>>>>>>>>>> pdfs
>>>>>>>>>>>>>>>>>>>> using
>>>>>>>>>>>>>>>>>>>> fop-1.0.
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> On 06/03/2011 11:04 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> aaa hey thanks for the help the other day, i resolve
>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>> problem
>>>>>>>>>>>>>>>>>>>>> changing
>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>> version of FOP for the 0.95beta instead of the 1.0, it
>>>>>>>>>>>>>>>>>>>>> works
>>>>>>>>>>>>>>>>>>>>> now
>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>> prints
>>>>>>>>>>>>>>>>>>>>> the image and its good, thanks and we are in touch if
>>>>>>>>>>>>>>>>>>>>> anything
>>>>>>>>>>>>>>>>>>>>> else
>>>>>>>>>>>>>>>>>>>>> fails
>>>>>>>>>>>>>>>>>>>>> jejeje
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> Nothing in the log from the transformer?
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> On 06/03/2011 09:47 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>> hi there i have another problem i hope you can help
>>>>>>>>>>>>>>>>>>>>>>> me
>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>> create
>>>>>>>>>>>>>>>>>>>>>>> with foe has no image, it dont show any of them, the
>>>>>>>>>>>>>>>>>>>>>>> xsl
>>>>>>>>>>>>>>>>>>>>>>> seems
>>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>>> be
>>>>>>>>>>>>>>>>>>>>>>> rigth i
>>>>>>>>>>>>>>>>>>>>>>> tested with EditX and the pdf show me the image, what
>>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>>> be,
>>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>>> xmlgraphics-commons-1.5svn, fop 1.0, fop-pdf-images
>>>>>>>>>>>>>>>>>>>>>>> 2.0.1
>>>>>>>>>>>>>>>>>>>>>>> Snapshot
>>>>>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>>> render of the image but it don work please help!!!
>>>>>>>>>>>>>>>>>>>>>>> :,(
>>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> :-):confused::confused::confused::confused:=)
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>> ---------------------------------------------------------------------
>>>>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>> For additional commands, e-mail:
>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>> http://old.nabble.com/file/p31822059/libraries.jpeg
>>>>>>> http://old.nabble.com/file/p31822059/libraries.bmp libraries.bmp
>>>>>>>
>>>>>> ---------------------------------------------------------------------
>>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>>>>
>>>>>>
>>>>>>
>>>> ---------------------------------------------------------------------
>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>>
>>>>
>>>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>
>>
>>

---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Problems with FOP and image

Posted by "Oscar.Flores" <fa...@hotmail.com>.
ok well i put the xml in scr of my proyect i see that i still have the same
issues of the image render of any image i dont now if the xml its in place i
put the code down to see if something its missing

15:45:07,827 ERROR [render] Error while processing image:
c:\cfd\nombregp.bmp (i
mage/bmp)
org.apache.xmlgraphics.image.loader.ImageException: Cannot load image (no
suitab
le loader/converter combination available) for c:\cfd\nombregp.bmp
(image/bmp)
        at
org.apache.xmlgraphics.image.loader.ImageManager.getImage(ImageManage



import mx.bigdata.sat.cfd.schema.Comprobante;
import mx.bigdata.sat.cfd.CFDv2;
import mx.bigdata.sat.security.KeyLoader;
import org.jdom.*;
import org.jdom.input.SAXBuilder;
import org.jdom.output.XMLOutputter;
import org.jdom.output.Format;
import org.jdom.transform.JDOMSource;
//Java
 import java.io.File;
 import java.io.OutputStream;

 //JAXP
 import javax.xml.transform.Transformer;
 import javax.xml.transform.TransformerFactory;
 import javax.xml.transform.Source;
 import javax.xml.transform.Result;
 import javax.xml.transform.stream.StreamSource;
 import javax.xml.transform.sax.SAXResult;
 
 //FOP
 import org.apache.fop.apps.FOUserAgent;
 import org.apache.fop.apps.Fop;
 import org.apache.fop.apps.FopFactory;
 import org.apache.fop.apps.MimeConstants;
 
 //log4j
 import org.apache.log4j.*;
 import org.apache.log4j.xml.DOMConfigurator;

public final class Main {
    @SuppressWarnings("unchecked")
    static Logger logger = Logger.getLogger(Main.class);

    public static void main(String[] args) throws Exception {
         DOMConfigurator.configure("D:/Mis
documentos/NetBeansProjects/Factura/src/factura/log4j.xml");
         logger.info("Entering application.");
         try {
            File file = new File(args[0]);
            Comprobante comp = CFDv2.newComprobante(new
FileInputStream(file));
            CFDv2 cfd = new CFDv2(comp);
            PrivateKey key = KeyLoader.loadPKCS8PrivateKey(new
FileInputStream(args[1]),(args[2]));
            X509Certificate cert = KeyLoader.loadX509Certificate(new
FileInputStream(args[3]));
            Comprobante sellado = cfd.sellarComprobante(key, cert);
            String cadena = cfd.getCadenaOriginal(); 
            String sello = sellado.getSello();
            // Creamos el builder basado en SAX
            SAXBuilder builder = new SAXBuilder();
            // Construimos el arbol DOM a partir del fichero xml
            Document documentJDOM = builder.build(new
FileInputStream(args[0]));

            
            Element raiz = documentJDOM.getRootElement();//toma el nodo raiz
del documento.
            raiz.setAttribute("sello", sello);
            raiz.setAttribute("certificado", sellado.getCertificado());
            //System.out.println(raiz.getAttributeValue("sello"));
            //System.out.println(raiz.getAttributeValue("certificado"));
            // Recorremos los hijos de la etiqueta raíz
            List<Element> hijosRaiz = raiz.getChildren();
            boolean Bandera=false;
            for(Element hijo: hijosRaiz)
            {
                // Obtenemos el nombre y su contenido de tipo texto
                String nombre = hijo.getName();

                if (nombre.equals("Addenda"))
                {   List<Element> subHijo = hijo.getChildren();
                    for(Element hij: subHijo)
                        {
                        hij.setAttribute("CadenaOriginal", cadena);
                        //System.out.println("CadenaOriginal:
"+hij.getAttributeValue("CadenaOriginal"));
                        Bandera=true;
                        break;
                        }
                }
                if (Bandera) 
                {
                    XMLOutputter out = new
XMLOutputter(Format.getPrettyFormat());
                    File nuevoXML = new File(args[0]);
                    try{
                        FileOutputStream archivoXML= new FileOutputStream
(nuevoXML);
                        out.output(documentJDOM, archivoXML);

                       }
                    catch (Exception
ex){System.out.println(ex.getMessage());}
                    // Para generar el pdf a partir de un archivo.xsl y un
                    // archivo.xml
                }
              }
          // configure fopFactory as desired
          FopFactory fopFactory = FopFactory.newInstance();
          FOUserAgent foUserAgent = fopFactory.newFOUserAgent();
        
          // configure foUserAgent as desired
          // Setup output
         File pdffile = new File(args[5]);

         OutputStream out = new java.io.FileOutputStream(pdffile);
         out = new java.io.BufferedOutputStream(out);
         try {
                // Construct fop with desired output format
                 Fop fop = fopFactory.newFop(MimeConstants.MIME_PDF,
foUserAgent, out);
                // Setup XSLT
                TransformerFactory factory =
TransformerFactory.newInstance();
                Transformer transformer = factory.newTransformer(new
StreamSource(args[4]));
                // Set the value of a  in the stylesheet
                transformer.setParameter("versionParam", "2.0");

               // Setup input for XSLT transformation
                Source src = new JDOMSource(documentJDOM);
                 // Resulting SAX events (the generated FO) must be piped
through to FOP
                Result res = new SAXResult(fop.getDefaultHandler());
                 // Start XSLT transformation and FOP processing
               // System.setProperty("java.awt.headless", "true");
                    transformer.transform(src, res);
                } finally {
                 out.close();
            }


          System.out.println("Success!");
         } catch (Exception e) {
          e.printStackTrace(System.err);
          System.exit(-1);
       }
     logger.info("Exiting application.");
  
  }


Rob Sargent-4 wrote:
> 
> Try this log4j.xml: Place it at the root of your jar file
> 
> <?xml version="1.0" encoding="UTF-8"?>
> <!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">
> 
> <log4j:configuration xmlns:log4j="http://jakarta.apache.org/log4j/" 
> debug="false">
> 
> <appender name="CONSOLE" class="org.apache.log4j.ConsoleAppender">
> 
> 
> 
> <layout class="org.apache.log4j.PatternLayout">
> 
> </layout>
> </appender>
> 
> <category name="org">
> <priority value="DEBUG"/>
> </category>
> <category name="org.apache">
> <priority value="WARN"/>
> </category>
> <category name="org.springframework">
> <priority value="WARN"/>
> </category>
> <category name="org.hibernate">
> <priority value="DEBUG"/>
> </category>
> <category name="net">
> <priority value="ERROR"/>
> </category>
> <category name="javax">
> <priority value="ERROR"/>
> </category>
> <category name="java">
> <priority value="ERROR"/>
> </category>
> <category name="sun">
> <priority value="ERROR"/>
> </category>
> <category name="org.jboss">
> <priority value="INFO"/>
> </category>
> <category name="org.jboss.seam">
> <priority value="ERROR"/>
> </category>
> <root>
> <appender-ref ref="CONSOLE"/>
> </root>
> 
> </log4j:configuration>
> 
> 
> On 06/13/2011 11:06 AM, Oscar.Flores wrote:
>> ok i dont thik i have a configuracion file i find the code that i put in
>> the
>> other post i think its the basic
>>
>>
>> Rob Sargent-4 wrote:
>>> Do you have a config file for log4j.  Usually it's in a resource tree.
>>> Are you copying that to your deployment? Is your ant script including
>>> the config file in the jar of your application?
>>>
>>> On 06/13/2011 10:12 AM, Oscar.Flores wrote:
>>>> Ok yeah the log4j its having isuees to find the configuration
>>>>
>>>> log4j:WARN No appenders could be found for logger
>>>> (org.apache.fop.util.ContentHandlerFactoryRegistry).
>>>> log4j:WARN Please initialize the log4j system properly.
>>>> log4j:WARN See http://logging.apache.org/log4j/1.2/faq.html#noconfig
>>>> for
>>>> more info.
>>>> i go to the faq guide and it say try loading the class or resource
>>>> yourself.
>>>> If you can't find it, neither will log4j.
>>>>
>>>> aaa i dont know where to set this
>>>>
>>>> also here its my xlst
>>>>
>>>>
>>>> http://old.nabble.com/file/p31835645/FacturasOMF.xsl FacturasOMF.xsl
>>>>
>>>>
>>>> and the fo file that generate the editix
>>>>
>>>> http://old.nabble.com/file/p31835645/Prueba.fo Prueba.fo
>>>>
>>>>
>>>> Rob Sargent-4 wrote:
>>>>> The first thing is to really dig into what you did to netbeans to get
>>>>> it
>>>>> to work...
>>>>>
>>>>> I've forgotten what your stylesheet looked like, so maybe if you show
>>>>> us
>>>>> again how you're referencing your images we might notice a problem.
>>>>>
>>>>> It might also help to see the "fo" generated during your
>>>>> transformation.
>>>>> Can you grab that just after xslt and just before fop calls.
>>>>>
>>>>> Are you sure there is no error being logged somewhere when you run
>>>>> from
>>>>> the command line? (Where is log4j writing and at what level?)
>>>>>
>>>>>
>>>>>
>>>>> Oscar.Flores wrote:
>>>>>> You where absolutly rigth i miss a few libraries to add into the jar
>>>>>> file, i
>>>>>> modified the build.xml to add the package and jar that i need, now
>>>>>> the
>>>>>> error
>>>>>> message is not there but still the images dont show in the pdf i
>>>>>> remeber
>>>>>> that i do something in netbeans so they can add to the pdf but i cant
>>>>>> remeber i dont now if there is still a library that is missing or i
>>>>>> am
>>>>>> adding more than it should be
>>>>>> This is what i use :
>>>>>> cfdi-base-0.1.6-SNAPSHOT.jar
>>>>>> guava-r09.jar
>>>>>> guava-r09-gwt.jar
>>>>>> jaxb-impl-2.1.10.jar
>>>>>> avalon-framework-api-4.3.jar
>>>>>> avalon-framework-cvs-20020806.jar
>>>>>> avalon-logkit-2.1.jar
>>>>>> not-yet-commons-ssl-0.3.11.jar
>>>>>> commons-codec-1.5.jar
>>>>>> commons-codec-1.5-sources.jar
>>>>>> log4j-1.2.16.jar
>>>>>> fop.jar
>>>>>> jdom.jar
>>>>>> xmlgraphics-commons-1.4.jar
>>>>>> commons-io-1.3.1.jar
>>>>>> fop-pdf-images-2.0.1.SNAPSHOT.jar
>>>>>> pdfbox-app-1.5.0.jar
>>>>>> fontbox-1.3.1.jar
>>>>>> jempbox-1.3.1.jar
>>>>>> xercesImpl-2.7.1.jar
>>>>>> batik-all-1.7.jar
>>>>>> xml-apis-1.3.04.jar
>>>>>> xml-apis-ext-1.3.04.jar
>>>>>>    avalon-framework-4.2.0.jar
>>>>>>    xalan-2.7.0.jar
>>>>>>    serializer-2.7.0.jar
>>>>>>    commons-logging-1.0.4.jar
>>>>>>    jai_codec.jar
>>>>>>    jai_core.jar
>>>>>>    batik-ext.jar
>>>>>>    jai_imageio-1.1-sources.jar
>>>>>>
>>>>>> Thanks Rob for the help
>>>>>>
>>>>>>
>>>>>> Rob Sargent-4 wrote:
>>>>>>
>>>>>>> I suspect running from your jar does not have/use the same classpath
>>>>>>> that is in effect while you're in the debugger.
>>>>>>> By what mechanism do you generate the jar?
>>>>>>> Is it an executable jar or are you running java -classpath
>>>>>>> <your-jar-here:other-jars>   Main?
>>>>>>> Make your IDE (netbeans) display the classpath  it uses to run your
>>>>>>> app
>>>>>>> and compare that with the above.
>>>>>>>
>>>>>>> On 06/09/2011 07:21 PM, Oscar.Flores wrote:
>>>>>>>
>>>>>>>> aaa ok well my problem is that when i do the pdf in netbean the pdf
>>>>>>>> is
>>>>>>>> fine
>>>>>>>> with images and evething but when i run the jar file in command it
>>>>>>>> give
>>>>>>>> me a
>>>>>>>> error
>>>>>>>>
>>>>>>>> GRAVE: Error while processing image: I:\cfd\rfc.jpg (image/jpeg)
>>>>>>>>     org.apache.xmlgraphics.image.loader.ImageException: Cannot load
>>>>>>>>     image (no suitable loader/converter combination available) for
>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>     (image/jpeg)
>>>>>>>>
>>>>>>>> so i dont no what its not working and if i have to add something to
>>>>>>>> my
>>>>>>>> code
>>>>>>>> so the images can load i am soooo desperate what i am doing wrong??
>>>>>>>> i am sorry for the trouble and if a dont explain my self very good
>>>>>>>> jejeje
>>>>>>>>
>>>>>>>>
>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>
>>>>>>>>> Not at all sure what your problem is.  All I can do is show you
>>>>>>>>> what
>>>>>>>>> works for us.
>>>>>>>>>
>>>>>>>>> Our source xml looks like this:
>>>>>>>>> <image image-id="381623861" reference-id="ref-220" width="750"
>>>>>>>>> height="750" image-space-id="space-1" position="5"
>>>>>>>>>                  image-pool-position="31" pos="4"
>>>>>>>>>                  file="ref_10_1002108221">    <!-- an actual file
>>>>>>>>> (.jpeg
>>>>>>>>> copied the working directory of the transformer -->
>>>>>>>>> <fields />
>>>>>>>>> <caption />
>>>>>>>>> <annotations>
>>>>>>>>> <arrow_positions origHeight="750" origWidth="750" />
>>>>>>>>> </annotations>
>>>>>>>>> </image>
>>>>>>>>>
>>>>>>>>> Our xslt looks like this for each image needed.
>>>>>>>>>
>>>>>>>>> <xsl:template name="image">
>>>>>>>>> <xsl:param name="img"/>    <!-- This is the xml node from the
>>>>>>>>> source
>>>>>>>>> xml
>>>>>>>>> above -->
>>>>>>>>> <xsl:param name="width"/>
>>>>>>>>> <xsl:param name="height" select="$width"/>
>>>>>>>>> <xsl:param name="ignoreHeight">false</xsl:param>
>>>>>>>>> <fo:block>
>>>>>>>>> <fo:external-graphic src="{$img/@file}" height="{$height}"
>>>>>>>>> width="{$width}" content-height="scale-to-fit"
>>>>>>>>>                                      content-width="scale-to-fit"
>>>>>>>>> border="0.5pt solid black" border-collapse="separate">
>>>>>>>>> <xsl:if test="$ignoreHeight != 'true'">
>>>>>>>>> <xsl:attribute name="height">
>>>>>>>>> <xsl:value-of select="$height"/>
>>>>>>>>> </xsl:attribute>
>>>>>>>>> </xsl:if>
>>>>>>>>> </fo:external-graphic>
>>>>>>>>> </fo:block>
>>>>>>>>> </xsl:template>
>>>>>>>>>
>>>>>>>>> Our generated fo looks like this:
>>>>>>>>> <fo:table-cell>
>>>>>>>>> <fo:block>
>>>>>>>>> <fo:external-graphic border-collapse="separate" border="0.5pt
>>>>>>>>> solid
>>>>>>>>> black" content-width="scale-to-fit" content-height="scale-to-fit"
>>>>>>>>> width="2.5in" height="2.5in" src="ref_10_1002108221" />
>>>>>>>>> </fo:block>
>>>>>>>>> </fo:table-cell>
>>>>>>>>>
>>>>>>>>> And the generated pdfs include the image and are shipped to the
>>>>>>>>> printer.
>>>>>>>>>
>>>>>>>>> How does this stack up with what you have?
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> On 06/09/2011 01:19 PM, Oscar.Flores wrote:
>>>>>>>>>
>>>>>>>>>> Hi there well i still got the problem but searching IN INTERNET i
>>>>>>>>>> find
>>>>>>>>>> a
>>>>>>>>>> JPEG
>>>>>>>>>> renderer output for FOP its here
>>>>>>>>>>
>>>>>>>>>> http://marc.info/?l=fop-user&m=125986752706366&w=2
>>>>>>>>>>
>>>>>>>>>> the cuestion is can i render the image that i want to put in the
>>>>>>>>>> pdf,
>>>>>>>>>> and
>>>>>>>>>> then add to the xsl the render jpeg it will work??
>>>>>>>>>>
>>>>>>>>>> and here explaints how use the render when he say uses fop as
>>>>>>>>>> normal
>>>>>>>>>> case
>>>>>>>>>> what does it mean
>>>>>>>>>> what else have to add to the code?? i hope you can help me
>>>>>>>>>>
>>>>>>>>>> Thanks!!
>>>>>>>>>>
>>>>>>>>>> // OutputStream out = what you want
>>>>>>>>>>                 FopFactory fopFactory = FopFactory.newInstance();
>>>>>>>>>>                 RendererFactory rendererFactory = null;
>>>>>>>>>>                 FOUserAgent foUserAgent = null;
>>>>>>>>>>
>>>>>>>>>>                 rendererFactory =
>>>>>>>>>> fopFactory.getRendererFactory();
>>>>>>>>>>                 rendererFactory.addRendererMaker(new
>>>>>>>>>> MultiRendererMaker("jpeg"));
>>>>>>>>>>                 foUserAgent = fopFactory.newFOUserAgent();
>>>>>>>>>>                 rendererFactory.createRenderer(foUserAgent,
>>>>>>>>>> "image/jpeg");
>>>>>>>>>>
>>>>>>>>>>                 Fop fop = fopFactory.newFop("image/jpeg",
>>>>>>>>>> foUserAgent,
>>>>>>>>>> out);
>>>>>>>>>>
>>>>>>>>>> //Use fop as normal case
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>
>>>>>>>>>>> Since you're now into xmlgraphics, I think you're best bet is
>>>>>>>>>>> here
>>>>>>>>>>> <http://xmlgraphics.apache.org/commons/image-loader.html>
>>>>>>>>>>>
>>>>>>>>>>> On 06/07/2011 10:18 AM, Oscar.Flores wrote:
>>>>>>>>>>>
>>>>>>>>>>>> Hi ok this is for generate images that dont need to be
>>>>>>>>>>>> decompress
>>>>>>>>>>>> later??
>>>>>>>>>>>> and
>>>>>>>>>>>> the result image i put in my xsl ?? then it should work, aaa i
>>>>>>>>>>>> change
>>>>>>>>>>>> to
>>>>>>>>>>>> fop
>>>>>>>>>>>> 1.0 and xml communs 1.4 and its the same jejeje   dont find the
>>>>>>>>>>>> image
>>>>>>>>>>>> preload
>>>>>>>>>>>>
>>>>>>>>>>>> org.apache.fop.fo.flow.ExternalGraphic bind
>>>>>>>>>>>> SEVERE: Image not available: The file format is not supported.
>>>>>>>>>>>> No
>>>>>>>>>>>> ImagePreloader for *.jpg or *.bmp
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>
>>>>>>>>>>>>> ImageIO.write(bufferedImage, "JPEG", file);
>>>>>>>>>>>>>
>>>>>>>>>>>>> On 06/07/2011 08:21 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>
>>>>>>>>>>>>>> Ok i actually register the handler now what i have to do is
>>>>>>>>>>>>>> setup
>>>>>>>>>>>>>> this
>>>>>>>>>>>>>> handler or not?? and how can i do that, also it seem that the
>>>>>>>>>>>>>> bmp
>>>>>>>>>>>>>> its
>>>>>>>>>>>>>> not
>>>>>>>>>>>>>> recognice also what can i do?? thanks for the help rob
>>>>>>>>>>>>>> also i am trying to convert the images to see if it that
>>>>>>>>>>>>>> helps
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> On 06/06/2011 02:29 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> Hi what can be the difference between execute the program
>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>> netbeans
>>>>>>>>>>>>>>>> (where
>>>>>>>>>>>>>>>> it works and print the images and the jar in the console)
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> Different classes being loaded by Netbeans than the console
>>>>>>>>>>>>>>> app.
>>>>>>>>>>>>>>> Get
>>>>>>>>>>>>>>> Netbeans to show you the full classpath it's using in it's
>>>>>>>>>>>>>>> "%classpath"
>>>>>>>>>>>>>>> variable
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> also i tried the
>>>>>>>>>>>>>>>> imageIO.getImageReadersBySuffix but i cant interpretate the
>>>>>>>>>>>>>>>> data
>>>>>>>>>>>>>>>> y.y,
>>>>>>>>>>>>>>>> its
>>>>>>>>>>>>>>>> that or always its true in the boolean variable, and how
>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>> register
>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>> handler??
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> Talk to IIORegistry, some thing like
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>>>> CLibJPEGImageReaderSpi());
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>>>> CLibJPEGImageWriterSpi());
>>>>>>>>>>>>>>> Note: those are not necessarily the services you have in
>>>>>>>>>>>>>>> your
>>>>>>>>>>>>>>> setup.
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> Thanks
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> See the javadoc on IIORegistry. With ImageIO you may have
>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>> register
>>>>>>>>>>>>>>>>> your handler(s). What does
>>>>>>>>>>>>>>>>> ImageIO.getImageReadersBySuffix()
>>>>>>>>>>>>>>>>> give
>>>>>>>>>>>>>>>>> you.
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> For certain jpegs we don't use ImageIO, rather the classes
>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>> com.sun.image.codec.jpeg:
>>>>>>>>>>>>>>>>>                 try {
>>>>>>>>>>>>>>>>>                     FileOutputStream fos = new
>>>>>>>>>>>>>>>>> FileOutputStream(file);
>>>>>>>>>>>>>>>>>                     JPEGImageEncoder encoder =
>>>>>>>>>>>>>>>>> JPEGCodec.createJPEGEncoder(fos);
>>>>>>>>>>>>>>>>>                     JPEGEncodeParam param =
>>>>>>>>>>>>>>>>> encoder.getDefaultJPEGEncodeParam(image.getRaster(),
>>>>>>>>>>>>>>>>> JPEGDecodeParam.COLOR_ID_CMYK);
>>>>>>>>>>>>>>>>>                     param.setQuality(1, false);
>>>>>>>>>>>>>>>>>                     encoder.encode(image.getRaster(),
>>>>>>>>>>>>>>>>> param);
>>>>>>>>>>>>>>>>>                     fos.close();
>>>>>>>>>>>>>>>>>                 } catch (Throwable t) {
>>>>>>>>>>>>>>>>>                     logger.debug(t.getMessage());
>>>>>>>>>>>>>>>>>                 }
>>>>>>>>>>>>>>>>> But generally we use ImageIO
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> On 06/06/2011 08:29 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> Yeah i think i need your help again i tried tu run the
>>>>>>>>>>>>>>>>>> .jar
>>>>>>>>>>>>>>>>>> file
>>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>> console it work but without images this it what appears
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> GRAVE: Error while processing image: I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException:
>>>>>>>>>>>>>>>>>> Cannot
>>>>>>>>>>>>>>>>>> load
>>>>>>>>>>>>>>>>>> image
>>>>>>>>>>>>>>>>>> (no
>>>>>>>>>>>>>>>>>> suitable loader/converter combination available) for
>>>>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> i tried  download the jai-imagio add to the class path
>>>>>>>>>>>>>>>>>> but
>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>> dont
>>>>>>>>>>>>>>>>>> work
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> Very odd.  I'm having no problems getting images into
>>>>>>>>>>>>>>>>>>> pdfs
>>>>>>>>>>>>>>>>>>> using
>>>>>>>>>>>>>>>>>>> fop-1.0.
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> On 06/03/2011 11:04 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> aaa hey thanks for the help the other day, i resolve
>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>> problem
>>>>>>>>>>>>>>>>>>>> changing
>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>> version of FOP for the 0.95beta instead of the 1.0, it
>>>>>>>>>>>>>>>>>>>> works
>>>>>>>>>>>>>>>>>>>> now
>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>> prints
>>>>>>>>>>>>>>>>>>>> the image and its good, thanks and we are in touch if
>>>>>>>>>>>>>>>>>>>> anything
>>>>>>>>>>>>>>>>>>>> else
>>>>>>>>>>>>>>>>>>>> fails
>>>>>>>>>>>>>>>>>>>> jejeje
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> Nothing in the log from the transformer?
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> On 06/03/2011 09:47 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>> hi there i have another problem i hope you can help
>>>>>>>>>>>>>>>>>>>>>> me
>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>> create
>>>>>>>>>>>>>>>>>>>>>> with foe has no image, it dont show any of them, the
>>>>>>>>>>>>>>>>>>>>>> xsl
>>>>>>>>>>>>>>>>>>>>>> seems
>>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>>> be
>>>>>>>>>>>>>>>>>>>>>> rigth i
>>>>>>>>>>>>>>>>>>>>>> tested with EditX and the pdf show me the image, what
>>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>>> be,
>>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>>> xmlgraphics-commons-1.5svn, fop 1.0, fop-pdf-images
>>>>>>>>>>>>>>>>>>>>>> 2.0.1
>>>>>>>>>>>>>>>>>>>>>> Snapshot
>>>>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>>> render of the image but it don work please help!!! 
>>>>>>>>>>>>>>>>>>>>>> :,(
>>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>> :-):confused::confused::confused::confused:=)
>>>>>>>>>>>>>>
>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>> For additional commands, e-mail:
>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>> ---------------------------------------------------------------------
>>>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>> For additional commands, e-mail:
>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>> http://old.nabble.com/file/p31822059/libraries.jpeg
>>>>>> http://old.nabble.com/file/p31822059/libraries.bmp libraries.bmp
>>>>>>
>>>>> ---------------------------------------------------------------------
>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>>>
>>>>>
>>>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>
>>>
>>>
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
> 
> 
> 

-- 
View this message in context: http://old.nabble.com/Problems-with-FOP-and-image-tp31766430p31837872.html
Sent from the FOP - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Problems with FOP and image

Posted by Rob Sargent <rs...@xmission.com>.
Try this log4j.xml: Place it at the root of your jar file

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">

<log4j:configuration xmlns:log4j="http://jakarta.apache.org/log4j/" 
debug="false">

<appender name="CONSOLE" class="org.apache.log4j.ConsoleAppender">
<param name="Target" value="System.out"/>
<param name="Threshold" value="DEBUG"/>

<layout class="org.apache.log4j.PatternLayout">
<param name="ConversionPattern" value="%d{ABSOLUTE} %-5p [%c{1}] %m%n"/>
</layout>
</appender>

<category name="org">
<priority value="DEBUG"/>
</category>
<category name="org.apache">
<priority value="WARN"/>
</category>
<category name="org.springframework">
<priority value="WARN"/>
</category>
<category name="org.hibernate">
<priority value="DEBUG"/>
</category>
<category name="net">
<priority value="ERROR"/>
</category>
<category name="javax">
<priority value="ERROR"/>
</category>
<category name="java">
<priority value="ERROR"/>
</category>
<category name="sun">
<priority value="ERROR"/>
</category>
<category name="org.jboss">
<priority value="INFO"/>
</category>
<category name="org.jboss.seam">
<priority value="ERROR"/>
</category>
<root>
<appender-ref ref="CONSOLE"/>
</root>

</log4j:configuration>


On 06/13/2011 11:06 AM, Oscar.Flores wrote:
> ok i dont thik i have a configuracion file i find the code that i put in the
> other post i think its the basic
>
>
> Rob Sargent-4 wrote:
>> Do you have a config file for log4j.  Usually it's in a resource tree.
>> Are you copying that to your deployment? Is your ant script including
>> the config file in the jar of your application?
>>
>> On 06/13/2011 10:12 AM, Oscar.Flores wrote:
>>> Ok yeah the log4j its having isuees to find the configuration
>>>
>>> log4j:WARN No appenders could be found for logger
>>> (org.apache.fop.util.ContentHandlerFactoryRegistry).
>>> log4j:WARN Please initialize the log4j system properly.
>>> log4j:WARN See http://logging.apache.org/log4j/1.2/faq.html#noconfig for
>>> more info.
>>> i go to the faq guide and it say try loading the class or resource
>>> yourself.
>>> If you can't find it, neither will log4j.
>>>
>>> aaa i dont know where to set this
>>>
>>> also here its my xlst
>>>
>>>
>>> http://old.nabble.com/file/p31835645/FacturasOMF.xsl FacturasOMF.xsl
>>>
>>>
>>> and the fo file that generate the editix
>>>
>>> http://old.nabble.com/file/p31835645/Prueba.fo Prueba.fo
>>>
>>>
>>> Rob Sargent-4 wrote:
>>>> The first thing is to really dig into what you did to netbeans to get it
>>>> to work...
>>>>
>>>> I've forgotten what your stylesheet looked like, so maybe if you show us
>>>> again how you're referencing your images we might notice a problem.
>>>>
>>>> It might also help to see the "fo" generated during your transformation.
>>>> Can you grab that just after xslt and just before fop calls.
>>>>
>>>> Are you sure there is no error being logged somewhere when you run from
>>>> the command line? (Where is log4j writing and at what level?)
>>>>
>>>>
>>>>
>>>> Oscar.Flores wrote:
>>>>> You where absolutly rigth i miss a few libraries to add into the jar
>>>>> file, i
>>>>> modified the build.xml to add the package and jar that i need, now the
>>>>> error
>>>>> message is not there but still the images dont show in the pdf i
>>>>> remeber
>>>>> that i do something in netbeans so they can add to the pdf but i cant
>>>>> remeber i dont now if there is still a library that is missing or i am
>>>>> adding more than it should be
>>>>> This is what i use :
>>>>> cfdi-base-0.1.6-SNAPSHOT.jar
>>>>> guava-r09.jar
>>>>> guava-r09-gwt.jar
>>>>> jaxb-impl-2.1.10.jar
>>>>> avalon-framework-api-4.3.jar
>>>>> avalon-framework-cvs-20020806.jar
>>>>> avalon-logkit-2.1.jar
>>>>> not-yet-commons-ssl-0.3.11.jar
>>>>> commons-codec-1.5.jar
>>>>> commons-codec-1.5-sources.jar
>>>>> log4j-1.2.16.jar
>>>>> fop.jar
>>>>> jdom.jar
>>>>> xmlgraphics-commons-1.4.jar
>>>>> commons-io-1.3.1.jar
>>>>> fop-pdf-images-2.0.1.SNAPSHOT.jar
>>>>> pdfbox-app-1.5.0.jar
>>>>> fontbox-1.3.1.jar
>>>>> jempbox-1.3.1.jar
>>>>> xercesImpl-2.7.1.jar
>>>>> batik-all-1.7.jar
>>>>> xml-apis-1.3.04.jar
>>>>> xml-apis-ext-1.3.04.jar
>>>>>    avalon-framework-4.2.0.jar
>>>>>    xalan-2.7.0.jar
>>>>>    serializer-2.7.0.jar
>>>>>    commons-logging-1.0.4.jar
>>>>>    jai_codec.jar
>>>>>    jai_core.jar
>>>>>    batik-ext.jar
>>>>>    jai_imageio-1.1-sources.jar
>>>>>
>>>>> Thanks Rob for the help
>>>>>
>>>>>
>>>>> Rob Sargent-4 wrote:
>>>>>
>>>>>> I suspect running from your jar does not have/use the same classpath
>>>>>> that is in effect while you're in the debugger.
>>>>>> By what mechanism do you generate the jar?
>>>>>> Is it an executable jar or are you running java -classpath
>>>>>> <your-jar-here:other-jars>   Main?
>>>>>> Make your IDE (netbeans) display the classpath  it uses to run your
>>>>>> app
>>>>>> and compare that with the above.
>>>>>>
>>>>>> On 06/09/2011 07:21 PM, Oscar.Flores wrote:
>>>>>>
>>>>>>> aaa ok well my problem is that when i do the pdf in netbean the pdf
>>>>>>> is
>>>>>>> fine
>>>>>>> with images and evething but when i run the jar file in command it
>>>>>>> give
>>>>>>> me a
>>>>>>> error
>>>>>>>
>>>>>>> GRAVE: Error while processing image: I:\cfd\rfc.jpg (image/jpeg)
>>>>>>>     org.apache.xmlgraphics.image.loader.ImageException: Cannot load
>>>>>>>     image (no suitable loader/converter combination available) for
>>>>>>> I:\cfd\rfc.jpg
>>>>>>>     (image/jpeg)
>>>>>>>
>>>>>>> so i dont no what its not working and if i have to add something to
>>>>>>> my
>>>>>>> code
>>>>>>> so the images can load i am soooo desperate what i am doing wrong??
>>>>>>> i am sorry for the trouble and if a dont explain my self very good
>>>>>>> jejeje
>>>>>>>
>>>>>>>
>>>>>>> Rob Sargent-4 wrote:
>>>>>>>
>>>>>>>> Not at all sure what your problem is.  All I can do is show you what
>>>>>>>> works for us.
>>>>>>>>
>>>>>>>> Our source xml looks like this:
>>>>>>>> <image image-id="381623861" reference-id="ref-220" width="750"
>>>>>>>> height="750" image-space-id="space-1" position="5"
>>>>>>>>                  image-pool-position="31" pos="4"
>>>>>>>>                  file="ref_10_1002108221">    <!-- an actual file
>>>>>>>> (.jpeg
>>>>>>>> copied the working directory of the transformer -->
>>>>>>>> <fields />
>>>>>>>> <caption />
>>>>>>>> <annotations>
>>>>>>>> <arrow_positions origHeight="750" origWidth="750" />
>>>>>>>> </annotations>
>>>>>>>> </image>
>>>>>>>>
>>>>>>>> Our xslt looks like this for each image needed.
>>>>>>>>
>>>>>>>> <xsl:template name="image">
>>>>>>>> <xsl:param name="img"/>    <!-- This is the xml node from the source
>>>>>>>> xml
>>>>>>>> above -->
>>>>>>>> <xsl:param name="width"/>
>>>>>>>> <xsl:param name="height" select="$width"/>
>>>>>>>> <xsl:param name="ignoreHeight">false</xsl:param>
>>>>>>>> <fo:block>
>>>>>>>> <fo:external-graphic src="{$img/@file}" height="{$height}"
>>>>>>>> width="{$width}" content-height="scale-to-fit"
>>>>>>>>                                      content-width="scale-to-fit"
>>>>>>>> border="0.5pt solid black" border-collapse="separate">
>>>>>>>> <xsl:if test="$ignoreHeight != 'true'">
>>>>>>>> <xsl:attribute name="height">
>>>>>>>> <xsl:value-of select="$height"/>
>>>>>>>> </xsl:attribute>
>>>>>>>> </xsl:if>
>>>>>>>> </fo:external-graphic>
>>>>>>>> </fo:block>
>>>>>>>> </xsl:template>
>>>>>>>>
>>>>>>>> Our generated fo looks like this:
>>>>>>>> <fo:table-cell>
>>>>>>>> <fo:block>
>>>>>>>> <fo:external-graphic border-collapse="separate" border="0.5pt solid
>>>>>>>> black" content-width="scale-to-fit" content-height="scale-to-fit"
>>>>>>>> width="2.5in" height="2.5in" src="ref_10_1002108221" />
>>>>>>>> </fo:block>
>>>>>>>> </fo:table-cell>
>>>>>>>>
>>>>>>>> And the generated pdfs include the image and are shipped to the
>>>>>>>> printer.
>>>>>>>>
>>>>>>>> How does this stack up with what you have?
>>>>>>>>
>>>>>>>>
>>>>>>>> On 06/09/2011 01:19 PM, Oscar.Flores wrote:
>>>>>>>>
>>>>>>>>> Hi there well i still got the problem but searching IN INTERNET i
>>>>>>>>> find
>>>>>>>>> a
>>>>>>>>> JPEG
>>>>>>>>> renderer output for FOP its here
>>>>>>>>>
>>>>>>>>> http://marc.info/?l=fop-user&m=125986752706366&w=2
>>>>>>>>>
>>>>>>>>> the cuestion is can i render the image that i want to put in the
>>>>>>>>> pdf,
>>>>>>>>> and
>>>>>>>>> then add to the xsl the render jpeg it will work??
>>>>>>>>>
>>>>>>>>> and here explaints how use the render when he say uses fop as
>>>>>>>>> normal
>>>>>>>>> case
>>>>>>>>> what does it mean
>>>>>>>>> what else have to add to the code?? i hope you can help me
>>>>>>>>>
>>>>>>>>> Thanks!!
>>>>>>>>>
>>>>>>>>> // OutputStream out = what you want
>>>>>>>>>                 FopFactory fopFactory = FopFactory.newInstance();
>>>>>>>>>                 RendererFactory rendererFactory = null;
>>>>>>>>>                 FOUserAgent foUserAgent = null;
>>>>>>>>>
>>>>>>>>>                 rendererFactory = fopFactory.getRendererFactory();
>>>>>>>>>                 rendererFactory.addRendererMaker(new
>>>>>>>>> MultiRendererMaker("jpeg"));
>>>>>>>>>                 foUserAgent = fopFactory.newFOUserAgent();
>>>>>>>>>                 rendererFactory.createRenderer(foUserAgent,
>>>>>>>>> "image/jpeg");
>>>>>>>>>
>>>>>>>>>                 Fop fop = fopFactory.newFop("image/jpeg",
>>>>>>>>> foUserAgent,
>>>>>>>>> out);
>>>>>>>>>
>>>>>>>>> //Use fop as normal case
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>
>>>>>>>>>> Since you're now into xmlgraphics, I think you're best bet is here
>>>>>>>>>> <http://xmlgraphics.apache.org/commons/image-loader.html>
>>>>>>>>>>
>>>>>>>>>> On 06/07/2011 10:18 AM, Oscar.Flores wrote:
>>>>>>>>>>
>>>>>>>>>>> Hi ok this is for generate images that dont need to be decompress
>>>>>>>>>>> later??
>>>>>>>>>>> and
>>>>>>>>>>> the result image i put in my xsl ?? then it should work, aaa i
>>>>>>>>>>> change
>>>>>>>>>>> to
>>>>>>>>>>> fop
>>>>>>>>>>> 1.0 and xml communs 1.4 and its the same jejeje   dont find the
>>>>>>>>>>> image
>>>>>>>>>>> preload
>>>>>>>>>>>
>>>>>>>>>>> org.apache.fop.fo.flow.ExternalGraphic bind
>>>>>>>>>>> SEVERE: Image not available: The file format is not supported. No
>>>>>>>>>>> ImagePreloader for *.jpg or *.bmp
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>
>>>>>>>>>>>> ImageIO.write(bufferedImage, "JPEG", file);
>>>>>>>>>>>>
>>>>>>>>>>>> On 06/07/2011 08:21 AM, Oscar.Flores wrote:
>>>>>>>>>>>>
>>>>>>>>>>>>> Ok i actually register the handler now what i have to do is
>>>>>>>>>>>>> setup
>>>>>>>>>>>>> this
>>>>>>>>>>>>> handler or not?? and how can i do that, also it seem that the
>>>>>>>>>>>>> bmp
>>>>>>>>>>>>> its
>>>>>>>>>>>>> not
>>>>>>>>>>>>> recognice also what can i do?? thanks for the help rob
>>>>>>>>>>>>> also i am trying to convert the images to see if it that helps
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>
>>>>>>>>>>>>>> On 06/06/2011 02:29 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> Hi what can be the difference between execute the program in
>>>>>>>>>>>>>>> netbeans
>>>>>>>>>>>>>>> (where
>>>>>>>>>>>>>>> it works and print the images and the jar in the console)
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>> Different classes being loaded by Netbeans than the console
>>>>>>>>>>>>>> app.
>>>>>>>>>>>>>> Get
>>>>>>>>>>>>>> Netbeans to show you the full classpath it's using in it's
>>>>>>>>>>>>>> "%classpath"
>>>>>>>>>>>>>> variable
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> also i tried the
>>>>>>>>>>>>>>> imageIO.getImageReadersBySuffix but i cant interpretate the
>>>>>>>>>>>>>>> data
>>>>>>>>>>>>>>> y.y,
>>>>>>>>>>>>>>> its
>>>>>>>>>>>>>>> that or always its true in the boolean variable, and how can
>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>> register
>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>> handler??
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>> Talk to IIORegistry, some thing like
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>>> CLibJPEGImageReaderSpi());
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>>> CLibJPEGImageWriterSpi());
>>>>>>>>>>>>>> Note: those are not necessarily the services you have in your
>>>>>>>>>>>>>> setup.
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> Thanks
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> See the javadoc on IIORegistry. With ImageIO you may have to
>>>>>>>>>>>>>>>> register
>>>>>>>>>>>>>>>> your handler(s). What does ImageIO.getImageReadersBySuffix()
>>>>>>>>>>>>>>>> give
>>>>>>>>>>>>>>>> you.
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> For certain jpegs we don't use ImageIO, rather the classes
>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>> com.sun.image.codec.jpeg:
>>>>>>>>>>>>>>>>                 try {
>>>>>>>>>>>>>>>>                     FileOutputStream fos = new
>>>>>>>>>>>>>>>> FileOutputStream(file);
>>>>>>>>>>>>>>>>                     JPEGImageEncoder encoder =
>>>>>>>>>>>>>>>> JPEGCodec.createJPEGEncoder(fos);
>>>>>>>>>>>>>>>>                     JPEGEncodeParam param =
>>>>>>>>>>>>>>>> encoder.getDefaultJPEGEncodeParam(image.getRaster(),
>>>>>>>>>>>>>>>> JPEGDecodeParam.COLOR_ID_CMYK);
>>>>>>>>>>>>>>>>                     param.setQuality(1, false);
>>>>>>>>>>>>>>>>                     encoder.encode(image.getRaster(), param);
>>>>>>>>>>>>>>>>                     fos.close();
>>>>>>>>>>>>>>>>                 } catch (Throwable t) {
>>>>>>>>>>>>>>>>                     logger.debug(t.getMessage());
>>>>>>>>>>>>>>>>                 }
>>>>>>>>>>>>>>>> But generally we use ImageIO
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> On 06/06/2011 08:29 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> Yeah i think i need your help again i tried tu run the .jar
>>>>>>>>>>>>>>>>> file
>>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>> console it work but without images this it what appears
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> GRAVE: Error while processing image: I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException: Cannot
>>>>>>>>>>>>>>>>> load
>>>>>>>>>>>>>>>>> image
>>>>>>>>>>>>>>>>> (no
>>>>>>>>>>>>>>>>> suitable loader/converter combination available) for
>>>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> i tried  download the jai-imagio add to the class path but
>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>> dont
>>>>>>>>>>>>>>>>> work
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> Very odd.  I'm having no problems getting images into pdfs
>>>>>>>>>>>>>>>>>> using
>>>>>>>>>>>>>>>>>> fop-1.0.
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> On 06/03/2011 11:04 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> aaa hey thanks for the help the other day, i resolve the
>>>>>>>>>>>>>>>>>>> problem
>>>>>>>>>>>>>>>>>>> changing
>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>> version of FOP for the 0.95beta instead of the 1.0, it
>>>>>>>>>>>>>>>>>>> works
>>>>>>>>>>>>>>>>>>> now
>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>> prints
>>>>>>>>>>>>>>>>>>> the image and its good, thanks and we are in touch if
>>>>>>>>>>>>>>>>>>> anything
>>>>>>>>>>>>>>>>>>> else
>>>>>>>>>>>>>>>>>>> fails
>>>>>>>>>>>>>>>>>>> jejeje
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> Nothing in the log from the transformer?
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> On 06/03/2011 09:47 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>> hi there i have another problem i hope you can help me
>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>> create
>>>>>>>>>>>>>>>>>>>>> with foe has no image, it dont show any of them, the
>>>>>>>>>>>>>>>>>>>>> xsl
>>>>>>>>>>>>>>>>>>>>> seems
>>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>>> be
>>>>>>>>>>>>>>>>>>>>> rigth i
>>>>>>>>>>>>>>>>>>>>> tested with EditX and the pdf show me the image, what
>>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>>> be,
>>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>>> xmlgraphics-commons-1.5svn, fop 1.0, fop-pdf-images
>>>>>>>>>>>>>>>>>>>>> 2.0.1
>>>>>>>>>>>>>>>>>>>>> Snapshot
>>>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>>> render of the image but it don work please help!!!  :,(
>>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>> :-):confused::confused::confused::confused:=)
>>>>>>>>>>>>>
>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>> ---------------------------------------------------------------------
>>>>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>> For additional commands, e-mail:
>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>> ---------------------------------------------------------------------
>>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>> http://old.nabble.com/file/p31822059/libraries.jpeg
>>>>> http://old.nabble.com/file/p31822059/libraries.bmp libraries.bmp
>>>>>
>>>> ---------------------------------------------------------------------
>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>>
>>>>
>>>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>
>>
>>

---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Problems with FOP and image

Posted by "Oscar.Flores" <fa...@hotmail.com>.
ok i dont thik i have a configuracion file i find the code that i put in the
other post i think its the basic 
 

Rob Sargent-4 wrote:
> 
> Do you have a config file for log4j.  Usually it's in a resource tree.  
> Are you copying that to your deployment? Is your ant script including 
> the config file in the jar of your application?
> 
> On 06/13/2011 10:12 AM, Oscar.Flores wrote:
>> Ok yeah the log4j its having isuees to find the configuration
>>
>> log4j:WARN No appenders could be found for logger
>> (org.apache.fop.util.ContentHandlerFactoryRegistry).
>> log4j:WARN Please initialize the log4j system properly.
>> log4j:WARN See http://logging.apache.org/log4j/1.2/faq.html#noconfig for
>> more info.
>> i go to the faq guide and it say try loading the class or resource
>> yourself.
>> If you can't find it, neither will log4j.
>>
>> aaa i dont know where to set this
>>
>> also here its my xlst
>>
>>
>> http://old.nabble.com/file/p31835645/FacturasOMF.xsl FacturasOMF.xsl
>>
>>
>> and the fo file that generate the editix
>>
>> http://old.nabble.com/file/p31835645/Prueba.fo Prueba.fo
>>
>>
>> Rob Sargent-4 wrote:
>>> The first thing is to really dig into what you did to netbeans to get it
>>> to work...
>>>
>>> I've forgotten what your stylesheet looked like, so maybe if you show us
>>> again how you're referencing your images we might notice a problem.
>>>
>>> It might also help to see the "fo" generated during your transformation.
>>> Can you grab that just after xslt and just before fop calls.
>>>
>>> Are you sure there is no error being logged somewhere when you run from
>>> the command line? (Where is log4j writing and at what level?)
>>>
>>>
>>>
>>> Oscar.Flores wrote:
>>>> You where absolutly rigth i miss a few libraries to add into the jar
>>>> file, i
>>>> modified the build.xml to add the package and jar that i need, now the
>>>> error
>>>> message is not there but still the images dont show in the pdf i
>>>> remeber
>>>> that i do something in netbeans so they can add to the pdf but i cant
>>>> remeber i dont now if there is still a library that is missing or i am
>>>> adding more than it should be
>>>> This is what i use :
>>>> cfdi-base-0.1.6-SNAPSHOT.jar
>>>> guava-r09.jar
>>>> guava-r09-gwt.jar
>>>> jaxb-impl-2.1.10.jar
>>>> avalon-framework-api-4.3.jar
>>>> avalon-framework-cvs-20020806.jar
>>>> avalon-logkit-2.1.jar
>>>> not-yet-commons-ssl-0.3.11.jar
>>>> commons-codec-1.5.jar
>>>> commons-codec-1.5-sources.jar
>>>> log4j-1.2.16.jar
>>>> fop.jar
>>>> jdom.jar
>>>> xmlgraphics-commons-1.4.jar
>>>> commons-io-1.3.1.jar
>>>> fop-pdf-images-2.0.1.SNAPSHOT.jar
>>>> pdfbox-app-1.5.0.jar
>>>> fontbox-1.3.1.jar
>>>> jempbox-1.3.1.jar
>>>> xercesImpl-2.7.1.jar
>>>> batik-all-1.7.jar
>>>> xml-apis-1.3.04.jar
>>>> xml-apis-ext-1.3.04.jar
>>>>   avalon-framework-4.2.0.jar
>>>>   xalan-2.7.0.jar
>>>>   serializer-2.7.0.jar
>>>>   commons-logging-1.0.4.jar
>>>>   jai_codec.jar
>>>>   jai_core.jar
>>>>   batik-ext.jar
>>>>   jai_imageio-1.1-sources.jar
>>>>
>>>> Thanks Rob for the help
>>>>
>>>>
>>>> Rob Sargent-4 wrote:
>>>>
>>>>> I suspect running from your jar does not have/use the same classpath
>>>>> that is in effect while you're in the debugger.
>>>>> By what mechanism do you generate the jar?
>>>>> Is it an executable jar or are you running java -classpath
>>>>> <your-jar-here:other-jars>  Main?
>>>>> Make your IDE (netbeans) display the classpath  it uses to run your
>>>>> app
>>>>> and compare that with the above.
>>>>>
>>>>> On 06/09/2011 07:21 PM, Oscar.Flores wrote:
>>>>>
>>>>>> aaa ok well my problem is that when i do the pdf in netbean the pdf
>>>>>> is
>>>>>> fine
>>>>>> with images and evething but when i run the jar file in command it
>>>>>> give
>>>>>> me a
>>>>>> error
>>>>>>
>>>>>> GRAVE: Error while processing image: I:\cfd\rfc.jpg (image/jpeg)
>>>>>>    org.apache.xmlgraphics.image.loader.ImageException: Cannot load
>>>>>>    image (no suitable loader/converter combination available) for
>>>>>> I:\cfd\rfc.jpg
>>>>>>    (image/jpeg)
>>>>>>
>>>>>> so i dont no what its not working and if i have to add something to
>>>>>> my
>>>>>> code
>>>>>> so the images can load i am soooo desperate what i am doing wrong??
>>>>>> i am sorry for the trouble and if a dont explain my self very good
>>>>>> jejeje
>>>>>>
>>>>>>
>>>>>> Rob Sargent-4 wrote:
>>>>>>
>>>>>>> Not at all sure what your problem is.  All I can do is show you what
>>>>>>> works for us.
>>>>>>>
>>>>>>> Our source xml looks like this:
>>>>>>> <image image-id="381623861" reference-id="ref-220" width="750"
>>>>>>> height="750" image-space-id="space-1" position="5"
>>>>>>>                 image-pool-position="31" pos="4"
>>>>>>>                 file="ref_10_1002108221">   <!-- an actual file
>>>>>>> (.jpeg
>>>>>>> copied the working directory of the transformer -->
>>>>>>> <fields />
>>>>>>> <caption />
>>>>>>> <annotations>
>>>>>>> <arrow_positions origHeight="750" origWidth="750" />
>>>>>>> </annotations>
>>>>>>> </image>
>>>>>>>
>>>>>>> Our xslt looks like this for each image needed.
>>>>>>>
>>>>>>> <xsl:template name="image">
>>>>>>> <xsl:param name="img"/>   <!-- This is the xml node from the source
>>>>>>> xml
>>>>>>> above -->
>>>>>>> <xsl:param name="width"/>
>>>>>>> <xsl:param name="height" select="$width"/>
>>>>>>> <xsl:param name="ignoreHeight">false</xsl:param>
>>>>>>> <fo:block>
>>>>>>> <fo:external-graphic src="{$img/@file}" height="{$height}"
>>>>>>> width="{$width}" content-height="scale-to-fit"
>>>>>>>                                     content-width="scale-to-fit"
>>>>>>> border="0.5pt solid black" border-collapse="separate">
>>>>>>> <xsl:if test="$ignoreHeight != 'true'">
>>>>>>> <xsl:attribute name="height">
>>>>>>> <xsl:value-of select="$height"/>
>>>>>>> </xsl:attribute>
>>>>>>> </xsl:if>
>>>>>>> </fo:external-graphic>
>>>>>>> </fo:block>
>>>>>>> </xsl:template>
>>>>>>>
>>>>>>> Our generated fo looks like this:
>>>>>>> <fo:table-cell>
>>>>>>> <fo:block>
>>>>>>> <fo:external-graphic border-collapse="separate" border="0.5pt solid
>>>>>>> black" content-width="scale-to-fit" content-height="scale-to-fit"
>>>>>>> width="2.5in" height="2.5in" src="ref_10_1002108221" />
>>>>>>> </fo:block>
>>>>>>> </fo:table-cell>
>>>>>>>
>>>>>>> And the generated pdfs include the image and are shipped to the
>>>>>>> printer.
>>>>>>>
>>>>>>> How does this stack up with what you have?
>>>>>>>
>>>>>>>
>>>>>>> On 06/09/2011 01:19 PM, Oscar.Flores wrote:
>>>>>>>
>>>>>>>> Hi there well i still got the problem but searching IN INTERNET i
>>>>>>>> find
>>>>>>>> a
>>>>>>>> JPEG
>>>>>>>> renderer output for FOP its here
>>>>>>>>
>>>>>>>> http://marc.info/?l=fop-user&m=125986752706366&w=2
>>>>>>>>
>>>>>>>> the cuestion is can i render the image that i want to put in the
>>>>>>>> pdf,
>>>>>>>> and
>>>>>>>> then add to the xsl the render jpeg it will work??
>>>>>>>>
>>>>>>>> and here explaints how use the render when he say uses fop as
>>>>>>>> normal
>>>>>>>> case
>>>>>>>> what does it mean
>>>>>>>> what else have to add to the code?? i hope you can help me
>>>>>>>>
>>>>>>>> Thanks!!
>>>>>>>>
>>>>>>>> // OutputStream out = what you want
>>>>>>>>                FopFactory fopFactory = FopFactory.newInstance();
>>>>>>>>                RendererFactory rendererFactory = null;
>>>>>>>>                FOUserAgent foUserAgent = null;
>>>>>>>>
>>>>>>>>                rendererFactory = fopFactory.getRendererFactory();
>>>>>>>>                rendererFactory.addRendererMaker(new
>>>>>>>> MultiRendererMaker("jpeg"));
>>>>>>>>                foUserAgent = fopFactory.newFOUserAgent();
>>>>>>>>                rendererFactory.createRenderer(foUserAgent,
>>>>>>>> "image/jpeg");
>>>>>>>>
>>>>>>>>                Fop fop = fopFactory.newFop("image/jpeg",
>>>>>>>> foUserAgent,
>>>>>>>> out);
>>>>>>>>
>>>>>>>> //Use fop as normal case
>>>>>>>>
>>>>>>>>
>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>
>>>>>>>>> Since you're now into xmlgraphics, I think you're best bet is here
>>>>>>>>> <http://xmlgraphics.apache.org/commons/image-loader.html>
>>>>>>>>>
>>>>>>>>> On 06/07/2011 10:18 AM, Oscar.Flores wrote:
>>>>>>>>>
>>>>>>>>>> Hi ok this is for generate images that dont need to be decompress
>>>>>>>>>> later??
>>>>>>>>>> and
>>>>>>>>>> the result image i put in my xsl ?? then it should work, aaa i
>>>>>>>>>> change
>>>>>>>>>> to
>>>>>>>>>> fop
>>>>>>>>>> 1.0 and xml communs 1.4 and its the same jejeje   dont find the
>>>>>>>>>> image
>>>>>>>>>> preload
>>>>>>>>>>
>>>>>>>>>> org.apache.fop.fo.flow.ExternalGraphic bind
>>>>>>>>>> SEVERE: Image not available: The file format is not supported. No
>>>>>>>>>> ImagePreloader for *.jpg or *.bmp
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>
>>>>>>>>>>> ImageIO.write(bufferedImage, "JPEG", file);
>>>>>>>>>>>
>>>>>>>>>>> On 06/07/2011 08:21 AM, Oscar.Flores wrote:
>>>>>>>>>>>
>>>>>>>>>>>> Ok i actually register the handler now what i have to do is
>>>>>>>>>>>> setup
>>>>>>>>>>>> this
>>>>>>>>>>>> handler or not?? and how can i do that, also it seem that the
>>>>>>>>>>>> bmp
>>>>>>>>>>>> its
>>>>>>>>>>>> not
>>>>>>>>>>>> recognice also what can i do?? thanks for the help rob
>>>>>>>>>>>> also i am trying to convert the images to see if it that helps
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>
>>>>>>>>>>>>> On 06/06/2011 02:29 PM, Oscar.Flores wrote:
>>>>>>>>>>>>>
>>>>>>>>>>>>>> Hi what can be the difference between execute the program in
>>>>>>>>>>>>>> netbeans
>>>>>>>>>>>>>> (where
>>>>>>>>>>>>>> it works and print the images and the jar in the console)
>>>>>>>>>>>>>>
>>>>>>>>>>>>> Different classes being loaded by Netbeans than the console
>>>>>>>>>>>>> app.
>>>>>>>>>>>>> Get
>>>>>>>>>>>>> Netbeans to show you the full classpath it's using in it's
>>>>>>>>>>>>> "%classpath"
>>>>>>>>>>>>> variable
>>>>>>>>>>>>>
>>>>>>>>>>>>>> also i tried the
>>>>>>>>>>>>>> imageIO.getImageReadersBySuffix but i cant interpretate the
>>>>>>>>>>>>>> data
>>>>>>>>>>>>>> y.y,
>>>>>>>>>>>>>> its
>>>>>>>>>>>>>> that or always its true in the boolean variable, and how can
>>>>>>>>>>>>>> i
>>>>>>>>>>>>>> register
>>>>>>>>>>>>>> the
>>>>>>>>>>>>>> handler??
>>>>>>>>>>>>>>
>>>>>>>>>>>>> Talk to IIORegistry, some thing like
>>>>>>>>>>>>>
>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>> CLibJPEGImageReaderSpi());
>>>>>>>>>>>>>
>>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>>> CLibJPEGImageWriterSpi());
>>>>>>>>>>>>> Note: those are not necessarily the services you have in your
>>>>>>>>>>>>> setup.
>>>>>>>>>>>>>
>>>>>>>>>>>>>> Thanks
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> See the javadoc on IIORegistry. With ImageIO you may have to
>>>>>>>>>>>>>>> register
>>>>>>>>>>>>>>> your handler(s). What does ImageIO.getImageReadersBySuffix()
>>>>>>>>>>>>>>> give
>>>>>>>>>>>>>>> you.
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> For certain jpegs we don't use ImageIO, rather the classes
>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>> com.sun.image.codec.jpeg:
>>>>>>>>>>>>>>>                try {
>>>>>>>>>>>>>>>                    FileOutputStream fos = new
>>>>>>>>>>>>>>> FileOutputStream(file);
>>>>>>>>>>>>>>>                    JPEGImageEncoder encoder =
>>>>>>>>>>>>>>> JPEGCodec.createJPEGEncoder(fos);
>>>>>>>>>>>>>>>                    JPEGEncodeParam param =
>>>>>>>>>>>>>>> encoder.getDefaultJPEGEncodeParam(image.getRaster(),
>>>>>>>>>>>>>>> JPEGDecodeParam.COLOR_ID_CMYK);
>>>>>>>>>>>>>>>                    param.setQuality(1, false);
>>>>>>>>>>>>>>>                    encoder.encode(image.getRaster(), param);
>>>>>>>>>>>>>>>                    fos.close();
>>>>>>>>>>>>>>>                } catch (Throwable t) {
>>>>>>>>>>>>>>>                    logger.debug(t.getMessage());
>>>>>>>>>>>>>>>                }
>>>>>>>>>>>>>>> But generally we use ImageIO
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> On 06/06/2011 08:29 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> Yeah i think i need your help again i tried tu run the .jar
>>>>>>>>>>>>>>>> file
>>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>> console it work but without images this it what appears
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> GRAVE: Error while processing image: I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException: Cannot
>>>>>>>>>>>>>>>> load
>>>>>>>>>>>>>>>> image
>>>>>>>>>>>>>>>> (no
>>>>>>>>>>>>>>>> suitable loader/converter combination available) for
>>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> i tried  download the jai-imagio add to the class path but
>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>> dont
>>>>>>>>>>>>>>>> work
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> Very odd.  I'm having no problems getting images into pdfs
>>>>>>>>>>>>>>>>> using
>>>>>>>>>>>>>>>>> fop-1.0.
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> On 06/03/2011 11:04 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> aaa hey thanks for the help the other day, i resolve the
>>>>>>>>>>>>>>>>>> problem
>>>>>>>>>>>>>>>>>> changing
>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>> version of FOP for the 0.95beta instead of the 1.0, it
>>>>>>>>>>>>>>>>>> works
>>>>>>>>>>>>>>>>>> now
>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>> prints
>>>>>>>>>>>>>>>>>> the image and its good, thanks and we are in touch if
>>>>>>>>>>>>>>>>>> anything
>>>>>>>>>>>>>>>>>> else
>>>>>>>>>>>>>>>>>> fails
>>>>>>>>>>>>>>>>>> jejeje
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> Nothing in the log from the transformer?
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> On 06/03/2011 09:47 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>> hi there i have another problem i hope you can help me
>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>> create
>>>>>>>>>>>>>>>>>>>> with foe has no image, it dont show any of them, the
>>>>>>>>>>>>>>>>>>>> xsl
>>>>>>>>>>>>>>>>>>>> seems
>>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>>> be
>>>>>>>>>>>>>>>>>>>> rigth i
>>>>>>>>>>>>>>>>>>>> tested with EditX and the pdf show me the image, what
>>>>>>>>>>>>>>>>>>>> can
>>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>>> be,
>>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>>> xmlgraphics-commons-1.5svn, fop 1.0, fop-pdf-images
>>>>>>>>>>>>>>>>>>>> 2.0.1
>>>>>>>>>>>>>>>>>>>> Snapshot
>>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>>> render of the image but it don work please help!!!  :,(
>>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>> :-):confused::confused::confused::confused:=)
>>>>>>>>>>>>
>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>> ---------------------------------------------------------------------
>>>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>> For additional commands, e-mail:
>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>> ---------------------------------------------------------------------
>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>>>
>>>>>
>>>>>
>>>>>
>>>> http://old.nabble.com/file/p31822059/libraries.jpeg
>>>> http://old.nabble.com/file/p31822059/libraries.bmp libraries.bmp
>>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>
>>>
>>>
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
> 
> 
> 

-- 
View this message in context: http://old.nabble.com/Problems-with-FOP-and-image-tp31766430p31836113.html
Sent from the FOP - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Problems with FOP and image

Posted by Rob Sargent <rs...@xmission.com>.
Do you have a config file for log4j.  Usually it's in a resource tree.  
Are you copying that to your deployment? Is your ant script including 
the config file in the jar of your application?

On 06/13/2011 10:12 AM, Oscar.Flores wrote:
> Ok yeah the log4j its having isuees to find the configuration
>
> log4j:WARN No appenders could be found for logger
> (org.apache.fop.util.ContentHandlerFactoryRegistry).
> log4j:WARN Please initialize the log4j system properly.
> log4j:WARN See http://logging.apache.org/log4j/1.2/faq.html#noconfig for
> more info.
> i go to the faq guide and it say try loading the class or resource yourself.
> If you can't find it, neither will log4j.
>
> aaa i dont know where to set this
>
> also here its my xlst
>
>
> http://old.nabble.com/file/p31835645/FacturasOMF.xsl FacturasOMF.xsl
>
>
> and the fo file that generate the editix
>
> http://old.nabble.com/file/p31835645/Prueba.fo Prueba.fo
>
>
> Rob Sargent-4 wrote:
>> The first thing is to really dig into what you did to netbeans to get it
>> to work...
>>
>> I've forgotten what your stylesheet looked like, so maybe if you show us
>> again how you're referencing your images we might notice a problem.
>>
>> It might also help to see the "fo" generated during your transformation.
>> Can you grab that just after xslt and just before fop calls.
>>
>> Are you sure there is no error being logged somewhere when you run from
>> the command line? (Where is log4j writing and at what level?)
>>
>>
>>
>> Oscar.Flores wrote:
>>> You where absolutly rigth i miss a few libraries to add into the jar
>>> file, i
>>> modified the build.xml to add the package and jar that i need, now the
>>> error
>>> message is not there but still the images dont show in the pdf i remeber
>>> that i do something in netbeans so they can add to the pdf but i cant
>>> remeber i dont now if there is still a library that is missing or i am
>>> adding more than it should be
>>> This is what i use :
>>> cfdi-base-0.1.6-SNAPSHOT.jar
>>> guava-r09.jar
>>> guava-r09-gwt.jar
>>> jaxb-impl-2.1.10.jar
>>> avalon-framework-api-4.3.jar
>>> avalon-framework-cvs-20020806.jar
>>> avalon-logkit-2.1.jar
>>> not-yet-commons-ssl-0.3.11.jar
>>> commons-codec-1.5.jar
>>> commons-codec-1.5-sources.jar
>>> log4j-1.2.16.jar
>>> fop.jar
>>> jdom.jar
>>> xmlgraphics-commons-1.4.jar
>>> commons-io-1.3.1.jar
>>> fop-pdf-images-2.0.1.SNAPSHOT.jar
>>> pdfbox-app-1.5.0.jar
>>> fontbox-1.3.1.jar
>>> jempbox-1.3.1.jar
>>> xercesImpl-2.7.1.jar
>>> batik-all-1.7.jar
>>> xml-apis-1.3.04.jar
>>> xml-apis-ext-1.3.04.jar
>>>   avalon-framework-4.2.0.jar
>>>   xalan-2.7.0.jar
>>>   serializer-2.7.0.jar
>>>   commons-logging-1.0.4.jar
>>>   jai_codec.jar
>>>   jai_core.jar
>>>   batik-ext.jar
>>>   jai_imageio-1.1-sources.jar
>>>
>>> Thanks Rob for the help
>>>
>>>
>>> Rob Sargent-4 wrote:
>>>
>>>> I suspect running from your jar does not have/use the same classpath
>>>> that is in effect while you're in the debugger.
>>>> By what mechanism do you generate the jar?
>>>> Is it an executable jar or are you running java -classpath
>>>> <your-jar-here:other-jars>  Main?
>>>> Make your IDE (netbeans) display the classpath  it uses to run your app
>>>> and compare that with the above.
>>>>
>>>> On 06/09/2011 07:21 PM, Oscar.Flores wrote:
>>>>
>>>>> aaa ok well my problem is that when i do the pdf in netbean the pdf is
>>>>> fine
>>>>> with images and evething but when i run the jar file in command it give
>>>>> me a
>>>>> error
>>>>>
>>>>> GRAVE: Error while processing image: I:\cfd\rfc.jpg (image/jpeg)
>>>>>    org.apache.xmlgraphics.image.loader.ImageException: Cannot load
>>>>>    image (no suitable loader/converter combination available) for
>>>>> I:\cfd\rfc.jpg
>>>>>    (image/jpeg)
>>>>>
>>>>> so i dont no what its not working and if i have to add something to my
>>>>> code
>>>>> so the images can load i am soooo desperate what i am doing wrong??
>>>>> i am sorry for the trouble and if a dont explain my self very good
>>>>> jejeje
>>>>>
>>>>>
>>>>> Rob Sargent-4 wrote:
>>>>>
>>>>>> Not at all sure what your problem is.  All I can do is show you what
>>>>>> works for us.
>>>>>>
>>>>>> Our source xml looks like this:
>>>>>> <image image-id="381623861" reference-id="ref-220" width="750"
>>>>>> height="750" image-space-id="space-1" position="5"
>>>>>>                 image-pool-position="31" pos="4"
>>>>>>                 file="ref_10_1002108221">   <!-- an actual file (.jpeg
>>>>>> copied the working directory of the transformer -->
>>>>>> <fields />
>>>>>> <caption />
>>>>>> <annotations>
>>>>>> <arrow_positions origHeight="750" origWidth="750" />
>>>>>> </annotations>
>>>>>> </image>
>>>>>>
>>>>>> Our xslt looks like this for each image needed.
>>>>>>
>>>>>> <xsl:template name="image">
>>>>>> <xsl:param name="img"/>   <!-- This is the xml node from the source xml
>>>>>> above -->
>>>>>> <xsl:param name="width"/>
>>>>>> <xsl:param name="height" select="$width"/>
>>>>>> <xsl:param name="ignoreHeight">false</xsl:param>
>>>>>> <fo:block>
>>>>>> <fo:external-graphic src="{$img/@file}" height="{$height}"
>>>>>> width="{$width}" content-height="scale-to-fit"
>>>>>>                                     content-width="scale-to-fit"
>>>>>> border="0.5pt solid black" border-collapse="separate">
>>>>>> <xsl:if test="$ignoreHeight != 'true'">
>>>>>> <xsl:attribute name="height">
>>>>>> <xsl:value-of select="$height"/>
>>>>>> </xsl:attribute>
>>>>>> </xsl:if>
>>>>>> </fo:external-graphic>
>>>>>> </fo:block>
>>>>>> </xsl:template>
>>>>>>
>>>>>> Our generated fo looks like this:
>>>>>> <fo:table-cell>
>>>>>> <fo:block>
>>>>>> <fo:external-graphic border-collapse="separate" border="0.5pt solid
>>>>>> black" content-width="scale-to-fit" content-height="scale-to-fit"
>>>>>> width="2.5in" height="2.5in" src="ref_10_1002108221" />
>>>>>> </fo:block>
>>>>>> </fo:table-cell>
>>>>>>
>>>>>> And the generated pdfs include the image and are shipped to the
>>>>>> printer.
>>>>>>
>>>>>> How does this stack up with what you have?
>>>>>>
>>>>>>
>>>>>> On 06/09/2011 01:19 PM, Oscar.Flores wrote:
>>>>>>
>>>>>>> Hi there well i still got the problem but searching IN INTERNET i
>>>>>>> find
>>>>>>> a
>>>>>>> JPEG
>>>>>>> renderer output for FOP its here
>>>>>>>
>>>>>>> http://marc.info/?l=fop-user&m=125986752706366&w=2
>>>>>>>
>>>>>>> the cuestion is can i render the image that i want to put in the pdf,
>>>>>>> and
>>>>>>> then add to the xsl the render jpeg it will work??
>>>>>>>
>>>>>>> and here explaints how use the render when he say uses fop as normal
>>>>>>> case
>>>>>>> what does it mean
>>>>>>> what else have to add to the code?? i hope you can help me
>>>>>>>
>>>>>>> Thanks!!
>>>>>>>
>>>>>>> // OutputStream out = what you want
>>>>>>>                FopFactory fopFactory = FopFactory.newInstance();
>>>>>>>                RendererFactory rendererFactory = null;
>>>>>>>                FOUserAgent foUserAgent = null;
>>>>>>>
>>>>>>>                rendererFactory = fopFactory.getRendererFactory();
>>>>>>>                rendererFactory.addRendererMaker(new
>>>>>>> MultiRendererMaker("jpeg"));
>>>>>>>                foUserAgent = fopFactory.newFOUserAgent();
>>>>>>>                rendererFactory.createRenderer(foUserAgent,
>>>>>>> "image/jpeg");
>>>>>>>
>>>>>>>                Fop fop = fopFactory.newFop("image/jpeg", foUserAgent,
>>>>>>> out);
>>>>>>>
>>>>>>> //Use fop as normal case
>>>>>>>
>>>>>>>
>>>>>>> Rob Sargent-4 wrote:
>>>>>>>
>>>>>>>> Since you're now into xmlgraphics, I think you're best bet is here
>>>>>>>> <http://xmlgraphics.apache.org/commons/image-loader.html>
>>>>>>>>
>>>>>>>> On 06/07/2011 10:18 AM, Oscar.Flores wrote:
>>>>>>>>
>>>>>>>>> Hi ok this is for generate images that dont need to be decompress
>>>>>>>>> later??
>>>>>>>>> and
>>>>>>>>> the result image i put in my xsl ?? then it should work, aaa i
>>>>>>>>> change
>>>>>>>>> to
>>>>>>>>> fop
>>>>>>>>> 1.0 and xml communs 1.4 and its the same jejeje   dont find the
>>>>>>>>> image
>>>>>>>>> preload
>>>>>>>>>
>>>>>>>>> org.apache.fop.fo.flow.ExternalGraphic bind
>>>>>>>>> SEVERE: Image not available: The file format is not supported. No
>>>>>>>>> ImagePreloader for *.jpg or *.bmp
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>
>>>>>>>>>> ImageIO.write(bufferedImage, "JPEG", file);
>>>>>>>>>>
>>>>>>>>>> On 06/07/2011 08:21 AM, Oscar.Flores wrote:
>>>>>>>>>>
>>>>>>>>>>> Ok i actually register the handler now what i have to do is setup
>>>>>>>>>>> this
>>>>>>>>>>> handler or not?? and how can i do that, also it seem that the bmp
>>>>>>>>>>> its
>>>>>>>>>>> not
>>>>>>>>>>> recognice also what can i do?? thanks for the help rob
>>>>>>>>>>> also i am trying to convert the images to see if it that helps
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>
>>>>>>>>>>>> On 06/06/2011 02:29 PM, Oscar.Flores wrote:
>>>>>>>>>>>>
>>>>>>>>>>>>> Hi what can be the difference between execute the program in
>>>>>>>>>>>>> netbeans
>>>>>>>>>>>>> (where
>>>>>>>>>>>>> it works and print the images and the jar in the console)
>>>>>>>>>>>>>
>>>>>>>>>>>> Different classes being loaded by Netbeans than the console app.
>>>>>>>>>>>> Get
>>>>>>>>>>>> Netbeans to show you the full classpath it's using in it's
>>>>>>>>>>>> "%classpath"
>>>>>>>>>>>> variable
>>>>>>>>>>>>
>>>>>>>>>>>>> also i tried the
>>>>>>>>>>>>> imageIO.getImageReadersBySuffix but i cant interpretate the
>>>>>>>>>>>>> data
>>>>>>>>>>>>> y.y,
>>>>>>>>>>>>> its
>>>>>>>>>>>>> that or always its true in the boolean variable, and how can i
>>>>>>>>>>>>> register
>>>>>>>>>>>>> the
>>>>>>>>>>>>> handler??
>>>>>>>>>>>>>
>>>>>>>>>>>> Talk to IIORegistry, some thing like
>>>>>>>>>>>>
>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>> CLibJPEGImageReaderSpi());
>>>>>>>>>>>>
>>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>>> CLibJPEGImageWriterSpi());
>>>>>>>>>>>> Note: those are not necessarily the services you have in your
>>>>>>>>>>>> setup.
>>>>>>>>>>>>
>>>>>>>>>>>>> Thanks
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>
>>>>>>>>>>>>>> See the javadoc on IIORegistry. With ImageIO you may have to
>>>>>>>>>>>>>> register
>>>>>>>>>>>>>> your handler(s). What does ImageIO.getImageReadersBySuffix()
>>>>>>>>>>>>>> give
>>>>>>>>>>>>>> you.
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> For certain jpegs we don't use ImageIO, rather the classes in
>>>>>>>>>>>>>> com.sun.image.codec.jpeg:
>>>>>>>>>>>>>>                try {
>>>>>>>>>>>>>>                    FileOutputStream fos = new
>>>>>>>>>>>>>> FileOutputStream(file);
>>>>>>>>>>>>>>                    JPEGImageEncoder encoder =
>>>>>>>>>>>>>> JPEGCodec.createJPEGEncoder(fos);
>>>>>>>>>>>>>>                    JPEGEncodeParam param =
>>>>>>>>>>>>>> encoder.getDefaultJPEGEncodeParam(image.getRaster(),
>>>>>>>>>>>>>> JPEGDecodeParam.COLOR_ID_CMYK);
>>>>>>>>>>>>>>                    param.setQuality(1, false);
>>>>>>>>>>>>>>                    encoder.encode(image.getRaster(), param);
>>>>>>>>>>>>>>                    fos.close();
>>>>>>>>>>>>>>                } catch (Throwable t) {
>>>>>>>>>>>>>>                    logger.debug(t.getMessage());
>>>>>>>>>>>>>>                }
>>>>>>>>>>>>>> But generally we use ImageIO
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> On 06/06/2011 08:29 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> Yeah i think i need your help again i tried tu run the .jar
>>>>>>>>>>>>>>> file
>>>>>>>>>>>>>>> in
>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>> console it work but without images this it what appears
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> GRAVE: Error while processing image: I:\cfd\rfc.jpg
>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException: Cannot
>>>>>>>>>>>>>>> load
>>>>>>>>>>>>>>> image
>>>>>>>>>>>>>>> (no
>>>>>>>>>>>>>>> suitable loader/converter combination available) for
>>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> i tried  download the jai-imagio add to the class path but it
>>>>>>>>>>>>>>> dont
>>>>>>>>>>>>>>> work
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> Very odd.  I'm having no problems getting images into pdfs
>>>>>>>>>>>>>>>> using
>>>>>>>>>>>>>>>> fop-1.0.
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> On 06/03/2011 11:04 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> aaa hey thanks for the help the other day, i resolve the
>>>>>>>>>>>>>>>>> problem
>>>>>>>>>>>>>>>>> changing
>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>> version of FOP for the 0.95beta instead of the 1.0, it
>>>>>>>>>>>>>>>>> works
>>>>>>>>>>>>>>>>> now
>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>> prints
>>>>>>>>>>>>>>>>> the image and its good, thanks and we are in touch if
>>>>>>>>>>>>>>>>> anything
>>>>>>>>>>>>>>>>> else
>>>>>>>>>>>>>>>>> fails
>>>>>>>>>>>>>>>>> jejeje
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> Nothing in the log from the transformer?
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> On 06/03/2011 09:47 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> hi there i have another problem i hope you can help me
>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>> create
>>>>>>>>>>>>>>>>>>> with foe has no image, it dont show any of them, the xsl
>>>>>>>>>>>>>>>>>>> seems
>>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>>> be
>>>>>>>>>>>>>>>>>>> rigth i
>>>>>>>>>>>>>>>>>>> tested with EditX and the pdf show me the image, what can
>>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>>> be,
>>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>>> xmlgraphics-commons-1.5svn, fop 1.0, fop-pdf-images 2.0.1
>>>>>>>>>>>>>>>>>>> Snapshot
>>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>>> render of the image but it don work please help!!!  :,(
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>> :-):confused::confused::confused::confused:=)
>>>>>>>>>>>
>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>> ---------------------------------------------------------------------
>>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>> ---------------------------------------------------------------------
>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>>
>>>>
>>>>
>>>>
>>> http://old.nabble.com/file/p31822059/libraries.jpeg
>>> http://old.nabble.com/file/p31822059/libraries.bmp libraries.bmp
>>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>
>>
>>

---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Problems with FOP and image

Posted by "Oscar.Flores" <fa...@hotmail.com>.
Ok yeah the log4j its having isuees to find the configuration 

log4j:WARN No appenders could be found for logger
(org.apache.fop.util.ContentHandlerFactoryRegistry).
log4j:WARN Please initialize the log4j system properly.
log4j:WARN See http://logging.apache.org/log4j/1.2/faq.html#noconfig for
more info.
i go to the faq guide and it say try loading the class or resource yourself.
If you can't find it, neither will log4j. 

aaa i dont know where to set this 

also here its my xlst


http://old.nabble.com/file/p31835645/FacturasOMF.xsl FacturasOMF.xsl 

 
and the fo file that generate the editix

http://old.nabble.com/file/p31835645/Prueba.fo Prueba.fo 


Rob Sargent-4 wrote:
> 
> The first thing is to really dig into what you did to netbeans to get it 
> to work...
> 
> I've forgotten what your stylesheet looked like, so maybe if you show us 
> again how you're referencing your images we might notice a problem.
> 
> It might also help to see the "fo" generated during your transformation. 
> Can you grab that just after xslt and just before fop calls.
> 
> Are you sure there is no error being logged somewhere when you run from 
> the command line? (Where is log4j writing and at what level?)
> 
> 
> 
> Oscar.Flores wrote:
>> You where absolutly rigth i miss a few libraries to add into the jar
>> file, i
>> modified the build.xml to add the package and jar that i need, now the
>> error
>> message is not there but still the images dont show in the pdf i remeber
>> that i do something in netbeans so they can add to the pdf but i cant
>> remeber i dont now if there is still a library that is missing or i am
>> adding more than it should be 
>> This is what i use :
>> cfdi-base-0.1.6-SNAPSHOT.jar 
>> guava-r09.jar
>> guava-r09-gwt.jar
>> jaxb-impl-2.1.10.jar
>> avalon-framework-api-4.3.jar
>> avalon-framework-cvs-20020806.jar
>> avalon-logkit-2.1.jar
>> not-yet-commons-ssl-0.3.11.jar
>> commons-codec-1.5.jar
>> commons-codec-1.5-sources.jar
>> log4j-1.2.16.jar
>> fop.jar
>> jdom.jar
>> xmlgraphics-commons-1.4.jar
>> commons-io-1.3.1.jar
>> fop-pdf-images-2.0.1.SNAPSHOT.jar
>> pdfbox-app-1.5.0.jar
>> fontbox-1.3.1.jar
>> jempbox-1.3.1.jar
>> xercesImpl-2.7.1.jar
>> batik-all-1.7.jar
>> xml-apis-1.3.04.jar
>> xml-apis-ext-1.3.04.jar
>>  avalon-framework-4.2.0.jar
>>  xalan-2.7.0.jar
>>  serializer-2.7.0.jar
>>  commons-logging-1.0.4.jar
>>  jai_codec.jar
>>  jai_core.jar     
>>  batik-ext.jar
>>  jai_imageio-1.1-sources.jar
>>
>> Thanks Rob for the help
>>   
>>
>> Rob Sargent-4 wrote:
>>   
>>> I suspect running from your jar does not have/use the same classpath 
>>> that is in effect while you're in the debugger.
>>> By what mechanism do you generate the jar?
>>> Is it an executable jar or are you running java -classpath 
>>> <your-jar-here:other-jars> Main?
>>> Make your IDE (netbeans) display the classpath  it uses to run your app 
>>> and compare that with the above.
>>>
>>> On 06/09/2011 07:21 PM, Oscar.Flores wrote:
>>>     
>>>> aaa ok well my problem is that when i do the pdf in netbean the pdf is
>>>> fine
>>>> with images and evething but when i run the jar file in command it give
>>>> me a
>>>> error
>>>>
>>>> GRAVE: Error while processing image: I:\cfd\rfc.jpg (image/jpeg)
>>>>   org.apache.xmlgraphics.image.loader.ImageException: Cannot load
>>>>   image (no suitable loader/converter combination available) for
>>>> I:\cfd\rfc.jpg
>>>>   (image/jpeg)
>>>>
>>>> so i dont no what its not working and if i have to add something to my
>>>> code
>>>> so the images can load i am soooo desperate what i am doing wrong??
>>>> i am sorry for the trouble and if a dont explain my self very good
>>>> jejeje
>>>>
>>>>
>>>> Rob Sargent-4 wrote:
>>>>       
>>>>> Not at all sure what your problem is.  All I can do is show you what
>>>>> works for us.
>>>>>
>>>>> Our source xml looks like this:
>>>>> <image image-id="381623861" reference-id="ref-220" width="750"
>>>>> height="750" image-space-id="space-1" position="5"
>>>>>                image-pool-position="31" pos="4"
>>>>>                file="ref_10_1002108221">  <!-- an actual file (.jpeg
>>>>> copied the working directory of the transformer -->
>>>>> <fields />
>>>>> <caption />
>>>>> <annotations>
>>>>> <arrow_positions origHeight="750" origWidth="750" />
>>>>> </annotations>
>>>>> </image>
>>>>>
>>>>> Our xslt looks like this for each image needed.
>>>>>
>>>>> <xsl:template name="image">
>>>>> <xsl:param name="img"/>  <!-- This is the xml node from the source xml
>>>>> above -->
>>>>> <xsl:param name="width"/>
>>>>> <xsl:param name="height" select="$width"/>
>>>>> <xsl:param name="ignoreHeight">false</xsl:param>
>>>>> <fo:block>
>>>>> <fo:external-graphic src="{$img/@file}" height="{$height}"
>>>>> width="{$width}" content-height="scale-to-fit"
>>>>>                                    content-width="scale-to-fit"
>>>>> border="0.5pt solid black" border-collapse="separate">
>>>>> <xsl:if test="$ignoreHeight != 'true'">
>>>>> <xsl:attribute name="height">
>>>>> <xsl:value-of select="$height"/>
>>>>> </xsl:attribute>
>>>>> </xsl:if>
>>>>> </fo:external-graphic>
>>>>> </fo:block>
>>>>> </xsl:template>
>>>>>
>>>>> Our generated fo looks like this:
>>>>> <fo:table-cell>
>>>>> <fo:block>
>>>>> <fo:external-graphic border-collapse="separate" border="0.5pt solid
>>>>> black" content-width="scale-to-fit" content-height="scale-to-fit"
>>>>> width="2.5in" height="2.5in" src="ref_10_1002108221" />
>>>>> </fo:block>
>>>>> </fo:table-cell>
>>>>>
>>>>> And the generated pdfs include the image and are shipped to the
>>>>> printer.
>>>>>
>>>>> How does this stack up with what you have?
>>>>>
>>>>>
>>>>> On 06/09/2011 01:19 PM, Oscar.Flores wrote:
>>>>>         
>>>>>> Hi there well i still got the problem but searching IN INTERNET i
>>>>>> find
>>>>>> a
>>>>>> JPEG
>>>>>> renderer output for FOP its here
>>>>>>
>>>>>> http://marc.info/?l=fop-user&m=125986752706366&w=2
>>>>>>
>>>>>> the cuestion is can i render the image that i want to put in the pdf,
>>>>>> and
>>>>>> then add to the xsl the render jpeg it will work??
>>>>>>
>>>>>> and here explaints how use the render when he say uses fop as normal
>>>>>> case
>>>>>> what does it mean
>>>>>> what else have to add to the code?? i hope you can help me
>>>>>>
>>>>>> Thanks!!
>>>>>>
>>>>>> // OutputStream out = what you want
>>>>>>               FopFactory fopFactory = FopFactory.newInstance();
>>>>>>               RendererFactory rendererFactory = null;
>>>>>>               FOUserAgent foUserAgent = null;
>>>>>>
>>>>>>               rendererFactory = fopFactory.getRendererFactory();
>>>>>>               rendererFactory.addRendererMaker(new
>>>>>> MultiRendererMaker("jpeg"));
>>>>>>               foUserAgent = fopFactory.newFOUserAgent();
>>>>>>               rendererFactory.createRenderer(foUserAgent,
>>>>>> "image/jpeg");
>>>>>>
>>>>>>               Fop fop = fopFactory.newFop("image/jpeg", foUserAgent,
>>>>>> out);
>>>>>>
>>>>>> //Use fop as normal case
>>>>>>
>>>>>>
>>>>>> Rob Sargent-4 wrote:
>>>>>>           
>>>>>>> Since you're now into xmlgraphics, I think you're best bet is here
>>>>>>> <http://xmlgraphics.apache.org/commons/image-loader.html>
>>>>>>>
>>>>>>> On 06/07/2011 10:18 AM, Oscar.Flores wrote:
>>>>>>>             
>>>>>>>> Hi ok this is for generate images that dont need to be decompress
>>>>>>>> later??
>>>>>>>> and
>>>>>>>> the result image i put in my xsl ?? then it should work, aaa i
>>>>>>>> change
>>>>>>>> to
>>>>>>>> fop
>>>>>>>> 1.0 and xml communs 1.4 and its the same jejeje   dont find the
>>>>>>>> image
>>>>>>>> preload
>>>>>>>>
>>>>>>>> org.apache.fop.fo.flow.ExternalGraphic bind
>>>>>>>> SEVERE: Image not available: The file format is not supported. No
>>>>>>>> ImagePreloader for *.jpg or *.bmp
>>>>>>>>
>>>>>>>>
>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>               
>>>>>>>>> ImageIO.write(bufferedImage, "JPEG", file);
>>>>>>>>>
>>>>>>>>> On 06/07/2011 08:21 AM, Oscar.Flores wrote:
>>>>>>>>>                 
>>>>>>>>>> Ok i actually register the handler now what i have to do is setup
>>>>>>>>>> this
>>>>>>>>>> handler or not?? and how can i do that, also it seem that the bmp
>>>>>>>>>> its
>>>>>>>>>> not
>>>>>>>>>> recognice also what can i do?? thanks for the help rob
>>>>>>>>>> also i am trying to convert the images to see if it that helps
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>                   
>>>>>>>>>>> On 06/06/2011 02:29 PM, Oscar.Flores wrote:
>>>>>>>>>>>                     
>>>>>>>>>>>> Hi what can be the difference between execute the program in
>>>>>>>>>>>> netbeans
>>>>>>>>>>>> (where
>>>>>>>>>>>> it works and print the images and the jar in the console)
>>>>>>>>>>>>                       
>>>>>>>>>>> Different classes being loaded by Netbeans than the console app.
>>>>>>>>>>> Get
>>>>>>>>>>> Netbeans to show you the full classpath it's using in it's
>>>>>>>>>>> "%classpath"
>>>>>>>>>>> variable
>>>>>>>>>>>                     
>>>>>>>>>>>> also i tried the
>>>>>>>>>>>> imageIO.getImageReadersBySuffix but i cant interpretate the
>>>>>>>>>>>> data
>>>>>>>>>>>> y.y,
>>>>>>>>>>>> its
>>>>>>>>>>>> that or always its true in the boolean variable, and how can i
>>>>>>>>>>>> register
>>>>>>>>>>>> the
>>>>>>>>>>>> handler??
>>>>>>>>>>>>                       
>>>>>>>>>>> Talk to IIORegistry, some thing like
>>>>>>>>>>>
>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>> CLibJPEGImageReaderSpi());
>>>>>>>>>>>
>>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>>> CLibJPEGImageWriterSpi());
>>>>>>>>>>> Note: those are not necessarily the services you have in your
>>>>>>>>>>> setup.
>>>>>>>>>>>                     
>>>>>>>>>>>> Thanks
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>                       
>>>>>>>>>>>>> See the javadoc on IIORegistry. With ImageIO you may have to
>>>>>>>>>>>>> register
>>>>>>>>>>>>> your handler(s). What does ImageIO.getImageReadersBySuffix()
>>>>>>>>>>>>> give
>>>>>>>>>>>>> you.
>>>>>>>>>>>>>
>>>>>>>>>>>>> For certain jpegs we don't use ImageIO, rather the classes in
>>>>>>>>>>>>> com.sun.image.codec.jpeg:
>>>>>>>>>>>>>               try {
>>>>>>>>>>>>>                   FileOutputStream fos = new
>>>>>>>>>>>>> FileOutputStream(file);
>>>>>>>>>>>>>                   JPEGImageEncoder encoder =
>>>>>>>>>>>>> JPEGCodec.createJPEGEncoder(fos);
>>>>>>>>>>>>>                   JPEGEncodeParam param =
>>>>>>>>>>>>> encoder.getDefaultJPEGEncodeParam(image.getRaster(),
>>>>>>>>>>>>> JPEGDecodeParam.COLOR_ID_CMYK);
>>>>>>>>>>>>>                   param.setQuality(1, false);
>>>>>>>>>>>>>                   encoder.encode(image.getRaster(), param);
>>>>>>>>>>>>>                   fos.close();
>>>>>>>>>>>>>               } catch (Throwable t) {
>>>>>>>>>>>>>                   logger.debug(t.getMessage());
>>>>>>>>>>>>>               }
>>>>>>>>>>>>> But generally we use ImageIO
>>>>>>>>>>>>>
>>>>>>>>>>>>> On 06/06/2011 08:29 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>                         
>>>>>>>>>>>>>> Yeah i think i need your help again i tried tu run the .jar
>>>>>>>>>>>>>> file
>>>>>>>>>>>>>> in
>>>>>>>>>>>>>> the
>>>>>>>>>>>>>> console it work but without images this it what appears
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> GRAVE: Error while processing image: I:\cfd\rfc.jpg
>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException: Cannot
>>>>>>>>>>>>>> load
>>>>>>>>>>>>>> image
>>>>>>>>>>>>>> (no
>>>>>>>>>>>>>> suitable loader/converter combination available) for
>>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> i tried  download the jai-imagio add to the class path but it
>>>>>>>>>>>>>> dont
>>>>>>>>>>>>>> work
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>                           
>>>>>>>>>>>>>>> Very odd.  I'm having no problems getting images into pdfs
>>>>>>>>>>>>>>> using
>>>>>>>>>>>>>>> fop-1.0.
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> On 06/03/2011 11:04 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>                             
>>>>>>>>>>>>>>>> aaa hey thanks for the help the other day, i resolve the
>>>>>>>>>>>>>>>> problem
>>>>>>>>>>>>>>>> changing
>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>> version of FOP for the 0.95beta instead of the 1.0, it
>>>>>>>>>>>>>>>> works
>>>>>>>>>>>>>>>> now
>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>> prints
>>>>>>>>>>>>>>>> the image and its good, thanks and we are in touch if
>>>>>>>>>>>>>>>> anything
>>>>>>>>>>>>>>>> else
>>>>>>>>>>>>>>>> fails
>>>>>>>>>>>>>>>> jejeje
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>>                               
>>>>>>>>>>>>>>>>> Nothing in the log from the transformer?
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> On 06/03/2011 09:47 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>>                                 
>>>>>>>>>>>>>>>>>> hi there i have another problem i hope you can help me
>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>> create
>>>>>>>>>>>>>>>>>> with foe has no image, it dont show any of them, the xsl
>>>>>>>>>>>>>>>>>> seems
>>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>>> be
>>>>>>>>>>>>>>>>>> rigth i
>>>>>>>>>>>>>>>>>> tested with EditX and the pdf show me the image, what can
>>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>>> be,
>>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>>> xmlgraphics-commons-1.5svn, fop 1.0, fop-pdf-images 2.0.1
>>>>>>>>>>>>>>>>>> Snapshot
>>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>>> render of the image but it don work please help!!!  :,(
>>>>>>>>>>>>>>>>>>                                   
>>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>                                 
>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>                             
>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>                         
>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>                     
>>>>>>>>>> :-):confused::confused::confused::confused:=)
>>>>>>>>>>                   
>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>> For additional commands, e-mail:
>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>                 
>>>>> ---------------------------------------------------------------------
>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>>>
>>>>>
>>>>>
>>>>>         
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>
>>>
>>>
>>>     
>> http://old.nabble.com/file/p31822059/libraries.jpeg 
>> http://old.nabble.com/file/p31822059/libraries.bmp libraries.bmp 
>>   
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
> 
> 
> 

-- 
View this message in context: http://old.nabble.com/Problems-with-FOP-and-image-tp31766430p31835645.html
Sent from the FOP - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Problems with FOP and image

Posted by Rob Sargent <rs...@xmission.com>.
The first thing is to really dig into what you did to netbeans to get it 
to work...

I've forgotten what your stylesheet looked like, so maybe if you show us 
again how you're referencing your images we might notice a problem.

It might also help to see the "fo" generated during your transformation. 
Can you grab that just after xslt and just before fop calls.

Are you sure there is no error being logged somewhere when you run from 
the command line? (Where is log4j writing and at what level?)



Oscar.Flores wrote:
> You where absolutly rigth i miss a few libraries to add into the jar file, i
> modified the build.xml to add the package and jar that i need, now the error
> message is not there but still the images dont show in the pdf i remeber
> that i do something in netbeans so they can add to the pdf but i cant
> remeber i dont now if there is still a library that is missing or i am
> adding more than it should be 
> This is what i use :
> cfdi-base-0.1.6-SNAPSHOT.jar 
> guava-r09.jar
> guava-r09-gwt.jar
> jaxb-impl-2.1.10.jar
> avalon-framework-api-4.3.jar
> avalon-framework-cvs-20020806.jar
> avalon-logkit-2.1.jar
> not-yet-commons-ssl-0.3.11.jar
> commons-codec-1.5.jar
> commons-codec-1.5-sources.jar
> log4j-1.2.16.jar
> fop.jar
> jdom.jar
> xmlgraphics-commons-1.4.jar
> commons-io-1.3.1.jar
> fop-pdf-images-2.0.1.SNAPSHOT.jar
> pdfbox-app-1.5.0.jar
> fontbox-1.3.1.jar
> jempbox-1.3.1.jar
> xercesImpl-2.7.1.jar
> batik-all-1.7.jar
> xml-apis-1.3.04.jar
> xml-apis-ext-1.3.04.jar
>  avalon-framework-4.2.0.jar
>  xalan-2.7.0.jar
>  serializer-2.7.0.jar
>  commons-logging-1.0.4.jar
>  jai_codec.jar
>  jai_core.jar     
>  batik-ext.jar
>  jai_imageio-1.1-sources.jar
>
> Thanks Rob for the help
>   
>
> Rob Sargent-4 wrote:
>   
>> I suspect running from your jar does not have/use the same classpath 
>> that is in effect while you're in the debugger.
>> By what mechanism do you generate the jar?
>> Is it an executable jar or are you running java -classpath 
>> <your-jar-here:other-jars> Main?
>> Make your IDE (netbeans) display the classpath  it uses to run your app 
>> and compare that with the above.
>>
>> On 06/09/2011 07:21 PM, Oscar.Flores wrote:
>>     
>>> aaa ok well my problem is that when i do the pdf in netbean the pdf is
>>> fine
>>> with images and evething but when i run the jar file in command it give
>>> me a
>>> error
>>>
>>> GRAVE: Error while processing image: I:\cfd\rfc.jpg (image/jpeg)
>>>   org.apache.xmlgraphics.image.loader.ImageException: Cannot load
>>>   image (no suitable loader/converter combination available) for
>>> I:\cfd\rfc.jpg
>>>   (image/jpeg)
>>>
>>> so i dont no what its not working and if i have to add something to my
>>> code
>>> so the images can load i am soooo desperate what i am doing wrong??
>>> i am sorry for the trouble and if a dont explain my self very good jejeje
>>>
>>>
>>> Rob Sargent-4 wrote:
>>>       
>>>> Not at all sure what your problem is.  All I can do is show you what
>>>> works for us.
>>>>
>>>> Our source xml looks like this:
>>>> <image image-id="381623861" reference-id="ref-220" width="750"
>>>> height="750" image-space-id="space-1" position="5"
>>>>                image-pool-position="31" pos="4"
>>>>                file="ref_10_1002108221">  <!-- an actual file (.jpeg
>>>> copied the working directory of the transformer -->
>>>> <fields />
>>>> <caption />
>>>> <annotations>
>>>> <arrow_positions origHeight="750" origWidth="750" />
>>>> </annotations>
>>>> </image>
>>>>
>>>> Our xslt looks like this for each image needed.
>>>>
>>>> <xsl:template name="image">
>>>> <xsl:param name="img"/>  <!-- This is the xml node from the source xml
>>>> above -->
>>>> <xsl:param name="width"/>
>>>> <xsl:param name="height" select="$width"/>
>>>> <xsl:param name="ignoreHeight">false</xsl:param>
>>>> <fo:block>
>>>> <fo:external-graphic src="{$img/@file}" height="{$height}"
>>>> width="{$width}" content-height="scale-to-fit"
>>>>                                    content-width="scale-to-fit"
>>>> border="0.5pt solid black" border-collapse="separate">
>>>> <xsl:if test="$ignoreHeight != 'true'">
>>>> <xsl:attribute name="height">
>>>> <xsl:value-of select="$height"/>
>>>> </xsl:attribute>
>>>> </xsl:if>
>>>> </fo:external-graphic>
>>>> </fo:block>
>>>> </xsl:template>
>>>>
>>>> Our generated fo looks like this:
>>>> <fo:table-cell>
>>>> <fo:block>
>>>> <fo:external-graphic border-collapse="separate" border="0.5pt solid
>>>> black" content-width="scale-to-fit" content-height="scale-to-fit"
>>>> width="2.5in" height="2.5in" src="ref_10_1002108221" />
>>>> </fo:block>
>>>> </fo:table-cell>
>>>>
>>>> And the generated pdfs include the image and are shipped to the printer.
>>>>
>>>> How does this stack up with what you have?
>>>>
>>>>
>>>> On 06/09/2011 01:19 PM, Oscar.Flores wrote:
>>>>         
>>>>> Hi there well i still got the problem but searching IN INTERNET i find
>>>>> a
>>>>> JPEG
>>>>> renderer output for FOP its here
>>>>>
>>>>> http://marc.info/?l=fop-user&m=125986752706366&w=2
>>>>>
>>>>> the cuestion is can i render the image that i want to put in the pdf,
>>>>> and
>>>>> then add to the xsl the render jpeg it will work??
>>>>>
>>>>> and here explaints how use the render when he say uses fop as normal
>>>>> case
>>>>> what does it mean
>>>>> what else have to add to the code?? i hope you can help me
>>>>>
>>>>> Thanks!!
>>>>>
>>>>> // OutputStream out = what you want
>>>>>               FopFactory fopFactory = FopFactory.newInstance();
>>>>>               RendererFactory rendererFactory = null;
>>>>>               FOUserAgent foUserAgent = null;
>>>>>
>>>>>               rendererFactory = fopFactory.getRendererFactory();
>>>>>               rendererFactory.addRendererMaker(new
>>>>> MultiRendererMaker("jpeg"));
>>>>>               foUserAgent = fopFactory.newFOUserAgent();
>>>>>               rendererFactory.createRenderer(foUserAgent,
>>>>> "image/jpeg");
>>>>>
>>>>>               Fop fop = fopFactory.newFop("image/jpeg", foUserAgent,
>>>>> out);
>>>>>
>>>>> //Use fop as normal case
>>>>>
>>>>>
>>>>> Rob Sargent-4 wrote:
>>>>>           
>>>>>> Since you're now into xmlgraphics, I think you're best bet is here
>>>>>> <http://xmlgraphics.apache.org/commons/image-loader.html>
>>>>>>
>>>>>> On 06/07/2011 10:18 AM, Oscar.Flores wrote:
>>>>>>             
>>>>>>> Hi ok this is for generate images that dont need to be decompress
>>>>>>> later??
>>>>>>> and
>>>>>>> the result image i put in my xsl ?? then it should work, aaa i change
>>>>>>> to
>>>>>>> fop
>>>>>>> 1.0 and xml communs 1.4 and its the same jejeje   dont find the image
>>>>>>> preload
>>>>>>>
>>>>>>> org.apache.fop.fo.flow.ExternalGraphic bind
>>>>>>> SEVERE: Image not available: The file format is not supported. No
>>>>>>> ImagePreloader for *.jpg or *.bmp
>>>>>>>
>>>>>>>
>>>>>>> Rob Sargent-4 wrote:
>>>>>>>               
>>>>>>>> ImageIO.write(bufferedImage, "JPEG", file);
>>>>>>>>
>>>>>>>> On 06/07/2011 08:21 AM, Oscar.Flores wrote:
>>>>>>>>                 
>>>>>>>>> Ok i actually register the handler now what i have to do is setup
>>>>>>>>> this
>>>>>>>>> handler or not?? and how can i do that, also it seem that the bmp
>>>>>>>>> its
>>>>>>>>> not
>>>>>>>>> recognice also what can i do?? thanks for the help rob
>>>>>>>>> also i am trying to convert the images to see if it that helps
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>                   
>>>>>>>>>> On 06/06/2011 02:29 PM, Oscar.Flores wrote:
>>>>>>>>>>                     
>>>>>>>>>>> Hi what can be the difference between execute the program in
>>>>>>>>>>> netbeans
>>>>>>>>>>> (where
>>>>>>>>>>> it works and print the images and the jar in the console)
>>>>>>>>>>>                       
>>>>>>>>>> Different classes being loaded by Netbeans than the console app.
>>>>>>>>>> Get
>>>>>>>>>> Netbeans to show you the full classpath it's using in it's
>>>>>>>>>> "%classpath"
>>>>>>>>>> variable
>>>>>>>>>>                     
>>>>>>>>>>> also i tried the
>>>>>>>>>>> imageIO.getImageReadersBySuffix but i cant interpretate the data
>>>>>>>>>>> y.y,
>>>>>>>>>>> its
>>>>>>>>>>> that or always its true in the boolean variable, and how can i
>>>>>>>>>>> register
>>>>>>>>>>> the
>>>>>>>>>>> handler??
>>>>>>>>>>>                       
>>>>>>>>>> Talk to IIORegistry, some thing like
>>>>>>>>>>
>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>> CLibJPEGImageReaderSpi());
>>>>>>>>>>
>>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>>> CLibJPEGImageWriterSpi());
>>>>>>>>>> Note: those are not necessarily the services you have in your
>>>>>>>>>> setup.
>>>>>>>>>>                     
>>>>>>>>>>> Thanks
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>                       
>>>>>>>>>>>> See the javadoc on IIORegistry. With ImageIO you may have to
>>>>>>>>>>>> register
>>>>>>>>>>>> your handler(s). What does ImageIO.getImageReadersBySuffix()
>>>>>>>>>>>> give
>>>>>>>>>>>> you.
>>>>>>>>>>>>
>>>>>>>>>>>> For certain jpegs we don't use ImageIO, rather the classes in
>>>>>>>>>>>> com.sun.image.codec.jpeg:
>>>>>>>>>>>>               try {
>>>>>>>>>>>>                   FileOutputStream fos = new
>>>>>>>>>>>> FileOutputStream(file);
>>>>>>>>>>>>                   JPEGImageEncoder encoder =
>>>>>>>>>>>> JPEGCodec.createJPEGEncoder(fos);
>>>>>>>>>>>>                   JPEGEncodeParam param =
>>>>>>>>>>>> encoder.getDefaultJPEGEncodeParam(image.getRaster(),
>>>>>>>>>>>> JPEGDecodeParam.COLOR_ID_CMYK);
>>>>>>>>>>>>                   param.setQuality(1, false);
>>>>>>>>>>>>                   encoder.encode(image.getRaster(), param);
>>>>>>>>>>>>                   fos.close();
>>>>>>>>>>>>               } catch (Throwable t) {
>>>>>>>>>>>>                   logger.debug(t.getMessage());
>>>>>>>>>>>>               }
>>>>>>>>>>>> But generally we use ImageIO
>>>>>>>>>>>>
>>>>>>>>>>>> On 06/06/2011 08:29 AM, Oscar.Flores wrote:
>>>>>>>>>>>>                         
>>>>>>>>>>>>> Yeah i think i need your help again i tried tu run the .jar
>>>>>>>>>>>>> file
>>>>>>>>>>>>> in
>>>>>>>>>>>>> the
>>>>>>>>>>>>> console it work but without images this it what appears
>>>>>>>>>>>>>
>>>>>>>>>>>>> GRAVE: Error while processing image: I:\cfd\rfc.jpg
>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException: Cannot load
>>>>>>>>>>>>> image
>>>>>>>>>>>>> (no
>>>>>>>>>>>>> suitable loader/converter combination available) for
>>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>>
>>>>>>>>>>>>> i tried  download the jai-imagio add to the class path but it
>>>>>>>>>>>>> dont
>>>>>>>>>>>>> work
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>                           
>>>>>>>>>>>>>> Very odd.  I'm having no problems getting images into pdfs
>>>>>>>>>>>>>> using
>>>>>>>>>>>>>> fop-1.0.
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> On 06/03/2011 11:04 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>                             
>>>>>>>>>>>>>>> aaa hey thanks for the help the other day, i resolve the
>>>>>>>>>>>>>>> problem
>>>>>>>>>>>>>>> changing
>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>> version of FOP for the 0.95beta instead of the 1.0, it works
>>>>>>>>>>>>>>> now
>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>> prints
>>>>>>>>>>>>>>> the image and its good, thanks and we are in touch if
>>>>>>>>>>>>>>> anything
>>>>>>>>>>>>>>> else
>>>>>>>>>>>>>>> fails
>>>>>>>>>>>>>>> jejeje
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>>                               
>>>>>>>>>>>>>>>> Nothing in the log from the transformer?
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> On 06/03/2011 09:47 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>>                                 
>>>>>>>>>>>>>>>>> hi there i have another problem i hope you can help me the
>>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>> create
>>>>>>>>>>>>>>>>> with foe has no image, it dont show any of them, the xsl
>>>>>>>>>>>>>>>>> seems
>>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>>> be
>>>>>>>>>>>>>>>>> rigth i
>>>>>>>>>>>>>>>>> tested with EditX and the pdf show me the image, what can
>>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>>> be,
>>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>>> xmlgraphics-commons-1.5svn, fop 1.0, fop-pdf-images 2.0.1
>>>>>>>>>>>>>>>>> Snapshot
>>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>> render of the image but it don work please help!!!  :,(
>>>>>>>>>>>>>>>>>                                   
>>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>                                 
>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>                             
>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>                         
>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>                     
>>>>>>>>> :-):confused::confused::confused::confused:=)
>>>>>>>>>                   
>>>>>>>> ---------------------------------------------------------------------
>>>>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>> For additional commands, e-mail:
>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>                 
>>>> ---------------------------------------------------------------------
>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>>
>>>>
>>>>
>>>>         
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>
>>
>>
>>     
> http://old.nabble.com/file/p31822059/libraries.jpeg 
> http://old.nabble.com/file/p31822059/libraries.bmp libraries.bmp 
>   

---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Problems with FOP and image

Posted by "Oscar.Flores" <fa...@hotmail.com>.
You where absolutly rigth i miss a few libraries to add into the jar file, i
modified the build.xml to add the package and jar that i need, now the error
message is not there but still the images dont show in the pdf i remeber
that i do something in netbeans so they can add to the pdf but i cant
remeber i dont now if there is still a library that is missing or i am
adding more than it should be 
This is what i use :
cfdi-base-0.1.6-SNAPSHOT.jar 
guava-r09.jar
guava-r09-gwt.jar
jaxb-impl-2.1.10.jar
avalon-framework-api-4.3.jar
avalon-framework-cvs-20020806.jar
avalon-logkit-2.1.jar
not-yet-commons-ssl-0.3.11.jar
commons-codec-1.5.jar
commons-codec-1.5-sources.jar
log4j-1.2.16.jar
fop.jar
jdom.jar
xmlgraphics-commons-1.4.jar
commons-io-1.3.1.jar
fop-pdf-images-2.0.1.SNAPSHOT.jar
pdfbox-app-1.5.0.jar
fontbox-1.3.1.jar
jempbox-1.3.1.jar
xercesImpl-2.7.1.jar
batik-all-1.7.jar
xml-apis-1.3.04.jar
xml-apis-ext-1.3.04.jar
 avalon-framework-4.2.0.jar
 xalan-2.7.0.jar
 serializer-2.7.0.jar
 commons-logging-1.0.4.jar
 jai_codec.jar
 jai_core.jar     
 batik-ext.jar
 jai_imageio-1.1-sources.jar

Thanks Rob for the help
  

Rob Sargent-4 wrote:
> 
> I suspect running from your jar does not have/use the same classpath 
> that is in effect while you're in the debugger.
> By what mechanism do you generate the jar?
> Is it an executable jar or are you running java -classpath 
> <your-jar-here:other-jars> Main?
> Make your IDE (netbeans) display the classpath  it uses to run your app 
> and compare that with the above.
> 
> On 06/09/2011 07:21 PM, Oscar.Flores wrote:
>> aaa ok well my problem is that when i do the pdf in netbean the pdf is
>> fine
>> with images and evething but when i run the jar file in command it give
>> me a
>> error
>>
>> GRAVE: Error while processing image: I:\cfd\rfc.jpg (image/jpeg)
>>   org.apache.xmlgraphics.image.loader.ImageException: Cannot load
>>   image (no suitable loader/converter combination available) for
>> I:\cfd\rfc.jpg
>>   (image/jpeg)
>>
>> so i dont no what its not working and if i have to add something to my
>> code
>> so the images can load i am soooo desperate what i am doing wrong??
>> i am sorry for the trouble and if a dont explain my self very good jejeje
>>
>>
>> Rob Sargent-4 wrote:
>>> Not at all sure what your problem is.  All I can do is show you what
>>> works for us.
>>>
>>> Our source xml looks like this:
>>> <image image-id="381623861" reference-id="ref-220" width="750"
>>> height="750" image-space-id="space-1" position="5"
>>>                image-pool-position="31" pos="4"
>>>                file="ref_10_1002108221">  <!-- an actual file (.jpeg
>>> copied the working directory of the transformer -->
>>> <fields />
>>> <caption />
>>> <annotations>
>>> <arrow_positions origHeight="750" origWidth="750" />
>>> </annotations>
>>> </image>
>>>
>>> Our xslt looks like this for each image needed.
>>>
>>> <xsl:template name="image">
>>> <xsl:param name="img"/>  <!-- This is the xml node from the source xml
>>> above -->
>>> <xsl:param name="width"/>
>>> <xsl:param name="height" select="$width"/>
>>> <xsl:param name="ignoreHeight">false</xsl:param>
>>> <fo:block>
>>> <fo:external-graphic src="{$img/@file}" height="{$height}"
>>> width="{$width}" content-height="scale-to-fit"
>>>                                    content-width="scale-to-fit"
>>> border="0.5pt solid black" border-collapse="separate">
>>> <xsl:if test="$ignoreHeight != 'true'">
>>> <xsl:attribute name="height">
>>> <xsl:value-of select="$height"/>
>>> </xsl:attribute>
>>> </xsl:if>
>>> </fo:external-graphic>
>>> </fo:block>
>>> </xsl:template>
>>>
>>> Our generated fo looks like this:
>>> <fo:table-cell>
>>> <fo:block>
>>> <fo:external-graphic border-collapse="separate" border="0.5pt solid
>>> black" content-width="scale-to-fit" content-height="scale-to-fit"
>>> width="2.5in" height="2.5in" src="ref_10_1002108221" />
>>> </fo:block>
>>> </fo:table-cell>
>>>
>>> And the generated pdfs include the image and are shipped to the printer.
>>>
>>> How does this stack up with what you have?
>>>
>>>
>>> On 06/09/2011 01:19 PM, Oscar.Flores wrote:
>>>> Hi there well i still got the problem but searching IN INTERNET i find
>>>> a
>>>> JPEG
>>>> renderer output for FOP its here
>>>>
>>>> http://marc.info/?l=fop-user&m=125986752706366&w=2
>>>>
>>>> the cuestion is can i render the image that i want to put in the pdf,
>>>> and
>>>> then add to the xsl the render jpeg it will work??
>>>>
>>>> and here explaints how use the render when he say uses fop as normal
>>>> case
>>>> what does it mean
>>>> what else have to add to the code?? i hope you can help me
>>>>
>>>> Thanks!!
>>>>
>>>> // OutputStream out = what you want
>>>>               FopFactory fopFactory = FopFactory.newInstance();
>>>>               RendererFactory rendererFactory = null;
>>>>               FOUserAgent foUserAgent = null;
>>>>
>>>>               rendererFactory = fopFactory.getRendererFactory();
>>>>               rendererFactory.addRendererMaker(new
>>>> MultiRendererMaker("jpeg"));
>>>>               foUserAgent = fopFactory.newFOUserAgent();
>>>>               rendererFactory.createRenderer(foUserAgent,
>>>> "image/jpeg");
>>>>
>>>>               Fop fop = fopFactory.newFop("image/jpeg", foUserAgent,
>>>> out);
>>>>
>>>> //Use fop as normal case
>>>>
>>>>
>>>> Rob Sargent-4 wrote:
>>>>> Since you're now into xmlgraphics, I think you're best bet is here
>>>>> <http://xmlgraphics.apache.org/commons/image-loader.html>
>>>>>
>>>>> On 06/07/2011 10:18 AM, Oscar.Flores wrote:
>>>>>> Hi ok this is for generate images that dont need to be decompress
>>>>>> later??
>>>>>> and
>>>>>> the result image i put in my xsl ?? then it should work, aaa i change
>>>>>> to
>>>>>> fop
>>>>>> 1.0 and xml communs 1.4 and its the same jejeje   dont find the image
>>>>>> preload
>>>>>>
>>>>>> org.apache.fop.fo.flow.ExternalGraphic bind
>>>>>> SEVERE: Image not available: The file format is not supported. No
>>>>>> ImagePreloader for *.jpg or *.bmp
>>>>>>
>>>>>>
>>>>>> Rob Sargent-4 wrote:
>>>>>>> ImageIO.write(bufferedImage, "JPEG", file);
>>>>>>>
>>>>>>> On 06/07/2011 08:21 AM, Oscar.Flores wrote:
>>>>>>>> Ok i actually register the handler now what i have to do is setup
>>>>>>>> this
>>>>>>>> handler or not?? and how can i do that, also it seem that the bmp
>>>>>>>> its
>>>>>>>> not
>>>>>>>> recognice also what can i do?? thanks for the help rob
>>>>>>>> also i am trying to convert the images to see if it that helps
>>>>>>>>
>>>>>>>>
>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>> On 06/06/2011 02:29 PM, Oscar.Flores wrote:
>>>>>>>>>> Hi what can be the difference between execute the program in
>>>>>>>>>> netbeans
>>>>>>>>>> (where
>>>>>>>>>> it works and print the images and the jar in the console)
>>>>>>>>> Different classes being loaded by Netbeans than the console app.
>>>>>>>>> Get
>>>>>>>>> Netbeans to show you the full classpath it's using in it's
>>>>>>>>> "%classpath"
>>>>>>>>> variable
>>>>>>>>>> also i tried the
>>>>>>>>>> imageIO.getImageReadersBySuffix but i cant interpretate the data
>>>>>>>>>> y.y,
>>>>>>>>>> its
>>>>>>>>>> that or always its true in the boolean variable, and how can i
>>>>>>>>>> register
>>>>>>>>>> the
>>>>>>>>>> handler??
>>>>>>>>> Talk to IIORegistry, some thing like
>>>>>>>>>
>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>> CLibJPEGImageReaderSpi());
>>>>>>>>>
>>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>>> CLibJPEGImageWriterSpi());
>>>>>>>>> Note: those are not necessarily the services you have in your
>>>>>>>>> setup.
>>>>>>>>>> Thanks
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>> See the javadoc on IIORegistry. With ImageIO you may have to
>>>>>>>>>>> register
>>>>>>>>>>> your handler(s). What does ImageIO.getImageReadersBySuffix()
>>>>>>>>>>> give
>>>>>>>>>>> you.
>>>>>>>>>>>
>>>>>>>>>>> For certain jpegs we don't use ImageIO, rather the classes in
>>>>>>>>>>> com.sun.image.codec.jpeg:
>>>>>>>>>>>               try {
>>>>>>>>>>>                   FileOutputStream fos = new
>>>>>>>>>>> FileOutputStream(file);
>>>>>>>>>>>                   JPEGImageEncoder encoder =
>>>>>>>>>>> JPEGCodec.createJPEGEncoder(fos);
>>>>>>>>>>>                   JPEGEncodeParam param =
>>>>>>>>>>> encoder.getDefaultJPEGEncodeParam(image.getRaster(),
>>>>>>>>>>> JPEGDecodeParam.COLOR_ID_CMYK);
>>>>>>>>>>>                   param.setQuality(1, false);
>>>>>>>>>>>                   encoder.encode(image.getRaster(), param);
>>>>>>>>>>>                   fos.close();
>>>>>>>>>>>               } catch (Throwable t) {
>>>>>>>>>>>                   logger.debug(t.getMessage());
>>>>>>>>>>>               }
>>>>>>>>>>> But generally we use ImageIO
>>>>>>>>>>>
>>>>>>>>>>> On 06/06/2011 08:29 AM, Oscar.Flores wrote:
>>>>>>>>>>>> Yeah i think i need your help again i tried tu run the .jar
>>>>>>>>>>>> file
>>>>>>>>>>>> in
>>>>>>>>>>>> the
>>>>>>>>>>>> console it work but without images this it what appears
>>>>>>>>>>>>
>>>>>>>>>>>> GRAVE: Error while processing image: I:\cfd\rfc.jpg
>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException: Cannot load
>>>>>>>>>>>> image
>>>>>>>>>>>> (no
>>>>>>>>>>>> suitable loader/converter combination available) for
>>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>>
>>>>>>>>>>>> i tried  download the jai-imagio add to the class path but it
>>>>>>>>>>>> dont
>>>>>>>>>>>> work
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>> Very odd.  I'm having no problems getting images into pdfs
>>>>>>>>>>>>> using
>>>>>>>>>>>>> fop-1.0.
>>>>>>>>>>>>>
>>>>>>>>>>>>> On 06/03/2011 11:04 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>> aaa hey thanks for the help the other day, i resolve the
>>>>>>>>>>>>>> problem
>>>>>>>>>>>>>> changing
>>>>>>>>>>>>>> the
>>>>>>>>>>>>>> version of FOP for the 0.95beta instead of the 1.0, it works
>>>>>>>>>>>>>> now
>>>>>>>>>>>>>> it
>>>>>>>>>>>>>> prints
>>>>>>>>>>>>>> the image and its good, thanks and we are in touch if
>>>>>>>>>>>>>> anything
>>>>>>>>>>>>>> else
>>>>>>>>>>>>>> fails
>>>>>>>>>>>>>> jejeje
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>>> Nothing in the log from the transformer?
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> On 06/03/2011 09:47 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>>> hi there i have another problem i hope you can help me the
>>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>> create
>>>>>>>>>>>>>>>> with foe has no image, it dont show any of them, the xsl
>>>>>>>>>>>>>>>> seems
>>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>>> be
>>>>>>>>>>>>>>>> rigth i
>>>>>>>>>>>>>>>> tested with EditX and the pdf show me the image, what can
>>>>>>>>>>>>>>>> it
>>>>>>>>>>>>>>>> be,
>>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>>> xmlgraphics-commons-1.5svn, fop 1.0, fop-pdf-images 2.0.1
>>>>>>>>>>>>>>>> Snapshot
>>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>> render of the image but it don work please help!!!  :,(
>>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>> For additional commands, e-mail:
>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>> :-):confused::confused::confused::confused:=)
>>>>>>> ---------------------------------------------------------------------
>>>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>> For additional commands, e-mail:
>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>
>>>>>>>
>>>>>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>
>>>
>>>
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
> 
> 
> 
http://old.nabble.com/file/p31822059/libraries.jpeg 
http://old.nabble.com/file/p31822059/libraries.bmp libraries.bmp 
-- 
View this message in context: http://old.nabble.com/Problems-with-FOP-and-image-tp31766430p31822059.html
Sent from the FOP - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Problems with FOP and image

Posted by Rob Sargent <rs...@xmission.com>.
I suspect running from your jar does not have/use the same classpath 
that is in effect while you're in the debugger.
By what mechanism do you generate the jar?
Is it an executable jar or are you running java -classpath 
<your-jar-here:other-jars> Main?
Make your IDE (netbeans) display the classpath  it uses to run your app 
and compare that with the above.

On 06/09/2011 07:21 PM, Oscar.Flores wrote:
> aaa ok well my problem is that when i do the pdf in netbean the pdf is fine
> with images and evething but when i run the jar file in command it give me a
> error
>
> GRAVE: Error while processing image: I:\cfd\rfc.jpg (image/jpeg)
>   org.apache.xmlgraphics.image.loader.ImageException: Cannot load
>   image (no suitable loader/converter combination available) for
> I:\cfd\rfc.jpg
>   (image/jpeg)
>
> so i dont no what its not working and if i have to add something to my code
> so the images can load i am soooo desperate what i am doing wrong??
> i am sorry for the trouble and if a dont explain my self very good jejeje
>
>
> Rob Sargent-4 wrote:
>> Not at all sure what your problem is.  All I can do is show you what
>> works for us.
>>
>> Our source xml looks like this:
>> <image image-id="381623861" reference-id="ref-220" width="750"
>> height="750" image-space-id="space-1" position="5"
>>                image-pool-position="31" pos="4"
>>                file="ref_10_1002108221">  <!-- an actual file (.jpeg
>> copied the working directory of the transformer -->
>> <fields />
>> <caption />
>> <annotations>
>> <arrow_positions origHeight="750" origWidth="750" />
>> </annotations>
>> </image>
>>
>> Our xslt looks like this for each image needed.
>>
>> <xsl:template name="image">
>> <xsl:param name="img"/>  <!-- This is the xml node from the source xml
>> above -->
>> <xsl:param name="width"/>
>> <xsl:param name="height" select="$width"/>
>> <xsl:param name="ignoreHeight">false</xsl:param>
>> <fo:block>
>> <fo:external-graphic src="{$img/@file}" height="{$height}"
>> width="{$width}" content-height="scale-to-fit"
>>                                    content-width="scale-to-fit"
>> border="0.5pt solid black" border-collapse="separate">
>> <xsl:if test="$ignoreHeight != 'true'">
>> <xsl:attribute name="height">
>> <xsl:value-of select="$height"/>
>> </xsl:attribute>
>> </xsl:if>
>> </fo:external-graphic>
>> </fo:block>
>> </xsl:template>
>>
>> Our generated fo looks like this:
>> <fo:table-cell>
>> <fo:block>
>> <fo:external-graphic border-collapse="separate" border="0.5pt solid
>> black" content-width="scale-to-fit" content-height="scale-to-fit"
>> width="2.5in" height="2.5in" src="ref_10_1002108221" />
>> </fo:block>
>> </fo:table-cell>
>>
>> And the generated pdfs include the image and are shipped to the printer.
>>
>> How does this stack up with what you have?
>>
>>
>> On 06/09/2011 01:19 PM, Oscar.Flores wrote:
>>> Hi there well i still got the problem but searching IN INTERNET i find a
>>> JPEG
>>> renderer output for FOP its here
>>>
>>> http://marc.info/?l=fop-user&m=125986752706366&w=2
>>>
>>> the cuestion is can i render the image that i want to put in the pdf, and
>>> then add to the xsl the render jpeg it will work??
>>>
>>> and here explaints how use the render when he say uses fop as normal case
>>> what does it mean
>>> what else have to add to the code?? i hope you can help me
>>>
>>> Thanks!!
>>>
>>> // OutputStream out = what you want
>>>               FopFactory fopFactory = FopFactory.newInstance();
>>>               RendererFactory rendererFactory = null;
>>>               FOUserAgent foUserAgent = null;
>>>
>>>               rendererFactory = fopFactory.getRendererFactory();
>>>               rendererFactory.addRendererMaker(new
>>> MultiRendererMaker("jpeg"));
>>>               foUserAgent = fopFactory.newFOUserAgent();
>>>               rendererFactory.createRenderer(foUserAgent, "image/jpeg");
>>>
>>>               Fop fop = fopFactory.newFop("image/jpeg", foUserAgent, out);
>>>
>>> //Use fop as normal case
>>>
>>>
>>> Rob Sargent-4 wrote:
>>>> Since you're now into xmlgraphics, I think you're best bet is here
>>>> <http://xmlgraphics.apache.org/commons/image-loader.html>
>>>>
>>>> On 06/07/2011 10:18 AM, Oscar.Flores wrote:
>>>>> Hi ok this is for generate images that dont need to be decompress
>>>>> later??
>>>>> and
>>>>> the result image i put in my xsl ?? then it should work, aaa i change
>>>>> to
>>>>> fop
>>>>> 1.0 and xml communs 1.4 and its the same jejeje   dont find the image
>>>>> preload
>>>>>
>>>>> org.apache.fop.fo.flow.ExternalGraphic bind
>>>>> SEVERE: Image not available: The file format is not supported. No
>>>>> ImagePreloader for *.jpg or *.bmp
>>>>>
>>>>>
>>>>> Rob Sargent-4 wrote:
>>>>>> ImageIO.write(bufferedImage, "JPEG", file);
>>>>>>
>>>>>> On 06/07/2011 08:21 AM, Oscar.Flores wrote:
>>>>>>> Ok i actually register the handler now what i have to do is setup
>>>>>>> this
>>>>>>> handler or not?? and how can i do that, also it seem that the bmp its
>>>>>>> not
>>>>>>> recognice also what can i do?? thanks for the help rob
>>>>>>> also i am trying to convert the images to see if it that helps
>>>>>>>
>>>>>>>
>>>>>>> Rob Sargent-4 wrote:
>>>>>>>> On 06/06/2011 02:29 PM, Oscar.Flores wrote:
>>>>>>>>> Hi what can be the difference between execute the program in
>>>>>>>>> netbeans
>>>>>>>>> (where
>>>>>>>>> it works and print the images and the jar in the console)
>>>>>>>> Different classes being loaded by Netbeans than the console app.
>>>>>>>> Get
>>>>>>>> Netbeans to show you the full classpath it's using in it's
>>>>>>>> "%classpath"
>>>>>>>> variable
>>>>>>>>> also i tried the
>>>>>>>>> imageIO.getImageReadersBySuffix but i cant interpretate the data
>>>>>>>>> y.y,
>>>>>>>>> its
>>>>>>>>> that or always its true in the boolean variable, and how can i
>>>>>>>>> register
>>>>>>>>> the
>>>>>>>>> handler??
>>>>>>>> Talk to IIORegistry, some thing like
>>>>>>>>
>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>> CLibJPEGImageReaderSpi());
>>>>>>>>
>>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>>> CLibJPEGImageWriterSpi());
>>>>>>>> Note: those are not necessarily the services you have in your setup.
>>>>>>>>> Thanks
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>> See the javadoc on IIORegistry. With ImageIO you may have to
>>>>>>>>>> register
>>>>>>>>>> your handler(s). What does ImageIO.getImageReadersBySuffix() give
>>>>>>>>>> you.
>>>>>>>>>>
>>>>>>>>>> For certain jpegs we don't use ImageIO, rather the classes in
>>>>>>>>>> com.sun.image.codec.jpeg:
>>>>>>>>>>               try {
>>>>>>>>>>                   FileOutputStream fos = new
>>>>>>>>>> FileOutputStream(file);
>>>>>>>>>>                   JPEGImageEncoder encoder =
>>>>>>>>>> JPEGCodec.createJPEGEncoder(fos);
>>>>>>>>>>                   JPEGEncodeParam param =
>>>>>>>>>> encoder.getDefaultJPEGEncodeParam(image.getRaster(),
>>>>>>>>>> JPEGDecodeParam.COLOR_ID_CMYK);
>>>>>>>>>>                   param.setQuality(1, false);
>>>>>>>>>>                   encoder.encode(image.getRaster(), param);
>>>>>>>>>>                   fos.close();
>>>>>>>>>>               } catch (Throwable t) {
>>>>>>>>>>                   logger.debug(t.getMessage());
>>>>>>>>>>               }
>>>>>>>>>> But generally we use ImageIO
>>>>>>>>>>
>>>>>>>>>> On 06/06/2011 08:29 AM, Oscar.Flores wrote:
>>>>>>>>>>> Yeah i think i need your help again i tried tu run the .jar file
>>>>>>>>>>> in
>>>>>>>>>>> the
>>>>>>>>>>> console it work but without images this it what appears
>>>>>>>>>>>
>>>>>>>>>>> GRAVE: Error while processing image: I:\cfd\rfc.jpg (image/jpeg)
>>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException: Cannot load
>>>>>>>>>>> image
>>>>>>>>>>> (no
>>>>>>>>>>> suitable loader/converter combination available) for
>>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>>> (image/jpeg)
>>>>>>>>>>>
>>>>>>>>>>> i tried  download the jai-imagio add to the class path but it
>>>>>>>>>>> dont
>>>>>>>>>>> work
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>> Very odd.  I'm having no problems getting images into pdfs using
>>>>>>>>>>>> fop-1.0.
>>>>>>>>>>>>
>>>>>>>>>>>> On 06/03/2011 11:04 AM, Oscar.Flores wrote:
>>>>>>>>>>>>> aaa hey thanks for the help the other day, i resolve the
>>>>>>>>>>>>> problem
>>>>>>>>>>>>> changing
>>>>>>>>>>>>> the
>>>>>>>>>>>>> version of FOP for the 0.95beta instead of the 1.0, it works
>>>>>>>>>>>>> now
>>>>>>>>>>>>> it
>>>>>>>>>>>>> prints
>>>>>>>>>>>>> the image and its good, thanks and we are in touch if anything
>>>>>>>>>>>>> else
>>>>>>>>>>>>> fails
>>>>>>>>>>>>> jejeje
>>>>>>>>>>>>>
>>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>>> Nothing in the log from the transformer?
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> On 06/03/2011 09:47 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>>> hi there i have another problem i hope you can help me the
>>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>>> that
>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>> create
>>>>>>>>>>>>>>> with foe has no image, it dont show any of them, the xsl
>>>>>>>>>>>>>>> seems
>>>>>>>>>>>>>>> to
>>>>>>>>>>>>>>> be
>>>>>>>>>>>>>>> rigth i
>>>>>>>>>>>>>>> tested with EditX and the pdf show me the image, what can it
>>>>>>>>>>>>>>> be,
>>>>>>>>>>>>>>> i
>>>>>>>>>>>>>>> have
>>>>>>>>>>>>>>> xmlgraphics-commons-1.5svn, fop 1.0, fop-pdf-images 2.0.1
>>>>>>>>>>>>>>> Snapshot
>>>>>>>>>>>>>>> for
>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>> render of the image but it don work please help!!!  :,(
>>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>> ---------------------------------------------------------------------
>>>>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>> For additional commands, e-mail:
>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>> :-):confused::confused::confused::confused:=)
>>>>>> ---------------------------------------------------------------------
>>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>>>>
>>>>>>
>>>>>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>
>>
>>

---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Problems with FOP and image

Posted by "Oscar.Flores" <fa...@hotmail.com>.
aaa ok well my problem is that when i do the pdf in netbean the pdf is fine
with images and evething but when i run the jar file in command it give me a
error 

GRAVE: Error while processing image: I:\cfd\rfc.jpg (image/jpeg)
 org.apache.xmlgraphics.image.loader.ImageException: Cannot load
 image (no suitable loader/converter combination available) for
I:\cfd\rfc.jpg
 (image/jpeg) 

so i dont no what its not working and if i have to add something to my code
so the images can load i am soooo desperate what i am doing wrong?? 
i am sorry for the trouble and if a dont explain my self very good jejeje


Rob Sargent-4 wrote:
> 
> Not at all sure what your problem is.  All I can do is show you what 
> works for us.
> 
> Our source xml looks like this:
> <image image-id="381623861" reference-id="ref-220" width="750" 
> height="750" image-space-id="space-1" position="5"
>               image-pool-position="31" pos="4"
>               file="ref_10_1002108221"> <!-- an actual file (.jpeg 
> copied the working directory of the transformer -->
> <fields />
> <caption />
> <annotations>
> <arrow_positions origHeight="750" origWidth="750" />
> </annotations>
> </image>
> 
> Our xslt looks like this for each image needed.
> 
> <xsl:template name="image">
> <xsl:param name="img"/> <!-- This is the xml node from the source xml 
> above -->
> <xsl:param name="width"/>
> <xsl:param name="height" select="$width"/>
> <xsl:param name="ignoreHeight">false</xsl:param>
> <fo:block>
> <fo:external-graphic src="{$img/@file}" height="{$height}" 
> width="{$width}" content-height="scale-to-fit"
>                                   content-width="scale-to-fit" 
> border="0.5pt solid black" border-collapse="separate">
> <xsl:if test="$ignoreHeight != 'true'">
> <xsl:attribute name="height">
> <xsl:value-of select="$height"/>
> </xsl:attribute>
> </xsl:if>
> </fo:external-graphic>
> </fo:block>
> </xsl:template>
> 
> Our generated fo looks like this:
> <fo:table-cell>
> <fo:block>
> <fo:external-graphic border-collapse="separate" border="0.5pt solid 
> black" content-width="scale-to-fit" content-height="scale-to-fit" 
> width="2.5in" height="2.5in" src="ref_10_1002108221" />
> </fo:block>
> </fo:table-cell>
> 
> And the generated pdfs include the image and are shipped to the printer.
> 
> How does this stack up with what you have?
> 
> 
> On 06/09/2011 01:19 PM, Oscar.Flores wrote:
>> Hi there well i still got the problem but searching IN INTERNET i find a
>> JPEG
>> renderer output for FOP its here
>>
>> http://marc.info/?l=fop-user&m=125986752706366&w=2
>>
>> the cuestion is can i render the image that i want to put in the pdf, and
>> then add to the xsl the render jpeg it will work??
>>
>> and here explaints how use the render when he say uses fop as normal case
>> what does it mean
>> what else have to add to the code?? i hope you can help me
>>
>> Thanks!!
>>
>> // OutputStream out = what you want
>>              FopFactory fopFactory = FopFactory.newInstance();
>>              RendererFactory rendererFactory = null;
>>              FOUserAgent foUserAgent = null;
>>
>>              rendererFactory = fopFactory.getRendererFactory();
>>              rendererFactory.addRendererMaker(new
>> MultiRendererMaker("jpeg"));
>>              foUserAgent = fopFactory.newFOUserAgent();
>>              rendererFactory.createRenderer(foUserAgent, "image/jpeg");
>>
>>              Fop fop = fopFactory.newFop("image/jpeg", foUserAgent, out);
>>
>> //Use fop as normal case
>>
>>
>> Rob Sargent-4 wrote:
>>> Since you're now into xmlgraphics, I think you're best bet is here
>>> <http://xmlgraphics.apache.org/commons/image-loader.html>
>>>
>>> On 06/07/2011 10:18 AM, Oscar.Flores wrote:
>>>> Hi ok this is for generate images that dont need to be decompress
>>>> later??
>>>> and
>>>> the result image i put in my xsl ?? then it should work, aaa i change
>>>> to
>>>> fop
>>>> 1.0 and xml communs 1.4 and its the same jejeje   dont find the image
>>>> preload
>>>>
>>>> org.apache.fop.fo.flow.ExternalGraphic bind
>>>> SEVERE: Image not available: The file format is not supported. No
>>>> ImagePreloader for *.jpg or *.bmp
>>>>
>>>>
>>>> Rob Sargent-4 wrote:
>>>>> ImageIO.write(bufferedImage, "JPEG", file);
>>>>>
>>>>> On 06/07/2011 08:21 AM, Oscar.Flores wrote:
>>>>>> Ok i actually register the handler now what i have to do is setup
>>>>>> this
>>>>>> handler or not?? and how can i do that, also it seem that the bmp its
>>>>>> not
>>>>>> recognice also what can i do?? thanks for the help rob
>>>>>> also i am trying to convert the images to see if it that helps
>>>>>>
>>>>>>
>>>>>> Rob Sargent-4 wrote:
>>>>>>> On 06/06/2011 02:29 PM, Oscar.Flores wrote:
>>>>>>>> Hi what can be the difference between execute the program in
>>>>>>>> netbeans
>>>>>>>> (where
>>>>>>>> it works and print the images and the jar in the console)
>>>>>>> Different classes being loaded by Netbeans than the console app. 
>>>>>>> Get
>>>>>>> Netbeans to show you the full classpath it's using in it's
>>>>>>> "%classpath"
>>>>>>> variable
>>>>>>>> also i tried the
>>>>>>>> imageIO.getImageReadersBySuffix but i cant interpretate the data
>>>>>>>> y.y,
>>>>>>>> its
>>>>>>>> that or always its true in the boolean variable, and how can i
>>>>>>>> register
>>>>>>>> the
>>>>>>>> handler??
>>>>>>> Talk to IIORegistry, some thing like
>>>>>>>
>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>> CLibJPEGImageReaderSpi());
>>>>>>>
>>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>>> CLibJPEGImageWriterSpi());
>>>>>>> Note: those are not necessarily the services you have in your setup.
>>>>>>>> Thanks
>>>>>>>>
>>>>>>>>
>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>> See the javadoc on IIORegistry. With ImageIO you may have to
>>>>>>>>> register
>>>>>>>>> your handler(s). What does ImageIO.getImageReadersBySuffix() give
>>>>>>>>> you.
>>>>>>>>>
>>>>>>>>> For certain jpegs we don't use ImageIO, rather the classes in
>>>>>>>>> com.sun.image.codec.jpeg:
>>>>>>>>>              try {
>>>>>>>>>                  FileOutputStream fos = new
>>>>>>>>> FileOutputStream(file);
>>>>>>>>>                  JPEGImageEncoder encoder =
>>>>>>>>> JPEGCodec.createJPEGEncoder(fos);
>>>>>>>>>                  JPEGEncodeParam param =
>>>>>>>>> encoder.getDefaultJPEGEncodeParam(image.getRaster(),
>>>>>>>>> JPEGDecodeParam.COLOR_ID_CMYK);
>>>>>>>>>                  param.setQuality(1, false);
>>>>>>>>>                  encoder.encode(image.getRaster(), param);
>>>>>>>>>                  fos.close();
>>>>>>>>>              } catch (Throwable t) {
>>>>>>>>>                  logger.debug(t.getMessage());
>>>>>>>>>              }
>>>>>>>>> But generally we use ImageIO
>>>>>>>>>
>>>>>>>>> On 06/06/2011 08:29 AM, Oscar.Flores wrote:
>>>>>>>>>> Yeah i think i need your help again i tried tu run the .jar file
>>>>>>>>>> in
>>>>>>>>>> the
>>>>>>>>>> console it work but without images this it what appears
>>>>>>>>>>
>>>>>>>>>> GRAVE: Error while processing image: I:\cfd\rfc.jpg (image/jpeg)
>>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException: Cannot load
>>>>>>>>>> image
>>>>>>>>>> (no
>>>>>>>>>> suitable loader/converter combination available) for
>>>>>>>>>> I:\cfd\rfc.jpg
>>>>>>>>>> (image/jpeg)
>>>>>>>>>>
>>>>>>>>>> i tried  download the jai-imagio add to the class path but it
>>>>>>>>>> dont
>>>>>>>>>> work
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>> Very odd.  I'm having no problems getting images into pdfs using
>>>>>>>>>>> fop-1.0.
>>>>>>>>>>>
>>>>>>>>>>> On 06/03/2011 11:04 AM, Oscar.Flores wrote:
>>>>>>>>>>>> aaa hey thanks for the help the other day, i resolve the
>>>>>>>>>>>> problem
>>>>>>>>>>>> changing
>>>>>>>>>>>> the
>>>>>>>>>>>> version of FOP for the 0.95beta instead of the 1.0, it works
>>>>>>>>>>>> now
>>>>>>>>>>>> it
>>>>>>>>>>>> prints
>>>>>>>>>>>> the image and its good, thanks and we are in touch if anything
>>>>>>>>>>>> else
>>>>>>>>>>>> fails
>>>>>>>>>>>> jejeje
>>>>>>>>>>>>
>>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>>> Nothing in the log from the transformer?
>>>>>>>>>>>>>
>>>>>>>>>>>>> On 06/03/2011 09:47 AM, Oscar.Flores wrote:
>>>>>>>>>>>>>> hi there i have another problem i hope you can help me the
>>>>>>>>>>>>>> pdf
>>>>>>>>>>>>>> that
>>>>>>>>>>>>>> i
>>>>>>>>>>>>>> create
>>>>>>>>>>>>>> with foe has no image, it dont show any of them, the xsl
>>>>>>>>>>>>>> seems
>>>>>>>>>>>>>> to
>>>>>>>>>>>>>> be
>>>>>>>>>>>>>> rigth i
>>>>>>>>>>>>>> tested with EditX and the pdf show me the image, what can it
>>>>>>>>>>>>>> be,
>>>>>>>>>>>>>> i
>>>>>>>>>>>>>> have
>>>>>>>>>>>>>> xmlgraphics-commons-1.5svn, fop 1.0, fop-pdf-images 2.0.1
>>>>>>>>>>>>>> Snapshot
>>>>>>>>>>>>>> for
>>>>>>>>>>>>>> the
>>>>>>>>>>>>>> render of the image but it don work please help!!!  :,(
>>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>> For additional commands, e-mail:
>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>> ---------------------------------------------------------------------
>>>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>> For additional commands, e-mail:
>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>> :-):confused::confused::confused::confused:=)
>>>>> ---------------------------------------------------------------------
>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>>>
>>>>>
>>>>>
>>>
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
> 
> 
> 

-- 
View this message in context: http://old.nabble.com/Problems-with-FOP-and-image-tp31766430p31814587.html
Sent from the FOP - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Problems with FOP and image

Posted by Rob Sargent <rs...@xmission.com>.
Not at all sure what your problem is.  All I can do is show you what 
works for us.

Our source xml looks like this:
<image image-id="381623861" reference-id="ref-220" width="750" 
height="750" image-space-id="space-1" position="5"
              image-pool-position="31" pos="4"
              file="ref_10_1002108221"> <!-- an actual file (.jpeg 
copied the working directory of the transformer -->
<fields />
<caption />
<annotations>
<arrow_positions origHeight="750" origWidth="750" />
</annotations>
</image>

Our xslt looks like this for each image needed.

<xsl:template name="image">
<xsl:param name="img"/> <!-- This is the xml node from the source xml 
above -->
<xsl:param name="width"/>
<xsl:param name="height" select="$width"/>
<xsl:param name="ignoreHeight">false</xsl:param>
<fo:block>
<fo:external-graphic src="{$img/@file}" height="{$height}" 
width="{$width}" content-height="scale-to-fit"
                                  content-width="scale-to-fit" 
border="0.5pt solid black" border-collapse="separate">
<xsl:if test="$ignoreHeight != 'true'">
<xsl:attribute name="height">
<xsl:value-of select="$height"/>
</xsl:attribute>
</xsl:if>
</fo:external-graphic>
</fo:block>
</xsl:template>

Our generated fo looks like this:
<fo:table-cell>
<fo:block>
<fo:external-graphic border-collapse="separate" border="0.5pt solid 
black" content-width="scale-to-fit" content-height="scale-to-fit" 
width="2.5in" height="2.5in" src="ref_10_1002108221" />
</fo:block>
</fo:table-cell>

And the generated pdfs include the image and are shipped to the printer.

How does this stack up with what you have?


On 06/09/2011 01:19 PM, Oscar.Flores wrote:
> Hi there well i still got the problem but searching IN INTERNET i find a JPEG
> renderer output for FOP its here
>
> http://marc.info/?l=fop-user&m=125986752706366&w=2
>
> the cuestion is can i render the image that i want to put in the pdf, and
> then add to the xsl the render jpeg it will work??
>
> and here explaints how use the render when he say uses fop as normal case
> what does it mean
> what else have to add to the code?? i hope you can help me
>
> Thanks!!
>
> // OutputStream out = what you want
>              FopFactory fopFactory = FopFactory.newInstance();
>              RendererFactory rendererFactory = null;
>              FOUserAgent foUserAgent = null;
>
>              rendererFactory = fopFactory.getRendererFactory();
>              rendererFactory.addRendererMaker(new
> MultiRendererMaker("jpeg"));
>              foUserAgent = fopFactory.newFOUserAgent();
>              rendererFactory.createRenderer(foUserAgent, "image/jpeg");
>
>              Fop fop = fopFactory.newFop("image/jpeg", foUserAgent, out);
>
> //Use fop as normal case
>
>
> Rob Sargent-4 wrote:
>> Since you're now into xmlgraphics, I think you're best bet is here
>> <http://xmlgraphics.apache.org/commons/image-loader.html>
>>
>> On 06/07/2011 10:18 AM, Oscar.Flores wrote:
>>> Hi ok this is for generate images that dont need to be decompress later??
>>> and
>>> the result image i put in my xsl ?? then it should work, aaa i change to
>>> fop
>>> 1.0 and xml communs 1.4 and its the same jejeje   dont find the image
>>> preload
>>>
>>> org.apache.fop.fo.flow.ExternalGraphic bind
>>> SEVERE: Image not available: The file format is not supported. No
>>> ImagePreloader for *.jpg or *.bmp
>>>
>>>
>>> Rob Sargent-4 wrote:
>>>> ImageIO.write(bufferedImage, "JPEG", file);
>>>>
>>>> On 06/07/2011 08:21 AM, Oscar.Flores wrote:
>>>>> Ok i actually register the handler now what i have to do is setup this
>>>>> handler or not?? and how can i do that, also it seem that the bmp its
>>>>> not
>>>>> recognice also what can i do?? thanks for the help rob
>>>>> also i am trying to convert the images to see if it that helps
>>>>>
>>>>>
>>>>> Rob Sargent-4 wrote:
>>>>>> On 06/06/2011 02:29 PM, Oscar.Flores wrote:
>>>>>>> Hi what can be the difference between execute the program in netbeans
>>>>>>> (where
>>>>>>> it works and print the images and the jar in the console)
>>>>>> Different classes being loaded by Netbeans than the console app.  Get
>>>>>> Netbeans to show you the full classpath it's using in it's
>>>>>> "%classpath"
>>>>>> variable
>>>>>>> also i tried the
>>>>>>> imageIO.getImageReadersBySuffix but i cant interpretate the data y.y,
>>>>>>> its
>>>>>>> that or always its true in the boolean variable, and how can i
>>>>>>> register
>>>>>>> the
>>>>>>> handler??
>>>>>> Talk to IIORegistry, some thing like
>>>>>>
>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>> CLibJPEGImageReaderSpi());
>>>>>>
>>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>>> CLibJPEGImageWriterSpi());
>>>>>> Note: those are not necessarily the services you have in your setup.
>>>>>>> Thanks
>>>>>>>
>>>>>>>
>>>>>>> Rob Sargent-4 wrote:
>>>>>>>> See the javadoc on IIORegistry. With ImageIO you may have to
>>>>>>>> register
>>>>>>>> your handler(s). What does ImageIO.getImageReadersBySuffix() give
>>>>>>>> you.
>>>>>>>>
>>>>>>>> For certain jpegs we don't use ImageIO, rather the classes in
>>>>>>>> com.sun.image.codec.jpeg:
>>>>>>>>              try {
>>>>>>>>                  FileOutputStream fos = new FileOutputStream(file);
>>>>>>>>                  JPEGImageEncoder encoder =
>>>>>>>> JPEGCodec.createJPEGEncoder(fos);
>>>>>>>>                  JPEGEncodeParam param =
>>>>>>>> encoder.getDefaultJPEGEncodeParam(image.getRaster(),
>>>>>>>> JPEGDecodeParam.COLOR_ID_CMYK);
>>>>>>>>                  param.setQuality(1, false);
>>>>>>>>                  encoder.encode(image.getRaster(), param);
>>>>>>>>                  fos.close();
>>>>>>>>              } catch (Throwable t) {
>>>>>>>>                  logger.debug(t.getMessage());
>>>>>>>>              }
>>>>>>>> But generally we use ImageIO
>>>>>>>>
>>>>>>>> On 06/06/2011 08:29 AM, Oscar.Flores wrote:
>>>>>>>>> Yeah i think i need your help again i tried tu run the .jar file in
>>>>>>>>> the
>>>>>>>>> console it work but without images this it what appears
>>>>>>>>>
>>>>>>>>> GRAVE: Error while processing image: I:\cfd\rfc.jpg (image/jpeg)
>>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException: Cannot load
>>>>>>>>> image
>>>>>>>>> (no
>>>>>>>>> suitable loader/converter combination available) for I:\cfd\rfc.jpg
>>>>>>>>> (image/jpeg)
>>>>>>>>>
>>>>>>>>> i tried  download the jai-imagio add to the class path but it dont
>>>>>>>>> work
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>> Very odd.  I'm having no problems getting images into pdfs using
>>>>>>>>>> fop-1.0.
>>>>>>>>>>
>>>>>>>>>> On 06/03/2011 11:04 AM, Oscar.Flores wrote:
>>>>>>>>>>> aaa hey thanks for the help the other day, i resolve the problem
>>>>>>>>>>> changing
>>>>>>>>>>> the
>>>>>>>>>>> version of FOP for the 0.95beta instead of the 1.0, it works now
>>>>>>>>>>> it
>>>>>>>>>>> prints
>>>>>>>>>>> the image and its good, thanks and we are in touch if anything
>>>>>>>>>>> else
>>>>>>>>>>> fails
>>>>>>>>>>> jejeje
>>>>>>>>>>>
>>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>>> Nothing in the log from the transformer?
>>>>>>>>>>>>
>>>>>>>>>>>> On 06/03/2011 09:47 AM, Oscar.Flores wrote:
>>>>>>>>>>>>> hi there i have another problem i hope you can help me the pdf
>>>>>>>>>>>>> that
>>>>>>>>>>>>> i
>>>>>>>>>>>>> create
>>>>>>>>>>>>> with foe has no image, it dont show any of them, the xsl seems
>>>>>>>>>>>>> to
>>>>>>>>>>>>> be
>>>>>>>>>>>>> rigth i
>>>>>>>>>>>>> tested with EditX and the pdf show me the image, what can it
>>>>>>>>>>>>> be,
>>>>>>>>>>>>> i
>>>>>>>>>>>>> have
>>>>>>>>>>>>> xmlgraphics-commons-1.5svn, fop 1.0, fop-pdf-images 2.0.1
>>>>>>>>>>>>> Snapshot
>>>>>>>>>>>>> for
>>>>>>>>>>>>> the
>>>>>>>>>>>>> render of the image but it don work please help!!!  :,(
>>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>> ---------------------------------------------------------------------
>>>>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>> For additional commands, e-mail:
>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>> ---------------------------------------------------------------------
>>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>>>>
>>>>>>
>>>>>>
>>>>> :-):confused::confused::confused::confused:=)
>>>> ---------------------------------------------------------------------
>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>>
>>>>
>>>>
>>

---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Problems with FOP and image

Posted by "Oscar.Flores" <fa...@hotmail.com>.
Hi there well i still got the problem but searching IN INTERNET i find a JPEG
renderer output for FOP its here
 
http://marc.info/?l=fop-user&m=125986752706366&w=2

the cuestion is can i render the image that i want to put in the pdf, and
then add to the xsl the render jpeg it will work??

and here explaints how use the render when he say uses fop as normal case
what does it mean
what else have to add to the code?? i hope you can help me 

Thanks!!
 
// OutputStream out = what you want
            FopFactory fopFactory = FopFactory.newInstance();
            RendererFactory rendererFactory = null;
            FOUserAgent foUserAgent = null;

            rendererFactory = fopFactory.getRendererFactory();
            rendererFactory.addRendererMaker(new 
MultiRendererMaker("jpeg"));
            foUserAgent = fopFactory.newFOUserAgent();
            rendererFactory.createRenderer(foUserAgent, "image/jpeg");
   
            Fop fop = fopFactory.newFop("image/jpeg", foUserAgent, out);

//Use fop as normal case
   

Rob Sargent-4 wrote:
> 
> Since you're now into xmlgraphics, I think you're best bet is here 
> <http://xmlgraphics.apache.org/commons/image-loader.html>
> 
> On 06/07/2011 10:18 AM, Oscar.Flores wrote:
>> Hi ok this is for generate images that dont need to be decompress later??
>> and
>> the result image i put in my xsl ?? then it should work, aaa i change to
>> fop
>> 1.0 and xml communs 1.4 and its the same jejeje   dont find the image
>> preload
>>
>> org.apache.fop.fo.flow.ExternalGraphic bind
>> SEVERE: Image not available: The file format is not supported. No
>> ImagePreloader for *.jpg or *.bmp
>>
>>
>> Rob Sargent-4 wrote:
>>> ImageIO.write(bufferedImage, "JPEG", file);
>>>
>>> On 06/07/2011 08:21 AM, Oscar.Flores wrote:
>>>> Ok i actually register the handler now what i have to do is setup this
>>>> handler or not?? and how can i do that, also it seem that the bmp its
>>>> not
>>>> recognice also what can i do?? thanks for the help rob
>>>> also i am trying to convert the images to see if it that helps
>>>>
>>>>
>>>> Rob Sargent-4 wrote:
>>>>>
>>>>> On 06/06/2011 02:29 PM, Oscar.Flores wrote:
>>>>>> Hi what can be the difference between execute the program in netbeans
>>>>>> (where
>>>>>> it works and print the images and the jar in the console)
>>>>> Different classes being loaded by Netbeans than the console app.  Get
>>>>> Netbeans to show you the full classpath it's using in it's
>>>>> "%classpath"
>>>>> variable
>>>>>> also i tried the
>>>>>> imageIO.getImageReadersBySuffix but i cant interpretate the data y.y,
>>>>>> its
>>>>>> that or always its true in the boolean variable, and how can i
>>>>>> register
>>>>>> the
>>>>>> handler??
>>>>> Talk to IIORegistry, some thing like
>>>>>
>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>> CLibJPEGImageReaderSpi());
>>>>>
>>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>>> CLibJPEGImageWriterSpi());
>>>>> Note: those are not necessarily the services you have in your setup.
>>>>>> Thanks
>>>>>>
>>>>>>
>>>>>> Rob Sargent-4 wrote:
>>>>>>> See the javadoc on IIORegistry. With ImageIO you may have to
>>>>>>> register
>>>>>>> your handler(s). What does ImageIO.getImageReadersBySuffix() give
>>>>>>> you.
>>>>>>>
>>>>>>> For certain jpegs we don't use ImageIO, rather the classes in
>>>>>>> com.sun.image.codec.jpeg:
>>>>>>>             try {
>>>>>>>                 FileOutputStream fos = new FileOutputStream(file);
>>>>>>>                 JPEGImageEncoder encoder =
>>>>>>> JPEGCodec.createJPEGEncoder(fos);
>>>>>>>                 JPEGEncodeParam param =
>>>>>>> encoder.getDefaultJPEGEncodeParam(image.getRaster(),
>>>>>>> JPEGDecodeParam.COLOR_ID_CMYK);
>>>>>>>                 param.setQuality(1, false);
>>>>>>>                 encoder.encode(image.getRaster(), param);
>>>>>>>                 fos.close();
>>>>>>>             } catch (Throwable t) {
>>>>>>>                 logger.debug(t.getMessage());
>>>>>>>             }
>>>>>>> But generally we use ImageIO
>>>>>>>
>>>>>>> On 06/06/2011 08:29 AM, Oscar.Flores wrote:
>>>>>>>> Yeah i think i need your help again i tried tu run the .jar file in
>>>>>>>> the
>>>>>>>> console it work but without images this it what appears
>>>>>>>>
>>>>>>>> GRAVE: Error while processing image: I:\cfd\rfc.jpg (image/jpeg)
>>>>>>>> org.apache.xmlgraphics.image.loader.ImageException: Cannot load
>>>>>>>> image
>>>>>>>> (no
>>>>>>>> suitable loader/converter combination available) for I:\cfd\rfc.jpg
>>>>>>>> (image/jpeg)
>>>>>>>>
>>>>>>>> i tried  download the jai-imagio add to the class path but it dont
>>>>>>>> work
>>>>>>>>
>>>>>>>>
>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>> Very odd.  I'm having no problems getting images into pdfs using
>>>>>>>>> fop-1.0.
>>>>>>>>>
>>>>>>>>> On 06/03/2011 11:04 AM, Oscar.Flores wrote:
>>>>>>>>>> aaa hey thanks for the help the other day, i resolve the problem
>>>>>>>>>> changing
>>>>>>>>>> the
>>>>>>>>>> version of FOP for the 0.95beta instead of the 1.0, it works now
>>>>>>>>>> it
>>>>>>>>>> prints
>>>>>>>>>> the image and its good, thanks and we are in touch if anything
>>>>>>>>>> else
>>>>>>>>>> fails
>>>>>>>>>> jejeje
>>>>>>>>>>
>>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>>> Nothing in the log from the transformer?
>>>>>>>>>>>
>>>>>>>>>>> On 06/03/2011 09:47 AM, Oscar.Flores wrote:
>>>>>>>>>>>> hi there i have another problem i hope you can help me the pdf
>>>>>>>>>>>> that
>>>>>>>>>>>> i
>>>>>>>>>>>> create
>>>>>>>>>>>> with foe has no image, it dont show any of them, the xsl seems
>>>>>>>>>>>> to
>>>>>>>>>>>> be
>>>>>>>>>>>> rigth i
>>>>>>>>>>>> tested with EditX and the pdf show me the image, what can it
>>>>>>>>>>>> be,
>>>>>>>>>>>> i
>>>>>>>>>>>> have
>>>>>>>>>>>> xmlgraphics-commons-1.5svn, fop 1.0, fop-pdf-images 2.0.1
>>>>>>>>>>>> Snapshot
>>>>>>>>>>>> for
>>>>>>>>>>>> the
>>>>>>>>>>>> render of the image but it don work please help!!!  :,(
>>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>> For additional commands, e-mail:
>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>> ---------------------------------------------------------------------
>>>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>> For additional commands, e-mail:
>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>
>>>>>>>
>>>>>>>
>>>>> ---------------------------------------------------------------------
>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>>>
>>>>>
>>>>>
>>>> :-):confused::confused::confused::confused:=)
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>
>>>
>>>
> 
> 

-- 
View this message in context: http://old.nabble.com/Problems-with-FOP-and-image-tp31766430p31812683.html
Sent from the FOP - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Problems with FOP and image

Posted by Rob Sargent <rs...@xmission.com>.
Since you're now into xmlgraphics, I think you're best bet is here 
<http://xmlgraphics.apache.org/commons/image-loader.html>

On 06/07/2011 10:18 AM, Oscar.Flores wrote:
> Hi ok this is for generate images that dont need to be decompress later?? and
> the result image i put in my xsl ?? then it should work, aaa i change to fop
> 1.0 and xml communs 1.4 and its the same jejeje   dont find the image
> preload
>
> org.apache.fop.fo.flow.ExternalGraphic bind
> SEVERE: Image not available: The file format is not supported. No
> ImagePreloader for *.jpg or *.bmp
>
>
> Rob Sargent-4 wrote:
>> ImageIO.write(bufferedImage, "JPEG", file);
>>
>> On 06/07/2011 08:21 AM, Oscar.Flores wrote:
>>> Ok i actually register the handler now what i have to do is setup this
>>> handler or not?? and how can i do that, also it seem that the bmp its not
>>> recognice also what can i do?? thanks for the help rob
>>> also i am trying to convert the images to see if it that helps
>>>
>>>
>>> Rob Sargent-4 wrote:
>>>>
>>>> On 06/06/2011 02:29 PM, Oscar.Flores wrote:
>>>>> Hi what can be the difference between execute the program in netbeans
>>>>> (where
>>>>> it works and print the images and the jar in the console)
>>>> Different classes being loaded by Netbeans than the console app.  Get
>>>> Netbeans to show you the full classpath it's using in it's "%classpath"
>>>> variable
>>>>> also i tried the
>>>>> imageIO.getImageReadersBySuffix but i cant interpretate the data y.y,
>>>>> its
>>>>> that or always its true in the boolean variable, and how can i register
>>>>> the
>>>>> handler??
>>>> Talk to IIORegistry, some thing like
>>>>
>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>> CLibJPEGImageReaderSpi());
>>>>
>>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>>> CLibJPEGImageWriterSpi());
>>>> Note: those are not necessarily the services you have in your setup.
>>>>> Thanks
>>>>>
>>>>>
>>>>> Rob Sargent-4 wrote:
>>>>>> See the javadoc on IIORegistry. With ImageIO you may have to register
>>>>>> your handler(s). What does ImageIO.getImageReadersBySuffix() give you.
>>>>>>
>>>>>> For certain jpegs we don't use ImageIO, rather the classes in
>>>>>> com.sun.image.codec.jpeg:
>>>>>>             try {
>>>>>>                 FileOutputStream fos = new FileOutputStream(file);
>>>>>>                 JPEGImageEncoder encoder =
>>>>>> JPEGCodec.createJPEGEncoder(fos);
>>>>>>                 JPEGEncodeParam param =
>>>>>> encoder.getDefaultJPEGEncodeParam(image.getRaster(),
>>>>>> JPEGDecodeParam.COLOR_ID_CMYK);
>>>>>>                 param.setQuality(1, false);
>>>>>>                 encoder.encode(image.getRaster(), param);
>>>>>>                 fos.close();
>>>>>>             } catch (Throwable t) {
>>>>>>                 logger.debug(t.getMessage());
>>>>>>             }
>>>>>> But generally we use ImageIO
>>>>>>
>>>>>> On 06/06/2011 08:29 AM, Oscar.Flores wrote:
>>>>>>> Yeah i think i need your help again i tried tu run the .jar file in
>>>>>>> the
>>>>>>> console it work but without images this it what appears
>>>>>>>
>>>>>>> GRAVE: Error while processing image: I:\cfd\rfc.jpg (image/jpeg)
>>>>>>> org.apache.xmlgraphics.image.loader.ImageException: Cannot load image
>>>>>>> (no
>>>>>>> suitable loader/converter combination available) for I:\cfd\rfc.jpg
>>>>>>> (image/jpeg)
>>>>>>>
>>>>>>> i tried  download the jai-imagio add to the class path but it dont
>>>>>>> work
>>>>>>>
>>>>>>>
>>>>>>> Rob Sargent-4 wrote:
>>>>>>>> Very odd.  I'm having no problems getting images into pdfs using
>>>>>>>> fop-1.0.
>>>>>>>>
>>>>>>>> On 06/03/2011 11:04 AM, Oscar.Flores wrote:
>>>>>>>>> aaa hey thanks for the help the other day, i resolve the problem
>>>>>>>>> changing
>>>>>>>>> the
>>>>>>>>> version of FOP for the 0.95beta instead of the 1.0, it works now it
>>>>>>>>> prints
>>>>>>>>> the image and its good, thanks and we are in touch if anything else
>>>>>>>>> fails
>>>>>>>>> jejeje
>>>>>>>>>
>>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>>> Nothing in the log from the transformer?
>>>>>>>>>>
>>>>>>>>>> On 06/03/2011 09:47 AM, Oscar.Flores wrote:
>>>>>>>>>>> hi there i have another problem i hope you can help me the pdf
>>>>>>>>>>> that
>>>>>>>>>>> i
>>>>>>>>>>> create
>>>>>>>>>>> with foe has no image, it dont show any of them, the xsl seems to
>>>>>>>>>>> be
>>>>>>>>>>> rigth i
>>>>>>>>>>> tested with EditX and the pdf show me the image, what can it be,
>>>>>>>>>>> i
>>>>>>>>>>> have
>>>>>>>>>>> xmlgraphics-commons-1.5svn, fop 1.0, fop-pdf-images 2.0.1
>>>>>>>>>>> Snapshot
>>>>>>>>>>> for
>>>>>>>>>>> the
>>>>>>>>>>> render of the image but it don work please help!!!  :,(
>>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>>> For additional commands, e-mail:
>>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>> ---------------------------------------------------------------------
>>>>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>> For additional commands, e-mail:
>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>> ---------------------------------------------------------------------
>>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>>>>
>>>>>>
>>>>>>
>>>> ---------------------------------------------------------------------
>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>>
>>>>
>>>>
>>> :-):confused::confused::confused::confused:=)
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>
>>
>>

Re: Problems with FOP and image

Posted by "Oscar.Flores" <fa...@hotmail.com>.
Hi ok this is for generate images that dont need to be decompress later?? and
the result image i put in my xsl ?? then it should work, aaa i change to fop
1.0 and xml communs 1.4 and its the same jejeje   dont find the image
preload

org.apache.fop.fo.flow.ExternalGraphic bind
SEVERE: Image not available: The file format is not supported. No
ImagePreloader for *.jpg or *.bmp


Rob Sargent-4 wrote:
> 
> ImageIO.write(bufferedImage, "JPEG", file);
> 
> On 06/07/2011 08:21 AM, Oscar.Flores wrote:
>> Ok i actually register the handler now what i have to do is setup this
>> handler or not?? and how can i do that, also it seem that the bmp its not
>> recognice also what can i do?? thanks for the help rob
>> also i am trying to convert the images to see if it that helps
>>
>>
>> Rob Sargent-4 wrote:
>>>
>>>
>>> On 06/06/2011 02:29 PM, Oscar.Flores wrote:
>>>> Hi what can be the difference between execute the program in netbeans
>>>> (where
>>>> it works and print the images and the jar in the console)
>>> Different classes being loaded by Netbeans than the console app.  Get
>>> Netbeans to show you the full classpath it's using in it's "%classpath"
>>> variable
>>>> also i tried the
>>>> imageIO.getImageReadersBySuffix but i cant interpretate the data y.y,
>>>> its
>>>> that or always its true in the boolean variable, and how can i register
>>>> the
>>>> handler??
>>> Talk to IIORegistry, some thing like
>>>
>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>> CLibJPEGImageReaderSpi());
>>>
>>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>>> CLibJPEGImageWriterSpi());
>>> Note: those are not necessarily the services you have in your setup.
>>>> Thanks
>>>>
>>>>
>>>> Rob Sargent-4 wrote:
>>>>> See the javadoc on IIORegistry. With ImageIO you may have to register
>>>>> your handler(s). What does ImageIO.getImageReadersBySuffix() give you.
>>>>>
>>>>> For certain jpegs we don't use ImageIO, rather the classes in
>>>>> com.sun.image.codec.jpeg:
>>>>>            try {
>>>>>                FileOutputStream fos = new FileOutputStream(file);
>>>>>                JPEGImageEncoder encoder =
>>>>> JPEGCodec.createJPEGEncoder(fos);
>>>>>                JPEGEncodeParam param =
>>>>> encoder.getDefaultJPEGEncodeParam(image.getRaster(),
>>>>> JPEGDecodeParam.COLOR_ID_CMYK);
>>>>>                param.setQuality(1, false);
>>>>>                encoder.encode(image.getRaster(), param);
>>>>>                fos.close();
>>>>>            } catch (Throwable t) {
>>>>>                logger.debug(t.getMessage());
>>>>>            }
>>>>> But generally we use ImageIO
>>>>>
>>>>> On 06/06/2011 08:29 AM, Oscar.Flores wrote:
>>>>>> Yeah i think i need your help again i tried tu run the .jar file in
>>>>>> the
>>>>>> console it work but without images this it what appears
>>>>>>
>>>>>> GRAVE: Error while processing image: I:\cfd\rfc.jpg (image/jpeg)
>>>>>> org.apache.xmlgraphics.image.loader.ImageException: Cannot load image
>>>>>> (no
>>>>>> suitable loader/converter combination available) for I:\cfd\rfc.jpg
>>>>>> (image/jpeg)
>>>>>>
>>>>>> i tried  download the jai-imagio add to the class path but it dont
>>>>>> work
>>>>>>
>>>>>>
>>>>>> Rob Sargent-4 wrote:
>>>>>>> Very odd.  I'm having no problems getting images into pdfs using
>>>>>>> fop-1.0.
>>>>>>>
>>>>>>> On 06/03/2011 11:04 AM, Oscar.Flores wrote:
>>>>>>>> aaa hey thanks for the help the other day, i resolve the problem
>>>>>>>> changing
>>>>>>>> the
>>>>>>>> version of FOP for the 0.95beta instead of the 1.0, it works now it
>>>>>>>> prints
>>>>>>>> the image and its good, thanks and we are in touch if anything else
>>>>>>>> fails
>>>>>>>> jejeje
>>>>>>>>
>>>>>>>> Rob Sargent-4 wrote:
>>>>>>>>> Nothing in the log from the transformer?
>>>>>>>>>
>>>>>>>>> On 06/03/2011 09:47 AM, Oscar.Flores wrote:
>>>>>>>>>> hi there i have another problem i hope you can help me the pdf
>>>>>>>>>> that
>>>>>>>>>> i
>>>>>>>>>> create
>>>>>>>>>> with foe has no image, it dont show any of them, the xsl seems to
>>>>>>>>>> be
>>>>>>>>>> rigth i
>>>>>>>>>> tested with EditX and the pdf show me the image, what can it be,
>>>>>>>>>> i
>>>>>>>>>> have
>>>>>>>>>> xmlgraphics-commons-1.5svn, fop 1.0, fop-pdf-images 2.0.1
>>>>>>>>>> Snapshot
>>>>>>>>>> for
>>>>>>>>>> the
>>>>>>>>>> render of the image but it don work please help!!!  :,(
>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>> To unsubscribe, e-mail:
>>>>>>>>> fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>>> For additional commands, e-mail:
>>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>> ---------------------------------------------------------------------
>>>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>> For additional commands, e-mail:
>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>
>>>>>>>
>>>>>>>
>>>>> ---------------------------------------------------------------------
>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>>>
>>>>>
>>>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>
>>>
>>>
>> :-):confused::confused::confused::confused:=)
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
> 
> 
> 

-- 
View this message in context: http://old.nabble.com/Problems-with-FOP-and-image-tp31766430p31793418.html
Sent from the FOP - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Problems with FOP and image

Posted by Rob Sargent <rs...@xmission.com>.
ImageIO.write(bufferedImage, "JPEG", file);

On 06/07/2011 08:21 AM, Oscar.Flores wrote:
> Ok i actually register the handler now what i have to do is setup this
> handler or not?? and how can i do that, also it seem that the bmp its not
> recognice also what can i do?? thanks for the help rob
> also i am trying to convert the images to see if it that helps
>
>
> Rob Sargent-4 wrote:
>>
>>
>> On 06/06/2011 02:29 PM, Oscar.Flores wrote:
>>> Hi what can be the difference between execute the program in netbeans
>>> (where
>>> it works and print the images and the jar in the console)
>> Different classes being loaded by Netbeans than the console app.  Get
>> Netbeans to show you the full classpath it's using in it's "%classpath"
>> variable
>>> also i tried the
>>> imageIO.getImageReadersBySuffix but i cant interpretate the data y.y, its
>>> that or always its true in the boolean variable, and how can i register
>>> the
>>> handler??
>> Talk to IIORegistry, some thing like
>>
>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>> CLibJPEGImageReaderSpi());
>>
>> IIORegistry.getDefaultInstance().registerServiceProvider(new
>> CLibJPEGImageWriterSpi());
>> Note: those are not necessarily the services you have in your setup.
>>> Thanks
>>>
>>>
>>> Rob Sargent-4 wrote:
>>>> See the javadoc on IIORegistry. With ImageIO you may have to register
>>>> your handler(s). What does ImageIO.getImageReadersBySuffix() give you.
>>>>
>>>> For certain jpegs we don't use ImageIO, rather the classes in
>>>> com.sun.image.codec.jpeg:
>>>>            try {
>>>>                FileOutputStream fos = new FileOutputStream(file);
>>>>                JPEGImageEncoder encoder =
>>>> JPEGCodec.createJPEGEncoder(fos);
>>>>                JPEGEncodeParam param =
>>>> encoder.getDefaultJPEGEncodeParam(image.getRaster(),
>>>> JPEGDecodeParam.COLOR_ID_CMYK);
>>>>                param.setQuality(1, false);
>>>>                encoder.encode(image.getRaster(), param);
>>>>                fos.close();
>>>>            } catch (Throwable t) {
>>>>                logger.debug(t.getMessage());
>>>>            }
>>>> But generally we use ImageIO
>>>>
>>>> On 06/06/2011 08:29 AM, Oscar.Flores wrote:
>>>>> Yeah i think i need your help again i tried tu run the .jar file in the
>>>>> console it work but without images this it what appears
>>>>>
>>>>> GRAVE: Error while processing image: I:\cfd\rfc.jpg (image/jpeg)
>>>>> org.apache.xmlgraphics.image.loader.ImageException: Cannot load image
>>>>> (no
>>>>> suitable loader/converter combination available) for I:\cfd\rfc.jpg
>>>>> (image/jpeg)
>>>>>
>>>>> i tried  download the jai-imagio add to the class path but it dont work
>>>>>
>>>>>
>>>>> Rob Sargent-4 wrote:
>>>>>> Very odd.  I'm having no problems getting images into pdfs using
>>>>>> fop-1.0.
>>>>>>
>>>>>> On 06/03/2011 11:04 AM, Oscar.Flores wrote:
>>>>>>> aaa hey thanks for the help the other day, i resolve the problem
>>>>>>> changing
>>>>>>> the
>>>>>>> version of FOP for the 0.95beta instead of the 1.0, it works now it
>>>>>>> prints
>>>>>>> the image and its good, thanks and we are in touch if anything else
>>>>>>> fails
>>>>>>> jejeje
>>>>>>>
>>>>>>> Rob Sargent-4 wrote:
>>>>>>>> Nothing in the log from the transformer?
>>>>>>>>
>>>>>>>> On 06/03/2011 09:47 AM, Oscar.Flores wrote:
>>>>>>>>> hi there i have another problem i hope you can help me the pdf that
>>>>>>>>> i
>>>>>>>>> create
>>>>>>>>> with foe has no image, it dont show any of them, the xsl seems to
>>>>>>>>> be
>>>>>>>>> rigth i
>>>>>>>>> tested with EditX and the pdf show me the image, what can it be, i
>>>>>>>>> have
>>>>>>>>> xmlgraphics-commons-1.5svn, fop 1.0, fop-pdf-images 2.0.1 Snapshot
>>>>>>>>> for
>>>>>>>>> the
>>>>>>>>> render of the image but it don work please help!!!  :,(
>>>>>>>> ---------------------------------------------------------------------
>>>>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>>> For additional commands, e-mail:
>>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>> ---------------------------------------------------------------------
>>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>>>>
>>>>>>
>>>>>>
>>>> ---------------------------------------------------------------------
>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>>
>>>>
>>>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>
>>
>>
> :-):confused::confused::confused::confused:=)

---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Problems with FOP and image

Posted by "Oscar.Flores" <fa...@hotmail.com>.
Ok i actually register the handler now what i have to do is setup this
handler or not?? and how can i do that, also it seem that the bmp its not
recognice also what can i do?? thanks for the help rob 
also i am trying to convert the images to see if it that helps
   

Rob Sargent-4 wrote:
> 
> 
> 
> On 06/06/2011 02:29 PM, Oscar.Flores wrote:
>> Hi what can be the difference between execute the program in netbeans
>> (where
>> it works and print the images and the jar in the console)
> Different classes being loaded by Netbeans than the console app.  Get 
> Netbeans to show you the full classpath it's using in it's "%classpath" 
> variable
>> also i tried the
>> imageIO.getImageReadersBySuffix but i cant interpretate the data y.y, its
>> that or always its true in the boolean variable, and how can i register
>> the
>> handler??
> 
> Talk to IIORegistry, some thing like
>              
> IIORegistry.getDefaultInstance().registerServiceProvider(new 
> CLibJPEGImageReaderSpi());
>              
> IIORegistry.getDefaultInstance().registerServiceProvider(new 
> CLibJPEGImageWriterSpi());
> Note: those are not necessarily the services you have in your setup.
>> Thanks
>>
>>
>> Rob Sargent-4 wrote:
>>> See the javadoc on IIORegistry. With ImageIO you may have to register
>>> your handler(s). What does ImageIO.getImageReadersBySuffix() give you.
>>>
>>> For certain jpegs we don't use ImageIO, rather the classes in
>>> com.sun.image.codec.jpeg:
>>>           try {
>>>               FileOutputStream fos = new FileOutputStream(file);
>>>               JPEGImageEncoder encoder =
>>> JPEGCodec.createJPEGEncoder(fos);
>>>               JPEGEncodeParam param =
>>> encoder.getDefaultJPEGEncodeParam(image.getRaster(),
>>> JPEGDecodeParam.COLOR_ID_CMYK);
>>>               param.setQuality(1, false);
>>>               encoder.encode(image.getRaster(), param);
>>>               fos.close();
>>>           } catch (Throwable t) {
>>>               logger.debug(t.getMessage());
>>>           }
>>> But generally we use ImageIO
>>>
>>> On 06/06/2011 08:29 AM, Oscar.Flores wrote:
>>>> Yeah i think i need your help again i tried tu run the .jar file in the
>>>> console it work but without images this it what appears
>>>>
>>>> GRAVE: Error while processing image: I:\cfd\rfc.jpg (image/jpeg)
>>>> org.apache.xmlgraphics.image.loader.ImageException: Cannot load image
>>>> (no
>>>> suitable loader/converter combination available) for I:\cfd\rfc.jpg
>>>> (image/jpeg)
>>>>
>>>> i tried  download the jai-imagio add to the class path but it dont work
>>>>
>>>>
>>>> Rob Sargent-4 wrote:
>>>>> Very odd.  I'm having no problems getting images into pdfs using
>>>>> fop-1.0.
>>>>>
>>>>> On 06/03/2011 11:04 AM, Oscar.Flores wrote:
>>>>>> aaa hey thanks for the help the other day, i resolve the problem
>>>>>> changing
>>>>>> the
>>>>>> version of FOP for the 0.95beta instead of the 1.0, it works now it
>>>>>> prints
>>>>>> the image and its good, thanks and we are in touch if anything else
>>>>>> fails
>>>>>> jejeje
>>>>>>
>>>>>> Rob Sargent-4 wrote:
>>>>>>> Nothing in the log from the transformer?
>>>>>>>
>>>>>>> On 06/03/2011 09:47 AM, Oscar.Flores wrote:
>>>>>>>> hi there i have another problem i hope you can help me the pdf that
>>>>>>>> i
>>>>>>>> create
>>>>>>>> with foe has no image, it dont show any of them, the xsl seems to
>>>>>>>> be
>>>>>>>> rigth i
>>>>>>>> tested with EditX and the pdf show me the image, what can it be, i
>>>>>>>> have
>>>>>>>> xmlgraphics-commons-1.5svn, fop 1.0, fop-pdf-images 2.0.1 Snapshot
>>>>>>>> for
>>>>>>>> the
>>>>>>>> render of the image but it don work please help!!!  :,(
>>>>>>> ---------------------------------------------------------------------
>>>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>>> For additional commands, e-mail:
>>>>>>> fop-users-help@xmlgraphics.apache.org
>>>>>>>
>>>>>>>
>>>>>>>
>>>>> ---------------------------------------------------------------------
>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>>>
>>>>>
>>>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>
>>>
>>>
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
> 
> 
> 
:-):confused::confused::confused::confused:=)
-- 
View this message in context: http://old.nabble.com/Problems-with-FOP-and-image-tp31766430p31792091.html
Sent from the FOP - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Problems with FOP and image

Posted by Rob Sargent <rs...@xmission.com>.

On 06/06/2011 02:29 PM, Oscar.Flores wrote:
> Hi what can be the difference between execute the program in netbeans (where
> it works and print the images and the jar in the console)
Different classes being loaded by Netbeans than the console app.  Get 
Netbeans to show you the full classpath it's using in it's "%classpath" 
variable
> also i tried the
> imageIO.getImageReadersBySuffix but i cant interpretate the data y.y, its
> that or always its true in the boolean variable, and how can i register the
> handler??

Talk to IIORegistry, some thing like
             
IIORegistry.getDefaultInstance().registerServiceProvider(new 
CLibJPEGImageReaderSpi());
             
IIORegistry.getDefaultInstance().registerServiceProvider(new 
CLibJPEGImageWriterSpi());
Note: those are not necessarily the services you have in your setup.
> Thanks
>
>
> Rob Sargent-4 wrote:
>> See the javadoc on IIORegistry. With ImageIO you may have to register
>> your handler(s). What does ImageIO.getImageReadersBySuffix() give you.
>>
>> For certain jpegs we don't use ImageIO, rather the classes in
>> com.sun.image.codec.jpeg:
>>           try {
>>               FileOutputStream fos = new FileOutputStream(file);
>>               JPEGImageEncoder encoder = JPEGCodec.createJPEGEncoder(fos);
>>               JPEGEncodeParam param =
>> encoder.getDefaultJPEGEncodeParam(image.getRaster(),
>> JPEGDecodeParam.COLOR_ID_CMYK);
>>               param.setQuality(1, false);
>>               encoder.encode(image.getRaster(), param);
>>               fos.close();
>>           } catch (Throwable t) {
>>               logger.debug(t.getMessage());
>>           }
>> But generally we use ImageIO
>>
>> On 06/06/2011 08:29 AM, Oscar.Flores wrote:
>>> Yeah i think i need your help again i tried tu run the .jar file in the
>>> console it work but without images this it what appears
>>>
>>> GRAVE: Error while processing image: I:\cfd\rfc.jpg (image/jpeg)
>>> org.apache.xmlgraphics.image.loader.ImageException: Cannot load image (no
>>> suitable loader/converter combination available) for I:\cfd\rfc.jpg
>>> (image/jpeg)
>>>
>>> i tried  download the jai-imagio add to the class path but it dont work
>>>
>>>
>>> Rob Sargent-4 wrote:
>>>> Very odd.  I'm having no problems getting images into pdfs using
>>>> fop-1.0.
>>>>
>>>> On 06/03/2011 11:04 AM, Oscar.Flores wrote:
>>>>> aaa hey thanks for the help the other day, i resolve the problem
>>>>> changing
>>>>> the
>>>>> version of FOP for the 0.95beta instead of the 1.0, it works now it
>>>>> prints
>>>>> the image and its good, thanks and we are in touch if anything else
>>>>> fails
>>>>> jejeje
>>>>>
>>>>> Rob Sargent-4 wrote:
>>>>>> Nothing in the log from the transformer?
>>>>>>
>>>>>> On 06/03/2011 09:47 AM, Oscar.Flores wrote:
>>>>>>> hi there i have another problem i hope you can help me the pdf that i
>>>>>>> create
>>>>>>> with foe has no image, it dont show any of them, the xsl seems to be
>>>>>>> rigth i
>>>>>>> tested with EditX and the pdf show me the image, what can it be, i
>>>>>>> have
>>>>>>> xmlgraphics-commons-1.5svn, fop 1.0, fop-pdf-images 2.0.1 Snapshot
>>>>>>> for
>>>>>>> the
>>>>>>> render of the image but it don work please help!!!  :,(
>>>>>> ---------------------------------------------------------------------
>>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>>>>
>>>>>>
>>>>>>
>>>> ---------------------------------------------------------------------
>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>>
>>>>
>>>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>
>>
>>

---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Problems with FOP and image

Posted by "Oscar.Flores" <fa...@hotmail.com>.
Hi what can be the difference between execute the program in netbeans (where
it works and print the images and the jar in the console) also i tried the
imageIO.getImageReadersBySuffix but i cant interpretate the data y.y, its
that or always its true in the boolean variable, and how can i register the
handler?? 

Thanks
 

Rob Sargent-4 wrote:
> 
> See the javadoc on IIORegistry. With ImageIO you may have to register 
> your handler(s). What does ImageIO.getImageReadersBySuffix() give you.
> 
> For certain jpegs we don't use ImageIO, rather the classes in 
> com.sun.image.codec.jpeg:
>          try {
>              FileOutputStream fos = new FileOutputStream(file);
>              JPEGImageEncoder encoder = JPEGCodec.createJPEGEncoder(fos);
>              JPEGEncodeParam param = 
> encoder.getDefaultJPEGEncodeParam(image.getRaster(), 
> JPEGDecodeParam.COLOR_ID_CMYK);
>              param.setQuality(1, false);
>              encoder.encode(image.getRaster(), param);
>              fos.close();
>          } catch (Throwable t) {
>              logger.debug(t.getMessage());
>          }
> But generally we use ImageIO
> 
> On 06/06/2011 08:29 AM, Oscar.Flores wrote:
>> Yeah i think i need your help again i tried tu run the .jar file in the
>> console it work but without images this it what appears
>>
>> GRAVE: Error while processing image: I:\cfd\rfc.jpg (image/jpeg)
>> org.apache.xmlgraphics.image.loader.ImageException: Cannot load image (no
>> suitable loader/converter combination available) for I:\cfd\rfc.jpg
>> (image/jpeg)
>>
>> i tried  download the jai-imagio add to the class path but it dont work
>>
>>
>> Rob Sargent-4 wrote:
>>> Very odd.  I'm having no problems getting images into pdfs using
>>> fop-1.0.
>>>
>>> On 06/03/2011 11:04 AM, Oscar.Flores wrote:
>>>> aaa hey thanks for the help the other day, i resolve the problem
>>>> changing
>>>> the
>>>> version of FOP for the 0.95beta instead of the 1.0, it works now it
>>>> prints
>>>> the image and its good, thanks and we are in touch if anything else
>>>> fails
>>>> jejeje
>>>>
>>>> Rob Sargent-4 wrote:
>>>>> Nothing in the log from the transformer?
>>>>>
>>>>> On 06/03/2011 09:47 AM, Oscar.Flores wrote:
>>>>>> hi there i have another problem i hope you can help me the pdf that i
>>>>>> create
>>>>>> with foe has no image, it dont show any of them, the xsl seems to be
>>>>>> rigth i
>>>>>> tested with EditX and the pdf show me the image, what can it be, i
>>>>>> have
>>>>>> xmlgraphics-commons-1.5svn, fop 1.0, fop-pdf-images 2.0.1 Snapshot
>>>>>> for
>>>>>> the
>>>>>> render of the image but it don work please help!!!  :,(
>>>>> ---------------------------------------------------------------------
>>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>>>
>>>>>
>>>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>
>>>
>>>
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
> 
> 
> 

-- 
View this message in context: http://old.nabble.com/Problems-with-FOP-and-image-tp31766430p31786846.html
Sent from the FOP - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Problems with FOP and image

Posted by Rob Sargent <rs...@xmission.com>.
See the javadoc on IIORegistry. With ImageIO you may have to register 
your handler(s). What does ImageIO.getImageReadersBySuffix() give you.

For certain jpegs we don't use ImageIO, rather the classes in 
com.sun.image.codec.jpeg:
         try {
             FileOutputStream fos = new FileOutputStream(file);
             JPEGImageEncoder encoder = JPEGCodec.createJPEGEncoder(fos);
             JPEGEncodeParam param = 
encoder.getDefaultJPEGEncodeParam(image.getRaster(), 
JPEGDecodeParam.COLOR_ID_CMYK);
             param.setQuality(1, false);
             encoder.encode(image.getRaster(), param);
             fos.close();
         } catch (Throwable t) {
             logger.debug(t.getMessage());
         }
But generally we use ImageIO

On 06/06/2011 08:29 AM, Oscar.Flores wrote:
> Yeah i think i need your help again i tried tu run the .jar file in the
> console it work but without images this it what appears
>
> GRAVE: Error while processing image: I:\cfd\rfc.jpg (image/jpeg)
> org.apache.xmlgraphics.image.loader.ImageException: Cannot load image (no
> suitable loader/converter combination available) for I:\cfd\rfc.jpg
> (image/jpeg)
>
> i tried  download the jai-imagio add to the class path but it dont work
>
>
> Rob Sargent-4 wrote:
>> Very odd.  I'm having no problems getting images into pdfs using fop-1.0.
>>
>> On 06/03/2011 11:04 AM, Oscar.Flores wrote:
>>> aaa hey thanks for the help the other day, i resolve the problem changing
>>> the
>>> version of FOP for the 0.95beta instead of the 1.0, it works now it
>>> prints
>>> the image and its good, thanks and we are in touch if anything else fails
>>> jejeje
>>>
>>> Rob Sargent-4 wrote:
>>>> Nothing in the log from the transformer?
>>>>
>>>> On 06/03/2011 09:47 AM, Oscar.Flores wrote:
>>>>> hi there i have another problem i hope you can help me the pdf that i
>>>>> create
>>>>> with foe has no image, it dont show any of them, the xsl seems to be
>>>>> rigth i
>>>>> tested with EditX and the pdf show me the image, what can it be, i have
>>>>> xmlgraphics-commons-1.5svn, fop 1.0, fop-pdf-images 2.0.1 Snapshot for
>>>>> the
>>>>> render of the image but it don work please help!!!  :,(
>>>> ---------------------------------------------------------------------
>>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>>
>>>>
>>>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>
>>
>>

---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Problems with FOP and image

Posted by "Oscar.Flores" <fa...@hotmail.com>.
Yeah i think i need your help again i tried tu run the .jar file in the
console it work but without images this it what appears 

GRAVE: Error while processing image: I:\cfd\rfc.jpg (image/jpeg)
org.apache.xmlgraphics.image.loader.ImageException: Cannot load image (no
suitable loader/converter combination available) for I:\cfd\rfc.jpg
(image/jpeg) 

i tried  download the jai-imagio add to the class path but it dont work 
 

Rob Sargent-4 wrote:
> 
> Very odd.  I'm having no problems getting images into pdfs using fop-1.0.
> 
> On 06/03/2011 11:04 AM, Oscar.Flores wrote:
>> aaa hey thanks for the help the other day, i resolve the problem changing
>> the
>> version of FOP for the 0.95beta instead of the 1.0, it works now it
>> prints
>> the image and its good, thanks and we are in touch if anything else fails
>> jejeje
>>
>> Rob Sargent-4 wrote:
>>> Nothing in the log from the transformer?
>>>
>>> On 06/03/2011 09:47 AM, Oscar.Flores wrote:
>>>> hi there i have another problem i hope you can help me the pdf that i
>>>> create
>>>> with foe has no image, it dont show any of them, the xsl seems to be
>>>> rigth i
>>>> tested with EditX and the pdf show me the image, what can it be, i have
>>>> xmlgraphics-commons-1.5svn, fop 1.0, fop-pdf-images 2.0.1 Snapshot for
>>>> the
>>>> render of the image but it don work please help!!!  :,(
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>>
>>>
>>>
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
> 
> 
> 

-- 
View this message in context: http://old.nabble.com/Problems-with-FOP-and-image-tp31766430p31783943.html
Sent from the FOP - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Problems with FOP and image

Posted by Rob Sargent <rs...@xmission.com>.
Very odd.  I'm having no problems getting images into pdfs using fop-1.0.

On 06/03/2011 11:04 AM, Oscar.Flores wrote:
> aaa hey thanks for the help the other day, i resolve the problem changing the
> version of FOP for the 0.95beta instead of the 1.0, it works now it prints
> the image and its good, thanks and we are in touch if anything else fails
> jejeje
>
> Rob Sargent-4 wrote:
>> Nothing in the log from the transformer?
>>
>> On 06/03/2011 09:47 AM, Oscar.Flores wrote:
>>> hi there i have another problem i hope you can help me the pdf that i
>>> create
>>> with foe has no image, it dont show any of them, the xsl seems to be
>>> rigth i
>>> tested with EditX and the pdf show me the image, what can it be, i have
>>> xmlgraphics-commons-1.5svn, fop 1.0, fop-pdf-images 2.0.1 Snapshot for
>>> the
>>> render of the image but it don work please help!!!  :,(
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
>> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
>>
>>
>>

---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Problems with FOP and image

Posted by "Oscar.Flores" <fa...@hotmail.com>.
aaa hey thanks for the help the other day, i resolve the problem changing the
version of FOP for the 0.95beta instead of the 1.0, it works now it prints
the image and its good, thanks and we are in touch if anything else fails
jejeje   

Rob Sargent-4 wrote:
> 
> Nothing in the log from the transformer?
> 
> On 06/03/2011 09:47 AM, Oscar.Flores wrote:
>> hi there i have another problem i hope you can help me the pdf that i
>> create
>> with foe has no image, it dont show any of them, the xsl seems to be
>> rigth i
>> tested with EditX and the pdf show me the image, what can it be, i have
>> xmlgraphics-commons-1.5svn, fop 1.0, fop-pdf-images 2.0.1 Snapshot for
>> the
>> render of the image but it don work please help!!!  :,(
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
> 
> 
> 

-- 
View this message in context: http://old.nabble.com/Problems-with-FOP-and-image-tp31766430p31767057.html
Sent from the FOP - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Problems with FOP and image

Posted by Rob Sargent <rs...@xmission.com>.
Nothing in the log from the transformer?

On 06/03/2011 09:47 AM, Oscar.Flores wrote:
> hi there i have another problem i hope you can help me the pdf that i create
> with foe has no image, it dont show any of them, the xsl seems to be rigth i
> tested with EditX and the pdf show me the image, what can it be, i have
> xmlgraphics-commons-1.5svn, fop 1.0, fop-pdf-images 2.0.1 Snapshot for the
> render of the image but it don work please help!!!  :,(

---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org