MZ Need Help Reducing Face Image Margins

So yeah, I recently discovered another one of RPG Maker's wonderful little features that they didn't bother to fully implement "quirks" in that no matter what I do, face graphics always take up a 144-pixel-wide chunk of space in message windows, even when I use the new option to change the default face size. No matter how small I make it, it's always surrounded by a hard-coded box of wasted space, which looks really awkward. Are there any plugins I can use to actually reduce these margins?
Basically you'll need a messaging-type plugin that adds that option to the show text command.
unfortunately I don't know MZ-plugins, so you'll have to check them yourself to see which offers that option and which not.
I've been looking around, and I've been struggling to find a plugin that actually lets me change the face image margins. Even Visustella seems to be missing that option!
Face margin is tied to window padding. Id prefer to use Eli Face window honestly. or you know use show picture instead.
The message window text start location method takes into account face size.

But I tested it quickly and it seemed to me that the game kept returning same face size and same icon size values no matter what size option I picked from database. Maybe I just don't know how to use them.

And if you want a smaller face fit better in the y-direction, doesn't that mean that you'd have to make the message window height smaller?

EDIT: Oh, didn't they change the codes to account that you can select in editor different sizes? Weird.

EDIT2: Anyway, you can change the method:
Window_Message.prototype.newLineX = function(textState) {
const faceExists = $gameMessage.faceName() !== "";
const faceWidth = ImageManager.faceWidth;
const spacing = 20;
const margin = faceExists ? faceWidth + spacing : 4;
return textState.rtl ? this.innerWidth - margin : margin;
};
Another method you could try is to show messages but with a blank background and use the show pic command to display the face graphic and a custom window skin?
Just to clarify, the exact location of the face graphic in Window_Message is determined by a few things:
  1. For LTR (e.g. English) text, there's a hardcoded starting X offset of 4px.
  2. From there, the face graphic is horizontally centered within the dimensions of ImageManager.standardFaceWidthwhich is hardcoded to 144px. This is the standard face size that the engine's windows are designed around using. The stock windows are not responsive; they do not scale or adapt if you change the face size in the editor.
  3. The face graphic is vertically centered within the current Window_Message's height. The calculation technically uses the window's innerHeightvalue, which does subtract padding (around 24px total, I think). However, if you are using a significantly smaller face graphic than the 144px default, the bulk of the "margin" you keep referring to is coming from the centering logic I've described above.
If you want to change the drawing logic, the most direct route would be a custom plugin that modifies Window_Message.prototype.drawMessageFace.

There is no magic "margin" value that you can just plug in like you would with a Word document or similar.

All of that said, even if you cut out the centering logic and got the face graphic flush at X 0, Y 0, you will still have a tiny face graphic sitting in a much larger Window_Message unless you have a plan to redesign the rest of said window.

Original thread: https://forums.rpgmakerweb.com/threads/need-help-reducing-face-image-margins.183964/