Bodmer / TFT_ILI9341

A fast Arduino IDE compatible graphics and fonts library including a driver for the ILI9341 based TFT displays.
112 stars 33 forks source link

Include - (minus) in 7 segment font #9

Closed Ozzy62 closed 7 years ago

Ozzy62 commented 7 years ago

First of all, thank you for the nice library, it works a charm. I use your library to display temperatures, and where I live (Denmark) outside temperatures tend to go below zero in the winter. It would therefore be a great addition (for me) to the library to include the minus sign in the 7 segment font. I do not have the foo to do it my self.

Regards Svend

Bodmer commented 7 years ago

Hi, I will see if I can create a new symbol for you this weekend.

Bodmer commented 7 years ago

Ah, forgot about this one.. is this still a need, or have you sought out another solution?

Ozzy62 commented 7 years ago

Yes, given the time of year, the need has come up again.

Bodmer commented 7 years ago

I have added the minus in the attached.

7seg.zip

Can you replace the Font7srle.c file with that attached and let me know if this works for you.

Ozzy62 commented 7 years ago

Hi Bodmer. It works like a charm, thank you very much for your effort. I did have to change: #include to #include <avr/pgmspace.h> but otherwise no problems.

Bodmer commented 7 years ago

Thanks for fixing that! I will correct it and add to main library.

nico1080 commented 2 years ago

Hi,

It is not included in master.

Bodmer commented 2 years ago

It is included, ASCII code 0x2D, so you can use for example:

tft.drawString("-123", 0, 0, 7);

Bodmer commented 2 years ago

Ah, wrong library! I will add it!

Bodmer commented 2 years ago

Just checked this library and it is in there, here.