Problem with caption changing

Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • #33139
    bjoerng85
    Participant

    If I make an UpdateSkin oder RepaintForms and then I change the caption of a form, the titlebar of this form won't be shown right.

    Look at the Demo. Clicking on the button.

    Thanks for help.

    #40056
    Support
    Keymaster

    Thank you for demo. Why you are using UpdateSkin there?

    #40079
    bjoerng85
    Participant

    Because I have changed and added some components, when the application is already running. And this components aren't skinned right, without an UpdateSkin or RepaintForms.

    In the demo I made an UpdateSkin, to show the problem with the change of the forms caption.

    #40090
    Support
    Keymaster

    Try to replace “sSkinManager1.UpdateSkin” by “TacCtrlAdapter(Child.sSkinProvider1.Adapter).AddAllItems(Child)”.
    This code must update all non-skinned third-party and standard controls which placed on Child.

    If changing will not be successful then you can try to call “sSkinManager1.RepaintForms” after all changes like this :

    CODE
      …
      sSkinManager1.UpdateSkin;
      Child.Caption := 'verändert – ' + Name;
      sSkinManager1.RepaintForms;

    If you can make a demo with incorrectly painted controls then I will suggest a more effective solution I think.

    #40109
    bjoerng85
    Participant

    I have replaced the UpdateSkin with RepaintForms and now it works.

    Thanks for help.

Viewing 5 posts - 1 through 5 (of 5 total)
  • You must be logged in to reply to this topic.