2006-12-09 13:33:38 -08:00
|
|
|
/* GIMP - The GNU Image Manipulation Program
|
1997-11-24 14:05:25 -08:00
|
|
|
* Copyright (C) 1995 Spencer Kimball and Peter Mattis
|
|
|
|
|
*
|
2009-01-17 14:28:01 -08:00
|
|
|
* This program is free software: you can redistribute it and/or modify
|
1997-11-24 14:05:25 -08:00
|
|
|
* it under the terms of the GNU General Public License as published by
|
2009-01-17 14:28:01 -08:00
|
|
|
* the Free Software Foundation; either version 3 of the License, or
|
1997-11-24 14:05:25 -08:00
|
|
|
* (at your option) any later version.
|
|
|
|
|
*
|
|
|
|
|
* This program is distributed in the hope that it will be useful,
|
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
|
* GNU General Public License for more details.
|
|
|
|
|
*
|
|
|
|
|
* You should have received a copy of the GNU General Public License
|
2018-07-11 14:47:19 -07:00
|
|
|
* along with this program. If not, see <https://www.gnu.org/licenses/>.
|
1997-11-24 14:05:25 -08:00
|
|
|
*/
|
2000-12-29 07:22:01 -08:00
|
|
|
|
2001-10-31 13:20:09 -08:00
|
|
|
#ifndef __GIMP_DISPLAY_SHELL_SCALE_H__
|
|
|
|
|
#define __GIMP_DISPLAY_SHELL_SCALE_H__
|
1997-11-24 14:05:25 -08:00
|
|
|
|
|
|
|
|
|
2016-01-05 10:18:40 -08:00
|
|
|
gboolean gimp_display_shell_scale_revert (GimpDisplayShell *shell);
|
|
|
|
|
gboolean gimp_display_shell_scale_can_revert (GimpDisplayShell *shell);
|
|
|
|
|
void gimp_display_shell_scale_save_revert_values (GimpDisplayShell *shell);
|
2010-02-03 10:50:46 -08:00
|
|
|
|
2016-01-05 10:18:40 -08:00
|
|
|
void gimp_display_shell_scale_set_dot_for_dot (GimpDisplayShell *shell,
|
|
|
|
|
gboolean dot_for_dot);
|
2010-02-03 10:50:46 -08:00
|
|
|
|
2016-01-05 10:18:40 -08:00
|
|
|
void gimp_display_shell_scale_get_image_size (GimpDisplayShell *shell,
|
|
|
|
|
gint *w,
|
|
|
|
|
gint *h);
|
2016-07-24 06:01:12 -07:00
|
|
|
void gimp_display_shell_scale_get_image_bounds (GimpDisplayShell *shell,
|
|
|
|
|
gint *x,
|
|
|
|
|
gint *y,
|
|
|
|
|
gint *w,
|
|
|
|
|
gint *h);
|
2016-01-05 10:18:40 -08:00
|
|
|
gboolean gimp_display_shell_scale_image_is_within_viewport
|
|
|
|
|
(GimpDisplayShell *shell,
|
|
|
|
|
gboolean *horizontally,
|
|
|
|
|
gboolean *vertically);
|
2010-02-03 10:50:46 -08:00
|
|
|
|
2016-01-05 10:18:40 -08:00
|
|
|
void gimp_display_shell_scale_update (GimpDisplayShell *shell);
|
2016-01-05 09:48:22 -08:00
|
|
|
|
2016-01-05 10:18:40 -08:00
|
|
|
void gimp_display_shell_scale (GimpDisplayShell *shell,
|
|
|
|
|
GimpZoomType zoom_type,
|
|
|
|
|
gdouble scale,
|
|
|
|
|
GimpZoomFocus zoom_focus);
|
|
|
|
|
void gimp_display_shell_scale_to_rectangle (GimpDisplayShell *shell,
|
|
|
|
|
GimpZoomType zoom_type,
|
|
|
|
|
gdouble x,
|
|
|
|
|
gdouble y,
|
|
|
|
|
gdouble width,
|
|
|
|
|
gdouble height,
|
|
|
|
|
gboolean resize_window);
|
|
|
|
|
void gimp_display_shell_scale_fit_in (GimpDisplayShell *shell);
|
|
|
|
|
void gimp_display_shell_scale_fill (GimpDisplayShell *shell);
|
|
|
|
|
void gimp_display_shell_scale_by_values (GimpDisplayShell *shell,
|
|
|
|
|
gdouble scale,
|
|
|
|
|
gint offset_x,
|
|
|
|
|
gint offset_y,
|
|
|
|
|
gboolean resize_window);
|
2010-02-03 10:50:46 -08:00
|
|
|
|
2016-11-16 05:41:30 -08:00
|
|
|
void gimp_display_shell_scale_drag (GimpDisplayShell *shell,
|
2018-06-04 02:42:02 -07:00
|
|
|
gdouble start_x,
|
|
|
|
|
gdouble start_y,
|
2016-11-16 05:41:30 -08:00
|
|
|
gdouble delta_x,
|
|
|
|
|
gdouble delta_y);
|
|
|
|
|
|
2016-01-05 10:18:40 -08:00
|
|
|
void gimp_display_shell_scale_shrink_wrap (GimpDisplayShell *shell,
|
|
|
|
|
gboolean grow_only);
|
|
|
|
|
void gimp_display_shell_scale_resize (GimpDisplayShell *shell,
|
|
|
|
|
gboolean resize_window,
|
|
|
|
|
gboolean grow_only);
|
|
|
|
|
void gimp_display_shell_set_initial_scale (GimpDisplayShell *shell,
|
|
|
|
|
gdouble scale,
|
|
|
|
|
gint *display_width,
|
|
|
|
|
gint *display_height);
|
|
|
|
|
|
2016-07-19 08:47:59 -07:00
|
|
|
void gimp_display_shell_get_rotated_scale (GimpDisplayShell *shell,
|
|
|
|
|
gdouble *scale_x,
|
|
|
|
|
gdouble *scale_y);
|
2016-01-05 10:18:40 -08:00
|
|
|
|
|
|
|
|
/* debug API for testing */
|
|
|
|
|
|
|
|
|
|
void gimp_display_shell_push_zoom_focus_pointer_pos (GimpDisplayShell *shell,
|
|
|
|
|
gint x,
|
|
|
|
|
gint y);
|
2008-08-14 12:23:28 -07:00
|
|
|
|
2001-10-31 13:20:09 -08:00
|
|
|
|
|
|
|
|
#endif /* __GIMP_DISPLAY_SHELL_SCALE_H__ */
|