Re: Output from NIST test suite

2004-01-03 Thread Bernd Brandstetter
Hi,

in your GhostScript installation there should also exist a gswin32c.exe 
which runs in console mode and therefore doesn't open a GUI window every 
time.

Bye,
Bernd


On Saturday 03 January 2004 00:35, Finn Bock wrote:
 [Jeremias Maerki]

 I drive ghostscript with a bash script like this:

 for f in $*; do
  r=${f/.pdf/.png}
  echo $f $r
  gswin32 -q -dSAFER -dBATCH -dNOPAUSE -sDEVICE=png16m \
   -sOutputFile=$r $f
 done

 and it is quite slow and cause the ghostscript console to flicker and
 grab the focus all the time. Annoying.

 Does anyone here know of a better (and maybe faster) way of using
 ghostscript to convert 615 pdf files to images?



Re: Output from NIST test suite

2004-01-03 Thread Finn Bock
[Bernd Brandstetter]

in your GhostScript installation there should also exist a gswin32c.exe 
which runs in console mode and therefore doesn't open a GUI window every 
time.
And indeed there is. Boy, I feel stupid now. Thank you for the pointer.

regards,
finn


cvs commit: xml-fop/src/java/org/apache/fop/fo/properties Property.java

2004-01-03 Thread pbwest
pbwest  2004/01/03 03:14:46

  Modified:src/java/org/apache/fop/fo/properties Tag:
FOP_0-20-0_Alt-Design Property.java
  Log:
  Added getters for initialValueTypes, inherited, dataTypes  and
  traitMapping, so that these methods can be overridden in
  subclasses of Property.
  
  Revision  ChangesPath
  No   revision
  No   revision
  1.1.2.3   +22 -3 
xml-fop/src/java/org/apache/fop/fo/properties/Attic/Property.java
  
  Index: Property.java
  ===
  RCS file: 
/home/cvs/xml-fop/src/java/org/apache/fop/fo/properties/Attic/Property.java,v
  retrieving revision 1.1.2.2
  retrieving revision 1.1.2.3
  diff -u -r1.1.2.2 -r1.1.2.3
  --- Property.java 21 Dec 2003 01:38:52 -  1.1.2.2
  +++ Property.java 3 Jan 2004 11:14:46 -   1.1.2.3
  @@ -252,8 +252,27 @@
 ;
   
   public static final int dataTypes = NOTYPE;
  +
  +public int getDataTypes() {
  +return dataTypes;
  +}
   public static final int initialValueType = NOTYPE_IT;
  +
  +public int getInitialValueType() {
  +return initialValueType;
  +}
  +
   public static final int inherited = NO;
  +
  +public int getInherited() {
  +return inherited;
  +}
  +
  +private static final int traitMapping = NO_TRAIT;
  +
  +public int getTraitMapping() {
  +return traitMapping;
  +}
   
   public static Map enumHash = null;
   
  
  
  

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Output from NIST test suite

2004-01-03 Thread Finn Bock
[Carmelo Montanez]

Hi Folks:

Somehow the final copy of the test suite was not uploaded to either our
server at NIST or W3C.  I uploaded a copy of the latest suite version
to the following link:
http://xw2k.sdct.itl.nist.gov/carmelo/formattingObjectsSuite123103.zip

I will make sure it is at the W3c and NIST server soon.
Wow, that is quite a developement between the two versions.

I've tested FOP with the new suite, and I think there is a few issues 
with the test suite itself.

- NIST/rendering-model/renderingmodel2 expect nist.gif to be available.
- NIST/table-header/thfoSingleCell1.xml there is a fo:block/ element
  but the fo namespace is undeclared, so the test can't be transformed.
- NIST/table-header/thfoDoubleCell.xml same at thfoSingleCell1.xml
- NIST/table-header/thfoBorderStyle9.xsl, a closing quote is missing on
  line 12:
xsl:attribute name = border-collapsecollapse/xsl:attribute
- NIST/wrapper/wrfoBlockColor1.xsl, an extra '' char at line 135.
- NIST/page-sequence/psfopagemaster1 isn't using master-reference:
 fo:page-sequence master-name=test-page-master1
- NIST/area-dimension/adp-height1, the oransq.jpg is not included.
- NIST/miscellaneous/misc-list1, the file crosshair1.jpg isn't included.
regards,
finn


cvs commit: xml-fop/src/java/org/apache/fop/fo PropertyConsts.java

2004-01-03 Thread pbwest
pbwest  2004/01/03 05:00:50

  Modified:src/java/org/apache/fop/fo Tag: FOP_0-20-0_Alt-Design
PropertyConsts.java
  Log:
  Adjusted HashMap initial size.
  
  Revision  ChangesPath
  No   revision
  No   revision
  1.1.2.2   +9 -28 xml-fop/src/java/org/apache/fop/fo/Attic/PropertyConsts.java
  
  Index: PropertyConsts.java
  ===
  RCS file: /home/cvs/xml-fop/src/java/org/apache/fop/fo/Attic/PropertyConsts.java,v
  retrieving revision 1.1.2.1
  retrieving revision 1.1.2.2
  diff -u -r1.1.2.1 -r1.1.2.2
  --- PropertyConsts.java   5 Jul 2003 19:26:05 -   1.1.2.1
  +++ PropertyConsts.java   3 Jan 2004 13:00:50 -   1.1.2.2
  @@ -137,8 +137,8 @@
* of a property class.  The index value is the index of the property
* class name in the classNames[] array.
*/
  -private final HashMap classToIndex
  -= new HashMap(PropNames.LAST_PROPERTY_INDEX + 1);
  +private final HashMap classToIndex = new HashMap(
  +(int)((PropNames.LAST_PROPERTY_INDEX + 1) / 0.75) + 1);
   
   /**
* An ttint[]/tt containing the iinherited/i values from the
  @@ -458,8 +458,6 @@
   Class pclass;
   Property property;
   
  -//System.out.println(setupProperty  + propindex +  
  -//+ PropNames.getPropertyName(propindex));
   if ((property = properties[propindex]) != null) return property;
   
   // Get the property class name
  @@ -484,38 +482,25 @@
   // Get the class for this property name
   String name = packageName + .properties. + cname;
   try {
  -//System.out.println(classes[+propindex+] +name);//DEBUG
   pclass = Class.forName(name);
   classes[propindex] = pclass;
   
   // Instantiate the class
   property = (Property)(pclass.newInstance());
   properties[propindex] = property;
  -//System.out.println
  -//(property name 
  - //+ property.getClass().getName());
  -//System.out.println
  -//(property name  +
  -//properties[propindex].getClass().getName());
   
   // Set inheritance value
   if ((inherited[propindex]
  -= pclass.getField(inherited).getInt(null))
  += property.getInherited())
   != Property.NO)
   inheritedprops.set(propindex);
   // Set datatypes
  -datatypes[propindex] = pclass.getField(dataTypes).getInt(null);
  -//System.out.println(datatypes  + datatypes[propindex] + \n
  -   //+ Property.listDataTypes(datatypes[propindex]));
  +datatypes[propindex] = property.getDataTypes();
   
   // Set initialValueTypes
  -initialValueTypes[propindex] =
  -pclass.getField(initialValueType).getInt(null);
  -//System.out.println(initialValueType 
  -   //+ initialValueTypes[propindex]);
  +initialValueTypes[propindex] = property.getInitialValueType();
   
  -traitMappings[propindex] =
  -pclass.getField(traitMapping).getInt(null);
  +traitMappings[propindex] = property.getTraitMapping();
   
   } catch (ClassNotFoundException e) {
   throw new PropertyException
  @@ -526,10 +511,6 @@
   } catch (InstantiationException e) {
   throw new PropertyException
   (InstantiationException + e.getMessage());
  -}
  -catch (NoSuchFieldException e) {
  -throw new PropertyException
  -(NoSuchFieldException + e.getMessage());
   }
   
   return property;
  
  
  

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



cvs commit: xml-fop build.xml

2004-01-03 Thread pbwest
pbwest  2004/01/03 05:09:35

  Modified:.Tag: FOP_0-20-0_Alt-Design build.xml
  Log:
  Cosmetic changes.
  
  Revision  ChangesPath
  No   revision
  No   revision
  1.37.2.8  +2 -2  xml-fop/build.xml
  
  Index: build.xml
  ===
  RCS file: /home/cvs/xml-fop/build.xml,v
  retrieving revision 1.37.2.7
  retrieving revision 1.37.2.8
  diff -u -r1.37.2.7 -r1.37.2.8
  --- build.xml 2 Jan 2004 15:12:26 -   1.37.2.7
  +++ build.xml 3 Jan 2004 13:09:35 -   1.37.2.8
  @@ -85,8 +85,8 @@
   
 !-- used to set values for testing etc. --
 !-- build-local.properties is not stored in CVS
  -  and overrides values from build.properties --
  -  property file=build-local.properties/
  +  and overrides values from build.properties --
  +  property file=build-local.properties/
 property file=build.properties/
   
   !--
  
  
  

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



cvs commit: xml-fop .project

2004-01-03 Thread pbwest
pbwest  2004/01/03 05:10:41

  Modified:.Tag: FOP_0-20-0_Alt-Design .project
  Log:
  Project modifications.
  
  Revision  ChangesPath
  No   revision
  No   revision
  1.1.2.4   +11 -0 xml-fop/Attic/.project
  
  Index: .project
  ===
  RCS file: /home/cvs/xml-fop/Attic/.project,v
  retrieving revision 1.1.2.3
  retrieving revision 1.1.2.4
  diff -u -r1.1.2.3 -r1.1.2.4
  --- .project  21 Dec 2003 01:41:52 -  1.1.2.3
  +++ .project  3 Jan 2004 13:10:41 -   1.1.2.4
  @@ -17,6 +17,17 @@
/arguments
/buildCommand
buildCommand
  + nameorg.eclipse.ui.externaltools.ExternalToolBuilder/name
  + arguments
  + dictionary
  + keyLaunchConfigHandle/key
  + valuelt;?xml version=quot;1.0quot; 
encoding=quot;UTF-8quot;?gt;
  +lt;launchConfiguration local=quot;falsequot; 
path=quot;/FOP_Alt-Design/.externalToolBuilders/alt.design build.xml 
[Builder].launchquot;/gt;
  +/value
  + /dictionary
  + /arguments
  + /buildCommand
  + buildCommand
nameorg.eclipse.jdt.core.javabuilder/name
arguments
/arguments
  
  
  

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



cvs commit: xml-fop/src/java/org/apache/fop/fo/properties Dummy.java

2004-01-03 Thread pbwest
pbwest  2004/01/03 05:11:15

  Removed: src/java/org/apache/fop/fo/properties Tag:
FOP_0-20-0_Alt-Design Dummy.java
  Log:
  No longer requuired.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



cvs commit: xml-fop/src/java/org/apache/fop/render/rtf/rtflib/rtfdoc RtfColorTable.java

2004-01-03 Thread pherweg
pherweg 2004/01/03 05:43:12

  Modified:src/java/org/apache/fop/render/rtf/rtflib/rtfdoc
RtfColorTable.java
  Log:
  bug fixed: The first occurence of a custom color was displayed with wrong color
  
  Revision  ChangesPath
  1.3   +12 -3 
xml-fop/src/java/org/apache/fop/render/rtf/rtflib/rtfdoc/RtfColorTable.java
  
  Index: RtfColorTable.java
  ===
  RCS file: 
/home/cvs/xml-fop/src/java/org/apache/fop/render/rtf/rtflib/rtfdoc/RtfColorTable.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- RtfColorTable.java15 Nov 2003 23:45:34 -  1.2
  +++ RtfColorTable.java3 Jan 2004 13:43:12 -   1.3
  @@ -187,14 +187,21 @@
   int retVal;
   
   if (o == null) {
  +//The color currently does not exist, so add it to the table.
  +//First add it, then read the size as index (to return it).
  +//So the first added color gets index 1. That is OK, because
  +//index 0 is reserved for auto-colored. 
   addColor (identifier);
   
   retVal = colorTable.size ();
   } else {
  -retVal = ((Integer) o).intValue ();
  +//The color was found. Before returning the index, increment
  +//it by one. Because index 0 is reserved for auto-colored, but
  +//is not contained in colorTable.
  +retVal = ((Integer) o).intValue () + 1;
   }
   
  -return new Integer(retVal + 1);
  +return new Integer(retVal);
   }
   
   /**
  @@ -212,6 +219,8 @@
   header.writeGroupMark (true);
   //Don't use writeControlWord, because it appends a blank,
   //which may confuse Wordpad.
  +//This also implicitly writes the first color (=index 0), which
  +//is reserved for auto-colored.
   header.write (\\colortbl;);
   
   int len = colorTable.size ();
  
  
  

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: More on row and column span (was: RE: (Changing Vote) etc.)

2004-01-03 Thread Andreas L. Delmelle
 -Original Message-
 From: Andreas L. Delmelle [mailto:[EMAIL PROTECTED]

 I guess the riddle I'm still trying to solve is:
 How do I access the LM's for the subsequent rows at this point?


AFAICT, I have overlooked (at least) the following note in the spec (6.7.1
Table Formatting Objects - Introduction):

- a cell that is spanned may have a different background in each of the grid
units it occupies

Reading this, I'm totally unsure of the solution I have proposed... As it
is, I think it would 'expand' the background props in the first grid unit,
and use them as background for the whole spanned cell. In order to achieve
this effect, it may be necessary to have the body LM add dummy cells to the
following rows.

So the child areas of a spanned cell need to be laid out to fill the full
range the cell spans, while the specified background may only be used on the
first grid unit... Quite a bit harder than I initially thought, but we'll
keep looking.

Another detail overlooked is the column-number property, which would
perfectly fulfill the role of my proposed cspanPrev variable. It is defined
in TableCell, but not according to the default defined in the spec.
(It's set to 0, but should be set to:
q the first column to be spanned by the table-cell. The initial value is
the current column-number. For the first table-cell in a table-row, the
current column is 1. For other table-cells, the current column-number is the
column-number of the previous table-cell in the row plus the number of
columns spanned by that previous cell. /q)

In the meantime, if anyone can provide me with any pointers, be sure to post
them!
(C'mon, ya layout-geeks, where are you? :) )

Thanks,

Andreas



DO NOT REPLY [Bug 25880] New: - [PATCH] avoid expotential notation for small transformation numbers.

2004-01-03 Thread bugzilla
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=25880.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=25880

[PATCH] avoid expotential notation for small transformation numbers.

   Summary: [PATCH] avoid expotential notation for small
transformation numbers.
   Product: Fop
   Version: 1.0dev
  Platform: Other
OS/Version: Other
Status: NEW
  Severity: Normal
  Priority: Other
 Component: pdf renderer
AssignedTo: [EMAIL PROTECTED]
ReportedBy: [EMAIL PROTECTED]


The attached example cause a the PDF transformation matrix to contain values 
like:
-1.0 1.2246467991473532E-16 -1.2246467991473532E-16 -1.0

which is invalid for PDF. Acrobat 6.0 complains when I open the example.

The patch calls the PDFNumber.doubleOut to prevent the use of expotential 
notation.


DO NOT REPLY [Bug 25880] - [PATCH] avoid expotential notation for small transformation numbers.

2004-01-03 Thread bugzilla
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=25880.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=25880

[PATCH] avoid expotential notation for small transformation numbers.





--- Additional Comments From [EMAIL PROTECTED]  2004-01-03 19:46 ---
Created an attachment (id=9786)
A unified diff against HEAD.-


DO NOT REPLY [Bug 25881] New: - [PATCH] relative font-size gets calculated twice.

2004-01-03 Thread bugzilla
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=25881.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=25881

[PATCH] relative font-size gets calculated twice.

   Summary: [PATCH] relative font-size gets calculated twice.
   Product: Fop
   Version: 1.0dev
  Platform: Other
OS/Version: Other
Status: NEW
  Severity: Normal
  Priority: Other
 Component: general
AssignedTo: [EMAIL PROTECTED]
ReportedBy: [EMAIL PROTECTED]


When the font-size property has a relative value that depends on font-size, the 
computation is done twice.

The testcase uses font-size=2em which should be a 24pt font, but the result 
is shown in 48pt.


DO NOT REPLY [Bug 25881] - [PATCH] relative font-size gets calculated twice.

2004-01-03 Thread bugzilla
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=25881.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=25881

[PATCH] relative font-size gets calculated twice.





--- Additional Comments From [EMAIL PROTECTED]  2004-01-03 21:04 ---
Created an attachment (id=9787)
A unified diff against HEAD.



DO NOT REPLY [Bug 25881] - [PATCH] relative font-size gets calculated twice.

2004-01-03 Thread bugzilla
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=25881.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=25881

[PATCH] relative font-size gets calculated twice.





--- Additional Comments From [EMAIL PROTECTED]  2004-01-03 21:04 ---
Created an attachment (id=9788)
A testcase .fo


DO NOT REPLY [Bug 25882] New: - PS-Renderer doesn't generate pages in landscape orientation

2004-01-03 Thread bugzilla
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=25882.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=25882

PS-Renderer doesn't generate pages in landscape orientation

   Summary: PS-Renderer doesn't generate pages in landscape
orientation
   Product: Fop
   Version: 0.20.5
  Platform: Other
OS/Version: Windows XP
Status: NEW
  Severity: Critical
  Priority: Other
 Component: general
AssignedTo: [EMAIL PROTECTED]
ReportedBy: [EMAIL PROTECTED]


The ps-renderer doesn't produce correct output if the page format is defined 
as landscape. 
I tested the outpot wit following fo-file:

?xml version=1.0 encoding=utf-8?

fo:root font-family=Times Roman font-size=12pt  
xmlns:fo=http://www.w3.org/1999/XSL/Format;

fo:layout-master-set
!-- layout for the first page --
fo:simple-page-master master-name=A4-landscape reference-
orientation=90
page-height=21cm page-width=29.7cm 
margin-top=1cm margin-bottom=1cm margin-left=1cm 
margin-right=1cm
fo:region-body/fo:region-body
/fo:simple-page-master
/fo:layout-master-set
 

  fo:page-sequence master-reference=A4-landscape

  fo:flow flow-name=xsl-region-body
  fo:block font-size=18pt font-weight=bold FOP test line /fo:block
  /fo:flow
/fo:page-sequence

/fo:root

With the PDF-renderer the output is correct. In my project I can not use the 
PDF-renderer. I have to produce documents with differnt EPS-images in it. EPS-
images will not be converted by PDF-renderer. PDF-files will be generated 
by distiller.

regards
markus steiner


Immediate plans for alt.design

2004-01-03 Thread Peter B. West
Fopsters,

Having woken from my torpor, I am planning to re-activate alt-design
development.
My immediate plans include:

Standardizing the name of alt.design.

Marker processing
. Generalise SyncedFoXmlEventsBuffer to handle events from any supported
   namespace
. Generalise buffer definitions to support circular and fixed-length
   XML event buffers
. Generalise SyncedFoXmlEventsBuffer to read from any buffer type
   supporting the buffer Interface
. Modify SyncedFoXmlEventsBuffer to read from a stack of buffer
   Interfaces, popping exhausted event buffers as required
. Modify initial marker processing to read fo:marker subtree events into
   individual marker event buffers
. Modify fo:static-content handling to (initially) read static-content
   XML events into per-page static-content buffers
The marker handling will be more or less in accordance with the notes 
posted here:
http://marc.theaimsgroup.com/?l=fop-devm=105455437221298w=4

Percentage expressions
. Add RPN expressions as a PropertyValue type, along the lines proposed 
here:
http://marc.theaimsgroup.com/?l=fop-devm=105391772500443w=4

Area construction
. Make the first attempts at area resolution on a per-page basis,
   providing immediate area context for FOs for resolution of
   percentage based expressions in most cases.
Corresponding properties
. Add corresponding property handling.
That should keep me (and anyone else who wants to become involved) busy 
for a while.

Peter
--
Peter B. West http://www.powerup.com.au/~pbwest/resume.html


Changes to Property sub-classes

2004-01-03 Thread Peter B. West
I have just made a series of changes to property processing in
alt.design, intended to 1) make the process look more familiar to Java
familiars, and 2) speed things up a bit.
property = (Property)(pclass.newInstance());
properties[propindex] = property;
// Set inheritance value
if ((inherited[propindex]
= pclass.getField(inherited).getInt(null))
!= Property.NO)
inheritedprops.set(propindex);
// Set datatypes
datatypes[propindex] = pclass.getField(dataTypes).getInt(null);
// Set initialValueTypes
initialValueTypes[propindex] =
pclass.getField(initialValueType).getInt(null);
traitMappings[propindex] =
pclass.getField(traitMapping).getInt(null);
Basically, the foregoing code, which used reflection to obtain
 public static fixed int
vales from the Property sub-classes, has been replaced by
// Instantiate the class
property = (Property)(pclass.newInstance());
properties[propindex] = property;
// Set inheritance value
if ((inherited[propindex]
= property.getInherited())
!= Property.NO)
inheritedprops.set(propindex);
// Set datatypes
datatypes[propindex] = property.getDataTypes();
// Set initialValueTypes
initialValueTypes[propindex] = property.getInitialValueType();
traitMappings[propindex] = property.getTraitMapping();
relying on the newly added getters in Property and its subclasses.
Because of all the bad press for reflection, I expected to see an
improvement of the speed of processing.  I was disappointed in this.
Unfortunately, I have only a poorly endowed laptop at the moment, so it
is difficult to get sound measurements while Eclipse and Mozilla are
running, but the results were inconclusive, sometimes recording faster
times for the original code, sometimes for the new version.  In any
case, the approach I originally took incurs no performance penalty under
1.4, and may even be slightly faster.
However, given the disturbance which seems to overcome Java programmers
when face by code which is not strictly OO, I have checked in the new
version.  It may make cross-fertilization with Finn's work easier.
Peter
--
Peter B. West http://www.powerup.com.au/~pbwest/resume.html



Unnecessary import of Constants

2004-01-03 Thread Peter B. West
Eclipse is still complaining to me 271 times of the unnecessary import 
of fo.Constants in the files of 
build/gensrc/org/apache/fop/fo/properties.  It also whinges about an 
unnecessary semi-colon in TextAlignLastMaker.java from the same 
directory.  It's actually an empty else condition.  Is anyone inclined 
to fix the generator, or is all of this going into CVS or is it all 
being superseded by Finn's new approach?

Peter
--
Peter B. West http://www.powerup.com.au/~pbwest/resume.html


Re: cvs commit: xml-fop/src/java/org/apache/fop/svg AbstractFOPTranscoder.java

2004-01-03 Thread Peter B. West
This one had a suspiciously large number of unused imports.  I couldn't 
see where they might be required, but someone else may have a more 
accurate idea of why they must be reinstated.

Peter

[EMAIL PROTECTED] wrote:
pbwest  2004/01/02 19:23:51

  Modified:src/java/org/apache/fop/svg AbstractFOPTranscoder.java
  Log:
  Remove unused imports to quieten Eclipse.
  
  Revision  ChangesPath
  1.4   +0 -6  xml-fop/src/java/org/apache/fop/svg/AbstractFOPTranscoder.java
  
  Index: AbstractFOPTranscoder.java
  ===
  RCS file: /home/cvs/xml-fop/src/java/org/apache/fop/svg/AbstractFOPTranscoder.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- AbstractFOPTranscoder.java	7 Nov 2003 21:54:32 -	1.3
  +++ AbstractFOPTranscoder.java	3 Jan 2004 03:23:51 -	1.4
  @@ -50,17 +50,12 @@
*/ 
   package org.apache.fop.svg;
   
  -import java.awt.Dimension;
  -import java.awt.geom.AffineTransform;
  -import java.awt.geom.Dimension2D;
  -
   import org.xml.sax.EntityResolver;
   
   import org.apache.avalon.framework.logger.ConsoleLogger;
   import org.apache.avalon.framework.logger.LogEnabled;
   import org.apache.avalon.framework.logger.Logger;
   import org.apache.batik.bridge.UserAgent;
  -import org.apache.batik.bridge.UserAgentAdapter;
   import org.apache.batik.dom.svg.SVGDOMImplementation;
   import org.apache.batik.dom.util.DocumentFactory;
   import org.apache.batik.transcoder.ErrorHandler;
  @@ -70,7 +65,6 @@
   import org.apache.batik.transcoder.image.ImageTranscoder;
   import org.apache.batik.transcoder.keys.BooleanKey;
   import org.apache.batik.util.SVGConstants;
  -import org.apache.batik.util.XMLResourceDescriptor;
   import org.w3c.dom.DOMImplementation;
   
   /**


--
Peter B. West http://www.powerup.com.au/~pbwest/resume.html


Recent tidying of alt.design

2004-01-03 Thread Peter B. West
Recent minor changes to alt.design triggered by comments from John 
Austin.  In particular, John drew my attention to HashMap 
initialization.  I naively assumed that providing an initial size to a 
HashMap would take account of the default load factor.  Re-reading the 
documentation, I came to the conclusion (with John) that this was not 
the case.  That is, creating a hash with
  hm = new HashMap(20);
then adding 20 items to it, will force a rehash after 75% of the items 
have been added.  Silly as it seems, that appears to be the way of it. 
Does anyone else have any experience of this?

Peter
--
Peter B. West http://www.powerup.com.au/~pbwest/resume.html


Re: AW: help with upload the ssh key

2004-01-03 Thread Peter B. West
Glen Mazza wrote:
Thanks, Peter, that helped a lot--I downloaded
puttygen and am working with it now.  Three more
questions if anyone can help:
1) I guess we're to use SSH2 and not SSH1, but does it
matter whether we use DSA or RSA?  Is one much slower
than the other?  I'll use DSA--it apparently works for
you and Joerg.
I don't know whether DSA or RSA is preferable, but SSH2 is definitely 
preferable to SSH1.

2) Also, you placed your public key in
authorized_keys, not authorized_keys2 like Joerg
has.  (Both of you are using DSA apparently.) Also,
PuttyGen seems to indicate that authorized_keys is
only for SSH1/RSA and authorized_keys2 is for SSH2
(RSA or DSA version).  Does this matter--shouldn't you
have yours in authorized_keys2?
When I set mine up (at the same time as Joerg) I recall having to use 
authorized_keys2 (and biting off chunks of my keyboard discovering 
that.)  Since then, I think the situation has changed and the use of 
authorized_keys2 is deprecated (or so I was told recently on a RH9 list.)

3) To use Putty on my work computer (besides my one at
home--where I've just created the key), should I
create another private/public key pair, and append the
public key to my authorized_keys/keys2 file, or just
transfer my private key to the second computer (via
floppy disk, etc.)--what is the more usual/accepted
practice?
When I was working with Putty to a Linux server, I found that it was 
easiest to generate the keys on the linux machine, move the private key 
 to Windows, and use the import facility in Putty.

Work environments tend to be a bit insecure, especially it you are using 
pageant (or ssh-agent on linux) to save having to key in the passphrase. 
  If you are accessing the repository from both your work and home 
machines though, it doesn't seem to make much sense to have different keys.

I used the key i have already used for accessing
jfor's cvs repository at
sourceforge. I created the key about 6 month ago
with puttygen. I ran it on
my local computer (win2000 prof.).
But you cannot use the files which puttygen creates
when you click on one of
the save buttons. Instead i copy-and-pasted the
content of the Public key
for pasting into OpenSSH authorized_keys2
file-textbox.
Peter
--
Peter B. West http://www.powerup.com.au/~pbwest/resume.html


DO NOT REPLY [Bug 25881] - [PATCH] relative font-size gets calculated twice.

2004-01-03 Thread bugzilla
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=25881.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=25881

[PATCH] relative font-size gets calculated twice.





--- Additional Comments From [EMAIL PROTECTED]  2004-01-04 05:35 ---
Finn,

I ran this with your sample .FO before and after applying the patch, and saw no 
difference in the output.

Two days ago, however, I added in Simon's patch preventing the duplication of 
processing base-only attributes (including font-size) in 
ConvertAttributeToProperty():

if (subPropertyName == null) { // base attribute only found
/* Do nothing if the base property has already been created.
 * This is e.g. the case when a compound attribute was
 * specified before the base attribute; in these cases
 * the base attribute was already created in 
 * findBaseProperty()
 */
if (getExplicitBaseProp(basePropertyName) != null) {
return;
}

I think Simon's change already fixes the problem you're mentioning here--so 
your patch may not be needed.  Certainly, at least on my side, it appears the 
second processing of font-size is being ignored now.  

Comments?

Thanks,
Glen


cvs commit: xml-fop/src/codegen properties.xsl

2004-01-03 Thread gmazza
gmazza  2004/01/03 21:42:04

  Modified:src/codegen properties.xsl
  Log:
  Fix to remove unnecessary imports of Constants interface.
  
  Revision  ChangesPath
  1.25  +6 -2  xml-fop/src/codegen/properties.xsl
  
  Index: properties.xsl
  ===
  RCS file: /home/cvs/xml-fop/src/codegen/properties.xsl,v
  retrieving revision 1.24
  retrieving revision 1.25
  diff -u -r1.24 -r1.25
  --- properties.xsl31 Dec 2003 01:41:46 -  1.24
  +++ properties.xsl4 Jan 2004 05:42:03 -   1.25
  @@ -311,7 +311,7 @@
   
   redirect:write select=concat($classname, '.java')
 xsl:textpackage org.apache.fop.fo.properties;
  -import org.apache.fop.fo.Constants;
  +  
   /xsl:text
 xsl:if test=.//keyword-equiv or ./name[.='generic-color']
   xsl:text
  @@ -338,6 +338,10 @@
   xsl:text
   import org.apache.fop.apps.FOPException;/xsl:text
 /xsl:if
  +  xsl:if test=.//enumeration and @type='generic'
  +xsl:text
  +import org.apache.fop.fo.Constants;/xsl:text
  +/xsl:if
 xsl:text
   
   public class /xsl:text
  
  
  

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Unnecessary import of Constants

2004-01-03 Thread Glen Mazza
Sorry about that; I don't use Eclipse.  

I just fixed the Constants problem--but the
TextAlignLastMaker will be more difficult--it appears
to have been there for a long time, well before my
recent changes.

Glen


--- Peter B. West [EMAIL PROTECTED] wrote:
 Eclipse is still complaining to me 271 times of the
 unnecessary import 
 of fo.Constants in the files of 
 build/gensrc/org/apache/fop/fo/properties.  It also
 whinges about an 
 unnecessary semi-colon in TextAlignLastMaker.java
 from the same 
 directory.  It's actually an empty else condition. 
 Is anyone inclined 
 to fix the generator, or is all of this going into
 CVS or is it all 
 being superseded by Finn's new approach?
 
 Peter
 -- 
 Peter B. West
 http://www.powerup.com.au/~pbwest/resume.html
 


__
Do you Yahoo!?
New Yahoo! Photos - easier uploading and sharing.
http://photos.yahoo.com/


Re: Recent tidying of alt.design

2004-01-03 Thread Glen Mazza
I checked the API, what you describe below is just as
it states:

http://java.sun.com/j2se/1.4.2/docs/api/java/util/HashMap.html

Its guidance on proper initial value and load factor
sizing may be of help for you.

Glen

--- Peter B. West [EMAIL PROTECTED] wrote:
 Recent minor changes to alt.design triggered by
 comments from John 
 Austin.  In particular, John drew my attention to
 HashMap 
 initialization.  I naively assumed that providing an
 initial size to a 
 HashMap would take account of the default load
 factor.  Re-reading the 
 documentation, I came to the conclusion (with John)
 that this was not 
 the case.  That is, creating a hash with
hm = new HashMap(20);
 then adding 20 items to it, will force a rehash
 after 75% of the items 
 have been added.  Silly as it seems, that appears to
 be the way of it. 
 Does anyone else have any experience of this?
 
 Peter
 -- 
 Peter B. West
 http://www.powerup.com.au/~pbwest/resume.html
 


__
Do you Yahoo!?
New Yahoo! Photos - easier uploading and sharing.
http://photos.yahoo.com/