Hi Neil,
> On May 24, 2026, at 11:34 PM, Neil <
scintil...@gmail.com> wrote:
>
> There were some more problems on current Wayland with the popups reporting a devicePixelRatioF of 2.0 when the system scale was 1.5 or 1.33. Its possible this is an initialization issue with windows not knowing an accurate scaling factor before they receive a set scale message. It was fixed by using the devicePixelRatioF of the main Scintilla window in the attached patch.
>
> Mitchell:
>
> I like the indicators that I see without the patch. Having multiple new scale-specific indicators doesn’t sound ideal.
>
> It's more likely you will be able to replace Diagonal with a single new DiagonalProportionalToDescender (or similar name) that implements a particular style of scaling diagonals. If there are different opinions on the best technique to use then there could be more than one Diagonal*.
That’s precisely what I’m concerned about. I use diagonal and squiggly indicators. They would each need their own scaled versions, possibly with more permutations. My application would have to pick an indicator based on detected scaling, etc. Right now, Qt already draws things correctly, even in my HiDPI Ubuntu 24.04 VM with 200% scaling.
> A constraint here is that downstream Windows projects have been scaling for 6 years and shouldn't have their appearance modified in ways that they may not like or want.
I think I could say my Mac project has been scaling for 6 years :) Or maybe I misunderstand your meaning.
> I increased my margin width using your new patch, but the markers remained the same, small size. Do I need to implement some sort of client-side scaling?
>
> It is likely you will have to perform some scaling yourself.
Okay, so another client-side branch based on whether or not the application is running on a HiDPI display.
> I did run into a strange issue with a Scintilla view that is normally 1 line high is now 2 lines high. However, I set the height using the SCI_TEXTHEIGHT, so I suspect Scintilla is reporting a new scaled height. Either I have to divide by two, or Scintilla (or its Qt platform) needs to do another computation somewhere.
>
> I'm not sure. There are really two scales working in the code: graphics and windowing with window coordinates not being scaled.
That’s what I was afraid of. Now I need to become an expert to know the difference between what units Scintilla’s APIs are reporting, and what units the Window toolkit is reporting.
> I would like some sort of control to disable scaling and keep the default drawing Scintilla Qt is doing on my Retina and 4K display (I assume macOS is doing 200% scaling for both). When I have time, I can enable scaling and then identify and report any issues I find, as I am now. Right now it feels like I’m going to run into a lot of small things over time rather than all at once. I’d be more comfortable with the fallback to disable and keep the current drawing.
>
> I have been working on this but scaling occurs in many places and the 'scaled' control property needs to be distributed and kept current.
I understand. It’s a hard issue with a non-zero maintenance burden.
Ultimately I will accept and adjust to whatever changes you make. I’m just offering my feedback now at this early stage for what it’s worth.
Cheers,
Mitchell