Re: [Builder] Global Search



On 01/14/2015 06:26 AM, Erick Pérez Castellanos wrote:
## Search Results Layout

```
  +----------------+-------------------------------------------------+
  |      Switch To | my-widget.md                              [==-] |
  |                | my-widget.ui                              [=- ] |
  |                | my-widget.c                               [=- ] |
  |                | my-widget.h                               [=- ] |
  | Jump to Symbol | my_widget_init                            [=- ] |
  |                | my_widget_class_init                      [-  ] |
  |                | my_widget_do_something                    [-  ] |
  |                |                                          2 more |
  |  Read Docs For | GtkWidget                                 [-  ] |
  |                | GtkTextView                               [-  ] |
  |                | GtkSourceView                             [-  ] |
  |                |                                         20 more |
  |     Calculator | hex(3*10) = 1E                                  |
  +----------------+-------------------------------------------------+
```

"Switch to" and "Open Document" could be merge, in the end its the same thing.
Also I think preferences could be excluded from here. There's a
shorcut to get into the preferences dialog and search inside the
dialog. The same for actions, those are available from the command bar
and it has autocompletion.

Merging Switch To and Open Document makes sense from the user
perspective. A bit harder from the implementation perspective (since the
Git index knows nothing about open documents). But I think it's
worthwhile to do this merging.

I'm wondering if we can replace the command bar with the global search
(with the exception of VIM mode). I think once history is exposed into
the command bar, it will stand well on it's own (so I think the answer
is no, we can't replace it).

## Shortcuts

On the idea of limiting the output we could do something like:
"c: my_widget" will show only the results of the "c" search providers,
the colon will act as a delimiter and if the user want to search for
the string `c:` it can always wrapped into single-quotes.

Yes, the idea is to only show the relevant search provider's results
when the character prefix is matched.

I don't think we can provide meaningful results with a single character
search query, so I'm not too worried about a delimiter between the
provider and the result.

As we get a real search engine, (with bi-grams and tri-grams), then
things like quoted strings makes sense.

## Search Context

Again, if the user clicks on the "X more" link there's no need to show
the results of other providers, clearly the user wants the results of
that provider and not the others

My thought was that we'd slide in from the right the search query
limited to that provider. (With the standard back arrow at the top to go
back).

Technical detail: This will execute the query a second time, but just
for that provider. This way we can discard items that are not high
enough score without creating costly objects for them in the normal case.

-- Christian



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]