Hi Mox,

Well, I'll add informations.  In fact, we need both  :

- highlight

and

- cursor implementation

Because the functions used are very similar. For highlighting, I think Sebastien, Ismael and me have finally found a solution.

What about the cursor ?

After I asked on [EMAIL PROTECTED], Philipp Lohmann and Jan Holesovsky kindly explained me the missing cursor we were searching for was implemented in vcl/source/window/cursor.cxx, exactly in ImplCursorInvert() function. In this function we can see calls to Invert. So once Invert works fine, I think it should work too for the cursor ( just guessing, and I'll try to confirm).

And readin more deeply the code inside, it does appear Ismael is right : we need to take care of all possible cases , and respect as close as possible vcl implementation. I'm ok with Ismael visoin of the implementation.

The cursor is based on Invert and they are 3 possible SAL_INVERT => let's implement them like that, and see ... What I'm finally not sure is what exactly means SAL_INVERT_TRACKFRAME ? (SAL_INVERT and SAL_INVERT_50 are obvious)

Last, I'll try the invert 50 with 50% of opacity. Not sure it works.

Mox Soini a écrit :
Hi all,

Although I haven't gone through code of all the alternative solutions,
The "CGContextSetBlendMode"
-approach seems most appealing to me, because I think we will get the best
performance from it.


Can you please propose code ? Maybe this track is interesting too ?

In fact, I'm like you : I'd have prefered implement Invert( ) and co, more "Quartzly", but this is yet not possible : we are inside and depend on everything vcl. :-/

No idea the time/energy it would take to rewrite everything, but maybe restart from scratch would be a best idea, IMHO ;)

The good thing is we now see more clear with vcl  ;-)


I think within vcl/aqua/source/ we should try to use as much native stuff
(Quartz & CG*) as possible and avoid mixing with generic OOo stuff....

I completely agree, and this is what we are doing.


Of course, we could use "::invertRect" as a fallback, if something does not
work, but is there any realistic likelihood for CGContext* not working and
still being able to successfully use "::invertRect"  ?

I guess it will be (not sure at all) on Leopard, but just for binary compatibility, and will lead to strange bugs difficult to analyse. But I can be wrong.


Eric Bachard

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to