I'm at present finishing off a slate tool for the company I work at. I mostly work on a Mac, and have started to de-bug on a windows machine to make sure everything is cross platform. I came across an annoying little problem, which I am hoping there is a work around - or I'm using the tool, whichever.
I'm applying a graphic to a script UI as a background image that serves as a layout. On a mac the image is correctly in the background with any other UI elements on top - in the example below are just a couple of checkboxes. On windows the image is getting placed in the foreground so that any other UI elements disappear.
Why is there a difference between platforms ? I don't get it.
I've stripped out the problem part of the code -
clearOutput();
if (system.osName.indexOf("Windows") != -1) {
var curDir = "C:\\Program Files\\Adobe\\Adobe After Effects CS3\\Support Files\\Scripts\\PLF\\_data\\";
} else {
var curDir = "/Applications/Adobe After Effects CS3/Scripts/PLF/_data/";
}
Folder.current = curDir;
write(curDir);
iconfile = new File("bg.png");
win = new Window("palette"," ",[100,100,550,573]);
w = buildUI();
win.show();
function buildUI() {
win.bggraphic = win.add("image",[0,0,1144,473],iconfile);
win.dailycheck = win.add("checkbox", [370,378,390,398], "");
win.dailycheck.value = false;
win.seqcheck = win.add("checkbox", [230,378,250,398], "");
win.seqcheck.value = false;
}
The "bg.png" could be any image, but the important thing is that it covers the entire UI palette.
Thanks for any help,
Stephen
UI help
Moderator: Paul Tuersley
I had a kind e-mail from Jeff Almasol who suggested placing the -
win.bggraphic = win.add("image",[0,0,1144,473],iconfile);
- after all of the other UI calls, which worked.
However, apparently this isn't supposed to work this way and only one item in the UI can be visible at a time.
-Stephen
win.bggraphic = win.add("image",[0,0,1144,473],iconfile);
- after all of the other UI calls, which worked.
However, apparently this isn't supposed to work this way and only one item in the UI can be visible at a time.
-Stephen