-
-
Notifications
You must be signed in to change notification settings - Fork 56
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
background documentation and opacity support #969
Conversation
>> Graphics3D[{Arrow[{{0,0,0},{1,0,1},{0,-1,0},{1,1,1}}]}, Background -> Red] | ||
= -Graphics3D- | ||
|
||
Other values for this option are neglected. For example, this prevent to |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For soft line breaks add \
at the end of the line in the above and below line.
Looks good. It would be nice to add a test in |
https://github.com/Mathics3/mathics-core/blob/master/test%2Fbuiltin%2Fdrawing%2Ftest_plot.py#L39.
Here
El sáb, 20 de ene de 2024, 4:13 p. m., R. Bernstein <
***@***.***> escribió:
… ***@***.**** commented on this pull request.
------------------------------
In mathics/builtin/drawing/drawing_options.py
<#969 (comment)>
:
> @@ -78,6 +78,32 @@ class Axis(Builtin):
summary_text = "graph option value to fill plot from curve to the axis"
+class Background(Builtin):
+ """
+ <url>:WMA link:https://reference.wolfram.com/language/ref/Background.html</url>
+
+ <dl>
+ <dt>'Background'
+ <dd>is an option that specifies the color of the background.
+ </dl>
+
+ The specification must be a 'Color' or 'Automatic':
+
+ >> Graphics3D[{Arrow[{{0,0,0},{1,0,1},{0,-1,0},{1,1,1}}]}, Background -> Red]
+ = -Graphics3D-
+
+ Other values for this option are neglected. For example, this prevent to
This is done already.
I am not seeing any changes in
https://github.com/Mathics3/mathics-core/pull/969/files any changes to
test/format/test_asy.py
—
Reply to this email directly, view it on GitHub
<#969 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAV2ZUGUEJEVHMR5NXEACWLYPQJMBAVCNFSM6AAAAABCCX6FROVHI2DSMVQWIX3LMV43YUDVNRWFEZLROVSXG5CSMV3GSZLXHMYTQMZUG4ZDANBZGA>
.
You are receiving this because you authored the thread.Message ID:
***@***.***>
|
Two things. I don't see any opacity parameter or alpha channel parameter in the example. Second, unit testing at a smaller level, i.e. inside |
else: | ||
from mathics.core.parser import parse_builtin_rule | ||
|
||
default = {} | ||
for option, value in self.options.items(): | ||
option = ensure_context(option) | ||
default[option] = parse_builtin_rule(value) | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This change is needed to make some of the low-level tests work, especially when an Evaluation
object is not available.
Looks great now. Merge whenever you are done/satisfied. |
This PR adds the entry for
Background
in the documentation and provides support for opacity in SVG and json graphics.