[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

gEDA-cvs: branch: master updated (c5a1e3de109aff6486b3a530652a6e05474bcf5b)



The branch, master has been updated
       via  c5a1e3de109aff6486b3a530652a6e05474bcf5b (commit)
       via  636c76231a18de5c2faef79fdf42b81cf9560a5c (commit)
       via  34e31d2340f909955156a5111c8bbe8e19b239ab (commit)
       via  c5fe3e0cc349f0facbb37d9a24f9f2256858124f (commit)
      from  58a300e237bc8f93571b3e47821ee739f65a2cc3 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.


=========
 Summary
=========

 Makefile.am                      |    8 +-
 configure.ac                     |   15 ++-
 lib/xgsch2pcb/assistant.py       |  310 ++++++++++++++++++++++++++++++
 lib/xgsch2pcb/config.py.in       |    2 +-
 lib/xgsch2pcb/gsch2pcbproject.py |    2 +-
 lib/xgsch2pcb/gui.py             |   69 ++------
 lib/xgsch2pcb/new_project_gui.py |  384 ++++++++++++++++++++++++++++++++++++++
 lib/xgsch2pcb/templates.py       |  137 ++++++++++++++
 update-changelogs.sh             |   34 ++++
 9 files changed, 902 insertions(+), 59 deletions(-)
 create mode 100644 lib/xgsch2pcb/assistant.py
 create mode 100644 lib/xgsch2pcb/new_project_gui.py
 create mode 100644 lib/xgsch2pcb/templates.py
 create mode 100755 update-changelogs.sh


=================
 Commit Messages
=================

commit c5a1e3de109aff6486b3a530652a6e05474bcf5b
Author: Peter Clifton <pcjc2@xxxxxxxxx>
Date:   Thu Oct 4 21:52:24 2007 +0100

    Add update-changelogs.sh copied from geda's gaf.git repository.

:000000 100755 0000000... 1313a6e... A	update-changelogs.sh

commit 636c76231a18de5c2faef79fdf42b81cf9560a5c
Author: Peter Clifton <pcjc2@xxxxxxxxx>
Date:   Thu Oct 4 21:50:55 2007 +0100

    Implement the new project GUI without using the GTK 2.10.x GtkAssistant

:100644 100644 a447bd8... e8a127b... M	Makefile.am
:000000 100644 0000000... 8c78337... A	lib/xgsch2pcb/assistant.py
:100644 100644 bd59264... 66a670e... M	lib/xgsch2pcb/new_project_gui.py

commit 34e31d2340f909955156a5111c8bbe8e19b239ab
Author: Peter Clifton <pcjc2@xxxxxxxxx>
Date:   Thu Oct 4 21:50:19 2007 +0100

    Add a new project druid where we can select a starting template.

:100644 100644 ca2c2fb... a447bd8... M	Makefile.am
:100644 100644 e2710ed... db228d9... M	configure.ac
:100644 100644 8d6d9b4... 9612965... M	lib/xgsch2pcb/config.py.in
:100644 100644 24bba3a... 61996d5... M	lib/xgsch2pcb/gsch2pcbproject.py
:100644 100644 a8c7dee... 445f4a4... M	lib/xgsch2pcb/gui.py
:000000 100644 0000000... bd59264... A	lib/xgsch2pcb/new_project_gui.py
:000000 100644 0000000... 9159aa5... A	lib/xgsch2pcb/templates.py

commit c5fe3e0cc349f0facbb37d9a24f9f2256858124f
Author: Peter Clifton <pcjc2@xxxxxxxxx>
Date:   Sun Sep 30 18:25:22 2007 +0100

    Comment out GUI code to change the layout name in use. (Unimplemented)
    
    Hide unimplemented placeholders before a released version.

:100644 100644 a070d4a... a8c7dee... M	lib/xgsch2pcb/gui.py

=========
 Changes
=========

commit c5a1e3de109aff6486b3a530652a6e05474bcf5b
Author: Peter Clifton <pcjc2@xxxxxxxxx>
Date:   Thu Oct 4 21:52:24 2007 +0100

    Add update-changelogs.sh copied from geda's gaf.git repository.

diff --git a/update-changelogs.sh b/update-changelogs.sh
new file mode 100755
index 0000000..1313a6e
--- /dev/null
+++ b/update-changelogs.sh
@@ -0,0 +1,34 @@
+#!/bin/bash
+#
+# ./update-changelogs.sh <options>
+# Updates ChangeLog files.
+#
+# e.g. if the main gEDA branch is called master, then to update all
+# ChangeLogs with revisions since the switch to git, do:
+#
+# ./update-changelogs.sh 1.0-20070526..master
+#
+# This should be only be run while preparing a release, in order to
+# ensure that the released tarballs contain change logs which can be
+# viewed without access to the git repository.
+#
+#
+
+GCLHEADER="# Do not edit this file - generated from version control history"
+GCLFOOTER="#GCL#"
+
+if ! git-log -n1 > /dev/null; then
+    exit $?
+fi
+
+for cl in $(find . -name ChangeLog); do
+    echo "Updating ${cl}"
+    dir=$(dirname $cl)
+    if tail -n1 ${cl} | grep $GCLFOOTER > /dev/null; then
+        echo -e "$GCLHEADER\n\n" > $cl
+        git-log --pretty=medium $@ -- $dir >> $cl
+        echo -e "\n\n$GCLFOOTER" >> $cl
+    else
+        echo "${cl}: Doesn't appear to be git format log, skipping"
+    fi
+done

commit 636c76231a18de5c2faef79fdf42b81cf9560a5c
Author: Peter Clifton <pcjc2@xxxxxxxxx>
Date:   Thu Oct 4 21:50:55 2007 +0100

    Implement the new project GUI without using the GTK 2.10.x GtkAssistant

diff --git a/Makefile.am b/Makefile.am
index a447bd8..e8a127b 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -24,6 +24,7 @@ pkglib_PYTHON = lib/xgsch2pcb/pcbmanager.py \
  lib/xgsch2pcb/gsch2pcbproject.py \
  lib/xgsch2pcb/gui.py \
  lib/xgsch2pcb/new_project_gui.py \
+ lib/xgsch2pcb/assistant.py \
  lib/xgsch2pcb/templates.py \
  lib/xgsch2pcb/funcs.py
 
diff --git a/lib/xgsch2pcb/assistant.py b/lib/xgsch2pcb/assistant.py
new file mode 100644
index 0000000..8c78337
--- /dev/null
+++ b/lib/xgsch2pcb/assistant.py
@@ -0,0 +1,310 @@
+# -*-Python-*-
+
+# xgsch2pcb - a GUI for gsch2pcb
+# Copyright (C) 2007 Peter Clifton <pcjc2@xxxxxxxxx>
+#
+# Emulate a GtkAssistant (available in GTK+2.10 onwards using <= GTK+2.8
+# Based in part on the GtkAssistant implementation in GTK+2.10
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
+
+import gtk, gtk.gdk, pango, gobject
+
+import gettext
+t = gettext.translation('xgsch2pcb', fallback=True)
+_ = t.ugettext
+
+
+ASSISTANT_PAGE_CONTENT  = 0
+ASSISTANT_PAGE_INTRO    = 1
+ASSISTANT_PAGE_CONFIRM  = 2
+ASSISTANT_PAGE_SUMMARY  = 3
+ASSISTANT_PAGE_PROGRESS = 4
+
+
+class AssistantPage(object):
+
+    def __init__(self):
+        self.page = None
+        self.type = ASSISTANT_PAGE_CONTENT
+        self.complete = False
+        self.title = None
+        self.header_image = None
+        self.sidebar_image = None
+        self.notebook_no = 0
+
+class Assistant(gtk.Window):
+
+
+    __gsignals__ = { 'apply'   : ( gobject.SIGNAL_RUN_LAST,
+                                   gobject.TYPE_NONE,
+                                   ( )),
+                     'cancel'  : ( gobject.SIGNAL_RUN_LAST,
+                                   gobject.TYPE_NONE,
+                                   ( ) ),
+                     'close'   : ( gobject.SIGNAL_RUN_LAST,
+                                   gobject.TYPE_NONE,
+                                   ( )),
+                     'prepare' : ( gobject.SIGNAL_RUN_LAST,
+                                   gobject.TYPE_NONE,
+                                   (gobject.TYPE_OBJECT, )),
+                   }
+
+    def __init__(self):
+        gtk.Window.__init__(self)
+
+        self.parent_window = None
+        self.cancel  = gtk.Button( stock = gtk.STOCK_CANCEL )
+        self.forward = gtk.Button( stock = gtk.STOCK_GO_FORWARD )
+        self.back    = gtk.Button( stock = gtk.STOCK_GO_BACK )
+        self.apply   = gtk.Button( stock = gtk.STOCK_APPLY )
+        self.close   = gtk.Button( stock = gtk.STOCK_CLOSE )
+        #self.last    = gtk.Button( stock = gtk.STOCK_GOTO_LAST )
+
+        self.cancel.set_no_show_all(True)
+        self.forward.set_no_show_all(True)
+        self.back.set_no_show_all(True)
+        self.apply.set_no_show_all(True)
+        self.close.set_no_show_all(True)
+        #self.last.set_no_show_all(True)
+
+        self.pages = []
+        self.current_page = None
+        self.visited_pages = []
+
+        vbox = gtk.VBox()
+        vbox.set_spacing( 12 )
+
+        self.notebook = gtk.Notebook()
+        self.notebook.set_show_tabs(False)
+        vbox.pack_start( self.notebook, True, True)
+
+        self.buttonbox = gtk.HButtonBox()
+        self.buttonbox.set_layout( gtk.BUTTONBOX_END )
+        self.buttonbox.set_spacing( 6 )
+        self.buttonbox.add( self.cancel )
+        self.buttonbox.add( self.back )
+        self.buttonbox.add( self.forward )
+        #self.buttonbox.add( self.last )
+        self.buttonbox.add( self.apply )
+        self.buttonbox.add( self.close )
+        vbox.pack_start( self.buttonbox, False, False)
+
+        self.add( vbox )
+
+        self.set_button_state()
+
+        def cancel_clicked_cb(button):
+            self.emit( 'cancel' )
+
+        def forward_clicked_cb(button):
+            if self.current_page:
+                self.visited_pages.append( self.current_page )
+            index = self.find_page_info_index( self.current_page )
+            self.set_page( self.pages[ index + 1 ] )
+
+        def back_clicked_cb(button):
+            # skip progress pages when going back
+            index = len(self.visited_pages) - 1
+            page_info = self.visited_pages[index]
+            while (page_info.type == ASSISTANT_PAGE_PROGRESS or
+                   not page_info.page.flags() | gtk.VISIBLE):
+                del self.visited_pages[index]
+                index = index - 1
+                page_info = self.visited_pages[index]
+            del self.visited_pages[index]
+            self.set_page( page_info )
+
+        def apply_clicked_cb(button):
+            self.emit( 'apply' )
+            self.destroy()
+
+        def close_clicked_cb(button):
+            self.emit( 'close' )
+            self.destroy()
+
+        #def last_clicked_cb(self, button):
+        #    print "LAST"
+
+        self.cancel.connect( 'clicked', cancel_clicked_cb )
+        self.forward.connect( 'clicked', forward_clicked_cb )
+        self.back.connect( 'clicked', back_clicked_cb )
+        self.apply.connect( 'clicked', apply_clicked_cb )
+        self.close.connect( 'clicked', close_clicked_cb )
+        #self.last.connect( 'clicked', last_clicked_cb )
+
+    def set_button_state(self):
+        if not self.current_page:
+            self.cancel.set_sensitive(True)
+            self.forward.set_sensitive(False)
+            self.cancel.show()
+            self.forward.show()
+            self.back.hide()
+            self.apply.hide()
+            self.close.hide()
+            #self.last.hide()
+        elif self.current_page.type == ASSISTANT_PAGE_INTRO:
+            self.cancel.set_sensitive(True)
+            self.forward.set_sensitive(self.current_page.complete)
+            self.cancel.show()
+            self.forward.show()
+            self.back.hide()
+            self.apply.hide()
+            self.close.hide()
+            #self.compute_last_button_state()
+        elif self.current_page.type == ASSISTANT_PAGE_CONFIRM:
+            self.cancel.set_sensitive(True)
+            self.back.set_sensitive(True)
+            self.apply.set_sensitive(self.current_page.complete)
+            self.cancel.show()
+            self.back.show()
+            self.apply.show()
+            self.forward.hide()
+            self.close.hide()
+            #self.last.hide()
+        elif self.current_page.type == ASSISTANT_PAGE_CONTENT:
+            self.cancel.set_sensitive(True)
+            self.back.set_sensitive(True);
+            self.forward.set_sensitive(self.current_page.complete)
+            self.cancel.show()
+            self.back.show()
+            self.forward.show()
+            self.apply.hide()
+            self.close.hide()
+            #self.compute_last_button_state()
+        elif self.current_page.type == ASSISTANT_PAGE_SUMMARY:
+            self.close.set_sensitive(True)
+            self.close.show()
+            self.cancel.hide()
+            self.back.hide()
+            self.forward.hide()
+            self.apply.hide()
+            #self.last.hide()
+        elif self.current_page.type == ASSISTANT_PAGE_PROGRESS:
+            self.cancel.set_sensitive(self.current_page.complete)
+            self.back.set_sensitive(self.current_page.complete)
+            self.forward.set_sensitive(self.current_page.complete)
+            cancel.show()
+            self.back.show()
+            self.forward.show()
+            self.apply.hide()
+            self.close.hide()
+            #self.last.hide()
+
+        if not self.visited_pages:
+            self.back.hide()
+
+    def find_page_info_index(self, page_info):
+        return self.pages.index( page_info )
+
+    def find_page_info(self, page):
+        for page_info in self.pages:
+            if page_info.page is page:
+                return page_info
+        return None
+
+    def set_page_colors(self, title, eb_title, eb_side):
+        title.ensure_style()
+        style = title.get_style()
+        title.modify_bg(gtk.STATE_NORMAL, style.bg[gtk.STATE_SELECTED])
+        title.modify_fg(gtk.STATE_NORMAL, style.fg[gtk.STATE_SELECTED])
+        eb_title.modify_bg(gtk.STATE_NORMAL, style.bg[gtk.STATE_SELECTED])
+        eb_side.modify_bg(gtk.STATE_NORMAL, style.bg[gtk.STATE_SELECTED])
+
+    def set_title_font(self, title):
+        desc = pango.FontDescription()
+        size = self.style.font_desc.get_size()
+        desc.set_weight( pango.WEIGHT_ULTRABOLD )
+        desc.set_size( int(size * pango.SCALE_XX_LARGE) )
+        title.modify_font( desc )
+
+    def append_page(self, page):
+        page_info = AssistantPage()
+        page_info.page = page
+        page_info.title = gtk.Label()
+        page_info.title.set_alignment(0, 0.5)
+        page_info.title.set_padding(6, 10)
+        page_info.sidebar_image = gtk.Image()
+        self.pages.append( page_info )
+
+        table = gtk.Table(2,2)
+        page_info.notebook_no = self.notebook.append_page( table )
+
+        # Event box hack so we can change its background
+        eb_title = gtk.EventBox()
+        eb_title.add( page_info.title )
+
+        al_side = gtk.Alignment()
+        al_side.add( page_info.sidebar_image )
+
+        # Event box hack so we can change its background
+        eb_side = gtk.EventBox()
+        eb_side.add( al_side )
+
+        table.attach(eb_title, 0, 2, 0, 1, gtk.EXPAND|gtk.FILL, 0)
+        table.attach(eb_side, 0, 1, 1, 2, 0, gtk.EXPAND|gtk.FILL)
+        table.attach(page_info.page, 1, 2, 1, 2, gtk.EXPAND|gtk.FILL, gtk.EXPAND|gtk.FILL)
+
+        self.set_page_colors( page_info.title, eb_title, eb_side )
+        self.set_title_font( page_info.title)
+        page_info.title.show()
+
+        if not self.current_page:
+            self.set_page( page_info )
+
+    def set_page(self, page_info):
+        self.emit( 'prepare', page_info.page )
+        self.current_page = page_info
+        self.set_button_state()
+        self.notebook.set_current_page( page_info.notebook_no )
+
+    def set_page_type(self, page, type):
+        page_info = self.find_page_info( page )
+        page_info.type = type
+
+    def set_page_title(self, page, title):
+        page_info = self.find_page_info( page )
+        page_info.title.set_text( title )
+
+    def set_page_side_image(self, page, pixbuf=None):
+        page_info = self.find_page_info( page )
+        page_info.sidebar_image.set_from_pixbuf( pixbuf )
+
+    def set_page_complete(self, page, complete):
+        page_info = self.find_page_info( page )
+        page_info.complete = complete
+        self.set_button_state()
+
+    # Unused gtk.Assistant API we won't reimplement
+    """
+    def get_current_page()
+    def set_current_page(page_num)
+    def get_n_pages()
+    def get_nth_page(page_num)
+    def prepend_page(page)
+    def insert_page(page, position)
+    def set_forward_page_func(page_func, data)
+    def get_page_type(page)
+    def get_page_title(page)
+    def set_page_header_image(page, pixbuf=None)
+    def get_page_header_image(page)
+    def get_page_side_image(page)
+    def get_page_complete(page)
+    def add_action_widget(child)
+    def remove_action_widget(child)
+    def update_buttons_state()
+    """
+
+gobject.type_register( Assistant )
diff --git a/lib/xgsch2pcb/new_project_gui.py b/lib/xgsch2pcb/new_project_gui.py
index bd59264..66a670e 100644
--- a/lib/xgsch2pcb/new_project_gui.py
+++ b/lib/xgsch2pcb/new_project_gui.py
@@ -26,8 +26,9 @@ _ = t.ugettext
 
 # xgsch2pcb-specific modules
 from templates import *
+from assistant import *
 
-class NewProjectAssistant(gtk.Assistant):
+class NewProjectAssistant(Assistant):
 
     __gsignals__ = { 'project-apply' :
                             ( gobject.SIGNAL_NO_RECURSE,
@@ -39,9 +40,6 @@ class NewProjectAssistant(gtk.Assistant):
 
     def assistant_apply(self, assistant):
 
-        # Change to the specified location
-        os.path.chdir( self.get_path() )
-
         # TODO: Why special case testing the writability of just this ONE output file?
         filename = self.get_filename()
 
@@ -133,7 +131,7 @@ class NewProjectAssistant(gtk.Assistant):
         return projectname
 
     def __init__(self, parent):
-        gtk.Assistant.__init__(self)
+        Assistant.__init__(self)
         self.set_transient_for( parent )
         self.set_position( gtk.WIN_POS_CENTER_ON_PARENT )
 
@@ -205,7 +203,7 @@ class NewProjectAssistant(gtk.Assistant):
 
         self.set_page_side_image(page,image)
 
-        self.set_page_type(page, gtk.ASSISTANT_PAGE_CONTENT)
+        self.set_page_type(page, ASSISTANT_PAGE_CONTENT)
         self.set_page_complete(page, True)
         self.template_page = page
 
@@ -245,10 +243,16 @@ class NewProjectAssistant(gtk.Assistant):
         label = gtk.Label(_("Location:"))
         label.set_alignment(0, 0.5)
         table.attach(label, 0, 1, 1, 2, gtk.FILL, 0)
+
+        def filebutton_selection_changed_cb(filechooser):
+            # Change to the specified location
+            os.chdir( self.get_path() )
+
         self.filebutton = gtk.FileChooserButton(_('Select project location...'))
-        #self.filebutton.connect( "selection-changed", self.event_filebutton_selection_changed )
+        self.filebutton.connect( "selection-changed", filebutton_selection_changed_cb )
         self.filebutton.set_local_only(True)
         self.filebutton.set_action(gtk.FILE_CHOOSER_ACTION_SELECT_FOLDER)
+
         table.attach(self.filebutton, 1, 2, 1, 2, gtk.FILL | gtk.EXPAND, 0)
 
         options.pack_start(table, False, False)
@@ -256,7 +260,7 @@ class NewProjectAssistant(gtk.Assistant):
         self.append_page(page)
         self.set_page_title(page, _("Create new project"))
         self.set_page_side_image(page,image)
-        self.set_page_type(page, gtk.ASSISTANT_PAGE_CONTENT)
+        self.set_page_type(page, ASSISTANT_PAGE_CONTENT)
         self.set_page_complete(page, False)
         self.filename_page = page
 
@@ -328,7 +332,7 @@ class NewProjectAssistant(gtk.Assistant):
         self.append_page(page)
         self.set_page_title(page, _("Create new project"))
         self.set_page_side_image(page,image)
-        self.set_page_type(page, gtk.ASSISTANT_PAGE_CONFIRM)
+        self.set_page_type(page, ASSISTANT_PAGE_CONFIRM)
         self.summary_page = page
 
 

commit 34e31d2340f909955156a5111c8bbe8e19b239ab
Author: Peter Clifton <pcjc2@xxxxxxxxx>
Date:   Thu Oct 4 21:50:19 2007 +0100

    Add a new project druid where we can select a starting template.

diff --git a/Makefile.am b/Makefile.am
index ca2c2fb..a447bd8 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -23,6 +23,8 @@ bin_SCRIPTS = xgsch2pcb
 pkglib_PYTHON = lib/xgsch2pcb/pcbmanager.py \
  lib/xgsch2pcb/gsch2pcbproject.py \
  lib/xgsch2pcb/gui.py \
+ lib/xgsch2pcb/new_project_gui.py \
+ lib/xgsch2pcb/templates.py \
  lib/xgsch2pcb/funcs.py
 
 nodist_pkglib_PYTHON = lib/xgsch2pcb/config.py
@@ -33,10 +35,13 @@ dist_noinst_SCRIPTS = tools/pygettext.py \
 EXTRA_DIST = xgsch2pcb.in lib/xgsch2pcb/config.py.in
 CLEANFILES = xgsch2pcb lib/xgsch2pcb/config.py
 
+templatesdir = @templatesdir@
+
 do_subst = sed -e 's,[@]prefix[@],$(prefix),g' \
                -e 's,[@]PYTHON[@],$(PYTHON),g' \
 				       -e 's,[@]VERSION[@],$(VERSION),g' \
 							 -e 's,[@]pkglibdir[@],$(pkglibdir),g' \
+							 -e 's,[@]templatesdir[@],$(templatesdir),g' \
 							 -e 's,[@]PACKAGE[@],$(PACKAGE),g'
 
 all: $(pkglib_PYTHON)
@@ -47,4 +52,4 @@ lib/xgsch2pcb/config.py: lib/xgsch2pcb/config.py.in Makefile
 xgsch2pcb: xgsch2pcb.in Makefile
 	$(do_subst) < $(srcdir)/xgsch2pcb.in > xgsch2pcb
 	chmod +x xgsch2pcb
- 
+
diff --git a/configure.ac b/configure.ac
index e2710ed..db228d9 100644
--- a/configure.ac
+++ b/configure.ac
@@ -51,7 +51,20 @@ AC_DEFUN([AC_PYTHON_MODULE],[
     fi
 ])
 
-    
+
+##########################################################################
+# Command line flags start
+#
+
+# Change default location for rc files
+AC_ARG_WITH(templatesdir, [  --with-templatesdir=path       Change where the template projects are found], [templatesdir=$withval],[templatesdir=$datarootdir/$PACKAGE/templates])
+
+AC_SUBST(templatesdir)
+
+#
+# Command line flags end
+##########################################################################
+
 ##########################################################################
 # Look for PyGTK
 #
diff --git a/lib/xgsch2pcb/config.py.in b/lib/xgsch2pcb/config.py.in
index 8d6d9b4..9612965 100644
--- a/lib/xgsch2pcb/config.py.in
+++ b/lib/xgsch2pcb/config.py.in
@@ -23,5 +23,5 @@ PACKAGE="@PACKAGE@"
 VERSION="@VERSION@"
 prefix="@prefix@"
 pkglibdir="@pkglibdir@"
-prefix="@prefix@"
+templatesdir="@templatesdir@"
 
diff --git a/lib/xgsch2pcb/gsch2pcbproject.py b/lib/xgsch2pcb/gsch2pcbproject.py
index 24bba3a..61996d5 100644
--- a/lib/xgsch2pcb/gsch2pcbproject.py
+++ b/lib/xgsch2pcb/gsch2pcbproject.py
@@ -52,7 +52,7 @@ class Gsch2PCBProject(gobject.GObject):
         else:
             self.output_name = None
 
-        if os.path.exists(self.filename):
+        if self.filename and os.path.exists(self.filename):
             self.load()
 
     def set_dirty(self, flag=True):
diff --git a/lib/xgsch2pcb/gui.py b/lib/xgsch2pcb/gui.py
index a8c7dee..445f4a4 100644
--- a/lib/xgsch2pcb/gui.py
+++ b/lib/xgsch2pcb/gui.py
@@ -31,6 +31,7 @@ import config
 from funcs import *
 from gsch2pcbproject import Gsch2PCBProject
 from pcbmanager import PCBManager
+from new_project_gui import NewProjectAssistant
 
 try:
     import gnomevfs
@@ -183,6 +184,7 @@ class MonitorWindow(gtk.Window):
         self.aboutdialog.set_authors(['Peter Brett', 'Peter Clifton'])
         gtk.about_dialog_set_url_hook(about_url_cb, None)
         self.aboutdialog.set_website('http://geda.seul.org/')
+        self.aboutdialog.set_transient_for( self )
 
         self.pcbmanager = None
         self.set_project(project)
@@ -457,62 +459,16 @@ class MonitorWindow(gtk.Window):
 
     def event_new_button_clicked( self, button ):
 
+        def new_project_apply( assistant, filename ):
+            self.set_project( filename )
+
         if self.close_project( _("creating a new project")):
             # User cancelled out of creating a new project
             return
 
-        d = gtk.FileChooserDialog(_('New project...'), self,
-                              (gtk.DIALOG_MODAL | 
-                               gtk.DIALOG_DESTROY_WITH_PARENT),
-                              (gtk.STOCK_CANCEL, gtk.RESPONSE_CANCEL,
-                               gtk.STOCK_NEW, gtk.RESPONSE_OK))
-        filter = gtk.FileFilter()
-        filter.add_pattern('*.gsch2pcb')
-        d.set_filter(filter)
-        d.set_do_overwrite_confirmation( True )
-        d.set_action(gtk.FILE_CHOOSER_ACTION_SAVE)
-
-        d.show_all()
-        r = d.run()
-        d.hide_all()
-
-        if r != gtk.RESPONSE_OK:
-            return
-
-        filename = d.get_filename()
-        if not filename.endswith('.gsch2pcb'):
-            filename += '.gsch2pcb'
-
-        # Create a new zero-length file
-        try:
-            open(filename, 'w').close()
-        except IOError, (errno, strerror):
-            md = gtk.MessageDialog(self,
-                                   (gtk.DIALOG_MODAL |
-                                    gtk.DIALOG_DESTROY_WITH_PARENT),
-                                   gtk.MESSAGE_ERROR,
-                                   gtk.BUTTONS_OK )
-
-            md.set_markup( _('<span weight="bold" size="larger">Could not create project</span>\n\nError %i: %s') % (errno, strerror) )
-            md.show_all()
-            md.run()
-            md.hide_all()
-            return
-        except:
-            #TODO: Provide a GUI Dialog for this
-            md = gtk.MessageDialog(self,
-                                   (gtk.DIALOG_MODAL |
-                                    gtk.DIALOG_DESTROY_WITH_PARENT),
-                                   gtk.MESSAGE_ERROR,
-                                   gtk.BUTTONS_OK )
-
-            md.set_markup( _('<span weight="bold" size="larger">Could not create project</span>') )
-            md.show_all()
-            md.run()
-            md.hide_all()
-            return
-
-        self.set_project(filename)
+        assistant = NewProjectAssistant(self)
+        assistant.connect( 'project-apply', new_project_apply )
+        assistant.show_all()
 
     def event_open_button_clicked( self, button ):
        
@@ -806,7 +762,7 @@ class AddPageDialog(gtk.Dialog):
                              gtk.DIALOG_DESTROY_WITH_PARENT),
                             (gtk.STOCK_CANCEL, gtk.RESPONSE_REJECT,
                              gtk.STOCK_OK, gtk.RESPONSE_ACCEPT))
-        
+        self.set_position( gtk.WIN_POS_CENTER_ON_PARENT )
 
         table = gtk.Table(2,2)
         
diff --git a/lib/xgsch2pcb/new_project_gui.py b/lib/xgsch2pcb/new_project_gui.py
new file mode 100644
index 0000000..bd59264
--- /dev/null
+++ b/lib/xgsch2pcb/new_project_gui.py
@@ -0,0 +1,380 @@
+# -*-Python-*-
+
+# xgsch2pcb - a GUI for gsch2pcb
+# Copyright (C) 2006 University of Cambridge
+# Copyright (C) 2007 Peter Clifton <pcjc2@xxxxxxxxx>
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
+
+import gtk, gtk.gdk, gobject
+
+import gettext
+t = gettext.translation('xgsch2pcb', fallback=True)
+_ = t.ugettext
+
+# xgsch2pcb-specific modules
+from templates import *
+
+class NewProjectAssistant(gtk.Assistant):
+
+    __gsignals__ = { 'project-apply' :
+                            ( gobject.SIGNAL_NO_RECURSE,
+                              gobject.TYPE_NONE,
+                              (gobject.TYPE_STRING, )),
+                   }
+
+    template = None
+
+    def assistant_apply(self, assistant):
+
+        # Change to the specified location
+        os.path.chdir( self.get_path() )
+
+        # TODO: Why special case testing the writability of just this ONE output file?
+        filename = self.get_filename()
+
+        # Create a new zero-length file
+        try:
+            if self.template:
+                # Apply any chosen template
+                templ = gsch2pcb_template( self.template )
+                templ.apply( self.get_projectname() )
+            else:
+                # Otherwise just write out a new project file
+                # Start with a filename of None to ensure that
+                # we don't load an existing project file.
+                new_project = Gsch2PCBProject( None,
+                                               self.get_projectname() )
+
+                new_project.save(self.get_filename())
+        except IOError, (errno, strerror):
+            md = gtk.MessageDialog(self,
+                                   (gtk.DIALOG_MODAL |
+                                    gtk.DIALOG_DESTROY_WITH_PARENT),
+                                   gtk.MESSAGE_ERROR,
+                                   gtk.BUTTONS_OK )
+
+            md.set_markup( _('<span weight="bold" size="larger">Could not create project</span>\n\nError %i: %s') % (errno, strerror) )
+            md.show_all()
+            md.run()
+            md.hide_all()
+            return
+        except:
+            md = gtk.MessageDialog(self,
+                                   (gtk.DIALOG_MODAL |
+                                    gtk.DIALOG_DESTROY_WITH_PARENT),
+                                   gtk.MESSAGE_ERROR,
+                                   gtk.BUTTONS_OK )
+
+            md.set_markup( _('<span weight="bold" size="larger">Could not create project</span>') )
+            md.show_all()
+            md.run()
+            md.hide_all()
+            return
+
+        self.emit('project-apply', filename)
+
+
+    def assistant_cancel(self, assistant):
+        self.destroy()
+
+    def assistant_close(self, assistant):
+        self.destroy()
+
+    def template_radio_toggled(self, button):
+        is_blank = self.blankradio.get_active()
+        self.templateview.set_sensitive(not is_blank)
+        if is_blank:
+            self.set_page_complete(self.template_page, True)
+        else:
+            # Synthesise a selection changed update on the tree-view
+            self.template_selection_changed(self.templateview.get_selection())
+
+    def template_selection_changed(self, treeselection):
+        [model,iters] = treeselection.get_selected()
+        if iters:
+            self.set_page_complete(self.template_page, True)
+            template_no = model.get_path(iters)[0]
+            [self.template, description] = model.get(iters,0,2)   # TODO: Remove magic numbers
+            self.description.set_text(description)
+        else:
+            self.set_page_complete(self.template_page, False)
+            self.template = None
+            self.description.set_text("")
+
+    def get_path(self):
+        path = self.filebutton.get_filename()
+        return path
+
+    def get_filename(self):
+        filename = self.filename.get_text()
+        # TODO: REMOVE HARDCODED EXTENTIONS - SHOULD THIS CODE GO HERE?
+        if not filename.endswith('.gsch2pcb'):
+            filename += '.gsch2pcb'
+        return filename
+
+    def get_projectname(self):
+        # TODO: Decide if this is the right way to do this
+        filename = self.get_filename()
+        # TODO: REMOVE HARDCODED EXTENTIONS - SHOULD THIS CODE GO HERE?
+        projectname = filename[0:filename.rfind( '.gsch2pcb' )]
+        return projectname
+
+    def __init__(self, parent):
+        gtk.Assistant.__init__(self)
+        self.set_transient_for( parent )
+        self.set_position( gtk.WIN_POS_CENTER_ON_PARENT )
+
+        # Render a stock "NEW" icon to display on the pages
+        image = self.render_icon( gtk.STOCK_NEW, gtk.ICON_SIZE_DIALOG )
+
+        # ====================
+        # Choose template page
+        # ====================
+
+        page = gtk.VBox()
+        page.set_border_width(12)
+        page.set_spacing(6)
+        label = gtk.Label(_("<b>Choose project template</b>"))
+        label.set_use_markup(True)
+        label.set_alignment(0, 0.5)
+        page.pack_start(label, False, False);
+
+        align = gtk.Alignment(0, 0, 1, 1)
+        page.pack_start(align, True, True)
+        align.set_padding(12,12,12,12)
+        options = gtk.VBox()
+        align.add(options)
+        options.set_spacing(6)
+        self.blankradio = gtk.RadioButton(label=_("Blank"))
+        self.templradio = gtk.RadioButton(group=self.blankradio,
+                                          label=_("From template:"))
+        options.pack_start(self.blankradio, False, False)
+        options.pack_start(self.templradio, False, False)
+
+        self.templatelist = gtk.ListStore(gobject.TYPE_STRING, gobject.TYPE_STRING, gobject.TYPE_STRING)
+        templates = list_templates()
+        for template in templates:
+            self.templatelist.append( template )
+
+        if len(templates) == 0:
+            self.templradio.set_sensitive(False)
+            self.templatelist.append( ['', _("(No templates found)"),''] )
+
+        textrenderer = gtk.CellRendererText()
+        textcol = gtk.TreeViewColumn(None, textrenderer, text=1)
+
+        self.templateview = gtk.TreeView(self.templatelist)
+        self.templateview.append_column(textcol)
+        self.templateview.set_headers_visible(False)
+        self.templateview.set_sensitive(False)
+
+        scrollwin = gtk.ScrolledWindow()
+        scrollwin.set_policy(gtk.POLICY_NEVER, gtk.POLICY_ALWAYS)
+        scrollwin.set_shadow_type(gtk.SHADOW_IN)
+        scrollwin.add(self.templateview)
+
+        align = gtk.Alignment(0, 0, 1, 1)
+        align.set_padding(0, 0, 18, 0)
+        align.add(scrollwin)
+        options.pack_start(align, True, True)
+
+        self.description = gtk.Label()
+
+        self.description.set_line_wrap(True)
+        self.description.set_alignment(0, 0)
+        self.description.set_padding(18, 0)
+        self.description.set_selectable(True)
+        self.description.set_max_width_chars(0)
+        options.pack_start(self.description, False, False)
+
+        self.append_page(page)
+        self.set_page_title(page, _("Create new project"))
+
+        self.set_page_side_image(page,image)
+
+        self.set_page_type(page, gtk.ASSISTANT_PAGE_CONTENT)
+        self.set_page_complete(page, True)
+        self.template_page = page
+
+        self.blankradio.connect('toggled', self.template_radio_toggled)
+        self.templradio.connect('toggled', self.template_radio_toggled)
+
+        treeselection = self.templateview.get_selection()
+        treeselection.connect('changed', self.template_selection_changed)
+
+        # ============================
+        # Choose project filename page
+        # ============================
+
+        page = gtk.VBox()
+        page.set_border_width(12)
+        page.set_spacing(6)
+        label = gtk.Label(_("<b>Choose project filename</b>"))
+        label.set_use_markup(True)
+        label.set_alignment(0, 0.5)
+        page.pack_start(label, False, False);
+
+        align = gtk.Alignment(0, 0, 1, 1)
+        page.pack_start(align, True, True)
+        align.set_padding(12,12,12,12)
+
+        options = gtk.VBox()
+        align.add(options)
+
+        table = gtk.Table(2,2)
+        table.set_col_spacings( 6 ) # TODO: Remove magic numbers
+        table.set_row_spacings( 6 ) # TODO: Remove magic numbers
+        label = gtk.Label(_("Project name:"))
+        label.set_alignment(0, 0.5)
+        table.attach(label, 0, 1, 0, 1, gtk.FILL, 0)
+        self.filename = gtk.Entry()
+        table.attach(self.filename, 1, 2, 0, 1, gtk.EXPAND | gtk.FILL, 0)
+        label = gtk.Label(_("Location:"))
+        label.set_alignment(0, 0.5)
+        table.attach(label, 0, 1, 1, 2, gtk.FILL, 0)
+        self.filebutton = gtk.FileChooserButton(_('Select project location...'))
+        #self.filebutton.connect( "selection-changed", self.event_filebutton_selection_changed )
+        self.filebutton.set_local_only(True)
+        self.filebutton.set_action(gtk.FILE_CHOOSER_ACTION_SELECT_FOLDER)
+        table.attach(self.filebutton, 1, 2, 1, 2, gtk.FILL | gtk.EXPAND, 0)
+
+        options.pack_start(table, False, False)
+
+        self.append_page(page)
+        self.set_page_title(page, _("Create new project"))
+        self.set_page_side_image(page,image)
+        self.set_page_type(page, gtk.ASSISTANT_PAGE_CONTENT)
+        self.set_page_complete(page, False)
+        self.filename_page = page
+
+        def filename_changed_cb( filename_entry ):
+            entrytext = self.filename.get_text()
+            self.set_page_complete(self.filename_page, (not entrytext == ""))
+
+        self.filename.connect('changed', filename_changed_cb)
+
+        # ================
+        # Creation summary
+        # ================
+
+        page = gtk.VBox()
+        page.set_border_width(12)
+        page.set_spacing(6)
+        label = gtk.Label(_("<b>Project summary</b>"))
+        label.set_use_markup(True)
+        label.set_alignment(0, 0.5)
+        page.pack_start(label, False, False);
+
+        align = gtk.Alignment(0, 0, 1, 1)
+        page.pack_start(align, True, True)
+        align.set_padding(12,12,12,12)
+
+        explanation = gtk.VBox()
+        align.add(explanation)
+
+        self.newfiles_frame = gtk.Frame(_("<b>New files to be created:</b>"))
+        self.newfiles_frame.get_label_widget().set_use_markup(True)
+        self.newfiles_frame.set_shadow_type(gtk.SHADOW_NONE)
+        explanation.pack_start(self.newfiles_frame, False, False)
+
+        align = gtk.Alignment(0, 0, 1, 1)
+        align.set_padding(0,12,12,12)
+        self.newfiles_frame.add(align)
+
+        self.newfiles_list = gtk.Label()
+        self.newfiles_list.set_alignment(0, 0.5)
+        self.newfiles_list.set_padding(0,12)
+        align.add(self.newfiles_list)
+
+        self.overwrite_frame = gtk.Frame(_("<b>The following files would be overwritten:</b>"))
+        self.overwrite_frame.get_label_widget().set_use_markup(True)
+        self.overwrite_frame.set_shadow_type(gtk.SHADOW_NONE)
+        explanation.pack_start(self.overwrite_frame, False, False)
+
+        align = gtk.Alignment(0, 0, 1, 1)
+        align.set_padding(0,12,12,12)
+        self.overwrite_frame.add(align)
+
+        vbox = gtk.VBox()
+        align.add(vbox)
+
+        self.overwrite_list = gtk.Label()
+        self.overwrite_list.set_alignment(0, 0.5)
+        self.overwrite_list.set_padding(0,12)
+        vbox.pack_start(self.overwrite_list, False, False)
+
+        self.confirm_overwrite = gtk.CheckButton(_("Confirm overwrite"))
+        vbox.pack_start(self.confirm_overwrite, False, False)
+
+        def confirm_overwrite_toggled_cb( togglebutton ):
+            confirmed = togglebutton.get_active()
+            self.set_page_complete(self.summary_page, confirmed)
+
+        self.confirm_overwrite.connect( 'toggled', confirm_overwrite_toggled_cb )
+
+        self.append_page(page)
+        self.set_page_title(page, _("Create new project"))
+        self.set_page_side_image(page,image)
+        self.set_page_type(page, gtk.ASSISTANT_PAGE_CONFIRM)
+        self.summary_page = page
+
+
+        def check_overwrites():
+            if self.template:
+                templ = gsch2pcb_template( self.template )
+                file_list = templ.would_create( self.get_projectname() )
+            else:
+                file_list = [self.get_filename()]
+            newfiles_list = []
+            overwrite_list = []
+            for file in file_list:
+                if os.path.exists( file ):
+                    overwrite_list.append( file )
+                else:
+                    newfiles_list.append( file )
+            return [newfiles_list, overwrite_list]
+
+        def assistant_prepare_cb(assistant, page):
+            if page is self.summary_page:
+                # Summary page before creating the new project on disk
+                [newfiles_list, overwrite_list] = check_overwrites()
+                self.newfiles_list.set_text( '\n'.join( newfiles_list ) )
+                self.overwrite_list.set_text( '\n'.join( overwrite_list ) )
+
+                no_newfiles = (newfiles_list == [])
+                if no_newfiles:
+                    self.newfiles_frame.hide_all()
+                else:
+                    self.newfiles_frame.show_all()
+
+                no_overwrite = (overwrite_list == [])
+                if no_overwrite:
+                    # No files will be overwritten, we are done
+                    self.overwrite_frame.hide_all()
+                    self.set_page_complete(self.summary_page, True)
+                else:
+                    # Need confirmation before overwriting files
+                    self.overwrite_frame.show_all()
+                    self.confirm_overwrite.set_active(False)
+
+        # GtkAssistant signals
+        self.connect('prepare', assistant_prepare_cb  )
+        self.connect('apply',   self.assistant_apply  )
+        self.connect('cancel',  self.assistant_cancel )
+        self.connect('close',   self.assistant_close  )
+
+
+gobject.type_register( NewProjectAssistant )
diff --git a/lib/xgsch2pcb/templates.py b/lib/xgsch2pcb/templates.py
new file mode 100644
index 0000000..9159aa5
--- /dev/null
+++ b/lib/xgsch2pcb/templates.py
@@ -0,0 +1,137 @@
+# -*-Python-*-
+
+# xgsch2pcb - a GUI for gsch2pcb
+# Copyright (C) 2006 University of Cambridge
+# Copyright (C) 2007 Peter Clifton <pcjc2@xxxxxxxxx>
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
+
+import os
+import shutil
+
+# xgsch2pcb-specific modules
+import config
+from gsch2pcbproject import Gsch2PCBProject
+
+def template_path( template, file ):
+    path = os.path.join( config.templatesdir, template )
+    path = os.path.join( path, file )
+    return path
+
+
+def replace_project_name( file, project ):
+    """
+Produce the filename which would exist for a given project name.
+
+This implementation simply replaces the first occurance of the string
+'template' with the project name.
+
+It should only be called with relative paths, otherwise any prefix directory
+containing the string template (e.g. the templates directory!) would be
+replaced instead of the desired portion of the file name.
+    """
+    return file.replace( 'template', project, 1 )
+
+
+def list_templates():
+
+    template_list = []
+
+    try:
+        filelist = os.listdir( config.templatesdir )
+    except:
+        print "Couldn't list templates directory"
+        return template_list
+
+    filelist.sort()
+
+    for template in filelist:
+        try:
+            templ = gsch2pcb_template( template )
+            [name, description] = templ.read_description()
+            template_list.append( [template, name, description] )
+        except:
+            print "Couldn't read a template in dir " + template
+
+    return template_list
+
+
+class gsch2pcb_template:
+
+    def __init__(self, template):
+        self.template = template
+        self.filename = template_path( template, 'template.gsch2pcb')
+
+        # Load the project into memory
+        self.template_project = Gsch2PCBProject( self.filename )
+
+    def read_description(self):
+
+        file = open( template_path( self.template, 'template.txt' ), 'r' )
+        name = file.readline().strip()
+        blank = file.readline()
+        if blank != "\n":
+            print "Invalid file format for this template"
+            file.close()
+        # Join remaining lines in the file to a single string
+        description = "".join( file.readlines() )
+        file.close()
+        return [name, description]
+
+
+    def would_create(self, projectname):
+        """Returns a list of files which this templates would create"""
+        # TODO: Should this be a relative or absolute path??
+
+        filelist = []
+
+        # Would create a new project file:
+        # TODO: Should the template have this as a relative path to some dir?
+        filelist.append( os.path.basename( self.template_project.filename ) )
+        # Would create the output file:
+        # TODO: REMOVE HARDCODED EXTENSION
+        filelist.append( self.template_project.output_name + '.pcb' )
+        # would create the pages:
+        filelist.extend( self.template_project.pages )
+
+        # Substitute the templatized filenames for ones matching the new project name
+        new_filelist = []
+        for file in filelist:
+          new_filelist.append( replace_project_name( file, projectname ) )
+
+        return new_filelist
+
+
+    def apply(self, projectname):
+
+        # Copy the output file
+        output_name = self.template_project.output_name
+        new_output_name = replace_project_name( output_name, projectname )
+        output_file = output_name + '.pcb'         # TODO: REMOVE HARDCODED EXTENSION
+        new_output_file = new_output_name + '.pcb' # TODO: REMOVE HARDCODED EXTENSION
+        shutil.copy( template_path( self.template, output_file ), new_output_file )
+
+        # Create a new gsch2pcb project in the new location, with the new output filename
+        # TODO: REMOVE HARDCODED EXTENSION
+        new_project = Gsch2PCBProject( projectname + '.gsch2pcb', new_output_name )
+
+        # Copy schematic pages, and add to the new project
+        for page_file in self.template_project.pages:
+            new_page_file = replace_project_name( page_file, projectname )
+            shutil.copy( template_path( self.template, page_file ), new_page_file )
+            new_project.add_page( new_page_file )
+
+        # TODO: We could just hand off the new project file without saving of course?
+        new_project.save()

commit c5fe3e0cc349f0facbb37d9a24f9f2256858124f
Author: Peter Clifton <pcjc2@xxxxxxxxx>
Date:   Sun Sep 30 18:25:22 2007 +0100

    Comment out GUI code to change the layout name in use. (Unimplemented)
    
    Hide unimplemented placeholders before a released version.

diff --git a/lib/xgsch2pcb/gui.py b/lib/xgsch2pcb/gui.py
index a070d4a..a8c7dee 100644
--- a/lib/xgsch2pcb/gui.py
+++ b/lib/xgsch2pcb/gui.py
@@ -159,10 +159,12 @@ class MonitorWindow(gtk.Window):
         self.updatepcbbutton.connect("clicked",
                        self.event_updatepcb_button_clicked)
 
+        """
         self.changepcbbutton = gtk.Button(_("Change layout file"))
         vbox.pack_start(self.changepcbbutton, False, False)
         self.changepcbbutton.connect("clicked",
                        self.event_changepcb_button_clicked)
+        """
 
 
         def about_url_cb(dialog, link, user_data):
@@ -438,6 +440,7 @@ class MonitorWindow(gtk.Window):
         self.update_layout()
     
     # TODO: Implement me
+    """
     def event_changepcb_button_clicked(self, button):
 
         d = gtk.MessageDialog(self,
@@ -449,7 +452,7 @@ class MonitorWindow(gtk.Window):
         d.show_all()
         d.run()
         d.hide_all()
-
+    """
 
 
     def event_new_button_clicked( self, button ):
@@ -624,7 +627,7 @@ class MonitorWindow(gtk.Window):
         self.pcbentry.set_sensitive( managers )
         self.editpcbbutton.set_sensitive( managers and (not pcbrunning) )
         self.updatepcbbutton.set_sensitive( managers and pages_available )
-        self.changepcbbutton.set_sensitive( managers )
+        #self.changepcbbutton.set_sensitive( managers )
 
 
     def handle_quit (self):




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