1 /* UserPrefsAccessor.java 2 * 3 * Copyright (C) 2021 by RStudio, PBC 4 * 5 * Unless you have received this program directly from RStudio pursuant 6 * to the terms of a commercial license agreement with RStudio, then 7 * this program is licensed to you under the terms of version 3 of the 8 * GNU Affero General Public License. This program is distributed WITHOUT 9 * ANY EXPRESS OR IMPLIED WARRANTY, INCLUDING THOSE OF NON-INFRINGEMENT, 10 * MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. Please refer to the 11 * AGPL (http://www.gnu.org/licenses/agpl-3.0.txt) for more details. 12 * 13 */ 14 15 /* DO NOT HAND-EDIT! This file is automatically generated from the formal user preference schema 16 * JSON. To add a preference, add it to "user-prefs-schema.json", then run "generate-prefs.R" to 17 * rebuild this file. 18 */ 19 20 package org.rstudio.studio.client.workbench.prefs.model; 21 22 import org.rstudio.core.client.js.JsObject; 23 import org.rstudio.studio.client.workbench.model.SessionInfo; 24 25 import com.google.gwt.core.client.JavaScriptObject; 26 import com.google.gwt.core.client.JsArrayString; 27 import com.google.gwt.core.client.JsArray; 28 import org.rstudio.core.client.JsArrayUtil; 29 30 import java.util.ArrayList; 31 import java.util.List; 32 33 34 /** 35 * Accessor class for user preferences. 36 */ 37 public class UserPrefsAccessor extends Prefs 38 { UserPrefsAccessor(SessionInfo sessionInfo, JsArray<PrefLayer> prefLayers)39 public UserPrefsAccessor(SessionInfo sessionInfo, 40 JsArray<PrefLayer> prefLayers) 41 { 42 super(prefLayers); 43 } 44 45 /** 46 * Whether to run .Rprofile again after resuming a suspended R session. 47 */ runRprofileOnResume()48 public PrefValue<Boolean> runRprofileOnResume() 49 { 50 return bool( 51 "run_rprofile_on_resume", 52 "Run .Rprofile on resume", 53 "Whether to run .Rprofile again after resuming a suspended R session.", 54 false); 55 } 56 57 /** 58 * Whether to save the workspace to an .Rdata file after the R session ends. 59 */ saveWorkspace()60 public PrefValue<String> saveWorkspace() 61 { 62 return enumeration( 63 "save_workspace", 64 "Save workspace on quit", 65 "Whether to save the workspace to an .Rdata file after the R session ends.", 66 new String[] { 67 SAVE_WORKSPACE_ALWAYS, 68 SAVE_WORKSPACE_NEVER, 69 SAVE_WORKSPACE_ASK 70 }, 71 "ask"); 72 } 73 74 public final static String SAVE_WORKSPACE_ALWAYS = "always"; 75 public final static String SAVE_WORKSPACE_NEVER = "never"; 76 public final static String SAVE_WORKSPACE_ASK = "ask"; 77 78 /** 79 * Whether to load the workspace when the R session begins. 80 */ loadWorkspace()81 public PrefValue<Boolean> loadWorkspace() 82 { 83 return bool( 84 "load_workspace", 85 "Load workspace on start", 86 "Whether to load the workspace when the R session begins.", 87 true); 88 } 89 90 /** 91 * The initial working directory for new R sessions. 92 */ initialWorkingDirectory()93 public PrefValue<String> initialWorkingDirectory() 94 { 95 return string( 96 "initial_working_directory", 97 "Initial working directory", 98 "The initial working directory for new R sessions.", 99 ""); 100 } 101 102 /** 103 * The CRAN mirror to use. 104 */ cranMirror()105 public PrefValue<CranMirror> cranMirror() 106 { 107 return object( 108 "cran_mirror", 109 "", 110 "The CRAN mirror to use.", 111 null); 112 } 113 114 public static class CranMirror extends JavaScriptObject 115 { CranMirror()116 protected CranMirror() {} 117 getName()118 public final native String getName() /*-{ 119 return this && this.name || "Global (CDN)"; 120 }-*/; 121 getHost()122 public final native String getHost() /*-{ 123 return this && this.host || "RStudio"; 124 }-*/; 125 getUrl()126 public final native String getUrl() /*-{ 127 return this && this.url || "https://cran.rstudio.com/"; 128 }-*/; 129 getRepos()130 public final native String getRepos() /*-{ 131 return this && this.repos || ""; 132 }-*/; 133 getCountry()134 public final native String getCountry() /*-{ 135 return this && this.country || "us"; 136 }-*/; 137 getSecondary()138 public final native String getSecondary() /*-{ 139 return this && this.secondary || ""; 140 }-*/; 141 142 } 143 144 /** 145 * The name of the default Bioconductor mirror. 146 */ bioconductorMirrorName()147 public PrefValue<String> bioconductorMirrorName() 148 { 149 return string( 150 "bioconductor_mirror_name", 151 "", 152 "The name of the default Bioconductor mirror.", 153 "Seattle (USA)"); 154 } 155 156 /** 157 * The URL of the default Bioconductor mirror. 158 */ bioconductorMirrorUrl()159 public PrefValue<String> bioconductorMirrorUrl() 160 { 161 return string( 162 "bioconductor_mirror_url", 163 "", 164 "The URL of the default Bioconductor mirror.", 165 "http://www.bioconductor.org"); 166 } 167 168 /** 169 * Whether to always save the R console history. 170 */ alwaysSaveHistory()171 public PrefValue<Boolean> alwaysSaveHistory() 172 { 173 return bool( 174 "always_save_history", 175 "Save R console history", 176 "Whether to always save the R console history.", 177 true); 178 } 179 180 /** 181 * Whether to remove duplicate entries from the R console history. 182 */ removeHistoryDuplicates()183 public PrefValue<Boolean> removeHistoryDuplicates() 184 { 185 return bool( 186 "remove_history_duplicates", 187 "Remove duplicates from console history", 188 "Whether to remove duplicate entries from the R console history.", 189 false); 190 } 191 192 /** 193 * Show the result of the last expression (.Last.value) in the Environment pane. 194 */ showLastDotValue()195 public PrefValue<Boolean> showLastDotValue() 196 { 197 return bool( 198 "show_last_dot_value", 199 "Show .Last.value in Environment pane", 200 "Show the result of the last expression (.Last.value) in the Environment pane.", 201 false); 202 } 203 204 /** 205 * The line ending format to use when saving files. 206 */ lineEndingConversion()207 public PrefValue<String> lineEndingConversion() 208 { 209 return enumeration( 210 "line_ending_conversion", 211 "Line ending format", 212 "The line ending format to use when saving files.", 213 new String[] { 214 LINE_ENDING_CONVERSION_DEFAULT, 215 LINE_ENDING_CONVERSION_WINDOWS, 216 LINE_ENDING_CONVERSION_POSIX, 217 LINE_ENDING_CONVERSION_NATIVE, 218 LINE_ENDING_CONVERSION_PASSTHROUGH 219 }, 220 "native"); 221 } 222 223 public final static String LINE_ENDING_CONVERSION_DEFAULT = "default"; 224 public final static String LINE_ENDING_CONVERSION_WINDOWS = "windows"; 225 public final static String LINE_ENDING_CONVERSION_POSIX = "posix"; 226 public final static String LINE_ENDING_CONVERSION_NATIVE = "native"; 227 public final static String LINE_ENDING_CONVERSION_PASSTHROUGH = "passthrough"; 228 229 /** 230 * Whether to use newlines when saving Makefiles. 231 */ useNewlinesInMakefiles()232 public PrefValue<Boolean> useNewlinesInMakefiles() 233 { 234 return bool( 235 "use_newlines_in_makefiles", 236 "Use newlines in Makefiles", 237 "Whether to use newlines when saving Makefiles.", 238 true); 239 } 240 241 /** 242 * The terminal shell to use on Windows. 243 */ windowsTerminalShell()244 public PrefValue<String> windowsTerminalShell() 245 { 246 return enumeration( 247 "windows_terminal_shell", 248 "", 249 "The terminal shell to use on Windows.", 250 new String[] { 251 WINDOWS_TERMINAL_SHELL_DEFAULT, 252 WINDOWS_TERMINAL_SHELL_WIN_GIT_BASH, 253 WINDOWS_TERMINAL_SHELL_WIN_WSL_BASH, 254 WINDOWS_TERMINAL_SHELL_WIN_CMD, 255 WINDOWS_TERMINAL_SHELL_WIN_PS, 256 WINDOWS_TERMINAL_SHELL_PS_CORE, 257 WINDOWS_TERMINAL_SHELL_CUSTOM, 258 WINDOWS_TERMINAL_SHELL_NONE 259 }, 260 "default"); 261 } 262 263 public final static String WINDOWS_TERMINAL_SHELL_DEFAULT = "default"; 264 public final static String WINDOWS_TERMINAL_SHELL_WIN_GIT_BASH = "win-git-bash"; 265 public final static String WINDOWS_TERMINAL_SHELL_WIN_WSL_BASH = "win-wsl-bash"; 266 public final static String WINDOWS_TERMINAL_SHELL_WIN_CMD = "win-cmd"; 267 public final static String WINDOWS_TERMINAL_SHELL_WIN_PS = "win-ps"; 268 public final static String WINDOWS_TERMINAL_SHELL_PS_CORE = "ps-core"; 269 public final static String WINDOWS_TERMINAL_SHELL_CUSTOM = "custom"; 270 public final static String WINDOWS_TERMINAL_SHELL_NONE = "none"; 271 272 /** 273 * The terminal shell to use on POSIX operating systems (MacOS and Linux). 274 */ posixTerminalShell()275 public PrefValue<String> posixTerminalShell() 276 { 277 return enumeration( 278 "posix_terminal_shell", 279 "", 280 "The terminal shell to use on POSIX operating systems (MacOS and Linux).", 281 new String[] { 282 POSIX_TERMINAL_SHELL_DEFAULT, 283 POSIX_TERMINAL_SHELL_BASH, 284 POSIX_TERMINAL_SHELL_ZSH, 285 POSIX_TERMINAL_SHELL_CUSTOM, 286 POSIX_TERMINAL_SHELL_NONE 287 }, 288 "default"); 289 } 290 291 public final static String POSIX_TERMINAL_SHELL_DEFAULT = "default"; 292 public final static String POSIX_TERMINAL_SHELL_BASH = "bash"; 293 public final static String POSIX_TERMINAL_SHELL_ZSH = "zsh"; 294 public final static String POSIX_TERMINAL_SHELL_CUSTOM = "custom"; 295 public final static String POSIX_TERMINAL_SHELL_NONE = "none"; 296 297 /** 298 * The fully qualified path to the custom shell command to use in the Terminal tab. 299 */ customShellCommand()300 public PrefValue<String> customShellCommand() 301 { 302 return string( 303 "custom_shell_command", 304 "", 305 "The fully qualified path to the custom shell command to use in the Terminal tab.", 306 ""); 307 } 308 309 /** 310 * The command-line options to pass to the custom shell command. 311 */ customShellOptions()312 public PrefValue<String> customShellOptions() 313 { 314 return string( 315 "custom_shell_options", 316 "", 317 "The command-line options to pass to the custom shell command.", 318 ""); 319 } 320 321 /** 322 * Show line numbers in RStudio's code editor. 323 */ showLineNumbers()324 public PrefValue<Boolean> showLineNumbers() 325 { 326 return bool( 327 "show_line_numbers", 328 "Show line numbers in editor", 329 "Show line numbers in RStudio's code editor.", 330 true); 331 } 332 333 /** 334 * Highlight the selected word in RStudio's code editor. 335 */ highlightSelectedWord()336 public PrefValue<Boolean> highlightSelectedWord() 337 { 338 return bool( 339 "highlight_selected_word", 340 "Highlight selected word in editor", 341 "Highlight the selected word in RStudio's code editor.", 342 true); 343 } 344 345 /** 346 * Highlight the selected line in RStudio's code editor. 347 */ highlightSelectedLine()348 public PrefValue<Boolean> highlightSelectedLine() 349 { 350 return bool( 351 "highlight_selected_line", 352 "Highlight selected line in editor", 353 "Highlight the selected line in RStudio's code editor.", 354 false); 355 } 356 357 /** 358 * Layout of panes in the RStudio workbench. 359 */ panes()360 public PrefValue<Panes> panes() 361 { 362 return object( 363 "panes", 364 "", 365 "Layout of panes in the RStudio workbench.", 366 null); 367 } 368 369 public static class Panes extends JavaScriptObject 370 { Panes()371 protected Panes() {} 372 373 public final static String QUADRANTS_SOURCE = "Source"; 374 public final static String QUADRANTS_CONSOLE = "Console"; 375 public final static String QUADRANTS_TABSET1 = "TabSet1"; 376 public final static String QUADRANTS_TABSET2 = "TabSet2"; 377 public final static String QUADRANTS_HIDDENTABSET = "HiddenTabSet"; 378 getQuadrants()379 public final native JsArrayString getQuadrants() /*-{ 380 return this && this.quadrants || ["Source","Console","TabSet1","TabSet2","HiddenTabSet"]; 381 }-*/; 382 getTabSet1()383 public final native JsArrayString getTabSet1() /*-{ 384 return this && this.tabSet1 || ["Environment","History","Connections","Build","VCS","Tutorial","Presentation"]; 385 }-*/; 386 getTabSet2()387 public final native JsArrayString getTabSet2() /*-{ 388 return this && this.tabSet2 || ["Files","Plots","Packages","Help","Viewer"]; 389 }-*/; 390 getHiddenTabSet()391 public final native JsArrayString getHiddenTabSet() /*-{ 392 return this && this.hiddenTabSet || []; 393 }-*/; 394 getConsoleLeftOnTop()395 public final native boolean getConsoleLeftOnTop() /*-{ 396 return this && this.console_left_on_top || false; 397 }-*/; 398 getConsoleRightOnTop()399 public final native boolean getConsoleRightOnTop() /*-{ 400 return this && this.console_right_on_top || true; 401 }-*/; 402 getAdditionalSourceColumns()403 public final native int getAdditionalSourceColumns() /*-{ 404 return this && this.additional_source_columns || 0; 405 }-*/; 406 407 } 408 409 /** 410 * Whether to enable the ability to add source columns to display. 411 */ allowSourceColumns()412 public PrefValue<Boolean> allowSourceColumns() 413 { 414 return bool( 415 "allow_source_columns", 416 "Allow source columns", 417 "Whether to enable the ability to add source columns to display.", 418 true); 419 } 420 421 /** 422 * Whether to insert spaces when pressing the Tab key. 423 */ useSpacesForTab()424 public PrefValue<Boolean> useSpacesForTab() 425 { 426 return bool( 427 "use_spaces_for_tab", 428 "Insert spaces for Tab", 429 "Whether to insert spaces when pressing the Tab key.", 430 true); 431 } 432 433 /** 434 * The number of spaces to insert when pressing the Tab key. 435 */ numSpacesForTab()436 public PrefValue<Integer> numSpacesForTab() 437 { 438 return integer( 439 "num_spaces_for_tab", 440 "Number of spaces for Tab", 441 "The number of spaces to insert when pressing the Tab key.", 442 2); 443 } 444 445 /** 446 * Whether to automatically detect indentation settings from file contents. 447 */ autoDetectIndentation()448 public PrefValue<Boolean> autoDetectIndentation() 449 { 450 return bool( 451 "auto_detect_indentation", 452 "Auto-detect indentation in files", 453 "Whether to automatically detect indentation settings from file contents.", 454 false); 455 } 456 457 /** 458 * Whether to show the margin guide in the RStudio code editor. 459 */ showMargin()460 public PrefValue<Boolean> showMargin() 461 { 462 return bool( 463 "show_margin", 464 "Show margin in editor", 465 "Whether to show the margin guide in the RStudio code editor.", 466 true); 467 } 468 469 /** 470 * Whether to flash the cursor off and on. 471 */ blinkingCursor()472 public PrefValue<Boolean> blinkingCursor() 473 { 474 return bool( 475 "blinking_cursor", 476 "Use a blinking cursor", 477 "Whether to flash the cursor off and on.", 478 true); 479 } 480 481 /** 482 * The number of columns of text after which the margin is shown. 483 */ marginColumn()484 public PrefValue<Integer> marginColumn() 485 { 486 return integer( 487 "margin_column", 488 "Margin column", 489 "The number of columns of text after which the margin is shown.", 490 80); 491 } 492 493 /** 494 * Whether to show invisible characters, such as spaces and tabs, in the RStudio code editor. 495 */ showInvisibles()496 public PrefValue<Boolean> showInvisibles() 497 { 498 return bool( 499 "show_invisibles", 500 "Show invisible characters in editor", 501 "Whether to show invisible characters, such as spaces and tabs, in the RStudio code editor.", 502 false); 503 } 504 505 /** 506 * Whether to show indentation guides in the RStudio code editor. 507 */ showIndentGuides()508 public PrefValue<Boolean> showIndentGuides() 509 { 510 return bool( 511 "show_indent_guides", 512 "Show indentation guides", 513 "Whether to show indentation guides in the RStudio code editor.", 514 false); 515 } 516 517 /** 518 * Whether continue comments (by inserting the comment character) after adding a new line. 519 */ continueCommentsOnNewline()520 public PrefValue<Boolean> continueCommentsOnNewline() 521 { 522 return bool( 523 "continue_comments_on_newline", 524 "Continue comments after adding new line", 525 "Whether continue comments (by inserting the comment character) after adding a new line.", 526 false); 527 } 528 529 /** 530 * Whether web links in comments are clickable. 531 */ highlightWebLink()532 public PrefValue<Boolean> highlightWebLink() 533 { 534 return bool( 535 "highlight_web_link", 536 "", 537 "Whether web links in comments are clickable.", 538 true); 539 } 540 541 /** 542 * The keybindings to use in the RStudio code editor. 543 */ editorKeybindings()544 public PrefValue<String> editorKeybindings() 545 { 546 return enumeration( 547 "editor_keybindings", 548 "Keybinding set for editor", 549 "The keybindings to use in the RStudio code editor.", 550 new String[] { 551 EDITOR_KEYBINDINGS_DEFAULT, 552 EDITOR_KEYBINDINGS_VIM, 553 EDITOR_KEYBINDINGS_EMACS, 554 EDITOR_KEYBINDINGS_SUBLIME 555 }, 556 "default"); 557 } 558 559 public final static String EDITOR_KEYBINDINGS_DEFAULT = "default"; 560 public final static String EDITOR_KEYBINDINGS_VIM = "vim"; 561 public final static String EDITOR_KEYBINDINGS_EMACS = "emacs"; 562 public final static String EDITOR_KEYBINDINGS_SUBLIME = "sublime"; 563 564 /** 565 * Whether to insert matching pairs, such as () and [], when the first is typed. 566 */ insertMatching()567 public PrefValue<Boolean> insertMatching() 568 { 569 return bool( 570 "insert_matching", 571 "Auto-insert matching parentheses and brackets", 572 "Whether to insert matching pairs, such as () and [], when the first is typed.", 573 true); 574 } 575 576 /** 577 * Whether to insert spaces around the equals sign in R code. 578 */ insertSpacesAroundEquals()579 public PrefValue<Boolean> insertSpacesAroundEquals() 580 { 581 return bool( 582 "insert_spaces_around_equals", 583 "Insert spaces around = in R code", 584 "Whether to insert spaces around the equals sign in R code.", 585 true); 586 } 587 588 /** 589 * Whether to insert parentheses after function completions. 590 */ insertParensAfterFunctionCompletion()591 public PrefValue<Boolean> insertParensAfterFunctionCompletion() 592 { 593 return bool( 594 "insert_parens_after_function_completion", 595 "Insert parentheses after functions", 596 "Whether to insert parentheses after function completions.", 597 true); 598 } 599 600 /** 601 * Whether to attempt completion of multiple-line statements when pressing Tab. 602 */ tabMultilineCompletion()603 public PrefValue<Boolean> tabMultilineCompletion() 604 { 605 return bool( 606 "tab_multiline_completion", 607 "Complete multi-line statements with Tab", 608 "Whether to attempt completion of multiple-line statements when pressing Tab.", 609 false); 610 } 611 612 /** 613 * Whether to attempt completion of statements when pressing Tab. 614 */ tabCompletion()615 public PrefValue<Boolean> tabCompletion() 616 { 617 return bool( 618 "tab_completion", 619 "Use Tab to trigger autocompletion", 620 "Whether to attempt completion of statements when pressing Tab.", 621 true); 622 } 623 624 /** 625 * Whether to show help tooltips for functions when the cursor has not been recently moved. 626 */ showHelpTooltipOnIdle()627 public PrefValue<Boolean> showHelpTooltipOnIdle() 628 { 629 return bool( 630 "show_help_tooltip_on_idle", 631 "Show function help tooltips on idle", 632 "Whether to show help tooltips for functions when the cursor has not been recently moved.", 633 false); 634 } 635 636 /** 637 * Which kinds of delimiters can be used to surround the current selection. 638 */ surroundSelection()639 public PrefValue<String> surroundSelection() 640 { 641 return enumeration( 642 "surround_selection", 643 "Surround selections with", 644 "Which kinds of delimiters can be used to surround the current selection.", 645 new String[] { 646 SURROUND_SELECTION_NEVER, 647 SURROUND_SELECTION_QUOTES, 648 SURROUND_SELECTION_QUOTES_AND_BRACKETS 649 }, 650 "quotes_and_brackets"); 651 } 652 653 public final static String SURROUND_SELECTION_NEVER = "never"; 654 public final static String SURROUND_SELECTION_QUOTES = "quotes"; 655 public final static String SURROUND_SELECTION_QUOTES_AND_BRACKETS = "quotes_and_brackets"; 656 657 /** 658 * Whether to enable code snippets in the RStudio code editor. 659 */ enableSnippets()660 public PrefValue<Boolean> enableSnippets() 661 { 662 return bool( 663 "enable_snippets", 664 "Enable code snippets", 665 "Whether to enable code snippets in the RStudio code editor.", 666 true); 667 } 668 669 /** 670 * When to use auto-completion for R code in the RStudio code editor. 671 */ codeCompletion()672 public PrefValue<String> codeCompletion() 673 { 674 return enumeration( 675 "code_completion", 676 "Use code completion for R", 677 "When to use auto-completion for R code in the RStudio code editor.", 678 new String[] { 679 CODE_COMPLETION_ALWAYS, 680 CODE_COMPLETION_NEVER, 681 CODE_COMPLETION_TRIGGERED, 682 CODE_COMPLETION_MANUAL 683 }, 684 "always"); 685 } 686 687 public final static String CODE_COMPLETION_ALWAYS = "always"; 688 public final static String CODE_COMPLETION_NEVER = "never"; 689 public final static String CODE_COMPLETION_TRIGGERED = "triggered"; 690 public final static String CODE_COMPLETION_MANUAL = "manual"; 691 692 /** 693 * When to use auto-completion for other languages (such as JavaScript and SQL) in the RStudio code editor. 694 */ codeCompletionOther()695 public PrefValue<String> codeCompletionOther() 696 { 697 return enumeration( 698 "code_completion_other", 699 "Use code completion for other languages", 700 "When to use auto-completion for other languages (such as JavaScript and SQL) in the RStudio code editor.", 701 new String[] { 702 CODE_COMPLETION_OTHER_ALWAYS, 703 CODE_COMPLETION_OTHER_TRIGGERED, 704 CODE_COMPLETION_OTHER_MANUAL 705 }, 706 "always"); 707 } 708 709 public final static String CODE_COMPLETION_OTHER_ALWAYS = "always"; 710 public final static String CODE_COMPLETION_OTHER_TRIGGERED = "triggered"; 711 public final static String CODE_COMPLETION_OTHER_MANUAL = "manual"; 712 713 /** 714 * Whether to always use code completion in the R console. 715 */ consoleCodeCompletion()716 public PrefValue<Boolean> consoleCodeCompletion() 717 { 718 return bool( 719 "console_code_completion", 720 "Use code completion in the R console", 721 "Whether to always use code completion in the R console.", 722 true); 723 } 724 725 /** 726 * The number of milliseconds to wait before offering code suggestions. 727 */ codeCompletionDelay()728 public PrefValue<Integer> codeCompletionDelay() 729 { 730 return integer( 731 "code_completion_delay", 732 "Delay before completing code (ms)", 733 "The number of milliseconds to wait before offering code suggestions.", 734 250); 735 } 736 737 /** 738 * The number of characters in a symbol that can be entered before completions are offered. 739 */ codeCompletionCharacters()740 public PrefValue<Integer> codeCompletionCharacters() 741 { 742 return integer( 743 "code_completion_characters", 744 "Number of characters for code completion", 745 "The number of characters in a symbol that can be entered before completions are offered.", 746 3); 747 } 748 749 /** 750 * Whether to show function signature tooltips during autocompletion. 751 */ showFunctionSignatureTooltips()752 public PrefValue<Boolean> showFunctionSignatureTooltips() 753 { 754 return bool( 755 "show_function_signature_tooltips", 756 "Show function signature tooltips", 757 "Whether to show function signature tooltips during autocompletion.", 758 true); 759 } 760 761 /** 762 * Whether to show diagnostic messages (such as syntax and usage errors) for R code as you type. 763 */ showDiagnosticsR()764 public PrefValue<Boolean> showDiagnosticsR() 765 { 766 return bool( 767 "show_diagnostics_r", 768 "Show diagnostics in R code", 769 "Whether to show diagnostic messages (such as syntax and usage errors) for R code as you type.", 770 true); 771 } 772 773 /** 774 * Whether to show diagnostic messages for C++ code as you type. 775 */ showDiagnosticsCpp()776 public PrefValue<Boolean> showDiagnosticsCpp() 777 { 778 return bool( 779 "show_diagnostics_cpp", 780 "Show diagnostics in C++ code", 781 "Whether to show diagnostic messages for C++ code as you type.", 782 true); 783 } 784 785 /** 786 * Whether to show diagnostic messages for other types of code (not R or C++). 787 */ showDiagnosticsOther()788 public PrefValue<Boolean> showDiagnosticsOther() 789 { 790 return bool( 791 "show_diagnostics_other", 792 "Show diagnostics in other languages", 793 "Whether to show diagnostic messages for other types of code (not R or C++).", 794 false); 795 } 796 797 /** 798 * Whether to show style diagnostics (suggestions for improving R code style) 799 */ styleDiagnostics()800 public PrefValue<Boolean> styleDiagnostics() 801 { 802 return bool( 803 "style_diagnostics", 804 "Show style diagnostics for R code", 805 "Whether to show style diagnostics (suggestions for improving R code style)", 806 false); 807 } 808 809 /** 810 * Whether to check code for problems after saving it. 811 */ diagnosticsOnSave()812 public PrefValue<Boolean> diagnosticsOnSave() 813 { 814 return bool( 815 "diagnostics_on_save", 816 "Check code for problems when saving", 817 "Whether to check code for problems after saving it.", 818 true); 819 } 820 821 /** 822 * Whether to run code diagnostics in the background, as you type. 823 */ backgroundDiagnostics()824 public PrefValue<Boolean> backgroundDiagnostics() 825 { 826 return bool( 827 "background_diagnostics", 828 "Run R code diagnostics in the background", 829 "Whether to run code diagnostics in the background, as you type.", 830 true); 831 } 832 833 /** 834 * The number of milliseconds to delay before running code diagnostics in the background. 835 */ backgroundDiagnosticsDelayMs()836 public PrefValue<Integer> backgroundDiagnosticsDelayMs() 837 { 838 return integer( 839 "background_diagnostics_delay_ms", 840 "Run R code diagnostics after (ms)", 841 "The number of milliseconds to delay before running code diagnostics in the background.", 842 2000); 843 } 844 845 /** 846 * Whether to run diagnostics in R function calls. 847 */ diagnosticsInRFunctionCalls()848 public PrefValue<Boolean> diagnosticsInRFunctionCalls() 849 { 850 return bool( 851 "diagnostics_in_r_function_calls", 852 "Run diagnostics on R function calls", 853 "Whether to run diagnostics in R function calls.", 854 true); 855 } 856 857 /** 858 * Whether to check arguments to R function calls. 859 */ checkArgumentsToRFunctionCalls()860 public PrefValue<Boolean> checkArgumentsToRFunctionCalls() 861 { 862 return bool( 863 "check_arguments_to_r_function_calls", 864 "Check arguments to R function calls", 865 "Whether to check arguments to R function calls.", 866 false); 867 } 868 869 /** 870 * Whether to check for unexpected variable assignments inside R function calls. 871 */ checkUnexpectedAssignmentInFunctionCall()872 public PrefValue<Boolean> checkUnexpectedAssignmentInFunctionCall() 873 { 874 return bool( 875 "check_unexpected_assignment_in_function_call", 876 "Check for unexpected assignments", 877 "Whether to check for unexpected variable assignments inside R function calls.", 878 false); 879 } 880 881 /** 882 * Whether to generate a warning if a variable is used without being defined in the current scope. 883 */ warnIfNoSuchVariableInScope()884 public PrefValue<Boolean> warnIfNoSuchVariableInScope() 885 { 886 return bool( 887 "warn_if_no_such_variable_in_scope", 888 "Warn when R variable used but not defined", 889 "Whether to generate a warning if a variable is used without being defined in the current scope.", 890 false); 891 } 892 893 /** 894 * Whether to generate a warning if a variable is defined without being used in the current scope 895 */ warnVariableDefinedButNotUsed()896 public PrefValue<Boolean> warnVariableDefinedButNotUsed() 897 { 898 return bool( 899 "warn_variable_defined_but_not_used", 900 "Warn when R variable defined but not used", 901 "Whether to generate a warning if a variable is defined without being used in the current scope", 902 false); 903 } 904 905 /** 906 * Whether to automatically discover and offer to install missing R package dependencies. 907 */ autoDiscoverPackageDependencies()908 public PrefValue<Boolean> autoDiscoverPackageDependencies() 909 { 910 return bool( 911 "auto_discover_package_dependencies", 912 "Detect missing R packages in the editor", 913 "Whether to automatically discover and offer to install missing R package dependencies.", 914 true); 915 } 916 917 /** 918 * Whether to ensure that source files end with a newline character. 919 */ autoAppendNewline()920 public PrefValue<Boolean> autoAppendNewline() 921 { 922 return bool( 923 "auto_append_newline", 924 "Ensure files end with a newline when saving", 925 "Whether to ensure that source files end with a newline character.", 926 false); 927 } 928 929 /** 930 * Whether to strip trailing whitespace from each line when saving. 931 */ stripTrailingWhitespace()932 public PrefValue<Boolean> stripTrailingWhitespace() 933 { 934 return bool( 935 "strip_trailing_whitespace", 936 "Strip trailing whitespace when saving", 937 "Whether to strip trailing whitespace from each line when saving.", 938 false); 939 } 940 941 /** 942 * Whether to save the position of the cursor when a file is closed, restore it when the file is opened. 943 */ restoreSourceDocumentCursorPosition()944 public PrefValue<Boolean> restoreSourceDocumentCursorPosition() 945 { 946 return bool( 947 "restore_source_document_cursor_position", 948 "Restore cursor position when reopening files", 949 "Whether to save the position of the cursor when a file is closed, restore it when the file is opened.", 950 true); 951 } 952 953 /** 954 * Whether to automatically re-indent code when it's pasted into RStudio. 955 */ reindentOnPaste()956 public PrefValue<Boolean> reindentOnPaste() 957 { 958 return bool( 959 "reindent_on_paste", 960 "Re-indent code when pasting", 961 "Whether to automatically re-indent code when it's pasted into RStudio.", 962 true); 963 } 964 965 /** 966 * Whether to vertically align arguments to R function calls during automatic indentation. 967 */ verticallyAlignArgumentsIndent()968 public PrefValue<Boolean> verticallyAlignArgumentsIndent() 969 { 970 return bool( 971 "vertically_align_arguments_indent", 972 "Vertically align function arguments", 973 "Whether to vertically align arguments to R function calls during automatic indentation.", 974 true); 975 } 976 977 /** 978 * Whether to soft-wrap R source files, wrapping the text for display without inserting newline characters. 979 */ softWrapRFiles()980 public PrefValue<Boolean> softWrapRFiles() 981 { 982 return bool( 983 "soft_wrap_r_files", 984 "Soft-wrap R source files", 985 "Whether to soft-wrap R source files, wrapping the text for display without inserting newline characters.", 986 false); 987 } 988 989 /** 990 * Whether to soft-wrap R Markdown files (and similar types such as R HTML and R Notebooks) 991 */ softWrapRmdFiles()992 public PrefValue<Boolean> softWrapRmdFiles() 993 { 994 return bool( 995 "soft_wrap_rmd_files", 996 "Soft-wrap R Markdown files", 997 "Whether to soft-wrap R Markdown files (and similar types such as R HTML and R Notebooks)", 998 true); 999 } 1000 1001 /** 1002 * Whether to focus the R console after executing an R command from a script. 1003 */ focusConsoleAfterExec()1004 public PrefValue<Boolean> focusConsoleAfterExec() 1005 { 1006 return bool( 1007 "focus_console_after_exec", 1008 "Focus console after executing R code", 1009 "Whether to focus the R console after executing an R command from a script.", 1010 false); 1011 } 1012 1013 /** 1014 * The style of folding to use. 1015 */ foldStyle()1016 public PrefValue<String> foldStyle() 1017 { 1018 return enumeration( 1019 "fold_style", 1020 "Fold style in editor", 1021 "The style of folding to use.", 1022 new String[] { 1023 FOLD_STYLE_BEGIN_ONLY, 1024 FOLD_STYLE_BEGIN_AND_END 1025 }, 1026 "begin-and-end"); 1027 } 1028 1029 public final static String FOLD_STYLE_BEGIN_ONLY = "begin-only"; 1030 public final static String FOLD_STYLE_BEGIN_AND_END = "begin-and-end"; 1031 1032 /** 1033 * Whether to automatically save scripts before executing them. 1034 */ saveBeforeSourcing()1035 public PrefValue<Boolean> saveBeforeSourcing() 1036 { 1037 return bool( 1038 "save_before_sourcing", 1039 "Save R scripts before sourcing", 1040 "Whether to automatically save scripts before executing them.", 1041 true); 1042 } 1043 1044 /** 1045 * Whether to use syntax highlighting in the R console. 1046 */ syntaxColorConsole()1047 public PrefValue<Boolean> syntaxColorConsole() 1048 { 1049 return bool( 1050 "syntax_color_console", 1051 "Syntax highlighting in R console", 1052 "Whether to use syntax highlighting in the R console.", 1053 false); 1054 } 1055 1056 /** 1057 * Whether to display error, warning, and message output in a different color. 1058 */ highlightConsoleErrors()1059 public PrefValue<Boolean> highlightConsoleErrors() 1060 { 1061 return bool( 1062 "highlight_console_errors", 1063 "Different color for error output in R console", 1064 "Whether to display error, warning, and message output in a different color.", 1065 true); 1066 } 1067 1068 /** 1069 * Whether to allow scrolling past the end of a file. 1070 */ scrollPastEndOfDocument()1071 public PrefValue<Boolean> scrollPastEndOfDocument() 1072 { 1073 return bool( 1074 "scroll_past_end_of_document", 1075 "Scroll past end of file", 1076 "Whether to allow scrolling past the end of a file.", 1077 false); 1078 } 1079 1080 /** 1081 * Whether to highlight R function calls in the code editor. 1082 */ highlightRFunctionCalls()1083 public PrefValue<Boolean> highlightRFunctionCalls() 1084 { 1085 return bool( 1086 "highlight_r_function_calls", 1087 "Highlight R function calls", 1088 "Whether to highlight R function calls in the code editor.", 1089 false); 1090 } 1091 1092 /** 1093 * Whether to highlight parentheses in a variety of colors. 1094 */ rainbowParentheses()1095 public PrefValue<Boolean> rainbowParentheses() 1096 { 1097 return bool( 1098 "rainbow_parentheses", 1099 "Rainbow parentheses", 1100 "Whether to highlight parentheses in a variety of colors.", 1101 false); 1102 } 1103 1104 /** 1105 * The maximum number of characters to display in a single line in the R console. 1106 */ consoleLineLengthLimit()1107 public PrefValue<Integer> consoleLineLengthLimit() 1108 { 1109 return integer( 1110 "console_line_length_limit", 1111 "Maximum characters per line in R console", 1112 "The maximum number of characters to display in a single line in the R console.", 1113 1000); 1114 } 1115 1116 /** 1117 * The maximum number of console actions to store and display in the console scrollback buffer. 1118 */ consoleMaxLines()1119 public PrefValue<Integer> consoleMaxLines() 1120 { 1121 return integer( 1122 "console_max_lines", 1123 "Maximum lines in R console", 1124 "The maximum number of console actions to store and display in the console scrollback buffer.", 1125 1000); 1126 } 1127 1128 /** 1129 * How to treat ANSI escape codes in the console. 1130 */ ansiConsoleMode()1131 public PrefValue<String> ansiConsoleMode() 1132 { 1133 return enumeration( 1134 "ansi_console_mode", 1135 "ANSI escape codes in R console", 1136 "How to treat ANSI escape codes in the console.", 1137 new String[] { 1138 ANSI_CONSOLE_MODE_OFF, 1139 ANSI_CONSOLE_MODE_ON, 1140 ANSI_CONSOLE_MODE_STRIP 1141 }, 1142 "on"); 1143 } 1144 1145 public final static String ANSI_CONSOLE_MODE_OFF = "off"; 1146 public final static String ANSI_CONSOLE_MODE_ON = "on"; 1147 public final static String ANSI_CONSOLE_MODE_STRIP = "strip"; 1148 1149 /** 1150 * Whether to only show a limited window of the total console output 1151 */ limitVisibleConsole()1152 public PrefValue<Boolean> limitVisibleConsole() 1153 { 1154 return bool( 1155 "limit_visible_console", 1156 "Limit visible console output", 1157 "Whether to only show a limited window of the total console output", 1158 false); 1159 } 1160 1161 /** 1162 * Whether to show a toolbar on code chunks in R Markdown documents. 1163 */ showInlineToolbarForRCodeChunks()1164 public PrefValue<Boolean> showInlineToolbarForRCodeChunks() 1165 { 1166 return bool( 1167 "show_inline_toolbar_for_r_code_chunks", 1168 "Show toolbar on R Markdown chunks", 1169 "Whether to show a toolbar on code chunks in R Markdown documents.", 1170 true); 1171 } 1172 1173 /** 1174 * Whether to highlight code chunks in R Markdown documents with a different background color. 1175 */ highlightCodeChunks()1176 public PrefValue<Boolean> highlightCodeChunks() 1177 { 1178 return bool( 1179 "highlight_code_chunks", 1180 "Highlight code chunks in R Markdown files", 1181 "Whether to highlight code chunks in R Markdown documents with a different background color.", 1182 true); 1183 } 1184 1185 /** 1186 * Whether to save all open, unsaved files before building the project. 1187 */ saveFilesBeforeBuild()1188 public PrefValue<Boolean> saveFilesBeforeBuild() 1189 { 1190 return bool( 1191 "save_files_before_build", 1192 "Save files before building", 1193 "Whether to save all open, unsaved files before building the project.", 1194 false); 1195 } 1196 1197 /** 1198 * The default editor font size, in points. 1199 */ fontSizePoints()1200 public PrefValue<Double> fontSizePoints() 1201 { 1202 return dbl( 1203 "font_size_points", 1204 "Editor font size (points)", 1205 "The default editor font size, in points.", 1206 10.0); 1207 } 1208 1209 /** 1210 * The help panel font size, in points. 1211 */ helpFontSizePoints()1212 public PrefValue<Double> helpFontSizePoints() 1213 { 1214 return dbl( 1215 "help_font_size_points", 1216 "Help panel font size (points)", 1217 "The help panel font size, in points.", 1218 10.0); 1219 } 1220 1221 /** 1222 * The name of the color theme to apply to the text editor in RStudio. 1223 */ editorTheme()1224 public PrefValue<String> editorTheme() 1225 { 1226 return string( 1227 "editor_theme", 1228 "Theme", 1229 "The name of the color theme to apply to the text editor in RStudio.", 1230 "Textmate (default)"); 1231 } 1232 1233 /** 1234 * Whether to use a custom editor font in RStudio Server. 1235 */ serverEditorFontEnabled()1236 public PrefValue<Boolean> serverEditorFontEnabled() 1237 { 1238 return bool( 1239 "server_editor_font_enabled", 1240 "Enable editor fonts on RStudio Server", 1241 "Whether to use a custom editor font in RStudio Server.", 1242 false); 1243 } 1244 1245 /** 1246 * The name of the fixed-width editor font to use with RStudio Server. 1247 */ serverEditorFont()1248 public PrefValue<String> serverEditorFont() 1249 { 1250 return string( 1251 "server_editor_font", 1252 "Editor font", 1253 "The name of the fixed-width editor font to use with RStudio Server.", 1254 ""); 1255 } 1256 1257 /** 1258 * The default character encoding to use when saving files. 1259 */ defaultEncoding()1260 public PrefValue<String> defaultEncoding() 1261 { 1262 return string( 1263 "default_encoding", 1264 "Default character encoding", 1265 "The default character encoding to use when saving files.", 1266 ""); 1267 } 1268 1269 /** 1270 * Whether to show the toolbar at the top of the RStudio workbench. 1271 */ toolbarVisible()1272 public PrefValue<Boolean> toolbarVisible() 1273 { 1274 return bool( 1275 "toolbar_visible", 1276 "Show top toolbar", 1277 "Whether to show the toolbar at the top of the RStudio workbench.", 1278 true); 1279 } 1280 1281 /** 1282 * The directory path under which to place new projects by default. 1283 */ defaultProjectLocation()1284 public PrefValue<String> defaultProjectLocation() 1285 { 1286 return string( 1287 "default_project_location", 1288 "Default new project location", 1289 "The directory path under which to place new projects by default.", 1290 ""); 1291 } 1292 1293 /** 1294 * Whether to echo R code when sourcing it. 1295 */ sourceWithEcho()1296 public PrefValue<Boolean> sourceWithEcho() 1297 { 1298 return bool( 1299 "source_with_echo", 1300 "Source with echo by default", 1301 "Whether to echo R code when sourcing it.", 1302 false); 1303 } 1304 1305 /** 1306 * The default engine to use when processing Sweave documents. 1307 */ defaultSweaveEngine()1308 public PrefValue<String> defaultSweaveEngine() 1309 { 1310 return string( 1311 "default_sweave_engine", 1312 "Default Sweave engine", 1313 "The default engine to use when processing Sweave documents.", 1314 "Sweave"); 1315 } 1316 1317 /** 1318 * The default program to use when processing LaTeX documents. 1319 */ defaultLatexProgram()1320 public PrefValue<String> defaultLatexProgram() 1321 { 1322 return string( 1323 "default_latex_program", 1324 "Default LaTeX program", 1325 "The default program to use when processing LaTeX documents.", 1326 "pdfLaTeX"); 1327 } 1328 1329 /** 1330 * Whether to use Roxygen for documentation. 1331 */ useRoxygen()1332 public PrefValue<Boolean> useRoxygen() 1333 { 1334 return bool( 1335 "use_roxygen", 1336 "Use Roxygen for documentation", 1337 "Whether to use Roxygen for documentation.", 1338 false); 1339 } 1340 1341 /** 1342 * Whether to use RStudio's data import feature. 1343 */ useDataimport()1344 public PrefValue<Boolean> useDataimport() 1345 { 1346 return bool( 1347 "use_dataimport", 1348 "Enable data import", 1349 "Whether to use RStudio's data import feature.", 1350 true); 1351 } 1352 1353 /** 1354 * The program to use to preview PDF files after generation. 1355 */ pdfPreviewer()1356 public PrefValue<String> pdfPreviewer() 1357 { 1358 return enumeration( 1359 "pdf_previewer", 1360 "PDF previewer", 1361 "The program to use to preview PDF files after generation.", 1362 new String[] { 1363 PDF_PREVIEWER_NONE, 1364 PDF_PREVIEWER_DEFAULT, 1365 PDF_PREVIEWER_RSTUDIO, 1366 PDF_PREVIEWER_DESKTOP_SYNCTEX, 1367 PDF_PREVIEWER_SYSTEM 1368 }, 1369 "default"); 1370 } 1371 1372 public final static String PDF_PREVIEWER_NONE = "none"; 1373 public final static String PDF_PREVIEWER_DEFAULT = "default"; 1374 public final static String PDF_PREVIEWER_RSTUDIO = "rstudio"; 1375 public final static String PDF_PREVIEWER_DESKTOP_SYNCTEX = "desktop-synctex"; 1376 public final static String PDF_PREVIEWER_SYSTEM = "system"; 1377 1378 /** 1379 * Whether to always enable the concordance for RNW files. 1380 */ alwaysEnableRnwConcordance()1381 public PrefValue<Boolean> alwaysEnableRnwConcordance() 1382 { 1383 return bool( 1384 "always_enable_rnw_concordance", 1385 "Enable Rnw concordance", 1386 "Whether to always enable the concordance for RNW files.", 1387 true); 1388 } 1389 1390 /** 1391 * Whether to insert numbered sections in LaTeX. 1392 */ insertNumberedLatexSections()1393 public PrefValue<Boolean> insertNumberedLatexSections() 1394 { 1395 return bool( 1396 "insert_numbered_latex_sections", 1397 "Insert numbered LaTeX sections", 1398 "Whether to insert numbered sections in LaTeX.", 1399 false); 1400 } 1401 1402 /** 1403 * The language of the spelling dictionary to use for spell checking. 1404 */ spellingDictionaryLanguage()1405 public PrefValue<String> spellingDictionaryLanguage() 1406 { 1407 return string( 1408 "spelling_dictionary_language", 1409 "Spelling dictionary language", 1410 "The language of the spelling dictionary to use for spell checking.", 1411 "en_US"); 1412 } 1413 1414 /** 1415 * The list of custom dictionaries to use when spell checking. 1416 */ spellingCustomDictionaries()1417 public PrefValue<JsArrayString> spellingCustomDictionaries() 1418 { 1419 return object( 1420 "spelling_custom_dictionaries", 1421 "Custom spelling dictionaries", 1422 "The list of custom dictionaries to use when spell checking.", 1423 JsArrayUtil.createStringArray()); 1424 } 1425 1426 /** 1427 * The number of milliseconds to wait before linting a document after it is loaded. 1428 */ documentLoadLintDelay()1429 public PrefValue<Integer> documentLoadLintDelay() 1430 { 1431 return integer( 1432 "document_load_lint_delay", 1433 "Lint document after load (ms)", 1434 "The number of milliseconds to wait before linting a document after it is loaded.", 1435 5000); 1436 } 1437 1438 /** 1439 * Whether to ignore words in uppercase when spell checking. 1440 */ ignoreUppercaseWords()1441 public PrefValue<Boolean> ignoreUppercaseWords() 1442 { 1443 return bool( 1444 "ignore_uppercase_words", 1445 "Ignore uppercase words in spell check", 1446 "Whether to ignore words in uppercase when spell checking.", 1447 true); 1448 } 1449 1450 /** 1451 * Whether to ignore words with numbers in them when spell checking. 1452 */ ignoreWordsWithNumbers()1453 public PrefValue<Boolean> ignoreWordsWithNumbers() 1454 { 1455 return bool( 1456 "ignore_words_with_numbers", 1457 "Ignore words with numbers in spell check", 1458 "Whether to ignore words with numbers in them when spell checking.", 1459 true); 1460 } 1461 1462 /** 1463 * Whether to enable real-time spellchecking by default. 1464 */ realTimeSpellchecking()1465 public PrefValue<Boolean> realTimeSpellchecking() 1466 { 1467 return bool( 1468 "real_time_spellchecking", 1469 "Use real-time spellchecking", 1470 "Whether to enable real-time spellchecking by default.", 1471 true); 1472 } 1473 1474 /** 1475 * Whether to navigate to build errors. 1476 */ navigateToBuildError()1477 public PrefValue<Boolean> navigateToBuildError() 1478 { 1479 return bool( 1480 "navigate_to_build_error", 1481 "Navigate to build errors", 1482 "Whether to navigate to build errors.", 1483 true); 1484 } 1485 1486 /** 1487 * Whether to enable RStudio's Packages pane. 1488 */ packagesPaneEnabled()1489 public PrefValue<Boolean> packagesPaneEnabled() 1490 { 1491 return bool( 1492 "packages_pane_enabled", 1493 "Enable the Packages pane", 1494 "Whether to enable RStudio's Packages pane.", 1495 true); 1496 } 1497 1498 /** 1499 * Whether to use RCPP templates. 1500 */ useRcppTemplate()1501 public PrefValue<Boolean> useRcppTemplate() 1502 { 1503 return bool( 1504 "use_rcpp_template", 1505 "Use RCpp file templates", 1506 "Whether to use RCPP templates.", 1507 true); 1508 } 1509 1510 /** 1511 * Whether to restore the last opened source documents when RStudio starts up. 1512 */ restoreSourceDocuments()1513 public PrefValue<Boolean> restoreSourceDocuments() 1514 { 1515 return bool( 1516 "restore_source_documents", 1517 "Restore last opened documents on startup", 1518 "Whether to restore the last opened source documents when RStudio starts up.", 1519 true); 1520 } 1521 1522 /** 1523 * Whether to handle errors only when user code is on the stack. 1524 */ handleErrorsInUserCodeOnly()1525 public PrefValue<Boolean> handleErrorsInUserCodeOnly() 1526 { 1527 return bool( 1528 "handle_errors_in_user_code_only", 1529 "Handle errors only when user code present", 1530 "Whether to handle errors only when user code is on the stack.", 1531 true); 1532 } 1533 1534 /** 1535 * Whether to automatically expand tracebacks when an error occurs. 1536 */ autoExpandErrorTracebacks()1537 public PrefValue<Boolean> autoExpandErrorTracebacks() 1538 { 1539 return bool( 1540 "auto_expand_error_tracebacks", 1541 "Auto-expand error tracebacks", 1542 "Whether to automatically expand tracebacks when an error occurs.", 1543 false); 1544 } 1545 1546 /** 1547 * Whether to check for new versions of RStudio when RStudio starts. 1548 */ checkForUpdates()1549 public PrefValue<Boolean> checkForUpdates() 1550 { 1551 return bool( 1552 "check_for_updates", 1553 "Check for new version at startup", 1554 "Whether to check for new versions of RStudio when RStudio starts.", 1555 true); 1556 } 1557 1558 /** 1559 * Whether to show functions without source references in the Traceback pane while debugging. 1560 */ showInternalFunctions()1561 public PrefValue<Boolean> showInternalFunctions() 1562 { 1563 return bool( 1564 "show_internal_functions", 1565 "Show internal functions when debugging", 1566 "Whether to show functions without source references in the Traceback pane while debugging.", 1567 false); 1568 } 1569 1570 /** 1571 * Where to display Shiny applications when they are run. 1572 */ shinyViewerType()1573 public PrefValue<String> shinyViewerType() 1574 { 1575 return enumeration( 1576 "shiny_viewer_type", 1577 "Run Shiny applications in", 1578 "Where to display Shiny applications when they are run.", 1579 new String[] { 1580 SHINY_VIEWER_TYPE_USER, 1581 SHINY_VIEWER_TYPE_NONE, 1582 SHINY_VIEWER_TYPE_PANE, 1583 SHINY_VIEWER_TYPE_WINDOW, 1584 SHINY_VIEWER_TYPE_BROWSER 1585 }, 1586 "window"); 1587 } 1588 1589 public final static String SHINY_VIEWER_TYPE_USER = "user"; 1590 public final static String SHINY_VIEWER_TYPE_NONE = "none"; 1591 public final static String SHINY_VIEWER_TYPE_PANE = "pane"; 1592 public final static String SHINY_VIEWER_TYPE_WINDOW = "window"; 1593 public final static String SHINY_VIEWER_TYPE_BROWSER = "browser"; 1594 1595 /** 1596 * Whether to run Shiny applications as background jobs. 1597 */ shinyBackgroundJobs()1598 public PrefValue<Boolean> shinyBackgroundJobs() 1599 { 1600 return bool( 1601 "shiny_background_jobs", 1602 "Run Shiny applications in the background", 1603 "Whether to run Shiny applications as background jobs.", 1604 false); 1605 } 1606 1607 /** 1608 * Where to display Shiny applications when they are run. 1609 */ plumberViewerType()1610 public PrefValue<String> plumberViewerType() 1611 { 1612 return enumeration( 1613 "plumber_viewer_type", 1614 "Run Plumber APIs in", 1615 "Where to display Shiny applications when they are run.", 1616 new String[] { 1617 PLUMBER_VIEWER_TYPE_USER, 1618 PLUMBER_VIEWER_TYPE_NONE, 1619 PLUMBER_VIEWER_TYPE_PANE, 1620 PLUMBER_VIEWER_TYPE_WINDOW, 1621 PLUMBER_VIEWER_TYPE_BROWSER 1622 }, 1623 "window"); 1624 } 1625 1626 public final static String PLUMBER_VIEWER_TYPE_USER = "user"; 1627 public final static String PLUMBER_VIEWER_TYPE_NONE = "none"; 1628 public final static String PLUMBER_VIEWER_TYPE_PANE = "pane"; 1629 public final static String PLUMBER_VIEWER_TYPE_WINDOW = "window"; 1630 public final static String PLUMBER_VIEWER_TYPE_BROWSER = "browser"; 1631 1632 /** 1633 * The default name to use as the document author when creating new documents. 1634 */ documentAuthor()1635 public PrefValue<String> documentAuthor() 1636 { 1637 return string( 1638 "document_author", 1639 "Document author", 1640 "The default name to use as the document author when creating new documents.", 1641 ""); 1642 } 1643 1644 /** 1645 * The path to the preferred R Markdown template. 1646 */ rmdPreferredTemplatePath()1647 public PrefValue<String> rmdPreferredTemplatePath() 1648 { 1649 return string( 1650 "rmd_preferred_template_path", 1651 "Path to preferred R Markdown template", 1652 "The path to the preferred R Markdown template.", 1653 ""); 1654 } 1655 1656 /** 1657 * Where to display R Markdown documents when they have completed rendering. 1658 */ rmdViewerType()1659 public PrefValue<String> rmdViewerType() 1660 { 1661 return enumeration( 1662 "rmd_viewer_type", 1663 "Display R Markdown documents in", 1664 "Where to display R Markdown documents when they have completed rendering.", 1665 new String[] { 1666 RMD_VIEWER_TYPE_WINDOW, 1667 RMD_VIEWER_TYPE_PANE, 1668 RMD_VIEWER_TYPE_NONE 1669 }, 1670 "window"); 1671 } 1672 1673 public final static String RMD_VIEWER_TYPE_WINDOW = "window"; 1674 public final static String RMD_VIEWER_TYPE_PANE = "pane"; 1675 public final static String RMD_VIEWER_TYPE_NONE = "none"; 1676 1677 /** 1678 * Whether to show verbose diagnostic information when publishing content. 1679 */ showPublishDiagnostics()1680 public PrefValue<Boolean> showPublishDiagnostics() 1681 { 1682 return bool( 1683 "show_publish_diagnostics", 1684 "Show diagnostic info when publishing", 1685 "Whether to show verbose diagnostic information when publishing content.", 1686 false); 1687 } 1688 1689 /** 1690 * Whether to check remote server SSL certificates when publishing content. 1691 */ publishCheckCertificates()1692 public PrefValue<Boolean> publishCheckCertificates() 1693 { 1694 return bool( 1695 "publish_check_certificates", 1696 "Check SSL certificates when publishing", 1697 "Whether to check remote server SSL certificates when publishing content.", 1698 true); 1699 } 1700 1701 /** 1702 * Whether to use a custom certificate authority (CA) bundle when publishing content. 1703 */ usePublishCaBundle()1704 public PrefValue<Boolean> usePublishCaBundle() 1705 { 1706 return bool( 1707 "use_publish_ca_bundle", 1708 "Use custom CA bundle when publishing", 1709 "Whether to use a custom certificate authority (CA) bundle when publishing content.", 1710 false); 1711 } 1712 1713 /** 1714 * The path to the custom certificate authority (CA) bundle to use when publishing content. 1715 */ publishCaBundle()1716 public PrefValue<String> publishCaBundle() 1717 { 1718 return string( 1719 "publish_ca_bundle", 1720 "Path to custom CA bundle for publishing", 1721 "The path to the custom certificate authority (CA) bundle to use when publishing content.", 1722 ""); 1723 } 1724 1725 /** 1726 * Whether to show chunk output inline for ordinary R Markdown documents. 1727 */ rmdChunkOutputInline()1728 public PrefValue<Boolean> rmdChunkOutputInline() 1729 { 1730 return bool( 1731 "rmd_chunk_output_inline", 1732 "Show chunk output inline in all documents", 1733 "Whether to show chunk output inline for ordinary R Markdown documents.", 1734 true); 1735 } 1736 1737 /** 1738 * Whether to show the document outline by default when opening R Markdown documents. 1739 */ showDocOutlineRmd()1740 public PrefValue<Boolean> showDocOutlineRmd() 1741 { 1742 return bool( 1743 "show_doc_outline_rmd", 1744 "Open document outline by default", 1745 "Whether to show the document outline by default when opening R Markdown documents.", 1746 false); 1747 } 1748 1749 /** 1750 * Whether to automatically run an R Markdown document's Setup chunk before running other chunks. 1751 */ autoRunSetupChunk()1752 public PrefValue<Boolean> autoRunSetupChunk() 1753 { 1754 return bool( 1755 "auto_run_setup_chunk", 1756 "Automatically run Setup chunk when needed", 1757 "Whether to automatically run an R Markdown document's Setup chunk before running other chunks.", 1758 true); 1759 } 1760 1761 /** 1762 * Whether to hide the R console when executing inline R Markdown chunks. 1763 */ hideConsoleOnChunkExecute()1764 public PrefValue<Boolean> hideConsoleOnChunkExecute() 1765 { 1766 return bool( 1767 "hide_console_on_chunk_execute", 1768 "Hide console when running R Markdown chunks", 1769 "Whether to hide the R console when executing inline R Markdown chunks.", 1770 true); 1771 } 1772 1773 /** 1774 * The unit of R code to execute when the Execute command is invoked. 1775 */ executionBehavior()1776 public PrefValue<String> executionBehavior() 1777 { 1778 return enumeration( 1779 "execution_behavior", 1780 "Unit of R code execution", 1781 "The unit of R code to execute when the Execute command is invoked.", 1782 new String[] { 1783 EXECUTION_BEHAVIOR_LINE, 1784 EXECUTION_BEHAVIOR_STATEMENT, 1785 EXECUTION_BEHAVIOR_PARAGRAPH 1786 }, 1787 "statement"); 1788 } 1789 1790 public final static String EXECUTION_BEHAVIOR_LINE = "line"; 1791 public final static String EXECUTION_BEHAVIOR_STATEMENT = "statement"; 1792 public final static String EXECUTION_BEHAVIOR_PARAGRAPH = "paragraph"; 1793 1794 /** 1795 * Whether to show the Terminal tab. 1796 */ showTerminalTab()1797 public PrefValue<Boolean> showTerminalTab() 1798 { 1799 return bool( 1800 "show_terminal_tab", 1801 "Show the Terminal tab", 1802 "Whether to show the Terminal tab.", 1803 true); 1804 } 1805 1806 /** 1807 * Whether to use local echo in the Terminal. 1808 */ terminalLocalEcho()1809 public PrefValue<Boolean> terminalLocalEcho() 1810 { 1811 return bool( 1812 "terminal_local_echo", 1813 "Use local echo in the Terminal", 1814 "Whether to use local echo in the Terminal.", 1815 true); 1816 } 1817 1818 /** 1819 * Whether to use websockets to communicate with the shell in the Terminal tab. 1820 */ terminalWebsockets()1821 public PrefValue<Boolean> terminalWebsockets() 1822 { 1823 return bool( 1824 "terminal_websockets", 1825 "Use websockets in the Terminal", 1826 "Whether to use websockets to communicate with the shell in the Terminal tab.", 1827 true); 1828 } 1829 1830 /** 1831 * Whether to close the terminal pane after the shell exits. 1832 */ terminalCloseBehavior()1833 public PrefValue<String> terminalCloseBehavior() 1834 { 1835 return enumeration( 1836 "terminal_close_behavior", 1837 "Close Terminal pane after shell exit", 1838 "Whether to close the terminal pane after the shell exits.", 1839 new String[] { 1840 TERMINAL_CLOSE_BEHAVIOR_ALWAYS, 1841 TERMINAL_CLOSE_BEHAVIOR_CLEAN, 1842 TERMINAL_CLOSE_BEHAVIOR_NEVER 1843 }, 1844 "always"); 1845 } 1846 1847 public final static String TERMINAL_CLOSE_BEHAVIOR_ALWAYS = "always"; 1848 public final static String TERMINAL_CLOSE_BEHAVIOR_CLEAN = "clean"; 1849 public final static String TERMINAL_CLOSE_BEHAVIOR_NEVER = "never"; 1850 1851 /** 1852 * Whether to track and save changes to system environment variables in the Terminal. 1853 */ terminalTrackEnvironment()1854 public PrefValue<Boolean> terminalTrackEnvironment() 1855 { 1856 return bool( 1857 "terminal_track_environment", 1858 "Save and restore system environment in Terminal tab", 1859 "Whether to track and save changes to system environment variables in the Terminal.", 1860 true); 1861 } 1862 1863 /** 1864 * Terminal bell style 1865 */ terminalBellStyle()1866 public PrefValue<String> terminalBellStyle() 1867 { 1868 return enumeration( 1869 "terminal_bell_style", 1870 "Terminal bell style", 1871 "Terminal bell style", 1872 new String[] { 1873 TERMINAL_BELL_STYLE_NONE, 1874 TERMINAL_BELL_STYLE_SOUND 1875 }, 1876 "sound"); 1877 } 1878 1879 public final static String TERMINAL_BELL_STYLE_NONE = "none"; 1880 public final static String TERMINAL_BELL_STYLE_SOUND = "sound"; 1881 1882 /** 1883 * Terminal rendering engine: canvas is faster, dom may be needed for some browsers or graphics cards 1884 */ terminalRenderer()1885 public PrefValue<String> terminalRenderer() 1886 { 1887 return enumeration( 1888 "terminal_renderer", 1889 "Terminal tab rendering engine", 1890 "Terminal rendering engine: canvas is faster, dom may be needed for some browsers or graphics cards", 1891 new String[] { 1892 TERMINAL_RENDERER_CANVAS, 1893 TERMINAL_RENDERER_DOM 1894 }, 1895 "canvas"); 1896 } 1897 1898 public final static String TERMINAL_RENDERER_CANVAS = "canvas"; 1899 public final static String TERMINAL_RENDERER_DOM = "dom"; 1900 1901 /** 1902 * Whether web links displayed in the Terminal tab are made clickable. 1903 */ terminalWeblinks()1904 public PrefValue<Boolean> terminalWeblinks() 1905 { 1906 return bool( 1907 "terminal_weblinks", 1908 "Make links in Terminal clickable", 1909 "Whether web links displayed in the Terminal tab are made clickable.", 1910 true); 1911 } 1912 1913 /** 1914 * Whether to print the render command use to knit R Markdown documents in the R Markdown tab. 1915 */ showRmdRenderCommand()1916 public PrefValue<Boolean> showRmdRenderCommand() 1917 { 1918 return bool( 1919 "show_rmd_render_command", 1920 "Show R Markdown render command", 1921 "Whether to print the render command use to knit R Markdown documents in the R Markdown tab.", 1922 false); 1923 } 1924 1925 /** 1926 * Whether to enable moving text on the editing surface by clicking and dragging it. 1927 */ enableTextDrag()1928 public PrefValue<Boolean> enableTextDrag() 1929 { 1930 return bool( 1931 "enable_text_drag", 1932 "Enable dragging text in code editor", 1933 "Whether to enable moving text on the editing surface by clicking and dragging it.", 1934 true); 1935 } 1936 1937 /** 1938 * Whether to show hidden files in the Files pane. 1939 */ showHiddenFiles()1940 public PrefValue<Boolean> showHiddenFiles() 1941 { 1942 return bool( 1943 "show_hidden_files", 1944 "Show hidden files in Files pane", 1945 "Whether to show hidden files in the Files pane.", 1946 false); 1947 } 1948 1949 /** 1950 * List of file names (case sensitive) that are always shown in the Files Pane, regardless of whether hidden files are shown 1951 */ alwaysShownFiles()1952 public PrefValue<JsArrayString> alwaysShownFiles() 1953 { 1954 return object( 1955 "always_shown_files", 1956 "Files always shown in the Files Pane", 1957 "List of file names (case sensitive) that are always shown in the Files Pane, regardless of whether hidden files are shown", 1958 JsArrayUtil.createStringArray(".build.yml", ".gitlab-ci.yml", ".travis.yml")); 1959 } 1960 1961 /** 1962 * List of file extensions (beginning with ., not case sensitive) that are always shown in the Files Pane, regardless of whether hidden files are shown 1963 */ alwaysShownExtensions()1964 public PrefValue<JsArrayString> alwaysShownExtensions() 1965 { 1966 return object( 1967 "always_shown_extensions", 1968 "Extensions always shown in the Files Pane", 1969 "List of file extensions (beginning with ., not case sensitive) that are always shown in the Files Pane, regardless of whether hidden files are shown", 1970 JsArrayUtil.createStringArray(".circleci", ".gitattributes", ".github", ".gitignore", ".httr-oauth", ".r", ".rbuildignore", ".rdata", ".renvignore", ".renviron", ".rhistory", ".rprofile", ".ruserdata")); 1971 } 1972 1973 /** 1974 * Whether to sort file names naturally, so that e.g., file10.R comes after file9.R 1975 */ sortFileNamesNaturally()1976 public PrefValue<Boolean> sortFileNamesNaturally() 1977 { 1978 return bool( 1979 "sort_file_names_naturally", 1980 "Sort file names naturally in Files pane", 1981 "Whether to sort file names naturally, so that e.g., file10.R comes after file9.R", 1982 true); 1983 } 1984 1985 /** 1986 * Whether to change the directory in the Files pane automatically when the working directory in R changes. 1987 */ syncFilesPaneWorkingDir()1988 public PrefValue<Boolean> syncFilesPaneWorkingDir() 1989 { 1990 return bool( 1991 "sync_files_pane_working_dir", 1992 "Synchronize the Files pane with the current working directory", 1993 "Whether to change the directory in the Files pane automatically when the working directory in R changes.", 1994 false); 1995 } 1996 1997 /** 1998 * The visibility of the Jobs tab. 1999 */ jobsTabVisibility()2000 public PrefValue<String> jobsTabVisibility() 2001 { 2002 return enumeration( 2003 "jobs_tab_visibility", 2004 "Jobs tab visibility", 2005 "The visibility of the Jobs tab.", 2006 new String[] { 2007 JOBS_TAB_VISIBILITY_CLOSED, 2008 JOBS_TAB_VISIBILITY_SHOWN, 2009 JOBS_TAB_VISIBILITY_DEFAULT 2010 }, 2011 "default"); 2012 } 2013 2014 public final static String JOBS_TAB_VISIBILITY_CLOSED = "closed"; 2015 public final static String JOBS_TAB_VISIBILITY_SHOWN = "shown"; 2016 public final static String JOBS_TAB_VISIBILITY_DEFAULT = "default"; 2017 2018 /** 2019 * Whether to show the Launcher jobs tab in RStudio Pro and RStudio Workbench. 2020 */ showLauncherJobsTab()2021 public PrefValue<Boolean> showLauncherJobsTab() 2022 { 2023 return bool( 2024 "show_launcher_jobs_tab", 2025 "", 2026 "Whether to show the Launcher jobs tab in RStudio Pro and RStudio Workbench.", 2027 true); 2028 } 2029 2030 /** 2031 * How to sort jobs in the Launcher tab in RStudio Pro and RStudio Workbench. 2032 */ launcherJobsSort()2033 public PrefValue<String> launcherJobsSort() 2034 { 2035 return enumeration( 2036 "launcher_jobs_sort", 2037 "", 2038 "How to sort jobs in the Launcher tab in RStudio Pro and RStudio Workbench.", 2039 new String[] { 2040 LAUNCHER_JOBS_SORT_RECORDED, 2041 LAUNCHER_JOBS_SORT_STATE 2042 }, 2043 "recorded"); 2044 } 2045 2046 public final static String LAUNCHER_JOBS_SORT_RECORDED = "recorded"; 2047 public final static String LAUNCHER_JOBS_SORT_STATE = "state"; 2048 2049 /** 2050 * How to detect busy status in the Terminal. 2051 */ busyDetection()2052 public PrefValue<String> busyDetection() 2053 { 2054 return enumeration( 2055 "busy_detection", 2056 "", 2057 "How to detect busy status in the Terminal.", 2058 new String[] { 2059 BUSY_DETECTION_ALWAYS, 2060 BUSY_DETECTION_NEVER, 2061 BUSY_DETECTION_LIST 2062 }, 2063 "always"); 2064 } 2065 2066 public final static String BUSY_DETECTION_ALWAYS = "always"; 2067 public final static String BUSY_DETECTION_NEVER = "never"; 2068 public final static String BUSY_DETECTION_LIST = "list"; 2069 2070 /** 2071 * A list of apps that should not be considered busy in the Terminal. 2072 */ busyExclusionList()2073 public PrefValue<JsArrayString> busyExclusionList() 2074 { 2075 return object( 2076 "busy_exclusion_list", 2077 "", 2078 "A list of apps that should not be considered busy in the Terminal.", 2079 JsArrayUtil.createStringArray("tmux", "screen")); 2080 } 2081 2082 /** 2083 * The working directory to use when knitting R Markdown documents. 2084 */ knitWorkingDir()2085 public PrefValue<String> knitWorkingDir() 2086 { 2087 return enumeration( 2088 "knit_working_dir", 2089 "Working directory for knitting", 2090 "The working directory to use when knitting R Markdown documents.", 2091 new String[] { 2092 KNIT_WORKING_DIR_DEFAULT, 2093 KNIT_WORKING_DIR_CURRENT, 2094 KNIT_WORKING_DIR_PROJECT 2095 }, 2096 "default"); 2097 } 2098 2099 public final static String KNIT_WORKING_DIR_DEFAULT = "default"; 2100 public final static String KNIT_WORKING_DIR_CURRENT = "current"; 2101 public final static String KNIT_WORKING_DIR_PROJECT = "project"; 2102 2103 /** 2104 * Which objects to show in the document outline pane. 2105 */ docOutlineShow()2106 public PrefValue<String> docOutlineShow() 2107 { 2108 return enumeration( 2109 "doc_outline_show", 2110 "Show in Document Outline", 2111 "Which objects to show in the document outline pane.", 2112 new String[] { 2113 DOC_OUTLINE_SHOW_SECTIONS_ONLY, 2114 DOC_OUTLINE_SHOW_SECTIONS_AND_CHUNKS, 2115 DOC_OUTLINE_SHOW_ALL 2116 }, 2117 "sections_only"); 2118 } 2119 2120 public final static String DOC_OUTLINE_SHOW_SECTIONS_ONLY = "sections_only"; 2121 public final static String DOC_OUTLINE_SHOW_SECTIONS_AND_CHUNKS = "sections_and_chunks"; 2122 public final static String DOC_OUTLINE_SHOW_ALL = "all"; 2123 2124 /** 2125 * When to preview LaTeX mathematical equations when cursor has not moved recently. 2126 */ latexPreviewOnCursorIdle()2127 public PrefValue<String> latexPreviewOnCursorIdle() 2128 { 2129 return enumeration( 2130 "latex_preview_on_cursor_idle", 2131 "Preview LaTeX equations on idle", 2132 "When to preview LaTeX mathematical equations when cursor has not moved recently.", 2133 new String[] { 2134 LATEX_PREVIEW_ON_CURSOR_IDLE_NEVER, 2135 LATEX_PREVIEW_ON_CURSOR_IDLE_INLINE_ONLY, 2136 LATEX_PREVIEW_ON_CURSOR_IDLE_ALWAYS 2137 }, 2138 "always"); 2139 } 2140 2141 public final static String LATEX_PREVIEW_ON_CURSOR_IDLE_NEVER = "never"; 2142 public final static String LATEX_PREVIEW_ON_CURSOR_IDLE_INLINE_ONLY = "inline_only"; 2143 public final static String LATEX_PREVIEW_ON_CURSOR_IDLE_ALWAYS = "always"; 2144 2145 /** 2146 * Whether to wrap around when going to the previous or next editor tab. 2147 */ wrapTabNavigation()2148 public PrefValue<Boolean> wrapTabNavigation() 2149 { 2150 return bool( 2151 "wrap_tab_navigation", 2152 "Wrap around when going to previous/next tab", 2153 "Whether to wrap around when going to the previous or next editor tab.", 2154 true); 2155 } 2156 2157 /** 2158 * The theme to use for the main RStudio user interface. 2159 */ globalTheme()2160 public PrefValue<String> globalTheme() 2161 { 2162 return enumeration( 2163 "global_theme", 2164 "Global theme", 2165 "The theme to use for the main RStudio user interface.", 2166 new String[] { 2167 GLOBAL_THEME_CLASSIC, 2168 GLOBAL_THEME_DEFAULT, 2169 GLOBAL_THEME_ALTERNATE 2170 }, 2171 "default"); 2172 } 2173 2174 public final static String GLOBAL_THEME_CLASSIC = "classic"; 2175 public final static String GLOBAL_THEME_DEFAULT = "default"; 2176 public final static String GLOBAL_THEME_ALTERNATE = "alternate"; 2177 2178 /** 2179 * Whether to ignore whitespace when generating diffs of version controlled files. 2180 */ gitDiffIgnoreWhitespace()2181 public PrefValue<Boolean> gitDiffIgnoreWhitespace() 2182 { 2183 return bool( 2184 "git_diff_ignore_whitespace", 2185 "Ignore whitespace in VCS diffs", 2186 "Whether to ignore whitespace when generating diffs of version controlled files.", 2187 false); 2188 } 2189 2190 /** 2191 * Whether double-clicking should select a word in the Console pane. 2192 */ consoleDoubleClickSelect()2193 public PrefValue<Boolean> consoleDoubleClickSelect() 2194 { 2195 return bool( 2196 "console_double_click_select", 2197 "Double click to select in the Console", 2198 "Whether double-clicking should select a word in the Console pane.", 2199 false); 2200 } 2201 2202 /** 2203 * Whether a git repo should be initialized inside new projects by default. 2204 */ newProjGitInit()2205 public PrefValue<Boolean> newProjGitInit() 2206 { 2207 return bool( 2208 "new_proj_git_init", 2209 "Create a Git repo in new projects", 2210 "Whether a git repo should be initialized inside new projects by default.", 2211 false); 2212 } 2213 2214 /** 2215 * Whether an renv environment should be created inside new projects by default. 2216 */ newProjUseRenv()2217 public PrefValue<Boolean> newProjUseRenv() 2218 { 2219 return bool( 2220 "new_proj_use_renv", 2221 "Create an renv environment in new projects", 2222 "Whether an renv environment should be created inside new projects by default.", 2223 false); 2224 } 2225 2226 /** 2227 * The root document to use when compiling PDF documents. 2228 */ rootDocument()2229 public PrefValue<String> rootDocument() 2230 { 2231 return string( 2232 "root_document", 2233 "Root document for PDF compilation", 2234 "The root document to use when compiling PDF documents.", 2235 ""); 2236 } 2237 2238 /** 2239 * When to show the server home page in RStudio Workbench. 2240 */ showUserHomePage()2241 public PrefValue<String> showUserHomePage() 2242 { 2243 return enumeration( 2244 "show_user_home_page", 2245 "Show user home page in RStudio Workbench", 2246 "When to show the server home page in RStudio Workbench.", 2247 new String[] { 2248 SHOW_USER_HOME_PAGE_ALWAYS, 2249 SHOW_USER_HOME_PAGE_NEVER, 2250 SHOW_USER_HOME_PAGE_SESSIONS 2251 }, 2252 "sessions"); 2253 } 2254 2255 public final static String SHOW_USER_HOME_PAGE_ALWAYS = "always"; 2256 public final static String SHOW_USER_HOME_PAGE_NEVER = "never"; 2257 public final static String SHOW_USER_HOME_PAGE_SESSIONS = "sessions"; 2258 2259 /** 2260 * Whether to reuse sessions when opening projects in RStudio Workbench. 2261 */ reuseSessionsForProjectLinks()2262 public PrefValue<Boolean> reuseSessionsForProjectLinks() 2263 { 2264 return bool( 2265 "reuse_sessions_for_project_links", 2266 "", 2267 "Whether to reuse sessions when opening projects in RStudio Workbench.", 2268 false); 2269 } 2270 2271 /** 2272 * Whether to enable RStudio's version control system interface. 2273 */ vcsEnabled()2274 public PrefValue<Boolean> vcsEnabled() 2275 { 2276 return bool( 2277 "vcs_enabled", 2278 "Enable version control if available", 2279 "Whether to enable RStudio's version control system interface.", 2280 true); 2281 } 2282 2283 /** 2284 * Automatically refresh VCS status? 2285 */ vcsAutorefresh()2286 public PrefValue<Boolean> vcsAutorefresh() 2287 { 2288 return bool( 2289 "vcs_autorefresh", 2290 "Auto-refresh state from version control", 2291 "Automatically refresh VCS status?", 2292 true); 2293 } 2294 2295 /** 2296 * The path to the Git executable to use. 2297 */ gitExePath()2298 public PrefValue<String> gitExePath() 2299 { 2300 return string( 2301 "git_exe_path", 2302 "Path to Git executable", 2303 "The path to the Git executable to use.", 2304 ""); 2305 } 2306 2307 /** 2308 * The path to the Subversion executable to use. 2309 */ svnExePath()2310 public PrefValue<String> svnExePath() 2311 { 2312 return string( 2313 "svn_exe_path", 2314 "Path to Subversion executable", 2315 "The path to the Subversion executable to use.", 2316 ""); 2317 } 2318 2319 /** 2320 * The path to the terminal executable to use. 2321 */ terminalPath()2322 public PrefValue<String> terminalPath() 2323 { 2324 return string( 2325 "terminal_path", 2326 "", 2327 "The path to the terminal executable to use.", 2328 ""); 2329 } 2330 2331 /** 2332 * The path to the RSA key file to use. 2333 */ rsaKeyPath()2334 public PrefValue<String> rsaKeyPath() 2335 { 2336 return string( 2337 "rsa_key_path", 2338 "", 2339 "The path to the RSA key file to use.", 2340 ""); 2341 } 2342 2343 /** 2344 * Whether to use the devtools R package. 2345 */ useDevtools()2346 public PrefValue<Boolean> useDevtools() 2347 { 2348 return bool( 2349 "use_devtools", 2350 "Use the devtools R package if available", 2351 "Whether to use the devtools R package.", 2352 true); 2353 } 2354 2355 /** 2356 * Whether to use Internet2 for networking on R for Windows. 2357 */ useInternet2()2358 public PrefValue<Boolean> useInternet2() 2359 { 2360 return bool( 2361 "use_internet2", 2362 "", 2363 "Whether to use Internet2 for networking on R for Windows.", 2364 true); 2365 } 2366 2367 /** 2368 * Whether to use secure downloads when fetching R packages. 2369 */ useSecureDownload()2370 public PrefValue<Boolean> useSecureDownload() 2371 { 2372 return bool( 2373 "use_secure_download", 2374 "Download R packages securely", 2375 "Whether to use secure downloads when fetching R packages.", 2376 true); 2377 } 2378 2379 /** 2380 * Whether to clean up temporary files after running R CMD CHECK. 2381 */ cleanupAfterRCmdCheck()2382 public PrefValue<Boolean> cleanupAfterRCmdCheck() 2383 { 2384 return bool( 2385 "cleanup_after_r_cmd_check", 2386 "Clean up temporary files after R CMD CHECK", 2387 "Whether to clean up temporary files after running R CMD CHECK.", 2388 true); 2389 } 2390 2391 /** 2392 * Whether to view the directory after running R CMD CHECK. 2393 */ viewDirAfterRCmdCheck()2394 public PrefValue<Boolean> viewDirAfterRCmdCheck() 2395 { 2396 return bool( 2397 "view_dir_after_r_cmd_check", 2398 "View directory after R CMD CHECK", 2399 "Whether to view the directory after running R CMD CHECK.", 2400 false); 2401 } 2402 2403 /** 2404 * Whether to hide object files in the Files pane. 2405 */ hideObjectFiles()2406 public PrefValue<Boolean> hideObjectFiles() 2407 { 2408 return bool( 2409 "hide_object_files", 2410 "Hide object files in the Files pane", 2411 "Whether to hide object files in the Files pane.", 2412 true); 2413 } 2414 2415 /** 2416 * Whether to restore the last project when starting RStudio. 2417 */ restoreLastProject()2418 public PrefValue<Boolean> restoreLastProject() 2419 { 2420 return bool( 2421 "restore_last_project", 2422 "Restore last project when starting RStudio", 2423 "Whether to restore the last project when starting RStudio.", 2424 true); 2425 } 2426 2427 /** 2428 * The number of seconds after which a project is deemed to have successfully started. 2429 */ projectSafeStartupSeconds()2430 public PrefValue<Integer> projectSafeStartupSeconds() 2431 { 2432 return integer( 2433 "project_safe_startup_seconds", 2434 "Number of seconds for safe project startup", 2435 "The number of seconds after which a project is deemed to have successfully started.", 2436 30); 2437 } 2438 2439 /** 2440 * Use tinytex to compile .tex files. 2441 */ useTinytex()2442 public PrefValue<Boolean> useTinytex() 2443 { 2444 return bool( 2445 "use_tinytex", 2446 "Use tinytex to compile .tex files", 2447 "Use tinytex to compile .tex files.", 2448 false); 2449 } 2450 2451 /** 2452 * Whether to clean output after running Texi2Dvi. 2453 */ cleanTexi2dviOutput()2454 public PrefValue<Boolean> cleanTexi2dviOutput() 2455 { 2456 return bool( 2457 "clean_texi2dvi_output", 2458 "Clean output after running Texi2Dvi", 2459 "Whether to clean output after running Texi2Dvi.", 2460 true); 2461 } 2462 2463 /** 2464 * Whether to enable shell escaping with LaTeX documents. 2465 */ latexShellEscape()2466 public PrefValue<Boolean> latexShellEscape() 2467 { 2468 return bool( 2469 "latex_shell_escape", 2470 "Shell escape LaTeX documents", 2471 "Whether to enable shell escaping with LaTeX documents.", 2472 false); 2473 } 2474 2475 /** 2476 * Whether to restore the last version of R used by the project in RStudio Pro and RStudio Workbench. 2477 */ restoreProjectRVersion()2478 public PrefValue<Boolean> restoreProjectRVersion() 2479 { 2480 return bool( 2481 "restore_project_r_version", 2482 "Restore project R version in RStudio Pro and RStudio Workbench", 2483 "Whether to restore the last version of R used by the project in RStudio Pro and RStudio Workbench.", 2484 true); 2485 } 2486 2487 /** 2488 * The verbosity level to use with Clang (0 - 2) 2489 */ clangVerbose()2490 public PrefValue<Integer> clangVerbose() 2491 { 2492 return integer( 2493 "clang_verbose", 2494 "Clang verbosity level (0 - 2)", 2495 "The verbosity level to use with Clang (0 - 2)", 2496 0); 2497 } 2498 2499 /** 2500 * Whether to automatically submit crash reports to RStudio. 2501 */ submitCrashReports()2502 public PrefValue<Boolean> submitCrashReports() 2503 { 2504 return bool( 2505 "submit_crash_reports", 2506 "Submit crash reports to RStudio", 2507 "Whether to automatically submit crash reports to RStudio.", 2508 true); 2509 } 2510 2511 /** 2512 * The R version to use by default. 2513 */ defaultRVersion()2514 public PrefValue<DefaultRVersion> defaultRVersion() 2515 { 2516 return object( 2517 "default_r_version", 2518 "", 2519 "The R version to use by default.", 2520 null); 2521 } 2522 2523 public static class DefaultRVersion extends JavaScriptObject 2524 { DefaultRVersion()2525 protected DefaultRVersion() {} 2526 getVersion()2527 public final native String getVersion() /*-{ 2528 return this && this.version || ""; 2529 }-*/; 2530 getRHome()2531 public final native String getRHome() /*-{ 2532 return this && this.r_home || ""; 2533 }-*/; 2534 getLabel()2535 public final native String getLabel() /*-{ 2536 return this && this.label || ""; 2537 }-*/; 2538 2539 } 2540 2541 /** 2542 * The maximum number of columns to show at once in the data viewer. 2543 */ dataViewerMaxColumns()2544 public PrefValue<Integer> dataViewerMaxColumns() 2545 { 2546 return integer( 2547 "data_viewer_max_columns", 2548 "Maximum number of columns in data viewer", 2549 "The maximum number of columns to show at once in the data viewer.", 2550 50); 2551 } 2552 2553 /** 2554 * Support accessibility aids such as screen readers (RStudio Server). 2555 */ enableScreenReader()2556 public PrefValue<Boolean> enableScreenReader() 2557 { 2558 return bool( 2559 "enable_screen_reader", 2560 "Enable support for screen readers in RStudio Server", 2561 "Support accessibility aids such as screen readers (RStudio Server).", 2562 false); 2563 } 2564 2565 /** 2566 * Number of milliseconds to wait after last keystroke before updating live region. 2567 */ typingStatusDelayMs()2568 public PrefValue<Integer> typingStatusDelayMs() 2569 { 2570 return integer( 2571 "typing_status_delay_ms", 2572 "Seconds to wait before updating ARIA live region", 2573 "Number of milliseconds to wait after last keystroke before updating live region.", 2574 2000); 2575 } 2576 2577 /** 2578 * Reduce use of animations in the user interface. 2579 */ reducedMotion()2580 public PrefValue<Boolean> reducedMotion() 2581 { 2582 return bool( 2583 "reduced_motion", 2584 "Reduced animation/motion mode", 2585 "Reduce use of animations in the user interface.", 2586 false); 2587 } 2588 2589 /** 2590 * Tab key moves focus out of text editing controls instead of inserting tabs. 2591 */ tabKeyMoveFocus()2592 public PrefValue<Boolean> tabKeyMoveFocus() 2593 { 2594 return bool( 2595 "tab_key_move_focus", 2596 "Tab key always moves focus", 2597 "Tab key moves focus out of text editing controls instead of inserting tabs.", 2598 false); 2599 } 2600 2601 /** 2602 * In source editor find panel, tab key moves focus directly from find text to replace text. 2603 */ findPanelLegacyTabSequence()2604 public PrefValue<Boolean> findPanelLegacyTabSequence() 2605 { 2606 return bool( 2607 "find_panel_legacy_tab_sequence", 2608 "Tab key moves focus directly from find text to replace text in find panel", 2609 "In source editor find panel, tab key moves focus directly from find text to replace text.", 2610 false); 2611 } 2612 2613 /** 2614 * Control with keyboard focus displays a visual focus indicator. 2615 */ showFocusRectangles()2616 public PrefValue<Boolean> showFocusRectangles() 2617 { 2618 return bool( 2619 "show_focus_rectangles", 2620 "Always show focus outlines", 2621 "Control with keyboard focus displays a visual focus indicator.", 2622 true); 2623 } 2624 2625 /** 2626 * Show which panel contains keyboard focus. 2627 */ showPanelFocusRectangle()2628 public PrefValue<Boolean> showPanelFocusRectangle() 2629 { 2630 return bool( 2631 "show_panel_focus_rectangle", 2632 "Show focus outline around focused panel", 2633 "Show which panel contains keyboard focus.", 2634 false); 2635 } 2636 2637 /** 2638 * How to deal with changes to documents on idle. 2639 */ autoSaveOnIdle()2640 public PrefValue<String> autoSaveOnIdle() 2641 { 2642 return enumeration( 2643 "auto_save_on_idle", 2644 "Autosave mode on idle", 2645 "How to deal with changes to documents on idle.", 2646 new String[] { 2647 AUTO_SAVE_ON_IDLE_COMMIT, 2648 AUTO_SAVE_ON_IDLE_BACKUP, 2649 AUTO_SAVE_ON_IDLE_NONE 2650 }, 2651 "backup"); 2652 } 2653 2654 public final static String AUTO_SAVE_ON_IDLE_COMMIT = "commit"; 2655 public final static String AUTO_SAVE_ON_IDLE_BACKUP = "backup"; 2656 public final static String AUTO_SAVE_ON_IDLE_NONE = "none"; 2657 2658 /** 2659 * The idle period, in milliseconds, after which documents should be auto-saved. 2660 */ autoSaveIdleMs()2661 public PrefValue<Integer> autoSaveIdleMs() 2662 { 2663 return integer( 2664 "auto_save_idle_ms", 2665 "Idle period for document autosave (ms)", 2666 "The idle period, in milliseconds, after which documents should be auto-saved.", 2667 1000); 2668 } 2669 2670 /** 2671 * Whether to automatically save when the editor loses focus. 2672 */ autoSaveOnBlur()2673 public PrefValue<Boolean> autoSaveOnBlur() 2674 { 2675 return bool( 2676 "auto_save_on_blur", 2677 "Save documents when editor loses input focus", 2678 "Whether to automatically save when the editor loses focus.", 2679 false); 2680 } 2681 2682 /** 2683 * Initial directory for new terminals. 2684 */ terminalInitialDirectory()2685 public PrefValue<String> terminalInitialDirectory() 2686 { 2687 return enumeration( 2688 "terminal_initial_directory", 2689 "Initial working directory for new terminals", 2690 "Initial directory for new terminals.", 2691 new String[] { 2692 TERMINAL_INITIAL_DIRECTORY_PROJECT, 2693 TERMINAL_INITIAL_DIRECTORY_CURRENT, 2694 TERMINAL_INITIAL_DIRECTORY_HOME 2695 }, 2696 "project"); 2697 } 2698 2699 public final static String TERMINAL_INITIAL_DIRECTORY_PROJECT = "project"; 2700 public final static String TERMINAL_INITIAL_DIRECTORY_CURRENT = "current"; 2701 public final static String TERMINAL_INITIAL_DIRECTORY_HOME = "home"; 2702 2703 /** 2704 * Whether to show the full path to project in desktop window title. 2705 */ fullProjectPathInWindowTitle()2706 public PrefValue<Boolean> fullProjectPathInWindowTitle() 2707 { 2708 return bool( 2709 "full_project_path_in_window_title", 2710 "Show full path to project in RStudio Desktop windows", 2711 "Whether to show the full path to project in desktop window title.", 2712 false); 2713 } 2714 2715 /** 2716 * Whether to enable visual editing by default for new markdown documents 2717 */ visualMarkdownEditingIsDefault()2718 public PrefValue<Boolean> visualMarkdownEditingIsDefault() 2719 { 2720 return bool( 2721 "visual_markdown_editing_is_default", 2722 "Use visual editing by default for new markdown documents", 2723 "Whether to enable visual editing by default for new markdown documents", 2724 false); 2725 } 2726 2727 /** 2728 * Default spacing for lists created in the visual editor 2729 */ visualMarkdownEditingListSpacing()2730 public PrefValue<String> visualMarkdownEditingListSpacing() 2731 { 2732 return enumeration( 2733 "visual_markdown_editing_list_spacing", 2734 "Default list spacing in visual markdown editing mode", 2735 "Default spacing for lists created in the visual editor", 2736 new String[] { 2737 VISUAL_MARKDOWN_EDITING_LIST_SPACING_TIGHT, 2738 VISUAL_MARKDOWN_EDITING_LIST_SPACING_SPACED 2739 }, 2740 "spaced"); 2741 } 2742 2743 public final static String VISUAL_MARKDOWN_EDITING_LIST_SPACING_TIGHT = "tight"; 2744 public final static String VISUAL_MARKDOWN_EDITING_LIST_SPACING_SPACED = "spaced"; 2745 2746 /** 2747 * Whether to automatically wrap text when writing markdown 2748 */ visualMarkdownEditingWrap()2749 public PrefValue<String> visualMarkdownEditingWrap() 2750 { 2751 return enumeration( 2752 "visual_markdown_editing_wrap", 2753 "Wrap text in visual markdown editing mode", 2754 "Whether to automatically wrap text when writing markdown", 2755 new String[] { 2756 VISUAL_MARKDOWN_EDITING_WRAP_NONE, 2757 VISUAL_MARKDOWN_EDITING_WRAP_COLUMN, 2758 VISUAL_MARKDOWN_EDITING_WRAP_SENTENCE 2759 }, 2760 "none"); 2761 } 2762 2763 public final static String VISUAL_MARKDOWN_EDITING_WRAP_NONE = "none"; 2764 public final static String VISUAL_MARKDOWN_EDITING_WRAP_COLUMN = "column"; 2765 public final static String VISUAL_MARKDOWN_EDITING_WRAP_SENTENCE = "sentence"; 2766 2767 /** 2768 * The column to wrap text at when writing markdown 2769 */ visualMarkdownEditingWrapAtColumn()2770 public PrefValue<Integer> visualMarkdownEditingWrapAtColumn() 2771 { 2772 return integer( 2773 "visual_markdown_editing_wrap_at_column", 2774 "Wrap column for visual markdown editing mode", 2775 "The column to wrap text at when writing markdown", 2776 72); 2777 } 2778 2779 /** 2780 * Placement of footnotes within markdown output. 2781 */ visualMarkdownEditingReferencesLocation()2782 public PrefValue<String> visualMarkdownEditingReferencesLocation() 2783 { 2784 return enumeration( 2785 "visual_markdown_editing_references_location", 2786 "Place visual markdown footnotes in", 2787 "Placement of footnotes within markdown output.", 2788 new String[] { 2789 VISUAL_MARKDOWN_EDITING_REFERENCES_LOCATION_BLOCK, 2790 VISUAL_MARKDOWN_EDITING_REFERENCES_LOCATION_SECTION, 2791 VISUAL_MARKDOWN_EDITING_REFERENCES_LOCATION_DOCUMENT 2792 }, 2793 "block"); 2794 } 2795 2796 public final static String VISUAL_MARKDOWN_EDITING_REFERENCES_LOCATION_BLOCK = "block"; 2797 public final static String VISUAL_MARKDOWN_EDITING_REFERENCES_LOCATION_SECTION = "section"; 2798 public final static String VISUAL_MARKDOWN_EDITING_REFERENCES_LOCATION_DOCUMENT = "document"; 2799 2800 /** 2801 * Whether to write canonical visual mode markdown when saving from source mode. 2802 */ visualMarkdownEditingCanonical()2803 public PrefValue<Boolean> visualMarkdownEditingCanonical() 2804 { 2805 return bool( 2806 "visual_markdown_editing_canonical", 2807 "Write canonical visual mode markdown in source mode", 2808 "Whether to write canonical visual mode markdown when saving from source mode.", 2809 false); 2810 } 2811 2812 /** 2813 * Maximum content width for visual editing mode, in pixels 2814 */ visualMarkdownEditingMaxContentWidth()2815 public PrefValue<Integer> visualMarkdownEditingMaxContentWidth() 2816 { 2817 return integer( 2818 "visual_markdown_editing_max_content_width", 2819 "Max content width for visual markdown editor (px)", 2820 "Maximum content width for visual editing mode, in pixels", 2821 700); 2822 } 2823 2824 /** 2825 * Whether to show the document outline by default when opening R Markdown documents in visual mode. 2826 */ visualMarkdownEditingShowDocOutline()2827 public PrefValue<Boolean> visualMarkdownEditingShowDocOutline() 2828 { 2829 return bool( 2830 "visual_markdown_editing_show_doc_outline", 2831 "Show document outline in visual markdown editing mode", 2832 "Whether to show the document outline by default when opening R Markdown documents in visual mode.", 2833 true); 2834 } 2835 2836 /** 2837 * Whether to show the margin guide in the visual mode code blocks. 2838 */ visualMarkdownEditingShowMargin()2839 public PrefValue<Boolean> visualMarkdownEditingShowMargin() 2840 { 2841 return bool( 2842 "visual_markdown_editing_show_margin", 2843 "Show margin in visual mode code blocks", 2844 "Whether to show the margin guide in the visual mode code blocks.", 2845 false); 2846 } 2847 2848 /** 2849 * The default visual editing mode font size, in points 2850 */ visualMarkdownEditingFontSizePoints()2851 public PrefValue<Integer> visualMarkdownEditingFontSizePoints() 2852 { 2853 return integer( 2854 "visual_markdown_editing_font_size_points", 2855 "Font size for visual editing mode", 2856 "The default visual editing mode font size, in points", 2857 0); 2858 } 2859 2860 /** 2861 * The name of the editor to use to provide code editing in visual mode 2862 */ visualMarkdownCodeEditor()2863 public PrefValue<String> visualMarkdownCodeEditor() 2864 { 2865 return enumeration( 2866 "visual_markdown_code_editor", 2867 "Editor for code chunks in visual editing mode", 2868 "The name of the editor to use to provide code editing in visual mode", 2869 new String[] { 2870 VISUAL_MARKDOWN_CODE_EDITOR_ACE, 2871 VISUAL_MARKDOWN_CODE_EDITOR_CODEMIRROR 2872 }, 2873 "ace"); 2874 } 2875 2876 public final static String VISUAL_MARKDOWN_CODE_EDITOR_ACE = "ace"; 2877 public final static String VISUAL_MARKDOWN_CODE_EDITOR_CODEMIRROR = "codemirror"; 2878 2879 /** 2880 * Zotero libraries to insert citations from. 2881 */ zoteroLibraries()2882 public PrefValue<JsArrayString> zoteroLibraries() 2883 { 2884 return object( 2885 "zotero_libraries", 2886 "Zotero libraries", 2887 "Zotero libraries to insert citations from.", 2888 JsArrayUtil.createStringArray("My Library")); 2889 } 2890 2891 /** 2892 * Preferred emoji skintone 2893 */ emojiSkintone()2894 public PrefValue<String> emojiSkintone() 2895 { 2896 return enumeration( 2897 "emoji_skintone", 2898 "", 2899 "Preferred emoji skintone", 2900 new String[] { 2901 EMOJI_SKINTONE__NONE_, 2902 EMOJI_SKINTONE__DEFAULT_, 2903 EMOJI_SKINTONE_LIGHT, 2904 EMOJI_SKINTONE_MEDIUM_LIGHT, 2905 EMOJI_SKINTONE_MEDIUM, 2906 EMOJI_SKINTONE_MEDIUM_DARK, 2907 EMOJI_SKINTONE_DARK 2908 }, 2909 "(None)"); 2910 } 2911 2912 public final static String EMOJI_SKINTONE__NONE_ = "(None)"; 2913 public final static String EMOJI_SKINTONE__DEFAULT_ = "(Default)"; 2914 public final static String EMOJI_SKINTONE_LIGHT = "Light"; 2915 public final static String EMOJI_SKINTONE_MEDIUM_LIGHT = "Medium-Light"; 2916 public final static String EMOJI_SKINTONE_MEDIUM = "Medium"; 2917 public final static String EMOJI_SKINTONE_MEDIUM_DARK = "Medium-Dark"; 2918 public final static String EMOJI_SKINTONE_DARK = "Dark"; 2919 2920 /** 2921 * List of aria-live announcements to disable. 2922 */ disabledAriaLiveAnnouncements()2923 public PrefValue<JsArrayString> disabledAriaLiveAnnouncements() 2924 { 2925 return object( 2926 "disabled_aria_live_announcements", 2927 "Disabled aria-live announcements", 2928 "List of aria-live announcements to disable.", 2929 JsArrayUtil.createStringArray()); 2930 } 2931 2932 /** 2933 * Maximum number of lines of console output announced after a command. 2934 */ screenreaderConsoleAnnounceLimit()2935 public PrefValue<Integer> screenreaderConsoleAnnounceLimit() 2936 { 2937 return integer( 2938 "screenreader_console_announce_limit", 2939 "Maximum number of console lines to announce", 2940 "Maximum number of lines of console output announced after a command.", 2941 25); 2942 } 2943 2944 /** 2945 * List of path components; file monitor will ignore paths containing one or more of these components. 2946 */ fileMonitorIgnoredComponents()2947 public PrefValue<JsArrayString> fileMonitorIgnoredComponents() 2948 { 2949 return object( 2950 "file_monitor_ignored_components", 2951 "List of path components ignored by file monitor", 2952 "List of path components; file monitor will ignore paths containing one or more of these components.", 2953 JsArrayUtil.createStringArray()); 2954 } 2955 2956 /** 2957 * Whether to install R package dependencies one at a time. 2958 */ installPkgDepsIndividually()2959 public PrefValue<Boolean> installPkgDepsIndividually() 2960 { 2961 return bool( 2962 "install_pkg_deps_individually", 2963 "Install R package dependencies one at a time", 2964 "Whether to install R package dependencies one at a time.", 2965 true); 2966 } 2967 2968 /** 2969 * R graphics backend. 2970 */ graphicsBackend()2971 public PrefValue<String> graphicsBackend() 2972 { 2973 return enumeration( 2974 "graphics_backend", 2975 "R graphics backend", 2976 "R graphics backend.", 2977 new String[] { 2978 GRAPHICS_BACKEND_DEFAULT, 2979 GRAPHICS_BACKEND_CAIRO, 2980 GRAPHICS_BACKEND_CAIRO_PNG, 2981 GRAPHICS_BACKEND_QUARTZ, 2982 GRAPHICS_BACKEND_WINDOWS, 2983 GRAPHICS_BACKEND_RAGG 2984 }, 2985 "default"); 2986 } 2987 2988 public final static String GRAPHICS_BACKEND_DEFAULT = "default"; 2989 public final static String GRAPHICS_BACKEND_CAIRO = "cairo"; 2990 public final static String GRAPHICS_BACKEND_CAIRO_PNG = "cairo-png"; 2991 public final static String GRAPHICS_BACKEND_QUARTZ = "quartz"; 2992 public final static String GRAPHICS_BACKEND_WINDOWS = "windows"; 2993 public final static String GRAPHICS_BACKEND_RAGG = "ragg"; 2994 2995 /** 2996 * Type of anti-aliasing to be used for generated R plots. 2997 */ graphicsAntialiasing()2998 public PrefValue<String> graphicsAntialiasing() 2999 { 3000 return enumeration( 3001 "graphics_antialiasing", 3002 "R graphics antialiasing method", 3003 "Type of anti-aliasing to be used for generated R plots.", 3004 new String[] { 3005 GRAPHICS_ANTIALIASING_DEFAULT, 3006 GRAPHICS_ANTIALIASING_NONE, 3007 GRAPHICS_ANTIALIASING_GRAY, 3008 GRAPHICS_ANTIALIASING_SUBPIXEL 3009 }, 3010 "default"); 3011 } 3012 3013 public final static String GRAPHICS_ANTIALIASING_DEFAULT = "default"; 3014 public final static String GRAPHICS_ANTIALIASING_NONE = "none"; 3015 public final static String GRAPHICS_ANTIALIASING_GRAY = "gray"; 3016 public final static String GRAPHICS_ANTIALIASING_SUBPIXEL = "subpixel"; 3017 3018 /** 3019 * List of fixed-width fonts to check for browser support. 3020 */ browserFixedWidthFonts()3021 public PrefValue<JsArrayString> browserFixedWidthFonts() 3022 { 3023 return object( 3024 "browser_fixed_width_fonts", 3025 "Fixed-width font list for RStudio Server", 3026 "List of fixed-width fonts to check for browser support.", 3027 JsArrayUtil.createStringArray("Andale Mono", "Bitstream Vera Sans Mono", "Cascadia Code", "Consolas", "Courier New", "Courier", "DejaVu Sans Mono", "Droid Sans Mono", "Fira Code", "Hack", "IBM Plex Mono", "Inconsolata", "JetBrains Mono", "Lucida Console", "Lucida Sans Typewriter", "Menlo", "Monaco", "Monoid", "Operator Mono", "Pragmata", "SF Mono", "Source Code Pro", "Vera Sans Mono", "Victor Mono", "Ubuntu Mono")); 3028 } 3029 3030 /** 3031 * The Python type. 3032 */ pythonType()3033 public PrefValue<String> pythonType() 3034 { 3035 return string( 3036 "python_type", 3037 "", 3038 "The Python type.", 3039 ""); 3040 } 3041 3042 /** 3043 * The Python version. 3044 */ pythonVersion()3045 public PrefValue<String> pythonVersion() 3046 { 3047 return string( 3048 "python_version", 3049 "", 3050 "The Python version.", 3051 ""); 3052 } 3053 3054 /** 3055 * The path to the default Python interpreter. 3056 */ pythonPath()3057 public PrefValue<String> pythonPath() 3058 { 3059 return string( 3060 "python_path", 3061 "", 3062 "The path to the default Python interpreter.", 3063 ""); 3064 } 3065 3066 /** 3067 * The maximum amount of seconds of retry for save operations. 3068 */ saveRetryTimeout()3069 public PrefValue<Integer> saveRetryTimeout() 3070 { 3071 return integer( 3072 "save_retry_timeout", 3073 "Save Retry Timeout", 3074 "The maximum amount of seconds of retry for save operations.", 3075 15); 3076 } 3077 3078 /** 3079 * Whether the Insert Pipe Operator command should insert the native R pipe operator, |> 3080 */ insertNativePipeOperator()3081 public PrefValue<Boolean> insertNativePipeOperator() 3082 { 3083 return bool( 3084 "insert_native_pipe_operator", 3085 "Use R's native pipe operator, |>", 3086 "Whether the Insert Pipe Operator command should insert the native R pipe operator, |>", 3087 false); 3088 } 3089 3090 /** 3091 * Whether to keep track of recently used commands in the Command Palette 3092 */ commandPaletteMru()3093 public PrefValue<Boolean> commandPaletteMru() 3094 { 3095 return bool( 3096 "command_palette_mru", 3097 "Remember recently used items in Command Palette", 3098 "Whether to keep track of recently used commands in the Command Palette", 3099 true); 3100 } 3101 3102 /** 3103 * Whether to compute and show memory usage in the Environment Pane 3104 */ showMemoryUsage()3105 public PrefValue<Boolean> showMemoryUsage() 3106 { 3107 return bool( 3108 "show_memory_usage", 3109 "Show memory usage in Environment Pane", 3110 "Whether to compute and show memory usage in the Environment Pane", 3111 true); 3112 } 3113 3114 /** 3115 * How many seconds to wait between automatic requeries of memory statistics (0 to disable) 3116 */ memoryQueryIntervalSeconds()3117 public PrefValue<Integer> memoryQueryIntervalSeconds() 3118 { 3119 return integer( 3120 "memory_query_interval_seconds", 3121 "Interval for requerying memory stats (seconds)", 3122 "How many seconds to wait between automatic requeries of memory statistics (0 to disable)", 3123 10); 3124 } 3125 3126 /** 3127 * Enable Python terminal hooks. When enabled, the RStudio-configured version of Python will be placed on the PATH. 3128 */ terminalPythonIntegration()3129 public PrefValue<Boolean> terminalPythonIntegration() 3130 { 3131 return bool( 3132 "terminal_python_integration", 3133 "Enable terminal Python integration", 3134 "Enable Python terminal hooks. When enabled, the RStudio-configured version of Python will be placed on the PATH.", 3135 true); 3136 } 3137 3138 /** 3139 * Enable session protocol debug logging showing all session requests and events 3140 */ sessionProtocolDebug()3141 public PrefValue<Boolean> sessionProtocolDebug() 3142 { 3143 return bool( 3144 "session_protocol_debug", 3145 "Session protocol debug logging", 3146 "Enable session protocol debug logging showing all session requests and events", 3147 false); 3148 } 3149 3150 /** 3151 * When enabled, if the active project contains a Python virtual environment, then RStudio will automatically activate this environment on startup. 3152 */ pythonProjectEnvironmentAutomaticActivate()3153 public PrefValue<Boolean> pythonProjectEnvironmentAutomaticActivate() 3154 { 3155 return bool( 3156 "python_project_environment_automatic_activate", 3157 "Automatically activate project Python environments", 3158 "When enabled, if the active project contains a Python virtual environment, then RStudio will automatically activate this environment on startup.", 3159 true); 3160 } 3161 3162 /** 3163 * When enabled, RStudio will detect R objects containing null external pointers when building the Environment pane, and avoid introspecting their contents further. 3164 */ checkNullExternalPointers()3165 public PrefValue<Boolean> checkNullExternalPointers() 3166 { 3167 return bool( 3168 "check_null_external_pointers", 3169 "Check values in the Environment pane for null external pointers", 3170 "When enabled, RStudio will detect R objects containing null external pointers when building the Environment pane, and avoid introspecting their contents further.", 3171 false); 3172 } 3173 syncPrefs(String layer, JsObject source)3174 public void syncPrefs(String layer, JsObject source) 3175 { 3176 if (source.hasKey("run_rprofile_on_resume")) 3177 runRprofileOnResume().setValue(layer, source.getBool("run_rprofile_on_resume")); 3178 if (source.hasKey("save_workspace")) 3179 saveWorkspace().setValue(layer, source.getString("save_workspace")); 3180 if (source.hasKey("load_workspace")) 3181 loadWorkspace().setValue(layer, source.getBool("load_workspace")); 3182 if (source.hasKey("initial_working_directory")) 3183 initialWorkingDirectory().setValue(layer, source.getString("initial_working_directory")); 3184 if (source.hasKey("cran_mirror")) 3185 cranMirror().setValue(layer, source.getObject("cran_mirror")); 3186 if (source.hasKey("bioconductor_mirror_name")) 3187 bioconductorMirrorName().setValue(layer, source.getString("bioconductor_mirror_name")); 3188 if (source.hasKey("bioconductor_mirror_url")) 3189 bioconductorMirrorUrl().setValue(layer, source.getString("bioconductor_mirror_url")); 3190 if (source.hasKey("always_save_history")) 3191 alwaysSaveHistory().setValue(layer, source.getBool("always_save_history")); 3192 if (source.hasKey("remove_history_duplicates")) 3193 removeHistoryDuplicates().setValue(layer, source.getBool("remove_history_duplicates")); 3194 if (source.hasKey("show_last_dot_value")) 3195 showLastDotValue().setValue(layer, source.getBool("show_last_dot_value")); 3196 if (source.hasKey("line_ending_conversion")) 3197 lineEndingConversion().setValue(layer, source.getString("line_ending_conversion")); 3198 if (source.hasKey("use_newlines_in_makefiles")) 3199 useNewlinesInMakefiles().setValue(layer, source.getBool("use_newlines_in_makefiles")); 3200 if (source.hasKey("windows_terminal_shell")) 3201 windowsTerminalShell().setValue(layer, source.getString("windows_terminal_shell")); 3202 if (source.hasKey("posix_terminal_shell")) 3203 posixTerminalShell().setValue(layer, source.getString("posix_terminal_shell")); 3204 if (source.hasKey("custom_shell_command")) 3205 customShellCommand().setValue(layer, source.getString("custom_shell_command")); 3206 if (source.hasKey("custom_shell_options")) 3207 customShellOptions().setValue(layer, source.getString("custom_shell_options")); 3208 if (source.hasKey("show_line_numbers")) 3209 showLineNumbers().setValue(layer, source.getBool("show_line_numbers")); 3210 if (source.hasKey("highlight_selected_word")) 3211 highlightSelectedWord().setValue(layer, source.getBool("highlight_selected_word")); 3212 if (source.hasKey("highlight_selected_line")) 3213 highlightSelectedLine().setValue(layer, source.getBool("highlight_selected_line")); 3214 if (source.hasKey("panes")) 3215 panes().setValue(layer, source.getObject("panes")); 3216 if (source.hasKey("allow_source_columns")) 3217 allowSourceColumns().setValue(layer, source.getBool("allow_source_columns")); 3218 if (source.hasKey("use_spaces_for_tab")) 3219 useSpacesForTab().setValue(layer, source.getBool("use_spaces_for_tab")); 3220 if (source.hasKey("num_spaces_for_tab")) 3221 numSpacesForTab().setValue(layer, source.getInteger("num_spaces_for_tab")); 3222 if (source.hasKey("auto_detect_indentation")) 3223 autoDetectIndentation().setValue(layer, source.getBool("auto_detect_indentation")); 3224 if (source.hasKey("show_margin")) 3225 showMargin().setValue(layer, source.getBool("show_margin")); 3226 if (source.hasKey("blinking_cursor")) 3227 blinkingCursor().setValue(layer, source.getBool("blinking_cursor")); 3228 if (source.hasKey("margin_column")) 3229 marginColumn().setValue(layer, source.getInteger("margin_column")); 3230 if (source.hasKey("show_invisibles")) 3231 showInvisibles().setValue(layer, source.getBool("show_invisibles")); 3232 if (source.hasKey("show_indent_guides")) 3233 showIndentGuides().setValue(layer, source.getBool("show_indent_guides")); 3234 if (source.hasKey("continue_comments_on_newline")) 3235 continueCommentsOnNewline().setValue(layer, source.getBool("continue_comments_on_newline")); 3236 if (source.hasKey("highlight_web_link")) 3237 highlightWebLink().setValue(layer, source.getBool("highlight_web_link")); 3238 if (source.hasKey("editor_keybindings")) 3239 editorKeybindings().setValue(layer, source.getString("editor_keybindings")); 3240 if (source.hasKey("insert_matching")) 3241 insertMatching().setValue(layer, source.getBool("insert_matching")); 3242 if (source.hasKey("insert_spaces_around_equals")) 3243 insertSpacesAroundEquals().setValue(layer, source.getBool("insert_spaces_around_equals")); 3244 if (source.hasKey("insert_parens_after_function_completion")) 3245 insertParensAfterFunctionCompletion().setValue(layer, source.getBool("insert_parens_after_function_completion")); 3246 if (source.hasKey("tab_multiline_completion")) 3247 tabMultilineCompletion().setValue(layer, source.getBool("tab_multiline_completion")); 3248 if (source.hasKey("tab_completion")) 3249 tabCompletion().setValue(layer, source.getBool("tab_completion")); 3250 if (source.hasKey("show_help_tooltip_on_idle")) 3251 showHelpTooltipOnIdle().setValue(layer, source.getBool("show_help_tooltip_on_idle")); 3252 if (source.hasKey("surround_selection")) 3253 surroundSelection().setValue(layer, source.getString("surround_selection")); 3254 if (source.hasKey("enable_snippets")) 3255 enableSnippets().setValue(layer, source.getBool("enable_snippets")); 3256 if (source.hasKey("code_completion")) 3257 codeCompletion().setValue(layer, source.getString("code_completion")); 3258 if (source.hasKey("code_completion_other")) 3259 codeCompletionOther().setValue(layer, source.getString("code_completion_other")); 3260 if (source.hasKey("console_code_completion")) 3261 consoleCodeCompletion().setValue(layer, source.getBool("console_code_completion")); 3262 if (source.hasKey("code_completion_delay")) 3263 codeCompletionDelay().setValue(layer, source.getInteger("code_completion_delay")); 3264 if (source.hasKey("code_completion_characters")) 3265 codeCompletionCharacters().setValue(layer, source.getInteger("code_completion_characters")); 3266 if (source.hasKey("show_function_signature_tooltips")) 3267 showFunctionSignatureTooltips().setValue(layer, source.getBool("show_function_signature_tooltips")); 3268 if (source.hasKey("show_diagnostics_r")) 3269 showDiagnosticsR().setValue(layer, source.getBool("show_diagnostics_r")); 3270 if (source.hasKey("show_diagnostics_cpp")) 3271 showDiagnosticsCpp().setValue(layer, source.getBool("show_diagnostics_cpp")); 3272 if (source.hasKey("show_diagnostics_other")) 3273 showDiagnosticsOther().setValue(layer, source.getBool("show_diagnostics_other")); 3274 if (source.hasKey("style_diagnostics")) 3275 styleDiagnostics().setValue(layer, source.getBool("style_diagnostics")); 3276 if (source.hasKey("diagnostics_on_save")) 3277 diagnosticsOnSave().setValue(layer, source.getBool("diagnostics_on_save")); 3278 if (source.hasKey("background_diagnostics")) 3279 backgroundDiagnostics().setValue(layer, source.getBool("background_diagnostics")); 3280 if (source.hasKey("background_diagnostics_delay_ms")) 3281 backgroundDiagnosticsDelayMs().setValue(layer, source.getInteger("background_diagnostics_delay_ms")); 3282 if (source.hasKey("diagnostics_in_r_function_calls")) 3283 diagnosticsInRFunctionCalls().setValue(layer, source.getBool("diagnostics_in_r_function_calls")); 3284 if (source.hasKey("check_arguments_to_r_function_calls")) 3285 checkArgumentsToRFunctionCalls().setValue(layer, source.getBool("check_arguments_to_r_function_calls")); 3286 if (source.hasKey("check_unexpected_assignment_in_function_call")) 3287 checkUnexpectedAssignmentInFunctionCall().setValue(layer, source.getBool("check_unexpected_assignment_in_function_call")); 3288 if (source.hasKey("warn_if_no_such_variable_in_scope")) 3289 warnIfNoSuchVariableInScope().setValue(layer, source.getBool("warn_if_no_such_variable_in_scope")); 3290 if (source.hasKey("warn_variable_defined_but_not_used")) 3291 warnVariableDefinedButNotUsed().setValue(layer, source.getBool("warn_variable_defined_but_not_used")); 3292 if (source.hasKey("auto_discover_package_dependencies")) 3293 autoDiscoverPackageDependencies().setValue(layer, source.getBool("auto_discover_package_dependencies")); 3294 if (source.hasKey("auto_append_newline")) 3295 autoAppendNewline().setValue(layer, source.getBool("auto_append_newline")); 3296 if (source.hasKey("strip_trailing_whitespace")) 3297 stripTrailingWhitespace().setValue(layer, source.getBool("strip_trailing_whitespace")); 3298 if (source.hasKey("restore_source_document_cursor_position")) 3299 restoreSourceDocumentCursorPosition().setValue(layer, source.getBool("restore_source_document_cursor_position")); 3300 if (source.hasKey("reindent_on_paste")) 3301 reindentOnPaste().setValue(layer, source.getBool("reindent_on_paste")); 3302 if (source.hasKey("vertically_align_arguments_indent")) 3303 verticallyAlignArgumentsIndent().setValue(layer, source.getBool("vertically_align_arguments_indent")); 3304 if (source.hasKey("soft_wrap_r_files")) 3305 softWrapRFiles().setValue(layer, source.getBool("soft_wrap_r_files")); 3306 if (source.hasKey("soft_wrap_rmd_files")) 3307 softWrapRmdFiles().setValue(layer, source.getBool("soft_wrap_rmd_files")); 3308 if (source.hasKey("focus_console_after_exec")) 3309 focusConsoleAfterExec().setValue(layer, source.getBool("focus_console_after_exec")); 3310 if (source.hasKey("fold_style")) 3311 foldStyle().setValue(layer, source.getString("fold_style")); 3312 if (source.hasKey("save_before_sourcing")) 3313 saveBeforeSourcing().setValue(layer, source.getBool("save_before_sourcing")); 3314 if (source.hasKey("syntax_color_console")) 3315 syntaxColorConsole().setValue(layer, source.getBool("syntax_color_console")); 3316 if (source.hasKey("highlight_console_errors")) 3317 highlightConsoleErrors().setValue(layer, source.getBool("highlight_console_errors")); 3318 if (source.hasKey("scroll_past_end_of_document")) 3319 scrollPastEndOfDocument().setValue(layer, source.getBool("scroll_past_end_of_document")); 3320 if (source.hasKey("highlight_r_function_calls")) 3321 highlightRFunctionCalls().setValue(layer, source.getBool("highlight_r_function_calls")); 3322 if (source.hasKey("rainbow_parentheses")) 3323 rainbowParentheses().setValue(layer, source.getBool("rainbow_parentheses")); 3324 if (source.hasKey("console_line_length_limit")) 3325 consoleLineLengthLimit().setValue(layer, source.getInteger("console_line_length_limit")); 3326 if (source.hasKey("console_max_lines")) 3327 consoleMaxLines().setValue(layer, source.getInteger("console_max_lines")); 3328 if (source.hasKey("ansi_console_mode")) 3329 ansiConsoleMode().setValue(layer, source.getString("ansi_console_mode")); 3330 if (source.hasKey("limit_visible_console")) 3331 limitVisibleConsole().setValue(layer, source.getBool("limit_visible_console")); 3332 if (source.hasKey("show_inline_toolbar_for_r_code_chunks")) 3333 showInlineToolbarForRCodeChunks().setValue(layer, source.getBool("show_inline_toolbar_for_r_code_chunks")); 3334 if (source.hasKey("highlight_code_chunks")) 3335 highlightCodeChunks().setValue(layer, source.getBool("highlight_code_chunks")); 3336 if (source.hasKey("save_files_before_build")) 3337 saveFilesBeforeBuild().setValue(layer, source.getBool("save_files_before_build")); 3338 if (source.hasKey("font_size_points")) 3339 fontSizePoints().setValue(layer, source.getDbl("font_size_points")); 3340 if (source.hasKey("help_font_size_points")) 3341 helpFontSizePoints().setValue(layer, source.getDbl("help_font_size_points")); 3342 if (source.hasKey("editor_theme")) 3343 editorTheme().setValue(layer, source.getString("editor_theme")); 3344 if (source.hasKey("server_editor_font_enabled")) 3345 serverEditorFontEnabled().setValue(layer, source.getBool("server_editor_font_enabled")); 3346 if (source.hasKey("server_editor_font")) 3347 serverEditorFont().setValue(layer, source.getString("server_editor_font")); 3348 if (source.hasKey("default_encoding")) 3349 defaultEncoding().setValue(layer, source.getString("default_encoding")); 3350 if (source.hasKey("toolbar_visible")) 3351 toolbarVisible().setValue(layer, source.getBool("toolbar_visible")); 3352 if (source.hasKey("default_project_location")) 3353 defaultProjectLocation().setValue(layer, source.getString("default_project_location")); 3354 if (source.hasKey("source_with_echo")) 3355 sourceWithEcho().setValue(layer, source.getBool("source_with_echo")); 3356 if (source.hasKey("default_sweave_engine")) 3357 defaultSweaveEngine().setValue(layer, source.getString("default_sweave_engine")); 3358 if (source.hasKey("default_latex_program")) 3359 defaultLatexProgram().setValue(layer, source.getString("default_latex_program")); 3360 if (source.hasKey("use_roxygen")) 3361 useRoxygen().setValue(layer, source.getBool("use_roxygen")); 3362 if (source.hasKey("use_dataimport")) 3363 useDataimport().setValue(layer, source.getBool("use_dataimport")); 3364 if (source.hasKey("pdf_previewer")) 3365 pdfPreviewer().setValue(layer, source.getString("pdf_previewer")); 3366 if (source.hasKey("always_enable_rnw_concordance")) 3367 alwaysEnableRnwConcordance().setValue(layer, source.getBool("always_enable_rnw_concordance")); 3368 if (source.hasKey("insert_numbered_latex_sections")) 3369 insertNumberedLatexSections().setValue(layer, source.getBool("insert_numbered_latex_sections")); 3370 if (source.hasKey("spelling_dictionary_language")) 3371 spellingDictionaryLanguage().setValue(layer, source.getString("spelling_dictionary_language")); 3372 if (source.hasKey("spelling_custom_dictionaries")) 3373 spellingCustomDictionaries().setValue(layer, source.getObject("spelling_custom_dictionaries")); 3374 if (source.hasKey("document_load_lint_delay")) 3375 documentLoadLintDelay().setValue(layer, source.getInteger("document_load_lint_delay")); 3376 if (source.hasKey("ignore_uppercase_words")) 3377 ignoreUppercaseWords().setValue(layer, source.getBool("ignore_uppercase_words")); 3378 if (source.hasKey("ignore_words_with_numbers")) 3379 ignoreWordsWithNumbers().setValue(layer, source.getBool("ignore_words_with_numbers")); 3380 if (source.hasKey("real_time_spellchecking")) 3381 realTimeSpellchecking().setValue(layer, source.getBool("real_time_spellchecking")); 3382 if (source.hasKey("navigate_to_build_error")) 3383 navigateToBuildError().setValue(layer, source.getBool("navigate_to_build_error")); 3384 if (source.hasKey("packages_pane_enabled")) 3385 packagesPaneEnabled().setValue(layer, source.getBool("packages_pane_enabled")); 3386 if (source.hasKey("use_rcpp_template")) 3387 useRcppTemplate().setValue(layer, source.getBool("use_rcpp_template")); 3388 if (source.hasKey("restore_source_documents")) 3389 restoreSourceDocuments().setValue(layer, source.getBool("restore_source_documents")); 3390 if (source.hasKey("handle_errors_in_user_code_only")) 3391 handleErrorsInUserCodeOnly().setValue(layer, source.getBool("handle_errors_in_user_code_only")); 3392 if (source.hasKey("auto_expand_error_tracebacks")) 3393 autoExpandErrorTracebacks().setValue(layer, source.getBool("auto_expand_error_tracebacks")); 3394 if (source.hasKey("check_for_updates")) 3395 checkForUpdates().setValue(layer, source.getBool("check_for_updates")); 3396 if (source.hasKey("show_internal_functions")) 3397 showInternalFunctions().setValue(layer, source.getBool("show_internal_functions")); 3398 if (source.hasKey("shiny_viewer_type")) 3399 shinyViewerType().setValue(layer, source.getString("shiny_viewer_type")); 3400 if (source.hasKey("shiny_background_jobs")) 3401 shinyBackgroundJobs().setValue(layer, source.getBool("shiny_background_jobs")); 3402 if (source.hasKey("plumber_viewer_type")) 3403 plumberViewerType().setValue(layer, source.getString("plumber_viewer_type")); 3404 if (source.hasKey("document_author")) 3405 documentAuthor().setValue(layer, source.getString("document_author")); 3406 if (source.hasKey("rmd_preferred_template_path")) 3407 rmdPreferredTemplatePath().setValue(layer, source.getString("rmd_preferred_template_path")); 3408 if (source.hasKey("rmd_viewer_type")) 3409 rmdViewerType().setValue(layer, source.getString("rmd_viewer_type")); 3410 if (source.hasKey("show_publish_diagnostics")) 3411 showPublishDiagnostics().setValue(layer, source.getBool("show_publish_diagnostics")); 3412 if (source.hasKey("publish_check_certificates")) 3413 publishCheckCertificates().setValue(layer, source.getBool("publish_check_certificates")); 3414 if (source.hasKey("use_publish_ca_bundle")) 3415 usePublishCaBundle().setValue(layer, source.getBool("use_publish_ca_bundle")); 3416 if (source.hasKey("publish_ca_bundle")) 3417 publishCaBundle().setValue(layer, source.getString("publish_ca_bundle")); 3418 if (source.hasKey("rmd_chunk_output_inline")) 3419 rmdChunkOutputInline().setValue(layer, source.getBool("rmd_chunk_output_inline")); 3420 if (source.hasKey("show_doc_outline_rmd")) 3421 showDocOutlineRmd().setValue(layer, source.getBool("show_doc_outline_rmd")); 3422 if (source.hasKey("auto_run_setup_chunk")) 3423 autoRunSetupChunk().setValue(layer, source.getBool("auto_run_setup_chunk")); 3424 if (source.hasKey("hide_console_on_chunk_execute")) 3425 hideConsoleOnChunkExecute().setValue(layer, source.getBool("hide_console_on_chunk_execute")); 3426 if (source.hasKey("execution_behavior")) 3427 executionBehavior().setValue(layer, source.getString("execution_behavior")); 3428 if (source.hasKey("show_terminal_tab")) 3429 showTerminalTab().setValue(layer, source.getBool("show_terminal_tab")); 3430 if (source.hasKey("terminal_local_echo")) 3431 terminalLocalEcho().setValue(layer, source.getBool("terminal_local_echo")); 3432 if (source.hasKey("terminal_websockets")) 3433 terminalWebsockets().setValue(layer, source.getBool("terminal_websockets")); 3434 if (source.hasKey("terminal_close_behavior")) 3435 terminalCloseBehavior().setValue(layer, source.getString("terminal_close_behavior")); 3436 if (source.hasKey("terminal_track_environment")) 3437 terminalTrackEnvironment().setValue(layer, source.getBool("terminal_track_environment")); 3438 if (source.hasKey("terminal_bell_style")) 3439 terminalBellStyle().setValue(layer, source.getString("terminal_bell_style")); 3440 if (source.hasKey("terminal_renderer")) 3441 terminalRenderer().setValue(layer, source.getString("terminal_renderer")); 3442 if (source.hasKey("terminal_weblinks")) 3443 terminalWeblinks().setValue(layer, source.getBool("terminal_weblinks")); 3444 if (source.hasKey("show_rmd_render_command")) 3445 showRmdRenderCommand().setValue(layer, source.getBool("show_rmd_render_command")); 3446 if (source.hasKey("enable_text_drag")) 3447 enableTextDrag().setValue(layer, source.getBool("enable_text_drag")); 3448 if (source.hasKey("show_hidden_files")) 3449 showHiddenFiles().setValue(layer, source.getBool("show_hidden_files")); 3450 if (source.hasKey("always_shown_files")) 3451 alwaysShownFiles().setValue(layer, source.getObject("always_shown_files")); 3452 if (source.hasKey("always_shown_extensions")) 3453 alwaysShownExtensions().setValue(layer, source.getObject("always_shown_extensions")); 3454 if (source.hasKey("sort_file_names_naturally")) 3455 sortFileNamesNaturally().setValue(layer, source.getBool("sort_file_names_naturally")); 3456 if (source.hasKey("sync_files_pane_working_dir")) 3457 syncFilesPaneWorkingDir().setValue(layer, source.getBool("sync_files_pane_working_dir")); 3458 if (source.hasKey("jobs_tab_visibility")) 3459 jobsTabVisibility().setValue(layer, source.getString("jobs_tab_visibility")); 3460 if (source.hasKey("show_launcher_jobs_tab")) 3461 showLauncherJobsTab().setValue(layer, source.getBool("show_launcher_jobs_tab")); 3462 if (source.hasKey("launcher_jobs_sort")) 3463 launcherJobsSort().setValue(layer, source.getString("launcher_jobs_sort")); 3464 if (source.hasKey("busy_detection")) 3465 busyDetection().setValue(layer, source.getString("busy_detection")); 3466 if (source.hasKey("busy_exclusion_list")) 3467 busyExclusionList().setValue(layer, source.getObject("busy_exclusion_list")); 3468 if (source.hasKey("knit_working_dir")) 3469 knitWorkingDir().setValue(layer, source.getString("knit_working_dir")); 3470 if (source.hasKey("doc_outline_show")) 3471 docOutlineShow().setValue(layer, source.getString("doc_outline_show")); 3472 if (source.hasKey("latex_preview_on_cursor_idle")) 3473 latexPreviewOnCursorIdle().setValue(layer, source.getString("latex_preview_on_cursor_idle")); 3474 if (source.hasKey("wrap_tab_navigation")) 3475 wrapTabNavigation().setValue(layer, source.getBool("wrap_tab_navigation")); 3476 if (source.hasKey("global_theme")) 3477 globalTheme().setValue(layer, source.getString("global_theme")); 3478 if (source.hasKey("git_diff_ignore_whitespace")) 3479 gitDiffIgnoreWhitespace().setValue(layer, source.getBool("git_diff_ignore_whitespace")); 3480 if (source.hasKey("console_double_click_select")) 3481 consoleDoubleClickSelect().setValue(layer, source.getBool("console_double_click_select")); 3482 if (source.hasKey("new_proj_git_init")) 3483 newProjGitInit().setValue(layer, source.getBool("new_proj_git_init")); 3484 if (source.hasKey("new_proj_use_renv")) 3485 newProjUseRenv().setValue(layer, source.getBool("new_proj_use_renv")); 3486 if (source.hasKey("root_document")) 3487 rootDocument().setValue(layer, source.getString("root_document")); 3488 if (source.hasKey("show_user_home_page")) 3489 showUserHomePage().setValue(layer, source.getString("show_user_home_page")); 3490 if (source.hasKey("reuse_sessions_for_project_links")) 3491 reuseSessionsForProjectLinks().setValue(layer, source.getBool("reuse_sessions_for_project_links")); 3492 if (source.hasKey("vcs_enabled")) 3493 vcsEnabled().setValue(layer, source.getBool("vcs_enabled")); 3494 if (source.hasKey("vcs_autorefresh")) 3495 vcsAutorefresh().setValue(layer, source.getBool("vcs_autorefresh")); 3496 if (source.hasKey("git_exe_path")) 3497 gitExePath().setValue(layer, source.getString("git_exe_path")); 3498 if (source.hasKey("svn_exe_path")) 3499 svnExePath().setValue(layer, source.getString("svn_exe_path")); 3500 if (source.hasKey("terminal_path")) 3501 terminalPath().setValue(layer, source.getString("terminal_path")); 3502 if (source.hasKey("rsa_key_path")) 3503 rsaKeyPath().setValue(layer, source.getString("rsa_key_path")); 3504 if (source.hasKey("use_devtools")) 3505 useDevtools().setValue(layer, source.getBool("use_devtools")); 3506 if (source.hasKey("use_internet2")) 3507 useInternet2().setValue(layer, source.getBool("use_internet2")); 3508 if (source.hasKey("use_secure_download")) 3509 useSecureDownload().setValue(layer, source.getBool("use_secure_download")); 3510 if (source.hasKey("cleanup_after_r_cmd_check")) 3511 cleanupAfterRCmdCheck().setValue(layer, source.getBool("cleanup_after_r_cmd_check")); 3512 if (source.hasKey("view_dir_after_r_cmd_check")) 3513 viewDirAfterRCmdCheck().setValue(layer, source.getBool("view_dir_after_r_cmd_check")); 3514 if (source.hasKey("hide_object_files")) 3515 hideObjectFiles().setValue(layer, source.getBool("hide_object_files")); 3516 if (source.hasKey("restore_last_project")) 3517 restoreLastProject().setValue(layer, source.getBool("restore_last_project")); 3518 if (source.hasKey("project_safe_startup_seconds")) 3519 projectSafeStartupSeconds().setValue(layer, source.getInteger("project_safe_startup_seconds")); 3520 if (source.hasKey("use_tinytex")) 3521 useTinytex().setValue(layer, source.getBool("use_tinytex")); 3522 if (source.hasKey("clean_texi2dvi_output")) 3523 cleanTexi2dviOutput().setValue(layer, source.getBool("clean_texi2dvi_output")); 3524 if (source.hasKey("latex_shell_escape")) 3525 latexShellEscape().setValue(layer, source.getBool("latex_shell_escape")); 3526 if (source.hasKey("restore_project_r_version")) 3527 restoreProjectRVersion().setValue(layer, source.getBool("restore_project_r_version")); 3528 if (source.hasKey("clang_verbose")) 3529 clangVerbose().setValue(layer, source.getInteger("clang_verbose")); 3530 if (source.hasKey("submit_crash_reports")) 3531 submitCrashReports().setValue(layer, source.getBool("submit_crash_reports")); 3532 if (source.hasKey("default_r_version")) 3533 defaultRVersion().setValue(layer, source.getObject("default_r_version")); 3534 if (source.hasKey("data_viewer_max_columns")) 3535 dataViewerMaxColumns().setValue(layer, source.getInteger("data_viewer_max_columns")); 3536 if (source.hasKey("enable_screen_reader")) 3537 enableScreenReader().setValue(layer, source.getBool("enable_screen_reader")); 3538 if (source.hasKey("typing_status_delay_ms")) 3539 typingStatusDelayMs().setValue(layer, source.getInteger("typing_status_delay_ms")); 3540 if (source.hasKey("reduced_motion")) 3541 reducedMotion().setValue(layer, source.getBool("reduced_motion")); 3542 if (source.hasKey("tab_key_move_focus")) 3543 tabKeyMoveFocus().setValue(layer, source.getBool("tab_key_move_focus")); 3544 if (source.hasKey("find_panel_legacy_tab_sequence")) 3545 findPanelLegacyTabSequence().setValue(layer, source.getBool("find_panel_legacy_tab_sequence")); 3546 if (source.hasKey("show_focus_rectangles")) 3547 showFocusRectangles().setValue(layer, source.getBool("show_focus_rectangles")); 3548 if (source.hasKey("show_panel_focus_rectangle")) 3549 showPanelFocusRectangle().setValue(layer, source.getBool("show_panel_focus_rectangle")); 3550 if (source.hasKey("auto_save_on_idle")) 3551 autoSaveOnIdle().setValue(layer, source.getString("auto_save_on_idle")); 3552 if (source.hasKey("auto_save_idle_ms")) 3553 autoSaveIdleMs().setValue(layer, source.getInteger("auto_save_idle_ms")); 3554 if (source.hasKey("auto_save_on_blur")) 3555 autoSaveOnBlur().setValue(layer, source.getBool("auto_save_on_blur")); 3556 if (source.hasKey("terminal_initial_directory")) 3557 terminalInitialDirectory().setValue(layer, source.getString("terminal_initial_directory")); 3558 if (source.hasKey("full_project_path_in_window_title")) 3559 fullProjectPathInWindowTitle().setValue(layer, source.getBool("full_project_path_in_window_title")); 3560 if (source.hasKey("visual_markdown_editing_is_default")) 3561 visualMarkdownEditingIsDefault().setValue(layer, source.getBool("visual_markdown_editing_is_default")); 3562 if (source.hasKey("visual_markdown_editing_list_spacing")) 3563 visualMarkdownEditingListSpacing().setValue(layer, source.getString("visual_markdown_editing_list_spacing")); 3564 if (source.hasKey("visual_markdown_editing_wrap")) 3565 visualMarkdownEditingWrap().setValue(layer, source.getString("visual_markdown_editing_wrap")); 3566 if (source.hasKey("visual_markdown_editing_wrap_at_column")) 3567 visualMarkdownEditingWrapAtColumn().setValue(layer, source.getInteger("visual_markdown_editing_wrap_at_column")); 3568 if (source.hasKey("visual_markdown_editing_references_location")) 3569 visualMarkdownEditingReferencesLocation().setValue(layer, source.getString("visual_markdown_editing_references_location")); 3570 if (source.hasKey("visual_markdown_editing_canonical")) 3571 visualMarkdownEditingCanonical().setValue(layer, source.getBool("visual_markdown_editing_canonical")); 3572 if (source.hasKey("visual_markdown_editing_max_content_width")) 3573 visualMarkdownEditingMaxContentWidth().setValue(layer, source.getInteger("visual_markdown_editing_max_content_width")); 3574 if (source.hasKey("visual_markdown_editing_show_doc_outline")) 3575 visualMarkdownEditingShowDocOutline().setValue(layer, source.getBool("visual_markdown_editing_show_doc_outline")); 3576 if (source.hasKey("visual_markdown_editing_show_margin")) 3577 visualMarkdownEditingShowMargin().setValue(layer, source.getBool("visual_markdown_editing_show_margin")); 3578 if (source.hasKey("visual_markdown_editing_font_size_points")) 3579 visualMarkdownEditingFontSizePoints().setValue(layer, source.getInteger("visual_markdown_editing_font_size_points")); 3580 if (source.hasKey("visual_markdown_code_editor")) 3581 visualMarkdownCodeEditor().setValue(layer, source.getString("visual_markdown_code_editor")); 3582 if (source.hasKey("zotero_libraries")) 3583 zoteroLibraries().setValue(layer, source.getObject("zotero_libraries")); 3584 if (source.hasKey("emoji_skintone")) 3585 emojiSkintone().setValue(layer, source.getString("emoji_skintone")); 3586 if (source.hasKey("disabled_aria_live_announcements")) 3587 disabledAriaLiveAnnouncements().setValue(layer, source.getObject("disabled_aria_live_announcements")); 3588 if (source.hasKey("screenreader_console_announce_limit")) 3589 screenreaderConsoleAnnounceLimit().setValue(layer, source.getInteger("screenreader_console_announce_limit")); 3590 if (source.hasKey("file_monitor_ignored_components")) 3591 fileMonitorIgnoredComponents().setValue(layer, source.getObject("file_monitor_ignored_components")); 3592 if (source.hasKey("install_pkg_deps_individually")) 3593 installPkgDepsIndividually().setValue(layer, source.getBool("install_pkg_deps_individually")); 3594 if (source.hasKey("graphics_backend")) 3595 graphicsBackend().setValue(layer, source.getString("graphics_backend")); 3596 if (source.hasKey("graphics_antialiasing")) 3597 graphicsAntialiasing().setValue(layer, source.getString("graphics_antialiasing")); 3598 if (source.hasKey("browser_fixed_width_fonts")) 3599 browserFixedWidthFonts().setValue(layer, source.getObject("browser_fixed_width_fonts")); 3600 if (source.hasKey("python_type")) 3601 pythonType().setValue(layer, source.getString("python_type")); 3602 if (source.hasKey("python_version")) 3603 pythonVersion().setValue(layer, source.getString("python_version")); 3604 if (source.hasKey("python_path")) 3605 pythonPath().setValue(layer, source.getString("python_path")); 3606 if (source.hasKey("save_retry_timeout")) 3607 saveRetryTimeout().setValue(layer, source.getInteger("save_retry_timeout")); 3608 if (source.hasKey("insert_native_pipe_operator")) 3609 insertNativePipeOperator().setValue(layer, source.getBool("insert_native_pipe_operator")); 3610 if (source.hasKey("command_palette_mru")) 3611 commandPaletteMru().setValue(layer, source.getBool("command_palette_mru")); 3612 if (source.hasKey("show_memory_usage")) 3613 showMemoryUsage().setValue(layer, source.getBool("show_memory_usage")); 3614 if (source.hasKey("memory_query_interval_seconds")) 3615 memoryQueryIntervalSeconds().setValue(layer, source.getInteger("memory_query_interval_seconds")); 3616 if (source.hasKey("terminal_python_integration")) 3617 terminalPythonIntegration().setValue(layer, source.getBool("terminal_python_integration")); 3618 if (source.hasKey("session_protocol_debug")) 3619 sessionProtocolDebug().setValue(layer, source.getBool("session_protocol_debug")); 3620 if (source.hasKey("python_project_environment_automatic_activate")) 3621 pythonProjectEnvironmentAutomaticActivate().setValue(layer, source.getBool("python_project_environment_automatic_activate")); 3622 if (source.hasKey("check_null_external_pointers")) 3623 checkNullExternalPointers().setValue(layer, source.getBool("check_null_external_pointers")); 3624 } allPrefs()3625 public List<PrefValue<?>> allPrefs() 3626 { 3627 ArrayList<PrefValue<?>> prefs = new ArrayList<PrefValue<?>>(); 3628 prefs.add(runRprofileOnResume()); 3629 prefs.add(saveWorkspace()); 3630 prefs.add(loadWorkspace()); 3631 prefs.add(initialWorkingDirectory()); 3632 prefs.add(cranMirror()); 3633 prefs.add(bioconductorMirrorName()); 3634 prefs.add(bioconductorMirrorUrl()); 3635 prefs.add(alwaysSaveHistory()); 3636 prefs.add(removeHistoryDuplicates()); 3637 prefs.add(showLastDotValue()); 3638 prefs.add(lineEndingConversion()); 3639 prefs.add(useNewlinesInMakefiles()); 3640 prefs.add(windowsTerminalShell()); 3641 prefs.add(posixTerminalShell()); 3642 prefs.add(customShellCommand()); 3643 prefs.add(customShellOptions()); 3644 prefs.add(showLineNumbers()); 3645 prefs.add(highlightSelectedWord()); 3646 prefs.add(highlightSelectedLine()); 3647 prefs.add(panes()); 3648 prefs.add(allowSourceColumns()); 3649 prefs.add(useSpacesForTab()); 3650 prefs.add(numSpacesForTab()); 3651 prefs.add(autoDetectIndentation()); 3652 prefs.add(showMargin()); 3653 prefs.add(blinkingCursor()); 3654 prefs.add(marginColumn()); 3655 prefs.add(showInvisibles()); 3656 prefs.add(showIndentGuides()); 3657 prefs.add(continueCommentsOnNewline()); 3658 prefs.add(highlightWebLink()); 3659 prefs.add(editorKeybindings()); 3660 prefs.add(insertMatching()); 3661 prefs.add(insertSpacesAroundEquals()); 3662 prefs.add(insertParensAfterFunctionCompletion()); 3663 prefs.add(tabMultilineCompletion()); 3664 prefs.add(tabCompletion()); 3665 prefs.add(showHelpTooltipOnIdle()); 3666 prefs.add(surroundSelection()); 3667 prefs.add(enableSnippets()); 3668 prefs.add(codeCompletion()); 3669 prefs.add(codeCompletionOther()); 3670 prefs.add(consoleCodeCompletion()); 3671 prefs.add(codeCompletionDelay()); 3672 prefs.add(codeCompletionCharacters()); 3673 prefs.add(showFunctionSignatureTooltips()); 3674 prefs.add(showDiagnosticsR()); 3675 prefs.add(showDiagnosticsCpp()); 3676 prefs.add(showDiagnosticsOther()); 3677 prefs.add(styleDiagnostics()); 3678 prefs.add(diagnosticsOnSave()); 3679 prefs.add(backgroundDiagnostics()); 3680 prefs.add(backgroundDiagnosticsDelayMs()); 3681 prefs.add(diagnosticsInRFunctionCalls()); 3682 prefs.add(checkArgumentsToRFunctionCalls()); 3683 prefs.add(checkUnexpectedAssignmentInFunctionCall()); 3684 prefs.add(warnIfNoSuchVariableInScope()); 3685 prefs.add(warnVariableDefinedButNotUsed()); 3686 prefs.add(autoDiscoverPackageDependencies()); 3687 prefs.add(autoAppendNewline()); 3688 prefs.add(stripTrailingWhitespace()); 3689 prefs.add(restoreSourceDocumentCursorPosition()); 3690 prefs.add(reindentOnPaste()); 3691 prefs.add(verticallyAlignArgumentsIndent()); 3692 prefs.add(softWrapRFiles()); 3693 prefs.add(softWrapRmdFiles()); 3694 prefs.add(focusConsoleAfterExec()); 3695 prefs.add(foldStyle()); 3696 prefs.add(saveBeforeSourcing()); 3697 prefs.add(syntaxColorConsole()); 3698 prefs.add(highlightConsoleErrors()); 3699 prefs.add(scrollPastEndOfDocument()); 3700 prefs.add(highlightRFunctionCalls()); 3701 prefs.add(rainbowParentheses()); 3702 prefs.add(consoleLineLengthLimit()); 3703 prefs.add(consoleMaxLines()); 3704 prefs.add(ansiConsoleMode()); 3705 prefs.add(limitVisibleConsole()); 3706 prefs.add(showInlineToolbarForRCodeChunks()); 3707 prefs.add(highlightCodeChunks()); 3708 prefs.add(saveFilesBeforeBuild()); 3709 prefs.add(fontSizePoints()); 3710 prefs.add(helpFontSizePoints()); 3711 prefs.add(editorTheme()); 3712 prefs.add(serverEditorFontEnabled()); 3713 prefs.add(serverEditorFont()); 3714 prefs.add(defaultEncoding()); 3715 prefs.add(toolbarVisible()); 3716 prefs.add(defaultProjectLocation()); 3717 prefs.add(sourceWithEcho()); 3718 prefs.add(defaultSweaveEngine()); 3719 prefs.add(defaultLatexProgram()); 3720 prefs.add(useRoxygen()); 3721 prefs.add(useDataimport()); 3722 prefs.add(pdfPreviewer()); 3723 prefs.add(alwaysEnableRnwConcordance()); 3724 prefs.add(insertNumberedLatexSections()); 3725 prefs.add(spellingDictionaryLanguage()); 3726 prefs.add(spellingCustomDictionaries()); 3727 prefs.add(documentLoadLintDelay()); 3728 prefs.add(ignoreUppercaseWords()); 3729 prefs.add(ignoreWordsWithNumbers()); 3730 prefs.add(realTimeSpellchecking()); 3731 prefs.add(navigateToBuildError()); 3732 prefs.add(packagesPaneEnabled()); 3733 prefs.add(useRcppTemplate()); 3734 prefs.add(restoreSourceDocuments()); 3735 prefs.add(handleErrorsInUserCodeOnly()); 3736 prefs.add(autoExpandErrorTracebacks()); 3737 prefs.add(checkForUpdates()); 3738 prefs.add(showInternalFunctions()); 3739 prefs.add(shinyViewerType()); 3740 prefs.add(shinyBackgroundJobs()); 3741 prefs.add(plumberViewerType()); 3742 prefs.add(documentAuthor()); 3743 prefs.add(rmdPreferredTemplatePath()); 3744 prefs.add(rmdViewerType()); 3745 prefs.add(showPublishDiagnostics()); 3746 prefs.add(publishCheckCertificates()); 3747 prefs.add(usePublishCaBundle()); 3748 prefs.add(publishCaBundle()); 3749 prefs.add(rmdChunkOutputInline()); 3750 prefs.add(showDocOutlineRmd()); 3751 prefs.add(autoRunSetupChunk()); 3752 prefs.add(hideConsoleOnChunkExecute()); 3753 prefs.add(executionBehavior()); 3754 prefs.add(showTerminalTab()); 3755 prefs.add(terminalLocalEcho()); 3756 prefs.add(terminalWebsockets()); 3757 prefs.add(terminalCloseBehavior()); 3758 prefs.add(terminalTrackEnvironment()); 3759 prefs.add(terminalBellStyle()); 3760 prefs.add(terminalRenderer()); 3761 prefs.add(terminalWeblinks()); 3762 prefs.add(showRmdRenderCommand()); 3763 prefs.add(enableTextDrag()); 3764 prefs.add(showHiddenFiles()); 3765 prefs.add(alwaysShownFiles()); 3766 prefs.add(alwaysShownExtensions()); 3767 prefs.add(sortFileNamesNaturally()); 3768 prefs.add(syncFilesPaneWorkingDir()); 3769 prefs.add(jobsTabVisibility()); 3770 prefs.add(showLauncherJobsTab()); 3771 prefs.add(launcherJobsSort()); 3772 prefs.add(busyDetection()); 3773 prefs.add(busyExclusionList()); 3774 prefs.add(knitWorkingDir()); 3775 prefs.add(docOutlineShow()); 3776 prefs.add(latexPreviewOnCursorIdle()); 3777 prefs.add(wrapTabNavigation()); 3778 prefs.add(globalTheme()); 3779 prefs.add(gitDiffIgnoreWhitespace()); 3780 prefs.add(consoleDoubleClickSelect()); 3781 prefs.add(newProjGitInit()); 3782 prefs.add(newProjUseRenv()); 3783 prefs.add(rootDocument()); 3784 prefs.add(showUserHomePage()); 3785 prefs.add(reuseSessionsForProjectLinks()); 3786 prefs.add(vcsEnabled()); 3787 prefs.add(vcsAutorefresh()); 3788 prefs.add(gitExePath()); 3789 prefs.add(svnExePath()); 3790 prefs.add(terminalPath()); 3791 prefs.add(rsaKeyPath()); 3792 prefs.add(useDevtools()); 3793 prefs.add(useInternet2()); 3794 prefs.add(useSecureDownload()); 3795 prefs.add(cleanupAfterRCmdCheck()); 3796 prefs.add(viewDirAfterRCmdCheck()); 3797 prefs.add(hideObjectFiles()); 3798 prefs.add(restoreLastProject()); 3799 prefs.add(projectSafeStartupSeconds()); 3800 prefs.add(useTinytex()); 3801 prefs.add(cleanTexi2dviOutput()); 3802 prefs.add(latexShellEscape()); 3803 prefs.add(restoreProjectRVersion()); 3804 prefs.add(clangVerbose()); 3805 prefs.add(submitCrashReports()); 3806 prefs.add(defaultRVersion()); 3807 prefs.add(dataViewerMaxColumns()); 3808 prefs.add(enableScreenReader()); 3809 prefs.add(typingStatusDelayMs()); 3810 prefs.add(reducedMotion()); 3811 prefs.add(tabKeyMoveFocus()); 3812 prefs.add(findPanelLegacyTabSequence()); 3813 prefs.add(showFocusRectangles()); 3814 prefs.add(showPanelFocusRectangle()); 3815 prefs.add(autoSaveOnIdle()); 3816 prefs.add(autoSaveIdleMs()); 3817 prefs.add(autoSaveOnBlur()); 3818 prefs.add(terminalInitialDirectory()); 3819 prefs.add(fullProjectPathInWindowTitle()); 3820 prefs.add(visualMarkdownEditingIsDefault()); 3821 prefs.add(visualMarkdownEditingListSpacing()); 3822 prefs.add(visualMarkdownEditingWrap()); 3823 prefs.add(visualMarkdownEditingWrapAtColumn()); 3824 prefs.add(visualMarkdownEditingReferencesLocation()); 3825 prefs.add(visualMarkdownEditingCanonical()); 3826 prefs.add(visualMarkdownEditingMaxContentWidth()); 3827 prefs.add(visualMarkdownEditingShowDocOutline()); 3828 prefs.add(visualMarkdownEditingShowMargin()); 3829 prefs.add(visualMarkdownEditingFontSizePoints()); 3830 prefs.add(visualMarkdownCodeEditor()); 3831 prefs.add(zoteroLibraries()); 3832 prefs.add(emojiSkintone()); 3833 prefs.add(disabledAriaLiveAnnouncements()); 3834 prefs.add(screenreaderConsoleAnnounceLimit()); 3835 prefs.add(fileMonitorIgnoredComponents()); 3836 prefs.add(installPkgDepsIndividually()); 3837 prefs.add(graphicsBackend()); 3838 prefs.add(graphicsAntialiasing()); 3839 prefs.add(browserFixedWidthFonts()); 3840 prefs.add(pythonType()); 3841 prefs.add(pythonVersion()); 3842 prefs.add(pythonPath()); 3843 prefs.add(saveRetryTimeout()); 3844 prefs.add(insertNativePipeOperator()); 3845 prefs.add(commandPaletteMru()); 3846 prefs.add(showMemoryUsage()); 3847 prefs.add(memoryQueryIntervalSeconds()); 3848 prefs.add(terminalPythonIntegration()); 3849 prefs.add(sessionProtocolDebug()); 3850 prefs.add(pythonProjectEnvironmentAutomaticActivate()); 3851 prefs.add(checkNullExternalPointers()); 3852 return prefs; 3853 } 3854 3855 userLayer()3856 public int userLayer() 3857 { 3858 return LAYER_USER; 3859 } 3860 projectLayer()3861 public int projectLayer() 3862 { 3863 return LAYER_PROJECT; 3864 } 3865 3866 public static final int LAYER_DEFAULT = 0; 3867 public static final int LAYER_COMPUTED = 1; 3868 public static final int LAYER_SYSTEM = 2; 3869 public static final int LAYER_USER = 3; 3870 public static final int LAYER_PROJECT = 4; 3871 } 3872