Skip to content

Commit

Permalink
Change colors as per #17 review
Browse files Browse the repository at this point in the history
  • Loading branch information
aakatz3 committed Jul 16, 2020
1 parent 9cc191c commit 7ab4971
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 8 deletions.
2 changes: 1 addition & 1 deletion src/wireviz/Harness.py
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ def create_graph(self) -> Graph:
font = 'arial'
dot.attr('graph', rankdir='LR',
ranksep='2',
bgcolor='white',
bgcolor=wv_colors.default_bknd_color,
nodesep='0.33',
fontname=font)
dot.attr('node', shape='record',
Expand Down
27 changes: 20 additions & 7 deletions src/wireviz/wv_colors.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@

# Convention: Color names should be 2 letters long, to allow for multicolored wires

shield_color = '#aaaaaa:#84878c' # SN
shield_color = '#aaaaaa' # Tinned wire

_color_hex = {
'BK': '#000000',
Expand All @@ -43,13 +43,17 @@
'TQ': '#00ffff',
'BU': '#0066ff',
'VT': '#8000ff',
'BN': '#a52a2a',
'BN': '#895956',
'SL': '#708090',
# Faux-copper look, for bare CU wire
'CU': '#d6775e:#895956',
'CU': '#d6775e',
# Silvery look for tinned bare wire
'SN': '#aaaaaa:#84878c',
# Yellow-green PE wire
'SN': '#aaaaaa',
# Darker silver for silvered wire
'AG': '#84878c',
# Golden color for gold
'AU': '#ffcf80',
# Yellow-green PE wire (matching actual wire colors, should prevent confusion with a yellow-green dual color wire
'PE': '#54aa85:#f7f854:#54aa85',

This comment has been minimized.

Copy link
@kvid

kvid Jul 17, 2020

Collaborator

See request from @formatc1702 #17 (comment)

  • please remove PE since it's not a color...
}

Expand All @@ -69,6 +73,9 @@
'SL': 'slate',
'CU': 'bare copper',
'SN': 'tinned copper',
'AG': 'silver wire',
'AU': 'gold wire',
'PE': 'earth'
}

# TODO Help wanted: can someone check the german translation?
Expand All @@ -90,9 +97,15 @@
# Slate --> Schieferfarbe --> SI ??
'SL': 'si',
# Copper
'CU': 'ku',
'CU': 'cu',
# Tinned
'SN': 'si'
'SN': 'sn',

This comment has been minimized.

Copy link
@kvid

kvid Jul 17, 2020

Collaborator

See suggestion from @formatc1702 #17 (comment)

  • should be 'vz' (verzinkt) probably
# Silver
'AG': 'ag',
# Gold
'AU': 'au',
# Earth
'PE': 'pe'
}


Expand Down

2 comments on commit 7ab4971

@kvid
Copy link
Collaborator

@kvid kvid commented on 7ab4971 Jul 17, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@formatc1702 requested default_bg_color in
#17 (comment)
and I agree with him. Maybe default_bgcolor is even better?

@formatc1702
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍 to default_bgcolor

Please sign in to comment.