[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
gnue/gnuef README client/gfclient src/UIwxpytho...
From: |
James Thompson |
Subject: |
gnue/gnuef README client/gfclient src/UIwxpytho... |
Date: |
Mon, 06 Nov 2000 20:31:09 -0800 |
CVSROOT: /cvs
Module name: gnue
Changes by: James Thompson <address@hidden> 00/11/06 20:31:09
Modified files:
gnuef : README
gnuef/client : gfclient
gnuef/src : UIwxpython.py
Added files:
gnuef/samples/zipcode: zipcode.gfd
Removed files:
gnuef : pg.py.patch
gnuef/samples/zipcode: zip_code.gfd
Log message:
README updates
renamed zip_code.gfd to zipcode.gfd
removed profiler code
partial addition of new login form (not active in this code checkin)
CVSWeb URLs:
http://subversions.gnu.org/cgi-bin/cvsweb/gnue/gnuef/README.diff?r1=1.10&r2=1.11
http://subversions.gnu.org/cgi-bin/cvsweb/gnue/gnuef/pg.py.patch.diff?r1=1.1&r2=NONE
http://subversions.gnu.org/cgi-bin/cvsweb/gnue/gnuef/client/gfclient.diff?r1=1.2&r2=1.3
http://subversions.gnu.org/cgi-bin/cvsweb/gnue/gnuef/samples/zipcode/zipcode.gfd.diff?r1=NONE&r2=1.1
http://subversions.gnu.org/cgi-bin/cvsweb/gnue/gnuef/samples/zipcode/zip_code.gfd.diff?r1=1.15&r2=NONE
http://subversions.gnu.org/cgi-bin/cvsweb/gnue/gnuef/src/UIwxpython.py.diff?r1=1.26&r2=1.27
Patches:
Index: gnue/gnuef/README
diff -u gnue/gnuef/README:1.10 gnue/gnuef/README:1.11
--- gnue/gnuef/README:1.10 Tue Oct 31 21:06:33 2000
+++ gnue/gnuef/README Mon Nov 6 20:31:09 2000
@@ -44,7 +44,7 @@
To access postgresql databases
- PyGreSql 3.0 (http://www.druid.net/pygresql/)
+ PyGreSql 3.1 (http://www.druid.net/pygresql/)
The readme is out dated on this package. If you have
distutils from python installed(if you dont then install it)
then simply do:
@@ -52,18 +52,11 @@
su
python setup.py install
+To Test:
- Note: If you're using tables w/o primary keys defined
- you'll need to apply the pg.py.patch file to the
- pg.py included with PyGreSQL 3.0. You can patch by
-
- patch pg.py pg.py.patch
-
-To use:
-
Run tests by switching to client dir and doing
- gfclient -u=[text|gui] ../samples/form.gfd
+ ./gfclient -u=[text|gui] ../samples/form.gfd
If you run without -u option it will default to gui or wxWindows.
@@ -83,6 +76,19 @@
F9 - Executes Query
F12 - Create new record
+
+To install:
+ If you wish to work on development of gnuef you'll
+ run ./autogen.sh from the top gnuef directory. The
+ only part of this in use in the creation of some
+ symlinks in the client directory. There is no need
+ to run configure, make, or make install.
+
+ To install in usable area
+
+ python setup.py build
+ python setup.py install
+
GFD format notes:
to add an additional attribute to an element just, well, add it :)
@@ -112,3 +118,5 @@
There is no attribute validation currently. Later this will likely be
done in a DTD. So be extra careful. :)
+
+
Index: gnue/gnuef/client/gfclient
diff -u gnue/gnuef/client/gfclient:1.2 gnue/gnuef/client/gfclient:1.3
--- gnue/gnuef/client/gfclient:1.2 Sat Nov 4 20:14:52 2000
+++ gnue/gnuef/client/gfclient Mon Nov 6 20:31:09 2000
@@ -12,7 +12,6 @@
# HISTORY:
# Copyright (c) 2000 James Thompson
#
-import profile
import pstats
import os
import sys
@@ -80,11 +79,12 @@
ui.mainLoop()
if __name__ == '__main__':
- profile.run("GFClient().run()","runstats")
- p = pstats.Stats('runstats')
- p.sort_stats('cumulative').print_stats(50)
+## import profile
+## profile.run("GFClient().run()","runstats")
+## p = pstats.Stats('runstats')
+## p.sort_stats('cumulative').print_stats(50)
-
+ GFClient().run()
Index: gnue/gnuef/src/UIwxpython.py
diff -u gnue/gnuef/src/UIwxpython.py:1.26 gnue/gnuef/src/UIwxpython.py:1.27
--- gnue/gnuef/src/UIwxpython.py:1.26 Sat Nov 4 20:14:52 2000
+++ gnue/gnuef/src/UIwxpython.py Mon Nov 6 20:31:09 2000
@@ -435,8 +435,8 @@
helpMenu = wxMenu()
print "About: ", helpMenu.Append( 300, "&About...", "Display info about
gnuef" )
-# EVT_MENU(self, 300, self.OnAbout)
- EVT_MENU(self, 300, self.OnLogin)
+ EVT_MENU(self, 300, self.OnAbout)
+# EVT_MENU(self, 300, self.getLogin)
menuBar = wxMenuBar()
@@ -482,28 +482,6 @@
dlg.ShowModal()
dlg.Destroy()
- def OnLogin(self, event):
- dlg = wxDialog(self.frame, -1, "Login
Required",wxPoint(-1,-1),wxSize(300,100))
- dlg.SetBackgroundColour(wxWHITE)
- dlg.SetAutoLayout(true)
-
- entryBox = wxBoxSizer(wxVERTICAL)
- entryBox.Add(wxStaticText(dlg, 1010, "Username"), 0)
- entryBox.Add(wxTextCtrl(dlg, 1020),0)
- entryBox.Add(wxStaticText(dlg, 1010, "Password"), 0)
- entryBox.Add(wxTextCtrl(dlg, 1030,"",
wxPoint(-1,-1),wxSize(-1,-1),wxTE_PASSWORD),0)
-
- bmp = wxImage('../src/gnue.bmp', wxBITMAP_TYPE_BMP).ConvertToBitmap()
-
-
- mainBox = wxBoxSizer(wxHORIZONTAL)
- mainBox.Add(wxStaticBitmap(dlg,-1, bmp, wxPoint(-1,
-1),wxSize(bmp.GetWidth(), bmp.GetHeight())),0)
- mainBox.Add(entryBox,0)
-
- dlg.SetSizer( mainBox )
- dlg.ShowModal()
- dlg.Destroy()
-
def getLogin(self,event):
print "trying to get it now dude"
dlg = wxDialog(self.frame, -1, "Login Required")
@@ -579,6 +557,55 @@
return widget
+ #
+ # Login support (not activated in this code)
+ #
+ def getLogin(self, event):
+ self.dlg = wxDialog(self.frame, -1, "Login Required for %s" %
event.data.dbname,wxPoint(-1,-1),wxSize(300,100))
+ self.dlg.SetBackgroundColour(wxWHITE)
+ self.dlg.SetAutoLayout(true)
+
+ bmp = wxImage('../src/gnue.bmp', wxBITMAP_TYPE_BMP).ConvertToBitmap()
+ self.usernameEntry = wxTextCtrl(self.dlg, 1020)
+ self.passwordEntry = wxTextCtrl(self.dlg, 1030,"",
wxPoint(-1,-1),wxSize(-1,-1),wxTE_PASSWORD)
+
+ EVT_CHAR(self.usernameEntry, self.usernameEventTrap)
+ EVT_CHAR(self.passwordEntry, self.passwordEventTrap)
+
+ entryBox = wxBoxSizer(wxVERTICAL)
+ entryBox.Add(wxStaticText(self.dlg, 1010, "Username"), 0)
+ entryBox.Add(self.usernameEntry,0)
+ entryBox.Add(wxStaticText(self.dlg, 1010, "Password"), 0)
+ entryBox.Add(self.passwordEntry,0)
+
+ mainBox = wxBoxSizer(wxHORIZONTAL)
+ mainBox.Add(wxStaticBitmap(self.dlg,-1, bmp, wxPoint(-1,
-1),wxSize(bmp.GetWidth(), bmp.GetHeight())),0)
+ mainBox.Add(entryBox,0)
+ self.usernameEntry.SetFocus()
+
+ self.dlg.SetSizer( mainBox )
+ self.dlg.ShowModal()
+ self.dlg.Destroy()
+
+
+ def usernameEventTrap(self, event):
+ if event.KeyCode() == WXK_RETURN:
+ self.passwordEntry.SetFocus()
+ else:
+ event.Skip()
+
+ def passwordEventTrap(self, event):
+ if event.KeyCode() == WXK_RETURN:
+ print "User %s" % (self.usernameEntry.GetValue())
+ print "Pass %s" % (self.passwordEntry.GetValue())
+ self.dispatchEvent(GFEvent('authenticationEVENT',\
+ [self.usernameEntry.GetValue(),
+ self.passwordEntry.GetValue()
+ ]))
+ self.dlg.Destroy()
+ else:
+ event.Skip()
+
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- gnue/gnuef README client/gfclient src/UIwxpytho...,
James Thompson <=