Re: [Sugar-devel] MIME type?

2016-06-21 Thread Iain Brown Douglas
On Tue, 2016-06-21 at 18:26 -0300, Gonzalo Odiard wrote: > Just beautiful :) It is. @Sam is this a product of Sphinx and Alabaster? I read [1] "as of Sphinx 1.3, Alabaster is ... the default theme." Previously I tried using Alabaster as the theme for Help Activity, it looked super, but I could

Re: [Sugar-devel] MIME type?

2016-06-21 Thread Dave Crossland
Probably, yes; there is a new font top level type in draft stage - https://datatracker.ietf.org/doc/draft-ietf-justfont-toplevel/ - and you could try these 3 for import: ttf "application/x-font-ttf" or "application/x-font-truetype" otf "application/x-font-opentype" sfnt "application/font-sfnt" I

Re: [Sugar-devel] MIME type?

2016-06-21 Thread Yash Agarwal
The documentation (attached below) says that we only use generic mime types defined in mime.py so do I need to make additions to mime.py to accommodate these types *what_filter (str): an activity bundle_id or a generic mime type as* *defined in :mod:`sugar3.mime` used to determine

Re: [Sugar-devel] MIME type?

2016-06-21 Thread Yash Agarwal
What if I want to open .ttf/.otf or .ufo files that are already on the system and not generated by my activity? What filter type should I specify then? On Wed, Jun 22, 2016 at 2:56 AM Gonzalo Odiard wrote: > Just beautiful :) > > On Tue, Jun 21, 2016 at 6:17 PM, Sam P.

Re: [Sugar-devel] MIME type?

2016-06-21 Thread Gonzalo Odiard
Just beautiful :) On Tue, Jun 21, 2016 at 6:17 PM, Sam P. wrote: > Hi Sebastian, > > We have Sphinx docs avbaliable online: > https://developer.sugarlabs.org/sugar3/ > > Contributions to add more docstrings are always appreciated. > > Thanks, > Sam > > On Wed, Jun 22, 2016, 04:53

Re: [Sugar-devel] MIME type?

2016-06-21 Thread Sam P.
Hi Sebastian, We have Sphinx docs avbaliable online: https://developer.sugarlabs.org/sugar3/ Contributions to add more docstrings are always appreciated. Thanks, Sam On Wed, Jun 22, 2016, 04:53 Sebastian Silva wrote: > El 21/06/16 a las 13:32, Gonzalo Odiard

Re: [Sugar-devel] MIME type?

2016-06-21 Thread Gonzalo Odiard
Also Sam was experimenting with generate the docs (like Aleksey did for the gtk2 sugar api) with gtk3 sugar3 api. On Tue, Jun 21, 2016 at 5:10 PM, Gary Martin wrote: > > On 21 Jun 2016, at 19:48, Sebastian Silva > wrote: > > > > El 21/06/16 a

Re: [Sugar-devel] MIME type?

2016-06-21 Thread Gary Martin
> On 21 Jun 2016, at 19:48, Sebastian Silva wrote: > > El 21/06/16 a las 13:32, Gonzalo Odiard escribió: > >> (btw, would be good have this information in a official place) > +1 in fact the Sugar Toolkit API docs are not online. Aleksey used to > maintain a website

Re: [Sugar-devel] MIME type?

2016-06-21 Thread Sebastian Silva
El 21/06/16 a las 13:32, Gonzalo Odiard escribió: > (btw, would be good have this information in a official place) +1 in fact the Sugar Toolkit API docs are not online. Aleksey used to maintain a website for them. Also, recently Tony complained that there's no toolkit docs. I don't know how

Re: [Sugar-devel] MIME type?

2016-06-21 Thread Sebastian Silva
El 21/06/16 a las 13:32, Gonzalo Odiard escribió: > (btw, would be good have this information in a official place) +1 in fact the Sugar Toolkit API docs are not online. Aleksey used to maintain a website for them. Also, recently Tony complained that there's no toolkit docs. I don't know how

Re: [Sugar-devel] MIME type?

2016-06-21 Thread Gonzalo Odiard
You can set the mime types your activity can open, and request to the object chooser open these mime types. More info: http://godiard.blogspot.com.ar/2013/07/sugar-programming-improovements-in.html (btw, would be good have this information in a official place) On Tue, Jun 21, 2016 at 3:23 PM,

[Sugar-devel] MIME type?

2016-06-21 Thread Yash Agarwal
Hello, what mime type should I use in the object chooser dialog for opening any ttf/otf or ufo files? Yash Agarwal ___ Sugar-devel mailing list Sugar-devel@lists.sugarlabs.org http://lists.sugarlabs.org/listinfo/sugar-devel

Re: [Sugar-devel] mime type error in sugar

2014-01-19 Thread Gonzalo Odiard
I don't know if this was needed by historical reasons, maybe the Gio functionality was not available. mime.get_for_file do some magic to recognize text files. Probably mime.get_for_file could call Gio instead of the SugarExt equivalent. Gonzalo On Sat, Jan 18, 2014 at 6:49 AM, Daniel Narvaez

Re: [Sugar-devel] mime type error in sugar

2014-01-19 Thread Daniel Narvaez
On 19 January 2014 17:04, Gonzalo Odiard godi...@sugarlabs.org wrote: I don't know if this was needed by historical reasons, maybe the Gio functionality was not available. mime.get_for_file do some magic to recognize text files. Gio seems to handle that just fine (tested with

Re: [Sugar-devel] mime type error in sugar

2014-01-19 Thread Gonzalo Odiard
On Sun, Jan 19, 2014 at 1:47 PM, Daniel Narvaez dwnarv...@gmail.com wrote: On 19 January 2014 17:04, Gonzalo Odiard godi...@sugarlabs.org wrote: I don't know if this was needed by historical reasons, maybe the Gio functionality was not available. mime.get_for_file do some magic to recognize

Re: [Sugar-devel] mime type error in sugar

2014-01-18 Thread Daniel Narvaez
Why we need that method at all? Without knowing the history of this code, it seems like we should Gio, both if the file exists and if it doesn't (if I remember correctly guess if for when the file doesn't exist). On 16 January 2014 20:42, Gonzalo Odiard godi...@sugarlabs.org wrote: I have

[Sugar-devel] mime type error in sugar

2014-01-16 Thread Gonzalo Odiard
I have filled #4715 [1] with information about a problem with the mime database in sugar. A workaround is available, but I would like to know what other think about using Gio to identify the mime types instead of our own SugarExt.mime_get_mime_type_for_file Regards, -- Gonzalo Odiard SugarLabs -