Lines Matching refs:markup
1486 markup = None
1488 markup = markup_name
1489 markup_attrs = markup
1496 or (markup and self._matches(markup, self.name))
1497 or (not markup and self._matches(markup_name, self.name))):
1516 if markup:
1517 found = markup
1525 def search(self, markup): argument
1530 if hasattr(markup, '__iter__') and not isinstance(markup, (Tag, basestring)):
1531 for element in markup:
1538 elif isinstance(markup, Tag):
1540 found = self.search_tag(markup)
1542 elif isinstance(markup, NavigableString) or \
1543 isinstance(markup, basestring):
1544 if not self.name and not self.attrs and self._matches(markup, self.text):
1545 found = markup
1548 "I don't know how to match against a %s" % markup.__class__)
1551 def _matches(self, markup, match_against): argument
1554 if isinstance(markup, list) or isinstance(markup, tuple):
1566 return (whitespace_re.split(match_against) == markup)
1568 for item in markup:
1575 return markup is not None
1578 return match_against(markup)
1582 if isinstance(markup, Tag):
1583 markup = markup.name
1586 markup = self._normalize_search_value(markup)
1588 if markup is None:
1594 return markup == match_against
1598 return match_against.search(markup)
1603 return markup in match_against