| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
Sorry, something went wrong.
|
Thought I'd try one more thing before IntEnum. Automatically converting the style code into an enum by making style_literal a separate function seems to be a better approach? (It solves the double conversion problem, too.) |
Sorry, something went wrong.
|
Sure, that works too. |
Sorry, something went wrong.
|
Some backend tests have failed—I don't suppose they are related to these changes? (I remember that they had passed after commit b7dee27.) |
Sorry, something went wrong.
|
Indeed, these are irrelevant. |
Sorry, something went wrong.
|
Yes, I could add a test for that. One point, though: \genfrac needs rulesize, which only accepts floating-point numbers, whereas \dfrac uses a rule size of self.get_state().get_current_underline_thickness(). Not sure how to proceed. If I set the rule size to 1 (e.g. \genfrac{}{}{1}{0}{2x}{3y} compared with \dfrac{2x}{3y}), the test passes (it fails for 0 and 2). But that doesn't look like a good test? |
Sorry, something went wrong.
I am open to suggestions! |
Sorry, something went wrong.
|
I agree this is a bit annoying :( Probably I would cheat a bit and, in the test, use thickness = matplotlib._mathtext.TruetypeFonts.get_underline_thickness(None, None, fontsize=<whatever>, dpi=<whatever>) and insert that value into the test genfrac. |
Sorry, something went wrong.
There was a problem hiding this comment.
Minor nits, which don't prevent the approval IMO.
Sorry, something went wrong.
|
Rebased on the current main branch, since a temporary fix for the failing macOS tests appears to be in place. |
Sorry, something went wrong.
The test changes the DPI of the figure, but compares images after saving them, so rcParams['savefig.dpi'] is more appropriate.
|
Fixed merge conflicts and rebased again. There are a couple of back-and-forth changes, so I will combine everything into a single commit. The test failures are due to an unidentified image error. Not sure what went wrong. |
Sorry, something went wrong.
|
I squashed the commit. Thanks! |
Sorry, something went wrong.
…lotlib#23034) * Correctly read the 'style' argument while processing 'genfrac'. * Default to text style if style not specified. * Hard-coded enumerations. Support script_stype and script_script_style. * Automatically convert style number to enumerated type. * Used double quotes for strings. * Verify that genfrac's displaystyle == dfrac. * Use rcParams instead of rcParamsDefault in the test. The test changes the DPI of the figure, but compares images after saving them, so rcParams['savefig.dpi'] is more appropriate.
…lotlib#23034) * Correctly read the 'style' argument while processing 'genfrac'. * Default to text style if style not specified. * Hard-coded enumerations. Support script_stype and script_script_style. * Automatically convert style number to enumerated type. * Used double quotes for strings. * Verify that genfrac's displaystyle == dfrac. * Use rcParams instead of rcParamsDefault in the test. The test changes the DPI of the figure, but compares images after saving them, so rcParams['savefig.dpi'] is more appropriate.
…lotlib#23034) * Correctly read the 'style' argument while processing 'genfrac'. * Default to text style if style not specified. * Hard-coded enumerations. Support script_stype and script_script_style. * Automatically convert style number to enumerated type. * Used double quotes for strings. * Verify that genfrac's displaystyle == dfrac. * Use rcParams instead of rcParamsDefault in the test. The test changes the DPI of the figure, but compares images after saving them, so rcParams['savefig.dpi'] is more appropriate.
| Back | FazBrowse Home | New Git URL |
PR Summary
An attempt to fix #23008.
PR Checklist
Tests and Styling
Documentation