Aller à la documentation de ce fichier.00001
00002
00003
00004
00005 licence={}
00006 licence['en']="""
00007 file mytextbrowser.py
00008 this file is part of the project scolasync
00009
00010 Copyright (C) 2010 Georges Khaznadar <georgesk@ofset.org>
00011
00012 This program is free software: you can redistribute it and/or modify
00013 it under the terms of the GNU General Public License as published by
00014 the Free Software Foundation, either version3 of the License, or
00015 (at your option) any later version.
00016
00017 This program is distributed in the hope that it will be useful,
00018 but WITHOUT ANY WARRANTY; without even the implied warranty of
00019 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
00020 GNU General Public License for more details.
00021
00022 You should have received a copy of the GNU General Public License
00023 along with this program. If not, see <http://www.gnu.org/licenses/>.
00024 """
00025
00026 from PyQt4.QtCore import *
00027 from PyQt4.QtGui import *
00028 import subprocess
00029
00030
00031
00032
00033
00034 class myTextBrowser(QTextBrowser):
00035
00036
00037
00038
00039
00040 def setSource(self,url):
00041 subprocess.call("(firefox %s &)"%url.toString(),shell=True)
00042
00043
00044
00045
00046
00047
00048 def setHtml(self,url):
00049 QTextBrowser.setSource(self,url)
00050