#2 Display color code with name

closed
nobody
None
5
2011-12-04
2007-10-10
Jim DeVona
No

Includes the LDraw color code in color name strings. For example, wherever Bricksmith previously referred to the color "Red", it now refers to it as "Red: 4".

Motivations:

1. I wanted to include the actual color code in exported part reports so that other scripts could process the report and easily identify the colors. Although the code is part of the name field, it is delimited by a colon.
2. I wanted to be able to see the color codes somewhere in the interface, mainly when diddling with other LDraw software.

Initially I considered these separate objectives, but then I realized that rather than tinker with things all over the place, I could just modify nameForLDrawColor, since its value is displayed everywhere I wanted access to the color codes.

It is not a perfect solution. A separate column, both in exported part reports and relevant nib files, would surely look cleaner. This was easier.

Discussion

  • Jim DeVona
    Jim DeVona
    2007-10-10

    patch for LDrawColor.m color name with code

     
    Attachments
  • Jim DeVona
    Jim DeVona
    2007-10-10

    Logged In: YES
    user_id=542607
    Originator: YES

    File Added: LDrawColor.m.diff

     
  • Jim DeVona
    Jim DeVona
    2007-10-11

    screenshot of color panel with color codes appended to names

     
  • Jim DeVona
    Jim DeVona
    2007-10-11

    Logged In: YES
    user_id=542607
    Originator: YES

    File Added: bricksmith-patch-color-codes.png

     
  • Jim DeVona
    Jim DeVona
    2011-12-04

    • status: open --> closed