;ELC ;;; Compiled ;;; in Emacs version 28.0.50 ;;; with all optimizations. (byte-code "\300\301!\210\300\302!\210\300\301!\210\300\303!\210\300\304!\210\300\305\306\"\207" [require ess-utils ess-custom hideshow outline essddr "ess-rd.el"] 3) (defvar ess-roxy-mode-map (byte-code "\302  \203 \303\304\305#\210\303\306\307#\210\303\310\311#\210\303\312\313#\210\303\314\315#\210\303\316\317#\210\303\320\321#\210\303\322\323#\210)\207" [map ess-roxy-hide-show-p make-sparse-keymap define-key "h" ess-roxy-hide-all "n" ess-roxy-next-entry "p" ess-roxy-previous-entry "" ess-roxy-update-entry "" ess-roxy-preview-Rd "" ess-roxy-preview-HTML "" ess-roxy-preview-text "" ess-roxy-toggle-roxy-region] 4)) (defvar ess-roxy-font-lock-keywords (byte-code "\303\304 \305\"\306R\307B\310P\311B\312\304\n\305\"\313Q\314B\260\315BF\207" [ess-roxy-re ess-roxy-tags-param ess-roxy-tags-noparam " *\\([@\\]" regexp-opt t "\\)\\>" ((1 'font-lock-keyword-face prepend)) " *\\(@\\<\\(\\(?:import\\(?:\\(?:\\(?:Classe\\|Method\\)s\\)?Fro\\)\\|para\\)m\\)\\>\\)\\(?:[ ]+\\(\\(?:\\sw+,?\\)+\\)\\)" ((1 'font-lock-keyword-face prepend) (3 'font-lock-variable-name-face prepend)) "[@\\]" "\\>" ((0 'font-lock-variable-name-face prepend)) ((0 'bold prepend))] 6)) #@111 Whether to fold `@examples' when opening a buffer. Use you regular key for `outline-show-entry' to reveal it. (defvar ess-roxy-fold-examples nil (#$ . 1288)) #@95 Non-nil if Ess-Roxy mode is enabled. Use the command `ess-roxy-mode' to change this variable. (defvar ess-roxy-mode nil (#$ . 1452)) (make-variable-buffer-local 'ess-roxy-mode) #@577 Minor mode for editing ROxygen documentation. This is a minor mode. If called interactively, toggle the `Ess-Roxy mode' mode. If the prefix argument is positive, enable the mode, and if it is zero or negative, disable the mode. If called from Lisp, toggle the mode if ARG is `toggle'. Enable the mode if ARG is nil, omitted, or is a positive number. Disable the mode if ARG is a negative number. To check whether the minor mode is enabled in the current buffer, evaluate `ess-roxy-mode'. The mode's hook is called both when the mode is enabled and when it is disabled. (defalias 'ess-roxy-mode #[(&optional arg) "\306  \307=\203\n?\202 \247\203 \310W\203\311\202\312\313\303!\2032\314\302 \"\n\2032\302 B\n\203b\315\311\f\"\210\316\317\320\321#\210 \203W\322\323!\203W\324\310!\2102\203W\325 \2103\203\221\326 \210\202\221 \203w\313\324!\203w\203w\327 \210\324 \210\330\311\f\"\210\331\332!\210\311\331\333!\210\311\331\334!\210\3114\203\245\335\336!\203\242\336 \210\202\245\337 \210\331\340!\210\3415\342 R \331\343!\210\3415\342#R#\331\344!\210\345$\346\347\n\203\320\350\202\321\351\"\210\352\353!\203\370\306 \203\345\306 \232\203\370\354\355\356\n\203\362\357\202\363\360#\210))\361 \210\n\207" [#1=#:last-message arg ess-roxy-mode local-minor-modes ess-roxy-font-lock-keywords ess-roxy-hide-show-p current-message toggle 1 nil t boundp delq font-lock-add-keywords add-hook completion-at-point-functions ess-roxy-complete-tag local featurep hideshow hs-minor-mode ess-roxy-hide-all ess-roxy-hide-all-examples hs-show-all font-lock-remove-keywords make-local-variable syntax-propertize-function font-lock-fontify-region-function font-lock-unfontify-region-function fboundp font-lock-flush font-lock-fontify-buffer paragraph-start "\\(" "\\)*" paragraph-separate adaptive-fill-function ess-roxy-adaptive-fill-function run-hooks ess-roxy-mode-hook ess-roxy-mode-on-hook ess-roxy-mode-off-hook called-interactively-p any " in current buffer" message "Ess-Roxy mode %sabled%s" "en" "dis" force-mode-line-update ess-roxy-start-hidden-p ess-roxy-fold-examples font-lock-mode ess-roxy-re] 4 (#$ . 1636) (list (if current-prefix-arg (prefix-numeric-value current-prefix-arg) 'toggle))]) (defvar ess-roxy-mode-hook nil) (byte-code "\301\302N\204\f\303\301\302\304#\210\303\301\305\306#\210\303\301\307\310C#\210\311\312\310\310\211%\207" [ess-roxy-mode-map ess-roxy-mode-hook variable-documentation put "Hook run after entering or leaving `ess-roxy-mode'.\nNo problems result if this variable is not bound.\n`add-hook' automatically binds it. (This is true for all hook variables.)" custom-type hook standard-value nil add-minor-mode ess-roxy-mode] 6) (defvar ess-roxy-outline-regexp "^#+' +@examples\\|^[^#]") (defalias 'ess-roxy-substitute-outline-regexp #[(command) "\303\304!\203\n\202 \n )\207" [ess-roxy-outline-regexp outline-regexp command ess-roxy-entry-p "examples"] 2]) (defalias 'ess-roxy-cycle-example #[nil "\301\302!\204\n\303\304!\210\305\306\307!)\207" [this-command featurep outline-magic error "Please install and load outline-magic" outline-cycle-overwiew ess-roxy-substitute-outline-regexp outline-cycle] 2 nil nil]) (defalias 'ess-roxy-show-example #[nil "\300\301!\207" [ess-roxy-substitute-outline-regexp outline-show-entry] 2 nil nil]) (defalias 'ess-roxy-hide-example #[nil "\300\301!\207" [ess-roxy-substitute-outline-regexp outline-hide-entry] 2 nil nil]) (defalias 'ess-roxy-hide-all-examples #[nil "\212eb\210\300\301\302\303#\205\304\305!\203\306 \210\202)\207" [re-search-forward "^#+' +@examples\\b" nil t ess-roxy-entry-p "examples" ess-roxy-hide-example] 4 nil nil]) (byte-code "\303\304!\203 \305\306\307 $\210\305\310\311\n$\210\305\312\313\n$\207" [ess-roxy-mode-map outline-mode-menu-bar-map outline-minor-mode-map featurep outline-magic substitute-key-definition outline-cyle ess-roxy-cyle-example outline-hide-entry ess-roxy-hide-example outline-show-entry ess-roxy-show-example] 5) #@20 Go to roxy prefix. (defalias 'ess-back-to-roxy #[nil "\301\210\302\303P\304 \"\210\305\225b\207" [ess-roxy-re nil re-search-backward " ?" point-at-bol 0] 3 (#$ . 5647)]) #@64 Get point number at start of current entry, 0 if not in entry. (defalias 'ess-roxy-beg-of-entry #[nil "\212\301\302 \210\303\304 \204\305\202`\303y\305U\203%\304 \203%`\202*\207" [beg nil beginning-of-line -1 ess-roxy-entry-p 0] 2 (#$ . 5825)]) #@51 True if point is the description / details field. (defalias 'ess-roxy-in-header-p #[nil "\212\303\304 \305 \210\203'\306\n\307P!\203\310\211\311y\312U\205\"\304 \211\204 +\207" [cont res ess-roxy-re t ess-roxy-entry-p beginning-of-line looking-at " *[@].+" nil -1 0] 4 (#$ . 6090)]) #@68 Get point number at beginning of current field, 0 if not in entry. (defalias 'ess-roxy-beg-of-field #[nil "\212\303\211\304 \210\305\306\307 \203A \203A`\310\n\311P!\203!\303\312 \2035\310\n\313P!\2035\314y\210`\303 \203\f\315y\305U\202\f+\207" [beg cont ess-roxy-re nil beginning-of-line 0 t ess-roxy-entry-p looking-at " *[@].+" ess-roxy-in-header-p " *$" 1 -1] 3 (#$ . 6391)]) #@62 Get point number at end of current entry, 0 if not in entry. (defalias 'ess-roxy-end-of-entry #[nil "\212\301\211\210\302\303 \204\304\202`\305y\304U\203(\303 \203(\301\210`\202*\207" [end nil -1 ess-roxy-entry-p 0 1] 3 (#$ . 6794)]) #@62 Get point number at end of current field, 0 if not in entry. (defalias 'ess-roxy-end-of-field #[nil "\212\303\211\304\305 \203\303\210`\306 \210\307y\210\310\305 \203T\203T\212\303\210`)\311 \2036\312\n\313P!\204>\312\n\314P!\203H\315y\210\303\210`\303\203\307y\304U\202 +\207" [cont end ess-roxy-re nil 0 ess-roxy-entry-p beginning-of-line 1 t ess-roxy-in-header-p looking-at " *$" " *[@].+" -1] 3 (#$ . 7050)]) #@35 True if point is in a roxy entry. (defalias 'ess-roxy-entry-p #[(&optional field) "\212\302 \210\303!)\205 ?\206\304 \230\207" [ess-roxy-re field beginning-of-line looking-at ess-roxy-current-field] 2 (#$ . 7494)]) #@38 Go to to the start of current field. (defalias 'ess-roxy-narrow-to-field #[nil "\302 \303 \211}*\207" [end beg ess-roxy-beg-of-field ess-roxy-end-of-field] 3 (#$ . 7721) nil]) (defalias 'ess-roxy-extract-field #[nil "\303 \304 {\305 \306\307\310\"r\nq\210\311\216 c\210eb\210\312d\313#\203)\314\315!\210\202ed{-\207" [prefix-re field #1=#:temp-buffer ess-roxy-beg-of-entry ess-roxy-end-of-entry ess-roxy-guess-str generate-new-buffer " *temp*" t #[nil "\301!\205 \302!\207" [#1# buffer-name kill-buffer] 2] re-search-forward noerror replace-match ""] 4]) #@63 Return prefix for filling paragraph or nil if not determined. (defalias 'ess-roxy-adaptive-fill-function #[nil "\302 \205.\303\304 \305\"@\306 \203&\212\307 \210\310\311\312 \313#\210\314\315\316!Q)\202-\314\317 \320\"Q)\207" [roxy-str ess-indent-offset ess-roxy-entry-p split-string ess-roxy-guess-str "'" ess-roxy-in-header-p ess-back-to-roxy re-search-forward "\\([ ]*\\)" line-end-position t "' " match-string 1 make-string 32] 5 (#$ . 8295)]) #@40 Return the name of the field at point. (defalias 'ess-roxy-current-field #[nil "\301 ?\205\212\302 b\210\303\304P\305 \306#\205\307\310!)\207" [ess-roxy-re ess-roxy-in-header-p ess-roxy-beg-of-field re-search-forward "[ ]+@\\([[:alpha:]]+\\)" line-end-position t match-string-no-properties 1] 4 (#$ . 8756)]) #@66 Indent line when point is in a field, but not in its first line. (defalias 'ess-roxy-maybe-indent-line #[nil "\302 ?\2056\303 \304\232?\2056\212\305 \210\306\307`\"\310 b\210\306\307`\"\232*?\2056\311 \210`\312\313w\210`|\210\314 \315\"c\207" [line-n ess-indent-offset ess-roxy-in-header-p ess-roxy-current-field "examples" beginning-of-line count-lines 1 ess-roxy-beg-of-field ess-back-to-roxy " " nil make-string 32] 4 (#$ . 9077)]) #@124 Put point at start of function. Go to the beginning of the current one or below the current roxygen entry, error otherwise (defalias 'ess-roxy-goto-func-def #[nil "\300 \203\301 \210\302y\210\303 \207\304 @b\207" [ess-roxy-entry-p ess-roxy-goto-end-of-entry 1 beginning-of-line ess-end-of-function] 1 (#$ . 9525)]) #@37 Get args list for current function. (defalias 'ess-roxy-get-args-list-from-def #[nil "\212\301 \210\302 \303\304\"*\207" [args ess-roxy-goto-func-def ess-roxy-get-function-args mapcar #[(x) "\301B\207" [x ("")] 2]] 3 (#$ . 9848)]) #@129 Insert an ARGS list to the end of the current roxygen entry. If HERE is supplied start inputting `here'. Finish at end of line. (defalias 'ess-roxy-insert-args #[(args &optional here) "\305\306 \n\203\n\307W\203!\310 \210\311 \210\312\313!\204$\305\210\202$\nb\210 @@;\205Y \211A\242\211@\314\230\204$\315 \316@\317\260c\210\320A@\260\315\211 P#c\210\f\203$\321 \210\202$*\207" [arg-des roxy-str here args ess-roxy-fill-param-p nil ess-roxy-guess-str 1 ess-roxy-goto-end-of-entry beginning-of-line looking-at "=" "" "\n" " @param " " " ess-replace-in-string fill-paragraph] 6 (#$ . 10089)]) #@272 Take two args lists (alists) and return their union. The result holds all keys from both FUN and ENT but no duplicates and association from ent are preferred over entries from fun. Also, drop entries from ent that are not in fun and are associated with the empty string. (defalias 'ess-roxy-merge-args #[(fun ent) "\304\211\n@@;\2032\n\211A\242\305@ \"\203(@\305@ \"AB B\202@\306B B\202 @@;\203Z \211A\242\305@ \"\2042A@\307\230\2042@AB B\2022 \237*\207" [arg-des res-arg fun ent nil assoc (#1="") #1#] 4 (#$ . 10705)]) #@301 Update the entry at point or the entry above the current function. Add a template empty roxygen documentation if no roxygen entry is available. The template can be customized via the variable `ess-roxy-template-alist'. The parameter descriptions can are filled if `ess-roxy-fill-param-p' is non-nil. (defalias 'ess-roxy-update-entry #[nil "\212\306 \307 \310 \"\311 \312\313\211\313\211\314 \210\315y\316U\204,\317c\210\315y\210\320\321!\204=\322 \204=\313\210\317c\210\322 \203M\323 S\324\n \"\202\261\325!@@;\205\261\211A\242\211@\326\230\203s\324\n`\"\210\202\254@\327\230\203\212\f \330A\317 \260c\210\202\254@\331\230\203\236\f \330ARc\210\202\254\f \332@\330A\260c\210\317\202S.\n\207" [args-fun args-ent args roxy-str line-break here ess-roxy-get-args-list-from-def ess-roxy-get-args-list-from-entry ess-roxy-merge-args ess-roxy-guess-str "" nil ess-roxy-goto-func-def -1 0 "\n" looking-at "^\n" ess-roxy-entry-p ess-roxy-delete-args ess-roxy-insert-args copy-sequence "param" "description" " " "details" " @" key template tag-def ess-roxy-template-alist] 7 (#$ . 11259) nil]) #@192 Put point at the top of the current entry or above the function at point. Return t if the point is left in a roxygen entry, otherwise nil. Error if point is not in function or roxygen entry. (defalias 'ess-roxy-goto-end-of-entry #[nil "\300 \204 \301 @b\210\302y\210\300 \203\303 b\210\304\207\305y\210\305\207" [ess-roxy-entry-p ess-end-of-function -1 ess-roxy-end-of-entry t nil] 1 (#$ . 12405)]) #@193 Put point at the top of the entry at point or above the function at point. Return t if the point is left in a roxygen entry, otherwise nil. Error if point is not in function or roxygen entry. (defalias 'ess-roxy-goto-beg-of-entry #[nil "\300 \204 \301 @b\210\302y\210\300 \203\303 b\210\304\207\305y\210\305\207" [ess-roxy-entry-p ess-end-of-function -1 ess-roxy-beg-of-entry t nil] 1 (#$ . 12814)]) #@162 Remove all args from the entry at point or above the function at point. Return 0 if no deletions were made other wise the point at where the last deletion ended (defalias 'ess-roxy-delete-args #[nil "\212\306\307\310\306\211\306\311 \210\312 \313 \211b\210\314 \210 `X\203N \310V\203N \203N\315\316P!\203@\317 \320 \n T|\210\306\321y\310U\203\307\202\n.\207" [args cont field-beg entry-beg entry-end field-end nil t 0 ess-roxy-goto-end-of-entry ess-roxy-beg-of-entry ess-roxy-end-of-entry beginning-of-line looking-at " *@param" ess-roxy-beg-of-field ess-roxy-end-of-field -1 ess-roxy-re] 4 (#$ . 13224)]) #@73 Fill an args list from the entry above the function where the point is. (defalias 'ess-roxy-get-args-list-from-entry #[nil "\212\306\211\306\211\306\211\306\307 \205t\310 \311 \210\312  `W\203s \313V\203s\314\315P!\203m\316 \317 \320\n \"\321\f\322#\321\f\323\322#\324\325\f\"\210\326\313\f\"\327\330\331 !\332Q\322\f# \260\260DB\333y\210\202.\207" [args entry-beg field-beg field-end args-text arg-name nil ess-roxy-goto-end-of-entry ess-roxy-guess-str beginning-of-line ess-roxy-beg-of-entry 0 looking-at " *@param" ess-roxy-beg-of-field ess-roxy-end-of-field buffer-substring-no-properties ess-replace-in-string "" "[[:space:]]*@param *" string-match "[^[:space:]]*" match-string replace-regexp-in-string "^" regexp-quote " *" -1 desc roxy-str ess-roxy-re] 5 (#$ . 13859)]) #@160 Remove prefix roxy string in this region if point is in a roxy region, otherwise prefix all lines with the roxy string. Convenient for editing example fields. (defalias 'ess-roxy-toggle-roxy-region #[(beg end) "\302 \204 \303\304!\210\305 \306 #\207" [beg end use-region-p error "Region is not active" ess-roxy-roxy-region ess-roxy-entry-p] 4 (#$ . 14680) "r"]) (defalias 'ess-roxy-roxy-region #[(beg end &optional on) "\212\306\211\307  \fS}\210 \203\310P\311\202!\312\313P b\210\314\nd\315#\2033\316 !\210\202$~,\207" [roxy-str to-string RE beg end on nil ess-roxy-guess-str " +?" "" "^" " " re-search-forward noerror replace-match ess-roxy-re] 4]) #@186 Use a (possibly newly) connected R session and the roxygen package `ess-roxy-package' to generate the Rd code for entry at point, place it in a temporary buffer and return that buffer. (defalias 'ess-roxy-preview #[nil "\306 \307\310!\311\312!\313\314 \315\230\203\316\202- \317\230\203)\320 \321\f\322\260\202-\323\324 \"/\325U\2039\323\326!\210\212\327 b\210\330y\210\331\332\333\"\203Q\334` #\210\202i\330y\203c\335\336!\204c\3350!\203Q\334` #\210\337 \210\340\341 \342Q!\204\323\343 \344 \345\260!\210\346/\347 \350R\n\"\210r\nq\210eb\210\351\352\353 \333#\203\241\354u\210\355 `|\210*\356 !\210\n.\207" [beg tmpf roxy-buf R-old-roxy R-new-roxy ess-roxy-package ess-roxy-beg-of-entry make-temp-file "ess-roxy" get-buffer-create " *RoxygenPreview*" "..results <- roxygen2:::roc_process(rd_roclet(), parse.files(P), \"\");cat(vapply(..results, function(x) roxygen2:::rd_out_cache$compute(x, format(x)), character(1)))" "..results <- roc_proc_text(rd_roclet(), readChar(P, file.info(P)$size));cat(vapply(..results, format, character(1)), \"\n\")" "roxygen" "make.Rd2.roclet()$parse" "roxygen2" "(function(P) { if(packageVersion('roxygen2') < '3.0.0') {" "} else {" "} })" error "Need to hard code the roclet output call for roxygen package '%s'" 0 "Point is not in a Roxygen entry" ess-roxy-end-of-entry 1 ess-end-of-function nil t append-to-file looking-at "^$" ess-force-buffer-current ess-boolean-command "print(suppressWarnings(require(" ", quietly=TRUE)))\n" "Failed to load the " " package; in R, try install.packages(\"" "\")" ess-command "(\"" "\")\n" re-search-forward "%" line-end-position -1 line-beginning-position delete-file out-rd-roclet ess-roxy-re] 6 (#$ . 15355)]) #@255 Use a (possibly newly) connected R session and the roxygen package to generate a HTML page for the roxygen entry at point and open that buffer in a browser. Visit the HTML file instead of showing it in a browser if `visit-instead-of-browse' is non-nil. (defalias 'ess-roxy-preview-HTML #[(&optional visit-instead-of-browse) "\305 \306\307\310\311#\306\307\310\312#\313 \314\n\315\260rq\210\316 !\210\317 \210\320!\210)\321 \210\322\323!\210\f\203>\322 \324P!\210\325\n!\202D\322\326 \327Q!,\207" [roxy-buf rd-tmp-file html-tmp-file rd-to-html visit-instead-of-browse ess-roxy-preview make-temp-file "ess-roxy-" nil ".Rd" ".html" "Rd2HTML(\"" "\",\"" "\", stages=c(\"render\"))" set-visited-file-name save-buffer kill-buffer ess-force-buffer-current ess-command "print(suppressWarnings(require(tools, quietly=TRUE)))\n" "\n" find-file "browseURL(" ")\n"] 5 (#$ . 17075) "P"]) #@115 Use the connected R session and the roxygen package to generate the text help page of the roxygen entry at point. (defalias 'ess-roxy-preview-text #[nil "r\300 q\210\301 )\207" [ess-roxy-preview Rd-preview-help] 1 (#$ . 17967) nil]) #@297 Preview Rd for the roxygen entry at point. Use the connected R session and the roxygen package to generate the Rd code for the roxygen entry at point. If called with a non-nil NAME-FILE (\[universal-argument]), also set the visited file name of the created buffer to facilitate saving that file. (defalias 'ess-roxy-preview-Rd #[(&optional name-file) "\302 \303!\210 \203\212\304b\210\305\306!\210\307\310\304!\311P!\210)\312 \210\313\314!\203*\314 \202,\315 )\207" [roxy-buf name-file ess-roxy-preview pop-to-buffer 1 search-forward-regexp "name{\\(.+\\)}" set-visited-file-name match-string ".Rd" Rd-mode fboundp font-lock-ensure font-lock-fontify-buffer] 3 (#$ . 18207) "P"]) #@138 Guess the prefix used in the current roxygen block. If NOT-HERE is non-nil, guess the prefix for nearest roxygen block before the point. (defalias 'ess-roxy-guess-str #[(&optional not-here) "\212\303 \203\304 b\210\305!\210\202 \203\306!\210 \204\"\303 \203(\307\310!\202)\n)\207" [ess-roxy-re not-here ess-roxy-str ess-roxy-entry-p point-at-bol search-forward-regexp search-backward-regexp match-string 0] 2 (#$ . 18899)]) #@37 Hide current roxygen comment block. (defalias 'ess-roxy-hide-block #[nil "\212\302 \303 \304\305 D\"+\207" [beg-of-entry end-of-entry ess-roxy-end-of-entry ess-roxy-beg-of-entry hs-hide-block-at-point nil] 4 (#$ . 19340) nil]) #@82 Toggle hiding/showing of a block. See `hs-show-block' and `ess-roxy-hide-block'. (defalias 'ess-roxy-toggle-hiding #[nil "\205\303\211\304\305 !\203\306 \202\307 *\207" [hs-minor-mode case-fold-search inhibit-point-motion-hooks t hs-overlay-at point-at-eol hs-show-block ess-roxy-hide-block] 2 (#$ . 19576) nil]) #@45 Hide all Roxygen entries in current buffer. (defalias 'ess-roxy-show-all #[nil "\300\301!\207" [ess-roxy-hide-all t] 2 (#$ . 19904) nil]) #@45 Hide all Roxygen entries in current buffer. (defalias 'ess-roxy-hide-all #[(&optional show) "\2052\306\211\212eb\210\307 \260d\306\310$\2051\311  \203$\312 \210\202'\313 \210\fb\210\310y\210)\202\f+\207" [hs-minor-mode case-fold-search inhibit-point-motion-hooks ess-roxy-re end-of-entry show t re-search-forward 1 ess-roxy-end-of-entry hs-show-block ess-roxy-hide-block] 5 (#$ . 20048) nil]) #@44 Go to beginning of previous Roxygen entry. (defalias 'ess-roxy-previous-entry #[nil "\301 \203\f\302 b\210\303y\210\304e\305\306$\210\302 b\207" [ess-roxy-re ess-roxy-entry-p ess-roxy-beg-of-entry -1 search-backward-regexp t 1] 5 (#$ . 20457) nil]) #@40 Go to beginning of next Roxygen entry. (defalias 'ess-roxy-next-entry #[nil "\301 \203\f\302 b\210\303y\210\304d\305\303$\210\306 b\207" [ess-roxy-re ess-roxy-entry-p ess-roxy-end-of-entry 1 search-forward-regexp t ess-roxy-beg-of-entry] 5 (#$ . 20714) nil]) #@79 Return the arguments specified for the current function as a list of strings. (defalias 'ess-roxy-get-function-args #[nil "\212\301 \210\302\303\304\305\211\306$\210`T\307 \210`\"\310\311\312#\310\313\312#\310\314\312#\310\315\312#\316\317\"*\207" [args-txt ess-beginning-of-function buffer-substring-no-properties search-forward-regexp "\\([=,-]+ *function *\\|^ *function\\)" nil 1 ess-roxy-match-paren replace-regexp-in-string "#+[^\"']*\n" "" "([^)]+)" "=[^,]+" "[ \n]+" split-string ","] 6 (#$ . 20981)]) #@33 Go to the matching parenthesis. (defalias 'ess-roxy-match-paren #[nil "\300\301!\203 \302\303!\210\304u\207\300\305!\205\303u\210\306\303!\207" [looking-at "\\s(" forward-list 1 -1 "\\s)" backward-list] 2 (#$ . 21508)]) #@28 Complete the tag at point. (defalias 'ess-roxy-complete-tag #[nil "\303 \211\205\212@b\210g)\304=\205@TA\305 \n\"E)\207" [bounds ess-roxy-tags-noparam ess-roxy-tags-param ess-bounds-of-symbol 64 append] 6 (#$ . 21737)]) #@34 Completion data for Emacs >= 24. (defalias 'ess-roxy-tag-completion #[nil "\212\305\306\307 \310#)\205*\311\312!\312\224\312\225\205)`U\205) \313 \f\"\314\315\257+\207" [end beg token ess-roxy-tags-noparam ess-roxy-tags-param re-search-backward "@\\<\\(\\w*\\)" point-at-bol t match-string-no-properties 1 append :exclusive no] 5 (#$ . 21971)]) #@169 Remove `ess-roxy-str' from STRING before sending to R process. Useful for sending code from example section. This function is placed in `ess-presend-filter-functions'. (defalias 'ess-roxy-remove-roxy-re #[(string) "\303\304!\203\"\305\306\307\"rq\210\310\216 c\210\303 +\203\"\311\n\312P\313 #\207 \207" [#1=#:temp-buffer string ess-roxy-re ess-roxy-entry-p "examples" generate-new-buffer " *temp*" t #[nil "\301!\205 \302!\207" [#1# buffer-name kill-buffer] 2] replace-regexp-in-string "\\s-*" ""] 4 (#$ . 22333)]) (add-hook 'ess-presend-filter-functions 'ess-roxy-remove-roxy-re nil) (defalias 'ess-roxy-find-par-end #[(stop-point &rest stoppers) "\302\303\"\210\212 b\210\304\305!)\207" [stoppers stop-point mapc #[(stopper) "`V\205\212\302 \303#)\205\304\224\211\207" [stop-point stopper re-search-forward t 0] 4] line-end-position 0] 3]) (defalias 'ess-roxy-with-filling-context '(macro . #[(examples &rest body) "\302\303\304\305\306\307\310\311\312BBD\257\313\314BB\315\316\317\310 BBEF\207" [examples body let (comment-start "#+'[ ]+#") (comment-start-skip "#+'[ ]+# *") (comment-use-syntax nil) (adaptive-fill-first-line-regexp (concat ess-roxy-re "[ ]*")) (paragraph-start (concat "\\(" ess-roxy-re "\\(" paragraph-start "\\|[ ]*@" "\\)" "\\)\\|\\(" paragraph-start "\\)")) temp-table if ((make-syntax-table S-syntax-table) Rd-mode-syntax-table) when ((modify-syntax-entry 35 "w" temp-table) (modify-syntax-entry 39 "w" temp-table)) cl-letf (((symbol-function 'comment-normalize-vars) #'ignore)) with-syntax-table] 10])) (byte-code "\300\301\302\303#\304\301\305\306#\210\307\310\311\312\313$\210\307\314\315\312\313$\210\307\316\317\312\313$\210\307\320\321\312\313$\210\307\322\323\312\313$\207" [function-put ess-roxy-with-filling-context lisp-indent-function 0 put edebug-form-spec (&rest form) ad-add-advice ess-eval-line-and-step (ess-eval-line-and-step-roxy nil t (advice lambda nil "Evaluate line but do not skip over comment (roxy) lines." (if (ess-roxy-entry-p) (let ((simple-next t)) ad-do-it) ad-do-it))) around nil ess-indent-command (ess-roxy-toggle-hiding nil t (advice lambda nil "Hide this block if we are at the beginning of the line." (if (and (= (point) (point-at-bol)) (ess-roxy-entry-p) 'ess-roxy-hide-show-p) (progn (ess-roxy-toggle-hiding)) ad-do-it))) fill-paragraph (ess-roxy-fill-advise nil t (advice lambda nil "Fill roxygen paragraphs." (cond ((not (and (eq major-mode 'ess-mode) (string= ess-dialect "R"))) ad-do-it) ((and (ess-roxy-entry-p) (save-excursion (back-to-indentation) (looking-at "#"))) (ess-roxy-with-filling-context t ad-do-it)) ((and (not (ess-roxy-entry-p)) (ess-inside-comment-p)) ad-do-it) ((and ess-fill-calls (ess-inside-call-name-p)) (save-excursion (skip-chars-forward "^([") (forward-char) (ess-fill-args))) ((and ess-fill-continuations (ess-inside-continuation-p)) (ess-fill-continuations)) ((and ess-fill-calls (ess-inside-call-p)) (ess-fill-args)) ((ess-roxy-entry-p) (save-excursion (let* ((saved-pos (point)) (saved-line (line-number-at-pos)) (saved-col (current-column)) (buffer (current-buffer)) (par-start (save-excursion (if (save-excursion (and (backward-paragraph) (forward-paragraph) (<= (point) saved-pos))) (line-beginning-position) (progn (backward-paragraph) (point))))) (par-end (ess-roxy-find-par-end (save-excursion (forward-paragraph) (point)) (concat ess-roxy-re "[ ]*@examples\\b") "^[^#]"))) (ess-roxy-with-filling-context nil (save-excursion (save-restriction (narrow-to-region par-start par-end) (goto-char 0) (while (< (point) (point-max)) (ess-roxy-maybe-indent-line) ad-do-it (forward-paragraph)))))))) (t ad-do-it)))) move-beginning-of-line (ess-roxy-beginning-of-line nil t (advice lambda nil "Move to start." (if (ess-roxy-entry-p) (let ((new-pos (save-excursion (end-of-line) (and (re-search-backward (concat ess-roxy-re " ?") (point-at-bol) t) (match-end 0))))) (if (or (bolp) (< new-pos (point))) (goto-char new-pos) ad-do-it)) ad-do-it))) back-to-indentation (ess-roxy-back-to-indentation nil t (advice lambda nil "Handle `back-to-indentation' in roxygen doc." (if (ess-roxy-entry-p) (progn (end-of-line) (re-search-backward (concat ess-roxy-re " *") (point-at-bol) t) (goto-char (match-end 0))) ad-do-it)))] 6) (defalias 'ess-roxy-indent-new-comment-line #[nil "\300 \204\301 \207\302 \207" [ess-roxy-entry-p indent-new-comment-line ess-roxy-indent-on-newline] 1]) (defalias 'ess-roxy-newline-and-indent #[nil "\301 \203 \204\f\302 \207\303 \207" [ess-roxy-insert-prefix-on-newline ess-roxy-entry-p newline-and-indent ess-roxy-indent-on-newline] 1]) #@38 Insert a newline in a roxygen field. (defalias 'ess-roxy-indent-on-newline #[nil "`\301 U\203\n\302 \207\212\303y\210\304 \210`)`]b\210)\302 \210\305\306!\307Pc\207" [point-after-roxy-string ess-roxy-beg-of-entry newline-and-indent 0 ess-back-to-roxy ess-roxy-guess-str t " "] 2 (#$ . 26916)]) (provide 'ess-roxy)