Skip to content
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

[BUG]: image quality issue in article viewer on lite version #1513

Open
seventyiris83 opened this issue Sep 30, 2024 · 5 comments
Open

[BUG]: image quality issue in article viewer on lite version #1513

seventyiris83 opened this issue Sep 30, 2024 · 5 comments
Assignees
Labels
Type-Defect This is BUG!!!

Comments

@seventyiris83
Copy link

seventyiris83 commented Sep 30, 2024

Brief description of the issue

when a height limit is applied to images in "Feeds & Articles -> Articles -> Limit height of all pictures", the image and attachement quality (not size) is directly tied to the size of the article previewer windowm which is unexpected behavior

when the article viewer window size is increased to the max, the image quality will be the highest it can be at the set height limit, and the more you decrease the article viewer size, the lower the quality of attachements and images get

here are comparison screenshots:

1
2
3

as highlighted in the first screenshot, when the article viewer window size is increased to the max, the quality of the images included in articles is also at max

in the second and third screenshots is the reason for this ticket, the quality of the images is decreased as the size of the article viewer window is decreased

it seems the wrapping logic is applied to the images even if they aren't being wrapped

it would be very nice if the previous behaviour (pre introduction of wrapping for lite version) could be re-instated when applying a height limit to images in articles (disabling wrapping), so it's always the original quality of the image being displayed with the image size capped to what the height limit is set to, regardless of the size of the article viewer window

How to reproduce the bug?

  1. have the latest lite build installed
  2. have any feed containing articles with images or/and attachements
  3. set a height limit in "Feeds & Articles -> Articles -> Limit height of all pictures"
  4. display an article with an image or/and attachement in the article viewer
  5. change the size of the article viewer window from maximum, tight fit for the height limit set, and minimum
  6. notice the quality be dependant on the article viewer window size (max size = max quality, min size = min quality)

What was the expected result?

i was expecting the image/attachement quality to be at maximum regardless of the size of the article viewer window size

What actually happened?

the quality of the images/attachements are dependant on the article viewer window size

Debug log

N/A

Operating system and version

  • OS: Windows 10 Pro
  • RSS Guard version: 4.7.4 Lite
@martinrotter
Copy link
Owner

Hi.

Yes, I will try to fix the actual resampling quality but note one thing.

The "lite" article viewer is technically VERY VERY limited in what it can do and what it can show. It is really really really rather text-based UI component and showing pictures, styling etc. is basic, very basic.

@martinrotter
Copy link
Owner

Well, I kind of have this:

  • note that while I do manual down-scaling of all pictures to viewport width
  • when you have limiting enabled it also limits height
  • and at the same the the component does not support "max-height" or "max-width", it can only leave pictures as they are or you can set fixed dimensions via "CSS"

So the thing is how precisely we want the "article height (or width??) limit" work. Do we want to avoid horizontal scrollbars at all cost? Do we even want to limit height of pictures? Or do we want to limit width of pictures?

@seventyiris83
Copy link
Author

seventyiris83 commented Oct 1, 2024

* and at the same the the component does not support "max-height" or "max-width", it can only leave pictures as they are or you can set fixed dimensions via "CSS"

how did the previous behavior in no web engine version where pictures seemingly retained their "max" quality but still respected the height limit work? or am i mistaken and the quality was indeed altered to fit the limit?

in my mind images and attachements, granted they being high quality to begin with, always looked "max" quality in the article viewer and never had their quality decreased, only the size of images beyond the height limit you set was decreased to respect the limit, but still looked just as sharp

So the thing is how precisely we want the "article height (or width??) limit" work. Do we want to avoid horizontal scrollbars at all cost? Do we even want to limit height of pictures? Or do we want to limit width of pictures?

the height limit setting always respects the aspect ratio of images, isn't the limit limiting both height and width at the same time even if it's labeled as height limit only?
i quite liked how it was before wrapping was introduced. i think we would indeed want to avoid horizontal scrollbars, i had and still have the height limit set to 350px for that exact reason, coupled with adjusting the size of the article viewer to tightly fit that limit results in me not seeing any horizontal bars in articles with images and attachements.

i would first have to know what exactly the no web engine behavior was, but i would suggest keeping the height limit setting as is, but:

  • when a limit is set, the previous no web engine behavior is active, no resampling or modification to the quality of the images is done, but image and attachement size is capped according to the height limit set
  • when no limit is set, current wrapping behavior is active (as it cannot apparently be improved given the limitations of the lite version from what you state:

The "lite" article viewer is technically VERY VERY limited in what it can do and what it can show. It is really really really rather text-based UI component and showing pictures, styling etc. is basic, very basic.
it can only leave pictures as they are or you can set fixed dimensions via "CSS"

would that be possible? a hybrid between previous and current behaviors depending on if a height limit is set or not

@martinrotter
Copy link
Owner

you can download some previous versions and check with git where/when changes were made

i will try to simplify the overall workflow, but honestly the lite viewer is quite on its limits

@seventyiris83
Copy link
Author

seventyiris83 commented Oct 1, 2024

So the thing is how precisely we want the "article height (or width??) limit" work. Do we want to avoid horizontal scrollbars at all cost? Do we even want to limit height of pictures? Or do we want to limit width of pictures?

i think this depends on what type of layout you have set. if you have the article viewer set horizontally, you'd want to limit the height, and if set vertically, width

maybe being able to select limiting either the height or width in the form of a dropdown menu? that would be another ticket though and a FR

you can download some previous versions and check with git where/when changes were made

i could be wrong here but i think this is where the change from previous behavior to current happened: b8f2295

overall i think dynamic wrapping should be left for the web engine version if it means keeping the original quality of images in lite version viewer. i think the previous behavior was better and would rather manually adjust the height limit of images manually when i change the article viewer window size instead of wrapping doing it for me at the cost of image quality

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type-Defect This is BUG!!!
Projects
None yet
Development

No branches or pull requests

2 participants