pyscripter 705 Posted 5 hours ago (edited) For years there have been rants about flicker in Vcl applications. So when I tried to fast resize a form with an EdgeBrowser and saw the browser scrollbar jumping right and left, I assumed that it is Delphi's problem. Then I tried the same with Edge and the result was the same. Massive flicker when the scrollbar is visible! Bravo Microsoft! In fact Edge flickers even without scrollbars, whilst Delphi's EdgeBrowser doesn't. By the way does anyone know how to Vcl style the EdgeBrowser scrollbar? Edited 3 hours ago by pyscripter Share this post Link to post
pyscripter 705 Posted 3 hours ago (edited) 1 hour ago, pyscripter said: By the way does anyone know how to Vcl style the EdgeBrowser scrollbar? In case anyone has a use for it, here is how you can set the browser color scheme: procedure TForm2.SetColorScheme(Dark: Boolean); var Profile: ICoreWebView2Profile; Scheme: COREWEBVIEW2_PREFERRED_COLOR_SCHEME; begin if Dark then Scheme := COREWEBVIEW2_PREFERRED_COLOR_SCHEME_DARK else Scheme := COREWEBVIEW2_PREFERRED_COLOR_SCHEME_LIGHT; (EdgeBrowser.DefaultInterface as ICoreWebView2_13).Get_Profile(Profile); Profile.Set_PreferredColorScheme(Scheme); end; function IsStyleDark: Boolean; var LStyle: TCustomStyleServices; LColor: TColor; begin Result := False; LStyle := TStyleManager.ActiveStyle; if Assigned(LStyle) then begin LColor := LStyle.GetSystemColor(clWindow); // Check if the background color is dark Result := (LColor and $FFFFFF) < $808080; end; end; Form2.SetColorScheme(IsStyleDark); Form2.EdgeBrowser.NavigateToString(Html); Edited 3 hours ago by pyscripter 1 Share this post Link to post