[Lazarus] Virtual TreeView on Windows x64

Luiz Americo Pereira Camara luizmed at oi.com.br
Thu Aug 16 01:53:12 CEST 2012


Em 15/8/2012 09:45, Alexander Hofmann escreveu:
> Hi there.
>
> Is SVN:
> https://lazarus-ccr.svn.sourceforge.net/svnroot/lazarus-ccr/components/virtualtreeview-new/trunk/
> still the actual current repository for the Virtual TreeView component?
> In many cases I read to use the 4.8 branch to be able to compile the
> TreeView on x64 Windows,
> https://lazarus-ccr.svn.sourceforge.net/svnroot/lazarus-ccr/components/virtualtreeview-new/trunk/
>
> In particular, I was searching for a working reversion of the Virtual
> TreeView-Control for Windows x64 platforms. I found numerous bug fixes
> that should enable the Virtual TreeView to compile under that platform,
> and most advises I read was to use the 4.8 branch, which seems to be
> available under
> https://lazarus-ccr.svn.sourceforge.net/svnroot/lazarus-ccr/components/virtualtreeview-new/branches/4.8/
> ?

Yes.
In fact 4.8 is the most recent branch.

> I'm sorry for the rather dumb question here, but I think I might miss
> some points, as the 4.8 branch seems to be older than the trunk - and at
> least the 4.8 branch checked out from the URL above does not compile on
> Windows x64 on my platform (is: Lazarus 0.9.30.4 with FPC 2.6 in Windows
> 7 Ent. x64).

The VirtualTreeView from svn only supports Lazarus 1.0 or above. There's 
one version that supports 0.9.30 but does not have 64bit fixes: 
http://forum.lazarus.freepascal.org/index.php/topic,12172.msg62067.html#msg62067

Please try the Lazarus 1.0RC with 4.8 branch + LCL Extensions from svn ( 
http://code.google.com/p/luipack/source/browse/#svn%2Ftrunk%2Flclextensions 
)

If you find bugs in the above configuration, send patches through bug 
reports (one report for each issue).

I'll do a release compatible with 1.0 soon

> However, as I wanted to use the Virtual TreeView-Control and didn't see
> through all the different versions (which might be sourced in my missing
> experience with version control systems ;-)) I took todays last
> SVN-Version of 2488 and changed some parts to be able to use it.
> My patch is based on the work of Luiz Americo available at
> http://bugs.freepascal.org/view.php?id=21216 - which I applied by hand,
> as it was based on rev. 2275.
>
> Changes:
> o HasMMX-Function now returns true on all Windows x64 platforms, as I
> think all Windows-Capable CPUs with x64 instruction set support MMX
> (which might be wrong in the end, but I don't know)
> o AlphaBlend's assembler helper functions were changed to support x64
> CPUs (rather dirty Hack, but works - I also tried to use Window GDI's
> own AlphaBlend function, which worked up to some extend but resulted in
> dithered blending in the Constant-Alpha-And-Color mode, so I gave up on
> that)
> o all references to TControl.Color have been Wrapped into a small
> function checking for clDefault first to resolve the "Black Control" issue
>
> The "patch" is attached to that eMail. As I didn't know how to make a
> diff in respect to Luiz' patch, that one contains both his and my
> changes; maybe someone can help me out with that?
>
> By the way, using LCL-Extensions 0.4, Virtual TreeView of reversion 2488
> with the changes above applied seems to work fine with Lazarus 1.0 RC1
> x64, too.
>
> You may now throw Tomatoes and Eggs ;-)


Most of the above bugs are fixed, others needs more tests in 64bit.  
Assembly routines should be removed or reworked by someone that have 
such knowledge

Luiz





More information about the Lazarus mailing list