Copy link to clipboard
Copied
I'm still confuse adding gradient fill to my ellipse shape.
For now, to add e gradient to my ellipse clips, i use properties panel like below:
and how to move the gradient fill to the 'nort west' of this ellipse shape?
Hi, i have another solution. There is no 'moving gradient' when using 'Properties Panel' of shape. So, if i want to move gradient, i should use 'fx' menu on bottom of layer then choose 'gradien overlay' from there. Not from shape properties panel.
I may have found a way to do it with a Gradient Fill layer, if that is how yours was originally set up. Double-click the layer thumbnail so that the Gradient Fill dialog box opens; now you can drag the gradient to reposition it as suggested earlier. So maybe we have two solutions now, this and the Gradient Overlay layer effect.
Copy link to clipboard
Copied
When using the modal dialog one can click/drag the gradient.
Copy link to clipboard
Copied
Hi, thanks for reply,
i think there is no feature like that on gradient fill from shape properties.
i change gradient to radial, and i try to move the gradient but the shape moved.
Copy link to clipboard
Copied
One can raise the modal dialog via Script:
//opens the modal dialog for editing selected adjustment layers of some types, not all though; based on john nack’s panel;
// use it at your own risk;
if (app.documents.length > 0) {
var myDocument = app.activeDocument;
var checksOut = true;
switch (myDocument.activeLayer.kind) {
case LayerKind.CURVES:
theVars365 = 1131574899;
break;
case LayerKind.HUESATURATION:
theVars365 = 1213428850;
break;
case LayerKind.SELECTIVECOLOR:
theVars365 = 1399612227;
break;
case LayerKind.LEVELS:
theVars365 = 1282829427;
break;
case LayerKind.BLACKANDWHITE:
theVars365 = 1113681495;
break;
case LayerKind.POSTERIZE:
theVars365 = 1349743730;
break;
case LayerKind.GRADIENTMAP:
theVars365 = 1197755760;
break;
case LayerKind.CHANNELMIXER:
theVars365 = 1130917453;
break;
case LayerKind.THRESHOLD:
theVars365 = 1416131187;
break;
case LayerKind.COLORBALANCE:
theVars365 = 1131180610;
break;
case LayerKind.VIBRANCE:
theVars365 = stringIDToTypeID( "vibrance" );
break;
case LayerKind.EXPOSURE:
theVars365 = 1165521011;
break;
default:
checksOut = false;
};
// adjustment layers;
if (checksOut == true){
var id365 = theVars365;
theModalDialogue (theVars365);
}
else {
// else check for solid fill layer;
if (myDocument.activeLayer.kind == "LayerKind.SOLIDFILL" || myDocument.activeLayer.kind == "LayerKind.PATTERNFILL" || myDocument.activeLayer.kind == "LayerKind.GRADIENTFILL") {
try {
layerContentOptions()
}
catch (e) {}
}
else {
alert("selected layer is neither curves–, hue/saturation-, selective color-, levels-, black and white-, posterize-, gradient map- or threshold-adjustment layer nor a solidfill-, gradient- or pattern-layer")
}
}
};
////// modal editing //////
function theModalDialogue (theVars365) {
ErrStrs = {};
ErrStrs.USER_CANCELLED=localize("$$$/ScriptingSupport/Error/UserCancelled=User cancelled the operation");
try {
var id359 = charIDToTypeID( "setd" );
var desc77 = new ActionDescriptor();
var id360 = charIDToTypeID( "null" );
var ref48 = new ActionReference();
var id361 = stringIDToTypeID( "contentLayer" );
var id362 = charIDToTypeID( "Ordn" );
var id363 = charIDToTypeID( "Trgt" );
ref48.putEnumerated( id361, id362, id363 );
desc77.putReference( id360, ref48 );
var id364 = charIDToTypeID( "T " );
desc77.putClass( id364, id365 );
executeAction( id359, desc77, DialogModes.ALL );
}
catch(e){
if (e.toString().indexOf(ErrStrs.USER_CANCELLED)!=-1) {;
}
else{
alert("$$$/ScriptingSupport/Error/CommandNotAvailable=The command is currently not available");
}
}
};
////// edit solid fill //////
function layerContentOptions () {
var id450 = charIDToTypeID( "slct" );
var desc90 = new ActionDescriptor();
var id451 = charIDToTypeID( "null" );
var ref61 = new ActionReference();
var id452 = charIDToTypeID( "Mn " );
var id453 = charIDToTypeID( "MnIt" );
var id454 = charIDToTypeID( "AdjO" );
ref61.putEnumerated( id452, id453, id454 );
desc90.putReference( id451, ref61 );
executeAction( id450, desc90, DialogModes.ALL )
};
Copy link to clipboard
Copied
Sorry, i'm not programmer, i don't understand the script 🙂
I'm curious, i just want to adding 'Gradient Fill' to the ellipse shape, then move it. I add gradient full by using shape panel properties.
Copy link to clipboard
Copied
You don’t need to understand it, you just need to save the code as a txt-file with the extension »jsx« and put it in the Presets/Scripts-Folder.
Copy link to clipboard
Copied
Hi, i have another solution. There is no 'moving gradient' when using 'Properties Panel' of shape. So, if i want to move gradient, i should use 'fx' menu on bottom of layer then choose 'gradien overlay' from there. Not from shape properties panel.
Copy link to clipboard
Copied
I may have found a way to do it with a Gradient Fill layer, if that is how yours was originally set up. Double-click the layer thumbnail so that the Gradient Fill dialog box opens; now you can drag the gradient to reposition it as suggested earlier. So maybe we have two solutions now, this and the Gradient Overlay layer effect.
Copy link to clipboard
Copied
Excellent!
Copy link to clipboard
Copied
amazing, thanks