Font!

Post here to discuss any new features, components, chips, etc, that you would like to see in Flowcode.
jgu1
Posts: 602
http://meble-kuchenne.info.pl
Joined: Thu Dec 03, 2020 8:25 pm
Location: Denmark
Has thanked: 495 times
Been thanked: 132 times

Font!

Post by jgu1 »

In display, some of the font doesn´t work. Be able to adjust the size of the font an not fixed. In FC8 you can made much bigger size :D

Jorgen

stefan.erni
Valued Contributor
Posts: 738
Joined: Wed Dec 02, 2020 10:53 am
Has thanked: 149 times
Been thanked: 170 times

Re: Font!

Post by stefan.erni »

Hi Jorgen

Some of the font was not working but after update the lib all of them was working on my display.

regards

Stefan

BenR
Matrix Staff
Posts: 1707
Joined: Mon Dec 07, 2020 10:06 am
Has thanked: 435 times
Been thanked: 598 times

Re: Font!

Post by BenR »

Hi Jorgen,

Have you seen this video? It might help to explain things in v9.
https://www.youtube.com/watch?v=HN8EI64ADic&t=1s

Let me know your thoughts.

jgu1
Posts: 602
Joined: Thu Dec 03, 2020 8:25 pm
Location: Denmark
Has thanked: 495 times
Been thanked: 132 times

Re: Font!

Post by jgu1 »

Yes yes Ben, I think you made it for me and I see the ligth (some of it) :lol:

But when I use one of the font with size 24, biggest, it is still small on a Ili9341. Again if have overseen or misunderstanding something I apoligize.


Br jorgen

BenR
Matrix Staff
Posts: 1707
Joined: Mon Dec 07, 2020 10:06 am
Has thanked: 435 times
Been thanked: 598 times

Re: Font!

Post by BenR »

Hello,

The old fonts in v8 probably used to go bigger then 24 pixels. I can have a go at adding a very large pixel font for you but it will likely take up a fair amount of ROM to store.

What sort of pixel height are you looking for?

In v8 size 31 would give you a 6x6 scaling factor so 5 x 8 would become 30 x 48 though it probably wouldn't look brilliant.

I can also maybe bring back font scaling so you can have multiple sizes from each single font set. This would likely be limited to 1x, 2x, 3x, 4x, etc and width and height would scale together.

jgu1
Posts: 602
Joined: Thu Dec 03, 2020 8:25 pm
Location: Denmark
Has thanked: 495 times
Been thanked: 132 times

Re: Font!

Post by jgu1 »

Hi Ben!

What a service :D

Is it tricky to make it possible so we are able to choose between Fc8 version and Fc9 version. At the other hand I also like the new possibility in Fc9.
But you wrote: "I can also maybe bring back font scaling so you can have multiple sizes from each single font set. This would likely be limited to 1x, 2x, 3x, 4x, etc and width and height would scale together". That would be nice.


Yes it's not easy to be you Ben and make everyone happy :lol: If it is a big job for you, don´t do it.

Br jorgen

BenR
Matrix Staff
Posts: 1707
Joined: Mon Dec 07, 2020 10:06 am
Has thanked: 435 times
Been thanked: 598 times

Re: Font!

Post by BenR »

Hi Jorgen,

Which display are you using and I'll have a go, it probably will be a new macro something like SetFontScaler to avoid breaking existing code.

I might be able to make it a floating point value rather then integer but this might look messy and would certainly add more code. anyway I'll have a go and see what we can acheive. Certinly don't think it's a masive job.

jgu1
Posts: 602
Joined: Thu Dec 03, 2020 8:25 pm
Location: Denmark
Has thanked: 495 times
Been thanked: 132 times

Re: Font!

Post by jgu1 »

Thank you Ben!

I am using the Ili9341 display.

Thank´s in advance

Jorgen

BenR
Matrix Staff
Posts: 1707
Joined: Mon Dec 07, 2020 10:06 am
Has thanked: 435 times
Been thanked: 598 times

Re: Font!

Post by BenR »

Hi Jorgen,

Right the ILI9341 has a new macro called SetFontScaler which allows you to set the X,Y scaling for the printed font, the default being 1, 1.

2, 2 would double the width and height of all printed characters on all fonts.

I've kept the scale factors as integers, floats would likely slow things down too much.

Let me know what you think and if it's working well then I'll roll it out to the other display components.

jgu1
Posts: 602
Joined: Thu Dec 03, 2020 8:25 pm
Location: Denmark
Has thanked: 495 times
Been thanked: 132 times

Re: Font!

Post by jgu1 »

Wow Ben, perform a test tomorrow and you hear, thank´s.

Edit, just update, but Icant´find the fontscaler :roll:

Jorgen

Post Reply