OSDN Git Service

Rebrand addons as add-ons in the GUI and documentation.
authorMichael Curran <mick@kulgan.net>
Tue, 8 May 2012 00:00:47 +0000 (10:00 +1000)
committerMichael Curran <mick@kulgan.net>
Tue, 8 May 2012 00:00:47 +0000 (10:00 +1000)
developerGuide.t2t
source/gui/__init__.py
source/gui/addonGui.py
user_docs/en/userGuide.t2t

index 4efcde9..1bef99c 100644 (file)
@@ -529,36 +529,36 @@ class LabelledEditField(Window):
 --- end ---\r
 ```\r
 \r
-+ Packaging  code as  NVDA Addons +\r
-To make it easy for users to share and install plugins, they can be packaged in to a single NVDA addon archive, which the user can then install into a copy of NVDA, via its Addons manager found under Tools in the NVDA menu.\r
-An addon is simply a standard zip file with the file extension of nvda-addon which contains a manifest file,  optional  install/uninstall code, and  one or more  directories containing plugins and or drivers.\r
++ Packaging  code as  NVDA Add-ons +\r
+To make it easy for users to share and install plugins, they can be packaged in to a single NVDA add-on archive, which the user can then install into a copy of NVDA, via its Add-ons manager found under Tools in the NVDA menu.\r
+An add-on is simply a standard zip file with the file extension of nvda-addon which contains a manifest file,  optional  install/uninstall code, and  one or more  directories containing plugins and or drivers.\r
 ++ Manifest files ++\r
-Each addon archive must contain a manifest file named manifest.ini.\r
-This manifest file contains key = value pares declaring such info as the addon's name, version and description.\r
+Each add-on archive must contain a manifest file named manifest.ini.\r
+This manifest file contains key = value pares declaring such info as the add-on's name, version and description.\r
 +++ Available Fields +++\r
-Although it is highly suggested that manifests contain all fields, the fields marked as manditory must be included otherwize the addon will not install.  \r
-- name: a short unique name for the addon. Used to differentiate addons internally. (Manditory)\r
-- summary: a few words describing the addon. This is shown to the user as its display name. (Manditory)\r
-- version: The version of this addon e.g. 2.0. (Manditory)\r
-- author: The author of this addon, preferably taking the form of  Full Name <email address> e.g. Michael Curran <mick@kulgan.net>. (Manditory)\r
-- description: A sentence or two describing what the addon does in more  detail.\r
-- url: a url where this addon, further info and upgrades can be found.\r
+Although it is highly suggested that manifests contain all fields, the fields marked as manditory must be included otherwize the add-on will not install.  \r
+- name: a short unique name for the add-on. Used to differentiate add-ons internally. (Manditory)\r
+- summary: a few words describing the add-on. This is shown to the user as its display name. (Manditory)\r
+- version: The version of this add-on e.g. 2.0. (Manditory)\r
+- author: The author of this add-on, preferably taking the form of  Full Name <email address> e.g. Michael Curran <mick@kulgan.net>. (Manditory)\r
+- description: A sentence or two describing what the add-on does in more  detail.\r
+- url: a url where this add-on, further info and upgrades can be found.\r
 -\r
 \r
 +++ An Example Manifest File +++\r
 ```\r
 --- start ---\r
 name = MyTestAddon\r
-summary = Cool Test Addon\r
+summary = Cool Test Add-on\r
 version = 1.0\r
-description = An example addon showing how to create addons!\r
+description = An example add-on showing how to create add-ons!\r
 author = Michael Curran <mick@kulgan.net>\r
 url = http://www.nvda-project.org/wiki/Development\r
 --- end ---\r
 ``` \r
 \r
 ++ Plugins and Drivers ++\r
-The following plugins and drivers can be included in an addon:\r
+The following plugins and drivers can be included in an add-on:\r
 - App modules: place them in an appModules directory in the archive.\r
 - Braille display drivers: place them in a brailleDisplayDrivers directory in the archive.\r
 - Global plugins: place them in a globalPlugins directory in the archive.\r
@@ -566,20 +566,20 @@ The following plugins and drivers can be included in an addon:
 -\r
 \r
 ++ Optional install / Uninstall code ++\r
-If you need to execute code as your addon is being installed or uninstalled from NVDA (for example to validate license info or to copy files to a custom location), you can provide a Python   file called installTasks.py in the archive which contains special functions that NVDA will call while installing or uninstalling your addon.\r
-This file should try to not load any modules it does not need to,  especially   Python c extensions or dlls from your own addon, as this could cause later removal of the addon to fail.\r
-However if this does happen, the addon directory will be renamed and then   deleted after the next restart of NVDA. \r
-Finally, it should also  not depend on the existance or state of other addons, as they may not be installed, or have already been removed, or are not yet initialized.\r
+If you need to execute code as your add-on is being installed or uninstalled from NVDA (for example to validate license info or to copy files to a custom location), you can provide a Python   file called installTasks.py in the archive which contains special functions that NVDA will call while installing or uninstalling your add-on.\r
+This file should try to not load any modules it does not need to,  especially   Python c extensions or dlls from your own add-on, as this could cause later removal of the add-on to fail.\r
+However if this does happen, the add-on directory will be renamed and then   deleted after the next restart of NVDA. \r
+Finally, it should also  not depend on the existance or state of other add-ons, as they may not be installed, or have already been removed, or are not yet initialized.\r
 +++ the onInstall function +++\r
-NVDA will look for and execute an onInstall function in installTasks.py after it has finished extracting the addon in to NVDA. \r
-Note that although the addon is extracted at this time, its directory has a .pendingInstall suffix until NVDA is restarted and the directory is renamed and the addon is really loaded for the first time.\r
+NVDA will look for and execute an onInstall function in installTasks.py after it has finished extracting the add-on in to NVDA. \r
+Note that although the add-on is extracted at this time, its directory has a .pendingInstall suffix until NVDA is restarted and the directory is renamed and the add-on is really loaded for the first time.\r
 If this function raises an exception, the installation will fail and its directory will be cleaned up.\r
 +++ The onUninstall Function +++\r
-NVDA will look for and execute an onUninstall function in installTasks.py when NVDA is restarted after the user has chosen to remove the addon.\r
-After this function completes, the addon's directory will automatically be removed.\r
+NVDA will look for and execute an onUninstall function in installTasks.py when NVDA is restarted after the user has chosen to remove the add-on.\r
+After this function completes, the add-on's directory will automatically be removed.\r
 As this happens on NVDA startup before other components are initialized, this function cannot request input from the user.\r
-++ Localizing Addons ++\r
-It is possible to provide locale-specific info and messages for your addon.\r
+++ Localizing Add-ons ++\r
+It is possible to provide locale-specific info and messages for your add-on.\r
 Locale information can be stored in a locale directory in the archive.\r
 This directory should contain directories for each language it supports, using the same language name format as the rest of NVDA (e.g. en for English, fr_CA for French Canadian).\r
 +++ Locale-specific Manifest Files +++\r
@@ -588,7 +588,7 @@ These fields are summary, and description.
 All other fields will be ignored.\r
 +++ Locale-specific Messages +++\r
 Each language directory can also contain gettext information, which is the system used to translate the rest of NVDA's user interface and reported messages. As like the rest of NVDA, an nvda.mo compiled gettext database file should be placed in the LC_MESSAGES directory within this directory.\r
-to allow plugins in your addon to access gettext message information via calls to _(), at the top of each file its necessary to initialize  translations by calling addonHandler.initTranslations() \r
+to allow plugins in your add-on to access gettext message information via calls to _(), at the top of each file its necessary to initialize  translations by calling addonHandler.initTranslations() \r
 For more information about gettext and NVDA translation in general, please read\r
 http://www.nvda-project.org/wiki/TranslatingNVDA\r
  \r
index d89533a..621e23d 100644 (file)
@@ -315,7 +315,7 @@ class SysTrayIcon(wx.TaskBarIcon):
                if not globalVars.appArgs.secure:\r
                        item = menu_tools.Append(wx.ID_ANY, _("Python console"))\r
                        self.Bind(wx.EVT_MENU, frame.onPythonConsoleCommand, item)\r
-                       item = menu_tools.Append(wx.ID_ANY, _("Addons Manager"))\r
+                       item = menu_tools.Append(wx.ID_ANY, _("Add-ons Manager"))\r
                        self.Bind(wx.EVT_MENU, frame.onAddonsManagerCommand, item)\r
                if not globalVars.appArgs.secure and getattr(sys,'frozen',None):\r
                        item = menu_tools.Append(wx.ID_ANY, _("Create Portable copy..."))\r
index d3bd362..f53f08d 100644 (file)
@@ -8,13 +8,13 @@ class AddonsDialog(wx.Dialog):
 \r
        def __init__(self,parent):\r
                # Translators: The title of the Addons Dialog\r
-               super(AddonsDialog,self).__init__(parent,title=_("Addons Manager"))\r
+               super(AddonsDialog,self).__init__(parent,title=_("Add-ons Manager"))\r
                self.needsRestart=False\r
                mainSizer=wx.BoxSizer(wx.VERTICAL)\r
                settingsSizer=wx.BoxSizer(wx.VERTICAL)\r
                entriesSizer=wx.BoxSizer(wx.VERTICAL)\r
                # Translators: the label for the installed addons list in the addons manager.\r
-               entriesLabel=wx.StaticText(self,-1,label=_("&Installed Addons"))\r
+               entriesLabel=wx.StaticText(self,-1,label=_("&Installed Add-ons"))\r
                entriesSizer.Add(entriesLabel)\r
                self.addonsList=wx.ListCtrl(self,-1,style=wx.LC_REPORT|wx.LC_SINGLE_SEL,size=(550,350))\r
                self.addonsList.InsertColumn(0,_("Status"),width=50)\r
@@ -26,7 +26,7 @@ class AddonsDialog(wx.Dialog):
                settingsSizer.Add(entriesSizer)\r
                entryButtonsSizer=wx.BoxSizer(wx.HORIZONTAL)\r
                aboutButtonID=wx.NewId()\r
-               self.aboutButton=wx.Button(self,aboutButtonID,_("&About Addon..."),wx.DefaultPosition)\r
+               self.aboutButton=wx.Button(self,aboutButtonID,_("&About Add-on..."),wx.DefaultPosition)\r
                self.aboutButton.Disable()\r
                self.Bind(wx.EVT_BUTTON,self.onAbout,id=aboutButtonID)\r
                entryButtonsSizer.Add(self.aboutButton)\r
@@ -52,7 +52,7 @@ class AddonsDialog(wx.Dialog):
 \r
        def OnAddClick(self,evt):\r
                # Translators: The message displayed in the dialog that allows you to choose an addon bundle for installation.\r
-               fd=wx.FileDialog(self,message=_("Choose Addon bundle file"),\r
+               fd=wx.FileDialog(self,message=_("Choose Add-on bundle file"),\r
                # Translators: the label for the nvda adon file type in the Choose addon dialog.\r
                wildcard=(_("NVDA Addon Bundle (*.{ext})")+"|*.{ext}").format(ext=addonHandler.BUNDLE_EXTENSION),\r
                defaultDir="c:",style=wx.FD_OPEN)\r
@@ -64,30 +64,30 @@ class AddonsDialog(wx.Dialog):
                except:\r
                        log.error("Error opening addon bundle from %s"%addonPath,exc_info=True)\r
                        # Translators: The message displayed when an error occurs when opening an addon bundle for adding. \r
-                       gui.messageBox(_("Failed to open addon bundle file at %s - missing file or invalid file format")%addonPath,\r
+                       gui.messageBox(_("Failed to open add-on bundle file at %s - missing file or invalid file format")%addonPath,\r
                                # Translators: The title of a dialog presented when an error occurs.\r
                                _("Error"),\r
                                wx.OK | wx.ICON_ERROR)\r
                        return\r
                # Translators: A message asking the user if they really wish to install an addon.\r
-               if gui.messageBox(_("Are you sure you want to install this addon? Only install addons from trusted sources.\nAddon: {summary} {version}\nAuthor: {author}").format(**bundle.manifest),\r
+               if gui.messageBox(_("Are you sure you want to install this add-on? Only install add-ons from trusted sources.\nAddon: {summary} {version}\nAuthor: {author}").format(**bundle.manifest),\r
                        # Translators: Title for message asking if the user really wishes to install an Addon.\r
-                       _("Addon Installation"),\r
+                       _("Add-on Installation"),\r
                        wx.YES|wx.NO|wx.ICON_WARNING)!=wx.YES:\r
                        return\r
                bundleName=bundle.manifest['name']\r
                if any(bundleName==addon.manifest['name'] for addon in self.curAddons if not addon.isPendingRemove):\r
                        # Translators: The message displayed when an an addon already seems to be installed. \r
-                       gui.messageBox(_("This addon seems to already be installed. Please remove the existing addon and try again."),\r
+                       gui.messageBox(_("This add-on seems to already be installed. Please remove the existing add-on and try again."),\r
                                # Translators: The title of a dialog presented when an error occurs.\r
                                _("Error"),\r
                                wx.OK | wx.ICON_WARNING)\r
                        return\r
                progressDialog = gui.IndeterminateProgressDialog(gui.mainFrame,\r
                # Translators: The title of the dialog presented while an Addon is being installed.\r
-               _("Installing Addon"),\r
+               _("Installing Add-on"),\r
                # Translators: The message displayed while an addon is being installed.\r
-               _("Please wait while the addon is being installed."))\r
+               _("Please wait while the add-on is being installed."))\r
                try:\r
                        gui.ExecAndPump(addonHandler.installAddonBundle,bundle)\r
                        self.needsRestart=True\r
@@ -97,7 +97,7 @@ class AddonsDialog(wx.Dialog):
                        progressDialog.done()\r
                        del progressDialog\r
                        # Translators: The message displayed when an error occurs when installing an addon bundle.\r
-                       gui.messageBox(_("Failed to install addon  from %s")%addonPath,\r
+                       gui.messageBox(_("Failed to install add-on  from %s")%addonPath,\r
                                # Translators: The title of a dialog presented when an error occurs.\r
                                _("Error"),\r
                                wx.OK | wx.ICON_ERROR)\r
@@ -110,7 +110,7 @@ class AddonsDialog(wx.Dialog):
        def OnRemoveClick(self,evt):\r
                index=self.addonsList.GetFirstSelected()\r
                if index<0: return\r
-               if gui.messageBox(_("Are you sure you wish to remove the selected addon from NVDA?"), _("Remove Addon"), wx.YES_NO|wx.ICON_WARNING) != wx.YES: return\r
+               if gui.messageBox(_("Are you sure you wish to remove the selected add-on from NVDA?"), _("Remove Add-on"), wx.YES_NO|wx.ICON_WARNING) != wx.YES: return\r
                addon=self.curAddons[index]\r
                addon.requestRemove()\r
                self.needsRestart=True\r
@@ -157,7 +157,7 @@ class AddonsDialog(wx.Dialog):
                self.Destroy()\r
                if self.needsRestart:\r
                        # Translators: A message asking the user if they wish to restart NVDA as addons have been added or removed. \r
-                       if gui.messageBox(_("Addons have been added or removed. You must restart NVDA for these changes to take affect. Would you like to restart now?"),\r
+                       if gui.messageBox(_("Add-ons have been added or removed. You must restart NVDA for these changes to take affect. Would you like to restart now?"),\r
                        # Translators: Title for message asking if the user wishes to restart NVDA as addons have been added or removed. \r
                        _("Restart NVDA"),\r
                        wx.YES|wx.NO|wx.ICON_WARNING)==wx.YES:\r
index df37985..15e5366 100644 (file)
@@ -944,27 +944,27 @@ Uncheck the menu item to disable it.
 While the speech viewer is enabled, it constantly updates to show you the most current text being spoken.\r
 However, if you click or focus inside the viewer, NVDA will temporarily stop updating the text, so that you are able to easily select or copy the existing content.\r
 \r
-++ Addons Manager ++\r
-The Addons manager, found under Tools in the NVDA menu, allows you to install and uninstall add-on packages for NVDA.\r
+++ Add-ons Manager ++\r
+The Add-ons manager, found under Tools in the NVDA menu, allows you to install and uninstall add-on packages for NVDA.\r
 These packages are provided by the community, and contain custom code that may add or change features in NVDA, or even provide support for extra Braille displays or speech synthesizers.\r
 \r
-The Addons Manager contains a list that displays all the addons currently installed in your NVDA user configuration. \r
-A package name, version and author are shown for each addon, though further information such as a description and url can be viewed by selecting the addon and pressing the About Addon button.\r
+The Add-ons Manager contains a list that displays all the add-ons currently installed in your NVDA user configuration. \r
+A package name, version and author are shown for each add-on, though further information such as a description and url can be viewed by selecting the add-on and pressing the About Add-on button.\r
 \r
-To install an Addon, press the Add button.\r
-This will allow you to browse for an addon archive (.nvda-addon file) somewhere on your computer or on a network.\r
-Once pressing Open, NVDA will ask if you really wish to install the addon. \r
-As addons are free to do what they wish inside NVDA, which in theory could include accessing your personal data or in deed the entire system if NVDA is an installed copy, its very important to only install addons from people you trust.\r
-Once the addon is installed, it is necessary for NVDA to be restarted for the addon to start running. \r
-Until you do, a status of "install" will show for that addon in the list.\r
+To install an Add-on, press the Add button.\r
+This will allow you to browse for an add-on archive (.nvda-add-on file) somewhere on your computer or on a network.\r
+Once pressing Open, NVDA will ask if you really wish to install the add-on. \r
+As add-ons are free to do what they wish inside NVDA, which in theory could include accessing your personal data or in deed the entire system if NVDA is an installed copy, its very important to only install add-ons from people you trust.\r
+Once the add-on is installed, it is necessary for NVDA to be restarted for the add-on to start running. \r
+Until you do, a status of "install" will show for that add-on in the list.\r
 \r
-To remove an addon, select the addon from the list and press the remove button.\r
+To remove an add-on, select the add-on from the list and press the remove button.\r
 NVDA will ask if you really wish to do this.\r
-Like with installing, NVDA must be restarted for the addon to be fully  removed.\r
-Until you do, a status of "remove" will be shown in the list for that addon.\r
+Like with installing, NVDA must be restarted for the add-on to be fully  removed.\r
+Until you do, a status of "remove" will be shown in the list for that add-on.\r
 \r
 The manager also has a close button to close the dialog.\r
-However if you have installed or removed addons, NVDA will firstly ask you if you wish to restart so that your changes can take effect.\r
+However if you have installed or removed add-ons, NVDA will firstly ask you if you wish to restart so that your changes can take effect.\r
  \r
 ++ Python Console ++\r
 The NVDA Python console, found under Tools in the NVDA menu, is a development tool which is useful for debugging, general inspection of NVDA internals or inspection of the accessibility hierarchy of an application.\r