Gitweb links:
...log
http://git.netsurf-browser.org/netsurf.git/shortlog/f64a22c228e4fc58c1d0b287fa8fe633db79dca6
...commit
http://git.netsurf-browser.org/netsurf.git/commit/f64a22c228e4fc58c1d0b287fa8fe633db79dca6
...tree
http://git.netsurf-browser.org/netsurf.git/tree/f64a22c228e4fc58c1d0b287fa8fe633db79dca6
The branch, master has been updated
via f64a22c228e4fc58c1d0b287fa8fe633db79dca6 (commit)
via 8e6cf1e1d40f3f6ae4cebb8d101fc10b6a8abc71 (commit)
from 2f466751ca15ee334bc8fbb694dacc2ed33e9bd2 (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/commit/?id=f64a22c228e4fc58c1d0b287fa8fe633db79dca6
commit f64a22c228e4fc58c1d0b287fa8fe633db79dca6
Author: Michael Drake <[email protected]>
Commit: Michael Drake <[email protected]>
CSS hints: Ensure length and unit are initialised for vertical-align.
diff --git a/content/handlers/css/hints.c b/content/handlers/css/hints.c
index 08fe438..3a15f8e 100644
--- a/content/handlers/css/hints.c
+++ b/content/handlers/css/hints.c
@@ -748,6 +748,8 @@ static void css_hint_vertical_align_table_cells(
corestring_dom_valign, &attr);
if (err == DOM_NO_ERR && attr != NULL) {
+ hint->data.length.value = 0;
+ hint->data.length.unit = CSS_UNIT_PX;
if (dom_string_caseless_lwc_isequal(attr,
corestring_lwc_top)) {
hint->prop = CSS_PROP_VERTICAL_ALIGN;
commitdiff
http://git.netsurf-browser.org/netsurf.git/commit/?id=8e6cf1e1d40f3f6ae4cebb8d101fc10b6a8abc71
commit 8e6cf1e1d40f3f6ae4cebb8d101fc10b6a8abc71
Author: Michael Drake <[email protected]>
Commit: Michael Drake <[email protected]>
Framebuffer: Don't create 0x0 bitmaps if content width is 0.
diff --git a/frontends/framebuffer/bitmap.c b/frontends/framebuffer/bitmap.c
index 59f68bb..1fc9f46 100644
--- a/frontends/framebuffer/bitmap.c
+++ b/frontends/framebuffer/bitmap.c
@@ -286,11 +286,11 @@ bitmap_render(struct bitmap *bitmap,
NSLOG(netsurf, INFO, "width %d, height %d", width, height);
/* Calculate size of buffer to render the content into */
- /* We get the width from the content width, unless it exceeds 1024,
- * in which case we use 1024. This means we never create excessively
- * large render buffers for huge contents, which would eat memory and
- * cripple performance. */
- cwidth = min(content_get_width(content), 1024);
+ /* We get the width from the largest of the bitmap width and the content
+ * width, unless it exceeds 1024, in which case we use 1024. This means
+ * we never create excessively large render buffers for huge contents,
+ * which would eat memory and cripple performance. */
+ cwidth = max(width, min(content_get_width(content), 1024));
/* The height is set in proportion with the width, according to the
* aspect ratio of the required thumbnail. */
cheight = ((cwidth * height) + (width / 2)) / width;
-----------------------------------------------------------------------
Summary of changes:
content/handlers/css/hints.c | 2 ++
frontends/framebuffer/bitmap.c | 10 +++++-----
2 files changed, 7 insertions(+), 5 deletions(-)
diff --git a/content/handlers/css/hints.c b/content/handlers/css/hints.c
index 08fe438..3a15f8e 100644
--- a/content/handlers/css/hints.c
+++ b/content/handlers/css/hints.c
@@ -748,6 +748,8 @@ static void css_hint_vertical_align_table_cells(
corestring_dom_valign, &attr);
if (err == DOM_NO_ERR && attr != NULL) {
+ hint->data.length.value = 0;
+ hint->data.length.unit = CSS_UNIT_PX;
if (dom_string_caseless_lwc_isequal(attr,
corestring_lwc_top)) {
hint->prop = CSS_PROP_VERTICAL_ALIGN;
diff --git a/frontends/framebuffer/bitmap.c b/frontends/framebuffer/bitmap.c
index 59f68bb..1fc9f46 100644
--- a/frontends/framebuffer/bitmap.c
+++ b/frontends/framebuffer/bitmap.c
@@ -286,11 +286,11 @@ bitmap_render(struct bitmap *bitmap,
NSLOG(netsurf, INFO, "width %d, height %d", width, height);
/* Calculate size of buffer to render the content into */
- /* We get the width from the content width, unless it exceeds 1024,
- * in which case we use 1024. This means we never create excessively
- * large render buffers for huge contents, which would eat memory and
- * cripple performance. */
- cwidth = min(content_get_width(content), 1024);
+ /* We get the width from the largest of the bitmap width and the content
+ * width, unless it exceeds 1024, in which case we use 1024. This means
+ * we never create excessively large render buffers for huge contents,
+ * which would eat memory and cripple performance. */
+ cwidth = max(width, min(content_get_width(content), 1024));
/* The height is set in proportion with the width, according to the
* aspect ratio of the required thumbnail. */
cheight = ((cwidth * height) + (width / 2)) / width;
--
NetSurf Browser
_______________________________________________
netsurf-commits mailing list
[email protected]
http://listmaster.pepperfish.net/cgi-bin/mailman/listinfo/netsurf-commits-netsurf-browser.org