[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
gnue common/scripts/gnuedtd common/src/GConditi...
From: |
Jason Cater |
Subject: |
gnue common/scripts/gnuedtd common/src/GConditi... |
Date: |
Sun, 27 Oct 2002 21:10:26 -0500 |
CVSROOT: /home/cvs
Module name: gnue
Changes by: Jason Cater <address@hidden> 02/10/27 21:10:26
Modified files:
common/scripts : gnuedtd
common/src : GConditions.py GDataSource.py
forms/doc : Developers-Guide.sxw
forms/src : GFParser.py
Added files:
common/utils : doc-xml-attrs-openoffice.py
Log message:
added form tags to dev guide; created a python script to autocreate OO
docs from G?Parser.py files; misc consistency checks
CVSWeb URLs:
http://savannah.gnu.org/cgi-bin/viewcvs/gnue/common/scripts/gnuedtd.diff?cvsroot=OldCVS&tr1=1.9&tr2=1.10&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/gnue/common/src/GConditions.py.diff?cvsroot=OldCVS&tr1=1.18&tr2=1.19&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/gnue/common/src/GDataSource.py.diff?cvsroot=OldCVS&tr1=1.41&tr2=1.42&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/gnue/common/utils/doc-xml-attrs-openoffice.py?cvsroot=OldCVS&rev=1.1
http://savannah.gnu.org/cgi-bin/viewcvs/gnue/forms/doc/Developers-Guide.sxw.diff?cvsroot=OldCVS&tr1=1.11&tr2=1.12&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/gnue/forms/src/GFParser.py.diff?cvsroot=OldCVS&tr1=1.72&tr2=1.73&r1=text&r2=text
Patches:
Index: gnue/common/scripts/gnuedtd
diff -c gnue/common/scripts/gnuedtd:1.9 gnue/common/scripts/gnuedtd:1.10
*** gnue/common/scripts/gnuedtd:1.9 Wed Oct 23 09:56:52 2002
--- gnue/common/scripts/gnuedtd Sun Oct 27 21:10:26 2002
***************
*** 88,94 ****
for element in xmlElements.keys():
# Get a mapping of all parent tags
if xmlElements[element].has_key('ParentTags') and \
! xmlElements[element]['ParentTags'] != None:
for parent in xmlElements[element]['ParentTags']:
if not self.parentMappings.has_key(parent):
self.parentMappings[parent] = {}
--- 88,94 ----
for element in xmlElements.keys():
# Get a mapping of all parent tags
if xmlElements[element].has_key('ParentTags') and \
! xmlElements[element]['ParentTags'] != None:
for parent in xmlElements[element]['ParentTags']:
if not self.parentMappings.has_key(parent):
self.parentMappings[parent] = {}
***************
*** 222,228 ****
# Line wrap a string. Note, this eliminates redundant spacing
#
def wrap(self, indent, text, firstindent=None):
! if firstindent == None:
firstindent = indent
pos = 0
--- 222,228 ----
# Line wrap a string. Note, this eliminates redundant spacing
#
def wrap(self, indent, text, firstindent=None):
! if firstindent == None:
firstindent = indent
pos = 0
***************
*** 267,285 ****
'<!-- DEPRECATED: Use of the <%s> element has been deprecated %s
-->' % \
(element, deprecated),0))
! if self.parentMappings.has_key(element):
es = self.parentMappings[element].keys()
! else:
es = []
! if len(es):
es.insert(0,'Child elements of %s' % element)
self.elementStack.append(es)
!
descr = self.default(self.xmlElements[element],'Description','')
if len(descr):
self.dest.write(self.wrap(5,
! '<!-- %s -->' % (description), 0))
elemdef = "<!ELEMENT %s" % element
indent = len(elemdef) + 2
--- 267,285 ----
'<!-- DEPRECATED: Use of the <%s> element has been deprecated %s
-->' % \
(element, deprecated),0))
! if self.parentMappings.has_key(element):
es = self.parentMappings[element].keys()
! else:
es = []
! if len(es):
es.insert(0,'Child elements of %s' % element)
self.elementStack.append(es)
!
descr = self.default(self.xmlElements[element],'Description','')
if len(descr):
self.dest.write(self.wrap(5,
! '<!-- %s -->' % (descr), 0))
elemdef = "<!ELEMENT %s" % element
indent = len(elemdef) + 2
***************
*** 291,301 ****
for child in m:
required = self.default(self.xmlElements[child], 'Required', 0)
single = self.default(self.xmlElements[child],'SingleInstance',0)
! if single and required:
children.append("%s" % child)
! elif single:
children.append("%s?" % child)
! elif required:
children.append("%s+" % child)
else:
children.append("%s*" % child)
--- 291,301 ----
for child in m:
required = self.default(self.xmlElements[child], 'Required', 0)
single = self.default(self.xmlElements[child],'SingleInstance',0)
! if single and required:
children.append("%s" % child)
! elif single:
children.append("%s?" % child)
! elif required:
children.append("%s+" % child)
else:
children.append("%s*" % child)
***************
*** 304,311 ****
children.append ('#PCDATA')
elemdef = elemdef + (" (%s)" % string.join(children,', '))
!
! else:
elemdef = elemdef + " EMPTY"
elemdef = elemdef + ">\n"
--- 304,311 ----
children.append ('#PCDATA')
elemdef = elemdef + (" (%s)" % string.join(children,', '))
!
! else:
elemdef = elemdef + " EMPTY"
elemdef = elemdef + ">\n"
***************
*** 319,325 ****
otherAtts = []
atts = self.default(self.xmlElements[element], 'Attributes',{}).keys()
atts.sort()
! for att in atts:
req = self.default(self.xmlElements[element]['Attributes'][att],
'Required',0)
--- 319,325 ----
otherAtts = []
atts = self.default(self.xmlElements[element], 'Attributes',{}).keys()
atts.sort()
! for att in atts:
req = self.default(self.xmlElements[element]['Attributes'][att],
'Required',0)
Index: gnue/common/src/GConditions.py
diff -c gnue/common/src/GConditions.py:1.18 gnue/common/src/GConditions.py:1.19
*** gnue/common/src/GConditions.py:1.18 Sat Sep 28 01:47:43 2002
--- gnue/common/src/GConditions.py Sun Oct 27 21:10:26 2002
***************
*** 154,163 ****
def getXMLelements(updates={}):
xmlElements = {
! 'conditions': {
! 'BaseClass': GConditions,
! 'SingleInstance': 1,
! 'ParentTags': None },
'condition': {
'BaseClass': GCondition,
'ParentTags': ('conditions','and','or','not','negate') },
--- 154,163 ----
def getXMLelements(updates={}):
xmlElements = {
! ## 'conditions': {
! ## 'BaseClass': GConditions,
! ## 'SingleInstance': 1,
! ## 'ParentTags': None },
'condition': {
'BaseClass': GCondition,
'ParentTags': ('conditions','and','or','not','negate') },
Index: gnue/common/src/GDataSource.py
diff -c gnue/common/src/GDataSource.py:1.41 gnue/common/src/GDataSource.py:1.42
*** gnue/common/src/GDataSource.py:1.41 Tue Oct 8 16:39:19 2002
--- gnue/common/src/GDataSource.py Sun Oct 27 21:10:26 2002
***************
*** 424,430 ****
# Add conditional elements
xmlElements.update(
GConditions.getXMLelements(
! {'conditions':{'ParentTags':('datasource',) } } ))
for alteration in updates.keys():
xmlElements[alteration].update(updates[alteration])
--- 424,430 ----
# Add conditional elements
xmlElements.update(
GConditions.getXMLelements(
! {'condition':{'ParentTags':('datasource',) } } ))
for alteration in updates.keys():
xmlElements[alteration].update(updates[alteration])
Index: gnue/forms/doc/Developers-Guide.sxw
Index: gnue/forms/src/GFParser.py
diff -c gnue/forms/src/GFParser.py:1.72 gnue/forms/src/GFParser.py:1.73
*** gnue/forms/src/GFParser.py:1.72 Tue Sep 17 20:27:50 2002
--- gnue/forms/src/GFParser.py Sun Oct 27 21:10:26 2002
***************
*** 139,145 ****
'host': {
'Required': 0,
'Typecast': GTypecast.text } },
- 'Deprecated': 'Use the external connections file format.',
'ParentTags': ('form',) },
'page': {
--- 139,144 ----
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- gnue common/scripts/gnuedtd common/src/GConditi...,
Jason Cater <=