Control/ Hyperlink ...
 
Notifications
Clear all

Control/ Hyperlink Scaling

11 Posts
2 Users
1 Reactions
538 Views
(@marts4)
Active Member Registered
Joined: 3 months ago
Posts: 8
Topic starter  

Morning!

I'm having difficulty with the sizing of hyperlinks, it seems the auto-scale function isn't working on 14" laptops (where scaling by default is 150%). I find the text size, width and height are not being adjusted. To add to the matter, we need to be able to scale for vastly varying monitor sizes and scaling.

To workaround this, I've tried specifying the text size, width, and height. Though, using variables by an IF query, based on the monitor output. It's closer than leaving it with just auto-scale, but I'm still having issues getting it right. Mostly, where DesktopInfo was first launched on one monitor size and scale, then the user switches to another (without rebooting) i.e. changing duplicate to extended, closing the laptop lid when connected to a bigger monitor etc.

I've added the contents of the config file, which is largely just an adaption based upon the corporate sample.
As I've omitted the phone number and email, and particularly with the email, apreciate the uploaded version will be a different width.

Many thanks in advance!

 


   
Quote
Glenn
(@glenn)
Member Admin
Joined: 6 years ago
Posts: 1369
 

the hyperlink scaling has been an ongoing headache for a while now. there's a few threads talking about this.


   
ReplyQuote
(@marts4)
Active Member Registered
Joined: 3 months ago
Posts: 8
Topic starter  

Hi Glenn,

Appreciate that, and all your work on this great tool! I had spotted those threads, though I thought it might be a bug with 150% scaling in the latest version, as 125% appeared to be ok.

Failing that, would you say my "IF" method is the right was to go?
Is there any way to improve said method for display switching?
Despite having "display-change=1" set, it seems it's not re-calculating the IF or MONITOR variables when switching i.e. DesktopInfo loads on a small 14" laptop with 150% scaling, then the lid is closed after docking, and DesktopInfo hops to a larger monitor with 100% scaling - COMMENT's are re-sized, HYPERLINK's (probably my variables) are not.

Many thanks in advance!


   
ReplyQuote
(@marts4)
Active Member Registered
Joined: 3 months ago
Posts: 8
Topic starter  

Morning,

Did a little more testing on this, found it wasn't the auto-scale function - see attached config with auto-scale=0.

Seems the bug may be with display-change=1, and it not applying to hyperlinks?
With this config, I find a COMMENT correctly re-calculates on a display change, though a HYPERLINK does not.

Not sure there's a workaround for this (or if my config is even the right mothod of working around)?

Thanks


   
Glenn reacted
ReplyQuote
Glenn
(@glenn)
Member Admin
Joined: 6 years ago
Posts: 1369
 

Desktop Info takes notice of the following windows messages:

WM_DISPLAYCHANGE, WM_DPICHANGED, WM_SETTINGCHANGE, WM_DEVICECHANGE (WParam=DBT_CONFIGCHANGED)

if display-change=1 then a full configuration reload is performed. if display-change=0 then a display refresh is performed.

Anyway, I found a bug in the hyperlink size measurement which will have an impact on scaling. See what it looks like in the next release.


   
ReplyQuote
(@marts4)
Active Member Registered
Joined: 3 months ago
Posts: 8
Topic starter  

Thanks Glenn - I'm not sure in that case why my non auto-scale version didn't resize, but I guess that won't matter. I'll look forward to testing the next version 😀 


   
ReplyQuote
(@marts4)
Active Member Registered
Joined: 3 months ago
Posts: 8
Topic starter  

Afternoon Glenn,

Apologies for the delayed reply! To be honest, I hadn't realised you had published the update (silly me looking at the date rather than version number!) 😆 

I haven't had much luck with the newer version I'm afraid to say, here's my findings:

auto-scale=1 & display-change=1
With this on, it works well on scaling of 100% & 125%. However, it still doesn't like 150% (14" laptops). Interestingly, there's still something behind the display it's executed from. For example, executing on 150% and changing to 100% - on the 150% it starts with text too large and half off the right-hand edge, but when it gets to the 100% the scaling becomes ok. Going the other way, starting on 100% and switching to 150% is where interestingly both are ok. So it's able to scale hyperlinks that when executed on certain scales and swithcing one way, but then it's not able to do it from others going the other way. I understand the complexity behind fine tuning this!

auto-scale=0 & display-change=1
This one is interesting results too. Similarly to the above, it depends where executed from. That said, I think that's more because there's a bug (of some kind) with display-change on hyperlinks. The configs I tested here didn't rely on auto-scale, and instead used variables based on the monitor results. Whilst text and other items would correctly re-calculate upon display change, hyperlinks simply are ignored (remaining the result of the initial calculation). It may be worth noting (or at least to prove my variables work), if I end the task and execute it on any display or scale - the hyperlinks are indeed the desired size. Thus, the conclusion of the display-change potential bug 😀 

 

Again, many thanks in advance - this truely is a great tool!

 


   
ReplyQuote
Glenn
(@glenn)
Member Admin
Joined: 6 years ago
Posts: 1369
 

yeah I can see that. I'll keep tinkering...


   
ReplyQuote
(@marts4)
Active Member Registered
Joined: 3 months ago
Posts: 8
Topic starter  

Thanks Glenn, much appreciated!


   
ReplyQuote
Glenn
(@glenn)
Member Admin
Joined: 6 years ago
Posts: 1369
 

So after further tinkering I've decided to do away with the discreet hyperlink control and modify the button control so that it can behave like a hyperlink.


   
ReplyQuote
(@marts4)
Active Member Registered
Joined: 3 months ago
Posts: 8
Topic starter  

Thanks again Glenn, will give this some testing as soon as the version is published 😀 


   
ReplyQuote
Glenn's Page