Re: [clutter] Guide for updating from 0.8

2009-08-10 Thread Emmanuele Bassi
On Mon, 2009-08-10 at 16:46 +0100, Emmanuele Bassi wrote:

 obviously, if somebody comes up with other topics, then feel free to
 mention them on the mailing list or open a bug; patches, as always, are
 welcome.

by the way, the README file also lists the changes in the release notes,
and the deprecation defines should give a hint when the API has been
changed/replaced.

ciao,
 Emmanuele.

-- 
Emmanuele Bassi, Senior Engineer| emmanuele.ba...@intel.com
Intel Open Source Technology Center | http://oss.intel.com

-- 
To unsubscribe send a mail to clutter+unsubscr...@o-hand.com



Re: [clutter] Guide for updating from 0.8

2009-08-10 Thread Karl Lattimer
On Mon, 2009-08-10 at 16:46 +0100, Emmanuele Bassi wrote:
 On Mon, 2009-08-10 at 16:42 +0100, Karl Lattimer wrote:
 
  Is there a guide available anywhere to assist in updating code from
  clutter-0.8 to clutter-1.0?

 I've been looking at the rest of the changes, and was planning to add a
 units-floats guide as well.

This is the bit I'm having a few issues with as it goes :/ ClutterUnit
to ClutterUnits seems a little more complicated than I first thought
although looking through the docs it probably isn't too difficult.

 
 obviously, if somebody comes up with other topics, then feel free to
 mention them on the mailing list or open a bug; patches, as always, are
 welcome.

ClutterFixed throws out a few errors but they're pretty self explanatory
maybe a few simple notes to help could be useful.

BR,
 K

-- 
To unsubscribe send a mail to clutter+unsubscr...@o-hand.com



Re: [clutter] Guide for updating from 0.8

2009-08-10 Thread Emmanuele Bassi
On Mon, 2009-08-10 at 16:58 +0100, Karl Lattimer wrote:
 On Mon, 2009-08-10 at 16:46 +0100, Emmanuele Bassi wrote:
  On Mon, 2009-08-10 at 16:42 +0100, Karl Lattimer wrote:
  
   Is there a guide available anywhere to assist in updating code from
   clutter-0.8 to clutter-1.0?
 
  I've been looking at the rest of the changes, and was planning to add a
  units-floats guide as well.
 
 This is the bit I'm having a few issues with as it goes :/ ClutterUnit
 to ClutterUnits seems a little more complicated than I first thought
 although looking through the docs it probably isn't too difficult.

ClutterUnit has been replaced by float: ClutterUnits is now what it was
meant to be (an opaque container for logical distances and positions),
and not a pixels with a fractionary part.

all you used to do with CLUTTER_UNITS_* now you just need to replace
with operations on single precision floating point values.

the ClutterUnits struct is an opaque container that you should use to
store non-pixel values, e.g. a width in em, or a height in millimeters.
when Clutter will be able to use XSETTINGS it will queue a relayout when
the DPI of the display changes so that actors can recompute their size
using ClutterUnits.

  obviously, if somebody comes up with other topics, then feel free to
  mention them on the mailing list or open a bug; patches, as always, are
  welcome.
 
 ClutterFixed throws out a few errors but they're pretty self explanatory
 maybe a few simple notes to help could be useful.

all the ClutterFixed API suffered the same fate of the old ClutterUnit
API, with the exception that it's now part of COGL instead of having
been removed. you should only use fixed point if you measure a
difference between fixed point and floating point operations -- though
if your platform has a GPU and no FPU, then you're doing it wrong, as
the kids nowadays say.

ciao,
 Emmanuele.

-- 
Emmanuele Bassi, Senior Engineer| emmanuele.ba...@intel.com
Intel Open Source Technology Center | http://oss.intel.com

-- 
To unsubscribe send a mail to clutter+unsubscr...@o-hand.com