Skip to content

feat: logo image in pixel-perfect scaling#1

Open
denilsonsa wants to merge 1 commit intoZQuestClassic:mainfrom
denilsonsa:logo-pixel-perfect
Open

feat: logo image in pixel-perfect scaling#1
denilsonsa wants to merge 1 commit intoZQuestClassic:mainfrom
denilsonsa:logo-pixel-perfect

Conversation

@denilsonsa
Copy link

The old ZC_Logo.png was upscaled with a non-integer multiplier. This means the original pixels were scaled to regions of either 9x9, 9x10, 10x9 or 10x10 pixels.

This commit removes that PNG image and instead puts a "raw" 1x-zoom PNG image (i.e. no scaling, each pixel is one pixel).

For convenience, it also adds a bigger 8x-zoom image. I don't know why we had that older image, so I'm just guessing that 8x is large enough for the purposes it previously had.

See also: ZQuestClassic/ZQuestClassic#1004

Next steps: tackle those icon images. They have a different set of issues.

The old `ZC_Logo.png` was upscaled with a non-integer multiplier. This
means the original pixels were scaled to regions of either 9x9, 9x10,
10x9 or 10x10 pixels.

This commit removes that PNG image and instead puts a "raw" 1x-zoom PNG
image (i.e. no scaling, each pixel is one pixel).

For convenience, it also adds a bigger 8x-zoom image. I don't know why
we had that older image, so I'm just guessing that 8x is large enough
for the purposes it previously had.

See also: ZQuestClassic/ZQuestClassic#1004

Next steps: tackle those icon images. They have a different set of
issues.
denilsonsa added a commit to denilsonsa/ZQuestClassic that referenced this pull request Oct 27, 2024
The `align` attribute has been deprecated for ages, and shouldn't be used anymore.

The `width` and `height` attributes are only valid in a few tags (such as `img`) and they should be plain integers corresponding to the CSS pixel dimensions.

The dimensions listed here are based on the adjusted image I proposed in ZQuestClassic#1004 and ZQuestClassic/commons#1 . Of course we can fine-tune those dimensions if the image changes.

* https://html.spec.whatwg.org/#dimension-attributes
* https://www.w3.org/TR/html5-diff/#obsolete-attributes
* https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes
@denilsonsa
Copy link
Author

Talking about the icons, while the background shield aligns nicely to a 3x3 grid (i.e. it was perfectly scaled to 3x), the ZC letters were scaled to 4.5x, which means each exploded pixel would be either 4x4 or 5x5 square, or 4x5 or 5x4 rectangle. Ugh.

So I cleaned up the ZC letters, zoomed them up to 3x (to match the shield) and tried a few variations. Which one do you like best?

ZC_blue_x1_test1 ZC_blue_x1_test2 ZC_blue_x1_test3 ZC_blue_x1_test4

ZC_blue_x3_test1 ZC_blue_x3_test2
ZC_blue_x3_test3 ZC_blue_x3_test4

And, for comparison, here's the ZC_Icon.psd, which is in the raw 1:1 pixel scaling.

ZC_Icon_1x

I can later send a PR with the chosen variant.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant