Opened 9 years ago
Closed 7 years ago
#581 closed defect (fixed)
colornames that start with "pale" get confused with "palette"
| Reported by: | Elaine Meng | Owned by: | Greg Couch |
|---|---|---|---|
| Priority: | minor | Milestone: | 0.7 |
| Component: | Command Line | Version: | |
| Keywords: | Cc: | Tom Goddard | |
| Blocked By: | 969 | Blocking: | |
| Notify when closed: | Platform: | all | |
| Project: | ChimeraX |
Description
Colornames that start with "pale" get mixed up with the "palette" keyword of the "color" command. So although you can use other color names with spaces in them without quoting, you must either use quotes or smush the words in the colorname together. So, the first example here won't work because it tries to fetch a palette, but the others will:
color /b pale green
color /b "pale green"
color /b palegreen
I imagine it is low priority, just thought I should record this observation.
Change History (10)
comment:2 by , 9 years ago
| Cc: | added; removed |
|---|---|
| Owner: | changed from to |
According to usage, the 'palette' keyword would follow a color name. I thought color-name parsing was supposed to be "greedy", just like atom specs. If it were, it should find "pale green" as a color name before it begins to look for the "palette" keyword. Seems like a bug to me.
comment:3 by , 9 years ago
Unless the argument is a required positional argument, keywords are checked first. And optional positional arguments can be specified as a keyword argument. So the unambigious command is:
color /b color pale green
comment:4 by , 9 years ago
| Component: | Unassigned → Command Line |
|---|---|
| Milestone: | → Beta Release |
comment:5 by , 8 years ago
| Milestone: | Beta Release → Beta 2 |
|---|
comment:7 by , 8 years ago
| Milestone: | 0.6 → 0.7 |
|---|
comment:8 by , 8 years ago
Implementing #969 (color subcommands) is expected to circumvent this problem.
comment:9 by , 8 years ago
| Blocked By: | → 969 |
|---|