Add suggestions from #186
This commit is contained in:
parent
b075e06d58
commit
1faaff078a
@ -747,7 +747,7 @@ class Cable(TopLevelGraphicalComponent):
|
||||
if self.show_name is None:
|
||||
self.show_name = not self.is_autogenerated
|
||||
|
||||
if not self.show_wirenumbers:
|
||||
if self.show_wirenumbers is None:
|
||||
# by default, show wire numbers for cables, hide for bundles
|
||||
self.show_wirenumbers = self.category != "bundle"
|
||||
|
||||
|
||||
@ -70,9 +70,10 @@ def expand(yaml_data):
|
||||
|
||||
|
||||
def get_single_key_and_value(d: dict):
|
||||
k = list(d.keys())[0]
|
||||
v = d[k]
|
||||
return (k, v)
|
||||
# used for defining a line in a harness' connection set
|
||||
# E.g. for the YAML input `- X1: 1`
|
||||
# this function returns a tuple in the form ("X1", "1")
|
||||
return next(iter(d.items()))
|
||||
|
||||
|
||||
def int2tuple(inp):
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user