<div dir="ltr"><div dir="ltr">On Wed, Nov 11, 2020 at 3:31 PM Zoë Peterson via lazarus <<a href="mailto:lazarus@lists.lazarus-ide.org">lazarus@lists.lazarus-ide.org</a>> wrote:<br></div><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Personally I need the new behavior for any TCustomControl descendant, so <br>
I'd put most of the code in TCocoaWSCustomControl, but we have our own <br>
TUiTreeView/TUiCustomControl classes already, so I can add the extra <br>
configurability we'd need there.<br></blockquote><div>I'd suggest to address the issue in the same manner as NSCell-based vs NSView-based 

tables were.</div><div>Just add another complication condition into Cocoa-widgetset.</div><div><br></div><div>The use of NSViualEffectView cannot be hard in Cocoa, as LCL claims to support back to 10.5.8 (or at least 10.6)</div><div>(There are still some PowerPC Lazarus users)</div><div><br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
The biggest concern I'd have with it being pushed into LCL proper is <br>
that FillRect(clWindow) doesn't look right.  The NSViualEffectView <br>
changes color based on the average color of the desktop wallpaper behind <br>
the window and shifts as you move the window around, so none of the <br>
NSColors can match it.  I had to adjust our owner draw functions to not <br>
rely on drawing an opaque rectangle to clear/overwrite things, but it <br>
wasn't too bad.<br></blockquote><div><br></div><div>This is actually a LCL change, rather than Cocoa change. <br>What you might want to do is to add another Widgetset compatibility flag (TLCLCapability) to indicate on how the background of TreeView should/should not be drawn. Using fancy effects is becoming a new norm (for any platform), so it might be handy in future for others (i.e. Qt5)</div><div><br></div><div>One might argue that TLCLCapability is not the right place for that, and instead Themes class should be used.<br>I personally don't have an opinion about that.</div><div><br></div><div>After all, you're dealing with a problem that surpassed Win9x User Interface :) </div><div>Thus, it's not a surprise for LCL not to have enough information to address the problem.</div><div><br></div><div>thanks,<br>Dmitry </div></div></div>