Code Monkey home page Code Monkey logo

Comments (2)

loonghao avatar loonghao commented on June 14, 2024

Hi @chwjshlwel ,
Thank you for your like, if you want to via JSX file to call python code you can reference this code.

In below example can help us create a menu in photoshop.

/*
// BEGIN__HARVEST_EXCEPTION_ZSTRING
<javascriptresource>
<name>pyblish</name>
<about>Pyblish for Photoshop.</about>
<category>photoshop</category>
<menu>filter</menu>
</javascriptresource>
// END__HARVEST_EXCEPTION_ZSTRING
   The item tagged "name" specifies the localized name or ZString that will be displayed in the menu
   The item tagged "menu" specifies the menu in which the command will appear: generate, automate, scripts, or filter
   The item tagged "enableinfo" specifies the conditions under which the command will be enabled. Too complex to describe here; see plugin sdk. Should usually just be "true", and your command should report a user-comprehensible error when it can't handle things. The problem with disabling the command when it's unsuitable is that there's no hint to the user as to why a command is disabled.
   The item tagged "about" specifies the localized text or ZString to be displayed in the about box for the plugin. Optional.
   The item tagged "eventid" needs to be a guaranteed unique string for your plugin. Usually generated with a UUID generator like uuidgen on MacOS
*/
{
app.system("start python your/python/file.py")
}    

another suggestion is we can use Qt create a Qt widget to deploy us scripts and use The above way to launch.

please let me know if that works for you.

from photoshop-python-api.

loonghao avatar loonghao commented on June 14, 2024

Hi @chwjshlwel I just want to confirm that is all works for you?

from photoshop-python-api.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.