Problem with RemapCol(ARealColIndex)

There is a problem with RemapCol when it is called with an col index that already is a realcol index (and your grid has hidden colums, of course).

The way TAdvStringGrid.RemapCol is implemented, in non-edge cases it will always return a ColIndex equal to the ACol parameter increased by the number hidden columns up and until the ACol column.
That is, if you have 5 columns, column 1 and 3 hidden, RemapCol(3) will return 5. RemapCol(2) would return 3.

If you use a value that was already maped with RemapCol, it will return a value that is likewise increased. That is, RemapCol(RemapCol(2)) would return 4.

That is of course fine. I don't know of any other way of getting the RealCol index without any other Information.
But it means you have to make sure to never call RemapCol with a value that was already processed with RemapCol.

Sadly there is a constelation where this happens:

TAdvInplaceEdit.WndProc in advgrid.pas calls FGrid.DoGetEditorProp(FGrid.RealCol, FGrid.Row, nil);
When FGrid is of TDBAdvGrid, the first Thing that happens in TDBAdvGrid.DoGetEditorProp is RCol := RealColIndex(ACol);

This can become quite problematic when RCol is used to get any Column or Cell Information, readOnly for instance.

Consider the following:
You have 3 columns.

Column 0: hidden
Column 1: visible
Column 2: visible, readOnly

If you click in a cell of column 0  to edit cell, TAdvInplaceEdit.WndProc will call FGrid.DoGetEditorProp(1, *theRow*, nil).
Then in TDBAdvGrid.DoGetEditorProp ACol of 1 will get mapped (again) to 2 as RCol.
Columns[RCol].ReadOnly will then (correctly) return true and as a result, the DataSet is not put in Edit mode.