示例#1
0
    def __init__(self, parent=None):
        QDialog.__init__(self, parent)
        self.setupUi(self)

        # self.title.setText( name() + version() )
        # self.description.setText( description() )

        text = self.txt.toHtml()
        text = text.replace("$PLUGIN_NAME$", name())
        text = text.replace("$PLUGIN_VERSION$", version())

        subject = "Help: %s" % name()
        body = """\n\n
--------
Plugin name: %s
Plugin version: %s
Python version: %s
Platform: %s - %s
--------
""" % (name(), version(), platform.python_version(), platform.system(), platform.version())

        mail = QUrl("mailto:[email protected]")
        mail.addQueryItem("subject", subject)
        mail.addQueryItem("body", body)

        text = text.replace("$MAIL_SUBJECT$", unicode(mail.encodedQueryItemValue("subject")))
        text = text.replace("$MAIL_BODY$", unicode(mail.encodedQueryItemValue("body")))

        self.txt.setHtml(text)
示例#2
0
    def __init__(self, parent=None):
        QDialog.__init__(self, parent)
        self.setupUi(self)

        # self.title.setText( name() + version() )
        # self.description.setText( description() )

        text = self.txt.toHtml()
        text = text.replace("$PLUGIN_NAME$", name())
        text = text.replace("$PLUGIN_VERSION$", version())

        subject = "Help: %s" % name()
        body = """\n\n
--------
Plugin name: %s
Plugin version: %s
Python version: %s
Platform: %s - %s
--------
""" % (name(), version(), platform.python_version(), platform.system(),
        platform.version())

        mail = QUrl("mailto:[email protected]")
        mail.addQueryItem("subject", subject)
        mail.addQueryItem("body", body)

        text = text.replace("$MAIL_SUBJECT$",
                            unicode(mail.encodedQueryItemValue("subject")))
        text = text.replace("$MAIL_BODY$",
                            unicode(mail.encodedQueryItemValue("body")))

        self.txt.setHtml(text)
示例#3
0
    def __init__(self, parent=None):
        QDialog.__init__(self, parent)
        self.setupUi(self)

        config = ConfigParser.ConfigParser()
        config.read(os.path.join(os.path.dirname(__file__), 'metadata.txt'))

        name = config.get('general', 'name')
        description = config.get('general', 'description')
        version = config.get('general', 'version')

        # self.title.setText( name )
        # self.description.setText( description )

        text = self.txt.toHtml()
        text = text.replace("$PLUGIN_NAME$", name)
        text = text.replace("$PLUGIN_VERSION$", version)

        subject = "Help: %s" % name
        body = """\n\n
--------
Plugin name: %s
Plugin version: %s
Python version: %s
Platform: %s - %s
--------
""" % (name, version, platform.python_version(), platform.system(),
        platform.version())

        mail = QUrl("mailto:[email protected]")
        mail.addQueryItem("subject", subject)
        mail.addQueryItem("body", body)

        text = text.replace("$MAIL_SUBJECT$",
                            unicode(mail.encodedQueryItemValue("subject")))
        text = text.replace("$MAIL_BODY$",
                            unicode(mail.encodedQueryItemValue("body")))

        self.txt.setHtml(text)
示例#4
0
    def __init__(self, parent=None):
        QDialog.__init__(self, parent)
        self.setupUi(self)

        config = ConfigParser.ConfigParser()
        config.read(os.path.join(os.path.dirname(__file__), 'metadata.txt'))

        name        = config.get('general', 'name')
        description = config.get('general', 'description')
        version     = config.get('general', 'version')

        # self.title.setText( name )
        # self.description.setText( description )

        text = self.txt.toHtml()
        text = text.replace("$PLUGIN_NAME$", name)
        text = text.replace("$PLUGIN_VERSION$", version)

        subject = "Help: %s" % name
        body = """\n\n
--------
Plugin name: %s
Plugin version: %s
Python version: %s
Platform: %s - %s
--------
""" % (name, version, platform.python_version(), platform.system(), platform.version())

        mail = QUrl("mailto:[email protected]")
        mail.addQueryItem("subject", subject)
        mail.addQueryItem("body", body)

        text = text.replace("$MAIL_SUBJECT$", unicode(mail.encodedQueryItemValue("subject")))
        text = text.replace("$MAIL_BODY$", unicode(mail.encodedQueryItemValue("body")))

        self.txt.setHtml(text)