How to fix jagged diagonal lines?

user9812user9812 Posts: 6
edited December 2022 in Font Technology
I'm trying to create tally marks in my font. The problem lies with the '5' symbol (4 vertical lines with a strike through). The strike through is so jagged! It needs to look like a diagonal line but it looks more like a set of stairs.

I'm using FontForge. I can't go to the smoothing option because that applies to the whole font (unless there's a way to have it only apply to one character?). I've tried removing hinting and instructions. I've tried changing the angle of the line. Nothing seems to work. I'm almost to the point of being convinced it can't be fixed because it's just the way the font works.. it wants to place any line < 45 degrees onto a pixel. It doesn't want to do anti aliasing. Is there a way to force it to anti aliase for just one character/glyph?


Tagged:

Comments

  • no

    But aside from that you have not given us important information needed to address the underlying question of why it is “so jagged.”

    The font rendering is massively depending on the rendering environment. Are you on Windows, Mac, Linux or something else? What app(s) are you looking at the font rendering in? If Windows, what version of Windows?

  • google chrome
  • Ah. I see, yes, you are talking about an optical illusion and not a rendering issue at all.
  • Nick ShinnNick Shinn Posts: 1,951
    Further to Andreas’ “optical” correction—perhaps some form of “ink trap” would be better?
  • John HudsonJohn Hudson Posts: 2,539
    I don’t find an optical illusion in the form on the left in Andreas’ illustration, and instead perceive the stepped segments in the adjusted form on the right. The optical illusion in which a diagonal crossing a stem can appear discontinuous occurs when the stems are of different thicknesses, e.g. in the Polish ł. In this case, the stems are of similar thickness, so the diagonal appears continuous without the need to segment it.
  • Nick ShinnNick Shinn Posts: 1,951
    This optical effect (I hesitate to use the term “illusion”) is subjective. In other words, one might not notice it unless one were looking for it, and even then different people react differently.
    However, John, you and I should really provide visual examples to further our observations.
  • John HudsonJohn Hudson Posts: 2,539
    I was using Andreas’ visual examples as a reference. The forms on the left do not look jagged to me, while those on the right do, and based on my experience I would say this is because the strokes are of similar thickness, and hence the thickness of the verticals does not affect the optical continuity of the straight diagonal.

    If we increase the contrast between the stroke thicknesses, then the diagonal looks discontinuous and jagged, and would need adjustments to appear continuous:

  • John HudsonJohn Hudson Posts: 2,539
    The distance between the uprights also affects the visual continuity of the diagonal when the strokes are of different thicknesses, meaning that any adjustment to compensate for the visual effect needs to take into account the distance as well as the stroke thickness.


Sign In or Register to comment.