Start with a 'MyFeeds' window that has unread messages
present. These are displayed as '(x)' in the pane as a
tree view object.
Notice that they appear to the right of the text, as you
would expect.
Now, horizontally shrink the pane so that a horizontal
scroll bar appears. Ensure that a '(x)' is still visible as you
shrink.
Now scroll the pane horizontally.
Notice that the '(x)' remains in the same physical location
whilst the logical scroll position of the text changes.
I'm not a Pascal person. However...
MainForm_FRM.pas line 1719 uses Node.DisplayRect(false)
to read the position of the node. The text is positioned
using Node.DisplayRect(true) (line 1732). This implies to
me that DisplayRect(false) does not take account of the
horizontal scroll position. Changing this call to use
DisplayRect(true) should, I believe, fix the problem.
As an aside, there is a problem with this routine in that
Size.cX may be uninitialised by the time the 'try' clause
at line 1766 is reached (consider the style selection at
1728 causing an exception and jumping out of the Try
clause). However, as I've said, I don't know pascal, so I
might be incorrect in that flow analysis.