I missed the extra lines. I can remove them for the next build.
Is there a need for this capability?
Paul, for my application, this is more than generous attention!
Thank you, Bill
I have removed the unwanted 1 or 2 pixel background border in the image. This will take effect with the next release of ClearWin+.
I have also added calls to GetForegroundWindow and BringWindowToTop within export_window_image@ so that they will no longer be needed in user's code. These calls can be removed from the sample Fortran program.
Please note that any windows that have the WS_EX_TOPMOST style could still potentially get in the way because BringWindowToTop does not hide them. This style is occasionally used, for example, in MessageBox windows.