Label Colors
Here, as promised, is my new label_colors node.
Label_colors was designed to colorize the labels produced by my labelmaker node, but they will also work with any grouped label consisting of a container shape enclosing a textpath. In fact, it will work with any geometry object (e.g. balloons), though the results may be a bit odd.
Label_colors is to a list of labels as colorize is to a list of rects. Labels made with labelmaker will already have a uniform background color and contrasting text color. But in some situations, you may wish to assign different colors to different label containers. Or you may wish to override the contrasting colors automatically assigned by labelmaker.
Label_colors takes 7 parameters:
- Label. A geometry (group) consisting of a container shape and a textpath.
- Container Fill. The desired container fill color.
- Container Stroke. The desired container stroke color.
- Con. Stroke Width. The desired container stroke width.
- Light Text. The text color when shown against a dark background.
- Dark Text. The text color when shown against a light background.
- Cutoff Percent. The luma value cutoff point between dark and light. I find 40% works pretty well in most situations.
The attached demo shows label_colors applied to two different kinds of labels.
The bottom labels, similar to the demo for labelmaker, shows a network of labels from a Lewis Carroll poem. The original labels were uniformly colored; label_colors turns each a different shade of yellow.
The top set of labels were formed by pairing blobs with text placed by my place_label node. Unlike the first example, these labels were already differently shaped and colored. Label_colors applies a new set of colors, matching the first example, and also changes the light and dark text color assignments.
By using label_colors with my other labeling systems you can quickly experiment and coordinate colors across complex designs.
Enjoy!
-
label_colors_screenshot.png 694 KB
- label_colors_demo.ndbx.zip 70.4 KB
Keyboard shortcuts
Generic
? | Show this help |
---|---|
ESC | Blurs the current field |
Comment Form
r | Focus the comment reply box |
---|---|
^ + ↩ | Submit the comment |
You can use Command ⌘
instead of Control ^
on Mac