When a paragraph has a auto-number style, how can I programmatically find the number TRichView assigned to it during formatting? I'd need this for table cell content via RVData, too.
I have found TCustomRichView.GetListMarkerInfo(). However this seems to give me the index of a paragraph only, not the complete number composed of all levels of numbering including fill characters (".").
The reason I ask: We want to resolve cross-references to paragraph numbers ("see paragraph 4.3.2") before printing. (Or are they built-in and I did not find them?)
Thanks
Moritz
How to find actual number assigned to paragraph
-
- Site Admin
- Posts: 17557
- Joined: Sat Aug 27, 2005 10:28 am
- Contact:
It is possible, but not documented.
First, you need to know the index of the list marker item (the first item in the paragraph (ItemNo).
Now you can get the marker object (TRVListMarkerInfo(rv.GetItem(ItemNo))). This object is declared in RVMarker.pas.
It has the following properties (please do not modify them):
Counter (for "4.3.2" it is 2)
DisplayString ('4.3.2')
First, you need to know the index of the list marker item (the first item in the paragraph (ItemNo).
Now you can get the marker object (TRVListMarkerInfo(rv.GetItem(ItemNo))). This object is declared in RVMarker.pas.
It has the following properties (please do not modify them):
Counter (for "4.3.2" it is 2)
DisplayString ('4.3.2')