/src/wrappers/gdk/library/gdk_segment.e
Specman e | 71 lines | 56 code | 9 blank | 6 comment | 2 complexity | ac722ca2ad7b769e7e4c04aa52ca6531 MD5 | raw file
1indexing 2 description: "GdkSegment." 3 copyright: "[ 4 Copyright (C) 2006 eiffel-libraries team, GTK+ team 5 6 This library is free software; you can redistribute it and/or 7 modify it under the terms of the GNU Lesser General Public License 8 as published by the Free Software Foundation; either version 2.1 of 9 the License, or (at your option) any later version. 10 11 This library is distributed in the hope that it will be useful, but 12 WITHOUT ANY WARRANTY; without even the implied warranty of 13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 14 Lesser General Public License for more details. 15 16 You should have received a copy of the GNU Lesser General Public 17 License along with this library; if not, write to the Free Software 18 Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 19 02110-1301 USA 20 ]" 21 22 -- Specifies the start and end point of a line for use by the 23 -- gdk_draw_segments() function. 24 25class GDK_SEGMENT 26 27inherit G_STRUCT 28 29creation from_external_pointer 30 31feature 32 x1: INTEGER is 33 -- the x coordinate of the start point. 34 do 35 Result := get_x1 (handle) 36 end 37 y1: INTEGER is 38 -- the y coordinate of the start point. 39 do 40 Result := get_y1 (handle) 41 end 42 x2: INTEGER is 43 -- the x coordinate of the end point. 44 do 45 Result := get_x2 (handle) 46 end 47 y2: INTEGER is 48 -- the y coordinate of the end point. 49 do 50 Result := get_y2 (handle) 51 end 52 53feature -- size 54 struct_size: INTEGER is 55 external "C inline use <gtk/gtk.h>" 56 alias "sizeof(GdkSegment)" 57 end 58feature {} -- External calls 59 get_x1 (segment: POINTER): INTEGER is 60 external "C struct GdkSegment get x1 use <gdk/gdk.h>" 61 end 62 get_y1 (segment: POINTER): INTEGER is 63 external "C struct GdkSegment get y1 use <gdk/gdk.h>" 64 end 65 get_x2 (segment: POINTER): INTEGER is 66 external "C struct GdkSegment get x2 use <gdk/gdk.h>" 67 end 68 get_y2 (segment: POINTER): INTEGER is 69 external "C struct GdkSegment get y2 use <gdk/gdk.h>" 70 end 71end