Adjusted list method
@@ -34,6 +34,7 @@ def list(keywords=None, dof=None, mtype=None):
# module = importlib.import_module(
# '.' + os.path.splitext(file)[0], package='bdsim.blocks')
+ try:
table = ANSITable(
Column("class", headalign="^", colalign="<"),
Column("model", headalign="^", colalign="<"),
@@ -44,6 +45,17 @@ def list(keywords=None, dof=None, mtype=None):
Column("keywords", headalign="^", colalign="<"),
border="thin"
)
+ except UnicodeEncodeError:
+ table = ANSITable(
+ Column("class", headalign="^", colalign="<"),
+ Column("model", headalign="^", colalign="<"),
+ Column("manufacturer", headalign="^", colalign="<"),
+ Column("model type", headalign="^", colalign="<"),
+ Column("DoF", colalign="<"),
+ Column("config", colalign="<"),
+ Column("keywords", headalign="^", colalign="<"),
+ border="ascii"
+ )
if mtype is not None:
categories = [mtype]
