Skip to content
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

fix xaxis/yaxis rendering, add keyword axes in PlotLayout #70

Merged
merged 2 commits into from
Mar 5, 2024

Conversation

hhaensel
Copy link
Member

@hhaensel hhaensel commented Mar 5, 2024

Although we do no longer develop our own implementation of Plots in favour of PlotlyBase, I feel that the current implementation of axes is confusing. (See #66 )

Currently, axis setting of the rendered PlotLayout is set by the xy field of PlotLayoutAxis and not by the keyword/field xaxis/yaxis.

I propose to change the rendering method such that we to chose the axis type according to the axis field so that

julia> render(PlotLayout(yaxis = [PlotLayoutAxis()]))
Dict{Symbol, Any} with 1 entry:
  :yaxis => Dict{Symbol, Any}()

For those who would want to keep the possibility to determine the axis type by the xy field, I have added a new keyword axes that keeps the behavior of former xaxis/yaxis.

julia> render(PlotLayout(axes = [PlotLayoutAxis(), PlotLayoutAxis(xy = "y")]))
Dict{Symbol, Any} with 2 entries:
  :xaxis => Dict{Symbol, Any}()
  :yaxis => Dict{Symbol, Any}()

@hhaensel hhaensel merged commit 65eedad into hh-vue3 Mar 5, 2024
0 of 20 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant