SVGs are all lower than they should be
msoucy opened this issue · 1 comments
msoucy commented
Describe the bug
Embedded SVGs are vertically lower than they should be
To Reproduce
Create the following script:
require 'squib'
require 'game_icons'
Squib::Deck.new(cards: 3) do
use_layout file: 'economy.yml'
background color: 'white'
cut_zone
safe_zone
LOVE = GameIcons.get('skoll/hearts').
recolor(fg: 'black', bg: 'white', fg_opacity: 1.0, bg_opacity: 0.0).
string
descs = [
"Here is text without an embed",
"Here is text with {l} embedded",
"{l}"
]
rect layout: :description
text layout: :description, str: descs do |embed|
embed.svg key: '{l}', width: 32, height: 32, data: LOVE
end
save format: :png
end
Run it with ruby deck.rb
Expected behavior
SVGs should be inline with text
Environment
- OS: Windows 11
- Ruby version 3.3 (also occurred with 3.2)
- Gemfile.lock: Gemfile.lock.txt
Additional context
A text string that is entirely replaced with embeds does not seem to be lowered.
Check the following:
- I have updated Squib to the latest version.
- I have checked the Squib issues backlog for something similar
- I have attempted to make a minimal script demonstrating my problem
- I have reviewed the Squib Docs and there's still a problem