Fit True
Attached is ANOTHER new node: fit_true.
NodeBox has a problem with scaling. The scale node scales shapes, but does NOT scale stroke widths. So when you scale up a shape with a visible outline, the shape will get bigger but its outline will not, which can make it hard to see the outline.
I have already fixed this with my scale_true node (available for all in the Cartan Node Library). But the same problem rears its ugly head again when you use the fit node to resize a shape.
Hence my new fix: fit_true. Fit true works exactly like the fit node, but doesn't screw up the stroke widths.
The attached demo shows a 48-point gray 'a' character with a 1 point blue outline. I then resize it using a normal fit node on the left and my fit_true node on the right, resizing to fit into a 150 x 300 box.
You can see the results in the screenshot. Both characters are resized correctly but only the one on the right has the correct stroke width for the blue outline.
That's it. Simple, but very handy when you need it.
- fit_true_screenshot.png 510 KB
- fit_true_demo.ndbx.zip 5.03 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
Support Staff 1 Posted by john on 13 Dec, 2024 02:17 AM
UPDATE
I have added the ability to set a minimum and maximum stroke width when resizing paths. I also fixed a bug that could reduce horizontal or vertical lines to a single point.
The updated version of fit_true will appear in the library 3.5, which I plan to publish soon.