alternative to assert
[gtkD.git] / gtkD / src / gtk / SeparatorToolItem.d
blob32aae931f5a7d5f95033833834fca015010d001c
1 /*
2 * This file is part of gtkD.
4 * gtkD is free software; you can redistribute it and/or modify
5 * it under the terms of the GNU Lesser General Public License as published by
6 * the Free Software Foundation; either version 2.1 of the License, or
7 * (at your option) any later version.
9 * gtkD is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU Lesser General Public License for more details.
14 * You should have received a copy of the GNU Lesser General Public License
15 * along with gtkD; if not, write to the Free Software
16 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
19 // generated automatically - do not change
20 // find conversion definition on APILookup.txt
21 // implement new conversion functionalities on the wrap.utils pakage
24 * Conversion parameters:
25 * inFile = GtkSeparatorToolItem.html
26 * outPack = gtk
27 * outFile = SeparatorToolItem
28 * strct = GtkSeparatorToolItem
29 * realStrct=
30 * ctorStrct=GtkToolItem
31 * clss = SeparatorToolItem
32 * interf =
33 * class Code: No
34 * interface Code: No
35 * template for:
36 * extend =
37 * implements:
38 * prefixes:
39 * - gtk_separator_tool_item_
40 * - gtk_
41 * omit structs:
42 * omit prefixes:
43 * omit code:
44 * imports:
45 * - gtk.ToolItem
46 * structWrap:
47 * - GtkToolItem* -> ToolItem
48 * module aliases:
49 * local aliases:
52 module gtk.SeparatorToolItem;
54 version(noAssert)
56 version(Tango)
58 import tango.io.Stdout; // use the tango loging?
62 private import gtkc.gtktypes;
64 private import gtkc.gtk;
67 private import gtk.ToolItem;
72 /**
73 * Description
74 * A GtkSeparatorItem is a GtkToolItem that separates groups of other
75 * GtkToolItems. Depending on the theme, a GtkSeparatorToolItem will
76 * often look like a vertical line on horizontally docked toolbars.
77 * If the property "expand" is TRUE and the property "draw" is FALSE, a
78 * GtkSeparatorToolItem will act as a "spring" that forces other items
79 * to the ends of the toolbar.
80 * Use gtk_separator_tool_item_new() to create a new GtkSeparatorToolItem.
82 private import gtk.ToolItem;
83 public class SeparatorToolItem : ToolItem
86 /** the main Gtk struct */
87 protected GtkSeparatorToolItem* gtkSeparatorToolItem;
90 public GtkSeparatorToolItem* getSeparatorToolItemStruct()
92 return gtkSeparatorToolItem;
96 /** the main Gtk struct as a void* */
97 protected void* getStruct()
99 return cast(void*)gtkSeparatorToolItem;
103 * Sets our main struct and passes it to the parent class
105 public this (GtkSeparatorToolItem* gtkSeparatorToolItem)
107 version(noAssert)
109 if ( gtkSeparatorToolItem is null )
111 int zero = 0;
112 version(Tango)
114 Stdout("struct gtkSeparatorToolItem is null on constructor").newline;
116 else
118 printf("struct gtkSeparatorToolItem is null on constructor");
120 zero = zero / zero;
123 else
125 assert(gtkSeparatorToolItem !is null, "struct gtkSeparatorToolItem is null on constructor");
127 super(cast(GtkToolItem*)gtkSeparatorToolItem);
128 this.gtkSeparatorToolItem = gtkSeparatorToolItem;
136 * Create a new GtkSeparatorToolItem
137 * Returns:
138 * the new GtkSeparatorToolItem
139 * Since 2.4
141 public this ()
143 // GtkToolItem* gtk_separator_tool_item_new (void);
144 this(cast(GtkSeparatorToolItem*)gtk_separator_tool_item_new() );
148 * When separator_tool_items is drawn as a vertical line, or just blank.
149 * Setting this FALSE along with gtk_tool_item_set_expand() is useful
150 * to create an item that forces following items to the end of the toolbar.
151 * item:
152 * a GtkSeparatorToolItem
153 * draw:
154 * whether separator_tool_item is drawn as a vertical line
155 * Since 2.4
157 public void setDraw(int draw)
159 // void gtk_separator_tool_item_set_draw (GtkSeparatorToolItem *item, gboolean draw);
160 gtk_separator_tool_item_set_draw(gtkSeparatorToolItem, draw);
164 * Returns whether separator_tool_item is drawn as a
165 * line, or just blank. See gtk_separator_tool_item_set_draw().
166 * item:
167 * a GtkSeparatorToolItem
168 * Returns:
169 * TRUE if separator_tool_item is drawn as a line, or just blank.
170 * Since 2.4
171 * Property Details
172 * The "draw" property
173 * "draw" gboolean : Read / Write
174 * Whether the separator is drawn, or just blank.
175 * Default value: TRUE
176 * See Also
177 * GtkToolbar
178 * The toolbar widget
179 * GtkRadioToolButton
180 * A toolbar item containing a radio
181 * button
183 public int getDraw()
185 // gboolean gtk_separator_tool_item_get_draw (GtkSeparatorToolItem *item);
186 return gtk_separator_tool_item_get_draw(gtkSeparatorToolItem);