• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

JEditorPane Problem ...

 
Ranch Hand
Posts: 35
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,
i am opening a html page via JEditorPane.
It is opening up.The page is not loaded clearly.
Is that Javscript is not supported in JEditorPane ???
I need to implement Help System in such a way that my Frame is focussed and if i press F1 , i need to open up a window/dialog where i am having JEditorPane to show up the Help HTML page.

Any other ideas to implement this functionality ???

Thanks
Manikandan
 
Ranch Hand
Posts: 196
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi
have you ever thought about JavaHelp API?
I had the same problem with JEditorPane and I think you are right, that it doesn't support JavaScript. Also displaying pure HTML is not perfect. Maybe it is a solution for you to open a real browser?
Bye
Rene
 
Bartender
Posts: 4121
IntelliJ IDE Spring Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
JEditorPane has a document that can render basic HTML. JavaScript is not HTML... if you need support for JavaScript, or any other web based technology that is not pure HTML, you'll have to either launch an actual browser, or use the JavaHelp API as Rene mentioned. (Though I am not sure of the status of the JavaHelp API... I haven't seen it used recently...)

-Nate
 
Manikandan Adaikkalavan
Ranch Hand
Posts: 35
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
hi Rene / Nate,
Thanks for your replies.
Actually before trying this JEditorPane,i already tried launching the HTML page in browser.I am able to open it.
But i have another problem in that....
Please see the Post titled "Always on Top Functionality" .URL given below...
https://coderanch.com/t/333723/GUI/java/Always-Top-Functionality
Thatz why i tried JEditorPane as an alternative.
As you suggested, i am going to look into JavaHelp API.
Thanks,
Manikandan
 
Rene Liebmann
Ranch Hand
Posts: 196
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Do you have to use Internet Explorer? I wrote an Java Application, where the customers can show documents with different applications (e.g. Word or Excel) I start those applications in the same way like you. The only difference is, that I start executables. They appear always on top.
So my question to you, can you use a different browser (Netscape, Mozilla, Opera ...). Those browsers are executables and I'm shure, they will be on top.
 
Manikandan Adaikkalavan
Ranch Hand
Posts: 35
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Rene,
It will open up the default browser in the machine.In my machine , the default browser is IE.
So it opens always in IE.So it depends on the default browser.
I need to make HTML Page to appear it infront of the Swing Application.But it always opens behind the application.
My machine is Win2000.
Is this feature in windows can't be changed throu' our swing application ?
Do you have any idea about how to solve this ?
Thanks,
Manikandan
 
Rene Liebmann
Ranch Hand
Posts: 196
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Sorry, but I think there is nothing I can do for you. Maybe you have to do a workaround. Ask the user in a JFileChooser for the right Browser to open the HTML page. Store this in a properties file. And then open it, reading the value from the properties file.
Yes this is ugly, but it will work in the way you want.
reply
    Bookmark Topic Watch Topic
  • New Topic