[Gtk-sharp-list] Some quick comments/questions from a newbie.

Todd Berman tberman@off.net
Sat, 12 Mar 2005 13:42:45 -0800

On Sat, 2005-03-12 at 16:20 -0500, Bet's On! wrote:
>I've been playing with GTK# recently (version 1.9.2 I think?) and I
>thought I'd comment and question some things I noticed:
>*There's no object or mechanism with which to prompt a user to select
>a directory instead of selecting a file. Am I supposed to use the
>FileSelection dialog instead?
>I'm not sure that's the way its to be done--FileSelection does not
>expose a "DirectoryName" property, though its kinda-sorta possible to
>grab the current directory by messing with one of the exposed controls
>that where the current directory is displayed at--but if that ever
>changes, the whole method fails miserably.
>*Speaking of FileSelection, I notice there's no way to gank the return
>result (user clicked 'OK' or 'Cancel') without having to use a
>delegate. Is that intentional?

Um. FileSelection is gtk+ 2.2 api, use FileChooserDialog for the 2.4
api. And as far as a directoryname property, you get a filename. i dont
see how converting between them is that hard.

Look at the response value from Run. It gives you everything you need
for return results.

>*TreeView and the MVC pattern: I love the extensibility of the MVC
>pattern as it applies to the TreeView control, don't get me wrong,
>but, oooh... ... ...has anyone considered, say, a *simplier* way of
>creating The Usual Suspects--you know, combo boxes, listboxes, etc.
>Prefabs, in other words, that wrap the TreeView's MVC architecture but
>expose a simplier, faster method of getting things done?
>Sometimes, I just want a listbox.


>*GTK 2.4 vs GTK 2.6--does GTK# 2.0 intend on using GTK 2.6 and its
>file selection dialogs? The ones we have now are kind of... I guess,
>"disconcerting" to look at and interact with.

GTK 2.4 introduced the FileChooser stuff, not GTK 2.6, so I dont quite
think your question makes sense.

>*Are we supposed to be able to inherit CellRenderer? I tried it once,
>but I got a strange "binary format" exception (can't quite remember
>the wording). Are there any examples of how to inherit and implement
>CellRenderer available?

Yes, gtk-sharp/sample/ has one.