Cannot move the debug window.

Just starting out? Need help? Post your questions and find answers here.
Stefan
Posts: 248
Joined: Mon Feb 05, 2018 9:44 pm

Cannot move the debug window.

Post by Stefan »

If I increase the system font to 125% in Windows, I can no longer move the debug window. It gets stuck on the left side.
Fred
Site Admin
Posts: 1820
Joined: Mon Feb 24, 2014 10:51 am

Re: Cannot move the debug window.

Post by Fred »

You mean in the browser ? Can you post a screenshot ? I tried here (with Windows font to 125%) in firefox, but it works as expected. Can anybody else confirm ?
Stefan
Posts: 248
Joined: Mon Feb 05, 2018 9:44 pm

Re: Cannot move the debug window.

Post by Stefan »

Yes, I mean the debugwindow in the browser.
I found the reason. I use the following code:

Code: Select all

 
  !document.body.style.zoom = 1 / window.devicePixelRatio * 100 + "%"
  !v_width=document.body.clientWidth;
  !v_height=document.body.clientHeight;

Fred
Site Admin
Posts: 1820
Joined: Mon Feb 24, 2014 10:51 am

Re: Cannot move the debug window.

Post by Fred »

As said before, this code doesn't really zoom properly, you shouldn't use it.
Stefan
Posts: 248
Joined: Mon Feb 05, 2018 9:44 pm

Re: Cannot move the debug window.

Post by Stefan »

Oh, okay, I didn't read that.
The problem is, I need a zoom because I also program for phones and tablets and the resolution on these devices is much too high.
Is there a better way to zoom in a web app?
plouf
Posts: 295
Joined: Tue Feb 25, 2014 6:01 pm
Location: Athens,Greece

Re: Cannot move the debug window.

Post by plouf »

This needed for mobile only?
You can get from deviceifnf() information if running under. Android or ios and "zoom" only there
Possible solution?
Christos
Fred
Site Admin
Posts: 1820
Joined: Mon Feb 24, 2014 10:51 am

Re: Cannot move the debug window.

Post by Fred »

I think there is a viewport tag to handle high dpi mode on mobile/tablet
Stefan
Posts: 248
Joined: Mon Feb 05, 2018 9:44 pm

Re: Cannot move the debug window.

Post by Stefan »

I don't program specifically for Android or IOS. I make a web app that will then also be used in the browser of tablets and phones.
But the resolution on phones and tablets is very high, so I zoom the screen so that it is easier to handle.
plouf
Posts: 295
Joined: Tue Feb 25, 2014 6:01 pm
Location: Athens,Greece

Re: Cannot move the debug window.

Post by plouf »

You can check also if it running in mobile browser via agent
Or you can checkscreen resolution and act accordinly
Christos
Quin
Posts: 118
Joined: Wed Nov 08, 2023 4:38 pm

Re: Cannot move the debug window.

Post by Quin »

Fred wrote: Sun Oct 20, 2024 4:05 pm I think there is a viewport tag to handle high dpi mode on mobile/tablet
Yes, something like this I think;

Code: Select all

<meta name="viewport" content="width=device-width, initial-scale=1.0">
[
Post Reply