allow cost / set-icon to be displayed in body-top ONLY (#258)

previously, if you used, ie, "--cost=body-top", the cost would show in
the tab AND body-top.  Since the help text implies that the way to
accomplish this should be "--cost=tab --cost=body-top" (and because if you
put it in body-top, it's probably because you want to save space on the
tab)
This commit is contained in:
Paul Molodowitch authored and Peter committed 2019-06-02 15:09:32 -07:00
1 parent b4619bc560
commit 87a2835097
2 files changed
+54 -4

No files matched your search

+10 -4
View File
@@ -296,19 +296,19 @@ def parse_opts(cmdline_args=None):
"--cost",
action="append",
choices=LOCATION_CHOICES,
default=["tab"],
help="Where to display the card cost; may be set to "
"'hide' to indicate it should not be displayed, or "
"given multiple times to show it in multiple places.",
"given multiple times to show it in multiple places. "
"(If not given, will default to 'tab'.)",
)
group_tab.add_argument(
"--set-icon",
action="append",
choices=LOCATION_CHOICES,
default=["tab"],
help="Where to display the set icon; may be set to "
"'hide' to indicate it should not be displayed, or "
"given multiple times to show it in multiple places.",
"given multiple times to show it in multiple places. "
"(If not given, will default to 'tab'.)",
)
group_tab.add_argument(
"--no-tab-artwork",
@@ -738,6 +738,12 @@ def clean_opts(options):
print("** Warning: --tab-serpentine only valid if --tab-number > 2. **")
options.tab_serpentine = False
if options.cost is None:
options.cost = ["tab"]
if options.set_icon is None:
options.set_icon = ["tab"]
if options.sleeved_thick:
options.thickness = 3.2
options.sleeved = True