MSDN/TVITEM Structure писал(а):
A state image is displayed next to an item's icon to indicate an application-defined state. Specify the state image list by sending a TVM_SETIMAGELIST message. To set an item's state image, include the TVIS_STATEIMAGEMASK value in the stateMask member of the TVITEM structure. Bits 12 through 15 of the structure's state member specify the index in the state image list of the image to be drawn.------------ Дoбавленo:
Думаю, что возвращать индексы из ParseIconIdx надо как var-переменные типа
procedure(var s:string; var i1:integer; var i2:integer; var i3:integer);
собственно, для таковой методом объекта быть не обязательно, может лежать где-нибудь в share...