Exemple #1
0
 def about_mitemOnMenuSelection(self, event):
     try:
         # noinspection PyPackageRequirements
         from wx.lib.wordwrap import wordwrap
         info = AboutDialogInfo()
         info.Name = "Lattice Viewer"
         info.Version = "0.1.0"
         info.Copyright = "(C) 2016 Tong Zhang, SINAP, CAS"
         info.Description = wordwrap(
             "This is application is created for showing the lattice elements "
             "and configurations in tree style.", 350, wx.ClientDC(self))
         info.Developers = ["Tong Zhang <*****@*****.**>", ]
         lt = "Lattice Viewer 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 3 of the License, or (at your option) any " \
              + "later version.\n" \
              + "\nLattice Viewer 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.\n" \
              + "\nYou should have received a copy of the GNU General Public License " \
              + "along with Lattice Viewer; if not, write to the Free Software " \
              + "Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA"
         info.License = wordwrap(lt, 500, wx.ClientDC(self))
         AboutBox(info)
     except:
         dial = wx.MessageDialog(self,
                                 "Cannot show about informaion, sorry!",
                                 "Unknown Error",
                                 style=wx.OK | wx.CANCEL | wx.ICON_ERROR |
                                       wx.CENTRE)
         if dial.ShowModal() == wx.ID_OK:
             dial.Destroy()
Exemple #2
0
    def on_about(event):
        r"""About has been chosen from the menu

        Parameters
        ----------
        event : wx.Event

        """
        info = AboutDialogInfo()
        info.Name = cadracks_ide.__name__
        info.Version = cadracks_ide.__version__
        info.Copyright = "(C) 2017 2018 2019 CadRacks"
        info.WebSite = (cadracks_ide.__url__, )
        info.Developers = [cadracks_ide.__author__]
        info.License = cadracks_ide.__license__
        AboutBox(info)  # Show the wx.AboutBox
Exemple #3
0
 def about_mitemOnMenuSelection(self, event):
     try:
         # noinspection PyPackageRequirements
         from wx.lib.wordwrap import wordwrap
         info = AboutDialogInfo()
         info.Name = "Lattice Viewer"
         info.Version = "0.1.0"
         info.Copyright = "(C) 2016 Tong Zhang, SINAP, CAS"
         info.Description = wordwrap(
             "This is application is created for showing the lattice elements "
             "and configurations in tree style.", 350, wx.ClientDC(self))
         info.Developers = [
             "Tong Zhang <*****@*****.**>",
         ]
         lt = "Lattice Viewer 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 3 of the License, or (at your option) any " \
              + "later version.\n" \
              + "\nLattice Viewer 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.\n" \
              + "\nYou should have received a copy of the GNU General Public License " \
              + "along with Lattice Viewer; if not, write to the Free Software " \
              + "Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA"
         info.License = wordwrap(lt, 500, wx.ClientDC(self))
         AboutBox(info)
     except:
         dial = wx.MessageDialog(self,
                                 "Cannot show about informaion, sorry!",
                                 "Unknown Error",
                                 style=wx.OK | wx.CANCEL | wx.ICON_ERROR
                                 | wx.CENTRE)
         if dial.ShowModal() == wx.ID_OK:
             dial.Destroy()