summaryrefslogtreecommitdiff
path: root/BeautifulSoup.py
diff options
context:
space:
mode:
authorLeonard Richardson <leonard.richardson@canonical.com>2009-04-08 18:14:26 -0400
committerLeonard Richardson <leonard.richardson@canonical.com>2009-04-08 18:14:26 -0400
commit95b59dd7b8709e8fb003bcdc4973682483006a4f (patch)
tree824c2b78859715dd9a97f1bcd7c45dbbe9ceac9f /BeautifulSoup.py
parente7435b9f7c2779f7930aa2a8e5f25c6efc7f4b21 (diff)
Changed more tag sets to have lowercase names.
Diffstat (limited to 'BeautifulSoup.py')
-rw-r--r--BeautifulSoup.py12
1 files changed, 6 insertions, 6 deletions
diff --git a/BeautifulSoup.py b/BeautifulSoup.py
index 1427ad2..f05e867 100644
--- a/BeautifulSoup.py
+++ b/BeautifulSoup.py
@@ -1007,8 +1007,8 @@ def buildTagMap(default, *args):
class TreeBuilder(Entities):
smartQuotesTo = Entities.XML_ENTITIES
- PRESERVE_WHITESPACE_TAGS = set()
- QUOTE_TAGS = set()
+ preserve_whitespace_tags = set()
+ quote_tags = set()
self_closing_tags = set()
assume_html = False
@@ -1265,8 +1265,8 @@ class HTMLParserBuilder(XMLParserBuilder):
builder."""
assume_html = True
- PRESERVE_WHITESPACE_TAGS = set(['pre', 'textarea'])
- QUOTE_TAGS = set(['script', 'textarea'])
+ preserve_whitespace_tags = set(['pre', 'textarea'])
+ quote_tags = set(['script', 'textarea'])
self_closing_tags = set(['br' , 'hr', 'input', 'img', 'meta',
'spacer', 'link', 'frame', 'base'])
@@ -1439,7 +1439,7 @@ class BeautifulStoneSoup(Tag):
currentData = u''.join(self.currentData)
if (currentData.translate(self.STRIP_ASCII_SPACES) == '' and
not set([tag.name for tag in self.tagStack]).intersection(
- self.builder.PRESERVE_WHITESPACE_TAGS)):
+ self.builder.preserve_whitespace_tags)):
if '\n' in currentData:
currentData = '\n'
else:
@@ -1551,7 +1551,7 @@ class BeautifulStoneSoup(Tag):
self.pushTag(tag)
if selfClosing or self.builder.isSelfClosingTag(name):
self.popTag()
- if name in self.builder.QUOTE_TAGS:
+ if name in self.builder.quote_tags:
#print "Beginning quote (%s)" % name
self.quoteStack.append(name)
self.literal = 1