Platform: Lazarus 1.8.4, FPC 3.0.4, TK Controls, latest version.
I'm incorporating a TKDBGrid control into my project and I need only one of the columns to display URLs. I have picked a font color of blue and underlined it so it now looks like a URL. However, the end user would like to see the cursor change from the default arrow, to a hand point, so they know that URL is clickable.
In Delphi, I did this like so...
var lCoord: TGridCoord;
begin
lCoord := kdbg.MouseCoord(X,Y);
if (lCoord.X = -1) or (lCoord.Y = -1) then
begin
if not (kdbg.Cursor = crDefault) then
kdbg.Cursor := crDefault;
Exit;
end;
if (Pos(';' + UpperCase(dbgkdbg.Columns[lCoord.X].FieldName) + ';', ';MINE;') > 0) then
begin
if not (kdbg.Cursor = crHandPoint) then
kdbg.Cursor := crHandPoint
end
else
begin
if not (kdbg.Cursor = crDefault) then
kdbg.Cursor := crDefault;
end;
end;
However, in a TKDBGrid, there is no kdbg.MouseCoord, and I can't find anything equivalent. The TK author is not supporting this component set anymore, so I'm relying on the Lazarus community for info on how to accomplish this. Thanks in advance.