Login
Username:

Password:

Remember me



Lost Password?

Register now!
Main Menu
Who's Online
1 user(s) are online (1 user(s) are browsing Forum)

Members: 0
Guests: 1

more...

Browsing this Thread:   1 Anonymous Users



« 1 (2) 3 »


Re: gtk-mui

Joined:
2010/1/8 10:07
Group:
Member
Posts: 1413
Offline
+1
why we need glib etc ?

and now i wonder if possible for full gtk same way


Posted on: 2011/8/12 10:06
Transfer the post to other applications Transfer


Re: gtk-mui

Joined:
2011/8/3 6:20
From france
Group:
Member
Posts: 16
Offline
up !

@o1i: if you're online, please, could you read the last posts of the page 1 of this topic ?
thanks a lot


Posted on: 2011/8/22 12:26
Transfer the post to other applications Transfer


Re: gtk-mui

Joined:
2005/6/16 11:11
Group:
Member
Posts: 612
Offline
Quote:

Tito-Amigang wrote:
an other question, excuse me, but why we need glib and gobjects for a GTK to MUI API ?

for my application (on aros and linux), i need dragndrop functions too ... not found in gtk-mui lib
so I would like to write a "direct translate lib" , because a lot of GTK function are the same on MUI , for example this 3 GTK functions and the MUI equivalent :

#define gtk_widget_show(a) set(a,MUIA_Window_Open,TRUE);
#define gtk_container_add(o,b) DoMethod(o,OM_ADDMEMBER,b)
#define gtk_button_new_with_label(l) SimpleButton(l)


@o1i : i'm rookie on GTK to MUI, so do you think it's possible ? why we need glib etc ?

for test my idea, i wrote "translate define" C lines for the helloWorld gtk, and it's ok, but could you say to me what is the limit of this method ? :
http://zaclys.com/?contenu_mode=voir&contenu_id=207&c=94


Sorry for the late answer, but everybody here is at vacation and only one stupid guy left to do all the work (me). In my spare time I have to care about my mail-servers, which are listed on some blacklists, which is my fault, but not trivial to fix :(.

But to stop whining, I started like you years ago. For some simple examples this will work. But it won't work for
- custom classes, which inherit the methods of their parent classes
- direct access of public class data (which is not recommended for Gtk >2.0 I suppose, but is still (heavily) used in some Gtk code)
There are more cases were it fails, I am sure.

You can write a custom widget with its own data section:

struct jDisplayClass {
GtkHBoxClass parent_class;
};

struct jDisplay {
GtkHBox object; /* parent object */
/** PRIVATE ***/

/* combo widget */
GtkWidget *screen_resolutions;
GList *res_items;

/*** PUBLIC ***/

guint gfx_width_win, gfx_height_win;
guint gfx_width_fs, gfx_height_fs;
}

So for a widget of that class you can get the gfx_width_win simply with

width=GTK_DISPLAY(widget)->gfx_width_win;

This won't work with defines. This will not even work without GLib. I tried it ;).

Contrary to MUI, a widget can expose some of its data section to the outside easily.


Posted on: 2011/8/22 23:42
Transfer the post to other applications Transfer


Re: gtk-mui

Joined:
2011/8/3 6:20
From france
Group:
Member
Posts: 16
Offline
mail-servers blacklisted :
open relay ? spf error ? :) i had the same problem by the past week

gtk mui : ok, i see.
my idea was not to only use define, but function too.
in my example to translate gtk-hello-world.c to mui, i wrote a fonction for use a pseudo hooks stack for translate gtk's g_signal_connect to mui's do_method... because define can't make it possibles, as you said.
but i understand that we can't translate all the gtk's dictionary by this way.
anyway I will continue to wrote my "simple-direct-translator" for my project (very simple gui), it's a good exercise to me to study GTK and MUI, and I need drag'n drop features ... and perhaps it can help someones, not for ports but for new projects with very simple GUI, in these cases it can be a good way to write a cross plateform application (linux-gtk and amiga-mui) without glib, as for me now.

an other question : which mui's widget does not exists in gtk ? knob i suppose ?

thanks

Posted on: 2011/8/25 4:18
Transfer the post to other applications Transfer


Re: gtk-mui

Joined:
2005/6/16 11:11
Group:
Member
Posts: 612
Offline
Quote:

Tito-Amigang wrote:
mail-servers blacklisted :
open relay ? spf error ? :) i had the same problem by the past week


No, I have few hundred users on that one and either one of them had some mass mailing Trojan (I have now finally installed sender throttling, was a long time on my list anyways) or we had some back-scatter of undeliverable mail, which could happen in some rare cases (also fixed now).

Quote:

[..]
anyway I will continue to wrote my "simple-direct-translator" for my project (very simple gui), it's a good exercise to me to study GTK and MUI, and I need drag'n drop features ... and perhaps it can help someones, not for ports but for new projects with very simple GUI, in these cases it can be a good way to write a cross plateform application (linux-gtk and amiga-mui) without glib, as for me now.

an other question : which mui's widget does not exists in gtk ? knob i suppose ?


Never looked at it this way, sorry. I only tried to map gtk widget to mui ones. Menu handling is totally different, that's for sure.

Posted on: 2011/8/26 0:34
Transfer the post to other applications Transfer


Re: gtk-mui

Joined:
2008/6/2 2:28
Group:
Member
Posts: 251
Offline

For fun I converted GTK Tetris :) You can try.

I tested it on a native AROS ABIv0 and Aros Linux host

here gtktetris

gtktetris


Posted on: 2013/3/30 10:24
Transfer the post to other applications Transfer


Re: gtk-mui

Joined:
2011/7/12 3:52
Group:
Member
Posts: 55
Offline
nice job! was it difficult? time-consuming? is it a start of more gtk apps to come?

Posted on: 2013/4/2 9:48
Transfer the post to other applications Transfer


Re: gtk-mui

Joined:
2010/8/30 7:20
Group:
Member
Posts: 947
Offline
@mmartinka
could that be compiled for the 68k (v1) target? would be interesting to see if and how that performs. how is the wrapper done? is it a link lib built in contribs or dynamic lib?

Posted on: 2013/4/2 10:18
Transfer the post to other applications Transfer


Re: gtk-mui

Joined:
2008/6/2 2:28
Group:
Member
Posts: 251
Offline
nice job!

Thanks

was it difficult?

This is not a definite answer. Just tetris not been challenging. It depends on how much of the application is not in the gtk-mui. And how difficult it is to replace the missing commands.

is it a start of more gtk apps to come?

Yes I'll try something else.


Posted on: 2013/4/2 21:17
Transfer the post to other applications Transfer


Re: gtk-mui

Joined:
2008/6/2 2:28
Group:
Member
Posts: 251
Offline

@wawa
could that be compiled for the 68k (v1) target?

Theoretically yes, but if it works gtk-mui to 68k is a question for the author of the project.


Posted on: 2013/4/2 21:23
Transfer the post to other applications Transfer



« 1 (2) 3 »



You can view topic.
You cannot start a new topic.
You cannot reply to posts.
You cannot edit your posts.
You cannot delete your posts.
You cannot add new polls.
You cannot vote in polls.
You cannot attach files to posts.
You cannot post without approval.

[Advanced Search]


Search
Top Posters
1 paolone
paolone
4358
2 magorium
magorium
4095
3 phoenixkonsole
phoenixkonsole
3892
4 nikolaos
nikolaos
3693
5 deadwood
deadwood
2923
6 ncafferkey
ncafferkey
2643
7 mazze
mazze
2214
8 clusteruk
clusteruk
2109
9 Kalamatee
Kalamatee
2024
10 damocles
damocles
1789
© 2004-2017 AROS Exec