-
Notifications
You must be signed in to change notification settings - Fork 253
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
NodeHeight does not scale in high-dpi mode, if RootNodeCount is set before scaling happens #633
Comments
* TBaseVirtualTree.CMFontChanged() calls ChangeScale() only if the handle was already created, as ChangeScale() would create the handle * A call to ChangeScale() was moved from TBaseVirtualTree.CreateWnd() to overriden TBaseVirtualTree.ChangeScale()
The problem behind "Button2" was that scaling was performed twice: First within |
The problem behind "Button1" is that For changing the behavior of |
I tried to do an component which derives from VirtualStringTree, which shows some static text, which the user can configure at design time. Due to nodes already get set while loading the component, I have a problem on how to circumvent this. It is because I cannot see a point where I could create the nodes later. If you have some hint for me on what I am doing wrong or how this could be circumvented, it would be very much appreciated. Anyway thanks a lot for your input! See attached component: |
You should add nodes by overriding |
I understand, will do. Thanks a lot for your help again! |
* TBaseVirtualTree.CMFontChanged() calls ChangeScale() only if the handle was already created, as ChangeScale() would create the handle * A call to ChangeScale() was moved from TBaseVirtualTree.CreateWnd() to overriden TBaseVirtualTree.ChangeScale() # Conflicts: # Source/VirtualTrees.pas
See attached example project
If pressing Button1
If pressing Button2 however it works as expected: regardless whats the font size the VirtualStringTree can show about 9 nodes at once
The difference between Button1 and Button2 is the position where the RootNodeCount is set.
Projects.zip
Tested on Windows 10 (version1511), using Delphi 10.1 Berlin + Version 6.3.0 of VirtualStringTree.
The text was updated successfully, but these errors were encountered: