GNOME Bugzilla – Bug 110014
Display problems with selection border and image border
Last modified: 2009-08-15 18:40:50 UTC
Under certain circumstances, the border of the selection is wrong. It also happens to the image border. How to reproduce: 1. Create a 10x4000 RGB image. 2. Select all. 3. Shrink selection by 1 pixel. 4. Zoom to 9:1. 5. Scroll to the top of the image. Both lines show strange behaviours now. Additional comments: Seems to be a GDK (or X) problem that shows up when the size of the line to be drawn is beyond 32767 pixels. It can be easily worked around; the following patch solves both issues.
Created attachment 15485 [details] [review] Patch to work around the selection lines problem.
2003-04-05 Sven Neumann <sven@gimp.org> * app/display/gimpdisplayshell-selection.c: applied a patch from Pedro Gimeno that fixes incorrect drawing of the selection border caused by overflowing 16bit X coordinates (bug #110014).
Created attachment 15518 [details] [review] Further fixes to the same problem, this time when dragging the selection
2003-04-07 Sven Neumann <sven@gimp.org> * app/tools/gimpeditselectiontool.c (selection_transform_segs): another patch from Pedro Gimeno that addresses problems displaying the selection border (bug #110014).
Fix merged into STABLE: 2003-05-26 Pedro Gimeno * app/selection.c (selection_transform_segs) * app/edit_selection.c (selection_transform_segs, edit_selection_draw): Merged last bit of the fix for bug #17904 from HEAD. Also merged fix for bug #110014. * app/rect_select.c (rect_select_draw): Added more clampings to avoid 16-bit overflows like those in bug #110014. The fix to HEAD has been also improved to handle a previously unhandled case (selection spilling off the layer limit): 2003-05-26 Pedro Gimeno * app/display/gimpdisplayshell-selection.c (selection_transform_segs): Perform the clamping that fixes bug #110014 here instead of in the callers. Solves a rare case that was not properly handled before. (selection_render_points, selection_generate_segs): Remove the clamping code from here. * app/tools/gimpdrawtool.c (gimp_draw_tool_draw_rectangle): More clampings to avoid overflow of 16-bit coordinates.
The fix is part of the stable release 1.2.5. Closing this bug.