Skip to content

Commit

Permalink
version 19.10B2
Browse files Browse the repository at this point in the history
update now "Copy IBMTTS files in an  add-on" copies the files in a new add-on. It closes #4
update english readme.
update translation strings.
update spanish translation and documentation.
  • Loading branch information
davidacm committed Oct 27, 2019
1 parent 74bb002 commit b5b5293
Show file tree
Hide file tree
Showing 6 changed files with 113 additions and 85 deletions.
77 changes: 40 additions & 37 deletions IBMTTS.pot
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: 'IBMTTS' '19.2b6'\n"
"Project-Id-Version: 'IBMTTS' '19.10B2'\n"
"Report-Msgid-Bugs-To: 'nvda-translations@freelists.org'\n"
"POT-Creation-Date: 2019-04-22 03:38-0600\n"
"POT-Creation-Date: 2019-10-27 10:20-0600\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
Expand All @@ -17,75 +17,75 @@ msgstr ""
"Content-Type: text/plain; charset=CHARSET\n"
"Content-Transfer-Encoding: 8bit\n"

#: addon\synthDrivers\_ibmeci.py:51
#: addon\synthDrivers\_ibmeci.py:61
msgid "Castilian Spanish"
msgstr ""

#: addon\synthDrivers\_ibmeci.py:52
#: addon\synthDrivers\_ibmeci.py:62
msgid "Latin American Spanish"
msgstr ""

#: addon\synthDrivers\_ibmeci.py:53
#: addon\synthDrivers\_ibmeci.py:63
msgid "Brazilian Portuguese"
msgstr ""

#: addon\synthDrivers\_ibmeci.py:54
#: addon\synthDrivers\_ibmeci.py:64
msgid "French"
msgstr ""

#: addon\synthDrivers\_ibmeci.py:55
#: addon\synthDrivers\_ibmeci.py:65
msgid "French Canadian"
msgstr ""

#: addon\synthDrivers\_ibmeci.py:56
#: addon\synthDrivers\_ibmeci.py:66
msgid "Finnish"
msgstr ""

#: addon\synthDrivers\_ibmeci.py:57
#: addon\synthDrivers\_ibmeci.py:67
msgid "Chinese"
msgstr ""

#: addon\synthDrivers\_ibmeci.py:58
#: addon\synthDrivers\_ibmeci.py:68
msgid "Japanese"
msgstr ""

#: addon\synthDrivers\_ibmeci.py:59
#: addon\synthDrivers\_ibmeci.py:69
msgid "Korean"
msgstr ""

#: addon\synthDrivers\_ibmeci.py:60
#: addon\synthDrivers\_ibmeci.py:70
msgid "German"
msgstr ""

#: addon\synthDrivers\_ibmeci.py:61
#: addon\synthDrivers\_ibmeci.py:71
msgid "Italian"
msgstr ""

#: addon\synthDrivers\_ibmeci.py:62
#: addon\synthDrivers\_ibmeci.py:72
msgid "American English"
msgstr ""

#: addon\synthDrivers\_ibmeci.py:63
#: addon\synthDrivers\_ibmeci.py:73
msgid "British English"
msgstr ""

#: addon\synthDrivers\ibmeci.py:91
#: addon\synthDrivers\ibmeci.py:100
msgid "Rate boos&t"
msgstr ""

#: addon\synthDrivers\ibmeci.py:92
#: addon\synthDrivers\ibmeci.py:102
msgid "Head Size"
msgstr ""

#: addon\synthDrivers\ibmeci.py:92
#: addon\synthDrivers\ibmeci.py:103
msgid "Roughness"
msgstr ""

#: addon\synthDrivers\ibmeci.py:92
#: addon\synthDrivers\ibmeci.py:104
msgid "Breathiness"
msgstr ""

#: addon\synthDrivers\ibmeci.py:92
#: addon\synthDrivers\ibmeci.py:105
msgid "Enable backquote voice &tags"
msgstr ""

Expand All @@ -112,8 +112,7 @@ msgstr ""
#. Translators: This is the button to copy external IBMTTS files into synth driver Add-on.
#: addon\globalPlugins\ibmtts.py:29
msgid ""
"&Copy IBMTTS files into driver add-on (may not work for some IBMTTS "
"distributions)"
"&Copy IBMTTS files in an add-on (may not work for some IBMTTS distributions)"
msgstr ""

#: addon\globalPlugins\ibmtts.py:41
Expand All @@ -136,7 +135,7 @@ msgstr ""

#. Translators: The title displayed when the IBMTTS files folder and library name have been set.
#. Translators: The title displayed when copying IBMTTS files to Add-on was successful.
#: addon\globalPlugins\ibmtts.py:54 addon\globalPlugins\ibmtts.py:101
#: addon\globalPlugins\ibmtts.py:54 addon\globalPlugins\ibmtts.py:102
msgid "Success"
msgstr ""

Expand All @@ -156,68 +155,72 @@ msgstr ""
msgid "Relative paths are not allowed."
msgstr ""

#: addon\globalPlugins\ibmtts.py:66 addon\globalPlugins\ibmtts.py:104
#: addon\globalPlugins\ibmtts.py:66 addon\globalPlugins\ibmtts.py:105
msgid "Error"
msgstr ""

#. Translators: A message to ask the user to copy IBMTTS files to Add-on folder.
#: addon\globalPlugins\ibmtts.py:69
msgid ""
"Are you sure to copy IBMTTS files to local NVDA driver Add-on? It may not "
"work in some IBMTTS distributions."
"Are you sure to copy IBMTTS files to local NVDA installation and register a "
"new add-on called \"eciLibraries\" to store the libraries? It may not work "
"in some IBMTTS distributions.\n"
"\t\tNote: after it, if you want to uninstall this add-on, you'll need to "
"uninstall two add-ons in order to delete IBMTTS files completelly from "
"NVDA. This one and \"eciLibraries\""
msgstr ""

#. Translators: The title of the Asking dialog displayed when trying to copy IBMTTS files.
#: addon\globalPlugins\ibmtts.py:71
#: addon\globalPlugins\ibmtts.py:72
msgid "Copy IBMTTS files"
msgstr ""

#. Translators: The title of the dialog presented while IBMTTS files are being copied.
#: addon\globalPlugins\ibmtts.py:75
#: addon\globalPlugins\ibmtts.py:76
msgid "Copying files"
msgstr ""

#. Translators: The message displayed while IBMTTS files are being copied.
#: addon\globalPlugins\ibmtts.py:77
#: addon\globalPlugins\ibmtts.py:78
msgid "Please wait while IBMTTS files are copied into add-on."
msgstr ""

#. Translators: a message dialog asking to retry or cancel when copying IBMTTS files.
#: addon\globalPlugins\ibmtts.py:85
#: addon\globalPlugins\ibmtts.py:86
msgid ""
"Unable to copy a file. Perhaps it is currently being used by another process "
"or you have run out of disc space on the drive you are copying to."
msgstr ""

#. Translators: the title of a retry cancel dialog when copying IBMTTS files.
#: addon\globalPlugins\ibmtts.py:87
#: addon\globalPlugins\ibmtts.py:88
msgid "Error Copying"
msgstr ""

#. Translators: The message displayed when copying IBMTTS files to Add-on was successful.
#: addon\globalPlugins\ibmtts.py:99
#: addon\globalPlugins\ibmtts.py:100
msgid ""
"Successfully copied IBMTTS files. The local copy will be used after restart "
"NVDA."
msgstr ""

#. Translators: The message displayed when errors were found while trying to copy IBMTTS files to Add-on.
#: addon\globalPlugins\ibmtts.py:104
#: addon\globalPlugins\ibmtts.py:105
msgid "Error copying IBMTTS files"
msgstr ""

#. Translators: the message shown if the driver can't find libraries during installation.
#: addon\installTasks.py:9
#: addon\installTasks.py:13
msgid ""
"The synthesizer won't be available until you set IBMTTS files. NVDA won't "
"show this synthesizer in teh synthesizers list because you need to set the "
"show this synthesizer in teh synthesizers lists because you need to set the "
"IBMTTS files location first.\n"
"\tTo do it open the NVDA settings dialog, select IBMTTS category and use the "
"\"Browse for IBMTTS library\" button to select the IBMTTS files folder.\n"
msgstr ""

#. Translators: message box when user is installing the addon in NVDA.
#: addon\installTasks.py:13
#: addon\installTasks.py:17
msgid ""
"if you are using another copy of IBMTTS or similar with a different name, "
"you should not load this driver in the same NVDA session. If you do it, NVDA "
Expand All @@ -227,7 +230,7 @@ msgid ""
msgstr ""

#. Translators: title of message box when user is installing NVDA
#: addon\installTasks.py:19
#: addon\installTasks.py:23
msgid "IBMTTS driver for NVDA"
msgstr ""

Expand Down
6 changes: 4 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,14 @@

# Installation.
Just install it as a NVDA add-on. Then open NVDA dialog settings, and set the IBMTTS folder files in the IBMTTS category.
Also in this category you can copy the external IBMTTS files into Add-on.
Please note: if the synthesizer is inside the add-on, the driver will update the ini library paths automatically. So you can use it on portable NVDA versions.
Also in this category you can copy the external IBMTTS files into an Add-on to use it locally.

# Packaging it for distribution.
Open a command line, change to the Add-on root folder and run the scons command. The created add-on, if there were no errors, is placed in the root directory.

## Notes:

* if the synthesizer is inside the add-on or in "eciLibraries" add-on, the driver will update the ini library paths automatically. So you can use it on portable NVDA versions.
* when you use the "Copy IBMTTS files in an add-on" button, it will create a new add-on. So, if you want to uninstall IBMTTS, you'll need to uninstall two add-ons: "IBMTTS driver" and "Eci libraries".
* scons and gettext tools on this project are compatible with python 3 only. Doesn't work with python 2.7.
* You can put the extra IBMTTS required files in the add-on (for personal use only). Just copy them in "addon\synthDrivers\ibmtts" folder. Adjust the default library name in "settingsDB.py" if necessary.
5 changes: 4 additions & 1 deletion addon/doc/es/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,14 @@
# Instalación.
Simplemente instálelo como cualquier otro complemento de NVDA. Después abre el diálogo de configuraciones de NVDA, y en la categoría IBMTTS establezca la ruta de los archivos de IBMTTS.
En esta categoría también puedes copiar los archivos externos de IBMTTS dentro del complemento.
Nota: si el sintetizador se encuentra dentro del complemento, el controlador actualizará las rutas del archivo ini automáticamente. Así que puedes usarlo en versiones portables de NVDA.


# Empaquetar el complemento para su distribución.
Abra una línea de comandos, cambie al directorio raíz del complemento y ejecute el comando scons. El complemento creado, si no hay errores, será puesto en la carpeta raíz del complemento.

## Notas:

* si el sintetizador está dentro de este complemento o en el complemento "eciLibraries", el controlador actualizará las rutas del archivo ini automáticamente. Así que puedes usarlo en versiones portables de NVDA.
* cuando utilice el botón "Copiar archivos IBMTTS en un add-on", creará un nuevo add-on en NVDA. Por lo tanto, si desea desinstalar IBMTTS, necesitará desinstalar dos complementos: "Controlador de IBMTTS" y "Eci libraries".
* Las herramientas scons y gettext de este proyecto son compatibles con python 3 únicamente. No funcionan en python 2.7.
* Puede agregar los archivos extra requeridos de IBMTTS dentro del complemento (para uso personal solamente). Simplemente cópielos dentro de "addon\synthDrivers\ibmtts". Ajuste el nombre de la librería por defecto en "settingsDB.py" si es necesario.
20 changes: 16 additions & 4 deletions addon/globalPlugins/ibmtts.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ def makeSettings(self, settingsSizer):
self._browseButton = sHelper.addItem (wx.Button (self, label = _("&Browse for IBMTTS library...")))
self._browseButton.Bind(wx.EVT_BUTTON, self._onBrowseClick)
# Translators: This is the button to copy external IBMTTS files into synth driver Add-on.
self._setLocalButton = sHelper.addItem (wx.Button (self, label = _("&Copy IBMTTS files into driver add-on (may not work for some IBMTTS distributions)")))
self._setLocalButton = sHelper.addItem (wx.Button (self, label = _("&Copy IBMTTS files in an add-on (may not work for some IBMTTS distributions)")))
self._setLocalButton.Bind(wx.EVT_BUTTON, self._onSetLocalClick)
self._setValues()

Expand Down Expand Up @@ -66,7 +66,8 @@ def _onSetLocalClick(self, evt):
gui.messageBox(_("Relative paths are not allowed."), _("Error"), wx.OK|wx.ICON_ERROR, self)
return
# Translators: A message to ask the user to copy IBMTTS files to Add-on folder.
if gui.messageBox(_("Are you sure to copy IBMTTS files to local NVDA driver Add-on? It may not work in some IBMTTS distributions."),
if gui.messageBox(_('''Are you sure to copy IBMTTS files to local NVDA installation and register a new add-on called "eciLibraries" to store the libraries? It may not work in some IBMTTS distributions.
Note: after it, if you want to uninstall this add-on, you'll need to uninstall two add-ons in order to delete IBMTTS files completelly from NVDA. This one and "eciLibraries"'''),
# Translators: The title of the Asking dialog displayed when trying to copy IBMTTS files.
_("Copy IBMTTS files"),
wx.YES|wx.NO|wx.ICON_QUESTION, self) == wx.YES:
Expand All @@ -92,7 +93,7 @@ def _onSetLocalClick(self, evt):
progressDialog.done()
del progressDialog
if res:
self._ttsPath.SetValue("ibmtts")
self._ttsPath.SetValue(r"..\..\eciLibraries")
# this parameter is saved even if the user doesn't click accept button.
config.conf.profiles[0]['ibmeci']['TTSPath'] = self._ttsPath.GetValue()
# Translators: The message displayed when copying IBMTTS files to Add-on was successful.
Expand All @@ -106,7 +107,7 @@ def _onSetLocalClick(self, evt):
def copyTtsFiles(self):
import installer
fp = self._ttsPath.GetValue()
tp = path.join(path.abspath(path.join(path.dirname(path.abspath(__file__)), "..")), r"synthDrivers\ibmtts")
tp = path.abspath(path.join(path.abspath(path.dirname(__file__)), r"..\..\eciLibraries"))
for curSourceDir,subDirs,files in os.walk(fp):
if curSourceDir == fp: curDestDir=tp
else:
Expand All @@ -116,6 +117,17 @@ def copyTtsFiles(self):
sourceFilePath=path.join(curSourceDir,f)
destFilePath=path.join(curDestDir,f)
installer.tryCopyFile(sourceFilePath,destFilePath)
# Create a manifest, so NVDA recognizes the folder as an add-on
with open(path.join(tp, "manifest.ini"), "w") as f:
f.write('''name = eciLibraries
summary = IBMTTS libraries
description = """You can put the libraries for IBMTTS driver here."""
author = NVDA User
version = 0.1
url = None
minimumNVDAVersion = 2012.1.1
lastTestedNVDAVersion = 2030.1.1
updateChannel = None''')

def onSave(self):
config.conf.profiles[0]['ibmeci']['dllName'] = self._dllName.GetValue()
Expand Down
Loading

0 comments on commit b5b5293

Please sign in to comment.