This is the bug/patch tracker for Rockbox. Click here for more information.
Quick links: Bugs · Patches · Rockbox frontpage
FS#7033 - Define line height in the WPS
Attached to Project:
Rockbox
Opened by Nicolas Pennequin (nicolas_p) - Sunday, 15 April 2007, 14:40 GMT+1
Last edited by Jonathan Gordon (jdgordon) - Tuesday, 23 September 2008, 12:17 GMT+1
Opened by Nicolas Pennequin (nicolas_p) - Sunday, 15 April 2007, 14:40 GMT+1
Last edited by Jonathan Gordon (jdgordon) - Tuesday, 23 September 2008, 12:17 GMT+1
|
DetailsThis patch adds an %lh tag to the WPS that allows to define the line height.
The format is %lh|height| (the '|' at the end is mandatory). With this tag added to a WPS, the lines will be of the specified height whatever the font chosen by the user. If the font used is smaller than the defined line height, the text will be centered. |
This task depends upon
Closed by Jonathan Gordon (jdgordon)
Tuesday, 23 September 2008, 12:17 GMT+1
Reason for closing: Out of Date
Additional comments about closing: this is less of an issue now the WPS has viewports so can probably be closed
Tuesday, 23 September 2008, 12:17 GMT+1
Reason for closing: Out of Date
Additional comments about closing: this is less of an issue now the WPS has viewports so can probably be closed
The code changes seem very minimal (mainly just replacing references to the font height to references to this new variable), and it implements two (IMO useful) features - 1) The ability for a WPS designer to specify a line-spacing; 2) The ability for a user to use slightly different sized fonts with an existing WPS without breaking the formatting wrt images. e.g. a user might want to use a smaller font in order to display more text without scrolling.
A side-effect is that WPSs are less broken when the user doesn't have the correct font installed, but I don't think that's the primary reason for committing this patch.
I will try to find a nice workaround, but it seems amiconn's viewports and LCD drivers rewrite will bring the true solution to this.
Thanks.
Until then, here is my latest version (I'm not sure there are some changes but at least it'll apply cleanly)