You are viewing a plain text version of this content. The canonical link for it is here.
Posted to fop-users@xmlgraphics.apache.org by Nestor Martinez <ma...@hotmail.com> on 2004/11/22 15:46:10 UTC

OUTLINE QUESTION

Does any one know why the following code wouldn't work as expected.  
When I click on a bookmark link it takes me to the correct
page but not the exact location, it always points to the block right 
below the one that actually contains the ID.  I have gone on the Internet
and downloaded sample files which run great, bookmarks go where they are 
supposed to go.  Any ideas?
I appreciate any help you can give, thanks.

    <fox:outline internal-destination="A1">
        <fox:label>Title 1</fox:label>
        <fox:outline internal-destination="A1B1">
            <fox:label>SubTitle 1</fox:label>
            <fox:outline internal-destination="A1B1C1">
                <fox:label>SubSubTitle 1</fox:label>
            </fox:outline>
            <fox:outline internal-destination="A1B1C2">
                <fox:label>SubSubTitle 2</fox:label>
            </fox:outline>
            <fox:outline internal-destination="A1B1C3">
                <fox:label>SubSubTitle 3</fox:label>
            </fox:outline>
        </fox:outline>
        <fox:outline internal-destination="A1B2">
            <fox:label>SubTitle 2</fox:label>
        </fox:outline>
    </fox:outline>
    <fox:outline internal-destination="A2">
        <fox:label>Title 2</fox:label>
    </fox:outline>
    <fox:outline internal-destination="A3">
        <fox:label>Title 3</fox:label>
        <fox:outline internal-destination="A3B1">
            <fox:label>SubTitle 1</fox:label>
        </fox:outline>
        <fox:outline internal-destination="A3B2">
            <fox:label>SubTitle 2</fox:label>
        </fox:outline>
    </fox:outline>
    <fox:outline internal-destination="A4">
        <fox:label>Title 4</fox:label>
        <fox:outline internal-destination="A4B1">
            <fox:label>SubTitle 1</fox:label>
        </fox:outline>
        <fox:outline internal-destination="A4B2">
            <fox:label>SubTitle 2</fox:label>
        </fox:outline>
        <fox:outline internal-destination="A4B3">
            <fox:label>SubTitle 3</fox:label>
        </fox:outline>
        <fox:outline internal-destination="A4B4">
            <fox:label>SubTitle 4</fox:label>
        </fox:outline>
        <fox:outline internal-destination="A4B5">
            <fox:label>SubTitle 5</fox:label>
        </fox:outline>
    </fox:outline>
    <fox:outline internal-destination="A5">
        <fox:label>Title 5</fox:label>
        <fox:outline internal-destination="A5B1">
            <fox:label>SubTitle 1</fox:label>
            <fox:outline internal-destination="A5B1C1">
                <fox:label>SubSubTitle 1</fox:label>
            </fox:outline>
            <fox:outline internal-destination="A5B1C2">
                <fox:label>SubSubTitle 2</fox:label>
            </fox:outline>
        </fox:outline>
        <fox:outline internal-destination="A5B2">
            <fox:label>SubTitle 2</fox:label>
        </fox:outline>
        <fox:outline internal-destination="A5B3">
            <fox:label>SubTitle 3</fox:label>
        </fox:outline>
    </fox:outline>
    <fox:outline internal-destination="A6">
        <fox:label>Title 6</fox:label>
    </fox:outline>


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


Re: OUTLINE QUESTION

Posted by "J.Pietschmann" <j3...@yahoo.de>.
Nestor Martinez wrote:
> Any reason as to why the outline doesn't work as well when there is a 
> table involved?

The offset calculation is buggy.

J.Pietschmann

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


Re: OUTLINE QUESTION

Posted by Nestor Martinez <ma...@hotmail.com>.
J.Pietschmann wrote:

> Andreas L. Delmelle wrote:
>
>> but it sounds like one of those pesky 'nested block' issues...
>
>
> Well, I'd say it's the "table cells and blocks with margins
> don't mix well for link target offset calculation" issue.
> Last time I looked padding the table cell rather than using
> a margin in an enclosed block worked better.
>
> J.Pietschmann
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: fop-user-unsubscribe@xml.apache.org
> For additional commands, e-mail: fop-user-help@xml.apache.org
>
> .
>
Hi Andreas,
I tried what you said and that didn't work, so what I did was remove the 
table that is around all of my content and that worked.
Any reason as to why the outline doesn't work as well when there is a 
table involved?

Thanks for your help.
-Nestor


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


Re: OUTLINE QUESTION

Posted by "J.Pietschmann" <j3...@yahoo.de>.
Andreas L. Delmelle wrote:
> but it sounds like one of those pesky 'nested block' issues...

Well, I'd say it's the "table cells and blocks with margins
don't mix well for link target offset calculation" issue.
Last time I looked padding the table cell rather than using
a margin in an enclosed block worked better.

J.Pietschmann

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


RE: OUTLINE QUESTION

Posted by "Andreas L. Delmelle" <a_...@pandora.be>.
> -----Original Message-----
> From: Nestor Martinez [mailto:martinez_nestor@hotmail.com]
>

Hi,

> Here is a little bit of the fo file, where it shows the block
> with the id, but it actually goes to the block right after the
> block with the leader inside of it, in other words, it points
> to two blocks down from where it is supposed to point at,
> any idea why this happens?

Aha, this looks like a familiar problem indeed... I'm not completely sure,
but it sounds like one of those pesky 'nested block' issues...

Is it in any way possible to leave out the surrounding fo:block?

I mean:
>  <fo:table-body>
>    <fo:table-row height="6.75in">
>      <fo:table-cell>

Leave the following fo:block out, and make the blocks containing the ID's
direct descendants of the fo:table-cell...
>        <fo:block margin-right="0.5in" margin-left="0.5in">

... and move its margin-* properties to this fo:block.
>          <fo:block font-size="16pt" font-weight="bold" id="A1">Title
1</fo:block>

See if that works...

Hope this helps!

Greetz,

Andreas


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


Re: OUTLINE QUESTION

Posted by Nestor Martinez <ma...@hotmail.com>.
Andreas L. Delmelle wrote:

>>-----Original Message-----
>>From: Nestor Martinez [mailto:martinez_nestor@hotmail.com]
>>
>>    
>>
>
>Hi,
>
>  
>
>>Does any one know why the following code wouldn't work as expected.
>>When I click on a bookmark link it takes me to the correct
>>page but not the exact location, it always points to the block right
>>below the one that actually contains the ID.  I have gone on the Internet
>>and downloaded sample files which run great, bookmarks go where they are
>>supposed to go.  Any ideas?
>>    
>>
>
>Errm... No.
>The code you've shown us contains only the outlines. Based on that, we can
>only assume that the ID's are in fact on the blocks below the ones that you
>think contain the ID...
>
>Can you post a minimized version of the FO demonstrating the problem?
>
>Greetz,
>
>Andreas
>
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: fop-user-unsubscribe@xml.apache.org
>For additional commands, e-mail: fop-user-help@xml.apache.org
>
>.
>
>  
>
Here is a little bit of the fo file, where it shows the block with the 
id, but it actually goes to the block right after the block with
the leader inside of it, in other words, it points to two blocks down 
from where it is supposed to point at, any idea why this happens?
I'm using fop-0.20.5.  Thanks.

        <fo:flow flow-name="xsl-region-body">
            <fo:table width="5.4in" height="7.75in" table-layout="fixed">
                <fo:table-column column-width="5.4in"/>
                <fo:table-header>
                    <fo:table-row>
                        <fo:table-cell padding="0.25in">
                            <fo:block/>
                        </fo:table-cell>
                    </fo:table-row>
                </fo:table-header>
                <fo:table-footer>
                    <fo:table-row>
                        <fo:table-cell padding="0.25in">
                            <fo:block/>
                        </fo:table-cell>
                    </fo:table-row>
                </fo:table-footer>
                <fo:table-body>
                    <fo:table-row height="6.75in">
                        <fo:table-cell>
                            <fo:block margin-right="0.5in" 
margin-left="0.5in">
   *** id -->*               <fo:block font-size="16pt" 
font-weight="bold" id="A1">Title 1</fo:block>
                                <fo:block>
                                    <fo:leader/>
                                </fo:block>
***goes here instead -->*   <fo:block>This <fo:inline 
font-style="italic">is</fo:inline> the paragraph that eventually the 
outline points to instead of the one above which contains the ID 
referenced in the outline.  Can anyone explain why that is?  I just 
don't understand it.</fo:block>
                                <fo:block>
                                    <fo:leader/>
                                </fo:block>
    *** id -->*              <fo:block font-size="14pt" 
font-weight="bold" id="A1B1">SubTitle 1</fo:block>
                                <fo:block>
                                    <fo:leader/>
                                </fo:block>
                                <fo:block>
                                    <fo:list-block>
***goes here instead -->*  <fo:list-item>
                                            <fo:list-item-label 
end-indent="label-end()" width="10pt">
                                                <fo:block 
font-weight="bold" font-size="10pt" font-family="serif" 
text-align="right">.</fo:block>
                                            </fo:list-item-label>
                                            <fo:list-item-body 
start-indent="body-start()">
                                                <fo:block>Instead of 
pointing at the subtitle 1 above which contains the ID, it points to 
this block instead.  Any idea why this happens?</fo:block>

RE: OUTLINE QUESTION

Posted by "Andreas L. Delmelle" <a_...@pandora.be>.
> -----Original Message-----
> From: Nestor Martinez [mailto:martinez_nestor@hotmail.com]
>

Hi,

> Does any one know why the following code wouldn't work as expected.
> When I click on a bookmark link it takes me to the correct
> page but not the exact location, it always points to the block right
> below the one that actually contains the ID.  I have gone on the Internet
> and downloaded sample files which run great, bookmarks go where they are
> supposed to go.  Any ideas?

Errm... No.
The code you've shown us contains only the outlines. Based on that, we can
only assume that the ID's are in fact on the blocks below the ones that you
think contain the ID...

Can you post a minimized version of the FO demonstrating the problem?

Greetz,

Andreas


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