Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPaul D'Pong2020-07-22 20:42:43 +0000
committerAlexander Kurtakov2020-07-25 08:36:47 +0000
commitc768eda6ffd5c4bcf8ea6a9a4ea5972d1e87e655 (patch)
tree0885a0205963336046e86554c6dec49a55b22204 /bundles/org.eclipse.swt/Eclipse SWT PI
parente9c6d1cee00a5a373a502ce5862fa8b613486b29 (diff)
downloadeclipse.platform.swt-c768eda6ffd5c4bcf8ea6a9a4ea5972d1e87e655.tar.gz
eclipse.platform.swt-c768eda6ffd5c4bcf8ea6a9a4ea5972d1e87e655.tar.xz
eclipse.platform.swt-c768eda6ffd5c4bcf8ea6a9a4ea5972d1e87e655.zip
Bug 565435 - [GTK4] Reimplement GtkToolbar with GtkBox due to removal
Removed from GTK4: gtk_tool_button_new gtk_tool_button_set_icon_widget gtk_tool_button_set_label_widget gtk_tool_button_set_use_underline gtk_toggle_tool_button_get_active gtk_toggle_tool_button_new gtk_toggle_tool_button_set_active gtk_tool_item_get_proxy_menu_item gtk_tool_item_retrieve_proxy_menu_item gtk_tool_item_set_is_important gtk_tool_item_set_homogeneous gtk_tool_item_set_proxy_menu_item gtk_toolbar_insert gtk_toolbar_new gtk_toolbar_set_show_arrow gtk_toolbar_set_style gtk_toolbar_set_icon_size gtk_menu_tool_button_new gtk_separator_tool_item_new gtk_separator_tool_item_set_draw Added: gtk_button_set_child gtk_button_set_use_underline gtk_box_append gtk_box_prepend gtk_box_insert_child_after All of the tool versions of GtkWidgets (toggle tool button) has been replaced with the base GtkWidget. The toolbar has been replaced with a GtkBox. Work to be done after compilation passes is implementing the proxy/overflow menu + image/label handling for the ToolItems. Change-Id: Ic0ef5c786d10953f21790f5f34bd262f746d4fd7 Signed-off-by: Paul D'Pong <sdamrong@redhat.com>
Diffstat (limited to 'bundles/org.eclipse.swt/Eclipse SWT PI')
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/os.c122
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/os.h22
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/os_stats.c9
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/os_stats.h9
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT PI/gtk/org/eclipse/swt/internal/gtk/GTK.java156
5 files changed, 230 insertions, 88 deletions
diff --git a/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/os.c b/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/os.c
index c543708839..52a04cd9f6 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/os.c
+++ b/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/os.c
@@ -3790,6 +3790,42 @@ JNIEXPORT void JNICALL GTK_NATIVE(gtk_1border_1free)
}
#endif
+#ifndef NO_gtk_1box_1append
+JNIEXPORT void JNICALL GTK_NATIVE(gtk_1box_1append)
+ (JNIEnv *env, jclass that, jlong arg0, jlong arg1)
+{
+ GTK_NATIVE_ENTER(env, that, gtk_1box_1append_FUNC);
+/*
+ gtk_box_append((GtkBox *)arg0, (GtkWidget *)arg1);
+*/
+ {
+ GTK_LOAD_FUNCTION(fp, gtk_box_append)
+ if (fp) {
+ ((void (CALLING_CONVENTION*)(GtkBox *, GtkWidget *))fp)((GtkBox *)arg0, (GtkWidget *)arg1);
+ }
+ }
+ GTK_NATIVE_EXIT(env, that, gtk_1box_1append_FUNC);
+}
+#endif
+
+#ifndef NO_gtk_1box_1insert_1child_1after
+JNIEXPORT void JNICALL GTK_NATIVE(gtk_1box_1insert_1child_1after)
+ (JNIEnv *env, jclass that, jlong arg0, jlong arg1, jlong arg2)
+{
+ GTK_NATIVE_ENTER(env, that, gtk_1box_1insert_1child_1after_FUNC);
+/*
+ gtk_box_insert_child_after((GtkBox *)arg0, (GtkWidget *)arg1, (GtkWidget *)arg2);
+*/
+ {
+ GTK_LOAD_FUNCTION(fp, gtk_box_insert_child_after)
+ if (fp) {
+ ((void (CALLING_CONVENTION*)(GtkBox *, GtkWidget *, GtkWidget *))fp)((GtkBox *)arg0, (GtkWidget *)arg1, (GtkWidget *)arg2);
+ }
+ }
+ GTK_NATIVE_EXIT(env, that, gtk_1box_1insert_1child_1after_FUNC);
+}
+#endif
+
#ifndef NO_gtk_1box_1new
JNIEXPORT jlong JNICALL GTK_NATIVE(gtk_1box_1new)
(JNIEnv *env, jclass that, jint arg0, jint arg1)
@@ -3802,39 +3838,39 @@ JNIEXPORT jlong JNICALL GTK_NATIVE(gtk_1box_1new)
}
#endif
-#ifndef NO_gtk_1box_1pack_1end__JJ
-JNIEXPORT void JNICALL GTK_NATIVE(gtk_1box_1pack_1end__JJ)
- (JNIEnv *env, jclass that, jlong arg0, jlong arg1)
+#ifndef NO_gtk_1box_1pack_1end
+JNIEXPORT void JNICALL GTK_NATIVE(gtk_1box_1pack_1end)
+ (JNIEnv *env, jclass that, jlong arg0, jlong arg1, jboolean arg2, jboolean arg3, jint arg4)
{
- GTK_NATIVE_ENTER(env, that, gtk_1box_1pack_1end__JJ_FUNC);
+ GTK_NATIVE_ENTER(env, that, gtk_1box_1pack_1end_FUNC);
/*
- gtk_box_pack_end((GtkBox *)arg0, (GtkWidget *)arg1);
+ gtk_box_pack_end((GtkBox *)arg0, (GtkWidget *)arg1, (gboolean)arg2, (gboolean)arg3, (guint)arg4);
*/
{
GTK_LOAD_FUNCTION(fp, gtk_box_pack_end)
if (fp) {
- ((void (CALLING_CONVENTION*)(GtkBox *, GtkWidget *))fp)((GtkBox *)arg0, (GtkWidget *)arg1);
+ ((void (CALLING_CONVENTION*)(GtkBox *, GtkWidget *, gboolean, gboolean, guint))fp)((GtkBox *)arg0, (GtkWidget *)arg1, (gboolean)arg2, (gboolean)arg3, (guint)arg4);
}
}
- GTK_NATIVE_EXIT(env, that, gtk_1box_1pack_1end__JJ_FUNC);
+ GTK_NATIVE_EXIT(env, that, gtk_1box_1pack_1end_FUNC);
}
#endif
-#ifndef NO_gtk_1box_1pack_1end__JJZZI
-JNIEXPORT void JNICALL GTK_NATIVE(gtk_1box_1pack_1end__JJZZI)
- (JNIEnv *env, jclass that, jlong arg0, jlong arg1, jboolean arg2, jboolean arg3, jint arg4)
+#ifndef NO_gtk_1box_1prepend
+JNIEXPORT void JNICALL GTK_NATIVE(gtk_1box_1prepend)
+ (JNIEnv *env, jclass that, jlong arg0, jlong arg1)
{
- GTK_NATIVE_ENTER(env, that, gtk_1box_1pack_1end__JJZZI_FUNC);
+ GTK_NATIVE_ENTER(env, that, gtk_1box_1prepend_FUNC);
/*
- gtk_box_pack_end((GtkBox *)arg0, (GtkWidget *)arg1, (gboolean)arg2, (gboolean)arg3, (guint)arg4);
+ gtk_box_prepend((GtkBox *)arg0, (GtkWidget *)arg1);
*/
{
- GTK_LOAD_FUNCTION(fp, gtk_box_pack_end)
+ GTK_LOAD_FUNCTION(fp, gtk_box_prepend)
if (fp) {
- ((void (CALLING_CONVENTION*)(GtkBox *, GtkWidget *, gboolean, gboolean, guint))fp)((GtkBox *)arg0, (GtkWidget *)arg1, (gboolean)arg2, (gboolean)arg3, (guint)arg4);
+ ((void (CALLING_CONVENTION*)(GtkBox *, GtkWidget *))fp)((GtkBox *)arg0, (GtkWidget *)arg1);
}
}
- GTK_NATIVE_EXIT(env, that, gtk_1box_1pack_1end__JJZZI_FUNC);
+ GTK_NATIVE_EXIT(env, that, gtk_1box_1prepend_FUNC);
}
#endif
@@ -3843,7 +3879,15 @@ JNIEXPORT void JNICALL GTK_NATIVE(gtk_1box_1reorder_1child)
(JNIEnv *env, jclass that, jlong arg0, jlong arg1, jint arg2)
{
GTK_NATIVE_ENTER(env, that, gtk_1box_1reorder_1child_FUNC);
+/*
gtk_box_reorder_child((GtkBox *)arg0, (GtkWidget *)arg1, (gint)arg2);
+*/
+ {
+ GTK_LOAD_FUNCTION(fp, gtk_box_reorder_child)
+ if (fp) {
+ ((void (CALLING_CONVENTION*)(GtkBox *, GtkWidget *, gint))fp)((GtkBox *)arg0, (GtkWidget *)arg1, (gint)arg2);
+ }
+ }
GTK_NATIVE_EXIT(env, that, gtk_1box_1reorder_1child_FUNC);
}
#endif
@@ -3916,6 +3960,24 @@ JNIEXPORT jlong JNICALL GTK_NATIVE(gtk_1button_1new)
}
#endif
+#ifndef NO_gtk_1button_1set_1child
+JNIEXPORT void JNICALL GTK_NATIVE(gtk_1button_1set_1child)
+ (JNIEnv *env, jclass that, jlong arg0, jlong arg1)
+{
+ GTK_NATIVE_ENTER(env, that, gtk_1button_1set_1child_FUNC);
+/*
+ gtk_button_set_child((GtkButton *)arg0, (GtkWidget *)arg1);
+*/
+ {
+ GTK_LOAD_FUNCTION(fp, gtk_button_set_child)
+ if (fp) {
+ ((void (CALLING_CONVENTION*)(GtkButton *, GtkWidget *))fp)((GtkButton *)arg0, (GtkWidget *)arg1);
+ }
+ }
+ GTK_NATIVE_EXIT(env, that, gtk_1button_1set_1child_FUNC);
+}
+#endif
+
#ifndef NO_gtk_1button_1set_1image
JNIEXPORT void JNICALL GTK_NATIVE(gtk_1button_1set_1image)
(JNIEnv *env, jclass that, jlong arg0, jlong arg1)
@@ -3934,6 +3996,16 @@ JNIEXPORT void JNICALL GTK_NATIVE(gtk_1button_1set_1image)
}
#endif
+#ifndef NO_gtk_1button_1set_1use_1underline
+JNIEXPORT void JNICALL GTK_NATIVE(gtk_1button_1set_1use_1underline)
+ (JNIEnv *env, jclass that, jlong arg0, jboolean arg1)
+{
+ GTK_NATIVE_ENTER(env, that, gtk_1button_1set_1use_1underline_FUNC);
+ gtk_button_set_use_underline((GtkButton *)arg0, arg1);
+ GTK_NATIVE_EXIT(env, that, gtk_1button_1set_1use_1underline_FUNC);
+}
+#endif
+
#ifndef NO_gtk_1calendar_1clear_1marks
JNIEXPORT void JNICALL GTK_NATIVE(gtk_1calendar_1clear_1marks)
(JNIEnv *env, jclass that, jlong arg0)
@@ -7082,6 +7154,18 @@ JNIEXPORT jlong JNICALL GTK_NATIVE(gtk_1menu_1bar_1new)
}
#endif
+#ifndef NO_gtk_1menu_1button_1new
+JNIEXPORT jlong JNICALL GTK_NATIVE(gtk_1menu_1button_1new)
+ (JNIEnv *env, jclass that)
+{
+ jlong rc = 0;
+ GTK_NATIVE_ENTER(env, that, gtk_1menu_1button_1new_FUNC);
+ rc = (jlong)gtk_menu_button_new();
+ GTK_NATIVE_EXIT(env, that, gtk_1menu_1button_1new_FUNC);
+ return rc;
+}
+#endif
+
#ifndef NO_gtk_1menu_1item_1get_1submenu
JNIEXPORT jlong JNICALL GTK_NATIVE(gtk_1menu_1item_1get_1submenu)
(JNIEnv *env, jclass that, jlong arg0)
@@ -10154,15 +10238,7 @@ JNIEXPORT void JNICALL GTK_NATIVE(gtk_1toolbar_1set_1icon_1size)
(JNIEnv *env, jclass that, jlong arg0, jint arg1)
{
GTK_NATIVE_ENTER(env, that, gtk_1toolbar_1set_1icon_1size_FUNC);
-/*
gtk_toolbar_set_icon_size((GtkToolbar *)arg0, arg1);
-*/
- {
- GTK_LOAD_FUNCTION(fp, gtk_toolbar_set_icon_size)
- if (fp) {
- ((void (CALLING_CONVENTION*)(GtkToolbar *, jint))fp)((GtkToolbar *)arg0, arg1);
- }
- }
GTK_NATIVE_EXIT(env, that, gtk_1toolbar_1set_1icon_1size_FUNC);
}
#endif
diff --git a/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/os.h b/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/os.h
index 0ccbecaa7a..d43d4a7cd7 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/os.h
+++ b/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/os.h
@@ -376,6 +376,28 @@
// GtkCalendarDisplayOptions removed
#define NO_gtk_1calendar_1set_1display_1options
+// GtkToolbar & toolbar item related objects removed
+#define NO_gtk_1toolbar_1new
+#define NO_gtk_1toolbar_1insert
+#define NO_gtk_1toolbar_1set_1icon_1size
+#define NO_gtk_1toolbar_1set_1style
+#define NO_gtk_1toolbar_1set_1show_1arrow
+#define NO_gtk_1separator_1tool_1item_1new
+#define NO_gtk_1separator_1tool_1item_1set_1draw
+#define NO_gtk_1toggle_1tool_1button_1new
+#define NO_gtk_1toggle_1tool_1button_1get_1active
+#define NO_gtk_1toggle_1tool_1button_1set_1active
+#define NO_gtk_1tool_1button_1new
+#define NO_gtk_1tool_1button_1set_1label_1widget
+#define NO_gtk_1tool_1button_1set_1icon_1widget
+#define NO_gtk_1tool_1button_1set_1use_1underline
+#define NO_gtk_1tool_1item_1set_1homogeneous
+#define NO_gtk_1tool_1item_1set_1is_1important
+#define NO_gtk_1tool_1item_1retrieve_1proxy_1menu_1item
+#define NO_gtk_1tool_1item_1set_1proxy_1menu_1item
+#define NO_gtk_1tool_1item_1get_1proxy_1menu_1item
+#define NO_gtk_1menu_1tool_1button_1new
+
#else
/**
diff --git a/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/os_stats.c b/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/os_stats.c
index a319cb7779..b37439b3e6 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/os_stats.c
+++ b/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/os_stats.c
@@ -323,16 +323,20 @@ char * GTK_nativeFunctionNames[] = {
"gtk_1adjustment_1set_1value",
"gtk_1bin_1get_1child",
"gtk_1border_1free",
+ "gtk_1box_1append",
+ "gtk_1box_1insert_1child_1after",
"gtk_1box_1new",
- "gtk_1box_1pack_1end__JJ",
- "gtk_1box_1pack_1end__JJZZI",
+ "gtk_1box_1pack_1end",
+ "gtk_1box_1prepend",
"gtk_1box_1reorder_1child",
"gtk_1box_1set_1child_1packing__JJI",
"gtk_1box_1set_1child_1packing__JJZZII",
"gtk_1box_1set_1homogeneous",
"gtk_1box_1set_1spacing",
"gtk_1button_1new",
+ "gtk_1button_1set_1child",
"gtk_1button_1set_1image",
+ "gtk_1button_1set_1use_1underline",
"gtk_1calendar_1clear_1marks",
"gtk_1calendar_1get_1date__J",
"gtk_1calendar_1get_1date__J_3I_3I_3I",
@@ -561,6 +565,7 @@ char * GTK_nativeFunctionNames[] = {
"gtk_1list_1store_1set__JJI_3BI",
"gtk_1main_1do_1event",
"gtk_1menu_1bar_1new",
+ "gtk_1menu_1button_1new",
"gtk_1menu_1item_1get_1submenu",
"gtk_1menu_1item_1new",
"gtk_1menu_1item_1set_1submenu",
diff --git a/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/os_stats.h b/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/os_stats.h
index a6ab4b2762..3e9fe923c6 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/os_stats.h
+++ b/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/os_stats.h
@@ -321,16 +321,20 @@ typedef enum {
gtk_1adjustment_1set_1value_FUNC,
gtk_1bin_1get_1child_FUNC,
gtk_1border_1free_FUNC,
+ gtk_1box_1append_FUNC,
+ gtk_1box_1insert_1child_1after_FUNC,
gtk_1box_1new_FUNC,
- gtk_1box_1pack_1end__JJ_FUNC,
- gtk_1box_1pack_1end__JJZZI_FUNC,
+ gtk_1box_1pack_1end_FUNC,
+ gtk_1box_1prepend_FUNC,
gtk_1box_1reorder_1child_FUNC,
gtk_1box_1set_1child_1packing__JJI_FUNC,
gtk_1box_1set_1child_1packing__JJZZII_FUNC,
gtk_1box_1set_1homogeneous_FUNC,
gtk_1box_1set_1spacing_FUNC,
gtk_1button_1new_FUNC,
+ gtk_1button_1set_1child_FUNC,
gtk_1button_1set_1image_FUNC,
+ gtk_1button_1set_1use_1underline_FUNC,
gtk_1calendar_1clear_1marks_FUNC,
gtk_1calendar_1get_1date__J_FUNC,
gtk_1calendar_1get_1date__J_3I_3I_3I_FUNC,
@@ -559,6 +563,7 @@ typedef enum {
gtk_1list_1store_1set__JJI_3BI_FUNC,
gtk_1main_1do_1event_FUNC,
gtk_1menu_1bar_1new_FUNC,
+ gtk_1menu_1button_1new_FUNC,
gtk_1menu_1item_1get_1submenu_FUNC,
gtk_1menu_1item_1new_FUNC,
gtk_1menu_1item_1set_1submenu_FUNC,
diff --git a/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/org/eclipse/swt/internal/gtk/GTK.java b/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/org/eclipse/swt/internal/gtk/GTK.java
index 904b1d8af1..1058bd156a 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/org/eclipse/swt/internal/gtk/GTK.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/org/eclipse/swt/internal/gtk/GTK.java
@@ -284,6 +284,13 @@ public class GTK extends OS {
public static final native long gtk_button_new();
+ /** @method flags=dynamic
+ * @param button cast=(GtkButton *)
+ * @param child cast=(GtkWidget *)
+ */
+ /* [GTK4 only] */
+ public static final native void gtk_button_set_child(long button, long child);
+
/**
* @method flags=dynamic
* @param button cast=(GtkButton *)
@@ -291,6 +298,10 @@ public class GTK extends OS {
*/
/* [GTK3 only] */
public static final native void gtk_button_set_image(long button, long image);
+ /**
+ * @param button cast=(GtkButton *)
+ */
+ public static final native void gtk_button_set_use_underline(long button, boolean use_underline);
/**
* @method flags=dynamic
@@ -373,25 +384,75 @@ public class GTK extends OS {
public static final native long gtk_bin_get_child(long bin);
/** @param border cast=(GtkBorder *) */
public static final native void gtk_border_free(long border);
+
+ /* GtkBox */
/** @param box cast=(GtkBox *) */
public static final native void gtk_box_set_spacing(long box, int spacing);
/**
+ * @param orientation cast=(GtkOrientation)
+ * @param spacing cast=(gint)
+ */
+ public static final native long gtk_box_new(int orientation, int spacing);
+ /**
+ * @param box cast=(GtkBox *)
+ * @param homogeneous cast=(gboolean)
+ */
+ public static final native void gtk_box_set_homogeneous(long box, boolean homogeneous);
+
+ /* GtkBox [GTK3 only] */
+ /**
* @method flags=dynamic
* @param box cast=(GtkBox *)
* @param child cast=(GtkWidget *)
*/
- /* [GTK3 only] */
public static final native void gtk_box_set_child_packing(long box, long child, boolean expand, boolean fill, int padding, int pack_type);
+
/**
* @method flags=dynamic
* @param box cast=(GtkBox *)
* @param child cast=(GtkWidget *)
*/
- /* [GTK4 only] */
public static final native void gtk_box_set_child_packing(long box, long child, int pack_type);
+ /**
+ * @method flags=dynamic
+ * @param box cast=(GtkBox *)
+ * @param child cast=(GtkWidget *)
+ * @param position cast=(gint)
+ */
+ public static final native void gtk_box_reorder_child(long box, long child, int position);
+ /**
+ * @method flags=dynamic
+ * @param box cast=(GtkBox *)
+ * @param widget cast=(GtkWidget *)
+ * @param expand cast=(gboolean)
+ * @param fill cast=(gboolean)
+ * @param padding cast=(guint)
+ */
+ public static final native void gtk_box_pack_end(long box, long widget, boolean expand, boolean fill, int padding);
- /* GtkCalendar */
+ /* GtkBox [GTK4 only] */
+ /**
+ * @method flags=dynamic
+ * @param box cast=(GtkBox *)
+ * @param child cast=(GtkWidget *)
+ */
+ public static final native void gtk_box_append(long box, long child);
+ /**
+ * @method flags=dynamic
+ * @param box cast=(GtkBox *)
+ * @param child cast=(GtkWidget *)
+ */
+ public static final native void gtk_box_prepend(long box, long child);
+
+ /**
+ * @method flags=dynamic
+ * @param box cast=(GtkBox *)
+ * @param child cast=(GtkWidget *)
+ * @param sibling cast=(GtkWidget *)
+ */
+ public static final native void gtk_box_insert_child_after(long box, long child, long sibling);
+ /* GtkCalendar */
public static final native long gtk_calendar_new();
/**
* @param calendar cast=(GtkCalendar *)
@@ -1294,40 +1355,6 @@ public class GTK extends OS {
*/
public static final native void gtk_rgb_to_hsv(double r, double g, double b, double[] h, double[] s, double[] v);
/**
- * @param orientation cast=(GtkOrientation)
- * @param spacing cast=(gint)
- */
- public static final native long gtk_box_new(int orientation, int spacing);
- /**
- * @method flags=dynamic
- * @param box cast=(GtkBox *)
- * @param widget cast=(GtkWidget *)
- * @param expand cast=(gboolean)
- * @param fill cast=(gboolean)
- * @param padding cast=(guint)
- */
- /* [GTK3 only] */
- public static final native void gtk_box_pack_end(long box, long widget,
- boolean expand, boolean fill, int padding);
- /**
- * @method flags=dynamic
- * @param box cast=(GtkBox *)
- * @param child cast=(GtkWidget *)
- */
- /* [GTK4 only] */
- public static final native void gtk_box_pack_end(long box, long child);
- /**
- * @param box cast=(GtkBox *)
- * @param child cast=(GtkWidget *)
- * @param position cast=(gint)
- */
- public static final native void gtk_box_reorder_child(long box, long child, int position);
- /**
- * @param box cast=(GtkBox *)
- * @param homogeneous cast=(gboolean)
- */
- public static final native void gtk_box_set_homogeneous(long box, boolean homogeneous);
- /**
* @method flags=dynamic
*/
/* [GTK3 only] */
@@ -1647,11 +1674,8 @@ public class GTK extends OS {
* @param take_focus cast=(gboolean)
*/
public static final native void gtk_menu_shell_set_take_focus(long menu_shell, boolean take_focus);
- /**
- * @param icon_widget cast=(GtkWidget *)
- * @param label cast=(const gchar *)
- */
- public static final native long gtk_menu_tool_button_new(long icon_widget, byte[] label);
+
+ public static final native long gtk_menu_button_new();
/**
* @param parent cast=(GtkWindow *)
* @param flags cast=(GtkDialogFlags)
@@ -2165,12 +2189,6 @@ public class GTK extends OS {
*/
public static final native void gtk_selection_data_set(long selection_data, long type, int format, long data, int length);
public static final native long gtk_separator_menu_item_new();
- public static final native long gtk_separator_tool_item_new();
- /**
- * @param item cast=(GtkSeparatorToolItem *)
- * @param draw cast=(gboolean)
- */
- public static final native void gtk_separator_tool_item_set_draw(long item, boolean draw);
/** @param socket cast=(GtkSocket *) */
public static final native long gtk_socket_get_id(long socket);
public static final native long gtk_socket_new();
@@ -2575,14 +2593,9 @@ public class GTK extends OS {
*/
/* [GTK3 only] */
public static final native void gtk_toggle_button_set_inconsistent(long toggle_button, boolean setting);
- /** @param button cast=(GtkToggleToolButton *) */
- public static final native boolean gtk_toggle_tool_button_get_active(long button);
- public static final native long gtk_toggle_tool_button_new();
- /**
- * @param item cast=(GtkToggleToolButton *)
- * @param selected cast=(gboolean)
- */
- public static final native void gtk_toggle_tool_button_set_active(long item, boolean selected);
+
+
+ /* GtkToolbar & related tool items [GTK3 only] */
/**
* @param icon_widget cast=(GtkWidget *)
* @param label cast=(const gchar *)
@@ -2603,6 +2616,16 @@ public class GTK extends OS {
* @param underline cast=(gboolean)
*/
public static final native void gtk_tool_button_set_use_underline(long item, boolean underline);
+
+ /** @param button cast=(GtkToggleToolButton *) */
+ public static final native boolean gtk_toggle_tool_button_get_active(long button);
+ public static final native long gtk_toggle_tool_button_new();
+ /**
+ * @param item cast=(GtkToggleToolButton *)
+ * @param selected cast=(gboolean)
+ */
+ public static final native void gtk_toggle_tool_button_set_active(long item, boolean selected);
+
/**
* @param item cast=(GtkToolItem *)
* @param menu_id cast=(const gchar *)
@@ -2637,16 +2660,27 @@ public class GTK extends OS {
* @param show_arrow cast=(gboolean)
*/
public static final native void gtk_toolbar_set_show_arrow(long toolbar, boolean show_arrow);
- /** @param toolbar cast=(GtkToolbar *)
+ /**
+ * @param toolbar cast=(GtkToolbar *)
* @param style cast=(GtkToolbarStyle)
*/
public static final native void gtk_toolbar_set_style(long toolbar, int style);
+ /** @param toolbar cast=(GtkToolbar *)*/
+ public static final native void gtk_toolbar_set_icon_size(long toolbar, int size);
/**
- * @method flags=dynamic
- * @param toolbar cast=(GtkToolbar *)
+ * @param icon_widget cast=(GtkWidget *)
+ * @param label cast=(const gchar *)
*/
- /* [GTK3 only] */
- public static final native void gtk_toolbar_set_icon_size(long toolbar, int size);
+ public static final native long gtk_menu_tool_button_new(long icon_widget, byte[] label);
+ public static final native long gtk_separator_tool_item_new();
+ /**
+ * @param item cast=(GtkSeparatorToolItem *)
+ * @param draw cast=(gboolean)
+ */
+ public static final native void gtk_separator_tool_item_set_draw(long item, boolean draw);
+
+
+
public static final native long gtk_tooltip_get_type();
/**
* @param tooltip cast=(GtkTooltip *)

Back to the top