Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add ligatures for mana costs #70

Closed
Estus-Dev opened this issue Apr 9, 2021 · 6 comments
Closed

Add ligatures for mana costs #70

Estus-Dev opened this issue Apr 9, 2021 · 6 comments
Assignees
Labels
enhancement Update to web package request User-requested change

Comments

@Estus-Dev
Copy link

Estus-Dev commented Apr 9, 2021

First off, thank you for this amazing resource. I'm using it for a prototype of something that really shouldn't work but does, and this project is helping enable that. If I decide to take the project all the way I'll be sure to send you a link.

Anyway, part of what I'm doing is displaying mana costs for cards in a context where I can only display plaintext. Right now I'm just using the unicode PUA symbols copied out of the cheatsheet for this purpose.

This works great for Lightning Bolt {R}, or Conflux {3}{W}{U}{B}{R}{G}.

I could make it work for things like Izzet Guildmage {U/R}{U/R} by putting the Izzet guild logo in its place, for my purposes that could be fine.

However, I don't know how to represent things like Norn's Annex {3}{W/P}{W/P} or Beseech the Queen {2/B}{2/B}{2/B} short of what I typed here. In the case of Phyrexian mana, I'm in a context where I can't control font color.

Is there any possibility to use ligatures or unicode combining marks or something, in order to represent cards with these hybrid/phyrexian costs? If not is there anything I can do as a developer with little/no artistic skill or font knowledge to contribute to doing so?

Hybrid Symbols I don't have a suitable replacement for:

  • {2/W}
  • {2/U}
  • {2/B}
  • {2/R}
  • {2/G}
  • {W/P}
  • {U/P}
  • {B/P}
  • {R/P}
  • {G/P}

Hybrid Guild Symbols, I can use guild logos if needed:

  • {W/U}
  • {W/B}
  • {U/B}
  • {U/R}
  • {B/R}
  • {B/G}
  • {R/B}
  • {R/W}
  • {G/W}
  • {G/U}

EDIT: Updated my wording after learning that these symbols do exist, when used in the browser with CSS.

@Estus-Dev Estus-Dev changed the title Hybrid symbols Hybrid symbols when using PUA characters Apr 25, 2021
@andrewgioia
Copy link
Owner

Thanks @AestusVitae and yes these are available with CSS classes, just not on a desktop as ligatures yet. I'd love to support them to make it much easier to type out (instead of having to manually copy them all the time) and it looks like Icomoon supports it fairly trivially.

I changed the name of this issue so we can track this specifically and should be able to get to this somewhat soon.

@andrewgioia andrewgioia self-assigned this Jul 8, 2021
@andrewgioia andrewgioia added enhancement Update to web package request User-requested change labels Jul 8, 2021
@andrewgioia andrewgioia changed the title Hybrid symbols when using PUA characters Add ligatures for mana costs Jul 8, 2021
@andrewgioia
Copy link
Owner

Rule 107.4 in the Comprehensive Rules seems to identify all of the mana costs that use this format:

107.4. The mana symbols are {W}, {U}, {B}, {R}, {G}, and {C}; the numerical symbols {0}, {1}, {2}, {3}, {4}, and so on; the variable symbol {X}; the hybrid symbols {W/U}, {W/B}, {U/B}, {U/R}, {B/R}, {B/G}, {R/G}, {R/W}, {G/W}, and {G/U}; the monocolored hybrid symbols {2/W}, {2/U}, {2/B}, {2/R}, and {2/G}; the Phyrexian mana symbols {W/P}, {U/P}, {B/P}, {R/P}, and {G/P}; and the snow mana symbol {S}.

andrewgioia added a commit that referenced this issue Jul 10, 2021
…he 2 alternate white mana symbols (#70), fixes missing Sass gradiant variable (#64 and #76), fixes Sass overwrite for kicker (#65)
@andrewgioia
Copy link
Owner

Basic ligature support added in 1.13.0. Unfortunately because of the way split symbols are handled (using 2 glyphs via CSS), ligatures are unavailable unless/until we add specific glyphs for these symbols. Currently these are supported:

  • {w}, {W}
  • {u}, {U}
  • {b}, {B}
  • {r}, {R}
  • {g}, {G}
  • {s}, {S}
  • {c}, {C}
  • {e}, {E}
  • {p}, {P}
  • {1}, {2}, . . . {20}
  • {100}
  • {100000}
  • {infinity}
  • {x}, {X}
  • {y}, {Y}
  • {z}, {Z}

@Estus-Dev
Copy link
Author

Estus-Dev commented Jul 11, 2021

That removes a large chunk of my mappings table that I'm maintaining for this project, but unfortunately doesn't solve my initial request.

Do you have any good resources for learning enough about SVGs and fonts that I could contribute those hybrid symbols myself?

@gbartholomeu
Copy link

Hi @AestusVitae, you can open the original svg provided in the repo in IcoMoon for example, download the mana svg and then draw a new font for each combination. I know it seems a lot of work, but once you have the template done, updating the following images shouldn't be much harder. I did it in my minimalist B&W proxy printing project. As you can imagine, for a B&W system, printing colored phyrexian mana is quite... impossible. So I created my own symbols for representing it.

I drew all the icons in GIMP, converted from PNG to SVG using InkScape, and uploaded the new icons to IcoMoon project. Once you do it 1-2 times you get to it without worries. Just be sure to add your icons in the end of the original SVG so you don't break the Unicode code order.

@andrewgioia andrewgioia moved this to Todo in Mana v2.0 Mar 11, 2023
@andrewgioia
Copy link
Owner

Closing this one for now as I believe we support ligatures as best as possible now.

@github-project-automation github-project-automation bot moved this from Todo to Done in Mana v2.0 Oct 31, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Update to web package request User-requested change
Projects
Status: Done
Development

No branches or pull requests

3 participants