mirror of https://github.com/GNOME/gimp.git
applied gimp-quinet-000427-0, draw the straight line preview in the center
* app/paint_core.c: applied gimp-quinet-000427-0, draw the straight line preview in the center of the start and end pixels at high zoom levels. -Yosh
This commit is contained in:
parent
f750cc0809
commit
e35436426b
|
@ -1,3 +1,9 @@
|
|||
Mon May 1 10:58:34 PDT 2000 Manish Singh <yosh@gimp.org>
|
||||
|
||||
* app/paint_core.c: applied gimp-quinet-000427-0, draw the straight
|
||||
line preview in the center of the start and end pixels at high zoom
|
||||
levels.
|
||||
|
||||
2000-05-01 Michael Natterer <mitch@gimp.org>
|
||||
|
||||
* plug-ins/common/[h-p]*.c: use gimp_ui_init(). Minor cleanups like
|
||||
|
|
|
@ -628,6 +628,16 @@ paint_core_draw (Tool *tool)
|
|||
|
||||
if (tx2 > 0 && ty2 > 0)
|
||||
{
|
||||
gint offx, offy;
|
||||
|
||||
/* Adjust coords to start drawing from center of pixel if zoom > 1 */
|
||||
offx = (int) SCALEFACTOR_X (gdisp) >> 1;
|
||||
offy = (int) SCALEFACTOR_Y (gdisp) >> 1;
|
||||
tx1 += offx;
|
||||
ty1 += offy;
|
||||
tx2 += offx;
|
||||
ty2 += offy;
|
||||
|
||||
/* Draw start target */
|
||||
gdk_draw_line (gdisp->canvas->window, paint_core->core->gc,
|
||||
tx1 - (TARGET_WIDTH >> 1), ty1,
|
||||
|
|
|
@ -628,6 +628,16 @@ paint_core_draw (Tool *tool)
|
|||
|
||||
if (tx2 > 0 && ty2 > 0)
|
||||
{
|
||||
gint offx, offy;
|
||||
|
||||
/* Adjust coords to start drawing from center of pixel if zoom > 1 */
|
||||
offx = (int) SCALEFACTOR_X (gdisp) >> 1;
|
||||
offy = (int) SCALEFACTOR_Y (gdisp) >> 1;
|
||||
tx1 += offx;
|
||||
ty1 += offy;
|
||||
tx2 += offx;
|
||||
ty2 += offy;
|
||||
|
||||
/* Draw start target */
|
||||
gdk_draw_line (gdisp->canvas->window, paint_core->core->gc,
|
||||
tx1 - (TARGET_WIDTH >> 1), ty1,
|
||||
|
|
Loading…
Reference in New Issue