libxfce4ui

Nick Schermer nickschermer at gmail.com
Sat Dec 15 13:31:21 CET 2007


So then, as a kickoff, I did some research what is used in
libxfcegui4, things we might want to change (api point of view) etc.
If we agree on things, I'll add them to libxfce4ui (and move it in svn
when someone with permissions created the root folders). I also have
no problems 'porting' modules to 4ui by providing patches and such, so
we go for quality api, not time-savers.

Please review the things below when you know what you're talking
about, add comments, strip irrelevant text from your reply and don't
make it a "yeey please switch to libxfce4ui topic" please.

Greets,
Nick


gtk_style.h
===========

None of the functions is used in Xfce, there are also good alternatives in Gtk+.


dialogs.h
=========

xfce_create_header, xfce_create_header_with_image:
Still used in xfwm4 and appfinder, both for creating a header in a
dialog, should be removed from the api and the code ported to
xfce-titled-dialog.

xfce_create_small_label:
Still used in xfwm4 and xfce-mcs-plugins. Has it's advantages, but we
could also provide PangoAttrList (see thunar-pango-extensions.h). More
flexible? Could also make libxfce4ui more interesting for thunar?

xfce_create_mixed_button:
Used in several places. Keep it.

xfce_err, xfce_warn, xfce_info, xfce_confirm:
Used here and there. Are useful so we keep them, names could be more
descriptive so we're talking about a dialog. Also no way to set the
parent, if we use a pointer here it could be NULL, a screen or a
widget (see thunar_util_parse_parent).
For the error dialog it is useful to set a GError (secondary text).

void xfce_dialog_error (gpointer parent, const GError *error, const
gchar *format, ...);
void xfce_dialog_warning (gpointer parent, const gchar *format, ...);
void xfce_dialog_info (gpointer parent, const gchar *format, ...);
gboolean xfce_dialog_confirm (gpointer parent, const gchar *text,
const gchar *stock_id, const gchar *action);

xfce_message_dialog, xfce_message_dialog_new
Useful, but I think we're overlapping Gtk here quite a bit. The
first_button_type could at least be an enum if you'd ask me. Still
used in a lot of places, so we should keep it, but then with some
small improvements.


gtktoxevent.h
=============

Not used anymore, could be dropped.


icons.h
=======

xfce_inline_icon_at_size:
Still used, makes live a bit easier.

xfce_themed_icon_lookup:
It does some handy stuff with the icon name, but appart from that it's
only used before loading the actual pixbuf. That said xfdesktop is
currently the only used of the code outside libxfcegui4, inside the
menu plugin, so I have no idea what libxfce4menu provides in the
feature? If it returns valid icon names, this function becomes more or
less useless.

xfce_themed_icon_load:
Still used on in a lot of code.

xfce_themed_icon_lookup_list, xfce_themed_icon_load_list:
Not used outside libxfcegui4.

xfce_themed_icon_lookup_category, xfce_themed_icon_load_category:
xfce_themed_icon_lookup_category is only used in xfdesktop, inside
menu code. Duno how libxfce4menu handles this...?


session-client.h
================

Needed, but we should do some research how the Gtk+ session api is
going to look like, so we can use that when it becomes available in
Gtk, also contains waaay to much function, really... Should also be
build on top of a GObject. Benny? Your the session guy ^_^.



xfce-appmenuitem.h
==================

Only used for the xfdesktop menu, same here, what's libxfce4menu going
to provide?


xfce-exec.h
===========

Used in a lot of code. Keep it.


xfce_framebox.h
xfce-widget-helpers.h
=====================

Both are used a lot. Most of if has switched to the not deprecated
xfce_create_framebox function in xfce-widget-helpers, but I think this
API is kinda ugly. Personally I'd prefer a "normal" widget for this,
so I suggest adding XfceFrame. A widget on top of a GtkFrame with a
bold label and some space inside the frame. Users can then add widgets
inside the frame using gtk_container_add.


xfce_aboutdialog.h
==================

I know it been in Xfce for a long time, but I think we should switch
to the gtk about dialog... simply because it's there and we don't want
to maintain this.


xfce_scaled_image.h
===================

Only used in xfce4-panel. I think it could be dropped, will take a look.


xfce_movehandler.h
==================

Not used anymore.


xfce-titled-dialog.h
====================

Part of the Xfce look since 4.4. No way we can drop this.


xfce-heading.h
==============

Needed for the titled dialog. Also not used as a standalone item, so
we could hide it from the public api, also reduces thenumber of plt
entries.


xfce-iconbutton.h
=================

Only used in xfce4-mixer, don't think it has any value...


xfce-gtk-extensions.h
=====================

Contains xfce_gtk_window_center_on_monitor and
xfce_gtk_window_center_on_monitor_with_pointer.
Usefull I don't think gtk has function for this yet, apart from the
long names, we should keep them ^_^.


xfce-gdk-extensions.h
=====================

Not really into this stuff, but it used by xfce-gtk-extensions.h, and in a lot
of xfce code, so we probably want to keep this.


xfce-startup-notification.h
===========================

Not used, could be removed. Gtk handles this too.


xfce-filechooser.h
preview_filesel.h
xfce-colorbutton.h
xinerama.h
xfce_togglebutton.h
xfce_systemtray.h
xfce_decorbutton.h
xfce_clock.h
xfce_icontheme.h
xfce_decortoggle.h
netk*
==================

Deprecated interfaces.



More information about the Xfce4-dev mailing list