r23397 - gnucash/trunk/src - Bug 336843: Attach images/files/urls to transactions.

Geert Janssens janssens-geert at telenet.be
Mon Nov 18 15:02:12 EST 2013

On Sunday 17 November 2013 10:19:10 John Ralls wrote:
> On Nov 17, 2013, at 9:02 AM, Geert Janssens <janssens-geert at telenet.be> wrote:
> > On Sunday 17 November 2013 08:13:21 John Ralls wrote:
> > > Geert,
> > > 
> > > When I tested it on a Mac, gtk_show_uri failed because it depends
> > > on
> > > gvfs which isn't at present a GC dependency, so please at least
> > > put
> > > back the Mac bit -- which I'd already fixed so that it works.
> > > 
> > > If you can get it to build and work on Win32 without resorting to
> > > Win32 calls, great, but let's not add any new Gnome dependencies.
> > 
> > If I understand this correctly, gvfs is only required for non-local
> > uris. What I did for Windows was enforcing local-only uris and then
> > using gtk_file_chooser_get_filename instead of
> > gtk_file_chooser_get_uri.
> > 
> > 
> > But my test box is taking too long to complete the build. I'm out of
> > time for today.
> > 
> > John, if you want to do a release, the quickest solution is to
> > replace INT_PTR with int in gnc-gnome-utils.c.
> > 
> > I have seen several examples like this on the net. I'll push my
> > changes for 2.5.9 if/when I get it sorted out. These changes
> > shouldn't conflict with the string/feature freeze.
> Geert,
> The error message implied that gvfs was required to figure out what
> type of file was being opened, but that's actually not material
> because Patrick's UI includes an "associate URL" menu item that
> presents a dialog to enter an unrestricted URL.
> I'll fix the win32 case and do the release; we can figure out what to
> do next when you have time.
> Regards,
> John Ralls

My test build finished. Using local-only filenames instead of uri's doesn't fix the problem.
Regardless of the input (local-only filename of full uri), gtk_show_uri errors out with "URI's are 
not supported).

This looks like a bug in gio to me. It seems to take the presence of a ":" in the path to 
automatically mean the path is a full uri. This is obviously not correct for absolute pathnames 
on Windows.

Perhaps adding gvfs will fix this. But given the added functions are pretty short and clear, I 
don't think it's worth now trying to add gvfs. So I won't go into this any further. There are more 
pressing and important matters to deal with.

Perhaps one day I'll check if adding gvfs support in GnuCash adds sufficient benefit to make it 
worth (if we haven't switched gui frameworks by then ;)  ).


More information about the gnucash-devel mailing list