diff options
author | Cyrille Bagard <nocbos@gmail.com> | 2010-04-18 22:30:19 (GMT) |
---|---|---|
committer | Cyrille Bagard <nocbos@gmail.com> | 2010-04-18 22:30:19 (GMT) |
commit | fb12cfc1727ba949b70a48ee042a2aec9ebbb407 (patch) | |
tree | e2c7300262312d77c9f57657e5238d269b7189c0 /src/glibext/gcodebuffer.c | |
parent | ef29fbc801e23f547b9ee7666b713bcf32d7e787 (diff) |
Defined attributes for printing binary content using GLib.
git-svn-id: svn://svn.gna.org/svn/chrysalide/trunk@153 abbe820e-26c8-41b2-8c08-b7b2b41f8b0a
Diffstat (limited to 'src/glibext/gcodebuffer.c')
-rw-r--r-- | src/glibext/gcodebuffer.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/glibext/gcodebuffer.c b/src/glibext/gcodebuffer.c index fda2c01..75c2e94 100644 --- a/src/glibext/gcodebuffer.c +++ b/src/glibext/gcodebuffer.c @@ -461,6 +461,8 @@ void g_buffer_view_draw(const GBufferView *view, const GdkEventExpose *event, Gd last = first + (event->area.height / view->line_height); if (event->area.height % view->line_height > 0) last++; + last = MIN(last, view->buffer->used > 0 ? view->buffer->used - 1 : 0); + y = event->area.y - (real_y % view->line_height); |