question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

FontNameEditor rendering artifact - *just* the blue box

See original GitHub issue

Problem description:

FontNameEditor font preview is showing less characters. For example on the below screenshots:

Font .NET 4.7.2 .NET Core 3.0
Arial Black ab a
Forte abc ab
Lucida Handwriting ab a

Actual behavior:

.NET 4.7.2 .NET Core 3.0
image image

🤔 ink It is possible the change may related to the change of the default font in #656.

Expected behavior:

We show the same amount of characters as with .NET FX.

It looks like we can achieve the same render by reducing the fontSize in DrawFontSample:

        private static void DrawFontSample(PaintValueEventArgs e, FontFamily fontFamily, FontStyle fontStyle)
        {
            float fontSize = (float)(e.Bounds.Height / 1.2);
            using (var font = new Font(fontFamily, fontSize, fontStyle, GraphicsUnit.Pixel))
            {
                e.Graphics.DrawString("abcd", font, SystemBrushes.ActiveCaptionText, e.Bounds);
            }
        }

Minimal repro:

  • Run WinformsControlsTest in .NET 4.7.2 and .NET 3
  • Compare

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:10 (10 by maintainers)

github_iconTop GitHub Comments

1reaction
RussKiecommented, Jun 7, 2019

😄 Yes, just the blue box.

0reactions
merriemcgawcommented, Jun 12, 2019

We’re going to take a fix here. It looks like it happens both in Framework and in Core and per @RussKie the implementation looks like just a line being added, with no particular purpose.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Weird Blue artefacts in Shadow, only visible post
Hi people, I'm trying to render this video, but every time I render it I get this weird blue colour (clipping I guess?)...
Read more >
Strange artifacts when rendering a video : r/davinciresolve
Hi, was wondering if someone can help me figure out why my rendered video has strange artifacts under this title.
Read more >
Blue artifacts when motion blur is on - Maya
I made an animation, and when I turn on the motion blur for final rendering, some weird blue artifacts appear on my rendered...
Read more >
Giant white block artifact in eevee render
I'm getting these giant white squares in my render for some reason. It shows up completely randomly and if I re render the...
Read more >
Render artifacts! | Forums
I have been trying to render a scene, but chronically get these black squares in my final mantra render. It's as if small...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found