render math in job tab info
Description of work
Currently, the Job tab info does not render the embedded LaTex expression strings, which can look less informative and cluttered. This PR proposes an enhancement in which images (rendered in a simple matplotlib figure) of the expression are inserted into the html of the Job tab, allowing mathematical expressions to be displayed in the text.
Fixes
Before:
After:
To test Please describe the tests that were run to verify the changes.
Looks like it's almost there. A few possible points that could still be worked on:
- If an equation is not inline, it is not picked up:
- The ignored expressions still affect the line breaks:
- In principle, it may be worthwhile to try to inline the images. With some tweaking, I got to the stage where it looked like this:
But if the vertical alignment cannot be corrected easily and the whole thing looks to awkward, then it should be fine to stick to the current version with a line break per maths symbol.
Just a few things.
White background with dark mode theme, and the inline equations' font size is very large. For the white background, I guess we could make the text white and the background transparent. The font size issue might be trickier. I wonder if we should latex the whole thing?
Good question - we may be able to get away with transparency and white font when in dark mode.
I don't think this needs to be fix here but something I discover in #1038 which also will happen for the equation images.
I don't think this needs to be fix here but something I discover in #1038 which also will happen for the equation images.
I've been able to fix some dark light mode system change GUI issues. See #1062 might be worth trying to add a similar fix here I think.
A few more things. Some text has been dropped. The "for a set of atoms" is missing. Also the equations are on their own line, I think it would be nice if you could inline them.
here is the text on protos.
@RobBuchananCompPhys Can you resolve the merge conflict, I can have a look to see if dark/light mode change can be fixed for the equation images.
