foray-commit Mailing List for FOray (Page 301)
Modular XSL-FO Implementation for Java.
Status: Alpha
Brought to you by:
victormote
You can subscribe to this list here.
| 2006 |
Jan
|
Feb
|
Mar
(139) |
Apr
(98) |
May
(250) |
Jun
(394) |
Jul
(84) |
Aug
(13) |
Sep
(420) |
Oct
(186) |
Nov
(1) |
Dec
(3) |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2007 |
Jan
(108) |
Feb
(202) |
Mar
(291) |
Apr
(247) |
May
(374) |
Jun
(227) |
Jul
(231) |
Aug
(60) |
Sep
(31) |
Oct
(45) |
Nov
(18) |
Dec
|
| 2008 |
Jan
(38) |
Feb
(71) |
Mar
(142) |
Apr
|
May
(59) |
Jun
(6) |
Jul
(10) |
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
| 2009 |
Jan
(12) |
Feb
(4) |
Mar
(88) |
Apr
(121) |
May
(17) |
Jun
(30) |
Jul
|
Aug
(5) |
Sep
|
Oct
(1) |
Nov
|
Dec
|
| 2010 |
Jan
(11) |
Feb
(76) |
Mar
(11) |
Apr
|
May
(11) |
Jun
|
Jul
|
Aug
(44) |
Sep
(14) |
Oct
(7) |
Nov
|
Dec
|
| 2011 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(9) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(10) |
Nov
|
Dec
|
| 2012 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
(3) |
Jul
(4) |
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
| 2016 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
(168) |
| 2017 |
Jan
(77) |
Feb
(11) |
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
| 2018 |
Jan
|
Feb
|
Mar
(1) |
Apr
(6) |
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
| 2019 |
Jan
|
Feb
(88) |
Mar
(118) |
Apr
(1) |
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
| 2020 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(6) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
(141) |
| 2021 |
Jan
(170) |
Feb
(20) |
Mar
|
Apr
|
May
|
Jun
|
Jul
(1) |
Aug
|
Sep
|
Oct
(62) |
Nov
(189) |
Dec
(162) |
| 2022 |
Jan
(201) |
Feb
(118) |
Mar
(8) |
Apr
|
May
(2) |
Jun
(47) |
Jul
(19) |
Aug
(14) |
Sep
(3) |
Oct
|
Nov
(28) |
Dec
(235) |
| 2023 |
Jan
(112) |
Feb
(23) |
Mar
(2) |
Apr
(2) |
May
|
Jun
(1) |
Jul
|
Aug
(70) |
Sep
(92) |
Oct
(20) |
Nov
(1) |
Dec
(1) |
| 2024 |
Jan
|
Feb
|
Mar
(1) |
Apr
(1) |
May
(14) |
Jun
(11) |
Jul
(1) |
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
| 2025 |
Jan
(10) |
Feb
(29) |
Mar
|
Apr
(162) |
May
(245) |
Jun
(83) |
Jul
|
Aug
(1) |
Sep
|
Oct
|
Nov
(4) |
Dec
(23) |
| 2026 |
Jan
(119) |
Feb
(335) |
Mar
(103) |
Apr
(43) |
May
(154) |
Jun
(107) |
Jul
(187) |
Aug
(4) |
Sep
|
Oct
|
Nov
|
Dec
|
|
From: <vic...@us...> - 2006-06-08 02:11:08
|
Revision: 7440 Author: victormote Date: 2006-06-07 11:29:27 -0700 (Wed, 07 Jun 2006) ViewCVS: http://svn.sourceforge.net/foray/?rev=7440&view=rev Log Message: ----------- 1. Fix overridding method that didn't change its signature when the overridden method did. 2. Remove debugging code. Modified Paths: -------------- trunk/foray/foray-pioneer/src/java/org/foray/pioneer/FONodePL.java Modified: trunk/foray/foray-pioneer/src/java/org/foray/pioneer/FONodePL.java =================================================================== --- trunk/foray/foray-pioneer/src/java/org/foray/pioneer/FONodePL.java 2006-06-07 18:29:19 UTC (rev 7439) +++ trunk/foray/foray-pioneer/src/java/org/foray/pioneer/FONodePL.java 2006-06-07 18:29:27 UTC (rev 7440) @@ -68,9 +68,6 @@ protected PioneerLS layout; public FONodePL(FONode realFObj, PioneerLS layout) { - if (realFObj == null) { - return; - } this.realFONode = realFObj; realFObj.setProxy(this); this.layout = layout; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
|
From: <vic...@us...> - 2006-06-08 02:11:07
|
Revision: 7439 Author: victormote Date: 2006-06-07 11:29:19 -0700 (Wed, 07 Jun 2006) ViewCVS: http://svn.sourceforge.net/foray/?rev=7439&view=rev Log Message: ----------- 1. Fix overridding method that didn't change its signature when the overridden method did. 2. Remove debugging code. Modified Paths: -------------- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/PageSequence.java Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/PageSequence.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/PageSequence.java 2006-06-07 18:08:03 UTC (rev 7438) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/PageSequence.java 2006-06-07 18:29:19 UTC (rev 7439) @@ -177,7 +177,7 @@ return pageNumberGenerator.makeFormattedPageNumber(pageNumber); } - public org.axsl.foR.fo.Flow getFlow() { + public org.axsl.foR.fo.Flow getFlow(FOContext context) { return this.flow; } @@ -216,7 +216,7 @@ return spm; } if (pageSequenceMaster != null) { - Flow flow = getFlow(); + Flow flow = getFlow(context); spm = pageSequenceMaster.getNextSimplePageMaster( ((pageNumberInDocument % 2) == 1), isBlank); Region region = (Region) spm.getRegionBody(); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
|
From: <vic...@us...> - 2006-06-07 18:08:24
|
Revision: 7438 Author: victormote Date: 2006-06-07 11:08:03 -0700 (Wed, 07 Jun 2006) ViewCVS: http://svn.sourceforge.net/foray/?rev=7438&view=rev Log Message: ----------- Conform to axsl changes: Use new FOContext interface to provide information to the FOTree. Modified Paths: -------------- trunk/foray/foray-pioneer/src/java/org/foray/pioneer/AbstractTableBodyPL.java trunk/foray/foray-pioneer/src/java/org/foray/pioneer/BlockPL.java trunk/foray/foray-pioneer/src/java/org/foray/pioneer/ContinuedLabelPL.java trunk/foray/foray-pioneer/src/java/org/foray/pioneer/ExternalGraphicPL.java trunk/foray/foray-pioneer/src/java/org/foray/pioneer/FONodePL.java trunk/foray/foray-pioneer/src/java/org/foray/pioneer/PioneerLS.java trunk/foray/foray-pioneer/src/java/org/foray/pioneer/RowSpanMgr.java trunk/foray/foray-pioneer/src/java/org/foray/pioneer/TableCellPL.java trunk/foray/foray-pioneer/src/java/org/foray/pioneer/TableColumnPL.java trunk/foray/foray-pioneer/src/java/org/foray/pioneer/TablePL.java trunk/foray/foray-pioneer/src/java/org/foray/pioneer/TableRowPL.java Modified: trunk/foray/foray-pioneer/src/java/org/foray/pioneer/AbstractTableBodyPL.java =================================================================== --- trunk/foray/foray-pioneer/src/java/org/foray/pioneer/AbstractTableBodyPL.java 2006-06-07 18:05:55 UTC (rev 7437) +++ trunk/foray/foray-pioneer/src/java/org/foray/pioneer/AbstractTableBodyPL.java 2006-06-07 18:08:03 UTC (rev 7438) @@ -32,6 +32,7 @@ import org.axsl.areaW.NormalBlockArea; import org.axsl.areaW.TableArea; import org.axsl.common.Constants; +import org.axsl.foR.FOContext; import org.axsl.foR.FONode; import org.axsl.foR.fo.AbstractTableBody; import org.axsl.foR.fo.Marker; @@ -64,23 +65,23 @@ return ((GenericContainer)areaContainerRef.get()).getYPosition(); } - public int getHeight() { - return ((GenericContainer)areaContainerRef.get()).crBPD() - + getReal().traitSpaceBeforeOptimum() - + getReal().traitSpaceAfterOptimum(); + public int getHeight(FOContext context) { + return ((GenericContainer)areaContainerRef.get()).crBPD() + + getReal().traitSpaceBeforeOptimum(context) + + getReal().traitSpaceAfterOptimum(context); } public void removeLayout(Area area) { if (areaContainerRef != null) { area.removeChild((GenericContainer)areaContainerRef.get()); } - if (getReal().traitSpaceBeforeOptimum() != 0) { + if (getReal().traitSpaceBeforeOptimum(area) != 0) { area.incrementProgressionDimension(-getReal() - .traitSpaceBeforeOptimum()); + .traitSpaceBeforeOptimum(area)); } - if (getReal().traitSpaceAfterOptimum() != 0) { + if (getReal().traitSpaceAfterOptimum(area) != 0) { area.incrementProgressionDimension(-getReal() - .traitSpaceAfterOptimum()); + .traitSpaceAfterOptimum(area)); } resetProgress(); } @@ -113,7 +114,7 @@ public int layout(Area area) throws AreaWException { AbstractTableBody node = getReal(); TableArea tableArea = (TableArea) area; - Table table = node.getNearestTable(); + Table table = node.getNearestTable(area); if (getProgress() == FONodePL.BREAK_AFTER) { return Status.OK; } @@ -135,9 +136,10 @@ } - if ((node.traitSpaceBeforeOptimum() != 0) && (getProgress() == 0)) { + if ((node.traitSpaceBeforeOptimum(area) != 0) + && (getProgress() == 0)) { area.incrementProgressionDimension(node - .traitSpaceBeforeOptimum()); + .traitSpaceBeforeOptimum(area)); } /* @@ -179,7 +181,7 @@ TableRowPL rowPL = (TableRowPL) getLayoutProxy(row); rowPL.setRowSpanMgr(rowSpanMgr); - if (row.traitKeepWithPreviousWithinColumn() > 0 + if (row.traitKeepWithPreviousWithinColumn(area) > 0 && lastRow != null && keepWith.indexOf(lastRow) == -1) { keepWith.add(lastRow); @@ -219,9 +221,9 @@ area.incrementProgressionDimension(areaContainer.crBPD()); if (i == numChildren - 1) { setProgress(FONodePL.BREAK_AFTER); - if (node.traitSpaceAfterOptimum() != 0) { + if (node.traitSpaceAfterOptimum(area) != 0) { area.incrementProgressionDimension( - node.traitSpaceAfterOptimum()); + node.traitSpaceAfterOptimum(area)); } } return status; @@ -270,8 +272,9 @@ } area.incrementProgressionDimension(areaContainer.crBPD()); - if (node.traitSpaceAfterOptimum() != 0) { - area.incrementProgressionDimension(node.traitSpaceAfterOptimum()); + if (node.traitSpaceAfterOptimum(area) != 0) { + area.incrementProgressionDimension( + node.traitSpaceAfterOptimum(area)); } return Status.OK; Modified: trunk/foray/foray-pioneer/src/java/org/foray/pioneer/BlockPL.java =================================================================== --- trunk/foray/foray-pioneer/src/java/org/foray/pioneer/BlockPL.java 2006-06-07 18:05:55 UTC (rev 7437) +++ trunk/foray/foray-pioneer/src/java/org/foray/pioneer/BlockPL.java 2006-06-07 18:08:03 UTC (rev 7438) @@ -128,14 +128,15 @@ // no break if last in area tree, or trailing in context // area - int breakAfterStatus = Status.checkBreakAfter(node.traitBreakAfter()); + int breakAfterStatus = Status.checkBreakAfter( + node.traitBreakAfter(area)); if (breakAfterStatus != Status.OK) { setProgress(FONodePL.BREAK_AFTER); blockArea = null; return breakAfterStatus; } - if (node.traitKeepWithNextWithinColumn() > 0 - || node.traitKeepWithNextWithinPage() > 0) { + if (node.traitKeepWithNextWithinColumn(area) > 0 + || node.traitKeepWithNextWithinPage(area) > 0) { return Status.KEEP_WITH_NEXT; } return Status.OK; Modified: trunk/foray/foray-pioneer/src/java/org/foray/pioneer/ContinuedLabelPL.java =================================================================== --- trunk/foray/foray-pioneer/src/java/org/foray/pioneer/ContinuedLabelPL.java 2006-06-07 18:05:55 UTC (rev 7437) +++ trunk/foray/foray-pioneer/src/java/org/foray/pioneer/ContinuedLabelPL.java 2006-06-07 18:08:03 UTC (rev 7438) @@ -60,7 +60,7 @@ } // See if ancestor table has generated any areas yet. - Table table = label.getNearestTable(); + Table table = label.getNearestTable(area); FOLinkage linkage = (FOLinkage) table.getResult(); if (linkage != null && linkage.qtyAreasGenerated() > 0) { int numChildren = label.getChildren().size(); Modified: trunk/foray/foray-pioneer/src/java/org/foray/pioneer/ExternalGraphicPL.java =================================================================== --- trunk/foray/foray-pioneer/src/java/org/foray/pioneer/ExternalGraphicPL.java 2006-06-07 18:05:55 UTC (rev 7437) +++ trunk/foray/foray-pioneer/src/java/org/foray/pioneer/ExternalGraphicPL.java 2006-06-07 18:08:03 UTC (rev 7438) @@ -51,9 +51,9 @@ org.axsl.areaW.Area parentForDimensions = area.nearestGeneratedByBlockLevelFO(); - int height = node.viewportBPD(parentForDimensions.crBPD()); + int height = node.viewportBPD(area, parentForDimensions.crBPD()); if (area.progressionDimensionAvailable() - < (height + node.traitSpaceBeforeOptimum())) { + < (height + node.traitSpaceBeforeOptimum(area))) { return Status.AREA_FULL_NONE; } Modified: trunk/foray/foray-pioneer/src/java/org/foray/pioneer/FONodePL.java =================================================================== --- trunk/foray/foray-pioneer/src/java/org/foray/pioneer/FONodePL.java 2006-06-07 18:05:55 UTC (rev 7437) +++ trunk/foray/foray-pioneer/src/java/org/foray/pioneer/FONodePL.java 2006-06-07 18:08:03 UTC (rev 7438) @@ -68,6 +68,9 @@ protected PioneerLS layout; public FONodePL(FONode realFObj, PioneerLS layout) { + if (realFObj == null) { + return; + } this.realFONode = realFObj; realFObj.setProxy(this); this.layout = layout; Modified: trunk/foray/foray-pioneer/src/java/org/foray/pioneer/PioneerLS.java =================================================================== --- trunk/foray/foray-pioneer/src/java/org/foray/pioneer/PioneerLS.java 2006-06-07 18:05:55 UTC (rev 7437) +++ trunk/foray/foray-pioneer/src/java/org/foray/pioneer/PioneerLS.java 2006-06-07 18:08:03 UTC (rev 7438) @@ -126,7 +126,7 @@ public void processPageSequence(PageCollection pageCollection) throws AreaWException { PageSequence pageSeq = pageCollection.getPageSequence(); - org.axsl.foR.fo.Flow flow = pageSeq.getFlow(); + org.axsl.foR.fo.Flow flow = pageSeq.getFlow(pageCollection); flow.setProxy(new FlowPL(flow, this)); pageCollection.padPagesAtBeginning(); @@ -202,7 +202,7 @@ public int checkBreakBefore(FObj node, Area area) { if (!(area instanceof NormalFlowRA)) { - switch (node.traitBreakBefore()) { + switch (node.traitBreakBefore(area)) { case Constants.FOVAL_PAGE: return Status.FORCE_PAGE_BREAK; case Constants.FOVAL_ODD_PAGE: @@ -216,7 +216,7 @@ } } NormalFlowRA colArea = (NormalFlowRA)area; - switch (node.traitBreakBefore()) { + switch (node.traitBreakBefore(area)) { case Constants.FOVAL_PAGE: { // if first ColumnArea, and empty, return OK if (!colArea.hasChildren() && (colArea.siblingIndex() == 0)) { Modified: trunk/foray/foray-pioneer/src/java/org/foray/pioneer/RowSpanMgr.java =================================================================== --- trunk/foray/foray-pioneer/src/java/org/foray/pioneer/RowSpanMgr.java 2006-06-07 18:05:55 UTC (rev 7437) +++ trunk/foray/foray-pioneer/src/java/org/foray/pioneer/RowSpanMgr.java 2006-06-07 18:08:03 UTC (rev 7438) @@ -60,7 +60,8 @@ totalRowHeight += rowHeight; if (--rowsRemaining == 0) { if (cell != null) { - getTableCellPL().setRowHeight(totalRowHeight); + /* TODO: Fix FOContext item below. */ + getTableCellPL().setRowHeight(null, totalRowHeight); } return true; } Modified: trunk/foray/foray-pioneer/src/java/org/foray/pioneer/TableCellPL.java =================================================================== --- trunk/foray/foray-pioneer/src/java/org/foray/pioneer/TableCellPL.java 2006-06-07 18:05:55 UTC (rev 7437) +++ trunk/foray/foray-pioneer/src/java/org/foray/pioneer/TableCellPL.java 2006-06-07 18:08:03 UTC (rev 7438) @@ -25,11 +25,11 @@ package org.foray.pioneer; import org.axsl.areaW.Area; +import org.axsl.areaW.AreaWException; import org.axsl.areaW.TableCellArea; import org.axsl.areaW.TableRowContainer; - -import org.axsl.areaW.AreaWException; import org.axsl.common.Constants; +import org.axsl.foR.FOContext; import org.axsl.foR.FObj; import org.axsl.foR.fo.TableCell; @@ -54,11 +54,11 @@ * adjustment for collapse style (because current scheme makes cell * overestimate the allocation height). */ - public int getHeight() { + public int getHeight(FOContext context) { return areaContainer.crBPD() - + getReal().traitBorderSeparationBPD() - - (getReal().traitBorderTopWidth() - + getReal().traitBorderBottomWidth()) + + getReal().traitBorderSeparationBPD(context) + - (getReal().traitBorderTopWidth(context) + + getReal().traitBorderBottomWidth(context)) / 2; } @@ -69,10 +69,10 @@ * the allocation height of all the cells in the row, including any * border separation values. */ - public void setRowHeight(int h) { - int delta = h - getHeight(); + public void setRowHeight(FOContext context, int h) { + int delta = h - getHeight(context); // cellArea.increaseHeight(h + borderHeight/2 - cellArea.getHeight()); - if (getReal().traitDisplayAlign() == Constants.FOVAL_AUTO) { + if (getReal().traitDisplayAlign(context) == Constants.FOVAL_AUTO) { // Must get info for all cells starting in row! // verticalAlign can be BEFORE or BASELINE // For now just treat like "before" @@ -83,10 +83,10 @@ return; } // Vertical cell alignment - short verticalAlign = getReal().traitDisplayAlign(); + short verticalAlign = getReal().traitDisplayAlign(context); if (verticalAlign == Constants.FOVAL_AUTO) { // Depends on all cells starting in row - verticalAlign = getReal().traitAlignmentBaseline(); + verticalAlign = getReal().traitAlignmentBaseline(context); } switch (verticalAlign) { case Constants.FOVAL_CENTER: @@ -145,7 +145,7 @@ bDone = true; // Adjust for minimum cell content height - int minCellHeight = node.traitBPDimensionMin(area.crBPD()); + int minCellHeight = node.traitBPDimensionMin(area, area.crBPD()); if (minCellHeight > cellArea.crBPD()) { cellArea.setProgressionDimension(minCellHeight); } Modified: trunk/foray/foray-pioneer/src/java/org/foray/pioneer/TableColumnPL.java =================================================================== --- trunk/foray/foray-pioneer/src/java/org/foray/pioneer/TableColumnPL.java 2006-06-07 18:05:55 UTC (rev 7437) +++ trunk/foray/foray-pioneer/src/java/org/foray/pioneer/TableColumnPL.java 2006-06-07 18:08:03 UTC (rev 7438) @@ -59,7 +59,7 @@ public int layout(Area area) throws AreaWException { TableColumn node = getFO(); TableArea tableArea = (TableArea) area; - Table table = node.getNearestTable(); + Table table = node.getNearestTable(area); if (getProgress() == FONodePL.BREAK_AFTER) { return Status.OK; } Modified: trunk/foray/foray-pioneer/src/java/org/foray/pioneer/TablePL.java =================================================================== --- trunk/foray/foray-pioneer/src/java/org/foray/pioneer/TablePL.java 2006-06-07 18:05:55 UTC (rev 7437) +++ trunk/foray/foray-pioneer/src/java/org/foray/pioneer/TablePL.java 2006-06-07 18:08:03 UTC (rev 7438) @@ -30,6 +30,7 @@ import org.axsl.areaW.AreaWException; import org.axsl.common.Constants; +import org.axsl.foR.FOContext; import org.axsl.foR.FONode; import org.axsl.foR.fo.Marker; import org.axsl.foR.fo.Table; @@ -78,15 +79,15 @@ } setProgress(0); - if (node.traitBreakBefore() == Constants.FOVAL_PAGE) { + if (node.traitBreakBefore(area) == Constants.FOVAL_PAGE) { return Status.FORCE_PAGE_BREAK; } - if (node.traitBreakBefore() == Constants.FOVAL_ODD_PAGE) { + if (node.traitBreakBefore(area) == Constants.FOVAL_ODD_PAGE) { return Status.FORCE_PAGE_BREAK_ODD; } - if (node.traitBreakBefore() == Constants.FOVAL_EVEN_PAGE) { + if (node.traitBreakBefore(area) == Constants.FOVAL_EVEN_PAGE) { return Status.FORCE_PAGE_BREAK_EVEN; } @@ -151,7 +152,7 @@ headerPL.resetProgress(); } if (node.getTableFooter() != null - && ! node.traitTableOmitFooterAtBreak() + && ! node.traitTableOmitFooterAtBreak(area) &&!addedFooter) { tf = node.getTableFooter(); TableFooterPL tfPL = (TableFooterPL) @@ -186,12 +187,12 @@ area.incrementProgressionDimension( areaContainer.crBPD()); if (node.getTableFooter() != null - && ! node.traitTableOmitFooterAtBreak()) { + && ! node.traitTableOmitFooterAtBreak(area)) { // move footer to bottom of area and move up body - int yPosition = getTableFooterYPosition(tf); + int yPosition = getTableFooterYPosition(area, tf); tableBodyPL.setYPosition(yPosition); tableFooterPL.setYPosition(yPosition - + tableBodyPL.getHeight()); + + tableBodyPL.getHeight(area)); } setupColumnHeights(node, areaContainer); status = Status.AREA_FULL_SOME; @@ -200,19 +201,19 @@ } this.bodyCount++; if (node.getTableFooter() != null - && ! node.traitTableOmitFooterAtBreak()) { + && ! node.traitTableOmitFooterAtBreak(area)) { // move footer to bottom of area and move up body // space before and after footer will make this wrong - int yPosition = getTableFooterYPosition(tf); + int yPosition = getTableFooterYPosition(area, tf); tableBodyPL.setYPosition(yPosition); tableFooterPL.setYPosition(yPosition - + tableBodyPL.getHeight()); + + tableBodyPL.getHeight(area)); } } } if (node.getTableFooter() != null - && node.traitTableOmitFooterAtBreak()) { + && node.traitTableOmitFooterAtBreak(area)) { TableFooter tf = node.getTableFooter(); TableFooterPL tfPL = (TableFooterPL) getLayoutProxy(tf); int status = tfPL.layout(areaContainer); @@ -232,7 +233,7 @@ } } - int height = node.traitBPDimensionOpt(area.crBPD()); + int height = node.traitBPDimensionOpt(area, area.crBPD()); if (height != 0) { areaContainer.setProgressionDimension(height); } @@ -242,17 +243,17 @@ /* should this be combined into above? */ area.incrementProgressionDimension(areaContainer.crBPD()); - if (node.traitBreakAfter() == Constants.FOVAL_PAGE) { + if (node.traitBreakAfter(area) == Constants.FOVAL_PAGE) { setProgress(FONodePL.BREAK_AFTER); return Status.FORCE_PAGE_BREAK; } - if (node.traitBreakAfter() == Constants.FOVAL_ODD_PAGE) { + if (node.traitBreakAfter(area) == Constants.FOVAL_ODD_PAGE) { setProgress(FONodePL.BREAK_AFTER); return Status.FORCE_PAGE_BREAK_ODD; } - if (node.traitBreakAfter() == Constants.FOVAL_EVEN_PAGE) { + if (node.traitBreakAfter(area) == Constants.FOVAL_EVEN_PAGE) { setProgress(FONodePL.BREAK_AFTER); return Status.FORCE_PAGE_BREAK_EVEN; } @@ -272,9 +273,9 @@ } // FIXME: this seems odd. - public int getTableFooterYPosition(TableFooter tFooter) { + public int getTableFooterYPosition(FOContext context, TableFooter tFooter) { TableFooterPL tfPL = (TableFooterPL) getLayoutProxy(tFooter); - return tfPL.getYPosition() - tFooter.traitSpaceBeforeOptimum(); + return tfPL.getYPosition() - tFooter.traitSpaceBeforeOptimum(context); } public void setupColumnHeights(Table table, TableArea areaContainer) { @@ -290,7 +291,7 @@ public int calcFixedColumnWidths(TableArea tableArea, int maxAllocationWidth) { Table node = getTableFO(); - int tableWidth = node.traitIPDimensionOpt(tableArea.crIPD()); + int tableWidth = node.traitIPDimensionOpt(tableArea, tableArea.crIPD()); /* Accumulates the total table units used in columns in this table. */ double totalTableUnits = 0.0; /* @@ -315,17 +316,19 @@ * in any column which has only proportional units. */ if (tu > 0 && tu < tuMin - && column.traitColumnWidth(tableWidth) == 0) { + && column.traitColumnWidth(tableArea, + tableWidth) == 0) { tuMin = tu; } totalTableUnits += tu; - totalFixedWidth += column.traitColumnWidth(tableWidth); + totalFixedWidth += column.traitColumnWidth(tableArea, + tableWidth); } } double dWidthFactor = 0.0; double dUnitLength = 0.0; - setIPD((totalTableUnits > 0.0), maxAllocationWidth); + setIPD(tableArea, (totalTableUnits > 0.0), maxAllocationWidth); if (totalTableUnits > 0.0) { int iProportionalWidth = 0; if (this.optIPD > totalFixedWidth) { @@ -391,7 +394,7 @@ * dUnitLength)); } else { //Fixed width - colWidth = column.traitColumnWidth(tableWidth); + colWidth = column.traitColumnWidth(tableArea, tableWidth); } // Check minimum values and adjust if necessary @@ -416,37 +419,38 @@ * standard getIPD... methods in FObj. Whatever is different should probably * be factored into methods that override (but use) the FObj methods. */ - private void setIPD(boolean bHasProportionalUnits, int maxAllocIPD) { + private void setIPD(FOContext context, boolean bHasProportionalUnits, + int maxAllocIPD) { Table node = getTableFO(); - if (node.traitIPDimensionMax(maxAllocIPD) >= 0) { - this.maxIPD = node.traitIPDimensionMax(maxAllocIPD); + if (node.traitIPDimensionMax(context, maxAllocIPD) >= 0) { + this.maxIPD = node.traitIPDimensionMax(context, maxAllocIPD); } else { this.maxIPD = maxAllocIPD; } - if (node.traitIPDimensionOpt(maxAllocIPD) < 0) { + if (node.traitIPDimensionOpt(context, maxAllocIPD) < 0) { this.optIPD = -1; } else { /* TODO: This looks like a bug. Should be getIPDOptimum()? */ - this.optIPD = node.traitIPDimensionMax(maxAllocIPD); + this.optIPD = node.traitIPDimensionMax(context, maxAllocIPD); } - if (node.traitIPDimensionMin(maxAllocIPD) < 0) { + if (node.traitIPDimensionMin(context, maxAllocIPD) < 0) { this.minIPD = -1; } else { - this.minIPD = node.traitIPDimensionMin(maxAllocIPD); + this.minIPD = node.traitIPDimensionMin(context, maxAllocIPD); } if (bHasProportionalUnits && this.optIPD < 0) { if (this.minIPD > 0) { - if (node.traitIPDimensionMax(maxAllocIPD) >= 0) { + if (node.traitIPDimensionMax(context, maxAllocIPD) >= 0) { this.optIPD = (minIPD + maxIPD)/2; } else { this.optIPD = this.minIPD; } } - else if (node.traitIPDimensionMax(maxAllocIPD) >= 0) { + else if (node.traitIPDimensionMax(context, maxAllocIPD) >= 0) { this.optIPD = this.maxIPD; } else { Modified: trunk/foray/foray-pioneer/src/java/org/foray/pioneer/TableRowPL.java =================================================================== --- trunk/foray/foray-pioneer/src/java/org/foray/pioneer/TableRowPL.java 2006-06-07 18:05:55 UTC (rev 7437) +++ trunk/foray/foray-pioneer/src/java/org/foray/pioneer/TableRowPL.java 2006-06-07 18:08:03 UTC (rev 7438) @@ -26,11 +26,11 @@ import org.axsl.areaW.AbstractTableContainer; import org.axsl.areaW.Area; -import org.axsl.areaW.TableRowContainer; - import org.axsl.areaW.AreaWException; import org.axsl.areaW.TableArea; +import org.axsl.areaW.TableRowContainer; import org.axsl.common.Constants; +import org.axsl.foR.FOContext; import org.axsl.foR.Keep; import org.axsl.foR.fo.TableCell; import org.axsl.foR.fo.TableRow; @@ -63,9 +63,9 @@ * Before starting layout for the first time, initialize information * about spanning rows, empty cells and spanning columns. */ - private void initCellArray() throws AreaWException { + private void initCellArray(FOContext context) throws AreaWException { TableRow node = getReal(); - List columns = node.getNearestTable().getTableColumns(); + List columns = node.getNearestTable(context).getTableColumns(); cellArray = new RowCellArray(rowSpanMgr, columns.size()); int colNum = 1; for (int i = 0; i < getReal().getChildren().size(); i++) { @@ -75,7 +75,7 @@ TableCell cell = (TableCell)getReal().getChildren().get(i); int numCols = cell.traitNumberColumnsSpanned(); - int cellColNum = cell.traitColumnNumber(); + int cellColNum = cell.traitColumnNumber(context); if (cellColNum == 0) { // Not explicitly specified, so put in next available colummn @@ -131,7 +131,7 @@ public int layout(Area area) throws AreaWException { TableRow node = getReal(); - List columns = node.getNearestTable().getTableColumns(); + List columns = node.getNearestTable(area).getTableColumns(); if (getProgress() == FONodePL.BREAK_AFTER) { return Status.OK; } @@ -141,7 +141,7 @@ // Only do this once. If the row is "thrown" and we start // layout over again, we can skip this. if (cellArray == null) { - initCellArray(); + initCellArray(area); // check to make sure this row hasn't been partially // laid out yet (with an id created already) } @@ -156,7 +156,7 @@ TableRowContainer areaContainer = container.makeTableRowContainer(node); /* Set a reasonable starting BPD for this row. */ - this.largestCellHeight = node.traitBPDimensionMin(area.crBPD()); + this.largestCellHeight = node.traitBPDimensionMin(area, area.crBPD()); // Flag indicaing whether any cell didn't fit in available space boolean someCellDidNotLayoutCompletely = false; @@ -206,7 +206,7 @@ int rowSpan = cell.traitNumberRowsSpanned(); int status = cellPL.layout(areaContainer); if (Status.isIncomplete(status)) { - if ((node.traitKeepTogetherWithinColumn() == Keep.ALWAYS + if ((node.traitKeepTogetherWithinColumn(area) == Keep.ALWAYS && bIgnoreKeepTogether == false) || (status == Status.AREA_FULL_NONE) || rowSpan > 1) { @@ -226,7 +226,7 @@ } } // else { // layout was complete for a particular cell - int h = cellPL.getHeight(); // allocation height of cell + int h = cellPL.getHeight(area); // allocation height of cell if (rowSpan > 1) { // pass cell fo or area??? rowSpanMgr.addRowSpan(cell, iColIndex, cell.traitNumberColumnsSpanned(), h, rowSpan, layout); @@ -243,7 +243,7 @@ && rowSpanMgr.isSpanned(iCol) == false) { TableCell cell = cellArray.getCell(iCol); TableCellPL cellPL = (TableCellPL) getLayoutProxy(cell); - cellPL.setRowHeight(largestCellHeight); + cellPL.setRowHeight(area, largestCellHeight); } } @@ -260,7 +260,7 @@ // Ignore break after if row span! return Status.KEEP_WITH_NEXT; } - short breakAfter = node.traitBreakAfter(); + short breakAfter = node.traitBreakAfter(area); if (breakAfter == Constants.FOVAL_PAGE) { setProgress(FONodePL.BREAK_AFTER); return Status.FORCE_PAGE_BREAK; @@ -280,7 +280,7 @@ setProgress(FONodePL.BREAK_AFTER); return Status.FORCE_COLUMN_BREAK; } - if (node.traitKeepWithNextWithinColumn() > Keep.AUTO) { + if (node.traitKeepWithNextWithinColumn(area) > Keep.AUTO) { return Status.KEEP_WITH_NEXT; } return Status.OK; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
|
From: <vic...@us...> - 2006-06-07 18:08:02
|
Revision: 7437 Author: victormote Date: 2006-06-07 11:05:55 -0700 (Wed, 07 Jun 2006) ViewCVS: http://svn.sourceforge.net/foray/?rev=7437&view=rev Log Message: ----------- Conform to axsl changes: Use new FOContext interface to provide information to the FOTree. Modified Paths: -------------- trunk/foray/foray-fotree/src/java/org/foray/fotree/FONode.java trunk/foray/foray-fotree/src/java/org/foray/fotree/FOText.java trunk/foray/foray-fotree/src/java/org/foray/fotree/FObj.java trunk/foray/foray-fotree/src/java/org/foray/fotree/FObjMixed.java trunk/foray/foray-fotree/src/java/org/foray/fotree/FObjScaled.java trunk/foray/foray-fotree/src/java/org/foray/fotree/PropertyList.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/AbstractFlow.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/BasicLink.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/Block.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/Bookmark.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/Character.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/ConditionalPageMasterReference.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/ExternalGraphic.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/Flow.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/LayoutMasterSet.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/Leader.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/ListItem.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/ListItemBody.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/ListItemLabel.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/Marker.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/PageNumber.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/PageNumberCitation.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/PageSequence.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/PageSequenceMaster.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/Region.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/RegionAfter.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/RegionBefore.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/RegionBody.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/RegionEnd.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/RegionStart.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/RepeatablePMAlternatives.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/RepeatablePMReference.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/Root.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/SimplePageMaster.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/SinglePageMasterReference.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/SubSequenceSpecifier.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/Table.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/TableColumn.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/Wrapper.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/AbsoluteDimension.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/AbsoluteOffset.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/AlignmentAdjust.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/AlignmentBaseline.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/AudioDial.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Azimuth.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/BackgroundImage.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/BackgroundPosition.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/BaselineShift.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Boolean.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/BorderPrecedence.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/BorderSeparation.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/BorderStyle.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/BorderWidth.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Character.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Clip.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Color.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/ColumnCount.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/ColumnGap.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/ColumnNumber.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/ColumnWidth.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/ContentDimension.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Country.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Cue.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/DestinationPlacementOffset.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/DisplayAlign.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/DominantBaseline.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Elevation.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Enumerated.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Extent.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/FontFamily.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/FontSize.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/FontSizeAdjust.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/FontStretch.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/FontStyle.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/FontVariant.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/FontWeight.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/ForcePageCount.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/GlyphOrientation.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/HyphLadderCount.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/HyphPushCharCount.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/HyphRemainCharCount.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Indent.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/InitialPageNumber.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Keep.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Language.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/LastLineEndIndent.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/LeaderLength.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/LeaderPatternWidth.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/LetterSpacing.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/LineHeight.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Margin.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/MaximumRepeats.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Name.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Orphans.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Padding.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/PageDimension.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Pause.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Pitch.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/PlayDuring.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/ProvDistanceBetween.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/ProvLabelSeparation.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/RefId.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/RelativeDimension.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/RelativeSpace.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Role.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/RuleThickness.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Script.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Size.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/SourceDocument.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/SpeechRate.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Src.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/TextAlign.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/TextAlignLast.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/TextAltitude.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/TextDecoration.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/TextDepth.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/TextIndent.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/TextShadow.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/TreatAsWordSpace.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/VoiceFamily.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Volume.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Widows.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/WordSpacing.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/WritingMode.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/ZIndex.java trunk/foray/foray-fotree/src/java/org/foray/fotree/value/FnBodyStart.java trunk/foray/foray-fotree/src/java/org/foray/fotree/value/FnFromParent.java trunk/foray/foray-fotree/src/java/org/foray/fotree/value/FnInheritedProp.java trunk/foray/foray-fotree/src/java/org/foray/fotree/value/FnLabelEnd.java trunk/foray/foray-fotree/src/java/org/foray/fotree/value/FnNearestSpecProp.java trunk/foray/foray-fotree/src/java/org/foray/fotree/value/FnProportionalColWidth.java Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/FONode.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/FONode.java 2006-06-07 18:05:37 UTC (rev 7436) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/FONode.java 2006-06-07 18:05:55 UTC (rev 7437) @@ -25,10 +25,16 @@ package org.foray.fotree; import org.foray.common.OrderedTreeNode; +import org.foray.fotree.fo.obj.Marker; +import org.axsl.foR.FOContext; import org.axsl.foR.FONodeProxy; import org.axsl.foR.FONodeResult; +import org.axsl.foR.FOTreeException; +import org.axsl.foR.fo.RetrieveMarker; +import javax.swing.tree.TreeNode; + /** * Base class for nodes in the formatting object tree. */ @@ -43,6 +49,39 @@ super(parent); } + /** + * Return this node's effective parent, cast as an FObj. + * This differs from the value returned by + * @param context TODO + * @return This node's effective parent. + */ + public FObj effectiveParent(FOContext context) { + TreeNode parent = this.getParent(); + if (parent instanceof Marker) { + if (context == null) { + return realParent(); + } + Marker marker = (Marker) parent; + RetrieveMarker retrieve; + try { + retrieve = context.getRetrieveMarker(marker); + } catch (FOTreeException e) { + return realParent(); + } + if (retrieve instanceof org.foray.fotree.fo.obj.RetrieveMarker) { + return (org.foray.fotree.fo.obj.RetrieveMarker) retrieve; + } else { + /* Hopefully this never happens. */ + return realParent(); + } + } + return realParent(); + } + + /** + * Return this node's real parent, cast as an FObj. + * @return This node's real parent. + */ public FObj realParent() { return (FObj) this.getParent(); } Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/FOText.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/FOText.java 2006-06-07 18:05:37 UTC (rev 7436) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/FOText.java 2006-06-07 18:05:55 UTC (rev 7437) @@ -27,6 +27,7 @@ import org.foray.common.XMLCharacter; import org.axsl.common.Constants; +import org.axsl.foR.FOContext; import org.axsl.foR.fo.Block; import org.axsl.foR.fo.Leader; import org.axsl.fontR.FontUse; @@ -70,10 +71,12 @@ public FOText(FObj parent, char[] chars) { super(parent); this.ca = chars; + /* TODO: Handle context better. */ + FOContext context = null; /* Convert the text as far as possible, store it, and set the status. * We cannot filter text-transform yet, because we may need subsequent * FOText instances. */ - this.ca = this.getPreTextTransformText(); + this.ca = this.getPreTextTransformText(context); this.filterStatus = FILTER_PRE_TRANSFORM; } @@ -117,21 +120,25 @@ * <li>linefeed-treatment. See XSL-FO Standard 1.0 Section 7.15.7.</li> * <li>text-transform. See XSL-FO Standard 1.0 Section 7.16.6.</li> * </ul> + * @param context TODO * * @return The text that should appear in the refined FO tree. */ - public char[] getRefinedText() { + public char[] getRefinedText(FOContext context) { + /* TODO: This needs to come from effectiveParent, with context. */ + FObj effectiveParent = this.realParent(); if (this.filterStatus >= FILTER_REFINED_FO_TREE) { /* The stored text has already been filtered. Just return it. */ return this.ca; } - char[] charArray = getPreTextTransformText(); + char[] charArray = getPreTextTransformText(context); // Now handle text-transform. - short textTransform = realParent().traitTextTransform(); + short textTransform = effectiveParent.traitTextTransform(context); if (textTransform != Constants.FOVAL_NONE) { for (int i = 0; i < charArray.length; i++) { - charArray[i] = applyTextTransform(charArray, i, textTransform); + charArray[i] = applyTextTransform(context, charArray, i, + textTransform); } } @@ -154,11 +161,13 @@ * is applied it does not create a stack overflow. This is possible because * text-transform looks at previous and subsequent FOText items, which must * inevitably look back at the original FOText instance.</p> + * @param context TODO * * @return The text that should appear in the refined FO tree, except that * text-transform is not applied. */ - private char[] getPreTextTransformText() { + private char[] getPreTextTransformText(FOContext context) { + FObj effectiveParent = this.effectiveParent(context); if (this.filterStatus >= FILTER_PRE_TRANSFORM) { /* The stored text has already been filtered. Just return it. */ return this.ca; @@ -166,11 +175,11 @@ /* Must handle white-space-treatment first. */ char[] workArray = applyWhiteSpaceTreatment(this.ca, - realParent().traitWhiteSpaceTreatment()); + effectiveParent.traitWhiteSpaceTreatment(context)); // Now handle linefeed-treatment. workArray = applyLinefeedTreatment(workArray, - realParent().traitLinefeedTreatment()); + effectiveParent.traitLinefeedTreatment(context)); /* Update this instance's text with the filtered value and update the * status. */ @@ -181,14 +190,15 @@ /** * Applies text-transform to one character of the array. + * @param context TODO * @param charArray The array which is being transformed. * @param index The 0-based index into charArray, which points to the * character being transformed. * @param textTransform The value of the text-transform enumerated property. * @return The transformed char. */ - private char applyTextTransform(char[] charArray, int index, - short textTransform) { + private char applyTextTransform(FOContext context, char[] charArray, + int index, short textTransform) { char c = charArray[index]; switch (textTransform) { /* This method not be entered if value is NONE. */ @@ -197,7 +207,7 @@ case Constants.FOVAL_LOWERCASE: return Character.toLowerCase(c); case Constants.FOVAL_CAPITALIZE: - if (isStartOfWord(charArray, index)) { + if (isStartOfWord(context, charArray, index)) { /* Use toTitleCase here. Apparently, some languages use a different character to represent a letter when using @@ -228,15 +238,17 @@ * ambiguous and appears to be definable by the user agent. * See http://lists.w3.org/Archives/Public/xsl-editors/2005AprJun/0006.html * for a discussion of this matter. - * + * @param context TODO * @param charArray The char[] being transformed. * @param index The 0-based index into charArray pointing to the character * that is being tested. + * * @return True iff the character at this location is the start of a new * word. */ - private boolean isStartOfWord(char[] charArray, int index) { - char prevChar = getRelativeCharInBlock(charArray, index, -1); + private boolean isStartOfWord(FOContext context, char[] charArray, + int index) { + char prevChar = getRelativeCharInBlock(context, charArray, index, -1); /* All we are really concerned about here is of what type prevChar is. If inputChar is not part of a word, then the Java conversions will (we hope) simply return inputChar. @@ -251,7 +263,8 @@ * as a possessive or a contraction, or might be a closing quote. */ case IS_WORD_CHAR_MAYBE: - char prevPrevChar = getRelativeCharInBlock(charArray, index, -2); + char prevPrevChar = getRelativeCharInBlock(context, charArray, + index, -2); switch (isWordChar(prevPrevChar)) { case IS_WORD_CHAR_TRUE: return false; @@ -356,17 +369,18 @@ * to a character in the current FOText. Treats all FOText objects within a * block as one unit, allowing text in adjoining FOText objects to be * returned if the parameters are outside of the current object. - * + * @param context TODO * @param charArray The charArray to be tested. * @param index 0-based index into charArray. * @param offset Signed integer with relative position within the block of * the character to return. To return the character immediately preceding i, * pass -1. To return the character immediately after i, pass 1. + * * @return the character in the offset position within the block; 0x0000 if * the offset points to an area outside of the block. */ - private char getRelativeCharInBlock(char[] charArray, int index, - int offset) { + private char getRelativeCharInBlock(FOContext context, char[] charArray, + int index, int offset) { // The easy case is where the desired character is in the same FOText int desiredIndex = index + offset; if (desiredIndex >= 0 && desiredIndex < charArray.length) { @@ -379,7 +393,7 @@ remainingOffset = offset - (charArray.length - 1 - index); FOText nextFOText = this.getNextContiguousTextInBlock(); while (nextFOText != null) { - char[] nextText = nextFOText.getPreTextTransformText(); + char[] nextText = nextFOText.getPreTextTransformText(context); if (nextText.length >= remainingOffset) { return nextText[remainingOffset - 1]; } @@ -392,7 +406,7 @@ remainingOffset = offset + index; FOText prevFOText = this.getPreviousContiguousTextInBlock(); while (prevFOText != null) { - char[] prevText = prevFOText.getPreTextTransformText(); + char[] prevText = prevFOText.getPreTextTransformText(context); if (prevText.length >= Math.abs(remainingOffset)) { return prevText[prevText.length + remainingOffset]; } @@ -436,6 +450,8 @@ * If any of these are not true, null is returned. */ private FOText getContiguousTextInBlock(FONode leafToTest) { + FObj effectiveParent = this.realParent(); + FOContext context = null; if (leafToTest == null) { return null; } @@ -444,13 +460,16 @@ } /* If either is within a Leader, they both need to be in the same one. */ - Leader thisLeader = this.realParent().getNearestLeader(); - Leader testLeader = leafToTest.realParent().getNearestLeader(); + Leader thisLeader = effectiveParent.getNearestLeader(context); + Leader testLeader = leafToTest.effectiveParent(context) + .getNearestLeader(context); if (thisLeader != testLeader) { return null; } - Block thisBlock = this.realParent().getContainingBlock(); - Block testBlock = leafToTest.realParent().getContainingBlock(); + Block thisBlock = this.effectiveParent(context).getContainingBlock( + context); + Block testBlock = leafToTest.effectiveParent(context) + .getContainingBlock(context); if (thisBlock != testBlock) { return null; } @@ -467,16 +486,18 @@ * * @return The text that should appear in the area tree. */ - public char[] getAreaTreeText() { + public char[] getAreaTreeText(FOContext context) { + FObj effectiveParent = this.realParent(); if (this.filterStatus >= FILTER_AREA_TREE) { /* The stored text has already been filtered. Just return it. */ return this.ca; } // Start with the refined FO Tree text - char[] returnArray = getRefinedText(); + char[] returnArray = getRefinedText(context); // Apply white-space-collapse. - boolean whiteSpaceCollapse = realParent().traitWhiteSpaceCollapse(); + boolean whiteSpaceCollapse = effectiveParent.traitWhiteSpaceCollapse( + context); returnArray = applyWhiteSpaceCollapse(returnArray, whiteSpaceCollapse); /* Set the instance text to the more refined value and update the @@ -487,56 +508,86 @@ } public char[] inlineText() { - return getAreaTreeText(); + /* TODO: Handle context better. */ + FOContext context = null; + return getAreaTreeText(context); } public FontUse inlinePrimaryFont() { - return realParent().getPrimaryFont(); + /* TODO: Handle context better. */ + FOContext context = null; + return effectiveParent(null).getPrimaryFont(context); } public FontUse inlineSecondaryFont(char c) { - return realParent().getSecondaryFont(c); + /* TODO: Handle context better. */ + FOContext context = null; + return effectiveParent(null).getSecondaryFont(context, c); } public int inlineFontSize() { - return realParent().traitFontSize(); + /* TODO: Handle context better. */ + FOContext context = null; + return effectiveParent(null).traitFontSize(context); } public int inlineLetterSpacingOptimum() { - return realParent().traitLetterSpacingOpt(); + /* TODO: Handle context better. */ + FOContext context = null; + return effectiveParent(null).traitLetterSpacingOpt(context); } public boolean inlineWrapOption() { - return (realParent().traitWrapOption() == Constants.FOVAL_WRAP); + /* TODO: Handle context better. */ + FOContext context = null; + return (effectiveParent(null).traitWrapOption(context) + == Constants.FOVAL_WRAP); } public boolean inlineHyphenate() { - return realParent().traitHyphenate(); + /* TODO: Handle context better. */ + FOContext context = null; + return effectiveParent(null).traitHyphenate(context); } public String inlineLanguage() { - return realParent().traitLanguage(); + /* TODO: Handle context better. */ + FOContext context = null; + return effectiveParent(null).traitLanguage(context); } public String inlineCountry() { - return realParent().traitCountry(); + /* TODO: Handle context better. */ + FOContext context = null; + return effectiveParent(null).traitCountry(context); } public int inlineHyphenationRemainCount() { - return realParent().traitHyphenationRemainCharacterCount(); + /* TODO: Handle context better. */ + FOContext context = null; + return effectiveParent(null).traitHyphenationRemainCharacterCount( + context); } public int inlineHyphenationPushCount() { - return realParent().traitHyphenationPushCharacterCount(); + /* TODO: Handle context better. */ + FOContext context = null; + return effectiveParent(null).traitHyphenationPushCharacterCount( + context); } public char inlineHyphenationCharacter() { - return realParent().traitHyphenationCharacter(); + /* TODO: Handle context better. */ + FOContext context = null; + return effectiveParent(null).traitHyphenationCharacter( + context); } public boolean inlineIsFauxSmallCaps() { - FObj parent = this.realParent(); - if (parent.traitFontVariant() != Constants.FOVAL_SMALL_CAPS) { + /* TODO: Handle context better. */ + FOContext context = null; + FObj parent = this.effectiveParent(context); + if (parent.traitFontVariant(context) != Constants.FOVAL_SMALL_CAPS) { return false; } /* @@ -550,7 +601,9 @@ } public int inlineFauxSmallCapsFontSize() { - return this.realParent().getFauxSmallCapFontSize(); + /* TODO: Handle context better. */ + FOContext context = null; + return this.effectiveParent(null).getFauxSmallCapFontSize(context); } public LineText nextContiguousLineText() { Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/FObj.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/FObj.java 2006-06-07 18:05:37 UTC (rev 7436) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/FObj.java 2006-06-07 18:05:55 UTC (rev 7437) @@ -27,6 +27,7 @@ import org.foray.common.XMLCharacter; import org.axsl.common.Constants; +import org.axsl.foR.FOContext; import org.axsl.foR.FOTreeException; import org.axsl.foR.ShadowEffect; import org.axsl.foR.Shape; @@ -185,65 +186,66 @@ /** * {@inheritDoc} */ - public org.axsl.foR.FObj getNearestAncestorGeneratingRA() { - if (realParent().traitIsReferenceArea()) { - return realParent(); + public org.axsl.foR.FObj getNearestAncestorGeneratingRA(FOContext context) { + if (effectiveParent(context).traitIsReferenceArea()) { + return effectiveParent(context); } - return realParent().getNearestAncestorGeneratingRA(); + return effectiveParent(context).getNearestAncestorGeneratingRA(context); } /** * @return Self or the nearest ancestor FObj that generates reference areas. */ - public org.axsl.foR.FObj getNearestGeneratingRA() { + public org.axsl.foR.FObj getNearestGeneratingRA(FOContext context) { if (this.traitIsReferenceArea()) { return this; } - return getNearestAncestorGeneratingRA(); + return getNearestAncestorGeneratingRA(context); } /** * {@inheritDoc} */ - public org.axsl.foR.fo.ListItem getNearestListItem() { - return realParent().getNearestListItem(); + public org.axsl.foR.fo.ListItem getNearestListItem(FOContext context) { + return effectiveParent(context).getNearestListItem(context); } /** * {@inheritDoc} */ - public org.axsl.foR.fo.ListBlock getNearestAncestorListBlock() { + public org.axsl.foR.fo.ListBlock getNearestAncestorListBlock( + FOContext context) { if (getParent() == null) { return null; } if (getParent() instanceof org.axsl.foR.fo.ListBlock) { return (org.axsl.foR.fo.ListBlock) getParent(); } - return realParent().getNearestAncestorListBlock(); + return effectiveParent(context).getNearestAncestorListBlock(context); } /** * {@inheritDoc} */ - public org.axsl.foR.fo.Root getRoot() { - return realParent().getRoot(); + public org.axsl.foR.fo.Root getRoot(FOContext context) { + return effectiveParent(context).getRoot(context); } /** * {@inheritDoc} */ - public org.axsl.foR.fo.Block getContainingBlock() { - return realParent().getContainingBlock(); + public org.axsl.foR.fo.Block getContainingBlock(FOContext context) { + return effectiveParent(context).getContainingBlock(context); } /** * {@inheritDoc} */ - public org.axsl.foR.fo.Flow getFlow() { + public org.axsl.foR.fo.Flow getFlow(FOContext context) { if (getParent() == null) { return null; } - return realParent().getFlow(); + return effectiveParent(context).getFlow(context); } public FOTreeBuilder getFOTreeBuilder() { @@ -257,29 +259,29 @@ /** * {@inheritDoc} */ - public org.axsl.foR.fo.Table getNearestTable() { - return realParent().getNearestTable(); + public org.axsl.foR.fo.Table getNearestTable(FOContext context) { + return effectiveParent(context).getNearestTable(context); } /** * {@inheritDoc} */ - public org.axsl.foR.fo.Leader getNearestLeader() { - return realParent().getNearestLeader(); + public org.axsl.foR.fo.Leader getNearestLeader(FOContext context) { + return effectiveParent(context).getNearestLeader(context); } /** * {@inheritDoc} */ - public org.axsl.foR.fo.BasicLink getBasicLink() { - return realParent().getBasicLink(); + public org.axsl.foR.fo.BasicLink getBasicLink(FOContext context) { + return effectiveParent(context).getBasicLink(context); } /** * {@inheritDoc} */ - public org.axsl.foR.FObj ancestorListRelatedObject() { - return realParent().ancestorListRelatedObject(); + public org.axsl.foR.FObj ancestorListRelatedObject(FOContext context) { + return effectiveParent(context).ancestorListRelatedObject(context); } /** @@ -386,103 +388,103 @@ /** * {@inheritDoc} */ - public int getMarginLeft(int widthContainingBlock) { - return propertyList.getMarginLeft(widthContainingBlock); + public int getMarginLeft(FOContext context, int widthContainingBlock) { + return propertyList.getMarginLeft(context, widthContainingBlock); } /** * {@inheritDoc} */ - public int getMarginRight(int widthContainingBlock) { - return propertyList.getMarginRight(widthContainingBlock); + public int getMarginRight(FOContext context, int widthContainingBlock) { + return propertyList.getMarginRight(context, widthContainingBlock); } /** * {@inheritDoc} */ - public int getMarginTop(int widthContainingBlock) { - return propertyList.getMarginTop(widthContainingBlock); + public int getMarginTop(FOContext context, int widthContainingBlock) { + return propertyList.getMarginTop(context, widthContainingBlock); } /** * {@inheritDoc} */ - public int getMarginBottom(int widthContainingBlock) { - return propertyList.getMarginBottom(widthContainingBlock); + public int getMarginBottom(FOContext context, int widthContainingBlock) { + return propertyList.getMarginBottom(context, widthContainingBlock); } /** * {@inheritDoc} */ - public Color traitColor() { - return propertyList.getColor(); + public Color traitColor(FOContext context) { + return propertyList.getColor(context); } /** * {@inheritDoc} */ - public short traitWrapOption() { - return propertyList.getWrapOption(); + public short traitWrapOption(FOContext context) { + return propertyList.getWrapOption(context); } /** * {@inheritDoc} */ - public boolean traitWhiteSpaceCollapse() { - return propertyList.getWhiteSpaceCollapse(); + public boolean traitWhiteSpaceCollapse(FOContext context) { + return propertyList.getWhiteSpaceCollapse(context); } /** * {@inheritDoc} */ - public boolean traitUnderlineScore() { - return propertyList.getUnderlineScore(); + public boolean traitUnderlineScore(FOContext context) { + return propertyList.getUnderlineScore(context); } /** * {@inheritDoc} */ - public boolean traitOverlineScore() { - return propertyList.getOverlineScore(); + public boolean traitOverlineScore(FOContext context) { + return propertyList.getOverlineScore(context); } /** * {@inheritDoc} */ - public boolean traitThroughScore() { - return propertyList.getThroughScore(); + public boolean traitThroughScore(FOContext context) { + return propertyList.getThroughScore(context); } /** * {@inheritDoc} */ - public Color traitUnderlineScoreColor() { + public Color traitUnderlineScoreColor(FOContext context) { /* TODO: This is not right. See Sections 5.5.6 and 7.16.4. Inheritance * is unusual here, and we need to fix it. */ - return traitColor(); + return traitColor(context); } /** * {@inheritDoc} */ - public Color traitOverlineScoreColor() { + public Color traitOverlineScoreColor(FOContext context) { // Value is the same as for underline. - return traitUnderlineScoreColor(); + return traitUnderlineScoreColor(context); } /** * {@inheritDoc} */ - public Color traitThroughScoreColor() { + public Color traitThroughScoreColor(FOContext context) { // Value is the same as for underline. - return traitUnderlineScoreColor(); + return traitUnderlineScoreColor(context); } /** * {@inheritDoc} */ - public boolean traitBlink() { - return propertyList.getBlink(); + public boolean traitBlink(FOContext context) { + return propertyList.getBlink(context); } /** @@ -509,21 +511,21 @@ /** * {@inheritDoc} */ - public int traitStartIndent(int ipdContainingRA) { - return propertyList.getIndent(Constants.DIRECTION_START, + public int traitStartIndent(FOContext context, int ipdContainingRA) { + return propertyList.getIndent(context, Constants.DIRECTION_START, ipdContainingRA); } /** * {@inheritDoc} */ - public short traitSpan() { + public short traitSpan(FOContext context) { /* * Only block-level FOs are affected by column-count, so, for all other * FOs, treat them as if the span trait were "all". */ if (this.isBlockLevelFO()) { - return propertyList.getSpan(); + return propertyList.getSpan(context); } return Constants.FOVAL_ALL; } @@ -531,43 +533,43 @@ /** * {@inheritDoc} */ - public String traitFlowName() { - return propertyList.getFlowName(); + public String traitFlowName(FOContext context) { + return propertyList.getFlowName(context); } /** * {@inheritDoc} */ - public String traitMarkerClassName() { - return propertyList.getMarkerClassName(); + public String traitMarkerClassName(FOContext context) { + return propertyList.getMarkerClassName(context); } /** * {@inheritDoc} */ - public String traitRetrieveClassName() { - return propertyList.getRetrieveClassName(); + public String traitRetrieveClassName(FOContext context) { + return propertyList.getRetrieveClassName(context); } /** * {@inheritDoc} */ - public short traitRetrievePosition() { - return propertyList.getRetrievePosition(); + public short traitRetrievePosition(FOContext context) { + return propertyList.getRetrievePosition(context); } /** * {@inheritDoc} */ - public short traitRetrieveBoundary() { - return propertyList.getRetrieveBoundary(); + public short traitRetrieveBoundary(FOContext context) { + return propertyList.getRetrieveBoundary(context); } /** * {@inheritDoc} */ - public int traitColumnNumber() { - return propertyList.getColumnNumber(); + public int traitColumnNumber(FOContext context) { + return propertyList.getColumnNumber(context); } /** @@ -587,36 +589,36 @@ /** * {@inheritDoc} */ - public short traitBorderCollapse() { - return propertyList.getBorderCollapse(); + public short traitBorderCollapse(FOContext context) { + return propertyList.getBorderCollapse(context); } /** * {@inheritDoc} */ - public short traitDisplayAlign() { - return propertyList.getDisplayAlign(); + public short traitDisplayAlign(FOContext context) { + return propertyList.getDisplayAlign(context); } /** * {@inheritDoc} */ - public short traitRelativeAlign() { - return propertyList.getRelativeAlign(); + public short traitRelativeAlign(FOContext context) { + return propertyList.getRelativeAlign(context); } /** * {@inheritDoc} */ - public int traitBorderSeparationIPD() { - return propertyList.getBorderSeparationIPD(); + public int traitBorderSeparationIPD(FOContext context) { + return propertyList.getBorderSeparationIPD(context); } /** * {@inheritDoc} */ - public int traitBorderSeparationBPD() { - return propertyList.getBorderSeparationBPD(); + public int traitBorderSeparationBPD(FOContext context) { + return propertyList.getBorderSeparationBPD(context); } /** @@ -629,8 +631,8 @@ /** * {@inheritDoc} */ - public int traitColumnWidth(int tableWidth) { - return propertyList.getColumnWidth(tableWidth); + public int traitColumnWidth(FOContext context, int tableWidth) { + return propertyList.getColumnWidth(context, tableWidth); } /** @@ -643,113 +645,114 @@ /** * {@inheritDoc} */ - public short traitBreakAfter() { - return propertyList.getBreakAfter(); + public short traitBreakAfter(FOContext context) { + return propertyList.getBreakAfter(context); } /** * {@inheritDoc} */ - public int traitKeepTogetherWithinLine() { - return propertyList.traitKeepTogetherWithinLine(); + public int traitKeepTogetherWithinLine(FOContext context) { + return propertyList.traitKeepTogetherWithinLine(context); } /** * {@inheritDoc} */ - public int traitKeepTogetherWithinColumn() { - return propertyList.traitKeepTogetherWithinColumn(); + public int traitKeepTogetherWithinColumn(FOContext context) { + return propertyList.traitKeepTogetherWithinColumn(context); } /** * {@inheritDoc} */ - public int traitKeepTogetherWithinPage() { - return propertyList.traitKeepTogetherWithinPage(); + public int traitKeepTogetherWithinPage(FOContext context) { + return propertyList.traitKeepTogetherWithinPage(context); } /** * {@inheritDoc} */ - public int traitKeepWithNextWithinLine() { - return propertyList.traitKeepWithNextWithinLine(); + public int traitKeepWithNextWithinLine(FOContext context) { + return propertyList.traitKeepWithNextWithinLine(context); } /** * {@inheritDoc} */ - public int traitKeepWithNextWithinColumn() { - return propertyList.traitKeepWithNextWithinColumn(); + public int traitKeepWithNextWithinColumn(FOContext context) { + return propertyList.traitKeepWithNextWithinColumn(context); } /** * {@inheritDoc} */ - public int traitKeepWithNextWithinPage() { - return propertyList.traitKeepWithNextWithinPage(); + public int traitKeepWithNextWithinPage(FOContext context) { + return propertyList.traitKeepWithNextWithinPage(context); } /** * {@inheritDoc} */ - public int traitKeepWithPreviousWithinLine() { - return propertyList.traitKeepWithPreviousWithinLine(); + public int traitKeepWithPreviousWithinLine(FOContext context) { + return propertyList.traitKeepWithPreviousWithinLine(context); } /** * {@inheritDoc} */ - public int traitKeepWithPreviousWithinColumn() { - return propertyList.traitKeepWithPreviousWithinColumn(); + public int traitKeepWithPreviousWithinColumn(FOContext context) { + return propertyList.traitKeepWithPreviousWithinColumn(context); } /** * {@inheritDoc} */ - public int traitKeepWithPreviousWithinPage() { - return propertyList.traitKeepWithPreviousWithinPage(); + public int traitKeepWithPreviousWithinPage(FOContext context) { + return propertyList.traitKeepWithPreviousWithinPage(context); } /** * {@inheritDoc} */ - public String traitMasterReference() { - return propertyList.getMasterReference(); + public String traitMasterReference(FOContext context) { + return propertyList.getMasterReference(context); } /** * {@inheritDoc} */ - public short traitPagePosition() { - return propertyList.getPagePosition(); + public short traitPagePosition(FOContext context) { + return propertyList.getPagePosition(context); } /** * {@inheritDoc} */ - public short traitOddOrEven() { - return propertyList.getOddOrEven(); + public short traitOddOrEven(FOContext context) { + return propertyList.getOddOrEven(context); } /** * {@inheritDoc} */ - public short traitBlankOrNotBlank() { - return propertyList.getBlankOrNotBlank(); + public short traitBlankOrNotBlank(FOContext context) { + return propertyList.getBlankOrNotBlank(context); } /** * {@inheritDoc} */ - public int traitInitialPageNumber(int lastPageNumberUsed) { - return propertyList.getInitialPageNumber(lastPageNumberUsed); + public int traitInitialPageNumber(FOContext context, + int lastPageNumberUsed) { + return propertyList.getInitialPageNumber(context, lastPageNumberUsed); } /** * {@inheritDoc} */ - public short getRawInitialPageNumber() { - return propertyList.getRawInitialPageNumber(); + public short getRawInitialPageNumber(FOContext context) { + return propertyList.getRawInitialPageNumber(context); } /** @@ -762,8 +765,8 @@ /** * {@inheritDoc} */ - public char traitGroupingSeparator() { - return propertyList.getGroupingSeparator(); + public char traitGroupingSeparator(FOContext context) { + return propertyList.getGroupingSeparator(context); } /** @@ -776,22 +779,22 @@ /** * {@inheritDoc} */ - public short traitLetterValue() { - return propertyList.getLetterValue(); + public short traitLetterValue(FOContext context) { + return propertyList.getLetterValue(context); } /** * {@inheritDoc} */ - public short traitForcePageCount() { - return propertyList.getForcePageCount(); + public short traitForcePageCount(FOContext context) { + return propertyList.getForcePageCount(context); } /** * {@inheritDoc} */ - public String traitMasterName() { - return propertyList.getMasterName(); + public String traitMasterName(FOContext context) { + return propertyList.getMasterName(context); } /** @@ -804,64 +807,64 @@ /** * {@inheritDoc} */ - public boolean traitPrecedence() { - return propertyList.getPrecedence(); + public boolean traitPrecedence(FOContext context) { + return propertyList.getPrecedence(context); } /** * {@inheritDoc} */ - public int traitExtent() { - return propertyList.getExtent(); + public int traitExtent(FOContext context) { + return propertyList.getExtent(context); } /** * {@inheritDoc} */ - public int traitColumnGap() { - return propertyList.getColumnGap(); + public int traitColumnGap(FOContext context) { + return propertyList.getColumnGap(context); } /** * {@inheritDoc} */ - public short traitOverflow() { - return propertyList.getOverflow(); + public short traitOverflow(FOContext context) { + return propertyList.getOverflow(context); } /** * {@inheritDoc} */ - public int traitColumnCount() { - return propertyList.getColumnCount(); + public int traitColumnCount(FOContext context) { + return propertyList.getColumnCount(context); } /** * {@inheritDoc} */ - public int traitMaximumRepeats() { - return propertyList.getMaximumRepeats(); + public int traitMaximumRepeats(FOContext context) { + return propertyList.getMaximumRepeats(context); } /** * {@inheritDoc} */ - public int traitPageWidth() { - return propertyList.getPageWidth(); + public int traitPageWidth(FOContext context) { + return propertyList.getPageWidth(context); } /** * {@inheritDoc} */ - public int traitPageHeight() { - return propertyList.getPageHeight(); + public int traitPageHeight(FOContext context) { + return propertyList.getPageHeight(context); } /** * {@inheritDoc} */ - public short traitTextAlign() { - return propertyList.getTextAlign(); + public short traitTextAlign(FOContext context) { + return propertyList.getTextAlign(context); } /** @@ -874,44 +877,44 @@ /** * {@inheritDoc} */ - public short traitTextAlignLast() { - return propertyList.getTextAlignLast(); + public short traitTextAlignLast(FOContext context) { + return propertyList.getTextAlignLast(context); } /** * {@inheritDoc} */ - public int traitEndIndent(int ipdContainingRA) { - return propertyList.getIndent(Constants.DIRECTION_END, + public int traitEndIndent(FOContext context, int ipdContainingRA) { + return propertyList.getIndent(context, Constants.DIRECTION_END, ipdContainingRA); } /** * {@inheritDoc} */ - public int traitSpaceBeforeMinimum() { - return propertyList.traitSpaceBeforeLength(Property.MINIMUM); + public int traitSpaceBeforeMinimum(FOContext context) { + return propertyList.traitSpaceBeforeLength(context, Property.MINIMUM); } /** * {@inheritDoc} */ - public int traitSpaceBeforeOptimum() { - return propertyList.traitSpaceBeforeLength(Property.OPTIMUM); + public int traitSpaceBeforeOptimum(FOContext context) { + return propertyList.traitSpaceBeforeLength(context, Property.OPTIMUM); } /** * {@inheritDoc} */ - public int traitSpaceBeforeMaximum() { - return propertyList.traitSpaceBeforeLength(Property.MAXIMUM); + public int traitSpaceBeforeMaximum(FOContext context) { + return propertyList.traitSpaceBeforeLength(context, Property.MAXIMUM); } /** * {@inheritDoc} */ - public short traitSpaceBeforeConditionality() { - return propertyList.traitSpaceBeforeConditionality(); + public short traitSpaceBeforeConditionality(FOContext context) { + return propertyList.traitSpaceBeforeConditionality(context); } /** @@ -924,29 +927,29 @@ /** * {@inheritDoc} */ - public int traitSpaceAfterMinimum() { - return propertyList.traitSpaceAfterLength(Property.MINIMUM); + public int traitSpaceAfterMinimum(FOContext context) { + return propertyList.traitSpaceAfterLength(context, Property.MINIMUM); } /** * {@inheritDoc} */ - public int traitSpaceAfterOptimum() { - return propertyList.traitSpaceAfterLength(Property.OPTIMUM); + public int traitSpaceAfterOptimum(FOContext context) { + return propertyList.traitSpaceAfterLength(context, Property.OPTIMUM); } /** * {@inheritDoc} */ - public int traitSpaceAfterMaximum() { - return propertyList.traitSpaceAfterLength(Property.MAXIMUM); + public int traitSpaceAfterMaximum(FOContext context) { + return propertyList.traitSpaceAfterLength(context, Property.MAXIMUM); } /** * {@inheritDoc} */ - public short traitSpaceAfterConditionality() { - return propertyList.traitSpaceAfterConditionality(); + public short traitSpaceAfterConditionality(FOContext context) { + return propertyList.traitSpaceAfterConditionality(context); } /** @@ -959,24 +962,27 @@ /** * {@inheritDoc} */ - public int traitSpaceStartMinimum(int ipdAncestorBlockArea) { - return propertyList.traitSpaceStartLength(Property.MINIMUM, + public int traitSpaceStartMinimum(FOContext context, + int ipdAncestorBlockArea) { + return propertyList.traitSpaceStartLength(context, Property.MINIMUM, ipdAncestorBlockArea); } /** * {@inheritDoc} */ - public int traitSpaceStartOptimum(int ipdAncestorBlockArea) { - return propertyList.traitSpaceStartLength(Property.OPTIMUM, + public int traitSpaceStartOptimum(FOContext context, + int ipdAncestorBlockArea) { + return propertyList.traitSpaceStartLength(context, Property.OPTIMUM, ipdAncestorBlockArea); } /** * {@inheritDoc} */ - public int traitSpaceStartMaximum(int ipdAncestorBlockArea) { - return propertyList.traitSpaceStartLength(Property.MAXIMUM, + public int traitSpaceStartMaximum(FOContext context, + int ipdAncestorBlockArea) { + return propertyList.traitSpaceStartLength(context, Property.MAXIMUM, ipdAncestorBlockArea); } @@ -997,24 +1003,27 @@ /** * {@inheritDoc} */ - public int traitSpaceEndMinimum(int ipdAncestorBlockArea) { - return propertyList.traitSpaceEndLength(Property.MINIMUM, + public int traitSpaceEndMinimum(FOContext context, + int ipdAncestorBlockArea) { + return propertyList.traitSpaceEndLength(context, Property.MINIMUM, ipdAncestorBlockArea); } /** * {@inheritDoc} */ - public int traitSpaceEndOptimum(int ipdAncestorBlockArea) { - return propertyList.traitSpaceEndLength(Property.OPTIMUM, + public int traitSpaceEndOptimum(FOContext context, + int ipdAncestorBlockArea) { + return propertyList.traitSpaceEndLength(context, Property.OPTIMUM, ipdAncestorBlockArea); } /** * {@inheritDoc} */ - public int traitSpaceEndMaximum(int ipdAncestorBlockArea) { - return propertyList.traitSpaceEndLength(Property.MAXIMUM, + public int traitSpaceEndMaximum(FOContext context, + int ipdAncestorBlockArea) { + return propertyList.traitSpaceEndLength(context, Property.MAXIMUM, ipdAncestorBlockArea); } @@ -1035,130 +1044,130 @@ /** * {@inheritDoc} */ - public int traitTextIndent(int widthContainingBlock) { - return propertyList.getTextIndent(widthContainingBlock); + public int traitTextIndent(FOContext context, int widthContainingBlock) { + return propertyList.getTextIndent(context, widthContainingBlock); } /** * {@inheritDoc} */ - public int traitTop(int heightContainingBlock) { - return propertyList.getTop(heightContainingBlock); + public int traitTop(FOContext context, int heightContainingBlock) { + return propertyList.getTop(context, heightContainingBlock); } /** * {@inheritDoc} */ - public int traitBottom(int heightContainingBlock) { - return propertyList.getBottom(heightContainingBlock); + public int traitBottom(FOContext context, int heightContainingBlock) { + return propertyList.getBottom(context, heightContainingBlock); } /** * {@inheritDoc} */ - public int traitLeft(int widthContainingBlock) { - return propertyList.getLeft(widthContainingBlock); + public int traitLeft(FOContext context, int widthContainingBlock) { + return propertyList.getLeft(context, widthContainingBlock); } /** * {@inheritDoc} */ - public int traitRight(int widthContainingBlock) { - return propertyList.getRight(widthContainingBlock); + public int traitRight(FOContext context, int widthContainingBlock) { + return propertyList.getRight(context, widthContainingBlock); } /** * {@inheritDoc} */ - public char traitCharacter() { - return propertyList.getCharacter(); + public char traitCharacter(FOContext context) { + return propertyList.getCharacter(context); } /** * {@inheritDoc} */ - public String traitSrc() { - return propertyList.getSrc(); + public String traitSrc(FOContext context) { + return propertyList.getSrc(context); } /** * {@inheritDoc} */ - public short traitBreakBefore() { - return propertyList.getBreakBefore(); + public short traitBreakBefore(FOContext context) { + return propertyList.getBreakBefore(context); } /** * {@inheritDoc} */ - public short traitScaling() { - return propertyList.getScaling(); + public short traitScaling(FOContext context) { + return propertyList.getScaling(context); } /** * {@inheritDoc} */ - public short traitLeaderPattern() { - return propertyList.getLeaderPattern(); + public short traitLeaderPattern(FOContext context) { + return propertyList.getLeaderPattern(context); } /** * {@inheritDoc} */ - public int traitLeaderLengthMin(int parentAreaCR_IPD) { - return propertyList.getLeaderLengthMinimum(parentAreaCR_IPD); + public int traitLeaderLengthMin(FOContext context, int parentAreaCR_IPD) { + return propertyList.getLeaderLengthMinimum(context, parentAreaCR_IPD); } /** * {@inheritDoc} */ - public int traitLeaderLengthOpt(int parentAreaCR_IPD) { - return propertyList.getLeaderLengthOptimum(parentAreaCR_IPD); + public int traitLeaderLengthOpt(FOContext context, int parentAreaCR_IPD) { + return propertyList.getLeaderLengthOptimum(context, parentAreaCR_IPD); } /** * {@inheritDoc} */ - public int traitLeaderLengthMax(int parentAreaCR_IPD) { - return propertyList.getLeaderLengthMaximum(parentAreaCR_IPD); + public int traitLeaderLengthMax(FOContext context, int parentAreaCR_IPD) { + return propertyList.getLeaderLengthMaximum(context, parentAreaCR_IPD); } /** * {@inheritDoc} */ - public int traitRuleThickness() { - if (traitRuleStyle() == Constants.FOVAL_NONE) { + public int traitRuleThickness(FOContext context) { + if (traitRuleStyle(context) == Constants.FOVAL_NONE) { return 0; } - return propertyList.getRuleThickness(); + return propertyList.getRuleThickness(context); } /** * {@inheritDoc} */ - public short traitRuleStyle() { - return propertyList.getRuleStyle(); + public short traitRuleStyle(FOContext context) { + return propertyList.getRuleStyle(context); } /** * {@inheritDoc} */ - public int traitLeaderPatternWidth(int ipd_CR_Parent) { - return propertyList.getLeaderPatternWidth(ipd_CR_Parent); + public int traitLeaderPatternWidth(FOContext context, int ipd_CR_Parent) { + return propertyList.getLeaderPatternWidth(context, ipd_CR_Parent); } /** * {@inheritDoc} */ - public short traitLeaderAlignment() { - return propertyList.getLeaderAlignment(); + public short traitLeaderAlignment(FOContext context) { + return propertyList.getLeaderAlignment(context); } /** * {@inheritDoc} */ - public String traitRefId() { - return propertyList.getRefId(); + public String traitRefId(FOContext context) { + return propertyList.getRefId(context); } /** @@ -1171,107 +1180,107 @@ /** * {@inheritDoc} */ - public boolean traitTableOmitHeaderAtBreak() { - return propertyList.getTableOmitHeaderAtBreak(); + public boolean traitTableOmitHeaderAtBreak(FOContext context) { + return propertyList.getTableOmitHeaderAtBreak(context); } /** * {@inheritDoc} */ - public boolean traitTableOmitFooterAtBreak() { - return propertyList.getTableOmitFooterAtBreak(); + public boolean traitTableOmitFooterAtBreak(FOContext context) { + return propertyList.getTableOmitFooterAtBreak(context); } /** * {@inheritDoc} */ - public int traitBPDimensionMax(int parentAreaCR_BPD) { - return propertyList.traitBPDimensionMax(parentAreaCR_BPD); + public int traitBPDimensionMax(FOContext context, int parentAreaCR_BPD) { + return propertyList.traitBPDimensionMax(context, parentAreaCR_BPD); } /** * {@inheritDoc} */ - public int traitBPDimensionOpt(int parentAreaCR_BPD) { - return propertyList.traitBPDimensionOpt(parentAreaCR_BPD); + public int traitBPDimensionOpt(FOContext context, int parentAreaCR_BPD) { + return propertyList.traitBPDimensionOpt(context, parentAreaCR_BPD); } /** * {@inheritDoc} */ - public int traitBPDimensionMin(int parentAreaCR_BPD) { - return propertyList.traitBPDimensionMin(parent... [truncated message content] |
|
From: <vic...@us...> - 2006-06-07 18:05:55
|
Revision: 7436 Author: victormote Date: 2006-06-07 11:05:37 -0700 (Wed, 07 Jun 2006) ViewCVS: http://svn.sourceforge.net/foray/?rev=7436&view=rev Log Message: ----------- Conform to axsl changes: Use new FOContext interface to provide information to the FOTree. Modified Paths: -------------- trunk/foray/foray-output/src/java/org/foray/output/MIFConverter.java Modified: trunk/foray/foray-output/src/java/org/foray/output/MIFConverter.java =================================================================== --- trunk/foray/foray-output/src/java/org/foray/output/MIFConverter.java 2006-06-07 18:05:14 UTC (rev 7435) +++ trunk/foray/foray-output/src/java/org/foray/output/MIFConverter.java 2006-06-07 18:05:37 UTC (rev 7436) @@ -26,6 +26,7 @@ import org.foray.mif.MIFDocument; +import org.axsl.foR.FOContext; import org.axsl.foR.fo.Block; import org.axsl.foR.fo.Table; import org.axsl.foR.fo.TableBody; @@ -157,9 +158,10 @@ * render the given block area */ public void render(Block block) { + FOContext context = null; int containingIPD = 1; - this.mifDoc.setBlockProp(block.traitStartIndent(containingIPD), - block.traitEndIndent(containingIPD)); + this.mifDoc.setBlockProp(block.traitStartIndent(context, containingIPD), + block.traitEndIndent(context, containingIPD)); } // /** This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
|
From: <vic...@us...> - 2006-06-07 18:05:34
|
Revision: 7435 Author: victormote Date: 2006-06-07 11:05:14 -0700 (Wed, 07 Jun 2006) ViewCVS: http://svn.sourceforge.net/foray/?rev=7435&view=rev Log Message: ----------- Conform to axsl changes: Use new FOContext interface to provide information to the FOTree. Modified Paths: -------------- trunk/foray/foray-areatree/src/java/org/foray/area/AbstractInlineArea.java trunk/foray/foray-areatree/src/java/org/foray/area/Area.java trunk/foray/foray-areatree/src/java/org/foray/area/AreaNode.java trunk/foray/foray-areatree/src/java/org/foray/area/ExternalGraphicArea.java trunk/foray/foray-areatree/src/java/org/foray/area/ForeignObjectArea.java trunk/foray/foray-areatree/src/java/org/foray/area/InlineArea.java trunk/foray/foray-areatree/src/java/org/foray/area/LeaderArea.java trunk/foray/foray-areatree/src/java/org/foray/area/LineArea.java trunk/foray/foray-areatree/src/java/org/foray/area/MainRA.java trunk/foray/foray-areatree/src/java/org/foray/area/NormalBlockArea.java trunk/foray/foray-areatree/src/java/org/foray/area/PageCollection.java trunk/foray/foray-areatree/src/java/org/foray/area/PageRA.java trunk/foray/foray-areatree/src/java/org/foray/area/RegionRA.java trunk/foray/foray-areatree/src/java/org/foray/area/RegionRABody.java trunk/foray/foray-areatree/src/java/org/foray/area/SpanRA.java trunk/foray/foray-areatree/src/java/org/foray/area/TableCellRA.java trunk/foray/foray-areatree/src/java/org/foray/area/TableRA.java trunk/foray/foray-areatree/src/java/org/foray/area/TextArea.java Modified: trunk/foray/foray-areatree/src/java/org/foray/area/AbstractInlineArea.java =================================================================== --- trunk/foray/foray-areatree/src/java/org/foray/area/AbstractInlineArea.java 2006-06-06 23:26:02 UTC (rev 7434) +++ trunk/foray/foray-areatree/src/java/org/foray/area/AbstractInlineArea.java 2006-06-07 18:05:14 UTC (rev 7435) @@ -79,7 +79,7 @@ } public int traitBaselineShift() { - return traitGeneratedBy().traitBaselineShift(); + return traitGeneratedBy().traitBaselineShift(this); } } Modified: trunk/foray/foray-areatree/src/java/org/foray/area/Area.java =================================================================== --- trunk/foray/foray-areatree/src/java/org/foray/area/Area.java 2006-06-06 23:26:02 UTC (rev 7434) +++ trunk/foray/foray-areatree/src/java/org/foray/area/Area.java 2006-06-07 18:05:14 UTC (rev 7435) @@ -36,8 +36,6 @@ import org.axsl.foR.fo.Block; import org.axsl.foR.fo.BlockContainer; import org.axsl.foR.fo.ListBlock; -import org.axsl.foR.fo.Marker; -import org.axsl.foR.fo.RetrieveMarker; import org.axsl.foR.fo.Table; import org.axsl.fontR.Font; import org.axsl.fontR.FontUse; @@ -60,43 +58,43 @@ } public int traitBackgroundRepeat() { - return this.traitGeneratedBy().traitBackgroundRepeat(); + return this.traitGeneratedBy().traitBackgroundRepeat(this); } public Graphic traitBackgroundImage() { - return this.traitGeneratedBy().traitBackgroundImage(); + return this.traitGeneratedBy().traitBackgroundImage(this); } public int getPaddingTop() { - return this.traitGeneratedBy().traitPaddingTop(); + return this.traitGeneratedBy().traitPaddingTop(this); } public int getPaddingLeft() { - return this.traitGeneratedBy().traitPaddingLeft(); + return this.traitGeneratedBy().traitPaddingLeft(this); } public int getPaddingBottom() { - return this.traitGeneratedBy().traitPaddingBottom(); + return this.traitGeneratedBy().traitPaddingBottom(this); } public int getPaddingRight() { - return this.traitGeneratedBy().traitPaddingRight(); + return this.traitGeneratedBy().traitPaddingRight(this); } public int getBorderTopWidth() { - return this.traitGeneratedBy().traitBorderTopWidth(); + return this.traitGeneratedBy().traitBorderTopWidth(this); } public int getBorderRightWidth() { - return this.traitGeneratedBy().traitBorderRightWidth(); + return this.traitGeneratedBy().traitBorderRightWidth(this); } public int getBorderLeftWidth() { - return this.traitGeneratedBy().traitBorderLeftWidth(); + return this.traitGeneratedBy().traitBorderLeftWidth(this); } public int getBorderBottomWidth() { - return this.traitGeneratedBy().traitBorderBottomWidth(); + return this.traitGeneratedBy().traitBorderBottomWidth(this); } public BlockContainerRA getNearestAncestorAreaContainer() { @@ -116,15 +114,15 @@ } public int traitLetterSpacingOpt() { - return traitGeneratedBy().traitLetterSpacingOpt(); + return traitGeneratedBy().traitLetterSpacingOpt(this); } public int traitLetterSpacingMax() { - return traitGeneratedBy().traitLetterSpacingMax(); + return traitGeneratedBy().traitLetterSpacingMax(this); } public int traitLetterSpacingMin() { - return traitGeneratedBy().traitLetterSpacingMin(); + return traitGeneratedBy().traitLetterSpacingMin(this); } /** @@ -138,29 +136,29 @@ } public int traitWordSpacingOpt() { - return traitGeneratedBy().traitWordSpacingOpt(); + return traitGeneratedBy().traitWordSpacingOpt(this); } public int traitWordSpacingMax() { - return traitGeneratedBy().traitWordSpacingMax(); + return traitGeneratedBy().traitWordSpacingMax(this); } public int traitWordSpacingMin() { - return traitGeneratedBy().traitWordSpacingMin(); + return traitGeneratedBy().traitWordSpacingMin(this); } public int traitFontSize() { - return traitGeneratedBy().traitFontSize(); + return traitGeneratedBy().traitFontSize(this); } public int traitEndIndent() { int percentBase = this.getContainingReferenceArea().crIPD(); - return traitGeneratedBy().traitEndIndent(percentBase); + return traitGeneratedBy().traitEndIndent(this, percentBase); } public int traitStartIndent() { int percentBase = this.getContainingReferenceArea().crIPD(); - return traitGeneratedBy().traitStartIndent(percentBase); + return traitGeneratedBy().traitStartIndent(this, percentBase); } public int parentAllocationWidth() { @@ -171,11 +169,11 @@ } public FontUse getPrimaryFont() { - return traitGeneratedBy().getPrimaryFont(); + return traitGeneratedBy().getPrimaryFont(this); } public FontUse getSecondaryFont(int codePoint) { - return traitGeneratedBy().getSecondaryFont(codePoint); + return traitGeneratedBy().getSecondaryFont(this, codePoint); } public int getAscender() { @@ -187,35 +185,35 @@ } public Color traitBorderTopColor() { - return traitGeneratedBy().traitBorderTopColor(); + return traitGeneratedBy().traitBorderTopColor(this); } public Color traitBorderLeftColor() { - return traitGeneratedBy().traitBorderLeftColor(); + return traitGeneratedBy().traitBorderLeftColor(this); } public Color traitBorderRightColor() { - return traitGeneratedBy().traitBorderRightColor(); + return traitGeneratedBy().traitBorderRightColor(this); } public Color traitBorderBottomColor() { - return traitGeneratedBy().traitBorderBottomColor(); + return traitGeneratedBy().traitBorderBottomColor(this); } public String traitFontFamily() { - return traitGeneratedBy().traitFontFamily()[0]; + return traitGeneratedBy().traitFontFamily(this)[0]; } public Color traitBackgroundColor() { - return traitGeneratedBy().traitBackgroundColor(); + return traitGeneratedBy().traitBackgroundColor(this); } public short traitRelativePosition() { - return traitGeneratedBy().traitRelativePosition(); + return traitGeneratedBy().traitRelativePosition(this); } public short traitAbsolutePosition() { - return traitGeneratedBy().traitAbsolutePosition(); + return traitGeneratedBy().traitAbsolutePosition(this); } public int getFontAscender() { @@ -275,31 +273,31 @@ } public short traitFontVariant() { - return traitGeneratedBy().traitFontVariant(); + return traitGeneratedBy().traitFontVariant(this); } public boolean traitUnderlineScore() { - return traitGeneratedBy().traitUnderlineScore(); + return traitGeneratedBy().traitUnderlineScore(this); } public boolean traitOverlineScore() { - return traitGeneratedBy().traitOverlineScore(); + return traitGeneratedBy().traitOverlineScore(this); } public boolean traitThroughScore() { - return traitGeneratedBy().traitThroughScore(); + return traitGeneratedBy().traitThroughScore(this); } public Color traitUnderlineScoreColor() { - return traitGeneratedBy().traitUnderlineScoreColor(); + return traitGeneratedBy().traitUnderlineScoreColor(this); } public Color traitOverlineScoreColor() { - return traitGeneratedBy().traitOverlineScoreColor(); + return traitGeneratedBy().traitOverlineScoreColor(this); } public Color traitThroughScoreColor() { - return traitGeneratedBy().traitThroughScoreColor(); + return traitGeneratedBy().traitThroughScoreColor(this); } public Area getAreaParent() { @@ -744,77 +742,78 @@ } public int traitBorderStartWidth() { - return traitGeneratedBy().traitBorderStartWidth(traitIsFirst()); + return traitGeneratedBy().traitBorderStartWidth(this, traitIsFirst()); } public int traitBorderEndWidth() { - return traitGeneratedBy().traitBorderEndWidth(traitIsLast()); + return traitGeneratedBy().traitBorderEndWidth(this, traitIsLast()); } public int traitBorderBeforeWidth() { - return traitGeneratedBy().traitBorderBeforeWidth(traitIsFirst()); + return traitGeneratedBy().traitBorderBeforeWidth(this, traitIsFirst()); } public int traitBorderAfterWidth() { - return traitGeneratedBy().traitBorderAfterWidth(traitIsLast()); + return traitGeneratedBy().traitBorderAfterWidth(this, traitIsLast()); } public int traitPaddingStart() { - return traitGeneratedBy().traitPaddingStart(traitIsFirst()); + return traitGeneratedBy().traitPaddingStart(this, traitIsFirst()); } public int traitPaddingEnd() { - return traitGeneratedBy().traitPaddingEnd(traitIsLast()); + return traitGeneratedBy().traitPaddingEnd(this, traitIsLast()); } public int traitPaddingBefore() { - return traitGeneratedBy().traitPaddingBefore(traitIsFirst()); + return traitGeneratedBy().traitPaddingBefore(this, traitIsFirst()); } public int traitPaddingAfter() { - return traitGeneratedBy().traitPaddingAfter(traitIsLast()); + return traitGeneratedBy().traitPaddingAfter(this, traitIsLast()); } public int traitSpaceBeforeMinimum() { - return traitGeneratedBy().traitSpaceBeforeMinimum(); + return traitGeneratedBy().traitSpaceBeforeMinimum(this); } public int traitSpaceBeforeOptimum() { - return traitGeneratedBy().traitSpaceBeforeOptimum(); + return traitGeneratedBy().traitSpaceBeforeOptimum(this); } public int traitSpaceBeforeMaximum() { - return traitGeneratedBy().traitSpaceBeforeMaximum(); + return traitGeneratedBy().traitSpaceBeforeMaximum(this); } public int traitSpaceAfterMinumum() { - return traitGeneratedBy().traitSpaceAfterMinimum(); + return traitGeneratedBy().traitSpaceAfterMinimum(this); } public int traitSpaceAfterOptimum() { - return traitGeneratedBy().traitSpaceAfterOptimum(); + return traitGeneratedBy().traitSpaceAfterOptimum(this); } public int traitSpaceAfterMaximum() { - return traitGeneratedBy().traitSpaceAfterMaximum(); + return traitGeneratedBy().traitSpaceAfterMaximum(this); } public int traitSpaceStartOptimum() { Area ancestor = this.ancestorBlockAreaNotALineArea(); - return traitGeneratedBy().traitSpaceStartOptimum(ancestor.crIPD()); + return traitGeneratedBy().traitSpaceStartOptimum(this, + ancestor.crIPD()); } public int traitSpaceEndOptimum() { Area ancestor = this.ancestorBlockAreaNotALineArea(); - return traitGeneratedBy().traitSpaceEndOptimum(ancestor.crIPD()); + return traitGeneratedBy().traitSpaceEndOptimum(this, ancestor.crIPD()); } public int traitBPDirection() { - return traitGeneratedBy().traitBPDirection(); + return traitGeneratedBy().traitBPDirection(this); } public int traitIPDirection() { - return traitGeneratedBy().traitIPDirection(); + return traitGeneratedBy().traitIPDirection(this); } private int nearestBaseBPD() { @@ -831,7 +830,7 @@ * @return -1 for "auto. */ public int traitBPDimensionMin() { - return traitGeneratedBy().traitBPDimensionMin(nearestBaseBPD()); + return traitGeneratedBy().traitBPDimensionMin(this, nearestBaseBPD()); } /** @@ -839,7 +838,7 @@ * @return -1 for "auto. */ public int traitBPDimensionOpt() { - return traitGeneratedBy().traitBPDimensionOpt(nearestBaseBPD()); + return traitGeneratedBy().traitBPDimensionOpt(this, nearestBaseBPD()); } /** @@ -847,7 +846,7 @@ * @return -1 for "auto. */ public int traitBPDimensionMax() { - return traitGeneratedBy().traitBPDimensionMax(nearestBaseBPD()); + return traitGeneratedBy().traitBPDimensionMax(this, nearestBaseBPD()); } private int nearestBaseIPD() { @@ -864,7 +863,7 @@ * @return -1 for "auto. */ public int traitIPDimensionMin() { - return traitGeneratedBy().traitIPDimensionMin(nearestBaseIPD()); + return traitGeneratedBy().traitIPDimensionMin(this, nearestBaseIPD()); } /** @@ -872,7 +871,7 @@ * @return -1 for "auto. */ public int traitIPDimensionOpt() { - return traitGeneratedBy().traitIPDimensionOpt(nearestBaseIPD()); + return traitGeneratedBy().traitIPDimensionOpt(this, nearestBaseIPD()); } /** @@ -880,15 +879,15 @@ * @return -1 for "auto. */ public int traitIPDimensionMax() { - return traitGeneratedBy().traitIPDimensionMax(nearestBaseIPD()); + return traitGeneratedBy().traitIPDimensionMax(this, nearestBaseIPD()); } public int traitPageWidth() { - return traitGeneratedBy().traitPageWidth(); + return traitGeneratedBy().traitPageWidth(this); } public int traitPageHeight() { - return traitGeneratedBy().traitPageHeight(); + return traitGeneratedBy().traitPageHeight(this); } /** @@ -897,15 +896,15 @@ * is invalid. */ public byte getBPAxis() { - return traitGeneratedBy().getBPAxis(); + return traitGeneratedBy().getBPAxis(this); } public byte getIPAxis() { - return traitGeneratedBy().getIPAxis(); + return traitGeneratedBy().getIPAxis(this); } public WritingMode getWritingMode() { - return traitGeneratedBy().getWritingMode(); + return traitGeneratedBy().getWritingMode(this); } /** @@ -941,19 +940,19 @@ } public int getMarginTop() { - return traitGeneratedBy().getMarginTop(traitPageWidth()); + return traitGeneratedBy().getMarginTop(this, traitPageWidth()); } public int getMarginBottom() { - return traitGeneratedBy().getMarginBottom(traitPageWidth()); + return traitGeneratedBy().getMarginBottom(this, traitPageWidth()); } public int getMarginLeft() { - return traitGeneratedBy().getMarginLeft(traitPageWidth()); + return traitGeneratedBy().getMarginLeft(this, traitPageWidth()); } public int getMarginRight() { - return traitGeneratedBy().getMarginRight(traitPageWidth()); + return traitGeneratedBy().getMarginRight(this, traitPageWidth()); } /** @@ -990,7 +989,7 @@ throws AreaWException; public int traitHalfLeadingOpt() { - return traitGeneratedBy().traitHalfLeadingOpt(); + return traitGeneratedBy().traitHalfLeadingOpt(this); } public boolean traitIsReferenceArea() { @@ -998,7 +997,7 @@ } public short traitReferenceOrientation() { - return traitGeneratedBy().traitReferenceOrientation(); + return traitGeneratedBy().traitReferenceOrientation(this); } public short referenceOrientationCumulative() { @@ -1016,11 +1015,11 @@ } public int traitExtent() { - return traitGeneratedBy().traitExtent(); + return traitGeneratedBy().traitExtent(this); } public short traitWhiteSpaceTreatment() { - return traitGeneratedBy().traitWhiteSpaceTreatment(); + return traitGeneratedBy().traitWhiteSpaceTreatment(this); } public boolean traitIsFirst() { @@ -1032,39 +1031,39 @@ } public short traitWrapOption() { - return traitGeneratedBy().traitWrapOption(); + return traitGeneratedBy().traitWrapOption(this); } public String traitLanguage() { - return traitGeneratedBy().traitLanguage(); + return traitGeneratedBy().traitLanguage(this); } public short traitScaling() { - return traitGeneratedBy().traitScaling(); + return traitGeneratedBy().traitScaling(this); } public short traitTextAlign() { - return traitGeneratedBy().traitTextAlign(); + return traitGeneratedBy().traitTextAlign(this); } public short traitAlignmentBaseline() { - return traitGeneratedBy().traitAlignmentBaseline(); + return traitGeneratedBy().traitAlignmentBaseline(this); } public short traitOverflow() { - return traitGeneratedBy().traitOverflow(); + return traitGeneratedBy().traitOverflow(this); } public String traitRefId() { - return traitGeneratedBy().traitRefId(); + return traitGeneratedBy().traitRefId(this); } public char traitHyphenationCharacter() { - return traitGeneratedBy().traitHyphenationCharacter(); + return traitGeneratedBy().traitHyphenationCharacter(this); } public short traitDominantBaseline() { - return traitGeneratedBy().traitDominantBaseline(); + return traitGeneratedBy().traitDominantBaseline(this); } /** @@ -1098,7 +1097,7 @@ * of a link, returns {@link Constants#BASIC_LINK_INVALID}. */ public byte linkType() { - BasicLink link = this.traitGeneratedBy().getBasicLink(); + BasicLink link = this.traitGeneratedBy().getBasicLink(this); if (link == null) { return Constants.BASIC_LINK_INVALID; } @@ -1112,7 +1111,7 @@ * external-destination. */ public String linkDestination() { - BasicLink link = this.traitGeneratedBy().getBasicLink(); + BasicLink link = this.traitGeneratedBy().getBasicLink(this); if (link == null) { return null; } @@ -1182,22 +1181,22 @@ public int traitTop() { Area ancestor = this.ancestorBlockAreaNotALineArea(); - return traitGeneratedBy().traitTop(ancestor.crBPD()); + return traitGeneratedBy().traitTop(this, ancestor.crBPD()); } public int traitBottom() { Area ancestor = this.ancestorBlockAreaNotALineArea(); - return traitGeneratedBy().traitBottom(ancestor.crBPD()); + return traitGeneratedBy().traitBottom(this, ancestor.crBPD()); } public int traitLeft() { Area ancestor = this.ancestorBlockAreaNotALineArea(); - return traitGeneratedBy().traitLeft(ancestor.crIPD()); + return traitGeneratedBy().traitLeft(this, ancestor.crIPD()); } public int traitRight() { Area ancestor = this.ancestorBlockAreaNotALineArea(); - return traitGeneratedBy().traitRight(ancestor.crIPD()); + return traitGeneratedBy().traitRight(this, ancestor.crIPD()); } /** @@ -1244,8 +1243,4 @@ return true; } - public RetrieveMarker getRetrieveMarker(Marker marker) { - return null; - } - } Modified: trunk/foray/foray-areatree/src/java/org/foray/area/AreaNode.java =================================================================== --- trunk/foray/foray-areatree/src/java/org/foray/area/AreaNode.java 2006-06-06 23:26:02 UTC (rev 7434) +++ trunk/foray/foray-areatree/src/java/org/foray/area/AreaNode.java 2006-06-07 18:05:14 UTC (rev 7435) @@ -29,8 +29,11 @@ import org.axsl.areaW.FOLinkage; import org.axsl.areaW.PageArea; import org.axsl.common.Constants; +import org.axsl.foR.FOContext; import org.axsl.foR.FONode; import org.axsl.foR.FObj; +import org.axsl.foR.fo.Marker; +import org.axsl.foR.fo.RetrieveMarker; import org.axsl.fontR.FontConsumer; import org.axsl.text.TextServer; @@ -255,7 +258,7 @@ } public Color traitColor() { - return traitGeneratedBy().traitColor(); + return traitGeneratedBy().traitColor(this); } /** @@ -263,10 +266,10 @@ * typeface that should be used. * @return One of 100 (lightest), 200, 300, 400 (normal), 500, 600, * 700 (bold), 800, or 900 (boldest). - * @see FObj#traitFontWeight() + * @see FObj#traitFontWeight(FOContext) */ public short traitFontWeight() { - return traitGeneratedBy().traitFontWeight(); + return traitGeneratedBy().traitFontWeight(this); } /** @@ -275,7 +278,7 @@ * {@link Constants#FOVAL_BACKSLANT}. */ public short traitFontStyle() { - return traitGeneratedBy().traitFontStyle(); + return traitGeneratedBy().traitFontStyle(this); } /** @@ -433,4 +436,8 @@ return nearest.crIPD(); } + public RetrieveMarker getRetrieveMarker(Marker marker) { + return null; + } + } Modified: trunk/foray/foray-areatree/src/java/org/foray/area/ExternalGraphicArea.java =================================================================== --- trunk/foray/foray-areatree/src/java/org/foray/area/ExternalGraphicArea.java 2006-06-06 23:26:02 UTC (rev 7434) +++ trunk/foray/foray-areatree/src/java/org/foray/area/ExternalGraphicArea.java 2006-06-07 18:05:14 UTC (rev 7435) @@ -42,7 +42,7 @@ } public Graphic getGraphic() { - return ((ExternalGraphic) this.traitGeneratedBy()).getGraphic(); + return ((ExternalGraphic) this.traitGeneratedBy()).getGraphic(this); } public byte getAreaType() { @@ -57,13 +57,13 @@ public int viewportBPD() { ExternalGraphic eg = (ExternalGraphic) this.traitGeneratedBy(); Area parentForDimensions = this.ancestorGeneratedByBlockLevelFO(); - return eg.viewportBPD(parentForDimensions.crBPD()); + return eg.viewportBPD(this, parentForDimensions.crBPD()); } public int viewportIPD() { ExternalGraphic eg = (ExternalGraphic) this.traitGeneratedBy(); Area parentForDimensions = this.ancestorGeneratedByBlockLevelFO(); - return eg.viewportIPD(parentForDimensions.crIPD()); + return eg.viewportIPD(this, parentForDimensions.crIPD()); } /** Modified: trunk/foray/foray-areatree/src/java/org/foray/area/ForeignObjectArea.java =================================================================== --- trunk/foray/foray-areatree/src/java/org/foray/area/ForeignObjectArea.java 2006-06-06 23:26:02 UTC (rev 7434) +++ trunk/foray/foray-areatree/src/java/org/foray/area/ForeignObjectArea.java 2006-06-07 18:05:14 UTC (rev 7435) @@ -59,14 +59,14 @@ InstreamForeignObject ifo = (InstreamForeignObject) this.traitGeneratedBy(); Area parentForDimensions = this.ancestorGeneratedByBlockLevelFO(); - return ifo.viewportBPD(parentForDimensions.crBPD()); + return ifo.viewportBPD(this, parentForDimensions.crBPD()); } public int viewportIPD() { InstreamForeignObject ifo = (InstreamForeignObject) this.traitGeneratedBy(); Area parentForDimensions = this.ancestorGeneratedByBlockLevelFO(); - return ifo.viewportIPD(parentForDimensions.crIPD()); + return ifo.viewportIPD(this, parentForDimensions.crIPD()); } public org.axsl.areaR.AreaNode getContainedForeignObject() { Modified: trunk/foray/foray-areatree/src/java/org/foray/area/InlineArea.java =================================================================== --- trunk/foray/foray-areatree/src/java/org/foray/area/InlineArea.java 2006-06-06 23:26:02 UTC (rev 7434) +++ trunk/foray/foray-areatree/src/java/org/foray/area/InlineArea.java 2006-06-07 18:05:14 UTC (rev 7435) @@ -88,7 +88,7 @@ boolean hasFauxSmallCaps, boolean isLastItemOnLine) { return LineArea.makeTextArea(foText, this, ipd, startOffset, sizeInChars, hasDiscretionaryHyphen, hasFauxSmallCaps, - isLastItemOnLine); + isLastItemOnLine, this); } } Modified: trunk/foray/foray-areatree/src/java/org/foray/area/LeaderArea.java =================================================================== --- trunk/foray/foray-areatree/src/java/org/foray/area/LeaderArea.java 2006-06-06 23:26:02 UTC (rev 7434) +++ trunk/foray/foray-areatree/src/java/org/foray/area/LeaderArea.java 2006-06-07 18:05:14 UTC (rev 7435) @@ -86,11 +86,11 @@ * @see FObj#traitLeaderPattern */ public short traitLeaderPattern() { - if (traitGeneratedBy().traitLeaderPattern() == Constants.FOVAL_RULE - && traitGeneratedBy().traitRuleThickness() <= 0) { + if (traitGeneratedBy().traitLeaderPattern(this) == Constants.FOVAL_RULE + && traitGeneratedBy().traitRuleThickness(this) <= 0) { return Constants.FOVAL_SPACE; } - return traitGeneratedBy().traitLeaderPattern(); + return traitGeneratedBy().traitLeaderPattern(this); } /** @@ -99,7 +99,7 @@ */ public int traitLeaderPatternWidth() { return traitGeneratedBy().traitLeaderPatternWidth( - getParentArea().crIPD()); + this, getParentArea().crIPD()); } /** @@ -107,7 +107,7 @@ * @see FObj#traitLeaderAlignment */ public short traitLeaderAlignment() { - return traitGeneratedBy().traitLeaderAlignment(); + return traitGeneratedBy().traitLeaderAlignment(this); } /** @@ -115,7 +115,7 @@ * @see FObj#traitRuleStyle */ public short traitRuleStyle() { - return traitGeneratedBy().traitRuleStyle(); + return traitGeneratedBy().traitRuleStyle(this); } /** @@ -123,7 +123,7 @@ * @see FObj#traitRuleThickness */ public int traitRuleThickness() { - return traitGeneratedBy().traitRuleThickness(); + return traitGeneratedBy().traitRuleThickness(this); } /** @@ -229,17 +229,17 @@ public int traitLeaderLengthMin() { int percentBase = this.getParentArea().crIPD(); - return this.traitGeneratedBy().traitLeaderLengthMin(percentBase); + return this.traitGeneratedBy().traitLeaderLengthMin(this, percentBase); } public int traitLeaderLengthOpt() { int percentBase = this.getParentArea().crIPD(); - return this.traitGeneratedBy().traitLeaderLengthOpt(percentBase); + return this.traitGeneratedBy().traitLeaderLengthOpt(this, percentBase); } public int traitLeaderLengthMax() { int percentBase = this.getParentArea().crIPD(); - return this.traitGeneratedBy().traitLeaderLengthMax(percentBase); + return this.traitGeneratedBy().traitLeaderLengthMax(this, percentBase); } public int getResolvedWordSpacing() { @@ -286,7 +286,7 @@ boolean hasFauxSmallCaps, boolean isLastItemOnLine) { return LineArea.makeTextArea(foText, this, ipd, startOffset, sizeInChars, hasDiscretionaryHyphen, hasFauxSmallCaps, - isLastItemOnLine); + isLastItemOnLine, this); } } Modified: trunk/foray/foray-areatree/src/java/org/foray/area/LineArea.java =================================================================== --- trunk/foray/foray-areatree/src/java/org/foray/area/LineArea.java 2006-06-06 23:26:02 UTC (rev 7434) +++ trunk/foray/foray-areatree/src/java/org/foray/area/LineArea.java 2006-06-07 18:05:14 UTC (rev 7435) @@ -27,6 +27,7 @@ import org.axsl.areaW.AreaWException; import org.axsl.common.Constants; import org.axsl.common.ConstantsAreaTree; +import org.axsl.foR.FOContext; import org.axsl.foR.FOText; import org.axsl.foR.FOTextContent; import org.axsl.foR.FObj; @@ -85,7 +86,7 @@ } default: getLogger().error("Invalid 'text-align': " - + traitGeneratedBy().traitTextAlign()); + + traitGeneratedBy().traitTextAlign(this)); return 0; } } @@ -504,7 +505,7 @@ * that results from aligning the line. */ public int startAlignmentAdjustment() { - short textAlign = traitGeneratedBy().traitTextAlign(); + short textAlign = traitGeneratedBy().traitTextAlign(this); switch (textAlign) { case Constants.FOVAL_END: case Constants.FOVAL_RIGHT: { @@ -680,9 +681,9 @@ * CENTER, JUSTIFY. */ public short traitTextAlign() { - short textAlign = traitGeneratedBy().traitTextAlign(); + short textAlign = traitGeneratedBy().traitTextAlign(this); if (this.textAlignLastApplies()) { - short textAlignLast = traitGeneratedBy().traitTextAlignLast(); + short textAlignLast = traitGeneratedBy().traitTextAlignLast(this); if (textAlignLast == Constants.FOVAL_RELATIVE) { if (textAlign == Constants.FOVAL_JUSTIFY) { return Constants.FOVAL_START; @@ -727,7 +728,7 @@ return 0; } int percentBase = this.ancestorBlockAreaNotALineArea().crIPD(); - return traitGeneratedBy().traitTextIndent(percentBase); + return traitGeneratedBy().traitTextIndent(this, percentBase); } public int traitLastLineEndIndent() { @@ -735,7 +736,7 @@ return 0; } int percentBase = this.ancestorBlockAreaNotALineArea().crIPD(); - return traitGeneratedBy().traitLastLineEndIndent(percentBase); + return traitGeneratedBy().traitLastLineEndIndent(this, percentBase); } public int traitStartIndent() { @@ -806,7 +807,8 @@ public static org.axsl.areaW.TextArea makeTextArea(FOTextContent foText, Area parentArea, int ipd, int startOffset, int sizeInChars, boolean hasDiscretionaryHyphen, - boolean hasFauxSmallCaps, boolean isLastItemOnLine) { + boolean hasFauxSmallCaps, boolean isLastItemOnLine, + FOContext context) { /* If the raw text is empty, don't create the TextArea. */ if (sizeInChars < 1) { @@ -814,7 +816,7 @@ } /* If the final text will be empty, don't create the TextArea. */ - char[] rawText = foText.getAreaTreeText(); + char[] rawText = foText.getAreaTreeText(context); boolean isFirstItemOnline = parentArea.children.size() == 0; int ignoreAtStart = TextArea.ignoreAtStart(rawText, startOffset, sizeInChars, isFirstItemOnline, @@ -864,7 +866,7 @@ boolean hasFauxSmallCaps, boolean isLastItemOnLine) { return LineArea.makeTextArea(foText, this, ipd, startOffset, sizeInChars, hasDiscretionaryHyphen, hasFauxSmallCaps, - isLastItemOnLine); + isLastItemOnLine, this); } public LineOutput asLineOutput() { Modified: trunk/foray/foray-areatree/src/java/org/foray/area/MainRA.java =================================================================== --- trunk/foray/foray-areatree/src/java/org/foray/area/MainRA.java 2006-06-06 23:26:02 UTC (rev 7434) +++ trunk/foray/foray-areatree/src/java/org/foray/area/MainRA.java 2006-06-07 18:05:14 UTC (rev 7435) @@ -67,9 +67,9 @@ int span = Constants.FOVAL_NONE; if (fo instanceof Block) { - span = ((Block)fo).traitSpan(); + span = ((Block)fo).traitSpan(this); } else if (fo instanceof BlockContainer) { - span = ((BlockContainer)fo).traitSpan(); + span = ((BlockContainer)fo).traitSpan(this); } if (this.getChildren().isEmpty()) { @@ -142,9 +142,9 @@ int span = Constants.FOVAL_NONE; if (fo instanceof Block) { - span = ((Block)fo).traitSpan(); + span = ((Block)fo).traitSpan(this); } else if (fo instanceof BlockContainer) { - span = ((BlockContainer)fo).traitSpan(); + span = ((BlockContainer)fo).traitSpan(this); } if ((span == Constants.FOVAL_ALL) Modified: trunk/foray/foray-areatree/src/java/org/foray/area/NormalBlockArea.java =================================================================== --- trunk/foray/foray-areatree/src/java/org/foray/area/NormalBlockArea.java 2006-06-06 23:26:02 UTC (rev 7434) +++ trunk/foray/foray-areatree/src/java/org/foray/area/NormalBlockArea.java 2006-06-07 18:05:14 UTC (rev 7435) @@ -92,7 +92,7 @@ RegionBody body = (RegionBody) mainRA.traitGeneratedBy(); FObj generatedBy = this.traitGeneratedBy(); SpanRA span = new SpanRA(body, mainRA, - generatedBy.traitColumnCount()); + generatedBy.traitColumnCount(this)); overflowColumn = (NormalFlowRA) span.getChildren().get(0); } if (overflowColumn != null) { @@ -146,7 +146,7 @@ } AreaFlexible child = (AreaFlexible) object; FObj listRelatedAncestor = child.traitGeneratedBy() - .ancestorListRelatedObject(); + .ancestorListRelatedObject(this); if (listRelatedAncestor instanceof ListItemLabel) { labelBPD += child.usedProgressionDimension(); } else if (listRelatedAncestor instanceof ListItemBody) { Modified: trunk/foray/foray-areatree/src/java/org/foray/area/PageCollection.java =================================================================== --- trunk/foray/foray-areatree/src/java/org/foray/area/PageCollection.java 2006-06-06 23:26:02 UTC (rev 7434) +++ trunk/foray/foray-areatree/src/java/org/foray/area/PageCollection.java 2006-06-07 18:05:14 UTC (rev 7435) @@ -180,12 +180,13 @@ PageSequence pageSeq = getPageSequence(); PageCollection previousPageCollection = previousPageCollection(); if (previousPageCollection == null) { - currentPageNumber = pageSeq.traitInitialPageNumber(0); + currentPageNumber = pageSeq.traitInitialPageNumber(this, 0); return; } int lastPageNumber = previousPageCollection.getCurrentPageNumber() - 1; - int computedPageNumber = pageSeq.traitInitialPageNumber(lastPageNumber); - if (pageSeq.getRawInitialPageNumber() + int computedPageNumber = pageSeq.traitInitialPageNumber(this, + lastPageNumber); + if (pageSeq.getRawInitialPageNumber(this) == Constants.FOVAL_NOT_A_KEYWORD) { /* * If the user set the page number explicitly, there is nothing @@ -233,7 +234,7 @@ */ PageSequence previousPageSequence = previousPageCollection.getPageSequence(); - if (previousPageSequence.traitForcePageCount() + if (previousPageSequence.traitForcePageCount(this) == Constants.FOVAL_AUTO) { /* * In this case we'll try to put the added page in the previous @@ -258,7 +259,7 @@ */ public void padPagesAtEnd() throws AreaWException { PageSequence pageSeq = getPageSequence(); - switch (pageSeq.traitForcePageCount()) { + switch (pageSeq.traitForcePageCount(this)) { case Constants.FOVAL_AUTO: { /* * The standard would seem to imply that force-page-count="auto" @@ -351,7 +352,7 @@ MainRA mainRA = bodyArea.getMainRA(); RegionBody body = (RegionBody) mainRA.traitGeneratedBy(); int columnsNeeded = -1; - if (nextFObj.traitSpan() == Constants.FOVAL_NONE) { + if (nextFObj.traitSpan(this) == Constants.FOVAL_NONE) { columnsNeeded = mainRA.traitColumnCount(); } else { columnsNeeded = 1; Modified: trunk/foray/foray-areatree/src/java/org/foray/area/PageRA.java =================================================================== --- trunk/foray/foray-areatree/src/java/org/foray/area/PageRA.java 2006-06-06 23:26:02 UTC (rev 7434) +++ trunk/foray/foray-areatree/src/java/org/foray/area/PageRA.java 2006-06-07 18:05:14 UTC (rev 7435) @@ -152,11 +152,11 @@ } public int getHeight() { - return traitGeneratedBy().traitPageHeight(); + return traitGeneratedBy().traitPageHeight(this); } public int getWidth() { - return traitGeneratedBy().traitPageWidth(); + return traitGeneratedBy().traitPageWidth(this); } public void registerMarker(Marker marker) { @@ -191,8 +191,8 @@ } RegionBody regionBody = simplePageMaster.getRegionBody(); RegionRABody area = new RegionRABody(regionBody, this, - regionBody.getXPositionVP_CR(), - regionBody.getYPositionVP_CR()); + regionBody.getXPositionVP_CR(this), + regionBody.getYPositionVP_CR(this)); this.body = area; } @@ -458,43 +458,43 @@ } // search forward if 'first-starting-within-page' or // 'first-including-carryover' - if (retrieve.traitRetrievePosition() + if (retrieve.traitRetrievePosition(this) == Constants.FOVAL_FIRST_INCLUDING_CARRYOVER) { for (int i = 0; i < pageMarkers.size(); i++) { Marker currentMarker = (Marker)pageMarkers.get(i); - if (currentMarker.traitMarkerClassName().equals( - retrieve.traitRetrieveClassName())) { + if (currentMarker.traitMarkerClassName(this).equals( + retrieve.traitRetrieveClassName(this))) { return currentMarker; } } - } else if (retrieve.traitRetrievePosition() + } else if (retrieve.traitRetrievePosition(this) == Constants.FOVAL_FIRST_STARTING_WITHIN_PAGE) { for (int i = 0; i < pageMarkers.size(); i++) { Marker currentMarker = (Marker)pageMarkers.get(i); - if (currentMarker.traitMarkerClassName().equals( - retrieve.traitRetrieveClassName())) { + if (currentMarker.traitMarkerClassName(this).equals( + retrieve.traitRetrieveClassName(this))) { if (startsHere(currentMarker)) { return currentMarker; } } } - } else if (retrieve.traitRetrievePosition() + } else if (retrieve.traitRetrievePosition(this) == Constants.FOVAL_LAST_STARTING_WITHIN_PAGE) { for (int i = pageMarkers.size() - 1; i >= 0; i--) { Marker currentMarker = (Marker)pageMarkers.get(i); - if (currentMarker.traitMarkerClassName().equals( - retrieve.traitRetrieveClassName())) { + if (currentMarker.traitMarkerClassName(this).equals( + retrieve.traitRetrieveClassName(this))) { if (startsHere(currentMarker)) { return currentMarker; } } } - } else if (retrieve.traitRetrievePosition() + } else if (retrieve.traitRetrievePosition(this) == Constants.FOVAL_LAST_ENDING_WITHIN_PAGE) { for (int i = pageMarkers.size() - 1; i >= 0; i--) { Marker currentMarker = (Marker)pageMarkers.get(i); - if (currentMarker.traitMarkerClassName().equals( - retrieve.traitRetrieveClassName())) { + if (currentMarker.traitMarkerClassName(this).equals( + retrieve.traitRetrieveClassName(this))) { if (endsHere(currentMarker)) { return currentMarker; } @@ -505,13 +505,14 @@ // search backward. ArrayList additionalMarkers = null; PageCollection pageCollection = getPageCollection(); - if (retrieve.traitRetrieveBoundary() == Constants.FOVAL_PAGE_SEQUENCE) { + if (retrieve.traitRetrieveBoundary(this) + == Constants.FOVAL_PAGE_SEQUENCE) { PageSequence pageSequence = pageCollection.getPageSequence(); if (pageSequence == getPageSequence()) { additionalMarkers = pageCollection .getCurrentPageSequenceMarkers(); } - } else if (retrieve.traitRetrieveBoundary() + } else if (retrieve.traitRetrieveBoundary(this) == Constants.FOVAL_DOCUMENT) { additionalMarkers = pageCollection.getDocumentMarkers(); } @@ -520,8 +521,8 @@ } for (int i = additionalMarkers.size() - 1; i >= 0; i--) { Marker currentMarker = (Marker) additionalMarkers.get(i); - if (currentMarker.traitMarkerClassName().equals( - retrieve.traitRetrieveClassName())) { + if (currentMarker.traitMarkerClassName(this).equals( + retrieve.traitRetrieveClassName(this))) { return currentMarker; } } Modified: trunk/foray/foray-areatree/src/java/org/foray/area/RegionRA.java =================================================================== --- trunk/foray/foray-areatree/src/java/org/foray/area/RegionRA.java 2006-06-06 23:26:02 UTC (rev 7434) +++ trunk/foray/foray-areatree/src/java/org/foray/area/RegionRA.java 2006-06-07 18:05:14 UTC (rev 7435) @@ -43,11 +43,11 @@ } public int getYPosition() { - return ((Region) traitGeneratedBy()).getYPositionVP_CR(); + return ((Region) traitGeneratedBy()).getYPositionVP_CR(this); } public int getXPosition() { - return ((Region) traitGeneratedBy()).getXPositionVP_CR(); + return ((Region) traitGeneratedBy()).getXPositionVP_CR(this); } public byte getAreaType() { @@ -57,7 +57,7 @@ public int crBPD() { if (this.generatedBy.getFONode() instanceof RegionBefore || this.generatedBy.getFONode() instanceof RegionAfter) { - return traitGeneratedBy().traitExtent(); + return traitGeneratedBy().traitExtent(this); } return getParentArea().brBPD(); } @@ -65,7 +65,7 @@ public int crIPD() { if (this.generatedBy.getFONode() instanceof RegionStart || this.generatedBy.getFONode() instanceof RegionEnd) { - return traitGeneratedBy().traitExtent(); + return traitGeneratedBy().traitExtent(this); } return getParentArea().brIPD(); } Modified: trunk/foray/foray-areatree/src/java/org/foray/area/RegionRABody.java =================================================================== --- trunk/foray/foray-areatree/src/java/org/foray/area/RegionRABody.java 2006-06-06 23:26:02 UTC (rev 7434) +++ trunk/foray/foray-areatree/src/java/org/foray/area/RegionRABody.java 2006-06-07 18:05:14 UTC (rev 7435) @@ -196,11 +196,11 @@ } public int traitColumnCount() { - return traitGeneratedBy().traitColumnCount(); + return traitGeneratedBy().traitColumnCount(this); } public int traitColumnGap() { - return traitGeneratedBy().traitColumnGap(); + return traitGeneratedBy().traitColumnGap(this); } /** Modified: trunk/foray/foray-areatree/src/java/org/foray/area/SpanRA.java =================================================================== --- trunk/foray/foray-areatree/src/java/org/foray/area/SpanRA.java 2006-06-06 23:26:02 UTC (rev 7434) +++ trunk/foray/foray-areatree/src/java/org/foray/area/SpanRA.java 2006-06-07 18:05:14 UTC (rev 7435) @@ -177,7 +177,7 @@ * If the span requirement is for multiple columns & this has them, * then the requirements match & simply return this. */ - if (fo.traitSpan() == Constants.FOVAL_NONE + if (fo.traitSpan(this) == Constants.FOVAL_NONE && this.traitColumnCount() > 1) { return this; } @@ -185,16 +185,16 @@ * If the span requirement is for only one column & this has only one, * then the requirements match & simply return this. */ - if (fo.traitSpan() == Constants.FOVAL_ALL + if (fo.traitSpan(this) == Constants.FOVAL_ALL && this.traitColumnCount() == 1) { return this; } // The requirements do not match, so we need to create a new span area. int numColumns = 0; - if (fo.traitSpan() == Constants.FOVAL_ALL) { + if (fo.traitSpan(this) == Constants.FOVAL_ALL) { numColumns = 1; } else { - numColumns = fo.traitColumnCount(); + numColumns = fo.traitColumnCount(this); } RegionBody body = (RegionBody) this.traitGeneratedBy(); MainRA main = (MainRA) this.getParent(); @@ -239,7 +239,7 @@ for (int i = 0; i < getChildren().size(); i++) { NormalFlowRA nf = (NormalFlowRA) getChildren().get(i); int sizeNextLine = blockArea.traitFontSize() - + blockArea.traitGeneratedBy().traitHalfLeadingOpt(); + + blockArea.traitGeneratedBy().traitHalfLeadingOpt(this); if (nf.bpdUsedByChildren() + sizeNextLine <= this.progressionDimensionAvailable()) { Modified: trunk/foray/foray-areatree/src/java/org/foray/area/TableCellRA.java =================================================================== --- trunk/foray/foray-areatree/src/java/org/foray/area/TableCellRA.java 2006-06-06 23:26:02 UTC (rev 7434) +++ trunk/foray/foray-areatree/src/java/org/foray/area/TableCellRA.java 2006-06-07 18:05:14 UTC (rev 7435) @@ -50,22 +50,22 @@ } public int getPaddingTop() { - return this.traitGeneratedBy().traitPaddingTop() + return this.traitGeneratedBy().traitPaddingTop(this) + getCenteringPaddingTop(); } public int getPaddingLeft() { - return this.traitGeneratedBy().traitPaddingLeft() + return this.traitGeneratedBy().traitPaddingLeft(this) + getCenteringPaddingLeft(); } public int getPaddingBottom() { - return this.traitGeneratedBy().traitPaddingBottom() + return this.traitGeneratedBy().traitPaddingBottom(this) + getCenteringPaddingBottom(); } public int getPaddingRight() { - return this.traitGeneratedBy().traitPaddingRight() + return this.traitGeneratedBy().traitPaddingRight(this) + getCenteringPaddingRight(); } @@ -131,13 +131,13 @@ */ public int getStartAdjust() { TableCell tableCell = (TableCell) traitGeneratedBy(); - if (tableCell.traitBorderCollapse() == Constants.FOVAL_SEPARATE) { - int iSep = tableCell.traitBorderSeparationIPD(); - return iSep / 2 + tableCell.traitBorderLeftWidth() - + tableCell.traitPaddingLeft(); + if (tableCell.traitBorderCollapse(this) == Constants.FOVAL_SEPARATE) { + int iSep = tableCell.traitBorderSeparationIPD(this); + return iSep / 2 + tableCell.traitBorderLeftWidth(this) + + tableCell.traitPaddingLeft(this); } - return tableCell.traitBorderLeftWidth() / 2 - + tableCell.traitPaddingLeft(); + return tableCell.traitBorderLeftWidth(this) / 2 + + tableCell.traitPaddingLeft(this); } /** @@ -147,7 +147,7 @@ */ public int getProgressionDimension() { TableArea tableRA = this.ancestorTableArea(); - int startingColumn = this.traitGeneratedBy().traitColumnNumber(); + int startingColumn = this.traitGeneratedBy().traitColumnNumber(this); int span = this.traitGeneratedBy().traitNumberColumnsSpanned(); return tableRA.ipdCell(startingColumn, span); } Modified: trunk/foray/foray-areatree/src/java/org/foray/area/TableRA.java =================================================================== --- trunk/foray/foray-areatree/src/java/org/foray/area/TableRA.java 2006-06-06 23:26:02 UTC (rev 7434) +++ trunk/foray/foray-areatree/src/java/org/foray/area/TableRA.java 2006-06-07 18:05:14 UTC (rev 7435) @@ -29,6 +29,7 @@ import org.axsl.areaW.TableFooterContainer; import org.axsl.areaW.TableHeaderContainer; import org.axsl.common.ConstantsAreaTree; +import org.axsl.foR.FOContext; import org.axsl.foR.fo.Table; import org.axsl.foR.fo.TableBody; import org.axsl.foR.fo.TableColumn; @@ -47,7 +48,8 @@ for (int i = 0; i < numColumns; i++) { TableColumn column = generatedBy.getTableColumn(i); if (column != null) { - resolvedColumnWidth[i] = column.traitColumnWidth(this.crIPD()); + resolvedColumnWidth[i] = column.traitColumnWidth(this, + this.crIPD()); } } } @@ -87,8 +89,8 @@ /** * The value returned here can be different from the nominal column-width - * returned by {@link TableColumn#traitColumnWidth(int)} because of - * allocation of excesses or deficiencies in the table width. + * returned by {@link TableColumn#traitColumnWidth(FOContext, int)} + * because of allocation of excesses or deficiencies in the table width. * @return The computed column-width, in millipoints. */ public int getResolvedColumnWidth(int startingColumn) { Modified: trunk/foray/foray-areatree/src/java/org/foray/area/TextArea.java =================================================================== --- trunk/foray/foray-areatree/src/java/org/foray/area/TextArea.java 2006-06-06 23:26:02 UTC (rev 7434) +++ trunk/foray/foray-areatree/src/java/org/foray/area/TextArea.java 2006-06-07 18:05:14 UTC (rev 7435) @@ -179,7 +179,7 @@ * @return The raw text from the FO Tree. */ protected char[] getRawText() { - return this.getTextContent().getAreaTreeText(); + return this.getTextContent().getAreaTreeText(this); } public byte getAreaType() { @@ -516,7 +516,7 @@ */ public int traitFontSize() { if (hasFauxSmallCaps) { - return traitGeneratedBy().getFauxSmallCapFontSize(); + return traitGeneratedBy().getFauxSmallCapFontSize(this); } return super.traitFontSize(); } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
|
From: <vic...@us...> - 2006-06-06 23:26:11
|
Revision: 7434 Author: victormote Date: 2006-06-06 16:26:02 -0700 (Tue, 06 Jun 2006) ViewCVS: http://svn.sourceforge.net/foray/?rev=7434&view=rev Log Message: ----------- Conform to axsl change: Make Area implement new FOContext interface. Modified Paths: -------------- trunk/foray/foray-areatree/src/java/org/foray/area/Area.java Modified: trunk/foray/foray-areatree/src/java/org/foray/area/Area.java =================================================================== --- trunk/foray/foray-areatree/src/java/org/foray/area/Area.java 2006-06-06 22:34:18 UTC (rev 7433) +++ trunk/foray/foray-areatree/src/java/org/foray/area/Area.java 2006-06-06 23:26:02 UTC (rev 7434) @@ -36,6 +36,8 @@ import org.axsl.foR.fo.Block; import org.axsl.foR.fo.BlockContainer; import org.axsl.foR.fo.ListBlock; +import org.axsl.foR.fo.Marker; +import org.axsl.foR.fo.RetrieveMarker; import org.axsl.foR.fo.Table; import org.axsl.fontR.Font; import org.axsl.fontR.FontUse; @@ -1242,4 +1244,8 @@ return true; } + public RetrieveMarker getRetrieveMarker(Marker marker) { + return null; + } + } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
|
From: <vic...@us...> - 2006-06-06 22:43:13
|
Revision: 7425 Author: victormote Date: 2006-06-06 11:04:34 -0700 (Tue, 06 Jun 2006) ViewCVS: http://svn.sourceforge.net/foray/?rev=7425&view=rev Log Message: ----------- If the factory method in this class is creating it, then this LineArea is the parent. Other Area classes that create inlines need their own factory methods. Modified Paths: -------------- trunk/foray/foray-areatree/src/java/org/foray/area/LineArea.java Modified: trunk/foray/foray-areatree/src/java/org/foray/area/LineArea.java =================================================================== --- trunk/foray/foray-areatree/src/java/org/foray/area/LineArea.java 2006-06-06 00:53:11 UTC (rev 7424) +++ trunk/foray/foray-areatree/src/java/org/foray/area/LineArea.java 2006-06-06 18:04:34 UTC (rev 7425) @@ -27,15 +27,11 @@ import org.axsl.areaW.AreaWException; import org.axsl.common.Constants; import org.axsl.common.ConstantsAreaTree; -import org.axsl.foR.FONode; import org.axsl.foR.FOText; import org.axsl.foR.FObj; import org.axsl.foR.FObjMixed; -import org.axsl.foR.fo.BasicLink; -import org.axsl.foR.fo.Block; import org.axsl.foR.fo.Character; import org.axsl.foR.fo.ExternalGraphic; -import org.axsl.foR.fo.Inline; import org.axsl.foR.fo.InstreamForeignObject; import org.axsl.foR.fo.Leader; import org.axsl.foR.fo.PageNumber; @@ -784,32 +780,27 @@ public org.axsl.areaW.ForeignObjectArea makeForeignObjectArea( InstreamForeignObject ifo, int ipd) { - Area parentArea = findParentArea(ifo); - return new ForeignObjectArea(ifo, parentArea, ipd); + return new ForeignObjectArea(ifo, this, ipd); } public org.axsl.areaW.ExternalGraphicArea makeExternalGraphicArea( ExternalGraphic ifo, int ipd) { - Area parentArea = findParentArea(ifo); - return new ExternalGraphicArea(ifo, parentArea, ipd); + return new ExternalGraphicArea(ifo, this, ipd); } public org.axsl.areaW.LeaderArea makeLeaderArea( Leader leader, int ipd) { - Area parentArea = findParentArea(leader); - return new LeaderArea(leader, parentArea, ipd); + return new LeaderArea(leader, this, ipd); } public org.axsl.areaW.PageNumberArea makePageNumberArea( PageNumber pageNumber, int ipd) { - Area parentArea = findParentArea(pageNumber); - return new PageNumberArea(pageNumber, parentArea, ipd); + return new PageNumberArea(pageNumber, this, ipd); } public org.axsl.areaW.PageNumberCitationArea makePageNumberCitationArea( PageNumberCitation citation, int ipd) { - Area parentArea = findParentArea(citation); - return new PageNumberCitationArea(citation, parentArea, ipd); + return new PageNumberCitationArea(citation, this, ipd); } /** @@ -837,46 +828,45 @@ /* Go ahead and create*/ FObj parent = foText.parentFO(); - Area parentArea = findParentArea(foText); if (parent instanceof FObjMixed) { FObjMixed mixed = (FObjMixed) foText.parentFO(); int sequence = mixed.getChildren().indexOf(foText); int initialWordSpacing = this.traitWordSpacingOpt(); int initialLetterSpacing = this.traitLetterSpacingOpt(); - return new TextArea(mixed, parentArea, sequence, + return new TextArea(mixed, this, sequence, startOffset, sizeInChars, ipd, initialLetterSpacing, initialWordSpacing, hasDiscretionaryHyphen, hasFauxSmallCaps); } if (parent instanceof Character) { - return new TextArea((Character) parent, parentArea, ipd, 0, 0, + return new TextArea((Character) parent, this, ipd, 0, 0, hasDiscretionaryHyphen, hasFauxSmallCaps); } return null; } - private AreaFlexible findParentArea(FONode node) { - // This is the easy and probably most frequent case - if (node.parentFO() instanceof Block) { - return this; - } - /* - * TODO: A test needs to be - * added to see whether the last child of LineArea should be a parent - * or other ancestor of node. If so, as much of that hierarchy as is - * common to node should be preserved. - */ - if (node.parentFO() instanceof BasicLink) { - BasicLink bl = (BasicLink) node.parentFO(); - return new BasicLinkArea(bl, findParentArea(bl)); - } - if (node.parentFO() instanceof Inline) { - Inline inline = (Inline) node.parentFO(); - return new InlineArea(inline, findParentArea(inline)); - } - // Default if nothing else works. - return this; - } +// private AreaFlexible findParentArea(FONode node) { +// // This is the easy and probably most frequent case +// if (node.parentFO() instanceof Block) { +// return this; +// } +// /* +// * TODO: A test needs to be +// * added to see whether the last child of LineArea should be a parent +// * or other ancestor of node. If so, as much of that hierarchy as is +// * common to node should be preserved. +// */ +// if (node.parentFO() instanceof BasicLink) { +// BasicLink bl = (BasicLink) node.parentFO(); +// return new BasicLinkArea(bl, findParentArea(bl)); +// } +// if (node.parentFO() instanceof Inline) { +// Inline inline = (Inline) node.parentFO(); +// return new InlineArea(inline, findParentArea(inline)); +// } +// // Default if nothing else works. +// return this; +// } public LineOutput asLineOutput() { return this; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
|
From: <vic...@us...> - 2006-06-06 22:35:41
|
Revision: 7433 Author: victormote Date: 2006-06-06 15:34:18 -0700 (Tue, 06 Jun 2006) ViewCVS: http://svn.sourceforge.net/foray/?rev=7433&view=rev Log Message: ----------- Rename method for clarity. Modified Paths: -------------- trunk/foray/foray-fotree/src/java/org/foray/fotree/FONode.java trunk/foray/foray-fotree/src/java/org/foray/fotree/FOText.java trunk/foray/foray-fotree/src/java/org/foray/fotree/FOTreeBuilder.java trunk/foray/foray-fotree/src/java/org/foray/fotree/FObj.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/Bookmark.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/Marker.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/Wrapper.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/AbsoluteDimension.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/AbsoluteOffset.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/AlignmentAdjust.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/AlignmentBaseline.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/AudioDial.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Azimuth.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/BackgroundImage.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/BackgroundPosition.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/BaselineShift.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Boolean.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/BorderPrecedence.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/BorderSeparation.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/BorderStyle.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/BorderWidth.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Character.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Clip.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Color.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/ColumnCount.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/ColumnGap.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/ContentDimension.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Country.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Cue.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/DisplayAlign.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/DominantBaseline.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Elevation.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Enumerated.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Extent.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/FontFamily.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/FontSize.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/FontSizeAdjust.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/FontStretch.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/FontStyle.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/FontVariant.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/FontWeight.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/ForcePageCount.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/GlyphOrientation.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/HyphLadderCount.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/HyphPushCharCount.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/HyphRemainCharCount.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Indent.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/InitialPageNumber.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Keep.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Language.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/LastLineEndIndent.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/LeaderLength.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/LeaderPatternWidth.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/LetterSpacing.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/LineHeight.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Margin.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/MaximumRepeats.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Name.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Orphans.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Padding.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/PageDimension.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Pause.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Pitch.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/PlayDuring.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/ProvDistanceBetween.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/ProvLabelSeparation.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/RefId.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/RelativeDimension.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/RelativeSpace.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Role.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/RuleThickness.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Script.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Size.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/SourceDocument.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/SpeechRate.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Src.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/TextAlign.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/TextAlignLast.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/TextAltitude.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/TextDecoration.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/TextDepth.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/TextIndent.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/TextShadow.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/TreatAsWordSpace.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/VoiceFamily.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Volume.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Widows.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/WordSpacing.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/WritingMode.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/ZIndex.java trunk/foray/foray-fotree/src/java/org/foray/fotree/value/FnFromParent.java trunk/foray/foray-fotree/src/java/org/foray/fotree/value/FnInheritedProp.java trunk/foray/foray-fotree/src/java/org/foray/fotree/value/FnNearestSpecProp.java Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/FONode.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/FONode.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/FONode.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -43,7 +43,7 @@ super(parent); } - public FObj getFObjParent() { + public FObj realParent() { return (FObj) this.getParent(); } Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/FOText.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/FOText.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/FOText.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -128,7 +128,7 @@ char[] charArray = getPreTextTransformText(); // Now handle text-transform. - short textTransform = getFObjParent().traitTextTransform(); + short textTransform = realParent().traitTextTransform(); if (textTransform != Constants.FOVAL_NONE) { for (int i = 0; i < charArray.length; i++) { charArray[i] = applyTextTransform(charArray, i, textTransform); @@ -166,11 +166,11 @@ /* Must handle white-space-treatment first. */ char[] workArray = applyWhiteSpaceTreatment(this.ca, - getFObjParent().traitWhiteSpaceTreatment()); + realParent().traitWhiteSpaceTreatment()); // Now handle linefeed-treatment. workArray = applyLinefeedTreatment(workArray, - getFObjParent().traitLinefeedTreatment()); + realParent().traitLinefeedTreatment()); /* Update this instance's text with the filtered value and update the * status. */ @@ -444,13 +444,13 @@ } /* If either is within a Leader, they both need to be in the same one. */ - Leader thisLeader = this.getFObjParent().getNearestLeader(); - Leader testLeader = leafToTest.getFObjParent().getNearestLeader(); + Leader thisLeader = this.realParent().getNearestLeader(); + Leader testLeader = leafToTest.realParent().getNearestLeader(); if (thisLeader != testLeader) { return null; } - Block thisBlock = this.getFObjParent().getContainingBlock(); - Block testBlock = leafToTest.getFObjParent().getContainingBlock(); + Block thisBlock = this.realParent().getContainingBlock(); + Block testBlock = leafToTest.realParent().getContainingBlock(); if (thisBlock != testBlock) { return null; } @@ -476,7 +476,7 @@ // Start with the refined FO Tree text char[] returnArray = getRefinedText(); // Apply white-space-collapse. - boolean whiteSpaceCollapse = getFObjParent().traitWhiteSpaceCollapse(); + boolean whiteSpaceCollapse = realParent().traitWhiteSpaceCollapse(); returnArray = applyWhiteSpaceCollapse(returnArray, whiteSpaceCollapse); /* Set the instance text to the more refined value and update the @@ -491,51 +491,51 @@ } public FontUse inlinePrimaryFont() { - return getFObjParent().getPrimaryFont(); + return realParent().getPrimaryFont(); } public FontUse inlineSecondaryFont(char c) { - return getFObjParent().getSecondaryFont(c); + return realParent().getSecondaryFont(c); } public int inlineFontSize() { - return getFObjParent().traitFontSize(); + return realParent().traitFontSize(); } public int inlineLetterSpacingOptimum() { - return getFObjParent().traitLetterSpacingOpt(); + return realParent().traitLetterSpacingOpt(); } public boolean inlineWrapOption() { - return (getFObjParent().traitWrapOption() == Constants.FOVAL_WRAP); + return (realParent().traitWrapOption() == Constants.FOVAL_WRAP); } public boolean inlineHyphenate() { - return getFObjParent().traitHyphenate(); + return realParent().traitHyphenate(); } public String inlineLanguage() { - return getFObjParent().traitLanguage(); + return realParent().traitLanguage(); } public String inlineCountry() { - return getFObjParent().traitCountry(); + return realParent().traitCountry(); } public int inlineHyphenationRemainCount() { - return getFObjParent().traitHyphenationRemainCharacterCount(); + return realParent().traitHyphenationRemainCharacterCount(); } public int inlineHyphenationPushCount() { - return getFObjParent().traitHyphenationPushCharacterCount(); + return realParent().traitHyphenationPushCharacterCount(); } public char inlineHyphenationCharacter() { - return getFObjParent().traitHyphenationCharacter(); + return realParent().traitHyphenationCharacter(); } public boolean inlineIsFauxSmallCaps() { - FObj parent = this.getFObjParent(); + FObj parent = this.realParent(); if (parent.traitFontVariant() != Constants.FOVAL_SMALL_CAPS) { return false; } @@ -550,7 +550,7 @@ } public int inlineFauxSmallCapsFontSize() { - return this.getFObjParent().getFauxSmallCapFontSize(); + return this.realParent().getFauxSmallCapFontSize(); } public LineText nextContiguousLineText() { Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/FOTreeBuilder.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/FOTreeBuilder.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/FOTreeBuilder.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -143,7 +143,7 @@ // Notify the listeners that this page-sequence is complete. notifyPageSequenceComplete((PageSequence) currentFObj); } - currentFObj = currentFObj.getFObjParent(); + currentFObj = currentFObj.realParent(); } /** Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/FObj.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/FObj.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/FObj.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -186,10 +186,10 @@ * {@inheritDoc} */ public org.axsl.foR.FObj getNearestAncestorGeneratingRA() { - if (getFObjParent().traitIsReferenceArea()) { - return getFObjParent(); + if (realParent().traitIsReferenceArea()) { + return realParent(); } - return getFObjParent().getNearestAncestorGeneratingRA(); + return realParent().getNearestAncestorGeneratingRA(); } /** @@ -206,7 +206,7 @@ * {@inheritDoc} */ public org.axsl.foR.fo.ListItem getNearestListItem() { - return getFObjParent().getNearestListItem(); + return realParent().getNearestListItem(); } /** @@ -219,21 +219,21 @@ if (getParent() instanceof org.axsl.foR.fo.ListBlock) { return (org.axsl.foR.fo.ListBlock) getParent(); } - return getFObjParent().getNearestAncestorListBlock(); + return realParent().getNearestAncestorListBlock(); } /** * {@inheritDoc} */ public org.axsl.foR.fo.Root getRoot() { - return getFObjParent().getRoot(); + return realParent().getRoot(); } /** * {@inheritDoc} */ public org.axsl.foR.fo.Block getContainingBlock() { - return getFObjParent().getContainingBlock(); + return realParent().getContainingBlock(); } /** @@ -243,43 +243,43 @@ if (getParent() == null) { return null; } - return getFObjParent().getFlow(); + return realParent().getFlow(); } public FOTreeBuilder getFOTreeBuilder() { - return getFObjParent().getFOTreeBuilder(); + return realParent().getFOTreeBuilder(); } public Log getLogger() { - return getFObjParent().getLogger(); + return realParent().getLogger(); } /** * {@inheritDoc} */ public org.axsl.foR.fo.Table getNearestTable() { - return getFObjParent().getNearestTable(); + return realParent().getNearestTable(); } /** * {@inheritDoc} */ public org.axsl.foR.fo.Leader getNearestLeader() { - return getFObjParent().getNearestLeader(); + return realParent().getNearestLeader(); } /** * {@inheritDoc} */ public org.axsl.foR.fo.BasicLink getBasicLink() { - return getFObjParent().getBasicLink(); + return realParent().getBasicLink(); } /** * {@inheritDoc} */ public org.axsl.foR.FObj ancestorListRelatedObject() { - return getFObjParent().ancestorListRelatedObject(); + return realParent().ancestorListRelatedObject(); } /** @@ -1738,17 +1738,17 @@ return this.getBaselineFromScript(); } } else { - return this.getFObjParent().traitDominantBaseline(); + return this.realParent().traitDominantBaseline(); } } case Constants.FOVAL_USE_SCRIPT: { return this.getBaselineFromScript(); } case Constants.FOVAL_NO_CHANGE: { - return this.getFObjParent().traitDominantBaseline(); + return this.realParent().traitDominantBaseline(); } case Constants.FOVAL_RESET_SIZE: { - return this.getFObjParent().traitDominantBaseline(); + return this.realParent().traitDominantBaseline(); } case Constants.FOVAL_IDEOGRAPHIC: { return Constants.BASELINE_IDEOGRAPHIC; Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/Bookmark.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/Bookmark.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/Bookmark.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -86,7 +86,7 @@ public Bookmark getParentOutline() { for (FONode node = (FONode) getParent(); - node != null; node = node.getFObjParent()) { + node != null; node = node.realParent()) { if (node instanceof Bookmark) { return (Bookmark)node; } Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/Marker.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/Marker.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/Marker.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -45,7 +45,7 @@ throwException(getFullName() + " must be descendant of fo:flow."); } // Validate that there is not content before this and other markers. - List siblings = getFObjParent().getChildren(); + List siblings = realParent().getChildren(); for (int i = 0; i < siblings.size(); i++) { FONode sibling = (FONode) siblings.get(i); if ((sibling instanceof Marker) @@ -60,7 +60,7 @@ public void start() throws FOTreeException { // Make sure that no sibling marker has the same 'marker-class-name'. - List siblings = getFObjParent().getChildren(); + List siblings = realParent().getChildren(); for (int i = 0; i < siblings.size(); i++) { if (! (siblings.get(i) instanceof Marker)) { continue; Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/Wrapper.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/Wrapper.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/Wrapper.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -76,9 +76,9 @@ * @return The closest non-wrapper ancestor. */ public FObj getNonWrapperAncestor() { - FObj ancestor = this.getFObjParent(); + FObj ancestor = this.realParent(); while (ancestor instanceof Wrapper) { - ancestor = ancestor.getFObjParent(); + ancestor = ancestor.realParent(); } return ancestor; } Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/AbsoluteDimension.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/AbsoluteDimension.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/AbsoluteDimension.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -102,28 +102,28 @@ case Constants.FOPROP_HEIGHT: case Constants.FOPROP_WIDTH: { if (relativeAxis == Constants.AXIS_BP) { - return fobj.getFObjParent().traitBPDimensionOpt + return fobj.realParent().traitBPDimensionOpt (dimAncestorGenByBlockLevelFO); } - return fobj.getFObjParent().traitIPDimensionOpt + return fobj.realParent().traitIPDimensionOpt (dimAncestorGenByBlockLevelFO); } case Constants.FOPROP_MAX_HEIGHT: case Constants.FOPROP_MAX_WIDTH: { if (relativeAxis == Constants.AXIS_BP) { - return fobj.getFObjParent().traitBPDimensionMax + return fobj.realParent().traitBPDimensionMax (dimAncestorGenByBlockLevelFO); } - return fobj.getFObjParent().traitIPDimensionMax + return fobj.realParent().traitIPDimensionMax (dimAncestorGenByBlockLevelFO); } case Constants.FOPROP_MIN_HEIGHT: case Constants.FOPROP_MIN_WIDTH: { if (relativeAxis == Constants.AXIS_BP) { - return fobj.getFObjParent().traitBPDimensionMin + return fobj.realParent().traitBPDimensionMin (dimAncestorGenByBlockLevelFO); } - return fobj.getFObjParent().traitIPDimensionMin + return fobj.realParent().traitIPDimensionMin (dimAncestorGenByBlockLevelFO); } } Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/AbsoluteOffset.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/AbsoluteOffset.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/AbsoluteOffset.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -80,7 +80,7 @@ return Constants.ABSOLUTE_POSITION_AUTO; } case Constants.FOVAL_INHERIT: { - FObj parent = fobj.getFObjParent(); + FObj parent = fobj.realParent(); if (parent == null) { return getValueNoInstance(); } Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/AlignmentAdjust.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/AlignmentAdjust.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/AlignmentAdjust.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -85,7 +85,7 @@ short keyword = ((PropertyKeyword) value).getValue(); switch (keyword) { case Constants.FOVAL_INHERIT: { - return fobj.getFObjParent().traitAlignmentAdjust(); + return fobj.realParent().traitAlignmentAdjust(); } default: { return keyword; Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/AlignmentBaseline.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/AlignmentBaseline.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/AlignmentBaseline.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -73,7 +73,7 @@ short keyword = ((PropertyKeyword) value).getValue(); switch (keyword) { case Constants.FOVAL_INHERIT: { - return fobj.getFObjParent().traitAlignmentBaseline(); + return fobj.realParent().traitAlignmentBaseline(); } default: { return keyword; Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/AudioDial.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/AudioDial.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/AudioDial.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -87,7 +87,7 @@ } public static double getValueNoInstance(FObj fobj, short propertyType) { - FObj parent = fobj.getFObjParent(); + FObj parent = fobj.realParent(); if (parent != null) { switch (propertyType) { case Constants.FOPROP_PITCH_RANGE: { Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Azimuth.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Azimuth.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Azimuth.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -179,7 +179,7 @@ } public static float getValueNoInstance(FObj fobj) { - FObj parent = fobj.getFObjParent(); + FObj parent = fobj.realParent(); if (parent != null) { return parent.traitAzimuth(); } Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/BackgroundImage.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/BackgroundImage.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/BackgroundImage.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -77,7 +77,7 @@ short keyword = ((PropertyKeyword) value).getValue(); switch (keyword) { case Constants.FOVAL_INHERIT: { - FObj parent = fobj.getFObjParent(); + FObj parent = fobj.realParent(); if (parent != null) { return parent.traitBackgroundImage(); } Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/BackgroundPosition.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/BackgroundPosition.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/BackgroundPosition.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -205,7 +205,7 @@ return paddingRectangleDimension - backgroundImageDimension; } case Constants.FOVAL_INHERIT: { - FObj parent = fobj.getFObjParent(); + FObj parent = fobj.realParent(); if (parent != null) { switch (axis) { case Constants.AXIS_HORIZONTAL: { Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/BaselineShift.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/BaselineShift.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/BaselineShift.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -79,7 +79,7 @@ case Constants.FOVAL_SUB: { /* TODO: This is the legacy computation. It needs to be * rewritten from the spec. */ - FObj parent = fobj.getFObjParent(); + FObj parent = fobj.realParent(); int ascender = parent.getPrimaryFont().getFont().getAscender( parent.traitFontSize()); return (int) Math.round(2 * ascender / 3.0); @@ -87,13 +87,13 @@ case Constants.FOVAL_SUPER: { /* TODO: This is the legacy computation. It needs to be * rewritten from the spec. */ - FObj parent = fobj.getFObjParent(); + FObj parent = fobj.realParent(); int ascender = parent.getPrimaryFont().getFont().getAscender( parent.traitFontSize()); return (int) Math.round(-2 * ascender / 3.0); } case Constants.FOVAL_INHERIT: { - return fobj.getFObjParent().traitBaselineShift(); + return fobj.realParent().traitBaselineShift(); } } } @@ -105,7 +105,7 @@ } if (this.value instanceof DtPercentage) { /* TODO: This base value is almost certainly wrong. */ - int base = fobj.getFObjParent() + int base = fobj.realParent() .propertyList.getLineHeight(OPTIMUM); return Math.round(((DtPercentage) this.value).getValue() * base); } Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Boolean.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Boolean.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Boolean.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -83,7 +83,7 @@ } public static boolean getValueNoInstance(FObj fobj, short propertyType) { - FObj parent = fobj.getFObjParent(); + FObj parent = fobj.realParent(); switch (propertyType) { case Constants.FOPROP_HYPHENATE: { if (parent != null) { Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/BorderPrecedence.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/BorderPrecedence.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/BorderPrecedence.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -82,7 +82,7 @@ return FORCE_VALUE; } case Constants.FOVAL_INHERIT: { - FObj parent = fobj.getFObjParent(); + FObj parent = fobj.realParent(); if (parent != null) { switch (direction) { case Constants.DIRECTION_BEFORE: { Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/BorderSeparation.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/BorderSeparation.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/BorderSeparation.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -105,7 +105,7 @@ } public static int getValueNoInstance(byte axis, FObj fobj) { - FObj parent = fobj.getFObjParent(); + FObj parent = fobj.realParent(); if (parent == null) { return 0; } Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/BorderStyle.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/BorderStyle.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/BorderStyle.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -120,28 +120,28 @@ } switch (direction) { case Constants.DIRECTION_BEFORE: { - return fobj.getFObjParent().traitBorderBeforeStyle(); + return fobj.realParent().traitBorderBeforeStyle(); } case Constants.DIRECTION_AFTER: { - return fobj.getFObjParent().traitBorderAfterStyle(); + return fobj.realParent().traitBorderAfterStyle(); } case Constants.DIRECTION_START: { - return fobj.getFObjParent().traitBorderStartStyle(); + return fobj.realParent().traitBorderStartStyle(); } case Constants.DIRECTION_END: { - return fobj.getFObjParent().traitBorderEndStyle(); + return fobj.realParent().traitBorderEndStyle(); } case Constants.DIRECTION_LEFT: { - return fobj.getFObjParent().traitBorderLeftStyle(); + return fobj.realParent().traitBorderLeftStyle(); } case Constants.DIRECTION_RIGHT: { - return fobj.getFObjParent().traitBorderRightStyle(); + return fobj.realParent().traitBorderRightStyle(); } case Constants.DIRECTION_TOP: { - return fobj.getFObjParent().traitBorderTopStyle(); + return fobj.realParent().traitBorderTopStyle(); } case Constants.DIRECTION_BOTTOM: { - return fobj.getFObjParent().traitBorderBottomStyle(); + return fobj.realParent().traitBorderBottomStyle(); } } return getValueNoInstance(); Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/BorderWidth.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/BorderWidth.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/BorderWidth.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -175,28 +175,28 @@ case Constants.FOVAL_INHERIT: { switch (direction) { case Constants.DIRECTION_BEFORE: { - return fobj.getFObjParent().traitBorderBeforeWidth(isOuterEdge); + return fobj.realParent().traitBorderBeforeWidth(isOuterEdge); } case Constants.DIRECTION_AFTER: { - return fobj.getFObjParent().traitBorderAfterWidth(isOuterEdge); + return fobj.realParent().traitBorderAfterWidth(isOuterEdge); } case Constants.DIRECTION_START: { - return fobj.getFObjParent().traitBorderStartWidth(isOuterEdge); + return fobj.realParent().traitBorderStartWidth(isOuterEdge); } case Constants.DIRECTION_END: { - return fobj.getFObjParent().traitBorderEndWidth(isOuterEdge); + return fobj.realParent().traitBorderEndWidth(isOuterEdge); } case Constants.DIRECTION_LEFT: { - return fobj.getFObjParent().traitBorderLeftWidth(); + return fobj.realParent().traitBorderLeftWidth(); } case Constants.DIRECTION_RIGHT: { - return fobj.getFObjParent().traitBorderRightWidth(); + return fobj.realParent().traitBorderRightWidth(); } case Constants.DIRECTION_TOP: { - return fobj.getFObjParent().traitBorderTopWidth(); + return fobj.realParent().traitBorderTopWidth(); } case Constants.DIRECTION_BOTTOM: { - return fobj.getFObjParent().traitBorderBottomWidth(); + return fobj.realParent().traitBorderBottomWidth(); } } } Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Character.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Character.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Character.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -92,7 +92,7 @@ return CHARACTER_NOT_SPECIFIED; } case Constants.FOPROP_HYPHENATION_CHARACTER: { - FObj parent = fobj.getFObjParent(); + FObj parent = fobj.realParent(); if (parent != null) { return parent.traitHyphenationCharacter(); } Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Clip.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Clip.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Clip.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -74,7 +74,7 @@ return null; } case Constants.FOVAL_INHERIT: { - FObj parent = fobj.getFObjParent(); + FObj parent = fobj.realParent(); if (parent != null) { return parent.traitClip(); } Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Color.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Color.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Color.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -98,7 +98,7 @@ } public static java.awt.Color getValueNoInstance(FObj fobj) { - FObj parent = fobj.getFObjParent(); + FObj parent = fobj.realParent(); if (parent == null) { return getDefaultColor(); } Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/ColumnCount.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/ColumnCount.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/ColumnCount.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -67,7 +67,7 @@ if (this.value instanceof PropertyKeyword) { short keyword = ((PropertyKeyword) this.value).getValue(); if (keyword == Constants.FOVAL_INHERIT) { - FObj parent = fobj.getFObjParent(); + FObj parent = fobj.realParent(); if (parent != null) { return parent.traitColumnCount(); } Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/ColumnGap.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/ColumnGap.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/ColumnGap.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -72,7 +72,7 @@ short keyword = ((PropertyKeyword) value).getValue(); switch (keyword) { case Constants.FOVAL_INHERIT: { - FObj parent = fobj.getFObjParent(); + FObj parent = fobj.realParent(); if (parent == null) { return getValueNoInstance(); } Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/ContentDimension.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/ContentDimension.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/ContentDimension.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -86,7 +86,7 @@ short keyword = ((PropertyKeyword) value).getValue(); switch (keyword) { case Constants.FOVAL_INHERIT: { - FObj parent = fobj.getFObjParent(); + FObj parent = fobj.realParent(); if (parent == null) { return getValueNoInstance(); } Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Country.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Country.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Country.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -86,7 +86,7 @@ } public static String getValueNoInstance(FObj fobj) { - FObj parent = fobj.getFObjParent(); + FObj parent = fobj.realParent(); if (parent != null) { return parent.traitCountry(); } Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Cue.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Cue.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Cue.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -100,7 +100,7 @@ short keyword = ((PropertyKeyword) this.value).getValue(); switch (keyword) { case Constants.FOVAL_INHERIT: { - FObj parent = fobj.getFObjParent(); + FObj parent = fobj.realParent(); if (parent != null) { switch (propertyType) { case Constants.FOPROP_CUE_BEFORE: { Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/DisplayAlign.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/DisplayAlign.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/DisplayAlign.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -66,7 +66,7 @@ short keyword = ((PropertyKeyword) value).getValue(); switch (keyword) { case Constants.FOVAL_INHERIT: { - return fobj.getFObjParent().traitDisplayAlign(); + return fobj.realParent().traitDisplayAlign(); } default: { return keyword; Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/DominantBaseline.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/DominantBaseline.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/DominantBaseline.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -74,7 +74,7 @@ short keyword = ((PropertyKeyword) value).getValue(); switch (keyword) { case Constants.FOVAL_INHERIT: { - return fobj.getFObjParent().traitDominantBaseline(); + return fobj.realParent().traitDominantBaseline(); } default: { return keyword; Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Elevation.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Elevation.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Elevation.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -98,7 +98,7 @@ } public static float getValueNoInstance(FObj fobj) { - FObj parent = fobj.getFObjParent(); + FObj parent = fobj.realParent(); if (parent != null) { return parent.traitAzimuth(); } Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Enumerated.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Enumerated.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Enumerated.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -66,7 +66,7 @@ if (this.value instanceof PropertyKeyword) { short keyword = ((PropertyKeyword) this.value).getValue(); if (keyword == Constants.FOVAL_INHERIT) { - FObj parent = fobj.getFObjParent(); + FObj parent = fobj.realParent(); if (parent != null) { return getInheritedValue(parent); } @@ -78,7 +78,7 @@ } public static short getValueNoInstance(short propertyType, FObj fobj) { - FObj parent = fobj.getFObjParent(); + FObj parent = fobj.realParent(); switch (propertyType) { case Constants.FOPROP_ABSOLUTE_POSITION: { return Constants.FOVAL_AUTO; Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Extent.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Extent.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Extent.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -76,7 +76,7 @@ short keyword = ((PropertyKeyword) value).getValue(); switch (keyword) { case Constants.FOVAL_INHERIT: { - FObj parent = fobj.getFObjParent(); + FObj parent = fobj.realParent(); if (parent == null) { return getValueNoInstance(); } Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/FontFamily.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/FontFamily.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/FontFamily.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -103,7 +103,7 @@ } public static String[] getValueNoInstance(FObj fobj) { - FObj parent = fobj.getFObjParent(); + FObj parent = fobj.realParent(); if (parent != null) { return parent.traitFontFamily(); } Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/FontSize.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/FontSize.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/FontSize.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -160,7 +160,7 @@ * The base font size comes from the parent object, and is needed * for "em" and percentage computations. */ - FObj parent = fobj.getFObjParent(); + FObj parent = fobj.realParent(); int baseFontSize = getDefaultFontSize(); if (parent != null) { baseFontSize = parent.traitFontSize(); Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/FontSizeAdjust.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/FontSizeAdjust.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/FontSizeAdjust.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -88,7 +88,7 @@ } public static double getValueNoInstance(FObj fobj) { - FObj parent = fobj.getFObjParent(); + FObj parent = fobj.realParent(); if (fobj != null) { return parent.traitFontSizeAdjust(); } Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/FontStretch.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/FontStretch.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/FontStretch.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -85,7 +85,7 @@ } public static short getValueNoInstance(FObj fobj) { - FObj parent = fobj.getFObjParent(); + FObj parent = fobj.realParent(); if (parent != null) { return parent.traitFontStretch(); } Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/FontStyle.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/FontStyle.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/FontStyle.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -82,7 +82,7 @@ } public static short getValueNoInstance(FObj fobj) { - FObj parent = fobj.getFObjParent(); + FObj parent = fobj.realParent(); if (parent != null) { return parent.traitFontStyle(); } Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/FontVariant.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/FontVariant.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/FontVariant.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -76,7 +76,7 @@ } public static short getValueNoInstance(FObj fobj) { - FObj parent = fobj.getFObjParent(); + FObj parent = fobj.realParent(); if (parent != null) { return parent.traitFontVariant(); } Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/FontWeight.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/FontWeight.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/FontWeight.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -132,7 +132,7 @@ } public static short getValueNoInstance(FObj fobj) { - FObj parent = fobj.getFObjParent(); + FObj parent = fobj.realParent(); if (parent != null) { return parent.traitFontWeight(); } @@ -144,7 +144,7 @@ } FontUse getInheritedFont(FObj fobj) { - FObj parent = fobj.getFObjParent(); + FObj parent = fobj.realParent(); if (parent == null) { return null; } Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/ForcePageCount.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/ForcePageCount.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/ForcePageCount.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -68,7 +68,7 @@ short keyword = ((PropertyKeyword) value).getValue(); switch (keyword) { case Constants.FOVAL_INHERIT: { - FObj parent = fobj.getFObjParent(); + FObj parent = fobj.realParent(); if (parent != null) { return parent.traitForcePageCount(); } Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/GlyphOrientation.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/GlyphOrientation.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/GlyphOrientation.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -100,7 +100,7 @@ } public static short getValueNoInstance(FObj fobj, byte axis) { - FObj parent = fobj.getFObjParent(); + FObj parent = fobj.realParent(); if (parent != null) { switch (axis) { case Constants.AXIS_HORIZONTAL: { Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/HyphLadderCount.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/HyphLadderCount.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/HyphLadderCount.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -84,7 +84,7 @@ } public static int getValueNoInstance(FObj fobj) { - FObj parent = fobj.getFObjParent(); + FObj parent = fobj.realParent(); if (parent != null) { return parent.traitHyphLadderCount(); } Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/HyphPushCharCount.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/HyphPushCharCount.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/HyphPushCharCount.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -67,7 +67,7 @@ short keyword = ((PropertyKeyword) value).getValue(); switch (keyword) { case Constants.FOVAL_INHERIT: { - return fobj.getFObjParent() + return fobj.realParent() .traitHyphenationPushCharacterCount(); } } @@ -79,7 +79,7 @@ } public static int traitValueNoInstance(FObj fobj) { - FObj parent = fobj.getFObjParent(); + FObj parent = fobj.realParent(); if (parent == null) { return 2; } Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/HyphRemainCharCount.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/HyphRemainCharCount.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/HyphRemainCharCount.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -68,7 +68,7 @@ short keyword = ((PropertyKeyword) value).getValue(); switch (keyword) { case Constants.FOVAL_INHERIT: { - return fobj.getFObjParent() + return fobj.realParent() .traitHyphenationRemainCharacterCount(); } } @@ -80,7 +80,7 @@ } public static int traitValueNoInstance(FObj fobj) { - FObj parent = fobj.getFObjParent(); + FObj parent = fobj.realParent(); if (parent == null) { return 2; } Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Indent.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Indent.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Indent.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -121,11 +121,11 @@ public static int getValueNoInstance(FObj fobj, byte direction, int ipdContainingRA) { - FObj parent = fobj.getFObjParent(); + FObj parent = fobj.realParent(); if (parent == null) { return 0; } - return fobj.getFObjParent().propertyList.getIndent(direction, + return fobj.realParent().propertyList.getIndent(direction, ipdContainingRA); } Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/InitialPageNumber.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/InitialPageNumber.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/InitialPageNumber.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -70,7 +70,7 @@ short keyword = ((PropertyKeyword) this.value).getValue(); switch (keyword) { case Constants.FOVAL_INHERIT: { - FObj parent = fobj.getFObjParent(); + FObj parent = fobj.realParent(); if (parent != null) { InitialPageNumber property = (InitialPageNumber) parent.propertyList.getProperty @@ -106,7 +106,7 @@ if (this.value instanceof PropertyKeyword) { short keyword = ((PropertyKeyword) this.value).getValue(); if (keyword == Constants.FOVAL_INHERIT) { - FObj parent = fobj.getFObjParent(); + FObj parent = fobj.realParent(); if (parent != null) { return parent.getRawInitialPageNumber(); } Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Keep.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Keep.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Keep.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -143,7 +143,7 @@ private static int getValueInherited(short propertyType, int subProperty, FObj fobj) { - FObj parent = fobj.getFObjParent(); + FObj parent = fobj.realParent(); if (parent == null) { return org.axsl.foR.Keep.AUTO; } Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Language.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Language.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Language.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -86,7 +86,7 @@ } public static String getValueNoInstance(FObj fobj) { - FObj parent = fobj.getFObjParent(); + FObj parent = fobj.realParent(); if (parent != null) { return parent.traitLanguage(); } Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/LastLineEndIndent.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/LastLineEndIndent.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/LastLineEndIndent.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -91,7 +91,7 @@ } public static int getValueNoInstance(FObj fobj, int ipdAncestorBANotLA) { - FObj parent = fobj.getFObjParent(); + FObj parent = fobj.realParent(); if (parent == null) { return 0; } Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/LeaderLength.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/LeaderLength.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/LeaderLength.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -131,13 +131,13 @@ int parentAreaCR_IPD) { switch (subProperty) { case 1: { - return fobj.getFObjParent().traitLeaderLengthMin(parentAreaCR_IPD); + return fobj.realParent().traitLeaderLengthMin(parentAreaCR_IPD); } case 2: { - return fobj.getFObjParent().traitLeaderLengthOpt(parentAreaCR_IPD); + return fobj.realParent().traitLeaderLengthOpt(parentAreaCR_IPD); } case 3: { - return fobj.getFObjParent().traitLeaderLengthMax(parentAreaCR_IPD); + return fobj.realParent().traitLeaderLengthMax(parentAreaCR_IPD); } } return getValueNoInstance(subProperty, fobj, parentAreaCR_IPD); Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/LeaderPatternWidth.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/LeaderPatternWidth.java 2006-06-06 21:59:57 UTC (rev 7432) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/LeaderPatternWidth.java 2006-06-06 22:34:18 UTC (rev 7433) @@ -91,7 +91,7 @@ } public static int getValueNoInstance(FObj fobj, int ipd_CR_Parent) { - FObj parent = fobj.getFObjParent(); + FObj parent = fobj.realParent(); if (parent == null) { return getValueFromFontMetrics(fobj); } Modified: trunk/foray/foray-fotree/src/java/org/foray... [truncated message content] |
|
From: <vic...@us...> - 2006-06-06 22:00:17
|
Revision: 7432 Author: victormote Date: 2006-06-06 14:59:57 -0700 (Tue, 06 Jun 2006) ViewCVS: http://svn.sourceforge.net/foray/?rev=7432&view=rev Log Message: ----------- 1. Implement new axsl methods related to handling of text content. 2. Use new FOTextContent to unify the FOText constructor. 3. Allow FONodes in Area Tree constructors (so that FOText items can be used). 4. If TextArea encapsulates an FOText, for the "generated by", have the FOText return its parent. Modified Paths: -------------- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/Character.java Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/Character.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/Character.java 2006-06-06 21:59:40 UTC (rev 7431) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/Character.java 2006-06-06 21:59:57 UTC (rev 7432) @@ -71,4 +71,9 @@ super.addChild(text); } + public char[] getAreaTreeText() { + FOText text = (FOText) this.children.get(0); + return text.getAreaTreeText(); + } + } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
|
From: <vic...@us...> - 2006-06-06 22:00:04
|
Revision: 7431 Author: victormote Date: 2006-06-06 14:59:40 -0700 (Tue, 06 Jun 2006) ViewCVS: http://svn.sourceforge.net/foray/?rev=7431&view=rev Log Message: ----------- 1. Implement new axsl methods related to handling of text content. 2. Use new FOTextContent to unify the FOText constructor. 3. Allow FONodes in Area Tree constructors (so that FOText items can be used). 4. If TextArea encapsulates an FOText, for the "generated by", have the FOText return its parent. Modified Paths: -------------- trunk/foray/foray-areatree/src/java/org/foray/area/AbstractInlineArea.java trunk/foray/foray-areatree/src/java/org/foray/area/Area.java trunk/foray/foray-areatree/src/java/org/foray/area/AreaFlexible.java trunk/foray/foray-areatree/src/java/org/foray/area/LineArea.java trunk/foray/foray-areatree/src/java/org/foray/area/TextArea.java Modified: trunk/foray/foray-areatree/src/java/org/foray/area/AbstractInlineArea.java =================================================================== --- trunk/foray/foray-areatree/src/java/org/foray/area/AbstractInlineArea.java 2006-06-06 20:17:53 UTC (rev 7430) +++ trunk/foray/foray-areatree/src/java/org/foray/area/AbstractInlineArea.java 2006-06-06 21:59:40 UTC (rev 7431) @@ -27,7 +27,7 @@ import org.axsl.areaR.GeneralInlineArea; import org.axsl.areaW.AreaWException; import org.axsl.common.Constants; -import org.axsl.foR.FObj; +import org.axsl.foR.FONode; /** * Common superclass for all areas generated by inline formatting objects. @@ -37,7 +37,7 @@ public abstract class AbstractInlineArea extends AreaFlexible implements GeneralInlineArea { - public AbstractInlineArea(FObj generatedBy, Area parentArea) { + public AbstractInlineArea(FONode generatedBy, Area parentArea) { super(generatedBy, parentArea); } Modified: trunk/foray/foray-areatree/src/java/org/foray/area/Area.java =================================================================== --- trunk/foray/foray-areatree/src/java/org/foray/area/Area.java 2006-06-06 20:17:53 UTC (rev 7430) +++ trunk/foray/foray-areatree/src/java/org/foray/area/Area.java 2006-06-06 21:59:40 UTC (rev 7431) @@ -30,7 +30,7 @@ import org.axsl.areaW.NormalBlockArea; import org.axsl.areaW.TableArea; import org.axsl.common.Constants; -import org.axsl.foR.FObj; +import org.axsl.foR.FONode; import org.axsl.foR.WritingMode; import org.axsl.foR.fo.BasicLink; import org.axsl.foR.fo.Block; @@ -53,7 +53,7 @@ * @param generatedBy * @param parentArea */ - public Area(FObj generatedBy, AreaNode parentArea) { + public Area(FONode generatedBy, AreaNode parentArea) { super(generatedBy, parentArea); } Modified: trunk/foray/foray-areatree/src/java/org/foray/area/AreaFlexible.java =================================================================== --- trunk/foray/foray-areatree/src/java/org/foray/area/AreaFlexible.java 2006-06-06 20:17:53 UTC (rev 7430) +++ trunk/foray/foray-areatree/src/java/org/foray/area/AreaFlexible.java 2006-06-06 21:59:40 UTC (rev 7431) @@ -25,7 +25,7 @@ package org.foray.area; import org.axsl.common.Constants; -import org.axsl.foR.FObj; +import org.axsl.foR.FONode; import java.util.List; @@ -51,7 +51,7 @@ */ private int anteriorSpace; - public AreaFlexible(FObj generatedBy, AreaNode parentArea) { + public AreaFlexible(FONode generatedBy, AreaNode parentArea) { super(generatedBy, parentArea); initializeProgressionDimension(); initializeAnteriorSpace(); Modified: trunk/foray/foray-areatree/src/java/org/foray/area/LineArea.java =================================================================== --- trunk/foray/foray-areatree/src/java/org/foray/area/LineArea.java 2006-06-06 20:17:53 UTC (rev 7430) +++ trunk/foray/foray-areatree/src/java/org/foray/area/LineArea.java 2006-06-06 21:59:40 UTC (rev 7431) @@ -28,9 +28,8 @@ import org.axsl.common.Constants; import org.axsl.common.ConstantsAreaTree; import org.axsl.foR.FOText; +import org.axsl.foR.FOTextContent; import org.axsl.foR.FObj; -import org.axsl.foR.FObjMixed; -import org.axsl.foR.fo.Character; import org.axsl.foR.fo.ExternalGraphic; import org.axsl.foR.fo.InstreamForeignObject; import org.axsl.foR.fo.Leader; @@ -804,7 +803,7 @@ return new PageNumberCitationArea(citation, parentArea, ipd); } - public static org.axsl.areaW.TextArea makeTextArea(FOText foText, + public static org.axsl.areaW.TextArea makeTextArea(FOTextContent foText, Area parentArea, int ipd, int startOffset, int sizeInChars, boolean hasDiscretionaryHyphen, boolean hasFauxSmallCaps, boolean isLastItemOnLine) { @@ -828,20 +827,8 @@ } /* Go ahead and create*/ - FObj parent = foText.parentFO(); - if (parent instanceof FObjMixed) { - FObjMixed mixed = (FObjMixed) foText.parentFO(); - int sequence = mixed.getChildren().indexOf(foText); - return new TextArea(mixed, parentArea, sequence, - startOffset, sizeInChars, ipd, - hasDiscretionaryHyphen, - hasFauxSmallCaps); - } - if (parent instanceof Character) { - return new TextArea((Character) parent, parentArea, ipd, - hasDiscretionaryHyphen, hasFauxSmallCaps); - } - return null; + return new TextArea(foText, parentArea, startOffset, sizeInChars, ipd, + hasDiscretionaryHyphen, hasFauxSmallCaps); } public org.axsl.areaW.ForeignObjectArea makeForeignObjectArea( Modified: trunk/foray/foray-areatree/src/java/org/foray/area/TextArea.java =================================================================== --- trunk/foray/foray-areatree/src/java/org/foray/area/TextArea.java 2006-06-06 20:17:53 UTC (rev 7430) +++ trunk/foray/foray-areatree/src/java/org/foray/area/TextArea.java 2006-06-06 21:59:40 UTC (rev 7431) @@ -28,8 +28,9 @@ import org.axsl.common.Constants; import org.axsl.common.ConstantsAreaTree; -import org.axsl.foR.FObjMixed; -import org.axsl.foR.fo.Character; +import org.axsl.foR.FONode; +import org.axsl.foR.FOTextContent; +import org.axsl.foR.FObj; import org.axsl.fontR.Font; import org.axsl.fontR.FontUse; @@ -55,17 +56,6 @@ implements org.axsl.areaR.TextArea, org.axsl.areaW.TextArea { /** - * Index into the Collection of the children of the generated-by that - * matches the FOText node that is the real generated-by for this - * TextSegment. For example, if the parent FObjMixed has 3 FO children: - * 1. a chunk of text, 2. an <fo:inline> element, and 3. another - * chunk of text, and the third item of these contains the text that is the - * backing for this TextSegment, then backingSequence should be 2 (the - * third ordinal item). - */ - int backingSequence; - - /** * The index of the first character in the char array that is the backing * for the text in this object. For example, if the text in this TextSegment * starts at array element 5 and has a size of 14, backingOffset will be 5. @@ -108,12 +98,11 @@ */ boolean hasFauxSmallCaps = false; - public TextArea(FObjMixed generatedBy, Area parentArea, - int backingSequence, int backingOffset, int backingSize, + public TextArea(FOTextContent generatedBy, Area parentArea, + int backingOffset, int backingSize, int progressionDimensionUsed, boolean hasDiscretionaryHyphen, boolean hasFauxSmallCaps) { super(generatedBy, parentArea); - this.backingSequence = backingSequence; this.backingOffset = backingOffset; this.backingSize = backingSize; this.resolvedLetterSpacing = parentArea.traitLetterSpacingOpt(); @@ -123,18 +112,6 @@ setProgressionDimension(progressionDimensionUsed); } - public TextArea(Character generatedBy, Area parentArea, - int progressionDimensionUsed, boolean hasDiscretionaryHyphen, - boolean hasFauxSmallCaps) { - super(generatedBy, parentArea); - this.backingSize = 1; - this.resolvedLetterSpacing = 0; - this.resolvedWordSpacing = 0; - this.hasDiscretionaryHyphen = hasDiscretionaryHyphen; - this.hasFauxSmallCaps = hasFauxSmallCaps; - setProgressionDimension(progressionDimensionUsed); - } - /** * <p>Computes and returns the text that should actually be used in the * output document. Note that it may be different from the char array that @@ -192,16 +169,17 @@ return returnChars; } + public FOTextContent getTextContent() { + FONode foNode = this.generatedBy.getFONode(); + /* Cast verified at construction. */ + return (FOTextContent) foNode; + } + /** * @return The raw text from the FO Tree. */ protected char[] getRawText() { - if (traitGeneratedBy() instanceof Character) { - return new char[] {traitGeneratedBy().traitCharacter()}; - } - // Cast verified at construction. - FObjMixed gb = (FObjMixed) traitGeneratedBy(); - return gb.getText(backingSequence); + return this.getTextContent().getAreaTreeText(); } public byte getAreaType() { @@ -550,4 +528,18 @@ return "text"; } + /** + * Override the standard method so that, if this is not an FObj, an ancestor + * FObj can be used instead. + */ + public FObj traitGeneratedBy() { + FONode generatedBy = this.generatedBy.getFONode(); + if (generatedBy instanceof FObj) { + /* If generated by Character. */ + return (FObj) generatedBy; + } + /* If generated by FOText. */ + return generatedBy.parentFO(); + } + } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
|
From: <vic...@us...> - 2006-06-06 20:25:15
|
Revision: 7428 Author: victormote Date: 2006-06-06 12:10:00 -0700 (Tue, 06 Jun 2006) ViewCVS: http://svn.sourceforge.net/foray/?rev=7428&view=rev Log Message: ----------- Conform to and use new axsl method: Add method returning the Region's page. Modified Paths: -------------- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/Region.java Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/Region.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/Region.java 2006-06-06 19:09:52 UTC (rev 7427) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/Region.java 2006-06-06 19:10:00 UTC (rev 7428) @@ -163,4 +163,8 @@ return this.getFOTreeBuilder().getFONamespace(); } + public org.axsl.foR.fo.SimplePageMaster getPage() { + return this.getPageMaster(); + } + } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
|
From: <vic...@us...> - 2006-06-06 20:25:03
|
Revision: 7427 Author: victormote Date: 2006-06-06 12:09:52 -0700 (Tue, 06 Jun 2006) ViewCVS: http://svn.sourceforge.net/foray/?rev=7427&view=rev Log Message: ----------- Conform to and use new axsl method: Add method returning the Region's page. Modified Paths: -------------- trunk/foray/foray-areatree/src/java/org/foray/area/RegionRABody.java Modified: trunk/foray/foray-areatree/src/java/org/foray/area/RegionRABody.java =================================================================== --- trunk/foray/foray-areatree/src/java/org/foray/area/RegionRABody.java 2006-06-06 18:42:43 UTC (rev 7426) +++ trunk/foray/foray-areatree/src/java/org/foray/area/RegionRABody.java 2006-06-06 19:09:52 UTC (rev 7427) @@ -115,12 +115,16 @@ - getDimensionFootnoteRA(); } + public SimplePageMaster getPageMaster() { + // Cast verified at construction. + RegionBody rb = (RegionBody) traitGeneratedBy(); + return rb.getPage(); + } + public int brOriginX() { // Start at the parent's content origin. int x = getParentArea().crOriginX(); - // Cast verified at construction. - RegionBody rb = (RegionBody) traitGeneratedBy(); - SimplePageMaster spm = (SimplePageMaster) rb.parentFO(); + SimplePageMaster spm = getPageMaster(); switch (getParentArea().contentStackingDirectionAbsolute()) { case Constants.DIRECTION_TOP_TO_BOTTOM: case Constants.DIRECTION_BOTTOM_TO_TOP: { @@ -142,9 +146,7 @@ public int brOriginY() { // Start at the parent's content origin. int y = getParentArea().crOriginY(); - // Cast verified at construction. - SimplePageMaster spm = (SimplePageMaster) - traitGeneratedBy().parentFO(); + SimplePageMaster spm = getPageMaster(); switch (getWritingMode().getAbsoluteDirFromRelativeAxis( Constants.AXIS_BP)) { case Constants.DIRECTION_TOP_TO_BOTTOM: { This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
|
From: <vic...@us...> - 2006-06-06 20:24:54
|
Revision: 7426 Author: victormote Date: 2006-06-06 11:42:43 -0700 (Tue, 06 Jun 2006) ViewCVS: http://svn.sourceforge.net/foray/?rev=7426&view=rev Log Message: ----------- Implement new axsl methods. Modified Paths: -------------- trunk/foray/foray-areatree/src/java/org/foray/area/InlineArea.java trunk/foray/foray-areatree/src/java/org/foray/area/LeaderArea.java trunk/foray/foray-areatree/src/java/org/foray/area/LineArea.java Modified: trunk/foray/foray-areatree/src/java/org/foray/area/InlineArea.java =================================================================== --- trunk/foray/foray-areatree/src/java/org/foray/area/InlineArea.java 2006-06-06 18:04:34 UTC (rev 7425) +++ trunk/foray/foray-areatree/src/java/org/foray/area/InlineArea.java 2006-06-06 18:42:43 UTC (rev 7426) @@ -25,7 +25,13 @@ package org.foray.area; import org.axsl.common.ConstantsAreaTree; +import org.axsl.foR.FOText; +import org.axsl.foR.fo.ExternalGraphic; import org.axsl.foR.fo.Inline; +import org.axsl.foR.fo.InstreamForeignObject; +import org.axsl.foR.fo.Leader; +import org.axsl.foR.fo.PageNumber; +import org.axsl.foR.fo.PageNumberCitation; /** * Areas generated by the fo:inline object. @@ -49,4 +55,40 @@ return "inline"; } + public org.axsl.areaW.ForeignObjectArea makeForeignObjectArea( + InstreamForeignObject ifo, int ipd) { + return LineArea.makeForeignObjectArea(ifo, this, ipd); + } + + public org.axsl.areaW.ExternalGraphicArea makeExternalGraphicArea( + ExternalGraphic ifo, int ipd) { + return LineArea.makeExternalGraphicArea(ifo, this, ipd); + } + + public org.axsl.areaW.LeaderArea makeLeaderArea( + Leader leader, int ipd) { + return LineArea.makeLeaderArea(leader, this, ipd); + } + + public org.axsl.areaW.PageNumberArea makePageNumberArea( + PageNumber pageNumber, int ipd) { + return LineArea.makePageNumberArea(pageNumber, this, ipd); + } + + public org.axsl.areaW.PageNumberCitationArea makePageNumberCitationArea( + PageNumberCitation citation, int ipd) { + return LineArea.makePageNumberCitationArea(citation, this, ipd); + } + + /** + * {@inheritDoc} + */ + public org.axsl.areaW.TextArea makeTextArea(FOText foText, int ipd, + int startOffset, int sizeInChars, boolean hasDiscretionaryHyphen, + boolean hasFauxSmallCaps, boolean isLastItemOnLine) { + return LineArea.makeTextArea(foText, this, ipd, startOffset, + sizeInChars, hasDiscretionaryHyphen, hasFauxSmallCaps, + isLastItemOnLine); + } + } Modified: trunk/foray/foray-areatree/src/java/org/foray/area/LeaderArea.java =================================================================== --- trunk/foray/foray-areatree/src/java/org/foray/area/LeaderArea.java 2006-06-06 18:04:34 UTC (rev 7425) +++ trunk/foray/foray-areatree/src/java/org/foray/area/LeaderArea.java 2006-06-06 18:42:43 UTC (rev 7426) @@ -24,8 +24,13 @@ package org.foray.area; +import org.axsl.foR.FOText; import org.axsl.foR.FObj; +import org.axsl.foR.fo.ExternalGraphic; +import org.axsl.foR.fo.InstreamForeignObject; import org.axsl.foR.fo.Leader; +import org.axsl.foR.fo.PageNumber; +import org.axsl.foR.fo.PageNumberCitation; import org.axsl.common.Constants; import org.axsl.common.ConstantsAreaTree; @@ -248,4 +253,40 @@ return "leader"; } + public org.axsl.areaW.ForeignObjectArea makeForeignObjectArea( + InstreamForeignObject ifo, int ipd) { + return LineArea.makeForeignObjectArea(ifo, this, ipd); + } + + public org.axsl.areaW.ExternalGraphicArea makeExternalGraphicArea( + ExternalGraphic ifo, int ipd) { + return LineArea.makeExternalGraphicArea(ifo, this, ipd); + } + + public org.axsl.areaW.LeaderArea makeLeaderArea( + Leader leader, int ipd) { + return LineArea.makeLeaderArea(leader, this, ipd); + } + + public org.axsl.areaW.PageNumberArea makePageNumberArea( + PageNumber pageNumber, int ipd) { + return LineArea.makePageNumberArea(pageNumber, this, ipd); + } + + public org.axsl.areaW.PageNumberCitationArea makePageNumberCitationArea( + PageNumberCitation citation, int ipd) { + return LineArea.makePageNumberCitationArea(citation, this, ipd); + } + + /** + * {@inheritDoc} + */ + public org.axsl.areaW.TextArea makeTextArea(FOText foText, int ipd, + int startOffset, int sizeInChars, boolean hasDiscretionaryHyphen, + boolean hasFauxSmallCaps, boolean isLastItemOnLine) { + return LineArea.makeTextArea(foText, this, ipd, startOffset, + sizeInChars, hasDiscretionaryHyphen, hasFauxSmallCaps, + isLastItemOnLine); + } + } Modified: trunk/foray/foray-areatree/src/java/org/foray/area/LineArea.java =================================================================== --- trunk/foray/foray-areatree/src/java/org/foray/area/LineArea.java 2006-06-06 18:04:34 UTC (rev 7425) +++ trunk/foray/foray-areatree/src/java/org/foray/area/LineArea.java 2006-06-06 18:42:43 UTC (rev 7426) @@ -778,35 +778,34 @@ return this.children.size() > 0; } - public org.axsl.areaW.ForeignObjectArea makeForeignObjectArea( - InstreamForeignObject ifo, int ipd) { - return new ForeignObjectArea(ifo, this, ipd); + public static org.axsl.areaW.ForeignObjectArea makeForeignObjectArea( + InstreamForeignObject ifo, Area parentArea, int ipd) { + return new ForeignObjectArea(ifo, parentArea, ipd); } - public org.axsl.areaW.ExternalGraphicArea makeExternalGraphicArea( - ExternalGraphic ifo, int ipd) { - return new ExternalGraphicArea(ifo, this, ipd); + public static org.axsl.areaW.ExternalGraphicArea makeExternalGraphicArea( + ExternalGraphic ifo, Area parentArea, int ipd) { + return new ExternalGraphicArea(ifo, parentArea, ipd); } - public org.axsl.areaW.LeaderArea makeLeaderArea( - Leader leader, int ipd) { - return new LeaderArea(leader, this, ipd); + public static org.axsl.areaW.LeaderArea makeLeaderArea( + Leader leader, Area parentArea, int ipd) { + return new LeaderArea(leader, parentArea, ipd); } - public org.axsl.areaW.PageNumberArea makePageNumberArea( - PageNumber pageNumber, int ipd) { - return new PageNumberArea(pageNumber, this, ipd); + public static org.axsl.areaW.PageNumberArea makePageNumberArea( + PageNumber pageNumber, Area parentArea, int ipd) { + return new PageNumberArea(pageNumber, parentArea, ipd); } - public org.axsl.areaW.PageNumberCitationArea makePageNumberCitationArea( - PageNumberCitation citation, int ipd) { - return new PageNumberCitationArea(citation, this, ipd); + public static org.axsl.areaW.PageNumberCitationArea + makePageNumberCitationArea( + PageNumberCitation citation, Area parentArea, int ipd) { + return new PageNumberCitationArea(citation, parentArea, ipd); } - /** - * {@inheritDoc} - */ - public org.axsl.areaW.TextArea makeTextArea(FOText foText, int ipd, + public static org.axsl.areaW.TextArea makeTextArea(FOText foText, + Area parentArea, int ipd, int startOffset, int sizeInChars, boolean hasDiscretionaryHyphen, boolean hasFauxSmallCaps, boolean isLastItemOnLine) { @@ -817,11 +816,13 @@ /* If the final text will be empty, don't create the TextArea. */ char[] rawText = foText.getAreaTreeText(); - boolean isFirstItemOnline = this.children.size() == 0; + boolean isFirstItemOnline = parentArea.children.size() == 0; int ignoreAtStart = TextArea.ignoreAtStart(rawText, startOffset, - sizeInChars, isFirstItemOnline, traitWhiteSpaceTreatment()); + sizeInChars, isFirstItemOnline, + parentArea.traitWhiteSpaceTreatment()); int ignoreAtEnd = TextArea.ignoreAtEnd(rawText, startOffset, - sizeInChars, isLastItemOnLine, traitWhiteSpaceTreatment()); + sizeInChars, isLastItemOnLine, + parentArea.traitWhiteSpaceTreatment()); if (ignoreAtStart + ignoreAtEnd >= sizeInChars) { return null; } @@ -831,43 +832,56 @@ if (parent instanceof FObjMixed) { FObjMixed mixed = (FObjMixed) foText.parentFO(); int sequence = mixed.getChildren().indexOf(foText); - int initialWordSpacing = this.traitWordSpacingOpt(); - int initialLetterSpacing = this.traitLetterSpacingOpt(); - return new TextArea(mixed, this, sequence, + int initialWordSpacing = parentArea.traitWordSpacingOpt(); + int initialLetterSpacing = parentArea.traitLetterSpacingOpt(); + return new TextArea(mixed, parentArea, sequence, startOffset, sizeInChars, ipd, initialLetterSpacing, initialWordSpacing, hasDiscretionaryHyphen, hasFauxSmallCaps); } if (parent instanceof Character) { - return new TextArea((Character) parent, this, ipd, 0, 0, + return new TextArea((Character) parent, parentArea, ipd, 0, 0, hasDiscretionaryHyphen, hasFauxSmallCaps); } return null; } -// private AreaFlexible findParentArea(FONode node) { -// // This is the easy and probably most frequent case -// if (node.parentFO() instanceof Block) { -// return this; -// } -// /* -// * TODO: A test needs to be -// * added to see whether the last child of LineArea should be a parent -// * or other ancestor of node. If so, as much of that hierarchy as is -// * common to node should be preserved. -// */ -// if (node.parentFO() instanceof BasicLink) { -// BasicLink bl = (BasicLink) node.parentFO(); -// return new BasicLinkArea(bl, findParentArea(bl)); -// } -// if (node.parentFO() instanceof Inline) { -// Inline inline = (Inline) node.parentFO(); -// return new InlineArea(inline, findParentArea(inline)); -// } -// // Default if nothing else works. -// return this; -// } + public org.axsl.areaW.ForeignObjectArea makeForeignObjectArea( + InstreamForeignObject ifo, int ipd) { + return LineArea.makeForeignObjectArea(ifo, this, ipd); + } + public org.axsl.areaW.ExternalGraphicArea makeExternalGraphicArea( + ExternalGraphic ifo, int ipd) { + return LineArea.makeExternalGraphicArea(ifo, this, ipd); + } + + public org.axsl.areaW.LeaderArea makeLeaderArea( + Leader leader, int ipd) { + return LineArea.makeLeaderArea(leader, this, ipd); + } + + public org.axsl.areaW.PageNumberArea makePageNumberArea( + PageNumber pageNumber, int ipd) { + return LineArea.makePageNumberArea(pageNumber, this, ipd); + } + + public org.axsl.areaW.PageNumberCitationArea makePageNumberCitationArea( + PageNumberCitation citation, int ipd) { + return LineArea.makePageNumberCitationArea(citation, this, ipd); + } + + /** + * {@inheritDoc} + */ + public org.axsl.areaW.TextArea makeTextArea(FOText foText, int ipd, + int startOffset, int sizeInChars, boolean hasDiscretionaryHyphen, + boolean hasFauxSmallCaps, boolean isLastItemOnLine) { + return LineArea.makeTextArea(foText, this, ipd, startOffset, + sizeInChars, hasDiscretionaryHyphen, hasFauxSmallCaps, + isLastItemOnLine); + } + public LineOutput asLineOutput() { return this; } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
|
From: <vic...@us...> - 2006-06-06 20:17:59
|
Revision: 7430 Author: victormote Date: 2006-06-06 13:17:53 -0700 (Tue, 06 Jun 2006) ViewCVS: http://svn.sourceforge.net/foray/?rev=7430&view=rev Log Message: ----------- Allow any FONode to generate Areas. If they really don't generate them (as per the XSL-FO standard), then one of their ancestors does. Modified Paths: -------------- trunk/foray/foray-areatree/src/java/org/foray/area/AreaNode.java trunk/foray/foray-areatree/src/java/org/foray/area/FOrayFOLinkage.java Modified: trunk/foray/foray-areatree/src/java/org/foray/area/AreaNode.java =================================================================== --- trunk/foray/foray-areatree/src/java/org/foray/area/AreaNode.java 2006-06-06 19:35:12 UTC (rev 7429) +++ trunk/foray/foray-areatree/src/java/org/foray/area/AreaNode.java 2006-06-06 20:17:53 UTC (rev 7430) @@ -29,6 +29,7 @@ import org.axsl.areaW.FOLinkage; import org.axsl.areaW.PageArea; import org.axsl.common.Constants; +import org.axsl.foR.FONode; import org.axsl.foR.FObj; import org.axsl.fontR.FontConsumer; import org.axsl.text.TextServer; @@ -56,7 +57,7 @@ * @param parentArea The Area instance that is the newly-constructed Area's * parent in the AreaTree. */ - public AreaNode(FObj generatedBy, AreaNode parentArea) { + public AreaNode(FONode generatedBy, AreaNode parentArea) { super(parentArea); if (! (this instanceof AreaTree)) { // AreaTree has no parent with which to register @@ -89,7 +90,7 @@ this.children.remove(areaNode); } - protected FOrayFOLinkage getFObjProxy(FObj fobj) { + protected FOrayFOLinkage getFObjProxy(FONode fobj) { if (fobj == null) { return null; } Modified: trunk/foray/foray-areatree/src/java/org/foray/area/FOrayFOLinkage.java =================================================================== --- trunk/foray/foray-areatree/src/java/org/foray/area/FOrayFOLinkage.java 2006-06-06 19:35:12 UTC (rev 7429) +++ trunk/foray/foray-areatree/src/java/org/foray/area/FOrayFOLinkage.java 2006-06-06 20:17:53 UTC (rev 7430) @@ -28,18 +28,17 @@ import org.axsl.areaW.AreaNode; import org.axsl.areaW.FOLinkage; import org.axsl.foR.FONode; -import org.axsl.foR.FObj; import java.util.ArrayList; /** * <p>An implementation of {@link org.axsl.foR.FONodeProxy} suitable for use - * with FOray.</p> + * with the FOray AreaTree.</p> */ public class FOrayFOLinkage implements FOLinkage { /** The FONode which generated the Areas in {@link #generatedAreas}. */ - private FObj realFONode; + private FONode realFONode; /** * The ordered list of Area instances generated by {@link #realFONode}. @@ -49,7 +48,7 @@ */ private ArrayList generatedAreas = new ArrayList(); - public FOrayFOLinkage(FObj realFObj) { + public FOrayFOLinkage(FONode realFObj) { this.realFONode = realFObj; } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
|
From: <vic...@us...> - 2006-06-06 19:35:23
|
Revision: 7429 Author: victormote Date: 2006-06-06 12:35:12 -0700 (Tue, 06 Jun 2006) ViewCVS: http://svn.sourceforge.net/foray/?rev=7429&view=rev Log Message: ----------- Simplify TextArea construction a bit. Modified Paths: -------------- trunk/foray/foray-areatree/src/java/org/foray/area/LineArea.java trunk/foray/foray-areatree/src/java/org/foray/area/TextArea.java Modified: trunk/foray/foray-areatree/src/java/org/foray/area/LineArea.java =================================================================== --- trunk/foray/foray-areatree/src/java/org/foray/area/LineArea.java 2006-06-06 19:10:00 UTC (rev 7428) +++ trunk/foray/foray-areatree/src/java/org/foray/area/LineArea.java 2006-06-06 19:35:12 UTC (rev 7429) @@ -832,15 +832,13 @@ if (parent instanceof FObjMixed) { FObjMixed mixed = (FObjMixed) foText.parentFO(); int sequence = mixed.getChildren().indexOf(foText); - int initialWordSpacing = parentArea.traitWordSpacingOpt(); - int initialLetterSpacing = parentArea.traitLetterSpacingOpt(); return new TextArea(mixed, parentArea, sequence, - startOffset, sizeInChars, ipd, initialLetterSpacing, - initialWordSpacing, hasDiscretionaryHyphen, + startOffset, sizeInChars, ipd, + hasDiscretionaryHyphen, hasFauxSmallCaps); } if (parent instanceof Character) { - return new TextArea((Character) parent, parentArea, ipd, 0, 0, + return new TextArea((Character) parent, parentArea, ipd, hasDiscretionaryHyphen, hasFauxSmallCaps); } return null; Modified: trunk/foray/foray-areatree/src/java/org/foray/area/TextArea.java =================================================================== --- trunk/foray/foray-areatree/src/java/org/foray/area/TextArea.java 2006-06-06 19:10:00 UTC (rev 7428) +++ trunk/foray/foray-areatree/src/java/org/foray/area/TextArea.java 2006-06-06 19:35:12 UTC (rev 7429) @@ -110,28 +110,26 @@ public TextArea(FObjMixed generatedBy, Area parentArea, int backingSequence, int backingOffset, int backingSize, - int progressionDimensionUsed, int initialLetterSpacing, - int initialWordSpacing, boolean hasDiscretionaryHyphen, + int progressionDimensionUsed, boolean hasDiscretionaryHyphen, boolean hasFauxSmallCaps) { super(generatedBy, parentArea); this.backingSequence = backingSequence; this.backingOffset = backingOffset; this.backingSize = backingSize; - this.resolvedLetterSpacing = initialLetterSpacing; - this.resolvedWordSpacing = initialWordSpacing; + this.resolvedLetterSpacing = parentArea.traitLetterSpacingOpt(); + this.resolvedWordSpacing = parentArea.traitWordSpacingOpt(); this.hasDiscretionaryHyphen = hasDiscretionaryHyphen; this.hasFauxSmallCaps = hasFauxSmallCaps; setProgressionDimension(progressionDimensionUsed); } public TextArea(Character generatedBy, Area parentArea, - int progressionDimensionUsed, int resolvedLetterSpacing, - int resolvedWordSpacing, boolean hasDiscretionaryHyphen, + int progressionDimensionUsed, boolean hasDiscretionaryHyphen, boolean hasFauxSmallCaps) { super(generatedBy, parentArea); this.backingSize = 1; - this.resolvedLetterSpacing = resolvedLetterSpacing; - this.resolvedWordSpacing = resolvedWordSpacing; + this.resolvedLetterSpacing = 0; + this.resolvedWordSpacing = 0; this.hasDiscretionaryHyphen = hasDiscretionaryHyphen; this.hasFauxSmallCaps = hasFauxSmallCaps; setProgressionDimension(progressionDimensionUsed); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
|
From: <vic...@us...> - 2006-06-06 02:57:19
|
Revision: 7404 Author: victormote Date: 2006-06-05 08:47:35 -0700 (Mon, 05 Jun 2006) ViewCVS: http://svn.sourceforge.net/foray/?rev=7404&view=rev Log Message: ----------- Remove dependencies on getHeight() method. Modified Paths: -------------- trunk/foray/foray-pioneer/src/java/org/foray/pioneer/TableCellPL.java trunk/foray/foray-pioneer/src/java/org/foray/pioneer/TablePL.java trunk/foray/foray-pioneer/src/java/org/foray/pioneer/TableRowPL.java Modified: trunk/foray/foray-pioneer/src/java/org/foray/pioneer/TableCellPL.java =================================================================== --- trunk/foray/foray-pioneer/src/java/org/foray/pioneer/TableCellPL.java 2006-06-05 15:36:36 UTC (rev 7403) +++ trunk/foray/foray-pioneer/src/java/org/foray/pioneer/TableCellPL.java 2006-06-05 15:47:35 UTC (rev 7404) @@ -145,8 +145,7 @@ bDone = true; // Adjust for minimum cell content height - int minCellHeight = area.crBPDNearestGeneratedByBlockLevelFO(); - minCellHeight = node.getHeight(minCellHeight); + int minCellHeight = node.traitBPDimensionMin(area.crBPD()); if (minCellHeight > cellArea.crBPD()) { cellArea.setProgressionDimension(minCellHeight); } Modified: trunk/foray/foray-pioneer/src/java/org/foray/pioneer/TablePL.java =================================================================== --- trunk/foray/foray-pioneer/src/java/org/foray/pioneer/TablePL.java 2006-06-05 15:36:36 UTC (rev 7403) +++ trunk/foray/foray-pioneer/src/java/org/foray/pioneer/TablePL.java 2006-06-05 15:47:35 UTC (rev 7404) @@ -232,8 +232,7 @@ } } - int height = area.crBPDNearestGeneratedByBlockLevelFO(); - height = node.getHeight(height); + int height = node.traitBPDimensionOpt(area.crBPD()); if (height != 0) { areaContainer.setProgressionDimension(height); } Modified: trunk/foray/foray-pioneer/src/java/org/foray/pioneer/TableRowPL.java =================================================================== --- trunk/foray/foray-pioneer/src/java/org/foray/pioneer/TableRowPL.java 2006-06-05 15:36:36 UTC (rev 7403) +++ trunk/foray/foray-pioneer/src/java/org/foray/pioneer/TableRowPL.java 2006-06-05 15:47:35 UTC (rev 7404) @@ -155,9 +155,8 @@ AbstractTableContainer container = (AbstractTableContainer) area; TableRowContainer areaContainer = container.makeTableRowContainer(node); - int height = area.crBPDNearestGeneratedByBlockLevelFO(); - height = node.getHeight(height); - largestCellHeight = height; + /* Set a reasonable starting BPD for this row. */ + this.largestCellHeight = node.traitBPDimensionMin(area.crBPD()); // Flag indicaing whether any cell didn't fit in available space boolean someCellDidNotLayoutCompletely = false; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
|
From: <vic...@us...> - 2006-06-06 02:57:16
|
Revision: 7408 Author: victormote Date: 2006-06-05 09:34:08 -0700 (Mon, 05 Jun 2006) ViewCVS: http://svn.sourceforge.net/foray/?rev=7408&view=rev Log Message: ----------- Consolidate the location of the DIMENSION_AUTO constant. Modified Paths: -------------- trunk/foray/foray-fotree/src/java/org/foray/fotree/FObjScaled.java trunk/foray/foray-fotree/src/java/org/foray/fotree/PropertyList.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/ExternalGraphic.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/AbsoluteDimension.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Dimension.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/RelativeDimension.java Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/FObjScaled.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/FObjScaled.java 2006-06-05 16:28:17 UTC (rev 7407) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/FObjScaled.java 2006-06-05 16:34:08 UTC (rev 7408) @@ -25,7 +25,6 @@ package org.foray.fotree; import org.foray.fotree.fo.prop.ContentDimension; -import org.foray.fotree.fo.prop.Dimension; import org.axsl.common.Constants; import org.axsl.foR.FOTreeException; @@ -115,7 +114,7 @@ * "Constraints", first paragraph, for explanation of logic. */ int viewportIPD = this.traitIPDimensionOpt(parentAreaCR_IPD); - if (viewportIPD == Dimension.DIMENSION_AUTO) { + if (viewportIPD == Constants.DIMENSION_AUTO) { viewportIPD = traitContentWidth(parentAreaCR_IPD, parentAreaCR_BPD); } return viewportIPD; @@ -134,7 +133,7 @@ * "Constraints", first paragraph, for explanation of logic. */ int viewportBPD = this.traitBPDimensionOpt(parentAreaCR_BPD); - if (viewportBPD == Dimension.DIMENSION_AUTO) { + if (viewportBPD == Constants.DIMENSION_AUTO) { viewportBPD = traitContentHeight(parentAreaCR_IPD, parentAreaCR_BPD); } Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/PropertyList.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/PropertyList.java 2006-06-05 16:28:17 UTC (rev 7407) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/PropertyList.java 2006-06-05 16:34:08 UTC (rev 7408) @@ -57,7 +57,6 @@ import org.foray.fotree.fo.prop.Country; import org.foray.fotree.fo.prop.Cue; import org.foray.fotree.fo.prop.DestinationPlacementOffset; -import org.foray.fotree.fo.prop.Dimension; import org.foray.fotree.fo.prop.DisplayAlign; import org.foray.fotree.fo.prop.DominantBaseline; import org.foray.fotree.fo.prop.Elevation; @@ -1512,7 +1511,7 @@ * corresponding dimension of the closest area ancestor that was generated * by a block-level formatting object." Used only when the * relative dimension is expressed as a percentage. - * @return The computed value, or {@link Dimension#DIMENSION_AUTO} for + * @return The computed value, or {@link Constants#DIMENSION_AUTO} for * "auto". */ private int getRelativeDimension(byte relativeAxis, int subProperty, Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/ExternalGraphic.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/ExternalGraphic.java 2006-06-05 16:28:17 UTC (rev 7407) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/ExternalGraphic.java 2006-06-05 16:34:08 UTC (rev 7408) @@ -29,8 +29,8 @@ import org.foray.fotree.FObjScaled; import org.foray.fotree.Namespace; import org.foray.fotree.PropertyList; -import org.foray.fotree.fo.prop.Dimension; +import org.axsl.common.Constants; import org.axsl.foR.FOTreeException; import org.axsl.graphicR.Graphic; import org.axsl.graphicR.GraphicException; @@ -111,7 +111,7 @@ */ protected int intrinsicContentWidth() { if (getGraphic() == null) { - return Dimension.DIMENSION_AUTO; + return Constants.DIMENSION_AUTO; } try { if (getGraphic().absoluteWidth(pixelsPerInch) > 0) { @@ -121,7 +121,7 @@ * 1.0, Section 6.6.5, where this formula is suggested. */ return pixelsToMillipoints(getGraphic().pixelWidth(), 96); } catch (GraphicException e) { - return Dimension.DIMENSION_AUTO; + return Constants.DIMENSION_AUTO; } } @@ -130,7 +130,7 @@ */ protected int intrinsicContentHeight() { if (getGraphic() == null) { - return Dimension.DIMENSION_AUTO; + return Constants.DIMENSION_AUTO; } try { if (getGraphic().absoluteHeight(pixelsPerInch) > 0) { @@ -140,7 +140,7 @@ * 1.0, Section 6.6.5, where this formula is suggested. */ return pixelsToMillipoints(getGraphic().pixelHeight(), 96); } catch (GraphicException e) { - return Dimension.DIMENSION_AUTO; + return Constants.DIMENSION_AUTO; } } Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/AbsoluteDimension.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/AbsoluteDimension.java 2006-06-05 16:28:17 UTC (rev 7407) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/AbsoluteDimension.java 2006-06-05 16:34:08 UTC (rev 7408) @@ -95,7 +95,7 @@ short keyword = kw.getValue(); switch (keyword) { case Constants.FOVAL_AUTO: { - return DIMENSION_AUTO; + return Constants.DIMENSION_AUTO; } case Constants.FOVAL_INHERIT: { switch (getPropertyType()) { @@ -133,11 +133,11 @@ switch (getPropertyType()) { case Constants.FOPROP_HEIGHT: case Constants.FOPROP_WIDTH: { - return DIMENSION_AUTO; + return Constants.DIMENSION_AUTO; } case Constants.FOPROP_MAX_HEIGHT: case Constants.FOPROP_MAX_WIDTH: { - return DIMENSION_AUTO; + return Constants.DIMENSION_AUTO; } case Constants.FOPROP_MIN_HEIGHT: case Constants.FOPROP_MIN_WIDTH: { Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Dimension.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Dimension.java 2006-06-05 16:28:17 UTC (rev 7407) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/Dimension.java 2006-06-05 16:34:08 UTC (rev 7408) @@ -35,9 +35,6 @@ */ public abstract class Dimension extends Property { - /** Negative values for Dimensions are invalid, so -1 indicates AUTO. */ - public static final byte DIMENSION_AUTO = -1; - public Dimension(PropertyList propertyList, short enumeration) throws PropertyException { super(propertyList, enumeration); Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/RelativeDimension.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/RelativeDimension.java 2006-06-05 16:28:17 UTC (rev 7407) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/RelativeDimension.java 2006-06-05 16:34:08 UTC (rev 7408) @@ -92,11 +92,11 @@ break; } default: { - return DIMENSION_AUTO; + return Constants.DIMENSION_AUTO; } } if (length == null) { - return DIMENSION_AUTO; + return Constants.DIMENSION_AUTO; } return length.getValue(fobj.traitFontSize(), 0); } @@ -106,7 +106,7 @@ } if (this.value instanceof DtPercentage) { if (parentAreaCR_Dimension < 0) { - return DIMENSION_AUTO; + return Constants.DIMENSION_AUTO; } DtPercentage percentage = (DtPercentage) this.value; return Math.round(percentage.getValue() * parentAreaCR_Dimension); @@ -114,7 +114,7 @@ if (this.value instanceof PropertyKeyword) { PropertyKeyword kw = (PropertyKeyword) this.value; if (kw.getValue() == Constants.FOVAL_AUTO) { - return DIMENSION_AUTO; + return Constants.DIMENSION_AUTO; } if (kw.getValue() == Constants.FOVAL_INHERIT) { switch (subProperty) { @@ -141,7 +141,7 @@ } public static int getValueNoInstance() { - return DIMENSION_AUTO; + return Constants.DIMENSION_AUTO; } protected short[] getValidKeywords() { This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
|
From: <vic...@us...> - 2006-06-06 02:56:04
|
Revision: 7412 Author: victormote Date: 2006-06-05 12:12:20 -0700 (Mon, 05 Jun 2006) ViewCVS: http://svn.sourceforge.net/foray/?rev=7412&view=rev Log Message: ----------- Remove unused and unneeded method. Modified Paths: -------------- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/ContentDimension.java Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/ContentDimension.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/ContentDimension.java 2006-06-05 19:05:37 UTC (rev 7411) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/prop/ContentDimension.java 2006-06-05 19:12:20 UTC (rev 7412) @@ -128,36 +128,6 @@ return getValueNoInstance(); } - /** - * Indicates whether the effective value of this property was the keyword - * "auto". - * @param fobj The FObj to which this property belongs. - * @param absoluteAxis One of {@link Constants#AXIS_HORIZONTAL} or - * {@link Constants#AXIS_VERTICAL}. - * @return True iff the effective value of this property is "auto". - */ - public boolean isAuto(FObj fobj, byte absoluteAxis) { - if (! (this.value instanceof PropertyKeyword)) { - return false; - } - short keyword = ((PropertyKeyword) value).getValue(); - switch (keyword) { - case Constants.FOVAL_INHERIT: { - FObj parent = fobj.getFObjParent(); - if (parent == null) { - return false; - } - return parent.propertyList - .getContentDimensionProperty(absoluteAxis) - .isAuto(parent, absoluteAxis); - } - case Constants.FOVAL_AUTO: { - return true; - } - } - return false; - } - public static float getValueNoInstance() { return 1; } @@ -169,7 +139,8 @@ /** * @param absoluteAxis One of the absolute axes (either AXIS_HORIZONTAL, * or AXIS_VERTICAL). - * @return String representation of the raw property name. + * @return Either {@link Constants#FOPROP_CONTENT_WIDTH} or + * {@link Constants#FOPROP_CONTENT_HEIGHT}. */ public static short rawPropertyName(int absoluteAxis) { switch (absoluteAxis) { @@ -182,4 +153,5 @@ } return 0; } + } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
|
From: <vic...@us...> - 2006-06-06 02:56:03
|
Revision: 7415 Author: victormote Date: 2006-06-05 13:08:50 -0700 (Mon, 05 Jun 2006) ViewCVS: http://svn.sourceforge.net/foray/?rev=7415&view=rev Log Message: ----------- Use new axsl interface. Modified Paths: -------------- trunk/foray/foray-fotree/src/java/org/foray/fotree/FObjScaled.java Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/FObjScaled.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/FObjScaled.java 2006-06-05 19:50:52 UTC (rev 7414) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/FObjScaled.java 2006-06-05 20:08:50 UTC (rev 7415) @@ -32,7 +32,8 @@ * Abstract base class for inline FOs that are scaleable. This currently * includes external-graphic and instream-foreign-object. */ -public abstract class FObjScaled extends FObj implements LineNonText { +public abstract class FObjScaled extends FObj implements LineNonText, + org.axsl.foR.FObjScaled { public FObjScaled(FObj parent, PropertyList propertyList, String systemId, int line, int column) throws FOTreeException { @@ -84,11 +85,7 @@ protected abstract int intrinsicContentHeight(); /** - * @param parentAreaCR_IPD Per XSL-FO Std 1.0, Section 7.14.5, "the - * corresponding dimension of the closest area ancestor that was generated - * by a block-level formatting object." - * @return The IPD, in millipoints, of the viewport area from which this - * content should be viewed. + * {@inheritDoc} */ public int viewportIPD(int parentAreaCR_IPD, int parentAreaCR_BPD) { /* @@ -103,11 +100,7 @@ } /** - * @param parentAreaCR_BPD Per XSL-FO Std 1.0, Section 7.14.1, "the - * corresponding dimension of the closest area ancestor that was generated - * by a block-level formatting object." - * @return The BPD, in millipoints, of the viewport area from which this - * content should be viewed. + * {@inheritDoc} */ public int viewportBPD(int parentAreaCR_IPD, int parentAreaCR_BPD) { /* This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
|
From: <vic...@us...> - 2006-06-06 02:27:59
|
Revision: 7413 Author: victormote Date: 2006-06-05 12:28:29 -0700 (Mon, 05 Jun 2006) ViewCVS: http://svn.sourceforge.net/foray/?rev=7413&view=rev Log Message: ----------- Reverse sense of method for future enhancement clarity. Modified Paths: -------------- trunk/foray/foray-fotree/src/java/org/foray/fotree/FObjScaled.java Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/FObjScaled.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/FObjScaled.java 2006-06-05 19:12:20 UTC (rev 7412) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/FObjScaled.java 2006-06-05 19:28:29 UTC (rev 7413) @@ -96,10 +96,10 @@ * "Constraints", first paragraph, for explanation of logic. */ int viewportIPD = this.traitIPDimensionOpt(parentAreaCR_IPD); - if (viewportIPD == Constants.DIMENSION_AUTO) { - viewportIPD = traitContentWidth(parentAreaCR_IPD); + if (viewportIPD != Constants.DIMENSION_AUTO) { + return viewportIPD; } - return viewportIPD; + return traitContentWidth(parentAreaCR_IPD); } /** @@ -115,10 +115,10 @@ * "Constraints", first paragraph, for explanation of logic. */ int viewportBPD = this.traitBPDimensionOpt(parentAreaCR_BPD); - if (viewportBPD == Constants.DIMENSION_AUTO) { - viewportBPD = traitContentHeight(parentAreaCR_BPD); + if (viewportBPD != Constants.DIMENSION_AUTO) { + return viewportBPD; } - return viewportBPD; + return traitContentHeight(parentAreaCR_BPD); } /** This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
|
From: <vic...@us...> - 2006-06-06 02:26:44
|
Revision: 7419 Author: victormote Date: 2006-06-05 13:20:23 -0700 (Mon, 05 Jun 2006) ViewCVS: http://svn.sourceforge.net/foray/?rev=7419&view=rev Log Message: ----------- Roll up some no-longer-needed methods. Modified Paths: -------------- trunk/foray/foray-fotree/src/java/org/foray/fotree/FObjScaled.java Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/FObjScaled.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/FObjScaled.java 2006-06-05 20:15:58 UTC (rev 7418) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/FObjScaled.java 2006-06-05 20:20:23 UTC (rev 7419) @@ -41,38 +41,6 @@ } /** - * @param parentAreaCR_IPD Per XSL-FO Std 1.0, Section 7.14.5, "the - * corresponding dimension of the closest area ancestor that was generated - * by a block-level formatting object." This is needed in order to compute - * the inline-progression-dimension, which is needed when content-width is - * scale-to-fit. - * @return The width, in millipoints, of the reference-area containing - * the content. - */ - public int traitContentWidth(int parentAreaCR_IPD) { - int viewportWidth = this.traitIPDimensionOpt(parentAreaCR_IPD); - float scalingFactor = this.getContentWidth( - this.intrinsicContentWidth(), viewportWidth); - return (int) (this.intrinsicContentWidth() * scalingFactor); - } - - /** - * @param parentAreaCR_BPD Per XSL-FO Std 1.0, Section 7.14.1, "the - * corresponding dimension of the closest area ancestor that was generated - * by a block-level formatting object." This is needed in order to compute - * the block-progression-dimension, which is needed when content-height is - * scale-to-fit. - * @return The height, in millipoints, of the reference-area containing - * the content. - */ - public int traitContentHeight(int parentAreaCR_BPD) { - int viewportHeight = this.traitBPDimensionOpt(parentAreaCR_BPD); - float scalingFactor = this.getContentHeight( - this.intrinsicContentHeight(), viewportHeight); - return (int) (this.intrinsicContentHeight() * scalingFactor); - } - - /** * @return The width, in millipoints, of the content of this object, as * reported by the content itself. */ @@ -96,7 +64,9 @@ if (viewportIPD != Constants.DIMENSION_AUTO) { return viewportIPD; } - return traitContentWidth(parentAreaCR_IPD); + float scalingFactor = this.getContentWidth( + this.intrinsicContentWidth(), viewportIPD); + return (int) (this.intrinsicContentWidth() * scalingFactor); } /** @@ -111,7 +81,9 @@ if (viewportBPD != Constants.DIMENSION_AUTO) { return viewportBPD; } - return traitContentHeight(parentAreaCR_BPD); + float scalingFactor = this.getContentHeight( + this.intrinsicContentHeight(), viewportBPD); + return (int) (this.intrinsicContentHeight() * scalingFactor); } /** @@ -125,15 +97,15 @@ } public int inlineSizeOptimum(int lineLength) { - return this.traitContentWidth(lineLength); + return this.viewportIPD(lineLength); } public int inlineSizeMinimum(int lineLength) { - return this.traitContentWidth(lineLength); + return this.viewportIPD(lineLength); } public int inlineSizeMaximum(int lineLength) { - return this.traitContentWidth(lineLength); + return this.viewportIPD(lineLength); } } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
|
From: <vic...@us...> - 2006-06-06 02:06:37
|
Revision: 7417 Author: victormote Date: 2006-06-05 13:15:49 -0700 (Mon, 05 Jun 2006) ViewCVS: http://svn.sourceforge.net/foray/?rev=7417&view=rev Log Message: ----------- Conform to axsl changes: Remove no-longer-needed parameters. Modified Paths: -------------- trunk/foray/foray-areatree/src/java/org/foray/area/ExternalGraphicArea.java trunk/foray/foray-areatree/src/java/org/foray/area/ForeignObjectArea.java Modified: trunk/foray/foray-areatree/src/java/org/foray/area/ExternalGraphicArea.java =================================================================== --- trunk/foray/foray-areatree/src/java/org/foray/area/ExternalGraphicArea.java 2006-06-05 20:15:42 UTC (rev 7416) +++ trunk/foray/foray-areatree/src/java/org/foray/area/ExternalGraphicArea.java 2006-06-05 20:15:49 UTC (rev 7417) @@ -57,15 +57,13 @@ public int viewportBPD() { ExternalGraphic eg = (ExternalGraphic) this.traitGeneratedBy(); Area parentForDimensions = this.ancestorGeneratedByBlockLevelFO(); - return eg.viewportBPD(parentForDimensions.crIPD(), - parentForDimensions.crBPD()); + return eg.viewportBPD(parentForDimensions.crBPD()); } public int viewportIPD() { ExternalGraphic eg = (ExternalGraphic) this.traitGeneratedBy(); Area parentForDimensions = this.ancestorGeneratedByBlockLevelFO(); - return eg.viewportIPD(parentForDimensions.crIPD(), - parentForDimensions.crBPD()); + return eg.viewportIPD(parentForDimensions.crIPD()); } /** Modified: trunk/foray/foray-areatree/src/java/org/foray/area/ForeignObjectArea.java =================================================================== --- trunk/foray/foray-areatree/src/java/org/foray/area/ForeignObjectArea.java 2006-06-05 20:15:42 UTC (rev 7416) +++ trunk/foray/foray-areatree/src/java/org/foray/area/ForeignObjectArea.java 2006-06-05 20:15:49 UTC (rev 7417) @@ -59,16 +59,14 @@ InstreamForeignObject ifo = (InstreamForeignObject) this.traitGeneratedBy(); Area parentForDimensions = this.ancestorGeneratedByBlockLevelFO(); - return ifo.viewportBPD(parentForDimensions.crIPD(), - parentForDimensions.crBPD()); + return ifo.viewportBPD(parentForDimensions.crBPD()); } public int viewportIPD() { InstreamForeignObject ifo = (InstreamForeignObject) this.traitGeneratedBy(); Area parentForDimensions = this.ancestorGeneratedByBlockLevelFO(); - return ifo.viewportIPD(parentForDimensions.crIPD(), - parentForDimensions.crBPD()); + return ifo.viewportIPD(parentForDimensions.crIPD()); } public org.axsl.areaR.AreaNode getContainedForeignObject() { This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
|
From: <vic...@us...> - 2006-06-06 02:06:08
|
Revision: 7410 Author: victormote Date: 2006-06-05 11:11:04 -0700 (Mon, 05 Jun 2006) ViewCVS: http://svn.sourceforge.net/foray/?rev=7410&view=rev Log Message: ----------- Move shared code to superclass. Modified Paths: -------------- trunk/foray/foray-fotree/src/java/org/foray/fotree/FObjScaled.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/ExternalGraphic.java trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/InstreamForeignObject.java Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/FObjScaled.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/FObjScaled.java 2006-06-05 17:41:51 UTC (rev 7409) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/FObjScaled.java 2006-06-05 18:11:04 UTC (rev 7410) @@ -192,4 +192,16 @@ return pixels * 72000 / pixelsPerInch; } + public int inlineSizeOptimum(int lineLength) { + return traitIPDimensionOpt(lineLength); + } + + public int inlineSizeMinimum(int lineLength) { + return traitIPDimensionOpt(lineLength); + } + + public int inlineSizeMaximum(int lineLength) { + return traitIPDimensionOpt(lineLength); + } + } Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/ExternalGraphic.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/ExternalGraphic.java 2006-06-05 17:41:51 UTC (rev 7409) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/ExternalGraphic.java 2006-06-05 18:11:04 UTC (rev 7410) @@ -94,18 +94,6 @@ return this.graphic; } - public int inlineSizeOptimum(int lineLength) { - return traitIPDimensionOpt(lineLength); - } - - public int inlineSizeMinimum(int lineLength) { - return traitIPDimensionOpt(lineLength); - } - - public int inlineSizeMaximum(int lineLength) { - return traitIPDimensionOpt(lineLength); - } - /** * {@inheritDoc} */ Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/InstreamForeignObject.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/InstreamForeignObject.java 2006-06-05 17:41:51 UTC (rev 7409) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/fo/obj/InstreamForeignObject.java 2006-06-05 18:11:04 UTC (rev 7410) @@ -75,18 +75,6 @@ return (ForeignXML) getChildren().get(0); } - public int inlineSizeOptimum(int lineLength) { - return traitIPDimensionOpt(lineLength); - } - - public int inlineSizeMinimum(int lineLength) { - return traitIPDimensionMin(lineLength); - } - - public int inlineSizeMaximum(int lineLength) { - return traitIPDimensionMax(lineLength); - } - /** * {@inheritDoc} */ This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
|
From: <vic...@us...> - 2006-06-06 01:47:23
|
Revision: 7418 Author: victormote Date: 2006-06-05 13:15:58 -0700 (Mon, 05 Jun 2006) ViewCVS: http://svn.sourceforge.net/foray/?rev=7418&view=rev Log Message: ----------- Conform to axsl changes: Remove no-longer-needed parameters. Modified Paths: -------------- trunk/foray/foray-fotree/src/java/org/foray/fotree/FObjScaled.java Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/FObjScaled.java =================================================================== --- trunk/foray/foray-fotree/src/java/org/foray/fotree/FObjScaled.java 2006-06-05 20:15:49 UTC (rev 7417) +++ trunk/foray/foray-fotree/src/java/org/foray/fotree/FObjScaled.java 2006-06-05 20:15:58 UTC (rev 7418) @@ -87,7 +87,7 @@ /** * {@inheritDoc} */ - public int viewportIPD(int parentAreaCR_IPD, int parentAreaCR_BPD) { + public int viewportIPD(int parentAreaCR_IPD) { /* * See XSL-FO Standard 1.0, Section 6.6.5 and 6.6.6, Subsection * "Constraints", first paragraph, for explanation of logic. @@ -102,7 +102,7 @@ /** * {@inheritDoc} */ - public int viewportBPD(int parentAreaCR_IPD, int parentAreaCR_BPD) { + public int viewportBPD(int parentAreaCR_BPD) { /* * See XSL-FO Standard 1.0, Section 6.6.5 and 6.6.6, Subsection * "Constraints", first paragraph, for explanation of logic. This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |