[ESS] Help pops up in web browser

Julian M. Burgos ju||@n@burgo@ @end|ng |rom h@|ogv@tn@|@
Mon Feb 24 10:29:47 CET 2020


Hi Naresh,

But isn't company-quickhelp supposed to show you the help when you are idling on a completion candidate?  You can modify this behaviour.  According to the github page:

"You can adjust the time it takes for the documentation to pop up by changing company-quickhelp-delay.

If you don't want the help popup to appear automatically, but prefer it to the popup help buffer provided by company, you can set company-quickhelp-delay to nil and manually trigger the popup with M-h."

The problem is that for some reason the R help is showing up in a separate buffer and not on a pop-up window as it is supposed to happen with company-quickhelp.  I don't know why this happens.

I don't use python, but in R and ESS you don't need company-quickhelp if you want to call the help file yourself.  In company-mode, you can press F1 and get the help file of the candidate in the company popup window.  And ESS provides ess-display-help-on-object (by default bounded to C-c C-v) to access the help file from any function.

If company-quickhelp is working for you in Python but not in ESS, you could activate it in your Python mode hook so it is only available when working on Python.

My best,

Julian



Naresh Gurbuxani writes:

> Julian,
>
> I was able to solve the second problem.  Now when I type ?library, R help is displayed in an emacs window, not a browser.
>
> But the first problem remains.  When I type and incomplete command (e.g., "libr"), emacs displays the entire documentation of "library" in inferior ESS window.  So emacs still opens the help file, not in browser but in inferior ESS window.
>
> I only want help document displayed when specifically asked (e.g., by typing ?library in inferior ESS window).  Otherwise, I only want a "temporary window" which shows possible completions and documentation, but disappears when command is complete.
>
> Thanks,
> Naresh
>
> ________________________________
> From: Julian M. Burgos <julian.burgos using hafogvatn.is>
> Sent: Friday, February 21, 2020 5:03 AM
> To: Naresh Gurbuxani <naresh_gurbuxani using hotmail.com>
> Cc: ess-help using r-project.org <ess-help using r-project.org>
> Subject: Re: [ESS] Help pops up in web browser
>
> Hi Naresh,
>
> I had a similar issue recently with emacs "automatically" opening the help file from a function when I started to type it.  It took me a lot of head scratching but I figured out that the culprit was one of the company-frontends (probably interacting with some other component of my setup).  I used to have these:
>
> (setq company-frontends
>            '(company-pseudo-tooltip-unless-just-one-frontend
>                      company-preview-frontend
>                       company-echo-metadata-frontend))
>
> I replaced them for this:
>
> (setq company-frontends '(company-pseudo-tooltip-frontend
>                           company-echo-metadata-frontend))
>
> And the problem went away.  I do not know exactly why.
>
> I found an old discussion thread where the problem was related to a conflict between the use of autocompletion and the use of html help:
>
> https://eur01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fstat.ethz.ch%2Fpipermail%2Fess-help%2F2013-April%2F008868.html&data=02%7C01%7C%7Cba177f5e93a74bb77e1608d7b789820b%7C8e105b94435e4303a61063620dbe162b%7C0%7C0%7C637179673539950023&sdata=bTxbW4BwIJykt0eK%2FR3u%2BL59smgKy5VJzO%2FYpTAN17U%3D&reserved=0
>
> ... the problem was that help was *supposed* to show up automatically in a pop-up window, but if you had your help file show up as html (instead of plain text), you get a browser with the help file instead.
>
> I assume that something similar is happening now with company-mode.
>
> Because I prefer the help in html (because hyperlinks, and as I use EXWM and the browser shows up within an emacs buffer) in my .emacs file I have this:
>
> (setq inferior-ess-r-help-command "help(\"%s\", help_type=\"html\")\n")
>
> But if you want (or need) help in plain text you can use
>
> help_type=text
>
> to ensure that the help shows up as text.
>
> I hope this helps.
>
> Cheers,
>
> Julian
>
>
> Naresh Gurbuxani via ESS-help writes:
>
>> To display python documentation, I recently installed company-quickhelp.  While it works well for python, my emacs now has an annoying feature in ess-r mode.
>>
>> When I linger on an R function, emacs launches a new web browser window displaying help for that function.  For example on typing ‘libr’, emacs launches a new browser window displaying documentation for ‘library’.  Moreover, the browser becomes the active application.
>>
>> How can this feature be turned off?  I want documentation to be displayed only when asked.  Moreover, I want to see documentation in emacs window.
>>
>> I am using Windows operating system.
>>
>> Thanks,
>> Naresh
>>
>> Sent from my iPhone
>> ______________________________________________
>> ESS-help using r-project.org mailing list
>> https://eur01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fstat.ethz.ch%2Fmailman%2Flistinfo%2Fess-help&data=02%7C01%7C%7Cba177f5e93a74bb77e1608d7b789820b%7C8e105b94435e4303a61063620dbe162b%7C0%7C0%7C637179673539950023&sdata=%2FNwl9Ds%2B2CTcsA35sS0yxO9KhNgAkgfLe0XeNdQTEls%3D&reserved=0


--
Julian Mariano Burgos, PhD
Hafrannsóknastofnun, rannsókna- og ráðgjafarstofnun hafs og vatna/
Marine and Freshwater Research Institute
Botnsjávarsviðs / Demersal Division
Skúlagata 4, 121 Reykjavík, Iceland
Sími/Telephone : +354-5752037
Bréfsími/Telefax:  +354-5752001
Netfang/Email: julian.burgos using hafogvatn.is



More information about the ESS-help mailing list