Commit 5a02283f authored by Benjamin Otte's avatar Benjamin Otte

API: Remove all GdkRegion API

Remove the deprecated region APIs completely from GTK.

https://bugzilla.gnome.org/show_bug.cgi?id=613284
parent 6c5dffd1
......@@ -28,7 +28,6 @@ IGNORE_HFILES= \
gdkinternals.h \
gdkprivate.h \
gdkpoly-generic.h \
gdkregion-generic.h \
keyname-table.h \
win32 \
directfb \
......
......@@ -870,43 +870,6 @@ GdkRectangle
gdk_rectangle_intersect
gdk_rectangle_union
<SUBSECTION>
GdkRegion
gdk_region_new
gdk_region_polygon
GdkFillRule
gdk_region_copy
gdk_region_rectangle
gdk_region_destroy
<SUBSECTION>
gdk_region_get_clipbox
gdk_region_get_rectangles
gdk_region_empty
gdk_region_equal
gdk_region_rect_equal
gdk_region_point_in
gdk_region_rect_in
GdkOverlapType
<SUBSECTION>
gdk_region_offset
gdk_region_shrink
gdk_region_union_with_rect
gdk_region_intersect
gdk_region_union
gdk_region_subtract
gdk_region_xor
<SUBSECTION>
GdkSpan
GdkSpanFunc
gdk_region_spans_intersect_foreach
<SUBSECTION Standard>
GDK_TYPE_OVERLAP_TYPE
GDK_TYPE_RECTANGLE
<SUBSECTION Private>
gdk_rectangle_get_type
</SECTION>
......
......@@ -195,6 +195,15 @@ and if that fails then %GDK_IMAGE_NORMAL will be used.
@Returns:
<!-- ##### FUNCTION gdk_image_get_pixels ##### -->
<para>
</para>
@image:
@Returns:
<!-- ##### FUNCTION gdk_image_put_pixel ##### -->
<para>
Sets a pixel in a #GdkImage to a given pixel value.
......
<!-- ##### SECTION Title ##### -->
Points, Rectangles and Regions
Points and Rectangles
<!-- ##### SECTION Short_Description ##### -->
Simple graphical data types
<!-- ##### SECTION Long_Description ##### -->
<para>
GDK provides the #GdkPoint, #GdkRectangle, #GdkRegion and #GdkSpan data types
for representing pixels and sets of pixels on the screen.
GDK provides the #GdkPoint and #GdkRectangle data types for representing pixels
and sets of pixels on the screen. Together with Cairo's #cairo_region_t data
type, they make up the central types for representing graphical data.
</para>
<para>
#GdkPoint is a simple structure containing an x and y coordinate of a point.
......@@ -19,13 +20,7 @@ gdk_rectangle_intersect(). To find the union of two rectangles use
gdk_rectangle_union().
</para>
<para>
#GdkRegion is an opaque data type holding a set of arbitrary pixels, and is
usually used for clipping graphical operations (see gdk_gc_set_clip_region()).
</para>
<para>
#GdkSpan is a structure holding a spanline. A spanline is a horizontal line that
is one pixel wide. It is mainly used when rasterizing other graphics primitives.
It can be intersected to regions by using gdk_region_spans_intersect_foreach().
#cairo_region_t is usually used for managing clipping of graphical operations.
</para>
<!-- ##### SECTION See_Also ##### -->
......@@ -75,239 +70,3 @@ Defines the position and size of a rectangle. It is identical to
@dest:
<!-- ##### STRUCT GdkRegion ##### -->
<para>
A GdkRegion represents a set of pixels on the screen.
</para>
<!-- ##### FUNCTION gdk_region_new ##### -->
<para>
</para>
@void:
@Returns:
<!-- ##### FUNCTION gdk_region_polygon ##### -->
<para>
</para>
@points:
@n_points:
@fill_rule:
@Returns:
<!-- ##### ENUM GdkFillRule ##### -->
<para>
The method for determining which pixels are included in a region, when
creating a #GdkRegion from a polygon.
The fill rule is only relevant for polygons which overlap themselves.
</para>
@GDK_EVEN_ODD_RULE: areas which are overlapped an odd number of times are
included in the region, while areas overlapped an even number of times are not.
@GDK_WINDING_RULE: overlapping areas are always included.
<!-- ##### FUNCTION gdk_region_copy ##### -->
<para>
</para>
@region:
@Returns:
<!-- ##### FUNCTION gdk_region_rectangle ##### -->
<para>
</para>
@rectangle:
@Returns:
<!-- ##### FUNCTION gdk_region_destroy ##### -->
<para>
</para>
@region:
<!-- ##### FUNCTION gdk_region_get_clipbox ##### -->
<para>
</para>
@region:
@rectangle:
<!-- ##### FUNCTION gdk_region_get_rectangles ##### -->
<para>
</para>
@region:
@rectangles:
@n_rectangles:
<!-- ##### FUNCTION gdk_region_empty ##### -->
<para>
</para>
@region:
@Returns:
<!-- ##### FUNCTION gdk_region_equal ##### -->
<para>
</para>
@region1:
@region2:
@Returns:
<!-- ##### FUNCTION gdk_region_rect_equal ##### -->
<para>
</para>
@region:
@rectangle:
@Returns:
<!-- ##### FUNCTION gdk_region_point_in ##### -->
<para>
</para>
@region:
@x:
@y:
@Returns:
<!-- ##### FUNCTION gdk_region_rect_in ##### -->
<para>
</para>
@region:
@rectangle:
@Returns:
<!-- ##### ENUM GdkOverlapType ##### -->
<para>
Specifies the possible values returned by gdk_region_rect_in().
</para>
@GDK_OVERLAP_RECTANGLE_IN: if the rectangle is inside the #GdkRegion.
@GDK_OVERLAP_RECTANGLE_OUT: if the rectangle is outside the #GdkRegion.
@GDK_OVERLAP_RECTANGLE_PART: if the rectangle is partly inside the #GdkRegion.
<!-- ##### FUNCTION gdk_region_offset ##### -->
<para>
</para>
@region:
@dx:
@dy:
<!-- ##### FUNCTION gdk_region_shrink ##### -->
<para>
</para>
@region:
@dx:
@dy:
<!-- ##### FUNCTION gdk_region_union_with_rect ##### -->
<para>
</para>
@region:
@rect:
<!-- ##### FUNCTION gdk_region_intersect ##### -->
<para>
</para>
@source1:
@source2:
<!-- ##### FUNCTION gdk_region_union ##### -->
<para>
</para>
@source1:
@source2:
<!-- ##### FUNCTION gdk_region_subtract ##### -->
<para>
</para>
@source1:
@source2:
<!-- ##### FUNCTION gdk_region_xor ##### -->
<para>
</para>
@source1:
@source2:
<!-- ##### STRUCT GdkSpan ##### -->
<para>
A GdkSpan represents a horizontal line of pixels starting
at the pixel with coordinates @x, @y and ending before @x + @width, @y.
</para>
@x: x coordinate of the first pixel.
@y: y coordinate of the first pixel.
@width: number of pixels in the span.
<!-- ##### USER_FUNCTION GdkSpanFunc ##### -->
<para>
This defines the type of the function passed to
gdk_region_spans_intersect_foreach().
</para>
@span: a #GdkSpan.
@data: the user data passed to gdk_region_spans_intersect_foreach().
<!-- ##### FUNCTION gdk_region_spans_intersect_foreach ##### -->
<para>
</para>
@region:
@spans:
@n_spans:
@sorted:
@function:
@data:
......@@ -387,3 +387,12 @@ Returns the current relief style of the given #GtkButton.
@Returns:
<!-- ##### FUNCTION gtk_button_get_event_window ##### -->
<para>
</para>
@button:
@Returns:
......@@ -205,7 +205,6 @@ calendar.
@calendar:
@month:
@year:
@Returns:
<!-- ##### FUNCTION gtk_calendar_select_day ##### -->
......@@ -222,7 +221,6 @@ calendar.
@calendar:
@day:
@Returns:
<!-- ##### FUNCTION gtk_calendar_unmark_day ##### -->
......@@ -231,7 +229,6 @@ calendar.
@calendar:
@day:
@Returns:
<!-- ##### FUNCTION gtk_calendar_clear_marks ##### -->
......
......@@ -785,7 +785,6 @@ Specifies the side of the entry at which an icon is placed.
@GTK_ENTRY_ICON_PRIMARY: At the beginning of the entry (depending on the text direction).
@GTK_ENTRY_ICON_SECONDARY: At the end of the entry (depending on the text direction).
@Since: 2.16
<!-- ##### FUNCTION gtk_entry_set_icon_from_pixbuf ##### -->
......
......@@ -118,3 +118,12 @@ fonts.</para></listitem>
@Returns:
<!-- ##### FUNCTION gtk_font_selection_dialog_get_font_selection ##### -->
<para>
</para>
@fsd:
@Returns:
......@@ -436,6 +436,19 @@ The #GQuark used for #GtkIconThemeError errors.
@Returns:
<!-- ##### FUNCTION gtk_icon_info_load_symbolic_for_style ##### -->
<para>
</para>
@icon_info:
@style:
@state:
@was_symbolic:
@error:
@Returns:
<!-- ##### FUNCTION gtk_icon_info_set_raw_coordinates ##### -->
<para>
......
......@@ -487,17 +487,6 @@ The #GtkNotebookPage is an opaque implementation detail of #GtkNotebook.
@Returns:
<!-- ##### FUNCTION gtk_notebook_query_tab_label_packing ##### -->
<para>
</para>
@notebook:
@child:
@expand:
@fill:
@pack_type:
<!-- ##### FUNCTION gtk_notebook_set_menu_label ##### -->
<para>
</para>
......@@ -525,17 +514,6 @@ The #GtkNotebookPage is an opaque implementation detail of #GtkNotebook.
@tab_label:
<!-- ##### FUNCTION gtk_notebook_set_tab_label_packing ##### -->
<para>
</para>
@notebook:
@child:
@expand:
@fill:
@pack_type:
<!-- ##### FUNCTION gtk_notebook_set_tab_label_text ##### -->
<para>
</para>
......
......@@ -89,6 +89,11 @@ and should be accessed using the functions below.
</para>
<!-- ##### ARG GtkProgressBar:show-text ##### -->
<para>
</para>
<!-- ##### ARG GtkProgressBar:text ##### -->
<para>
......@@ -141,32 +146,34 @@ Creates a new #GtkProgressBar.
@pbar:
<!-- ##### FUNCTION gtk_progress_bar_set_text ##### -->
<!-- ##### FUNCTION gtk_progress_bar_set_fraction ##### -->
<para>
</para>
@pbar:
@text:
@fraction:
<!-- ##### FUNCTION gtk_progress_bar_set_fraction ##### -->
<!-- ##### FUNCTION gtk_progress_bar_get_fraction ##### -->
<para>
</para>
@pbar:
@fraction:
@Returns:
<!-- ##### FUNCTION gtk_progress_bar_set_pulse_step ##### -->
<!-- ##### ENUM GtkProgressBarOrientation ##### -->
<para>
An enumeration representing possible orientations and growth
directions for the visible progress bar.
</para>
@pbar:
@fraction:
@GTK_PROGRESS_LEFT_TO_RIGHT: A horizontal progress bar growing from left to right.
@GTK_PROGRESS_RIGHT_TO_LEFT: A horizontal progress bar growing from right to left.
@GTK_PROGRESS_BOTTOM_TO_TOP: A vertical progress bar growing from bottom to top.
@GTK_PROGRESS_TOP_TO_BOTTOM: A vertical progress bar growing from top to bottom.
<!-- ##### FUNCTION gtk_progress_bar_set_orientation ##### -->
<para>
......@@ -177,27 +184,25 @@ Creates a new #GtkProgressBar.
@orientation:
<!-- ##### FUNCTION gtk_progress_bar_set_ellipsize ##### -->
<!-- ##### FUNCTION gtk_progress_bar_get_orientation ##### -->
<para>
</para>
@pbar:
@mode:
@Returns:
<!-- ##### ENUM GtkProgressBarOrientation ##### -->
<!-- ##### FUNCTION gtk_progress_bar_set_show_text ##### -->
<para>
An enumeration representing possible orientations and growth
directions for the visible progress bar.
</para>
@GTK_PROGRESS_LEFT_TO_RIGHT: A horizontal progress bar growing from left to right.
@GTK_PROGRESS_RIGHT_TO_LEFT: A horizontal progress bar growing from right to left.
@GTK_PROGRESS_BOTTOM_TO_TOP: A vertical progress bar growing from bottom to top.
@GTK_PROGRESS_TOP_TO_BOTTOM: A vertical progress bar growing from top to bottom.
@pbar:
@show_text:
<!-- ##### FUNCTION gtk_progress_bar_get_text ##### -->
<!-- ##### FUNCTION gtk_progress_bar_get_show_text ##### -->
<para>
</para>
......@@ -206,16 +211,16 @@ directions for the visible progress bar.
@Returns:
<!-- ##### FUNCTION gtk_progress_bar_get_fraction ##### -->
<!-- ##### FUNCTION gtk_progress_bar_set_text ##### -->
<para>
</para>
@pbar:
@Returns:
@text:
<!-- ##### FUNCTION gtk_progress_bar_get_pulse_step ##### -->
<!-- ##### FUNCTION gtk_progress_bar_get_text ##### -->
<para>
</para>
......@@ -224,13 +229,13 @@ directions for the visible progress bar.
@Returns:
<!-- ##### FUNCTION gtk_progress_bar_get_orientation ##### -->
<!-- ##### FUNCTION gtk_progress_bar_set_ellipsize ##### -->
<para>
</para>
@pbar:
@Returns:
@mode:
<!-- ##### FUNCTION gtk_progress_bar_get_ellipsize ##### -->
......@@ -242,11 +247,21 @@ directions for the visible progress bar.
@Returns:
<!-- ##### ENUM GtkProgressBarStyle ##### -->
<!-- ##### FUNCTION gtk_progress_bar_set_pulse_step ##### -->
<para>
An enumeration representing the styles for drawing the progress bar.
</para>
@GTK_PROGRESS_CONTINUOUS: The progress bar grows in a smooth, continuous manner.
@GTK_PROGRESS_DISCRETE: The progress bar grows in discrete, visible blocks.
@pbar:
@fraction:
<!-- ##### FUNCTION gtk_progress_bar_get_pulse_step ##### -->
<para>
</para>
@pbar:
@Returns:
......@@ -151,6 +151,16 @@ If you need to change a table's size <emphasis>after</emphasis> it has been crea
@columns: The new number of columns.
<!-- ##### FUNCTION gtk_table_get_size ##### -->
<para>
</para>
@table:
@rows:
@columns:
<!-- ##### FUNCTION gtk_table_attach ##### -->
<para>
Adds a widget to a table. The number of 'cells' that a widget will occupy is
......
......@@ -62,6 +62,15 @@ Limit the effect of grabs
@Returns:
<!-- ##### FUNCTION gtk_window_group_get_current_grab ##### -->
<para>
</para>
@window_group:
@Returns:
<!-- ##### FUNCTION gtk_window_group_get_current_device_grab ##### -->
<para>
......
......@@ -92,7 +92,6 @@ gdk_public_h_sources = \
gdkpixmap.h \
gdkprivate.h \
gdkproperty.h \
gdkregion.h \
gdkrgb.h \
gdkscreen.h \
gdkselection.h \
......@@ -112,8 +111,7 @@ gdk_private_headers = \
gdkinternals.h \
gdkdeviceprivate.h \
gdkintl.h \
gdkpoly-generic.h \
gdkregion-generic.h
gdkpoly-generic.h
gdk_c_sources = \
$(medialib_sources) \
......@@ -139,9 +137,7 @@ gdk_c_sources = \
gdkpixbuf-drawable.c \
gdkpixbuf-render.c \
gdkpixmap.c \
gdkpolyreg-generic.c \
gdkrectangle.c \
gdkregion-generic.c \
gdkrgb.c \
gdkscreen.c \
gdkselection.c \
......
......@@ -49,7 +49,6 @@
#include <gdk/gdkpixbuf.h>
#include <gdk/gdkpixmap.h>
#include <gdk/gdkproperty.h>
#include <gdk/gdkregion.h>
#include <gdk/gdkrgb.h>
#include <gdk/gdkscreen.h>
#include <gdk/gdkselection.h>
......
......@@ -258,7 +258,6 @@ gdk_extension_mode_get_type G_GNUC_CONST
gdk_event_mask_get_type G_GNUC_CONST
gdk_event_type_get_type G_GNUC_CONST
gdk_fill_get_type G_GNUC_CONST
gdk_fill_rule_get_type G_GNUC_CONST
gdk_filter_return_get_type G_GNUC_CONST
gdk_function_get_type G_GNUC_CONST
gdk_grab_ownership_get_type G_GNUC_CONST
......@@ -268,7 +267,6 @@ gdk_join_style_get_type G_GNUC_CONST
gdk_line_style_get_type G_GNUC_CONST
gdk_modifier_type_get_type G_GNUC_CONST
gdk_notify_type_get_type G_GNUC_CONST
gdk_overlap_type_get_type G_GNUC_CONST
gdk_owner_change_get_type G_GNUC_CONST
gdk_property_state_get_type G_GNUC_CONST
gdk_prop_mode_get_type G_GNUC_CONST
......@@ -975,40 +973,6 @@ gdk_pixmap_lookup_for_display
#endif
#endif
#if IN_HEADER(__GDK_REGION_H__)
#if IN_FILE(__GDK_REGION_GENERIC_C__)
#ifndef GDK_DISABLE_DEPRECATED
gdk_region_copy
gdk_region_destroy
gdk_region_empty
gdk_region_equal
gdk_region_rect_equal
gdk_region_get_clipbox
gdk_region_get_rectangles
gdk_region_intersect
gdk_region_new
gdk_region_offset
gdk_region_point_in
gdk_region_rectangle
gdk_region_rect_in
gdk_region_shrink
gdk_region_spans_intersect_foreach
gdk_region_subtract
gdk_region_union
gdk_region_union_with_rect
gdk_region_xor
#endif
#endif
#endif
#if IN_HEADER(__GDK_REGION_H__)
#if IN_FILE(__GDK_POLYREG_GENERIC_C__)
#ifndef GDK_DISABLE_DEPRECATED
gdk_region_polygon
#endif
#endif
#endif
#if IN_HEADER(__GDK_RGB_H__)
#if IN_FILE(__GDK_RGB_C__)
gdk_rgb_cmap_free
......
/* $TOG: PolyReg.c /main/15 1998/02/06 17:47:08 kaleb $ */
/************************************************************************
Copyright 1987, 1998 The Open Group
All Rights Reserved.
The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
Except as contained in this notice, the name of The Open Group shall not be