Re: [OT] Guidelines for handling data in a GUI application?
- From: Murray Cumming <murrayc murrayc com>
- To: Jef Driesen <jefdriesen hotmail com>
- Cc: gtkmm-list gnome org
- Subject: Re: [OT] Guidelines for handling data in a GUI application?
- Date: Fri, 17 Nov 2006 21:16:19 +0100
On Fri, 2006-11-17 at 21:10 +0100, Jef Driesen wrote:
> Murray Cumming wrote:
> > On Fri, 2006-11-17 at 15:41 +0100, Jef Driesen wrote:
> >> I'm ready to write my first real GUI application (using gtkmm of
> >> course). I studied the gtkmm documentation and can make simple
> >> applications. The focus there was on the user interface part (e.g.
> >> adding widgets, event handling and stuff like that). But that is only
> >> one part of an application. My application must also be able to show and
> >> modify data. But I don't know how to do that in a "well designed" way.
> >>
> >> I looked for more information, but I couldn't find what I'm looking for.
> >> I do find lots of information on GUI toolkits and database APIs, but
> >> almost nothing useful on how to glue them together. Does anyone know
> >> where I can find more information on this (websites, books,...)?
> >>
> >> To give you some more background on my project: My application stores
> >> its data in an sqlite database. The application will have one main
> >> window, probably some type of master-detail view, with a listview for a
> >> (readonly) overview of the main database table and a detail part to
> >> modify that data. All the other data in the database is related to that
> >> main table (e.g. data to populate widgets in the detail part of the main
> >> window) and modified using secondary windows.
> >
> > It's probably worth looking at libgnomedb.
>
> I took a quick look at the libgnomedb website [1] and it seems to
> provide some wrapper around various database apis (including sqlite)
Yes, that's libgda, part of the gnome-db project.
> and
> data-aware widgets. I'm not sure if that's what I'm looking for. Using
> the sqlite api directly seems also much easier and is very well documented.
>
> My problem is not really that I don't how to get the data out of the
> sqlite database and add it to a certain widget. It's more about how do I
> structure/design my code. Things like: Do I add the database code inside
> my window classes? How do I pass data between windows? Do I create a
> class for every object stored in the database? At which point do I
> validate the user input? ...
Well, I think that's a problem that the libgnomedb data-aware widgets
want to solve for you.
> If I could study a well written and not too large or complicated
> project, that would already help me a lot.
>
> [1] http://www.gnome-db.org/
--
Murray Cumming
murrayc murrayc com
www.murrayc.com
www.openismus.com
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]