Alaska Software Inc. - Re: Buggy XbpStatic:SetCaption()
Username: Password:
AuthorTopic: Re: Buggy XbpStatic:SetCaption()
Andreas Gehrs-Pahl

View the complete thread for this message in:

Re: Buggy XbpStatic:SetCaption()
on Sat, 14 Feb 2015 05:05:24 -0500
Itai,

>Iʼd like to report the following bug:

I don't see any bug here at all.

>If a XbpStatic() object is a child of another XbpStatic() object then the 
>method SetCaption() does not clear the previous caption.

Sure it does. But it obviously doesn't clear the Caption of the parent's 
XbpStatic(). There are lots of ways to fix your display problem, though:

1) Just add the following line of code after your last line of code to 
   clear the caption of your parent static: oXbp:SetCaption("").

2) Don't use an XbpStatic() of :Type "XBPSTATIC_TYPE_TEXT" as the parent.

3) Don't assign a :Caption to the parent XbpStatic() in the first place.

4) Make the Child (oXbp2) the exact same size as the parent (oXbp) and 
   position it at the parent's lower left corner {0, 0}, so it covers the 
   parent static completely.

Either of those options will work.

Andreas

Andreas Gehrs-Pahl
Absolute Software, LLC

phone: (989) 723-9927
email: Andreas.GP@Charter.net
web:   http://www.Aerospace-History.net