skoch9 / meshplot

Plot 3D triangle meshes
GNU General Public License v3.0
148 stars 37 forks source link

Render type "OFFLINE" is not easily visualized #27

Open daviesthomas opened 3 years ago

daviesthomas commented 3 years ago

Heya.

Very useful library :)

The jupyter visualization is perfect, but I'm not a fan of using notebooks :). It would be convenient if the "OFFLINE" render mode opened a window rendering the HTML instead of just saving it to some local directory.

Has this functionality been explored or is this possible in lib today? Could default to open in the default browser or render in an "iframe" created by Tkinter. If this functionality is favoured I'd love to discuss here and I can help implement it if needed.

~ tom

daviesthomas commented 3 years ago

could use tkinter to open in a specific window.

from tkinterhtml import HtmlFrame
import tkinter as tk

root = tk.Tk()

frame = HtmlFrame(root, horizontal_scrollbar="auto")

frame.set_content("<html></html>")

or webbrowser to simply open in default browser (https://docs.python.org/2/library/webbrowser.html)