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

Highlight #185

Merged
merged 4 commits into from
Sep 20, 2018
Merged

Highlight #185

merged 4 commits into from
Sep 20, 2018

Conversation

schloerke
Copy link
Collaborator

Fixes #180
Fixes #150

Copy the latest from rmarkdown for code highlighting. Was defaulting to only texmate highlightjs style. Now allows for all pandoc and textmate style.

Copied from template here:
https://github.com/rstudio/rmarkdown/blob/0ff85d8db1c1b75386cc752062f6016884709139/inst/rmd/h/default.html#L50-L75
Removed code folding as it was not there before

Copied from html_document here: https://github.com/rstudio/rmarkdown/blob/19008bf684659f8592c5cbd440f9ce7e3786d65a/R/html_document.R#L285-L291

@jjallaire
Copy link
Member

One reason we hard-coded this was to match with the Ace editor instances (which also use a textmate style). That said, I see no reason why we shouldn't support everything.

@schloerke
Copy link
Collaborator Author

Thank you for the context!

I'll keep the default to textmate, but allow you to change it if you'd like. I'll add a documentation item that explains it will only give highlighting color to the R code, not ace editor code.

@jjallaire
Copy link
Member

Okay, sounds good!

@schloerke schloerke merged commit 7a28826 into rstudio:master Sep 20, 2018
@schloerke schloerke deleted the highlight branch October 8, 2018 20:30
schloerke added a commit to schloerke/learnr that referenced this pull request Oct 8, 2018
* upstream/master:
  Highlight code and exercise area (rstudio#185)
  save metadata information using dput vs deparse (rstudio#190)
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.

2 participants