Extending TFT_eSPI library #1536
Replies: 25 comments 19 replies
-
p.s. and could you add non-inlined versions of begin_tft_write() / end_tft_write(), please? |
Beta Was this translation helpful? Give feedback.
-
Maybe, a few provisos:
|
Beta Was this translation helpful? Give feedback.
-
Hi, yes it is intended to publish it /them I have uploaded an example here: https://github.com/FrankBoesing/WT32-SC01-TTF-TEST - it includes your library, slightly edited. |
Beta Was this translation helpful? Give feedback.
-
Hi, thanks, that is great. I have run your example with a few minor tweaks on an RP2040 using the stock library. It runs very well. I used startWrite() and endWrite() as these are the user interface for private begin_tft_write and end_tft_write. I need to think on this further as there may be a DMA transaction iin progress when the TTF font call is made and this needs to wait. At the moment I think a dedicated start (with DMA wait) and end functions may be needed. |
Beta Was this translation helpful? Give feedback.
-
No hurry, take your time :) |
Beta Was this translation helpful? Give feedback.
-
I'd like to add some methods to make a nice tool work - I modified it to work with other screen-sizes (than ILI9341). It's a PowerPoint :) with a macro that converts the screens to tft display commands.... you can create your GUI with powerpoint, start the macro and get a (almost) 1:1 sourcecode that displays this gui on the tft... This is the original: https://github.com/KrisKasprzak/Powerpoint-ILI9341_t3 |
Beta Was this translation helpful? Give feedback.
-
Thanks :) |
Beta Was this translation helpful? Give feedback.
-
Hm.. however... i just took a look... it seems my version is Powerpoint 2007 (?) Can you post the errormessages? |
Beta Was this translation helpful? Give feedback.
-
Great news :) I'll publish my version tomorrow.. |
Beta Was this translation helpful? Give feedback.
-
I had a go at tweaking the macro code myself. I expect you noticed there were a few bugs that needed fixing. TFT_eSPI handles ellipses so there is no need to assume a circle is drawn and I have updated the code. I have created a test slide but it is not complete yet. Here is a copy FWIW. |
Beta Was this translation helpful? Give feedback.
-
Hi, i've uploaded my version. |
Beta Was this translation helpful? Give feedback.
-
A first version of the library is here: |
Beta Was this translation helpful? Give feedback.
-
Hm,, looks like we have to add a scaling to the fonts-sizes, too. They are too small with a 480x320 display. |
Beta Was this translation helpful? Give feedback.
-
Beta Was this translation helpful? Give feedback.
-
I think the font sizes on the slast sliede of kris fit only by chance for the 320*240 ili9341. With 480x320 the fontsize 8 in the "screen2" table is ok, but the headline is way too small and should roughly double the size... |
Beta Was this translation helpful? Give feedback.
-
Yes, the screen w and h is 1.5x so maybe that is a good scale factor for a 320x480 screen. |
Beta Was this translation helpful? Give feedback.
-
My version calcs the scale factor with the help of screen size and display size to get the "dot"s needed by Powerpoint for all elements und uses the font size the slides uses. However, this using that fontsize seems not to be correct, although PP scales the fonts.... the x1.5 seems not to be correct, too, as it is too less for the headline and too large for the 8pt fonts in the table. Have to think about it... |
Beta Was this translation helpful? Give feedback.
-
No, headline is 13 but should be ~25 - fontsize in the table is ok. |
Beta Was this translation helpful? Give feedback.
-
Still doesn't look "perfect", but indeed the 1.5 scalefactor seems almost ok.. have updated the ppt. |
Beta Was this translation helpful? Give feedback.
-
My latest version 1.0.4 of the sketch generator is here, it includes test slides only at the moment: This includes the first attempt at creating boxes with associated variables. |
Beta Was this translation helpful? Give feedback.
-
Looks good. I'll wait for your version and do other things. Frank |
Beta Was this translation helpful? Give feedback.
-
I've compiled ttf2bdf for windows: |
Beta Was this translation helpful? Give feedback.
-
I have updated the VBA macro and put the updated pptm here: I have created a pull request to Kris's repository. |
Beta Was this translation helpful? Give feedback.
-
I'll take a look :) |
Beta Was this translation helpful? Give feedback.
-
I have added a ReadMe to the repository here: |
Beta Was this translation helpful? Give feedback.
-
Hi,
i'd like to extend your great library. Some needed functions are "private", so this is not possible. Changing that "private:" into "protected:" would allow to use inheritance and to add extensions on top of your lib.
Is there a chance that you change this?
Thank you in advance,
Frank
Beta Was this translation helpful? Give feedback.
All reactions