Gray Boxes shown in front of page - Printable Version +- Antwise community forums (https://forums.antwise.com) +-- Forum: Antview (https://forums.antwise.com/forumdisplay.php?fid=11) +--- Forum: Antview for Windows (https://forums.antwise.com/forumdisplay.php?fid=12) +--- Thread: Gray Boxes shown in front of page (/showthread.php?tid=190) |
Gray Boxes shown in front of page - pivoten - 2024-03-25 We have a simple page that has this html. Code: <!DOCTYPE html> When AntView displays it the page looks like this with gray boxes that don't scroll with the page. We are on a trial version. Is that what is causing this? Phil RE: Gray Boxes shown in front of page - wila - 2024-03-25 Hi Phil, It's not because you are on a trial license. That would be a bad thing if it was a side effect of running in trial mode. This certainly is not normal. If I understand you correctly then the control does work if you navigate to a page such as google.com? The "Test" that is currently displayed is rendered by the AntView control? The only place where we've seen rendering issues is when using the control in a virtual environment. In that case you'll have to manually disable the hardware GPU rendering. See the AdditionalBrowserArguments property documentation for more information on how-to do that. -- Wil RE: Gray Boxes shown in front of page - pivoten - 2024-03-25 (2024-03-25, 14:51:15)Thanks for the reply Wila!This is a app running in Windows on a Parallels virtual machine. Is there a way to set the gpu flag programmatically? I followed the link and it looked like it was a command line argument when you start Chrome.Philwila Wrote: Hi Phil, RE: Gray Boxes shown in front of page - wila - 2024-03-25 Phil, Running the control in a Parallels VM might explain the issue. Before creating the AntView control set the property AdditionalBrowserArguments. So in VB that would look along the lines of: Code: Private Sub Form_Load() -- Wil RE: Gray Boxes shown in front of page - pivoten - 2024-03-26 This is a Visual FoxPro form. I've added these statements to the init of the form. thisform.oBrowser.additionalBrowserArguments = "--disable-gpu" thisform.oBrowser.createWebView thisform.oBrowser.EventsUseHexadecimal = .T. The gray boxes still show up. RE: Gray Boxes shown in front of page - wila - 2024-03-27 Hi, There are a number of other GPU flags that you can try which are listed at that command line website you found. But before you go down that rabbit hole.. first check with Sysinternals Process Explorer that the "--disable-gpu" flag was actually passed to the external webview2 process. A screenshot of how it should look like is in the AdditionalBrowserArguments documentation. Another thing to try is to see if you can confirm that the same problem happens with the WebView2 component itself. There's a compiled version available from a link on this page: MS WebView .net example. On top of all that you might also consider enabling logging and see if the log has something interesting to note about this issue, see AntView logging functionality. Hope this helps tracking down the issue. -- Wil RE: Gray Boxes shown in front of page - pivoten - 2024-03-28 The --disable-gpu didn't show in Process Explorer since the WebView was started instead a VFP app. I ran the MS WebView.net example and it didn't have the problem. I turned on logging for AntView and here is the log. It looks like the --disable-gpu is getting set. Creating new log... 2024-03-28 08:39:34.331 2024-03-28 08:39:34.335 ------------------------------------------------------------------------- 2024-03-28 08:39:34.339 ------ Starting new WebView2 instance ------ 2024-03-28 08:39:34.340 ------------------------------------------------------------------------- 2024-03-28 08:39:34.340 Application: C:\SherWare\AMPRO\ampro.EXE (8732) 2024-03-28 08:39:34.340 Win32 2024-03-28 08:39:34.340 Current Directory: C:\SherWare\AMPRO 2024-03-28 08:39:34.355 AntView loaded C:\PROGRA~2\AntView\Win32\AntView.ocx 2024-03-28 08:39:34.355 AntView version 1.1.354.0 2024-03-28 08:39:34.355 User: philsherwood 2024-03-28 08:39:34.355 Log Level: 1 2024-03-28 08:39:34.355 Initializing defaults 2024-03-28 08:39:34.375 Creating window $31610 2024-03-28 08:39:34.384 EventSink changed, creating inplace object $31612 2024-03-28 08:39:34.388 Reading Version = 1.1.354 2024-03-28 08:39:34.389 Configuring default userDataFolder. 2024-03-28 08:39:34.389 userDataFolder C:\Users\philsherwood\AppData\Local\Temp\ampro.EXE.WebView2\ 2024-03-28 08:39:34.389 CreateWebViewOnCreate is set to false, not initializing WebView2 until requested. 2024-03-28 08:39:34.411 2024-03-28 08:39:34.416 ------------------------------------------------------------------------- 2024-03-28 08:39:34.417 ------ Starting new WebView2 instance ------ 2024-03-28 08:39:34.417 ------------------------------------------------------------------------- 2024-03-28 08:39:34.417 Application: C:\SherWare\AMPRO\ampro.EXE (8732) 2024-03-28 08:39:34.417 Win32 2024-03-28 08:39:34.433 Current Directory: C:\SherWare\AMPRO 2024-03-28 08:39:34.433 AntView loaded C:\PROGRA~2\AntView\Win32\AntView.ocx 2024-03-28 08:39:34.433 AntView version 1.1.354.0 2024-03-28 08:39:34.448 User: philsherwood 2024-03-28 08:39:34.448 Log Level: 1 2024-03-28 08:39:34.448 Initializing defaults 2024-03-28 08:39:34.461 Creating window $410D74 2024-03-28 08:39:34.469 EventSink changed, creating inplace object $A1618 2024-03-28 08:39:34.474 Reading Version = 1.1.354 2024-03-28 08:39:34.475 Configuring default userDataFolder. 2024-03-28 08:39:34.475 userDataFolder C:\Users\philsherwood\AppData\Local\Temp\ampro.EXE.WebView2\ 2024-03-28 08:39:34.475 CreateWebViewOnCreate is set to false, not initializing WebView2 until requested. 2024-03-28 08:39:34.499 2024-03-28 08:39:34.504 ------------------------------------------------------------------------- 2024-03-28 08:39:34.505 ------ Starting new WebView2 instance ------ 2024-03-28 08:39:34.505 ------------------------------------------------------------------------- 2024-03-28 08:39:34.505 Application: C:\SherWare\AMPRO\ampro.EXE (8732) 2024-03-28 08:39:34.505 Win32 2024-03-28 08:39:34.521 Current Directory: C:\SherWare\AMPRO 2024-03-28 08:39:34.521 AntView loaded C:\PROGRA~2\AntView\Win32\AntView.ocx 2024-03-28 08:39:34.521 AntView version 1.1.354.0 2024-03-28 08:39:34.521 User: philsherwood 2024-03-28 08:39:34.536 Log Level: 1 2024-03-28 08:39:34.536 Initializing defaults 2024-03-28 08:39:34.547 Creating window $6C1088 2024-03-28 08:39:34.554 EventSink changed, creating inplace object $E30FB0 2024-03-28 08:39:34.559 Reading Version = 1.1.354 2024-03-28 08:39:34.560 Configuring default userDataFolder. 2024-03-28 08:39:34.560 userDataFolder C:\Users\philsherwood\AppData\Local\Temp\ampro.EXE.WebView2\ 2024-03-28 08:39:34.560 CreateWebViewOnCreate is set to false, not initializing WebView2 until requested. 2024-03-28 08:39:34.578 Test if WebView2 control is OK. 2024-03-28 08:39:34.583 Start async creation of the WebView2 control. 2024-03-28 08:39:34.587 BrowserExecutableFolder: 2024-03-28 08:39:34.588 UserDataFolder: C:\Users\philsherwood\AppData\Local\Temp\ampro.EXE.WebView2\ 2024-03-28 08:39:34.588 Setting environment options: chrome flags: [--disable-gpu] Language [] Min. Browser version [95.0.1020.44] Single Sign On False 2024-03-28 08:39:34.588 Reading InstallPath = C:\Program Files (x86)\AntView 2024-03-28 08:39:34.588 Trying to load the loader DLL as C:\Program Files (x86)\AntView\Win32\WebView2Loader.dll 2024-03-28 08:39:34.604 Loading from InstallPath : success. 2024-03-28 08:39:34.604 Loaded as C:\Program Files (x86)\AntView\Win32\WebView2Loader.dll 2024-03-28 08:39:34.604 Version = 1.0.1108.44 2024-03-28 08:39:34.620 Assigned loader library procedures. 2024-03-28 08:39:34.899 CreateAsync Success $31610 2024-03-28 08:39:34.899 WebView2 version 122.0.2365.92 2024-03-28 08:39:34.914 Event OnCreateWebviewCompleted HResult = 0x00000000 (S_OK) RE: Gray Boxes shown in front of page - wila - 2024-03-28 Phil, That's weird, so the plot thickens. The WebView2 control that's used by the .net example does not even set the --disable-gpu flag as far as I can recall. Just to make sure we are chasing the correct issue. Have you tested this with the standard VFP9 example that comes pre-installed with AntView under "C:\Users\Public\Documents\AntView\Examples\Visual FoxPro" ? For the record I just ran the standard example using your test page as posted above, here on a Windows 11 VM running under VMware Fusion and it worked as expected. In addition, I do not need to set the disable-gpu flag for my VMware Fusion install either, but that might be hardware specific as it still depends on the host hardware GPU if the VM can provide GPU acceleration or not. -- Wil RE: Gray Boxes shown in front of page - pivoten - 2024-03-29 I feel stupid. I found that there was an EdgeWebBrowser control inside of an EdgeWebBrowser control that was causing the gray boxes. I deleted the extra control and presto! The boxes are gone. Sorry to trouble you! Phil RE: Gray Boxes shown in front of page - wila - 2024-03-29 Phil, Don't worry. These kind of things happen to the best of us, it certainly is a thing that could happen to me too. I'm just glad that you figured out the reason for the problem and that it now works as it should be. Also thanks for sharing the reason of the issues. I'm sure this thread is going to help someone in the future. -- Wil |