#FEATURE by cg
authorClaus Gittinger <cg@exept.de>
Thu, 21 Jun 2018 18:40:23 +0200
changeset 6358 c260ba065216
parent 6357 471bd864f489
child 6359 7c4a24875876
#FEATURE by cg class: TextView added: #openWebBrowserOnIt
TextView.st
--- a/TextView.st	Thu Jun 21 13:41:28 2018 +0200
+++ b/TextView.st	Thu Jun 21 18:40:23 2018 +0200
@@ -1,3 +1,5 @@
+"{ Encoding: utf8 }"
+
 "
  COPYRIGHT (c) 1989 by Claus Gittinger
               All Rights Reserved
@@ -2718,6 +2720,17 @@
     "Modified: / 22-05-2018 / 18:24:22 / Claus Gittinger"
 !
 
+openWebBrowserOnIt
+    "open a webBrowser on the selected url"
+
+    |urlString|
+
+    urlString := self selectionAsString.
+    OperatingSystem openApplicationForDocument:urlString operation:#open mimeType:'text/html'.
+
+    "Created: / 21-06-2018 / 17:15:27 / Claus Gittinger"
+!
+
 openWorkspaceWithIt
     "open a workspace containing the selected text"