Author Topic: *.Rmd and smart indenting  (Read 487 times)

jporkkahtc

  • Senior Community Member
  • Posts: 1855
  • Hero Points: 179
  • Text
*.Rmd and smart indenting
« on: August 28, 2018, 04:41:49 pm »
Normally when cursor is at col 1 and I hit <tab>, the cursor moves to the 1st non-blank character and the line is reindented to what Slick thinks is the correct indent amount.

In *.RMD file (R + markdown), it doesn't do this smart behavior - it simply inserts 4 spaces.
it should do the smart indent thing.

Clark

  • SlickEdit Team Member
  • Senior Community Member
  • *
  • Posts: 4938
  • Hero Points: 404
Re: *.Rmd and smart indenting
« Reply #1 on: August 28, 2018, 10:45:04 pm »
Right now, none of the smart keys work in embedded language code for Markdown (.markdown and .rmd).

In order for most smart keys to work for embedded languages, the outer language must at least list tags. However, in the case of R (or Kotlin, Groovy, and Scala), there's also the requirement for a statement level parser. It's doubtful we will have time to do that.

We can make smart keys work for other embedded languages without statement level tagging (just a proc_search function). However, this won't help R (or Kotlin, Groovy, and Scala).
« Last Edit: August 29, 2018, 12:27:08 am by Clark »