Results 1 to 9 of 9

Thread: [RESOLVED] Form blurry at runtime

  1. #1

    Thread Starter
    Addicted Member
    Join Date
    Sep 2016
    Posts
    164

    Resolved [RESOLVED] Form blurry at runtime

    Anyone have a fix for the form being blurry at runtime - compare screenshots below:
    The first is a screenshot from application runtime and second is a screenshot from design view of form - notice font and general form blurring.
    Name:  Form.jpg
Views: 5526
Size:  8.8 KB
    Name:  View.jpg
Views: 5534
Size:  9.6 KB

    If it is relevant the display monitor resolution is 2560 x 1440
    Thank you in advance

  2. #2
    PowerPoster Poppa Mintin's Avatar
    Join Date
    Mar 2009
    Location
    Bottesford, North Lincolnshire, England.
    Posts
    2,423

    Re: Form blurry at runtime

    Hi Mmiller524,

    From what we can see, I'd suggest either:

    1. Reduce the font size in the Labels (TextBoxes ?)
    Or,
    2. Make the Labels as large as you can, in which case maybe remove any borders and ensure the Labels' BackColor are the same as the background.

    What is the source of the image design? Is it a photo image? If so, try making the image resolution greater. Also if it's a photo, try making it a .PNG file.

    Poppa.

    PS. You might want to set the TextAlign to MiddleCenter, to improve the appearance.

    Pop.
    Along with the sunshine there has to be a little rain sometime.

  3. #3
    Sinecure devotee
    Join Date
    Aug 2013
    Location
    Southern Tier NY
    Posts
    6,582

    Re: Form blurry at runtime

    That is a known problem with high DPI settings for the newer high resolution displays.
    Did you do a internet search on form blurry before posting this question?

  4. #4

    Thread Starter
    Addicted Member
    Join Date
    Sep 2016
    Posts
    164

    Re: Form blurry at runtime

    I did yes, resizing applications to 100% rather than the 200% they are sized at now (as siuggested by other forums) makes the display much smaller in general - as seen below

    Name:  100% dpi.jpg
Views: 5375
Size:  6.9 KB
    unfortunately this involves running my entire system in a much larger res, on a 13 inch screen this is not ideal
    Name:  desk space.jpg
Views: 5405
Size:  30.5 KB

    thanks for your help

  5. #5
    Sinecure devotee
    Join Date
    Aug 2013
    Location
    Southern Tier NY
    Posts
    6,582

    Re: Form blurry at runtime

    I thought the other suggested solution would be to use a wpf project instead of a winform project.
    I have a higher display laptop which I generally run at 125 to 150 percent, but I guess haven't had a project yet that has given me a problem (pretty simple projects), so haven't had to try to work around the issue myself, and can't really offer an alternative, not knowing what combination of controls/drawing you're doing to have the issue.

  6. #6

    Thread Starter
    Addicted Member
    Join Date
    Sep 2016
    Posts
    164

    Re: Form blurry at runtime

    thanks for your help, images are vectors so that shouldnt necessarily be the cause,

  7. #7
    PowerPoster
    Join Date
    Oct 2010
    Posts
    2,141

    Re: Form blurry at runtime

    Go to VS Project Menu->ProjName Properties->Application Tab->Click on "View Window Settings" button. This will open the app.Manifest file.

    Locate this block:
    Code:
      <!--
      <application xmlns="urn:schemas-microsoft-com:asm.v3">
        <windowsSettings>
          <dpiAware xmlns="http://schemas.microsoft.com/SMI/2005/WindowsSettings">true</dpiAware>
        </windowsSettings>
      </application>
      -->
    Delete the first line "<!--" and the last line " -->".

    This will declare your application as DPI aware and will prevent Windows DWM from applying a scale factor to your application.

  8. #8

    Thread Starter
    Addicted Member
    Join Date
    Sep 2016
    Posts
    164

    Re: Form blurry at runtime

    FIXED! worked perfectly, thank you TnTinMN

  9. #9
    New Member
    Join Date
    Jul 2018
    Posts
    1

    Talking Re: Form blurry at runtime

    Quote Originally Posted by TnTinMN View Post
    Go to VS Project Menu->ProjName Properties->Application Tab->Click on "View Window Settings" button. This will open the app.Manifest file.

    Locate this block:
    Code:
      <!--
      <application xmlns="urn:schemas-microsoft-com:asm.v3">
        <windowsSettings>
          <dpiAware xmlns="http://schemas.microsoft.com/SMI/2005/WindowsSettings">true</dpiAware>
        </windowsSettings>
      </application>
      -->
    Delete the first line "<!--" and the last line " -->".

    This will declare your application as DPI aware and will prevent Windows DWM from applying a scale factor to your application.

    THANK YOU SO MUCH!!!!!!!!!!!!!! YOUR THE ONLY ONE ON THE INTERNET THAT FIXED MY PROBLEM WITH THE BLURRY STUFF AS WELL!!!

    NOW I HAVE A HD RESOLUTION FOR MY FORM!!!

    Made this account specifically just to say thank you!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

    :D :D :D :D :D :D :D :D :D :D :D :D :D

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width