[Gambas-devel] gb.gtk 050305

Bodard Fabien gambasfr at ...4...
Sat Mar 5 23:57:07 CET 2005


Le samedi 5 Mars 2005 16:10, Daniel Campos a écrit :
Hi daniel

i can't use the menu editor on your exemple ... the ide raise an error !

fabien

ps: good work :)

> Hi:
>
> gb.gtk 050305:
>
> -> "Plugin" widget changed its name to "Plugger".
>
> -> "Grab" method from Widgets and Desktop is working now.
>
> -> Added "ScrollView" widget, partially working.
>
> -> Added a "TrayIcon" class which allows to add an icon in the
> notification area, comonly called "System Tray" on win$ systems.
> This has been written using the freedesktop.org specifications, so
> it works when using GNOME, KDE, XFCE and may be other
> desktops/window managers.
>
> The main part of this class is X-Windows code (gtrayicon.cpp),
> so it should be ported to QT using the QtXEmbedContainer
> <http://doc.trolltech.com/solutions/qtxembed/qtxembedcontainer.html> and
> a QPixmap. This feature, of course is just for X-WIndows systems,
> but it is sure it can be ported to Win$ using the Systray API from
> that system, or may be it can work directly with the rootless X server
> usually
> used with Cygwin. (By the way, once I had to embeed a window from a
> process into another, using Win$ and VB, and I was able to do it using API
> calls, so the "Plugger" widget should be portable too). About
> framebuffer implementations,
> just a simple application can be run at once in the framebuffer, so
> "Plugger" has no
> sense there, and the notification area can be just a "stub". May  be
> DirectFB will allow
> to run multiple applications using the Fusion API, but GTK+ for DirectFB
> is very
> inmature now, even if a guy decided recently to restart the work in the
> gdk-directfb,
> so it is not a problem by now, and I suppose they will offer these
> features in the future.
> (I don't know anything about QTopia)
>
> Note that this icon is just an icon into the notification area, which is
> quite different
> from KDE or GNOME "applets". Theorically, any kind of widget could
> be added in the notification area, however, an image is the only widget
> that really works for all notification area implementations
> (KDE,GNOME,XFCE...),
> and trying to add windows, buttons and other stuff causes strange problems.
> However, it makes no sense to add a lot of widgets in that small area:
> programmers usually
> want to place just an icon there.
>
> This Systray class emits the "MouseDown","MouseUp" and "Menu" signals, so
> you can easily popup menus when clicked. I send a little example.
>
> There's also a "TrayIcons" class which enumerates all Tray icons managed
> by the
> application.
>
> I think it is very simple, following the "Gambas" way: two properties
> "Picture" for
> the icon, and "Text"/"ToolTip" for the tip, and three events, thats all.
>
> The application can work normally even if there's notification area: the
> icon is simply
> not shown.
>
> This is the last "new feature" I will add to gb.gtk, prior to complete
> all the rest of
> widgets (I mean at least the skeleton of the widgets), and release the
> first alpha
> gb.gtk version.
>
> -> Benoît: I have problems trying to manage menus with gb.gtk and the
> Gambas IDE 1.9.3,
> I think i've implemented all needed to manage the menus, but it seems
> there's any
> kind of bug in the IDE that causes the problem when gb.qt is not the
> graphical library used.
>
> Regards,
>
> D. Campos





More information about the Devel mailing list