Stroke Width Randomizer
Script for Adobe Illustrator
ㅤ
Description
The Stroke Width Randomizer script for Adobe Illustrator allows users to add variation to their designs by randomizing the stroke widths of selected objects within a user-defined range. The script features an interactive dialog window where users can set the minimum and maximum stroke width values in points using sliders or text input. The stroke width changes are applied in real-time, providing immediate visual feedback. Users can finalize the changes by clicking OK or cancel the adjustments by clicking Cancel, which restores the original stroke widths.
ㅤ
Installation
- Place the script file in your Adobe Illustrator Scripts folder:
MacOS: /Applications/Adobe Illustrator <Version>/Presets/<Language>/Scripts
Windows: C:\Program Files\Adobe\Adobe Illustrator <Version>\Presets\<Language>\Scripts
- Restart Adobe Illustrator to load the script into the File > Scripts menu.
- Open your document and go to File > Scripts > Stroke Width Randomizer to launch the script.
- A dialog window titled 'Stroke Width Randomizer' will appear.
ㅤ
➊ Minimum Stroke Width
The Minimum Stroke Width in the Stroke Width Randomizer script determines the smallest value (in points) that a stroke can be randomized to within the selected range. It acts as the lower boundary for the randomization process.
ㅤ
Functionality:
- When the script applies randomization to the selected objects, the stroke widths are assigned random values between the Minimum Stroke Width and the Maximum Stroke Width.
- If you set a Minimum Stroke Width of, for example, 1 pt, no stroke in the selection will have a randomized stroke width smaller than 1 pt.
ㅤ
How to use:
- 🅰 Slider: Drag the slider to adjust the minimum stroke width. The value will update dynamically in real-time.
- 🅱 Input Field: You can also type a specific value (e.g., 10 pt) into the text field. The slider will update to reflect this value.
➋ Maximum Stroke Width
The Maximum Stroke Width in the Stroke Width Randomizer script determines the largest value (in points) that a stroke can be randomized to within the selected range. It acts as the upper boundary for the randomization process.
ㅤ
Functionality:
- When the script applies randomization to the selected objects, it assigns random stroke widths between the Minimum Stroke Width and the Maximum Stroke Width.
- If you set a Maximum Stroke Width of, for example, 10 pt, no stroke in the selection will have a randomized width larger than 10 pt.
ㅤ
How to use:
- 🅰 Slider: Adjust the slider to set the maximum stroke width, and the value updates dynamically in real-time.
- 🅱 Input Field: Type a specific value (e.g., 90 pt) into the text field, and the slider will reflect this value.
ⓘ Tip: Use the Up Arrow to increase the value and the Down Arrow to decrease it. Hold Shift while pressing the arrow keys to adjust in larger increments (e.g., +10 or -10).
ㅤ
ㅤ
➌ Confirm or Cancel Changes
ㅤ
Cancel Button
The Cancel button allows you to discard any randomization changes made to the stroke widths and revert all stroke widths to their original values.
ㅤ
Functionality:
- Restores the original stroke widths of all selected objects.
- Closes the dialog window without applying any changes.
When to Use:
- If you want to undo all adjustments made during the session.
- If you accidentally opened the script or changed your mind about randomizing stroke widths.
ㅤ
OK Button
The OK button finalizes the randomization changes you’ve made to the stroke widths within the selected range.
ㅤ
Functionality:
- Confirms and applies the randomized stroke widths as displayed in real-time.
- Closes the dialog window, saving the randomized stroke widths.
When to Use:
- Once you’re satisfied with the randomized stroke widths.
- To confirm and apply the randomization to the selected objects.
ㅤ
ㅤ
➍ Additional Notes
ㅤ
- The Open Guide button in the Stroke Width Randomizer script provides quick access to the user guide for the script. It is represented as a small icon ⏼ in the dialog window’s footer.
- If no objects are selected, or if no strokes are found, an error message will prompt you to select stroked objects.
ㅤ
With this script, you can easily add variation to designs and achieve dynamic, creative effects by randomizing stroke widths across selected objects in Adobe Illustrator.
ㅤ
ㅤ