r18404 - gnucash/trunk/src/app-utils - Bug #599953: Let gnc:make-[complex|simple]-boolean-option store its value as a string

Christian Stimming cstim at code.gnucash.org
Sat Oct 31 17:03:41 EDT 2009


Author: cstim
Date: 2009-10-31 17:03:40 -0400 (Sat, 31 Oct 2009)
New Revision: 18404
Trac: http://svn.gnucash.org/trac/changeset/18404

Modified:
   gnucash/trunk/src/app-utils/options.scm
Log:
Bug #599953: Let gnc:make-[complex|simple]-boolean-option store its value as a string

Patch by Mike Alexander (plus documentation comment by me):

Neither gnc:make-complex-boolean-option nor gnc:make-simple-boolean-option
(which calls it) correctly stores its result in the KVP that it is using.
This is because it calls kvp-frame-get-slot-path-gslist and
kvp-frame-set-slot-path-gslist to get and set the value.  Both of these are
implemented in C and the code in kvp-scm.c can't convert a Scheme boolean value
to or from a KvpValue since there is no boolean type in KvpValue.  There are
already a few places that have comments suggesting that there should be a
KVP_TYPE_BOOLEAN type, but adding this would be non-trivial.  For now I'll
supply a patch that will store the boolean value as a string (which is what
code in xaccAccountSetAutoInterestXfer in Account.c does).



More information about the gnucash-patches mailing list