Page 1 of 1

GrabDesktop - Possible bug

Posted: Tue Feb 28, 2023 6:11 pm
by NathanH
Hi,
In previous Hollywood versions (I think 8) the following worked fine with no error:
blead=GrabDesktop(Nil, {X=cnt+FWIDTH, Y=sfloor, Width=FWIDTH, Height=FHEIGHT, PubScreen="Workbench Screen"})

Under 9.1 I get an error that it can't find the public screen and have to replace with:
blead=GrabDesktop(Nil, {X=cnt+FWIDTH, Y=sfloor, Width=FWIDTH, Height=FHEIGHT})

This works most of the time but I really need it to just use the workbench screen. Am I doing something wrong or is this a bug? I'm working with WinUAE, OS3.9, and Hollywod 9.1.

NathanH

Re: GrabDesktop - Possible bug

Posted: Wed Mar 01, 2023 1:02 am
by NathanH
Hi,

The PubScreen= attribute that the display opened on can be queried with:
SPUBLIC=GetAttribute(#DISPLAY, 1, #ATTRPUBSCREEN) ;public screen

SPUBLIC should be used instead of "Workbench Screen"

NathanH

Re: GrabDesktop - Possible bug

Posted: Fri Mar 03, 2023 8:50 pm
by airsoftsoftwair
NathanH wrote: Tue Feb 28, 2023 6:11 pm Hi,
In previous Hollywood versions (I think 8) the following worked fine with no error:
blead=GrabDesktop(Nil, {X=cnt+FWIDTH, Y=sfloor, Width=FWIDTH, Height=FHEIGHT, PubScreen="Workbench Screen"})

This works most of the time but I really need it to just use the workbench screen. Am I doing something wrong or is this a bug? I'm working with WinUAE, OS3.9, and Hollywod 9.1.
I'd need an MCVE to check that. But if you just want to grab the Workbench screen, why don't you just leave out the "PubScreen" tag? Or do you want to grab the Workbench screen while your script is running on a different screen?

Re: GrabDesktop - Possible bug

Posted: Sat Mar 04, 2023 5:21 pm
by NathanH
Hi,

Thanks! Yes, I'm trying to capture small parts of Workbench and another public screen. If I don't use the PubScreen syntax it can capture the wrong part when I don't want it too.

NathanH

Re: GrabDesktop - Possible bug

Posted: Sat Mar 04, 2023 9:20 pm
by airsoftsoftwair
I think the public screen name of Workbench is "Workbench" not "Workbench screen". Have you tried that?

Re: GrabDesktop - Possible bug

Posted: Mon Mar 06, 2023 5:30 pm
by NathanH
Hi,
Yes, that works; thanks. Scout said it was Workbench Screen.

Nathan