RSS/Atom feed Twitter
Site is read-only, email is disabled

Workflow through scripting

This discussion is connected to the gimp-user-list.gnome.org mailing list which is provided by the GIMP developers and not related to gimpusers.com.

This is a read-only list on gimpusers.com so this discussion thread is read-only, too.

5 of 5 messages available
Toggle history

Please log in to manage your subscriptions.

Workflow through scripting John Smith 02 Oct 07:24
  Workflow through scripting Ofnuts 02 Oct 08:37
   Workflow through scripting Alexandre Prokoudine 02 Oct 08:59
    Workflow through scripting Ofnuts 02 Oct 09:18
  Workflow through scripting Jan Kandziora 02 Oct 12:11
John Smith
2016-10-02 07:24:36 UTC (about 8 years ago)

Workflow through scripting

Hello you all,

Thanks for your answers. Not being a native English speaker, I am not sure my description of what I want has been very clear.

Here is an example of the work-flow I have with Photoshop and I'd like to have with the Gimp. I am NOT afraid of coding.

Cursor:

I move the cursor in the general area of where the click is needed without fussing and then, if a non-moving tool is selected (lasso, brush, stamp etc.), hitting the arrows moves the cursor 1 pixel (or 10 with a ctrl arrow, 50 with an alt arrow) allowing me to have the cursor exactly where I need it to be.

In order to do that I have to write a script that will get the information about the tool that is selected. Then I have to access the part of the application that moves the cursor.

If the Gimp doesn't allow me to move the cursor from inside, I'll have to build a tool working besides it to move the cursor when a non moving tool is selected. It is basically a listener and a Boolean so that is no big deal. What I need to know FOR CERTAIN before starting to learn the Gimp is “Can I do this with the Gimp?” Or “Am I able to ascertain which tool is selected and send the result elsewhere?”

Layers:

I have very often 500 layers (yeah, you read right, five hundred) in my images. Some of them have layer masks some don't.

I activate a layer by right-clicking in the image and choose from a list. Then I want to add a mask if there is none or activate the layer mask if there is one just by pressing the f3 key.

I can write the code to do this IF IT IS POSSIBLE, So my question is can I do things like that with the Gimp.

So you see my problem is NOT to unlearn Photoshop as someone said. I have the time and capacities to adjust a program to my needs, provided the program can send me the right information. Can I get the information needed? I meant the program knows what tool is selected or if there is a layer mask, or what layer is below my cursor. Can I have access to that information?

Cordialement,

John

http://johnsmithimages.net

2016-10-01 22:23 GMT+02:00 :

Send gimp-user-list mailing list submissions to gimp-user-list@gnome.org

To subscribe or unsubscribe via the World Wide Web, visit https://mail.gnome.org/mailman/listinfo/gimp-user-list or, via email, send a message with subject or body 'help' to gimp-user-list-request@gnome.org

You can reach the person managing the list at gimp-user-list-owner@gnome.org

When replying, please edit your Subject line so it is more specific than "Re: Contents of gimp-user-list digest..."

Today's Topics:

1. Re: Scripting, toggles and accessing the application state (Rick Strong)
2. Re: Scripting, toggles and accessing the application state (Rick Strong)
3. Suddenly can't do anything (cut, paste, draw, clear, etc) (nekomaster)
4. Suddenly can't do anything (cut, paste, draw, clear, etc) (nekomaster)
5. Re: Suddenly can't do anything (cut, paste, draw, clear, etc) (Partha Bagchi)
6. Suddenly can't do anything (cut, paste, draw, clear, etc) (nekomaster)
7. GIMP Crashing (Jennings Almond) 8. Re: GIMP Crashing (achbarrr@gmail.com)

----------------------------------------------------------------------

Message: 1 Date: Sat, 1 Oct 2016 08:51:38 -0400 From: "Rick Strong"
To: "John Smith"
Cc: gimp-user-list@gnome.org
Subject: Re: [Gimp-user] Scripting, toggles and accessing the application state
Message-ID:
Content-Type: text/plain; charset="utf-8"

I understand the technique having used Photoshop for 27 years. I have scripted Indesign, Pagemaker, Corel draw (made it draw pie charts with callouts from a simple list of data), Word, Excel. It was fun but the time I spent debugging was better put to use using the other side of my brain and being creative.

That?s just me.

Sans souci, Rick

From: John Smith
Sent: Saturday, October 01, 2016 3:16 AM To: Rick Strong
Cc: gimp-user-list@gnome.org
Subject: Re: [Gimp-user] Scripting, toggles and accessing the application state

I answer on this thread, the other one (no subject) was another mistake of my part.

So as Jan said we aren't all that fluent in typing.

My personnal reason is that I used Photoshop for 21 years now and I consider that a program should yield to its users' needs and not the other way round.

For example I need a toggle when working on an image for which I have a sketch. Sometimes I need to show the layer with the sketch, then hide it then show it then hide it to see what is on the sketch that I lost on the image I built. Pressing F8 repetitively in very rapid strokes generally do the trick. Don' forget to half close your eyes as well?

Cordialement,

John

http://johnsmithimages.net

2016-09-30 13:54 GMT+02:00 Rick Strong :

Ctrl + Z = Undo Ctrl + Y = Redo
Hold down Ctrl and do a two-finger dance to toggle.

Rick S.

Question 3) As far as I understand it, it is not possible to have toggles at the moment. Ctrl z twice will cancel 2 actions instead of undoing and redoing the last action. Am I right?

Cordialement,

John

http://johnsmithimages.net _______________________________________________ gimp-user-list mailing list
List address: gimp-user-list@gnome.org List membership: https://mail.gnome.org/mailman/listinfo/gimp-user-list List archives: https://mail.gnome.org/archives/gimp-user-list

------------------------------

Message: 2 Date: Sat, 1 Oct 2016 08:58:36 -0400 From: "Rick Strong"
To: "Simon Budig" ,
Subject: Re: [Gimp-user] Scripting, toggles and accessing the application state
Message-ID:
Content-Type: text/plain; format=flowed; charset="iso-8859-1"; reply-type=original

Another approach is to duplicate the layer you are working on and put it above the original layer. Turning the dupe layer on/off will reveal the changes.

Rick

-----Original Message----- From: Simon Budig
Sent: Friday, September 30, 2016 7:24 PM To: gimp-user-list@gnome.org
Subject: Re: [Gimp-user] Scripting, toggles and accessing the application state

Rick Strong (rnstrong@primus.ca) wrote:

Ctrl + Z = Undo
Ctrl + Y = Redo
Hold down Ctrl and do a two-finger dance to toggle.

This is unfortunately not true for german kezboards...

Bye, Simon

--
simon@budig.de http://simon.budig.de/ _______________________________________________ gimp-user-list mailing list
List address: gimp-user-list@gnome.org List membership: https://mail.gnome.org/mailman/listinfo/gimp-user-list List archives: https://mail.gnome.org/archives/gimp-user-list

------------------------------

Message: 3 Date: Sat, 01 Oct 2016 20:11:27 +0200 From: nekomaster
To: gimp-user-list@gnome.org
Cc: notifications@gimpusers.com
Subject: [Gimp-user] Suddenly can't do anything (cut, paste, draw, clear, etc)
Message-ID:
Content-Type: text/plain; charset=UTF-8

I've been using GIMP to do sprite work for Transport Tycoon, and everything was
working fine last night when I finished up with a new sprite and exported it to
PNG.

Today I get on my computer and now I can't do much of anything with GIMP.

I've tried everything I know on new images (made new in GIMP) or old images I
previously worked on and nothing works.

I tried drawing with the brush or pencil, nothing happens.

I try to select an area and I can't cut or copy the area, and if I try to paste
something it just pastes nothing/invisible things.

I'f I select an area to delete/clear, when I hit "Clear selection" or the DELETE
key, the whole layer gets deleted, even if I only selected a pixel.

All this happens whether I'm in RGB or Indexed color mode, on a old layer or a
new layer, and Reinstalling GIMP did nothing either.

Just to make sure I'm not going crazy or my keyboard or mouse is being weird, I
tried SAI, MS Paint and Paint.net to see if I can draw, cut, delete, etc and
everything works in other image editing software, jut not in GIMP.

I'm Running GIMP 2.8.18 x64 on Windows 10 Pro x64 (Build 14393)

-- nekomaster (via www.gimpusers.com/forums)

------------------------------

Message: 4 Date: Sat, 01 Oct 2016 20:13:39 +0200 From: nekomaster
To: gimp-user-list@gnome.org
Cc: notifications@gimpusers.com
Subject: [Gimp-user] Suddenly can't do anything (cut, paste, draw, clear, etc)
Message-ID:
Content-Type: text/plain; charset=UTF-8

Oh and I should mention I already tried uninstalling and reinstalling GIMP, that
didn't solve the issue.

neither did restarting my computer help, After two restarts GIMP still isn't
letting me do anything.

--
nekomaster (via www.gimpusers.com/forums)

------------------------------

Message: 5 Date: Sat, 1 Oct 2016 14:56:33 -0400 From: Partha Bagchi
To: nekomaster
Cc: "gimp-user-list@gnome.org" ,
notifications@gimpusers.com
Subject: Re: [Gimp-user] Suddenly can't do anything (cut, paste, draw, clear, etc)
Message-ID:

Content-Type: text/plain; charset=UTF-8

If I have to guess, your personal GIMP folder is corrupt. Delete or move it somewhere and restart GIMP.

Your personal folder is located at C:\Users\YourUserName\AppData\Roaming\GIMP\2.8 or it's C:\Users\YourUserName\.gimp-2.8

On Sat, Oct 1, 2016 at 2:13 PM, nekomaster wrote:

Oh and I should mention I already tried uninstalling and reinstalling GIMP, that
didn't solve the issue.

neither did restarting my computer help, After two restarts GIMP still isn't
letting me do anything.

--
nekomaster (via www.gimpusers.com/forums) _______________________________________________ gimp-user-list mailing list
List address: gimp-user-list@gnome.org List membership: https://mail.gnome.org/mailman/listinfo/gimp-user-list List archives: https://mail.gnome.org/archives/gimp-user-list

------------------------------

Message: 6 Date: Sat, 01 Oct 2016 20:59:03 +0200 From: nekomaster
To: gimp-user-list@gnome.org
Cc: notifications@gimpusers.com
Subject: [Gimp-user] Suddenly can't do anything (cut, paste, draw, clear, etc)
Message-ID:
Content-Type: text/plain; charset=UTF-8

If I have to guess, your personal GIMP folder is corrupt. Delete or move it
somewhere and restart GIMP.

Your personal folder is located at C:\Users\YourUserName\AppData\Roaming\GIMP\2.8 or it's C:\Users\YourUserName\.gimp-2.8

I went and reset my tool preferances and that seems to have fixed my problem.
Now I can draw, cut, paste, and delete again.

-- nekomaster (via www.gimpusers.com/forums)

------------------------------

Message: 7 Date: Sat, 1 Oct 2016 19:35:39 +0000 (UTC) From: Jennings Almond
To: "gimp-user-list@gnome.org"
Subject: [Gimp-user] GIMP Crashing
Message-ID:
Content-Type: text/plain; charset=UTF-8

I have GIMP 2.8 and windows 8.1. If I open more than one file and try to move one with the left-right, up-down icon, GIMP crashes. ?I thought I might "overload the 8.2 version with a more current version GIMP 8.2.16. ?It did't work. ?So, I thought I would uninstall GIMP altogether and reinstall the newer version.. ?To my unpleasant surprise, the directory still calls it a 2.8 version and when I reloaded it anew, I still had the same problems; it did not work.. I've had this problem with no other vision of GIMP.
I realize that since GIMP is free, I should not complain. ?I still have one question: When they have a program that works, why do their programmers keep fiddling with it until it does'nt work? Jennings Almond

------------------------------

Message: 8 Date: Sat, 1 Oct 2016 20:23:39 +0000 (UTC) From: achbarrr@gmail.com
To: gimp-user-list@gnome.org
Subject: Re: [Gimp-user] GIMP Crashing Message-ID:

Content-Type: text/plain; charset=UTF-8

It can happenned to all win app . you can try older version that working stable.

Dari: Jennings Almond

Terkirim: Minggu, 2 Oktober 4.45 AM

Subjek: [Gimp-user] GIMP Crashing

Kepada: gimp-user-list@gnome.org

I have GIMP 2.8 and windows 8.1. If I open more than one file and try to move one with the left-right, up-down icon, GIMP crashes. ?I thought I might "overload the 8.2 version with a more current version GIMP 8.2.16. ?It did't work. ?So, I thought I would uninstall GIMP altogether and reinstall the newer version.. ?To my unpleasant surprise, the directory still calls it a 2.8 version and when I reloaded it anew, I still had the same problems; it did not work.. I've had this problem with no other vision of GIMP. I realize that since GIMP is free, I should not complain. ?I still have one question: When they have a program that works, why do their programmers keep fiddling with it until it does'nt work? Jennings Almond _______________________________________________ gimp-user-list mailing list List address: gimp-user-list@gnome.org List membership: https://mail.gnome.org/mailman/listinfo/gimp-user-list List archives: https://mail.gnome.org/archives/gimp-user-list

------------------------------

Subject: Digest Footer

_______________________________________________ gimp-user-list mailing list
gimp-user-list@gnome.org
https://mail.gnome.org/mailman/listinfo/gimp-user-list

------------------------------

End of gimp-user-list Digest, Vol 61, Issue 2 *********************************************

Ofnuts
2016-10-02 08:37:47 UTC (about 8 years ago)

Workflow through scripting

On 02/10/16 09:24, John Smith wrote:

Here is an example of the work-flow I have with Photoshop and I'd like to have with the Gimp. I am NOT afraid of coding.

Cursor:

I move the cursor in the general area of where the click is needed without fussing and then, if a non-moving tool is selected (lasso, brush, stamp etc.), hitting the arrows moves the cursor 1 pixel (or 10 with a ctrl arrow, 50 with an alt arrow) allowing me to have the cursor exactly where I need it to be.

In order to do that I have to write a script that will get the information about the tool that is selected. Then I have to access the part of the application that moves the cursor.

Can't do. Neither cursor information nor current tool are available in the scripts (and BTW, you would also need to know the zoom factor). Scripts are meant to enhance the function, not the UI.

If the Gimp doesn't allow me to move the cursor from inside, I'll have to build a tool working besides it to move the cursor when a non moving tool is selected. It is basically a listener and a Boolean so that is no big deal. What I need to know FOR CERTAIN before starting to learn the Gimp is “Can I do this with the Gimp?” Or “Am I able to ascertain which tool is selected and send the result elsewhere?”

Not without forking Gimp and writing a lot of C code, I am afraid. The SMOP is in the eye of the person who hasn't stated coding.

Layers:

I have very often 500 layers (yeah, you read right, five hundred) in my images. Some of them have layer masks some don't.

I activate a layer by right-clicking in the image and choose from a list. Then I want to add a mask if there is none or activate the layer mask if there is one just by pressing the f3 key.

I can write the code to do this IF IT IS POSSIBLE, So my question is can I do things like that with the Gimp.

You can do *that*. You may be able to do *other things like that* (but not knowing exactly what the are, I can't answer).

So you see my problem is NOT to unlearn Photoshop as someone said. I have the time and capacities to adjust a program to my needs, provided the program can send me the right information. Can I get the information needed? I meant the program knows what tool is selected or if there is a layer mask, or what layer is below my cursor. Can I have access to that information?

Your problem is still to unlearn Photoshop. Here you are focusing on one specific task, but differences are all over the place. Gimp is not a Photoshop clone, it is an image editing application on its own right, with its own ways. You are going to spend a lot more time coding than Gimping. For what it's worth, you would not be the first to try, and there used to be a a Gimp fork called GimpShop (don't use the version you'll find of the web, since the project has been hijacked and is now mostly a vector for malware).

Maybe you should stick to Photoshop. Or maybe you should use Gimp which I have heard is somewhat easier to script, so maybe you can handle your 500 layers in very different ways if you look at the problem from a Gimp perspective.

Alexandre Prokoudine
2016-10-02 08:59:40 UTC (about 8 years ago)

Workflow through scripting

On Sun, Oct 2, 2016 at 11:37 AM, Ofnuts wrote:

So you see my problem is NOT to unlearn Photoshop as someone said. I have the time and capacities to adjust a program to my needs, provided the program can send me the right information. Can I get the information needed? I meant the program knows what tool is selected or if there is a layer mask, or what layer is below my cursor. Can I have access to that information?

Your problem is still to unlearn Photoshop. Here you are focusing on one specific task, but differences are all over the place. Gimp is not a Photoshop clone, it is an image editing application on its own right, with its own ways. You are going to spend a lot more time coding than Gimping. For what it's worth, you would not be the first to try, and there used to be a a Gimp fork called GimpShop (don't use the version you'll find of the web, since the project has been hijacked and is now mostly a vector for malware).

Maybe you should stick to Photoshop. Or maybe you should use Gimp which I have heard is somewhat easier to script, so maybe you can handle your 500 layers in very different ways if you look at the problem from a Gimp perspective.

Personally, I have a problem understanding your response.

John asked a very specific question and outlined the exact features he's missing to get his job done. No amount of unlearning Photoshop will get GIMP to send the data that he needs. Those are completely orthogonal things.

Alex

Ofnuts
2016-10-02 09:18:37 UTC (about 8 years ago)

Workflow through scripting

On 02/10/16 10:59, Alexandre Prokoudine wrote:

On Sun, Oct 2, 2016 at 11:37 AM, Ofnuts wrote:

So you see my problem is NOT to unlearn Photoshop as someone said. I have the time and capacities to adjust a program to my needs, provided the program can send me the right information. Can I get the information needed? I meant the program knows what tool is selected or if there is a layer mask, or what layer is below my cursor. Can I have access to that information?

Your problem is still to unlearn Photoshop. Here you are focusing on one specific task, but differences are all over the place. Gimp is not a Photoshop clone, it is an image editing application on its own right, with its own ways. You are going to spend a lot more time coding than Gimping. For what it's worth, you would not be the first to try, and there used to be a a Gimp fork called GimpShop (don't use the version you'll find of the web, since the project has been hijacked and is now mostly a vector for malware).

Maybe you should stick to Photoshop. Or maybe you should use Gimp which I have heard is somewhat easier to script, so maybe you can handle your 500 layers in very different ways if you look at the problem from a Gimp perspective.

Personally, I have a problem understanding your response.

John asked a very specific question and outlined the exact features he's missing to get his job done. No amount of unlearning Photoshop will get GIMP to send the data that he needs. Those are completely orthogonal things.

He needs the data because he wants to use Gimp like he uses Photoshop. Learning to use Gimp as Gimp should remove that need (and plenty of others, because IMHO the OP considerably underestimates the coding required...)

I also have the nagging thought that someone with deeply entrenched habits is doing the same thing very repetitively, which is a good target for scripting.

Jan Kandziora
2016-10-02 12:11:08 UTC (about 8 years ago)

Workflow through scripting

Am 02.10.2016 um 09:24 schrieb John Smith:

Here is an example of the work-flow I have with Photoshop and I'd like to have with the Gimp. I am NOT afraid of coding.

John, if you aren't afraid of coding, there's NOTHING you cannot add/remove/change in GIMP. It's a free software, sources are available and you can alter them yourself and compile your very own GIMP.

This isn't too simple but still a feasible approach.

The reason why the UI isn't accessible through scripting is because it haven't scratched the itch of anybody yet. The people who want UI changes very badly do patch their GIMP themselves.

Kind regards

Jan