No puede seleccionar más de 25 temas Los temas deben comenzar con una letra o número, pueden incluir guiones ('-') y pueden tener hasta 35 caracteres de largo.
 
 
 
 
 
 

38 líneas
1.1 KiB

  1. #!/usr/bin/env python
  2. # -*- coding: utf-8 -*-
  3. #
  4. # libcaca Colour ASCII-Art library
  5. # Python language bindings
  6. # Copyright (c) 2010 Alex Foulon <alxf@lavabit.com>
  7. # All Rights Reserved
  8. #
  9. # This library is free software. It comes without any warranty, to
  10. # the extent permitted by applicable law. You can redistribute it
  11. # and/or modify it under the terms of the Do What the Fuck You Want
  12. # to Public License, Version 2, as published by Sam Hocevar. See
  13. # http://www.wtfpl.net/ for more details.
  14. #
  15. """ Libcaca Python bindings """
  16. import caca
  17. if __name__ == '__main__':
  18. print("libcaca version %s" % caca.get_version())
  19. print("")
  20. print("Available drivers:")
  21. for drv, desc in caca.get_display_driver_list():
  22. print(" - %s: %s" % (drv, desc))
  23. print("")
  24. print("Available fonts:")
  25. for font in caca.get_font_list():
  26. print(" - %s" % font)
  27. print("")
  28. print("Export formats:")
  29. for fmt, desc in caca.get_export_list():
  30. print(" - %s: %s" % (fmt, desc))
  31. print("")
  32. print("Import formats:")
  33. for fmt, desc in caca.get_import_list():
  34. print(" - %s: %s" % (fmt, desc))