Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Does a button control have to be gray????
Message
De
25/06/1998 17:06:57
 
 
À
25/06/1998 15:04:09
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
00111460
Message ID:
00111727
Vues:
22
>>>>Is there a way to make the button control have a different color for the background? All buttons seem to be gray in the background, regardless of altering the 'background' property on the button.
>>>>
>>>>Mark
>>>>mark@remarkable-systems.com
>>>
>>>This is general Window setting. The workaround is to replace buttons with containers (SpecialEffect=0/1).
>>
>>Ed,
>>
>>I tried your idea. I made a container and placed a text label within it; then I changed the container's backcolor and made the label transparent; also made the container raised (specialeffect). When I was done -- it looked like a button! Great! Only problems are: 1) It doesn't do the indenting motion when clicked (like normal buttons do) and 2) if I clicked any where on the text label, the container's click event doesn't fire, the label's does.
>>
>>Any more ideas or am I doing something wrong?
>>
>>Thanks,
>>
>>Mark
>
>Nothing wrong, but nothing is simple :). If you really want to proceed this way, you should do more:
>1. Reset Container.SpecialEffect property to 1 (Sunken) in MouseDown events of both label and container.
>2. Move label a little bit in MouseDown event of both label and container and restore Label.Top in MouseUp events to make click appearance nicer.


Ed,

Great idea -- I'll give that a try.

Thanks for all your help,

Mark
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform