Jeremias, Jeremias Maerki wrote:
>Peter > >(comments inline) > >>In config.xml: >> >> <entry> >> <key>userConfigFileName</key> >> <value>userconfig.xml</value> >> </entry> >> > >Ok, that means FOP looks in the current directory for userconfig.xml. >I can agree with that. I guess there are pros and cons: This mechanism >can reduce the work that needs to be done to get FOP running in embedded >mode. But on the other hand, I'm not sure if it cuts on flexibility when >you want to provide a special configuration. > Then you use the command line. >> <entry> >> <key>languageConfigFileName</key> >> <value>xml-lang.xml</value> >> </entry> >> >>(More on languageConfigFileName later.) >> >>In userconfig.xml, allow things like >> >> <entry> >> <key>foFileName</key> >> <value>/home/pbw/public_html/xml/newtest3.fo</value> >> </entry> >> >> <entry> >> <key>inputMode</key> >> <value>fo</value> >> </entry> >> >> <entry> >> <key>foFileName</key> >> <value>/home/pbw/public_html/xml/newtest3.fo</value> >> </entry> >> >> <entry> >> <key>outputMode</key> >> <value>pdf</value> >> </entry> >> >> <entry> >> <key>outputFileName</key> >> <value>/home/pbw/public_html/xml/newtest3.pdf</value> >> </entry> >> > >Now, I think you're really start mixing things. I strongly recommend to >separate configuration (as the filename says) and processing >instructions. What you want to do means creating a new userconfig.xml >for each call to FOP. This is much easier using the command line (and >faster). > >Any other opinions? > No, it doesn't mean creating a new userconfig file for each invocation; that's what the command line is for. It's a convenience for special requirements for, e.g., developers. Command line trumps userconfig. Is it nice? No. Is it useful? Yes. In any case, it seems that in Java environments, the command line may not be the best way to pass such things around. What do you do on a Mac? >>The language file (see attached) is just a validation mechanism for >>certain attribute/property values. It (currently) requires the >>org.apache.fop.configuration.LanguageFileReader class which reads the >>xml-lang.xml file and builds three HashMaps, which are installed in >>Configuration. >> > >I don't get you here. What do you need the language validation for? > For completeness. I can specify country, language and script, and these may be acted upon in respect of hyphenation. Two situations may arise. 1) That particular language/country/script may have no support in this version of FOP. 2) There is no such language/country/script. When I'm parsing one of these attributes, I like to be able to detect the second situation at the point of parsing. Peter --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED]