Board index » delphi » D7 + Manifest ==> Cannot change Panel color

D7 + Manifest ==> Cannot change Panel color

Hi,

I have an application written in D7 w/ a manifest.  The standard TPanel will
always show as clbtnface eventhought its color property is something else.

Is this behaviour a bug or by design?

If I replaced TPanel w/ TLMDPanel it behaves as I expected.

Any ideas?

Thanks,

Isi R.

 

Re:D7 + Manifest ==> Cannot change Panel color


For mer, this doesn't work as expected

Regards,

Jens B Kristensen

"Mike Lischke" <pub...@lischke-online.de> wrote

Set ParentBackground to false.

Re:D7 + Manifest ==> Cannot change Panel color


I have also seen this effect.
I found what I would call a cheap solution to it; Just set border witdh of
the panel to a very hight number,
and the panel will be shown in the correct color.

Otherwise it will be shown in clBtnFace (at least on my system).
Seems like a bug to me :)

Regards,
Mikael Stalvik

Quote
"Mike Lischke" <pub...@lischke-online.de> wrote in message

news:3e3164b3$1@newsgroups.borland.com...
Hi Jens B Kristensen,

Quote
> For mer, this doesn't work as expected

Try the following and tell me what happens:

- Create new Win32 application.
- Drop a panel on the new form.
- Set ParentBackground of the panel to false.
- Set Color of the panel to clRed.

Does it show in red?

Mike
--
www.delphi-gems.com
www.delphi-unicode.net
www.lischke-online.de

Posted with XanaNews 1.12.5.11

Re:D7 + Manifest ==> Cannot change Panel color


Sorry I didn't see your reply a bit earlier! See below the quote.

"Mike Lischke" <pub...@lischke-online.de> wrote

Quote
>Try the following and tell me what happens:
>- Create new Win32 application.
>- Drop a panel on the new form.
>- Set ParentBackground of the panel to false.
>- Set Color of the panel to clRed.
>Does it show in red?

Yes it does - in the IDE! But when you run the program, the color reverts to
clBtnFace thanks to the XP Manifest. I have read the various comments on
this issue in this and other threads. One way out seems to be adding code to
OnFormCreate that sets ParentBackground=false for all controls on the form
(and probably do the same to all forms in the project). I hope there is an
easier way...

Thanks. Jens

Other Threads