|
|
Home » U++ TheIDE » U++ TheIDE: Other Features Wishlist and/or Bugs » [PROPOSAL] Configurable web search menu for TheIDE
[PROPOSAL] Configurable web search menu for TheIDE [message #55394] |
Fri, 06 November 2020 11:34  |
Oblivion
Messages: 1202 Registered: August 2007
|
Senior Contributor |
|
|
Hi,
I've been using TheIDE with this configurable web search menu for some time and I find it very useful, so I thought it might be a good idea to propose it for the trunk.
A direct search on web sites sometimes yield better results than using a generic search engine such as google. E.g. just search for "private" on Google and CppReference and see the results. 
What I propose is:
* Adding an optional sub-menu to TheIDE's context menu. This menu will become visible only if a search provider is set.
* Adding a simple search provider setup tab in the setting menu.
- This proposal does not change Google and Upp website search entries, and leave them intact (as default, hard-coded options).
Screenshots:


What do you think?
Best regards,
Oblivion
Github page: https://github.com/ismail-yilmaz
upp-components: https://github.com/ismail-yilmaz/upp-components
Bobcat the terminal emulator: https://github.com/ismail-yilmaz/Bobcat
[Updated on: Fri, 06 November 2020 11:38] Report message to a moderator
|
|
|
|
|
|
|
|
|
|
Re: [PROPOSAL] Configurable web search menu for TheIDE [message #55445 is a reply to message #55427] |
Wed, 11 November 2020 10:15   |
Oblivion
Messages: 1202 Registered: August 2007
|
Senior Contributor |
|
|
Quote:Actually, if U++ ever started to be used more widely, nice possible source of funding there...
Fingers crossed.
Anyway, the above patch adds the ability to set ALT + G and default search provider.
In time if Upp gains more audience, we can simply ship a selected set of default entries too (Json file compiled-in as a binary resource, maybe). For now, the hard-coded default is Google but it can be changed by users, using the web search manager or simply by editing the ide.search file.
The real benefit of this configurable search engine is that it allows users to do something like this:


Best regards,
Oblivion
Github page: https://github.com/ismail-yilmaz
upp-components: https://github.com/ismail-yilmaz/upp-components
Bobcat the terminal emulator: https://github.com/ismail-yilmaz/Bobcat
[Updated on: Wed, 11 November 2020 10:17] Report message to a moderator
|
|
|
Re: [PROPOSAL] Configurable web search menu for TheIDE [message #55446 is a reply to message #55445] |
Wed, 11 November 2020 14:41   |
 |
Klugier
Messages: 1099 Registered: September 2012 Location: Poland, Kraków
|
Senior Contributor |
|
|
Hello,
I would personally simplify editor menu. Too many options there is not good option and might be misleading. So I opt for moving "Search on Google" and "Search on the official site.." to "Search on menu" (This entry shouldn't have .., because it doesn't spawn any external dialog or redirect to browser):
Search on ->
Google..
Official site..
Separator /* Not hard coded engines */
CppReference..
DuckDuckGo..
...
Thanks to that editor menu will not be overload with options.
Also "ide.search" nice idea for external modification, however we should use regular TheIDE serialization procedures (binary) and bump settings version. We should keep all TheIDE options in standardize way. If we want to keep it in external file that is easy to modify by the user then let's do it for all options. Partial solution will always increase fragmentation.
I like the idea of supporting more sources. With the solution that we will have the option to specify default engine only we will lose that ability. Also, sites like CppReference is extremely useful for the learning purpose (C++ and standard library).
If we will gain popularity - sure we could try selling default option here. Maybe we should ask DuckDuckGo if they want to buy it 
Klugier
U++ - one framework to rule them all.
[Updated on: Wed, 11 November 2020 16:12] Report message to a moderator
|
|
|
Re: [PROPOSAL] Configurable web search menu for TheIDE [message #55447 is a reply to message #55446] |
Wed, 11 November 2020 16:22   |
Oblivion
Messages: 1202 Registered: August 2007
|
Senior Contributor |
|
|
Hello Klugier,
Quote: would personally simplify editor menu. Too many options there is not good option and might be misleading. So I opt for moving "Search on Google" and "Search on the official site.." to "Search on menu"
OK.
Quote:however we should use regular TheIDE serialization procedures (binary) and bump settings version
I was hesitant to add a Serialize method (not to disrupt TheIDE's config settings), but this sounds OK to me. Still, I'd prefer an external file in human-readble form (Json seems very good to me. besides it can allow us to easily change/add new stuff if need be).
I'll upload a patch with the changes you've asked, later tonight.
It is up to Mirek to decide.
p.s: Speaking of consistency, I think TheIDE's toolbar should have an Icon for "Settings" menu entry.
Best regards,
Oblivion
Github page: https://github.com/ismail-yilmaz
upp-components: https://github.com/ismail-yilmaz/upp-components
Bobcat the terminal emulator: https://github.com/ismail-yilmaz/Bobcat
[Updated on: Wed, 11 November 2020 16:25] Report message to a moderator
|
|
|
|
|
|
Re: [PROPOSAL] Configurable web search menu for TheIDE [message #55457 is a reply to message #55456] |
Thu, 12 November 2020 21:02   |
Oblivion
Messages: 1202 Registered: August 2007
|
Senior Contributor |
|
|
Quote:do the phrase placeholder need to be so complicated? Would not simple '@' be enough?
Sure, @ would do just fine.
I was following KDE/Konqueror's style there. Gnome web uses "%s", for example.
Quote:
I am sorry but the code feels a bit overengineered. There will be simplifications
By all means, go on. 
Quote:More importantly, we need a default list.
Yes, I was going to propose that too, but apparently I am a bit late.
Still I think, at least Google, Upp, CppReference, StackOverflow [+Github] could be in the list.
Thanks.
Best regards,
Oblivion
Github page: https://github.com/ismail-yilmaz
upp-components: https://github.com/ismail-yilmaz/upp-components
Bobcat the terminal emulator: https://github.com/ismail-yilmaz/Bobcat
[Updated on: Thu, 12 November 2020 21:04] Report message to a moderator
|
|
|
|
Re: [PROPOSAL] Configurable web search menu for TheIDE [message #55472 is a reply to message #55471] |
Sat, 14 November 2020 13:58   |
Oblivion
Messages: 1202 Registered: August 2007
|
Senior Contributor |
|
|
Hello Mirek,
Quote:ReadIcon crashed on png. But it does not anymore when I am testing. Can you check this one?
I've just synced my copy of trunk and recompiled TheIDE (on Linux, in both DEBUG and RELEASE modes). The issue seems to be resolved. The search manager downloaded and displayed the icons correctly. Thanks!
By the way, some more observations on the new code:
1. It does not discard empty entries in json file (while reading). Empty entries can show up in both menu and in the search manager. The original patch prevented this. A cosmetics issue really, but looks ugly when it happens.
2. Default Google search is not available when the list has at least one entry. (The original patch prevented this too by allowing the user to unset the default engine) The only way to reset the default search engine to Google is by deleting the entire list.
3. ArrayCtrl has ScrollBar visible. Shouldn't it be AutoHideScrollbar() ?
4. ArrayCtrl has visible vertical and horizontal grids, which seems unnecessary as it uses even/odd line coloring already.
As for the StackOverflow issue,
I have now checked and yes, you are right. We should find anothe provider.
I'd recommend Microsoft Docs (for at least Windows builds)
Thank you for your efforts.
Best regards,
Oblivion
Github page: https://github.com/ismail-yilmaz
upp-components: https://github.com/ismail-yilmaz/upp-components
Bobcat the terminal emulator: https://github.com/ismail-yilmaz/Bobcat
[Updated on: Sat, 14 November 2020 14:05] Report message to a moderator
|
|
|
|
|
|
Goto Forum:
Current Time: Fri Apr 25 21:30:03 CEST 2025
Total time taken to generate the page: 0.01610 seconds
|
|
|