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

Global cell defaults #173

Merged
merged 13 commits into from
Apr 1, 2024
Merged

Conversation

ute
Copy link
Contributor

@ute ute commented Mar 26, 2024

Here is the pull request for my feature suggestion, #172

It is just a proof-of-concept, maybe it can be solved in a very different way, or you even have planned something more general.

(sorry, I am really clumsy at GitHubbing ;-))

ute added 3 commits March 26, 2024 22:46
Allow user to define code cell defaults in yaml
Add a cell option for editor-font-size.
You might perhaps want a different name?
@coatless coatless mentioned this pull request Mar 28, 2024
@coatless coatless changed the title User defaults and editor fontsize Global cell defaults Mar 28, 2024
@coatless
Copy link
Owner

@ute so, I removed the font-size part from this PR in favor of working on it in #175.

I've added a demo document in docs/demos, a test in tests/, and a new release note.

If you're okay with the changes, please let me know and I'll merge it in. Otherwise, if there are changes you think should be made, please go ahead and let me know when I should re-look at the PR.

Thanks again for submitting a PR and the discussion! 🎉

@coatless coatless added this to the 4.2 milestone Mar 29, 2024
@coatless coatless added t: enhancement New feature or request p: low Address issue when time permits labels Mar 29, 2024
@ute
Copy link
Contributor Author

ute commented Mar 29, 2024

Thank you, James, and great documentation 💯 🎉 ! As for the yaml key: you came up with some nice suggestions for the name cell-defaults (still better than celldefaults), I am happy with anything 😄 you decide for (almost anything but banana)

@coatless
Copy link
Owner

@ute I'm inclined to keep it at cell-defaults; though, looking at how Quarto lists out code cell options in https://quarto.org/docs/reference/cells/cells-knitr.html

Maybe we should opt for:

  • code-cell-defaults
  • code-cell-options
  • cell-option-defaults

@coatless
Copy link
Owner

From pinging the internet, we have:

  • cell-defaults +1
  • cell-options +2

@ute
Copy link
Contributor Author

ute commented Mar 31, 2024

From pinging the internet, we have:

  • cell-defaults +1
  • cell-options +2

I am not on mastodon (👍for asking the public voice) but I've read chunk options so often recently 🤔

@coatless
Copy link
Owner

coatless commented Apr 1, 2024

@ute I thought about that a lot (c.f. the opts-chunk-set in #172 (comment)); but, in a lot of the documentation in Quarto there's a preference toward "Code Cells". Within the R-specific documentation, they adopt "Code Chunks" or "Code Blocks"


Viewing any non-RStudio documentation entry for the getting started:

https://quarto.org/docs/get-started/hello/vscode.html#code-cells

Vs. RStudio entry:

https://quarto.org/docs/get-started/hello/rstudio.html#code-chunks


The computation block switches to Code Blocks and describes "cell level options"

https://quarto.org/docs/computations/r.html#code-blocks


So, in VS code it shows:

`Run Cell` in VS Code

But, in RStudio we have chunks:

`Run Chunk` in RStudio

I'm partial to go more towards cell-options than chunk-options; but, @ute I'm going to let you pick the name since there isn't a clear consensus and you developed the feature. Sound okay?

@ute
Copy link
Contributor Author

ute commented Apr 1, 2024

I am also mainly using vs code now - lets go for cell options then. You need not take consideration of me, though. It is you who develops the package, and I can see you put a lot of thought into syntax and documentation 😊👍

@coatless coatless force-pushed the user-defaults-and-editor-fontsize branch from c5a55c2 to 0d120b9 Compare April 1, 2024 16:56
@coatless
Copy link
Owner

coatless commented Apr 1, 2024

@ute thanks for the kind words! I've updated it from cell-defaults to cell-options. In we go!

Thanks again for the PR 🎉

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
p: low Address issue when time permits t: enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants