Closed Bug 178273 Opened 23 years ago Closed 23 years ago

Mis-sized file icon

Categories

(Core :: Graphics: ImageLib, defect, P2)

x86
Windows XP
defect

Tracking

()

RESOLVED FIXED
mozilla1.4alpha

People

(Reporter: matt.lee, Assigned: Biesinger)

Details

Attachments

(2 files)

When clicking a link to a document file on a website or doing a Save Target As, the dialog that appears, usually contains an icon for the particular file type. However, if the default icon size in Windows is increased to say 48x48, these icons appear garbled. I am using 1.2b
Target Milestone: --- → mozilla1.2beta
see also bug 108567
Assignee: asa → law
Component: Browser-General → File Handling
QA Contact: asa → petersen
Reporter (Matt): Can you reproduce this bug with a recent build of Mozilla (for example, 1.3a)? If so, then please comment again with details. If not, then please resolve this bug as WORKSFORME. Thanks.
Target Milestone: mozilla1.2beta → ---
I have tried this in 1.3a and the problem is not resolved. Attached a screenshot. Matt
>However, if the default icon size in Windows is increased to say 48x48 Hm, can that be done in Windows 2000 too? And if so, how?
biesi - yes, and on Windows 98 as well I think. standard icons are 32x32. in display properties (right click on desktop and choose properties is easiest), the effects tab has a checkbox for "use large icons", which gives 48x48 icons. if Windows is set to use large icons, Mozilla takes the large (48x48) icon from Windows and displays a badly-rescaled 32x32 version. I guess if the user has a high res screen and has set large icons, they would probably want the large icon in the mozilla dialog too. confirming.
Status: UNCONFIRMED → NEW
Ever confirmed: true
michaell, thanks for your tip. I can reproduce. let me investigate.
Assignee: law → cbiesinger
oh, and this is an imagelib bug really
Component: File Handling → ImageLib
sigh, this was hard to track down I have a patch, will attach in a second
Status: NEW → ASSIGNED
Priority: -- → P2
Target Milestone: --- → mozilla1.4alpha
Attachment #114135 - Flags: review?(pavlov)
Attachment #114135 - Flags: review?(pavlov) → review+
I guess I'll post the explanation about how the patch works here too: The patch consists of two parts: Firstly, the windows API is asked for a shell-sized icon (which respects the user setting) instead of a "large" icon (which seems to be always 32x32) Secondly, it fixes a bad assumption in the icon channel, which always assumed a width of 32 bit (4 byte). That holds true for all icons below 32 pixels width, because it is rounded up to a 4 byte boundary. For 48x48 icons, this needed to be fixed.
Comment on attachment 114135 [details] [diff] [review] patch sr=tor
Attachment #114135 - Flags: superreview+
Checking in win/nsIconChannel.cpp; /cvsroot/mozilla/modules/libpr0n/decoders/icon/win/nsIconChannel.cpp,v <-- nsIconChannel.cpp new revision: 1.23; previous revision: 1.22 done
Status: ASSIGNED → RESOLVED
Closed: 23 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: