# HG changeset patch
# User Mario de Sousa
# Date 1490357267 0
# Node ID c1298e7ffe3a3079ffa1e3e3fdc4548b2213bc04
# Parent a375e31bf312c7238c813b3133a4b688d1a452ff# Parent 1953c268a194a86a63997eeaf959df897d09bd86
merge
diff -r a375e31bf312 -r c1298e7ffe3a .hgignore
--- a/.hgignore Sun Mar 05 00:38:25 2017 +0000
+++ b/.hgignore Fri Mar 24 12:07:47 2017 +0000
@@ -4,9 +4,14 @@
bug_report*
syntax: regexp
^tests/.*/build$
+^.idea/.*
syntax: regexp
^.*\.pyc$
syntax: regexp
^.*~$
syntax: regexp
^.*\.swp$
+
+bug_report.*\.txt
+i18n/.*.new$
+revision
diff -r a375e31bf312 -r c1298e7ffe3a Beremiz.py
--- a/Beremiz.py Sun Mar 05 00:38:25 2017 +0000
+++ b/Beremiz.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,27 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of Beremiz, a Integrated Development Environment for
-#programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
updateinfo_url = None
@@ -31,18 +30,33 @@
import shutil
import random
import time
+import version
from types import ListType
beremiz_dir = os.path.dirname(os.path.realpath(__file__))
-import wxversion
-wxversion.select('2.8')
-import wx
+if __name__ == '__main__':
+ import wxversion
+ wxversion.select(['2.8', '3.0'])
+ import wx
+
from wx.lib.agw.advancedsplash import AdvancedSplash
def Bpath(*args):
return os.path.join(beremiz_dir,*args)
+def ShowSplashScreen():
+ bmp = wx.Image(Bpath("images", "splash.png")).ConvertToBitmap()
+ #splash=AdvancedSplash(None, bitmap=bmp, style=wx.SPLASH_CENTRE_ON_SCREEN, timeout=4000)
+ splash = AdvancedSplash(None, bitmap=bmp)
+
+ # process all events
+ # even the events generated by splash themself during showing
+ for i in range(0,30):
+ wx.Yield()
+ time.sleep(0.01);
+ return splash
+
if __name__ == '__main__':
def usage():
print "\nUsage of Beremiz.py :"
@@ -84,18 +98,24 @@
else :
__builtin__.__dict__["BMZ_DBG"] = False
- app = wx.PySimpleApp(redirect=BMZ_DBG)
+ if wx.VERSION >= (3, 0, 0):
+ app = wx.App(redirect=BMZ_DBG)
+ else:
+ app = wx.PySimpleApp(redirect=BMZ_DBG)
+
app.SetAppName('beremiz')
- wx.InitAllImageHandlers()
+ if wx.VERSION < (3, 0, 0):
+ wx.InitAllImageHandlers()
# popup splash
- bmp = wx.Image(Bpath("images", "splash.png")).ConvertToBitmap()
- #splash=AdvancedSplash(None, bitmap=bmp, style=wx.SPLASH_CENTRE_ON_SCREEN, timeout=4000)
- splash=AdvancedSplash(None, bitmap=bmp)
- wx.Yield()
-
+ splash = ShowSplashScreen()
+
+ # load internatialization files
+ from util.misc import InstallLocalRessources
+ InstallLocalRessources(beremiz_dir)
+
if updateinfo_url is not None:
- updateinfo = "Fetching %s" % updateinfo_url
+ updateinfo = _("Fetching %s") % updateinfo_url
# warn for possible updates
def updateinfoproc():
global updateinfo
@@ -103,7 +123,7 @@
import urllib2
updateinfo = urllib2.urlopen(updateinfo_url,None).read()
except :
- updateinfo = "update info unavailable."
+ updateinfo = _("update info unavailable.")
from threading import Thread
splash.SetText(text=updateinfo)
@@ -114,9 +134,6 @@
splash.SetText(text=updateinfo)
wx.Yield()
- from util.misc import InstallLocalRessources
- InstallLocalRessources(beremiz_dir)
-
# Load extensions
for extfilename in extensions:
from util.TranslationCatalogs import AddCatalog
@@ -142,6 +159,8 @@
from util.ProcessLogger import ProcessLogger
from controls.LogViewer import LogViewer
from controls.CustomStyledTextCtrl import CustomStyledTextCtrl
+from controls import EnhancedStatusBar as esb
+from dialogs.AboutDialog import ShowAboutDialog
from PLCControler import LOCATION_CONFNODE, LOCATION_MODULE, LOCATION_GROUP, LOCATION_VAR_INPUT, LOCATION_VAR_OUTPUT, LOCATION_VAR_MEMORY, ITEM_PROJECT, ITEM_RESOURCE
from ProjectController import ProjectController, GetAddMenuItems, MATIEC_ERROR_MODEL, ITEM_CONFNODE
@@ -231,12 +250,14 @@
# adding text. It seems that text modifications, even
# programmatically, are disabled in StyledTextCtrl when read
# only is active
+ start_pos = self.output.GetLength()
self.output.SetReadOnly(False)
self.output.AppendText(s)
self.output.SetReadOnly(True)
+ text_len = self.output.GetLength() - start_pos
if style != self.black_white:
- self.output.SetStyling(len(s), style)
+ self.output.SetStyling(text_len, style)
self.stack = []
self.lock.release()
self.output.Thaw()
@@ -377,6 +398,11 @@
inspectorID = wx.NewId()
self.Bind(wx.EVT_MENU, self.OnOpenWidgetInspector, id=inspectorID)
accels = [wx.AcceleratorEntry(wx.ACCEL_CTRL|wx.ACCEL_ALT, ord('I'), inspectorID)]
+
+ keyID = wx.NewId()
+ self.Bind(wx.EVT_MENU, self.SwitchFullScrMode, id=keyID)
+ accels += [wx.AcceleratorEntry(wx.ACCEL_NORMAL, wx.WXK_F12, keyID)]
+
for method,shortcut in [("Stop", wx.WXK_F4),
("Run", wx.WXK_F5),
("Transfer", wx.WXK_F6),
@@ -440,11 +466,28 @@
self.AUIManager.Update()
- self.ConnectionStatusBar = wx.StatusBar(self, style=wx.ST_SIZEGRIP)
+ self.ConnectionStatusBar = esb.EnhancedStatusBar(self, style=wx.ST_SIZEGRIP)
self._init_coll_ConnectionStatusBar_Fields(self.ConnectionStatusBar)
+ self.ProgressStatusBar = wx.Gauge(self.ConnectionStatusBar, -1, range = 100)
+ self.ConnectionStatusBar.AddWidget(self.ProgressStatusBar, esb.ESB_EXACT_FIT, esb.ESB_EXACT_FIT, 2)
+ self.ProgressStatusBar.Hide()
self.SetStatusBar(self.ConnectionStatusBar)
+ def __init_execute_path(self):
+ if os.name == 'nt':
+ # on windows, desktop shortcut launches Beremiz.py
+ # with working dir set to mingw/bin.
+ # then we prefix CWD to PATH in order to ensure that
+ # commands invoked by build process by default are
+ # found here.
+ os.environ["PATH"] = os.getcwd()+';'+os.environ["PATH"]
+
+
def __init__(self, parent, projectOpen=None, buildpath=None, ctr=None, debug=True):
+ # Add beremiz's icon in top left corner of the frame
+ self.icon = wx.Icon(Bpath("images", "brz.ico"), wx.BITMAP_TYPE_ICO)
+ self.__init_execute_path()
+
IDEFrame.__init__(self, parent, debug)
self.Log = LogPseudoFile(self.LogConsole,self.SelectTab)
@@ -473,16 +516,13 @@
("Extension", ITEM_CONFNODE)]:
self.TreeImageDict[itemtype] = self.TreeImageList.Add(GetBitmap(imgname))
- # Add beremiz's icon in top left corner of the frame
- self.SetIcon(wx.Icon(Bpath("images", "brz.ico"), wx.BITMAP_TYPE_ICO))
-
if projectOpen is not None:
projectOpen = DecodeFileSystemPath(projectOpen, False)
if projectOpen is not None and os.path.isdir(projectOpen):
self.CTR = ProjectController(self, self.Log)
self.Controler = self.CTR
- result = self.CTR.LoadProject(projectOpen, buildpath)
+ result, err = self.CTR.LoadProject(projectOpen, buildpath)
if not result:
self.LibraryPanel.SetController(self.Controler)
self.ProjectTree.Enable(True)
@@ -534,7 +574,7 @@
{False : "-x 0", True :"-x 1"}[taskbaricon],
self.local_runtime_tmpdir),
no_gui=False,
- timeout=500, keyword = "working",
+ timeout=500, keyword = self.local_runtime_tmpdir,
cwd = self.local_runtime_tmpdir)
self.local_runtime.spin()
return self.runtime_port
@@ -717,6 +757,11 @@
self.GetConfigEntry("RecentProjects", []))
except:
recent_projects = []
+
+ while self.RecentProjectsMenu.GetMenuItemCount() > len(recent_projects):
+ item = self.RecentProjectsMenu.FindItemByPosition(0)
+ self.RecentProjectsMenu.RemoveItem(item)
+
self.FileMenu.Enable(ID_FILEMENURECENTPROJECTS, len(recent_projects) > 0)
for idx, projectpath in enumerate(recent_projects):
text = u'%d: %s' % (idx + 1, projectpath)
@@ -856,7 +901,7 @@
self.DebugVariablePanel.SetDataProducer(None)
self.ResetConnectionStatusBar()
- def RefreshConfigRecentProjects(self, projectpath):
+ def RefreshConfigRecentProjects(self, projectpath, err=False):
try:
recent_projects = map(DecodeFileSystemPath,
self.GetConfigEntry("RecentProjects", []))
@@ -864,7 +909,8 @@
recent_projects = []
if projectpath in recent_projects:
recent_projects.remove(projectpath)
- recent_projects.insert(0, projectpath)
+ if not err:
+ recent_projects.insert(0, projectpath)
self.Config.Write("RecentProjects", cPickle.dumps(
map(EncodeFileSystemPath, recent_projects[:MAX_RECENT_PROJECTS])))
self.Config.Flush()
@@ -931,12 +977,11 @@
self.ResetView()
self.CTR = ProjectController(self, self.Log)
self.Controler = self.CTR
- result = self.CTR.LoadProject(projectpath)
+ result, err = self.CTR.LoadProject(projectpath)
if not result:
self.LibraryPanel.SetController(self.Controler)
self.ProjectTree.Enable(True)
self.PouInstanceVariablesPanel.SetController(self.Controler)
- self.RefreshConfigRecentProjects(projectpath)
if self.EnableDebug:
self.DebugVariablePanel.SetDataProducer(self.CTR)
self._Refresh(PROJECTTREE, POUINSTANCEVARIABLESPANEL, LIBRARYTREE)
@@ -944,8 +989,11 @@
self.ResetView()
self.ShowErrorMessage(result)
self.RefreshAll()
+ self.SearchResultPanel.ResetSearchResults()
else:
self.ShowErrorMessage(_("\"%s\" folder is not a valid Beremiz project\n") % projectpath)
+ err = True
+ self.RefreshConfigRecentProjects(projectpath, err)
self._Refresh(TITLE, EDITORTOOLBAR, FILEMENU, EDITMENU)
def OnCloseProjectMenu(self, event):
@@ -974,13 +1022,15 @@
if self.CTR is not None:
self.CTR.SaveProjectAs()
self.RefreshAll()
+ self.RefreshConfigRecentProjects(self.CTR.ProjectPath)
self._Refresh(TITLE, FILEMENU, EDITMENU, PAGETITLES)
def OnQuitMenu(self, event):
self.Close()
def OnAboutMenu(self, event):
- OpenHtmlFrame(self,_("About Beremiz"), Bpath("doc", "about.html"), wx.Size(550, 500))
+ info = version.GetAboutDialogInfo()
+ ShowAboutDialog(self, info)
def OnProjectTreeItemBeginEdit(self, event):
selected = event.GetItem()
@@ -1145,7 +1195,7 @@
Please be kind enough to send this file to:
beremiz-devel@lists.sourceforge.net
-You should now restart Beremiz.
+You should now restart program.
Traceback:
""") % bug_report_path +
@@ -1231,7 +1281,7 @@
if __name__ == '__main__':
# Install a exception handle for bug reports
- AddExceptHook(os.getcwd(),updateinfo_url)
+ AddExceptHook(os.getcwd(),version.app_version)
frame = Beremiz(None, projectOpen, buildpath)
if splash:
diff -r a375e31bf312 -r c1298e7ffe3a Beremiz_service.py
--- a/Beremiz_service.py Sun Mar 05 00:38:25 2017 +0000
+++ b/Beremiz_service.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of Beremiz, a Integrated Development Environment for
-#programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import os, sys, getopt
from threading import Thread
@@ -112,10 +112,52 @@
if __name__ == '__main__':
__builtin__.__dict__['_'] = lambda x: x
+def Bpath(*args):
+ return os.path.join(beremiz_dir,*args)
+
+def SetupI18n():
+ # Import module for internationalization
+ import gettext
+
+ # Get folder containing translation files
+ localedir = os.path.join(beremiz_dir,"locale")
+ # Get the default language
+ langid = wx.LANGUAGE_DEFAULT
+ # Define translation domain (name of translation files)
+ domain = "Beremiz"
+
+ # Define locale for wx
+ loc = __builtin__.__dict__.get('loc', None)
+ if loc is None:
+ loc = wx.Locale(langid)
+ __builtin__.__dict__['loc'] = loc
+ # Define location for searching translation files
+ loc.AddCatalogLookupPathPrefix(localedir)
+ # Define locale domain
+ loc.AddCatalog(domain)
+
+
+ import locale
+ global default_locale
+ default_locale = locale.getdefaultlocale()[1]
+
+
+ # sys.stdout.encoding = default_locale
+ # if Beremiz_service is started from Beremiz IDE
+ # sys.stdout.encoding is None (that means 'ascii' encoding').
+ # And unicode string returned by wx.GetTranslation() are
+ # automatically converted to 'ascii' string.
+ def unicode_translation(message):
+ return wx.GetTranslation(message).encode(default_locale)
+
+ if __name__ == '__main__':
+ __builtin__.__dict__['_'] = unicode_translation
+ # __builtin__.__dict__['_'] = wx.GetTranslation
+
if enablewx:
try:
import wxversion
- wxversion.select('2.8')
+ wxversion.select(['2.8', '3.0'])
import wx
havewx = True
except:
@@ -126,36 +168,15 @@
import re
from threading import Thread, currentThread
from types import *
- app=wx.App(redirect=False)
-
- # Import module for internationalization
- import gettext
-
- def Bpath(*args):
- return os.path.join(beremiz_dir,*args)
-
- # Get folder containing translation files
- localedir = os.path.join(beremiz_dir,"locale")
- # Get the default language
- langid = wx.LANGUAGE_DEFAULT
- # Define translation domain (name of translation files)
- domain = "Beremiz"
-
- # Define locale for wx
- loc = __builtin__.__dict__.get('loc', None)
- if loc is None:
- loc = wx.Locale(langid)
- __builtin__.__dict__['loc'] = loc
- # Define location for searching translation files
- loc.AddCatalogLookupPathPrefix(localedir)
- # Define locale domain
- loc.AddCatalog(domain)
-
- def unicode_translation(message):
- return wx.GetTranslation(message).encode("utf-8")
-
- if __name__ == '__main__':
- __builtin__.__dict__['_'] = wx.GetTranslation#unicode_translation
+
+ if wx.VERSION >= (3, 0, 0):
+ app = wx.App(redirect=False)
+ else:
+ app = wx.PySimpleApp(redirect=False)
+ app.SetTopWindow(wx.Frame(None, -1))
+
+ default_locale = None
+ SetupI18n()
defaulticon = wx.Image(Bpath("images", "brz.png"))
starticon = wx.Image(Bpath("images", "icoplay24.png"))
@@ -170,7 +191,7 @@
event(self, function)
- def __init__(self, parent, message, caption = "Please enter text", defaultValue = "",
+ def __init__(self, parent, message, caption = _("Please enter text"), defaultValue = "",
style = wx.OK|wx.CANCEL|wx.CENTRE, pos = wx.DefaultPosition):
wx.TextEntryDialog.__init__(self, parent, message, caption, defaultValue, style, pos)
@@ -267,14 +288,23 @@
def OnTaskBarStartPLC(self, evt):
if self.pyroserver.plcobj is not None:
- self.pyroserver.plcobj.StartPLC()
+ plcstatus = self.pyroserver.plcobj.GetPLCstatus()[0]
+ if plcstatus is "Stopped":
+ self.pyroserver.plcobj.StartPLC()
+ else:
+ print _("PLC is empty or already started.")
def OnTaskBarStopPLC(self, evt):
if self.pyroserver.plcobj is not None:
- Thread(target=self.pyroserver.plcobj.StopPLC).start()
+ if self.pyroserver.plcobj.GetPLCstatus()[0] == "Started":
+ Thread(target=self.pyroserver.plcobj.StopPLC).start()
+ else:
+ print _("PLC is not started.")
def OnTaskBarChangeInterface(self, evt):
- dlg = ParamsEntryDialog(None, _("Enter the IP of the interface to bind"), defaultValue=self.pyroserver.ip_addr)
+ ip_addr = self.pyroserver.ip_addr
+ ip_addr = '' if ip_addr is None else ip_addr
+ dlg = ParamsEntryDialog(None, _("Enter the IP of the interface to bind"), defaultValue=ip_addr)
dlg.SetTests([(re.compile('\d{1,3}(?:\.\d{1,3}){3}$').match, _("IP is not valid!")),
( lambda x :len([x for x in x.split(".") if 0 <= int(x) <= 255]) == 4, _("IP is not valid!"))
])
@@ -296,10 +326,12 @@
self.pyroserver.Stop()
def OnTaskBarChangeName(self, evt):
- dlg = ParamsEntryDialog(None, _("Enter a name "), defaultValue=self.pyroserver.name)
+ servicename = self.pyroserver.servicename
+ servicename = '' if servicename is None else servicename
+ dlg = ParamsEntryDialog(None, _("Enter a name "), defaultValue=servicename)
dlg.SetTests([(lambda name : len(name) is not 0 , _("Name must not be null!"))])
if dlg.ShowModal() == wx.ID_OK:
- self.pyroserver.name = dlg.GetValue()
+ self.pyroserver.servicename = dlg.GetValue()
self.pyroserver.Restart()
def _LiveShellLocals(self):
@@ -379,6 +411,7 @@
def Quit(self):
self.continueloop = False
if self.plcobj is not None:
+ self.plcobj.StopPLC()
self.plcobj.UnLoadPLC()
self.Stop()
@@ -390,9 +423,13 @@
self.pyruntimevars)
uri = self.daemon.connect(self.plcobj,"PLCObject")
- print "Pyro port :",self.port
- print "Pyro object's uri :",uri
- print "Current working directory :",self.workdir
+ print _("Pyro port :"), self.port
+ print _("Pyro object's uri :"), uri
+
+ # Beremiz IDE detects daemon start by looking
+ # for self.workdir in the daemon's stdout.
+ # Therefore don't delete the following line
+ print _("Current working directory :"), self.workdir
# Configure and publish service
# Not publish service if localhost in address params
@@ -400,18 +437,20 @@
self.ip_addr is not None and
self.ip_addr != "localhost" and
self.ip_addr != "127.0.0.1"):
- print "Publishing service on local network"
+ print _("Publishing service on local network")
self.servicepublisher = ServicePublisher.ServicePublisher()
self.servicepublisher.RegisterService(self.servicename, self.ip_addr, self.port)
- if self.autostart :
- self.plcobj.AutoLoad()
- if self.plcobj.GetPLCstatus()[0] != "Empty":
+ self.plcobj.AutoLoad()
+ if self.plcobj.GetPLCstatus()[0] != "Empty":
+ if self.autostart :
self.plcobj.StartPLC()
+ self.plcobj.StatusChange()
sys.stdout.flush()
self.daemon.requestLoop()
+ self.daemon.sock.close()
def Stop(self):
if self.plcobj is not None:
@@ -434,7 +473,7 @@
havetwisted = True
except:
- print "Twisted unavailable."
+ print _("Twisted unavailable.")
havetwisted = False
pyruntimevars = {}
@@ -512,7 +551,7 @@
try:
import runtime.NevowServer as NS
except Exception, e:
- print "Nevow/Athena import failed :", e
+ print _("Nevow/Athena import failed :"), e
webport = None
NS.WorkingDir = WorkingDir
@@ -520,7 +559,7 @@
try:
import runtime.WampClient as WC
except Exception, e:
- print "WAMP import failed :", e
+ print _("WAMP import failed :"), e
wampconf = None
# Load extensions
@@ -536,7 +575,7 @@
pyruntimevars["website"] = website
statuschange.append(NS.website_statuslistener_factory(website))
except Exception, e:
- print "Nevow Web service failed.", e
+ print _("Nevow Web service failed. "), e
if wampconf is not None :
try:
@@ -544,7 +583,7 @@
pyruntimevars["wampsession"] = WC.GetSession
WC.SetServer(pyroserver)
except Exception, e:
- print "WAMP client startup failed.", e
+ print _("WAMP client startup failed. "), e
if havetwisted or havewx:
diff -r a375e31bf312 -r c1298e7ffe3a COPYING
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/COPYING Fri Mar 24 12:07:47 2017 +0000
@@ -0,0 +1,339 @@
+ GNU GENERAL PUBLIC LICENSE
+ Version 2, June 1991
+
+ Copyright (C) 1989, 1991 Free Software Foundation, Inc.,
+ 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ Everyone is permitted to copy and distribute verbatim copies
+ of this license document, but changing it is not allowed.
+
+ Preamble
+
+ The licenses for most software are designed to take away your
+freedom to share and change it. By contrast, the GNU General Public
+License is intended to guarantee your freedom to share and change free
+software--to make sure the software is free for all its users. This
+General Public License applies to most of the Free Software
+Foundation's software and to any other program whose authors commit to
+using it. (Some other Free Software Foundation software is covered by
+the GNU Lesser General Public License instead.) You can apply it to
+your programs, too.
+
+ When we speak of free software, we are referring to freedom, not
+price. Our General Public Licenses are designed to make sure that you
+have the freedom to distribute copies of free software (and charge for
+this service if you wish), that you receive source code or can get it
+if you want it, that you can change the software or use pieces of it
+in new free programs; and that you know you can do these things.
+
+ To protect your rights, we need to make restrictions that forbid
+anyone to deny you these rights or to ask you to surrender the rights.
+These restrictions translate to certain responsibilities for you if you
+distribute copies of the software, or if you modify it.
+
+ For example, if you distribute copies of such a program, whether
+gratis or for a fee, you must give the recipients all the rights that
+you have. You must make sure that they, too, receive or can get the
+source code. And you must show them these terms so they know their
+rights.
+
+ We protect your rights with two steps: (1) copyright the software, and
+(2) offer you this license which gives you legal permission to copy,
+distribute and/or modify the software.
+
+ Also, for each author's protection and ours, we want to make certain
+that everyone understands that there is no warranty for this free
+software. If the software is modified by someone else and passed on, we
+want its recipients to know that what they have is not the original, so
+that any problems introduced by others will not reflect on the original
+authors' reputations.
+
+ Finally, any free program is threatened constantly by software
+patents. We wish to avoid the danger that redistributors of a free
+program will individually obtain patent licenses, in effect making the
+program proprietary. To prevent this, we have made it clear that any
+patent must be licensed for everyone's free use or not licensed at all.
+
+ The precise terms and conditions for copying, distribution and
+modification follow.
+
+ GNU GENERAL PUBLIC LICENSE
+ TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
+
+ 0. This License applies to any program or other work which contains
+a notice placed by the copyright holder saying it may be distributed
+under the terms of this General Public License. The "Program", below,
+refers to any such program or work, and a "work based on the Program"
+means either the Program or any derivative work under copyright law:
+that is to say, a work containing the Program or a portion of it,
+either verbatim or with modifications and/or translated into another
+language. (Hereinafter, translation is included without limitation in
+the term "modification".) Each licensee is addressed as "you".
+
+Activities other than copying, distribution and modification are not
+covered by this License; they are outside its scope. The act of
+running the Program is not restricted, and the output from the Program
+is covered only if its contents constitute a work based on the
+Program (independent of having been made by running the Program).
+Whether that is true depends on what the Program does.
+
+ 1. You may copy and distribute verbatim copies of the Program's
+source code as you receive it, in any medium, provided that you
+conspicuously and appropriately publish on each copy an appropriate
+copyright notice and disclaimer of warranty; keep intact all the
+notices that refer to this License and to the absence of any warranty;
+and give any other recipients of the Program a copy of this License
+along with the Program.
+
+You may charge a fee for the physical act of transferring a copy, and
+you may at your option offer warranty protection in exchange for a fee.
+
+ 2. You may modify your copy or copies of the Program or any portion
+of it, thus forming a work based on the Program, and copy and
+distribute such modifications or work under the terms of Section 1
+above, provided that you also meet all of these conditions:
+
+ a) You must cause the modified files to carry prominent notices
+ stating that you changed the files and the date of any change.
+
+ b) You must cause any work that you distribute or publish, that in
+ whole or in part contains or is derived from the Program or any
+ part thereof, to be licensed as a whole at no charge to all third
+ parties under the terms of this License.
+
+ c) If the modified program normally reads commands interactively
+ when run, you must cause it, when started running for such
+ interactive use in the most ordinary way, to print or display an
+ announcement including an appropriate copyright notice and a
+ notice that there is no warranty (or else, saying that you provide
+ a warranty) and that users may redistribute the program under
+ these conditions, and telling the user how to view a copy of this
+ License. (Exception: if the Program itself is interactive but
+ does not normally print such an announcement, your work based on
+ the Program is not required to print an announcement.)
+
+These requirements apply to the modified work as a whole. If
+identifiable sections of that work are not derived from the Program,
+and can be reasonably considered independent and separate works in
+themselves, then this License, and its terms, do not apply to those
+sections when you distribute them as separate works. But when you
+distribute the same sections as part of a whole which is a work based
+on the Program, the distribution of the whole must be on the terms of
+this License, whose permissions for other licensees extend to the
+entire whole, and thus to each and every part regardless of who wrote it.
+
+Thus, it is not the intent of this section to claim rights or contest
+your rights to work written entirely by you; rather, the intent is to
+exercise the right to control the distribution of derivative or
+collective works based on the Program.
+
+In addition, mere aggregation of another work not based on the Program
+with the Program (or with a work based on the Program) on a volume of
+a storage or distribution medium does not bring the other work under
+the scope of this License.
+
+ 3. You may copy and distribute the Program (or a work based on it,
+under Section 2) in object code or executable form under the terms of
+Sections 1 and 2 above provided that you also do one of the following:
+
+ a) Accompany it with the complete corresponding machine-readable
+ source code, which must be distributed under the terms of Sections
+ 1 and 2 above on a medium customarily used for software interchange; or,
+
+ b) Accompany it with a written offer, valid for at least three
+ years, to give any third party, for a charge no more than your
+ cost of physically performing source distribution, a complete
+ machine-readable copy of the corresponding source code, to be
+ distributed under the terms of Sections 1 and 2 above on a medium
+ customarily used for software interchange; or,
+
+ c) Accompany it with the information you received as to the offer
+ to distribute corresponding source code. (This alternative is
+ allowed only for noncommercial distribution and only if you
+ received the program in object code or executable form with such
+ an offer, in accord with Subsection b above.)
+
+The source code for a work means the preferred form of the work for
+making modifications to it. For an executable work, complete source
+code means all the source code for all modules it contains, plus any
+associated interface definition files, plus the scripts used to
+control compilation and installation of the executable. However, as a
+special exception, the source code distributed need not include
+anything that is normally distributed (in either source or binary
+form) with the major components (compiler, kernel, and so on) of the
+operating system on which the executable runs, unless that component
+itself accompanies the executable.
+
+If distribution of executable or object code is made by offering
+access to copy from a designated place, then offering equivalent
+access to copy the source code from the same place counts as
+distribution of the source code, even though third parties are not
+compelled to copy the source along with the object code.
+
+ 4. You may not copy, modify, sublicense, or distribute the Program
+except as expressly provided under this License. Any attempt
+otherwise to copy, modify, sublicense or distribute the Program is
+void, and will automatically terminate your rights under this License.
+However, parties who have received copies, or rights, from you under
+this License will not have their licenses terminated so long as such
+parties remain in full compliance.
+
+ 5. You are not required to accept this License, since you have not
+signed it. However, nothing else grants you permission to modify or
+distribute the Program or its derivative works. These actions are
+prohibited by law if you do not accept this License. Therefore, by
+modifying or distributing the Program (or any work based on the
+Program), you indicate your acceptance of this License to do so, and
+all its terms and conditions for copying, distributing or modifying
+the Program or works based on it.
+
+ 6. Each time you redistribute the Program (or any work based on the
+Program), the recipient automatically receives a license from the
+original licensor to copy, distribute or modify the Program subject to
+these terms and conditions. You may not impose any further
+restrictions on the recipients' exercise of the rights granted herein.
+You are not responsible for enforcing compliance by third parties to
+this License.
+
+ 7. If, as a consequence of a court judgment or allegation of patent
+infringement or for any other reason (not limited to patent issues),
+conditions are imposed on you (whether by court order, agreement or
+otherwise) that contradict the conditions of this License, they do not
+excuse you from the conditions of this License. If you cannot
+distribute so as to satisfy simultaneously your obligations under this
+License and any other pertinent obligations, then as a consequence you
+may not distribute the Program at all. For example, if a patent
+license would not permit royalty-free redistribution of the Program by
+all those who receive copies directly or indirectly through you, then
+the only way you could satisfy both it and this License would be to
+refrain entirely from distribution of the Program.
+
+If any portion of this section is held invalid or unenforceable under
+any particular circumstance, the balance of the section is intended to
+apply and the section as a whole is intended to apply in other
+circumstances.
+
+It is not the purpose of this section to induce you to infringe any
+patents or other property right claims or to contest validity of any
+such claims; this section has the sole purpose of protecting the
+integrity of the free software distribution system, which is
+implemented by public license practices. Many people have made
+generous contributions to the wide range of software distributed
+through that system in reliance on consistent application of that
+system; it is up to the author/donor to decide if he or she is willing
+to distribute software through any other system and a licensee cannot
+impose that choice.
+
+This section is intended to make thoroughly clear what is believed to
+be a consequence of the rest of this License.
+
+ 8. If the distribution and/or use of the Program is restricted in
+certain countries either by patents or by copyrighted interfaces, the
+original copyright holder who places the Program under this License
+may add an explicit geographical distribution limitation excluding
+those countries, so that distribution is permitted only in or among
+countries not thus excluded. In such case, this License incorporates
+the limitation as if written in the body of this License.
+
+ 9. The Free Software Foundation may publish revised and/or new versions
+of the General Public License from time to time. Such new versions will
+be similar in spirit to the present version, but may differ in detail to
+address new problems or concerns.
+
+Each version is given a distinguishing version number. If the Program
+specifies a version number of this License which applies to it and "any
+later version", you have the option of following the terms and conditions
+either of that version or of any later version published by the Free
+Software Foundation. If the Program does not specify a version number of
+this License, you may choose any version ever published by the Free Software
+Foundation.
+
+ 10. If you wish to incorporate parts of the Program into other free
+programs whose distribution conditions are different, write to the author
+to ask for permission. For software which is copyrighted by the Free
+Software Foundation, write to the Free Software Foundation; we sometimes
+make exceptions for this. Our decision will be guided by the two goals
+of preserving the free status of all derivatives of our free software and
+of promoting the sharing and reuse of software generally.
+
+ NO WARRANTY
+
+ 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
+FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN
+OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
+PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
+OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS
+TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE
+PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
+REPAIR OR CORRECTION.
+
+ 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
+WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
+REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
+INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
+OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
+TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
+YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
+PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
+POSSIBILITY OF SUCH DAMAGES.
+
+ END OF TERMS AND CONDITIONS
+
+ How to Apply These Terms to Your New Programs
+
+ If you develop a new program, and you want it to be of the greatest
+possible use to the public, the best way to achieve this is to make it
+free software which everyone can redistribute and change under these terms.
+
+ To do so, attach the following notices to the program. It is safest
+to attach them to the start of each source file to most effectively
+convey the exclusion of warranty; and each file should have at least
+the "copyright" line and a pointer to where the full notice is found.
+
+
+ Copyright (C)
+
+ 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
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License along
+ with this program; if not, write to the Free Software Foundation, Inc.,
+ 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+
+Also add information on how to contact you by electronic and paper mail.
+
+If the program is interactive, make it output a short notice like this
+when it starts in an interactive mode:
+
+ Gnomovision version 69, Copyright (C) year name of author
+ Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
+ This is free software, and you are welcome to redistribute it
+ under certain conditions; type `show c' for details.
+
+The hypothetical commands `show w' and `show c' should show the appropriate
+parts of the General Public License. Of course, the commands you use may
+be called something other than `show w' and `show c'; they could even be
+mouse-clicks or menu items--whatever suits your program.
+
+You should also get your employer (if you work as a programmer) or your
+school, if any, to sign a "copyright disclaimer" for the program, if
+necessary. Here is a sample; alter the names:
+
+ Yoyodyne, Inc., hereby disclaims all copyright interest in the program
+ `Gnomovision' (which makes passes at compilers) written by James Hacker.
+
+ , 1 April 1989
+ Ty Coon, President of Vice
+
+This General Public License does not permit incorporating your program into
+proprietary programs. If your program is a subroutine library, you may
+consider it more useful to permit linking proprietary applications with the
+library. If this is what you want to do, use the GNU Lesser General
+Public License instead of this License.
diff -r a375e31bf312 -r c1298e7ffe3a CodeFileTreeNode.py
--- a/CodeFileTreeNode.py Sun Mar 05 00:38:25 2017 +0000
+++ b/CodeFileTreeNode.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,3 +1,28 @@
+#!/usr/bin/env python
+# -*- coding: utf-8 -*-
+
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+
+
import os, re, traceback
from copy import deepcopy
@@ -92,11 +117,12 @@
try:
self.CodeFile, error = self.CodeFileParser.LoadXMLString(codefile_xml)
if error is not None:
- self.GetCTRoot().logger.write_warning(
- XSDSchemaErrorMessage % ((self.CODEFILE_NAME,) + error))
+ (fname, lnum, src) = ((self.CODEFILE_NAME,) + error)
+ self.GetCTRoot().logger.write_warning(XSDSchemaErrorMessage.format(a1 = fname, a2 = lnum, a3 = src))
self.CreateCodeFileBuffer(True)
except Exception, exc:
- self.GetCTRoot().logger.write_error(_("Couldn't load confnode parameters %s :\n %s") % (CTNName, unicode(exc)))
+ msg = _("Couldn't load confnode parameters {a1} :\n {a2}").format(a1 = CTNName, a2 = unicode(exc))
+ self.GetCTRoot().logger.write_error(msg)
self.GetCTRoot().logger.write_error(traceback.format_exc())
else:
self.CodeFile = self.CodeFileParser.CreateRoot()
diff -r a375e31bf312 -r c1298e7ffe3a ConfigTreeNode.py
--- a/ConfigTreeNode.py Sun Mar 05 00:38:25 2017 +0000
+++ b/ConfigTreeNode.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,3 +1,27 @@
+#!/usr/bin/env python
+# -*- coding: utf-8 -*-
+
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+
"""
Config Tree Node base class.
@@ -29,7 +53,7 @@
""")
NameTypeSeparator = '@'
-XSDSchemaErrorMessage = _("%s XML file doesn't follow XSD schema at line %d:\n%s")
+XSDSchemaErrorMessage = _("{a1} XML file doesn't follow XSD schema at line %{a2}:\n{a3}")
class ConfigTreeNode:
"""
@@ -397,7 +421,8 @@
shutil.move(oldname, self.CTNPath())
# warn user he has two left hands
if DesiredName != res:
- self.GetCTRoot().logger.write_warning(_("A child named \"%s\" already exist -> \"%s\"\n")%(DesiredName,res))
+ msg = _("A child named \"{a1}\" already exists -> \"{a2}\"\n").format(a1 = DesiredName, a2 = res)
+ self.GetCTRoot().logger.write_warning(msg)
return res
def GetAllChannels(self):
@@ -501,7 +526,7 @@
try:
CTNClass, CTNHelp = CTNChildrenTypes[CTNType]
except KeyError:
- raise Exception, _("Cannot create child %s of type %s ")%(CTNName, CTNType)
+ raise Exception, _("Cannot create child {a1} of type {a2} ").format(a1 = CTNName, a2 = CTNType)
# if CTNClass is a class factory, call it. (prevent unneeded imports)
if type(CTNClass) == types.FunctionType:
@@ -511,7 +536,8 @@
ChildrenWithSameClass = self.Children.setdefault(CTNType, list())
# Check count
if getattr(CTNClass, "CTNMaxCount", None) and len(ChildrenWithSameClass) >= CTNClass.CTNMaxCount:
- raise Exception, _("Max count (%d) reached for this confnode of type %s ")%(CTNClass.CTNMaxCount, CTNType)
+ msg = _("Max count ({a1}) reached for this confnode of type {a2} ").format(a1 = CTNClass.CTNMaxCount, a2 = CTNType)
+ raise Exception, msg
# create the final class, derived of provided confnode and template
class FinalCTNClass(CTNClass, ConfigTreeNode):
@@ -537,7 +563,9 @@
_self.LoadXMLParams(NewCTNName)
# Basic check. Better to fail immediately.
if (_self.BaseParams.getName() != NewCTNName):
- raise Exception, _("Project tree layout do not match confnode.xml %s!=%s ")%(NewCTNName, _self.BaseParams.getName())
+ msg = _("Project tree layout do not match confnode.xml {a1}!={a2} ").\
+ format(a1 = NewCTNName, a2 = _self.BaseParams.getName())
+ raise Exception, msg
# Now, self.CTNPath() should be OK
@@ -590,12 +618,13 @@
basexmlfile = open(self.ConfNodeBaseXmlFilePath(CTNName), 'r')
self.BaseParams, error = _BaseParamsParser.LoadXMLString(basexmlfile.read())
if error is not None:
- self.GetCTRoot().logger.write_warning(
- XSDSchemaErrorMessage % ((ConfNodeName + " BaseParams",) + error))
+ (fname, lnum, src) = ((ConfNodeName + " BaseParams",) + error)
+ self.GetCTRoot().logger.write_warning(XSDSchemaErrorMessage.format(a1 = fname, a2 = lnum, a3 = src))
self.MandatoryParams = ("BaseParams", self.BaseParams)
basexmlfile.close()
except Exception, exc:
- self.GetCTRoot().logger.write_error(_("Couldn't load confnode base parameters %s :\n %s") % (ConfNodeName, unicode(exc)))
+ msg = _("Couldn't load confnode base parameters {a1} :\n {a2}").format(a1 = ConfNodeName, a2 = unicode(exc))
+ self.GetCTRoot().logger.write_error(msg)
self.GetCTRoot().logger.write_error(traceback.format_exc())
# Get the xml tree
@@ -604,14 +633,15 @@
xmlfile = open(self.ConfNodeXmlFilePath(CTNName), 'r')
obj, error = self.Parser.LoadXMLString(xmlfile.read())
if error is not None:
- self.GetCTRoot().logger.write_warning(
- XSDSchemaErrorMessage % ((ConfNodeName,) + error))
+ (fname, lnum, src) = ((ConfNodeName,) + error)
+ self.GetCTRoot().logger.write_warning(XSDSchemaErrorMessage.format(a1 = fname, a2 = lnum, a3 = src))
name = obj.getLocalTag()
setattr(self, name, obj)
self.CTNParams = (name, obj)
xmlfile.close()
except Exception, exc:
- self.GetCTRoot().logger.write_error(_("Couldn't load confnode parameters %s :\n %s") % (ConfNodeName, unicode(exc)))
+ msg = _("Couldn't load confnode parameters {a1} :\n {a2}").format(a1 = ConfNodeName, a2 = unicode(exc))
+ self.GetCTRoot().logger.write_error(msg)
self.GetCTRoot().logger.write_error(traceback.format_exc())
def LoadChildren(self):
@@ -623,6 +653,7 @@
try:
self.CTNAddChild(pname, ptype)
except Exception, exc:
- self.GetCTRoot().logger.write_error(_("Could not add child \"%s\", type %s :\n%s\n")%(pname, ptype, unicode(exc)))
+ msg = _("Could not add child \"{a1}\", type {a2} :\n{a3}\n").format(a1 = pname, a2 = ptype, a3 = unicode(exc))
+ self.GetCTRoot().logger.write_error(msg)
self.GetCTRoot().logger.write_error(traceback.format_exc())
diff -r a375e31bf312 -r c1298e7ffe3a IDEFrame.py
--- a/IDEFrame.py Sun Mar 05 00:38:25 2017 +0000
+++ b/IDEFrame.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,3 +1,26 @@
+#!/usr/bin/env python
+# -*- coding: utf-8 -*-
+
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import os, sys
import cPickle
@@ -41,7 +64,8 @@
# Define PLCOpenEditor DisplayMenu extra items id
[ID_PLCOPENEDITORDISPLAYMENURESETPERSPECTIVE,
-] = [wx.NewId() for _init_coll_DisplayMenu_Items in range(1)]
+ ID_PLCOPENEDITORDISPLAYMENUSWITCHPERSPECTIVE,
+] = [wx.NewId() for _init_coll_DisplayMenu_Items in range(2)]
#-------------------------------------------------------------------------------
# EditorToolBar definitions
@@ -419,6 +443,10 @@
self.Bind(wx.EVT_MENU, self.GenerateZoomFunction(idx), id=new_id)
parent.AppendSeparator()
+ AppendMenu(parent, help='', id=ID_PLCOPENEDITORDISPLAYMENUSWITCHPERSPECTIVE,
+ kind=wx.ITEM_NORMAL, text=_(u'Switch perspective') + '\tF12')
+ self.Bind(wx.EVT_MENU, self.SwitchFullScrMode, id=ID_PLCOPENEDITORDISPLAYMENUSWITCHPERSPECTIVE)
+
AppendMenu(parent, help='', id=ID_PLCOPENEDITORDISPLAYMENURESETPERSPECTIVE,
kind=wx.ITEM_NORMAL, text=_(u'Reset Perspective'))
self.Bind(wx.EVT_MENU, self.OnResetPerspective, id=ID_PLCOPENEDITORDISPLAYMENURESETPERSPECTIVE)
@@ -444,10 +472,17 @@
self._init_coll_DisplayMenu_Items(self.DisplayMenu)
self._init_coll_HelpMenu_Items(self.HelpMenu)
+ def _init_icon(self, parent):
+ if self.icon:
+ self.SetIcon(self.icon)
+ elif parent and parent.icon:
+ self.SetIcon(parent.icon)
+
def _init_ctrls(self, prnt):
wx.Frame.__init__(self, id=ID_PLCOPENEDITOR, name='IDEFrame',
parent=prnt, pos=wx.DefaultPosition, size=wx.Size(1000, 600),
style=wx.DEFAULT_FRAME_STYLE)
+ self._init_icon(prnt)
self.SetClientSize(wx.Size(1000, 600))
self.Bind(wx.EVT_ACTIVATE, self.OnActivated)
@@ -1225,6 +1260,7 @@
def OnFindMenu(self, event):
if not self.FindDialog.IsShown():
self.FindDialog.Show()
+ self.FindDialog.FindPattern.SetFocus()
def CloseFindInPouDialog(self):
selected = self.TabsOpened.GetSelection()
@@ -1249,10 +1285,11 @@
dialog = SearchInProjectDialog(self)
if dialog.ShowModal() == wx.ID_OK:
criteria = dialog.GetCriteria()
- result = self.Controler.SearchInProject(criteria)
- self.ClearSearchResults()
- self.SearchResultPanel.SetSearchResults(criteria, result)
- self.SelectTab(self.SearchResultPanel)
+ if len(criteria) > 0:
+ result = self.Controler.SearchInProject(criteria)
+ self.ClearSearchResults()
+ self.SearchResultPanel.SetSearchResults(criteria, result)
+ self.SelectTab(self.SearchResultPanel)
#-------------------------------------------------------------------------------
# Display Menu Functions
@@ -1408,15 +1445,18 @@
def OnTabsOpenedDClick(event):
pos = event.GetPosition()
if tabctrl.TabHitTest(pos.x, pos.y, None):
- pane = self.AUIManager.GetPane(self.TabsOpened)
- if pane.IsMaximized():
- self.AUIManager.RestorePane(pane)
- else:
- self.AUIManager.MaximizePane(pane)
- self.AUIManager.Update()
+ self.SwitchFullScrMode(event)
event.Skip()
return OnTabsOpenedDClick
+ def SwitchFullScrMode(self,evt):
+ pane = self.AUIManager.GetPane(self.TabsOpened)
+ if pane.IsMaximized():
+ self.AUIManager.RestorePane(pane)
+ else:
+ self.AUIManager.MaximizePane(pane)
+ self.AUIManager.Update()
+
#-------------------------------------------------------------------------------
# Types Tree Management Functions
#-------------------------------------------------------------------------------
@@ -1451,8 +1491,7 @@
item_name = _(item_name)
self.ProjectTree.SetItemText(root, item_name)
self.ProjectTree.SetPyData(root, infos)
- highlight_colours = self.Highlights.get(infos.get("tagname", None), (wx.WHITE, wx.BLACK))
- self.ProjectTree.SetItemBackgroundColour(root, highlight_colours[0])
+ highlight_colours = self.Highlights.get(infos.get("tagname", None), (wx.Colour(255, 255, 255, 0), wx.BLACK))
self.ProjectTree.SetItemTextColour(root, highlight_colours[1])
self.ProjectTree.SetItemExtraImage(root, None)
if infos["type"] == ITEM_POU:
@@ -1582,6 +1621,8 @@
self.RefreshLibraryPanel()
self.RefreshPageTitles()
elif item_infos["type"] == ITEM_TRANSITION:
+ pou_item = self.ProjectTree.GetItemParent(event.GetItem())
+ pou_name = self.ProjectTree.GetItemText(pou_item)
if new_name.upper() in [name.upper() for name in self.Controler.GetProjectPouNames()]:
message = _("A POU named \"%s\" already exists!")%new_name
elif new_name.upper() in [name.upper() for name in self.Controler.GetProjectPouVariableNames(pou_name) if name != old_name]:
@@ -1593,6 +1634,8 @@
self.Controler.ComputePouTransitionName(words[1], new_name))
self.RefreshPageTitles()
elif item_infos["type"] == ITEM_ACTION:
+ pou_item = self.ProjectTree.GetItemParent(event.GetItem())
+ pou_name = self.ProjectTree.GetItemText(pou_item)
if new_name.upper() in [name.upper() for name in self.Controler.GetProjectPouNames()]:
message = _("A POU named \"%s\" already exists!")%new_name
elif new_name.upper() in [name.upper() for name in self.Controler.GetProjectPouVariableNames(pou_name) if name != old_name]:
@@ -1645,8 +1688,6 @@
if message or abort:
if message:
self.ShowErrorMessage(message)
- item = event.GetItem()
- wx.CallAfter(self.ProjectTree.EditLabel, item)
event.Veto()
else:
wx.CallAfter(self.RefreshProjectTree)
@@ -1918,7 +1959,7 @@
self.Bind(wx.EVT_MENU, self.OnDeleteMenu, id=new_id)
if menu is not None:
- self.PopupMenu(menu)
+ self.FindFocus().PopupMenu(menu)
menu.Destroy()
self.ResetSelectedItem()
diff -r a375e31bf312 -r c1298e7ffe3a NativeLib.py
--- a/NativeLib.py Sun Mar 05 00:38:25 2017 +0000
+++ b/NativeLib.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,3 +1,27 @@
+#!/usr/bin/env python
+# -*- coding: utf-8 -*-
+
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+
import os
from POULibrary import POULibrary
diff -r a375e31bf312 -r c1298e7ffe3a PLCControler.py
--- a/PLCControler.py Sun Mar 05 00:38:25 2017 +0000
+++ b/PLCControler.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
from xml.dom import minidom
from types import StringType, UnicodeType, TupleType
@@ -967,7 +967,8 @@
# programs cannot be pasted as functions or function blocks
if orig_type == 'functionBlock' and pou_type == 'function' or \
orig_type == 'program' and pou_type in ['function', 'functionBlock']:
- return _('''%s "%s" can't be pasted as a %s.''') % (orig_type, name, pou_type)
+ msg = _('''{a1} "{a2}" can't be pasted as a {a3}.''').format(a1 = orig_type, a2 = name, a3 = pou_type)
+ return msg
new_pou.setpouType(pou_type)
@@ -1962,7 +1963,7 @@
for dimension in element_type.getdimension():
dimensions.append((dimension.getlower(), dimension.getupper()))
base_type = element_type.baseType.getcontent()
- base_type_type = element_type.getLocalTag()
+ base_type_type = base_type.getLocalTag()
element_infos["Type"] = ("array",
base_type.getname()
if base_type_type == "derived"
@@ -1972,7 +1973,7 @@
else:
element_infos["Type"] = element_type_type.upper()
if element.initialValue is not None:
- element_infos["Initial Value"] = str(element.initialValue.getvalue())
+ element_infos["Initial Value"] = element.initialValue.getvalue()
else:
element_infos["Initial Value"] = ""
infos["elements"].append(element_infos)
@@ -1983,7 +1984,7 @@
else basetype_content_type.upper())
if datatype.initialValue is not None:
- infos["initial"] = str(datatype.initialValue.getvalue())
+ infos["initial"] = datatype.initialValue.getvalue()
else:
infos["initial"] = ""
return infos
@@ -2062,6 +2063,8 @@
if element_infos["Type"][0] == "array":
array_type, base_type_name, dimensions = element_infos["Type"]
array = PLCOpenParser.CreateElement("array", "dataType")
+ baseType = PLCOpenParser.CreateElement("baseType", "array")
+ array.setbaseType(baseType)
element_type.setcontent(array)
for j, dimension in enumerate(dimensions):
dimension_range = PLCOpenParser.CreateElement("dimension", "array")
@@ -2072,7 +2075,7 @@
else:
array.appenddimension(dimension_range)
if base_type_name in self.GetBaseTypes():
- array.baseType.setcontent(PLCOpenParser.CreateElement(
+ baseType.setcontent(PLCOpenParser.CreateElement(
base_type_name.lower()
if base_type_name in ["STRING", "WSTRING"]
else base_type_name, "dataType"))
@@ -2181,7 +2184,7 @@
if pou is not None:
return self.GetPouInterfaceReturnType(pou, tree, debug)
elif words[0] == 'T':
- return "BOOL"
+ return ["BOOL", ([], [])]
return None
# Change the edited element text
@@ -2315,7 +2318,7 @@
new_id = {}
try:
- instances, error = LoadPouInstances(text.encode("utf-8"), bodytype)
+ instances, error = LoadPouInstances(text, bodytype)
except:
instances, error = [], ""
if error is not None or len(instances) == 0:
@@ -3190,7 +3193,14 @@
def SearchInPou(self, tagname, criteria, debug=False):
pou = self.GetEditedElement(tagname, debug)
if pou is not None:
- return pou.Search(criteria)
+ search_results = pou.Search(criteria, [tagname])
+ if tagname.split("::")[0] in ['A', 'T']:
+ parent_pou_tagname = "P::%s" % (tagname.split("::")[-2])
+ parent_pou = self.GetEditedElement(parent_pou_tagname, debug)
+ for infos, start, end, text in parent_pou.Search(criteria):
+ if infos[1] in ["var_local", "var_input", "var_output", "var_inout"]:
+ search_results.append((infos, start, end, text))
+ return search_results
return []
#-------------------------------------------------------------------------------
diff -r a375e31bf312 -r c1298e7ffe3a PLCGenerator.py
--- a/PLCGenerator.py Sun Mar 05 00:38:25 2017 +0000
+++ b/PLCGenerator.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
from plcopen import PLCOpenParser
from plcopen.structures import *
@@ -393,6 +393,11 @@
single = task.getsingle()
# Single argument if exists
if single is not None:
+ if len(single) == 0:
+ msg = _("Source signal has to be defined for single task '{a1}' in resource '{a2}.{a3}'.").\
+ format(a1 = task.getname(), a2 = config_name, a3 = resource.getname())
+ raise PLCGenException, msg
+
if single[0]=='[' and single[-1]==']' :
SNGLKW = "MULTI"
else:
@@ -763,7 +768,10 @@
content = instance.getconditionContent()
if content["type"] == "connection":
self.ConnectionTypes[content["value"]] = "BOOL"
- for link in content["value"].getconnections():
+ connections = content["value"].getconnections()
+ if not connections:
+ raise PLCGenException, _("SFC transition in POU \"%s\" must be connected.") % self.Name
+ for link in connections:
connected = self.GetLinkedConnector(link, body)
if connected is not None and not self.ConnectionTypes.has_key(connected):
for related in self.ExtractRelatedConnections(connected):
@@ -775,7 +783,8 @@
for element in body.getcontentInstances():
if isinstance(element, ConnectorClass) and element.getname() == name:
if connector is not None:
- raise PLCGenException, _("More than one connector found corresponding to \"%s\" continuation in \"%s\" POU")%(name, self.Name)
+ msg = _("More than one connector found corresponding to \"{a1}\" continuation in \"{a2}\" POU").format(a1 = name, a2 = self.Name)
+ raise PLCGenException, msg
connector = element
if connector is not None:
undefined = [instance.connectionPointOut, connector.connectionPointIn]
@@ -794,7 +803,8 @@
for connection in related:
self.ConnectionTypes[connection] = var_type
else:
- raise PLCGenException, _("No connector found corresponding to \"%s\" continuation in \"%s\" POU")%(name, self.Name)
+ msg = _("No connector found corresponding to \"{a1}\" continuation in \"{a2}\" POU").format(a1 = name, a2 = self.Name)
+ raise PLCGenException, msg
elif isinstance(instance, BlockClass):
block_infos = self.GetBlockType(instance.gettypeName(), "undefined")
if block_infos is not None:
@@ -948,7 +958,7 @@
if block_infos is None:
block_infos = self.GetBlockType(block_type)
if block_infos is None:
- raise PLCGenException, _("Undefined block type \"%s\" in \"%s\" POU")%(block_type, self.Name)
+ raise PLCGenException, _("Undefined block type \"{a1}\" in \"{a2}\" POU").format(a1 = block_type, a2 = self.Name)
try:
self.GenerateBlock(instance, block_infos, body, None)
except ValueError, e:
@@ -1088,7 +1098,8 @@
self.Program += JoinList([(", ", ())], vars)
self.Program += [(");\n", ())]
else:
- self.Warnings.append(_("\"%s\" function cancelled in \"%s\" POU: No input connected")%(type, self.TagName.split("::")[-1]))
+ msg = _("\"{a1}\" function cancelled in \"{a2}\" POU: No input connected").format(a1 = type, a2 = self.TagName.split("::")[-1])
+ self.Warnings.append(msg)
elif block_infos["type"] == "functionBlock":
if not self.ComputedBlocks.get(block, False) and not order:
self.ComputedBlocks[block] = True
@@ -1177,11 +1188,12 @@
if output_parameter is None:
output_parameter = ""
if name:
- blockname = "%s(%s)" % (name, type)
+ blockname = "{a1}({a2})".format(a1 = name, a2 = type)
else:
blockname = type
- raise ValueError, _("No output %s variable found in block %s in POU %s. Connection must be broken") % \
- (output_parameter, blockname, self.Name)
+ msg = _("No output {a1} variable found in block {a2} in POU {a3}. Connection must be broken").\
+ format(a1 = output_parameter, a2 = blockname, a3 = self.Name)
+ raise ValueError, msg
def GeneratePaths(self, connections, body, order = False, to_inout = False):
paths = []
@@ -1199,7 +1211,8 @@
if block_infos is None:
block_infos = self.GetBlockType(block_type)
if block_infos is None:
- raise PLCGenException, _("Undefined block type \"%s\" in \"%s\" POU")%(block_type, self.Name)
+ msg = _("Undefined block type \"{a1}\" in \"{a2}\" POU").format(a1 = block_type, a2 = self.Name)
+ raise PLCGenException, msg
try:
paths.append(str(self.GenerateBlock(next, block_infos, body, connection, order, to_inout)))
except ValueError, e:
@@ -1214,7 +1227,8 @@
for instance in body.getcontentInstances():
if isinstance(instance, ConnectorClass) and instance.getname() == name:
if connector is not None:
- raise PLCGenException, _("More than one connector found corresponding to \"%s\" continuation in \"%s\" POU")%(name, self.Name)
+ msg = _("More than one connector found corresponding to \"{a1}\" continuation in \"{a2}\" POU").format(a1 = name, a2 = self.Name)
+ raise PLCGenException, msg
connector = instance
if connector is not None:
connections = connector.connectionPointIn.getconnections()
@@ -1224,7 +1238,8 @@
self.ComputedConnectors[name] = expression
paths.append(str(expression))
else:
- raise PLCGenException, _("No connector found corresponding to \"%s\" continuation in \"%s\" POU")%(name, self.Name)
+ msg = _("No connector found corresponding to \"{a1}\" continuation in \"{a2}\" POU").format(a1 = name, a2 = self.Name)
+ raise PLCGenException, msg
elif isinstance(next, ContactClass):
contact_info = (self.TagName, "contact", next.getlocalId())
variable = str(self.ExtractModifier(next, [(next.getvariable(), contact_info + ("reference",))], contact_info))
@@ -1372,6 +1387,10 @@
def GenerateSFCJump(self, jump, pou):
jump_target = jump.gettargetName()
+ if not pou.hasstep(jump_target):
+ pname = pou.getname()
+ msg = _("SFC jump in pou \"{a1}\" refers to non-existent SFC step \"{a2}\"").format( a1 = pname, a2 = jump_target)
+ raise PLCGenException, msg
if jump.connectionPointIn is not None:
instances = []
connections = jump.connectionPointIn.getconnections()
@@ -1576,7 +1595,9 @@
elif len(transition_infos["from"]) == 1:
self.Program += transition_infos["from"][0]
else:
- raise PLCGenException, _("Transition with content \"%s\" not connected to a previous step in \"%s\" POU")%(transition_infos["content"], self.Name)
+ msg = _("Transition with content \"{a1}\" not connected to a previous step in \"{a2}\" POU").\
+ format(a1 = transition_infos["content"], a2 = self.Name)
+ raise PLCGenException, msg
self.Program += [(" TO ", ())]
if len(transition_infos["to"]) > 1:
self.Program += [("(", ())]
@@ -1585,7 +1606,9 @@
elif len(transition_infos["to"]) == 1:
self.Program += transition_infos["to"][0]
else:
- raise PLCGenException, _("Transition with content \"%s\" not connected to a next step in \"%s\" POU")%(transition_infos["content"], self.Name)
+ msg = _("Transition with content \"{a1}\" not connected to a next step in \"{a2}\" POU").\
+ format(a1 = transition_infos["content"], a2 = self.Name)
+ raise PLCGenException, msg
self.Program += transition_infos["content"]
self.Program += [("%sEND_TRANSITION\n\n"%self.CurrentIndent, ())]
for [(step_name, step_infos)] in transition_infos["to"]:
diff -r a375e31bf312 -r c1298e7ffe3a PLCOpenEditor.py
--- a/PLCOpenEditor.py Sun Mar 05 00:38:25 2017 +0000
+++ b/PLCOpenEditor.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,29 +1,30 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import wx
import os, sys, platform, time, traceback, getopt
+import version
beremiz_dir = os.path.dirname(os.path.realpath(__file__))
@@ -60,7 +61,11 @@
# Create wxApp (Need to create App before internationalization because of
# Windows)
- app = wx.PySimpleApp()
+ if wx.VERSION >= (3, 0, 0):
+ app = wx.App()
+ else:
+ app = wx.PySimpleApp()
+
from util.misc import InstallLocalRessources
InstallLocalRessources(beremiz_dir)
@@ -72,6 +77,7 @@
from editors.Viewer import Viewer
from PLCControler import PLCControler
from dialogs import ProjectDialog
+from dialogs.AboutDialog import ShowAboutDialog
#-------------------------------------------------------------------------------
# PLCOpenEditor Main Class
@@ -160,6 +166,7 @@
# @param fileOpen The filepath to open if no controler defined (default: None).
# @param debug The filepath to open if no controler defined (default: False).
def __init__(self, parent, fileOpen = None):
+ self.icon = wx.Icon(os.path.join(beremiz_dir, "images", "poe.ico"), wx.BITMAP_TYPE_ICO)
IDEFrame.__init__(self, parent)
result = None
@@ -178,15 +185,15 @@
self._Refresh(PROJECTTREE, POUINSTANCEVARIABLESPANEL, LIBRARYTREE)
# Define PLCOpenEditor icon
- self.SetIcon(wx.Icon(os.path.join(beremiz_dir, "images", "poe.ico"),wx.BITMAP_TYPE_ICO))
+ self.SetIcon(self.icon)
self.Bind(wx.EVT_CLOSE, self.OnCloseFrame)
self._Refresh(TITLE, EDITORTOOLBAR, FILEMENU, EDITMENU, DISPLAYMENU)
if result is not None:
- self.ShowErrorMessage(
- _("PLC syntax error at line %d:\n%s") % result)
+ (num, line) = result
+ self.ShowErrorMessage(_("PLC syntax error at line {a1}:\n{a2}").format(a1 = num, a2 = line))
def OnCloseFrame(self, event):
if self.Controler is None or self.CheckSaveBeforeClosing(_("Close Application")):
@@ -298,8 +305,8 @@
dialog.Destroy()
if result is not None:
- self.ShowErrorMessage(
- _("PLC syntax error at line %d:\n%s") % result)
+ (num, line) = result
+ self.ShowErrorMessage(_("PLC syntax error at line {a1}:\n{a2}").format(a1 = num, a2 = line))
def OnCloseProjectMenu(self, event):
if not self.CheckSaveBeforeClosing():
@@ -343,7 +350,12 @@
open_pdf(os.path.join(beremiz_dir, "plcopen", "TC6_XML_V101.pdf"))
def OnAboutMenu(self, event):
- OpenHtmlFrame(self,_("About PLCOpenEditor"), os.path.join(beremiz_dir, "doc", "plcopen_about.html"), wx.Size(350, 350))
+ info = version.GetAboutDialogInfo()
+ info.Name = "PLCOpenEditor"
+ info.Description = _("PLCOpenEditor is part of Beremiz project.\n\n"
+ "Beremiz is an ") + info.Description
+ info.Icon = wx.Icon(os.path.join(beremiz_dir, "images", "aboutlogo.png"), wx.BITMAP_TYPE_PNG)
+ ShowAboutDialog(self, info)
def SaveProject(self):
result = self.Controler.SaveXMLFile()
@@ -394,16 +406,17 @@
dlg = wx.SingleChoiceDialog(None,
_("""
-An error has occurred.
-
-Click OK to save an error report.
+An unhandled exception (bug) occured. Bug report saved at :
+(%s)
Please be kind enough to send this file to:
-edouard.tisserant@gmail.com
-
-Error:
-""") +
- str(e_type) + _(" : ") + str(e_value),
+beremiz-devel@lists.sourceforge.net
+
+You should now restart program.
+
+Traceback:
+""") % bug_report_path +
+ repr(e_type) + " : " + repr(e_value),
_("Error"),
trcbck_lst)
try:
@@ -472,10 +485,11 @@
sys.excepthook = handle_exception
if __name__ == '__main__':
- wx.InitAllImageHandlers()
+ if wx.VERSION < (3, 0, 0):
+ wx.InitAllImageHandlers()
# Install a exception handle for bug reports
- AddExceptHook(os.getcwd(),__version__)
+ AddExceptHook(os.getcwd(), version.app_version)
frame = PLCOpenEditor(None, fileOpen=fileOpen)
diff -r a375e31bf312 -r c1298e7ffe3a POULibrary.py
--- a/POULibrary.py Sun Mar 05 00:38:25 2017 +0000
+++ b/POULibrary.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,3 +1,27 @@
+#!/usr/bin/env python
+# -*- coding: utf-8 -*-
+
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+
from weakref import ref
class POULibrary:
diff -r a375e31bf312 -r c1298e7ffe3a ProjectController.py
--- a/ProjectController.py Sun Mar 05 00:38:25 2017 +0000
+++ b/ProjectController.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,3 +1,27 @@
+#!/usr/bin/env python
+# -*- coding: utf-8 -*-
+
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+
"""
Beremiz Project Controller
"""
@@ -60,6 +84,60 @@
def GetAddMenuItems():
return ExtractMenuItemsFromCatalog(features.catalog)
+class Iec2CSettings():
+ def __init__(self):
+ self.iec2c = os.path.join(base_folder, "matiec", "iec2c"+(".exe" if wx.Platform == '__WXMSW__' else ""))
+ self.iec2c_buildopts = None
+ self.ieclib_path = os.path.join(base_folder, "matiec", "lib")
+ self.ieclib_c_path = None
+
+ def findLibCPath(self):
+ path=""
+ paths=[
+ os.path.join(base_folder, "matiec", "lib", "C"),
+ os.path.join(base_folder, "matiec", "lib") ]
+ for p in paths:
+ filename=os.path.join(p, "iec_types.h")
+ if (os.path.isfile(filename)):
+ path = p
+ break
+ return path
+
+ def findSupportedOptions(self):
+ buildcmd = "\"%s\" -h"%(self.iec2c)
+ options =["-f", "-l", "-p"]
+
+ buildopt = ""
+ try:
+ # Invoke compiler. Output files are listed to stdout, errors to stderr
+ status, result, err_result = ProcessLogger(self.logger, buildcmd,
+ no_stdout=True, no_stderr=True).spin()
+ except Exception,e:
+ return buildopt
+
+ for opt in options:
+ if opt in result:
+ buildopt = buildopt + " " + opt
+ return buildopt
+
+ def getCmd(self):
+ return self.iec2c
+
+ def getOptions(self):
+ if self.iec2c_buildopts is None:
+ self.iec2c_buildopts = self.findSupportedOptions()
+ return self.iec2c_buildopts
+
+ def getLibPath(self):
+ return self.ieclib_path
+
+ def getLibCPath(self):
+ if self.ieclib_c_path is None:
+ self.ieclib_c_path = self.findLibCPath()
+ return self.ieclib_c_path
+
+iec2c_cfg = Iec2CSettings()
+
class ProjectController(ConfigTreeNode, PLCControler):
"""
This class define Root object of the confnode tree.
@@ -115,10 +193,6 @@
self.DebugTicks = []
self.SetAppFrame(frame, logger)
- self.iec2c_path = os.path.join(base_folder, "matiec", "iec2c"+(".exe" if wx.Platform == '__WXMSW__' else ""))
- self.ieclib_path = os.path.join(base_folder, "matiec", "lib")
- self.ieclib_c_path = os.path.join(base_folder, "matiec", "lib", "C")
-
# Setup debug information
self.IECdebug_datas = {}
self.IECdebug_lock = Lock()
@@ -204,10 +278,10 @@
return self
def GetIECLibPath(self):
- return self.ieclib_c_path
+ return iec2c_cfg.getLibCPath()
def GetIEC2cPath(self):
- return self.iec2c_path
+ return iec2c_cfg.getCmd()
def GetCurrentLocation(self):
return ()
@@ -331,15 +405,15 @@
# Verify that project contains a PLCOpen program
plc_file = os.path.join(ProjectPath, "plc.xml")
if not os.path.isfile(plc_file):
- return _("Chosen folder doesn't contain a program. It's not a valid project!")
+ return _("Chosen folder doesn't contain a program. It's not a valid project!"), True
# Load PLCOpen file
error = self.OpenXMLFile(plc_file)
if error is not None:
if self.Project is not None:
- self.logger.write_warning(
- XSDSchemaErrorMessage % (("PLC",) + error))
+ (fname_err, lnum, src) = (("PLC",) + error)
+ self.logger.write_warning(XSDSchemaErrorMessage.format(a1 = fname_err, a2 = lnum, a3 = src))
else:
- return error
+ return error, False
if len(self.GetProjectConfigNames()) == 0:
self.AddProjectDefaultConfiguration()
# Change XSD into class members
@@ -353,20 +427,12 @@
#Load the confnode.xml file into parameters members
result = self.LoadXMLParams()
if result:
- return result
+ return result, False
#Load and init all the children
self.LoadChildren()
self.RefreshConfNodesBlockLists()
-
- if os.path.exists(self._getBuildPath()):
- self.EnableMethod("_Clean", True)
-
- if os.path.isfile(self._getIECcodepath()):
- self.ShowMethod("_showIECcode", True)
-
- self.UpdateMethodsFromPLCStatus()
-
- return None
+ self.UpdateButtons()
+ return None, False
def RecursiveConfNodeInfos(self, confnode):
values = []
@@ -399,6 +465,21 @@
self.ClearChildren()
self.ResetAppFrame(None)
+ def CheckNewProjectPath(self, old_project_path, new_project_path):
+ if old_project_path == new_project_path:
+ message = (_("Save path is the same as path of a project! \n"))
+ dialog = wx.MessageDialog(self.AppFrame, message, _("Error"), wx.OK | wx.ICON_ERROR)
+ dialog.ShowModal()
+ return False
+ else:
+ plc_file = os.path.join(new_project_path, "plc.xml")
+ if os.path.isfile(plc_file):
+ message = (_("Selected directory already contains another project. Overwrite? \n"))
+ dialog = wx.MessageDialog(self.AppFrame, message, _("Error"), wx.YES_NO | wx.ICON_ERROR)
+ answer = dialog.ShowModal()
+ return answer == wx.ID_YES
+ return True
+
def SaveProject(self, from_project_path=None):
if self.CheckProjectPathPerm(False):
if from_project_path is not None:
@@ -423,9 +504,10 @@
if answer == wx.ID_OK:
newprojectpath = dirdialog.GetPath()
if os.path.isdir(newprojectpath):
- self.ProjectPath, old_project_path = newprojectpath, self.ProjectPath
- self.SaveProject(old_project_path)
- self._setBuildPath(self.BuildPath)
+ if self.CheckNewProjectPath(self.ProjectPath, newprojectpath):
+ self.ProjectPath, old_project_path = newprojectpath, self.ProjectPath
+ self.SaveProject(old_project_path)
+ self._setBuildPath(self.BuildPath)
return True
return False
@@ -605,12 +687,15 @@
plc_file.close()
return True
+
+
def _Compile_ST_to_SoftPLC(self):
self.logger.write(_("Compiling IEC Program into C code...\n"))
buildpath = self._getBuildPath()
- buildcmd = "\"%s\" -f -l -p -I \"%s\" -T \"%s\" \"%s\""%(
- self.iec2c_path,
- self.ieclib_path,
+ buildcmd = "\"%s\" %s -I \"%s\" -T \"%s\" \"%s\""%(
+ iec2c_cfg.getCmd(),
+ iec2c_cfg.getOptions(),
+ iec2c_cfg.getLibPath(),
buildpath,
self._getIECcodepath())
@@ -679,7 +764,7 @@
# Keep track of generated C files for later use by self.CTNGenerate_C
self.PLCGeneratedCFiles = C_files
# compute CFLAGS for plc
- self.plcCFLAGS = '"-I%s" -Wno-unused-function'%self.ieclib_c_path
+ self.plcCFLAGS = '"-I%s" -Wno-unused-function'%iec2c_cfg.getLibCPath()
return True
def GetBuilder(self):
@@ -797,7 +882,7 @@
attrs["C_path"] = '__'.join(parts)
if attrs["vartype"] == "FB":
config_FBs[tuple(parts)] = attrs["C_path"]
- if attrs["vartype"] != "FB":
+ if attrs["vartype"] != "FB" and attrs["type"] in DebugTypesSize:
# Push this dictionnary into result.
self._DbgVariablesList.append(attrs)
# Fill in IEC<->C translation dicts
@@ -915,15 +1000,13 @@
# Eventually create build dir
if not os.path.exists(buildpath):
os.mkdir(buildpath)
- # There is something to clean
- self.EnableMethod("_Clean", True)
self.logger.flush()
self.logger.write(_("Start build in %s\n") % buildpath)
# Generate SoftPLC IEC code
IECGenRes = self._Generate_SoftPLC()
- self.ShowMethod("_showIECcode", True)
+ self.UpdateButtons()
# If IEC code gen fail, bail out.
if not IECGenRes:
@@ -1034,8 +1117,14 @@
def ShowError(self, logger, from_location, to_location):
chunk_infos = self.GetChunkInfos(from_location, to_location)
for infos, (start_row, start_col) in chunk_infos:
- start = (from_location[0] - start_row, from_location[1] - start_col)
- end = (to_location[0] - start_row, to_location[1] - start_col)
+ row = 1 if from_location[0] < start_row else (from_location[0] - start_row)
+ col = 1 if (start_row != from_location[0]) else (from_location[1] - start_col)
+ start = (row, col)
+
+ row = 1 if to_location[0] < start_row else (to_location[0] - start_row)
+ col = 1 if (start_row != to_location[0]) else (to_location[1] - start_col)
+ end = (row, col)
+
if self.AppFrame is not None:
self.AppFrame.ShowError(infos, start, end)
@@ -1068,6 +1157,7 @@
except:
text = '(* No IEC code have been generated at that time ! *)'
self._IECCodeView.SetText(text = text)
+ self._IECCodeView.Editor.SetReadOnly(True)
self._IECCodeView.SetIcon(GetBitmap("ST"))
setattr(self._IECCodeView, "_OnClose", self.OnCloseEditor)
@@ -1164,18 +1254,28 @@
shutil.rmtree(os.path.join(self._getBuildPath()))
else:
self.logger.write_error(_("Build directory already clean\n"))
- self.ShowMethod("_showIECcode", False)
- self.EnableMethod("_Clean", False)
# kill the builder
self._builder = None
self.CompareLocalAndRemotePLC()
-
+ self.UpdateButtons()
+
+ def _UpdateButtons(self):
+ self.EnableMethod("_Clean", os.path.exists(self._getBuildPath()))
+ self.ShowMethod("_showIECcode", os.path.isfile(self._getIECcodepath()))
+ if self.AppFrame is not None and not self.UpdateMethodsFromPLCStatus():
+ self.AppFrame.RefreshStatusToolBar()
+
+ def UpdateButtons(self):
+ wx.CallAfter(self._UpdateButtons)
+
+
def UpdatePLCLog(self, log_count):
if log_count:
if self.AppFrame is not None:
self.AppFrame.LogViewer.SetLogCounters(log_count)
def UpdateMethodsFromPLCStatus(self):
+ updated = False
status = None
if self._connector is not None:
PLCstatus = self._connector.GetPLCstatus()
@@ -1203,15 +1303,39 @@
self.ShowMethod(*args)
self.previous_plcstate = status
if self.AppFrame is not None:
+ updated = True
self.AppFrame.RefreshStatusToolBar()
if status == "Disconnected":
- self.AppFrame.ConnectionStatusBar.SetStatusText(_(status), 1)
+ self.AppFrame.ConnectionStatusBar.SetStatusText(self.GetTextStatus(status), 1)
self.AppFrame.ConnectionStatusBar.SetStatusText('', 2)
else:
self.AppFrame.ConnectionStatusBar.SetStatusText(
_("Connected to URI: %s") % self.BeremizRoot.getURI_location().strip(), 1)
- self.AppFrame.ConnectionStatusBar.SetStatusText(_(status), 2)
-
+ self.AppFrame.ConnectionStatusBar.SetStatusText(self.GetTextStatus(status), 2)
+ return updated
+
+ def GetTextStatus(self, status):
+ msgs = {
+ "Started": _("Started"),
+ "Stopped": _("Stopped"),
+ "Empty": _("Empty"),
+ "Broken": _("Broken"),
+ "Disconnected": _("Disconnected")
+ }
+ return msgs.get(status, status)
+
+ def ShowPLCProgress(self, status = "", progress = 0):
+ self.AppFrame.ProgressStatusBar.Show()
+ self.AppFrame.ConnectionStatusBar.SetStatusText(self.GetTextStatus(status), 1)
+ self.AppFrame.ProgressStatusBar.SetValue(progress)
+
+ def HidePLCProgress(self):
+ # clear previous_plcstate to restore status
+ # in UpdateMethodsFromPLCStatus()
+ self.previous_plcstate = ""
+ self.AppFrame.ProgressStatusBar.Hide()
+ self.UpdateMethodsFromPLCStatus()
+
def PullPLCStatusProc(self, event):
self.UpdateMethodsFromPLCStatus()
@@ -1505,6 +1629,7 @@
if connector is not None:
if self.StatusTimer is not None:
# Start the status Timer
+ wx.Yield()
self.StatusTimer.Start(milliseconds=500, oneShot=False)
else:
if self.StatusTimer is not None:
@@ -1654,6 +1779,7 @@
self.logger.write(_("Transfer completed successfully.\n"))
else:
self.logger.write_error(_("Transfer failed\n"))
+ self.HidePLCProgress()
else:
self.logger.write_error(_("No PLC to transfer (did build succeed ?)\n"))
diff -r a375e31bf312 -r c1298e7ffe3a c_ext/CFileEditor.py
--- a/c_ext/CFileEditor.py Sun Mar 05 00:38:25 2017 +0000
+++ b/c_ext/CFileEditor.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,3 +1,26 @@
+#!/usr/bin/env python
+# -*- coding: utf-8 -*-
+
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import wx.stc as stc
diff -r a375e31bf312 -r c1298e7ffe3a c_ext/__init__.py
--- a/c_ext/__init__.py Sun Mar 05 00:38:25 2017 +0000
+++ b/c_ext/__init__.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,1 +1,25 @@
+#!/usr/bin/env python
+# -*- coding: utf-8 -*-
+
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+
from c_ext import *
diff -r a375e31bf312 -r c1298e7ffe3a c_ext/c_ext.py
--- a/c_ext/c_ext.py Sun Mar 05 00:38:25 2017 +0000
+++ b/c_ext/c_ext.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,3 +1,26 @@
+#!/usr/bin/env python
+# -*- coding: utf-8 -*-
+
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import os
@@ -99,7 +122,7 @@
cfile.write(text)
cfile.close()
- matiec_flags = '"-l -p -I%s"'%os.path.abspath(self.GetCTRoot().GetIECLibPath())
+ matiec_CFLAGS = '"-I%s"'%os.path.abspath(self.GetCTRoot().GetIECLibPath())
- return [(Gen_Cfile_path, str(self.CExtension.getCFLAGS() + matiec_flags))],str(self.CExtension.getLDFLAGS()),True
+ return [(Gen_Cfile_path, str(self.CExtension.getCFLAGS() + matiec_CFLAGS))],str(self.CExtension.getLDFLAGS()),True
diff -r a375e31bf312 -r c1298e7ffe3a canfestival/NetworkEditor.py
--- a/canfestival/NetworkEditor.py Sun Mar 05 00:38:25 2017 +0000
+++ b/canfestival/NetworkEditor.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,3 +1,26 @@
+#!/usr/bin/env python
+# -*- coding: utf-8 -*-
+
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import wx
diff -r a375e31bf312 -r c1298e7ffe3a canfestival/SlaveEditor.py
--- a/canfestival/SlaveEditor.py Sun Mar 05 00:38:25 2017 +0000
+++ b/canfestival/SlaveEditor.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,3 +1,26 @@
+#!/usr/bin/env python
+# -*- coding: utf-8 -*-
+
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import wx
diff -r a375e31bf312 -r c1298e7ffe3a canfestival/__init__.py
--- a/canfestival/__init__.py Sun Mar 05 00:38:25 2017 +0000
+++ b/canfestival/__init__.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,1 +1,25 @@
+#!/usr/bin/env python
+# -*- coding: utf-8 -*-
+
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+
from canfestival import *
diff -r a375e31bf312 -r c1298e7ffe3a canfestival/canfestival.py
--- a/canfestival/canfestival.py Sun Mar 05 00:38:25 2017 +0000
+++ b/canfestival/canfestival.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,3 +1,27 @@
+#!/usr/bin/env python
+# -*- coding: utf-8 -*-
+
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+
import os, sys, shutil
base_folder = os.path.dirname(os.path.dirname(os.path.dirname(os.path.realpath(__file__))))
diff -r a375e31bf312 -r c1298e7ffe3a canfestival/config_utils.py
--- a/canfestival/config_utils.py Sun Mar 05 00:38:25 2017 +0000
+++ b/canfestival/config_utils.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of Beremiz, a Integrated Development Environment for
-#programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
from types import *
@@ -352,14 +352,16 @@
# Check Id is in slave node list
if nodeid not in self.NodeList.SlaveNodes.keys():
- raise PDOmappingException, _("Non existing node ID : %d (variable %s)") % (nodeid,name)
+ raise PDOmappingException, _("Non existing node ID : {a1} (variable {a2})").format(a1 = nodeid, a2 = name)
# Get the model for this node (made from EDS)
node = self.NodeList.SlaveNodes[nodeid]["Node"]
# Extract and check index and subindex
if not node.IsEntry(index, subindex):
- raise PDOmappingException, _("No such index/subindex (%x,%x) in ID : %d (variable %s)") % (index,subindex,nodeid,name)
+ msg = _("No such index/subindex ({a1},{a2}) in ID : {a3} (variable {a4})").\
+ format(a1 = "%x" % index, a2 ="%x" % subindex, a3 = nodeid, a4 = name)
+ raise PDOmappingException, msg
# Get the entry info
subentry_infos = node.GetSubentryInfos(index, subindex)
@@ -369,19 +371,23 @@
if sizelocation == "X" and len(loc) > 3:
numbit = loc[3]
elif sizelocation != "X" and len(loc) > 3:
- raise PDOmappingException, _("Cannot set bit offset for non bool '%s' variable (ID:%d,Idx:%x,sIdx:%x))") % (name,nodeid,index,subindex)
+ msg = _("Cannot set bit offset for non bool '{a1}' variable (ID:{a2},Idx:{a3},sIdx:{a4}))").\
+ format(a1 = name, a2 = nodeid, a3 = "%x" % index, a4 = "%x" % subindex)
+ raise PDOmappingException, msg
else:
numbit = None
if location["IEC_TYPE"] != "BOOL" and subentry_infos["type"] != COlocationtype:
- raise PDOmappingException, _("Invalid type \"%s\"-> %d != %d for location\"%s\"") % (location["IEC_TYPE"], COlocationtype, subentry_infos["type"] , name)
+ raise PDOmappingException, _("Invalid type \"{a1}\"-> {a2} != {a3} for location\"{a4}\"").\
+ format(a1 = location["IEC_TYPE"], a2 = COlocationtype, a3 = subentry_infos["type"] , a4 = name)
typeinfos = node.GetEntryInfos(COlocationtype)
self.IECLocations[name] = {"type":COlocationtype, "pdotype":SlavePDOType[direction],
"nodeid": nodeid, "index": index,"subindex": subindex,
"bit": numbit, "size": typeinfos["size"], "sizelocation": sizelocation}
else:
- raise PDOmappingException, _("Not PDO mappable variable : '%s' (ID:%d,Idx:%x,sIdx:%x))") % (name,nodeid,index,subindex)
+ raise PDOmappingException, _("Not PDO mappable variable : '{a1}' (ID:{a2},Idx:{a3},sIdx:{a4}))").\
+ format(a1 = name, a2 = nodeid, a3 = "%x" % index, a4 = "%x" % subindex)
#-------------------------------------------------------------------------------
# Search for locations already mapped
@@ -630,12 +636,14 @@
# Extract and check index and subindex
if not slave.IsEntry(index, subindex):
- raise PDOmappingException, _("No such index/subindex (%x,%x) (variable %s)") % (index, subindex, name)
+ raise PDOmappingException, _("No such index/subindex ({a1},{a2}) (variable {a3})").\
+ format(a1 = "%x" % index, a2 = "%x" % subindex, a3 = name)
# Get the entry info
subentry_infos = slave.GetSubentryInfos(index, subindex)
if subentry_infos["type"] != COlocationtype:
- raise PDOmappingException, _("Invalid type \"%s\"-> %d != %d for location\"%s\"") % (location["IEC_TYPE"], COlocationtype, subentry_infos["type"] , name)
+ raise PDOmappingException, _("Invalid type \"{a1}\"-> {a2} != {a3} for location \"{a4}\"").\
+ format( a1 = location["IEC_TYPE"], a2 = COlocationtype, a3 = subentry_infos["type"] , a4 = name)
IECLocations[name] = COlocationtype
pointers[(index, subindex)] = name
diff -r a375e31bf312 -r c1298e7ffe3a connectors/PYRO/__init__.py
--- a/connectors/PYRO/__init__.py Sun Mar 05 00:38:25 2017 +0000
+++ b/connectors/PYRO/__init__.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,23 +1,27 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
+
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
# See COPYING file for copyrights details.
#
-# This library is free software; you can redistribute it and/or
-# modify it under the terms of the GNU General Public
-# License as published by the Free Software Foundation; either
-# version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-# This library is distributed in the hope that it will be useful,
+# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-# General Public License for more details.
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-# You should have received a copy of the GNU General Public
-# License along with this library; if not, write to the Free Software
-# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+
import Pyro
import Pyro.core
import Pyro.util
@@ -83,7 +87,7 @@
ip = str(socket.inet_ntoa(i.getAddress()))
port = str(i.getPort())
newlocation = ip + ':' + port
- confnodesroot.logger.write(_("'%s' is located at %s\n") % (location, newlocation))
+ confnodesroot.logger.write(_("'{a1}' is located at {a2}\n").format(a1 = location, a2 = newlocation))
location = newlocation
r.close()
except Exception, msg:
@@ -108,10 +112,10 @@
try:
return func(*args, **kwargs)
except Pyro.errors.ConnectionClosedError, e:
- confnodesroot.logger.write_error("Connection lost!\n")
+ confnodesroot.logger.write_error(_("Connection lost!\n"))
confnodesroot._SetConnector(None)
except Pyro.errors.ProtocolError, e:
- confnodesroot.logger.write_error("Pyro exception: " + str(e) + "\n")
+ confnodesroot.logger.write_error(_("Pyro exception: %s\n") % e)
except Exception, e:
# confnodesroot.logger.write_error(traceback.format_exc())
errmess = ''.join(Pyro.util.getPyroTraceback(e))
diff -r a375e31bf312 -r c1298e7ffe3a connectors/WAMP/__init__.py
--- a/connectors/WAMP/__init__.py Sun Mar 05 00:38:25 2017 +0000
+++ b/connectors/WAMP/__init__.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,23 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
+
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2015: Edouard TISSERANT
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import sys, traceback, atexit
#from twisted.python import log
@@ -105,7 +108,7 @@
reactor, _WampSession.call, wampfuncname,
*args,**kwargs)
except TransportLost, e:
- confnodesroot.logger.write_error("Connection lost!\n")
+ confnodesroot.logger.write_error(_("Connection lost!\n"))
confnodesroot._SetConnector(None)
except Exception,e:
errmess = traceback.format_exc()
diff -r a375e31bf312 -r c1298e7ffe3a connectors/__init__.py
--- a/connectors/__init__.py Sun Mar 05 00:38:25 2017 +0000
+++ b/connectors/__init__.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,23 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
+
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
# See COPYING file for copyrights details.
#
-# This library is free software; you can redistribute it and/or
-# modify it under the terms of the GNU General Public
-# License as published by the Free Software Foundation; either
-# version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-# This library is distributed in the hope that it will be useful,
+# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-# General Public License for more details.
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-# You should have received a copy of the GNU General Public
-# License along with this library; if not, write to the Free Software
-# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
# Package initialisation
diff -r a375e31bf312 -r c1298e7ffe3a controls/CustomEditableListBox.py
--- a/controls/CustomEditableListBox.py Sun Mar 05 00:38:25 2017 +0000
+++ b/controls/CustomEditableListBox.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import wx
import wx.gizmos
diff -r a375e31bf312 -r c1298e7ffe3a controls/CustomGrid.py
--- a/controls/CustomGrid.py Sun Mar 05 00:38:25 2017 +0000
+++ b/controls/CustomGrid.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import wx
import wx.grid
@@ -37,8 +37,8 @@
self.UpButton = None
self.DownButton = None
- self.SetFont(wx.Font(12, 77, wx.NORMAL, wx.NORMAL, False, 'Sans'))
- self.SetLabelFont(wx.Font(10, 77, wx.NORMAL, wx.NORMAL, False, 'Sans'))
+ self.SetFont(wx.Font(12, wx.DEFAULT, wx.NORMAL, wx.NORMAL, False, 'Sans'))
+ self.SetLabelFont(wx.Font(10, wx.DEFAULT, wx.NORMAL, wx.NORMAL, False, 'Sans'))
self.SetSelectionBackground(wx.WHITE)
self.SetSelectionForeground(wx.BLACK)
self.DisableDragRowSize()
diff -r a375e31bf312 -r c1298e7ffe3a controls/CustomStyledTextCtrl.py
--- a/controls/CustomStyledTextCtrl.py Sun Mar 05 00:38:25 2017 +0000
+++ b/controls/CustomStyledTextCtrl.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,6 +1,27 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+
import wx
import wx.stc
diff -r a375e31bf312 -r c1298e7ffe3a controls/CustomTable.py
--- a/controls/CustomTable.py Sun Mar 05 00:38:25 2017 +0000
+++ b/controls/CustomTable.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,19 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
-#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
-#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import wx
import wx.grid
diff -r a375e31bf312 -r c1298e7ffe3a controls/CustomToolTip.py
--- a/controls/CustomToolTip.py Sun Mar 05 00:38:25 2017 +0000
+++ b/controls/CustomToolTip.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import wx
diff -r a375e31bf312 -r c1298e7ffe3a controls/CustomTree.py
--- a/controls/CustomTree.py Sun Mar 05 00:38:25 2017 +0000
+++ b/controls/CustomTree.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,19 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import wx
import wx.lib.agw.customtreectrl as CT
diff -r a375e31bf312 -r c1298e7ffe3a controls/DebugVariablePanel/DebugVariableGraphicViewer.py
--- a/controls/DebugVariablePanel/DebugVariableGraphicViewer.py Sun Mar 05 00:38:25 2017 +0000
+++ b/controls/DebugVariablePanel/DebugVariableGraphicViewer.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2012: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2012: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
from types import TupleType
from time import time as gettime
@@ -41,6 +41,12 @@
from DebugVariableViewer import *
from GraphButton import GraphButton
+
+from distutils.version import LooseVersion
+if LooseVersion(matplotlib.__version__) >= LooseVersion("1.5.0"):
+ from cycler import cycler
+
+
# Graph variable display type
GRAPH_PARALLEL, GRAPH_ORTHOGONAL = range(2)
@@ -975,7 +981,13 @@
kwargs["transform"] = self.Axes.transAxes
return text_func(*args, **kwargs)
return AddText
-
+
+ def SetAxesColor(self, color):
+ if LooseVersion(matplotlib.__version__) >= LooseVersion("1.5.0"):
+ self.Axes.set_prop_cycle(cycler('color',color))
+ else:
+ self.Axes.set_color_cycle(color)
+
def ResetGraphics(self):
"""
Reset figure and graphical elements displayed in it
@@ -987,7 +999,7 @@
# Add 3D projection if graph is in 3D
if self.Is3DCanvas():
self.Axes = self.Figure.gca(projection='3d')
- self.Axes.set_color_cycle(['b'])
+ self.SetAxesColor(['b'])
# Override function to prevent too much refresh when graph is
# rotated
@@ -1002,7 +1014,7 @@
else:
self.Axes = self.Figure.gca()
- self.Axes.set_color_cycle(COLOR_CYCLE)
+ self.SetAxesColor(COLOR_CYCLE)
# Set size of X and Y axis labels
self.Axes.tick_params(axis='x', labelsize='small')
@@ -1363,7 +1375,8 @@
# Get bitmap of figure rendered
self.bitmap = _convert_agg_to_wx_bitmap(self.get_renderer(), None)
- self.bitmap.UseAlpha()
+ if wx.VERSION < (3, 0, 0):
+ self.bitmap.UseAlpha()
# Create DC for rendering graphics in bitmap
destDC = wx.MemoryDC()
diff -r a375e31bf312 -r c1298e7ffe3a controls/DebugVariablePanel/DebugVariableItem.py
--- a/controls/DebugVariablePanel/DebugVariableItem.py Sun Mar 05 00:38:25 2017 +0000
+++ b/controls/DebugVariablePanel/DebugVariableItem.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
-#
-#Copyright (C) 2012: Edouard TISSERANT and Laurent BESSARD
-#
-#See COPYING file for copyrights details.
-#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
-#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
-#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2012: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import numpy
import binascii
diff -r a375e31bf312 -r c1298e7ffe3a controls/DebugVariablePanel/DebugVariablePanel.py
--- a/controls/DebugVariablePanel/DebugVariablePanel.py Sun Mar 05 00:38:25 2017 +0000
+++ b/controls/DebugVariablePanel/DebugVariablePanel.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2012: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2012: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
from types import TupleType
import math
@@ -50,10 +50,10 @@
# List of values possible for graph range
# Format is [(time_in_plain_text, value_in_nanosecond),...]
RANGE_VALUES = \
- [("%dms" % i, i * MILLISECOND) for i in (10, 20, 50, 100, 200, 500)] + \
- [("%ds" % i, i * SECOND) for i in (1, 2, 5, 10, 20, 30)] + \
- [("%dm" % i, i * MINUTE) for i in (1, 2, 5, 10, 20, 30)] + \
- [("%dh" % i, i * HOUR) for i in (1, 2, 3, 6, 12, 24)]
+ [(_("%dms") % i, i * MILLISECOND) for i in (10, 20, 50, 100, 200, 500)] + \
+ [(_("%ds") % i, i * SECOND) for i in (1, 2, 5, 10, 20, 30)] + \
+ [(_("%dm") % i, i * MINUTE) for i in (1, 2, 5, 10, 20, 30)] + \
+ [(_("%dh") % i, i * HOUR) for i in (1, 2, 3, 6, 12, 24)]
# Scrollbar increment in pixel
SCROLLBAR_UNIT = 10
@@ -291,6 +291,7 @@
DebugViewer.__init__(self, producer, True)
self.SetSizer(main_sizer)
+ self.SetTickTime()
def SetTickTime(self, ticktime=0):
"""
@@ -561,20 +562,20 @@
else:
tick = None
if tick is not None:
- self.TickLabel.SetLabel("Tick: %d" % tick)
+ self.TickLabel.SetLabel(label=_("Tick: %d") % tick)
tick_duration = int(tick * self.Ticktime)
not_null = False
duration = ""
- for value, format in [(tick_duration / DAY, "%dd"),
- ((tick_duration % DAY) / HOUR, "%dh"),
- ((tick_duration % HOUR) / MINUTE, "%dm"),
- ((tick_duration % MINUTE) / SECOND, "%ds")]:
+ for value, format in [(tick_duration / DAY, _("%dd")),
+ ((tick_duration % DAY) / HOUR, _("%dh")),
+ ((tick_duration % HOUR) / MINUTE, _("%dm")),
+ ((tick_duration % MINUTE) / SECOND, _("%ds"))]:
if value > 0 or not_null:
duration += format % value
not_null = True
- duration += "%gms" % (float(tick_duration % SECOND) / MILLISECOND)
+ duration += _("%03gms") % (float(tick_duration % SECOND) / MILLISECOND)
self.TickTimeLabel.SetLabel("t: %s" % duration)
else:
self.TickLabel.SetLabel("")
diff -r a375e31bf312 -r c1298e7ffe3a controls/DebugVariablePanel/DebugVariableTextViewer.py
--- a/controls/DebugVariablePanel/DebugVariableTextViewer.py Sun Mar 05 00:38:25 2017 +0000
+++ b/controls/DebugVariablePanel/DebugVariableTextViewer.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
-#
-#Copyright (C) 2012: Edouard TISSERANT and Laurent BESSARD
-#
-#See COPYING file for copyrights details.
-#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
-#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
-#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2012: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
from types import TupleType
diff -r a375e31bf312 -r c1298e7ffe3a controls/DebugVariablePanel/DebugVariableViewer.py
--- a/controls/DebugVariablePanel/DebugVariableViewer.py Sun Mar 05 00:38:25 2017 +0000
+++ b/controls/DebugVariablePanel/DebugVariableViewer.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2012: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2012: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
from collections import OrderedDict
diff -r a375e31bf312 -r c1298e7ffe3a controls/DebugVariablePanel/GraphButton.py
--- a/controls/DebugVariablePanel/GraphButton.py Sun Mar 05 00:38:25 2017 +0000
+++ b/controls/DebugVariablePanel/GraphButton.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2012: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2012: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import wx
diff -r a375e31bf312 -r c1298e7ffe3a controls/DebugVariablePanel/__init__.py
--- a/controls/DebugVariablePanel/__init__.py Sun Mar 05 00:38:25 2017 +0000
+++ b/controls/DebugVariablePanel/__init__.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,1 +1,26 @@
-from DebugVariablePanel import DebugVariablePanel
\ No newline at end of file
+#!/usr/bin/env python
+# -*- coding: utf-8 -*-
+
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2012: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+
+
+from DebugVariablePanel import DebugVariablePanel
diff -r a375e31bf312 -r c1298e7ffe3a controls/DurationCellEditor.py
--- a/controls/DurationCellEditor.py Sun Mar 05 00:38:25 2017 +0000
+++ b/controls/DurationCellEditor.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import wx
@@ -118,15 +118,22 @@
self.CellControl.SetValue(self.Table.GetValueByName(row, self.Colname))
self.CellControl.SetFocus()
- def EndEdit(self, row, col, grid):
+ def EndEditInternal(self, row, col, grid, old_duration):
duration = self.CellControl.GetValue()
- old_duration = self.Table.GetValueByName(row, self.Colname)
changed = duration != old_duration
if changed:
self.Table.SetValueByName(row, self.Colname, duration)
self.CellControl.Disable()
return changed
+ if wx.VERSION >= (3, 0, 0):
+ def EndEdit(self, row, col, grid, oldval):
+ return self.EndEditInternal(row, col, grid, oldval)
+ else:
+ def EndEdit(self, row, col, grid):
+ oldval = self.Table.GetValueByName(row, self.Colname)
+ return self.EndEditInternal(row, col, grid, oldval)
+
def SetSize(self, rect):
self.CellControl.SetDimensions(rect.x + 1, rect.y,
rect.width, rect.height,
diff -r a375e31bf312 -r c1298e7ffe3a controls/EnhancedStatusBar.py
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/controls/EnhancedStatusBar.py Fri Mar 24 12:07:47 2017 +0000
@@ -0,0 +1,248 @@
+# --------------------------------------------------------------------------- #
+# ENHANCEDSTATUSBAR wxPython IMPLEMENTATION
+# Python Code By:
+#
+# Andrea Gavana, @ 31 May 2005
+# Nitro, @ 21 September 2005
+# Latest Revision: 21 September 2005, 19.57.20 GMT+2
+# Latest Revision before Latest Revision: 21 September 2005, 18.29.35 GMT+2
+# Latest Revision before Latest Revision before Latest Revision: 31 May 2005, 23.17 CET
+#
+#
+# TODO List/Caveats
+#
+# 1. Some Requests/Features To Add?
+#
+#
+# For All Kind Of Problems, Requests Of Enhancements And Bug Reports, Please
+# Write To Me At:
+#
+#
+# andrea.gavana@agip.it
+# andrea_gavan@tin.it
+#
+# Or, Obviously, To The wxPython Mailing List!!!
+#
+#
+# licensed under wxWidgets License (GPL compatible)
+# End Of Comments
+# --------------------------------------------------------------------------- #
+
+""" Description:
+
+EnhancedStatusBar Is A Slight Modification (Actually A Subclassing) Of wx.StatusBar.
+It Allows You To Add Almost Any Widget You Like To The wx.StatusBar Of Your Main
+Frame Application And Also To Layout Them Properly.
+
+
+What It Can Do:
+
+1) Almost All The Functionalities Of wx.StatusBar Are Still Present;
+2) You Can Add Different Kind Of Widgets Into Every Field Of The EnhancedStatusBar;
+3) The AddWidget() Methods Accepts 2 Layout Inputs:
+ - horizontalalignment: This Specify The Horizontal Alignment For Your Widget,
+ And Can Be ESB_EXACT_FIT, ESB_ALIGN_CENTER_HORIZONTAL, ESB_ALIGN_LEFT And
+ ESB_ALIGN_RIGHT;
+ - varticalalignment: This Specify The Vertical Alignment For Your Widget,
+ And Can Be ESB_EXACT_FIT, ESB_ALIGN_CENTER_VERTICAL, ESB_ALIGN_BOTTOM And
+ ESB_ALIGN_LEFT;
+
+EnhancedStatusBar Is Freeware And Distributed Under The wxPython License.
+
+Latest Revision: 21 September 2005, 19.57.20 GMT+2
+Latest Revision before Latest Revision: 21 September 2005, 18.29.35 GMT+2
+Latest Revision before Latest Revision before Latest Revision: 31 May 2005, 23.17 CET
+
+"""
+
+import wx
+
+# Horizontal Alignment Constants
+ESB_ALIGN_CENTER_VERTICAL = 1
+ESB_ALIGN_TOP = 2
+ESB_ALIGN_BOTTOM = 3
+
+# Vertical Alignment Constants
+ESB_ALIGN_CENTER_HORIZONTAL = 11
+ESB_ALIGN_LEFT = 12
+ESB_ALIGN_RIGHT = 13
+
+# Exact Fit (Either Horizontal Or Vertical Or Both) Constant
+ESB_EXACT_FIT = 20
+
+
+# ---------------------------------------------------------------
+# Class EnhancedStatusBar
+# ---------------------------------------------------------------
+# This Is The Main Class Implementation. See The Demo For Details
+# ---------------------------------------------------------------
+class EnhancedStatusBarItem(object):
+ def __init__(self, widget, pos, horizontalalignment=ESB_ALIGN_CENTER_HORIZONTAL, verticalalignment=ESB_ALIGN_CENTER_VERTICAL):
+ self.__dict__.update( locals() )
+
+class EnhancedStatusBar(wx.StatusBar):
+
+ def __init__(self, parent, id=wx.ID_ANY, style=wx.ST_SIZEGRIP,
+ name="EnhancedStatusBar"):
+ """Default Class Constructor.
+
+ EnhancedStatusBar.__init__(self, parent, id=wx.ID_ANY,
+ style=wx.ST_SIZEGRIP,
+ name="EnhancedStatusBar")
+ """
+
+ wx.StatusBar.__init__(self, parent, id, style, name)
+
+ self._items = {}
+ self._curPos = 0
+ self._parent = parent
+
+ wx.EVT_SIZE(self, self.OnSize)
+ wx.CallAfter(self.OnSize, None)
+
+
+ def OnSize(self, event):
+ """Handles The wx.EVT_SIZE Events For The StatusBar.
+
+ Actually, All The Calculations Linked To HorizontalAlignment And
+ VerticalAlignment Are Done In This Function."""
+
+ for pos, item in self._items.items():
+ widget, horizontalalignment, verticalalignment = item.widget, item.horizontalalignment, item.verticalalignment
+
+ rect = self.GetFieldRect(pos)
+ widgetpos = widget.GetPosition()
+ widgetsize = widget.GetSize()
+
+ rect = self.GetFieldRect(pos)
+
+ if horizontalalignment == ESB_EXACT_FIT:
+
+ if verticalalignment == ESB_EXACT_FIT:
+ """ 1 September 2015 Fix fit align """
+ widget.SetSize((rect.width-4, rect.height-4))
+ widget.SetPosition((rect.x+2, rect.y+2))
+ elif verticalalignment == ESB_ALIGN_CENTER_VERTICAL:
+ if widgetsize[1] < rect.width - 1:
+ diffs = (rect.height - widgetsize[1])/2
+ widget.SetSize((rect.width-2, widgetsize[1]))
+ widget.SetPosition((rect.x-1, rect.y+diffs))
+ else:
+ widget.SetSize((rect.width-2, widgetsize[1]))
+ widget.SetPosition((rect.x-1, rect.y-1))
+ elif verticalalignment == ESB_ALIGN_TOP:
+ widget.SetSize((rect.width-2, widgetsize[1]))
+ widget.SetPosition((rect.x-1, rect.y))
+ elif verticalalignment == ESB_ALIGN_BOTTOM:
+ widget.SetSize((rect.width-2, widgetsize[1]))
+ widget.SetPosition((rect.x-1, rect.height-widgetsize[1]))
+
+ elif horizontalalignment == ESB_ALIGN_LEFT:
+
+ xpos = rect.x - 1
+ if verticalalignment == ESB_EXACT_FIT:
+ widget.SetSize((widgetsize[0], rect.height-2))
+ widget.SetPosition((xpos, rect.y-1))
+ elif verticalalignment == ESB_ALIGN_CENTER_VERTICAL:
+ if widgetsize[1] < rect.height - 1:
+ diffs = (rect.height - widgetsize[1])/2
+ widget.SetPosition((xpos, rect.y+diffs))
+ else:
+ widget.SetSize((widgetsize[0], rect.height-2))
+ widget.SetPosition((xpos, rect.y-1))
+ elif verticalalignment == ESB_ALIGN_TOP:
+ widget.SetPosition((xpos, rect.y))
+ elif verticalalignment == ESB_ALIGN_BOTTOM:
+ widget.SetPosition((xpos, rect.height-widgetsize[1]))
+
+ elif horizontalalignment == ESB_ALIGN_RIGHT:
+
+ xpos = rect.x + rect.width - widgetsize[0] - 1
+ if verticalalignment == ESB_EXACT_FIT:
+ widget.SetSize((widgetsize[0], rect.height-2))
+ widget.SetPosition((xpos, rect.y-1))
+ elif verticalalignment == ESB_ALIGN_CENTER_VERTICAL:
+ if widgetsize[1] < rect.height - 1:
+ diffs = (rect.height - widgetsize[1])/2
+ widget.SetPosition((xpos, rect.y+diffs))
+ else:
+ widget.SetSize((widgetsize[0], rect.height-2))
+ widget.SetPosition((xpos, rect.y-1))
+ elif verticalalignment == ESB_ALIGN_TOP:
+ widget.SetPosition((xpos, rect.y))
+ elif verticalalignment == ESB_ALIGN_BOTTOM:
+ widget.SetPosition((xpos, rect.height-widgetsize[1]))
+
+ elif horizontalalignment == ESB_ALIGN_CENTER_HORIZONTAL:
+
+ xpos = rect.x + (rect.width - widgetsize[0])/2 - 1
+ if verticalalignment == ESB_EXACT_FIT:
+ widget.SetSize((widgetsize[0], rect.height))
+ widget.SetPosition((xpos, rect.y))
+ elif verticalalignment == ESB_ALIGN_CENTER_VERTICAL:
+ if widgetsize[1] < rect.height - 1:
+ diffs = (rect.height - widgetsize[1])/2
+ widget.SetPosition((xpos, rect.y+diffs))
+ else:
+ widget.SetSize((widgetsize[0], rect.height-1))
+ widget.SetPosition((xpos, rect.y+1))
+ elif verticalalignment == ESB_ALIGN_TOP:
+ widget.SetPosition((xpos, rect.y))
+ elif verticalalignment == ESB_ALIGN_BOTTOM:
+ widget.SetPosition((xpos, rect.height-widgetsize[1]))
+
+
+ if event is not None:
+ event.Skip()
+
+
+ def AddWidget(self, widget, horizontalalignment=ESB_ALIGN_CENTER_HORIZONTAL,
+ verticalalignment=ESB_ALIGN_CENTER_VERTICAL, pos = -1):
+ """Add A Widget To The EnhancedStatusBar.
+
+ Parameters:
+
+ - horizontalalignment: This Can Be One Of:
+ a) ESB_EXACT_FIT: The Widget Will Fit Horizontally The StatusBar Field Width;
+ b) ESB_ALIGN_CENTER_HORIZONTAL: The Widget Will Be Centered Horizontally In
+ The StatusBar Field;
+ c) ESB_ALIGN_LEFT: The Widget Will Be Left Aligned In The StatusBar Field;
+ d) ESB_ALIGN_RIGHT: The Widget Will Be Right Aligned In The StatusBar Field;
+
+ - verticalalignment:
+ a) ESB_EXACT_FIT: The Widget Will Fit Vertically The StatusBar Field Height;
+ b) ESB_ALIGN_CENTER_VERTICAL: The Widget Will Be Centered Vertically In
+ The StatusBar Field;
+ c) ESB_ALIGN_BOTTOM: The Widget Will Be Bottom Aligned In The StatusBar Field;
+ d) ESB_ALIGN_TOP: The Widget Will Be TOP Aligned In The StatusBar Field;
+
+ """
+
+ if pos == -1:
+ pos = self._curPos
+ self._curPos += 1
+
+ if self.GetFieldsCount() <= pos:
+ raise "\nERROR: EnhancedStatusBar has a max of %d items, you tried to set item #%d" % (self.GetFieldsCount(), pos)
+
+ if horizontalalignment not in [ESB_ALIGN_CENTER_HORIZONTAL, ESB_EXACT_FIT,
+ ESB_ALIGN_LEFT, ESB_ALIGN_RIGHT]:
+ raise '\nERROR: Parameter "horizontalalignment" Should Be One Of '\
+ '"ESB_ALIGN_CENTER_HORIZONTAL", "ESB_ALIGN_LEFT", "ESB_ALIGN_RIGHT"' \
+ '"ESB_EXACT_FIT"'
+
+ if verticalalignment not in [ESB_ALIGN_CENTER_VERTICAL, ESB_EXACT_FIT,
+ ESB_ALIGN_TOP, ESB_ALIGN_BOTTOM]:
+ raise '\nERROR: Parameter "verticalalignment" Should Be One Of '\
+ '"ESB_ALIGN_CENTER_VERTICAL", "ESB_ALIGN_TOP", "ESB_ALIGN_BOTTOM"' \
+ '"ESB_EXACT_FIT"'
+
+
+ try:
+ self.RemoveChild(self._items[pos].widget)
+ self._items[pos].widget.Destroy()
+ except KeyError: pass
+
+ self._items[pos] = EnhancedStatusBarItem(widget, pos, horizontalalignment, verticalalignment)
+
+ wx.CallAfter(self.OnSize, None)
diff -r a375e31bf312 -r c1298e7ffe3a controls/FolderTree.py
--- a/controls/FolderTree.py Sun Mar 05 00:38:25 2017 +0000
+++ b/controls/FolderTree.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
-#
-#Copyright (C) 2013: Edouard TISSERANT and Laurent BESSARD
-#
-#See COPYING file for copyrights details.
-#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
-#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
-#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2013: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import os
diff -r a375e31bf312 -r c1298e7ffe3a controls/LibraryPanel.py
--- a/controls/LibraryPanel.py Sun Mar 05 00:38:25 2017 +0000
+++ b/controls/LibraryPanel.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import wx
@@ -67,8 +67,12 @@
self.OnSearchButtonClick, self.SearchCtrl)
# Bind keyboard event on SearchCtrl text control to catch UP and DOWN
# for search previous and next occurrence
- search_textctrl = self.SearchCtrl.GetChildren()[0]
- search_textctrl.Bind(wx.EVT_CHAR, self.OnKeyDown)
+
+ # This protects from fail to start when no children[0] available (possible for wxPython 3.0)
+ if self.SearchCtrl.GetChildren():
+ search_textctrl = self.SearchCtrl.GetChildren()[0]
+ search_textctrl.Bind(wx.EVT_CHAR, self.OnKeyDown)
+
main_sizer.AddWindow(self.SearchCtrl, flag=wx.GROW)
# Add Splitter window for tree and block comment to main sizer
@@ -397,7 +401,7 @@
item_pydata = self.Tree.GetPyData(item)
# Item is a block category
- if item_pydata["type"] == CATEGORY:
+ if (item == root) or item_pydata["type"] == CATEGORY:
# Get category first or last child according to search mode
# defined
diff -r a375e31bf312 -r c1298e7ffe3a controls/LocationCellEditor.py
--- a/controls/LocationCellEditor.py Sun Mar 05 00:38:25 2017 +0000
+++ b/controls/LocationCellEditor.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import wx
@@ -95,7 +95,7 @@
if not infos["location"].startswith("%"):
dialog = wx.SingleChoiceDialog(self,
_("Select a variable class:"), _("Variable class"),
- ["Input", "Output", "Memory"],
+ [_("Input"), _("Output"), _("Memory")],
wx.DEFAULT_DIALOG_STYLE|wx.OK|wx.CANCEL)
if dialog.ShowModal() == wx.ID_OK:
selected = dialog.GetSelection()
@@ -161,15 +161,22 @@
self.CellControl.SetVarType(self.Table.GetValueByName(row, 'Type'))
self.CellControl.SetFocus()
- def EndEdit(self, row, col, grid):
+ def EndEditInternal(self, row, col, grid, old_loc):
loc = self.CellControl.GetValue()
- old_loc = self.Table.GetValueByName(row, 'Location')
changed = loc != old_loc
if changed:
self.Table.SetValueByName(row, 'Location', loc)
self.Table.SetValueByName(row, 'Type', self.CellControl.GetVarType())
self.CellControl.Disable()
return changed
+
+ if wx.VERSION >= (3, 0, 0):
+ def EndEdit(self, row, col, grid, oldval):
+ return self.EndEditInternal(row, col, grid, oldval)
+ else:
+ def EndEdit(self, row, col, grid):
+ old_loc = self.Table.GetValueByName(row, 'Location')
+ return self.EndEditInternal(row, col, grid, old_loc)
def SetSize(self, rect):
self.CellControl.SetDimensions(rect.x + 1, rect.y,
diff -r a375e31bf312 -r c1298e7ffe3a controls/LogViewer.py
--- a/controls/LogViewer.py Sun Mar 05 00:38:25 2017 +0000
+++ b/controls/LogViewer.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,27 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2013: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2013: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+
from datetime import datetime
from time import time as gettime
@@ -176,7 +177,7 @@
dc.EndDrawing()
event.Skip()
-BUTTON_SIZE = (30, 15)
+BUTTON_SIZE = (70, 15)
class LogButton():
diff -r a375e31bf312 -r c1298e7ffe3a controls/PouInstanceVariablesPanel.py
--- a/controls/PouInstanceVariablesPanel.py Sun Mar 05 00:38:25 2017 +0000
+++ b/controls/PouInstanceVariablesPanel.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2012: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2012: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
from collections import namedtuple
@@ -93,7 +93,7 @@
images_bbx = self.GetItemRightImagesBBox(item)
r_image_w, r_image_h = self._imageListRight.GetSize(rightimages[0])
- dc.SetBrush(wx.WHITE_BRUSH)
+ dc.SetBrush(wx.TRANSPARENT_BRUSH)
dc.SetPen(wx.TRANSPARENT_PEN)
bg_width = (r_image_w + 4) * len(rightimages) + 4
@@ -350,8 +350,8 @@
self.InstanceChoice.SetFocusFromKbd()
size = self.InstanceChoice.GetSize()
event = wx.MouseEvent(wx.EVT_LEFT_DOWN._getEvtType())
- event.m_x = size.width / 2
- event.m_y = size.height / 2
+ event.x = size.width / 2
+ event.y = size.height / 2
event.SetEventObject(self.InstanceChoice)
#event = wx.KeyEvent(wx.EVT_KEY_DOWN._getEvtType())
#event.m_keyCode = wx.WXK_SPACE
diff -r a375e31bf312 -r c1298e7ffe3a controls/ProjectPropertiesPanel.py
--- a/controls/ProjectPropertiesPanel.py Sun Mar 05 00:38:25 2017 +0000
+++ b/controls/ProjectPropertiesPanel.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
-#
-#Copyright (C) 2012: Edouard TISSERANT and Laurent BESSARD
-#
-#See COPYING file for copyrights details.
-#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
-#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
-#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2012: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import wx
@@ -212,7 +212,7 @@
for param in REQUIRED_PARAMS:
getattr(self, param).Enable(enable_required)
- languages = ["", "en-US", "fr-FR", "zh-CN"]
+ languages = ["", "en-US", "fr-FR", "zh-CN", "ru-RU"]
for language in languages:
self.Language.Append(language)
diff -r a375e31bf312 -r c1298e7ffe3a controls/SearchResultPanel.py
--- a/controls/SearchResultPanel.py Sun Mar 05 00:38:25 2017 +0000
+++ b/controls/SearchResultPanel.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
-#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
-#
-#See COPYING file for copyrights details.
-#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
-#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
-#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
from types import TupleType
@@ -232,28 +232,15 @@
break
if element_type == ITEM_RESOURCE:
search_results_tree_children.append(element_infos)
- else:
- _tagname = self.ParentWindow.Controler.ComputePouName(words[1])
- _element_type = self.ParentWindow.Controler.GetPouType(words[1])
-
- _element_infos = {"name": words[1],
- "type": _element_type,
- "data": _tagname,
- "text": None,
- "matches": 1,
- "children": [element_infos]}
-
- search_results_tree_children.append(_element_infos)
-
else:
search_results_tree_children.append(element_infos)
if matches_number < 2:
- header_format = _("'%s' - %d match in project")
+ header_format = _("'{a1}' - {a2} match in project")
else:
- header_format = _("'%s' - %d matches in project")
-
- self.HeaderLabel.SetLabel(header_format % (self.Criteria["raw_pattern"], matches_number))
+ header_format = _("'{a1}' - {a2} matches in project")
+
+ self.HeaderLabel.SetLabel(header_format.format(a1 = self.Criteria["find_pattern"], a2 = matches_number))
self.ResetButton.Enable(True)
if matches_number > 0:
@@ -337,6 +324,7 @@
search_results = [data]
else:
search_results = self.SearchResults.get(data, [])
+ self.ParentWindow.ClearHighlights(SEARCH_RESULT_HIGHLIGHT)
for infos, start, end, text in search_results:
self.ParentWindow.ShowSearchResult(infos, start, end)
diff -r a375e31bf312 -r c1298e7ffe3a controls/TextCtrlAutoComplete.py
--- a/controls/TextCtrlAutoComplete.py Sun Mar 05 00:38:25 2017 +0000
+++ b/controls/TextCtrlAutoComplete.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of Beremiz, a Integrated Development Environment for
-#programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
-#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
-#
-#See COPYING file for copyrights details.
-#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
-#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
-#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import wx
import cPickle
@@ -87,13 +87,13 @@
return self.ListBox.GetStringSelection()
def OnLeftDown(self, event):
- selected = self.ListBox.HitTest(wx.Point(event.m_x, event.m_y))
+ selected = self.ListBox.HitTest(wx.Point(event.GetX(), event.GetY()))
parent_size = self.Parent.GetSize()
parent_rect = wx.Rect(0, -parent_size[1], parent_size[0], parent_size[1])
if selected != wx.NOT_FOUND:
wx.CallAfter(self.Parent.SetValueFromSelected, self.ListBox.GetString(selected))
- elif parent_rect.InsideXY(event.m_x, event.m_y):
- result, x, y = self.Parent.HitTest(wx.Point(event.m_x, event.m_y + parent_size[1]))
+ elif parent_rect.InsideXY(event.GetX(), event.GetY()):
+ result, x, y = self.Parent.HitTest(wx.Point(event.GetX(), event.GetY() + parent_size[1]))
if result != wx.TE_HT_UNKNOWN:
self.Parent.SetInsertionPoint(self.Parent.XYToPosition(x, y))
else:
@@ -102,7 +102,7 @@
def OnMotion(self, event):
self.ListBox.SetSelection(
- self.ListBox.HitTest(wx.Point(event.m_x, event.m_y)))
+ self.ListBox.HitTest(wx.Point(event.GetX(), event.GetY())))
event.Skip()
class TextCtrlAutoComplete(wx.TextCtrl):
diff -r a375e31bf312 -r c1298e7ffe3a controls/VariablePanel.py
--- a/controls/VariablePanel.py Sun Mar 05 00:38:25 2017 +0000
+++ b/controls/VariablePanel.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import os
import re
@@ -144,6 +144,14 @@
def GetOldValue(self):
return self.old_value
+ def _GetRowEdit(self, row):
+ row_edit = self.GetValueByName(row, "Edit")
+ var_type = self.Parent.GetTagName()
+ bodytype = self.Parent.Controler.GetEditedElementBodyType(var_type)
+ if bodytype in ["ST", "IL"]:
+ row_edit = True;
+ return row_edit
+
def _updateColAttrs(self, grid):
"""
wx.grid.Grid -> update the column attributes to add the
@@ -171,7 +179,7 @@
editor.SetParameters(",".join(map(_, options)))
else:
grid.SetReadOnly(row, col, True)
- elif col != 0 and self.GetValueByName(row, "Edit"):
+ elif col != 0 and self._GetRowEdit(row):
grid.SetReadOnly(row, col, False)
if colname == "Name":
editor = wx.grid.GridCellTextEditor()
@@ -238,7 +246,7 @@
self.ParentWindow.ParentWindow.Select()
x, y = self.ParentWindow.VariablesGrid.CalcUnscrolledPosition(x, y)
col = self.ParentWindow.VariablesGrid.XToCol(x)
- row = self.ParentWindow.VariablesGrid.YToRow(y - self.ParentWindow.VariablesGrid.GetColLabelSize())
+ row = self.ParentWindow.VariablesGrid.YToRow(y)
message = None
element_type = self.ParentWindow.ElementType
try:
@@ -265,7 +273,8 @@
if values[2] is not None:
base_location_type = self.ParentWindow.Controler.GetBaseType(values[2])
if values[2] != variable_type and base_type != base_location_type:
- message = _("Incompatible data types between \"%s\" and \"%s\"")%(values[2], variable_type)
+ message = _("Incompatible data types between \"{a1}\" and \"{a2}\"").\
+ format(a1 = values[2], a2 = variable_type)
if message is None:
if not location.startswith("%"):
@@ -274,11 +283,12 @@
elif location[0] not in LOCATIONDATATYPES:
message = _("Unrecognized data size \"%s\"")%location[0]
elif base_type not in LOCATIONDATATYPES[location[0]]:
- message = _("Incompatible size of data between \"%s\" and \"%s\"")%(location, variable_type)
+ message = _("Incompatible size of data between \"{a1}\" and \"{a2}\"").\
+ format(a1 = location, a2 = variable_type)
else:
dialog = wx.SingleChoiceDialog(self.ParentWindow.ParentWindow.ParentWindow,
_("Select a variable class:"), _("Variable class"),
- ["Input", "Output", "Memory"],
+ [_("Input"), _("Output"), _("Memory")],
wx.DEFAULT_DIALOG_STYLE|wx.OK|wx.CANCEL)
if dialog.ShowModal() == wx.ID_OK:
selected = dialog.GetSelection()
@@ -316,7 +326,7 @@
dlg = wx.TextEntryDialog(
self.ParentWindow.ParentWindow.ParentWindow,
_("Confirm or change variable name"),
- 'Variable Drop', var_name)
+ _('Variable Drop'), var_name)
dlg.SetValue(var_name)
var_name = dlg.GetValue() if dlg.ShowModal() == wx.ID_OK else None
dlg.Destroy()
@@ -338,7 +348,7 @@
if not location.startswith("%"):
dialog = wx.SingleChoiceDialog(self.ParentWindow.ParentWindow.ParentWindow,
_("Select a variable class:"), _("Variable class"),
- ["Input", "Output", "Memory"],
+ [_("Input"), _("Output"), _("Memory")],
wx.DEFAULT_DIALOG_STYLE|wx.OK|wx.CANCEL)
if dialog.ShowModal() == wx.ID_OK:
selected = dialog.GetSelection()
@@ -584,7 +594,7 @@
setattr(self.VariablesGrid, "_AddRow", _AddVariable)
def _DeleteVariable(row):
- if self.Table.GetValueByName(row, "Edit"):
+ if _GetRowEdit(row):
self.Values.remove(self.Table.GetRow(row))
self.SaveValues()
if self.ElementType == "resource":
@@ -603,6 +613,14 @@
return row
setattr(self.VariablesGrid, "_MoveRow", _MoveVariable)
+ def _GetRowEdit(row):
+ row_edit = False
+ if self:
+ row_edit = self.Table.GetValueByName(row, "Edit")
+ bodytype = self.Controler.GetEditedElementBodyType(self.TagName)
+ row_edit = row_edit or (bodytype in ["ST", "IL"])
+ return row_edit
+
def _RefreshButtons():
if self:
table_length = len(self.Table.data)
@@ -611,7 +629,7 @@
row = 0
if table_length > 0:
row = self.VariablesGrid.GetGridCursorRow()
- row_edit = self.Table.GetValueByName(row, "Edit")
+ row_edit = _GetRowEdit(row)
self.AddButton.Enable(not self.Debug)
self.DeleteButton.Enable(not self.Debug and (table_length > 0 and row_edit))
self.UpButton.Enable(not self.Debug and (table_length > 0 and row > 0 and self.Filter == "All"))
diff -r a375e31bf312 -r c1298e7ffe3a controls/__init__.py
--- a/controls/__init__.py Sun Mar 05 00:38:25 2017 +0000
+++ b/controls/__init__.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
# Package initialization
diff -r a375e31bf312 -r c1298e7ffe3a dialogs/AboutDialog.py
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/dialogs/AboutDialog.py Fri Mar 24 12:07:47 2017 +0000
@@ -0,0 +1,182 @@
+#!/usr/bin/env python
+# -*- coding: utf-8 -*-
+
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+# This file is based on code written for Whyteboard project.
+#
+# Copyright (c) 2009, 2010 by Steven Sproat
+# Copyright (c) 2016 by Andrey Skvortsov
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+#
+
+
+"""
+This module contains classes extended from wx.Dialog used by the GUI.
+"""
+
+import os
+import sys
+import time
+import wx
+from wx.lib.agw.hyperlink import HyperLinkCtrl
+
+
+#----------------------------------------------------------------------
+
+class AboutDialog(wx.Dialog):
+ """
+ A replacement About Dialog for Windows, as it uses a generic frame that
+ well...sucks.
+ """
+ def __init__(self, parent, info):
+ title = _("About") + " " + info.Name
+ wx.Dialog.__init__(self, parent, title=title)
+ self.info = info
+
+ if parent and parent.GetIcon():
+ self.SetIcon(parent.GetIcon())
+
+ image = None
+ if self.info.Icon:
+ bitmap = wx.BitmapFromIcon(self.info.Icon)
+ image = wx.StaticBitmap(self, bitmap=bitmap)
+
+ name = wx.StaticText(self, label="%s %s" % (info.Name, info.Version))
+ description = wx.StaticText(self, label=info.Description)
+ description.Wrap(400)
+ copyright = wx.StaticText(self, label=info.Copyright)
+ url = HyperLinkCtrl(self, label=info.WebSite[0], URL=info.WebSite[1])
+
+ font = name.GetClassDefaultAttributes().font
+ font.SetWeight(wx.FONTWEIGHT_BOLD)
+ font.SetPointSize(18)
+ name.SetFont(font)
+
+ credits = wx.Button(self, id=wx.ID_ABOUT, label=_("C&redits"))
+ license = wx.Button(self, label=_("&License"))
+ close = wx.Button(self, id=wx.ID_CANCEL, label=_("&Close"))
+
+ btnSizer = wx.BoxSizer(wx.HORIZONTAL)
+ btnSizer.Add(credits, flag=wx.CENTER | wx.LEFT | wx.RIGHT, border=5)
+ btnSizer.Add(license, flag=wx.CENTER | wx.RIGHT, border=5)
+ btnSizer.Add(close, flag=wx.CENTER | wx.RIGHT, border=5)
+
+ sizer = wx.BoxSizer(wx.VERTICAL)
+ if image:
+ sizer.Add(image, flag=wx.CENTER | wx.TOP | wx.BOTTOM, border=5)
+ sizer.Add(name, flag=wx.CENTER | wx.BOTTOM, border=10)
+ sizer.Add(description, flag=wx.CENTER | wx.BOTTOM, border=10)
+ sizer.Add(copyright, flag=wx.CENTER | wx.BOTTOM, border=10)
+ sizer.Add(url, flag=wx.CENTER | wx.BOTTOM, border=15)
+ sizer.Add(btnSizer, flag=wx.CENTER | wx.BOTTOM, border=5)
+
+ container = wx.BoxSizer(wx.VERTICAL)
+ container.Add(sizer, flag=wx.ALL, border=10)
+ self.SetSizer(container)
+ self.Layout()
+ self.Fit()
+ self.Centre()
+ self.Show(True)
+ self.SetEscapeId(close.GetId())
+
+ credits.Bind(wx.EVT_BUTTON, self.on_credits)
+ license.Bind(wx.EVT_BUTTON, self.on_license)
+ close.Bind(wx.EVT_BUTTON, lambda evt: self.Destroy())
+
+ def on_license(self, event):
+ LicenseDialog(self, self.info)
+
+ def on_credits(self, event):
+ CreditsDialog(self, self.info)
+
+
+#----------------------------------------------------------------------
+
+class CreditsDialog(wx.Dialog):
+ def __init__(self, parent, info):
+ wx.Dialog.__init__(self, parent, title=_("Credits"), size=(475, 320),
+ style=wx.DEFAULT_DIALOG_STYLE | wx.RESIZE_BORDER)
+
+ if parent and parent.GetIcon():
+ self.SetIcon(parent.GetIcon())
+
+ self.SetMinSize((300, 200))
+ notebook = wx.Notebook(self)
+ close = wx.Button(self, id=wx.ID_CLOSE, label=_("&Close"))
+ close.SetDefault()
+
+ developer = wx.TextCtrl(notebook, style=wx.TE_READONLY | wx.TE_MULTILINE)
+ translators = wx.TextCtrl(notebook, style=wx.TE_READONLY | wx.TE_MULTILINE)
+
+ developer.SetValue(u'\n'.join(info.Developers))
+ translators.SetValue(u'\n'.join(info.Translators))
+
+ notebook.AddPage(developer, text=_("Written by"))
+ notebook.AddPage(translators, text=_("Translated by"))
+
+ btnSizer = wx.BoxSizer(wx.HORIZONTAL)
+ btnSizer.Add(close)
+
+ sizer = wx.BoxSizer(wx.VERTICAL)
+ sizer.Add(notebook, 1, wx.EXPAND | wx.ALL, 10)
+ sizer.Add(btnSizer, flag=wx.ALIGN_RIGHT | wx.RIGHT | wx.BOTTOM, border=10)
+ self.SetSizer(sizer)
+ self.Layout()
+ self.Show()
+ self.SetEscapeId(close.GetId())
+
+ close.Bind(wx.EVT_BUTTON, lambda evt: self.Destroy())
+
+
+#----------------------------------------------------------------------
+
+class LicenseDialog(wx.Dialog):
+ def __init__(self, parent, info):
+ wx.Dialog.__init__(self, parent, title=_("License"), size=(500, 400),
+ style=wx.DEFAULT_DIALOG_STYLE | wx.RESIZE_BORDER)
+
+ if parent and parent.GetIcon():
+ self.SetIcon(parent.GetIcon())
+
+ self.SetMinSize((400, 300))
+ close = wx.Button(self, id=wx.ID_CLOSE, label=_("&Close"))
+
+ ctrl = wx.TextCtrl(self, style=wx.TE_READONLY | wx.TE_MULTILINE)
+ ctrl.SetValue(info.License)
+
+ btnSizer = wx.BoxSizer(wx.HORIZONTAL)
+ btnSizer.Add(close)
+
+ sizer = wx.BoxSizer(wx.VERTICAL)
+ sizer.Add(ctrl, 1, wx.EXPAND | wx.ALL, 10)
+ sizer.Add(btnSizer, flag=wx.ALIGN_RIGHT | wx.RIGHT | wx.BOTTOM, border=10)
+ self.SetSizer(sizer)
+ self.Layout()
+ self.Show()
+ self.SetEscapeId(close.GetId())
+
+ close.Bind(wx.EVT_BUTTON, lambda evt: self.Destroy())
+
+#----------------------------------------------------------------------
+
+def ShowAboutDialog(parent, info):
+ if os.name == "nt":
+ AboutDialog(parent, info)
+ else:
+ wx.AboutBox(info)
diff -r a375e31bf312 -r c1298e7ffe3a dialogs/ActionBlockDialog.py
--- a/dialogs/ActionBlockDialog.py Sun Mar 05 00:38:25 2017 +0000
+++ b/dialogs/ActionBlockDialog.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,25 +1,25 @@
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
-#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
-#
-#See COPYING file for copyrights details.
-#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
-#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
-#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import wx
import wx.grid
diff -r a375e31bf312 -r c1298e7ffe3a dialogs/ArrayTypeDialog.py
--- a/dialogs/ArrayTypeDialog.py Sun Mar 05 00:38:25 2017 +0000
+++ b/dialogs/ArrayTypeDialog.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,25 +1,25 @@
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import re
from types import TupleType
@@ -42,7 +42,7 @@
def __init__(self, parent, datatypes, infos):
wx.Dialog.__init__(self, parent,
- size=wx.Size(500, 300), title=_('Edit array type properties'))
+ size=wx.Size(500, 350), title=_('Edit array type properties'))
main_sizer = wx.FlexGridSizer(cols=1, hgap=0, rows=3, vgap=10)
main_sizer.AddGrowableCol(0)
diff -r a375e31bf312 -r c1298e7ffe3a dialogs/BlockPreviewDialog.py
--- a/dialogs/BlockPreviewDialog.py Sun Mar 05 00:38:25 2017 +0000
+++ b/dialogs/BlockPreviewDialog.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
-#
-#Copyright (C) 2013: Edouard TISSERANT and Laurent BESSARD
-#
-#See COPYING file for copyrights details.
-#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
-#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
-#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2013: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import wx
@@ -300,4 +300,4 @@
"""
self.RefreshPreview()
event.Skip()
-
\ No newline at end of file
+
diff -r a375e31bf312 -r c1298e7ffe3a dialogs/BrowseLocationsDialog.py
--- a/dialogs/BrowseLocationsDialog.py Sun Mar 05 00:38:25 2017 +0000
+++ b/dialogs/BrowseLocationsDialog.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,21 +1,26 @@
-#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
-#
-#See COPYING file for copyrights details.
-#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
-#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
-#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+#!/usr/bin/env python
+# -*- coding: utf-8 -*-
+
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.#
import os
diff -r a375e31bf312 -r c1298e7ffe3a dialogs/BrowseValuesLibraryDialog.py
--- a/dialogs/BrowseValuesLibraryDialog.py Sun Mar 05 00:38:25 2017 +0000
+++ b/dialogs/BrowseValuesLibraryDialog.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of Beremiz, a Integrated Development Environment for
-#programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import wx
diff -r a375e31bf312 -r c1298e7ffe3a dialogs/ConnectionDialog.py
--- a/dialogs/ConnectionDialog.py Sun Mar 05 00:38:25 2017 +0000
+++ b/dialogs/ConnectionDialog.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
-#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
-#
-#See COPYING file for copyrights details.
-#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
-#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
-#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import wx
@@ -49,7 +49,7 @@
to all connector having the same name in POU (default: False)
"""
BlockPreviewDialog.__init__(self, parent, controller, tagname,
- size=wx.Size(350, 220), title=_('Connection Properties'))
+ size=wx.Size(350, 250), title=_('Connection Properties'))
# Init common sizers
self._init_sizers(2, 0, 5, None, 2, 1)
@@ -216,4 +216,4 @@
# Call BlockPreviewDialog function
BlockPreviewDialog.RefreshPreview(self)
-
\ No newline at end of file
+
diff -r a375e31bf312 -r c1298e7ffe3a dialogs/DiscoveryDialog.py
--- a/dialogs/DiscoveryDialog.py Sun Mar 05 00:38:25 2017 +0000
+++ b/dialogs/DiscoveryDialog.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,25 +1,26 @@
+#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of Beremiz, a Integrated Development Environment for
-#programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
-#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
-#
-#See COPYING file for copyrights details.
-#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
-#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
-#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import socket
import wx
@@ -61,7 +62,7 @@
def _init_coll_ButtonGridSizer_Growables(self, parent):
parent.AddGrowableCol(0)
parent.AddGrowableCol(1)
- parent.AddGrowableRow(1)
+ parent.AddGrowableRow(0)
def _init_sizers(self):
self.MainSizer = wx.FlexGridSizer(cols=1, hgap=0, rows=3, vgap=10)
@@ -78,7 +79,7 @@
wx.Dialog.__init__(self, id=ID_DISCOVERYDIALOG,
name='DiscoveryDialog', parent=prnt,
size=wx.Size(600, 600), style=wx.DEFAULT_DIALOG_STYLE,
- title='Service Discovery')
+ title=_('Service Discovery'))
self.staticText1 = wx.StaticText(id=ID_DISCOVERYDIALOGSTATICTEXT1,
label=_('Services available:'), name='staticText1', parent=self,
@@ -88,10 +89,10 @@
self.ServicesList = AutoWidthListCtrl(id=ID_DISCOVERYDIALOGSERVICESLIST,
name='ServicesList', parent=self, pos=wx.Point(0, 0), size=wx.Size(0, 0),
style=wx.LC_REPORT|wx.LC_EDIT_LABELS|wx.LC_SORT_ASCENDING|wx.LC_SINGLE_SEL)
- self.ServicesList.InsertColumn(0, 'NAME')
- self.ServicesList.InsertColumn(1, 'TYPE')
- self.ServicesList.InsertColumn(2, 'IP')
- self.ServicesList.InsertColumn(3, 'PORT')
+ self.ServicesList.InsertColumn(0, _('NAME'))
+ self.ServicesList.InsertColumn(1, _('TYPE'))
+ self.ServicesList.InsertColumn(2, _('IP'))
+ self.ServicesList.InsertColumn(3, _('PORT'))
self.ServicesList.SetColumnWidth(0, 150)
self.ServicesList.SetColumnWidth(1, 150)
self.ServicesList.SetColumnWidth(2, 150)
diff -r a375e31bf312 -r c1298e7ffe3a dialogs/DurationEditorDialog.py
--- a/dialogs/DurationEditorDialog.py Sun Mar 05 00:38:25 2017 +0000
+++ b/dialogs/DurationEditorDialog.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import re
@@ -148,9 +148,9 @@
def OnOK(self, event):
errors = []
- for control, name in [(self.Days, "days"), (self.Hours, "hours"),
- (self.Minutes, "minutes"), (self.Seconds, "seconds"),
- (self.Milliseconds, "milliseconds")]:
+ for control, name in [(self.Days, _("days")), (self.Hours, _("hours")),
+ (self.Minutes, _("minutes")), (self.Seconds, _("seconds")),
+ (self.Milliseconds, _("milliseconds"))]:
try:
value = float(control.GetValue())
except ValueError, e:
diff -r a375e31bf312 -r c1298e7ffe3a dialogs/FBDBlockDialog.py
--- a/dialogs/FBDBlockDialog.py Sun Mar 05 00:38:25 2017 +0000
+++ b/dialogs/FBDBlockDialog.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
-#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
-#
-#See COPYING file for copyrights details.
-#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
-#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
-#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import re
diff -r a375e31bf312 -r c1298e7ffe3a dialogs/FBDVariableDialog.py
--- a/dialogs/FBDVariableDialog.py Sun Mar 05 00:38:25 2017 +0000
+++ b/dialogs/FBDVariableDialog.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
-#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
-#
-#See COPYING file for copyrights details.
-#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
-#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
-#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import wx
@@ -287,4 +287,4 @@
# Call BlockPreviewDialog function
BlockPreviewDialog.RefreshPreview(self)
-
\ No newline at end of file
+
diff -r a375e31bf312 -r c1298e7ffe3a dialogs/FindInPouDialog.py
--- a/dialogs/FindInPouDialog.py Sun Mar 05 00:38:25 2017 +0000
+++ b/dialogs/FindInPouDialog.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,39 +1,45 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import wx
+from plcopen.plcopen import *
-class FindInPouDialog(wx.Frame):
+class FindInPouDialog(wx.Dialog):
+ def _init_icon(self, parent):
+ if parent and parent.icon:
+ self.SetIcon(parent.icon)
+
+
def __init__(self, parent):
- wx.Frame.__init__(self, parent, title=_("Find"),
- size=wx.Size(400, 250), style=wx.CAPTION|
+ wx.Dialog.__init__(self, parent, title=_("Find"),
+ size=wx.Size(500, 280), style=wx.CAPTION|
wx.CLOSE_BOX|
wx.CLIP_CHILDREN|
- wx.RESIZE_BORDER|
- wx.STAY_ON_TOP)
+ wx.RESIZE_BORDER)
+ self._init_icon(parent)
panel = wx.Panel(self, style=wx.TAB_TRAVERSAL)
main_sizer = wx.FlexGridSizer(cols=1, hgap=5, rows=2, vgap=5)
@@ -53,6 +59,7 @@
self.FindPattern = wx.TextCtrl(panel)
self.Bind(wx.EVT_TEXT, self.OnFindPatternChanged, self.FindPattern)
+ self.Bind(wx.EVT_CHAR_HOOK, self.OnEscapeKey)
patterns_sizer.AddWindow(self.FindPattern, flag=wx.GROW)
params_sizer = wx.BoxSizer(wx.HORIZONTAL)
@@ -101,16 +108,21 @@
self.Bind(wx.EVT_BUTTON, self.OnFindButton, self.FindButton)
buttons_sizer.AddWindow(self.FindButton, border=5, flag=wx.RIGHT)
- self.CloseButton = wx.Button(panel, label=("Close"))
+ self.CloseButton = wx.Button(panel, label=_("Close"))
self.Bind(wx.EVT_BUTTON, self.OnCloseButton, self.CloseButton)
buttons_sizer.AddWindow(self.CloseButton)
+
+ self.StatusLabel = wx.StaticText(panel, label= "")
+ controls_sizer.AddWindow(self.StatusLabel, flag=wx.ALIGN_CENTER_VERTICAL)
panel.SetSizer(main_sizer)
+ main_sizer.Fit(self)
self.ParentWindow = parent
self.Bind(wx.EVT_CLOSE, self.OnCloseFrame)
-
+ self.infosPrev = {}
+ self.criteria = {}
self.FindPattern.SetFocus()
self.RefreshButtonsState()
@@ -126,17 +138,41 @@
self.Hide()
event.Skip()
+ def OnEscapeKey(self, event):
+ keycode = event.GetKeyCode()
+ if keycode == wx.WXK_ESCAPE:
+ self.OnCloseButton(event)
+ else:
+ event.Skip()
+
def OnFindPatternChanged(self, event):
self.RefreshButtonsState()
event.Skip()
+ def SetStatusText(self, msg):
+ self.StatusLabel.SetLabel(msg)
+ self.Layout()
+
def OnFindButton(self, event):
infos = {
"find_pattern": self.FindPattern.GetValue(),
"wrap": self.WrapSearch.GetValue(),
"case_sensitive": self.CaseSensitive.GetValue(),
- "regular_expression": self.RegularExpressions.GetValue()}
- wx.CallAfter(self.ParentWindow.FindInPou,
- {True: 1, False:-1}[self.Forward.GetValue()],
- infos)
+ "regular_expression": self.RegularExpressions.GetValue(),
+ "filter": "all"}
+
+ if self.infosPrev != infos:
+ self.infosPrev = infos
+ message = ""
+ try:
+ self.criteria = infos
+ CompilePattern(self.criteria)
+ except:
+ self.criteria.clear()
+ message = _("Syntax error in regular expression of pattern to search!")
+ self.SetStatusText(message)
+ if len(self.criteria) > 0:
+ wx.CallAfter(self.ParentWindow.FindInPou,
+ {True: 1, False:-1}[self.Forward.GetValue()],
+ self.criteria)
event.Skip()
diff -r a375e31bf312 -r c1298e7ffe3a dialogs/ForceVariableDialog.py
--- a/dialogs/ForceVariableDialog.py Sun Mar 05 00:38:25 2017 +0000
+++ b/dialogs/ForceVariableDialog.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,25 +1,25 @@
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import re
import datetime
@@ -174,7 +174,7 @@
if value == "":
message = _("You must type a value!")
elif GetTypeValue[self.IEC_Type](value) is None:
- message = _("Invalid value \"%s\" for \"%s\" variable!") % (value, self.IEC_Type)
+ message = _("Invalid value \"{a1}\" for \"{a2}\" variable!").format(a1 = value, a2 = self.IEC_Type)
if message is not None:
dialog = wx.MessageDialog(self, message, _("Error"), wx.OK|wx.ICON_ERROR)
dialog.ShowModal()
diff -r a375e31bf312 -r c1298e7ffe3a dialogs/LDElementDialog.py
--- a/dialogs/LDElementDialog.py Sun Mar 05 00:38:25 2017 +0000
+++ b/dialogs/LDElementDialog.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import wx
@@ -50,7 +50,7 @@
@param type: Type of LD element ('contact or 'coil')
"""
BlockPreviewDialog.__init__(self, parent, controller, tagname,
- size=wx.Size(350, 280 if type == "contact" else 330),
+ size=wx.Size(350, 320 if type == "contact" else 380),
title=(_("Edit Contact Values")
if type == "contact"
else _("Edit Coil Values")))
diff -r a375e31bf312 -r c1298e7ffe3a dialogs/LDPowerRailDialog.py
--- a/dialogs/LDPowerRailDialog.py Sun Mar 05 00:38:25 2017 +0000
+++ b/dialogs/LDPowerRailDialog.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,25 +1,26 @@
+#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import wx
diff -r a375e31bf312 -r c1298e7ffe3a dialogs/PouActionDialog.py
--- a/dialogs/PouActionDialog.py Sun Mar 05 00:38:25 2017 +0000
+++ b/dialogs/PouActionDialog.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2012: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2012: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import wx
@@ -34,7 +34,7 @@
class PouActionDialog(wx.Dialog):
def __init__(self, parent):
- wx.Dialog.__init__(self, parent, size=wx.Size(320, 160),
+ wx.Dialog.__init__(self, parent, size=wx.Size(320, 200),
title=_('Create a new action'))
main_sizer = wx.FlexGridSizer(cols=1, hgap=0, rows=2, vgap=10)
diff -r a375e31bf312 -r c1298e7ffe3a dialogs/PouDialog.py
--- a/dialogs/PouDialog.py Sun Mar 05 00:38:25 2017 +0000
+++ b/dialogs/PouDialog.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2012: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2012: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import wx
diff -r a375e31bf312 -r c1298e7ffe3a dialogs/PouNameDialog.py
--- a/dialogs/PouNameDialog.py Sun Mar 05 00:38:25 2017 +0000
+++ b/dialogs/PouNameDialog.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,25 +1,26 @@
+#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import wx
diff -r a375e31bf312 -r c1298e7ffe3a dialogs/PouTransitionDialog.py
--- a/dialogs/PouTransitionDialog.py Sun Mar 05 00:38:25 2017 +0000
+++ b/dialogs/PouTransitionDialog.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2012: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2012: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import wx
@@ -32,13 +32,18 @@
def GetTransitionLanguages():
_ = lambda x : x
- return [_("IL"), _("ST"), _("LD"), _("FBD")]
+ #
+ # IL language is temporary disabled because
+ # matiec freezes if transition is written in IL
+ #
+ # return [_("IL"), _("ST"), _("LD"), _("FBD")]
+ return [ _("ST"), _("LD"), _("FBD")]
TRANSITION_LANGUAGES_DICT = dict([(_(language), language) for language in GetTransitionLanguages()])
class PouTransitionDialog(wx.Dialog):
def __init__(self, parent):
- wx.Dialog.__init__(self, parent, size=wx.Size(350, 160),
+ wx.Dialog.__init__(self, parent, size=wx.Size(350, 200),
title=_('Create a new transition'))
main_sizer = wx.FlexGridSizer(cols=1, hgap=0, rows=2, vgap=10)
diff -r a375e31bf312 -r c1298e7ffe3a dialogs/ProjectDialog.py
--- a/dialogs/ProjectDialog.py Sun Mar 05 00:38:25 2017 +0000
+++ b/dialogs/ProjectDialog.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2012: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2012: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import wx
@@ -51,10 +51,10 @@
def OnOK(self, event):
values = self.ProjectProperties.GetValues()
error = []
- for param, name in [("projectName", "Project Name"),
- ("productName", "Product Name"),
- ("productVersion", "Product Version"),
- ("companyName", "Company Name")]:
+ for param, name in [("projectName", _("Project Name")),
+ ("productName", _("Product Name")),
+ ("productVersion", _("Product Version")),
+ ("companyName", _("Company Name"))]:
if values[param] == "":
error.append(name)
if len(error) > 0:
@@ -63,7 +63,7 @@
if i == 0:
text += item
elif i == len(error) - 1:
- text += " and %s"%item
+ text += _(" and %s")%item
else:
text += ", %s"%item
dialog = wx.MessageDialog(self,
diff -r a375e31bf312 -r c1298e7ffe3a dialogs/SFCDivergenceDialog.py
--- a/dialogs/SFCDivergenceDialog.py Sun Mar 05 00:38:25 2017 +0000
+++ b/dialogs/SFCDivergenceDialog.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,25 +1,26 @@
+#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import wx
@@ -39,12 +40,13 @@
class SFCDivergenceDialog(BlockPreviewDialog):
- def __init__(self, parent, controller, tagname):
+ def __init__(self, parent, controller, tagname, poss_div_types = None):
"""
Constructor
@param parent: Parent wx.Window of dialog for modal
@param controller: Reference to project controller
@param tagname: Tagname of project POU edited
+ @param poss_div_types: Types of divergence that will be available in the dialog window
"""
BlockPreviewDialog.__init__(self, parent, controller, tagname,
size=wx.Size(500, 300),
@@ -58,19 +60,28 @@
self.LeftGridSizer.AddWindow(type_label, flag=wx.GROW)
# Create radio buttons for selecting divergence type
+ divergence_buttons = [
+ (SELECTION_DIVERGENCE, _('Selection Divergence')),
+ (SELECTION_CONVERGENCE, _('Selection Convergence')),
+ (SIMULTANEOUS_DIVERGENCE, _('Simultaneous Divergence')),
+ (SIMULTANEOUS_CONVERGENCE, _('Simultaneous Convergence'))]
+ poss_div_btns = []
+ if poss_div_types is not None:
+ for val in poss_div_types:
+ poss_div_btns.append(divergence_buttons[val])
+ else:
+ poss_div_btns = divergence_buttons
self.TypeRadioButtons = {}
first = True
- for type, label in [
- (SELECTION_DIVERGENCE, _('Selection Divergence')),
- (SELECTION_CONVERGENCE, _('Selection Convergence')),
- (SIMULTANEOUS_DIVERGENCE, _('Simultaneous Divergence')),
- (SIMULTANEOUS_CONVERGENCE, _('Simultaneous Convergence'))]:
+ focusbtn = None
+ for type, label in poss_div_btns:
radio_button = wx.RadioButton(self, label=label,
style=(wx.RB_GROUP if first else 0))
radio_button.SetValue(first)
self.Bind(wx.EVT_RADIOBUTTON, self.OnTypeChanged, radio_button)
self.LeftGridSizer.AddWindow(radio_button, flag=wx.GROW)
self.TypeRadioButtons[type] = radio_button
+ if first: focusbtn = type
first = False
# Create label for number of divergence sequences
@@ -79,7 +90,7 @@
self.LeftGridSizer.AddWindow(sequences_label, flag=wx.GROW)
# Create spin control for defining number of divergence sequences
- self.Sequences = wx.SpinCtrl(self, min=2, max=20)
+ self.Sequences = wx.SpinCtrl(self, min=2, max=20, initial=2)
self.Bind(wx.EVT_SPINCTRL, self.OnSequencesChanged, self.Sequences)
self.LeftGridSizer.AddWindow(self.Sequences, flag=wx.GROW)
@@ -93,7 +104,7 @@
# Selection divergence radio button is default control having keyboard
# focus
- self.TypeRadioButtons[SELECTION_DIVERGENCE].SetFocus()
+ self.TypeRadioButtons[focusbtn].SetFocus()
def GetMinElementSize(self):
"""
@@ -151,4 +162,4 @@
# Call BlockPreviewDialog function
BlockPreviewDialog.RefreshPreview(self)
-
\ No newline at end of file
+
diff -r a375e31bf312 -r c1298e7ffe3a dialogs/SFCStepDialog.py
--- a/dialogs/SFCStepDialog.py Sun Mar 05 00:38:25 2017 +0000
+++ b/dialogs/SFCStepDialog.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,25 +1,26 @@
+#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import wx
@@ -46,7 +47,7 @@
@param initial: True if step is initial (default: False)
"""
BlockPreviewDialog.__init__(self,parent, controller, tagname,
- size=wx.Size(400, 250), title=_('Edit Step'))
+ size=wx.Size(400, 280), title=_('Edit Step'))
# Init common sizers
self._init_sizers(2, 0, 6, None, 2, 1)
@@ -70,6 +71,8 @@
("output", _("Output")),
("action", _("Action"))]:
check_box = wx.CheckBox(self, label=label)
+ if name == "output" or (name == "input" and not initial):
+ check_box.SetValue(True)
self.Bind(wx.EVT_CHECKBOX, self.OnConnectorsChanged, check_box)
self.LeftGridSizer.AddWindow(check_box, flag=wx.GROW)
self.ConnectorsCheckBox[name] = check_box
diff -r a375e31bf312 -r c1298e7ffe3a dialogs/SFCStepNameDialog.py
--- a/dialogs/SFCStepNameDialog.py Sun Mar 05 00:38:25 2017 +0000
+++ b/dialogs/SFCStepNameDialog.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,25 +1,26 @@
+#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import wx
diff -r a375e31bf312 -r c1298e7ffe3a dialogs/SFCTransitionDialog.py
--- a/dialogs/SFCTransitionDialog.py Sun Mar 05 00:38:25 2017 +0000
+++ b/dialogs/SFCTransitionDialog.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,25 +1,26 @@
+#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
-#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
-#
-#See COPYING file for copyrights details.
-#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
-#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
-#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import wx
@@ -47,7 +48,7 @@
connection (default: True)
"""
BlockPreviewDialog.__init__(self, parent, controller, tagname,
- size=wx.Size(350, 300), title=_('Edit transition'))
+ size=wx.Size(350, 350), title=_('Edit transition'))
# Init common sizers
self._init_sizers(2, 0, 8, None, 2, 1)
diff -r a375e31bf312 -r c1298e7ffe3a dialogs/SearchInProjectDialog.py
--- a/dialogs/SearchInProjectDialog.py Sun Mar 05 00:38:25 2017 +0000
+++ b/dialogs/SearchInProjectDialog.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,39 +1,31 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import re
-
+from plcopen.plcopen import *
import wx
-RE_ESCAPED_CHARACTERS = ".*+()[]?:|{}^$<>=-,"
-
-def EscapeText(text):
- text = text.replace('\\', '\\\\')
- for c in RE_ESCAPED_CHARACTERS:
- text = text.replace(c, '\\' + c)
- return text
-
#-------------------------------------------------------------------------------
# Search In Project Dialog
#-------------------------------------------------------------------------------
@@ -68,8 +60,9 @@
pattern_sizer.AddWindow(self.CaseSensitive, flag=wx.GROW)
self.Pattern = wx.TextCtrl(self)
+ self.Bind(wx.EVT_TEXT, self.FindPatternChanged, self.Pattern)
pattern_sizer.AddWindow(self.Pattern, flag=wx.GROW)
-
+ self.Bind(wx.EVT_CHAR_HOOK, self.OnEscapeKey)
self.RegularExpression = wx.CheckBox(self, label=_('Regular expression'))
pattern_sizer.AddWindow(self.RegularExpression, flag=wx.GROW)
@@ -99,58 +92,76 @@
self.ElementsList.Enable(False)
scope_sizer.AddWindow(self.ElementsList, 1, border=5,
flag=wx.GROW|wx.TOP|wx.RIGHT|wx.BOTTOM)
-
- self.ButtonSizer = self.CreateButtonSizer(wx.OK|wx.CANCEL|wx.CENTRE)
- ok_button = self.ButtonSizer.GetAffirmativeButton()
- ok_button.SetLabel(_('Search'))
- self.Bind(wx.EVT_BUTTON, self.OnOK, ok_button)
- main_sizer.AddSizer(self.ButtonSizer, border=20,
- flag=wx.ALIGN_RIGHT|wx.BOTTOM|wx.LEFT|wx.RIGHT)
+
+ buttons_sizer = wx.BoxSizer(wx.HORIZONTAL)
+ main_sizer.AddSizer(buttons_sizer, border=20,
+ flag=wx.LEFT | wx.RIGHT | wx.BOTTOM | wx.ALIGN_RIGHT)
+
+ self.FindButton = wx.Button(self, label=_("Find"))
+ self.FindButton.SetDefault()
+ self.Bind(wx.EVT_BUTTON, self.OnFindButton, self.FindButton)
+ buttons_sizer.AddWindow(self.FindButton, border=5, flag=wx.RIGHT)
+
+ self.CloseButton = wx.Button(self, label=_("Close"))
+ self.Bind(wx.EVT_BUTTON, self.OnCloseButton, self.CloseButton)
+ buttons_sizer.AddWindow(self.CloseButton)
self.SetSizer(main_sizer)
for name, label in GetElementsChoices():
self.ElementsList.Append(_(label))
-
+ self.infosPrev = {}
+ self.criteria = {}
self.Pattern.SetFocus()
+ self.RefreshButtonsState()
+
+ def RefreshButtonsState(self):
+ find_pattern = self.Pattern.GetValue()
+ self.FindButton.Enable(find_pattern != "")
def GetCriteria(self):
- raw_pattern = pattern = self.Pattern.GetValue()
- if not self.CaseSensitive.GetValue():
- pattern = pattern.upper()
- if not self.RegularExpression.GetValue():
- pattern = EscapeText(pattern)
- criteria = {
- "raw_pattern": raw_pattern,
- "pattern": re.compile(pattern),
+ return self.criteria
+
+ def FindPatternChanged(self, event):
+ self.RefreshButtonsState()
+ event.Skip()
+
+ def OnScopeChanged(self, event):
+ self.ElementsList.Enable(self.OnlyElements.GetValue())
+ event.Skip()
+
+ def OnCloseButton(self, event):
+ self.EndModal(wx.ID_CANCEL)
+
+ def OnEscapeKey(self, event):
+ keycode = event.GetKeyCode()
+ if keycode == wx.WXK_ESCAPE:
+ self.OnCloseButton(event)
+ else:
+ event.Skip()
+
+ def OnFindButton(self, event):
+ message = None
+ infos = {
+ "find_pattern": self.Pattern.GetValue(),
"case_sensitive": self.CaseSensitive.GetValue(),
"regular_expression": self.RegularExpression.GetValue(),
}
if self.WholeProject.GetValue():
- criteria["filter"] = "all"
+ infos["filter"] = "all"
elif self.OnlyElements.GetValue():
- criteria["filter"] = []
+ infos["filter"] = []
for index, (name, label) in enumerate(GetElementsChoices()):
if self.ElementsList.IsChecked(index):
- criteria["filter"].append(name)
- return criteria
-
- def OnScopeChanged(self, event):
- self.ElementsList.Enable(self.OnlyElements.GetValue())
- event.Skip()
-
- def OnOK(self, event):
- message = None
- if self.Pattern.GetValue() == "":
- message = _("Form isn't complete. Pattern to search must be filled!")
- else:
- wrong_pattern = False
- if self.RegularExpression.GetValue():
- try:
- re.compile(self.Pattern.GetValue())
- except:
- wrong_pattern = True
- if wrong_pattern:
+ infos["filter"].append(name)
+
+ if self.infosPrev != infos:
+ try:
+ self.criteria = infos
+ CompilePattern(self.criteria)
+ self.infosPrev = infos
+ except:
+ self.criteria.clear()
message = _("Syntax error in regular expression of pattern to search!")
if message is not None:
diff -r a375e31bf312 -r c1298e7ffe3a dialogs/__init__.py
--- a/dialogs/__init__.py Sun Mar 05 00:38:25 2017 +0000
+++ b/dialogs/__init__.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,27 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+
# Package initialization
diff -r a375e31bf312 -r c1298e7ffe3a doc/about.html
--- a/doc/about.html Sun Mar 05 00:38:25 2017 +0000
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,23 +0,0 @@
-
-
-
-
-
-Beremiz is an Open Source framework for automation.
-
-http://www.beremiz.org/
-
-
-
-
-
\ No newline at end of file
diff -r a375e31bf312 -r c1298e7ffe3a doc/plcopen_about.html
--- a/doc/plcopen_about.html Sun Mar 05 00:38:25 2017 +0000
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,13 +0,0 @@
-
-
-
-
-
-The PLCopen Editor saves and loads XML projects,
accordingly to PLCopen TC6-XML Schemes.
-
-More informations on :
-http://www.beremiz.org/
-
-
-
-
\ No newline at end of file
diff -r a375e31bf312 -r c1298e7ffe3a docutil/__init__.py
--- a/docutil/__init__.py Sun Mar 05 00:38:25 2017 +0000
+++ b/docutil/__init__.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,27 +1,27 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
from dochtml import *
from docpdf import *
-from docsvg import *
\ No newline at end of file
+from docsvg import *
diff -r a375e31bf312 -r c1298e7ffe3a docutil/dochtml.py
--- a/docutil/dochtml.py Sun Mar 05 00:38:25 2017 +0000
+++ b/docutil/dochtml.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import wx, os, wx.html, subprocess
@@ -63,6 +63,7 @@
wx.Frame.__init__(self, id=ID_HTMLFRAME, name='HtmlFrame',
parent=prnt, pos=wx.Point(320, 231), size=wx.Size(853, 616),
style=wx.DEFAULT_FRAME_STYLE, title='')
+ self.SetIcon(prnt.icon)
self.Bind(wx.EVT_CLOSE, self.OnCloseFrame)
self.HtmlContent = UrlClickHtmlWindow(id=ID_HTMLFRAMEHTMLCONTENT,
@@ -93,4 +94,4 @@
elif subprocess.call("firefox %s"%url, shell=True) != 0:
wx.MessageBox("""Firefox browser not found.\nPlease point your browser at :\n%s""" % url)
except ImportError:
- wx.MessageBox('Please point your browser at: %s' % url)
\ No newline at end of file
+ wx.MessageBox('Please point your browser at: %s' % url)
diff -r a375e31bf312 -r c1298e7ffe3a docutil/docpdf.py
--- a/docutil/docpdf.py Sun Mar 05 00:38:25 2017 +0000
+++ b/docutil/docpdf.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import wx, os
@@ -53,7 +53,7 @@
if pagenum == None :
os.system("%s -remote DS301 %s &"%(readerexepath, pdffile))
else:
- print "Open pdf %s at page %d"%(pdffile, pagenum)
+ print "Open pdf %s at page %d"%(pdffile, pagenum)
os.system("%s -remote DS301 %s %d &"%(readerexepath, pdffile, pagenum))
def open_pdf(pdffile, pagenum = None):
diff -r a375e31bf312 -r c1298e7ffe3a docutil/docsvg.py
--- a/docutil/docsvg.py Sun Mar 05 00:38:25 2017 +0000
+++ b/docutil/docsvg.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import wx, os, subprocess
diff -r a375e31bf312 -r c1298e7ffe3a editors/CodeFileEditor.py
--- a/editors/CodeFileEditor.py Sun Mar 05 00:38:25 2017 +0000
+++ b/editors/CodeFileEditor.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,3 +1,27 @@
+#!/usr/bin/env python
+# -*- coding: utf-8 -*-
+
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+
import re
import wx
@@ -482,17 +506,11 @@
self.ClearHighlights(SEARCH_RESULT_HIGHLIGHT)
self.SearchParams = search_params
- criteria = {
- "raw_pattern": search_params["find_pattern"],
- "pattern": re.compile(search_params["find_pattern"]),
- "case_sensitive": search_params["case_sensitive"],
- "regular_expression": search_params["regular_expression"],
- "filter": "all"}
self.SearchResults = [
(start, end, SEARCH_RESULT_HIGHLIGHT)
for start, end, text in
- TestTextElement(self.GetText(), criteria)]
+ TestTextElement(self.GetText(), search_params)]
self.CurrentFindHighlight = None
if len(self.SearchResults) > 0:
@@ -660,11 +678,13 @@
self.VariablesDefaultValue = {"Name" : "", "Type" : DefaultType, "Initial": "",
"Description":"", "OnChange":"", "Options":""}
- self.Table = VariablesTable(self, [], ["#", "Name", "Type", "Initial",
- "Description", "OnChange", "Options"])
+ self.Table = VariablesTable(self, [], ["#", "Name","Type", "Initial",
+ "Description", "OnChange", "Options"])
+ # self.Table = VariablesTable(self, [], [_("#"), _("Name"), _("Type"), _("Initial"),
+ # _("Description"), _("OnChange"), _("Options")])
self.ColAlignements = [wx.ALIGN_RIGHT] + \
[wx.ALIGN_LEFT]*(len(self.VariablesDefaultValue))
- self.ColSizes = [20, 150] + [100]*(len(self.VariablesDefaultValue)-1)
+ self.ColSizes = [20, 150] + [130]*(len(self.VariablesDefaultValue)-1)
self.VariablesGrid.SetTable(self.Table)
self.VariablesGrid.SetButtons({"Add": self.AddVariableButton,
"Delete": self.DeleteVariableButton,
diff -r a375e31bf312 -r c1298e7ffe3a editors/ConfTreeNodeEditor.py
--- a/editors/ConfTreeNodeEditor.py Sun Mar 05 00:38:25 2017 +0000
+++ b/editors/ConfTreeNodeEditor.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,3 +1,26 @@
+#!/usr/bin/env python
+# -*- coding: utf-8 -*-
+
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import os
import types
@@ -319,25 +342,20 @@
staticbox = wx.StaticBox(self.ParamsEditor,
label=_(label), size=wx.Size(10, 0))
staticboxsizer = wx.StaticBoxSizer(staticbox, wx.VERTICAL)
+ flags = (wx.GROW | wx.BOTTOM | wx.LEFT | wx.RIGHT)
if first:
- sizer.AddSizer(staticboxsizer, border=5,
- flag=wx.GROW|wx.TOP|wx.BOTTOM)
- else:
- sizer.AddSizer(staticboxsizer, border=5,
- flag=wx.GROW|wx.BOTTOM)
+ flags |= wx.TOP
+ sizer.AddSizer(staticboxsizer, border=5, flag=flags)
self.GenerateSizerElements(staticboxsizer,
element_infos["children"],
element_path)
else:
boxsizer = wx.FlexGridSizer(cols=3, rows=1)
boxsizer.AddGrowableCol(1)
+ flags = (wx.GROW | wx.BOTTOM | wx.LEFT | wx.RIGHT)
if first:
- sizer.AddSizer(boxsizer, border=5,
- flag=wx.GROW|wx.ALL)
- else:
- sizer.AddSizer(boxsizer, border=5,
- flag=wx.GROW|wx.LEFT|wx.RIGHT|wx.BOTTOM)
-
+ flags |= wx.TOP
+ sizer.AddSizer(boxsizer, border=5, flag=flags)
staticbitmap = GenStaticBitmap(ID=-1, bitmapname=element_infos["name"],
name="%s_bitmap"%element_infos["name"], parent=self.ParamsEditor,
pos=wx.Point(0, 0), size=wx.Size(24, 24), style=0)
@@ -385,7 +403,7 @@
staticbox = wx.StaticBox(self.ParamsEditor,
label="%s - %s"%(_(name), _(value)), size=wx.Size(10, 0))
staticboxsizer = wx.StaticBoxSizer(staticbox, wx.VERTICAL)
- sizer.AddSizer(staticboxsizer, border=5, flag=wx.GROW|wx.BOTTOM)
+ sizer.AddSizer(staticboxsizer, border=5, flag=wx.GROW | wx.BOTTOM | wx.LEFT | wx.RIGHT)
self.GenerateSizerElements(staticboxsizer, element_infos["children"], element_path)
callback = self.GetChoiceContentCallBackFunction(combobox, staticboxsizer, element_path)
else:
@@ -456,6 +474,8 @@
textctrl.Bind(wx.EVT_TEXT_ENTER, callback)
textctrl.Bind(wx.EVT_KILL_FOCUS, callback)
first = False
+ sizer.Layout()
+ self.RefreshScrollbars()
def GetItemChannelChangedFunction(self, dir):
diff -r a375e31bf312 -r c1298e7ffe3a editors/DataTypeEditor.py
--- a/editors/DataTypeEditor.py Sun Mar 05 00:38:25 2017 +0000
+++ b/editors/DataTypeEditor.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import re
from types import TupleType
@@ -74,10 +74,11 @@
return row + 1
colname = self.GetColLabelValue(col, False)
value = self.data[row].get(colname, "")
+
if colname == "Type" and isinstance(value, TupleType):
if value[0] == "array":
return "ARRAY [%s] OF %s" % (",".join(map(lambda x : "..".join(x), value[2])), value[1])
- return str(value)
+ return value
def SetValue(self, row, col, value):
if col < len(self.colnames):
diff -r a375e31bf312 -r c1298e7ffe3a editors/DebugViewer.py
--- a/editors/DebugViewer.py Sun Mar 05 00:38:25 2017 +0000
+++ b/editors/DebugViewer.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
-#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
-#
-#See COPYING file for copyrights details.
-#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
-#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
-#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
from threading import Lock, Timer
from time import time as gettime
diff -r a375e31bf312 -r c1298e7ffe3a editors/EditorPanel.py
--- a/editors/EditorPanel.py Sun Mar 05 00:38:25 2017 +0000
+++ b/editors/EditorPanel.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import wx
@@ -79,7 +79,7 @@
self.ParentWindow.EditProjectElement(None, self.GetTagName(), True)
def GetTitle(self):
- return "-".join(self.TagName.split("::")[1:])
+ return ".".join(self.TagName.split("::")[1:])
def GetIcon(self):
return self.Icon
diff -r a375e31bf312 -r c1298e7ffe3a editors/FileManagementPanel.py
--- a/editors/FileManagementPanel.py Sun Mar 05 00:38:25 2017 +0000
+++ b/editors/FileManagementPanel.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of Beremiz, a Integrated Development Environment for
-#programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
-#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
-#
-#See COPYING file for copyrights details.
-#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
-#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
-#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import os
import shutil
@@ -211,4 +211,4 @@
dragSource = wx.DropSource(self)
dragSource.SetData(data)
dragSource.DoDragDrop()
-
\ No newline at end of file
+
diff -r a375e31bf312 -r c1298e7ffe3a editors/IECCodeViewer.py
--- a/editors/IECCodeViewer.py Sun Mar 05 00:38:25 2017 +0000
+++ b/editors/IECCodeViewer.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,3 +1,26 @@
+#!/usr/bin/env python
+# -*- coding: utf-8 -*-
+
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
from editors.TextViewer import TextViewer
from plcopen.plcopen import TestTextElement
@@ -14,4 +37,4 @@
TextViewer.Paste(self)
def Search(self, criteria):
- return [((self.TagName, "body", 0),) + result for result in TestTextElement(self.Editor.GetText(), criteria)]
\ No newline at end of file
+ return [((self.TagName, "body", 0),) + result for result in TestTextElement(self.Editor.GetText(), criteria)]
diff -r a375e31bf312 -r c1298e7ffe3a editors/LDViewer.py
--- a/editors/LDViewer.py Sun Mar 05 00:38:25 2017 +0000
+++ b/editors/LDViewer.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import wx
import time
diff -r a375e31bf312 -r c1298e7ffe3a editors/ProjectNodeEditor.py
--- a/editors/ProjectNodeEditor.py Sun Mar 05 00:38:25 2017 +0000
+++ b/editors/ProjectNodeEditor.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,3 +1,26 @@
+#!/usr/bin/env python
+# -*- coding: utf-8 -*-
+
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import wx
@@ -68,4 +91,4 @@
def Redo(self):
self.Controler.LoadNext()
self.ParentWindow.CloseTabsWithoutModel()
-
\ No newline at end of file
+
diff -r a375e31bf312 -r c1298e7ffe3a editors/ResourceEditor.py
--- a/editors/ResourceEditor.py Sun Mar 05 00:38:25 2017 +0000
+++ b/editors/ResourceEditor.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import wx
import wx.lib.buttons
@@ -434,17 +434,18 @@
def OnTasksGridCellChange(self, event):
row, col = event.GetRow(), event.GetCol()
- if self.TasksTable.GetColLabelValue(col) == "Name":
+ if self.TasksTable.GetColLabelValue(col, False) == "Name":
tasklist = [name for name in self.TaskList.split(",") if name != ""]
for i in xrange(self.TasksTable.GetNumberRows()):
task = self.TasksTable.GetValueByName(i, "Name")
if task in tasklist:
tasklist.remove(task)
if len(tasklist) > 0:
- old_name = tasklist[0]
+ old_name = tasklist[0].upper()
new_name = self.TasksTable.GetValue(row, col)
for i in xrange(self.InstancesTable.GetNumberRows()):
- if self.InstancesTable.GetValueByName(i, "Task") == old_name:
+ name = self.InstancesTable.GetValueByName(i, "Task").upper()
+ if old_name == name:
self.InstancesTable.SetValueByName(i, "Task", new_name)
self.RefreshModel()
colname = self.TasksTable.GetColLabelValue(col, False)
diff -r a375e31bf312 -r c1298e7ffe3a editors/SFCViewer.py
--- a/editors/SFCViewer.py Sun Mar 05 00:38:25 2017 +0000
+++ b/editors/SFCViewer.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,35 +1,87 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
from types import *
import wx
from Viewer import *
+from graphics.SFC_Objects import *
+from graphics.GraphicCommons import SELECTION_DIVERGENCE, \
+ SELECTION_CONVERGENCE, SIMULTANEOUS_DIVERGENCE, SIMULTANEOUS_CONVERGENCE, EAST, NORTH, WEST, SOUTH
+
+SFC_Objects = (SFC_Step, SFC_ActionBlock, SFC_Transition, SFC_Divergence, SFC_Jump)
+
class SFC_Viewer(Viewer):
+ SFC_StandardRules = {
+ # The key of this dict is a block that user try to connect,
+ # and the value is a list of blocks, that can be connected with the current block
+ # and with directions of connection
+ "SFC_Step": [("SFC_ActionBlock", EAST),
+ ("SFC_Transition", SOUTH),
+ (SELECTION_DIVERGENCE, SOUTH),
+ (SIMULTANEOUS_CONVERGENCE, SOUTH)],
+
+ "SFC_ActionBlock": [("SFC_Step", EAST)],
+
+ "SFC_Transition": [("SFC_Step", SOUTH),
+ (SELECTION_CONVERGENCE, SOUTH),
+ (SIMULTANEOUS_DIVERGENCE, SOUTH),
+ ("SFC_Jump", SOUTH),
+ ("FBD_Block", EAST),
+ ("FBD_Variable", EAST),
+ ("FBD_Connector", EAST),
+ ("LD_Contact", EAST),
+ ("LD_PowerRail", EAST),
+ ("LD_Coil", EAST)],
+
+ SELECTION_DIVERGENCE: [("SFC_Transition", SOUTH)],
+
+ SELECTION_CONVERGENCE: [("SFC_Step", SOUTH),
+ ("SFC_Jump", SOUTH)],
+
+ SIMULTANEOUS_DIVERGENCE: [("SFC_Step", SOUTH)],
+
+ SIMULTANEOUS_CONVERGENCE: [("SFC_Transition", SOUTH)],
+
+ "SFC_Jump": [],
+
+ "FBD_Block": [("SFC_Transition", WEST)],
+
+ "FBD_Variable": [("SFC_Transition", WEST)],
+
+ "FBD_Connector": [("SFC_Transition", WEST)],
+
+ "LD_Contact": [("SFC_Transition", WEST)],
+
+ "LD_PowerRail": [("SFC_Transition", WEST)],
+
+ "LD_Coil": [("SFC_Transition", WEST)]
+ }
+
def __init__(self, parent, tagname, window, controler, debug = False, instancepath = ""):
Viewer.__init__(self, parent, tagname, window, controler, debug, instancepath)
self.CurrentLanguage = "SFC"
@@ -282,6 +334,28 @@
self.UpdateScrollPos(event)
event.Skip()
+ def GetBlockName(self, block):
+ blockName = block.__class__.__name__
+ if blockName == "SFC_Divergence":
+ blockName = block.Type
+ return blockName
+
+ # This method check the IEC 61131-3 compatibility between two SFC blocks
+ def BlockCompatibility(self,startblock = None, endblock = None, direction = None):
+ if startblock!= None and endblock != None and (isinstance(startblock,SFC_Objects)\
+ or isinstance(endblock,SFC_Objects)):
+ # Full "SFC_StandardRules" table would be symmetrical and
+ # to avoid duplicate records and minimize the table only upper part is defined.
+ if (direction == SOUTH or direction == EAST):
+ startblock, endblock = endblock, startblock
+ start = self.GetBlockName(startblock)
+ end = self.GetBlockName(endblock)
+ for val in self.SFC_StandardRules[start]:
+ if end in val:
+ return True
+ return False
+ return True
+
#-------------------------------------------------------------------------------
# Keyboard event functions
#-------------------------------------------------------------------------------
diff -r a375e31bf312 -r c1298e7ffe3a editors/TextViewer.py
--- a/editors/TextViewer.py Sun Mar 05 00:38:25 2017 +0000
+++ b/editors/TextViewer.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import re
from types import *
@@ -47,7 +47,8 @@
[STC_PLC_WORD, STC_PLC_COMMENT, STC_PLC_NUMBER, STC_PLC_STRING,
STC_PLC_VARIABLE, STC_PLC_PARAMETER, STC_PLC_FUNCTION, STC_PLC_JUMP,
- STC_PLC_ERROR, STC_PLC_SEARCH_RESULT] = range(10)
+ STC_PLC_ERROR, STC_PLC_SEARCH_RESULT,
+ STC_PLC_EMPTY] = range(11)
[SPACE, WORD, NUMBER, STRING, WSTRING, COMMENT, PRAGMA, DPRAGMA] = range(8)
[ID_TEXTVIEWER, ID_TEXTVIEWERTEXTCTRL,
@@ -258,10 +259,11 @@
blockinputs = None
if values[1] != "function":
if blockname == "":
- dialog = wx.TextEntryDialog(self.ParentWindow, "Block name", "Please enter a block name", "", wx.OK|wx.CANCEL|wx.CENTRE)
+ dialog = wx.TextEntryDialog(self.ParentWindow, _("Block name"), _("Please enter a block name"), "", wx.OK|wx.CANCEL|wx.CENTRE)
if dialog.ShowModal() == wx.ID_OK:
blockname = dialog.GetValue()
else:
+ event.SetDragText("")
return
dialog.Destroy()
if blockname.upper() in [name.upper() for name in self.Controler.GetProjectPouNames(self.Debug)]:
@@ -287,7 +289,7 @@
dlg = wx.TextEntryDialog(
self.ParentWindow,
_("Confirm or change variable name"),
- 'Variable Drop', var_name)
+ _('Variable Drop'), var_name)
dlg.SetValue(var_name)
var_name = dlg.GetValue() if dlg.ShowModal() == wx.ID_OK else None
dlg.Destroy()
@@ -302,7 +304,7 @@
if not location.startswith("%"):
dialog = wx.SingleChoiceDialog(self.ParentWindow,
_("Select a variable class:"), _("Variable class"),
- ["Input", "Output", "Memory"],
+ [_("Input"), _("Output"), _("Memory")],
wx.DEFAULT_DIALOG_STYLE|wx.OK|wx.CANCEL)
if dialog.ShowModal() == wx.ID_OK:
selected = dialog.GetSelection()
@@ -338,7 +340,7 @@
dlg = wx.TextEntryDialog(
self.ParentWindow,
_("Confirm or change variable name"),
- 'Variable Drop', var_name)
+ _('Variable Drop'), var_name)
dlg.SetValue(var_name)
var_name = dlg.GetValue() if dlg.ShowModal() == wx.ID_OK else None
dlg.Destroy()
@@ -361,7 +363,7 @@
dlg = wx.TextEntryDialog(
self.ParentWindow,
_("Confirm or change variable name"),
- 'Variable Drop', var_name)
+ _('Variable Drop'), var_name)
dlg.SetValue(var_name)
var_name = dlg.GetValue() if dlg.ShowModal() == wx.ID_OK else None
dlg.Destroy()
@@ -412,7 +414,7 @@
self.Colourise(0, -1)
def RefreshJumpList(self):
- if self.TextSyntax != "IL":
+ if self.TextSyntax == "IL":
self.Jumps = [jump.upper() for jump in LABEL_MODEL.findall(self.GetText())]
self.Colourise(0, -1)
@@ -576,7 +578,7 @@
self.ContextStack = []
current_context = self.Variables
if state == COMMENT:
- self.SetStyling(current_pos - last_styled_pos + 1, STC_PLC_COMMENT)
+ self.SetStyling(current_pos - last_styled_pos, STC_PLC_COMMENT)
elif state == NUMBER:
self.SetStyling(current_pos - last_styled_pos, STC_PLC_NUMBER)
elif state == WORD:
@@ -593,33 +595,33 @@
elif word in self.EnumeratedValues:
self.SetStyling(current_pos - last_styled_pos, STC_PLC_NUMBER)
else:
- self.SetStyling(current_pos - last_styled_pos, 31)
+ self.SetStyling(current_pos - last_styled_pos, STC_PLC_EMPTY)
if word not in ["]", ")"] and (self.GetCurrentPos() < last_styled_pos or self.GetCurrentPos() > current_pos):
self.StartStyling(last_styled_pos, wx.stc.STC_INDICS_MASK)
self.SetStyling(current_pos - last_styled_pos, wx.stc.STC_INDIC0_MASK)
self.StartStyling(current_pos, 0xff)
else:
- self.SetStyling(current_pos - last_styled_pos, 31)
+ self.SetStyling(current_pos - last_styled_pos, STC_PLC_EMPTY)
last_styled_pos = current_pos
- if state != DPRAGMA:
+ if (state != DPRAGMA) and (state != COMMENT):
state = SPACE
line = ""
line_number += 1
self.RefreshLineFolding(line_number)
elif line.endswith("(*") and state != COMMENT:
- self.SetStyling(current_pos - last_styled_pos - 1, 31)
+ self.SetStyling(current_pos - last_styled_pos - 1, STC_PLC_EMPTY)
last_styled_pos = current_pos
if state == WORD:
current_context = self.Variables
state = COMMENT
elif line.endswith("{") and state not in [PRAGMA, DPRAGMA]:
- self.SetStyling(current_pos - last_styled_pos, 31)
+ self.SetStyling(current_pos - last_styled_pos, STC_PLC_EMPTY)
last_styled_pos = current_pos
if state == WORD:
current_context = self.Variables
state = PRAGMA
elif line.endswith("{{") and state == PRAGMA:
- self.SetStyling(current_pos - last_styled_pos, 31)
+ self.SetStyling(current_pos - last_styled_pos, STC_PLC_EMPTY)
last_styled_pos = current_pos
state = DPRAGMA
elif state == COMMENT:
@@ -627,18 +629,22 @@
self.SetStyling(current_pos - last_styled_pos + 2, STC_PLC_COMMENT)
last_styled_pos = current_pos + 1
state = SPACE
+ if len(self.CallStack) > 0:
+ current_call = self.CallStack.pop()
+ else:
+ current_call = None
elif state == PRAGMA:
if line.endswith("}"):
- self.SetStyling(current_pos - last_styled_pos, 31)
+ self.SetStyling(current_pos - last_styled_pos, STC_PLC_EMPTY)
last_styled_pos = current_pos
state = SPACE
elif state == DPRAGMA:
if line.endswith("}}"):
- self.SetStyling(current_pos - last_styled_pos + 1, 31)
+ self.SetStyling(current_pos - last_styled_pos + 1, STC_PLC_EMPTY)
last_styled_pos = current_pos + 1
state = SPACE
elif (line.endswith("'") or line.endswith('"')) and state not in [STRING, WSTRING]:
- self.SetStyling(current_pos - last_styled_pos, 31)
+ self.SetStyling(current_pos - last_styled_pos, STC_PLC_EMPTY)
last_styled_pos = current_pos
if state == WORD:
current_context = self.Variables
@@ -661,7 +667,7 @@
word = "#"
state = WORD
elif state == SPACE:
- self.SetStyling(current_pos - last_styled_pos, 31)
+ self.SetStyling(current_pos - last_styled_pos, STC_PLC_EMPTY)
word = char
last_styled_pos = current_pos
state = WORD
@@ -669,7 +675,7 @@
word += char
elif char in NUMBERS or char == '.' and state != WORD:
if state == SPACE:
- self.SetStyling(current_pos - last_styled_pos, 31)
+ self.SetStyling(current_pos - last_styled_pos, STC_PLC_EMPTY)
last_styled_pos = current_pos
state = NUMBER
elif state == WORD and char != '.':
@@ -692,7 +698,7 @@
elif word in self.EnumeratedValues:
self.SetStyling(current_pos - last_styled_pos, STC_PLC_NUMBER)
else:
- self.SetStyling(current_pos - last_styled_pos, 31)
+ self.SetStyling(current_pos - last_styled_pos, STC_PLC_EMPTY)
if word not in ["]", ")"] and (self.GetCurrentPos() < last_styled_pos or self.GetCurrentPos() > current_pos):
self.StartStyling(last_styled_pos, wx.stc.STC_INDICS_MASK)
self.SetStyling(current_pos - last_styled_pos, wx.stc.STC_INDIC0_MASK)
@@ -756,9 +762,9 @@
elif word in self.EnumeratedValues:
self.SetStyling(current_pos - last_styled_pos, STC_PLC_NUMBER)
else:
- self.SetStyling(current_pos - last_styled_pos, 31)
+ self.SetStyling(current_pos - last_styled_pos, STC_PLC_EMPTY)
else:
- self.SetStyling(current_pos - start_pos, 31)
+ self.SetStyling(current_pos - start_pos, STC_PLC_EMPTY)
self.ShowHighlights(start_pos, end_pos)
event.Skip()
@@ -804,17 +810,10 @@
self.ClearHighlights(SEARCH_RESULT_HIGHLIGHT)
self.SearchParams = search_params
- criteria = {
- "raw_pattern": search_params["find_pattern"],
- "pattern": re.compile(search_params["find_pattern"]),
- "case_sensitive": search_params["case_sensitive"],
- "regular_expression": search_params["regular_expression"],
- "filter": "all"}
-
self.SearchResults = [
(infos[1:], start, end, SEARCH_RESULT_HIGHLIGHT)
for infos, start, end, text in
- self.Search(criteria)]
+ self.Search(search_params)]
self.CurrentFindHighlight = None
if len(self.SearchResults) > 0:
@@ -895,14 +894,15 @@
key_handled = True
elif key == wx.WXK_BACK:
if self.TextSyntax in ["ST", "ALL"]:
- indent = self.Editor.GetLineIndentation(line)
- if lineText.strip() == "" and indent > 0:
- self.Editor.DelLineLeft()
- self.Editor.AddText(" " * ((max(0, indent - 1) / 2) * 2))
- key_handled = True
+ if not self.Editor.GetSelectedText():
+ indent = self.Editor.GetColumn(self.Editor.GetCurrentPos())
+ if lineText.strip() == "" and len(lineText) > 0 and indent > 0:
+ self.Editor.DelLineLeft()
+ self.Editor.AddText(" " * ((max(0, indent - 1) / 2) * 2))
+ key_handled = True
if not key_handled:
event.Skip()
- elif key in NAVIGATION_KEYS:
+ else:
event.Skip()
def OnKillFocus(self, event):
diff -r a375e31bf312 -r c1298e7ffe3a editors/Viewer.py
--- a/editors/Viewer.py Sun Mar 05 00:38:25 2017 +0000
+++ b/editors/Viewer.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import re
import math
@@ -43,6 +43,7 @@
SCROLL_ZONE = 10
CURSORS = None
+SFC_Objects = (SFC_Step, SFC_ActionBlock, SFC_Transition, SFC_Divergence, SFC_Jump)
def ResetCursors():
global CURSORS
@@ -146,6 +147,9 @@
specific_values.priority, id)
return transition
+divergence_types = [SELECTION_DIVERGENCE,
+ SELECTION_CONVERGENCE, SIMULTANEOUS_DIVERGENCE, SIMULTANEOUS_CONVERGENCE]
+
def GetDivergenceCreationFunction(divergence_type):
def divergenceCreationFunction(viewer, id, specific_values):
return SFC_Divergence(viewer, divergence_type,
@@ -243,7 +247,7 @@
elif pou_type == "function" and values[1] != "function":
message = _("Function Blocks can't be used in Functions!")
elif self.ParentWindow.Controler.PouIsUsedBy(pou_name, values[0], self.ParentWindow.Debug):
- message = _("\"%s\" is already used by \"%s\"!")%(pou_name, values[0])
+ message = _("\"{a1}\" is already used by \"{a2}\"!").format(a1 = pou_name, a2 = values[0])
else:
blockname = values[2]
if len(values) > 3:
@@ -282,7 +286,7 @@
if not location.startswith("%"):
dialog = wx.SingleChoiceDialog(self.ParentWindow.ParentWindow,
_("Select a variable class:"), _("Variable class"),
- ["Input", "Output", "Memory"],
+ [_("Input"), _("Output"), _("Memory")],
wx.DEFAULT_DIALOG_STYLE|wx.OK|wx.CANCEL)
if dialog.ShowModal() == wx.ID_OK:
selected = dialog.GetSelection()
@@ -301,7 +305,7 @@
dlg = wx.TextEntryDialog(
self.ParentWindow.ParentWindow,
_("Confirm or change variable name"),
- 'Variable Drop', var_name)
+ _('Variable Drop'), var_name)
dlg.SetValue(var_name)
var_name = dlg.GetValue() if dlg.ShowModal() == wx.ID_OK else None
dlg.Destroy()
@@ -331,7 +335,7 @@
dlg = wx.TextEntryDialog(
self.ParentWindow.ParentWindow,
_("Confirm or change variable name"),
- 'Variable Drop', var_name)
+ _('Variable Drop'), var_name)
dlg.SetValue(var_name)
var_name = dlg.GetValue() if dlg.ShowModal() == wx.ID_OK else None
dlg.Destroy()
@@ -353,7 +357,7 @@
dlg = wx.TextEntryDialog(
self.ParentWindow.ParentWindow,
_("Confirm or change variable name"),
- 'Variable Drop', var_name)
+ _('Variable Drop'), var_name)
dlg.SetValue(var_name)
var_name = dlg.GetValue() if dlg.ShowModal() == wx.ID_OK else None
dlg.Destroy()
@@ -573,11 +577,11 @@
[ID_CLEAR_EXEC_ORDER, ID_RESET_EXEC_ORDER] = [wx.NewId() for i in xrange(2)]
# Create menu items
- self.AddMenuItems(menu, [
- (ID_CLEAR_EXEC_ORDER, wx.ITEM_NORMAL, _(u'Clear Execution Order'), '', self.OnClearExecutionOrderMenu),
- (ID_RESET_EXEC_ORDER, wx.ITEM_NORMAL, _(u'Reset Execution Order'), '', self.OnResetExecutionOrderMenu)])
-
- menu.AppendSeparator()
+ if self.CurrentLanguage == 'FBD':
+ self.AddMenuItems(menu, [
+ (ID_CLEAR_EXEC_ORDER, wx.ITEM_NORMAL, _(u'Clear Execution Order'), '', self.OnClearExecutionOrderMenu),
+ (ID_RESET_EXEC_ORDER, wx.ITEM_NORMAL, _(u'Reset Execution Order'), '', self.OnResetExecutionOrderMenu)])
+ menu.AppendSeparator()
add_menu = wx.Menu(title='')
self.AddAddMenuItems(add_menu)
@@ -600,7 +604,7 @@
def _init_Editor(self, prnt):
self.Editor = wx.ScrolledWindow(prnt, name="Viewer",
pos=wx.Point(0, 0), size=wx.Size(0, 0),
- style=wx.HSCROLL | wx.VSCROLL | wx.ALWAYS_SHOW_SB)
+ style=wx.HSCROLL | wx.VSCROLL)
self.Editor.ParentWindow = self
# Create a new Viewer
@@ -757,8 +761,8 @@
client_size = self.Editor.GetClientSize()
mouse_pos = wx.Point(client_size[0] / 2, client_size[1] / 2)
mouse_event = wx.MouseEvent(wx.EVT_MOUSEWHEEL.typeId)
- mouse_event.m_x = mouse_pos.x
- mouse_event.m_y = mouse_pos.y
+ mouse_event.x = mouse_pos.x
+ mouse_event.y = mouse_pos.y
else:
mouse_pos = mouse_event.GetPosition()
pos = mouse_event.GetLogicalPosition(dc)
@@ -883,6 +887,15 @@
comments.sort(lambda x, y: cmp(x.GetId(), y.GetId()))
return blocks + wires + comments
+ def GetContinuationByName(self, name):
+ blocks = []
+ for block in self.Blocks.itervalues():
+ if isinstance(block, FBD_Connector) and\
+ block.GetType() == CONTINUATION and\
+ block.GetName() == name:
+ blocks.append(block)
+ return blocks
+
def GetConnectorByName(self, name):
for block in self.Blocks.itervalues():
if isinstance(block, FBD_Connector) and\
@@ -1462,12 +1475,24 @@
return None
def FindBlockConnector(self, pos, direction = None, exclude = None):
+ result, error = self.FindBlockConnectorWithError(pos, direction, exclude)
+ return result
+
+ def FindBlockConnectorWithError(self, pos, direction = None, exclude = None):
+ error = False
+ startblock = None
for block in self.Blocks.itervalues():
- result = block.TestConnector(pos, direction, exclude)
- if result:
- return result
- return None
-
+ connector = block.TestConnector(pos, direction, exclude)
+ if connector:
+ if self.IsWire(self.SelectedElement):
+ startblock = self.SelectedElement.StartConnected.GetParentBlock()
+ avail, error = connector.ConnectionAvailable(direction, exclude)
+ if not avail or not self.BlockCompatibility(startblock, block, direction):
+ connector = None
+ error = True
+ return connector, error
+ return None, error
+
def FindElementById(self, id):
block = self.Blocks.get(id, None)
if block is not None:
@@ -2048,47 +2073,7 @@
self.SelectedElement.HighlightPoint(pos)
self.RefreshBuffer()
elif connector is None or self.SelectedElement.GetDragging():
- start_connector = self.SelectedElement.GetStartConnected()
- start_direction = start_connector.GetDirection()
-
- items = []
-
- if self.CurrentLanguage == "SFC" and start_direction == SOUTH:
- items.extend([
- (_(u'Initial Step'), self.GetAddToWireMenuCallBack(self.AddNewStep, True)),
- (_(u'Step'), self.GetAddToWireMenuCallBack(self.AddNewStep, False)),
- (_(u'Transition'), self.GetAddToWireMenuCallBack(self.AddNewTransition, False)),
- (_(u'Divergence'), self.GetAddToWireMenuCallBack(self.AddNewDivergence)),
- (_(u'Jump'), self.GetAddToWireMenuCallBack(self.AddNewJump)),
- ])
-
- elif start_direction == EAST:
-
- if isinstance(start_connector.GetParentBlock(), SFC_Step):
- items.append(
- (_(u'Action Block'), self.GetAddToWireMenuCallBack(self.AddNewActionBlock))
- )
- else:
- items.extend([
- (_(u'Block'), self.GetAddToWireMenuCallBack(self.AddNewBlock)),
- (_(u'Variable'), self.GetAddToWireMenuCallBack(self.AddNewVariable, True)),
- (_(u'Connection'), self.GetAddToWireMenuCallBack(self.AddNewConnection)),
- ])
-
- if self.CurrentLanguage != "FBD":
- items.append(
- (_(u'Contact'), self.GetAddToWireMenuCallBack(self.AddNewContact))
- )
- if self.CurrentLanguage == "LD":
- items.extend([
- (_(u'Coil'), self.GetAddToWireMenuCallBack(self.AddNewCoil)),
- (_(u'Power Rail'), self.GetAddToWireMenuCallBack(self.AddNewPowerRail)),
- ])
- if self.CurrentLanguage == "SFC":
- items.append(
- (_(u'Transition'), self.GetAddToWireMenuCallBack(self.AddNewTransition, True))
- )
-
+ items = self.GetPopupMenuItems()
if len(items) > 0:
if self.Editor.HasCapture():
self.Editor.ReleaseMouse()
@@ -2273,7 +2258,8 @@
self.rubberBand.OnMotion(event, dc, self.Scaling)
elif not self.Debug and self.Mode == MODE_SELECTION and self.SelectedElement is not None:
if self.DrawingWire:
- connector = self.FindBlockConnector(pos, self.SelectedElement.GetConnectionDirection(), self.SelectedElement.EndConnected)
+ connector, errorHighlight = self.FindBlockConnectorWithError(pos, self.SelectedElement.GetConnectionDirection(), self.SelectedElement.EndConnected)
+ self.SelectedElement.ErrHighlight = errorHighlight;
if not connector or self.SelectedElement.EndConnected == None:
self.SelectedElement.ResetPoints()
movex, movey = self.SelectedElement.OnMotion(event, dc, self.Scaling)
@@ -2340,6 +2326,54 @@
self.Scroll(xstart + move_window.x, ystart + move_window.y)
self.RefreshScrollBars(move_window.x, move_window.y)
+ def BlockCompatibility(self, startblock=None, endblock=None, direction = None):
+ return True
+
+ def GetPopupMenuItems(self):
+ start_connector = self.SelectedElement.GetStartConnected()
+ start_direction = start_connector.GetDirection()
+ startblock = start_connector.GetParentBlock()
+ items = []
+ if isinstance(startblock, SFC_Objects):
+ startblockname = self.GetBlockName(startblock)
+ poss_div_types = []
+
+ SFC_WireMenu_Buttons = {
+ 'SFC_Step': (_(u'Step'), self.GetAddToWireMenuCallBack(self.AddNewStep, False)),
+ 'SFC_Jump': (_(u'Jump'), self.GetAddToWireMenuCallBack(self.AddNewJump)),
+ 'SFC_Transition': (_(u'Transition'), self.GetAddToWireMenuCallBack(self.AddNewTransition, False)),
+ 'SFC_ActionBlock': (_(u'Action Block'), self.GetAddToWireMenuCallBack(self.AddNewActionBlock))}
+
+ for endblock in self.SFC_StandardRules.get(startblockname):
+ if start_direction in endblock:
+ if endblock[0] in divergence_types:
+ poss_div_types.append(endblock[0])
+ else:
+ items.append(SFC_WireMenu_Buttons[endblock[0]])
+ if len(poss_div_types) > 0:
+ items.append((_(u'Divergence'), self.GetAddToWireMenuCallBack(self.AddNewDivergence,
+ poss_div_types)))
+ elif start_direction == EAST:
+ items.extend([
+ (_(u'Block'), self.GetAddToWireMenuCallBack(self.AddNewBlock)),
+ (_(u'Connection'), self.GetAddToWireMenuCallBack(self.AddNewConnection))])
+
+ if self.CurrentLanguage != "FBD":
+ items.append((_(u'Contact'), self.GetAddToWireMenuCallBack(self.AddNewContact)))
+
+ if self.CurrentLanguage == "LD":
+ items.extend([
+ (_(u'Coil'), self.GetAddToWireMenuCallBack(self.AddNewCoil)),
+ (_(u'Power Rail'), self.GetAddToWireMenuCallBack(self.AddNewPowerRail))])
+
+ if self.CurrentLanguage == "SFC":
+ items.append(
+ (_(u'Transition'), self.GetAddToWireMenuCallBack(self.AddNewTransition, True)))
+ else:
+ items.append(
+ (_(u'Variable'), self.GetAddToWireMenuCallBack(self.AddNewVariable, True)))
+ return items
+
#-------------------------------------------------------------------------------
# Keyboard event functions
#-------------------------------------------------------------------------------
@@ -2398,7 +2432,7 @@
if self.IsBlock(self.SelectedElement) or self.IsComment(self.SelectedElement):
block = self.CopyBlock(self.SelectedElement, wx.Point(*self.SelectedElement.GetPosition()))
event = wx.MouseEvent()
- event.m_x, event.m_y = self.Editor.ScreenToClient(wx.GetMousePosition())
+ event.x, event.y = self.Editor.ScreenToClient(wx.GetMousePosition())
dc = self.GetLogicalDC()
self.SelectedElement.OnLeftUp(event, dc, self.Scaling)
self.SelectedElement.SetSelected(False)
@@ -2607,7 +2641,7 @@
"name": self.Controler.GenerateNewName(
self.TagName, None, "Step%d", 0),
"input": True,
- "output": False,
+ "output": True,
"action":False}
else:
dialog = SFCStepDialog(self.ParentWindow, self.Controler, self.TagName, initial)
@@ -2651,8 +2685,8 @@
connector = transition.GetConnectors()["inputs"][0]
self.AddNewElement(transition, bbox, wire, connector)
- def AddNewDivergence(self, bbox, wire=None):
- dialog = SFCDivergenceDialog(self.ParentWindow, self.Controler, self.TagName)
+ def AddNewDivergence(self, bbox, poss_div_types = None, wire=None):
+ dialog = SFCDivergenceDialog(self.ParentWindow, self.Controler, self.TagName, poss_div_types)
dialog.SetPreviewFont(self.GetFont())
dialog.SetMinElementSize((bbox.width, bbox.height))
if dialog.ShowModal() == wx.ID_OK:
@@ -2868,7 +2902,20 @@
if dialog.ShowModal() == wx.ID_OK:
values = dialog.GetValues()
rect = step.GetRedrawRect(1, 1)
- step.SetName(values["name"])
+
+ new_name = values["name"]
+ if self.GetDrawingMode() == DRIVENDRAWING_MODE:
+ old_name = step.GetName().upper()
+ if new_name.upper() != old_name:
+ for block in self.Blocks.itervalues():
+ if isinstance(block, SFC_Jump):
+ if old_name == block.GetTarget().upper():
+ block.SetTarget(new_name)
+ block.RefreshModel()
+ rect = rect.Union(block.GetRedrawRect())
+ block.Refresh(rect)
+ step.SetName(new_name)
+
if values["input"]:
step.AddInput()
else:
@@ -2915,7 +2962,12 @@
dialog = wx.SingleChoiceDialog(self.ParentWindow,
_("Edit jump target"), _("Please choose a target"),
choices, wx.DEFAULT_DIALOG_STYLE|wx.OK|wx.CANCEL)
- dialog.SetSelection(choices.index(jump.GetTarget()))
+ try:
+ indx = choices.index(jump.GetTarget())
+ dialog.SetSelection(indx)
+ except ValueError:
+ pass
+
if dialog.ShowModal() == wx.ID_OK:
value = dialog.GetStringSelection()
rect = jump.GetRedrawRect(1, 1)
@@ -3216,6 +3268,17 @@
if element not in elements:
elements.append(element)
step.Clean()
+
+ if self.GetDrawingMode() == DRIVENDRAWING_MODE:
+ name = step.GetName().upper()
+ remove_jumps = []
+ for block in self.Blocks.itervalues():
+ if isinstance(block, SFC_Jump):
+ if name == block.GetTarget().upper():
+ remove_jumps.append(block)
+ for jump in remove_jumps:
+ self.DeleteJump(jump)
+
self.RemoveBlock(step)
self.Controler.RemoveEditedElementInstance(self.TagName, step.GetId())
for element in elements:
@@ -3399,22 +3462,16 @@
self.ClearHighlights(SEARCH_RESULT_HIGHLIGHT)
self.SearchParams = search_params
- criteria = {
- "raw_pattern": search_params["find_pattern"],
- "pattern": re.compile(search_params["find_pattern"]),
- "case_sensitive": search_params["case_sensitive"],
- "regular_expression": search_params["regular_expression"],
- "filter": "all"}
-
self.SearchResults = []
blocks = []
- for infos, start, end, text in self.Controler.SearchInPou(self.TagName, criteria, self.Debug):
- if infos[1] in ["var_local", "var_input", "var_output", "var_inout"]:
- self.SearchResults.append((infos[1:], start, end, SEARCH_RESULT_HIGHLIGHT))
- else:
- block = self.Blocks.get(infos[2])
- if block is not None:
- blocks.append((block, (infos[1:], start, end, SEARCH_RESULT_HIGHLIGHT)))
+ for infos, start, end, text in self.Controler.SearchInPou(self.TagName, search_params, self.Debug):
+ if (infos[0] == self.TagName or self.TagName.split("::")[0] in ['A', 'T']) and infos[1] is not 'name':
+ if infos[1] in ["var_local", "var_input", "var_output", "var_inout"]:
+ self.SearchResults.append((infos[1:], start, end, SEARCH_RESULT_HIGHLIGHT))
+ else:
+ block = self.Blocks.get(infos[2])
+ if block is not None:
+ blocks.append((block, (infos[1:], start, end, SEARCH_RESULT_HIGHLIGHT)))
blocks.sort(sort_blocks)
self.SearchResults.extend([infos for block, infos in blocks])
self.CurrentFindHighlight = None
diff -r a375e31bf312 -r c1298e7ffe3a features.py
--- a/features.py Sun Mar 05 00:38:25 2017 +0000
+++ b/features.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,3 +1,27 @@
+#!/usr/bin/env python
+# -*- coding: utf-8 -*-
+
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+
libraries = [
('Native', 'NativeLib.NativeLibrary'),
('Python', 'py_ext.PythonLibrary'),
diff -r a375e31bf312 -r c1298e7ffe3a graphics/.cvsignore
--- a/graphics/.cvsignore Sun Mar 05 00:38:25 2017 +0000
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,1 +0,0 @@
-*.pyc
diff -r a375e31bf312 -r c1298e7ffe3a graphics/DebugDataConsumer.py
--- a/graphics/DebugDataConsumer.py Sun Mar 05 00:38:25 2017 +0000
+++ b/graphics/DebugDataConsumer.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
-#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
-#
-#See COPYING file for copyrights details.
-#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
-#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
-#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import datetime
diff -r a375e31bf312 -r c1298e7ffe3a graphics/FBD_Objects.py
--- a/graphics/FBD_Objects.py Sun Mar 05 00:38:25 2017 +0000
+++ b/graphics/FBD_Objects.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import wx
@@ -902,7 +902,15 @@
else:
connectors["outputs"].append(self.Connector)
return connectors
-
+
+ def SpreadCurrent(self):
+ if self.Type == CONNECTOR:
+ continuations = self.Parent.GetContinuationByName(self.Name)
+ if continuations is not None:
+ value = self.Connector.ReceivingCurrent()
+ for cont in continuations:
+ cont.Connector.SpreadCurrent(value)
+
# Changes the variable type
def SetType(self, type):
if type != self.Type:
diff -r a375e31bf312 -r c1298e7ffe3a graphics/GraphicCommons.py
--- a/graphics/GraphicCommons.py Sun Mar 05 00:38:25 2017 +0000
+++ b/graphics/GraphicCommons.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import wx
from math import *
@@ -1351,19 +1351,35 @@
self.Edge = edge
self.Negated = False
+ # assume that pointer is already inside of this connector
+ def ConnectionAvailable(self, direction=None, exclude=True):
+ wire_nums = len(self.Wires)
+
+ connector_free = (wire_nums<= 0)
+ connector_max_used = ((wire_nums > 0) and self.OneConnected)
+ if (self.Parent.CurrentLanguage in ["SFC", "LD"]) and (self.Type == "BOOL"):
+ connector_max_used = False;
+
+ # connector is available for new connection
+ connect = connector_free or not connector_max_used
+ return connect, connector_max_used
+
# Tests if the point given is near from the end point of this connector
- def TestPoint(self, pt, direction = None, exclude = True):
- parent_pos = self.ParentBlock.GetPosition()
- if (not (len(self.Wires) > 0 and self.OneConnected and exclude) or self.Type == "BOOL")\
- and direction is None or self.Direction == direction:
+ def TestPoint(self, pt, direction=None, exclude=True):
+ inside = False;
+ check_point = (not exclude) and (direction is None or self.Direction == direction);
+
+ if check_point:
# Calculate a square around the end point of this connector
+ parent_pos = self.ParentBlock.GetPosition()
x = parent_pos[0] + self.Pos.x + self.Direction[0] * CONNECTOR_SIZE - ANCHOR_DISTANCE
y = parent_pos[1] + self.Pos.y + self.Direction[1] * CONNECTOR_SIZE - ANCHOR_DISTANCE
width = ANCHOR_DISTANCE * 2 + abs(self.Direction[0]) * CONNECTOR_SIZE
height = ANCHOR_DISTANCE * 2 + abs(self.Direction[1]) * CONNECTOR_SIZE
rect = wx.Rect(x, y, width, height)
- return rect.InsideXY(pt.x, pt.y)
- return False
+ inside = rect.InsideXY(pt.x, pt.y);
+
+ return inside
# Draws the highlightment of this element if it is highlighted
def DrawHighlightment(self, dc):
@@ -1551,6 +1567,7 @@
self.OverEnd = False
self.ComputingType = False
self.Font = parent.GetMiniFont()
+ self.ErrHighlight = False
def GetDefinition(self):
if self.StartConnected is not None and self.EndConnected is not None:
@@ -2590,8 +2607,13 @@
def DrawHighlightment(self, dc):
scalex, scaley = dc.GetUserScale()
dc.SetUserScale(1, 1)
- dc.SetPen(MiterPen(HIGHLIGHTCOLOR, (2 * scalex + 5)))
- dc.SetBrush(wx.Brush(HIGHLIGHTCOLOR))
+ # If user trying to connect wire with wrong input, highlight will become red.
+ if self.ErrHighlight == True and not (self.EndConnected):
+ highlightcolor = wx.RED
+ else:
+ highlightcolor = HIGHLIGHTCOLOR
+ dc.SetPen(MiterPen(highlightcolor, (2 * scalex + 5)))
+ dc.SetBrush(wx.Brush(highlightcolor))
dc.SetLogicalFunction(wx.AND)
# Draw the start and end points if they are not connected or the mouse is over them
if len(self.Points) > 0 and (not self.StartConnected or self.OverStart):
@@ -2873,10 +2895,15 @@
wx.Point(self.Pos.x + self.Size[0], self.Pos.y + self.Size[1]),
wx.Point(self.Pos.x, self.Pos.y + self.Size[1])]
dc.DrawPolygon(polygon)
+
+ # dc.SetBrush call is workaround for the issue with wx.PrinterDC
+ # with wxPython 3.0 on GNU/Linux (don't remove it)
+ dc.SetBrush(wx.WHITE_BRUSH)
lines = [wx.Point(self.Pos.x + self.Size[0] - 10, self.Pos.y),
wx.Point(self.Pos.x + self.Size[0] - 10, self.Pos.y + 10),
wx.Point(self.Pos.x + self.Size[0], self.Pos.y + 10)]
dc.DrawLines(lines)
+
# Draws the comment content
y = self.Pos.y + 10
for idx, line in enumerate(self.Content.splitlines()):
diff -r a375e31bf312 -r c1298e7ffe3a graphics/LD_Objects.py
--- a/graphics/LD_Objects.py Sun Mar 05 00:38:25 2017 +0000
+++ b/graphics/LD_Objects.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import wx
diff -r a375e31bf312 -r c1298e7ffe3a graphics/RubberBand.py
--- a/graphics/RubberBand.py Sun Mar 05 00:38:25 2017 +0000
+++ b/graphics/RubberBand.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import wx
diff -r a375e31bf312 -r c1298e7ffe3a graphics/SFC_Objects.py
--- a/graphics/SFC_Objects.py Sun Mar 05 00:38:25 2017 +0000
+++ b/graphics/SFC_Objects.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import wx
diff -r a375e31bf312 -r c1298e7ffe3a graphics/ToolTipProducer.py
--- a/graphics/ToolTipProducer.py Sun Mar 05 00:38:25 2017 +0000
+++ b/graphics/ToolTipProducer.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import wx
diff -r a375e31bf312 -r c1298e7ffe3a graphics/__init__.py
--- a/graphics/__init__.py Sun Mar 05 00:38:25 2017 +0000
+++ b/graphics/__init__.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
# Package initialisation
@@ -29,4 +29,4 @@
from LD_Objects import *
from SFC_Objects import *
from RubberBand import RubberBand
-from DebugDataConsumer import DebugDataConsumer
\ No newline at end of file
+from DebugDataConsumer import DebugDataConsumer
diff -r a375e31bf312 -r c1298e7ffe3a i18n/Beremiz_ru_RU.po
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/i18n/Beremiz_ru_RU.po Fri Mar 24 12:07:47 2017 +0000
@@ -0,0 +1,4063 @@
+# SOME DESCRIPTIVE TITLE.
+# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
+# This file is distributed under the same license as the PACKAGE package.
+# FIRST AUTHOR , YEAR.
+#
+msgid ""
+msgstr ""
+"Project-Id-Version: Beremiz\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2017-01-12 14:39+0300\n"
+"PO-Revision-Date: 2017-01-12 14:41+0300\n"
+"Last-Translator: Andrey Skvortsov \n"
+"Language-Team: Andrey Skvortsov \n"
+"Language: ru_RU\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+"X-Generator: Poedit 1.8.11\n"
+
+#: ../PLCOpenEditor.py:408 ../Beremiz.py:1191
+#, python-format
+msgid ""
+"\n"
+"An unhandled exception (bug) occured. Bug report saved at :\n"
+"(%s)\n"
+"\n"
+"Please be kind enough to send this file to:\n"
+"beremiz-devel@lists.sourceforge.net\n"
+"\n"
+"You should now restart program.\n"
+"\n"
+"Traceback:\n"
+msgstr ""
+"\n"
+"Произошла невосстанавливаемая ошибка (bug). Отчет об ошибке сохранен в:\n"
+"(%s)\n"
+"\n"
+"Будьте добры, отправьте этот файл по адресу\n"
+"beremiz-devel@lists.sourceforge.net\n"
+"\n"
+"Для дальнейшей работы перезапустите программу.\n"
+"\n"
+"Traceback:\n"
+
+#: ../controls/VariablePanel.py:72
+msgid " External"
+msgstr " Внешний"
+
+#: ../controls/VariablePanel.py:71
+msgid " InOut"
+msgstr " Вход/Выход"
+
+#: ../controls/VariablePanel.py:71
+msgid " Input"
+msgstr " Вход"
+
+#: ../controls/VariablePanel.py:72
+msgid " Local"
+msgstr " Локальный"
+
+#: ../controls/VariablePanel.py:71
+msgid " Output"
+msgstr " Выход"
+
+#: ../controls/VariablePanel.py:73
+msgid " Temp"
+msgstr " Временный"
+
+#: ../dialogs/PouTransitionDialog.py:99 ../dialogs/ProjectDialog.py:66
+#: ../dialogs/PouActionDialog.py:91 ../dialogs/PouDialog.py:113
+#, python-format
+msgid " and %s"
+msgstr "и %s"
+
+#: ../ProjectController.py:1089
+msgid " generation failed !\n"
+msgstr "неудачная генерация кода!\n"
+
+#: ../plcopen/plcopen.py:881
+#, python-format
+msgid "\"%s\" Data Type doesn't exist !!!"
+msgstr "Тип данных \"%s\" не существует!!!"
+
+#: ../plcopen/plcopen.py:899
+#, python-format
+msgid "\"%s\" POU already exists !!!"
+msgstr "POU \"%s\" уже существует!!!"
+
+#: ../plcopen/plcopen.py:920
+#, python-format
+msgid "\"%s\" POU doesn't exist !!!"
+msgstr "POU \"%s\" не найден!!!"
+
+#: ../editors/Viewer.py:246
+#, python-format
+msgid "\"%s\" can't use itself!"
+msgstr "\"%s\" не может использовать сам себя!!!"
+
+#: ../IDEFrame.py:1652 ../IDEFrame.py:1671
+#, python-format
+msgid "\"%s\" config already exists!"
+msgstr "Конфигурация \"%s\" уже существует!!!"
+
+#: ../plcopen/plcopen.py:467
+#, python-format
+msgid "\"%s\" configuration already exists !!!"
+msgstr "Конфигурация \"%s\" уже существует!!!"
+
+#: ../IDEFrame.py:1602
+#, python-format
+msgid "\"%s\" data type already exists!"
+msgstr "Тип данных \"%s\" уже существует!!!"
+
+#: ../dialogs/PouTransitionDialog.py:110 ../dialogs/BlockPreviewDialog.py:219
+#: ../dialogs/PouActionDialog.py:102 ../editors/Viewer.py:262
+#: ../editors/Viewer.py:330 ../editors/Viewer.py:354 ../editors/Viewer.py:374
+#: ../editors/TextViewer.py:272 ../editors/TextViewer.py:301
+#: ../controls/VariablePanel.py:396
+#, python-format
+msgid "\"%s\" element for this pou already exists!"
+msgstr "Элемент с именем \"%s\" уже существует в этом POU!!!"
+
+#: ../Beremiz.py:994
+#, python-format
+msgid "\"%s\" folder is not a valid Beremiz project\n"
+msgstr "Директория \"%s\" не является проектом Beremiz\n"
+
+#: ../dialogs/SFCStepNameDialog.py:52 ../dialogs/PouTransitionDialog.py:106
+#: ../dialogs/BlockPreviewDialog.py:207 ../dialogs/PouNameDialog.py:50
+#: ../dialogs/PouActionDialog.py:98 ../dialogs/PouDialog.py:120
+#: ../editors/DataTypeEditor.py:555 ../editors/DataTypeEditor.py:584
+#: ../editors/CodeFileEditor.py:770 ../controls/VariablePanel.py:751
+#: ../IDEFrame.py:1593
+#, python-format
+msgid "\"%s\" is a keyword. It can't be used!"
+msgstr "\"%s\" является ключевым словом и не может быть использован!"
+
+#: ../plcopen/plcopen.py:2412
+#, python-format
+msgid "\"%s\" is an invalid value!"
+msgstr "\"%s\" недопустимое значение!"
+
+#: ../PLCOpenEditor.py:339 ../PLCOpenEditor.py:381
+#, python-format
+msgid "\"%s\" is not a valid folder!"
+msgstr "\"%s\" не является директорией!"
+
+#: ../dialogs/SFCStepNameDialog.py:50 ../dialogs/PouTransitionDialog.py:104
+#: ../dialogs/BlockPreviewDialog.py:203 ../dialogs/PouNameDialog.py:48
+#: ../dialogs/PouActionDialog.py:96 ../dialogs/PouDialog.py:118
+#: ../editors/DataTypeEditor.py:579 ../editors/CodeFileEditor.py:768
+#: ../controls/VariablePanel.py:749 ../IDEFrame.py:1591
+#, python-format
+msgid "\"%s\" is not a valid identifier!"
+msgstr "\"%s\" неверный идентификатор!"
+
+#: ../IDEFrame.py:2396
+#, python-format
+msgid "\"%s\" is used by one or more POUs. Do you wish to continue?"
+msgstr "\"%s\" используется более чем одним POU. Продолжить?"
+
+#: ../dialogs/BlockPreviewDialog.py:211 ../dialogs/PouDialog.py:122
+#: ../editors/Viewer.py:260 ../editors/Viewer.py:315 ../editors/Viewer.py:345
+#: ../editors/Viewer.py:367 ../editors/TextViewer.py:270
+#: ../editors/TextViewer.py:299 ../editors/TextViewer.py:350
+#: ../editors/TextViewer.py:373 ../controls/VariablePanel.py:338
+#: ../IDEFrame.py:1611
+#, python-format
+msgid "\"%s\" pou already exists!"
+msgstr "POU \"%s\" уже существует!"
+
+#: ../dialogs/SFCStepNameDialog.py:58
+#, python-format
+msgid "\"%s\" step already exists!"
+msgstr "Шаг \"%s\" уже существует!"
+
+#: ../editors/DataTypeEditor.py:550
+#, python-format
+msgid "\"%s\" value already defined!"
+msgstr "\"%s\" значение уже задано!"
+
+#: ../dialogs/ArrayTypeDialog.py:97 ../editors/DataTypeEditor.py:745
+#, python-format
+msgid "\"%s\" value isn't a valid array dimension!"
+msgstr "\"%s\" не является корректной размерностью для массива! "
+
+#: ../dialogs/ArrayTypeDialog.py:103 ../editors/DataTypeEditor.py:752
+#, python-format
+msgid ""
+"\"%s\" value isn't a valid array dimension!\n"
+"Right value must be greater than left value."
+msgstr "\"%s\" не является корректной размерностью массива! Правое значение должно быть больше левого."
+
+#: ../PLCGenerator.py:1101
+#, python-brace-format
+msgid "\"{a1}\" function cancelled in \"{a2}\" POU: No input connected"
+msgstr "Функция \"{a1}\" не используется в POU \"{a2}\": входы не подключены"
+
+#: ../editors/Viewer.py:250
+#, python-brace-format
+msgid "\"{a1}\" is already used by \"{a2}\"!"
+msgstr "\"{a1}\" уже используется \"{a2}\"!"
+
+#: ../plcopen/plcopen.py:491
+#, python-brace-format
+msgid "\"{a1}\" resource already exists in \"{a2}\" configuration !!!"
+msgstr "Ресурс \"{a1}\" уже существует в конфигурации \"{a2}\"!!!"
+
+#: ../plcopen/plcopen.py:509
+#, python-brace-format
+msgid "\"{a1}\" resource doesn't exist in \"{a2}\" configuration !!!"
+msgstr "Ресурс \"{a1}\" отсутствует в конфигурации \"{a2}\"!!!"
+
+msgid "%(codefile_name)s"
+msgstr "%(codefile_name)"
+
+#: ../controls/DebugVariablePanel/DebugVariablePanel.py:578
+#, python-format
+msgid "%03gms"
+msgstr "%03gмс"
+
+#: ../controls/DebugVariablePanel/DebugVariablePanel.py:569
+#, python-format
+msgid "%dd"
+msgstr "%dд"
+
+#: ../controls/DebugVariablePanel/DebugVariablePanel.py:56
+#: ../controls/DebugVariablePanel/DebugVariablePanel.py:570
+#, python-format
+msgid "%dh"
+msgstr "%dч"
+
+#: ../controls/DebugVariablePanel/DebugVariablePanel.py:55
+#: ../controls/DebugVariablePanel/DebugVariablePanel.py:571
+#, python-format
+msgid "%dm"
+msgstr "%dм"
+
+#: ../controls/DebugVariablePanel/DebugVariablePanel.py:53
+#, python-format
+msgid "%dms"
+msgstr "%dмс"
+
+#: ../controls/DebugVariablePanel/DebugVariablePanel.py:54
+#: ../controls/DebugVariablePanel/DebugVariablePanel.py:572
+#, python-format
+msgid "%ds"
+msgstr "%dc"
+
+#: ../PLCControler.py:1531
+#, python-format
+msgid "%s Data Types"
+msgstr "%s типы данных"
+
+#: ../PLCControler.py:1514
+#, python-format
+msgid "%s POUs"
+msgstr "%s POU"
+
+#: ../canfestival/SlaveEditor.py:69 ../canfestival/NetworkEditor.py:90
+#, python-format
+msgid "%s Profile"
+msgstr "%s профиль"
+
+#: ../plcopen/plcopen.py:1645 ../plcopen/plcopen.py:1652
+#: ../plcopen/plcopen.py:1664 ../plcopen/plcopen.py:1672
+#: ../plcopen/plcopen.py:1682
+#, python-format
+msgid "%s body don't have instances!"
+msgstr "Тело %s не содержит экземпляров!"
+
+#: ../plcopen/plcopen.py:1700 ../plcopen/plcopen.py:1707
+#: ../plcopen/plcopen.py:1714
+#, python-format
+msgid "%s body don't have text!"
+msgstr "Тело %s не содержит никакой текст!"
+
+#: ../IDEFrame.py:386
+msgid "&Add Element"
+msgstr "&Добавить элемент"
+
+#: ../dialogs/AboutDialog.py:65 ../dialogs/AboutDialog.py:113
+#: ../dialogs/AboutDialog.py:150
+msgid "&Close"
+msgstr "&Закрыть"
+
+#: ../IDEFrame.py:356
+msgid "&Configuration"
+msgstr "&Конфигурация"
+
+#: ../IDEFrame.py:345
+msgid "&Data Type"
+msgstr "&Типы данных"
+
+#: ../IDEFrame.py:390
+msgid "&Delete"
+msgstr "&Удалить"
+
+#: ../IDEFrame.py:337
+msgid "&Display"
+msgstr "&Вид"
+
+#: ../IDEFrame.py:336
+msgid "&Edit"
+msgstr "&Редактировать"
+
+#: ../IDEFrame.py:335
+msgid "&File"
+msgstr "&Файл"
+
+#: ../IDEFrame.py:347
+msgid "&Function"
+msgstr "&Функции"
+
+#: ../IDEFrame.py:338
+msgid "&Help"
+msgstr "&Помощь"
+
+#: ../dialogs/AboutDialog.py:64
+msgid "&License"
+msgstr "&Лицензия"
+
+#: ../IDEFrame.py:351
+msgid "&Program"
+msgstr "&Программы"
+
+#: ../PLCOpenEditor.py:125
+msgid "&Properties"
+msgstr "&Свойства"
+
+#: ../Beremiz.py:324
+msgid "&Recent Projects"
+msgstr "&Недавние проекты"
+
+#: ../IDEFrame.py:353
+msgid "&Resource"
+msgstr "&Ресурсы"
+
+#: ../controls/SearchResultPanel.py:239
+#, python-brace-format
+msgid "'{a1}' - {a2} match in project"
+msgstr "'{a1}'- {a2} совпадений в проекте"
+
+#: ../controls/SearchResultPanel.py:241
+#, python-brace-format
+msgid "'{a1}' - {a2} matches in project"
+msgstr "'{a1}' - {a2} совпадений в проекте"
+
+#: ../connectors/PYRO/__init__.py:90
+#, python-brace-format
+msgid "'{a1}' is located at {a2}\n"
+msgstr "'{a1}' находится {a2}\n"
+
+#: ../controls/SearchResultPanel.py:291
+#, python-format
+msgid "(%d matches)"
+msgstr "(%d совпадений)"
+
+#: ../PLCOpenEditor.py:396 ../PLCOpenEditor.py:398 ../PLCOpenEditor.py:399
+msgid ", "
+msgstr ", "
+
+#: ../dialogs/PouTransitionDialog.py:101 ../dialogs/PouActionDialog.py:93
+#: ../dialogs/PouDialog.py:115
+#, python-format
+msgid ", %s"
+msgstr ", %s"
+
+#: ../PLCOpenEditor.py:394
+msgid ". "
+msgstr ". "
+
+#: Extra TC6 documentation strings
+msgid "0 - current time, 1 - load time from PDT"
+msgstr "0 - текущее время, 1 - отклонение от PDT"
+
+msgid "0 - manual , 1 - automatic"
+msgstr "0 - ручной, 1 - автоматический"
+
+msgid "0 - track X0, 1 - ramp to/track X1"
+msgstr "0 - вход X0, 1 - нарастание до значения X1"
+
+msgid "0 = reset"
+msgstr "0 = сброс"
+
+msgid "1 = integrate, 0 = hold"
+msgstr "1 = интегрировать, 0 = остановка"
+
+#: ../controls/LogViewer.py:279
+msgid "1d"
+msgstr "1 день"
+
+#: ../controls/LogViewer.py:280
+msgid "1h"
+msgstr "1 час"
+
+#: ../controls/LogViewer.py:281
+msgid "1m"
+msgstr "1 мин"
+
+#: ../controls/LogViewer.py:282
+msgid "1s"
+msgstr "1 сек"
+
+#: ../dialogs/PouDialog.py:124 ../IDEFrame.py:1614 ../IDEFrame.py:1660
+#: ../IDEFrame.py:1679
+#, python-format
+msgid "A POU has an element named \"%s\". This could cause a conflict. Do you wish to continue?"
+msgstr "В POU присутствует элемент с именем \"%s\". Это может вызвать конфликт. Хотите продолжить?"
+
+#: ../dialogs/SFCStepNameDialog.py:54 ../dialogs/PouTransitionDialog.py:108
+#: ../dialogs/PouNameDialog.py:52 ../dialogs/PouActionDialog.py:100
+#: ../controls/VariablePanel.py:753 ../IDEFrame.py:1628 ../IDEFrame.py:1641
+#, python-format
+msgid "A POU named \"%s\" already exists!"
+msgstr "POU с именем \"%s\" уже существует!"
+
+#: ../ConfigTreeNode.py:424
+#, python-brace-format
+msgid "A child named \"{a1}\" already exists -> \"{a2}\"\n"
+msgstr "Дочерний элемент с именем \"{a1}\" уже существует -> \"{a2}\"\n"
+
+#: ../dialogs/BrowseLocationsDialog.py:216
+msgid "A location must be selected!"
+msgstr "Необходимо выбрать размещение!"
+
+#: ../dialogs/SFCStepNameDialog.py:56 ../controls/VariablePanel.py:755
+#: ../IDEFrame.py:1630 ../IDEFrame.py:1643
+#, python-format
+msgid "A variable with \"%s\" as name already exists in this pou!"
+msgstr "Переменная с именем \"%s\" уже существует в этом POU!"
+
+#: ../editors/CodeFileEditor.py:774
+#, python-format
+msgid "A variable with \"%s\" as name already exists!"
+msgstr "Переменная с именем \"%s\" уже существует!"
+
+#: ../dialogs/AboutDialog.py:40 ../PLCOpenEditor.py:158 ../Beremiz.py:381
+msgid "About"
+msgstr "О программе"
+
+#: ../plcopen/iec_std.csv:22
+msgid "Absolute number"
+msgstr "Абсолютный номер"
+
+#: ../dialogs/SFCStepDialog.py:72 ../dialogs/ActionBlockDialog.py:42
+msgid "Action"
+msgstr "Действие"
+
+#: ../editors/Viewer.py:555 ../editors/Viewer.py:2345
+msgid "Action Block"
+msgstr "Блок действия"
+
+#: ../dialogs/PouActionDialog.py:81
+msgid "Action Name"
+msgstr "Имя действия"
+
+#: ../dialogs/PouActionDialog.py:49
+msgid "Action Name:"
+msgstr "Имя действия:"
+
+#: ../plcopen/plcopen.py:1359
+#, python-format
+msgid "Action with name %s doesn't exist!"
+msgstr "Действие с именем %s не существует!"
+
+#: ../PLCControler.py:96
+msgid "Actions"
+msgstr "Действия"
+
+#: ../dialogs/ActionBlockDialog.py:133
+msgid "Actions:"
+msgstr "Действия:"
+
+#: ../editors/Viewer.py:1100
+msgid "Active"
+msgstr "Активный"
+
+#: ../canfestival/SlaveEditor.py:80 ../canfestival/NetworkEditor.py:101
+#: ../editors/Viewer.py:588 ../Beremiz.py:1060
+msgid "Add"
+msgstr "Добавить"
+
+#: ../IDEFrame.py:1890 ../IDEFrame.py:1925
+msgid "Add Action"
+msgstr "Добавить действие"
+
+#: ../features.py:32
+msgid "Add C code accessing located variables synchronously"
+msgstr "Добавить C-код с синхронным доступом к локальным переменным"
+
+#: ../IDEFrame.py:1873
+msgid "Add Configuration"
+msgstr "Добавить конфигурацию"
+
+#: ../IDEFrame.py:1853
+msgid "Add DataType"
+msgstr "Добавить тип данных"
+
+#: ../editors/Viewer.py:513
+msgid "Add Divergence Branch"
+msgstr "Добавить ветвление"
+
+#: ../dialogs/DiscoveryDialog.py:116
+msgid "Add IP"
+msgstr "Добавить IP адрес"
+
+#: ../IDEFrame.py:1861
+msgid "Add POU"
+msgstr "Добавить POU"
+
+#: ../features.py:33
+msgid "Add Python code executed asynchronously"
+msgstr "Добавить асинхронно вызываемый код на Python"
+
+#: ../IDEFrame.py:1901 ../IDEFrame.py:1951
+msgid "Add Resource"
+msgstr "Добавить ресурс"
+
+#: ../IDEFrame.py:1879 ../IDEFrame.py:1922
+msgid "Add Transition"
+msgstr "Добавить переход"
+
+#: ../editors/Viewer.py:500
+msgid "Add Wire Segment"
+msgstr "Добавить провод"
+
+#: ../editors/SFCViewer.py:433
+msgid "Add a new initial step"
+msgstr "Добавить новый исходный шаг"
+
+#: ../editors/Viewer.py:2706 ../editors/SFCViewer.py:770
+msgid "Add a new jump"
+msgstr "Добавить новый безусловный переход"
+
+#: ../editors/SFCViewer.py:455
+msgid "Add a new step"
+msgstr "Добавить новый шаг"
+
+#: ../features.py:34
+msgid "Add a simple WxGlade based GUI."
+msgstr "Добавить простой GUI на WxGlade "
+
+#: ../dialogs/ActionBlockDialog.py:137
+msgid "Add action"
+msgstr "Добавить действие"
+
+#: ../editors/DataTypeEditor.py:352
+msgid "Add element"
+msgstr "Добавить элемент"
+
+#: ../editors/ResourceEditor.py:268
+msgid "Add instance"
+msgstr "Добавить экземпляр"
+
+#: ../canfestival/NetworkEditor.py:103
+msgid "Add slave"
+msgstr "Добавить слэйв"
+
+#: ../editors/ResourceEditor.py:239
+msgid "Add task"
+msgstr "Добавить задачу"
+
+#: ../editors/CodeFileEditor.py:658 ../controls/VariablePanel.py:450
+msgid "Add variable"
+msgstr "Добавить переменную"
+
+#: ../plcopen/iec_std.csv:33
+msgid "Addition"
+msgstr "Сложение"
+
+#: ../plcopen/definitions.py:47
+msgid "Additional function blocks"
+msgstr "Дополнительные функциональные блоки"
+
+#: ../editors/Viewer.py:571
+msgid "Adjust Block Size"
+msgstr "Скорректировать размер элемента"
+
+#: ../editors/Viewer.py:1637
+msgid "Alignment"
+msgstr "Выравнивание"
+
+#: ../dialogs/BrowseLocationsDialog.py:39
+#: ../dialogs/BrowseLocationsDialog.py:47
+#: ../dialogs/BrowseLocationsDialog.py:140
+#: ../dialogs/BrowseLocationsDialog.py:143 ../controls/LogViewer.py:298
+#: ../controls/VariablePanel.py:70
+msgid "All"
+msgstr "Все"
+
+#: ../editors/FileManagementPanel.py:35
+msgid "All files (*.*)|*.*|CSV files (*.csv)|*.csv"
+msgstr "Все файлы (*.*)|*.*|CSV files (*.csv)|*.csv"
+
+#: ../ProjectController.py:1623
+msgid "Already connected. Please disconnect\n"
+msgstr "Уже подключен. Пожалуйста, отключитесь сначала.\n"
+
+#: ../editors/DataTypeEditor.py:594
+#, python-format
+msgid "An element named \"%s\" already exists in this structure!"
+msgstr "Поле с именем \"%s\" уже существует в данной структуре!"
+
+#: ../dialogs/ConnectionDialog.py:96
+msgid "Apply name modification to all continuations with the same name"
+msgstr "Переименовать все цепи с тем же самым именем"
+
+#: ../plcopen/iec_std.csv:31
+msgid "Arc cosine"
+msgstr "Арккосинус"
+
+#: ../plcopen/iec_std.csv:30
+msgid "Arc sine"
+msgstr "Арксинус"
+
+#: ../plcopen/iec_std.csv:32
+msgid "Arc tangent"
+msgstr "Арктангенс"
+
+#: ../plcopen/iec_std.csv:33
+msgid "Arithmetic"
+msgstr "Математика"
+
+#: ../editors/DataTypeEditor.py:54 ../editors/DataTypeEditor.py:635
+#: ../controls/VariablePanel.py:829
+msgid "Array"
+msgstr "Массив"
+
+#: ../plcopen/iec_std.csv:39
+msgid "Assignment"
+msgstr "Присвоение"
+
+#: ../dialogs/FBDVariableDialog.py:217
+msgid "At least a variable or an expression must be selected!"
+msgstr "Переменная или выражение должно быть выбрано!"
+
+#: ../controls/ProjectPropertiesPanel.py:99
+msgid "Author"
+msgstr "Автор"
+
+#: ../controls/ProjectPropertiesPanel.py:96
+msgid "Author Name (optional):"
+msgstr "Имя автора (опционально):"
+
+msgid "BUSY = 1 during ramping period"
+msgstr "BOSY = 1 во время "
+
+#: ../dialogs/FindInPouDialog.py:79
+msgid "Backward"
+msgstr "Назад"
+
+#: ../util/Zeroconf.py:599
+msgid "Bad domain name (circular) at "
+msgstr "Неправильное доменное имя (ответ) в "
+
+#: ../util/Zeroconf.py:602
+msgid "Bad domain name at "
+msgstr "Неправильное доменное имя в"
+
+#: ../canfestival/config_utils.py:342 ../canfestival/config_utils.py:630
+#, python-format
+msgid "Bad location size : %s"
+msgstr "Неправильный размер: %s"
+
+#: ../dialogs/ArrayTypeDialog.py:55 ../editors/DataTypeEditor.py:175
+#: ../editors/DataTypeEditor.py:205 ../editors/DataTypeEditor.py:297
+msgid "Base Type:"
+msgstr "Базовый тип:"
+
+#: ../editors/DataTypeEditor.py:625 ../controls/VariablePanel.py:787
+msgid "Base Types"
+msgstr "Базовые типы"
+
+msgid "BaseParams"
+msgstr "Базовые параметры"
+
+#: ../Beremiz.py:553
+msgid "Beremiz"
+msgstr "Beremiz"
+
+msgid "BeremizRoot"
+msgstr "Настройки Beremiz "
+
+#: ../plcopen/iec_std.csv:70
+msgid "Binary selection (1 of 2)"
+msgstr "Бинарный выбор (1 или 2)"
+
+#: ../plcopen/iec_std.csv:62
+msgid "Bit-shift"
+msgstr "Сдвиговые операции"
+
+#: ../plcopen/iec_std.csv:66
+msgid "Bitwise"
+msgstr "Битовые операции"
+
+#: ../plcopen/iec_std.csv:66
+msgid "Bitwise AND"
+msgstr "Битовое И"
+
+#: ../plcopen/iec_std.csv:67
+msgid "Bitwise OR"
+msgstr "Битовое ИЛИ"
+
+#: ../plcopen/iec_std.csv:68
+msgid "Bitwise XOR"
+msgstr "Исключающее ИЛИ"
+
+#: ../plcopen/iec_std.csv:69
+msgid "Bitwise inverting"
+msgstr "Битовое НЕ"
+
+#: ../editors/Viewer.py:525 ../editors/Viewer.py:2358
+msgid "Block"
+msgstr "Блок"
+
+#: ../dialogs/FBDBlockDialog.py:59
+msgid "Block Properties"
+msgstr "Свойства блока"
+
+#: ../editors/TextViewer.py:262
+msgid "Block name"
+msgstr "Имя блока"
+
+#: ../editors/Viewer.py:491
+msgid "Bottom"
+msgstr "Низ"
+
+#: ../ProjectController.py:1301
+msgid "Broken"
+msgstr "Ошибка"
+
+#: ../dialogs/BrowseValuesLibraryDialog.py:37
+#, python-format
+msgid "Browse %s values library"
+msgstr "Browse %s values library"
+
+#: ../dialogs/BrowseLocationsDialog.py:65
+msgid "Browse Locations"
+msgstr "Просмотр директорий"
+
+#: ../ProjectController.py:1769
+msgid "Build"
+msgstr "Сборка"
+
+#: ../ProjectController.py:1235
+msgid "Build directory already clean\n"
+msgstr "Директория сборки уже пуста\n"
+
+#: ../ProjectController.py:1770
+msgid "Build project into build folder"
+msgstr "Сборка проекта в директории сборки"
+
+#: ../ProjectController.py:1018
+msgid "C Build crashed !\n"
+msgstr "Крэш во время сборки C-кода!\n"
+
+#: ../ProjectController.py:1015
+msgid "C Build failed.\n"
+msgstr "Ошибка сборки C-кода.\n"
+
+#: ../c_ext/CFileEditor.py:63
+msgid "C code"
+msgstr "C код "
+
+#: ../ProjectController.py:1093
+msgid "C code generated successfully.\n"
+msgstr "C-код успешно сгенерирован.\n"
+
+#: ../targets/toolchain_makefile.py:122
+msgid "C compilation failed.\n"
+msgstr "Ошибка компиляции.\n"
+
+#: ../targets/toolchain_gcc.py:156
+#, python-format
+msgid "C compilation of %s failed.\n"
+msgstr "Ошибка компиляции %s.\n"
+
+#: ../features.py:32
+msgid "C extension"
+msgstr "С-расширение"
+
+#: ../dialogs/AboutDialog.py:63
+msgid "C&redits"
+msgstr "&Благодарности"
+
+#: ../canfestival/NetworkEditor.py:52
+msgid "CANOpen network"
+msgstr "Сеть CANOpen"
+
+#: ../canfestival/SlaveEditor.py:44
+msgid "CANOpen slave"
+msgstr "CANOpen ведущий"
+
+msgid "CAN_Baudrate"
+msgstr "Скорость CAN"
+
+msgid "CAN_Device"
+msgstr "CAN устройство"
+
+msgid "CAN_Driver"
+msgstr "CAN драйвер"
+
+#: ../features.py:31
+msgid "CANopen support"
+msgstr "Поддержка CANOpen"
+
+msgid "CFLAGS"
+msgstr "CFLAGS"
+
+#: ../plcopen/plcopen.py:1584 ../plcopen/plcopen.py:1598
+#: ../plcopen/plcopen.py:1622 ../plcopen/plcopen.py:1638
+msgid "Can only generate execution order on FBD networks!"
+msgstr "Можно сгенерировать порядок исполнения только для FBD!"
+
+#: ../controls/VariablePanel.py:267
+msgid "Can only give a location to local or global variables"
+msgstr "Можно задать размещение только локальным или глобальным переменны"
+
+#: ../PLCOpenEditor.py:334
+#, python-format
+msgid "Can't generate program to file %s!"
+msgstr "Нельзя сгенерировать программу в файл %s!"
+
+#: ../controls/VariablePanel.py:265
+msgid "Can't give a location to a function block instance"
+msgstr "Нельзя задать размещение для экземпляра функционального блока"
+
+#: ../PLCOpenEditor.py:379
+#, python-format
+msgid "Can't save project to file %s!"
+msgstr "Нельзя сохранить проект в файл %s!"
+
+#: ../controls/VariablePanel.py:313
+msgid "Can't set an initial value to a function block instance"
+msgstr "Нельзя задать исходное значение экземпляру функционального блока"
+
+msgid "CanFestivalInstance"
+msgstr ""
+
+msgid "CanFestivalNode"
+msgstr ""
+
+#: Extra XSD strings
+msgid "CanFestivalSlaveNode"
+msgstr ""
+
+#: ../ConfigTreeNode.py:529
+#, python-brace-format
+msgid "Cannot create child {a1} of type {a2} "
+msgstr "Нельзя создать дочерний элемент {a1} типа {a2}"
+
+#: ../ConfigTreeNode.py:454
+#, python-format
+msgid "Cannot find lower free IEC channel than %d\n"
+msgstr "Не удалось найти свободный МЭК-канал с номером меньше чем %d\n"
+
+#: ../connectors/PYRO/__init__.py:131
+msgid "Cannot get PLC status - connection failed.\n"
+msgstr "Невозможно получить состояние ПЛК - ошибка подключения.\n"
+
+#: ../ProjectController.py:881
+msgid "Cannot open/parse VARIABLES.csv!\n"
+msgstr "Не удалось открыть/прочитать VARIABLES.csv\n"
+
+#: ../canfestival/config_utils.py:374
+#, python-brace-format
+msgid "Cannot set bit offset for non bool '{a1}' variable (ID:{a2},Idx:{a3},sIdx:{a4}))"
+msgstr "Невозможно установить битовое смещение для небулевой переменной '{a1}' (ID:{a2},Idx:{a3},sIdx:{a4}))"
+
+#: ../dialogs/SearchInProjectDialog.py:59 ../dialogs/FindInPouDialog.py:88
+msgid "Case sensitive"
+msgstr "Регистрозависимый"
+
+#: ../editors/Viewer.py:486
+msgid "Center"
+msgstr "Центр"
+
+#: ../Beremiz_service.py:266
+msgid "Change IP of interface to bind"
+msgstr "Сменить IP-адрес интерфейса для привязки сокета"
+
+#: ../Beremiz_service.py:265
+msgid "Change Name"
+msgstr "Сменить имя"
+
+#: ../IDEFrame.py:1943
+msgid "Change POU Type To"
+msgstr "Сменить тип POU на"
+
+#: ../Beremiz_service.py:267
+msgid "Change Port Number"
+msgstr "Сменить номер порта"
+
+#: ../Beremiz_service.py:268
+msgid "Change working directory"
+msgstr "Сменить рабочую директорию"
+
+#: ../plcopen/iec_std.csv:81
+msgid "Character string"
+msgstr "Строковые операции"
+
+#: ../svgui/svgui.py:125
+msgid "Choose a SVG file"
+msgstr "Выберите SVG-файл"
+
+#: ../ProjectController.py:451
+msgid "Choose a directory to save project"
+msgstr "Выберите директорию, чтобы сохранить проект"
+
+#: ../canfestival/canfestival.py:160 ../PLCOpenEditor.py:292
+#: ../PLCOpenEditor.py:324 ../PLCOpenEditor.py:373
+msgid "Choose a file"
+msgstr "Выберите файл"
+
+#: ../Beremiz.py:931 ../Beremiz.py:966
+msgid "Choose a project"
+msgstr "Выберите проект"
+
+#: ../dialogs/BrowseValuesLibraryDialog.py:42
+#, python-format
+msgid "Choose a value for %s:"
+msgstr "Выберите значение для %s:"
+
+#: ../Beremiz_service.py:323
+msgid "Choose a working directory "
+msgstr "Выберите рабочую директорию"
+
+#: ../ProjectController.py:358
+msgid "Chosen folder doesn't contain a program. It's not a valid project!"
+msgstr "Выбранная директория не содержит программы. Это некорректный проект!"
+
+#: ../ProjectController.py:325
+msgid "Chosen folder isn't empty. You can't use it for a new project!"
+msgstr "Выбранная директория не пуста и не может использоваться для нового проекта!"
+
+#: ../controls/VariablePanel.py:53 ../controls/VariablePanel.py:54
+msgid "Class"
+msgstr "Класс"
+
+#: ../controls/VariablePanel.py:441
+msgid "Class Filter:"
+msgstr "Фильтр класса:"
+
+#: ../dialogs/FBDVariableDialog.py:69
+msgid "Class:"
+msgstr "Класс:"
+
+#: ../ProjectController.py:1773
+msgid "Clean"
+msgstr "Очистить"
+
+#: ../controls/LogViewer.py:318
+msgid "Clean log messages"
+msgstr "Очистить лог"
+
+#: ../ProjectController.py:1775
+msgid "Clean project build folder"
+msgstr "Очистить директорию сборки проекта"
+
+#: ../ProjectController.py:1232
+msgid "Cleaning the build directory\n"
+msgstr "Очистка директории сборки\n"
+
+#: ../IDEFrame.py:435
+msgid "Clear Errors"
+msgstr "Очистить ошибки"
+
+#: ../editors/Viewer.py:582
+msgid "Clear Execution Order"
+msgstr "Очистить порядок исполнения"
+
+#: ../dialogs/SearchInProjectDialog.py:105 ../dialogs/FindInPouDialog.py:111
+msgid "Close"
+msgstr "Закрыть"
+
+#: ../PLCOpenEditor.py:199 ../Beremiz.py:693
+msgid "Close Application"
+msgstr "Закрыть приложение"
+
+#: ../PLCOpenEditor.py:108 ../Beremiz.py:333 ../Beremiz.py:637
+#: ../IDEFrame.py:1009
+msgid "Close Project"
+msgstr "Закрыть проект"
+
+#: ../PLCOpenEditor.py:106 ../Beremiz.py:331
+msgid "Close Tab"
+msgstr "Закрыть вкладку"
+
+#: ../editors/Viewer.py:541 ../editors/Viewer.py:2366
+msgid "Coil"
+msgstr "Катушка"
+
+msgid "Command"
+msgstr "Комманда"
+
+#: ../editors/Viewer.py:561 ../editors/LDViewer.py:506
+msgid "Comment"
+msgstr "Комментарий"
+
+#: ../dialogs/ProjectDialog.py:57
+msgid "Company Name"
+msgstr "Имя компании"
+
+#: ../controls/ProjectPropertiesPanel.py:94
+msgid "Company Name (required):"
+msgstr "Компания (обязательно):"
+
+#: ../controls/ProjectPropertiesPanel.py:95
+msgid "Company URL (optional):"
+msgstr "Сайт компании (опционально):"
+
+#: ../plcopen/iec_std.csv:75
+msgid "Comparison"
+msgstr "Сравнение"
+
+msgid "Compiler"
+msgstr "Компилятор"
+
+#: ../ProjectController.py:672
+msgid "Compiling IEC Program into C code...\n"
+msgstr "Компиляция МЭК-программы в C-код...\n"
+
+#: ../plcopen/iec_std.csv:85
+msgid "Concatenation"
+msgstr "Объединение"
+
+#: ../editors/ConfTreeNodeEditor.py:229
+msgid "Config"
+msgstr "Конфигурация"
+
+#: ../editors/ProjectNodeEditor.py:36
+msgid "Config variables"
+msgstr "Конфигурационные переменные"
+
+#: ../dialogs/SearchInProjectDialog.py:39
+msgid "Configuration"
+msgstr "Конфигурация"
+
+#: ../PLCControler.py:97
+msgid "Configurations"
+msgstr "Конфигурации"
+
+#: ../editors/Viewer.py:307 ../editors/Viewer.py:337 ../editors/Viewer.py:359
+#: ../editors/TextViewer.py:291 ../editors/TextViewer.py:342
+#: ../editors/TextViewer.py:365 ../controls/VariablePanel.py:328
+msgid "Confirm or change variable name"
+msgstr "Подтвердить или поменять имя переменной"
+
+#: ../ProjectController.py:1788
+msgid "Connect"
+msgstr "Подключиться"
+
+#: ../ProjectController.py:1789
+msgid "Connect to the target PLC"
+msgstr "Подключиться к целевому ПЛК"
+
+#: ../ProjectController.py:1292
+#, python-format
+msgid "Connected to URI: %s"
+msgstr "Подключен к URI: %s"
+
+#: ../dialogs/SFCTransitionDialog.py:76 ../editors/Viewer.py:527
+#: ../editors/Viewer.py:2359
+msgid "Connection"
+msgstr "Подключение"
+
+#: ../dialogs/ConnectionDialog.py:52
+msgid "Connection Properties"
+msgstr "Свойства подключение"
+
+#: ../ProjectController.py:1647
+msgid "Connection canceled!\n"
+msgstr "Подключение отменено!\n"
+
+#: ../ProjectController.py:1672
+#, python-format
+msgid "Connection failed to %s!\n"
+msgstr "Неудачное подключение к %s!\n"
+
+#: ../connectors/PYRO/__init__.py:115 ../connectors/WAMP/__init__.py:111
+msgid "Connection lost!\n"
+msgstr "Подключение прервано!\n"
+
+#: ../connectors/PYRO/__init__.py:102
+#, python-format
+msgid "Connection to '%s' failed.\n"
+msgstr "Неудачное подключение к %s!\n"
+
+#: ../dialogs/ConnectionDialog.py:64 ../editors/Viewer.py:1594
+msgid "Connector"
+msgstr "Коннектор"
+
+#: ../dialogs/SFCStepDialog.py:65
+msgid "Connectors:"
+msgstr "Коннекторы:"
+
+#: ../Beremiz.py:448
+msgid "Console"
+msgstr "Консоль"
+
+#: ../controls/VariablePanel.py:60
+msgid "Constant"
+msgstr "Константа"
+
+#: ../editors/Viewer.py:537 ../editors/Viewer.py:2362
+msgid "Contact"
+msgstr "Контакт"
+
+#: ../controls/ProjectPropertiesPanel.py:197
+msgid "Content Description (optional):"
+msgstr "Описание содержимого (опционально):"
+
+#: ../dialogs/ConnectionDialog.py:65 ../editors/Viewer.py:1595
+msgid "Continuation"
+msgstr "Продолжение"
+
+#: ../plcopen/iec_std.csv:18
+msgid "Conversion from BCD"
+msgstr "Преобразование из BCD"
+
+#: ../plcopen/iec_std.csv:19
+msgid "Conversion to BCD"
+msgstr "Преобразование в BCD"
+
+#: ../plcopen/iec_std.csv:21
+msgid "Conversion to date"
+msgstr "Преобразование в дату"
+
+#: ../plcopen/iec_std.csv:20
+msgid "Conversion to time-of-day"
+msgstr "Преобразование во время суток"
+
+#: ../editors/Viewer.py:597 ../controls/LogViewer.py:693 ../IDEFrame.py:370
+#: ../IDEFrame.py:425
+msgid "Copy"
+msgstr "Копировать"
+
+#: ../IDEFrame.py:1930
+msgid "Copy POU"
+msgstr "Копировать POU"
+
+#: ../editors/FileManagementPanel.py:65
+msgid "Copy file from left folder to right"
+msgstr "Скопировать файл с левой директории в правую"
+
+#: ../editors/FileManagementPanel.py:64
+msgid "Copy file from right folder to left"
+msgstr "Скопировать файл с правой директории в левую"
+
+msgid "Copy of IN"
+msgstr "Копия входа IN"
+
+#: ../plcopen/iec_std.csv:28
+msgid "Cosine"
+msgstr "Косинус"
+
+#: ../ConfigTreeNode.py:656
+#, python-brace-format
+msgid ""
+"Could not add child \"{a1}\", type {a2} :\n"
+"{a3}\n"
+msgstr ""
+"Невозможно добавить дочерний элемент \"{a1}\", тип {a2}:\n"
+"{a3}\n"
+
+#: ../py_ext/PythonFileCTNMixin.py:77
+#, python-format
+msgid "Couldn't import old %s file."
+msgstr "Невозможно импортировать старый файл %s."
+
+#: ../ConfigTreeNode.py:626
+#, python-brace-format
+msgid ""
+"Couldn't load confnode base parameters {a1} :\n"
+" {a2}"
+msgstr ""
+"Невозможно загрузить базовые параметры confnode {a1}:\n"
+" {a2}"
+
+#: ../ConfigTreeNode.py:643 ../CodeFileTreeNode.py:124
+#, python-brace-format
+msgid ""
+"Couldn't load confnode parameters {a1} :\n"
+" {a2}"
+msgstr ""
+"Невозможно загрузить параметры confnode {a1}:\n"
+" {a2}"
+
+#: ../PLCControler.py:946
+msgid "Couldn't paste non-POU object."
+msgstr "Невозможно вставить не-POU."
+
+#: ../ProjectController.py:1589
+msgid "Couldn't start PLC !\n"
+msgstr "Невозможно запустить ПЛК!\n"
+
+#: ../ProjectController.py:1597
+msgid "Couldn't stop PLC !\n"
+msgstr "Невозможно остановить ПЛК!\n"
+
+#: ../ProjectController.py:1561
+msgid "Couldn't stop debugger.\n"
+msgstr "Невозможно остановить отладчик.\n"
+
+#: ../svgui/svgui.py:47
+msgid "Create HMI"
+msgstr "Создать HMI"
+
+#: ../dialogs/PouDialog.py:45
+msgid "Create a new POU"
+msgstr "Создать новый POU"
+
+#: ../dialogs/PouActionDialog.py:38
+msgid "Create a new action"
+msgstr "Создать новое действие"
+
+#: ../IDEFrame.py:159
+msgid "Create a new action block"
+msgstr "Создать новый блок действие"
+
+#: ../IDEFrame.py:108 ../IDEFrame.py:138 ../IDEFrame.py:171
+msgid "Create a new block"
+msgstr "Создать новый блок"
+
+#: ../IDEFrame.py:132
+msgid "Create a new branch"
+msgstr "Создать новое ветвление"
+
+#: ../IDEFrame.py:126
+msgid "Create a new coil"
+msgstr "Создать новую катушку"
+
+#: ../IDEFrame.py:102 ../IDEFrame.py:117 ../IDEFrame.py:147
+msgid "Create a new comment"
+msgstr "Создать новый комментарий"
+
+#: ../IDEFrame.py:111 ../IDEFrame.py:141 ../IDEFrame.py:174
+msgid "Create a new connection"
+msgstr "Создать новое подключение"
+
+#: ../IDEFrame.py:129 ../IDEFrame.py:180
+msgid "Create a new contact"
+msgstr "Создать новый контакт"
+
+#: ../IDEFrame.py:162
+msgid "Create a new divergence"
+msgstr "Создать новое ветвление"
+
+#: ../dialogs/SFCDivergenceDialog.py:53
+msgid "Create a new divergence or convergence"
+msgstr "Создать новое ветвление или объединение"
+
+#: ../IDEFrame.py:150
+msgid "Create a new initial step"
+msgstr "Создать исходный шаг"
+
+#: ../IDEFrame.py:165
+msgid "Create a new jump"
+msgstr "Создать новый безусловный переход"
+
+#: ../IDEFrame.py:120 ../IDEFrame.py:177
+msgid "Create a new power rail"
+msgstr "Создать новую линию питания"
+
+#: ../IDEFrame.py:123
+msgid "Create a new rung"
+msgstr "Создать новую цепь"
+
+#: ../IDEFrame.py:153
+msgid "Create a new step"
+msgstr "Создать новый шаг"
+
+#: ../dialogs/PouTransitionDialog.py:47 ../IDEFrame.py:156
+msgid "Create a new transition"
+msgstr "Создать новый переход"
+
+#: ../IDEFrame.py:105 ../IDEFrame.py:135 ../IDEFrame.py:168
+msgid "Create a new variable"
+msgstr "Создать новую переменную"
+
+#: ../dialogs/AboutDialog.py:105
+msgid "Credits"
+msgstr "Благодарности"
+
+#: ../Beremiz_service.py:432
+msgid "Current working directory :"
+msgstr "Текущая рабочая директория :"
+
+#: ../editors/Viewer.py:596 ../IDEFrame.py:368 ../IDEFrame.py:424
+msgid "Cut"
+msgstr "Вырезать"
+
+#: ../editors/ResourceEditor.py:72
+msgid "Cyclic"
+msgstr "Циклический"
+
+#: ../plcopen/iec_std.csv:42 ../plcopen/iec_std.csv:44
+#: ../plcopen/iec_std.csv:46 ../plcopen/iec_std.csv:50
+#: ../plcopen/iec_std.csv:52 ../plcopen/iec_std.csv:54
+#: ../plcopen/iec_std.csv:56 ../plcopen/iec_std.csv:58
+#: ../plcopen/iec_std.csv:60
+msgid "DEPRECATED"
+msgstr "УСТАРЕЛО"
+
+#: ../canfestival/SlaveEditor.py:76 ../canfestival/NetworkEditor.py:97
+msgid "DS-301 Profile"
+msgstr "Профиль DS-301"
+
+#: ../canfestival/SlaveEditor.py:77 ../canfestival/NetworkEditor.py:98
+msgid "DS-302 Profile"
+msgstr "Профиль DS-302"
+
+#: ../dialogs/SearchInProjectDialog.py:35
+msgid "Data Type"
+msgstr "Тип данных"
+
+#: ../PLCControler.py:96
+msgid "Data Types"
+msgstr "Типы данных"
+
+#: ../plcopen/iec_std.csv:16
+msgid "Data type conversion"
+msgstr "Преобразование типов данных"
+
+#: ../plcopen/iec_std.csv:44 ../plcopen/iec_std.csv:45
+msgid "Date addition"
+msgstr "Сложение дат"
+
+#: ../plcopen/iec_std.csv:56 ../plcopen/iec_std.csv:57
+#: ../plcopen/iec_std.csv:58 ../plcopen/iec_std.csv:59
+msgid "Date and time subtraction"
+msgstr "Вычитание даты и времени"
+
+#: ../plcopen/iec_std.csv:50 ../plcopen/iec_std.csv:51
+msgid "Date subtraction"
+msgstr "Вычитание дат"
+
+msgid "Datetime, current or relative to PDT"
+msgstr "Текущие дата и время, абсолютные или относительные от PDT"
+
+#: ../dialogs/DurationEditorDialog.py:43
+msgid "Days:"
+msgstr "Дни:"
+
+#: ../ProjectController.py:1694
+msgid "Debug does not match PLC - stop/transfert/start to re-enable\n"
+msgstr "Отлаживаемая программа не соответствует программе в ПЛК - остановите/загрузите/запустите, чтобы разрешить отладку\n"
+
+#: ../controls/PouInstanceVariablesPanel.py:134
+msgid "Debug instance"
+msgstr "Отладка экземпляра"
+
+#: ../editors/Viewer.py:1117 ../editors/Viewer.py:3653
+#, python-format
+msgid "Debug: %s"
+msgstr "Отладка: %s"
+
+#: ../ProjectController.py:1350
+#, python-format
+msgid "Debug: Unknown variable '%s'\n"
+msgstr "Отладка: неизвестная переменная '%s'\n"
+
+#: ../ProjectController.py:1348
+#, python-format
+msgid "Debug: Unsupported type to debug '%s'\n"
+msgstr "Отладка: неподдерживамый отладкой тип '%s'\n"
+
+#: ../IDEFrame.py:639
+msgid "Debugger"
+msgstr "Отладчик"
+
+#: ../ProjectController.py:1530
+msgid "Debugger disabled\n"
+msgstr "Отладчик запрещен\n"
+
+#: ../ProjectController.py:1691
+msgid "Debugger ready\n"
+msgstr "Отладчик готов\n"
+
+#: ../ProjectController.py:1563
+msgid "Debugger stopped.\n"
+msgstr "Отладчик остановлен.\n"
+
+#: ../editors/Viewer.py:572 ../Beremiz.py:1064 ../IDEFrame.py:1959
+msgid "Delete"
+msgstr "Удалить"
+
+#: ../editors/Viewer.py:514
+msgid "Delete Divergence Branch"
+msgstr "Удалить ветвь"
+
+#: ../editors/FileManagementPanel.py:153
+msgid "Delete File"
+msgstr "Удалить файл"
+
+#: ../editors/Viewer.py:501
+msgid "Delete Wire Segment"
+msgstr "Удалить сегмент цепи"
+
+#: ../controls/CustomEditableListBox.py:41
+msgid "Delete item"
+msgstr "Удалить"
+
+#: ../plcopen/iec_std.csv:88
+msgid "Deletion (within)"
+msgstr "Удаление подстроки"
+
+#: ../editors/DataTypeEditor.py:153
+msgid "Derivation Type:"
+msgstr "Механизм создания типа:"
+
+msgid "Derivative time constant"
+msgstr "Постоянная времени дифференцирования"
+
+#: ../controls/VariablePanel.py:432
+msgid "Description:"
+msgstr "Описание:"
+
+msgid "Differentiated output"
+msgstr "Дифференцированный выход"
+
+#: ../dialogs/ArrayTypeDialog.py:61 ../editors/DataTypeEditor.py:321
+msgid "Dimensions:"
+msgstr "Размеры:"
+
+#: ../dialogs/FindInPouDialog.py:68
+msgid "Direction"
+msgstr "Направление"
+
+#: ../dialogs/BrowseLocationsDialog.py:90
+msgid "Direction:"
+msgstr "Направление:"
+
+#: ../editors/DataTypeEditor.py:54
+msgid "Directly"
+msgstr "Синоним"
+
+msgid "Disable_Extensions"
+msgstr "Запретить расширения"
+
+#: ../ProjectController.py:1797
+msgid "Disconnect"
+msgstr "Отключиться"
+
+#: ../ProjectController.py:1799
+msgid "Disconnect from PLC"
+msgstr "Отключиться от ПЛК"
+
+#: ../ProjectController.py:1302
+msgid "Disconnected"
+msgstr "Отключено"
+
+#: ../editors/Viewer.py:556 ../editors/Viewer.py:2354
+msgid "Divergence"
+msgstr "Ветвление"
+
+#: ../plcopen/iec_std.csv:36
+msgid "Division"
+msgstr "Деление"
+
+#: ../editors/FileManagementPanel.py:152
+#, python-format
+msgid "Do you really want to delete the file '%s'?"
+msgstr "Вы действительно хотите удалить этот файл '%s'?"
+
+#: ../controls/VariablePanel.py:53 ../controls/VariablePanel.py:54
+msgid "Documentation"
+msgstr "Описание"
+
+#: ../PLCOpenEditor.py:328
+msgid "Done"
+msgstr "Завершено"
+
+#: ../dialogs/ActionBlockDialog.py:38
+msgid "Duration"
+msgstr "Длительность"
+
+#: ../canfestival/canfestival.py:163
+msgid "EDS files (*.eds)|*.eds|All files|*.*"
+msgstr "Файлы EDS (*.eds)|*.eds|All files|*.*"
+
+#: ../editors/Viewer.py:570
+msgid "Edit Block"
+msgstr "Редактировать блок"
+
+#: ../dialogs/LDElementDialog.py:56
+msgid "Edit Coil Values"
+msgstr "Редактировать значение катушки"
+
+#: ../dialogs/LDElementDialog.py:54
+msgid "Edit Contact Values"
+msgstr "Редактировать значение контакта"
+
+#: ../dialogs/DurationEditorDialog.py:59
+msgid "Edit Duration"
+msgstr "Редактировать длительность"
+
+#: ../dialogs/SFCStepDialog.py:50
+msgid "Edit Step"
+msgstr "Редактировать шаг"
+
+#: ../wxglade_hmi/wxglade_hmi.py:36
+msgid "Edit a WxWidgets GUI with WXGlade"
+msgstr "Редактировать WxWidgets GUI с помощью WXGlade"
+
+#: ../dialogs/ActionBlockDialog.py:121
+msgid "Edit action block properties"
+msgstr "Редактировать свойства блока действия"
+
+#: ../dialogs/ArrayTypeDialog.py:45
+msgid "Edit array type properties"
+msgstr "Редактировать свойства массива"
+
+#: ../editors/Viewer.py:2575 ../editors/Viewer.py:3004
+msgid "Edit comment"
+msgstr "Редактировать комментарий"
+
+#: ../editors/FileManagementPanel.py:66
+msgid "Edit file"
+msgstr "Редактировать файл"
+
+#: ../controls/CustomEditableListBox.py:39
+msgid "Edit item"
+msgstr "Редактировать элемент"
+
+#: ../editors/Viewer.py:2963
+msgid "Edit jump target"
+msgstr "Редактирование безусловного перехода"
+
+#: ../ProjectController.py:1811
+msgid "Edit raw IEC code added to code generated by PLCGenerator"
+msgstr "Редактировать МЭК-код добавленный к коду сгенерированному PLCGenerator"
+
+#: ../editors/SFCViewer.py:799
+msgid "Edit step name"
+msgstr "Редактировать имя шага"
+
+#: ../dialogs/SFCTransitionDialog.py:51
+msgid "Edit transition"
+msgstr "Редактировать переход"
+
+#: ../IDEFrame.py:611
+msgid "Editor ToolBar"
+msgstr "Редактор панели инструментов"
+
+#: ../ProjectController.py:1195
+msgid "Editor selection"
+msgstr "Редактор выделения"
+
+msgid "Elapsed time of ramp"
+msgstr "Прошедшее время нарастания"
+
+#: ../editors/DataTypeEditor.py:348
+msgid "Elements :"
+msgstr "Элементы:"
+
+#: ../ProjectController.py:1300
+msgid "Empty"
+msgstr "Нет программы"
+
+#: ../IDEFrame.py:365
+msgid "Enable Undo/Redo"
+msgstr "Разрешить отмену и повтор операций"
+
+msgid "Enabled"
+msgstr "Разрешено"
+
+#: ../Beremiz_service.py:331
+msgid "Enter a name "
+msgstr "Введите имя"
+
+#: ../Beremiz_service.py:316
+msgid "Enter a port number "
+msgstr "Введите номер порта"
+
+#: ../Beremiz_service.py:307
+msgid "Enter the IP of the interface to bind"
+msgstr "Введите IP-адрес используемого интерфейса"
+
+#: ../editors/DataTypeEditor.py:54
+msgid "Enumerated"
+msgstr "Перечисление"
+
+#: ../plcopen/iec_std.csv:77
+msgid "Equal to"
+msgstr "Равно"
+
+#: ../dialogs/ForceVariableDialog.py:179
+#: ../dialogs/SearchInProjectDialog.py:168 ../dialogs/SFCStepNameDialog.py:60
+#: ../dialogs/DurationEditorDialog.py:121
+#: ../dialogs/DurationEditorDialog.py:163 ../dialogs/PouTransitionDialog.py:112
+#: ../dialogs/BlockPreviewDialog.py:236 ../dialogs/ProjectDialog.py:71
+#: ../dialogs/ArrayTypeDialog.py:97 ../dialogs/ArrayTypeDialog.py:103
+#: ../dialogs/PouNameDialog.py:54 ../dialogs/BrowseLocationsDialog.py:216
+#: ../dialogs/BrowseValuesLibraryDialog.py:83 ../dialogs/PouActionDialog.py:104
+#: ../dialogs/PouDialog.py:134 ../PLCOpenEditor.py:335 ../PLCOpenEditor.py:340
+#: ../PLCOpenEditor.py:420 ../PLCOpenEditor.py:430 ../editors/Viewer.py:423
+#: ../editors/LDViewer.py:666 ../editors/LDViewer.py:882
+#: ../editors/LDViewer.py:886 ../editors/DataTypeEditor.py:550
+#: ../editors/DataTypeEditor.py:555 ../editors/DataTypeEditor.py:579
+#: ../editors/DataTypeEditor.py:584 ../editors/DataTypeEditor.py:594
+#: ../editors/DataTypeEditor.py:745 ../editors/DataTypeEditor.py:752
+#: ../editors/TextViewer.py:389 ../editors/CodeFileEditor.py:783
+#: ../ProjectController.py:293 ../ProjectController.py:421
+#: ../ProjectController.py:428 ../controls/FolderTree.py:217
+#: ../controls/DebugVariablePanel/DebugVariablePanel.py:166
+#: ../controls/DebugVariablePanel/DebugVariableTextViewer.py:137
+#: ../controls/DebugVariablePanel/DebugVariableGraphicViewer.py:231
+#: ../controls/VariablePanel.py:402 ../controls/VariablePanel.py:772
+#: ../Beremiz.py:1203 ../IDEFrame.py:1003 ../IDEFrame.py:1614
+#: ../IDEFrame.py:1655 ../IDEFrame.py:1660 ../IDEFrame.py:1674
+#: ../IDEFrame.py:1679 ../Beremiz_service.py:211
+msgid "Error"
+msgstr "Ошибка"
+
+#: ../ProjectController.py:727
+msgid "Error : At least one configuration and one resource must be declared in PLC !\n"
+msgstr "Ошибка: Как минимум одна конфигурация и один ресурс должны быть задекларированы в ПЛК!\n"
+
+#: ../ProjectController.py:719
+#, python-format
+msgid "Error : IEC to C compiler returned %d\n"
+msgstr "Ошибка: компилятор МЭК в C вернул код ошибки %d\n"
+
+#: ../ProjectController.py:621
+#, python-format
+msgid ""
+"Error in ST/IL/SFC code generator :\n"
+"%s\n"
+msgstr "Ошибка в ST/IL/SFC кодогенераторе: %s\n"
+
+#: ../ConfigTreeNode.py:216
+#, python-format
+msgid "Error while saving \"%s\"\n"
+msgstr "Ошибка во время сохранения \"%s\"\n"
+
+#: ../canfestival/canfestival.py:168
+msgid "Error: Export slave failed\n"
+msgstr "Ошибка: неудачный экспорт ведомого\n"
+
+#: ../canfestival/canfestival.py:369
+msgid "Error: No Master generated\n"
+msgstr "Ошибка: мастер не сгенерирован\n"
+
+#: ../canfestival/canfestival.py:364
+msgid "Error: No PLC built\n"
+msgstr "Ошибка: ПЛК не собран\n"
+
+#: ../ProjectController.py:1666
+#, python-format
+msgid "Exception while connecting %s!\n"
+msgstr "Исключение во время подключения %s!\n"
+
+#: ../dialogs/FBDBlockDialog.py:117
+msgid "Execution Control:"
+msgstr "Управление исполнением:"
+
+#: ../dialogs/FBDVariableDialog.py:79 ../dialogs/FBDBlockDialog.py:105
+msgid "Execution Order:"
+msgstr "Порядок исполнения:"
+
+#: ../features.py:35
+msgid "Experimental web based HMI"
+msgstr "Экспериментальный WEB-HMI"
+
+#: ../plcopen/iec_std.csv:38
+msgid "Exponent"
+msgstr "Экспонента"
+
+#: ../plcopen/iec_std.csv:26
+msgid "Exponentiation"
+msgstr "Взятие экспоненты"
+
+#: ../canfestival/canfestival.py:174
+msgid "Export CanOpen slave to EDS file"
+msgstr "Экспортировать CanOpen ведомое устройство в EDS файл"
+
+#: ../controls/DebugVariablePanel/DebugVariablePanel.py:243
+msgid "Export graph values to clipboard"
+msgstr "Экспортировать график значений в буфер обмена"
+
+#: ../canfestival/canfestival.py:173
+msgid "Export slave"
+msgstr "Экспортировать ведомое устройство"
+
+#: ../dialogs/FBDVariableDialog.py:89
+msgid "Expression:"
+msgstr "Выражение:"
+
+#: ../controls/VariablePanel.py:72
+msgid "External"
+msgstr "Внешний"
+
+#: ../ProjectController.py:740
+msgid "Extracting Located Variables...\n"
+msgstr "Экспорт локальных переменных...\n"
+
+msgid "FB for derivative term"
+msgstr "ФБ дифференцирования"
+
+msgid "FB for integral term"
+msgstr "ФД интегрирования"
+
+#: ../dialogs/PouTransitionDialog.py:40 ../dialogs/PouActionDialog.py:31
+#: ../dialogs/PouDialog.py:36 ../controls/ProjectPropertiesPanel.py:143
+msgid "FBD"
+msgstr "FBD"
+
+#: ../ProjectController.py:1729
+msgid "Failed : Must build before transfer.\n"
+msgstr "Ошибка: необходима сборка перед передачей.\n"
+
+#: ../dialogs/LDElementDialog.py:77 ../editors/Viewer.py:462
+msgid "Falling Edge"
+msgstr "Спадающий фронт"
+
+#: ../ProjectController.py:1008
+msgid "Fatal : cannot get builder.\n"
+msgstr "Ошибка: невозможно получить сборщик.\n"
+
+#: ../Beremiz.py:118
+#, python-format
+msgid "Fetching %s"
+msgstr "Проверка %s"
+
+#: ../dialogs/DurationEditorDialog.py:160
+#, python-format
+msgid "Field %s hasn't a valid value!"
+msgstr "Поле %s имеет неверное значение!"
+
+#: ../dialogs/DurationEditorDialog.py:162
+#, python-format
+msgid "Fields %s haven't a valid value!"
+msgstr "Поля %s имеют неверные значения!"
+
+#: ../controls/FolderTree.py:216
+#, python-format
+msgid "File '%s' already exists!"
+msgstr "Файл '%s' уже существует!"
+
+#: ../dialogs/SearchInProjectDialog.py:100 ../dialogs/FindInPouDialog.py:36
+#: ../dialogs/FindInPouDialog.py:106 ../IDEFrame.py:375
+msgid "Find"
+msgstr "Поиск"
+
+#: ../IDEFrame.py:377
+msgid "Find Next"
+msgstr "Поиск следующего"
+
+#: ../IDEFrame.py:379
+msgid "Find Previous"
+msgstr "Поиск предыдущего"
+
+#: ../plcopen/iec_std.csv:90
+msgid "Find position"
+msgstr "Поиск позиции"
+
+#: ../dialogs/FindInPouDialog.py:57
+msgid "Find:"
+msgstr "Поиск:"
+
+#: ../connectors/PYRO/__init__.py:163
+msgid "Force runtime reload\n"
+msgstr "Принудительный перезапуск системы исполнения\n"
+
+#: ../editors/Viewer.py:1553
+msgid "Force value"
+msgstr "Фиксировать значение"
+
+#: ../dialogs/ForceVariableDialog.py:162
+msgid "Forcing Variable Value"
+msgstr "Форсировать значение переменной"
+
+#: ../dialogs/SFCTransitionDialog.py:179 ../dialogs/PouTransitionDialog.py:102
+#: ../dialogs/ProjectDialog.py:70 ../dialogs/PouActionDialog.py:94
+#: ../dialogs/PouDialog.py:116
+#, python-format
+msgid "Form isn't complete. %s must be filled!"
+msgstr "Форма заполнена неполностью. %s должен быть заполнен!"
+
+#: ../dialogs/SFCStepDialog.py:144 ../dialogs/FBDBlockDialog.py:232
+#: ../dialogs/ConnectionDialog.py:160
+msgid "Form isn't complete. Name must be filled!"
+msgstr "Форма заполнена неполностью. Имя должно быть заполнено!"
+
+#: ../dialogs/FBDBlockDialog.py:228
+msgid "Form isn't complete. Valid block type must be selected!"
+msgstr "Форма заполнена неполностью. Должен быть выбран корректный тип блока!"
+
+#: ../dialogs/FindInPouDialog.py:74
+msgid "Forward"
+msgstr "Вперед"
+
+#: ../dialogs/SearchInProjectDialog.py:36 ../IDEFrame.py:1746
+msgid "Function"
+msgstr "Функция"
+
+#: ../IDEFrame.py:349
+msgid "Function &Block"
+msgstr "Функциональный &блок"
+
+#: ../dialogs/SearchInProjectDialog.py:37 ../IDEFrame.py:1745
+#: ../IDEFrame.py:1938
+msgid "Function Block"
+msgstr "Функциональный блок"
+
+#: ../controls/VariablePanel.py:825
+msgid "Function Block Types"
+msgstr "Типы функциональных блоков"
+
+#: ../PLCControler.py:95
+msgid "Function Blocks"
+msgstr "Функциональные блоки"
+
+#: ../editors/Viewer.py:248
+msgid "Function Blocks can't be used in Functions!"
+msgstr "Функциональные блоки не могут использоваться в функциях!"
+
+#: ../PLCControler.py:2337
+#, python-format
+msgid "FunctionBlock \"%s\" can't be pasted in a Function!!!"
+msgstr "Функциональный блок \"%s\" не может быть вставлен в функцию!!!"
+
+#: ../PLCControler.py:95
+msgid "Functions"
+msgstr "Функции"
+
+#: ../PLCOpenEditor.py:115
+msgid "Generate Program"
+msgstr "Сгенерировать программу"
+
+#: ../ProjectController.py:612
+msgid "Generating SoftPLC IEC-61131 ST/IL/SFC code...\n"
+msgstr "Генерация МЭК-61131 ST/IL/SFC кода ПЛК...\n"
+
+msgid "Generic"
+msgstr "Generic"
+
+#: ../controls/VariablePanel.py:73
+msgid "Global"
+msgstr "Глобальный"
+
+#: ../controls/DebugVariablePanel/DebugVariablePanel.py:242
+msgid "Go to current value"
+msgstr "Перейти к текущему значению"
+
+#: ../controls/ProjectPropertiesPanel.py:173
+msgid "Graphics"
+msgstr "Графика"
+
+#: ../plcopen/iec_std.csv:75
+msgid "Greater than"
+msgstr "Больше"
+
+#: ../plcopen/iec_std.csv:76
+msgid "Greater than or equal to"
+msgstr "Больше или равно"
+
+#: ../controls/ProjectPropertiesPanel.py:134
+msgid "Grid Resolution:"
+msgstr "Шаг сетки:"
+
+#: ../runtime/NevowServer.py:181
+msgid "HTTP interface port :"
+msgstr "Порт HTTP-интерфейса :"
+
+#: ../controls/ProjectPropertiesPanel.py:120
+msgid "Height:"
+msgstr "Высота:"
+
+#: ../editors/FileManagementPanel.py:85
+msgid "Home Directory:"
+msgstr "Домашняя директория:"
+
+#: ../controls/ProjectPropertiesPanel.py:150
+msgid "Horizontal:"
+msgstr "Горизонтальный:"
+
+#: ../dialogs/DurationEditorDialog.py:44
+msgid "Hours:"
+msgstr "Часы:"
+
+msgid "IEC_Channel"
+msgstr "МЭК-канал"
+
+#: ../dialogs/PouActionDialog.py:31 ../dialogs/PouDialog.py:36
+msgid "IL"
+msgstr "IL"
+
+#: ../dialogs/DiscoveryDialog.py:94
+msgid "IP"
+msgstr "IP"
+
+#: ../Beremiz_service.py:308 ../Beremiz_service.py:309
+msgid "IP is not valid!"
+msgstr "Неверный IP-адрес"
+
+#: ../svgui/svgui.py:42 ../svgui/svgui.py:43
+msgid "Import SVG"
+msgstr "Импорт SVG"
+
+#: ../dialogs/FBDVariableDialog.py:38 ../editors/Viewer.py:1580
+#: ../controls/VariablePanel.py:71
+msgid "InOut"
+msgstr "Вход/Выход"
+
+#: ../editors/Viewer.py:1100
+msgid "Inactive"
+msgstr "Неактивный"
+
+#: ../controls/VariablePanel.py:276
+#, python-brace-format
+msgid "Incompatible data types between \"{a1}\" and \"{a2}\""
+msgstr "\"{a1}\" и \"{a2}\" имеют несовместимые типы данных"
+
+#: ../controls/VariablePanel.py:282
+#, python-format
+msgid "Incompatible size of data between \"%s\" and \"BOOL\""
+msgstr "Несовместимый размер данных \"%s\" с типом \"BOOL\""
+
+#: ../controls/VariablePanel.py:286
+#, python-brace-format
+msgid "Incompatible size of data between \"{a1}\" and \"{a2}\""
+msgstr "\"{a1}\" и \"{a2}\" имеют несовместимый размер данных"
+
+#: ../dialogs/ActionBlockDialog.py:38
+msgid "Indicator"
+msgstr "Индикатор"
+
+#: ../editors/Viewer.py:552
+msgid "Initial Step"
+msgstr "Исходный шаг"
+
+#: ../editors/DataTypeEditor.py:50 ../controls/VariablePanel.py:53
+#: ../controls/VariablePanel.py:54
+msgid "Initial Value"
+msgstr "Исходное значение"
+
+#: ../editors/DataTypeEditor.py:185 ../editors/DataTypeEditor.py:216
+#: ../editors/DataTypeEditor.py:272 ../editors/DataTypeEditor.py:310
+msgid "Initial Value:"
+msgstr "Исходное значение:"
+
+msgid "Initial value"
+msgstr "Исходное значение"
+
+#: ../svgui/svgui.py:46
+msgid "Inkscape"
+msgstr "Inkscape"
+
+#: ../dialogs/SFCTransitionDialog.py:75 ../dialogs/ActionBlockDialog.py:42
+msgid "Inline"
+msgstr "Непосредственно"
+
+#: ../dialogs/SFCStepDialog.py:70 ../dialogs/FBDVariableDialog.py:37
+#: ../dialogs/BrowseLocationsDialog.py:40 ../editors/Viewer.py:289
+#: ../editors/Viewer.py:1578 ../editors/TextViewer.py:307
+#: ../controls/LocationCellEditor.py:98 ../controls/VariablePanel.py:71
+#: ../controls/VariablePanel.py:291 ../controls/VariablePanel.py:351
+msgid "Input"
+msgstr "Вход"
+
+msgid "Input to be differentiated"
+msgstr "Вход для дифференцирования"
+
+msgid "Input variable"
+msgstr "Входная переменная"
+
+#: ../dialogs/FBDBlockDialog.py:93
+msgid "Inputs:"
+msgstr "Входы:"
+
+#: ../plcopen/iec_std.csv:87
+msgid "Insertion (into)"
+msgstr "Вставка подстроки"
+
+#: ../plcopen/plcopen.py:1691
+#, python-format
+msgid "Instance with id %d doesn't exist!"
+msgstr "Экземпляр с id %d не существует!"
+
+#: ../editors/ResourceEditor.py:264
+msgid "Instances:"
+msgstr "Экземпляры:"
+
+msgid "Integrated output"
+msgstr "Интегрированный выход"
+
+#: ../controls/VariablePanel.py:70
+msgid "Interface"
+msgstr "Интерфейс"
+
+#: ../editors/ResourceEditor.py:72
+msgid "Interrupt"
+msgstr "Прерывание"
+
+#: ../editors/ResourceEditor.py:68
+msgid "Interval"
+msgstr "Интервал"
+
+#: ../PLCControler.py:2325
+msgid "Invalid plcopen element(s)!!!"
+msgstr "Некорректный PlcOpen элемент(ы)!!!"
+
+#: ../canfestival/config_utils.py:381
+#, python-brace-format
+msgid "Invalid type \"{a1}\"-> {a2} != {a3} for location\"{a4}\""
+msgstr "Неправильный тип \"{a1}\"-> {a2} != {a3} для \"{a4}\""
+
+#: ../canfestival/config_utils.py:645
+#, python-brace-format
+msgid "Invalid type \"{a1}\"-> {a2} != {a3} for location \"{a4}\""
+msgstr "Неправильный тип \"{a1}\"-> {a2} != {a3} для \"{a4}\""
+
+#: ../controls/DebugVariablePanel/DebugVariablePanel.py:132
+#: ../controls/DebugVariablePanel/DebugVariableTextViewer.py:92
+#: ../controls/DebugVariablePanel/DebugVariableGraphicViewer.py:166
+#, python-format
+msgid "Invalid value \"%s\" for debug variable"
+msgstr "Неверное значение \"%s\" для отлаживаемой переменной"
+
+#: ../controls/VariablePanel.py:255 ../controls/VariablePanel.py:258
+#, python-format
+msgid "Invalid value \"%s\" for variable grid element"
+msgstr "Неверное значение \"%s\" для значения размещения переменной"
+
+#: ../editors/Viewer.py:233 ../editors/Viewer.py:236
+#, python-format
+msgid "Invalid value \"%s\" for viewer block"
+msgstr "Неверное значение \"%s\" для вставки в редактор"
+
+#: ../dialogs/ForceVariableDialog.py:177
+#, python-brace-format
+msgid "Invalid value \"{a1}\" for \"{a2}\" variable!"
+msgstr "Неверное значение \"{a1}\" для переменной \"{a2}\"!"
+
+#: ../dialogs/DurationEditorDialog.py:121
+msgid ""
+"Invalid value!\n"
+"You must fill a numeric value."
+msgstr ""
+"Неверное значение!\n"
+"Необходимо ввести числовое значение."
+
+#: ../editors/Viewer.py:557 ../editors/Viewer.py:2343
+msgid "Jump"
+msgstr "Безусловный переход"
+
+#: ../dialogs/PouTransitionDialog.py:40 ../dialogs/PouActionDialog.py:31
+#: ../dialogs/PouDialog.py:36 ../controls/ProjectPropertiesPanel.py:143
+msgid "LD"
+msgstr "LD"
+
+msgid "LDFLAGS"
+msgstr "LDFLAGS"
+
+#: ../editors/LDViewer.py:215 ../editors/LDViewer.py:231
+#, python-format
+msgid "Ladder element with id %d is on more than one rung."
+msgstr "Элемент лестничной диаграммы с id %d более чем на одной ступени."
+
+#: ../dialogs/PouTransitionDialog.py:91 ../dialogs/PouActionDialog.py:83
+#: ../dialogs/PouDialog.py:104
+msgid "Language"
+msgstr "Язык"
+
+#: ../controls/ProjectPropertiesPanel.py:186
+msgid "Language (optional):"
+msgstr "Язык (опционально):"
+
+#: ../dialogs/PouTransitionDialog.py:65 ../dialogs/PouActionDialog.py:56
+#: ../dialogs/PouDialog.py:73
+msgid "Language:"
+msgstr "Язык:"
+
+#: ../ProjectController.py:1735
+msgid "Latest build already matches current target. Transfering anyway...\n"
+msgstr "Загружаемая программа совпадает с текущий программой в целевом ПЛК. Загрузка продолжена...\n"
+
+#: ../Beremiz_service.py:271
+msgid "Launch WX GUI inspector"
+msgstr "Запустить WX GUI Inspector"
+
+#: ../Beremiz_service.py:270
+msgid "Launch a live Python shell"
+msgstr "Запустить консоль Python"
+
+#: ../editors/Viewer.py:485
+msgid "Left"
+msgstr "Слева"
+
+#: ../dialogs/LDPowerRailDialog.py:62
+msgid "Left PowerRail"
+msgstr "Левая шина питания"
+
+#: ../plcopen/iec_std.csv:81
+msgid "Length of string"
+msgstr "Длина строки"
+
+#: ../plcopen/iec_std.csv:78
+msgid "Less than"
+msgstr "Меньше"
+
+#: ../plcopen/iec_std.csv:79
+msgid "Less than or equal to"
+msgstr "Меньше либо равно"
+
+msgid "Libraries"
+msgstr "Библиотеки"
+
+#: ../IDEFrame.py:631
+msgid "Library"
+msgstr "Библиотеки"
+
+#: ../dialogs/AboutDialog.py:143
+msgid "License"
+msgstr "Лицензия"
+
+#: ../plcopen/iec_std.csv:73
+msgid "Limitation"
+msgstr "Ограничение"
+
+msgid "Linker"
+msgstr "Линковщик"
+
+#: ../targets/toolchain_gcc.py:166
+msgid "Linking :\n"
+msgstr "Линковка:\n"
+
+msgid "Linux"
+msgstr "GNU/Linux"
+
+#: ../dialogs/DiscoveryDialog.py:111 ../controls/VariablePanel.py:72
+msgid "Local"
+msgstr "Локальный"
+
+#: ../canfestival/canfestival.py:346
+msgid "Local entries"
+msgstr "Локальные записи"
+
+#: ../ProjectController.py:1641
+msgid "Local service discovery failed!\n"
+msgstr "Локальный сервис не найден!\n"
+
+#: ../controls/VariablePanel.py:53
+msgid "Location"
+msgstr "Размещение"
+
+#: ../dialogs/BrowseLocationsDialog.py:72
+msgid "Locations available:"
+msgstr "Доступные размещения:"
+
+#: ../plcopen/iec_std.csv:25
+msgid "Logarithm to base 10"
+msgstr "Десятичный логарифм"
+
+#: ../connectors/PYRO/__init__.py:94
+#, python-format
+msgid "MDNS resolution failure for '%s'\n"
+msgstr "MDNS разрешение неудачно для '%s'\n"
+
+msgid "Manual output adjustment - Typically from transfer station"
+msgstr "Ручной выход"
+
+#: ../canfestival/SlaveEditor.py:64 ../canfestival/NetworkEditor.py:85
+msgid "Map Variable"
+msgstr "Отображение переменной"
+
+#: ../features.py:31
+msgid "Map located variables over CANopen"
+msgstr "Отображение переменных по CANopen"
+
+#: ../canfestival/NetworkEditor.py:106
+msgid "Master"
+msgstr "Ведущий"
+
+#: ../ConfigTreeNode.py:539
+#, python-brace-format
+msgid "Max count ({a1}) reached for this confnode of type {a2} "
+msgstr "Достигнуто максимальное количество ({a1}) для типа узла конфигурации {a2} "
+
+#: ../plcopen/iec_std.csv:71
+msgid "Maximum"
+msgstr "Максимум"
+
+#: ../editors/DataTypeEditor.py:239
+msgid "Maximum:"
+msgstr "Максимум:"
+
+#: ../dialogs/BrowseLocationsDialog.py:42 ../editors/Viewer.py:289
+#: ../editors/TextViewer.py:307 ../controls/LocationCellEditor.py:98
+#: ../controls/VariablePanel.py:291 ../controls/VariablePanel.py:351
+msgid "Memory"
+msgstr "Память"
+
+#: ../IDEFrame.py:599
+msgid "Menu ToolBar"
+msgstr "Меню"
+
+#: ../dialogs/DurationEditorDialog.py:48
+msgid "Microseconds:"
+msgstr "Микросекунды:"
+
+#: ../editors/Viewer.py:490
+msgid "Middle"
+msgstr "Посередине"
+
+#: ../dialogs/DurationEditorDialog.py:47
+msgid "Milliseconds:"
+msgstr "Миллисекунды:"
+
+#: ../plcopen/iec_std.csv:72
+msgid "Minimum"
+msgstr "Минимум"
+
+#: ../editors/DataTypeEditor.py:226
+msgid "Minimum:"
+msgstr "Минимум:"
+
+#: ../dialogs/DurationEditorDialog.py:45
+msgid "Minutes:"
+msgstr "Минуты:"
+
+#: ../controls/ProjectPropertiesPanel.py:210
+msgid "Miscellaneous"
+msgstr "Прочее"
+
+#: ../dialogs/LDElementDialog.py:63
+msgid "Modifier:"
+msgstr "Модификатор:"
+
+#: ../PLCGenerator.py:786 ../PLCGenerator.py:1230
+#, python-brace-format
+msgid "More than one connector found corresponding to \"{a1}\" continuation in \"{a2}\" POU"
+msgstr "Более одного коннектора соответствуют продолжению цепи \"{a1}\" в POU \"{a2}\""
+
+#: ../dialogs/ActionBlockDialog.py:140
+msgid "Move action down"
+msgstr "Переместить действие ниже"
+
+#: ../dialogs/ActionBlockDialog.py:139
+msgid "Move action up"
+msgstr "Переместить действие выше"
+
+#: ../controls/CustomEditableListBox.py:43
+msgid "Move down"
+msgstr "Переместить ниже"
+
+#: ../editors/DataTypeEditor.py:355
+msgid "Move element down"
+msgstr "Переместить элемент ниже"
+
+#: ../editors/DataTypeEditor.py:354
+msgid "Move element up"
+msgstr "Переместить элементы выше"
+
+#: ../editors/ResourceEditor.py:271
+msgid "Move instance down"
+msgstr "Переместить экземпляр ниже"
+
+#: ../editors/ResourceEditor.py:270
+msgid "Move instance up"
+msgstr "Переместить экземпляр выше"
+
+#: ../editors/ResourceEditor.py:242
+msgid "Move task down"
+msgstr "Переместить задачу ниже"
+
+#: ../editors/ResourceEditor.py:241
+msgid "Move task up"
+msgstr "Переместить задачу выше"
+
+#: ../IDEFrame.py:99 ../IDEFrame.py:114 ../IDEFrame.py:144 ../IDEFrame.py:185
+msgid "Move the view"
+msgstr "Переместить отображение"
+
+#: ../controls/CustomEditableListBox.py:42
+msgid "Move up"
+msgstr "Переместить выше"
+
+#: ../editors/CodeFileEditor.py:661 ../controls/VariablePanel.py:453
+msgid "Move variable down"
+msgstr "Переместить переменную ниже"
+
+#: ../editors/CodeFileEditor.py:660 ../controls/VariablePanel.py:452
+msgid "Move variable up"
+msgstr "Переместить переменную выше"
+
+#: ../plcopen/iec_std.csv:74
+msgid "Multiplexer (select 1 of N)"
+msgstr "Мультиплексор (1 в N)"
+
+#: ../plcopen/iec_std.csv:34
+msgid "Multiplication"
+msgstr "Умножение"
+
+#: ../editors/FileManagementPanel.py:83
+msgid "My Computer:"
+msgstr "Мой компьютер:"
+
+#: ../dialogs/DiscoveryDialog.py:92
+msgid "NAME"
+msgstr "Имя"
+
+msgid "NOT R1"
+msgstr "НЕ R1"
+
+#: ../editors/ResourceEditor.py:68 ../editors/ResourceEditor.py:83
+#: ../editors/DataTypeEditor.py:50 ../controls/VariablePanel.py:53
+#: ../controls/VariablePanel.py:54
+msgid "Name"
+msgstr "Имя"
+
+#: ../Beremiz_service.py:332
+msgid "Name must not be null!"
+msgstr "Имя не может быть null!"
+
+#: ../dialogs/SFCStepDialog.py:56 ../dialogs/FBDBlockDialog.py:83
+#: ../dialogs/ConnectionDialog.py:75
+msgid "Name:"
+msgstr "Имя:"
+
+#: ../plcopen/iec_std.csv:24
+msgid "Natural logarithm"
+msgstr "Натуральный логарифм"
+
+#: ../dialogs/LDElementDialog.py:75 ../editors/Viewer.py:460
+msgid "Negated"
+msgstr "Инверсия"
+
+#: ../Beremiz_service.py:578
+msgid "Nevow Web service failed. "
+msgstr "Ошибка Web сервиса Nevow. "
+
+#: ../Beremiz_service.py:554
+msgid "Nevow/Athena import failed :"
+msgstr "Ошибка импорта Nevow/Athena :"
+
+#: ../PLCOpenEditor.py:102 ../PLCOpenEditor.py:144 ../Beremiz.py:321
+#: ../Beremiz.py:356
+msgid "New"
+msgstr "Новый"
+
+#: ../controls/CustomEditableListBox.py:40
+msgid "New item"
+msgstr "Новый элемент"
+
+#: ../editors/Viewer.py:459
+msgid "No Modifier"
+msgstr "Нет модификатора"
+
+#: ../ProjectController.py:1763
+msgid "No PLC to transfer (did build succeed ?)\n"
+msgstr "Нет ПЛК для передачи (была сборка успешна?)\n"
+
+#: ../PLCGenerator.py:1631
+#, python-format
+msgid "No body defined in \"%s\" POU"
+msgstr "Нет тела для POU \"%s\""
+
+#: ../PLCGenerator.py:806 ../PLCGenerator.py:1241
+#, python-brace-format
+msgid "No connector found corresponding to \"{a1}\" continuation in \"{a2}\" POU"
+msgstr "Не найден коннектор, соответствующий продолжению цепи \"{a1}\" в POU \"{a2}\""
+
+#: ../PLCOpenEditor.py:347
+msgid ""
+"No documentation available.\n"
+"Coming soon."
+msgstr ""
+"Документация отсутствует.\n"
+"В разработке."
+
+#: ../PLCGenerator.py:829
+#, python-format
+msgid "No informations found for \"%s\" block"
+msgstr "Не найдена информация по блоку \"%s\""
+
+#: ../PLCGenerator.py:1194
+#, python-brace-format
+msgid "No output {a1} variable found in block {a2} in POU {a3}. Connection must be broken"
+msgstr "Выходная переменная {a1} не найдена в блоке {a2} в POU {a3}."
+
+#: ../controls/SearchResultPanel.py:169
+msgid "No search results available."
+msgstr "Ничего не найдено."
+
+#: ../svgui/svgui.py:131
+#, python-format
+msgid "No such SVG file: %s\n"
+msgstr "Нет такого SVG файла: %s\n"
+
+#: ../canfestival/config_utils.py:639
+#, python-brace-format
+msgid "No such index/subindex ({a1},{a2}) (variable {a3})"
+msgstr "Нет индекса/подиндекса ({a1},{a2}) (переменная {a3})"
+
+#: ../canfestival/config_utils.py:362
+#, python-brace-format
+msgid "No such index/subindex ({a1},{a2}) in ID : {a3} (variable {a4})"
+msgstr "Нет индекса/подиндекса ({a1},{a2}) в ID: {a3} (переменная {a4})"
+
+#: ../dialogs/BrowseValuesLibraryDialog.py:83
+msgid "No valid value selected!"
+msgstr "Не выбрано допустимое значение!"
+
+#: ../PLCGenerator.py:1629
+#, python-format
+msgid "No variable defined in \"%s\" POU"
+msgstr "Переменная не определена в POU \"%s\""
+
+msgid "NodeId"
+msgstr "ID узла"
+
+#: ../canfestival/config_utils.py:355
+#, python-brace-format
+msgid "Non existing node ID : {a1} (variable {a2})"
+msgstr "Несуществующий ID узла: {a1} (переменная {a2})"
+
+#: ../controls/VariablePanel.py:64
+msgid "Non-Retain"
+msgstr "Не-Retain"
+
+#: ../dialogs/LDElementDialog.py:75
+msgid "Normal"
+msgstr "Обычный"
+
+#: ../canfestival/config_utils.py:389
+#, python-brace-format
+msgid "Not PDO mappable variable : '{a1}' (ID:{a2},Idx:{a3},sIdx:{a4}))"
+msgstr "Не переменная для отображения в PDO: '{a1}' (ID:{a2},Idx:{a3},sIdx:{a4}))"
+
+#: ../plcopen/iec_std.csv:80
+msgid "Not equal to"
+msgstr "Не равно"
+
+#: ../dialogs/SFCDivergenceDialog.py:89
+msgid "Number of sequences:"
+msgstr "Число ветвей:"
+
+#: ../plcopen/iec_std.csv:22
+msgid "Numerical"
+msgstr "Математические функции"
+
+#: ../dialogs/SearchInProjectDialog.py:86
+msgid "Only Elements"
+msgstr "Только элементы"
+
+#: ../PLCOpenEditor.py:104 ../PLCOpenEditor.py:145 ../Beremiz.py:323
+#: ../Beremiz.py:357
+msgid "Open"
+msgstr "Открыть"
+
+#: ../svgui/svgui.py:140
+msgid "Open Inkscape"
+msgstr "Открыть Inkscape"
+
+#: ../version.py:66
+msgid "Open Source framework for automation, implemented IEC 61131 IDE with constantly growing set of extensions and flexible PLC runtime."
+msgstr "Свободное программное обеспечение для промышленной автоматизации, состоящие из среды разработки программ по стандарту МЭК 61131 с постоянно расширяющимся набором плагинов и гибкой системой исполнения для ПЛК."
+
+#: ../ProjectController.py:1815
+msgid "Open a file explorer to manage project files"
+msgstr "Открыть файловый менеджер для просмотра файлов проекта"
+
+#: ../wxglade_hmi/wxglade_hmi.py:138
+msgid "Open wxGlade"
+msgstr "Открыть wxGlade"
+
+#: ../controls/VariablePanel.py:53 ../controls/VariablePanel.py:54
+msgid "Option"
+msgstr "Настройка"
+
+#: ../dialogs/FindInPouDialog.py:83
+msgid "Options"
+msgstr "Настройки"
+
+#: ../controls/ProjectPropertiesPanel.py:97
+msgid "Organization (optional):"
+msgstr "Организация (опционально):"
+
+#: ../canfestival/SlaveEditor.py:74 ../canfestival/NetworkEditor.py:95
+msgid "Other Profile"
+msgstr "Другой профиль"
+
+#: ../dialogs/SFCStepDialog.py:71 ../dialogs/FBDVariableDialog.py:39
+#: ../dialogs/BrowseLocationsDialog.py:41 ../editors/Viewer.py:289
+#: ../editors/Viewer.py:1579 ../editors/TextViewer.py:307
+#: ../controls/LocationCellEditor.py:98 ../controls/VariablePanel.py:71
+#: ../controls/VariablePanel.py:291 ../controls/VariablePanel.py:351
+msgid "Output"
+msgstr "Выход"
+
+msgid "Overriding reset"
+msgstr "Сброс интегратора"
+
+#: ../canfestival/SlaveEditor.py:63 ../canfestival/NetworkEditor.py:84
+msgid "PDO Receive"
+msgstr "PDO приема"
+
+#: ../canfestival/SlaveEditor.py:62 ../canfestival/NetworkEditor.py:83
+msgid "PDO Transmit"
+msgstr "PDO передачи"
+
+msgid "PLC"
+msgstr "ПЛК"
+
+#: ../targets/toolchain_gcc.py:131
+msgid "PLC :\n"
+msgstr "ПЛК:\n"
+
+#: ../Beremiz.py:453
+msgid "PLC Log"
+msgstr "Лог ПЛК"
+
+#: ../ProjectController.py:992
+msgid "PLC code generation failed !\n"
+msgstr "Неудачная генерация кода!\n"
+
+#: ../Beremiz_service.py:295
+msgid "PLC is empty or already started."
+msgstr "В ПЛК нет программы или он уже запущен."
+
+#: ../Beremiz_service.py:302
+msgid "PLC is not started."
+msgstr "ПЛК незапущен."
+
+#: ../PLCOpenEditor.py:196 ../PLCOpenEditor.py:309
+#, python-brace-format
+msgid ""
+"PLC syntax error at line {a1}:\n"
+"{a2}"
+msgstr ""
+"Синтаксическая ошибка в строке {a1}:\n"
+"{a2}"
+
+#: ../PLCOpenEditor.py:292 ../PLCOpenEditor.py:373
+msgid "PLCOpen files (*.xml)|*.xml|All files|*.*"
+msgstr "PLCOpen файлы (*.xml)|*.xml|All files|*.*"
+
+#: ../PLCOpenEditor.py:152 ../PLCOpenEditor.py:209
+msgid "PLCOpenEditor"
+msgstr "PLCOpenEditor"
+
+#: ../PLCOpenEditor.py:355
+msgid ""
+"PLCOpenEditor is part of Beremiz project.\n"
+"\n"
+"Beremiz is an "
+msgstr ""
+"PLCOpenEditor является частью проекта Beremiz.\n"
+"\n"
+"Beremiz — "
+
+#: ../dialogs/DiscoveryDialog.py:95
+msgid "PORT"
+msgstr "Порт"
+
+#: ../dialogs/PouDialog.py:100
+msgid "POU Name"
+msgstr "Имя POU"
+
+#: ../dialogs/PouDialog.py:58
+msgid "POU Name:"
+msgstr "Имя POU:"
+
+#: ../dialogs/PouDialog.py:102
+msgid "POU Type"
+msgstr "Тип POU"
+
+#: ../dialogs/PouDialog.py:65
+msgid "POU Type:"
+msgstr "Тип POU:"
+
+msgid "PV - SP"
+msgstr "Ошибка, PV - SP"
+
+#: ../connectors/PYRO/__init__.py:45
+#, python-format
+msgid "PYRO connecting to URI : %s\n"
+msgstr "PYRO подключение к URI: %s\n"
+
+#: ../connectors/PYRO/__init__.py:61
+#, python-format
+msgid "PYRO using certificates in '%s' \n"
+msgstr "PYRO использует сертификаты в '%s'\n"
+
+#: ../PLCOpenEditor.py:118 ../Beremiz.py:336
+msgid "Page Setup"
+msgstr "Настройки страницы"
+
+#: ../controls/ProjectPropertiesPanel.py:110
+msgid "Page Size (optional):"
+msgstr "Размер страницы (опционально):"
+
+#: ../IDEFrame.py:2599
+#, python-format
+msgid "Page: %d"
+msgstr "Страница: %d"
+
+#: ../controls/PouInstanceVariablesPanel.py:124
+msgid "Parent instance"
+msgstr "Родительский экземпляр"
+
+#: ../editors/Viewer.py:598 ../IDEFrame.py:372 ../IDEFrame.py:426
+msgid "Paste"
+msgstr "Вставить"
+
+#: ../IDEFrame.py:1865
+msgid "Paste POU"
+msgstr "Вставить POU"
+
+#: ../dialogs/SearchInProjectDialog.py:56
+msgid "Pattern to search:"
+msgstr "Шаблон поиска:"
+
+#: ../dialogs/LDPowerRailDialog.py:73
+msgid "Pin number:"
+msgstr "Номер пина:"
+
+#: ../editors/Viewer.py:2706 ../editors/Viewer.py:2963
+#: ../editors/SFCViewer.py:770
+msgid "Please choose a target"
+msgstr "Выберите цель перехода"
+
+#: ../editors/TextViewer.py:262
+msgid "Please enter a block name"
+msgstr "Введите имя блока"
+
+#: ../editors/Viewer.py:2576 ../editors/Viewer.py:3005
+msgid "Please enter comment text"
+msgstr "Введите текст комментария"
+
+#: ../editors/SFCViewer.py:433 ../editors/SFCViewer.py:455
+#: ../editors/SFCViewer.py:799
+msgid "Please enter step name"
+msgstr "Введите имя шага"
+
+#: ../Beremiz_service.py:194
+msgid "Please enter text"
+msgstr "Введите текст"
+
+#: ../dialogs/ForceVariableDialog.py:163
+#, python-format
+msgid "Please enter value for a \"%s\" variable:"
+msgstr "Введите значение для переменной \"%s\":"
+
+#: ../Beremiz_service.py:317
+msgid "Port number must be 0 <= port <= 65535!"
+msgstr "Номер порта должен быть в диапазоне от 0 до 65535!"
+
+#: ../Beremiz_service.py:317
+msgid "Port number must be an integer!"
+msgstr "Номер порта должен быть целым числом!"
+
+#: ../editors/Viewer.py:536 ../editors/Viewer.py:2367
+msgid "Power Rail"
+msgstr "Шина питания"
+
+#: ../dialogs/LDPowerRailDialog.py:50
+msgid "Power Rail Properties"
+msgstr "Свойства шины питания"
+
+msgid "Preset datetime"
+msgstr "Основное время"
+
+#: ../PLCOpenEditor.py:120 ../Beremiz.py:338
+msgid "Preview"
+msgstr "Просмотр"
+
+#: ../dialogs/BlockPreviewDialog.py:57
+msgid "Preview:"
+msgstr "Просмотр:"
+
+#: ../PLCOpenEditor.py:122 ../PLCOpenEditor.py:148 ../Beremiz.py:340
+#: ../Beremiz.py:360
+msgid "Print"
+msgstr "Печать"
+
+#: ../IDEFrame.py:1075
+msgid "Print preview"
+msgstr "Предварительный просмотр"
+
+#: ../editors/ResourceEditor.py:68
+msgid "Priority"
+msgstr "Приоритет"
+
+#: ../dialogs/SFCTransitionDialog.py:89
+msgid "Priority:"
+msgstr "Приоритет:"
+
+#: ../runtime/PLCObject.py:370
+#, python-format
+msgid "Problem starting PLC : error %d"
+msgstr "Проблема запуска ПЛК: ошибка %d"
+
+msgid "Process variable"
+msgstr "Текущее значение регулируемой переменной"
+
+#: ../dialogs/ProjectDialog.py:55
+msgid "Product Name"
+msgstr "Имя продукта"
+
+#: ../controls/ProjectPropertiesPanel.py:80
+msgid "Product Name (required):"
+msgstr "Имя продукта (обязательно):"
+
+#: ../controls/ProjectPropertiesPanel.py:82
+msgid "Product Release (optional):"
+msgstr "Релиз продукта (опцинально):"
+
+#: ../dialogs/ProjectDialog.py:56
+msgid "Product Version"
+msgstr "Версия продукта"
+
+#: ../controls/ProjectPropertiesPanel.py:81
+msgid "Product Version (required):"
+msgstr "Версия продукта (обязательно):"
+
+#: ../dialogs/SearchInProjectDialog.py:38 ../IDEFrame.py:1744
+#: ../IDEFrame.py:1941
+msgid "Program"
+msgstr "Программа"
+
+#: ../PLCOpenEditor.py:337
+msgid "Program was successfully generated!"
+msgstr "Программа успешно сгенерирована!"
+
+#: ../PLCControler.py:96
+msgid "Programs"
+msgstr "Программы"
+
+#: ../editors/Viewer.py:242
+msgid "Programs can't be used by other POUs!"
+msgstr "Программы не могут использоваться другими POU!"
+
+#: ../controls/ProjectPropertiesPanel.py:84 ../IDEFrame.py:584
+msgid "Project"
+msgstr "Проект"
+
+#: ../controls/SearchResultPanel.py:173
+#, python-format
+msgid "Project '%s':"
+msgstr "Проект '%s':"
+
+#: ../ProjectController.py:1814
+msgid "Project Files"
+msgstr "Файлы проекта"
+
+#: ../dialogs/ProjectDialog.py:54
+msgid "Project Name"
+msgstr "Имя проекта"
+
+#: ../controls/ProjectPropertiesPanel.py:78
+msgid "Project Name (required):"
+msgstr "Имя проекта (обязательно):"
+
+#: ../controls/ProjectPropertiesPanel.py:79
+msgid "Project Version (optional):"
+msgstr "Версия проекта (опционально):"
+
+#: ../PLCControler.py:3158
+msgid ""
+"Project file syntax error:\n"
+"\n"
+msgstr ""
+"Синтаксическая ошибка в файле проекта:\n"
+"\n"
+
+#: ../dialogs/ProjectDialog.py:32 ../editors/ProjectNodeEditor.py:37
+msgid "Project properties"
+msgstr "Свойства проекта"
+
+#: ../ConfigTreeNode.py:566
+#, python-brace-format
+msgid "Project tree layout do not match confnode.xml {a1}!={a2} "
+msgstr "Дерево проекта не соответствует confnode.xml {a1}!={a2} "
+
+#: ../dialogs/ConnectionDialog.py:94
+msgid "Propagate Name"
+msgstr "Для всей цепи"
+
+#: ../PLCControler.py:97
+msgid "Properties"
+msgstr "Свойства"
+
+msgid "Proportionality constant"
+msgstr "Коэффициент пропорциональности"
+
+#: ../Beremiz_service.py:440
+msgid "Publishing service on local network"
+msgstr "Сервис доступен в локальной сети"
+
+#: ../connectors/PYRO/__init__.py:118
+#, python-format
+msgid "Pyro exception: %s\n"
+msgstr "Исключение Pyro: %s\n"
+
+#: ../Beremiz_service.py:427
+msgid "Pyro object's uri :"
+msgstr "URI для Pyro :"
+
+#: ../Beremiz_service.py:426
+msgid "Pyro port :"
+msgstr "Порт Pyro :"
+
+#: ../py_ext/PythonEditor.py:81
+msgid "Python code"
+msgstr "Код на python"
+
+#: ../features.py:33
+msgid "Python file"
+msgstr "Python файл"
+
+#: ../dialogs/ActionBlockDialog.py:38
+msgid "Qualifier"
+msgstr "Спецификатор"
+
+#: ../PLCOpenEditor.py:128 ../Beremiz.py:343 ../Beremiz_service.py:273
+msgid "Quit"
+msgstr "Выход"
+
+msgid "Ramp duration"
+msgstr "Длительность нарастания"
+
+#: ../controls/DebugVariablePanel/DebugVariablePanel.py:225
+msgid "Range:"
+msgstr "Диапазон:"
+
+#: ../ProjectController.py:1810
+msgid "Raw IEC code"
+msgstr "МЭК-код"
+
+#: ../Beremiz.py:1143
+#, python-format
+msgid "Really delete node '%s'?"
+msgstr "Действительно удалить элемент '%s'?"
+
+#: ../IDEFrame.py:362 ../IDEFrame.py:422
+msgid "Redo"
+msgstr "Повторить"
+
+#: ../dialogs/SFCTransitionDialog.py:74
+msgid "Reference"
+msgstr "Ссылка"
+
+#: ../dialogs/DiscoveryDialog.py:106 ../IDEFrame.py:432
+msgid "Refresh"
+msgstr "Обновить"
+
+#: ../dialogs/SearchInProjectDialog.py:66
+msgid "Regular expression"
+msgstr "Регулярное выражение"
+
+#: ../dialogs/FindInPouDialog.py:98
+msgid "Regular expressions"
+msgstr "Регулярные выражения"
+
+#: ../editors/Viewer.py:1556
+msgid "Release value"
+msgstr "Освободить значение"
+
+#: ../plcopen/iec_std.csv:37
+msgid "Remainder (modulo)"
+msgstr "Остаток от деления (modulo)"
+
+#: ../Beremiz.py:1144
+#, python-format
+msgid "Remove %s node"
+msgstr "Удалить %s элемент"
+
+#: ../IDEFrame.py:2405
+msgid "Remove Datatype"
+msgstr "Удалить тип данных"
+
+#: ../IDEFrame.py:2410
+msgid "Remove Pou"
+msgstr "Удалить POU"
+
+#: ../dialogs/ActionBlockDialog.py:138
+msgid "Remove action"
+msgstr "Удалить действие"
+
+#: ../editors/DataTypeEditor.py:353
+msgid "Remove element"
+msgstr "Удалить элемент"
+
+#: ../editors/FileManagementPanel.py:63
+msgid "Remove file from left folder"
+msgstr "Удалить файл из левой директории"
+
+#: ../editors/ResourceEditor.py:269
+msgid "Remove instance"
+msgstr "Удалить экземпляр"
+
+#: ../canfestival/NetworkEditor.py:104
+msgid "Remove slave"
+msgstr "Удалить ведомое устройство"
+
+#: ../editors/ResourceEditor.py:240
+msgid "Remove task"
+msgstr "Удалить задачу"
+
+#: ../editors/CodeFileEditor.py:659 ../controls/VariablePanel.py:451
+msgid "Remove variable"
+msgstr "Удалить переменную"
+
+#: ../IDEFrame.py:1945
+msgid "Rename"
+msgstr "Переименовать"
+
+#: ../editors/FileManagementPanel.py:181
+msgid "Replace File"
+msgstr "Заменить файл"
+
+#: ../editors/Viewer.py:502
+msgid "Replace Wire by connections"
+msgstr "Заменить цепь подключениями"
+
+#: ../plcopen/iec_std.csv:89
+msgid "Replacement (within)"
+msgstr "Замена подстроки"
+
+#: ../dialogs/LDElementDialog.py:76
+msgid "Reset"
+msgstr "Сброс"
+
+#: ../editors/Viewer.py:583
+msgid "Reset Execution Order"
+msgstr "Сбросить порядок исполнения"
+
+#: ../IDEFrame.py:451
+msgid "Reset Perspective"
+msgstr "Сбросить представление"
+
+#: ../controls/SearchResultPanel.py:105
+msgid "Reset search result"
+msgstr "Сбросить результаты поиска"
+
+msgid "Reset time"
+msgstr "Постоянная времени интегрирования"
+
+#: ../PLCControler.py:97 ../Beremiz.py:1075
+msgid "Resources"
+msgstr "Ресурсы"
+
+#: ../controls/VariablePanel.py:62
+msgid "Retain"
+msgstr "Retain"
+
+#: ../controls/VariablePanel.py:424
+msgid "Return Type:"
+msgstr "Возвращаемый тип:"
+
+#: ../editors/Viewer.py:487
+msgid "Right"
+msgstr "Право"
+
+#: ../dialogs/LDPowerRailDialog.py:63
+msgid "Right PowerRail"
+msgstr "Правая шина питания"
+
+#: ../dialogs/LDElementDialog.py:77 ../editors/Viewer.py:461
+msgid "Rising Edge"
+msgstr "Нарастающий фронт"
+
+#: ../plcopen/iec_std.csv:65
+msgid "Rotate left"
+msgstr "Циклический сдвиг влево"
+
+#: ../plcopen/iec_std.csv:64
+msgid "Rotate right"
+msgstr "Циклический сдвиг вправо"
+
+#: ../plcopen/iec_std.csv:17
+msgid "Rounding up/down"
+msgstr "Округление вверх/вниз"
+
+#: ../ProjectController.py:1778
+msgid "Run"
+msgstr "Старт"
+
+#: ../ProjectController.py:1037
+msgid "Runtime IO extensions C code generation failed !\n"
+msgstr "Ошибка генерации C-кода для расширений ввода-вывода!\n"
+
+#: ../ProjectController.py:1046
+msgid "Runtime library extensions C code generation failed !\n"
+msgstr "Ошибка генерации C-кода для библиотеки расширений системы исполнения!\n"
+
+#: ../canfestival/SlaveEditor.py:61 ../canfestival/NetworkEditor.py:82
+msgid "SDO Client"
+msgstr "SDO клиент"
+
+#: ../canfestival/SlaveEditor.py:60 ../canfestival/NetworkEditor.py:81
+msgid "SDO Server"
+msgstr "SDO сервер"
+
+#: ../dialogs/PouDialog.py:36 ../controls/ProjectPropertiesPanel.py:143
+msgid "SFC"
+msgstr "SFC"
+
+#: ../PLCGenerator.py:1392
+#, python-brace-format
+msgid "SFC jump in pou \"{a1}\" refers to non-existent SFC step \"{a2}\""
+msgstr "Безусловный переход в POU \"{a1}\" ссылается на несуществующий SFC шаг \"{a2}\""
+
+#: ../PLCGenerator.py:773
+#, python-format
+msgid "SFC transition in POU \"%s\" must be connected."
+msgstr "SFC переход в POU \"%s\" должен быть подключен."
+
+#: ../dialogs/PouTransitionDialog.py:40 ../dialogs/PouActionDialog.py:31
+#: ../dialogs/PouDialog.py:36
+msgid "ST"
+msgstr "ST"
+
+#: ../PLCOpenEditor.py:324
+msgid "ST files (*.st)|*.st|All files|*.*"
+msgstr "ST файлы (*.st)|*.st|Все файлы|*.*"
+
+#: ../svgui/svgui.py:125
+msgid "SVG files (*.svg)|*.svg|All files|*.*"
+msgstr "SVG файлы (*.svg)|*.svg|Все файлы|*.*"
+
+#: ../features.py:35
+msgid "SVGUI"
+msgstr "SVGUI"
+
+msgid "Sampling period"
+msgstr "Период сэмплирования"
+
+#: ../PLCOpenEditor.py:111 ../PLCOpenEditor.py:146 ../Beremiz.py:327
+#: ../Beremiz.py:358
+msgid "Save"
+msgstr "Сохранить"
+
+#: ../PLCOpenEditor.py:113 ../PLCOpenEditor.py:147 ../Beremiz.py:359
+msgid "Save As..."
+msgstr "Сохранить как..."
+
+#: ../Beremiz.py:329
+msgid "Save as"
+msgstr "Сохранить как"
+
+#: ../ProjectController.py:420
+msgid "Save path is the same as path of a project! \n"
+msgstr "Выбранный путь совпадает с путём проекта!\n"
+
+#: ../dialogs/SearchInProjectDialog.py:69
+msgid "Scope"
+msgstr "Область действия"
+
+#: ../IDEFrame.py:623
+msgid "Search"
+msgstr "Поиск"
+
+#: ../dialogs/SearchInProjectDialog.py:44 ../IDEFrame.py:382 ../IDEFrame.py:428
+msgid "Search in Project"
+msgstr "Поиск в проекте"
+
+#: ../dialogs/DurationEditorDialog.py:46
+msgid "Seconds:"
+msgstr "Секунды:"
+
+#: ../IDEFrame.py:388
+msgid "Select All"
+msgstr "Выделить все"
+
+#: ../editors/Viewer.py:288 ../editors/TextViewer.py:306
+#: ../controls/LocationCellEditor.py:97 ../controls/VariablePanel.py:290
+#: ../controls/VariablePanel.py:350
+msgid "Select a variable class:"
+msgstr "Выберите класс переменной:"
+
+#: ../ProjectController.py:1195
+msgid "Select an editor:"
+msgstr "Выберите редактор:"
+
+#: ../controls/PouInstanceVariablesPanel.py:276
+msgid "Select an instance"
+msgstr "Выберите экземпляр"
+
+#: ../IDEFrame.py:607
+msgid "Select an object"
+msgstr "Выберите объект"
+
+#: ../ProjectController.py:427
+msgid "Selected directory already contains another project. Overwrite? \n"
+msgstr "Выбранная директория уже содержит другой проект. Перезаписать?\n"
+
+#: ../plcopen/iec_std.csv:70
+msgid "Selection"
+msgstr "Выбор"
+
+#: ../dialogs/SFCDivergenceDialog.py:65
+msgid "Selection Convergence"
+msgstr "Альтернативное объединение"
+
+#: ../dialogs/SFCDivergenceDialog.py:64
+msgid "Selection Divergence"
+msgstr "Альтернативное ветвление"
+
+#: ../dialogs/DiscoveryDialog.py:82
+msgid "Service Discovery"
+msgstr "Поиск сервиса"
+
+#: ../dialogs/DiscoveryDialog.py:85
+msgid "Services available:"
+msgstr "Сервисы доступны:"
+
+#: ../dialogs/LDElementDialog.py:76
+msgid "Set"
+msgstr "Установить"
+
+msgid "Set point"
+msgstr "Уставка"
+
+#: ../plcopen/iec_std.csv:62
+msgid "Shift left"
+msgstr "Сдвиг влево"
+
+#: ../plcopen/iec_std.csv:63
+msgid "Shift right"
+msgstr "Сдвиг вправо"
+
+#: ../ProjectController.py:1804
+msgid "Show IEC code generated by PLCGenerator"
+msgstr "Показать год, сгенерированный PLCGenerator"
+
+#: ../canfestival/canfestival.py:387
+msgid "Show Master"
+msgstr "Показать ведущего"
+
+#: ../canfestival/canfestival.py:388
+msgid "Show Master generated by config_utils"
+msgstr "Показать ведущий узел сгенерированный config_utils"
+
+#: ../ProjectController.py:1802
+msgid "Show code"
+msgstr "Показать код"
+
+#: ../dialogs/SFCDivergenceDialog.py:67
+msgid "Simultaneous Convergence"
+msgstr "Параллельное объединение"
+
+#: ../dialogs/SFCDivergenceDialog.py:66
+msgid "Simultaneous Divergence"
+msgstr "Параллельное ветвление"
+
+#: ../plcopen/iec_std.csv:27
+msgid "Sine"
+msgstr "Синус"
+
+#: ../editors/ResourceEditor.py:68
+msgid "Single"
+msgstr "Источник"
+
+#: ../targets/toolchain_makefile.py:126
+msgid "Source didn't change, no build.\n"
+msgstr "Исходные файлы не изменились, сборка не нужна.\n"
+
+#: ../PLCGenerator.py:397
+#, python-brace-format
+msgid "Source signal has to be defined for single task '{a1}' in resource '{a2}.{a3}'."
+msgstr "Для задачи '{a1}' в ресурсе '{a2}.{a3}' отсутсвует задание источника."
+
+#: ../plcopen/iec_std.csv:23
+msgid "Square root (base 2)"
+msgstr "Квадратный корень"
+
+#: ../plcopen/definitions.py:46
+msgid "Standard function blocks"
+msgstr "Стандартные функциональные блоки"
+
+#: ../ProjectController.py:1780 ../Beremiz_service.py:261
+msgid "Start PLC"
+msgstr "Запустить ПЛК"
+
+#: ../ProjectController.py:984
+#, python-format
+msgid "Start build in %s\n"
+msgstr "Сборка запущена в %s\n"
+
+#: ../ProjectController.py:1298
+msgid "Started"
+msgstr "Работа"
+
+#: ../ProjectController.py:1586
+msgid "Starting PLC\n"
+msgstr "ПЛК запускается\n"
+
+#: ../Beremiz.py:463
+msgid "Status ToolBar"
+msgstr "Панель статуса"
+
+#: ../editors/Viewer.py:553 ../editors/Viewer.py:2342
+msgid "Step"
+msgstr "Шаг"
+
+#: ../ProjectController.py:1783
+msgid "Stop"
+msgstr "Стоп"
+
+#: ../Beremiz_service.py:262
+msgid "Stop PLC"
+msgstr "Остановить ПЛК"
+
+#: ../ProjectController.py:1785
+msgid "Stop Running PLC"
+msgstr "Остановить запущенный ПЛК"
+
+#: ../ProjectController.py:1299
+msgid "Stopped"
+msgstr "Стоп"
+
+#: ../ProjectController.py:1558
+msgid "Stopping debugger...\n"
+msgstr "Остановка отладчика...\n"
+
+#: ../editors/DataTypeEditor.py:54
+msgid "Structure"
+msgstr "Структура"
+
+#: ../editors/DataTypeEditor.py:54
+msgid "Subrange"
+msgstr "Поддиапазон"
+
+#: ../plcopen/iec_std.csv:35
+msgid "Subtraction"
+msgstr "Вычитание"
+
+#: ../ProjectController.py:1023
+msgid "Successfully built.\n"
+msgstr "Сборка прошла успешно.\n"
+
+#: ../IDEFrame.py:447
+msgid "Switch perspective"
+msgstr "Сменить представление"
+
+msgid "Sync_Align"
+msgstr ""
+
+msgid "Sync_Align_Ratio"
+msgstr ""
+
+msgid "Sync_TPDOs"
+msgstr ""
+
+#: ../dialogs/SearchInProjectDialog.py:165 ../dialogs/FindInPouDialog.py:172
+msgid "Syntax error in regular expression of pattern to search!"
+msgstr "Синтаксическая ошибка в регулярном выражении шаблона поиска!"
+
+#: ../dialogs/DiscoveryDialog.py:93
+msgid "TYPE"
+msgstr "Тип"
+
+#: ../plcopen/iec_std.csv:29
+msgid "Tangent"
+msgstr "Тангенс"
+
+msgid "TargetType"
+msgstr "Целевая платформа"
+
+#: ../editors/ResourceEditor.py:83
+msgid "Task"
+msgstr "Задача"
+
+#: ../editors/ResourceEditor.py:235
+msgid "Tasks:"
+msgstr "Задачи:"
+
+#: ../controls/VariablePanel.py:73
+msgid "Temp"
+msgstr "Временный"
+
+msgid "The PID (proportional, Integral, Derivative) function block provides the classical three term controller for closed loop control."
+msgstr "ПИД (Пропорциональный Интегральный Дифференциальный) ФБ - классический регулятор, используемый в системах с обратной связью."
+
+msgid "The RAMP function block is modelled on example given in the standard."
+msgstr "Ограничитель скорости изменения сигнала. Функциональный блок написан согласно примеру, приведенному в стандарте."
+
+msgid "The RS bistable is a latch where the Reset dominates."
+msgstr "RS-триггер с приоритетом выключения."
+
+msgid "The SR bistable is a latch where the Set dominates."
+msgstr "SR-триггер с приоритетом включения."
+
+msgid "The derivative function block produces an output XOUT proportional to the rate of change of the input XIN."
+msgstr "Функциональный блок формирует выход XOUT пропорционально частоте изменения входа XIN."
+
+msgid "The down-counter can be used to signal when a count has reached zero, on counting down from a preset value."
+msgstr "Декрементный счетчик может использоваться, когда необходимо сигнализировать, что счетчик достиг нулевого значения с исходного заданного значения."
+
+#: ../editors/FileManagementPanel.py:180
+#, python-format
+msgid ""
+"The file '%s' already exist.\n"
+"Do you want to replace it?"
+msgstr ""
+"Файл '%s' уже существует.\n"
+"Вы хотите заменить его?"
+
+#: ../editors/LDViewer.py:882
+msgid "The group of block must be coherent!"
+msgstr "Группа блоков должна быть связанной!"
+
+msgid "The hysteresis function block provides a hysteresis boolean output driven by the difference of two floating point (REAL) inputs XIN1 and XIN2."
+msgstr "Функциональный блок формирует дискретный выход с гистерезисом в зависимости от разницы двух вещественных входов XIN1 и XIN2."
+
+msgid "The integral function block integrates the value of input XIN over time."
+msgstr "Функциональный блок интегрирует входное значение XIN во времени."
+
+msgid "The off-delay timer can be used to delay setting an output false, for fixed period after input goes false."
+msgstr "Таймер выключения может быть использован, чтобы внести задержку установки выхода в FALSE на фиксированный период времени после того, как вход стал FALSE."
+
+msgid "The on-delay timer can be used to delay setting an output true, for fixed period after an input becomes true."
+msgstr "Таймер выключения может быть использован, чтобы внести задержку установки выхода в TRUE на фиксированный период времени после того, как вход стал TRUE."
+
+msgid "The output produces a single pulse when a falling edge is detected."
+msgstr "Детектор падающего фронта. На выходе формируется одиночный импульс, если обнаружен падающий фронт."
+
+msgid "The output produces a single pulse when a rising edge is detected."
+msgstr "Детектор нарастающего фронта. На выходе формируется одиночный импульс, если обнаружен нарастающий фронт."
+
+msgid "The pulse timer can be used to generate output pulses of a given time duration."
+msgstr "Генератор импульсов. Функциональный блок используется для генерации выходных импульсов заданной длительности."
+
+msgid "The real time clock has many uses including time stamping, setting dates and times of day in batch reports, in alarm messages and so on."
+msgstr "Часы реального времени используется для получения меток времени, установки даты и времени дня в отчетах, сообщениях об авариях и пр."
+
+msgid "The semaphore provides a mechanism to allow software elements mutually exclusive access to certain ressources."
+msgstr "Семафор предоставляет собой программный механизм синхронизации для обеспечения исключительного доступа к определенным ресурсам."
+
+msgid "The up-counter can be used to signal when a count has reached a maximum value."
+msgstr "Инкрементный счетчик может использоваться, когда необходимо сигнализировать, что счетчик достиг максимального значения."
+
+msgid "The up-down counter has two inputs CU and CD. It can be used to both count up on one input and down on the other."
+msgstr "Инкрементный/декрементный счетчик имеет два входа CU и CD. Он может использоваться для счета вверх по одному входу и для счета низ по другому."
+
+#: ../Beremiz.py:640 ../IDEFrame.py:1011
+msgid "There are changes, do you want to save?"
+msgstr "Хотите сохранить изменения?"
+
+#: ../IDEFrame.py:1655 ../IDEFrame.py:1674
+#, python-format
+msgid "There is a POU named \"%s\". This could cause a conflict. Do you wish to continue?"
+msgstr "Существует POU с именем \"%s\". Это может вызвать конфликт. Хотите продолжить?"
+
+#: ../IDEFrame.py:1098
+msgid ""
+"There was a problem printing.\n"
+"Perhaps your current printer is not set correctly?"
+msgstr ""
+"Произошла проблема во время печати.\n"
+"Возможно, текущий принтер не настроен?"
+
+#: ../editors/LDViewer.py:891
+msgid "This option isn't available yet!"
+msgstr "Это опция еще не доступна!"
+
+#: ../controls/DebugVariablePanel/DebugVariablePanel.py:565
+#, python-format
+msgid "Tick: %d"
+msgstr "Цикл: %d"
+
+#: ../plcopen/iec_std.csv:40
+msgid "Time"
+msgstr "Время"
+
+#: ../plcopen/iec_std.csv:40 ../plcopen/iec_std.csv:41
+msgid "Time addition"
+msgstr "Сложение времени"
+
+#: ../plcopen/iec_std.csv:86
+msgid "Time concatenation"
+msgstr "Объединение времен"
+
+#: ../plcopen/iec_std.csv:60 ../plcopen/iec_std.csv:61
+msgid "Time division"
+msgstr "Деление времени"
+
+#: ../plcopen/iec_std.csv:46 ../plcopen/iec_std.csv:47
+msgid "Time multiplication"
+msgstr "Умножение времени"
+
+#: ../plcopen/iec_std.csv:48 ../plcopen/iec_std.csv:49
+msgid "Time subtraction"
+msgstr "Вычитание времени"
+
+#: ../plcopen/iec_std.csv:42 ../plcopen/iec_std.csv:43
+msgid "Time-of-day addition"
+msgstr "Сложение времени суток"
+
+#: ../plcopen/iec_std.csv:52 ../plcopen/iec_std.csv:53
+#: ../plcopen/iec_std.csv:54 ../plcopen/iec_std.csv:55
+msgid "Time-of-day subtraction"
+msgstr "Вычитание времени суток"
+
+#: ../editors/Viewer.py:489
+msgid "Top"
+msgstr "Верх"
+
+#: ../ProjectController.py:1792
+msgid "Transfer"
+msgstr "Передать"
+
+#: ../ProjectController.py:1794
+msgid "Transfer PLC"
+msgstr "Передать ПЛК"
+
+#: ../ProjectController.py:1758
+msgid "Transfer completed successfully.\n"
+msgstr "Передача успешно завершена.\n"
+
+#: ../ProjectController.py:1760
+msgid "Transfer failed\n"
+msgstr "Ошибка передачи\n"
+
+#: ../editors/Viewer.py:554 ../editors/Viewer.py:2344 ../editors/Viewer.py:2371
+msgid "Transition"
+msgstr "Переход"
+
+#: ../PLCGenerator.py:1518
+#, python-format
+msgid "Transition \"%s\" body must contain an output variable or coil referring to its name"
+msgstr "Тело перехода \"%s\" должно содержать выходную переменную или катушку, ссылающуюся на его имя"
+
+#: ../dialogs/PouTransitionDialog.py:89
+msgid "Transition Name"
+msgstr "Имя перехода"
+
+#: ../dialogs/PouTransitionDialog.py:58
+msgid "Transition Name:"
+msgstr "Имя перехода:"
+
+#: ../PLCGenerator.py:1609
+#, python-brace-format
+msgid "Transition with content \"{a1}\" not connected to a next step in \"{a2}\" POU"
+msgstr "Переход с содержимым \"{a1}\" не подключен к следующему шагу в POU \"{a2}\""
+
+#: ../PLCGenerator.py:1598
+#, python-brace-format
+msgid "Transition with content \"{a1}\" not connected to a previous step in \"{a2}\" POU"
+msgstr "Переход с содержимым \"{a1}\" не подключен к предыдущему шагу в POU \"{a2}\""
+
+#: ../plcopen/plcopen.py:1318
+#, python-format
+msgid "Transition with name %s doesn't exist!"
+msgstr "Переход с именем %s отсутствует!"
+
+#: ../PLCControler.py:96
+msgid "Transitions"
+msgstr "Переходы"
+
+#: ../dialogs/AboutDialog.py:123
+msgid "Translated by"
+msgstr "Перевод"
+
+#: ../editors/ResourceEditor.py:68
+msgid "Triggering"
+msgstr "Запуск"
+
+#: ../Beremiz_service.py:476
+msgid "Twisted unavailable."
+msgstr "Модуль Twisted недоступен."
+
+#: ../dialogs/ActionBlockDialog.py:38 ../editors/ResourceEditor.py:83
+#: ../editors/DataTypeEditor.py:50 ../controls/VariablePanel.py:53
+#: ../controls/VariablePanel.py:54
+msgid "Type"
+msgstr "Тип"
+
+#: ../dialogs/BrowseLocationsDialog.py:48
+msgid "Type and derivated"
+msgstr "Тип и его производные"
+
+#: ../canfestival/config_utils.py:336 ../canfestival/config_utils.py:624
+#, python-format
+msgid "Type conflict for location \"%s\""
+msgstr "Конфликт типов \"%s\""
+
+#: ../plcopen/iec_std.csv:16
+msgid "Type conversion"
+msgstr "Преобразование типов"
+
+#: ../editors/DataTypeEditor.py:162
+msgid "Type infos:"
+msgstr "Информация о типе:"
+
+#: ../dialogs/BrowseLocationsDialog.py:49
+msgid "Type strict"
+msgstr "Только данный тип"
+
+#: ../dialogs/SFCDivergenceDialog.py:59 ../dialogs/SFCTransitionDialog.py:57
+#: ../dialogs/LDPowerRailDialog.py:56 ../dialogs/BrowseLocationsDialog.py:99
+#: ../dialogs/FBDBlockDialog.py:65 ../dialogs/ConnectionDialog.py:58
+msgid "Type:"
+msgstr "Тип:"
+
+msgid "URI_location"
+msgstr "URI системы исполнения"
+
+#: ../canfestival/config_utils.py:462 ../canfestival/config_utils.py:476
+#, python-format
+msgid "Unable to define PDO mapping for node %02x"
+msgstr "Невозможно определить отображение PDO для узла %02x"
+
+#: ../targets/Xenomai/__init__.py:39
+#, python-format
+msgid "Unable to get Xenomai's %s \n"
+msgstr "Невозможно получить Xenomai %s\n"
+
+#: ../PLCGenerator.py:961 ../PLCGenerator.py:1214
+#, python-brace-format
+msgid "Undefined block type \"{a1}\" in \"{a2}\" POU"
+msgstr "Неопределенный тип блока \"{a1}\" в POU \"{a2}\""
+
+#: ../PLCGenerator.py:254
+#, python-format
+msgid "Undefined pou type \"%s\""
+msgstr "Неопределенный тип POU \"%s\""
+
+#: ../IDEFrame.py:360 ../IDEFrame.py:421
+msgid "Undo"
+msgstr "Отмена"
+
+#: ../ProjectController.py:332
+msgid "Unknown"
+msgstr "Неизвестно"
+
+#: ../editors/Viewer.py:393
+#, python-format
+msgid "Unknown variable \"%s\" for this POU!"
+msgstr "Неизвестная переменная \"%s\" для этого POU!"
+
+#: ../ProjectController.py:329 ../ProjectController.py:330
+msgid "Unnamed"
+msgstr "Unnamed"
+
+#: ../PLCControler.py:636
+#, python-format
+msgid "Unnamed%d"
+msgstr "Unnamed%d"
+
+#: ../controls/VariablePanel.py:284
+#, python-format
+msgid "Unrecognized data size \"%s\""
+msgstr "Неопределенный размер данных \"%s\""
+
+#: ../editors/DataTypeEditor.py:632 ../controls/VariablePanel.py:798
+msgid "User Data Types"
+msgstr "Пользовательские типы данных"
+
+#: ../canfestival/SlaveEditor.py:65 ../canfestival/NetworkEditor.py:86
+msgid "User Type"
+msgstr "Пользовательский тип"
+
+#: ../PLCControler.py:95
+msgid "User-defined POUs"
+msgstr "Пользовательские POU"
+
+#: ../dialogs/ActionBlockDialog.py:38
+msgid "Value"
+msgstr "Значение"
+
+#: ../editors/DataTypeEditor.py:259
+msgid "Values:"
+msgstr "Значения:"
+
+#: ../dialogs/ActionBlockDialog.py:42 ../editors/Viewer.py:526
+#: ../editors/Viewer.py:2374
+msgid "Variable"
+msgstr "Переменная"
+
+#: ../editors/Viewer.py:308 ../editors/Viewer.py:338 ../editors/Viewer.py:360
+#: ../editors/TextViewer.py:292 ../editors/TextViewer.py:343
+#: ../editors/TextViewer.py:366 ../controls/VariablePanel.py:329
+msgid "Variable Drop"
+msgstr "Перетаскивание переменной"
+
+#: ../dialogs/FBDVariableDialog.py:63
+msgid "Variable Properties"
+msgstr "Свойства переменных"
+
+#: ../editors/Viewer.py:288 ../editors/TextViewer.py:306
+#: ../controls/LocationCellEditor.py:97 ../controls/VariablePanel.py:290
+#: ../controls/VariablePanel.py:350
+msgid "Variable class"
+msgstr "Класс переменной"
+
+#: ../editors/Viewer.py:395 ../editors/TextViewer.py:387
+msgid "Variable don't belong to this POU!"
+msgstr "Переменная не принадлежит этому POU!"
+
+#: ../dialogs/LDElementDialog.py:89
+msgid "Variable:"
+msgstr "Переменная:"
+
+#: ../controls/VariablePanel.py:72
+msgid "Variables"
+msgstr "Переменные"
+
+#: ../controls/ProjectPropertiesPanel.py:151
+msgid "Vertical:"
+msgstr "Вертикальный:"
+
+#: ../Beremiz_service.py:586
+msgid "WAMP client startup failed. "
+msgstr "Ошибка импорта WAMP. "
+
+#: ../connectors/WAMP/__init__.py:91
+#, python-format
+msgid "WAMP connecting to URL : %s\n"
+msgstr "WAMP подключение к URI: %s\n"
+
+#: ../connectors/WAMP/__init__.py:131
+msgid "WAMP connection timeout"
+msgstr "Тайм-аут WAMP подключения "
+
+#: ../connectors/WAMP/__init__.py:150
+#, python-format
+msgid "WAMP connection to '%s' failed.\n"
+msgstr "Не удалось установить WAMP подключение к %s.\n"
+
+#: ../Beremiz_service.py:562
+msgid "WAMP import failed :"
+msgstr "Ошибка импорта WAMP :"
+
+#: ../wxglade_hmi/wxglade_hmi.py:35
+msgid "WXGLADE GUI"
+msgstr "WXGLADE GUI"
+
+#: ../dialogs/PouDialog.py:128 ../editors/LDViewer.py:891
+msgid "Warning"
+msgstr "Предупреждение"
+
+#: ../ProjectController.py:616
+msgid "Warnings in ST/IL/SFC code generator :\n"
+msgstr "Предупреждения в ST/IL/SFC коде генераторе:\n"
+
+#: ../dialogs/SearchInProjectDialog.py:78
+msgid "Whole Project"
+msgstr "Целый проект"
+
+#: ../controls/ProjectPropertiesPanel.py:119
+msgid "Width:"
+msgstr "Ширина:"
+
+msgid "Win32"
+msgstr "Win32"
+
+#: ../dialogs/FindInPouDialog.py:93
+msgid "Wrap search"
+msgstr "Продолжить поиск сначала"
+
+#: ../dialogs/AboutDialog.py:122
+msgid "Written by"
+msgstr "Авторы"
+
+#: ../features.py:34
+msgid "WxGlade GUI"
+msgstr "WxGlade GUI"
+
+msgid "XenoConfig"
+msgstr "Настройки Xenomai"
+
+msgid "Xenomai"
+msgstr "Xenomai"
+
+#: ../svgui/svgui.py:139
+msgid ""
+"You don't have write permissions.\n"
+"Open Inkscape anyway ?"
+msgstr ""
+"У вас недостаточно прав для записи.\n"
+"Открыть Inkscape все равно?"
+
+#: ../wxglade_hmi/wxglade_hmi.py:137
+msgid ""
+"You don't have write permissions.\n"
+"Open wxGlade anyway ?"
+msgstr ""
+"У вас недостаточно прав для записи.\n"
+"Открыть wxGlade все равно?"
+
+#: ../ProjectController.py:292
+msgid ""
+"You must have permission to work on the project\n"
+"Work on a project copy ?"
+msgstr ""
+"Вы должны иметь права на запись, чтобы работать с проектом\n"
+"Работать с копией проекта?"
+
+#: ../editors/LDViewer.py:886
+msgid "You must select the block or group of blocks around which a branch should be added!"
+msgstr "Выберите блок или группу блоков, вокруг которых нужно добавить ветвление!"
+
+#: ../editors/LDViewer.py:666
+msgid "You must select the wire where a contact should be added!"
+msgstr "Выберите провод, куда должен быть добавлен контакт!"
+
+#: ../dialogs/SFCStepNameDialog.py:48 ../dialogs/PouNameDialog.py:46
+msgid "You must type a name!"
+msgstr "Введите имя!"
+
+#: ../dialogs/ForceVariableDialog.py:175
+msgid "You must type a value!"
+msgstr "Введите значение!"
+
+#: ../IDEFrame.py:438
+msgid "Zoom"
+msgstr "Приближение"
+
+msgid "class"
+msgstr "класс"
+
+#: ../dialogs/DurationEditorDialog.py:151
+msgid "days"
+msgstr "дни"
+
+msgid "desc"
+msgstr ""
+
+#: ../PLCOpenEditor.py:333
+#, python-format
+msgid "error: %s\n"
+msgstr "ошибка: %s\n"
+
+#: ../util/ProcessLogger.py:169
+#, python-brace-format
+msgid "exited with status {a1} (pid {a2})\n"
+msgstr "завершился с кодом {a1} (pid {a2})\n"
+
+#: ../PLCOpenEditor.py:396 ../PLCOpenEditor.py:398
+msgid "file : "
+msgstr "файл:"
+
+msgid "first input parameter"
+msgstr "первый входной параметр"
+
+msgid "first output parameter"
+msgstr "первый выходной параметр"
+
+#: ../dialogs/PouDialog.py:31
+msgid "function"
+msgstr "функция"
+
+#: ../PLCOpenEditor.py:399
+msgid "function : "
+msgstr "функция: "
+
+#: ../dialogs/PouDialog.py:31
+msgid "functionBlock"
+msgstr "функциональный блок"
+
+#: ../dialogs/DurationEditorDialog.py:151
+msgid "hours"
+msgstr "часы"
+
+msgid "initial"
+msgstr "исходный"
+
+msgid "internal state: 0-reset, 1-counting, 2-set"
+msgstr "состояние: 0 - сброс, 1 - счёт, 2 - установка"
+
+#: ../PLCOpenEditor.py:399
+msgid "line : "
+msgstr "строка:"
+
+#: ../dialogs/DurationEditorDialog.py:153
+msgid "milliseconds"
+msgstr "милисекунды"
+
+#: ../dialogs/DurationEditorDialog.py:152
+msgid "minutes"
+msgstr "минуты"
+
+msgid "name"
+msgstr "имя"
+
+msgid "onchange"
+msgstr ""
+
+msgid "opts"
+msgstr ""
+
+#: ../dialogs/PouDialog.py:31
+msgid "program"
+msgstr "программа"
+
+msgid "second input parameter"
+msgstr "второй входной параметр"
+
+msgid "second output parameter"
+msgstr "второй выходной параметр"
+
+#: ../dialogs/DurationEditorDialog.py:152
+msgid "seconds"
+msgstr "секунды"
+
+#: ../plcopen/iec_std.csv:84
+msgid "string from the middle"
+msgstr "строка из середины"
+
+#: ../plcopen/iec_std.csv:82
+msgid "string left of"
+msgstr "строка слева от "
+
+#: ../plcopen/iec_std.csv:83
+msgid "string right of"
+msgstr "строка справа от "
+
+msgid "type"
+msgstr "тип"
+
+#: ../Beremiz.py:126
+msgid "update info unavailable."
+msgstr "информация об обновлениях недоступна."
+
+msgid "variable"
+msgstr "переменная"
+
+msgid "variables"
+msgstr "переменные"
+
+#: ../PLCOpenEditor.py:331
+#, python-format
+msgid "warning: %s\n"
+msgstr "предупреждение: %s\n"
+
+#: ../PLCControler.py:970
+#, python-brace-format
+msgid "{a1} \"{a2}\" can't be pasted as a {a3}."
+msgstr "{a1} \"{a2}\" не может быть вставлен как {a3}."
+
+#: ../ConfigTreeNode.py:56
+#, python-brace-format
+msgid ""
+"{a1} XML file doesn't follow XSD schema at line %{a2}:\n"
+"{a3}"
+msgstr ""
+"{a1} XML файл не следует XSD-схеме в строке {a2}:\n"
+"{a3}"
+
+#~ msgid ""
+#~ "\n"
+#~ "An error has occurred.\n"
+#~ "\n"
+#~ "Click OK to save an error report.\n"
+#~ "\n"
+#~ "Please be kind enough to send this file to:\n"
+#~ "edouard.tisserant@gmail.com\n"
+#~ "\n"
+#~ "Error:\n"
+#~ msgstr ""
+#~ "\n"
+#~ "Произошла ошибка.\n"
+#~ "\n"
+#~ "Нажмите OK, чтобы сохранить репорт об ошибке.\n"
+#~ "\n"
+#~ "Будьте так добры, пошлите этот файл:\n"
+#~ "edouard.tisserant@gmail.com\n"
+#~ "\n"
+#~ "Ошибка:\n"
+
+#~ msgid " -> Nothing to do\n"
+#~ msgstr " -> Ничего не нужно делать\n"
+
+#~ msgid " : "
+#~ msgstr " : "
+
+#~ msgid "\"%s\" element can't be pasted here!!!"
+#~ msgstr "Элемент \"%s\" не может быть вставлен сюда!!!"
+
+#~ msgid "... debugger recovered\n"
+#~ msgstr "... отладчик восстановлен\n"
+
+#~ msgid "About Beremiz"
+#~ msgstr "О Beremiz"
+
+#~ msgid "About PLCOpenEditor"
+#~ msgstr "О PLCOpenEditor"
+
+#~ msgid "Clear the graph values"
+#~ msgstr "Очистить значения на графике"
+
+#~ msgid ""
+#~ "Derivative\n"
+#~ "The derivative function block produces an output XOUT proportional to the rate of change of the input XIN."
+#~ msgstr ""
+#~ "Производная\n"
+#~ "Функциональный блок формирует выход XOUT пропорционально частоте изменения входа XIN."
+
+#~ msgid "Description"
+#~ msgstr "Описание"
+
+#~ msgid ""
+#~ "Down-counter\n"
+#~ "The down-counter can be used to signal when a count has reached zero, on counting down from a preset value."
+#~ msgstr ""
+#~ "Декрементный счетчик\n"
+#~ "Декрементный счетчик может использоваться, когда необходимо сигнализировать, что счетчик достиг нулевого значения с исходного заданного значения."
+
+#~ msgid "Enable_Native_Library"
+#~ msgstr "Разрешить библиотеку Native"
+
+#~ msgid ""
+#~ "Falling edge detector\n"
+#~ "The output produces a single pulse when a falling edge is detected."
+#~ msgstr ""
+#~ "Детектор падающего фронта\n"
+#~ "На выходе формируется одиночный импульс, если обнаружен падающий фронт."
+
+#~ msgid "Form isn't complete. Pattern to search must be filled!"
+#~ msgstr "Форма заполнена неполностью. Шаблон поиска должен быть заполнен!"
+
+#~ msgid ""
+#~ "Hysteresis\n"
+#~ "The hysteresis function block provides a hysteresis boolean output driven by the difference of two floating point (REAL) inputs XIN1 and XIN2."
+#~ msgstr ""
+#~ "Гистерезис\n"
+#~ "Функциональный блок формирует дискретный выход с гистерезисом в зависимости от разницы двух вещественных входов XIN1 и XIN2."
+
+#~ msgid "IEC-61131-3 code generation failed !\n"
+#~ msgstr "Неудачная генерация МЭК-61131-3 кода!\n"
+
+#~ msgid "In section: "
+#~ msgstr "В секции: "
+
+#~ msgid "Initial"
+#~ msgstr "Исходное значение"
+
+#~ msgid ""
+#~ "Integral\n"
+#~ "The integral function block integrates the value of input XIN over time."
+#~ msgstr ""
+#~ "Интеграл\n"
+#~ "Функциональный блок интегрирует входное значение XIN во времени."
+
+#~ msgid "Move debug variable down"
+#~ msgstr "Переместить отлаживаемую переменную ниже"
+
+#~ msgid "Move debug variable up"
+#~ msgstr "Переместить отлаживаемую переменную выше"
+
+#~ msgid "No PLC project found"
+#~ msgstr "Не найден проект ПЛК"
+
+#~ msgid "No output variable found"
+#~ msgstr "Выходная переменная не найдена"
+
+#~ msgid ""
+#~ "Off-delay timer\n"
+#~ "The off-delay timer can be used to delay setting an output false, for fixed period after input goes false."
+#~ msgstr ""
+#~ "Таймер выключения\n"
+#~ "Таймер выключения может быть использован, чтобы внести задержку установки выхода в FALSE на фиксированный период времени после того, как вход стал FALSE."
+
+#~ msgid ""
+#~ "On-delay timer\n"
+#~ "The on-delay timer can be used to delay setting an output true, for fixed period after an input becomes true."
+#~ msgstr ""
+#~ "Таймер включения\n"
+#~ "Таймер выключения может быть использован, чтобы внести задержку установки выхода в TRUE на фиксированный период времени после того, как вход стал TRUE."
+
+#~ msgid ""
+#~ "PID\n"
+#~ "The PID (proportional, Integral, Derivative) function block provides the classical three term controller for closed loop control."
+#~ msgstr ""
+#~ "ПИД\n"
+#~ "ПИД (Пропорциональный Интегральный Дифференциальный) ФБ - классический регулятор, используемый в системах с обратной связью."
+
+#~ msgid "Position:"
+#~ msgstr "Позиция:"
+
+#~ msgid ""
+#~ "Pulse timer\n"
+#~ "The pulse timer can be used to generate output pulses of a given time duration."
+#~ msgstr ""
+#~ "Генератор импульсов\n"
+#~ "Функциональный блок используется для генерации выходных импульсов заданной длительности."
+
+#~ msgid ""
+#~ "RS bistable\n"
+#~ "The RS bistable is a latch where the Reset dominates."
+#~ msgstr ""
+#~ "RS триггер\n"
+#~ "RS триггер - переключатель с доминантой выключения."
+
+#~ msgid ""
+#~ "Ramp\n"
+#~ "The RAMP function block is modelled on example given in the standard."
+#~ msgstr ""
+#~ "Ограничитель скорости изменения сигнала\n"
+#~ "Функциональный блок написан согласно примеру, приведенному в стандарте."
+
+#~ msgid ""
+#~ "Real time clock\n"
+#~ "The real time clock has many uses including time stamping, setting dates and times of day in batch reports, in alarm messages and so on."
+#~ msgstr ""
+#~ "RTC часы\n"
+#~ "Часы реального времени используется для получения меток времени, установки даты и времени дня в отчетах, сообщениях об авариях и пр."
+
+#~ msgid "Remove debug variable"
+#~ msgstr "Удалить отлаживаемую переменную"
+
+#~ msgid "Reset zoom and offset"
+#~ msgstr "Сбросить приближение и смещение"
+
+#~ msgid ""
+#~ "Rising edge detector\n"
+#~ "The output produces a single pulse when a rising edge is detected."
+#~ msgstr ""
+#~ "Детектор нарастающего фронта\n"
+#~ "На выходе формируется одиночный импульс, если обнаружен нарастающий фронт."
+
+#~ msgid ""
+#~ "SR bistable\n"
+#~ "The SR bistable is a latch where the Set dominates."
+#~ msgstr ""
+#~ "SR триггер\n"
+#~ "SR триггер - переключатель с доминантой включения."
+
+#~ msgid ""
+#~ "Semaphore\n"
+#~ "The semaphore provides a mechanism to allow software elements mutually exclusive access to certain ressources."
+#~ msgstr ""
+#~ "Семафор\n"
+#~ "Семафор предоставляет собой программный механизм синхронизации для обеспечения исключительного доступа к определенным ресурсам."
+
+#~ msgid "Tick"
+#~ msgstr "Тик"
+
+#~ msgid ""
+#~ "Up-counter\n"
+#~ "The up-counter can be used to signal when a count has reached a maximum value."
+#~ msgstr ""
+#~ "Инкрементный счетчик\n"
+#~ "Инкрементный счетчик может использоваться, когда необходимо сигнализировать, что счетчик достиг максимального значения."
+
+#~ msgid ""
+#~ "Up-down counter\n"
+#~ "The up-down counter has two inputs CU and CD. It can be used to both count up on one input and down on the other."
+#~ msgstr ""
+#~ "Инкрементный/декрементный счетчик\n"
+#~ "Инкрементный/декрементный счетчик имеет два входа CU и CD. Он может использоваться для счета вверх по одному входу и для счета низ по другому."
+
+#~ msgid "Values"
+#~ msgstr "Значения"
+
+#~ msgid "Waiting debugger to recover...\n"
+#~ msgstr "Ожидание восстановления отладчика...\n"
+
+#~ msgid "Zoom:"
+#~ msgstr "Приближение:"
+
+#~ msgid "about.html"
+#~ msgstr "about.ru.html"
+
+#~ msgid "plcopen_about.html"
+#~ msgstr "plcopen_about.ru.html"
diff -r a375e31bf312 -r c1298e7ffe3a i18n/app.fil
--- a/i18n/app.fil Sun Mar 05 00:38:25 2017 +0000
+++ b/i18n/app.fil Fri Mar 24 12:07:47 2017 +0000
@@ -1,94 +1,120 @@
-../runtime/ServicePublisher.py
-../runtime/PLCObject.py
+../canfestival/canfestival.py
../canfestival/SlaveEditor.py
../canfestival/config_utils.py
-../canfestival/canfestival.py
../canfestival/NetworkEditor.py
-../Beremiz_service.py
+../dialogs/LDElementDialog.py
+../dialogs/ForceVariableDialog.py
+../dialogs/SearchInProjectDialog.py
+../dialogs/SFCStepDialog.py
+../dialogs/SFCStepNameDialog.py
+../dialogs/FindInPouDialog.py
+../dialogs/SFCDivergenceDialog.py
+../dialogs/SFCTransitionDialog.py
+../dialogs/DurationEditorDialog.py
+../dialogs/PouTransitionDialog.py
+../dialogs/FBDVariableDialog.py
+../dialogs/BlockPreviewDialog.py
+../dialogs/AboutDialog.py
+../dialogs/ProjectDialog.py
+../dialogs/LDPowerRailDialog.py
+../dialogs/ArrayTypeDialog.py
+../dialogs/PouNameDialog.py
+../dialogs/BrowseLocationsDialog.py
+../dialogs/FBDBlockDialog.py
+../dialogs/ConnectionDialog.py
+../dialogs/BrowseValuesLibraryDialog.py
+../dialogs/ActionBlockDialog.py
+../dialogs/PouActionDialog.py
+../dialogs/DiscoveryDialog.py
+../dialogs/PouDialog.py
+../graphics/RubberBand.py
+../graphics/FBD_Objects.py
+../graphics/DebugDataConsumer.py
+../graphics/ToolTipProducer.py
+../graphics/LD_Objects.py
+../graphics/SFC_Objects.py
+../graphics/GraphicCommons.py
+../connectors/PYRO/__init__.py
+../connectors/__init__.py
+../connectors/WAMP/__init__.py
+../targets/Generic/XSD
+../targets/XSD_toolchain_makefile
+../targets/Xenomai/__init__.py
+../targets/Xenomai/XSD
+../targets/XSD_toolchain_gcc
+../targets/PLC/XSD
+../targets/__init__.py
+../targets/toolchain_gcc.py
+../targets/toolchain_makefile.py
+../targets/Linux/XSD
+../targets/Win32/XSD
+../PLCControler.py
+../PLCOpenEditor.py
+../py_ext/PythonEditor.py
+../py_ext/PythonFileCTNMixin.py
+../wxglade_hmi/wxglade_hmi.py
+../runtime/NevowServer.py
+../runtime/PLCObject.py
+../runtime/ServicePublisher.py
+../ConfigTreeNode.py
+../editors/ConfTreeNodeEditor.py
+../editors/ResourceEditor.py
+../editors/Viewer.py
+../editors/LDViewer.py
+../editors/DataTypeEditor.py
+../editors/IECCodeViewer.py
+../editors/TextViewer.py
+../editors/ProjectNodeEditor.py
+../editors/EditorPanel.py
+../editors/DebugViewer.py
+../editors/SFCViewer.py
+../editors/FileManagementPanel.py
+../editors/CodeFileEditor.py
+../ProjectController.py
../controls/LocationCellEditor.py
-../controls/CustomTree.py
+../controls/SearchResultPanel.py
+../controls/PouInstanceVariablesPanel.py
+../controls/CustomTable.py
+../controls/LibraryPanel.py
+../controls/CustomToolTip.py
+../controls/LogViewer.py
+../controls/FolderTree.py
+../controls/ProjectPropertiesPanel.py
+../controls/DebugVariablePanel/DebugVariablePanel.py
+../controls/DebugVariablePanel/DebugVariableViewer.py
+../controls/DebugVariablePanel/DebugVariableTextViewer.py
+../controls/DebugVariablePanel/DebugVariableGraphicViewer.py
+../controls/DebugVariablePanel/GraphButton.py
+../controls/DebugVariablePanel/DebugVariableItem.py
+../controls/TextCtrlAutoComplete.py
+../controls/DurationCellEditor.py
+../controls/CustomStyledTextCtrl.py
../controls/VariablePanel.py
../controls/CustomGrid.py
-../controls/SearchResultPanel.py
-../controls/LibraryPanel.py
-../controls/TextCtrlAutoComplete.py
-../controls/DebugVariablePanel.py
-../controls/PouInstanceVariablesPanel.py
-../controls/DurationCellEditor.py
-../controls/CustomTable.py
+../controls/CustomTree.py
../controls/CustomEditableListBox.py
-../controls/ProjectPropertiesPanel.py
-../IDEFrame.py
+../CodeFileTreeNode.py
+../docutil/dochtml.py
+../c_ext/CFileEditor.py
+../xmlclass/xsdschema.py
+../xmlclass/xmlclass.py
../Beremiz.py
+../version.py
+../POULibrary.py
+../util/MiniTextControler.py
+../util/Zeroconf.py
+../util/misc.py
+../util/ProcessLogger.py
+../features.py
../svgui/svgui.py
../svgui/svgui_server.py
../svgui/svguilib.py
-../xmlclass/xmlclass.py
-../xmlclass/xsdschema.py
-../PLCOpenEditor.py
-../c_ext/CFileEditor.py
-../c_ext/c_ext.py
-../ConfigTreeNode.py
-../wxglade_hmi/wxglade_hmi.py
-../PLCGenerator.py
-../docutil/dochtml.py
-../editors/ProjectNodeEditor.py
-../editors/ConfTreeNodeEditor.py
-../editors/TextViewer.py
-../editors/DataTypeEditor.py
-../editors/GraphicViewer.py
-../editors/ResourceEditor.py
-../editors/Viewer.py
-../editors/LDViewer.py
-../editors/SFCViewer.py
-../editors/EditorPanel.py
-../editors/FileManagementPanel.py
-../graphics/GraphicCommons.py
-../graphics/LD_Objects.py
-../graphics/SFC_Objects.py
-../graphics/FBD_Objects.py
-../PLCControler.py
-../connectors/__init__.py
-../connectors/PYRO/__init__.py
-../targets/toolchain_gcc.py
-../targets/__init__.py
-../targets/Linux/XSD
-../targets/XSD_toolchain_gcc
-../targets/Win32/XSD
-../targets/Xenomai/__init__.py
-../targets/Xenomai/XSD
-../features.py
-../ProjectController.py
-../POULibrary.py
-../dialogs/PouNameDialog.py
-../dialogs/SFCDivergenceDialog.py
-../dialogs/LDPowerRailDialog.py
-../dialogs/PouTransitionDialog.py
-../dialogs/BrowseLocationsDialog.py
-../dialogs/DiscoveryDialog.py
-../dialogs/ProjectDialog.py
-../dialogs/SFCStepNameDialog.py
-../dialogs/ConnectionDialog.py
-../dialogs/FBDVariableDialog.py
-../dialogs/PouActionDialog.py
-../dialogs/BrowseValuesLibraryDialog.py
-../dialogs/PouDialog.py
-../dialogs/ActionBlockDialog.py
-../dialogs/SFCTransitionDialog.py
-../dialogs/LDElementDialog.py
-../dialogs/DurationEditorDialog.py
-../dialogs/FindInPouDialog.py
-../dialogs/SearchInProjectDialog.py
-../dialogs/SFCStepDialog.py
-../dialogs/ArrayTypeDialog.py
-../dialogs/FBDBlockDialog.py
-../dialogs/ForceVariableDialog.py
-../util/ProcessLogger.py
-../util/MiniTextControler.py
-../util/Zeroconf.py
-../util/misc.py
../plcopen/iec_std.csv
../plcopen/structures.py
../plcopen/plcopen.py
-../py_ext/PythonFileCTNMixin.py
-../py_ext/PythonEditor.py
+../plcopen/definitions.py
+../IDEFrame.py
+../PLCGenerator.py
+../Beremiz_service.py
+../plcopen/Additional_Function_Blocks.xml
+../plcopen/Standard_Function_Blocks.xml
\ No newline at end of file
diff -r a375e31bf312 -r c1298e7ffe3a i18n/messages.pot
--- a/i18n/messages.pot Sun Mar 05 00:38:25 2017 +0000
+++ b/i18n/messages.pot Fri Mar 24 12:07:47 2017 +0000
@@ -8,7 +8,7 @@
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2013-03-26 22:55+0100\n"
+"POT-Creation-Date: 2017-01-12 14:39+0300\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME \n"
"Language-Team: LANGUAGE \n"
@@ -17,20 +17,7 @@
"Content-Type: text/plain; charset=CHARSET\n"
"Content-Transfer-Encoding: 8bit\n"
-#: ../PLCOpenEditor.py:405
-msgid ""
-"\n"
-"An error has occurred.\n"
-"\n"
-"Click OK to save an error report.\n"
-"\n"
-"Please be kind enough to send this file to:\n"
-"edouard.tisserant@gmail.com\n"
-"\n"
-"Error:\n"
-msgstr ""
-
-#: ../Beremiz.py:1119
+#: ../PLCOpenEditor.py:408 ../Beremiz.py:1191
#, python-format
msgid ""
"\n"
@@ -40,367 +27,398 @@
"Please be kind enough to send this file to:\n"
"beremiz-devel@lists.sourceforge.net\n"
"\n"
-"You should now restart Beremiz.\n"
+"You should now restart program.\n"
"\n"
"Traceback:\n"
msgstr ""
-#: ../controls/VariablePanel.py:77
+#: ../controls/VariablePanel.py:72
msgid " External"
msgstr ""
-#: ../controls/VariablePanel.py:76
+#: ../controls/VariablePanel.py:71
msgid " InOut"
msgstr ""
-#: ../controls/VariablePanel.py:76
+#: ../controls/VariablePanel.py:71
msgid " Input"
msgstr ""
-#: ../controls/VariablePanel.py:77
+#: ../controls/VariablePanel.py:72
msgid " Local"
msgstr ""
-#: ../controls/VariablePanel.py:76
+#: ../controls/VariablePanel.py:71
msgid " Output"
msgstr ""
-#: ../controls/VariablePanel.py:78
+#: ../controls/VariablePanel.py:73
msgid " Temp"
msgstr ""
-#: ../PLCOpenEditor.py:415
-msgid " : "
-msgstr ""
-
-#: ../dialogs/PouTransitionDialog.py:94 ../dialogs/PouActionDialog.py:91
-#: ../dialogs/PouDialog.py:111 ../dialogs/SFCTransitionDialog.py:144
+#: ../dialogs/PouTransitionDialog.py:99 ../dialogs/ProjectDialog.py:66
+#: ../dialogs/PouActionDialog.py:91 ../dialogs/PouDialog.py:113
#, python-format
msgid " and %s"
msgstr ""
-#: ../ProjectController.py:917
+#: ../ProjectController.py:1089
msgid " generation failed !\n"
msgstr ""
-#: ../plcopen/plcopen.py:1051
+#: ../plcopen/plcopen.py:881
#, python-format
msgid "\"%s\" Data Type doesn't exist !!!"
msgstr ""
-#: ../plcopen/plcopen.py:1069
+#: ../plcopen/plcopen.py:899
#, python-format
msgid "\"%s\" POU already exists !!!"
msgstr ""
-#: ../plcopen/plcopen.py:1090
+#: ../plcopen/plcopen.py:920
#, python-format
msgid "\"%s\" POU doesn't exist !!!"
msgstr ""
-#: ../editors/Viewer.py:234
+#: ../editors/Viewer.py:246
#, python-format
msgid "\"%s\" can't use itself!"
msgstr ""
-#: ../IDEFrame.py:1587 ../IDEFrame.py:1606
+#: ../IDEFrame.py:1652 ../IDEFrame.py:1671
#, python-format
msgid "\"%s\" config already exists!"
msgstr ""
-#: ../plcopen/plcopen.py:315
+#: ../plcopen/plcopen.py:467
#, python-format
msgid "\"%s\" configuration already exists !!!"
msgstr ""
-#: ../IDEFrame.py:1541
+#: ../IDEFrame.py:1602
#, python-format
msgid "\"%s\" data type already exists!"
msgstr ""
-#: ../PLCControler.py:2165 ../PLCControler.py:2169
-#, python-format
-msgid "\"%s\" element can't be pasted here!!!"
-msgstr ""
-
-#: ../editors/TextViewer.py:298 ../editors/TextViewer.py:318
-#: ../editors/Viewer.py:250 ../dialogs/PouTransitionDialog.py:105
-#: ../dialogs/ConnectionDialog.py:157 ../dialogs/PouActionDialog.py:102
-#: ../dialogs/FBDBlockDialog.py:162
+#: ../dialogs/PouTransitionDialog.py:110 ../dialogs/BlockPreviewDialog.py:219
+#: ../dialogs/PouActionDialog.py:102 ../editors/Viewer.py:262
+#: ../editors/Viewer.py:330 ../editors/Viewer.py:354 ../editors/Viewer.py:374
+#: ../editors/TextViewer.py:272 ../editors/TextViewer.py:301
+#: ../controls/VariablePanel.py:396
#, python-format
msgid "\"%s\" element for this pou already exists!"
msgstr ""
-#: ../Beremiz.py:921
+#: ../Beremiz.py:994
#, python-format
msgid "\"%s\" folder is not a valid Beremiz project\n"
msgstr ""
-#: ../plcopen/structures.py:105
-#, python-format
-msgid "\"%s\" function cancelled in \"%s\" POU: No input connected"
-msgstr ""
-
-#: ../controls/VariablePanel.py:659 ../IDEFrame.py:1532
-#: ../editors/DataTypeEditor.py:554 ../editors/DataTypeEditor.py:583
-#: ../dialogs/PouNameDialog.py:49 ../dialogs/PouTransitionDialog.py:101
-#: ../dialogs/SFCStepNameDialog.py:51 ../dialogs/ConnectionDialog.py:153
-#: ../dialogs/FBDVariableDialog.py:199 ../dialogs/PouActionDialog.py:98
-#: ../dialogs/PouDialog.py:118 ../dialogs/SFCStepDialog.py:122
-#: ../dialogs/FBDBlockDialog.py:158
+#: ../dialogs/SFCStepNameDialog.py:52 ../dialogs/PouTransitionDialog.py:106
+#: ../dialogs/BlockPreviewDialog.py:207 ../dialogs/PouNameDialog.py:50
+#: ../dialogs/PouActionDialog.py:98 ../dialogs/PouDialog.py:120
+#: ../editors/DataTypeEditor.py:555 ../editors/DataTypeEditor.py:584
+#: ../editors/CodeFileEditor.py:770 ../controls/VariablePanel.py:751
+#: ../IDEFrame.py:1593
#, python-format
msgid "\"%s\" is a keyword. It can't be used!"
msgstr ""
-#: ../editors/Viewer.py:238
-#, python-format
-msgid "\"%s\" is already used by \"%s\"!"
-msgstr ""
-
-#: ../plcopen/plcopen.py:2836
+#: ../plcopen/plcopen.py:2412
#, python-format
msgid "\"%s\" is an invalid value!"
msgstr ""
-#: ../PLCOpenEditor.py:341 ../PLCOpenEditor.py:378
+#: ../PLCOpenEditor.py:339 ../PLCOpenEditor.py:381
#, python-format
msgid "\"%s\" is not a valid folder!"
msgstr ""
-#: ../controls/VariablePanel.py:657 ../IDEFrame.py:1530
-#: ../editors/DataTypeEditor.py:578 ../dialogs/PouNameDialog.py:47
-#: ../dialogs/PouTransitionDialog.py:99 ../dialogs/SFCStepNameDialog.py:49
-#: ../dialogs/ConnectionDialog.py:151 ../dialogs/PouActionDialog.py:96
-#: ../dialogs/PouDialog.py:116 ../dialogs/SFCStepDialog.py:120
-#: ../dialogs/FBDBlockDialog.py:156
+#: ../dialogs/SFCStepNameDialog.py:50 ../dialogs/PouTransitionDialog.py:104
+#: ../dialogs/BlockPreviewDialog.py:203 ../dialogs/PouNameDialog.py:48
+#: ../dialogs/PouActionDialog.py:96 ../dialogs/PouDialog.py:118
+#: ../editors/DataTypeEditor.py:579 ../editors/CodeFileEditor.py:768
+#: ../controls/VariablePanel.py:749 ../IDEFrame.py:1591
#, python-format
msgid "\"%s\" is not a valid identifier!"
msgstr ""
-#: ../IDEFrame.py:221 ../IDEFrame.py:2313 ../IDEFrame.py:2332
-#, python-format
-msgid "\"%s\" is used by one or more POUs. It can't be removed!"
-msgstr ""
-
-#: ../controls/VariablePanel.py:313 ../IDEFrame.py:1550
-#: ../editors/TextViewer.py:296 ../editors/TextViewer.py:316
-#: ../editors/TextViewer.py:353 ../editors/Viewer.py:248
-#: ../editors/Viewer.py:293 ../editors/Viewer.py:311
-#: ../dialogs/ConnectionDialog.py:155 ../dialogs/PouDialog.py:120
-#: ../dialogs/FBDBlockDialog.py:160
+#: ../IDEFrame.py:2396
+#, python-format
+msgid "\"%s\" is used by one or more POUs. Do you wish to continue?"
+msgstr ""
+
+#: ../dialogs/BlockPreviewDialog.py:211 ../dialogs/PouDialog.py:122
+#: ../editors/Viewer.py:260 ../editors/Viewer.py:315 ../editors/Viewer.py:345
+#: ../editors/Viewer.py:367 ../editors/TextViewer.py:270
+#: ../editors/TextViewer.py:299 ../editors/TextViewer.py:350
+#: ../editors/TextViewer.py:373 ../controls/VariablePanel.py:338
+#: ../IDEFrame.py:1611
#, python-format
msgid "\"%s\" pou already exists!"
msgstr ""
-#: ../plcopen/plcopen.py:346
-#, python-format
-msgid "\"%s\" resource already exists in \"%s\" configuration !!!"
-msgstr ""
-
-#: ../plcopen/plcopen.py:362
-#, python-format
-msgid "\"%s\" resource doesn't exist in \"%s\" configuration !!!"
-msgstr ""
-
-#: ../dialogs/SFCStepNameDialog.py:57 ../dialogs/SFCStepDialog.py:128
+#: ../dialogs/SFCStepNameDialog.py:58
#, python-format
msgid "\"%s\" step already exists!"
msgstr ""
-#: ../editors/DataTypeEditor.py:549
+#: ../editors/DataTypeEditor.py:550
#, python-format
msgid "\"%s\" value already defined!"
msgstr ""
-#: ../editors/DataTypeEditor.py:744 ../dialogs/ArrayTypeDialog.py:97
+#: ../dialogs/ArrayTypeDialog.py:97 ../editors/DataTypeEditor.py:745
#, python-format
msgid "\"%s\" value isn't a valid array dimension!"
msgstr ""
-#: ../editors/DataTypeEditor.py:751 ../dialogs/ArrayTypeDialog.py:103
+#: ../dialogs/ArrayTypeDialog.py:103 ../editors/DataTypeEditor.py:752
#, python-format
msgid ""
"\"%s\" value isn't a valid array dimension!\n"
"Right value must be greater than left value."
msgstr ""
-#: ../PLCControler.py:847
-#, python-format
-msgid "%s \"%s\" can't be pasted as a %s."
-msgstr ""
-
-#: ../PLCControler.py:1476
+#: ../PLCGenerator.py:1101
+#, python-brace-format
+msgid "\"{a1}\" function cancelled in \"{a2}\" POU: No input connected"
+msgstr ""
+
+#: ../editors/Viewer.py:250
+#, python-brace-format
+msgid "\"{a1}\" is already used by \"{a2}\"!"
+msgstr ""
+
+#: ../plcopen/plcopen.py:491
+#, python-brace-format
+msgid "\"{a1}\" resource already exists in \"{a2}\" configuration !!!"
+msgstr ""
+
+#: ../plcopen/plcopen.py:509
+#, python-brace-format
+msgid "\"{a1}\" resource doesn't exist in \"{a2}\" configuration !!!"
+msgstr ""
+
+#: ../controls/DebugVariablePanel/DebugVariablePanel.py:578
+#, python-format
+msgid "%03gms"
+msgstr ""
+
+#: ../controls/DebugVariablePanel/DebugVariablePanel.py:569
+#, python-format
+msgid "%dd"
+msgstr ""
+
+#: ../controls/DebugVariablePanel/DebugVariablePanel.py:56
+#: ../controls/DebugVariablePanel/DebugVariablePanel.py:570
+#, python-format
+msgid "%dh"
+msgstr ""
+
+#: ../controls/DebugVariablePanel/DebugVariablePanel.py:55
+#: ../controls/DebugVariablePanel/DebugVariablePanel.py:571
+#, python-format
+msgid "%dm"
+msgstr ""
+
+#: ../controls/DebugVariablePanel/DebugVariablePanel.py:53
+#, python-format
+msgid "%dms"
+msgstr ""
+
+#: ../controls/DebugVariablePanel/DebugVariablePanel.py:54
+#: ../controls/DebugVariablePanel/DebugVariablePanel.py:572
+#, python-format
+msgid "%ds"
+msgstr ""
+
+#: ../PLCControler.py:1531
#, python-format
msgid "%s Data Types"
msgstr ""
-#: ../editors/GraphicViewer.py:278
-#, python-format
-msgid "%s Graphics"
-msgstr ""
-
-#: ../PLCControler.py:1471
+#: ../PLCControler.py:1514
#, python-format
msgid "%s POUs"
msgstr ""
-#: ../canfestival/SlaveEditor.py:46 ../canfestival/NetworkEditor.py:67
+#: ../canfestival/SlaveEditor.py:69 ../canfestival/NetworkEditor.py:90
#, python-format
msgid "%s Profile"
msgstr ""
-#: ../plcopen/plcopen.py:1790 ../plcopen/plcopen.py:1800
-#: ../plcopen/plcopen.py:1810 ../plcopen/plcopen.py:1820
-#: ../plcopen/plcopen.py:1829
+#: ../plcopen/plcopen.py:1645 ../plcopen/plcopen.py:1652
+#: ../plcopen/plcopen.py:1664 ../plcopen/plcopen.py:1672
+#: ../plcopen/plcopen.py:1682
#, python-format
msgid "%s body don't have instances!"
msgstr ""
-#: ../plcopen/plcopen.py:1852 ../plcopen/plcopen.py:1859
+#: ../plcopen/plcopen.py:1700 ../plcopen/plcopen.py:1707
+#: ../plcopen/plcopen.py:1714
#, python-format
msgid "%s body don't have text!"
msgstr ""
-#: ../IDEFrame.py:369
+#: ../IDEFrame.py:386
msgid "&Add Element"
msgstr ""
-#: ../IDEFrame.py:339
+#: ../dialogs/AboutDialog.py:65 ../dialogs/AboutDialog.py:113
+#: ../dialogs/AboutDialog.py:150
+msgid "&Close"
+msgstr ""
+
+#: ../IDEFrame.py:356
msgid "&Configuration"
msgstr ""
-#: ../IDEFrame.py:330
+#: ../IDEFrame.py:345
msgid "&Data Type"
msgstr ""
-#: ../IDEFrame.py:373
+#: ../IDEFrame.py:390
msgid "&Delete"
msgstr ""
-#: ../IDEFrame.py:322
+#: ../IDEFrame.py:337
msgid "&Display"
msgstr ""
-#: ../IDEFrame.py:321
+#: ../IDEFrame.py:336
msgid "&Edit"
msgstr ""
-#: ../IDEFrame.py:320
+#: ../IDEFrame.py:335
msgid "&File"
msgstr ""
-#: ../IDEFrame.py:332
+#: ../IDEFrame.py:347
msgid "&Function"
msgstr ""
-#: ../IDEFrame.py:323
+#: ../IDEFrame.py:338
msgid "&Help"
msgstr ""
-#: ../IDEFrame.py:336
+#: ../dialogs/AboutDialog.py:64
+msgid "&License"
+msgstr ""
+
+#: ../IDEFrame.py:351
msgid "&Program"
msgstr ""
-#: ../PLCOpenEditor.py:129
+#: ../PLCOpenEditor.py:125
msgid "&Properties"
msgstr ""
-#: ../Beremiz.py:312
+#: ../Beremiz.py:324
msgid "&Recent Projects"
msgstr ""
-#: ../Beremiz.py:354
+#: ../IDEFrame.py:353
msgid "&Resource"
msgstr ""
-#: ../controls/SearchResultPanel.py:252
-#, python-format
-msgid "'%s' - %d match in project"
-msgstr ""
-
-#: ../controls/SearchResultPanel.py:254
-#, python-format
-msgid "'%s' - %d matches in project"
-msgstr ""
-
-#: ../connectors/PYRO/__init__.py:51
-#, python-format
-msgid "'%s' is located at %s\n"
-msgstr ""
-
-#: ../controls/SearchResultPanel.py:304
+#: ../controls/SearchResultPanel.py:239
+#, python-brace-format
+msgid "'{a1}' - {a2} match in project"
+msgstr ""
+
+#: ../controls/SearchResultPanel.py:241
+#, python-brace-format
+msgid "'{a1}' - {a2} matches in project"
+msgstr ""
+
+#: ../connectors/PYRO/__init__.py:90
+#, python-brace-format
+msgid "'{a1}' is located at {a2}\n"
+msgstr ""
+
+#: ../controls/SearchResultPanel.py:291
#, python-format
msgid "(%d matches)"
msgstr ""
-#: ../PLCOpenEditor.py:393 ../PLCOpenEditor.py:395 ../PLCOpenEditor.py:396
+#: ../PLCOpenEditor.py:396 ../PLCOpenEditor.py:398 ../PLCOpenEditor.py:399
msgid ", "
msgstr ""
-#: ../dialogs/PouTransitionDialog.py:96 ../dialogs/PouActionDialog.py:93
-#: ../dialogs/PouDialog.py:113 ../dialogs/SFCTransitionDialog.py:146
+#: ../dialogs/PouTransitionDialog.py:101 ../dialogs/PouActionDialog.py:93
+#: ../dialogs/PouDialog.py:115
#, python-format
msgid ", %s"
msgstr ""
-#: ../PLCOpenEditor.py:391
+#: ../PLCOpenEditor.py:394
msgid ". "
msgstr ""
-#: ../ProjectController.py:1294
-msgid "... debugger recovered\n"
-msgstr ""
-
-#: ../IDEFrame.py:1553 ../IDEFrame.py:1595 ../IDEFrame.py:1614
-#: ../dialogs/PouDialog.py:122
+#: ../controls/LogViewer.py:279
+msgid "1d"
+msgstr ""
+
+#: ../controls/LogViewer.py:280
+msgid "1h"
+msgstr ""
+
+#: ../controls/LogViewer.py:281
+msgid "1m"
+msgstr ""
+
+#: ../controls/LogViewer.py:282
+msgid "1s"
+msgstr ""
+
+#: ../dialogs/PouDialog.py:124 ../IDEFrame.py:1614 ../IDEFrame.py:1660
+#: ../IDEFrame.py:1679
#, python-format
msgid "A POU has an element named \"%s\". This could cause a conflict. Do you wish to continue?"
msgstr ""
-#: ../controls/VariablePanel.py:661 ../IDEFrame.py:1565 ../IDEFrame.py:1576
-#: ../dialogs/PouNameDialog.py:51 ../dialogs/PouTransitionDialog.py:103
-#: ../dialogs/SFCStepNameDialog.py:53 ../dialogs/PouActionDialog.py:100
-#: ../dialogs/SFCStepDialog.py:124
+#: ../dialogs/SFCStepNameDialog.py:54 ../dialogs/PouTransitionDialog.py:108
+#: ../dialogs/PouNameDialog.py:52 ../dialogs/PouActionDialog.py:100
+#: ../controls/VariablePanel.py:753 ../IDEFrame.py:1628 ../IDEFrame.py:1641
#, python-format
msgid "A POU named \"%s\" already exists!"
msgstr ""
-#: ../ConfigTreeNode.py:388
-#, python-format
-msgid "A child named \"%s\" already exist -> \"%s\"\n"
-msgstr ""
-
-#: ../dialogs/BrowseLocationsDialog.py:212
+#: ../ConfigTreeNode.py:424
+#, python-brace-format
+msgid "A child named \"{a1}\" already exists -> \"{a2}\"\n"
+msgstr ""
+
+#: ../dialogs/BrowseLocationsDialog.py:216
msgid "A location must be selected!"
msgstr ""
-#: ../controls/VariablePanel.py:663 ../IDEFrame.py:1567 ../IDEFrame.py:1578
-#: ../dialogs/SFCStepNameDialog.py:55 ../dialogs/SFCStepDialog.py:126
+#: ../dialogs/SFCStepNameDialog.py:56 ../controls/VariablePanel.py:755
+#: ../IDEFrame.py:1630 ../IDEFrame.py:1643
#, python-format
msgid "A variable with \"%s\" as name already exists in this pou!"
msgstr ""
-#: ../Beremiz.py:364 ../PLCOpenEditor.py:162
+#: ../editors/CodeFileEditor.py:774
+#, python-format
+msgid "A variable with \"%s\" as name already exists!"
+msgstr ""
+
+#: ../dialogs/AboutDialog.py:40 ../PLCOpenEditor.py:158 ../Beremiz.py:381
msgid "About"
msgstr ""
-#: ../Beremiz.py:957
-msgid "About Beremiz"
-msgstr ""
-
-#: ../PLCOpenEditor.py:355
-msgid "About PLCOpenEditor"
-msgstr ""
-
#: ../plcopen/iec_std.csv:22
msgid "Absolute number"
msgstr ""
-#: ../dialogs/ActionBlockDialog.py:41 ../dialogs/SFCStepDialog.py:69
+#: ../dialogs/SFCStepDialog.py:72 ../dialogs/ActionBlockDialog.py:42
msgid "Action"
msgstr ""
-#: ../editors/Viewer.py:494
+#: ../editors/Viewer.py:555 ../editors/Viewer.py:2345
msgid "Action Block"
msgstr ""
@@ -412,109 +430,109 @@
msgid "Action Name:"
msgstr ""
-#: ../plcopen/plcopen.py:1490
+#: ../plcopen/plcopen.py:1359
#, python-format
msgid "Action with name %s doesn't exist!"
msgstr ""
-#: ../PLCControler.py:95
+#: ../PLCControler.py:96
msgid "Actions"
msgstr ""
-#: ../dialogs/ActionBlockDialog.py:134
+#: ../dialogs/ActionBlockDialog.py:133
msgid "Actions:"
msgstr ""
-#: ../editors/Viewer.py:999
+#: ../editors/Viewer.py:1100
msgid "Active"
msgstr ""
-#: ../canfestival/SlaveEditor.py:57 ../canfestival/NetworkEditor.py:78
-#: ../Beremiz.py:987 ../editors/Viewer.py:527
+#: ../canfestival/SlaveEditor.py:80 ../canfestival/NetworkEditor.py:101
+#: ../editors/Viewer.py:588 ../Beremiz.py:1060
msgid "Add"
msgstr ""
-#: ../IDEFrame.py:1801 ../IDEFrame.py:1832
+#: ../IDEFrame.py:1890 ../IDEFrame.py:1925
msgid "Add Action"
msgstr ""
-#: ../features.py:8
+#: ../features.py:32
msgid "Add C code accessing located variables synchronously"
msgstr ""
-#: ../IDEFrame.py:1784
+#: ../IDEFrame.py:1873
msgid "Add Configuration"
msgstr ""
-#: ../IDEFrame.py:1764
+#: ../IDEFrame.py:1853
msgid "Add DataType"
msgstr ""
-#: ../editors/Viewer.py:452
+#: ../editors/Viewer.py:513
msgid "Add Divergence Branch"
msgstr ""
-#: ../dialogs/DiscoveryDialog.py:115
+#: ../dialogs/DiscoveryDialog.py:116
msgid "Add IP"
msgstr ""
-#: ../IDEFrame.py:1772
+#: ../IDEFrame.py:1861
msgid "Add POU"
msgstr ""
-#: ../features.py:9
+#: ../features.py:33
msgid "Add Python code executed asynchronously"
msgstr ""
-#: ../IDEFrame.py:1812 ../IDEFrame.py:1858
+#: ../IDEFrame.py:1901 ../IDEFrame.py:1951
msgid "Add Resource"
msgstr ""
-#: ../IDEFrame.py:1790 ../IDEFrame.py:1829
+#: ../IDEFrame.py:1879 ../IDEFrame.py:1922
msgid "Add Transition"
msgstr ""
-#: ../editors/Viewer.py:441
+#: ../editors/Viewer.py:500
msgid "Add Wire Segment"
msgstr ""
-#: ../editors/SFCViewer.py:359
+#: ../editors/SFCViewer.py:433
msgid "Add a new initial step"
msgstr ""
-#: ../editors/Viewer.py:2363 ../editors/SFCViewer.py:696
+#: ../editors/Viewer.py:2706 ../editors/SFCViewer.py:770
msgid "Add a new jump"
msgstr ""
-#: ../editors/SFCViewer.py:381
+#: ../editors/SFCViewer.py:455
msgid "Add a new step"
msgstr ""
-#: ../features.py:10
+#: ../features.py:34
msgid "Add a simple WxGlade based GUI."
msgstr ""
-#: ../dialogs/ActionBlockDialog.py:138
+#: ../dialogs/ActionBlockDialog.py:137
msgid "Add action"
msgstr ""
-#: ../editors/DataTypeEditor.py:351
+#: ../editors/DataTypeEditor.py:352
msgid "Add element"
msgstr ""
-#: ../editors/ResourceEditor.py:259
+#: ../editors/ResourceEditor.py:268
msgid "Add instance"
msgstr ""
-#: ../canfestival/NetworkEditor.py:80
+#: ../canfestival/NetworkEditor.py:103
msgid "Add slave"
msgstr ""
-#: ../editors/ResourceEditor.py:230
+#: ../editors/ResourceEditor.py:239
msgid "Add task"
msgstr ""
-#: ../controls/VariablePanel.py:380 ../c_ext/CFileEditor.py:517
+#: ../editors/CodeFileEditor.py:658 ../controls/VariablePanel.py:450
msgid "Add variable"
msgstr ""
@@ -522,22 +540,23 @@
msgid "Addition"
msgstr ""
-#: ../plcopen/structures.py:249
+#: ../plcopen/definitions.py:47
msgid "Additional function blocks"
msgstr ""
-#: ../editors/Viewer.py:510
+#: ../editors/Viewer.py:571
msgid "Adjust Block Size"
msgstr ""
-#: ../editors/Viewer.py:1458
+#: ../editors/Viewer.py:1637
msgid "Alignment"
msgstr ""
-#: ../controls/VariablePanel.py:75 ../dialogs/BrowseLocationsDialog.py:34
-#: ../dialogs/BrowseLocationsDialog.py:43
-#: ../dialogs/BrowseLocationsDialog.py:136
-#: ../dialogs/BrowseLocationsDialog.py:139
+#: ../dialogs/BrowseLocationsDialog.py:39
+#: ../dialogs/BrowseLocationsDialog.py:47
+#: ../dialogs/BrowseLocationsDialog.py:140
+#: ../dialogs/BrowseLocationsDialog.py:143 ../controls/LogViewer.py:298
+#: ../controls/VariablePanel.py:70
msgid "All"
msgstr ""
@@ -545,16 +564,16 @@
msgid "All files (*.*)|*.*|CSV files (*.csv)|*.csv"
msgstr ""
-#: ../ProjectController.py:1373
+#: ../ProjectController.py:1623
msgid "Already connected. Please disconnect\n"
msgstr ""
-#: ../editors/DataTypeEditor.py:593
+#: ../editors/DataTypeEditor.py:594
#, python-format
msgid "An element named \"%s\" already exists in this structure!"
msgstr ""
-#: ../dialogs/ConnectionDialog.py:98
+#: ../dialogs/ConnectionDialog.py:96
msgid "Apply name modification to all continuations with the same name"
msgstr ""
@@ -574,8 +593,8 @@
msgid "Arithmetic"
msgstr ""
-#: ../controls/VariablePanel.py:732 ../editors/DataTypeEditor.py:54
-#: ../editors/DataTypeEditor.py:634
+#: ../editors/DataTypeEditor.py:54 ../editors/DataTypeEditor.py:635
+#: ../controls/VariablePanel.py:829
msgid "Array"
msgstr ""
@@ -583,7 +602,7 @@
msgid "Assignment"
msgstr ""
-#: ../dialogs/FBDVariableDialog.py:197
+#: ../dialogs/FBDVariableDialog.py:217
msgid "At least a variable or an expression must be selected!"
msgstr ""
@@ -595,7 +614,7 @@
msgid "Author Name (optional):"
msgstr ""
-#: ../dialogs/FindInPouDialog.py:72
+#: ../dialogs/FindInPouDialog.py:79
msgid "Backward"
msgstr ""
@@ -607,21 +626,21 @@
msgid "Bad domain name at "
msgstr ""
-#: ../canfestival/config_utils.py:341 ../canfestival/config_utils.py:623
+#: ../canfestival/config_utils.py:342 ../canfestival/config_utils.py:630
#, python-format
msgid "Bad location size : %s"
msgstr ""
-#: ../editors/DataTypeEditor.py:174 ../editors/DataTypeEditor.py:204
-#: ../editors/DataTypeEditor.py:296 ../dialogs/ArrayTypeDialog.py:55
+#: ../dialogs/ArrayTypeDialog.py:55 ../editors/DataTypeEditor.py:175
+#: ../editors/DataTypeEditor.py:205 ../editors/DataTypeEditor.py:297
msgid "Base Type:"
msgstr ""
-#: ../controls/VariablePanel.py:702 ../editors/DataTypeEditor.py:624
+#: ../editors/DataTypeEditor.py:625 ../controls/VariablePanel.py:787
msgid "Base Types"
msgstr ""
-#: ../Beremiz.py:511
+#: ../Beremiz.py:553
msgid "Beremiz"
msgstr ""
@@ -653,151 +672,167 @@
msgid "Bitwise inverting"
msgstr ""
-#: ../editors/Viewer.py:464
+#: ../editors/Viewer.py:525 ../editors/Viewer.py:2358
msgid "Block"
msgstr ""
-#: ../dialogs/FBDBlockDialog.py:38
+#: ../dialogs/FBDBlockDialog.py:59
msgid "Block Properties"
msgstr ""
-#: ../editors/Viewer.py:433
+#: ../editors/TextViewer.py:262
+msgid "Block name"
+msgstr ""
+
+#: ../editors/Viewer.py:491
msgid "Bottom"
msgstr ""
+#: ../ProjectController.py:1301
+msgid "Broken"
+msgstr ""
+
#: ../dialogs/BrowseValuesLibraryDialog.py:37
#, python-format
msgid "Browse %s values library"
msgstr ""
-#: ../dialogs/BrowseLocationsDialog.py:61
+#: ../dialogs/BrowseLocationsDialog.py:65
msgid "Browse Locations"
msgstr ""
-#: ../ProjectController.py:1519
+#: ../ProjectController.py:1769
msgid "Build"
msgstr ""
-#: ../ProjectController.py:1079
+#: ../ProjectController.py:1235
msgid "Build directory already clean\n"
msgstr ""
-#: ../ProjectController.py:1520
+#: ../ProjectController.py:1770
msgid "Build project into build folder"
msgstr ""
-#: ../ProjectController.py:937
+#: ../ProjectController.py:1018
msgid "C Build crashed !\n"
msgstr ""
-#: ../ProjectController.py:934
+#: ../ProjectController.py:1015
msgid "C Build failed.\n"
msgstr ""
-#: ../c_ext/CFileEditor.py:731
+#: ../c_ext/CFileEditor.py:63
msgid "C code"
msgstr ""
-#: ../ProjectController.py:922
+#: ../ProjectController.py:1093
msgid "C code generated successfully.\n"
msgstr ""
-#: ../targets/toolchain_gcc.py:132
+#: ../targets/toolchain_makefile.py:122
+msgid "C compilation failed.\n"
+msgstr ""
+
+#: ../targets/toolchain_gcc.py:156
#, python-format
msgid "C compilation of %s failed.\n"
msgstr ""
-#: ../features.py:8
+#: ../features.py:32
msgid "C extension"
msgstr ""
-#: ../canfestival/NetworkEditor.py:29
+#: ../dialogs/AboutDialog.py:63
+msgid "C&redits"
+msgstr ""
+
+#: ../canfestival/NetworkEditor.py:52
msgid "CANOpen network"
msgstr ""
-#: ../canfestival/SlaveEditor.py:21
+#: ../canfestival/SlaveEditor.py:44
msgid "CANOpen slave"
msgstr ""
-#: ../features.py:7
+#: ../features.py:31
msgid "CANopen support"
msgstr ""
-#: ../plcopen/plcopen.py:1732 ../plcopen/plcopen.py:1746
-#: ../plcopen/plcopen.py:1767 ../plcopen/plcopen.py:1783
+#: ../plcopen/plcopen.py:1584 ../plcopen/plcopen.py:1598
+#: ../plcopen/plcopen.py:1622 ../plcopen/plcopen.py:1638
msgid "Can only generate execution order on FBD networks!"
msgstr ""
-#: ../controls/VariablePanel.py:256
+#: ../controls/VariablePanel.py:267
msgid "Can only give a location to local or global variables"
msgstr ""
-#: ../PLCOpenEditor.py:336
+#: ../PLCOpenEditor.py:334
#, python-format
msgid "Can't generate program to file %s!"
msgstr ""
-#: ../controls/VariablePanel.py:254
+#: ../controls/VariablePanel.py:265
msgid "Can't give a location to a function block instance"
msgstr ""
-#: ../PLCOpenEditor.py:376
+#: ../PLCOpenEditor.py:379
#, python-format
msgid "Can't save project to file %s!"
msgstr ""
-#: ../controls/VariablePanel.py:300
+#: ../controls/VariablePanel.py:313
msgid "Can't set an initial value to a function block instance"
msgstr ""
-#: ../ConfigTreeNode.py:490
-#, python-format
-msgid "Cannot create child %s of type %s "
-msgstr ""
-
-#: ../ConfigTreeNode.py:417
+#: ../ConfigTreeNode.py:529
+#, python-brace-format
+msgid "Cannot create child {a1} of type {a2} "
+msgstr ""
+
+#: ../ConfigTreeNode.py:454
#, python-format
msgid "Cannot find lower free IEC channel than %d\n"
msgstr ""
-#: ../connectors/PYRO/__init__.py:92
+#: ../connectors/PYRO/__init__.py:131
msgid "Cannot get PLC status - connection failed.\n"
msgstr ""
-#: ../ProjectController.py:737
+#: ../ProjectController.py:881
msgid "Cannot open/parse VARIABLES.csv!\n"
msgstr ""
-#: ../canfestival/config_utils.py:371
-#, python-format
-msgid "Cannot set bit offset for non bool '%s' variable (ID:%d,Idx:%x,sIdx:%x))"
-msgstr ""
-
-#: ../dialogs/FindInPouDialog.py:81 ../dialogs/SearchInProjectDialog.py:67
+#: ../canfestival/config_utils.py:374
+#, python-brace-format
+msgid "Cannot set bit offset for non bool '{a1}' variable (ID:{a2},Idx:{a3},sIdx:{a4}))"
+msgstr ""
+
+#: ../dialogs/SearchInProjectDialog.py:59 ../dialogs/FindInPouDialog.py:88
msgid "Case sensitive"
msgstr ""
-#: ../editors/Viewer.py:428
+#: ../editors/Viewer.py:486
msgid "Center"
msgstr ""
-#: ../Beremiz_service.py:326
+#: ../Beremiz_service.py:266
msgid "Change IP of interface to bind"
msgstr ""
-#: ../Beremiz_service.py:325
+#: ../Beremiz_service.py:265
msgid "Change Name"
msgstr ""
-#: ../IDEFrame.py:1850
+#: ../IDEFrame.py:1943
msgid "Change POU Type To"
msgstr ""
-#: ../Beremiz_service.py:327
+#: ../Beremiz_service.py:267
msgid "Change Port Number"
msgstr ""
-#: ../Beremiz_service.py:328
+#: ../Beremiz_service.py:268
msgid "Change working directory"
msgstr ""
@@ -805,20 +840,20 @@
msgid "Character string"
msgstr ""
-#: ../svgui/svgui.py:92
+#: ../svgui/svgui.py:125
msgid "Choose a SVG file"
msgstr ""
-#: ../ProjectController.py:364
+#: ../ProjectController.py:451
msgid "Choose a directory to save project"
msgstr ""
-#: ../canfestival/canfestival.py:136 ../PLCOpenEditor.py:294
-#: ../PLCOpenEditor.py:326 ../PLCOpenEditor.py:370
+#: ../canfestival/canfestival.py:160 ../PLCOpenEditor.py:292
+#: ../PLCOpenEditor.py:324 ../PLCOpenEditor.py:373
msgid "Choose a file"
msgstr ""
-#: ../Beremiz.py:858 ../Beremiz.py:893
+#: ../Beremiz.py:931 ../Beremiz.py:966
msgid "Choose a project"
msgstr ""
@@ -827,75 +862,83 @@
msgid "Choose a value for %s:"
msgstr ""
-#: ../Beremiz_service.py:378
+#: ../Beremiz_service.py:323
msgid "Choose a working directory "
msgstr ""
-#: ../ProjectController.py:288
+#: ../ProjectController.py:358
msgid "Chosen folder doesn't contain a program. It's not a valid project!"
msgstr ""
-#: ../ProjectController.py:255
+#: ../ProjectController.py:325
msgid "Chosen folder isn't empty. You can't use it for a new project!"
msgstr ""
-#: ../controls/VariablePanel.py:58 ../controls/VariablePanel.py:59
+#: ../controls/VariablePanel.py:53 ../controls/VariablePanel.py:54
msgid "Class"
msgstr ""
-#: ../controls/VariablePanel.py:371
+#: ../controls/VariablePanel.py:441
msgid "Class Filter:"
msgstr ""
-#: ../dialogs/FBDVariableDialog.py:62
+#: ../dialogs/FBDVariableDialog.py:69
msgid "Class:"
msgstr ""
-#: ../ProjectController.py:1523
+#: ../ProjectController.py:1773
msgid "Clean"
msgstr ""
-#: ../ProjectController.py:1525
+#: ../controls/LogViewer.py:318
+msgid "Clean log messages"
+msgstr ""
+
+#: ../ProjectController.py:1775
msgid "Clean project build folder"
msgstr ""
-#: ../ProjectController.py:1076
+#: ../ProjectController.py:1232
msgid "Cleaning the build directory\n"
msgstr ""
-#: ../IDEFrame.py:416
+#: ../IDEFrame.py:435
msgid "Clear Errors"
msgstr ""
-#: ../editors/Viewer.py:520
+#: ../editors/Viewer.py:582
msgid "Clear Execution Order"
msgstr ""
-#: ../editors/GraphicViewer.py:125
-msgid "Clear the graph values"
-msgstr ""
-
-#: ../Beremiz.py:633 ../PLCOpenEditor.py:202
+#: ../dialogs/SearchInProjectDialog.py:105 ../dialogs/FindInPouDialog.py:111
+msgid "Close"
+msgstr ""
+
+#: ../PLCOpenEditor.py:199 ../Beremiz.py:693
msgid "Close Application"
msgstr ""
-#: ../IDEFrame.py:972 ../Beremiz.py:321 ../Beremiz.py:587
-#: ../PLCOpenEditor.py:112
+#: ../PLCOpenEditor.py:108 ../Beremiz.py:333 ../Beremiz.py:637
+#: ../IDEFrame.py:1009
msgid "Close Project"
msgstr ""
-#: ../Beremiz.py:319 ../PLCOpenEditor.py:110
+#: ../PLCOpenEditor.py:106 ../Beremiz.py:331
msgid "Close Tab"
msgstr ""
-#: ../editors/Viewer.py:480
+#: ../editors/Viewer.py:541 ../editors/Viewer.py:2366
msgid "Coil"
msgstr ""
-#: ../editors/Viewer.py:500 ../editors/LDViewer.py:506
+#: ../editors/Viewer.py:561 ../editors/LDViewer.py:506
msgid "Comment"
msgstr ""
+#: ../dialogs/ProjectDialog.py:57
+msgid "Company Name"
+msgstr ""
+
#: ../controls/ProjectPropertiesPanel.py:94
msgid "Company Name (required):"
msgstr ""
@@ -908,7 +951,7 @@
msgid "Comparison"
msgstr ""
-#: ../ProjectController.py:552
+#: ../ProjectController.py:672
msgid "Compiling IEC Program into C code...\n"
msgstr ""
@@ -916,79 +959,85 @@
msgid "Concatenation"
msgstr ""
-#: ../editors/ConfTreeNodeEditor.py:249
+#: ../editors/ConfTreeNodeEditor.py:229
msgid "Config"
msgstr ""
-#: ../editors/ProjectNodeEditor.py:13
+#: ../editors/ProjectNodeEditor.py:36
msgid "Config variables"
msgstr ""
-#: ../dialogs/SearchInProjectDialog.py:47
+#: ../dialogs/SearchInProjectDialog.py:39
msgid "Configuration"
msgstr ""
-#: ../PLCControler.py:96
+#: ../PLCControler.py:97
msgid "Configurations"
msgstr ""
-#: ../ProjectController.py:1538
+#: ../editors/Viewer.py:307 ../editors/Viewer.py:337 ../editors/Viewer.py:359
+#: ../editors/TextViewer.py:291 ../editors/TextViewer.py:342
+#: ../editors/TextViewer.py:365 ../controls/VariablePanel.py:328
+msgid "Confirm or change variable name"
+msgstr ""
+
+#: ../ProjectController.py:1788
msgid "Connect"
msgstr ""
-#: ../ProjectController.py:1539
+#: ../ProjectController.py:1789
msgid "Connect to the target PLC"
msgstr ""
-#: ../ProjectController.py:1125
+#: ../ProjectController.py:1292
#, python-format
msgid "Connected to URI: %s"
msgstr ""
-#: ../connectors/PYRO/__init__.py:40
-#, python-format
-msgid "Connecting to URI : %s\n"
-msgstr ""
-
-#: ../editors/Viewer.py:466 ../dialogs/SFCTransitionDialog.py:76
+#: ../dialogs/SFCTransitionDialog.py:76 ../editors/Viewer.py:527
+#: ../editors/Viewer.py:2359
msgid "Connection"
msgstr ""
-#: ../dialogs/ConnectionDialog.py:37
+#: ../dialogs/ConnectionDialog.py:52
msgid "Connection Properties"
msgstr ""
-#: ../ProjectController.py:1397
+#: ../ProjectController.py:1647
msgid "Connection canceled!\n"
msgstr ""
-#: ../ProjectController.py:1422
+#: ../ProjectController.py:1672
#, python-format
msgid "Connection failed to %s!\n"
msgstr ""
-#: ../connectors/PYRO/__init__.py:63
+#: ../connectors/PYRO/__init__.py:115 ../connectors/WAMP/__init__.py:111
+msgid "Connection lost!\n"
+msgstr ""
+
+#: ../connectors/PYRO/__init__.py:102
#, python-format
msgid "Connection to '%s' failed.\n"
msgstr ""
-#: ../editors/Viewer.py:1426 ../dialogs/ConnectionDialog.py:56
+#: ../dialogs/ConnectionDialog.py:64 ../editors/Viewer.py:1594
msgid "Connector"
msgstr ""
-#: ../dialogs/SFCStepDialog.py:58
+#: ../dialogs/SFCStepDialog.py:65
msgid "Connectors:"
msgstr ""
-#: ../Beremiz.py:420
+#: ../Beremiz.py:448
msgid "Console"
msgstr ""
-#: ../controls/VariablePanel.py:65
+#: ../controls/VariablePanel.py:60
msgid "Constant"
msgstr ""
-#: ../editors/Viewer.py:476
+#: ../editors/Viewer.py:537 ../editors/Viewer.py:2362
msgid "Contact"
msgstr ""
@@ -996,7 +1045,7 @@
msgid "Content Description (optional):"
msgstr ""
-#: ../editors/Viewer.py:1427 ../dialogs/ConnectionDialog.py:61
+#: ../dialogs/ConnectionDialog.py:65 ../editors/Viewer.py:1595
msgid "Continuation"
msgstr ""
@@ -1016,11 +1065,12 @@
msgid "Conversion to time-of-day"
msgstr ""
-#: ../IDEFrame.py:353 ../IDEFrame.py:406 ../editors/Viewer.py:536
+#: ../editors/Viewer.py:597 ../controls/LogViewer.py:693 ../IDEFrame.py:370
+#: ../IDEFrame.py:425
msgid "Copy"
msgstr ""
-#: ../IDEFrame.py:1837
+#: ../IDEFrame.py:1930
msgid "Copy POU"
msgstr ""
@@ -1036,48 +1086,53 @@
msgid "Cosine"
msgstr ""
-#: ../ConfigTreeNode.py:602
-#, python-format
+#: ../ConfigTreeNode.py:656
+#, python-brace-format
msgid ""
-"Could not add child \"%s\", type %s :\n"
-"%s\n"
-msgstr ""
-
-#: ../ConfigTreeNode.py:579
-#, python-format
+"Could not add child \"{a1}\", type {a2} :\n"
+"{a3}\n"
+msgstr ""
+
+#: ../py_ext/PythonFileCTNMixin.py:77
+#, python-format
+msgid "Couldn't import old %s file."
+msgstr ""
+
+#: ../ConfigTreeNode.py:626
+#, python-brace-format
msgid ""
-"Couldn't load confnode base parameters %s :\n"
-" %s"
-msgstr ""
-
-#: ../ConfigTreeNode.py:590
-#, python-format
+"Couldn't load confnode base parameters {a1} :\n"
+" {a2}"
+msgstr ""
+
+#: ../ConfigTreeNode.py:643 ../CodeFileTreeNode.py:124
+#, python-brace-format
msgid ""
-"Couldn't load confnode parameters %s :\n"
-" %s"
-msgstr ""
-
-#: ../PLCControler.py:819 ../PLCControler.py:856
+"Couldn't load confnode parameters {a1} :\n"
+" {a2}"
+msgstr ""
+
+#: ../PLCControler.py:946
msgid "Couldn't paste non-POU object."
msgstr ""
-#: ../ProjectController.py:1344
+#: ../ProjectController.py:1589
msgid "Couldn't start PLC !\n"
msgstr ""
-#: ../ProjectController.py:1352
+#: ../ProjectController.py:1597
msgid "Couldn't stop PLC !\n"
msgstr ""
-#: ../ProjectController.py:1321
+#: ../ProjectController.py:1561
msgid "Couldn't stop debugger.\n"
msgstr ""
-#: ../svgui/svgui.py:22
+#: ../svgui/svgui.py:47
msgid "Create HMI"
msgstr ""
-#: ../dialogs/PouDialog.py:43
+#: ../dialogs/PouDialog.py:45
msgid "Create a new POU"
msgstr ""
@@ -1085,71 +1140,79 @@
msgid "Create a new action"
msgstr ""
-#: ../IDEFrame.py:142
+#: ../IDEFrame.py:159
msgid "Create a new action block"
msgstr ""
-#: ../IDEFrame.py:91 ../IDEFrame.py:121 ../IDEFrame.py:154
+#: ../IDEFrame.py:108 ../IDEFrame.py:138 ../IDEFrame.py:171
msgid "Create a new block"
msgstr ""
-#: ../IDEFrame.py:115
+#: ../IDEFrame.py:132
msgid "Create a new branch"
msgstr ""
-#: ../IDEFrame.py:109
+#: ../IDEFrame.py:126
msgid "Create a new coil"
msgstr ""
-#: ../IDEFrame.py:85 ../IDEFrame.py:100 ../IDEFrame.py:130
+#: ../IDEFrame.py:102 ../IDEFrame.py:117 ../IDEFrame.py:147
msgid "Create a new comment"
msgstr ""
-#: ../IDEFrame.py:94 ../IDEFrame.py:124 ../IDEFrame.py:157
+#: ../IDEFrame.py:111 ../IDEFrame.py:141 ../IDEFrame.py:174
msgid "Create a new connection"
msgstr ""
-#: ../IDEFrame.py:112 ../IDEFrame.py:163
+#: ../IDEFrame.py:129 ../IDEFrame.py:180
msgid "Create a new contact"
msgstr ""
-#: ../IDEFrame.py:145
+#: ../IDEFrame.py:162
msgid "Create a new divergence"
msgstr ""
-#: ../dialogs/SFCDivergenceDialog.py:36
+#: ../dialogs/SFCDivergenceDialog.py:53
msgid "Create a new divergence or convergence"
msgstr ""
-#: ../IDEFrame.py:133
+#: ../IDEFrame.py:150
msgid "Create a new initial step"
msgstr ""
-#: ../IDEFrame.py:148
+#: ../IDEFrame.py:165
msgid "Create a new jump"
msgstr ""
-#: ../IDEFrame.py:103 ../IDEFrame.py:160
+#: ../IDEFrame.py:120 ../IDEFrame.py:177
msgid "Create a new power rail"
msgstr ""
-#: ../IDEFrame.py:106
+#: ../IDEFrame.py:123
msgid "Create a new rung"
msgstr ""
-#: ../IDEFrame.py:136
+#: ../IDEFrame.py:153
msgid "Create a new step"
msgstr ""
-#: ../IDEFrame.py:139 ../dialogs/PouTransitionDialog.py:42
+#: ../dialogs/PouTransitionDialog.py:47 ../IDEFrame.py:156
msgid "Create a new transition"
msgstr ""
-#: ../IDEFrame.py:88 ../IDEFrame.py:118 ../IDEFrame.py:151
+#: ../IDEFrame.py:105 ../IDEFrame.py:135 ../IDEFrame.py:168
msgid "Create a new variable"
msgstr ""
-#: ../IDEFrame.py:351 ../IDEFrame.py:405 ../editors/Viewer.py:535
+#: ../dialogs/AboutDialog.py:105
+msgid "Credits"
+msgstr ""
+
+#: ../Beremiz_service.py:432
+msgid "Current working directory :"
+msgstr ""
+
+#: ../editors/Viewer.py:596 ../IDEFrame.py:368 ../IDEFrame.py:424
msgid "Cut"
msgstr ""
@@ -1165,19 +1228,19 @@
msgid "DEPRECATED"
msgstr ""
-#: ../canfestival/SlaveEditor.py:53 ../canfestival/NetworkEditor.py:74
+#: ../canfestival/SlaveEditor.py:76 ../canfestival/NetworkEditor.py:97
msgid "DS-301 Profile"
msgstr ""
-#: ../canfestival/SlaveEditor.py:54 ../canfestival/NetworkEditor.py:75
+#: ../canfestival/SlaveEditor.py:77 ../canfestival/NetworkEditor.py:98
msgid "DS-302 Profile"
msgstr ""
-#: ../dialogs/SearchInProjectDialog.py:43
+#: ../dialogs/SearchInProjectDialog.py:35
msgid "Data Type"
msgstr ""
-#: ../PLCControler.py:95
+#: ../PLCControler.py:96
msgid "Data Types"
msgstr ""
@@ -1202,50 +1265,50 @@
msgid "Days:"
msgstr ""
-#: ../ProjectController.py:1444
+#: ../ProjectController.py:1694
msgid "Debug does not match PLC - stop/transfert/start to re-enable\n"
msgstr ""
-#: ../controls/PouInstanceVariablesPanel.py:59
+#: ../controls/PouInstanceVariablesPanel.py:134
msgid "Debug instance"
msgstr ""
-#: ../editors/Viewer.py:1016 ../editors/Viewer.py:3326
+#: ../editors/Viewer.py:1117 ../editors/Viewer.py:3653
#, python-format
msgid "Debug: %s"
msgstr ""
-#: ../ProjectController.py:1153
+#: ../ProjectController.py:1350
#, python-format
msgid "Debug: Unknown variable '%s'\n"
msgstr ""
-#: ../ProjectController.py:1151
+#: ../ProjectController.py:1348
#, python-format
msgid "Debug: Unsupported type to debug '%s'\n"
msgstr ""
-#: ../IDEFrame.py:612
+#: ../IDEFrame.py:639
msgid "Debugger"
msgstr ""
-#: ../ProjectController.py:1311
+#: ../ProjectController.py:1530
msgid "Debugger disabled\n"
msgstr ""
-#: ../ProjectController.py:1441
+#: ../ProjectController.py:1691
msgid "Debugger ready\n"
msgstr ""
-#: ../ProjectController.py:1323
+#: ../ProjectController.py:1563
msgid "Debugger stopped.\n"
msgstr ""
-#: ../IDEFrame.py:1866 ../Beremiz.py:991 ../editors/Viewer.py:511
+#: ../editors/Viewer.py:572 ../Beremiz.py:1064 ../IDEFrame.py:1959
msgid "Delete"
msgstr ""
-#: ../editors/Viewer.py:453
+#: ../editors/Viewer.py:514
msgid "Delete Divergence Branch"
msgstr ""
@@ -1253,7 +1316,7 @@
msgid "Delete File"
msgstr ""
-#: ../editors/Viewer.py:442
+#: ../editors/Viewer.py:501
msgid "Delete Wire Segment"
msgstr ""
@@ -1265,29 +1328,23 @@
msgid "Deletion (within)"
msgstr ""
-#: ../editors/DataTypeEditor.py:152
+#: ../editors/DataTypeEditor.py:153
msgid "Derivation Type:"
msgstr ""
-#: ../plcopen/structures.py:263
-msgid ""
-"Derivative\n"
-"The derivative function block produces an output XOUT proportional to the rate of change of the input XIN."
-msgstr ""
-
-#: ../controls/VariablePanel.py:362
+#: ../controls/VariablePanel.py:432
msgid "Description:"
msgstr ""
-#: ../editors/DataTypeEditor.py:320 ../dialogs/ArrayTypeDialog.py:61
+#: ../dialogs/ArrayTypeDialog.py:61 ../editors/DataTypeEditor.py:321
msgid "Dimensions:"
msgstr ""
-#: ../dialogs/FindInPouDialog.py:61
+#: ../dialogs/FindInPouDialog.py:68
msgid "Direction"
msgstr ""
-#: ../dialogs/BrowseLocationsDialog.py:86
+#: ../dialogs/BrowseLocationsDialog.py:90
msgid "Direction:"
msgstr ""
@@ -1295,15 +1352,19 @@
msgid "Directly"
msgstr ""
-#: ../ProjectController.py:1547
+#: ../ProjectController.py:1797
msgid "Disconnect"
msgstr ""
-#: ../ProjectController.py:1549
+#: ../ProjectController.py:1799
msgid "Disconnect from PLC"
msgstr ""
-#: ../editors/Viewer.py:495
+#: ../ProjectController.py:1302
+msgid "Disconnected"
+msgstr ""
+
+#: ../editors/Viewer.py:556 ../editors/Viewer.py:2354
msgid "Divergence"
msgstr ""
@@ -1316,37 +1377,31 @@
msgid "Do you really want to delete the file '%s'?"
msgstr ""
-#: ../controls/VariablePanel.py:58 ../controls/VariablePanel.py:59
+#: ../controls/VariablePanel.py:53 ../controls/VariablePanel.py:54
msgid "Documentation"
msgstr ""
-#: ../PLCOpenEditor.py:330
+#: ../PLCOpenEditor.py:328
msgid "Done"
msgstr ""
-#: ../plcopen/structures.py:226
-msgid ""
-"Down-counter\n"
-"The down-counter can be used to signal when a count has reached zero, on counting down from a preset value."
-msgstr ""
-
-#: ../dialogs/ActionBlockDialog.py:37
+#: ../dialogs/ActionBlockDialog.py:38
msgid "Duration"
msgstr ""
-#: ../canfestival/canfestival.py:139
+#: ../canfestival/canfestival.py:163
msgid "EDS files (*.eds)|*.eds|All files|*.*"
msgstr ""
-#: ../editors/Viewer.py:509
+#: ../editors/Viewer.py:570
msgid "Edit Block"
msgstr ""
-#: ../dialogs/LDElementDialog.py:41
+#: ../dialogs/LDElementDialog.py:56
msgid "Edit Coil Values"
msgstr ""
-#: ../dialogs/LDElementDialog.py:38
+#: ../dialogs/LDElementDialog.py:54
msgid "Edit Contact Values"
msgstr ""
@@ -1354,15 +1409,15 @@
msgid "Edit Duration"
msgstr ""
-#: ../dialogs/SFCStepDialog.py:35
+#: ../dialogs/SFCStepDialog.py:50
msgid "Edit Step"
msgstr ""
-#: ../wxglade_hmi/wxglade_hmi.py:12
+#: ../wxglade_hmi/wxglade_hmi.py:36
msgid "Edit a WxWidgets GUI with WXGlade"
msgstr ""
-#: ../dialogs/ActionBlockDialog.py:122
+#: ../dialogs/ActionBlockDialog.py:121
msgid "Edit action block properties"
msgstr ""
@@ -1370,8 +1425,7 @@
msgid "Edit array type properties"
msgstr ""
-#: ../editors/Viewer.py:2186 ../editors/Viewer.py:2188
-#: ../editors/Viewer.py:2706 ../editors/Viewer.py:2708
+#: ../editors/Viewer.py:2575 ../editors/Viewer.py:3004
msgid "Edit comment"
msgstr ""
@@ -1383,47 +1437,51 @@
msgid "Edit item"
msgstr ""
-#: ../editors/Viewer.py:2670
+#: ../editors/Viewer.py:2963
msgid "Edit jump target"
msgstr ""
-#: ../ProjectController.py:1561
+#: ../ProjectController.py:1811
msgid "Edit raw IEC code added to code generated by PLCGenerator"
msgstr ""
-#: ../editors/SFCViewer.py:725
+#: ../editors/SFCViewer.py:799
msgid "Edit step name"
msgstr ""
-#: ../dialogs/SFCTransitionDialog.py:38
+#: ../dialogs/SFCTransitionDialog.py:51
msgid "Edit transition"
msgstr ""
-#: ../IDEFrame.py:584
+#: ../IDEFrame.py:611
msgid "Editor ToolBar"
msgstr ""
-#: ../ProjectController.py:1039
+#: ../ProjectController.py:1195
msgid "Editor selection"
msgstr ""
-#: ../editors/DataTypeEditor.py:347
+#: ../editors/DataTypeEditor.py:348
msgid "Elements :"
msgstr ""
-#: ../IDEFrame.py:348
+#: ../ProjectController.py:1300
+msgid "Empty"
+msgstr ""
+
+#: ../IDEFrame.py:365
msgid "Enable Undo/Redo"
msgstr ""
-#: ../Beremiz_service.py:385
+#: ../Beremiz_service.py:331
msgid "Enter a name "
msgstr ""
-#: ../Beremiz_service.py:370
+#: ../Beremiz_service.py:316
msgid "Enter a port number "
msgstr ""
-#: ../Beremiz_service.py:360
+#: ../Beremiz_service.py:307
msgid "Enter the IP of the interface to bind"
msgstr ""
@@ -1435,80 +1493,81 @@
msgid "Equal to"
msgstr ""
-#: ../Beremiz_service.py:271 ../controls/VariablePanel.py:332
-#: ../controls/VariablePanel.py:681 ../controls/DebugVariablePanel.py:379
-#: ../IDEFrame.py:966 ../IDEFrame.py:1553 ../IDEFrame.py:1590
-#: ../IDEFrame.py:1595 ../IDEFrame.py:1609 ../IDEFrame.py:1614
-#: ../IDEFrame.py:2290 ../Beremiz.py:1131 ../PLCOpenEditor.py:337
-#: ../PLCOpenEditor.py:342 ../PLCOpenEditor.py:416 ../PLCOpenEditor.py:426
-#: ../editors/TextViewer.py:369 ../editors/DataTypeEditor.py:549
-#: ../editors/DataTypeEditor.py:554 ../editors/DataTypeEditor.py:578
-#: ../editors/DataTypeEditor.py:583 ../editors/DataTypeEditor.py:593
-#: ../editors/DataTypeEditor.py:744 ../editors/DataTypeEditor.py:751
-#: ../editors/Viewer.py:365 ../editors/LDViewer.py:666
-#: ../editors/LDViewer.py:882 ../editors/LDViewer.py:886
-#: ../ProjectController.py:225 ../dialogs/PouNameDialog.py:53
-#: ../dialogs/PouTransitionDialog.py:107
-#: ../dialogs/BrowseLocationsDialog.py:212 ../dialogs/ProjectDialog.py:71
-#: ../dialogs/SFCStepNameDialog.py:59 ../dialogs/ConnectionDialog.py:159
-#: ../dialogs/FBDVariableDialog.py:201 ../dialogs/PouActionDialog.py:104
-#: ../dialogs/BrowseValuesLibraryDialog.py:83 ../dialogs/PouDialog.py:132
-#: ../dialogs/SFCTransitionDialog.py:147
+#: ../dialogs/ForceVariableDialog.py:179
+#: ../dialogs/SearchInProjectDialog.py:168 ../dialogs/SFCStepNameDialog.py:60
#: ../dialogs/DurationEditorDialog.py:121
-#: ../dialogs/DurationEditorDialog.py:163
-#: ../dialogs/SearchInProjectDialog.py:157 ../dialogs/SFCStepDialog.py:130
+#: ../dialogs/DurationEditorDialog.py:163 ../dialogs/PouTransitionDialog.py:112
+#: ../dialogs/BlockPreviewDialog.py:236 ../dialogs/ProjectDialog.py:71
#: ../dialogs/ArrayTypeDialog.py:97 ../dialogs/ArrayTypeDialog.py:103
-#: ../dialogs/FBDBlockDialog.py:164 ../dialogs/ForceVariableDialog.py:179
+#: ../dialogs/PouNameDialog.py:54 ../dialogs/BrowseLocationsDialog.py:216
+#: ../dialogs/BrowseValuesLibraryDialog.py:83 ../dialogs/PouActionDialog.py:104
+#: ../dialogs/PouDialog.py:134 ../PLCOpenEditor.py:335 ../PLCOpenEditor.py:340
+#: ../PLCOpenEditor.py:420 ../PLCOpenEditor.py:430 ../editors/Viewer.py:423
+#: ../editors/LDViewer.py:666 ../editors/LDViewer.py:882
+#: ../editors/LDViewer.py:886 ../editors/DataTypeEditor.py:550
+#: ../editors/DataTypeEditor.py:555 ../editors/DataTypeEditor.py:579
+#: ../editors/DataTypeEditor.py:584 ../editors/DataTypeEditor.py:594
+#: ../editors/DataTypeEditor.py:745 ../editors/DataTypeEditor.py:752
+#: ../editors/TextViewer.py:389 ../editors/CodeFileEditor.py:783
+#: ../ProjectController.py:293 ../ProjectController.py:421
+#: ../ProjectController.py:428 ../controls/FolderTree.py:217
+#: ../controls/DebugVariablePanel/DebugVariablePanel.py:166
+#: ../controls/DebugVariablePanel/DebugVariableTextViewer.py:137
+#: ../controls/DebugVariablePanel/DebugVariableGraphicViewer.py:231
+#: ../controls/VariablePanel.py:402 ../controls/VariablePanel.py:772
+#: ../Beremiz.py:1203 ../IDEFrame.py:1003 ../IDEFrame.py:1614
+#: ../IDEFrame.py:1655 ../IDEFrame.py:1660 ../IDEFrame.py:1674
+#: ../IDEFrame.py:1679 ../Beremiz_service.py:211
msgid "Error"
msgstr ""
-#: ../ProjectController.py:601
+#: ../ProjectController.py:727
msgid "Error : At least one configuration and one resource must be declared in PLC !\n"
msgstr ""
-#: ../ProjectController.py:593
+#: ../ProjectController.py:719
#, python-format
msgid "Error : IEC to C compiler returned %d\n"
msgstr ""
-#: ../ProjectController.py:534
+#: ../ProjectController.py:621
#, python-format
msgid ""
"Error in ST/IL/SFC code generator :\n"
"%s\n"
msgstr ""
-#: ../ConfigTreeNode.py:183
+#: ../ConfigTreeNode.py:216
#, python-format
msgid "Error while saving \"%s\"\n"
msgstr ""
-#: ../canfestival/canfestival.py:144
+#: ../canfestival/canfestival.py:168
msgid "Error: Export slave failed\n"
msgstr ""
-#: ../canfestival/canfestival.py:345
+#: ../canfestival/canfestival.py:369
msgid "Error: No Master generated\n"
msgstr ""
-#: ../canfestival/canfestival.py:340
+#: ../canfestival/canfestival.py:364
msgid "Error: No PLC built\n"
msgstr ""
-#: ../ProjectController.py:1416
+#: ../ProjectController.py:1666
#, python-format
msgid "Exception while connecting %s!\n"
msgstr ""
-#: ../dialogs/FBDBlockDialog.py:95
+#: ../dialogs/FBDBlockDialog.py:117
msgid "Execution Control:"
msgstr ""
-#: ../dialogs/FBDVariableDialog.py:76 ../dialogs/FBDBlockDialog.py:87
+#: ../dialogs/FBDVariableDialog.py:79 ../dialogs/FBDBlockDialog.py:105
msgid "Execution Order:"
msgstr ""
-#: ../features.py:11
+#: ../features.py:35
msgid "Experimental web based HMI"
msgstr ""
@@ -1520,54 +1579,52 @@
msgid "Exponentiation"
msgstr ""
-#: ../canfestival/canfestival.py:150
+#: ../canfestival/canfestival.py:174
msgid "Export CanOpen slave to EDS file"
msgstr ""
-#: ../controls/DebugVariablePanel.py:1472 ../editors/GraphicViewer.py:144
+#: ../controls/DebugVariablePanel/DebugVariablePanel.py:243
msgid "Export graph values to clipboard"
msgstr ""
-#: ../canfestival/canfestival.py:149
+#: ../canfestival/canfestival.py:173
msgid "Export slave"
msgstr ""
-#: ../dialogs/FBDVariableDialog.py:69
+#: ../dialogs/FBDVariableDialog.py:89
msgid "Expression:"
msgstr ""
-#: ../controls/VariablePanel.py:77
+#: ../controls/VariablePanel.py:72
msgid "External"
msgstr ""
-#: ../ProjectController.py:605
+#: ../ProjectController.py:740
msgid "Extracting Located Variables...\n"
msgstr ""
-#: ../controls/ProjectPropertiesPanel.py:143
-#: ../dialogs/PouTransitionDialog.py:35 ../dialogs/PouActionDialog.py:31
-#: ../dialogs/PouDialog.py:36
+#: ../dialogs/PouTransitionDialog.py:40 ../dialogs/PouActionDialog.py:31
+#: ../dialogs/PouDialog.py:36 ../controls/ProjectPropertiesPanel.py:143
msgid "FBD"
msgstr ""
-#: ../ProjectController.py:1480
+#: ../ProjectController.py:1729
msgid "Failed : Must build before transfer.\n"
msgstr ""
-#: ../editors/Viewer.py:404 ../dialogs/LDElementDialog.py:84
+#: ../dialogs/LDElementDialog.py:77 ../editors/Viewer.py:462
msgid "Falling Edge"
msgstr ""
-#: ../plcopen/structures.py:216
-msgid ""
-"Falling edge detector\n"
-"The output produces a single pulse when a falling edge is detected."
-msgstr ""
-
-#: ../ProjectController.py:927
+#: ../ProjectController.py:1008
msgid "Fatal : cannot get builder.\n"
msgstr ""
+#: ../Beremiz.py:118
+#, python-format
+msgid "Fetching %s"
+msgstr ""
+
#: ../dialogs/DurationEditorDialog.py:160
#, python-format
msgid "Field %s hasn't a valid value!"
@@ -1578,16 +1635,21 @@
msgid "Fields %s haven't a valid value!"
msgstr ""
-#: ../IDEFrame.py:358 ../dialogs/FindInPouDialog.py:30
-#: ../dialogs/FindInPouDialog.py:99
+#: ../controls/FolderTree.py:216
+#, python-format
+msgid "File '%s' already exists!"
+msgstr ""
+
+#: ../dialogs/SearchInProjectDialog.py:100 ../dialogs/FindInPouDialog.py:36
+#: ../dialogs/FindInPouDialog.py:106 ../IDEFrame.py:375
msgid "Find"
msgstr ""
-#: ../IDEFrame.py:360
+#: ../IDEFrame.py:377
msgid "Find Next"
msgstr ""
-#: ../IDEFrame.py:362
+#: ../IDEFrame.py:379
msgid "Find Previous"
msgstr ""
@@ -1595,15 +1657,15 @@
msgid "Find position"
msgstr ""
-#: ../dialogs/FindInPouDialog.py:51
+#: ../dialogs/FindInPouDialog.py:57
msgid "Find:"
msgstr ""
-#: ../connectors/PYRO/__init__.py:125
+#: ../connectors/PYRO/__init__.py:163
msgid "Force runtime reload\n"
msgstr ""
-#: ../controls/DebugVariablePanel.py:1934 ../editors/Viewer.py:1385
+#: ../editors/Viewer.py:1553
msgid "Force value"
msgstr ""
@@ -1611,75 +1673,73 @@
msgid "Forcing Variable Value"
msgstr ""
-#: ../dialogs/PouTransitionDialog.py:97 ../dialogs/ProjectDialog.py:70
-#: ../dialogs/PouActionDialog.py:94 ../dialogs/PouDialog.py:114
-#: ../dialogs/SFCTransitionDialog.py:147
+#: ../dialogs/SFCTransitionDialog.py:179 ../dialogs/PouTransitionDialog.py:102
+#: ../dialogs/ProjectDialog.py:70 ../dialogs/PouActionDialog.py:94
+#: ../dialogs/PouDialog.py:116
#, python-format
msgid "Form isn't complete. %s must be filled!"
msgstr ""
-#: ../dialogs/ConnectionDialog.py:149 ../dialogs/FBDBlockDialog.py:154
+#: ../dialogs/SFCStepDialog.py:144 ../dialogs/FBDBlockDialog.py:232
+#: ../dialogs/ConnectionDialog.py:160
msgid "Form isn't complete. Name must be filled!"
msgstr ""
-#: ../dialogs/SearchInProjectDialog.py:145
-msgid "Form isn't complete. Pattern to search must be filled!"
-msgstr ""
-
-#: ../dialogs/FBDBlockDialog.py:152
+#: ../dialogs/FBDBlockDialog.py:228
msgid "Form isn't complete. Valid block type must be selected!"
msgstr ""
-#: ../dialogs/FindInPouDialog.py:67
+#: ../dialogs/FindInPouDialog.py:74
msgid "Forward"
msgstr ""
-#: ../dialogs/SearchInProjectDialog.py:44
+#: ../dialogs/SearchInProjectDialog.py:36 ../IDEFrame.py:1746
msgid "Function"
msgstr ""
-#: ../IDEFrame.py:334
+#: ../IDEFrame.py:349
msgid "Function &Block"
msgstr ""
-#: ../IDEFrame.py:1845 ../dialogs/SearchInProjectDialog.py:45
+#: ../dialogs/SearchInProjectDialog.py:37 ../IDEFrame.py:1745
+#: ../IDEFrame.py:1938
msgid "Function Block"
msgstr ""
-#: ../controls/VariablePanel.py:744
+#: ../controls/VariablePanel.py:825
msgid "Function Block Types"
msgstr ""
-#: ../PLCControler.py:94
+#: ../PLCControler.py:95
msgid "Function Blocks"
msgstr ""
-#: ../editors/Viewer.py:236
+#: ../editors/Viewer.py:248
msgid "Function Blocks can't be used in Functions!"
msgstr ""
-#: ../PLCControler.py:2180
+#: ../PLCControler.py:2337
#, python-format
msgid "FunctionBlock \"%s\" can't be pasted in a Function!!!"
msgstr ""
-#: ../PLCControler.py:94
+#: ../PLCControler.py:95
msgid "Functions"
msgstr ""
-#: ../PLCOpenEditor.py:119
+#: ../PLCOpenEditor.py:115
msgid "Generate Program"
msgstr ""
-#: ../ProjectController.py:524
+#: ../ProjectController.py:612
msgid "Generating SoftPLC IEC-61131 ST/IL/SFC code...\n"
msgstr ""
-#: ../controls/VariablePanel.py:78
+#: ../controls/VariablePanel.py:73
msgid "Global"
msgstr ""
-#: ../controls/DebugVariablePanel.py:1471 ../editors/GraphicViewer.py:131
+#: ../controls/DebugVariablePanel/DebugVariablePanel.py:242
msgid "Go to current value"
msgstr ""
@@ -1699,6 +1759,10 @@
msgid "Grid Resolution:"
msgstr ""
+#: ../runtime/NevowServer.py:181
+msgid "HTTP interface port :"
+msgstr ""
+
#: ../controls/ProjectPropertiesPanel.py:120
msgid "Height:"
msgstr ""
@@ -1715,87 +1779,81 @@
msgid "Hours:"
msgstr ""
-#: ../plcopen/structures.py:278
-msgid ""
-"Hysteresis\n"
-"The hysteresis function block provides a hysteresis boolean output driven by the difference of two floating point (REAL) inputs XIN1 and XIN2."
-msgstr ""
-
-#: ../ProjectController.py:851
-msgid "IEC-61131-3 code generation failed !\n"
-msgstr ""
-
-#: ../dialogs/PouTransitionDialog.py:35 ../dialogs/PouActionDialog.py:31
-#: ../dialogs/PouDialog.py:36
+#: ../dialogs/PouActionDialog.py:31 ../dialogs/PouDialog.py:36
msgid "IL"
msgstr ""
-#: ../Beremiz_service.py:361 ../Beremiz_service.py:362
+#: ../dialogs/DiscoveryDialog.py:94
+msgid "IP"
+msgstr ""
+
+#: ../Beremiz_service.py:308 ../Beremiz_service.py:309
msgid "IP is not valid!"
msgstr ""
-#: ../svgui/svgui.py:17 ../svgui/svgui.py:18
+#: ../svgui/svgui.py:42 ../svgui/svgui.py:43
msgid "Import SVG"
msgstr ""
-#: ../controls/VariablePanel.py:76 ../editors/Viewer.py:1412
-#: ../dialogs/FBDVariableDialog.py:34
+#: ../dialogs/FBDVariableDialog.py:38 ../editors/Viewer.py:1580
+#: ../controls/VariablePanel.py:71
msgid "InOut"
msgstr ""
-#: ../editors/Viewer.py:999
+#: ../editors/Viewer.py:1100
msgid "Inactive"
msgstr ""
-#: ../controls/VariablePanel.py:265
-#, python-format
-msgid "Incompatible data types between \"%s\" and \"%s\""
-msgstr ""
-
-#: ../controls/VariablePanel.py:274
-#, python-format
-msgid "Incompatible size of data between \"%s\" and \"%s\""
-msgstr ""
-
-#: ../controls/VariablePanel.py:270
+#: ../controls/VariablePanel.py:276
+#, python-brace-format
+msgid "Incompatible data types between \"{a1}\" and \"{a2}\""
+msgstr ""
+
+#: ../controls/VariablePanel.py:282
#, python-format
msgid "Incompatible size of data between \"%s\" and \"BOOL\""
msgstr ""
-#: ../dialogs/ActionBlockDialog.py:37
+#: ../controls/VariablePanel.py:286
+#, python-brace-format
+msgid "Incompatible size of data between \"{a1}\" and \"{a2}\""
+msgstr ""
+
+#: ../dialogs/ActionBlockDialog.py:38
msgid "Indicator"
msgstr ""
-#: ../editors/Viewer.py:491
+#: ../editors/Viewer.py:552
msgid "Initial Step"
msgstr ""
-#: ../controls/VariablePanel.py:58 ../controls/VariablePanel.py:59
-#: ../editors/DataTypeEditor.py:50
+#: ../editors/DataTypeEditor.py:50 ../controls/VariablePanel.py:53
+#: ../controls/VariablePanel.py:54
msgid "Initial Value"
msgstr ""
-#: ../editors/DataTypeEditor.py:184 ../editors/DataTypeEditor.py:215
-#: ../editors/DataTypeEditor.py:271 ../editors/DataTypeEditor.py:309
+#: ../editors/DataTypeEditor.py:185 ../editors/DataTypeEditor.py:216
+#: ../editors/DataTypeEditor.py:272 ../editors/DataTypeEditor.py:310
msgid "Initial Value:"
msgstr ""
-#: ../svgui/svgui.py:21
+#: ../svgui/svgui.py:46
msgid "Inkscape"
msgstr ""
-#: ../dialogs/ActionBlockDialog.py:41 ../dialogs/SFCTransitionDialog.py:66
-#: ../dialogs/SFCTransitionDialog.py:137
+#: ../dialogs/SFCTransitionDialog.py:75 ../dialogs/ActionBlockDialog.py:42
msgid "Inline"
msgstr ""
-#: ../controls/VariablePanel.py:76 ../editors/Viewer.py:1410
-#: ../dialogs/BrowseLocationsDialog.py:35 ../dialogs/FBDVariableDialog.py:33
-#: ../dialogs/SFCStepDialog.py:61
+#: ../dialogs/SFCStepDialog.py:70 ../dialogs/FBDVariableDialog.py:37
+#: ../dialogs/BrowseLocationsDialog.py:40 ../editors/Viewer.py:289
+#: ../editors/Viewer.py:1578 ../editors/TextViewer.py:307
+#: ../controls/LocationCellEditor.py:98 ../controls/VariablePanel.py:71
+#: ../controls/VariablePanel.py:291 ../controls/VariablePanel.py:351
msgid "Input"
msgstr ""
-#: ../dialogs/FBDBlockDialog.py:78
+#: ../dialogs/FBDBlockDialog.py:93
msgid "Inputs:"
msgstr ""
@@ -1803,22 +1861,16 @@
msgid "Insertion (into)"
msgstr ""
-#: ../plcopen/plcopen.py:1843
+#: ../plcopen/plcopen.py:1691
#, python-format
msgid "Instance with id %d doesn't exist!"
msgstr ""
-#: ../editors/ResourceEditor.py:255
+#: ../editors/ResourceEditor.py:264
msgid "Instances:"
msgstr ""
-#: ../plcopen/structures.py:258
-msgid ""
-"Integral\n"
-"The integral function block integrates the value of input XIN over time."
-msgstr ""
-
-#: ../controls/VariablePanel.py:75
+#: ../controls/VariablePanel.py:70
msgid "Interface"
msgstr ""
@@ -1830,33 +1882,40 @@
msgid "Interval"
msgstr ""
-#: ../PLCControler.py:2157 ../PLCControler.py:2195
+#: ../PLCControler.py:2325
msgid "Invalid plcopen element(s)!!!"
msgstr ""
-#: ../canfestival/config_utils.py:376 ../canfestival/config_utils.py:637
-#, python-format
-msgid "Invalid type \"%s\"-> %d != %d for location\"%s\""
+#: ../canfestival/config_utils.py:381
+#, python-brace-format
+msgid "Invalid type \"{a1}\"-> {a2} != {a3} for location\"{a4}\""
+msgstr ""
+
+#: ../canfestival/config_utils.py:645
+#, python-brace-format
+msgid "Invalid type \"{a1}\"-> {a2} != {a3} for location \"{a4}\""
+msgstr ""
+
+#: ../controls/DebugVariablePanel/DebugVariablePanel.py:132
+#: ../controls/DebugVariablePanel/DebugVariableTextViewer.py:92
+#: ../controls/DebugVariablePanel/DebugVariableGraphicViewer.py:166
+#, python-format
+msgid "Invalid value \"%s\" for debug variable"
+msgstr ""
+
+#: ../controls/VariablePanel.py:255 ../controls/VariablePanel.py:258
+#, python-format
+msgid "Invalid value \"%s\" for variable grid element"
+msgstr ""
+
+#: ../editors/Viewer.py:233 ../editors/Viewer.py:236
+#, python-format
+msgid "Invalid value \"%s\" for viewer block"
msgstr ""
#: ../dialogs/ForceVariableDialog.py:177
-#, python-format
-msgid "Invalid value \"%s\" for \"%s\" variable!"
-msgstr ""
-
-#: ../controls/DebugVariablePanel.py:319 ../controls/DebugVariablePanel.py:322
-#, python-format
-msgid "Invalid value \"%s\" for debug variable"
-msgstr ""
-
-#: ../controls/VariablePanel.py:244 ../controls/VariablePanel.py:247
-#, python-format
-msgid "Invalid value \"%s\" for variable grid element"
-msgstr ""
-
-#: ../editors/Viewer.py:221 ../editors/Viewer.py:224
-#, python-format
-msgid "Invalid value \"%s\" for viewer block"
+#, python-brace-format
+msgid "Invalid value \"{a1}\" for \"{a2}\" variable!"
msgstr ""
#: ../dialogs/DurationEditorDialog.py:121
@@ -1865,13 +1924,12 @@
"You must fill a numeric value."
msgstr ""
-#: ../editors/Viewer.py:496
+#: ../editors/Viewer.py:557 ../editors/Viewer.py:2343
msgid "Jump"
msgstr ""
-#: ../controls/ProjectPropertiesPanel.py:143
-#: ../dialogs/PouTransitionDialog.py:35 ../dialogs/PouActionDialog.py:31
-#: ../dialogs/PouDialog.py:36
+#: ../dialogs/PouTransitionDialog.py:40 ../dialogs/PouActionDialog.py:31
+#: ../dialogs/PouDialog.py:36 ../controls/ProjectPropertiesPanel.py:143
msgid "LD"
msgstr ""
@@ -1880,8 +1938,8 @@
msgid "Ladder element with id %d is on more than one rung."
msgstr ""
-#: ../dialogs/PouTransitionDialog.py:86 ../dialogs/PouActionDialog.py:83
-#: ../dialogs/PouDialog.py:102
+#: ../dialogs/PouTransitionDialog.py:91 ../dialogs/PouActionDialog.py:83
+#: ../dialogs/PouDialog.py:104
msgid "Language"
msgstr ""
@@ -1889,28 +1947,28 @@
msgid "Language (optional):"
msgstr ""
-#: ../dialogs/PouTransitionDialog.py:60 ../dialogs/PouActionDialog.py:56
-#: ../dialogs/PouDialog.py:71
+#: ../dialogs/PouTransitionDialog.py:65 ../dialogs/PouActionDialog.py:56
+#: ../dialogs/PouDialog.py:73
msgid "Language:"
msgstr ""
-#: ../ProjectController.py:1486
+#: ../ProjectController.py:1735
msgid "Latest build already matches current target. Transfering anyway...\n"
msgstr ""
-#: ../Beremiz_service.py:331
+#: ../Beremiz_service.py:271
msgid "Launch WX GUI inspector"
msgstr ""
-#: ../Beremiz_service.py:330
+#: ../Beremiz_service.py:270
msgid "Launch a live Python shell"
msgstr ""
-#: ../editors/Viewer.py:427
+#: ../editors/Viewer.py:485
msgid "Left"
msgstr ""
-#: ../dialogs/LDPowerRailDialog.py:55
+#: ../dialogs/LDPowerRailDialog.py:62
msgid "Left PowerRail"
msgstr ""
@@ -1926,35 +1984,39 @@
msgid "Less than or equal to"
msgstr ""
-#: ../IDEFrame.py:604
+#: ../IDEFrame.py:631
msgid "Library"
msgstr ""
+#: ../dialogs/AboutDialog.py:143
+msgid "License"
+msgstr ""
+
#: ../plcopen/iec_std.csv:73
msgid "Limitation"
msgstr ""
-#: ../targets/toolchain_gcc.py:142
+#: ../targets/toolchain_gcc.py:166
msgid "Linking :\n"
msgstr ""
-#: ../controls/VariablePanel.py:77 ../dialogs/DiscoveryDialog.py:110
+#: ../dialogs/DiscoveryDialog.py:111 ../controls/VariablePanel.py:72
msgid "Local"
msgstr ""
-#: ../canfestival/canfestival.py:322
+#: ../canfestival/canfestival.py:346
msgid "Local entries"
msgstr ""
-#: ../ProjectController.py:1391
+#: ../ProjectController.py:1641
msgid "Local service discovery failed!\n"
msgstr ""
-#: ../controls/VariablePanel.py:58
+#: ../controls/VariablePanel.py:53
msgid "Location"
msgstr ""
-#: ../dialogs/BrowseLocationsDialog.py:68
+#: ../dialogs/BrowseLocationsDialog.py:72
msgid "Locations available:"
msgstr ""
@@ -1962,41 +2024,43 @@
msgid "Logarithm to base 10"
msgstr ""
-#: ../connectors/PYRO/__init__.py:55
+#: ../connectors/PYRO/__init__.py:94
#, python-format
msgid "MDNS resolution failure for '%s'\n"
msgstr ""
-#: ../canfestival/SlaveEditor.py:41 ../canfestival/NetworkEditor.py:62
+#: ../canfestival/SlaveEditor.py:64 ../canfestival/NetworkEditor.py:85
msgid "Map Variable"
msgstr ""
-#: ../features.py:7
+#: ../features.py:31
msgid "Map located variables over CANopen"
msgstr ""
-#: ../canfestival/NetworkEditor.py:83
+#: ../canfestival/NetworkEditor.py:106
msgid "Master"
msgstr ""
-#: ../ConfigTreeNode.py:500
-#, python-format
-msgid "Max count (%d) reached for this confnode of type %s "
+#: ../ConfigTreeNode.py:539
+#, python-brace-format
+msgid "Max count ({a1}) reached for this confnode of type {a2} "
msgstr ""
#: ../plcopen/iec_std.csv:71
msgid "Maximum"
msgstr ""
-#: ../editors/DataTypeEditor.py:238
+#: ../editors/DataTypeEditor.py:239
msgid "Maximum:"
msgstr ""
-#: ../dialogs/BrowseLocationsDialog.py:37
+#: ../dialogs/BrowseLocationsDialog.py:42 ../editors/Viewer.py:289
+#: ../editors/TextViewer.py:307 ../controls/LocationCellEditor.py:98
+#: ../controls/VariablePanel.py:291 ../controls/VariablePanel.py:351
msgid "Memory"
msgstr ""
-#: ../IDEFrame.py:572
+#: ../IDEFrame.py:599
msgid "Menu ToolBar"
msgstr ""
@@ -2004,7 +2068,7 @@
msgid "Microseconds:"
msgstr ""
-#: ../editors/Viewer.py:432
+#: ../editors/Viewer.py:490
msgid "Middle"
msgstr ""
@@ -2016,7 +2080,7 @@
msgid "Minimum"
msgstr ""
-#: ../editors/DataTypeEditor.py:225
+#: ../editors/DataTypeEditor.py:226
msgid "Minimum:"
msgstr ""
@@ -2028,60 +2092,52 @@
msgid "Miscellaneous"
msgstr ""
-#: ../dialogs/LDElementDialog.py:59
+#: ../dialogs/LDElementDialog.py:63
msgid "Modifier:"
msgstr ""
-#: ../PLCGenerator.py:732 ../PLCGenerator.py:975
-#, python-format
-msgid "More than one connector found corresponding to \"%s\" continuation in \"%s\" POU"
-msgstr ""
-
-#: ../dialogs/ActionBlockDialog.py:141
+#: ../PLCGenerator.py:786 ../PLCGenerator.py:1230
+#, python-brace-format
+msgid "More than one connector found corresponding to \"{a1}\" continuation in \"{a2}\" POU"
+msgstr ""
+
+#: ../dialogs/ActionBlockDialog.py:140
msgid "Move action down"
msgstr ""
-#: ../dialogs/ActionBlockDialog.py:140
+#: ../dialogs/ActionBlockDialog.py:139
msgid "Move action up"
msgstr ""
-#: ../controls/DebugVariablePanel.py:1532
-msgid "Move debug variable down"
-msgstr ""
-
-#: ../controls/DebugVariablePanel.py:1531
-msgid "Move debug variable up"
-msgstr ""
-
#: ../controls/CustomEditableListBox.py:43
msgid "Move down"
msgstr ""
+#: ../editors/DataTypeEditor.py:355
+msgid "Move element down"
+msgstr ""
+
#: ../editors/DataTypeEditor.py:354
-msgid "Move element down"
-msgstr ""
-
-#: ../editors/DataTypeEditor.py:353
msgid "Move element up"
msgstr ""
-#: ../editors/ResourceEditor.py:262
+#: ../editors/ResourceEditor.py:271
msgid "Move instance down"
msgstr ""
-#: ../editors/ResourceEditor.py:261
+#: ../editors/ResourceEditor.py:270
msgid "Move instance up"
msgstr ""
-#: ../editors/ResourceEditor.py:233
+#: ../editors/ResourceEditor.py:242
msgid "Move task down"
msgstr ""
-#: ../editors/ResourceEditor.py:232
+#: ../editors/ResourceEditor.py:241
msgid "Move task up"
msgstr ""
-#: ../IDEFrame.py:82 ../IDEFrame.py:97 ../IDEFrame.py:127 ../IDEFrame.py:168
+#: ../IDEFrame.py:99 ../IDEFrame.py:114 ../IDEFrame.py:144 ../IDEFrame.py:185
msgid "Move the view"
msgstr ""
@@ -2089,11 +2145,11 @@
msgid "Move up"
msgstr ""
-#: ../controls/VariablePanel.py:383 ../c_ext/CFileEditor.py:520
+#: ../editors/CodeFileEditor.py:661 ../controls/VariablePanel.py:453
msgid "Move variable down"
msgstr ""
-#: ../controls/VariablePanel.py:382 ../c_ext/CFileEditor.py:519
+#: ../editors/CodeFileEditor.py:660 ../controls/VariablePanel.py:452
msgid "Move variable up"
msgstr ""
@@ -2109,19 +2165,22 @@
msgid "My Computer:"
msgstr ""
-#: ../controls/VariablePanel.py:58 ../controls/VariablePanel.py:59
-#: ../editors/DataTypeEditor.py:50 ../editors/ResourceEditor.py:68
-#: ../editors/ResourceEditor.py:77
+#: ../dialogs/DiscoveryDialog.py:92
+msgid "NAME"
+msgstr ""
+
+#: ../editors/ResourceEditor.py:68 ../editors/ResourceEditor.py:83
+#: ../editors/DataTypeEditor.py:50 ../controls/VariablePanel.py:53
+#: ../controls/VariablePanel.py:54
msgid "Name"
msgstr ""
-#: ../Beremiz_service.py:386
+#: ../Beremiz_service.py:332
msgid "Name must not be null!"
msgstr ""
-#: ../dialogs/ConnectionDialog.py:65 ../dialogs/FBDVariableDialog.py:89
-#: ../dialogs/LDElementDialog.py:88 ../dialogs/SFCStepDialog.py:51
-#: ../dialogs/FBDBlockDialog.py:70
+#: ../dialogs/SFCStepDialog.py:56 ../dialogs/FBDBlockDialog.py:83
+#: ../dialogs/ConnectionDialog.py:75
msgid "Name:"
msgstr ""
@@ -2129,12 +2188,20 @@
msgid "Natural logarithm"
msgstr ""
-#: ../editors/Viewer.py:402 ../dialogs/LDElementDialog.py:67
+#: ../dialogs/LDElementDialog.py:75 ../editors/Viewer.py:460
msgid "Negated"
msgstr ""
-#: ../Beremiz.py:309 ../Beremiz.py:344 ../PLCOpenEditor.py:106
-#: ../PLCOpenEditor.py:148
+#: ../Beremiz_service.py:578
+msgid "Nevow Web service failed. "
+msgstr ""
+
+#: ../Beremiz_service.py:554
+msgid "Nevow/Athena import failed :"
+msgstr ""
+
+#: ../PLCOpenEditor.py:102 ../PLCOpenEditor.py:144 ../Beremiz.py:321
+#: ../Beremiz.py:356
msgid "New"
msgstr ""
@@ -2142,94 +2209,91 @@
msgid "New item"
msgstr ""
-#: ../editors/Viewer.py:401
+#: ../editors/Viewer.py:459
msgid "No Modifier"
msgstr ""
-#: ../PLCControler.py:3054
-msgid "No PLC project found"
-msgstr ""
-
-#: ../ProjectController.py:1513
+#: ../ProjectController.py:1763
msgid "No PLC to transfer (did build succeed ?)\n"
msgstr ""
-#: ../PLCGenerator.py:1360
+#: ../PLCGenerator.py:1631
#, python-format
msgid "No body defined in \"%s\" POU"
msgstr ""
-#: ../PLCGenerator.py:751 ../PLCGenerator.py:984
-#, python-format
-msgid "No connector found corresponding to \"%s\" continuation in \"%s\" POU"
-msgstr ""
-
-#: ../PLCOpenEditor.py:349
+#: ../PLCGenerator.py:806 ../PLCGenerator.py:1241
+#, python-brace-format
+msgid "No connector found corresponding to \"{a1}\" continuation in \"{a2}\" POU"
+msgstr ""
+
+#: ../PLCOpenEditor.py:347
msgid ""
"No documentation available.\n"
"Coming soon."
msgstr ""
-#: ../PLCGenerator.py:773
+#: ../PLCGenerator.py:829
#, python-format
msgid "No informations found for \"%s\" block"
msgstr ""
-#: ../plcopen/structures.py:166
-msgid "No output variable found"
+#: ../PLCGenerator.py:1194
+#, python-brace-format
+msgid "No output {a1} variable found in block {a2} in POU {a3}. Connection must be broken"
msgstr ""
#: ../controls/SearchResultPanel.py:169
msgid "No search results available."
msgstr ""
-#: ../svgui/svgui.py:98
+#: ../svgui/svgui.py:131
#, python-format
msgid "No such SVG file: %s\n"
msgstr ""
-#: ../canfestival/config_utils.py:632
-#, python-format
-msgid "No such index/subindex (%x,%x) (variable %s)"
-msgstr ""
-
-#: ../canfestival/config_utils.py:361
-#, python-format
-msgid "No such index/subindex (%x,%x) in ID : %d (variable %s)"
+#: ../canfestival/config_utils.py:639
+#, python-brace-format
+msgid "No such index/subindex ({a1},{a2}) (variable {a3})"
+msgstr ""
+
+#: ../canfestival/config_utils.py:362
+#, python-brace-format
+msgid "No such index/subindex ({a1},{a2}) in ID : {a3} (variable {a4})"
msgstr ""
#: ../dialogs/BrowseValuesLibraryDialog.py:83
msgid "No valid value selected!"
msgstr ""
-#: ../PLCGenerator.py:1358
+#: ../PLCGenerator.py:1629
#, python-format
msgid "No variable defined in \"%s\" POU"
msgstr ""
-#: ../canfestival/config_utils.py:354
-#, python-format
-msgid "Non existing node ID : %d (variable %s)"
-msgstr ""
-
-#: ../controls/VariablePanel.py:69
+#: ../canfestival/config_utils.py:355
+#, python-brace-format
+msgid "Non existing node ID : {a1} (variable {a2})"
+msgstr ""
+
+#: ../controls/VariablePanel.py:64
msgid "Non-Retain"
msgstr ""
-#: ../dialogs/LDElementDialog.py:62
+#: ../dialogs/LDElementDialog.py:75
msgid "Normal"
msgstr ""
-#: ../canfestival/config_utils.py:383
-#, python-format
-msgid "Not PDO mappable variable : '%s' (ID:%d,Idx:%x,sIdx:%x))"
+#: ../canfestival/config_utils.py:389
+#, python-brace-format
+msgid "Not PDO mappable variable : '{a1}' (ID:{a2},Idx:{a3},sIdx:{a4}))"
msgstr ""
#: ../plcopen/iec_std.csv:80
msgid "Not equal to"
msgstr ""
-#: ../dialogs/SFCDivergenceDialog.py:80
+#: ../dialogs/SFCDivergenceDialog.py:89
msgid "Number of sequences:"
msgstr ""
@@ -2237,44 +2301,36 @@
msgid "Numerical"
msgstr ""
-#: ../plcopen/structures.py:246
-msgid ""
-"Off-delay timer\n"
-"The off-delay timer can be used to delay setting an output false, for fixed period after input goes false."
-msgstr ""
-
-#: ../plcopen/structures.py:241
-msgid ""
-"On-delay timer\n"
-"The on-delay timer can be used to delay setting an output true, for fixed period after an input becomes true."
-msgstr ""
-
-#: ../dialogs/SearchInProjectDialog.py:93
+#: ../dialogs/SearchInProjectDialog.py:86
msgid "Only Elements"
msgstr ""
-#: ../Beremiz.py:311 ../Beremiz.py:345 ../PLCOpenEditor.py:108
-#: ../PLCOpenEditor.py:149
+#: ../PLCOpenEditor.py:104 ../PLCOpenEditor.py:145 ../Beremiz.py:323
+#: ../Beremiz.py:357
msgid "Open"
msgstr ""
-#: ../svgui/svgui.py:107
+#: ../svgui/svgui.py:140
msgid "Open Inkscape"
msgstr ""
-#: ../ProjectController.py:1565
+#: ../version.py:66
+msgid "Open Source framework for automation, implemented IEC 61131 IDE with constantly growing set of extensions and flexible PLC runtime."
+msgstr ""
+
+#: ../ProjectController.py:1815
msgid "Open a file explorer to manage project files"
msgstr ""
-#: ../wxglade_hmi/wxglade_hmi.py:109
+#: ../wxglade_hmi/wxglade_hmi.py:138
msgid "Open wxGlade"
msgstr ""
-#: ../controls/VariablePanel.py:58 ../controls/VariablePanel.py:59
+#: ../controls/VariablePanel.py:53 ../controls/VariablePanel.py:54
msgid "Option"
msgstr ""
-#: ../dialogs/FindInPouDialog.py:76
+#: ../dialogs/FindInPouDialog.py:83
msgid "Options"
msgstr ""
@@ -2282,63 +2338,99 @@
msgid "Organization (optional):"
msgstr ""
-#: ../canfestival/SlaveEditor.py:51 ../canfestival/NetworkEditor.py:72
+#: ../canfestival/SlaveEditor.py:74 ../canfestival/NetworkEditor.py:95
msgid "Other Profile"
msgstr ""
-#: ../controls/VariablePanel.py:76 ../editors/Viewer.py:1411
-#: ../dialogs/BrowseLocationsDialog.py:36 ../dialogs/FBDVariableDialog.py:35
-#: ../dialogs/SFCStepDialog.py:65
+#: ../dialogs/SFCStepDialog.py:71 ../dialogs/FBDVariableDialog.py:39
+#: ../dialogs/BrowseLocationsDialog.py:41 ../editors/Viewer.py:289
+#: ../editors/Viewer.py:1579 ../editors/TextViewer.py:307
+#: ../controls/LocationCellEditor.py:98 ../controls/VariablePanel.py:71
+#: ../controls/VariablePanel.py:291 ../controls/VariablePanel.py:351
msgid "Output"
msgstr ""
-#: ../canfestival/SlaveEditor.py:40 ../canfestival/NetworkEditor.py:61
+#: ../canfestival/SlaveEditor.py:63 ../canfestival/NetworkEditor.py:84
msgid "PDO Receive"
msgstr ""
-#: ../canfestival/SlaveEditor.py:39 ../canfestival/NetworkEditor.py:60
+#: ../canfestival/SlaveEditor.py:62 ../canfestival/NetworkEditor.py:83
msgid "PDO Transmit"
msgstr ""
-#: ../plcopen/structures.py:268
+#: ../targets/toolchain_gcc.py:131
+msgid "PLC :\n"
+msgstr ""
+
+#: ../Beremiz.py:453
+msgid "PLC Log"
+msgstr ""
+
+#: ../ProjectController.py:992
+msgid "PLC code generation failed !\n"
+msgstr ""
+
+#: ../Beremiz_service.py:295
+msgid "PLC is empty or already started."
+msgstr ""
+
+#: ../Beremiz_service.py:302
+msgid "PLC is not started."
+msgstr ""
+
+#: ../PLCOpenEditor.py:196 ../PLCOpenEditor.py:309
+#, python-brace-format
msgid ""
-"PID\n"
-"The PID (proportional, Integral, Derivative) function block provides the classical three term controller for closed loop control."
-msgstr ""
-
-#: ../targets/toolchain_gcc.py:107
-msgid "PLC :\n"
-msgstr ""
-
-#: ../Beremiz.py:425
-msgid "PLC Log"
-msgstr ""
-
-#: ../PLCOpenEditor.py:294 ../PLCOpenEditor.py:370
+"PLC syntax error at line {a1}:\n"
+"{a2}"
+msgstr ""
+
+#: ../PLCOpenEditor.py:292 ../PLCOpenEditor.py:373
msgid "PLCOpen files (*.xml)|*.xml|All files|*.*"
msgstr ""
-#: ../PLCOpenEditor.py:156 ../PLCOpenEditor.py:212
+#: ../PLCOpenEditor.py:152 ../PLCOpenEditor.py:209
msgid "PLCOpenEditor"
msgstr ""
-#: ../dialogs/PouDialog.py:98
+#: ../PLCOpenEditor.py:355
+msgid ""
+"PLCOpenEditor is part of Beremiz project.\n"
+"\n"
+"Beremiz is an "
+msgstr ""
+
+#: ../dialogs/DiscoveryDialog.py:95
+msgid "PORT"
+msgstr ""
+
+#: ../dialogs/PouDialog.py:100
msgid "POU Name"
msgstr ""
-#: ../dialogs/PouDialog.py:56
+#: ../dialogs/PouDialog.py:58
msgid "POU Name:"
msgstr ""
-#: ../dialogs/PouDialog.py:100
+#: ../dialogs/PouDialog.py:102
msgid "POU Type"
msgstr ""
-#: ../dialogs/PouDialog.py:63
+#: ../dialogs/PouDialog.py:65
msgid "POU Type:"
msgstr ""
-#: ../Beremiz.py:324 ../PLCOpenEditor.py:122
+#: ../connectors/PYRO/__init__.py:45
+#, python-format
+msgid "PYRO connecting to URI : %s\n"
+msgstr ""
+
+#: ../connectors/PYRO/__init__.py:61
+#, python-format
+msgid "PYRO using certificates in '%s' \n"
+msgstr ""
+
+#: ../PLCOpenEditor.py:118 ../Beremiz.py:336
msgid "Page Setup"
msgstr ""
@@ -2346,88 +2438,88 @@
msgid "Page Size (optional):"
msgstr ""
-#: ../IDEFrame.py:2492
+#: ../IDEFrame.py:2599
#, python-format
msgid "Page: %d"
msgstr ""
-#: ../controls/PouInstanceVariablesPanel.py:48
+#: ../controls/PouInstanceVariablesPanel.py:124
msgid "Parent instance"
msgstr ""
-#: ../IDEFrame.py:355 ../IDEFrame.py:407 ../editors/Viewer.py:537
+#: ../editors/Viewer.py:598 ../IDEFrame.py:372 ../IDEFrame.py:426
msgid "Paste"
msgstr ""
-#: ../IDEFrame.py:1776
+#: ../IDEFrame.py:1865
msgid "Paste POU"
msgstr ""
-#: ../dialogs/SearchInProjectDialog.py:64
+#: ../dialogs/SearchInProjectDialog.py:56
msgid "Pattern to search:"
msgstr ""
-#: ../dialogs/LDPowerRailDialog.py:64
+#: ../dialogs/LDPowerRailDialog.py:73
msgid "Pin number:"
msgstr ""
-#: ../editors/Viewer.py:2363 ../editors/Viewer.py:2670
-#: ../editors/SFCViewer.py:696
+#: ../editors/Viewer.py:2706 ../editors/Viewer.py:2963
+#: ../editors/SFCViewer.py:770
msgid "Please choose a target"
msgstr ""
-#: ../editors/Viewer.py:2186 ../editors/Viewer.py:2188
-#: ../editors/Viewer.py:2706 ../editors/Viewer.py:2708
+#: ../editors/TextViewer.py:262
+msgid "Please enter a block name"
+msgstr ""
+
+#: ../editors/Viewer.py:2576 ../editors/Viewer.py:3005
msgid "Please enter comment text"
msgstr ""
-#: ../editors/SFCViewer.py:359 ../editors/SFCViewer.py:381
-#: ../editors/SFCViewer.py:725
+#: ../editors/SFCViewer.py:433 ../editors/SFCViewer.py:455
+#: ../editors/SFCViewer.py:799
msgid "Please enter step name"
msgstr ""
+#: ../Beremiz_service.py:194
+msgid "Please enter text"
+msgstr ""
+
#: ../dialogs/ForceVariableDialog.py:163
#, python-format
msgid "Please enter value for a \"%s\" variable:"
msgstr ""
-#: ../Beremiz_service.py:371
+#: ../Beremiz_service.py:317
msgid "Port number must be 0 <= port <= 65535!"
msgstr ""
-#: ../Beremiz_service.py:371
+#: ../Beremiz_service.py:317
msgid "Port number must be an integer!"
msgstr ""
-#: ../editors/GraphicViewer.py:105
-msgid "Position:"
-msgstr ""
-
-#: ../editors/Viewer.py:475
+#: ../editors/Viewer.py:536 ../editors/Viewer.py:2367
msgid "Power Rail"
msgstr ""
-#: ../dialogs/LDPowerRailDialog.py:36
+#: ../dialogs/LDPowerRailDialog.py:50
msgid "Power Rail Properties"
msgstr ""
-#: ../Beremiz.py:326 ../PLCOpenEditor.py:124
+#: ../PLCOpenEditor.py:120 ../Beremiz.py:338
msgid "Preview"
msgstr ""
-#: ../dialogs/SFCDivergenceDialog.py:93 ../dialogs/LDPowerRailDialog.py:78
-#: ../dialogs/ConnectionDialog.py:78 ../dialogs/FBDVariableDialog.py:97
-#: ../dialogs/SFCTransitionDialog.py:96 ../dialogs/LDElementDialog.py:101
-#: ../dialogs/SFCStepDialog.py:79 ../dialogs/FBDBlockDialog.py:103
+#: ../dialogs/BlockPreviewDialog.py:57
msgid "Preview:"
msgstr ""
-#: ../Beremiz.py:328 ../Beremiz.py:348 ../PLCOpenEditor.py:126
-#: ../PLCOpenEditor.py:152
+#: ../PLCOpenEditor.py:122 ../PLCOpenEditor.py:148 ../Beremiz.py:340
+#: ../Beremiz.py:360
msgid "Print"
msgstr ""
-#: ../IDEFrame.py:1038
+#: ../IDEFrame.py:1075
msgid "Print preview"
msgstr ""
@@ -2435,15 +2527,19 @@
msgid "Priority"
msgstr ""
-#: ../dialogs/SFCTransitionDialog.py:83
+#: ../dialogs/SFCTransitionDialog.py:89
msgid "Priority:"
msgstr ""
-#: ../runtime/PLCObject.py:318
+#: ../runtime/PLCObject.py:370
#, python-format
msgid "Problem starting PLC : error %d"
msgstr ""
+#: ../dialogs/ProjectDialog.py:55
+msgid "Product Name"
+msgstr ""
+
#: ../controls/ProjectPropertiesPanel.py:80
msgid "Product Name (required):"
msgstr ""
@@ -2452,27 +2548,32 @@
msgid "Product Release (optional):"
msgstr ""
+#: ../dialogs/ProjectDialog.py:56
+msgid "Product Version"
+msgstr ""
+
#: ../controls/ProjectPropertiesPanel.py:81
msgid "Product Version (required):"
msgstr ""
-#: ../IDEFrame.py:1848 ../dialogs/SearchInProjectDialog.py:46
+#: ../dialogs/SearchInProjectDialog.py:38 ../IDEFrame.py:1744
+#: ../IDEFrame.py:1941
msgid "Program"
msgstr ""
-#: ../PLCOpenEditor.py:339
+#: ../PLCOpenEditor.py:337
msgid "Program was successfully generated!"
msgstr ""
-#: ../PLCControler.py:95
+#: ../PLCControler.py:96
msgid "Programs"
msgstr ""
-#: ../editors/Viewer.py:230
+#: ../editors/Viewer.py:242
msgid "Programs can't be used by other POUs!"
msgstr ""
-#: ../controls/ProjectPropertiesPanel.py:84 ../IDEFrame.py:557
+#: ../controls/ProjectPropertiesPanel.py:84 ../IDEFrame.py:584
msgid "Project"
msgstr ""
@@ -2481,10 +2582,14 @@
msgid "Project '%s':"
msgstr ""
-#: ../ProjectController.py:1564
+#: ../ProjectController.py:1814
msgid "Project Files"
msgstr ""
+#: ../dialogs/ProjectDialog.py:54
+msgid "Project Name"
+msgstr ""
+
#: ../controls/ProjectPropertiesPanel.py:78
msgid "Project Name (required):"
msgstr ""
@@ -2493,103 +2598,96 @@
msgid "Project Version (optional):"
msgstr ""
-#: ../PLCControler.py:3041
+#: ../PLCControler.py:3158
msgid ""
"Project file syntax error:\n"
"\n"
msgstr ""
-#: ../editors/ProjectNodeEditor.py:14 ../dialogs/ProjectDialog.py:32
+#: ../dialogs/ProjectDialog.py:32 ../editors/ProjectNodeEditor.py:37
msgid "Project properties"
msgstr ""
-#: ../ConfigTreeNode.py:526
-#, python-format
-msgid "Project tree layout do not match confnode.xml %s!=%s "
-msgstr ""
-
-#: ../dialogs/ConnectionDialog.py:96
+#: ../ConfigTreeNode.py:566
+#, python-brace-format
+msgid "Project tree layout do not match confnode.xml {a1}!={a2} "
+msgstr ""
+
+#: ../dialogs/ConnectionDialog.py:94
msgid "Propagate Name"
msgstr ""
-#: ../PLCControler.py:96
+#: ../PLCControler.py:97
msgid "Properties"
msgstr ""
-#: ../plcopen/structures.py:236
-msgid ""
-"Pulse timer\n"
-"The pulse timer can be used to generate output pulses of a given time duration."
-msgstr ""
-
-#: ../py_ext/PythonEditor.py:61
+#: ../Beremiz_service.py:440
+msgid "Publishing service on local network"
+msgstr ""
+
+#: ../connectors/PYRO/__init__.py:118
+#, python-format
+msgid "Pyro exception: %s\n"
+msgstr ""
+
+#: ../Beremiz_service.py:427
+msgid "Pyro object's uri :"
+msgstr ""
+
+#: ../Beremiz_service.py:426
+msgid "Pyro port :"
+msgstr ""
+
+#: ../py_ext/PythonEditor.py:81
msgid "Python code"
msgstr ""
-#: ../features.py:9
+#: ../features.py:33
msgid "Python file"
msgstr ""
-#: ../dialogs/ActionBlockDialog.py:37
+#: ../dialogs/ActionBlockDialog.py:38
msgid "Qualifier"
msgstr ""
-#: ../Beremiz_service.py:333 ../Beremiz.py:331 ../PLCOpenEditor.py:132
+#: ../PLCOpenEditor.py:128 ../Beremiz.py:343 ../Beremiz_service.py:273
msgid "Quit"
msgstr ""
-#: ../plcopen/structures.py:201
-msgid ""
-"RS bistable\n"
-"The RS bistable is a latch where the Reset dominates."
-msgstr ""
-
-#: ../plcopen/structures.py:273
-msgid ""
-"Ramp\n"
-"The RAMP function block is modelled on example given in the standard."
-msgstr ""
-
-#: ../controls/DebugVariablePanel.py:1462 ../editors/GraphicViewer.py:89
+#: ../controls/DebugVariablePanel/DebugVariablePanel.py:225
msgid "Range:"
msgstr ""
-#: ../ProjectController.py:1560
+#: ../ProjectController.py:1810
msgid "Raw IEC code"
msgstr ""
-#: ../plcopen/structures.py:253
-msgid ""
-"Real time clock\n"
-"The real time clock has many uses including time stamping, setting dates and times of day in batch reports, in alarm messages and so on."
-msgstr ""
-
-#: ../Beremiz.py:1072
+#: ../Beremiz.py:1143
#, python-format
msgid "Really delete node '%s'?"
msgstr ""
-#: ../IDEFrame.py:345 ../IDEFrame.py:403
+#: ../IDEFrame.py:362 ../IDEFrame.py:422
msgid "Redo"
msgstr ""
-#: ../dialogs/SFCTransitionDialog.py:57 ../dialogs/SFCTransitionDialog.py:135
+#: ../dialogs/SFCTransitionDialog.py:74
msgid "Reference"
msgstr ""
-#: ../IDEFrame.py:413 ../dialogs/DiscoveryDialog.py:105
+#: ../dialogs/DiscoveryDialog.py:106 ../IDEFrame.py:432
msgid "Refresh"
msgstr ""
-#: ../dialogs/SearchInProjectDialog.py:73
+#: ../dialogs/SearchInProjectDialog.py:66
msgid "Regular expression"
msgstr ""
-#: ../dialogs/FindInPouDialog.py:91
+#: ../dialogs/FindInPouDialog.py:98
msgid "Regular expressions"
msgstr ""
-#: ../controls/DebugVariablePanel.py:1938 ../editors/Viewer.py:1388
+#: ../editors/Viewer.py:1556
msgid "Release value"
msgstr ""
@@ -2597,20 +2695,24 @@
msgid "Remainder (modulo)"
msgstr ""
-#: ../Beremiz.py:1073
+#: ../Beremiz.py:1144
#, python-format
msgid "Remove %s node"
msgstr ""
-#: ../dialogs/ActionBlockDialog.py:139
+#: ../IDEFrame.py:2405
+msgid "Remove Datatype"
+msgstr ""
+
+#: ../IDEFrame.py:2410
+msgid "Remove Pou"
+msgstr ""
+
+#: ../dialogs/ActionBlockDialog.py:138
msgid "Remove action"
msgstr ""
-#: ../controls/DebugVariablePanel.py:1530
-msgid "Remove debug variable"
-msgstr ""
-
-#: ../editors/DataTypeEditor.py:352
+#: ../editors/DataTypeEditor.py:353
msgid "Remove element"
msgstr ""
@@ -2618,23 +2720,23 @@
msgid "Remove file from left folder"
msgstr ""
-#: ../editors/ResourceEditor.py:260
+#: ../editors/ResourceEditor.py:269
msgid "Remove instance"
msgstr ""
-#: ../canfestival/NetworkEditor.py:81
+#: ../canfestival/NetworkEditor.py:104
msgid "Remove slave"
msgstr ""
-#: ../editors/ResourceEditor.py:231
+#: ../editors/ResourceEditor.py:240
msgid "Remove task"
msgstr ""
-#: ../controls/VariablePanel.py:381 ../c_ext/CFileEditor.py:518
+#: ../editors/CodeFileEditor.py:659 ../controls/VariablePanel.py:451
msgid "Remove variable"
msgstr ""
-#: ../IDEFrame.py:1852
+#: ../IDEFrame.py:1945
msgid "Rename"
msgstr ""
@@ -2642,6 +2744,10 @@
msgid "Replace File"
msgstr ""
+#: ../editors/Viewer.py:502
+msgid "Replace Wire by connections"
+msgstr ""
+
#: ../plcopen/iec_std.csv:89
msgid "Replacement (within)"
msgstr ""
@@ -2650,11 +2756,11 @@
msgid "Reset"
msgstr ""
-#: ../editors/Viewer.py:521
+#: ../editors/Viewer.py:583
msgid "Reset Execution Order"
msgstr ""
-#: ../IDEFrame.py:428
+#: ../IDEFrame.py:451
msgid "Reset Perspective"
msgstr ""
@@ -2662,40 +2768,30 @@
msgid "Reset search result"
msgstr ""
-#: ../editors/GraphicViewer.py:137
-msgid "Reset zoom and offset"
-msgstr ""
-
-#: ../PLCControler.py:96
+#: ../PLCControler.py:97 ../Beremiz.py:1075
msgid "Resources"
msgstr ""
-#: ../controls/VariablePanel.py:67
+#: ../controls/VariablePanel.py:62
msgid "Retain"
msgstr ""
-#: ../controls/VariablePanel.py:354
+#: ../controls/VariablePanel.py:424
msgid "Return Type:"
msgstr ""
-#: ../editors/Viewer.py:429
+#: ../editors/Viewer.py:487
msgid "Right"
msgstr ""
-#: ../dialogs/LDPowerRailDialog.py:60
+#: ../dialogs/LDPowerRailDialog.py:63
msgid "Right PowerRail"
msgstr ""
-#: ../editors/Viewer.py:403 ../dialogs/LDElementDialog.py:80
+#: ../dialogs/LDElementDialog.py:77 ../editors/Viewer.py:461
msgid "Rising Edge"
msgstr ""
-#: ../plcopen/structures.py:211
-msgid ""
-"Rising edge detector\n"
-"The output produces a single pulse when a rising edge is detected."
-msgstr ""
-
#: ../plcopen/iec_std.csv:65
msgid "Rotate left"
msgstr ""
@@ -2708,72 +2804,83 @@
msgid "Rounding up/down"
msgstr ""
-#: ../ProjectController.py:1528
+#: ../ProjectController.py:1778
msgid "Run"
msgstr ""
-#: ../ProjectController.py:865 ../ProjectController.py:874
-msgid "Runtime extensions C code generation failed !\n"
-msgstr ""
-
-#: ../canfestival/SlaveEditor.py:38 ../canfestival/NetworkEditor.py:59
+#: ../ProjectController.py:1037
+msgid "Runtime IO extensions C code generation failed !\n"
+msgstr ""
+
+#: ../ProjectController.py:1046
+msgid "Runtime library extensions C code generation failed !\n"
+msgstr ""
+
+#: ../canfestival/SlaveEditor.py:61 ../canfestival/NetworkEditor.py:82
msgid "SDO Client"
msgstr ""
-#: ../canfestival/SlaveEditor.py:37 ../canfestival/NetworkEditor.py:58
+#: ../canfestival/SlaveEditor.py:60 ../canfestival/NetworkEditor.py:81
msgid "SDO Server"
msgstr ""
-#: ../controls/ProjectPropertiesPanel.py:143 ../dialogs/PouDialog.py:36
+#: ../dialogs/PouDialog.py:36 ../controls/ProjectPropertiesPanel.py:143
msgid "SFC"
msgstr ""
-#: ../plcopen/structures.py:196
-msgid ""
-"SR bistable\n"
-"The SR bistable is a latch where the Set dominates."
-msgstr ""
-
-#: ../dialogs/PouTransitionDialog.py:35 ../dialogs/PouActionDialog.py:31
+#: ../PLCGenerator.py:1392
+#, python-brace-format
+msgid "SFC jump in pou \"{a1}\" refers to non-existent SFC step \"{a2}\""
+msgstr ""
+
+#: ../PLCGenerator.py:773
+#, python-format
+msgid "SFC transition in POU \"%s\" must be connected."
+msgstr ""
+
+#: ../dialogs/PouTransitionDialog.py:40 ../dialogs/PouActionDialog.py:31
#: ../dialogs/PouDialog.py:36
msgid "ST"
msgstr ""
-#: ../PLCOpenEditor.py:326
+#: ../PLCOpenEditor.py:324
msgid "ST files (*.st)|*.st|All files|*.*"
msgstr ""
-#: ../svgui/svgui.py:92
+#: ../svgui/svgui.py:125
msgid "SVG files (*.svg)|*.svg|All files|*.*"
msgstr ""
-#: ../features.py:11
+#: ../features.py:35
msgid "SVGUI"
msgstr ""
-#: ../Beremiz.py:315 ../Beremiz.py:346 ../PLCOpenEditor.py:115
-#: ../PLCOpenEditor.py:150
+#: ../PLCOpenEditor.py:111 ../PLCOpenEditor.py:146 ../Beremiz.py:327
+#: ../Beremiz.py:358
msgid "Save"
msgstr ""
-#: ../Beremiz.py:347 ../PLCOpenEditor.py:117 ../PLCOpenEditor.py:151
+#: ../PLCOpenEditor.py:113 ../PLCOpenEditor.py:147 ../Beremiz.py:359
msgid "Save As..."
msgstr ""
-#: ../Beremiz.py:317
+#: ../Beremiz.py:329
msgid "Save as"
msgstr ""
-#: ../dialogs/SearchInProjectDialog.py:76
+#: ../ProjectController.py:420
+msgid "Save path is the same as path of a project! \n"
+msgstr ""
+
+#: ../dialogs/SearchInProjectDialog.py:69
msgid "Scope"
msgstr ""
-#: ../IDEFrame.py:596 ../dialogs/SearchInProjectDialog.py:105
+#: ../IDEFrame.py:623
msgid "Search"
msgstr ""
-#: ../IDEFrame.py:365 ../IDEFrame.py:409
-#: ../dialogs/SearchInProjectDialog.py:52
+#: ../dialogs/SearchInProjectDialog.py:44 ../IDEFrame.py:382 ../IDEFrame.py:428
msgid "Search in Project"
msgstr ""
@@ -2781,50 +2888,53 @@
msgid "Seconds:"
msgstr ""
-#: ../IDEFrame.py:371
+#: ../IDEFrame.py:388
msgid "Select All"
msgstr ""
-#: ../controls/LocationCellEditor.py:97 ../controls/VariablePanel.py:277
-#: ../editors/TextViewer.py:323 ../editors/Viewer.py:275
+#: ../editors/Viewer.py:288 ../editors/TextViewer.py:306
+#: ../controls/LocationCellEditor.py:97 ../controls/VariablePanel.py:290
+#: ../controls/VariablePanel.py:350
msgid "Select a variable class:"
msgstr ""
-#: ../ProjectController.py:1039
+#: ../ProjectController.py:1195
msgid "Select an editor:"
msgstr ""
-#: ../controls/PouInstanceVariablesPanel.py:209
+#: ../controls/PouInstanceVariablesPanel.py:276
msgid "Select an instance"
msgstr ""
-#: ../IDEFrame.py:580
+#: ../IDEFrame.py:607
msgid "Select an object"
msgstr ""
+#: ../ProjectController.py:427
+msgid "Selected directory already contains another project. Overwrite? \n"
+msgstr ""
+
#: ../plcopen/iec_std.csv:70
msgid "Selection"
msgstr ""
-#: ../dialogs/SFCDivergenceDialog.py:62
+#: ../dialogs/SFCDivergenceDialog.py:65
msgid "Selection Convergence"
msgstr ""
-#: ../dialogs/SFCDivergenceDialog.py:55
+#: ../dialogs/SFCDivergenceDialog.py:64
msgid "Selection Divergence"
msgstr ""
-#: ../plcopen/structures.py:206
-msgid ""
-"Semaphore\n"
-"The semaphore provides a mechanism to allow software elements mutually exclusive access to certain ressources."
-msgstr ""
-
-#: ../dialogs/DiscoveryDialog.py:84
+#: ../dialogs/DiscoveryDialog.py:82
+msgid "Service Discovery"
+msgstr ""
+
+#: ../dialogs/DiscoveryDialog.py:85
msgid "Services available:"
msgstr ""
-#: ../dialogs/LDElementDialog.py:72
+#: ../dialogs/LDElementDialog.py:76
msgid "Set"
msgstr ""
@@ -2836,27 +2946,27 @@
msgid "Shift right"
msgstr ""
-#: ../ProjectController.py:1554
+#: ../ProjectController.py:1804
msgid "Show IEC code generated by PLCGenerator"
msgstr ""
-#: ../canfestival/canfestival.py:363
+#: ../canfestival/canfestival.py:387
msgid "Show Master"
msgstr ""
-#: ../canfestival/canfestival.py:364
+#: ../canfestival/canfestival.py:388
msgid "Show Master generated by config_utils"
msgstr ""
-#: ../ProjectController.py:1552
+#: ../ProjectController.py:1802
msgid "Show code"
msgstr ""
-#: ../dialogs/SFCDivergenceDialog.py:74
+#: ../dialogs/SFCDivergenceDialog.py:67
msgid "Simultaneous Convergence"
msgstr ""
-#: ../dialogs/SFCDivergenceDialog.py:68
+#: ../dialogs/SFCDivergenceDialog.py:66
msgid "Simultaneous Divergence"
msgstr ""
@@ -2868,48 +2978,65 @@
msgid "Single"
msgstr ""
+#: ../targets/toolchain_makefile.py:126
+msgid "Source didn't change, no build.\n"
+msgstr ""
+
+#: ../PLCGenerator.py:397
+#, python-brace-format
+msgid "Source signal has to be defined for single task '{a1}' in resource '{a2}.{a3}'."
+msgstr ""
+
#: ../plcopen/iec_std.csv:23
msgid "Square root (base 2)"
msgstr ""
-#: ../plcopen/structures.py:192
+#: ../plcopen/definitions.py:46
msgid "Standard function blocks"
msgstr ""
-#: ../Beremiz_service.py:321 ../ProjectController.py:1530
+#: ../ProjectController.py:1780 ../Beremiz_service.py:261
msgid "Start PLC"
msgstr ""
-#: ../ProjectController.py:843
+#: ../ProjectController.py:984
#, python-format
msgid "Start build in %s\n"
msgstr ""
-#: ../ProjectController.py:1341
+#: ../ProjectController.py:1298
+msgid "Started"
+msgstr ""
+
+#: ../ProjectController.py:1586
msgid "Starting PLC\n"
msgstr ""
-#: ../Beremiz.py:435
+#: ../Beremiz.py:463
msgid "Status ToolBar"
msgstr ""
-#: ../editors/Viewer.py:492
+#: ../editors/Viewer.py:553 ../editors/Viewer.py:2342
msgid "Step"
msgstr ""
-#: ../ProjectController.py:1533
+#: ../ProjectController.py:1783
msgid "Stop"
msgstr ""
-#: ../Beremiz_service.py:322
+#: ../Beremiz_service.py:262
msgid "Stop PLC"
msgstr ""
-#: ../ProjectController.py:1535
+#: ../ProjectController.py:1785
msgid "Stop Running PLC"
msgstr ""
-#: ../ProjectController.py:1318
+#: ../ProjectController.py:1299
+msgid "Stopped"
+msgstr ""
+
+#: ../ProjectController.py:1558
msgid "Stopping debugger...\n"
msgstr ""
@@ -2925,27 +3052,35 @@
msgid "Subtraction"
msgstr ""
-#: ../ProjectController.py:942
+#: ../ProjectController.py:1023
msgid "Successfully built.\n"
msgstr ""
-#: ../dialogs/SearchInProjectDialog.py:154
+#: ../IDEFrame.py:447
+msgid "Switch perspective"
+msgstr ""
+
+#: ../dialogs/SearchInProjectDialog.py:165 ../dialogs/FindInPouDialog.py:172
msgid "Syntax error in regular expression of pattern to search!"
msgstr ""
+#: ../dialogs/DiscoveryDialog.py:93
+msgid "TYPE"
+msgstr ""
+
#: ../plcopen/iec_std.csv:29
msgid "Tangent"
msgstr ""
-#: ../editors/ResourceEditor.py:77
+#: ../editors/ResourceEditor.py:83
msgid "Task"
msgstr ""
-#: ../editors/ResourceEditor.py:226
+#: ../editors/ResourceEditor.py:235
msgid "Tasks:"
msgstr ""
-#: ../controls/VariablePanel.py:78
+#: ../controls/VariablePanel.py:73
msgid "Temp"
msgstr ""
@@ -2960,16 +3095,16 @@
msgid "The group of block must be coherent!"
msgstr ""
-#: ../IDEFrame.py:974 ../Beremiz.py:590
+#: ../Beremiz.py:640 ../IDEFrame.py:1011
msgid "There are changes, do you want to save?"
msgstr ""
-#: ../IDEFrame.py:1590 ../IDEFrame.py:1609
+#: ../IDEFrame.py:1655 ../IDEFrame.py:1674
#, python-format
msgid "There is a POU named \"%s\". This could cause a conflict. Do you wish to continue?"
msgstr ""
-#: ../IDEFrame.py:1061
+#: ../IDEFrame.py:1098
msgid ""
"There was a problem printing.\n"
"Perhaps your current printer is not set correctly?"
@@ -2979,8 +3114,9 @@
msgid "This option isn't available yet!"
msgstr ""
-#: ../editors/GraphicViewer.py:278
-msgid "Tick"
+#: ../controls/DebugVariablePanel/DebugVariablePanel.py:565
+#, python-format
+msgid "Tick: %d"
msgstr ""
#: ../plcopen/iec_std.csv:40
@@ -3016,77 +3152,85 @@
msgid "Time-of-day subtraction"
msgstr ""
-#: ../editors/Viewer.py:431
+#: ../editors/Viewer.py:489
msgid "Top"
msgstr ""
-#: ../ProjectController.py:1542
+#: ../ProjectController.py:1792
msgid "Transfer"
msgstr ""
-#: ../ProjectController.py:1544
+#: ../ProjectController.py:1794
msgid "Transfer PLC"
msgstr ""
-#: ../ProjectController.py:1509
+#: ../ProjectController.py:1758
msgid "Transfer completed successfully.\n"
msgstr ""
-#: ../ProjectController.py:1511
+#: ../ProjectController.py:1760
msgid "Transfer failed\n"
msgstr ""
-#: ../editors/Viewer.py:493
+#: ../editors/Viewer.py:554 ../editors/Viewer.py:2344 ../editors/Viewer.py:2371
msgid "Transition"
msgstr ""
-#: ../PLCGenerator.py:1252
+#: ../PLCGenerator.py:1518
#, python-format
msgid "Transition \"%s\" body must contain an output variable or coil referring to its name"
msgstr ""
-#: ../dialogs/PouTransitionDialog.py:84
+#: ../dialogs/PouTransitionDialog.py:89
msgid "Transition Name"
msgstr ""
-#: ../dialogs/PouTransitionDialog.py:53
+#: ../dialogs/PouTransitionDialog.py:58
msgid "Transition Name:"
msgstr ""
-#: ../PLCGenerator.py:1340
-#, python-format
-msgid "Transition with content \"%s\" not connected to a next step in \"%s\" POU"
-msgstr ""
-
-#: ../PLCGenerator.py:1331
-#, python-format
-msgid "Transition with content \"%s\" not connected to a previous step in \"%s\" POU"
-msgstr ""
-
-#: ../plcopen/plcopen.py:1447
+#: ../PLCGenerator.py:1609
+#, python-brace-format
+msgid "Transition with content \"{a1}\" not connected to a next step in \"{a2}\" POU"
+msgstr ""
+
+#: ../PLCGenerator.py:1598
+#, python-brace-format
+msgid "Transition with content \"{a1}\" not connected to a previous step in \"{a2}\" POU"
+msgstr ""
+
+#: ../plcopen/plcopen.py:1318
#, python-format
msgid "Transition with name %s doesn't exist!"
msgstr ""
-#: ../PLCControler.py:95
+#: ../PLCControler.py:96
msgid "Transitions"
msgstr ""
+#: ../dialogs/AboutDialog.py:123
+msgid "Translated by"
+msgstr ""
+
#: ../editors/ResourceEditor.py:68
msgid "Triggering"
msgstr ""
-#: ../controls/VariablePanel.py:58 ../controls/VariablePanel.py:59
-#: ../editors/DataTypeEditor.py:50 ../editors/ResourceEditor.py:77
-#: ../dialogs/ActionBlockDialog.py:37
+#: ../Beremiz_service.py:476
+msgid "Twisted unavailable."
+msgstr ""
+
+#: ../dialogs/ActionBlockDialog.py:38 ../editors/ResourceEditor.py:83
+#: ../editors/DataTypeEditor.py:50 ../controls/VariablePanel.py:53
+#: ../controls/VariablePanel.py:54
msgid "Type"
msgstr ""
-#: ../dialogs/BrowseLocationsDialog.py:44
+#: ../dialogs/BrowseLocationsDialog.py:48
msgid "Type and derivated"
msgstr ""
-#: ../canfestival/config_utils.py:335 ../canfestival/config_utils.py:617
+#: ../canfestival/config_utils.py:336 ../canfestival/config_utils.py:624
#, python-format
msgid "Type conflict for location \"%s\""
msgstr ""
@@ -3095,122 +3239,117 @@
msgid "Type conversion"
msgstr ""
-#: ../editors/DataTypeEditor.py:161
+#: ../editors/DataTypeEditor.py:162
msgid "Type infos:"
msgstr ""
-#: ../dialogs/BrowseLocationsDialog.py:45
+#: ../dialogs/BrowseLocationsDialog.py:49
msgid "Type strict"
msgstr ""
-#: ../dialogs/SFCDivergenceDialog.py:51 ../dialogs/LDPowerRailDialog.py:51
-#: ../dialogs/BrowseLocationsDialog.py:95 ../dialogs/ConnectionDialog.py:52
-#: ../dialogs/SFCTransitionDialog.py:53 ../dialogs/FBDBlockDialog.py:48
+#: ../dialogs/SFCDivergenceDialog.py:59 ../dialogs/SFCTransitionDialog.py:57
+#: ../dialogs/LDPowerRailDialog.py:56 ../dialogs/BrowseLocationsDialog.py:99
+#: ../dialogs/FBDBlockDialog.py:65 ../dialogs/ConnectionDialog.py:58
msgid "Type:"
msgstr ""
-#: ../canfestival/config_utils.py:455 ../canfestival/config_utils.py:469
+#: ../canfestival/config_utils.py:462 ../canfestival/config_utils.py:476
#, python-format
msgid "Unable to define PDO mapping for node %02x"
msgstr ""
-#: ../targets/Xenomai/__init__.py:14
+#: ../targets/Xenomai/__init__.py:39
#, python-format
msgid "Unable to get Xenomai's %s \n"
msgstr ""
-#: ../PLCGenerator.py:904 ../PLCGenerator.py:963
-#, python-format
-msgid "Undefined block type \"%s\" in \"%s\" POU"
-msgstr ""
-
-#: ../PLCGenerator.py:252
+#: ../PLCGenerator.py:961 ../PLCGenerator.py:1214
+#, python-brace-format
+msgid "Undefined block type \"{a1}\" in \"{a2}\" POU"
+msgstr ""
+
+#: ../PLCGenerator.py:254
#, python-format
msgid "Undefined pou type \"%s\""
msgstr ""
-#: ../IDEFrame.py:343 ../IDEFrame.py:402
+#: ../IDEFrame.py:360 ../IDEFrame.py:421
msgid "Undo"
msgstr ""
-#: ../ProjectController.py:262
+#: ../ProjectController.py:332
msgid "Unknown"
msgstr ""
-#: ../editors/Viewer.py:335
+#: ../editors/Viewer.py:393
#, python-format
msgid "Unknown variable \"%s\" for this POU!"
msgstr ""
-#: ../ProjectController.py:259 ../ProjectController.py:260
+#: ../ProjectController.py:329 ../ProjectController.py:330
msgid "Unnamed"
msgstr ""
-#: ../PLCControler.py:305
+#: ../PLCControler.py:636
#, python-format
msgid "Unnamed%d"
msgstr ""
-#: ../controls/VariablePanel.py:272
+#: ../controls/VariablePanel.py:284
#, python-format
msgid "Unrecognized data size \"%s\""
msgstr ""
-#: ../plcopen/structures.py:221
-msgid ""
-"Up-counter\n"
-"The up-counter can be used to signal when a count has reached a maximum value."
-msgstr ""
-
-#: ../plcopen/structures.py:231
-msgid ""
-"Up-down counter\n"
-"The up-down counter has two inputs CU and CD. It can be used to both count up on one input and down on the other."
-msgstr ""
-
-#: ../controls/VariablePanel.py:712 ../editors/DataTypeEditor.py:631
+#: ../editors/DataTypeEditor.py:632 ../controls/VariablePanel.py:798
msgid "User Data Types"
msgstr ""
-#: ../canfestival/SlaveEditor.py:42 ../canfestival/NetworkEditor.py:63
+#: ../canfestival/SlaveEditor.py:65 ../canfestival/NetworkEditor.py:86
msgid "User Type"
msgstr ""
-#: ../PLCControler.py:94
+#: ../PLCControler.py:95
msgid "User-defined POUs"
msgstr ""
-#: ../controls/DebugVariablePanel.py:58 ../dialogs/ActionBlockDialog.py:37
+#: ../dialogs/ActionBlockDialog.py:38
msgid "Value"
msgstr ""
-#: ../editors/GraphicViewer.py:278
-msgid "Values"
-msgstr ""
-
-#: ../editors/DataTypeEditor.py:258
+#: ../editors/DataTypeEditor.py:259
msgid "Values:"
msgstr ""
-#: ../controls/DebugVariablePanel.py:58 ../editors/Viewer.py:465
-#: ../dialogs/ActionBlockDialog.py:41
+#: ../dialogs/ActionBlockDialog.py:42 ../editors/Viewer.py:526
+#: ../editors/Viewer.py:2374
msgid "Variable"
msgstr ""
-#: ../dialogs/FBDVariableDialog.py:47
+#: ../editors/Viewer.py:308 ../editors/Viewer.py:338 ../editors/Viewer.py:360
+#: ../editors/TextViewer.py:292 ../editors/TextViewer.py:343
+#: ../editors/TextViewer.py:366 ../controls/VariablePanel.py:329
+msgid "Variable Drop"
+msgstr ""
+
+#: ../dialogs/FBDVariableDialog.py:63
msgid "Variable Properties"
msgstr ""
-#: ../controls/LocationCellEditor.py:97 ../controls/VariablePanel.py:277
-#: ../editors/TextViewer.py:323 ../editors/Viewer.py:275
+#: ../editors/Viewer.py:288 ../editors/TextViewer.py:306
+#: ../controls/LocationCellEditor.py:97 ../controls/VariablePanel.py:290
+#: ../controls/VariablePanel.py:350
msgid "Variable class"
msgstr ""
-#: ../editors/TextViewer.py:367 ../editors/Viewer.py:337
+#: ../editors/Viewer.py:395 ../editors/TextViewer.py:387
msgid "Variable don't belong to this POU!"
msgstr ""
-#: ../controls/VariablePanel.py:77
+#: ../dialogs/LDElementDialog.py:89
+msgid "Variable:"
+msgstr ""
+
+#: ../controls/VariablePanel.py:72
msgid "Variables"
msgstr ""
@@ -3218,23 +3357,41 @@
msgid "Vertical:"
msgstr ""
-#: ../wxglade_hmi/wxglade_hmi.py:11
+#: ../Beremiz_service.py:586
+msgid "WAMP client startup failed. "
+msgstr ""
+
+#: ../connectors/WAMP/__init__.py:91
+#, python-format
+msgid "WAMP connecting to URL : %s\n"
+msgstr ""
+
+#: ../connectors/WAMP/__init__.py:131
+msgid "WAMP connection timeout"
+msgstr ""
+
+#: ../connectors/WAMP/__init__.py:150
+#, python-format
+msgid "WAMP connection to '%s' failed.\n"
+msgstr ""
+
+#: ../Beremiz_service.py:562
+msgid "WAMP import failed :"
+msgstr ""
+
+#: ../wxglade_hmi/wxglade_hmi.py:35
msgid "WXGLADE GUI"
msgstr ""
-#: ../ProjectController.py:1302
-msgid "Waiting debugger to recover...\n"
-msgstr ""
-
-#: ../editors/LDViewer.py:891 ../dialogs/PouDialog.py:126
+#: ../dialogs/PouDialog.py:128 ../editors/LDViewer.py:891
msgid "Warning"
msgstr ""
-#: ../ProjectController.py:529
+#: ../ProjectController.py:616
msgid "Warnings in ST/IL/SFC code generator :\n"
msgstr ""
-#: ../dialogs/SearchInProjectDialog.py:85
+#: ../dialogs/SearchInProjectDialog.py:78
msgid "Whole Project"
msgstr ""
@@ -3242,27 +3399,31 @@
msgid "Width:"
msgstr ""
-#: ../dialogs/FindInPouDialog.py:86
+#: ../dialogs/FindInPouDialog.py:93
msgid "Wrap search"
msgstr ""
-#: ../features.py:10
+#: ../dialogs/AboutDialog.py:122
+msgid "Written by"
+msgstr ""
+
+#: ../features.py:34
msgid "WxGlade GUI"
msgstr ""
-#: ../svgui/svgui.py:106
+#: ../svgui/svgui.py:139
msgid ""
"You don't have write permissions.\n"
"Open Inkscape anyway ?"
msgstr ""
-#: ../wxglade_hmi/wxglade_hmi.py:108
+#: ../wxglade_hmi/wxglade_hmi.py:137
msgid ""
"You don't have write permissions.\n"
"Open wxGlade anyway ?"
msgstr ""
-#: ../ProjectController.py:224
+#: ../ProjectController.py:292
msgid ""
"You must have permission to work on the project\n"
"Work on a project copy ?"
@@ -3276,8 +3437,7 @@
msgid "You must select the wire where a contact should be added!"
msgstr ""
-#: ../dialogs/PouNameDialog.py:45 ../dialogs/SFCStepNameDialog.py:47
-#: ../dialogs/SFCStepDialog.py:118
+#: ../dialogs/SFCStepNameDialog.py:48 ../dialogs/PouNameDialog.py:46
msgid "You must type a name!"
msgstr ""
@@ -3285,25 +3445,25 @@
msgid "You must type a value!"
msgstr ""
-#: ../IDEFrame.py:419
+#: ../IDEFrame.py:438
msgid "Zoom"
msgstr ""
-#: ../editors/GraphicViewer.py:97
-msgid "Zoom:"
-msgstr ""
-
-#: ../PLCOpenEditor.py:335
+#: ../dialogs/DurationEditorDialog.py:151
+msgid "days"
+msgstr ""
+
+#: ../PLCOpenEditor.py:333
#, python-format
msgid "error: %s\n"
msgstr ""
-#: ../util/ProcessLogger.py:161
-#, python-format
-msgid "exited with status %s (pid %s)\n"
-msgstr ""
-
-#: ../PLCOpenEditor.py:393 ../PLCOpenEditor.py:395
+#: ../util/ProcessLogger.py:169
+#, python-brace-format
+msgid "exited with status {a1} (pid {a2})\n"
+msgstr ""
+
+#: ../PLCOpenEditor.py:396 ../PLCOpenEditor.py:398
msgid "file : "
msgstr ""
@@ -3311,7 +3471,7 @@
msgid "function"
msgstr ""
-#: ../PLCOpenEditor.py:396
+#: ../PLCOpenEditor.py:399
msgid "function : "
msgstr ""
@@ -3319,14 +3479,30 @@
msgid "functionBlock"
msgstr ""
-#: ../PLCOpenEditor.py:396
+#: ../dialogs/DurationEditorDialog.py:151
+msgid "hours"
+msgstr ""
+
+#: ../PLCOpenEditor.py:399
msgid "line : "
msgstr ""
+#: ../dialogs/DurationEditorDialog.py:153
+msgid "milliseconds"
+msgstr ""
+
+#: ../dialogs/DurationEditorDialog.py:152
+msgid "minutes"
+msgstr ""
+
#: ../dialogs/PouDialog.py:31
msgid "program"
msgstr ""
+#: ../dialogs/DurationEditorDialog.py:152
+msgid "seconds"
+msgstr ""
+
#: ../plcopen/iec_std.csv:84
msgid "string from the middle"
msgstr ""
@@ -3339,13 +3515,30 @@
msgid "string right of"
msgstr ""
-#: ../PLCOpenEditor.py:333
+#: ../Beremiz.py:126
+msgid "update info unavailable."
+msgstr ""
+
+#: ../PLCOpenEditor.py:331
#, python-format
msgid "warning: %s\n"
msgstr ""
+#: ../PLCControler.py:970
+#, python-brace-format
+msgid "{a1} \"{a2}\" can't be pasted as a {a3}."
+msgstr ""
+
+#: ../ConfigTreeNode.py:56
+#, python-brace-format
+msgid ""
+"{a1} XML file doesn't follow XSD schema at line %{a2}:\n"
+"{a3}"
+msgstr ""
+
#: Extra XSD strings
+
msgid "CanFestivalSlaveNode"
msgstr ""
@@ -3376,15 +3569,39 @@
msgid "CAN_Driver"
msgstr ""
-msgid "CExtension"
+msgid "Generic"
+msgstr ""
+
+msgid "Command"
+msgstr ""
+
+msgid "Xenomai"
+msgstr ""
+
+msgid "XenoConfig"
+msgstr ""
+
+msgid "Compiler"
msgstr ""
msgid "CFLAGS"
msgstr ""
+msgid "Linker"
+msgstr ""
+
msgid "LDFLAGS"
msgstr ""
+msgid "PLC"
+msgstr ""
+
+msgid "Linux"
+msgstr ""
+
+msgid "Win32"
+msgstr ""
+
msgid "BaseParams"
msgstr ""
@@ -3394,24 +3611,6 @@
msgid "Enabled"
msgstr ""
-msgid "Linux"
-msgstr ""
-
-msgid "Compiler"
-msgstr ""
-
-msgid "Linker"
-msgstr ""
-
-msgid "Win32"
-msgstr ""
-
-msgid "Xenomai"
-msgstr ""
-
-msgid "XenoConfig"
-msgstr ""
-
msgid "BeremizRoot"
msgstr ""
@@ -3426,3 +3625,186 @@
msgid "Disable_Extensions"
msgstr ""
+
+msgid "%(codefile_name)s"
+msgstr ""
+
+msgid "variables"
+msgstr ""
+
+msgid "variable"
+msgstr ""
+
+msgid "name"
+msgstr ""
+
+msgid "type"
+msgstr ""
+
+msgid "class"
+msgstr ""
+
+msgid "initial"
+msgstr ""
+
+msgid "desc"
+msgstr ""
+
+msgid "onchange"
+msgstr ""
+
+msgid "opts"
+msgstr ""
+
+#: Extra TC6 documentation strings
+
+
+msgid "0 - current time, 1 - load time from PDT"
+msgstr ""
+
+msgid "Preset datetime"
+msgstr ""
+
+msgid "Copy of IN"
+msgstr ""
+
+msgid "Datetime, current or relative to PDT"
+msgstr ""
+
+msgid "The real time clock has many uses including time stamping, setting dates and times of day in batch reports, in alarm messages and so on."
+msgstr ""
+
+msgid "1 = integrate, 0 = hold"
+msgstr ""
+
+msgid "Overriding reset"
+msgstr ""
+
+msgid "Input variable"
+msgstr ""
+
+msgid "Initial value"
+msgstr ""
+
+msgid "Sampling period"
+msgstr ""
+
+msgid "NOT R1"
+msgstr ""
+
+msgid "Integrated output"
+msgstr ""
+
+msgid "The integral function block integrates the value of input XIN over time."
+msgstr ""
+
+msgid "0 = reset"
+msgstr ""
+
+msgid "Input to be differentiated"
+msgstr ""
+
+msgid "Differentiated output"
+msgstr ""
+
+msgid "The derivative function block produces an output XOUT proportional to the rate of change of the input XIN."
+msgstr ""
+
+msgid "0 - manual , 1 - automatic"
+msgstr ""
+
+msgid "Process variable"
+msgstr ""
+
+msgid "Set point"
+msgstr ""
+
+msgid "Manual output adjustment - Typically from transfer station"
+msgstr ""
+
+msgid "Proportionality constant"
+msgstr ""
+
+msgid "Reset time"
+msgstr ""
+
+msgid "Derivative time constant"
+msgstr ""
+
+msgid "PV - SP"
+msgstr ""
+
+msgid "FB for integral term"
+msgstr ""
+
+msgid "FB for derivative term"
+msgstr ""
+
+msgid "The PID (proportional, Integral, Derivative) function block provides the classical three term controller for closed loop control."
+msgstr ""
+
+msgid "0 - track X0, 1 - ramp to/track X1"
+msgstr ""
+
+msgid "Ramp duration"
+msgstr ""
+
+msgid "BUSY = 1 during ramping period"
+msgstr ""
+
+msgid "Elapsed time of ramp"
+msgstr ""
+
+msgid "The RAMP function block is modelled on example given in the standard."
+msgstr ""
+
+msgid "The hysteresis function block provides a hysteresis boolean output driven by the difference of two floating point (REAL) inputs XIN1 and XIN2."
+msgstr ""
+
+msgid "The SR bistable is a latch where the Set dominates."
+msgstr ""
+
+msgid "The RS bistable is a latch where the Reset dominates."
+msgstr ""
+
+msgid "The semaphore provides a mechanism to allow software elements mutually exclusive access to certain ressources."
+msgstr ""
+
+msgid "The output produces a single pulse when a rising edge is detected."
+msgstr ""
+
+msgid "The output produces a single pulse when a falling edge is detected."
+msgstr ""
+
+msgid "The up-counter can be used to signal when a count has reached a maximum value."
+msgstr ""
+
+msgid "The down-counter can be used to signal when a count has reached zero, on counting down from a preset value."
+msgstr ""
+
+msgid "The up-down counter has two inputs CU and CD. It can be used to both count up on one input and down on the other."
+msgstr ""
+
+msgid "first input parameter"
+msgstr ""
+
+msgid "second input parameter"
+msgstr ""
+
+msgid "first output parameter"
+msgstr ""
+
+msgid "second output parameter"
+msgstr ""
+
+msgid "internal state: 0-reset, 1-counting, 2-set"
+msgstr ""
+
+msgid "The pulse timer can be used to generate output pulses of a given time duration."
+msgstr ""
+
+msgid "The on-delay timer can be used to delay setting an output true, for fixed period after an input becomes true."
+msgstr ""
+
+msgid "The off-delay timer can be used to delay setting an output false, for fixed period after input goes false."
+msgstr ""
diff -r a375e31bf312 -r c1298e7ffe3a i18n/mki18n.py
--- a/i18n/mki18n.py Sun Mar 05 00:38:25 2017 +0000
+++ b/i18n/mki18n.py Fri Mar 24 12:07:47 2017 +0000
@@ -95,7 +95,12 @@
def getlanguageDict():
languageDict = {}
-
+
+ if wx.VERSION >= (3, 0, 0):
+ app = wx.App()
+ else:
+ app = wx.PySimpleApp()
+
for lang in [x for x in dir(wx) if x.startswith("LANGUAGE")]:
i = wx.Locale(wx.LANGUAGE_DEFAULT).GetLanguageInfo(getattr(wx, lang))
if i:
@@ -103,7 +108,33 @@
return languageDict
-XSD_STRING_MODEL = re.compile("]*\>")
+
+
+def processCustomFiles(filein, fileout, regexp, prefix = ''):
+ appfil_file = open(filein, 'r')
+ messages_file = open(fileout, 'r')
+ messages = messages_file.read()
+ messages_file.close()
+ messages_file = open(fileout, 'a')
+ messages_file.write('\n')
+ messages_file.write('#: %s\n' % prefix)
+ messages_file.write('\n')
+
+ words_found = {}
+ for filepath in appfil_file.xreadlines():
+ code_file = open(filepath.strip(), 'r')
+ for match in regexp.finditer(code_file.read()):
+ word = match.group(1)
+ if not words_found.get(word, False) and messages.find("msgid \"%s\"\nmsgstr \"\"" % word) == -1:
+ words_found[word] = True
+ messages_file.write('\n')
+ messages_file.write("msgid \"%s\"\n"%word)
+ messages_file.write("msgstr \"\"\n")
+ code_file.close()
+
+ messages_file.close()
+ appfil_file.close()
+
# -----------------------------------------------------------------------------
# m a k e P O ( ) -- Build the Portable Object file for the application --
@@ -138,10 +169,12 @@
else:
applicationName = applicationDomain
currentDir = os.getcwd()
- os.chdir(applicationDirectoryPath)
- if not os.path.exists('app.fil'):
- raise IOError(2,'No module file: app.fil')
-
+ os.chdir(applicationDirectoryPath)
+ filelist = 'app.fil'
+ if not os.path.exists(filelist):
+ raise IOError(2,'No module file: ' % filelist)
+
+ fileout = 'messages.pot'
# Steps:
# Use xgettext to parse all application modules
# The following switches are used:
@@ -149,33 +182,16 @@
# -s : sort output by string content (easier to use when we need to merge several .po files)
# --files-from=app.fil : The list of files is taken from the file: app.fil
# --output= : specifies the name of the output file (using a .pot extension)
- cmd = 'xgettext -s --no-wrap --language=Python --files-from=app.fil --output=messages.pot'
+ cmd = 'xgettext -s --no-wrap --language=Python --files-from=' + filelist + ' --output=' + fileout
if verbose: print cmd
os.system(cmd)
- appfil_file = open("app.fil", 'r')
- messages_file = open("messages.pot", 'r')
- messages = messages_file.read()
- messages_file.close()
- messages_file = open("messages.pot", 'a')
- messages_file.write("""
-#: Extra XSD strings
-""")
- words_found = {}
- for filepath in appfil_file.xreadlines():
- code_file = open(filepath.strip(), 'r')
- for match in XSD_STRING_MODEL.finditer(code_file.read()):
- word = match.group(1)
- if not words_found.get(word, False) and messages.find("msgid \"%s\"\nmsgstr \"\"" % word) == -1:
- words_found[word] = True
- messages_file.write("""
-msgid "%s"
-msgstr ""
-"""%word)
- code_file.close()
- messages_file.close()
- appfil_file.close()
-
+ XSD_STRING_MODEL = re.compile("]*\>")
+ processCustomFiles(filelist, fileout, XSD_STRING_MODEL, 'Extra XSD strings')
+
+ XML_TC6_STRING_MODEL = re.compile("\s*\s*", re.MULTILINE | re.DOTALL)
+ processCustomFiles(filelist, fileout, XML_TC6_STRING_MODEL, 'Extra TC6 documentation strings')
+
languageDict = getlanguageDict()
for langCode in languageDict.keys():
@@ -184,7 +200,7 @@
else:
langPOfileName = "%s_%s.po" % (applicationName , langCode)
if os.path.exists(langPOfileName):
- cmd = 'msgmerge -s --no-wrap "%s" messages.pot > "%s.new"' % (langPOfileName, langPOfileName)
+ cmd = 'msgmerge -s --no-wrap "%s" %s > "%s.new"' % (langPOfileName, fileout, langPOfileName)
if verbose: print cmd
os.system(cmd)
os.chdir(currentDir)
diff -r a375e31bf312 -r c1298e7ffe3a images/about_brz_logo.png
Binary file images/about_brz_logo.png has changed
diff -r a375e31bf312 -r c1298e7ffe3a images/icons.svg
--- a/images/icons.svg Sun Mar 05 00:38:25 2017 +0000
+++ b/images/icons.svg Fri Mar 24 12:07:47 2017 +0000
@@ -15,7 +15,7 @@
height="1052.3622"
id="svg2"
sodipodi:version="0.32"
- inkscape:version="0.48.3.1 r9886"
+ inkscape:version="0.91 r13725"
sodipodi:docname="icons.svg"
inkscape:output_extension="org.inkscape.output.svg.inkscape">
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ style="fill:#84c225;fill-rule:evenodd;stroke:#5d9d35;stroke-width:2.82220006" />
+ style="fill:#84c225;fill-rule:evenodd;stroke:#5d9d35;stroke-width:2.82220006" />
+ cx="0" />
+ cx="0" />
+ cx="0" />
+ cx="0" />
+ cx="0" />
+ style="fill:#84c225;fill-rule:evenodd;stroke:#5d9d35;stroke-width:2.82220006" />
+ %% about_brz_logo %%
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Free Software for Automation
+
+
diff -r a375e31bf312 -r c1298e7ffe3a locale/ru_RU/LC_MESSAGES/Beremiz.mo
Binary file locale/ru_RU/LC_MESSAGES/Beremiz.mo has changed
diff -r a375e31bf312 -r c1298e7ffe3a plcopen/.cvsignore
--- a/plcopen/.cvsignore Sun Mar 05 00:38:25 2017 +0000
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,1 +0,0 @@
-*.pyc
diff -r a375e31bf312 -r c1298e7ffe3a plcopen/__init__.py
--- a/plcopen/__init__.py Sun Mar 05 00:38:25 2017 +0000
+++ b/plcopen/__init__.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
# Package initialisation
diff -r a375e31bf312 -r c1298e7ffe3a plcopen/definitions.py
--- a/plcopen/definitions.py Sun Mar 05 00:38:25 2017 +0000
+++ b/plcopen/definitions.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,3 +1,28 @@
+#!/usr/bin/env python
+# -*- coding: utf-8 -*-
+
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+
+
from os.path import join, split, realpath
sd = split(realpath(__file__))[0]
@@ -23,35 +48,8 @@
StdFuncsCSV = join(sd,"iec_std.csv")
-# FIXME : since std fb now loaded from TC6 file, is that still necessary ?
-StdBlockComments = {
- "SR": _("SR bistable\nThe SR bistable is a latch where the Set dominates."),
- "RS": _("RS bistable\nThe RS bistable is a latch where the Reset dominates."),
- "SEMA": _("Semaphore\nThe semaphore provides a mechanism to allow software elements mutually exclusive access to certain ressources."),
- "R_TRIG": _("Rising edge detector\nThe output produces a single pulse when a rising edge is detected."),
- "F_TRIG": _("Falling edge detector\nThe output produces a single pulse when a falling edge is detected."),
- "CTU": _("Up-counter\nThe up-counter can be used to signal when a count has reached a maximum value."),
- "CTD": _("Down-counter\nThe down-counter can be used to signal when a count has reached zero, on counting down from a preset value."),
- "CTUD": _("Up-down counter\nThe up-down counter has two inputs CU and CD. It can be used to both count up on one input and down on the other."),
- "TP": _("Pulse timer\nThe pulse timer can be used to generate output pulses of a given time duration."),
- "TON": _("On-delay timer\nThe on-delay timer can be used to delay setting an output true, for fixed period after an input becomes true."),
- "TOF": _("Off-delay timer\nThe off-delay timer can be used to delay setting an output false, for fixed period after input goes false."),
- "RTC": _("Real time clock\nThe real time clock has many uses including time stamping, setting dates and times of day in batch reports, in alarm messages and so on."),
- "INTEGRAL": _("Integral\nThe integral function block integrates the value of input XIN over time."),
- "DERIVATIVE": _("Derivative\nThe derivative function block produces an output XOUT proportional to the rate of change of the input XIN."),
- "PID": _("PID\nThe PID (proportional, Integral, Derivative) function block provides the classical three term controller for closed loop control."),
- "RAMP": _("Ramp\nThe RAMP function block is modelled on example given in the standard."),
- "HYSTERESIS": _("Hysteresis\nThe hysteresis function block provides a hysteresis boolean output driven by the difference of two floating point (REAL) inputs XIN1 and XIN2."),
-}
-
-for block_type in ["CTU", "CTD", "CTUD"]:
- for return_type in ["DINT", "LINT", "UDINT", "ULINT"]:
- StdBlockComments["%s_%s" % (block_type, return_type)] = StdBlockComments[block_type]
-
def GetBlockInfos(pou):
infos = pou.getblockInfos()
- # FIXME : as well
- infos["comment"] = StdBlockComments[infos["name"]]
infos["inputs"] = [
(var_name, var_type, "rising")
if var_name in ["CU", "CD"]
diff -r a375e31bf312 -r c1298e7ffe3a plcopen/plcopen.py
--- a/plcopen/plcopen.py Sun Mar 05 00:38:25 2017 +0000
+++ b/plcopen/plcopen.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
from xmlclass import *
from types import *
@@ -111,10 +111,15 @@
lines = text.split("\n")
return len(lines) - 1, len(lines[-1])
+def CompilePattern(criteria):
+ flag = 0 if criteria["case_sensitive"] else re.IGNORECASE
+ find_pattern = criteria["find_pattern"]
+ if not criteria["regular_expression"]:
+ find_pattern = re.escape(find_pattern)
+ criteria["pattern"] = re.compile(find_pattern, flag)
+
def TestTextElement(text, criteria):
lines = text.splitlines()
- if not criteria["case_sensitive"]:
- text = text.upper()
test_result = []
result = criteria["pattern"].search(text)
while result is not None:
@@ -124,6 +129,9 @@
result = criteria["pattern"].search(text, result.end())
return test_result
+def TextMatched(str1, str2):
+ return str1 and str2 and (str1.upper() == str2.upper())
+
PLCOpenParser = GenerateParserFromXSD(os.path.join(os.path.split(__file__)[0], "tc6_xml_v201.xsd"))
PLCOpen_XPath = lambda xpath: etree.XPath(xpath, namespaces=PLCOpenParser.NSMAP)
@@ -285,15 +293,8 @@
if cls:
def updateElementName(self, old_name, new_name):
text = self.getanyText()
- index = text.find(old_name)
- while index != -1:
- if index > 0 and (text[index - 1].isalnum() or text[index - 1] == "_"):
- index = text.find(old_name, index + len(old_name))
- elif index < len(text) - len(old_name) and (text[index + len(old_name)].isalnum() or text[index + len(old_name)] == "_"):
- index = text.find(old_name, index + len(old_name))
- else:
- text = text[:index] + new_name + text[index + len(old_name):]
- index = text.find(old_name, index + len(new_name))
+ pattern = re.compile('\\b' + old_name + '\\b', re.IGNORECASE)
+ text = pattern.sub(new_name, text)
self.setanyText(text)
setattr(cls, "updateElementName", updateElementName)
@@ -311,14 +312,9 @@
setattr(cls, "updateElementAddress", updateElementAddress)
def hasblock(self, block_type):
- text = self.getanyText().upper()
- index = text.find(block_type.upper())
- while index != -1:
- if (not (index > 0 and (text[index - 1].isalnum() or text[index - 1] == "_")) and
- not (index < len(text) - len(block_type) and text[index + len(block_type)] != "(")):
- return True
- index = text.find(block_type.upper(), index + len(block_type))
- return False
+ text = self.getanyText()
+ pattern = re.compile('\\b' + block_type + '\\b', re.IGNORECASE)
+ return pattern.search(text) is not None
setattr(cls, "hasblock", hasblock)
def Search(self, criteria, parent_infos):
@@ -492,7 +488,8 @@
def addconfigurationResource(self, config_name, name):
if self.getconfigurationResource(config_name, name) is not None:
- raise ValueError, _("\"%s\" resource already exists in \"%s\" configuration !!!") % (name, config_name)
+ msg = _("\"{a1}\" resource already exists in \"{a2}\" configuration !!!").format(a1 = name, a2 = config_name)
+ raise ValueError, msg
configuration = self.getconfiguration(config_name)
if configuration is not None:
new_resource = PLCOpenParser.CreateElement("resource", "configuration")
@@ -509,7 +506,8 @@
configuration.remove(resource)
found = True
if not found:
- raise ValueError, _("\"%s\" resource doesn't exist in \"%s\" configuration !!!")%(name, config_name)
+ msg = _("\"{a1}\" resource doesn't exist in \"{a2}\" configuration !!!").format(a1 = name, a2 = config_name)
+ raise ValueError, msg
setattr(cls, "removeconfigurationResource", removeconfigurationResource)
def updateElementName(self, old_name, new_name):
@@ -633,9 +631,9 @@
for var in varlist.getvariable():
var_address = var.getaddress()
if var_address is not None:
- if var_address == old_name:
+ if TextMatched(var_address, old_name):
var.setaddress(new_name)
- if var.getname() == old_name:
+ if TextMatched(var.getname(), old_name):
var.setname(new_name)
def _updateConfigurationResourceElementAddress(self, address_model, new_leading):
@@ -769,9 +767,9 @@
cls = PLCOpenParser.GetElementClass("task", "resource")
if cls:
def updateElementName(self, old_name, new_name):
- if self.single == old_name:
+ if TextMatched(self.single, old_name):
self.single = new_name
- if self.interval == old_name:
+ if TextMatched(self.interval, old_name):
self.interval = new_name
for instance in self.getpouInstance():
instance.updateElementName(old_name, new_name)
@@ -794,7 +792,7 @@
cls = PLCOpenParser.GetElementClass("pouInstance")
if cls:
def updateElementName(self, old_name, new_name):
- if self.typeName == old_name:
+ if TextMatched(self.typeName, old_name):
self.typeName = new_name
setattr(cls, "updateElementName", updateElementName)
@@ -856,7 +854,7 @@
def getdataTypeElement(self, name):
elements = self.dataTypes.getdataType()
for element in elements:
- if element.getname() == name:
+ if TextMatched(element.getname(), name):
return element
return None
setattr(cls, "getdataTypeElement", getdataTypeElement)
@@ -875,7 +873,7 @@
def removedataTypeElement(self, name):
found = False
for element in self.dataTypes.getdataType():
- if element.getname() == name:
+ if TextMatched(element.getname(), name):
self.dataTypes.remove(element)
found = True
break
@@ -890,14 +888,14 @@
def getpouElement(self, name):
elements = self.pous.getpou()
for element in elements:
- if element.getname() == name:
+ if TextMatched(element.getname(), name):
return element
return None
setattr(cls, "getpouElement", getpouElement)
def appendpouElement(self, name, pou_type, body_type):
for element in self.pous.getpou():
- if element.getname() == name:
+ if TextMatched(element.getname(), name):
raise ValueError, _("\"%s\" POU already exists !!!")%name
new_pou = PLCOpenParser.CreateElement("pou", "pous")
self.pous.appendpou(new_pou)
@@ -914,7 +912,7 @@
def removepouElement(self, name):
found = False
for element in self.pous.getpou():
- if element.getname() == name:
+ if TextMatched(element.getname(), name):
self.pous.remove(element)
found = True
break
@@ -981,7 +979,7 @@
cls = PLCOpenParser.GetElementClass("derived", "dataType")
if cls:
def updateElementName(self, old_name, new_name):
- if self.name == old_name:
+ if TextMatched(self.name, old_name):
self.name = new_name
setattr(cls, "updateElementName", updateElementName)
@@ -1226,9 +1224,9 @@
for varlist in content:
variables = varlist.getvariable()
for var in variables:
- if var.getname() == old_name:
+ if TextMatched(var.getname(), old_name):
vartype_content = var.gettype().getcontent()
- if vartype_content.getLocalTag() == "derived" and vartype_content.getname() == old_type:
+ if vartype_content.getLocalTag() == "derived" and TextMatched(vartype_content.getname(), old_type):
var.setname(new_name)
vartype_content.setname(new_type)
return
@@ -1239,21 +1237,28 @@
content = self.interface.getcontent()
for varlist in content:
for var in varlist.getvariable():
- if var.getname() == name:
+ if TextMatched(var.getname(), name):
vartype_content = var.gettype().getcontent()
- if vartype_content.getLocalTag() == "derived" and vartype_content.getname() == var_type:
+ if vartype_content.getLocalTag() == "derived" and TextMatched(vartype_content.getname(), var_type):
varlist.remove(var)
if len(varlist.getvariable()) == 0:
self.interface.remove(varlist)
break
setattr(cls, "removepouVar", removepouVar)
+
+ def hasstep(self, name=None):
+ if self.getbodyType() in ["SFC"]:
+ for instance in self.getinstances():
+ if isinstance(instance, PLCOpenParser.GetElementClass("step", "sfcObjects")) and TextMatched(instance.getname(), name):
+ return True
+ return False
+ setattr(cls, "hasstep", hasstep)
def hasblock(self, name=None, block_type=None):
if self.getbodyType() in ["FBD", "LD", "SFC"]:
for instance in self.getinstances():
if (isinstance(instance, PLCOpenParser.GetElementClass("block", "fbdObjects")) and
- (name and instance.getinstanceName() == name or
- block_type and instance.gettypeName() == block_type)):
+ (TextMatched(instance.getinstanceName(), name) or TextMatched(instance.gettypeName(), block_type))):
return True
if self.transitions:
for transition in self.transitions.gettransition():
@@ -1279,15 +1284,13 @@
transition.setname(name)
transition.setbodyType(body_type)
if body_type == "ST":
- transition.setanyText(":= ;")
- elif body_type == "IL":
- transition.setanyText("\tST\t%s"%name)
+ transition.settext(":= ;")
setattr(cls, "addtransition", addtransition)
def gettransition(self, name):
if self.transitions is not None:
for transition in self.transitions.gettransition():
- if transition.getname() == name:
+ if TextMatched(transition.getname(), name):
return transition
return None
setattr(cls, "gettransition", gettransition)
@@ -1302,7 +1305,7 @@
if self.transitions is not None:
removed = False
for transition in self.transitions.gettransition():
- if transition.getname() == name:
+ if TextMatched(transition.getname(), name):
if transition.getbodyType() in ["FBD", "LD", "SFC"]:
for instance in transition.getinstances():
if isinstance(instance, PLCOpenParser.GetElementClass("block", "fbdObjects")):
@@ -1328,7 +1331,7 @@
def getaction(self, name):
if self.actions is not None:
for action in self.actions.getaction():
- if action.getname() == name:
+ if TextMatched(action.getname(), name):
return action
return None
setattr(cls, "getaction", getaction)
@@ -1343,7 +1346,7 @@
if self.actions is not None:
removed = False
for action in self.actions.getaction():
- if action.getname() == name:
+ if TextMatched(action.getname(), name):
if action.getbodyType() in ["FBD", "LD", "SFC"]:
for instance in action.getinstances():
if isinstance(instance, PLCOpenParser.GetElementClass("block", "fbdObjects")):
@@ -1362,13 +1365,13 @@
for var in content.getvariable():
var_address = var.getaddress()
if var_address is not None:
- if var_address == old_name:
+ if TextMatched(var_address, old_name):
var.setaddress(new_name)
- if var.getname() == old_name:
+ if TextMatched(var.getname(), old_name):
var.setname(new_name)
var_type_content = var.gettype().getcontent()
if var_type_content.getLocalTag() == "derived":
- if var_type_content.getname() == old_name:
+ if TextMatched(var_type_content.getname(), old_name):
var_type_content.setname(new_name)
self.body[0].updateElementName(old_name, new_name)
for action in self.getactionList():
@@ -1395,7 +1398,7 @@
if self.interface is not None:
for content in self.interface.getcontent():
for variable in content.getvariable():
- if variable.getaddress() == address:
+ if TextMatched(variable.getaddress(), address):
content.remove(variable)
setattr(cls, "removeVariableByAddress", removeVariableByAddress)
@@ -1414,7 +1417,8 @@
search_result = []
filter = criteria["filter"]
if filter == "all" or self.getpouType() in filter:
- parent_infos = parent_infos + ["P::%s" % self.getname()]
+ if parent_infos == []:
+ parent_infos = parent_infos + ["P::%s" % self.getname()]
search_result.extend(_Search([("name", self.getname())], criteria, parent_infos))
if self.interface is not None:
var_number = 0
@@ -1486,8 +1490,7 @@
if self.getbodyType() in ["FBD", "LD", "SFC"]:
for instance in self.getinstances():
if (isinstance(instance, PLCOpenParser.GetElementClass("block", "fbdObjects")) and
- (name and instance.getinstanceName() == name or
- block_type and instance.gettypeName() == block_type)):
+ (TextMatched(instance.getinstanceName(), name) or TextMatched(instance.gettypeName(), block_type))):
return True
elif block_type is not None:
return self.body.hasblock(block_type)
@@ -1559,7 +1562,7 @@
cls = PLCOpenParser.GetElementClass("body")
if cls:
cls.currentExecutionOrderId = 0
-
+ cls.checkedBlocksDict = {}
def resetcurrentExecutionOrderId(self):
object.__setattr__(self, "currentExecutionOrderId", 0)
setattr(cls, "resetcurrentExecutionOrderId", resetcurrentExecutionOrderId)
@@ -1576,6 +1579,7 @@
PLCOpenParser.GetElementClass("connector", "commonObjects"),
PLCOpenParser.GetElementClass("continuation", "commonObjects"))):
element.setexecutionOrderId(0)
+ self.checkedBlocksDict.clear()
else:
raise TypeError, _("Can only generate execution order on FBD networks!")
setattr(cls, "resetexecutionOrder", resetexecutionOrder)
@@ -1598,16 +1602,19 @@
if self.content.getLocalTag() == "FBD":
localid = link.getrefLocalId()
instance = self.getcontentInstance(localid)
+ self.checkedBlocksDict[localid] = True
if isinstance(instance, PLCOpenParser.GetElementClass("block", "fbdObjects")) and instance.getexecutionOrderId() == 0:
for variable in instance.inputVariables.getvariable():
connections = variable.connectionPointIn.getconnections()
if connections and len(connections) == 1:
- self.compileelementExecutionOrder(connections[0])
- instance.setexecutionOrderId(self.getnewExecutionOrderId())
+ if (self.checkedBlocksDict.has_key(connections[0].getrefLocalId()) == False):
+ self.compileelementExecutionOrder(connections[0])
+ if instance.getexecutionOrderId() == 0:
+ instance.setexecutionOrderId(self.getnewExecutionOrderId())
elif isinstance(instance, PLCOpenParser.GetElementClass("continuation", "commonObjects")) and instance.getexecutionOrderId() == 0:
- name = instance.getname()
for tmp_instance in self.getcontentInstances():
- if isinstance(tmp_instance, PLCOpenParser.GetElementClass("connector", "commonObjects")) and tmp_instance.getname() == name and tmp_instance.getexecutionOrderId() == 0:
+ if (isinstance(tmp_instance, PLCOpenParser.GetElementClass("connector", "commonObjects")) and
+ TextMatched(tmp_instance.getname(), instance.getname()) and tmp_instance.getexecutionOrderId() == 0):
connections = tmp_instance.connectionPointIn.getconnections()
if connections and len(connections) == 1:
self.compileelementExecutionOrder(connections[0])
@@ -1907,7 +1914,7 @@
setattr(cls, "getBoundingBox", getBoundingBox)
def updateElementName(self, old_name, new_name):
- if self.typeName == old_name:
+ if TextMatched(self.typeName, old_name):
self.typeName = new_name
setattr(cls, "updateElementName", updateElementName)
@@ -1947,7 +1954,7 @@
_initElementClass("rightPowerRail", "ldObjects", "multiple")
def _UpdateLDElementName(self, old_name, new_name):
- if self.variable == old_name:
+ if TextMatched(self.variable, old_name):
self.variable = new_name
def _UpdateLDElementAddress(self, address_model, new_leading):
@@ -2053,7 +2060,7 @@
content = self.condition.getcontent()
content_name = content.getLocalTag()
if content_name == "reference":
- if content.getname() == old_name:
+ if TextMatched(content.getname(), old_name):
content.setname(new_name)
elif content_name == "inline":
content.updateElementName(old_name, new_name)
@@ -2125,7 +2132,7 @@
setattr(cls, "getinlineContent", getinlineContent)
def updateElementName(self, old_name, new_name):
- if self.reference is not None and self.reference.getname() == old_name:
+ if self.reference is not None and TextMatched(self.reference.getname(), old_name):
self.reference.setname(new_name)
if self.inline is not None:
self.inline.updateElementName(old_name, new_name)
@@ -2215,7 +2222,7 @@
return _Search([("expression", self.expression)], criteria, parent_infos + ["io_variable", self.getlocalId()])
def _UpdateIOElementName(self, old_name, new_name):
- if self.expression == old_name:
+ if TextMatched(self.expression, old_name):
self.expression = new_name
def _UpdateIOElementAddress(self, address_model, new_leading):
@@ -2248,7 +2255,7 @@
setattr(cls, "Search", _SearchInConnector)
def updateElementName(self, old_name, new_name):
- if self.name == old_name:
+ if TextMatched(self.name, old_name):
self.name = new_name
setattr(cls, "updateElementName", updateElementName)
@@ -2257,7 +2264,7 @@
setattr(cls, "Search", _SearchInConnector)
def updateElementName(self, old_name, new_name):
- if self.name == old_name:
+ if TextMatched(self.name, old_name):
self.name = new_name
setattr(cls, "updateElementName", updateElementName)
diff -r a375e31bf312 -r c1298e7ffe3a plcopen/structures.py
--- a/plcopen/structures.py Sun Mar 05 00:38:25 2017 +0000
+++ b/plcopen/structures.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of PLCOpenEditor, a library implementing an IEC 61131-3 editor
-#based on the plcopen standard.
-#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
-#
-#See COPYING file for copyrights details.
-#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
-#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
-#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import string, re
from plcopen import LoadProject
diff -r a375e31bf312 -r c1298e7ffe3a py_ext/PythonEditor.py
--- a/py_ext/PythonEditor.py Sun Mar 05 00:38:25 2017 +0000
+++ b/py_ext/PythonEditor.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,3 +1,27 @@
+#!/usr/bin/env python
+# -*- coding: utf-8 -*-
+
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+
import keyword
import wx.stc as stc
diff -r a375e31bf312 -r c1298e7ffe3a py_ext/PythonFileCTNMixin.py
--- a/py_ext/PythonFileCTNMixin.py Sun Mar 05 00:38:25 2017 +0000
+++ b/py_ext/PythonFileCTNMixin.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,3 +1,27 @@
+#!/usr/bin/env python
+# -*- coding: utf-8 -*-
+
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+
import os, re
from lxml import etree
@@ -258,10 +282,10 @@
pycfile.write(PyCFileContent)
pycfile.close()
- matiec_flags = '"-l -p -I%s"'%os.path.abspath(
+ matiec_CFLAGS = '"-I%s"'%os.path.abspath(
self.GetCTRoot().GetIECLibPath())
- return ([(Gen_PyCfile_path, matiec_flags)],
+ return ([(Gen_PyCfile_path, matiec_CFLAGS)],
"",
True,
("runtime_%s.py"%location_str, file(runtimefile_path,"rb")))
diff -r a375e31bf312 -r c1298e7ffe3a py_ext/__init__.py
--- a/py_ext/__init__.py Sun Mar 05 00:38:25 2017 +0000
+++ b/py_ext/__init__.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,3 +1,27 @@
+#!/usr/bin/env python
+# -*- coding: utf-8 -*-
+
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+
from py_ext import *
from PythonEditor import PythonEditor
from PythonFileCTNMixin import PythonFileCTNMixin
diff -r a375e31bf312 -r c1298e7ffe3a py_ext/py_ext.py
--- a/py_ext/py_ext.py Sun Mar 05 00:38:25 2017 +0000
+++ b/py_ext/py_ext.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,3 +1,27 @@
+#!/usr/bin/env python
+# -*- coding: utf-8 -*-
+
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+
import os
from POULibrary import POULibrary
from PythonFileCTNMixin import PythonFileCTNMixin
diff -r a375e31bf312 -r c1298e7ffe3a runtime/NevowServer.py
--- a/runtime/NevowServer.py Sun Mar 05 00:38:25 2017 +0000
+++ b/runtime/NevowServer.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,3 +1,27 @@
+#!/usr/bin/env python
+# -*- coding: utf-8 -*-
+
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+
import os
from nevow import rend, appserver, inevow, tags, loaders, athena
from nevow.page import renderer
@@ -154,7 +178,7 @@
listening = False
reactor.listenTCP(port, site)
- print "Http interface port :",port
+ print _("HTTP interface port :"), port
return website
class statuslistener:
diff -r a375e31bf312 -r c1298e7ffe3a runtime/PLCObject.py
--- a/runtime/PLCObject.py Sun Mar 05 00:38:25 2017 +0000
+++ b/runtime/PLCObject.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of Beremiz, a Integrated Development Environment for
-#programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import Pyro.core as pyro
from threading import Timer, Thread, Lock, Semaphore, Event
@@ -79,7 +79,8 @@
self.CurrentPLCFilename=open(
self._GetMD5FileName(),
"r").read().strip() + lib_ext
- self.LoadPLC()
+ if self.LoadPLC():
+ self.PLCStatus = "Stopped"
except Exception, e:
self.PLCStatus = "Empty"
self.CurrentPLCFilename=None
diff -r a375e31bf312 -r c1298e7ffe3a runtime/ServicePublisher.py
--- a/runtime/ServicePublisher.py Sun Mar 05 00:38:25 2017 +0000
+++ b/runtime/ServicePublisher.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,26 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
-#This file is part of Beremiz, a Integrated Development Environment for
-#programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import socket, threading
from util import Zeroconf
diff -r a375e31bf312 -r c1298e7ffe3a runtime/WampClient.py
--- a/runtime/WampClient.py Sun Mar 05 00:38:25 2017 +0000
+++ b/runtime/WampClient.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,6 +1,27 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+
import sys
#from twisted.python import log
from autobahn.twisted import wamp
diff -r a375e31bf312 -r c1298e7ffe3a runtime/__init__.py
--- a/runtime/__init__.py Sun Mar 05 00:38:25 2017 +0000
+++ b/runtime/__init__.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,3 +1,27 @@
+#!/usr/bin/env python
+# -*- coding: utf-8 -*-
+
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+
# module which import C files as strings
import os
diff -r a375e31bf312 -r c1298e7ffe3a svgui/__init__.py
--- a/svgui/__init__.py Sun Mar 05 00:38:25 2017 +0000
+++ b/svgui/__init__.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,1 +1,25 @@
+#!/usr/bin/env python
+# -*- coding: utf-8 -*-
+
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+
from svgui import *
diff -r a375e31bf312 -r c1298e7ffe3a svgui/svgui.py
--- a/svgui/svgui.py Sun Mar 05 00:38:25 2017 +0000
+++ b/svgui/svgui.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,3 +1,27 @@
+#!/usr/bin/env python
+# -*- coding: utf-8 -*-
+
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+
import wx
import os, sys, shutil
diff -r a375e31bf312 -r c1298e7ffe3a svgui/svgui_server.py
--- a/svgui/svgui_server.py Sun Mar 05 00:38:25 2017 +0000
+++ b/svgui/svgui_server.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,6 +1,27 @@
-#!/usr/bin/python
+#!/usr/bin/env python
# -*- coding: utf-8 -*-
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+
import os
from nevow import rend, appserver, inevow, tags, loaders, athena
diff -r a375e31bf312 -r c1298e7ffe3a svgui/svguilib.py
--- a/svgui/svguilib.py Sun Mar 05 00:38:25 2017 +0000
+++ b/svgui/svguilib.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,3 +1,26 @@
+#!/usr/bin/env python
+# -*- coding: utf-8 -*-
+
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
class button:
diff -r a375e31bf312 -r c1298e7ffe3a targets/Generic/__init__.py
--- a/targets/Generic/__init__.py Sun Mar 05 00:38:25 2017 +0000
+++ b/targets/Generic/__init__.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,3 +1,27 @@
+#!/usr/bin/env python
+# -*- coding: utf-8 -*-
+
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+
from ..toolchain_makefile import toolchain_makefile
class Generic_target(toolchain_makefile):
diff -r a375e31bf312 -r c1298e7ffe3a targets/Linux/__init__.py
--- a/targets/Linux/__init__.py Sun Mar 05 00:38:25 2017 +0000
+++ b/targets/Linux/__init__.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,3 +1,27 @@
+#!/usr/bin/env python
+# -*- coding: utf-8 -*-
+
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+
from ..toolchain_gcc import toolchain_gcc
class Linux_target(toolchain_gcc):
diff -r a375e31bf312 -r c1298e7ffe3a targets/Win32/__init__.py
--- a/targets/Win32/__init__.py Sun Mar 05 00:38:25 2017 +0000
+++ b/targets/Win32/__init__.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,3 +1,27 @@
+#!/usr/bin/env python
+# -*- coding: utf-8 -*-
+
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+
from ..toolchain_gcc import toolchain_gcc
class Win32_target(toolchain_gcc):
diff -r a375e31bf312 -r c1298e7ffe3a targets/Win32/plc_Win32_main.c
--- a/targets/Win32/plc_Win32_main.c Sun Mar 05 00:38:25 2017 +0000
+++ b/targets/Win32/plc_Win32_main.c Fri Mar 24 12:07:47 2017 +0000
@@ -84,7 +84,7 @@
if (debug_sem == NULL)
{
printf("startPLC CreateSemaphore debug_sem error: %d\n", GetLastError());
- return;
+ return 1;
}
debug_wait_sem = CreateSemaphore(
@@ -96,7 +96,7 @@
if (debug_wait_sem == NULL)
{
printf("startPLC CreateSemaphore debug_wait_sem error: %d\n", GetLastError());
- return;
+ return 1;
}
python_sem = CreateSemaphore(
@@ -108,7 +108,7 @@
if (python_sem == NULL)
{
printf("startPLC CreateSemaphore python_sem error: %d\n", GetLastError());
- return;
+ return 1;
}
python_wait_sem = CreateSemaphore(
NULL, // default security attributes
@@ -120,7 +120,7 @@
if (python_wait_sem == NULL)
{
printf("startPLC CreateSemaphore python_wait_sem error: %d\n", GetLastError());
- return;
+ return 1;
}
diff -r a375e31bf312 -r c1298e7ffe3a targets/XSD_toolchain_gcc
--- a/targets/XSD_toolchain_gcc Sun Mar 05 00:38:25 2017 +0000
+++ b/targets/XSD_toolchain_gcc Fri Mar 24 12:07:47 2017 +0000
@@ -1,5 +1,5 @@
-
+
-
+
diff -r a375e31bf312 -r c1298e7ffe3a targets/Xenomai/__init__.py
--- a/targets/Xenomai/__init__.py Sun Mar 05 00:38:25 2017 +0000
+++ b/targets/Xenomai/__init__.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,3 +1,27 @@
+#!/usr/bin/env python
+# -*- coding: utf-8 -*-
+
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+
from ..toolchain_gcc import toolchain_gcc
class Xenomai_target(toolchain_gcc):
diff -r a375e31bf312 -r c1298e7ffe3a targets/__init__.py
--- a/targets/__init__.py Sun Mar 05 00:38:25 2017 +0000
+++ b/targets/__init__.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,23 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
+
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
# Package initialisation
#import targets
diff -r a375e31bf312 -r c1298e7ffe3a targets/plc_debug.c
--- a/targets/plc_debug.c Sun Mar 05 00:38:25 2017 +0000
+++ b/targets/plc_debug.c Fri Mar 24 12:07:47 2017 +0000
@@ -149,7 +149,7 @@
void Retain(unsigned int offset, unsigned int count, void * p);
-inline void BufferIterator(dbgvardsc_t *dsc, int do_debug)
+static inline void BufferIterator(dbgvardsc_t *dsc, int do_debug)
{
void *real_value_p = NULL;
void *visible_value_p = NULL;
diff -r a375e31bf312 -r c1298e7ffe3a targets/plc_main_tail.c
--- a/targets/plc_main_tail.c Sun Mar 05 00:38:25 2017 +0000
+++ b/targets/plc_main_tail.c Fri Mar 24 12:07:47 2017 +0000
@@ -16,7 +16,7 @@
#define LOG_BUFFER_MASK (LOG_BUFFER_SIZE-1)
static char LogBuff[LOG_LEVELS][LOG_BUFFER_SIZE] LOG_BUFFER_ATTRS;
-void inline copy_to_log(uint8_t level, uint32_t buffpos, void* buf, uint32_t size){
+static void inline copy_to_log(uint8_t level, uint32_t buffpos, void* buf, uint32_t size){
if(buffpos + size < LOG_BUFFER_SIZE){
memcpy(&LogBuff[level][buffpos], buf, size);
}else{
@@ -25,7 +25,7 @@
memcpy(LogBuff[level], (char*)buf + remaining, size - remaining);
}
}
-void inline copy_from_log(uint8_t level, uint32_t buffpos, void* buf, uint32_t size){
+static void inline copy_from_log(uint8_t level, uint32_t buffpos, void* buf, uint32_t size){
if(buffpos + size < LOG_BUFFER_SIZE){
memcpy(buf, &LogBuff[level][buffpos], size);
}else{
diff -r a375e31bf312 -r c1298e7ffe3a targets/toolchain_gcc.py
--- a/targets/toolchain_gcc.py Sun Mar 05 00:38:25 2017 +0000
+++ b/targets/toolchain_gcc.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,3 +1,27 @@
+#!/usr/bin/env python
+# -*- coding: utf-8 -*-
+
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+
import os, re, operator
from util.ProcessLogger import ProcessLogger
import hashlib
diff -r a375e31bf312 -r c1298e7ffe3a targets/toolchain_makefile.py
--- a/targets/toolchain_makefile.py Sun Mar 05 00:38:25 2017 +0000
+++ b/targets/toolchain_makefile.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,3 +1,27 @@
+#!/usr/bin/env python
+# -*- coding: utf-8 -*-
+
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
+#
+# Copyright (C) 2007: Edouard TISSERANT and Laurent BESSARD
+#
+# See COPYING file for copyrights details.
+#
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+
import os, re, operator
from util.ProcessLogger import ProcessLogger
import hashlib
@@ -6,15 +30,6 @@
includes_re = re.compile('\s*#include\s*["<]([^">]*)[">].*')
-
-if os.name == 'nt':
- # on windows, desktop shortcut launches Beremiz.py
- # with working dir set to mingw/bin.
- # then we prefix CWD to PATH in order to ensure that
- # commands invoked from Makefiles will first resolve
- # to here.
- os.environ["PATH"] = os.getcwd()+';'+os.environ["PATH"]
-
class toolchain_makefile():
def __init__(self, CTRInstance):
self.CTRInstance = CTRInstance
@@ -80,11 +95,7 @@
oldmd5 = self.md5key
self.md5key = hashlib.md5(wholesrcdata).hexdigest()
- props = self.CTRInstance.GetProjectProperties()
- self.md5key += '#'.join([props[key] for key in ['companyName',
- 'projectName',
- 'productName']])
- self.md5key += '#' #+','.join(map(str,time.localtime()))
+
# Store new PLC filename based on md5 key
f = open(self._GetMD5FileName(), "w")
f.write(self.md5key)
@@ -98,7 +109,10 @@
"buildpath": self.buildpath
}
- command = [ token % beremizcommand for token in target.getCommand().split(' ')]
+ # clean sequence of multiple whitespaces
+ cmd = re.sub(r"[ ]+", " ", target.getCommand())
+
+ command = [ token % beremizcommand for token in cmd.split(' ')]
# Call Makefile to build PLC code and link it with target specific code
status, result, err_result = ProcessLogger(self.CTRInstance.logger,
diff -r a375e31bf312 -r c1298e7ffe3a targets/typemapping.py
--- a/targets/typemapping.py Sun Mar 05 00:38:25 2017 +0000
+++ b/targets/typemapping.py Fri Mar 24 12:07:47 2017 +0000
@@ -1,23 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
+
+# This file is part of Beremiz, a Integrated Development Environment for
+# programming IEC 61131-3 automates supporting plcopen standard and CanFestival.
#
-#Copyright (C) 2011: Edouard TISSERANT and Laurent BESSARD
+# Copyright (C) 2011: Edouard TISSERANT and Laurent BESSARD
#
-#See COPYING file for copyrights details.
+# See COPYING file for copyrights details.
#
-#This library is free software; you can redistribute it and/or
-#modify it under the terms of the GNU General Public
-#License as published by the Free Software Foundation; either
-#version 2.1 of the License, or (at your option) any later version.
+# 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 the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
#
-#This library is distributed in the hope that it will be useful,
-#but WITHOUT ANY WARRANTY; without even the implied warranty of
-#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-#General Public License for more details.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
#
-#You should have received a copy of the GNU General Public
-#License along with this library; if not, write to the Free Software
-#Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
import ctypes
ctypes.pythonapi.PyString_AsString.argtypes = (ctypes.c_void_p,)
diff -r a375e31bf312 -r c1298e7ffe3a tests/first_steps/beremiz.xml
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/first_steps/beremiz.xml Fri Mar 24 12:07:47 2017 +0000
@@ -0,0 +1,6 @@
+
+
+
+
+
+
diff -r a375e31bf312 -r c1298e7ffe3a tests/first_steps/plc.xml
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/first_steps/plc.xml Fri Mar 24 12:07:47 2017 +0000
@@ -0,0 +1,1019 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Reset
+
+
+
+
+
+
+
+
+
+
+ Cnt1
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Cnt2
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Cnt3
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Reset
+
+
+
+
+
+
+
+
+
+
+ Cnt4
+
+
+
+
+
+
+ Reset
+
+
+
+
+
+
+ Reset
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Cnt5
+
+
+
+
+
+
+ Reset
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Reset
+
+
+
+
+
+
+
+
+
+
+ OUT
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Cnt
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ ResetCounterValue
+
+
+
+
+
+
+ 1
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Out
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Cnt
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ ResetCounterValue
+
+
+
+
+
+
+ 1
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Reset
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff -r a375e31bf312 -r c1298e7ffe3a tests/genericmake/plc.xml
--- a/tests/genericmake/plc.xml Sun Mar 05 00:38:25 2017 +0000
+++ b/tests/genericmake/plc.xml Fri Mar 24 12:07:47 2017 +0000
@@ -1,7 +1,7 @@
-
-
+
+
@@ -35,25 +35,44 @@
-
+
LocalVara
-
+
-
-
-
-
+
+
LocalVarb
+
+
+
+
+
+
diff -r a375e31bf312 -r c1298e7ffe3a tests/genericmake/project_files/Makefile
--- a/tests/genericmake/project_files/Makefile Sun Mar 05 00:38:25 2017 +0000
+++ b/tests/genericmake/project_files/Makefile Fri Mar 24 12:07:47 2017 +0000
@@ -9,5 +9,5 @@
some_binary: $(BEREMIZ_OBJS)
@echo "* Would link $^ -> $@"
-%o : %c
+%.o: %.c
@echo "* Would compile $< -> $@"
diff -r a375e31bf312 -r c1298e7ffe3a tests/logging/plc.xml
--- a/tests/logging/plc.xml Sun Mar 05 00:38:25 2017 +0000
+++ b/tests/logging/plc.xml Fri Mar 24 12:07:47 2017 +0000
@@ -1,14 +1,7 @@
-
-
-
-
+
+
+
+
@@ -47,29 +40,34 @@
-
+
+
+
+
+
+
-
-
-
-
-
- 'Moooooo'
+
+
+
+
+
+ 'IEC side logging: beat #'
-
-
+
+
-
-
-
+
+
+
@@ -83,121 +81,117 @@
-
-
+
+
-
-
-
-
-
-
+
+
+
+
+
+
-
+
beat
-
-
+
+
-
+
-
-
-
-
+
+
+
+
+
+
-
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
+
+
+
+
+
+
-
+
count
-
-
+
+
-
+
-
-
-
-
+
+
-
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
+
+
@@ -211,19 +205,17 @@
-
-
+
+
-
-
-
-
-
-
+
+
+
+
@@ -237,39 +229,33 @@
-
-
+
+
-
+
-
-
-
-
+
+
-
+
-
-
-
-
+
+
-
+
-
-
-
-
+
+
@@ -277,13 +263,72 @@
-
-
+
+
- WARNING
+ lvl
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ T#3s
+
+
+
+
+
+
+
@@ -293,8 +338,8 @@
-
-
+
+
diff -r a375e31bf312 -r c1298e7ffe3a tests/logging/py_ext_0@py_ext/py_ext.xml
--- a/tests/logging/py_ext_0@py_ext/py_ext.xml Sun Mar 05 00:38:25 2017 +0000
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,26 +0,0 @@
-
-
-
-
diff -r a375e31bf312 -r c1298e7ffe3a tests/logging/py_ext_0@py_ext/pyfile.xml
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/logging/py_ext_0@py_ext/pyfile.xml Fri Mar 24 12:07:47 2017 +0000
@@ -0,0 +1,41 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff -r a375e31bf312 -r c1298e7ffe3a tests/python/plc.xml
--- a/tests/python/plc.xml Sun Mar 05 00:38:25 2017 +0000
+++ b/tests/python/plc.xml Fri Mar 24 12:07:47 2017 +0000
@@ -1,7 +1,7 @@
-
-
+
+
@@ -54,6 +54,22 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -128,17 +144,30 @@
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
+
+
+
@@ -208,24 +237,24 @@
-
-
+
+
'time.sleep(1)'
-
-
+
+
-
-
-
-
+
+
+
+
@@ -233,8 +262,8 @@
-
-
+
+
@@ -253,15 +282,15 @@
-
-
+
+
-
-
+
+
@@ -275,17 +304,17 @@
-
-
+
+
-
-
-
-
-
-
+
+
+
+
+
+
@@ -293,17 +322,17 @@
pytest_var2
-
-
+
+
-
-
-
-
+
+
+
+
@@ -311,8 +340,8 @@
-
-
+
+
@@ -331,31 +360,31 @@
-
-
+
+
'sys.stdout.write("FBID :"+str(FBID)+"\n")'
-
-
+
+
'PLCBinary.Simple_C_Call(5678)'
-
-
+
+
-
-
-
-
+
+
+
+
@@ -363,8 +392,8 @@
-
-
+
+
@@ -383,24 +412,24 @@
-
-
+
+
'MyPythonFunc(42)'
-
-
+
+
-
-
-
-
+
+
+
+
@@ -408,8 +437,8 @@
-
-
+
+
@@ -429,20 +458,22 @@
-
+
-
+
-
-
+
+
-
-
+
+
+
+
@@ -450,10 +481,10 @@
-
-
-
-
+
+
+
+
@@ -461,10 +492,10 @@
-
-
-
-
+
+
+
+
@@ -472,10 +503,10 @@
-
-
-
-
+
+
+
+
@@ -483,8 +514,8 @@
-
-
+
+
@@ -498,33 +529,28 @@
-
-
-
-
-
- 3
-
-
-
+
+
-
-
+
+
pytest_var1
-
-
+
+
-
-
+
+
+
+
@@ -532,8 +558,8 @@
-
-
+
+
@@ -541,10 +567,10 @@
-
-
-
-
+
+
+
+
@@ -552,10 +578,10 @@
-
-
-
-
+
+
+
+
@@ -563,10 +589,10 @@
-
-
-
-
+
+
+
+
@@ -580,51 +606,51 @@
-
-
-
-
-
- 3
-
-
-
+
+
+
+
+
+ mux1_sel
+
+
+
-
-
+
+
pytest_var3
-
-
+
+
-
-
+
+
FromC
-
-
+
+
23
-
-
+
+
-
-
+
+
@@ -638,139 +664,129 @@
-
-
+
+
TestInput
-
-
+
+
-
-
+
+
TestOutput
-
-
+
+
-
-
+
+
FromInput
-
-
+
+
10
-
-
+
+
+Happy hacking! ]]>
-
+
-
+
-
+
-
+
-
-
-
-
+
+
+
+
-
-
+
+
Test_BCD_RESULT
-
-
-
-
+
+
+
+
Test_BCD
-
-
-
-
-
-
-
-
+
+
+
-
+
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
Test_DT
-
-
+
+
-
+
-
-
+
+
@@ -779,22 +795,22 @@
-
-
-
-
-
-
-
+
+
+
+
+
+
+
-
+
-
-
-
-
+
+
+
+
@@ -803,53 +819,53 @@
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
-
-
+
+
Test_Date
-
-
-
-
+
+
+
+
-
-
+
+
Test_String
-
-
-
-
+
+
+
+
-
-
+
+
Test_Bool
-
-
+
+
-
+
-
-
+
+
@@ -858,27 +874,27 @@
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
'True'
-
-
+
+
-
+
-
-
+
+
@@ -887,27 +903,27 @@
-
+
-
+
Global_RS.Q1
-
+
-
-
+
+
@@ -915,8 +931,8 @@
-
-
+
+
@@ -930,51 +946,51 @@
-
-
-
-
+
+
+
+
BOOL#TRUE
-
+
-
-
+
+
Global_RS.S
-
+
-
-
+
+
Global_RS.R1
-
+
Global_RS.Q1
-
+
-
-
+
+
@@ -982,8 +998,8 @@
-
-
+
+
@@ -997,46 +1013,33 @@
-
-
-
-
+
+
+
+
BOOL#FALSE
-
-
-
-
-
-
-
-
-
-
-
- Test_BCD_ENO
-
-
-
-
-
+
+
+
+
-
-
+
+
Test_TOD_STRING
-
-
+
+
-
+
-
-
+
+
@@ -1045,90 +1048,90 @@
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
+
+
+
+
+
+
Test_TOD
-
-
+
+
42
-
-
+
+
-
-
+
+
TOTO
-
-
+
+
-
-
-
-
+
+
+
+
TUTU
-
-
-
-
+
+
+
+
Second_Python_Var
-
-
+
+
-
-
+
+
Test_Python_Var
-
-
+
+
23
-
+
-
-
+
+
@@ -1143,23 +1146,147 @@
-
+
fefvsd
-
+
-
-
+
+
fefvsd
+
+
+
+
+
+
+
+
+
+
+
+ mux2_sel
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Test_BCD_WRONG
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Test_BCD_WRONG_RESULT
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Test_BCD_CONVERTED
+
+
+
+
+
+
+
@@ -1243,7 +1370,7 @@
SetFbVar(COORDS, somebyte, .table[4]);
}
}}
-(* If you do not use __GET_VAR and _SET_VAR macro, expect unexpected *)
+(* If you do not use GetFbVar and SetFbVar macros, expect unexpected behaviour*)
Global_RS();
]]>
diff -r a375e31bf312 -r c1298e7ffe3a tests/svgui/plc.xml
--- a/tests/svgui/plc.xml Sun Mar 05 00:38:25 2017 +0000
+++ b/tests/svgui/plc.xml Fri Mar 24 12:07:47 2017 +0000
@@ -1,14 +1,7 @@
-
-
-
-
+
+
+
+
@@ -33,57 +26,17 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
-
+
@@ -92,15 +45,15 @@
-
-
+
+
-
-
+
+
@@ -108,8 +61,8 @@
-
-
+
+
@@ -117,12 +70,12 @@
-
-
-
-
-
-
+
+
+
+
+
+
@@ -141,71 +94,71 @@
-
-
+
+
-
+
-
-
+
+
-
+
counter
-
-
-
-
+
+
+
+
BOOL#1
-
-
+
+
'stop_back'
-
-
+
+
'stop_sele'
-
-
-
-
-
- 'text_compteur'
-
-
-
-
-
+
+
+
+
+
+ 'text_counter'
+
+
+
+
+
'led_stop'
-
-
+
+
'led_start'
-
-
+
+
-
-
+
+
@@ -219,24 +172,24 @@
-
-
+
+
-
+
-
-
+
+
-
+
-
-
+
+
@@ -244,19 +197,19 @@
-
-
+
+
-
+
-
+
@@ -264,45 +217,45 @@
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
BOOL#1
-
-
+
+
-
-
+
+
-
+
-
-
+
+
-
+
-
-
+
+
@@ -310,31 +263,31 @@
-
-
-
-
+
+
+
+
BOOL#1
-
-
+
+
-
+
-
-
+
+
-
+
-
-
+
+
@@ -342,8 +295,8 @@
-
-
+
+
@@ -351,28 +304,28 @@
-
-
+
+
-
+
-
-
-
-
-
-
+
+
+
+
+
+
-
+
-
-
+
+
@@ -381,68 +334,96 @@
-
+
-
+
-
-
+
+
-
+
-
-
+
+
-
-
+
+
+
+
+
+
+
+
+
+
+
+ counter
+
+
+
-
-
-
-
-
- counter
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
@@ -451,45 +432,41 @@
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
diff -r a375e31bf312 -r c1298e7ffe3a tests/svgui/svgui@svgui/py_ext.xml
--- a/tests/svgui/svgui@svgui/py_ext.xml Sun Mar 05 00:38:25 2017 +0000
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,4 +0,0 @@
-
-
-
-
diff -r a375e31bf312 -r c1298e7ffe3a tests/svgui/svgui@svgui/pyfile.xml
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/svgui/svgui@svgui/pyfile.xml Fri Mar 24 12:07:47 2017 +0000
@@ -0,0 +1,33 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff -r a375e31bf312 -r c1298e7ffe3a tests/traffic_lights/plc.xml
--- a/tests/traffic_lights/plc.xml Sun Mar 05 00:38:25 2017 +0000
+++ b/tests/traffic_lights/plc.xml Fri Mar 24 12:07:47 2017 +0000
@@ -1,7 +1,7 @@
-
-
+
+
@@ -405,8 +405,8 @@
-
-
+
+
@@ -512,7 +512,7 @@
-
+
@@ -554,7 +554,7 @@
-
+
@@ -696,7 +696,7 @@
-
+
@@ -731,7 +731,11 @@
-
+
+
+
+
+
@@ -796,7 +800,7 @@
-
+
@@ -831,7 +835,12 @@
-
+
+
+
+
+
+
@@ -896,7 +905,7 @@
-
+
@@ -1112,6 +1121,92 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ SWITCH_BUTTON
+
+
+
+
+
+
+
-
-
+
+
-
-
-
-
+
+
@@ -1216,8 +1273,10 @@
-
-
+
+
+
+
@@ -1251,15 +1310,15 @@
-
-
+
+
-
-
+
+
@@ -1267,8 +1326,8 @@
-
-
+
+
@@ -1276,8 +1335,8 @@
-
-
+
+
@@ -1301,15 +1360,15 @@
-
-
+
+
-
-
+
+
@@ -1317,8 +1376,8 @@
-
-
+
+
@@ -1347,50 +1406,50 @@
-
-
+
+
1
-
-
+
+
'SWITCH_OFF'
-
-
+
+
'SWITCH_ON'
-
-
+
+
'PEDESTRIAN_OFF'
-
-
+
+
'PEDESTRIAN_ON'
-
-
+
+
-
-
+
+
@@ -1398,8 +1457,8 @@
-
-
+
+
@@ -1407,8 +1466,8 @@
-
-
+
+
@@ -1416,29 +1475,29 @@
-
-
+
+
'RED_OFF'
-
-
+
+
'RED_ON'
-
-
+
+
-
-
+
+
@@ -1446,8 +1505,8 @@
-
-
+
+
@@ -1455,8 +1514,8 @@
-
-
+
+
@@ -1464,29 +1523,29 @@
-
-
+
+
'ORANGE_OFF'
-
-
+
+
'ORANGE_ON'
-
-
+
+
-
-
+
+
@@ -1494,8 +1553,8 @@
-
-
+
+
@@ -1503,8 +1562,8 @@
-
-
+
+
@@ -1512,29 +1571,29 @@
-
-
+
+
'GREEN_OFF'
-
-
+
+
'GREEN_ON'
-
-
+
+
-
-
+
+
@@ -1542,8 +1601,8 @@
-
-
+
+
@@ -1551,8 +1610,8 @@
-
-
+
+
@@ -1560,29 +1619,29 @@
-
-
+
+
'PEDESTRIAN_RED_OFF'
-
-
+
+
'PEDESTRIAN_RED_ON'
-
-
+
+
-
-
+
+
@@ -1590,8 +1649,8 @@
-
-
+
+
@@ -1599,8 +1658,8 @@
-
-
+
+
@@ -1608,236 +1667,52 @@
-
-
+
+
'PEDESTRIAN_GREEN_OFF'
-
-
+
+
'PEDESTRIAN_GREEN_ON'
-
-
-
-
-
- TEST_DATE
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- RESULT_STRING
-
-
-
-
-
-
- TEST_ULINT
-
-
-
-
-
-
-
-
-
-
- RESULT_INT
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- RESULT_INT
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- 0
-
-
-
-
-
-
- 31
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- RESULT_BYTE
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- 1
-
+
+
+
+
+
+
+
+
+
+
+
+