QSF Exports
Neil Williams
linux at codehelp.co.uk
Tue Mar 8 10:30:13 EST 2005
On Tuesday 08 March 2005 2:52 pm, Derek Atkins wrote:
> Neil Williams <linux at codehelp.co.uk> writes:
> > I'm planning a cover-all export dialog that will use a notebook (tabbed)
> > style interface - one tab for each supported GnuCash entity. Accounts,
> > Transactions, Invoices, Customers, Vendors, Employees (any others?)
>
> All I can say is that you had better make sure the pages are pluggable
> when some module adds a new data type.
You do mean object type? As in Account rather than a data type like "string"?
Yes, I had planned for new objects. By using tabs vertically on the left, it's
easier to fit in more objects. I estimate I can fit in another 6 before the
dialog becomes any larger. Thereagain, it'll only show objects that exist in
the current book. Naturally, during testing, this is hardcoded but I'd do it
this way:
Add new tabs at run-time using gtk_notebook_append_page (), generate the list
of pages from qof_object_foreach_type and the page contents from
qof_class_param_foreach - no entities, no page, no tab to add.
Maybe. It's v.early days for this little bit. Maybe it'll grow into a druid
that separates objects like Accounts from business objects like Invoice,
maybe it'll get so complex I'll have to split some modules out into their own
dialogs. Realistically, the full version of this may not make the release of
G2, it may need to be the release after.
The entire QSF/book_merge code can have new data types added, just not at
runtime! I've done what I can to make the framework as extendable as
possible.
New objects are not a problem for any part of the framework. Compile a new
object in, register it with QOF and it'll work. It's regularly tested using
non-GnuCash objects.
New data types can be supported with a few additions to the code, like how to
compare two values, conversion to strings and from strings, etc. I've also
got a check in the QSF code that if the QOF interface version is incremented
(due to additional/modified data types), the user is warned if a file
contains an old set of data types.
>
> -derek
--
Neil Williams
=============
http://www.dcglug.org.uk/
http://www.nosoftwarepatents.com/
http://sourceforge.net/projects/isbnsearch/
http://www.neil.williamsleesmill.me.uk/
http://www.biglumber.com/x/web?qs=0x8801094A28BCB3E3
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
Url : http://lists.gnucash.org/pipermail/gnucash-devel/attachments/20050308/e26236c2/attachment.bin
More information about the gnucash-devel
mailing list