Esempio n. 1
0
	def run_reitwander(self): 
		import WebGui
		bl=self.root.ids['bl'].text()
		spli=bl.split(',')
		my=float(spli[0])
		mx=float(spli[1])
		WebGui.openBrowser( "http://www.wanderreitkarte.de/index.php?lon="+str(mx)+"&lat="+str(my)+"&zoom=12")
Esempio n. 2
0
	def run_google(self): 
		import WebGui
		bl=self.root.ids['bl'].text()
		spli=bl.split(',')
		my=float(spli[0])
		mx=float(spli[1])
		WebGui.openBrowser( "https://www.google.de/maps/@"+str(my)+','+str(mx) +",8000m/data=!3m1!1e3")
Esempio n. 3
0
	def run_browser(self): 
		import WebGui
		bl=self.root.ids['bl'].text()
		spli=bl.split(',')
		my=float(spli[0])
		mx=float(spli[1])
		WebGui.openBrowser( "http://www.openstreetmap.org/#map=12/"+str(my)+'/'+str(mx))
Esempio n. 4
0
 def showMap(self):
     bl = self.root.ids["bl"].text()
     spli = bl.split(",")
     b = float(spli[0])
     l = float(spli[1])
     s = 15
     WebGui.openBrowser("http://www.openstreetmap.org/#map=16/" + str(b) + "/" + str(l))
Esempio n. 5
0
	def showMap(self):
		print "Run values"
		b=self.root.ids['b'].text()
		l=self.root.ids['l'].text()
		s=self.root.ids['s'].value()
		print [l,b,s]
		import WebGui
		WebGui.openBrowser( "http://www.openstreetmap.org/#map=16/"+str(b)+'/'+str(l))
Esempio n. 6
0
	def showMap(self):
		print "Run values"
		bl=self.root.ids['bl'].text()
		spli=bl.split(',')
		b=float(spli[0])
		l=float(spli[1])
		s=self.root.ids['s'].value()
		print [l,b,s]
		WebGui.openBrowser( "http://www.openstreetmap.org/#map=16/"+str(b)+'/'+str(l))
Esempio n. 7
0
	def showMap(self):
		'''open a webbrowser window and display the openstreetmap presentation of the area'''

		bl_disp=self.root.ids['lat'].text()
		b=float(bl_disp)
		bl_disp=self.root.ids['long'].text()
		l=float(bl_disp)
		
		
		s=self.root.ids['s'].value()
		print [l,b,s]
		WebGui.openBrowser( "http://www.openstreetmap.org/#map=16/"+str(b)+'/'+str(l))
	def on_pushButton02_clicked(self):
		text=""
		for sel in self.listWidget.selectedItems():
			plugin=sel.text()
			text += "*** "+ sel.text() + " ***"
			say(text)
			say(self.config[sel.text()])
			say("ok")
			text += "\n" + str(self.config[sel.text()]['author'])
			say(text)
			text += "\n" + str(self.config[sel.text()]['source'])
			say(text)
			text += "\n" + str(self.config[sel.text()]['description'])
			say(text)
			text += "\n"
			mess=""
			try:
				import re
				source=str(self.config[sel.text()]['source'])
				say(source)
				m = re.match(r"https://github.com/(.*)/archive/master.zip", source)
				say(m)
				say(m.group(1))
				gitdate='no date from git'
				if m: 
					fn='https://api.github.com/repos/' + m.group(1) + '/commits'
					import urllib,json
					data=urllib.urlopen(fn).read()
					d = json.loads(data)
					dit=d[0]
					gitdate=dit['commit']['committer']['date']
				say(gitdate)
				installdate=FreeCAD.ParamGet('User parameter:/Plugins/'+plugin).GetString("installdate")
				if installdate >gitdate:
					mess="--- package " + plugin + " is up to date ---"
				else:
					mess="!!! update for " + plugin + " recommented !!!"
				FreeCAD.ParamGet('User parameter:/Plugins/'+plugin).SetString("gitdate",gitdate)
			except:
				sayexc()
				
			text += "my install:  " + FreeCAD.ParamGet('User parameter:/Plugins/'+plugin).GetString("installdate") + "\n"
			text += "git version:  " + FreeCAD.ParamGet('User parameter:/Plugins/'+plugin).GetString("gitdate","not implemented") + "\n"
			text += "\n" + mess + "\n\n"
		self.lab2.setText(text)
		if self.config[sel.text()].has_key('web'):
			WebGui.openBrowser( str(self.config[sel.text()]['web']))
		say("done")
Esempio n. 9
0
 def testHtmlCase(self):
     bytestr=b'<b>Fran\xc3\xa7ais</b>'
     browser=WebGui.openBrowserWindow('Browser')
     browser.setHtml(bytestr.decode("utf8"), FreeCAD.getResourceDir())