After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 471362 - Should have more useful sources (Wikipedia?)
Should have more useful sources (Wikipedia?)
Status: RESOLVED OBSOLETE
Product: gnome-dictionary
Classification: Core
Component: general
git master
Other Linux
: Normal enhancement
: ---
Assigned To: gnome-dictionary-maint
gnome-dictionary-maint
: 492626 597249 (view as bug list)
Depends on:
Blocks:
 
 
Reported: 2007-08-29 00:02 UTC by Bastien Nocera
Modified: 2021-06-10 11:23 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Bastien Nocera 2007-08-29 00:02:19 UTC
Having a Wikipedia source, and being able to switch languages means that we'd get very good support for 14 languages. The default source could be chosen depending on the locale.

MacOS X' dictionary can use Wikipedia
http://www.thinksecret.com/archives/leopard9a527/image/dictionary001.jpg
Comment 1 Emmanuele Bassi (:ebassi) 2007-08-29 07:45:56 UTC
does wikipedia provide a web API to retrieve the data in text/plain form? is any documentation available?

otherwise I'd have to embed a web browser into the dictionary, and that I would like to avoid; or I'd have to screenscrape the contents of a wiki page through something like lynx to have it in text/plain, and that too I'd like to avoid.
Comment 2 Bastien Nocera 2007-08-29 11:57:15 UTC
It looks like the DBPedia page offers a decent API. It doesn't contain all the data that the actual Wikipedia page does, but it might be a good thing, allowing the user to click an item to get more information in a browser.

Here's an example page:
http://dbpedia.org/page/Manchester_United_F.C.
http://dbpedia.org/docs/

There's also the FUTEF API:
http://api.futef.com/apidocs.html

The MediaWiki API, available directly from Wikipedia:
http://en.wikipedia.org/w/api.php

A "special export" type of page from Wikipedia:
http://en.wikipedia.org/wiki/Special:Export/Train

A Perl search API:
http://search.cpan.org/~esummers/WWW-Wikipedia/lib/WWW/Wikipedia.pm
Comment 3 Emmanuele Bassi (:ebassi) 2007-09-04 14:25:08 UTC
the Special:Export page looks promising. I think libsoup could be used to retrieve the data from the web and then the returned XML could be parsed to generate the output. thanks for the pointers!
Comment 4 Teppo Turtiainen 2007-12-08 09:53:12 UTC
*** Bug 492626 has been marked as a duplicate of this bug. ***
Comment 5 antistress 2009-02-28 04:15:59 UTC
nothing new about that feature request ?
Comment 6 Luis Menina 2009-03-02 17:07:40 UTC
Don't forget to use wiktionary.org, which makes more sense at first than wikipedia.org.
Comment 7 Emmanuele Bassi (:ebassi) 2014-11-02 11:11:15 UTC
*** Bug 597249 has been marked as a duplicate of this bug. ***
Comment 8 Juan R. Garcia Blanco 2014-12-26 10:31:51 UTC
I think we need to define a new GdictSource interface, for which the current GdictSource would be an implementation; another implementation would handle a wiktionary source.

I think wiktionary and DICT sources share almost nothing, maybe just a name and a description; so we need to add a ::protocol property to identify the implementation. I don't know if this is a good pattern.

Anyway, undoubtedly we need a wiktionary source and an associated context, so I will start with that. The output can now be retrieved also in json format.
Comment 9 Juan R. Garcia Blanco 2015-03-07 12:44:24 UTC
I've started this as a proof of concept https://github.com/juanrgar/gnome-wiktionary
Comment 10 André Klapper 2021-06-10 11:23:20 UTC
GNOME is going to shut down bugzilla.gnome.org in favor of gitlab.gnome.org.
As part of that, we are mass-closing older open tickets in bugzilla.gnome.org
which have not seen updates for a longer time (resources are unfortunately
quite limited so not every ticket can get handled).

If you can still reproduce the situation described in this ticket in a recent
and supported software version of gnome-dictionary, then please follow
  https://wiki.gnome.org/GettingInTouch/BugReportingGuidelines
and create a ticket at
  https://gitlab.gnome.org/GNOME/gnome-dictionary/-/issues/

Thank you for your understanding and your help.