question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

large images are not scaled to stay inside diff panel

See original GitHub issue

Description

With the new image diff improvements in #2383 there’s a scenario where a large image is drawn outside the diff panel. We shouldn’t do this.

Version

GitHub Desktop version: current master e.g. 82b1d2377b98208d74aff0337c8f482cef2c1e35 OS version: Windows 10

Steps to Reproduce

  1. Clone https://github.com/shiftkey/image-examples
  2. Switch to History tab
  3. Select this commit https://github.com/shiftkey/image-examples/commit/10c1cf4d08b884f83332d8ae24e14336c5ad73df
  4. Ensure you have 2-up selected (but the others show this problem too)

Expected behavior:

  • Image does not display outside diff view.
  • Can toggle between different modes.

Actual behavior:

  • Image drawn over top menu.
  • Unable to change diff mode.

Reproduces how often: 100%

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Reactions:3
  • Comments:19 (14 by maintainers)

github_iconTop GitHub Comments

3reactions
shiftkeycommented, Jan 6, 2019

I’ve been able to reproduce this on Windows 10 and I think it’s some combination of scaling and screen real-estate.

This is the commit I’m working with (thanks @AndyThePie for the setup): https://github.com/AndyThePie/pizzaRPG-repo/commit/0233f1c56771ddf2d72f71c800d3f2ac86ef18ed

At 100% scaling on a 1440x900px display, the image diff is scaled down to fit into the space:

At 200% scaling on a 2560x1440px display, the image is no longer scaled down:

Probably requires some refreshing of what the image diff controls are rendering and whether they care about the available space…

2reactions
ChiriVulpescommented, Sep 4, 2018

I use 125% zoom and I have this issue very frequently in an image-heavy repository. It can cover the branch/fetch buttons in the changes view, and always covers the diff view options in the history view. I have to resize down to 100% to work with this repository.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Image sizing and scaling in SharePoint modern pages
Modern pages and web parts are designed to be fully responsive across devices, meaning that images used in web parts will scale differently...
Read more >
How to use Nvidia Image Scaling | Rock Paper Shotgun
Step 1: Open up Nvidia Control Panel and click “Manage 3D settings”. Under Global Settings, you should see the Image Scaling setting at...
Read more >
Keeping the Same Scale Size when Updating or Relinking to ...
How to tell InDesign to stop scaling images when the dimensions change. ... You need the scaling to remain the same. The solution...
Read more >
How to Serve Scaled Images on WordPress Website - Hostinger
Serving scaled images involves optimizing images by refitting them into the perfect size – not too small, not too large.
Read more >
Resize Images Without Losing Quality with Photoshop Smart ...
Learn how to scale and resize images in Photoshop without losing quality using smart objects! You'll learn the difference between resizing a normal...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found