question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[QUESTION] Information on use of TerminalTheme with save_html

See original GitHub issue

Have you checked the issues for a similar suggestions? Yes.

I would like to use console.save_html() and use the theme parameter; but I am not clear on the process to create a theme color pallet. I looked at the file terminal_theme.py but I am still not quite clear how to proceed. Is there documentation on this topic or could you advise?

Ideally I would like to use a pygments style name to define the color theme if possible; for example use pygments.style.get_style_by_name(“paraiso-dark”) as a means to se the save_html() theme.

I really appreciate your help and guidance!

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:13

github_iconTop GitHub Comments

1reaction
jeremyschulmancommented, Aug 2, 2020

Thank you very much for the math trick. Works perfectly. Really appreciate your help! Love the Rich package!

0reactions
jeremyschulmancommented, Aug 2, 2020

Since I imaging others might want to do what I am doing, I make this package, available on PyPi: https://github.com/jeremyschulman/iterm2-colors2rgb

Read more comments on GitHub >

github_iconTop Results From Across the Web

[QUESTION] Information on use of TerminalTheme ... - GitHub
A terminal theme defines a foreground / background color, 8 standard colors, and 8 bright versions. In https://github.com/willmcgugan/rich/blob/ ...
Read more >
How to saveHTML of DOMDocument without HTML wrapper?
We use strpos and strrpos to find the offsets from the front and back, respectively: $dom = new domDocument; $dom->loadHTML($html, LIBXML_HTML_NODEFDTD); ...
Read more >
Responsive class to all the images in the content
I have used this function to add a responsive class to all the images in content but this breaks the html structure of...
Read more >
Getting Started with Visual Studio Code and Building HTML ...
In this article, we will go over the steps necessary to download a popular text editor called Visual Studio Code, also referred to...
Read more >
DOMDocument::saveHTML - Manual - PHP
Creates an HTML document from the DOM representation. This function is usually called after building a new dom document from scratch as in...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found