As for colored letters (Apply random colour from swatch group to letters individually), on other forum i find a script for Illustrator that can do this. So maybe same script could be somehow adjusted for PhotoLine as well?
var letters = app.activeDocument.textFrames[0].textRange.characters;
for (var i = 0; i < letters.length; i++) {
var x = Math.floor(Math.random() * (7 - 1)) + 1;
letters[i].fillColor = app.activeDocument.swatches[x].color;
}
var min = app.activeDocument.swatches.length - 6;
var max = app.activeDocument.swatches.length - 1;
var letters = app.activeDocument.textFrames[0].textRange.characters;
for (var i = 0; i < letters.length; i++) {
var x = Math.floor(Math.random() * (max - min + 1)) + min;
letters[i].fillColor = app.activeDocument.swatches[x].color;
}
var colorGroupName = "enter your color group name here";
var colorGroup = app.activeDocument.swatchGroups[colorGroupName].getAllSwatches();
var noOfColors = colorGroup.length;
var letters = app.activeDocument.textFrames[0].textRange.characters;
for (var i = 0; i < letters.length; i++) {
var x = Math.floor(Math.random() * noOfColors);
letters[i].fillColor = colorGroup[x].color;
}
Herbert123 hat geschrieben: Mo 15 Jun 2026 07:13
I see no benefits in adding every possible option for a wide range of contexts.
That's precisely what I already say for years…
Nur wenige wissen, wie viel man wissen muss, um zu wissen, wie wenig man weiss.
Only few know how much you have to know to know how little you know.
— Werner Heisenberg [German theoretical physicist]
Guess i find the global source of Layer Style Gradient problem. By default Gradient in any Layer Style use the size of the object, but Shadow Long (and other styles as well) expect that Gradient will be the size of Effect. So if manually change Position value of Gradient points and extend it - it start to look as expected.
This fix not perfect because manually it is impossible to set gradient start/end points and angle exactly to effect size. Also this is rather hidden and hard to find that it is possible to extend gradient like this by entering values manually. So it really needs checkbox that allow to match Gradient size and direction to Layer Style size and direction.
sh1.jpg
sh2.jpg
Du hast keine ausreichende Berechtigung, um die Dateianhänge dieses Beitrags anzusehen.
Here is illustration of same problem in Outline Outside Layer Style. By default Gradient applied to Outline Outside use object size for start and end points and fill the rest with plain color.
Screen Shot 2026-06-16 at 9.03.33 PM.jpg
Du hast keine ausreichende Berechtigung, um die Dateianhänge dieses Beitrags anzusehen.
By using multiple virtual copies and Long Shadow with different length it is possible to reproduce striped effect and also keep text editable. But i still believe that it could be much simpler and logical if it was an option to apply gradient in Long Shadow Layer Style for this.
Screen Shot 2026-06-16 at 10.23.51 PM.jpg
Du hast keine ausreichende Berechtigung, um die Dateianhänge dieses Beitrags anzusehen.
shijan hat geschrieben: Mo 15 Jun 2026 16:42
As for colored letters (Apply random colour from swatch group to letters individually), on other forum i find a script for Illustrator that can do this. So maybe same script could be somehow adjusted for PhotoLine as well?
This is an AppleScript that colorizes each letter:
tell application "PhotoLine"
try
set doc to front document
on error
set doc to missing value
end try
if doc is not missing value then
set activeLayer to active layer of doc
# Is there an active layer and the active layer is a text layer?
if (activeLayer is not missing value) and (type of activeLayer is LTText) then
# RGB colors that will be randomly set.
# Each value in the list is a list of RGB values in the range of 0 to 1
set colorList to {{1, 0, 0}, {0, 1, 0}, {0, 0, 1}}
# iterate over the complete text inside the text layer
# textRange[0]: start index of text, textRange[1]: number of characters
set textRange to text range of activeLayer
set actIndex to textRange's item 1
set endIndex to actIndex + (textRange's item 2)
repeat until actIndex ≥ endIndex
# set randomIndex to (random number from 1 to (count colorList))
set text attribute "Color" of activeLayer in range {actIndex, 1} to (some item of colorList)
set actIndex to actIndex + 1
end repeat
else
alert title "Note" message "The active layer has to be a text layer." first button "OK"
end if
end if
end tell
$pl = New-Object -ComObject PhotoLine.Application -Strict
$pl.Visible = $True
$doc = $pl.ActiveDocument
# Is there a document?
if ($null -ne $doc)
{
$activeLayer = $doc.ActiveLayer
# Is there an active layer and the active layer is a text layer?
if (($null -ne $activeLayer) -and ($activeLayer.Type -eq 4))
{
# RGB colors that will be randomly set
$colors = @(@(1, 0, 0),#red
@(0, 1, 0),#green
@(0, 0, 1)#blue
)
# iterate over the complete text inside the text layer
# $textRange[0]: start index of text, $textRange[1]: number of characters
$textRange = $activeLayer.TextRange
$actIndex = $textRange[0]
$endIndex = $textRange[0] + $textRange[1]
for ($actIndex = $textRange[0]; $actIndex -lt $endIndex; $actIndex++)
{
$randomIndex = Get-Random -Minimum 0 -Maximum $colors.Count
$activeLayer.SetAttribute(@($actIndex, 1), "Color", $colors[$randomIndex])
}
}
else
{
$pl.Alert("Attention", "The active layer has to be a text layer!", "OK")
}
}
Thanks Martin! It works but it only reads RGB values from set colorList. Sure i can add more color values there, but maybe it is possible somehow read automatically colors from specific Color palette, if simply enter palette name? I start new thread in Scripts forum area for this discussion here viewtopic.php?t=7337