Open tan-yong-sheng opened 2 years ago
You can see how to change a textbox's font in #176.
To change the direction or justification of the text you can look at the source code for text_item
, in particular the direction
and justification
functions.
This lib is COM binding, and if you want anything, please first check js reference and this js class relation mindmap If you find a class is not in this lib, try following code to define it, and on most situations it should work out of the box:
from photoshop.api._core import Photoshop as pscore
class <the classname>(pscore):
object_name = '<the classname>'
@tys203831
You can set the font using its regular name like so:
import photoshop.api as ps
app = ps.Application()
layer = app.activeDocument.layers.getByName("My Text Layer")
layer.textItem.font = app.fonts.getByName("Font Name").postScriptName
Hi I found this is a great library to automate photoshop in order to make the flow automated. However, I still feel there is some functions still lacking there.
Feature Request:
Once again, thanks so much for the team's effort to create such useful library.