View Single Post
  #4  
Old 03-29-2013, 11:58 AM
farshizzo farshizzo is offline
WorldViz Team Member
 
Join Date: Mar 2003
Posts: 2,849
The embedded browser is based on the Windows native web browser control. It appears that the browser defaults to IE7 mode, and the web page you are trying to view is not compatible with IE7.

However, you can specify which version of IE to use for the embedded browser through a registry setting. The following sample code will force the embedded browser to use IE9 and then opens the sample page you previously mentioned.
Code:
import viz
viz.go()

import _winreg
reg = _winreg.OpenKey(_winreg.HKEY_CURRENT_USER, r'Software\Microsoft\Internet Explorer\Main\FeatureControl\FEATURE_BROWSER_EMULATION',0,_winreg.KEY_ALL_ACCESS)
_winreg.SetValueEx(reg,'VizHTMLViewer.exe',0,_winreg.REG_DWORD,9999)

viz.window.displayHTML('http://mbostock.github.com/d3/talk/20111116/iris-parallel.html')
The chart appears to render properly within the browser now.
Reply With Quote