TTMSFNCTableView Accessory Issues

Hi,

I am finding that I cannot manage to change the fill/border colors of an accessory. Code is as follows but the accessory remains gray.

Thanks,

Ken

ItemsListView2.BeginUpdate;
ItemsListView2.Items.Clear;
...
while not Query.EOF do
begin
Item2:=ItemsListView2.Items.Add;
...
Item2.Accessory:=tviaButton;
Item2.AccessoryWidth:=64;
Item2.AccessoryHeight:=36;
Item2.AccessoryFontColor:=MainBackground;
Item2.AccessoryBorderColor:=MainBackground;
Item2.AccessoryColor:=gcWhite;
Item2.AccessoryText:=Format('%.1f',[Amount],EKMFormatSettings)+'g';
Item2.EnableMoreOptions:=True;
Query.Next;
end;
...
ItemsListView2.EndUpdate;

Hi,

Did you check the ItemAppearance.AccessoryStroke general setting? This is required to make sure the AccessoryBorderColor is applied.

Yes, I have, makes no difference. Same with AccessoryFill (which is not saved in the project as it always reverts to YellowGreen).

Hi,

I noticed that you are using a tviaButton accessory, but the Accessory colors are not applied to a button. Only to the following types:

  • tviaProgress
  • tviaBadge

The button is rendered as a default button look and feel.

Can I apply any colors, etc. to this?

No, the button is not styleable. We'll see if we can add colors to the button.

Thanks Pieter, that would be appreciated.