home *** CD-ROM | disk | FTP | other *** search
- # Source Generated with Decompyle++
- # File: in.pyc (Python 2.6)
-
- from pygments.plugin import find_plugin_styles
- from pygments.util import ClassNotFound
- STYLE_MAP = {
- 'default': 'default::DefaultStyle',
- 'emacs': 'emacs::EmacsStyle',
- 'friendly': 'friendly::FriendlyStyle',
- 'colorful': 'colorful::ColorfulStyle',
- 'autumn': 'autumn::AutumnStyle',
- 'murphy': 'murphy::MurphyStyle',
- 'manni': 'manni::ManniStyle',
- 'monokai': 'monokai::MonokaiStyle',
- 'perldoc': 'perldoc::PerldocStyle',
- 'pastie': 'pastie::PastieStyle',
- 'borland': 'borland::BorlandStyle',
- 'trac': 'trac::TracStyle',
- 'native': 'native::NativeStyle',
- 'fruity': 'fruity::FruityStyle',
- 'bw': 'bw::BlackWhiteStyle',
- 'vs': 'vs::VisualStudioStyle',
- 'tango': 'tango::TangoStyle' }
-
- def get_style_by_name(name):
-
- try:
- mod = __import__('pygments.styles.' + mod, None, None, [
- cls])
- except ImportError:
- None if name in STYLE_MAP else name == found_name
- None if name in STYLE_MAP else name == found_name
- if builtin:
- pass
- raise ClassNotFound('Could not find style module %r' % mod + ', though it should be builtin' + '.')
- except:
- None if name in STYLE_MAP else name == found_name
-
-
- try:
- return getattr(mod, cls)
- except AttributeError:
- None if name in STYLE_MAP else name == found_name
- None if name in STYLE_MAP else name == found_name
- raise ClassNotFound('Could not find style class %r in style module.' % cls)
- except:
- None if name in STYLE_MAP else name == found_name
-
-
-
- def get_all_styles():
- for name in STYLE_MAP:
- yield name
-
- for name, _ in find_plugin_styles():
- yield name
-
-
-