Welcome Guest Search | Active Topics | Sign In | Register

Fussy (or blured) fonts in the web browser Options
Patrick Dupont
Posted: Tuesday, May 1, 2018 3:33:19 PM
Rank: Newbie
Groups: Member

Joined: 5/1/2018
Posts: 6
Hi!

Fonts are rendered more blurred than if I use the webbrowser provided by default in Visual Studio. I used this code to correct the problem, but this it not working...

Quote:
EO.WebBrowser.Runtime.ExtraCommandLineArgs = "--disable-direct-write"


I need to know if there is something we can do for that. If I make it work, we will buy EO.WebBrowser, for sure! It is a very good product, but this problem is very annoying.

Thanks, and have a nice day!

-Patrick.
eo_support
Posted: Tuesday, May 1, 2018 3:36:13 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,221
Hi,

Which platform do you use? Windows Forms or WPF?

Thanks!
Patrick Dupont
Posted: Tuesday, May 1, 2018 3:38:02 PM
Rank: Newbie
Groups: Member

Joined: 5/1/2018
Posts: 6
Hi!

Sorry, I forget to mention that!

Visual Studio 2017
Windows Forms
Windows Server 2012 R2

Thanks!

-Patrick.
eo_support
Posted: Tuesday, May 1, 2018 3:53:29 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,221
Hi,

Please try to call SetProcessDPIAware and see if it works. If you use C#, the code would be something like this:

Code: C#
using System.Runtime.InteropServices;

class Program
{
    //Delcare Windows API SetProcessDPIAware
    [DllImport("user32.dll", SetLastError = true)]
    static extern bool SetProcessDPIAware();

    [STAThread]
    public static void Main()
    {
        //This line is new
        SetProcessDPIAware();

        //Your original code
        Application.EnableVisualStyles();
        Form1 form = new Form1();
        Application.Run(form);
    }
}


Note the SetProcessDPIAware call added before your original code in your Main.

Please let us know if this works for you.

Thanks!
Patrick Dupont
Posted: Tuesday, May 1, 2018 3:59:31 PM
Rank: Newbie
Groups: Member

Joined: 5/1/2018
Posts: 6
Thank you very much, it is very appreciated. I will include that in my project, and make the final user give a try. I hope that solution will work!

Little question, should I let the following code in place?

Quote:
EO.WebBrowser.Runtime.ExtraCommandLineArgs = "--disable-direct-write"


Thanks again!

-Patrick.
eo_support
Posted: Tuesday, May 1, 2018 4:06:07 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,221
I believe you can remove this flag because this is an old flag and it is no longer supported by newer version of the Chromium engine.
Patrick Dupont
Posted: Wednesday, May 2, 2018 9:52:58 AM
Rank: Newbie
Groups: Member

Joined: 5/1/2018
Posts: 6
Hi,

Unfortunately, it is not working. May I show you a picture that show the problem?

(I think we cannot join an attachment to the post, right?)

Thanks, and have a nice day!

-Patrick.
eo_support
Posted: Wednesday, May 2, 2018 1:27:29 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,221
Hi,

We won't be able to find much just from a picture. Please try the following:

1. Load the same page with the regular Google Chrome browser ---- if the same problem occurs with Google Chrome browser, then you will want to try to get Google Chrome to work first. Once you get Google Chrome working, you can find out the corresponding command line arguments (if one exists) and apply it to EO.WebBrowser;

2. Try our TabbedBrowser sample application and see if it works;

3. If TabbedBrowser still does not work, try to disable GPU by adding the following code to App.xaml.cs:

Code: C#
EO.WebEngine.Engine.Default.Options.DisableGPU = true;


Add this before creating the MainWindow.

If you are able to get Google Chrome to work but not EO.WebBrowser, then we may need remote access to the system in order to investigate further.

Thanks!
Patrick Dupont
Posted: Wednesday, May 2, 2018 2:23:51 PM
Rank: Newbie
Groups: Member

Joined: 5/1/2018
Posts: 6
Hi!

Do you think the C# code you mention will work in Windows Forms application?

Thanks,

-Patrick.
eo_support
Posted: Wednesday, May 2, 2018 2:39:49 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,221
It will. However there are two flavor of the settings. They are slightly different and generally you should not mix them. One flavor is the one mentioned in the previous post. Another flavor is:

Code: C#
EO.WebBrowser.Runtime.DisableGPU = true;


You can use either one but you should not set some settings with one flavor and some other settings with the other flavor. The reason we provided the "long" flavor in the previous post is because TabbedBrowser already sets some other settings with the "long" flavor. These has nothing to do with WPF or Windows Forms.
Patrick Dupont
Posted: Wednesday, May 2, 2018 2:58:03 PM
Rank: Newbie
Groups: Member

Joined: 5/1/2018
Posts: 6
Could you try something please from your side?

Please open https://login.microsoftonline.com from Chrome and Internet Explorer, you will see that the term Sign In is more bold in Chrome than in Internet Explorer... probably the problem is with Chromium... what do you think about that?

Thanks again!

-Patrick.
eo_support
Posted: Wednesday, May 2, 2018 3:26:08 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,221
This is why the first thing we ask you to try is to load the same page with Google Chrome browser. We can not change the behavior of the Chromium browser engine. So if for whatever reason the Chromium browser engine does not produce the desired result, then the first thing you need to do is to get Chromium browser engine to produce the desired result (by using Google Chrome browser). If you can not pass that step, then there is almost no chance that it will work with EO.WebBrowser since they are based on the same source code.


You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.