piecepackr icon indicating copy to clipboard operation
piecepackr copied to clipboard

Add more colors for configurations returned by `game_systems()`

Open trevorld opened this issue 3 years ago • 7 comments

  • in particular "orange" and "purple" are the two missing "secondary" colors and I don't think PPN is using O or P.

trevorld avatar Feb 18 '22 18:02 trevorld

Currently we have been using the following "color-blind-friendly" palette:

colors

Currently we use the following colors from this palette:

Suit color Actual color-blind-friendly color Trade-offs
Red Vermilion
Black Black
Green Bluish-green
Blue Sky Blue Light blue not best contrast from white
Yellow Orange playing_cards_colored uses yellow stars which would look bad unless use orange or add black outlines
White White

We may want to switch to instead use:

Suit color Actual color-blind-friendly color
Red Vermilion
Black Black
Green Bluish-green
Blue Blue
Yellow Yellow Will need to adjust playing_cards_colored yellow star suit and perhaps yellow Looney Pyramids in {piecenikr} and color choice in plaintext diagrams emitted by {ppgames} and yellow gridlines/squares in boards...
White White
Purple Reddish-Purple One of five-primary hues in Munsell's color system, Purple fish suit in Four Seasons Expansion
Orange Orange Used in (sun) Decktet chips, with purple last of secondary/primary colors in RYB system, one of key rainbow colors, Leaf suit in Four Seasons Expansion
Cyan Sky blue One of five "xeon" Looney pyramids colors, Flower suit in Four Seasons Expansion, one of key (modern) rainbow colors, primary CYMK color. Note though PPN already uses "C" for "Crowns" suit

Other potential "colors" of interest that may be difficult to incorporate due to color-blindness concerns:

  • Clear (i.e. last Looney Pyramids "xeon" "color")
  • Brown
  • Gray
  • Pink
  • Light Green
  • Light purple or Magenta

Color-blindness simulator: https://www.color-blindness.com/coblis-color-blindness-simulator/

trevorld avatar Jun 15 '23 22:06 trevorld

{cli} "palettes" support the following eight colors:

  • black
  • red
  • green
  • yellow
  • blue
  • magenta
  • cyan
  • white

Note no orange and uses magenta instead of purple

trevorld avatar Aug 28 '23 21:08 trevorld

Common One Letter Color Abbreviations (i.e. for Portable Piecepack Notation):

  • RGB (red, green, blue)
  • RYB (red, yellow, blue)
  • CYMK (cyan, yellow, magenta, black)
  • ROYGBIV (red, orange, yellow, green, blue, indigo, violet)
  • (Munsell) Red, Yellow, Green, Blue, and Purple

trevorld avatar Oct 17 '24 22:10 trevorld

Could use actual yellow as yellow (instead of orange) if relevant glyphs had black outlines.

Possible workarounds to get black outlines around glyphs:

  • fontr::glpyh_polygon() (but note {fontr} not on CRAN)

  • {string2path}

  • systemfonts::glyph_outline() (currently we "Suggest" {systemfonts})

    • Not sure how well this works for glyphs with holes in them...
  • Manually create/store these glyphs in the package

  • Try to layer black open glyph on top of yellow closed glyph (e.g. black "white" chess piece on top of yellow "black" chess piece)

    • May need other compatible fonts in order to do this with numbers / letters (besides other changes to grob functions to allow this in cards)
  • Convert to bittermelon objects and add a black "glow" effect

Situations where we have relatively narrow yellow lines on white backgrounds:

  • Chess bits
  • Suit five (yellow stars) of playing_cards_colored
  • I forget if any of the piecepack configurations has a fifth yellow crowns suit or not...
  • Lined boards (first draw larger black lines and then yellow lines on top?)

trevorld avatar Feb 20 '25 07:02 trevorld