[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: gEDA-dev: [PATCH] gschem: recent files support



On Monday 23 April 2007 12:43:21 Ivan Stankovic wrote:
> On Mon, Apr 23, 2007 at 12:17:46PM +0100, Peter TB Brett wrote:
> > On Monday 23 April 2007 12:02:20 Ivan Stankovic wrote:
> > > On Sat, Apr 21, 2007 at 11:23:40AM +0100, Peter Clifton wrote:
> > > > My strategy for dealing with the guile stuff is to find a similar
> > > > thing I want to copy, then use grep to chase it through the various
> > > > places it is implemented.
> > > >
> > > > Good luck, and great work on the patch so far.
> > >
> > > Thanks for the help, I appreciate it. Please see the new patch
> > > attached.
> >
> > Firstly, big problem: you're using GLib's key file API, which was
> > introduced in GLib 2.6.  Gschem is required to be backward compatible as
> > far as 2.4.
> >
> > Options:
> >
> > 1. Check for GTK 2.6, and don't support recent files if the API isn't new
> > enough (easy solution).
> >
> > 2. Use a different mechanism (good solution).
>
> I'm aware of this, but Ales suggested I use glib's keyfile mechanism.
> Personally, I don't think many people use glib (or gtk) 2.4 these
> days.

News to me.  About 9 months ago I tried to use 2.6 features and got my wrists 
slapped.  It should degrade nicely back to 2.4, unless we're going to require 
GTK+ 2.6 for gEDA. In that case, someone would need to update all of the 
configure scripts.

> > Secondly, since gschem loads configuration from the current working
> > directory, that would be the appropriate place to store the recent files
> > list.  This has the added advantage that all the files in the recent
> > files list would be relevant to the project you're currently working on.
>
> Yes, but I like global recent files. If you look at other programs
> implementing this feature, almost always the recent file list is global
> (ie. not specific to a particular project).

In which case you need to make gschem have a separate configuration context 
for each open file, and load all the appropriate rc files along with a 
schematic.  Clicking on a schematic in the recent files list and getting a 
huge series of "symbol not found" messages isn't very user friendly. ;)

(Hint: this would not be easy).

> I was using git for the first patch, but for this one I had to
> use CVS since the git mirror is currently broken:
>
> [ivan@alpha2 ~/src] $ git clone http://repo.or.cz/w/geda-gaf.git
> Initialized empty Git repository in /home/ivan/src/geda-gaf/.git/
> /usr/bin/git-clone: line 374: cd:
> /home/ivan/src/geda-gaf/.git/refs/remotes/origin: No such file or directory
> fatal: Not a valid object name HEAD

You're trying to clone the web interface. ;)

Try 'cg-clone git://repo.or.cz/geda-gaf.git' -- works for me.  Also, try to 
avoid repeatedly cloning the entire repository -- fetch it once and keep it 
up-to-date with 'cg-fetch origin'.

Cheers,

Peter


-- 
Fisher Society committee                    http://tinyurl.com/o39w2
CUSBC novices, match and league secretary   http://tinyurl.com/mwrc9
CU Spaceflight                              http://tinyurl.com/ognu2

v3sw6YChw7$ln3pr6$ck3ma8u7+Lw3+2m0l7Ci6e4+8t4Gb8en6g6Pa2Xs5Mr4p4
  hackerkey.com                                  peter-b.co.uk

PGP signature



_______________________________________________
geda-dev mailing list
geda-dev@moria.seul.org
http://www.seul.org/cgi-bin/mailman/listinfo/geda-dev