Integrate Google Chrome browser into eclipse
Asked Answered
M

5

9

I am trying to create an application using SWT Browser. Is it possible to integrate Google Chrome as browser into Eclipse (not as external web browser)?

Mcmillon answered 13/6, 2012 at 9:42 Comment(3)
A blog talks about it but a proper roadmap for embedding it is still not quite clear to meSelfcommand
Isn't webkit already part of Eclipse, and that you can browse inside of eclipse...Valorize
webkit is not included on windows. You have to either install XULRunner to use with Firefox or the WebKit available with Safari. I've been unable to get this working with Chrome on windows. If you need help getting firefox or safari working on Windows - let me know, I've got those working - at least up to the latest supported versions in Eclipse Juno.Terpsichorean
R
7

No, as of current stable release of google chrome, you cannot use it inside SWT. The reason is that google chrome (and essentially chromium) doesn't support ActiveX (like IE, Firefox, Safari etc) but is based on NPAPI. (Note: I am considering that you are working on Windows machine as you haven't mentioned in your question !!)

But there are projects which are trying to make an embeddable version of chromium. See these links:

  1. Chromiumembedded
  2. Is Google Chrome embeddable?
Rationale answered 15/6, 2012 at 6:7 Comment(0)
A
2

You can set it through Eclipse UI.

Goto : Window > Preferences > General > Web Browser

Select "Use External Browser" radio button

Click "New" button to add a new browser eg. Chrome !

Click Apply + Ok

... and you have it working !

Ashtonashtonunderlyne answered 20/4, 2013 at 5:42 Comment(3)
but ofcourse i have not tried it for SWT projects, I was working for a web application.Ashtonashtonunderlyne
sorry guys - i later realized that this question was not for "external browsers" - my miss :( sorry again !Ashtonashtonunderlyne
I know your answer is a miss to the OPs requirements but I came across this searching and it is a hit for me.Paleoasiatic
I
2

Bug 405031 - [Browser] implement Chromium support

https://bugs.eclipse.org/bugs/show_bug.cgi?id=405031

Insightful answered 11/6, 2014 at 15:20 Comment(1)
This request lead to this project: github.com/maketechnology/chromium.swtAbility
K
0

If you can not make it through UI, Try to edit settings in the following file.

YOUR-WORKSPACE\.metadata\.plugins\org.eclipse.core.runtime\.settings
there will be a file called org.eclipse.ui.browser.prefs open it with any text editor and change the appropriate values, It is self descriptive you can easily find out what to change and all. Have a back up of the same before you modify.

Hope this helps you.

EDIT: Restart your eclipse to effect the above change.

Kelcie answered 13/6, 2012 at 9:50 Comment(2)
@Downvoter, Could you tell me the reason for downvote, so that I can improve my answers next time.Kelcie
You said change appropriate values but what are those? In my setting file I could only see 1) eclipse.preferences.version and 2) internalWebBrowserHistory. Please update your answer with correct values and I will take my down-vote back. Apart from that google-chrome doesn't support embedding.Rationale
S
0

To integrate Chromium into Eclipse or SWT applications you can use https://github.com/equoplatform/chromium-swt.

Sexagesima answered 8/9, 2022 at 22:38 Comment(1)
Your answer could be improved with additional supporting information. Please edit to add further details, such as citations or documentation, so that others can confirm that your answer is correct. You can find more information on how to write good answers in the help center.Endosperm

© 2022 - 2024 — McMap. All rights reserved.