Page 1 of 1
add action: layer name and group color
Posted: 11 Sep 2015, 13:21
by furushil
Hello,
I want to make a button which does the following:
1. duplicate selected layers
2. merge selected layers
3. rename layer to "merged"
4. set first group color (or a specific group color)
So far I have found "duplicate selected layers" and "merge selected" but I cannot find the last two functions.
Could someone tell me how I can add them?

- button.png (16.41 KiB) Viewed 13131 times
Re: add action: layer name and group color
Posted: 14 Sep 2015, 06:51
by Elodie
It's in "Layer > Rename"

Re: add action: layer name and group color
Posted: 14 Sep 2015, 07:52
by furushil
Elodie wrote:It's in "Layer > Rename"

Thank you Elodie but if I choose that, I have to type in "merged" every time. Is there a way to have it named "merged" automatically.
It is probably very simple but I don't know anything about george script. I will try to look through the manual.
Re: add action: layer name and group color
Posted: 14 Sep 2015, 08:39
by Elodie
Oh ! ok. In that case, yes, you must use a script (but I cannot help :s)
Re: add action: layer name and group color
Posted: 15 Sep 2015, 12:55
by Mads Juul
You can use this code for the two last
Choose "Embedded George Script" in the action and paste the following code
Code: Select all
tv_LayerRename 0 "merge"
tv_layercolor "set" 0 1
read about the two george functions here
http://wiki.tvpaint.fr/index.php?title=Tv_LayerRename" onclick="window.open(this.href);return false;
and here
http://wiki.tvpaint.fr/index.php?title=Tv_LayerColor" onclick="window.open(this.href);return false;
Re: add action: layer name and group color
Posted: 15 Sep 2015, 13:46
by furushil
That's it, thank you very much!