[2.0.72] Sprite gets stretched when used in rich text

Post your bugs and problems so we can fix them.
User avatar
tiriscef
Fast Inserter
Fast Inserter
Posts: 102
Joined: Thu Mar 28, 2019 8:45 pm
Contact:

[2.0.72] Sprite gets stretched when used in rich text

Post by tiriscef »

I'm adding a sprite prototype that looks like this:

Code: Select all

{
    type = "sprite",
    name = "sosciencity-people",
    filename = "__sosciencity-graphics__/graphics/utility/people.png",
    size = 64
}
It's a 64x64 px sprite with some transparent whitespace around.

When I'm rendering it with rendering.draw_sprite, it looks as intended:
rendering_draw_sprite.png
rendering_draw_sprite.png (161.83 KiB) Viewed 325 times
But when I'm using the same sprite in rich text, it gets stretched and looks sad:
rich_text.png
rich_text.png (20.06 KiB) Viewed 325 times
Kind of like the transparent space got removed.
When I'm adding non-transparent pixels in every corner, it looks as intended in rich text.
Attachments
people_dots.png
people_dots.png (477 Bytes) Viewed 325 times
people.png
people.png (576 Bytes) Viewed 325 times
Post Reply

Return to “Bug Reports”