Font scaling for different screen sizes

Someone please help me with this problem
how can i make the font appear in same ratio for different screen sizes
i made the game in pc in 480/700 screen size and used font in it, i have placed the fonts and its size according to the screen size in pc and set no change to screen size in the properties for android
when i play it in android all fonts are going out of the screen

I tried doing the scaling of font by setting it according to the ratio with the screen size and even with window size but still they are not getting fit in the screen for different sizes

Maybe using this on very top line of your first scene:

under which category is that function?

and does it apply on text size?

Under Game’s window. Yes it does.

it worked but partially
font is inside in horizontal border but it didnt get smaller instead it’s overflowing downwards

for example there is a back button with Back labeled on it
in pc screen the text is at the middle of the button and the size of the text is let say 20
but in android the buttons size gets a little smaller due to screen size and cause of that the text no longer appears in middle as the text’s size is still same as 20 and looks awful

Try setting “NO” to keep aspect ratio.
I never use text inside buttons or sprites.
I make the sprites in Photoshop and make them already with the text I want.

This is a screenshot of my game for PC:

This is for Android:

Texts out of buttons are made in GD.

yea the pics you shared it will work in that way cause there is no text in it as you said that you made the text in photoshope so its just a png pic thats why it is good in ratio
and what you suggest well i also do it that way but what about when you want some user input then how can i manage the text of that and its size

The only text I made in Photoshop are those inside buttons. The others are made in GDevelop and they scales.

can you share some more pics with more text
and the codes for them.
and what is your setting in the properties panel about the window size, whether it fits to height or width or no change?

Nothing special. I just used a code to center it.

I used no change in properties.

i m attachinng of some simple test with the text
PC screenshot

android screesnshot

game screen size is 480x720

can you do the same thing and send me the screenshot of your results?

PC Screen:

Android Screen:

what about your text object?
how is the text is written in your text object?

No matter if I write the text in Text Properties or in an Action in Event Sheet. It works the same way.

can you send me the material so i can run your app in my device may be its the prob with my device

I’ll do it again and post it.

for me about those text object its one object and it’s 2 instances one at left and one at right

test is written in a single line like this ‘testing text texting text…’

width of the instance of the text object at left is half that of the width of instance at right