Perfect hint, thank you.
I've also adapted:
Render() in ParagraphRenderer.cs
Code:
if ((int)this.paragraph.Format.OutlineLevel >= 1 && this.gfx.PdfPage != null) // Don't call GetOutlineTitle() in vain
this.documentRenderer.AddOutline((int)this.paragraph.Format.OutlineLevel,
GetOutlineTitle(), this.gfx.PdfPage, this.currentYPosition);
With this I get the exact behaviour I needed. The outline direct points to chapter title.
Perhaps some offset should be added (because it is not that beautiful).
Oh, and I also changed to int here, because I got "comma" separated and this destroyed the outlines.
Code:
new PdfLiteral(String.Format("/XYZ null {0} 0",(int)(DestinationPage.Height - 1.0 - PageOffset))));
I don't do any rounding because the values are nevertheless in the 840 range for A4 sheet.
One question to admins:Is there a plan to collect all the "user provided changes and fixes" and release a 1.32-user-edition or something likely.