> 
> But even if the window contents change, e.g. I switch to another tab
> in Firefox, and call the script again, the bar's background gets not
> updated. I've tried using cl.redisplay, cl.refresh, deleting the
> thumbnails, editing the skin file manually and reapplying it, with no
> luck.
> 
> I suspect bars generated with cl-functions cache the skin files 
and/or
> bg-images, is it so? 

Nothing is cached once the bar is closed; so closing and re-opeing the 
bar should be enough to do this.

As Mockey points out, you don't really need a skin just to change the 
background; you can use cl.setbackground.

However, just to test, I did try the following simplified version of 
your script which just inputs a bmp file and redisplays the bar each 
time it is run.  It works fine for me. (You have to pre-create the 
skins\testcl folder).  (It needs 4.5.05 for the mycl.xxx stuff).

    local myclname="testcl"
    local foutskin=pprofolder++?"skins\testcl\testcl.txt"

    if(not cl.exists(myclname))Do
        local mycl=cl.create(myclname, 1)
    Else
        local mycl=cl.get(myclname)
        mycl.RemoveAll
    EndIf


    Local fhskin = file.open(foutskin, "w")
    If(fhskin)Do
        fhskin.writeline(?"*skin")
        fhskin.writeline(?#*bar width 200 height 150 background "# ++ 
inputpath ++?#"#)
        fhskin.close()
    Else
        Do("Message", scriptname ++ ?#: Cannot create skin file!#)
        Quit(1)
    EndIf

    mycl.setproperties( ?"Format1 = Position: Floating Transparent: 25 
Flat TextUnder TopMost AllVDesks AutoShowBar TextCenter")
    mycl.addproperties(?"Skin = " ++ foutskin)
    mycl.addproperties(?"FontName = Trebuchet MS")
    mycl.addproperties(?"FontInfo = Bold Size: 16 Charset: 162")

    mycl.insert(0)
    mycl.setlabel(0, "button 1")
    mycl.settooltip(0, "tool tip 1")
    mycl.setwidth(0, 200)
    mycl.setheight(0, 150)
    mycl.addleft(0, "message left")
    mycl.addright(0, "message right")
    bar.show(myclname)









Attention: PowerPro's Web site has moved: http://www.ppro.org 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/power-pro/

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 


Reply via email to