/[ascend]/trunk/models/johnpye/listnotes.py
ViewVC logotype

Contents of /trunk/models/johnpye/listnotes.py

Parent Directory Parent Directory | Revision Log Revision Log


Revision 912 - (show annotations) (download) (as text)
Fri Oct 27 07:18:21 2006 UTC (18 years, 2 months ago) by johnpye
File MIME type: text/x-python
File size: 675 byte(s)
Removed BBOXWHINE (replaced with some one-time-only warnings for the moment)
Added ExtMethodDestroyFn to allow 'user_data' associated with external methods to be destroyed.
Implemented the destroy fn through to 'extpy' module.
Added 'name' as an extra parameter in the user_data for extpy, to help with debug msgs.
Moved 'solvernotes' to a file of its own (was part of listnotes.py)
Added 'repaint' to GTK 'tools' menu (for debugging)
Added 'python.h' to top of library, type files (pygtk) to stop silly warnings.
Working on some diagnosing of problems as noted in Simulation::checkInstance.
Removed some old comments from namio.h and others.
Renamed 'blsys' to 'sys' in integrator.c.
Some work on fixing up the J*v function for IDA (not yet complete).
Added new 'destroyfn' parameter (as NULL) to all calls to 'CreateUserFunctionMethod'.
1 import ascpy
2 import extpy
3 browser = extpy.getbrowser()
4
5 def listnotes(self):
6 """ make a list of NOTES for the present model """
7 self = ascpy.Registry().getInstance('context')
8
9 db = browser.library.getAnnotationDatabase()
10 notes = db.getNotes(self.getType(),ascpy.SymChar("solver"))
11
12 for i in range(1,len(notes)):
13 mm = notes[i].getMethod()
14 ll = notes[i].getLanguage()
15 ii = notes[i].getId()
16 tt = notes[i].getText()
17 s = "type = %s, method = %s, lang = %s, id = %s, text = %s" % (notes[i].getType(), mm, ll, ii, tt)
18 print "NOTES:",s
19 browser.reporter.reportNote(s)
20
21 # note: 'setup_solver' moved to 'solvernotes.py' (and renamed)
22
23 extpy.registermethod(listnotes)

john.pye@anu.edu.au
ViewVC Help
Powered by ViewVC 1.1.22