Re: Search from address bar
Aki Helin <[email protected]>
| Newsgroups | gmane.comp.web.dillo.devel |
|---|---|
| Message-ID | <51bfe6ce.kpSK5jXnK1NfcCfM%[email protected]> |
Johannes Hofmann <[email protected]> wrote: > On Mon, Jun 17, 2013 at 11:53:45PM +0300, Aki Helin wrote: > > Johannes Hofmann <[email protected]> wrote: > > > > > Hi, > > > > > > On Mon, Jun 17, 2013 at 03:16:09PM +0300, Aki Helin wrote: > > > > Hi, > > > > > > > > [...] > > > > Searches would have to be differentiated somehow from URLs. Dillo already > > > > has a customizable list of engines in preferences, so one natural solution > > > > would be to interpret url strings which start with the name of a search > > > > engine as searches to be performed using it, so that e.g. 'wikipedia > > > > slartibartfast', 'google foo' and 'weather oulu' do what you would expect. > > > > > > > > Below is a quick patch I've used to do this for a while, should anyone > > > > else find this feature useful. > > > > > > This has been discussed before, but somehow wasn't completed. I like > > > your idea to reuse the search engine name to derive the shortcut. > > > However, I would allow arbitrary prefixes of the search engine name > > > as in the slightly modified patch below. > > > What do you think? > > > > Looks good to me. You could even drop the 'len > 0' check, so that > > prefixing with space leads to search with your first search engine, > > and an optional prefix can be given to choose another one. > > Not sure about that. What I really hate with other browsers is when > they send the location I typed to some search engine just because > they think it's not a hostname. Searching for everything that starts > with a blank seems a bit too aggressive to me. On second thought, it is. It would also lead to pasted URLs being sent to search engine if you accidentally copied a space. -- Aki Helin