PageRenderTime 24ms CodeModel.GetById 20ms app.highlight 1ms RepoModel.GetById 1ms app.codeStats 1ms

/src/wrappers/gtk/library/gtk_unit.e

http://github.com/tybor/Liberty
Specman e | 58 lines | 44 code | 10 blank | 4 comment | 2 complexity | 3a91a0288291eaf5ae667bcbfef77df7 MD5 | raw file
 1indexing
 2	description: "enum GtkUnit"
 3	copyright: "[
 4					Copyright (C) 2007 Paolo Redaelli, 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
22deferred class GTK_UNIT
23
24inherit ANY undefine is_equal, copy end
25
26feature  -- enum
27	is_valid_gtk_unit (a_unit: INTEGER): BOOLEAN is
28		do	
29			Result:=((a_unit = gtk_unit_pixel) or else
30						(a_unit = gtk_unit_points) or else
31						(a_unit = gtk_unit_inch) or else
32						(a_unit = gtk_unit_mm))
33		end
34
35	gtk_unit_pixel: INTEGER is
36			-- GTK_UNIT_PIXEL
37		external "C macro use <gtk/gtk.h>"
38		alias "GTK_UNIT_PIXEL"
39		end
40
41	gtk_unit_points: INTEGER is
42			-- GTK_UNIT_POINTS
43		external "C macro use <gtk/gtk.h>"
44		alias "GTK_UNIT_POINTS"
45		end
46
47	gtk_unit_inch: INTEGER is
48			-- GTK_UNIT_INCH
49		external "C macro use <gtk/gtk.h>"
50		alias "GTK_UNIT_INCH"
51		end
52
53	gtk_unit_mm: INTEGER is
54			-- GTK_UNIT_MM
55		external "C macro use <gtk/gtk.h>"
56		alias "GTK_UNIT_MM"
57		end
58end