Hi all,
I´m currently working with a XtraForm that will be the main container for my application. From this main form different XtraForms will raise.
What I want to achieve is to change the background colour of the Title Bar, but only for the Main Form.
I made a bit of researching in your KB and I followed an approach that consisted of overriding the OnShown method to change the corresponding the SkinElement. It worked fine for the Main Form but it was extended to the rest of forms, what I do not want to. The code snippet in the main form is:
C#protected override void OnShown(EventArgs e)
{
base.OnShown(e);
Skin currentSkin = FormSkins.GetSkin(this.LookAndFeel);
SkinElement element = currentSkin[FormSkins.SkinFormCaption];
element.Image.Image = null;
element.Color.BackColor = Color.FromArgb(194, 191, 184);
this.LookAndFeel.UpdateStyleSettings();
}
I realised that changing the look & feel of the rest of the forms to not using the Skin provokes they do not have the new colour but we are losing the desired look & feel. So, how could I achieve this in a smarter way? I guess by a Custom Paint somewhere in the Main Form…?
Thanks,