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

Axis par args not getting into the render #459

Merged
merged 6 commits into from
Mar 22, 2017

Conversation

jordansread
Copy link
Member

tcl and others were being ignored in axis. This is aimed at fixing #456

@coveralls
Copy link

Coverage Status

Changes Unknown when pulling 14d4dd8 on jread-usgs:axis_trouble into ** on USGS-R:master**.

R/axis.R Outdated
user_args[[fun.name]]$n.minor <- n.minor
user_args[[fun.name]]$tcl.minor <- tcl.minor
if (length(args$extracted.args) > 0){
warning('axs.gsplot is not configured to support embedded function calls', call. = FALSE)

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

warning message should say "axis" not "axs"

user.args[[fun.name]]$n.minor <- n.minor
user.args[[fun.name]]$tcl.minor <- tcl.minor

user.args[[fun.name]] <- append_replace(user.args[[fun.name]], args$option.args)

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

correct me if I'm wrong, but this is the legitimate change for this PR, right? The others are adding warnings, catching nulls, and changing code style/object names, but this line is what has been actually added

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes, this is the meat of it

gs <- points(gsplot(), 1, 0) %>% axis(side=1, tcl.minor = -0.136)
expect_equal(gs$side.1$axis[["tcl.minor"]], -0.136)
})

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should we add a test that does something with axis style args in other places? gs <- points(gsplot(), 1, 0, tcl=-0.4) %>% axis(side=1, n.minor = 4)

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I can add that.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@lindsaycarr added things per your review

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yep, waiting for travis to finish and then I will merge!

@coveralls
Copy link

Coverage Status

Changes Unknown when pulling ef206d1 on jread-usgs:axis_trouble into ** on USGS-R:master**.

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.

3 participants