Re: more missing boxed types



James Henstridge <james daa com au> writes:

> I was going through the pango headers looking for more types that could
> use typecodes.  Here are the ones with missing get_types I found:

>   PangoCoverage: easy to fix.  Already has ref/unref pair in header

Very much internal, however.

>   PangoEngine ??? (is this needed by an app?)

No, it's not needed.

>   PangoGlyphString

This one is a bit interesting ... there are functions in GDK, for
instance, that take PangoGlyphString. It's still pretty lowlevel, and
most uses of PangoGlyphString would still require looking inside the
structure.

>   PangoItem: this one already has copy/free pair in header

On the other hand, it is used by poking into the structure in a very
undisciplined manner .... it would take lots of manual intervention to
make it useable from a language binding. I don't think it makes sense
to have a boxed type for this one currently.. it's messy and pretty
lowlevel.

>   PangoLanguage: may not be necessary.

I think language bindings will _probably_ want to use non-interned
strings for PangoLanguage. While its marginally less efficient, it's
more convenient to use "en-us", then Pango.Language ("en-us"),
lang.to_string ().

The language property on GtkTextTag just uses a string, for
example. It's perhaps a bit like PangoFontDescription in this manner.

I wouldn't object to a patch to add boxed types for PangoGlyphString
and PangoLanguage, though even they are a little marginal.

Regards,
                                        Own


 




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