From 65d8363b61d7ca962bc4e7ff931deaca90d78d97 Mon Sep 17 00:00:00 2001 From: Sven Neumann Date: Thu, 21 Sep 2006 13:51:36 +0000 Subject: [PATCH] added align-tool (bug #356260). 2006-09-21 Sven Neumann * menus/image-menu.xml.in: added align-tool (bug #356260). * plug-ins/pygimp/plug-ins/palette-to-gradient.py * plug-ins/pygimp/plug-ins/pdbbrowse.py: prepared for translation. --- ChangeLog | 7 ++++ menus/image-menu.xml.in | 1 + .../pygimp/plug-ins/palette-to-gradient.py | 38 ++++++++++--------- plug-ins/pygimp/plug-ins/pdbbrowse.py | 9 +++-- po-python/POTFILES.in | 2 + 5 files changed, 37 insertions(+), 20 deletions(-) diff --git a/ChangeLog b/ChangeLog index e58422fca5..bf266d441f 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +2006-09-21 Sven Neumann + + * menus/image-menu.xml.in: added align-tool (bug #356260). + + * plug-ins/pygimp/plug-ins/palette-to-gradient.py + * plug-ins/pygimp/plug-ins/pdbbrowse.py: prepared for translation. + 2006-09-21 Sven Neumann * plug-ins/pygimp/plug-ins/palette-offset.py diff --git a/menus/image-menu.xml.in b/menus/image-menu.xml.in index 7ae86d8228..497ed286e9 100644 --- a/menus/image-menu.xml.in +++ b/menus/image-menu.xml.in @@ -504,6 +504,7 @@ + diff --git a/plug-ins/pygimp/plug-ins/palette-to-gradient.py b/plug-ins/pygimp/plug-ins/palette-to-gradient.py index f4f8a70e5a..9ce76c4076 100644 --- a/plug-ins/pygimp/plug-ins/palette-to-gradient.py +++ b/plug-ins/pygimp/plug-ins/palette-to-gradient.py @@ -1,5 +1,4 @@ #!/usr/bin/env python -# -*- coding: UTF-8 -*- # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -18,6 +17,7 @@ from gimpfu import * +gettext.install("gimp20-python", gimp.locale_directory, unicode=1) def make_gradient(palette, num_segments, num_colors): gradient = pdb.gimp_gradient_new(palette) @@ -43,41 +43,45 @@ def make_gradient(palette, num_segments, num_colors): def palette_to_gradient_repeating(palette): num_colors = pdb.gimp_palette_get_info(palette) num_segments = num_colors - make_gradient(palette, num_segments, num_colors) + return make_gradient(palette, num_segments, num_colors) register( "python-fu-palette-to-gradient-repeating", - "Palette to gradient.", - "Use the colors in the palette to make a new repeating gradient", + N_("Create a repeating gradient using colors from the palette"), + "Create a new repeating gradient using colors from the palette.", "Carol Spears, reproduced from previous work by Adrian Likins and Jeff Trefftz", "Carol Spears", "2006", - "Palette to _Repeating Gradient", + N_("Palette to _Repeating Gradient"), "", - [(PF_PALETTE, "palette", "Name of palette to convert", "")], - [(PF_GRADIENT, "new_gradient", "Name of the New Gradient:", "")], - palette_to_gradient_repeating, menu="") + [(PF_PALETTE, "palette", _("Palette"), "")], + [(PF_GRADIENT, "new-gradient", "Result")], + palette_to_gradient_repeating, + menu="", + domain=("gimp20-python", gimp.locale_directory) + ) def palette_to_gradient(palette): num_colors = pdb.gimp_palette_get_info(palette) num_segments = num_colors - 1 - make_gradient(palette, num_segments, num_colors) - + return make_gradient(palette, num_segments, num_colors) register( "python-fu-palette-to-gradient", - "Palette to gradient.", - "Use the colors in the palette to make a new gradient", + N_("Create a gradient using colors from the palette"), + "Create a new gradient using colors from the palette.", "Carol Spears, reproduced from previous work by Adrian Likins and Jeff Trefftz", "Carol Spears", "2006", - "Palette to _Gradient", + N_("Palette to _Gradient"), "", - [(PF_PALETTE, "palette", "Name of palette to convert", "")], - [(PF_GRADIENT, "new-gradient", "Name of the New Gradient:")], - palette_to_gradient, menu="") - + [(PF_PALETTE, "palette", _("Palette"), "")], + [(PF_GRADIENT, "new-gradient", "Result")], + palette_to_gradient, + menu="", + domain=("gimp20-python", gimp.locale_directory) + ) main () diff --git a/plug-ins/pygimp/plug-ins/pdbbrowse.py b/plug-ins/pygimp/plug-ins/pdbbrowse.py index 6786649c91..0bce35776e 100755 --- a/plug-ins/pygimp/plug-ins/pdbbrowse.py +++ b/plug-ins/pygimp/plug-ins/pdbbrowse.py @@ -34,15 +34,18 @@ def pdb_browse(): register( "python-fu-pdb-browse", - "Browse the Procedural Database", + N_("Browse the Procedural Database"), "Pick a PDB proc, and read the information", "James Henstridge", "James Henstridge", "1997-1999", - "_Procedure Browser", + N_("_Procedure Browser"), "", [], [], - pdb_browse, menu="/Xtns/Languages/Python-Fu") + pdb_browse, + menu="/Xtns/Languages/Python-Fu", + domain=("gimp20-python", gimp.locale_directory) + ) main() diff --git a/po-python/POTFILES.in b/po-python/POTFILES.in index da7406c251..f39ed383ae 100644 --- a/po-python/POTFILES.in +++ b/po-python/POTFILES.in @@ -11,3 +11,5 @@ plug-ins/pygimp/plug-ins/gtkcons.py plug-ins/pygimp/plug-ins/foggify.py plug-ins/pygimp/plug-ins/palette-offset.py plug-ins/pygimp/plug-ins/palette-sort.py +plug-ins/pygimp/plug-ins/palette-to-gradient.py +plug-ins/pygimp/plug-ins/pdbbrowse.py