[Gtk-sharp-list] Newbie Rant

Mike Kestner mkestner@speakeasy.net
Thu, 30 Oct 2003 11:05:34 -0600

Hi Daniel,

On Thu, 2003-10-30 at 01:29, Daniel Kornhauser wrote:
> So I am very frustrated because:
>  * I just committed and unfinished piece of code to CVS

Maybe you'd feel better if you focused on what you finished in the demo,
instead of focusing on what you couldn't figure out on your own.   

> * And I couldn't solve the bug that mknester assigned to me, because  I
> can't make a lousy test sample.

I think you are thinking too grandly on what the test sample needs to
be.  Comments below.

> Unfinished GtkDemo
> --------------------
> I'm sorry for Adding an unfinished example, but nobody has replied to
> explicit my questions in CVS. Perhaps I have asked to many question in
> my GtkDemo posts and should just ask one question each day ? I guess
> that looking a 5 question in a post is kind of discouraging.

Big posts with lots of questions can take a while to digest and summon
the time to respond.  That doesn't mean you shouldn't write them, it
just means you need to be a little more patient in waiting for the
response sometimes.

> Plus I don't know how to invoke the script that automatically updates
> the ChangeLog, I fell stupid.

You're just giving cvs too much credit.  Nothing automatically updates
the ChangeLog.  You have to edit it yourself.  I normally make my
ChangeLog entry before committing and then when cvs launches vi for the
commit message, I read it in from the ChangeLog.

One more point here about the cvs learning curve:  I noticed that you
did a cvs add of the demo directory, but it doesn't look like you
committed any of the files.  cvs add doesn't add files to the
repository, you have to cvs ci the files after they are added.

> Bug Fixing
> ------------
> It started nicely, mknester gives me a bug. :-)
> I go to the page, and "Bang" first problem I don't know how the hell
> Drag and Drop works in Gnome.  :-( So I google for a while and kind of
> learn a little what it is for, but I don't really know how it work.

Join the club.  I've been using Gtk+ for over 4 years and don't
completely understand all the nuances of DnD.  We're not alone, either.

> Anyway I do a patch iteration (with lots of help from mknester & team
> from the IRC), and I have only to test it right ? 
> "Bang again", I can find a simple example of drag and drop in C :-(
> luckily I find one in c++, but I don't know c++, I try to port it but I
> just not good enough.
> AM I STUPID or just didn't inherited the hacker gene !!!

I think you are thinking too big on this test sample.  The patch you
want to test adds glue to access fields on the DragContext object.  You
don't necessarily have to have a full-blown DnD test to verify that. 
Instantiate a DragContext, set a field, read the field, make sure the
get is returning the same value you set.  Rinse, repeat, for the other

FWIW, there are other open bugs on Dnd in Gtk#.  It hasn't been used
much yet and there is missing API and broken API all over the place. 
You would have to fix a lot of other bugs before you could use a
full-blown DnD test to test your patch.

> 	So who do gurus actually do it ?

I look at application code.  GNOME CVS is *full* of applications using
Gtk+.  Evolution, Gnumeric, and Nautilus in particular are full of
really nice code by very skilled hackers.  They are huge applications
though so it can take a little time zeroing in on the right code, but
find and grep are your best friends.

> Is there some hidden pieces of Gtk+ Documentation I should know about ?

Documentation is a weak spot.        

> 	Sorry for venting out publicly but I fell incompetent and had to get it
> out of my system.

Heh.  :-)

Mike Kestner <mkestner@speakeasy.net>