MV Text Alignment in Menu

Hopefully this a simple fix; though I could not figure out myself. I want the gold number to aligned to the right.

Unaligned.png


I have a feeling it's related to this section Yanfly's Core Engine code:
Yanfly Engine Core.png


Or this section of code from SumRndmDde Alt FF7 Menu:
FF7 Gold & Time Window.png


I'm using this plugin to change the word "time" from the FF7 plugin into an icon.

Here's all my plugins if needed:
My Plugins.png
Hello. Change the last argument of the drawText function to 'left' instead of 'right'.
Should do it.

edit: seems I read too fast. To align it to more to the right, add a little offset to the wx argument, like:
Code:
let wwx = wx + 20
this.drawText(unit, wwx, wy, ww, 'right')
That didn't seem to change anything. This is what you meant, right? In Yanfly's code?

Code:
this.drawText(unit, wx + 20 , wy, ww, 'right');
Hello, yeah it was an edit for yanfly coreEngine in the drawCurrency function. Just tested it and it work for me, but I don't have the SRD plugin. Does that plugin have its own drawCurrency function, or it call it from windowBase?
As in the first post, the second block of code, it also has a window.goldandtime.

Maybe I need to have both say wx + 20 and 'right'?
Hello, sorry for late response, I was at work.
Then you could try to offset it in SRD plugin by adding + 20 to the x argument
Code:
this.drawCurrencyValue(this.value(), this.currencyUnit(), x + 20, this.lineHeight(), width)
It moves the number... And the icon...

2020-10-17 00_20_41-Silver Monster.png
Hello again, I downloaded the SRD plugin to test it with both plugins. I can still move the text to the right with the changes in YEP_coreEngine. Be sure to offset both drawText functions, that's why I stored the offset in a local variable in my first example, sorry if it wasn't clear enough...
Capture d’écran, le 2020-10-17 à 08.50.01.png

Should work now.
What about SumRndmDde Plugin Menu Kingdom Hearts? I want to make a menu middle alignment when you open a menu, like item, skill, weapon, status, and more...

Screenshot (254).png
Hello @Killerslash, if you're using YEP_coreEngine, I think there's a parameter to change the text alignment (but will affect all menus), or you can paste these lines in SRD plugin or any other:
Code:
Window_MenuCommand.prototype.itemTextAlign = function() {
    return 'center';
};
That should do it.
If not, start a separate thread for your problem, and we'll see what can be done 😉
I am not using YEP core engine.
It's working without YEP CoreEngine.
Thanks for your help.
🙂
Thanks! My icon and text are fixed!!

Original thread: https://forums.rpgmakerweb.com/threads/text-alignment-in-menu.128737/