Apply suggestions from code review of branch fast-sim
Co-authored-by: Joe Knapper <joe.knapper@glasgow.ac.uk>
This commit is contained in:
parent
51d6bdb991
commit
0bba613a4b
1 changed files with 2 additions and 2 deletions
|
|
@ -80,8 +80,8 @@ def _downsample_shape(
|
||||||
def colour_str_to_colour(colour_str: str) -> tuple[int, int, int]:
|
def colour_str_to_colour(colour_str: str) -> tuple[int, int, int]:
|
||||||
"""Convert a colour string into RGB colour values.
|
"""Convert a colour string into RGB colour values.
|
||||||
|
|
||||||
:param colour_str: Should be a hex colour such as #33aa33 or a list separated by
|
:param colour_str: Should be a hex colour such as #33aa33 or a list of hex
|
||||||
semicolons.
|
colours separated by semicolons (with optional spaces).
|
||||||
:return: The colour as a tuple of 3 integers from 0 to 255 in value
|
:return: The colour as a tuple of 3 integers from 0 to 255 in value
|
||||||
:raises ValueError: If the hex string is not valid. This should never happen if the
|
:raises ValueError: If the hex string is not valid. This should never happen if the
|
||||||
user enters a bad colour string as the colour property setter checks the
|
user enters a bad colour string as the colour property setter checks the
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue