I'm having some trouble with automatically positioning a floating bar.
The bar initially has a right caption position. It is autoshown upon
use in a script of 

cl.import(kbfile)
cl.show(bname)

(where kbfile is an ini file for a bar named bname).

What I want to do is change the bar to floating, but have its initial
position be unchanged.

I tried adding:

local myrec=win.getrect(bname)

win.getrect is documented as returning left top right bottom whereas
cl.setrect is documented as needing cl, top, left, right, bottom

So I tried manipulating myrec to look like what cl.setrect uses but
that didn't work. If I used

cl.NewProperties(bname, "Format1=Position: Floating")
followed by
cl.setrect(manipulated_values)
the bar moved.

also tried
win.setrect(bname, myrec)

(using the original unmanipulated values) but the bar still moved and
was not repositioned as it should be.

Any idea what I'm doing wrong?

Thanks,
Sheri

Reply via email to