Understanding Colors and Styles

This How-To aims at describing how colors are used within the CS framework.

From the users point of view...

The image below explains the color codes used by the CS framework. The colors have been adopted according to this Wiki-Page, discussions amongst colleagues and taking into account LabVIEW specific features.

ColorStyles

  • white "no info available": This color is typically used, if data expected via DIM/OPC/..., but there is no data available. White is used, since this situation can not unambigiously assigned to the cases "alarm", "warning", "on", "off" or "user action required".
  • dark green "stand by/off": Indicates a state of a value or device that is o.k., but the value or device has been switched off or not yet been switched on.
  • green "on": The device or value is "on", "o.k." or in a "no error" state.
  • yellow "warning": The device or value is in a "warning" state. This could also be a pre-warning about a critical situation. This color is strictly reserved and should not be used for something else.
  • red "alarm/malfunction": The device or value is in an "error" or even in a critical state. Immediate action is required. This color is strictly reserved and should not be used for something else.
  • black "not implemented": This color is typically used for a synoptics view of an experiment or machine to indicate that a certain part is not implemented (in the control system). As an example, a "read back" or "get value" of a GUI of an device is colored black, if the device does not allow to read back the actual value.
  • blue "user action required": Does indicate, that the user has to do something here.
  • pink "important information": Yes, this color looks strange. However, it is the only color that is rather unique and not used for something else. It can be used to indicate an important information that is not a warning or an error and which does not require immediate action.
  • system/white/grey "... default": These colors are used as default colors for panel background, control elements, indicator elements and boolean buttons.

From the developers point of view...

Most of the colors have been defined withing the "UtilityLib" that is used by the CS framework.
  • Color codes are defined by the routine "UtilityLib.Sixcolor.vi".
  • States of a front panel element are defined by the typedef "UtilityLib.valueStatus.ctl".
  • Dedicated routines exist for setting the color of front panel elements "UtilityLib.set color of ....vi"
  • Please have a look at the routine "UtilityLib.GUI styles and colors example.vi". It will explain most of the conventions that are recommended.
  • In order to ease using color styles, consider calling the routine ""UtilityLib.set colors of panel to defaults.vi" as the first sub-vi of your GUI. It will try to set the colors of GUI elements to the recommended values.

Below is an example of GUI of a very funny developer.

FunnyGUI

This is the GUI after it has been started and GUI elements set to default colors.

StandardGUI

Below is the diagram of this very fancy GUI. Please note, that the standardization of the GUI has been achieved by simply calling the "set colors of panel to defaults" in the first frame.

DiagramOfStandardGUI

-- DietrichBeck - 20 Aug 2008
Topic revision: r3 - 2008-08-22, DietrichBeck
 
This site is powered by FoswikiCopyright © by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding GSI Wiki? Send feedback
Imprint (in German)
Privacy Policy (in German)