Hi Slava,

Thanks for your review.

2010/10/13 Slava Pestov <sl...@factorcode.org>:
> Hi Anton,
>
> I took a look at the latest gtk bindings code. It looks good but needs
> a few fixes. I think once you fix these problems, we should merge it
> as soon as its minimally usable, so that it can get more testing from
> users.
>
> - basis/pango/cairo/cairo.factor references 'cairo.pango.ffi'.
> Changing it to 'pango.cairo.ffi' makes it load.
Oops!

> - typing in the UI listener immediately crashes with a fep. Changing
> "[ first2 ] bi@" to "[ first2 [ >fixnum ] bi@ ]" in ui.backend.gtk
> fixes that problem.
What is the "fep"?
I think that integer types must have the same behaviour on 32 and 64
bit systems.
On 64 bit int has [ >fixnum ] in its unboxer-quot slot, so it's
possible to run "1.0 2.5 1 1 cairo_rectangle_int_t <struct-boa>", but
(I think) the same code will crash on 32 bit.

> - Mouse clicks are not handled properly because the GdkEventButton
> struct is defined wrong. Looking at it in the gesture-logger, I'm
> seeing mouse clicks produce the following:
> T{ button-down { mods { S+ } } { # 131694336 } }
> Comparing the definition of GdkEventButton in gdkevent.h with
> GdkEventButton that gets generated in Factor, I see the former has a
> field 'gdouble * axis' and the latter has 'gdouble axis'. On 64-bit
> systems, as long as this field is never accessed there will not be a
> problem, but on 32-bit it messes up the struct layout. I suspect you
> only tested on x86-64 :-)
Sorry, I didn't check these structs after moving to a version 0.9 of
the GObjectIntrospection (this version don't make any suppositions and
needs more detailed annotations so there are many incorrect types of
'out' and/or 'array' function parameters and fields). Possibly I will
implement these structs manually.

> - ui.backends.gtk:gadget-location is duplicating ui.gadgets:screen-loc.
Ok, I'll remove it.

> - I get this error when closing the help browser window:
>
> Type check error
> Object: ALIEN: a9b2df84
> Object type: alien
> Expected type: fixnum
>
> (O) Word: ( callback )
> (O) Word: on-preedit-changed
> (O) Word: get-preedit-string
> (U) Quotation: [
>        63 special-object error-thread set-global
>        continuation -> error-continuation set-global
>        [ original-error set-global ] [ rethrow ] bi
>    ]
That's weird. Actually on-preedit-changed should never be called,
because I turned "preediting" off (so some code can be removed). But
when I called get-preedit-string manually, it worked without errors.
 What's a version of Gtk? I will test this case more deeply.

> - Deployed images are too large; one problem is that io.backend.unix
> is always pulled in by the Gtk backend. hello-ui deploys down to 2.6mb
> with the Gtk backend and 1.2 Mb with X11.
I decreased deployed image size from 3.7 to 3.2 by stripping
gobject-introspection.types:type-infos global variable in
tools.deploy.shaker ('"type-infos" "gobject-introspection.types"
lookup ,' in 'stripped-globals'). How should it be done?

> - You may as well nuke opengl.gl.x11 and ui.backend.x11 at this point;
> they no longer work since the pango code pulls in gtk.
Hm... They work well (i didn't test enough, but they should work :)).

> Slava
>
> ------------------------------------------------------------------------------
> Beautiful is writing same markup. Internet Explorer 9 supports
> standards for HTML5, CSS3, SVG 1.1,  ECMAScript5, and DOM L2 & L3.
> Spend less time writing and  rewriting code and more time creating great
> experiences on the web. Be a part of the beta today.
> http://p.sf.net/sfu/beautyoftheweb
> _______________________________________________
> Factor-talk mailing list
> Factor-talk@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/factor-talk
>

------------------------------------------------------------------------------
Beautiful is writing same markup. Internet Explorer 9 supports
standards for HTML5, CSS3, SVG 1.1,  ECMAScript5, and DOM L2 & L3.
Spend less time writing and  rewriting code and more time creating great
experiences on the web. Be a part of the beta today.
http://p.sf.net/sfu/beautyoftheweb
_______________________________________________
Factor-talk mailing list
Factor-talk@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/factor-talk

Reply via email to