MarlinFirmware / Marlin

Marlin is an optimized firmware for RepRap 3D printers based on the Arduino platform. Many commercial 3D printers come with Marlin installed. Check with your vendor if you need source code for your specific machine.
https://marlinfw.org
GNU General Public License v3.0
15.94k stars 19.08k forks source link

Change GET_TEXT to GET_TEXT_F #27032

Closed classicrocker883 closed 1 week ago

classicrocker883 commented 2 weeks ago

Description

Now that some other than English *language_.h** files have these defined, we can use GET_TEXT_F instead.

In addition, I included a swap over from MString<> to TS for proui/printstats.cpp because it does save on memory.

Requirements

Benefits

Configurations

Related Issues

sjasonsmith commented 2 weeks ago

I believe that from @thinkyhead's comment on #26949 that this is probably desirable, but I'm going to leave it to him to merge since the GET_TEXT macros weren't explicitly referenced in that comment. I'm still a bit fuzzy on all the different string types and advantages of each.

I attempted to do a find/replace of ALL the GET_TEXT macros, but still had to revert several files that caused build failures.

I am able to compile all the tests if I add replacements in these files, but it is possible that they are just not covered by the compilation checks:

image

thinkyhead commented 1 week ago

Thanks for catching these. We can also go straight to the "_P" versions of functions / methods sometimes, if for some (weird) reason using the passthrough increases AVR build size. Ideally we should find that the use of passthroughs has zero impact on build size.