linebender / linebender/resvg

Rendering of text-shadow not working correctly

Open
#996 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Rust
Stars
4.1k
Forks
348
Avg merge
1d 14h
Merged PRs (30d)
3

Description

This issue was originally raised in https://github.com/typst/svg2pdf/issues/96. Apparently, resvg does not properly handle text-shadow.

MRE:

<svg width="300" height="100" xmlns="http://www.w3.org/2000/svg">
  <style>
    .shadowed {
      font-size: 40px;
      fill: black;
      text-shadow: black 5px 5px 5px;
    }
  </style>

  <text x="50" y="50" class="shadowed">Shadow Text</text>
</svg>

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the provided SVG MRE and tracing how resvg handles the SVG text-shadow property. Done means the rendered text includes the expected black shadow with the specified 5px offsets and blur, matching the behavior described in the original svg2pdf issue.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
computer-graphics
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.