onedark.py 1.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859
  1. """
  2. pygments.styles.onedark
  3. ~~~~~~~~~~~~~~~~~~~~~~~
  4. One Dark Theme for Pygments by Tobias Zoghaib (https://github.com/TobiZog)
  5. Inspired by one-dark-ui for the code editor Atom
  6. (https://atom.io/themes/one-dark-ui).
  7. :copyright: Copyright 2006-2023 by the Pygments team, see AUTHORS.
  8. :license: BSD, see LICENSE for details.
  9. """
  10. from pygments.style import Style
  11. from pygments.token import Comment, Keyword, Name, Number, Operator, \
  12. Punctuation, String, Token
  13. class OneDarkStyle(Style):
  14. """
  15. Theme inspired by One Dark Pro for Atom.
  16. .. versionadded:: 2.11
  17. """
  18. background_color = '#282C34'
  19. styles = {
  20. Token: '#ABB2BF',
  21. Punctuation: '#ABB2BF',
  22. Punctuation.Marker: '#ABB2BF',
  23. Keyword: '#C678DD',
  24. Keyword.Constant: '#E5C07B',
  25. Keyword.Declaration: '#C678DD',
  26. Keyword.Namespace: '#C678DD',
  27. Keyword.Reserved: '#C678DD',
  28. Keyword.Type: '#E5C07B',
  29. Name: '#E06C75',
  30. Name.Attribute: '#E06C75',
  31. Name.Builtin: '#E5C07B',
  32. Name.Class: '#E5C07B',
  33. Name.Function: 'bold #61AFEF',
  34. Name.Function.Magic: 'bold #56B6C2',
  35. Name.Other: '#E06C75',
  36. Name.Tag: '#E06C75',
  37. Name.Decorator: '#61AFEF',
  38. Name.Variable.Class: '',
  39. String: '#98C379',
  40. Number: '#D19A66',
  41. Operator: '#56B6C2',
  42. Comment: '#7F848E'
  43. }