ImpulseAdventure / GUIslice-Builder

Cross-platform drag & drop GUI builder for GUIslice
Other
167 stars 35 forks source link

Strange codes in generated file #257

Closed Kabron287 closed 5 months ago

Kabron287 commented 5 months ago

Describe the bug Example: ex25_bld_popup.prj To Reproduce Steps to reproduce the behavior:

  1. Generate

Expected behavior In file: ex25_bld_popup_GSLC.h @ line 42: #define "/" @ line 144: gslc_SetBkgndImage(&m_gui,,));

Version

Pconti31 commented 5 months ago

@Kabron287 Sorry, but I just tried this and everything worked fine. Maybe you played around with the options. Look at the E_PROJECT_OPTIONS posted below and see what it should look like.

popup

If you can't see whats wrong post a full zip file starting with the folder ex25_bld_popup Paul--

Kabron287 commented 5 months ago

@Pconti31 please try to generate for TFT_eSPI driver esp-tftespi-default-ft6206.h

Kabron287 commented 5 months ago

Here is my project ex25_bld_popup.zip

Kabron287 commented 5 months ago

Errors are allready in Builder templates: graphics.t, linux.t

// Set Background to an image gslc_SetBkgndImage(&m_gui,$$,$));

Pconti31 commented 5 months ago

@Kabron287 I would like to help you out here but no luck. So I'll point out a few things here.

I can't think of anything else I can do...

Paul--

Pconti31 commented 5 months ago

@Kabron287 I take point two above back. Seems there is a bug that allows generation after making changes to E_PROJECT_OPTIONS without doing a save. I'll fix that in a future release.

Kabron287 commented 5 months ago

@Pconti31 Thanks for attention. Concernind TFT_eSPI/Adafruit, I could see my code only tomorrow.

Kabron287 commented 5 months ago

@Pconti31 you right, my proj had different settings in E_PROJECT_OPTIONS and Edit->Options. That was the source of errors.

Why these setting are located in 2 different places? Why not to join them in one place?

Kabron287 commented 5 months ago

Closed

Pconti31 commented 4 months ago

@Kabron287 Why two places? Well, for good or bad my thinking is that not everyone uses Adadfruit_GFX and a 320 x 240 screen right? So, why have them enter these values everytime they create a new project. The edit->options values are stored in user prefences not the .prj file and are used as starting values for new projects but if you need to override them for a one off project you just edit the E_PROJECT_OPTIONS and they will be stored inside the .prj file.

Also, say you start with Arduino Mega and move on to an ESP32 but decide to go back and make some small changes to your old mega project. Well, the E_PROJECT_OPTIONS are stored inside the *.prj file so you don't need to override them in that case since the project file just remembers the settings.

Still, I agree it has caused a bit of confusion. Maybe I could instead not only save E_PROJECT_OPTIONS in the current *.prj file but also place the new edits inside user prefences and get rid of edit->options altogether... Still, that would be a fair amount of work. It would be nice if someone else took an interest like @etet100 has and help implement new features. I'm in my seventies after all.

Paul--