Labels

  • float_labels (boolean, default: off) controls whether or not labels are drawn last without Z-buffer clipping so that they appear to float over the image. This setting has no effect when ray tracing.
  • label_color (color, default: -6 (front)) controls the text color of labels. By default, labels assume the front color, which is a color that has sharp contrast to the background. (i.e., white if the background is black)
  • label_font_id (integer: 1-15, default: 5) controls what font is used to draw labels.
    • label fonts 1-4: are non-scalable raster fonts
    • label fonts 5-15: are scalable vector fonts. Font 15 includes greek characters accessible via unicode.
  • label_outline_color (color, default -1) controls whether or not an outline of the indicated color is drawn around each character in order to improve contrast and readability. This setting only applies to scalable fonts.
  • label_position (vector, default: [0.0, 0.0, 1.75]) controls the position and alignment of labels in camera X, Y, and Z. Values between -1.0 and 1.0 affect alignment only, with the label attached to the atom position. Values beyond that range represent coordinate displacements. For the z dimension, values from -1 to 1 do not mean anything. Values above 1 and below -1 are offsets (minus 1 of the absolute value) in world coordinates. For example, the default 1.75 is .75 angstroms closer to the viewer.
  • label_shadow_mode (integer, default: 0) controls whether labels cast and/or catch shadows.
    • 0 = labels neither cast nor catch shadows.
    • 1 = labels catch shadows.
    • 2 = labels cast shadows.
    • 3 = labels both cast and catch shadows just like normal geometries.
  • label_size (float, default: 14.0) controls the approximate size of label text. Negative values specify label size in world coordinates (e.g., -1. will show a label 1 angstrom in height)
  • label_anchor (string, default: CA) Atom name to which default labels are attached. For example, CA=alpha carbon and CB=beta carbon.
  • label_angle_digits (integer, default: -1) controls the number of decimal places shown on angle labels. If default use value from label_digits setting.
  • label_digits (integer, default: 1) controls the number of decimal places shown on labels.
  • label_dihedral_digits (integer, default: -1) controls the number of decimal places shown on dihedral labels. If default use value from label_digits setting.
  • label_distance_digits (integer, default: -1) controls the number of decimal places shown on distance labels. If default use value from label_digits setting.
  • texture_fonts (DEPRECATED; boolean, default: off) controls whether labels are drawn using textures or bitmaps, if both choices are available.
  • label_z_target (New in 1.7)

Label Settings new in 1.7

  • label_placement_offset (vector, default: [0.0, 0.0, 0.0]) controls the position of labels in camera X, Y, and Z. This value is changed at the atom-state level when the labels are dragged with the mouse. This setting behaves similar to the label_position setting without the alignment functionality.
  • label_relative_mode (integer, default: 0) specifies whether the label is relative to the world or screen. When set to 0 labels are relative to the “world coordinates,” and will move when the camera moves. When set to 1, the labels are relative to screen coordinates, and thus will not move upon camera transformations. For screen relative values, the label_screen_point setting is used.
    • 0 = relative to the world
    • 1 = relative to the screen (label_screen_point setting values -1 to 1 is the screen range)
    • 2 = relative to the screen (label_screen_point setting values in pixels, where 0,0 is the lower left corner)
  • label_screen_point (vector, default: [0.0, 0.0, 0.0]) specifies screen placement when label_relative_mode is 1 or 2 (see above). If label_z_target is not set, the 3rd value is used for the normalized z value relative to the clipping planes (1. is on the front clipping plane, -1 is on the back clipping plane).
  • label_multiline_spacing (float, default: 1.2) controls the space between multiline labels (value is in label_size scale, e.g., 1.2 there is .2 label_size between the lines)
Line spacing set to 1.5 Line spacing set to 3.0
  • label_multiline_justification (float, default: 1.) For labels with multiple lines, this justification value controls the horizontal justification. This value is a floating point value, so it can be interpolated between the values below.
    • 1 = left justification
    • 0 = center justification
    • -1 = right justification
Left justified (1) Center Justified (0) Right Justification (-1)
  • label_padding (vector, default: [0.2, 0.2, 0.0]) controls the space between the bounds of the text and the background outline in the X and Y direction. (values are in label_size scale), 3rd value in the vector is currently not used.
Padding set to [1.2 0.8 0]
  • pick_labels (integer, default: 1) controls whether labels are picked. These work on the object or global level.
    • 0 - do not pick labels
    • 1 - pick labels
    • 2 - only pick labels (i.e., do not pick anything else)

Label Connectors (New in 1.7)

  • label_connector (boolean, default: off) controls whether or not the connector between the label and its target atom is drawn.
Label Connector OffLabel Connector On
  • label_connector_mode (integer, default: 0) controls how the connector is drawn from the label to its target atom.
    • 0 - line from target to closest corner or midpoint of label’s outline bounding box
    • 1 - line from target to center of label (stops at bounding box)
    • 2 - two lines drawn from target to lower corner of label (with bend at label_connector_ext_length distance from label)
    • 3 - line from target to closest corner or edge of label
    • 4 - same as mode #2, except that if the target is in-between the label in either dimension, a line is drawn directly perpendicular to the label
Mode 0Mode 1Mode 2
  • label_connector_color (color, default: -6) controls the color of label connector. By default, label connectors behave the same way as labels and assume the front color, which is a color that has sharp contrast to the background. (i.e., white if the background is black)
  • label_connector_width (float, default: 2.0) controls the width of the connector and background outline lines.
  • label_connector_ext_length (float, default: 2.5) controls the distance away from the label in which the two lines meet in label_connector_mode 2 and 4. This value is multiplied by the label_size.
Connector Width DefaultConnector Width = 8
  • label_bg_color (color, default: -1) controls the color of label’s background. By default, the background is not shown, but once this value is set to a value other than -1/default, the background is shown.
  • label_bg_transparency (float, default: .6) controls the transparency of the label’s background.
  • label_bg_outline (boolean, default: off) controls whether or not the label’s background outline is drawn. If set, the outline is drawn in the same color as label_connector_color.
  • ray_label_connector_flat (boolean, default: on) controls whether the connector and outline are drawn as flat geometry. If this setting is not set, then cylinders are used.
 
setting/label.txt
 
Copyright © Schrödinger, LLC. All Rights Reserved.