MZ OpenType Pixel Font Renderer (MV & MZ)

I suggest you try downloading OpenTypePixelFontNew.zip again.
It fixed missing strokes when the text's position is not whole number.
Same issue, with YEP_CoreEngine it shows glitch "ON" and "OFF", without YEP it will show a perfect pixel font and no glitch

There's something issue of YEP_CoreEngine

[Mod edit - attachment (YEP_CoreEngine.js) removed in line with Yanfly's terms of use:
Redistribution of the plugins and its code, outside the scope of game projects, is strictly forbidden outside of the host website, Yanfly.moe, and by the following sites/members: itch.io.
]
1742453287855.png

640x300, font size = 16
Looks normal here.
Did you use YEP? if yes, how?
Yes, just the core engien and nothing else. Also change font size to 16. Also the font you linked.
So I think there might be other reasons.
It seems I fixed the issue, which is nwjs I upgrade from 29 to 49 (RPG Maker MV), which cause the font was not perfectly pixel font, so I downgrade to default 29 and it works perfectly fine.
Good to know. I think I need to check it out.
Edit*

OK it seems the problem is the infamous mssing-part-of-text glitch of nw.js.
There's a fix on the Japanese site: here.

I tried it and it fixed the problem on 0.49.2, but not sure if will cause any performance drop. You can try it if you still need nw v0.49.2.

This is copied from fspace's FONT_RENDERING_WORKAROUND_TEST.js in that topic.
JavaScript:
    const markContext = (() => {
        const marked = new WeakSet();
        return context => {
            if (!marked.has(context)) {
                context.getImageData(0, 0, 1, 1);
                marked.add(context);
            }
        };
    })();


    const Bitmap_drawText = Bitmap.prototype.drawText;
    Bitmap.prototype.drawText = function () {
        Bitmap_drawText.apply(this, arguments);


        markContext(this.context);
    };
YES!!! YES!!!!! IT WORKS NOW!!!

I am so glad I upgrade to 53.1 and it's working 100% pixel font

Thank you!! Finally it solved the problem RPG Maker MV and MZ font issue
1742821305555.png

This is a bit experimental. About the width compression when the text is longer than the button.
Obviously if the font is too small it can't shrink any further.
So if the text is 2x its base size, it can shrink to 1/2 of its width; if the text is 3x its base size, it can shrink to 1/3 and 2/3 of its width, and so on.
Did you update it?
Yes, hope it doesn't affect existing project. If so maybe I should make it not default.
I checked yours on itch.io, I don't see you updated, it shows 7 days ago that you fixed bug.
I checked yours on itch.io, I don't see you updated, it shows 7 days ago that you fixed bug.
Ah, OK I think it is still experimental so I'll skip the log for now.
I also made it a hidden feature, so it won't affect existing project.
You can add a #squish to the url if you download the newest version to enable the squish feature.

For example, PixelOperator.ttf#squish
I'm a bit unsure if it is really needed, because I have yet to see any game using pixel font have squished text.
like this?

1743262523043.png
Yes, but you need to download the newest file.
But I see you use 16 for your font size, so it may not work for your game because the font is already the smallest.
Just want to let you know I integrate a fix for the missing parts bug:
1743552383910.png

I also tested it has been fixed since Chromium 97(nw v0.60). So maye I should add a check for browser versions later.
Is it possible to toggle the rendering of text from the default to this plugin's method while the game is deployed and running? I'd like to add this as an option in the options menu of my game.
There's no such option yet.
But you can use a work around, create two fonts with the same ttf file, one use snap to grid option, the other one doesn't. Then use a font change plugin like this:
There's no such option yet.
But you can use a work around, create two fonts with the same ttf file, one use snap to grid option, the other one doesn't. Then use a font change plugin like this:
Thank you!
Amazing plugin-in, it's allowed me to consider moving away from SFonts!

Several of my testers have reported blocky/poorly scaled text that happens often that I and other users can't recreate.

Example- in the picture, the 'd' on the last line. (font = Yesterday)

It seems users that have reported the issue might all have >60 hz refresh rate, and their window.devicePixelRatio is either 1.25 or 2.5 (when I switch mine though I can't recreate the issue). These might be involved but I'm unsure.

image.png

Original thread: https://forums.rpgmakerweb.com/threads/opentype-pixel-font-renderer-mv-mz.171027/