imagelabel - Attach text to images
Nautilus Scripts
Score 50%
Description:

This script lets you enter text to label your images. The image is extended to make space, and the text becomes part of the image.

Choose font size, background color or border, and your text. Each time you click OK on the text window, a preview will be redrawn.

When you're finished, enter either SAVE or QUIT into the text dialog.

REQUIRES:
zenity
imagemagick
kcolorchooser

Extract, then move to ~/.gnome2/nautilus-scripts

Sorry for the way the dialog windows pile up, but zenity does not allow placement :-(
Last changelog:

7 years ago

0.02 -- Better scaling of preview display. Better menus.

TheWiseDj

7 years ago

First of all, you can save time and lines using "$(whoami)" variable instead of that long line for $iam.

Ex:

my username is "killer".

echo "Hello $(whoami)"

Output: Hello killer

It's an interesting script, but is confusionary, and, moreover, you CAN'T exit!
Have you inserted some exit functions?

For example after a zenity dialog:

if [ "$?" -eq 0 ]; then
exit
fi

I suggest you to use a dialog per time:

Zenity dialog 1:
[] Change font
[] Change color
...
[] Show preview

and so on.

Report

C

marc41

7 years ago

Hey, thanks!

I didn't know about
echo "Hello $(whoami)"

As for the chain of events, I did consider asking the questions in sequence. In fact that's how it worked at first. I changed it to multiple background tasks later. This was because I found that I might want, for instance, to change the font size repeatedly without cycling through all the prompts again.

So, the last response to each dialog is remembered, and all can be changed independently and in any sequence. However, as you see, it is when clicking OK to the text input that the preview is refreshed.

The way to exit is this: Either type "save" or "quit" in the text dialog. This ends the program. Quit just cleans up and exits. Save triggers a dialog to "save-as" the resulting file.

So that's WHY it was done this way. I wish zenity would allow a multi-section dialog which could have avoided all this confusion.

Does the save/quit help? I realize now that the explanation wasn't so great.

And THANKS for the $(whoami) tip. Setting $iam manually is a habit going way back to my Unix days :-)

-- Marc

Report

C

marc41

7 years ago

No comments and no votes? Does this work for you?

Report

7 years ago

0.02 -- Better scaling of preview display. Better menus.

product-maker 8 8

File (click to download) Version Description Filetype Packagetype License Downloads Date Filesize OCS-Install DL
Details
version
0.02
updated Dec 17 2010
added Apr 20 2010
downloads today
0
page views today 4