Closed ropg closed 4 months ago
Thanks. Can you please clean-up the white-space/formatting changes in write()
. The diff is too large because of that.
I think this is the implementation of what was Helmut's TODO item at the beginning of the file
@helmut64 I think that refers to you 😄
I needed to change the indent on the whole block because there was a if (this->logBufferSize > 0) {
wrapping most of write()
that is not necessary anymore if we make sure there's always a logBuffer. Not sure how to not make a large commit when removing a wrapping condition like that.
Oh, right...Once I looked at it outside the diff viewer I realized it's actually correct. Got confused by the diff. Sorry about that.
Now print, println and printf "just work" because they execute drawLogBuffer(0,0) and display() when done.
New protected boolean
inhibitDrawLogBuffer
makes sure display is not refreshed every character when a string of characters is written at once. I think this is the implementation of what was Helmut's TODO item at the beginning of the file, which read: "Finish _putc with drawLogBuffer when running display". Note that I moved the creation of the logbuffer from _putc() to write(), because we also want it it to "just work" on Arduino.