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;
Pieter
(Pieter)
January 5, 2021, 6:58pm
2
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).
Pieter
(Pieter)
January 6, 2021, 3:09pm
5
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:
The button is rendered as a default button look and feel.
Can I apply any colors, etc. to this?
Pieter
(Pieter)
January 6, 2021, 4:51pm
7
No, the button is not styleable. We'll see if we can add colors to the button.
Thanks Pieter, that would be appreciated.
Pieter
(Pieter)
July 15, 2022, 6:35am
10
There is no time allocated yet to take a look at this. It's on our list
That's all very well but the fact that an accessory button is always a light gray background with white text makes it almost unusable as it looks as if it is disabled!
Any update as it looks disabled?