First, to have custom controls like minimize,etc, the window bar needs to be active and the only way to hide it so that it's still active for the custom controls to work is to skin the window, I've discovered.
My particular project needing this, also needs to be able to reduce or enlarge the height or width of the stack (4 differing dimensions each). I can do this relatively easily to the stack width or height, of course.
But if I import a rectangular image for my skin for the window shape, I don't know how (or if it's possible) to script to crop the image, to make it not as high for instance, so that my window height decreases/increases as I want.
I hope I've explained myself fairly clearly here!
So if anyone knows how I can "crop" the skin image script-wise and then the stack window to change accordingly to the new shape, that'd be excellent, thanks. (If it's not possible, I'd be obliged for that info as well.)

Edit: as the skin will be white, I don't need to crop it, just reduce or enlarge the height, for instance. I've tried doing this in tandem with resetting the windowshape, but no joy...