Gitweb links:

...log 
http://git.netsurf-browser.org/netsurf.git/shortlog/888d8eac4f102f6ecb75878e7717c3495e81a215
...commit 
http://git.netsurf-browser.org/netsurf.git/commit/888d8eac4f102f6ecb75878e7717c3495e81a215
...tree 
http://git.netsurf-browser.org/netsurf.git/tree/888d8eac4f102f6ecb75878e7717c3495e81a215

The branch, master has been updated
       via  888d8eac4f102f6ecb75878e7717c3495e81a215 (commit)
      from  2f408f0ecbadcfc895c5067940d840108bbbb77f (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commitdiff 
http://git.netsurf-browser.org/netsurf.git/commitdiff/888d8eac4f102f6ecb75878e7717c3495e81a215
commit 888d8eac4f102f6ecb75878e7717c3495e81a215
Author: Michael Drake <t...@netsurf-browser.org>
Commit: Michael Drake <t...@netsurf-browser.org>

    A few tweaks from when I was looking for internal font renderer bug in 
wrong place.

diff --git a/framebuffer/framebuffer.c b/framebuffer/framebuffer.c
index 9195398..fda8aae 100644
--- a/framebuffer/framebuffer.c
+++ b/framebuffer/framebuffer.c
@@ -136,12 +136,14 @@ static bool framebuffer_plot_text(int x, int y, const 
char *text, size_t length,
     if (buffer == NULL)
         return true;
 
-        /* y is given to the fonts baseline we need it to the fonts top */
-        y-=((fb_font->height * 75)/100);
+        /* y is given as the baseline, at 3/4 from top.
+         * we need it to the top */
+        y -= ((fb_font->height * 3) / 4);
 
-        y+=1; /* the coord is the bottom-left of the pixels offset by 1 to make
-               *   it work since fb coords are the top-left of pixels
-               */
+        /* the coord is the bottom-left of the pixels offset by 1 to make
+         *   it work since fb coords are the top-left of pixels
+         */
+        y += 1;
 
     blen = strlen(buffer);
 
@@ -154,7 +156,7 @@ static bool framebuffer_plot_text(int x, int y, const char 
*text, size_t length,
         chrp = fb_font->data + ((unsigned char)buffer[chr] * fb_font->height);
         nsfb_plot_glyph1(nsfb, &loc, (uint8_t *)chrp, 32, fstyle->foreground);
 
-        x+=fb_font->width;
+        x += fb_font->width;
 
     }
 


-----------------------------------------------------------------------

Summary of changes:
 framebuffer/framebuffer.c |   14 ++++++++------
 1 files changed, 8 insertions(+), 6 deletions(-)

diff --git a/framebuffer/framebuffer.c b/framebuffer/framebuffer.c
index 9195398..fda8aae 100644
--- a/framebuffer/framebuffer.c
+++ b/framebuffer/framebuffer.c
@@ -136,12 +136,14 @@ static bool framebuffer_plot_text(int x, int y, const 
char *text, size_t length,
     if (buffer == NULL)
         return true;
 
-        /* y is given to the fonts baseline we need it to the fonts top */
-        y-=((fb_font->height * 75)/100);
+        /* y is given as the baseline, at 3/4 from top.
+         * we need it to the top */
+        y -= ((fb_font->height * 3) / 4);
 
-        y+=1; /* the coord is the bottom-left of the pixels offset by 1 to make
-               *   it work since fb coords are the top-left of pixels
-               */
+        /* the coord is the bottom-left of the pixels offset by 1 to make
+         *   it work since fb coords are the top-left of pixels
+         */
+        y += 1;
 
     blen = strlen(buffer);
 
@@ -154,7 +156,7 @@ static bool framebuffer_plot_text(int x, int y, const char 
*text, size_t length,
         chrp = fb_font->data + ((unsigned char)buffer[chr] * fb_font->height);
         nsfb_plot_glyph1(nsfb, &loc, (uint8_t *)chrp, 32, fstyle->foreground);
 
-        x+=fb_font->width;
+        x += fb_font->width;
 
     }
 


-- 
NetSurf Browser

_______________________________________________
netsurf-commits mailing list
netsurf-commits@netsurf-browser.org
http://vlists.pepperfish.net/cgi-bin/mailman/listinfo/netsurf-commits-netsurf-browser.org

Reply via email to