-
-
Notifications
You must be signed in to change notification settings - Fork 77
Plots Improvements - A continutation of #966 #1245
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
base: PG-2.20
Are you sure you want to change the base?
Conversation
There were two connected problems. First, I was not checking the correct container div size in the "drawPromise" for the dialog version of the graph. I was always checking the div for the main JSXGraph image in the page. Although, that doesn't entirely matter since the real problem was that the imageview JSXGraph div did not have its size set on initialization (which I do in all of the other places where I do this sort of thing with JSXGraph).
Working on the colors, I think the issue @drgrice1 pointed out was due to contrast, and I do agree that the green doesn't look as good. I took the colors from the W3school color wheel and wanted something that wasn't as stark as just I liked the looks of the RYB color wheel, so I went with that, but I didn't pay close enough attention and noticed that the wheel they draw and the color codes they give do not match, and agree that green is the worst looking. Maybe I'll just grab the colors from the wheel directly. Here is a test problem.
The green by itself without contrasting with blue doesn't look as bad, but I'll update to the colors shown in the wheel vs the color codes given (unless someone knows some decent color codes for a base pallet, I just thought the RGB codes were a bit much which was why I wanted to change them). And here is what the colors look like if I grab the color codes from the color wheel W3 has vs use the codes they provide. To me I like the red/blue/purple from the first, and the yellow/green/orange from the second image. |
b4e8005
to
42fd949
Compare
The W3 RYB colors didn't look right, reverting but changing green to be the SVG/HTML definition `#008000` which looks better to me than `#00ff00`, which SVG calls lime green. Also adding the secondary RGB colors `cyan` and `magenta`, but keeping the RYB secondary colors orange and purple. Add `grey` as an alternative spelling for `gray` as well.
42fd949
to
5465185
Compare
* Only show minor grid lines if major grid lines are shown. * Fix issue with Tikz not hiding tick marks correctly with show_ticks set to zero for the appropriate axes. * Make it so axes will adjust their size to the current view when `jsx_navigation` is enabled. * Fixed a bug with JSXGraph not changing the min/max bounds of a function to a number from a string, such '2pi'.
I have updated the examples for those who want to testing things, I have removed |
Those colors look better. |
Here is a problem to see/test the line style changes.
|
Update the line style options and adjust how the line style is applied to make the Tikz lines look like the line styles defined by JSXGraph. The line styles are now 'solid', 'dashed', 'dotted', 'short dashes', 'long dashes', 'long medium dashes', or 'none'. Also fixed an issue where functions must generate data points for JSXGraph if the markers are to be drawn.
63f7eee
to
607145a
Compare
Updated examples: |
ff1d92a
to
e298619
Compare
A new method to add arcs defined by three points. $plot->add_arc([$x1, $y1], [$x2, $y2], [$x3, $y3], %options); In the process reduce some code duplication, by creating a single get_options method for JSXGraph options as the code for that had been duplicated a few times, also try to minimize having to test and fall back to default values when a data style is not defined.
e298619
to
ce29e60
Compare
This matches the setting used in Tikz and JSXGraph and gives more control over the rotation of the label.
This is the new branch of improvements to the new Plots library after my accidental merge of #966.