Opened 11 years ago

Closed 11 years ago

#68 closed enhancement (fixed)

Make command keywords case insensitive

Reported by: Tom Goddard Owned by: Greg Couch
Priority: minor Milestone:
Component: Command Line Version:
Keywords: Cc:
Blocked By: Blocking:
Notify when closed: Platform: all
Project: chimera

Description

Would like command keywords to be case insensitive.

Change History (5)

comment:1 by Tom Goddard, 11 years ago

Component: 3D GraphicsCommand API

comment:2 by Greg Couch, 11 years ago

Resolution: wontfix
Status: newclosed

My guess is comes from using camel-case for a keyword? Since our coding conventions (PEP8) say to not do that, and to use underscores instead, and since we don't want the user to have to press the shift key to get the underscore, the cli module maps dashes to underscores. So bgColor becomes bg_color which becomes bg-color when the user types it.

comment:3 by goddard@…, 11 years ago

I think we want “set bgcolor white” to work.  I don’t mind if “set bg-color white” works.  What will the Chimera 2 documentation say is the syntax?

comment:4 by Tom Goddard, 11 years ago

Resolution: wontfix
Status: closedreopened

Conrad, Eric, Greg and I decided that the user can type lower case with no punctuation for keywords. Case will be ignored. Also they can include punctuation (dash or underscore) that will be stripped out.

We did not figure out how to write the keywords in user documentation: "set bgColor", or "set bgcolor" or "set bg_color", or "set bg color". I'll make a separate ticket for the documentation question.

comment:5 by Greg Couch, 11 years ago

Resolution: fixed
Status: reopenedclosed

Resolved as user can type any case for keywords. And that the bg_color keyword will be shown in usage as bgColor and will be accepted regardless of case (without the underscore).

Note: See TracTickets for help on using tickets.