MATE drag-and-drop development SOLVED
Forum rules
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
-
- Level 3
- Posts: 156
- Joined: Mon Jul 29, 2013 1:05 pm
- Location: San Francisco
- Contact:
MATE drag-and-drop development SOLVED
I'm trying t build a MATE (Gnome) based application for Mint 20.2 with MATE 1.24.0 I have previously built a couple of GTK+ applications but now want to use drag-and-drop from Caja to my new application and I need a connection to MATE to do this. What and where are the headers and libraries to do this ?
Last edited by LockBot on Wed Dec 28, 2022 7:16 am, edited 2 times in total.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
First program written in Algol for a KDF9 (just look up KDF9 on Wikipedia).
Re: MATE drag-and-drop development
You might want to start looking here: https://github.com/mate-desktop
-
- Level 3
- Posts: 156
- Joined: Mon Jul 29, 2013 1:05 pm
- Location: San Francisco
- Contact:
Re: MATE drag-and-drop development
Thanks. A good start. I found the headers that look promising:
Now I have to search for the MATE libs and start looking for drag-and-drop code...
Code: Select all
#include <glib-object.h>
#include <glib/gi18n.h>
#include <gio/gio.h>
#include <gtk/gtk.h>
First program written in Algol for a KDF9 (just look up KDF9 on Wikipedia).
-
- Level 3
- Posts: 156
- Joined: Mon Jul 29, 2013 1:05 pm
- Location: San Francisco
- Contact:
Re: MATE drag-and-drop development
This may where I need to look: https://ubuntu-mate.org/get-involved/development/
First program written in Algol for a KDF9 (just look up KDF9 on Wikipedia).
-
- Level 3
- Posts: 156
- Joined: Mon Jul 29, 2013 1:05 pm
- Location: San Francisco
- Contact:
Re: MATE drag-and-drop development
After poking around in configure.ac it seems that libmate-desktop-dev is needed. This lead me to install it. I then guessed that libmate-desktop.a would need to be linked into my code. I didn't even know if such a lib existed. It does ! I got lucky.
There seems to be a paucity of novice Mate development resources and old Gnome code doesn't help.
There seems to be a paucity of novice Mate development resources and old Gnome code doesn't help.
First program written in Algol for a KDF9 (just look up KDF9 on Wikipedia).
-
- Level 3
- Posts: 156
- Joined: Mon Jul 29, 2013 1:05 pm
- Location: San Francisco
- Contact:
Re: MATE drag-and-drop development SOLVED
Scratch all that...
After poking around I discovered I didn't need any additional libraries. The hook-up for the drag-and-drop wasn't hard and I can drag images from Caja to my application nicely... It just wasn't clear to me that the Mate desktop, forked from Gnome, has the existing Gtk+ interfaces.
After poking around I discovered I didn't need any additional libraries. The hook-up for the drag-and-drop wasn't hard and I can drag images from Caja to my application nicely... It just wasn't clear to me that the Mate desktop, forked from Gnome, has the existing Gtk+ interfaces.
Code: Select all
for(k = 0; k < 10; k++)
{
g_signal_connect // now in Glib not GTK
(
image_strip[k],
"drag_data_received",
G_CALLBACK(drag_image_received),
NULL
);
}
//---------------- final setup for drop destination
for(k = 0; k < 10; k++)
{
gtk_drag_dest_set
(
GTK_WIDGET(image_strip[k]),
GTK_DEST_DEFAULT_ALL,
target_table,
G_N_ELEMENTS(target_table),
GDK_ACTION_COPY
);
}
First program written in Algol for a KDF9 (just look up KDF9 on Wikipedia).