During my current adventures into android screen scaling, I have been looking 
into our lcd api. It was a while since I dug into it last, and I was quite 
intrigued to find that we now have no less than 14 lcd_puts function calls:

 lcd_puts
 lcd_puts_offset
 lcd_puts_scroll
 lcd_puts_scroll_offset
 lcd_puts_scroll_style
 lcd_puts_scroll_style_offset
 lcd_puts_scroll_style_xyoffset
 lcd_puts_style
 lcd_puts_style_offset
 lcd_puts_style_xyoffset
 lcd_putsf
 lcd_putsxy
 lcd_putsxy_style_offset
 lcd_putsxyf

One of the reasons for the growth is that the api started out with 
line-oriented positioning and has then been expanded with pixel-oriented (xy) 
alternatives. I would like to stop using line oriented positioning and convert 
all code to pixel positions. Jonathan Gordon has already written a patch that 
does much of that, which I have used in my effort so far.

Going pixel-only removes some of the api proliferation, but we still have puts 
functions for nearly all combinations of scroll, offset and style.

I would like to condense all of our puts variants into one single function:

 void lcd_puts(int x, int y, int xcrop, int style,
               bool scrolled, const char* fmt, ...)

As far as I can tell, this works on the charcell Player too. It simply has two 
possible y positions: 0 or 1.

If you believe this change is unsuitable, I would very much appreciate hearing 
what I have missed or what would require special consideration.

As for time frame, this is clearly a post-3.10 change.

-- 
Björn

Reply via email to