use of provate functions and other gtk code
Olivier Fourdan
fourdan at xfce.org
Tue Apr 20 23:54:39 CEST 2004
Brian,
The gtk part must go. Just remove the parts that come from gtk, and
protect the part of xfce code with #if/#endif to adjust to the gtk
version the code is being compiled with.
Anything else will be seen as hack and will lead to endless bugs.
So yes, please take the necessaty actions to remove the parts of the
code that either use gtk cut'n paste or gtk private functions (even if
it means taking functionality out of the code)
I definitely prefer a clean, stable maintainable code.
Cheers,
Olivier.
On Tue, 2004-04-20 at 23:41, Brian J. Tarricone wrote:
> On Tue, 20 Apr 2004, Olivier Fourdan wrote:
>
> > Brian,
> >
> > It seems you added a bunch of code from gtk in libxfcegui4.
> >
> > This is not correct and should be reverted because:
> > 1) as already said, use of private gtk functions outside gtk is not
> > correct and wil lead to a lot of problems
>
> i didn't think it would be a problem since 1) both gtk 2.2 and 2.4 have
> _gtk_fnmatch() (and since gtk 2.2 is no longer the current release,
> that's unlikely to change), and 2) it worked fine for me. but obviously
> it is a problem, so, as i said in a previous email, i'll fix it. i'll
> probably end up setting it up to use the system fnmatch(), or, in the
> absence of it, degrade (hopefully) gracefully.
>
> > 2) the "gtk" name space is reserved to gtk and using it outside gtk is a
> > bug.
>
> what would you suggest i do? the gtk_/Gtk namespaced 'classes' are
> backports from gtk 2.4. if i were to go and rename, e.g., GtkFileFilter
> to XfceFileFilter, and all the gtk_file_filter_* functions to
> xfce_file_filter_*, it would be a lot of wasted effort for what i think
> is negligible gain. plus that means writing stub functions for all of
> them that just call the gtk_* counterparts when compiled against gtk
> 2.4. also it means renaming everything that references it. it also
> adds some maintainence overhead if bugs are fixed in gtk 2.4.0's
> implementation of GtkFileFilter or GtkIconTheme, as it's not so simple
> to just copy over the new files and change a few lines - there will be a
> need to track down each individual line that changed and merge it into
> the libxfcegui4 tree.
>
> the only reason these gtk bits are in there are for compatibility with
> users that are stuck with gtk 2.2. when compiled against gtk 2.4, these
> parts don't get compiled. there shouldn't be any binary compat issues
> (with libxfcegui4), but it seems there are, and i'll do my best to get
> to the bottom of it.
>
> if it really is that important to you, i'll make the changes - it's your
> show - but i'm certainly not going to enjoy the extra work that implies.
>
> -brian
>
> _______________________________________________
> Xfce4-dev mailing list
> Xfce4-dev at xfce.org
> http://lunar-linux.org/mailman/listinfo/xfce4-dev
--
- Olivier Fourdan - fourdan at xfce.org - http://www.xfce.org -
More information about the Xfce4-dev
mailing list