Chrome (actually Chromium) Inside SketchUp 2017


#1

This is a Wiki so that we can use groupthink to refine our understanding of the introduction of Chromium to SketchUp 2017. I’ll start, but I welcome people to change/correct/enhance what I’ve said below (should you have attained a sufficient trust level in this forum - which is everybody except a “New User”) so that we end up with good, accurate information!

Sketchup 2017 (Make, Pro, Mac, Windows) includes - as part of the installation - the Chromium Browser.[quote=“Tommy, post:1, topic:33349”]
Chromium Web Dialogs: SketchUp ships with a platform-independent web browser (called Chromium). This is a big benefit to extension developers: no more worrying which version of IE or Safari is installed on the computer.
[/quote]

It’s more accurate to say that SketchUp 2017 includes the “Chromium Embedded Framework”. It is installed for use by SketchUp and is not exposed as a standalone application or for use by other programs.

Various conversations in this forum have converged on what is likely the critical reason that Trimble did this: It will greatly reduce support issues from browser library differences! The Chromium Embedded Framework works across Mac and Windows, so Trimble and other developers no longer have to account for differences between the Mac and Windows forks of their code - or between different versions of IE and Safari in areas that rely on web access (or web-like access - such as html based pop up windows).

The benefits to us, the users of SketchUp, are (or will be) as follows:

  • We will no longer need to worry about keeping Internet Explorer (Windows) or Safari (Mac) up to date since SketchUp will no longer rely on the default browser installed with the OS or by the user
  • Developers (presumably those using both Ruby and C++) will no longer have to worry about which browser is used when they code. Hopefully, this will results in fewer extensions that work well in one OS, but poorly in the other.

But we aren’t there yet! Here’s a summary table of where Chromium is used in SketchUp, and where it’s not (yet) implemented:
<editor’s note: If you edit the table below, please be hyper-vigilant as to the alignment! The columns rely on spaces between them to line up - and the triple-tick feature forces a fixed space font!>

Use of Chromium in SketchUp, Feature by Feature
Feature                    Windows        Mac
3dWarehouse Window         SU2017         SU2017
Ext. Warehouse Window      SU2017         SU2017
SU SDK (aka C++ API)       ???            ???
Ruby API WebDialog         No             No
Ruby API HTMLDialogs       ???            ???
Add Location Tool          ???            ???
Trimble Connect Ext        ???            ???
Dynamic Components Ext     ???            ???
Generate Report            ???            ???

<editor’s note: If you edit the above table, please be hyper-vigilant as to the alignment! The columns rely on spaces between them to line up - and the triple-tick feature forces a fixed space font!>
(I may have missed some features, so feel free to add lines - and if you know, replace the "???"s!)

We, collectively, need to identify which of these areas still rely on the OS’s browser library and which have been “converted” to the Chromium Embedded Framework. And as they are updated, change the status appropriately.


#3

No, I can’t edit the Wiki (or don’t know how to)…

Yes, SketchUp embeds the Chromium library, it does not install the Chrome or Chromium browser. It also does not put the library anywhere that other programs can readily use it.

Aside from the Safari vs IE issues, there have also been numerous problems between versions of IE. There must be almost daily posts of issues that track down to the user having an obsolete/different version of IE! Once all of SU is converted to use Chromium, not just WebDialogs, a great many support issues will go away!

I don’t know what you mean about the SDK and Ruby API using “an html engine”? The SDK and Ruby API are programming interfaces, most of which has nothing whatever to do with the web or html.


#4

Take a look at my original post. Is there an edit icon (pencil) below it on the right? If so, that’s where you click to try editing it. I believe you can as your trust level as a Sage is higher than mine as a “Top Contributor”.


#5

I’m not sure I’ve used the correct terminology here. As a wiki, this is just a first draft and I’d love to have people who actually uses these parts (I don’t) to correct me. But as I understand it (and correct me if I’m wrong), it’s possible using Ruby (and C++) to create a web dialog - and it’s those parts that will no longer require developers to worry about the underlying OS.


#6

It was suppressed initially, hidden by a little … icon. When I clicked that, the pencil appeared and I can then edit the Wiki.


#7

I don’t program to the SDK myself so maybe an expert will correct me, but I don’t think it has any html/web components involved. It is intended for creating and editing SketchUp models and for reading and writing them to files from within your own application. It has no interactive aspects or GUI support and I don’t think it can create WebDialogs.

Within the Ruby API, the benefits will come only to code that creates HTMLDialogs for user interaction. WebDialogs are now deprecated though they will still work.

BTW. I will continue to add posts rather than editing the Wiki itself unless I am 100% certain I am right! No need to generate misinformation!


#8

@sjdorst, I tried an edit, but it failed…

it was to the topic title…

Chrome ‘inside’ Sketchup 2017 is more accurate when referring to the CEF which is now embedded inside SU…

“Trimble Connect” is the another shipped extension that now uses HtmlDialogs…

the ones that don’t are probably more important for now, as they continue to cause issues we see on the forum…

the DC extension is possibly the most notable so far that still uses IE/Safari…

john


#9

Editing the topic title is a separate title than wiki-editing of the content. If you have the authority (and you do), there should be a big pencil icon just to the right of the title - that’s what you use to edit the title.

I’ve gone ahead and edited the title to something suggested by your change. However, when I tried to save it, it threw a “500 server error”. On a hunch, I removed the single quotes and tried again to save it - successfully!


#10

Y’all can also just click the little green wiki icon at the top right of the wikipost, just to the left of the edit topic title pencil icon. (It is faster as you need not scroll all the way to the bottom of a long wiki.)


#11

Well tan my hide! I missed that one too. No experience with Wiki’s on Discourse.


#12

A couple of missing built-in features are the new Extension Manager and the Instructor panel.

Add Location still uses WebDialog (IE/Safari,) which is using Google Maps, not under Trimble control. This website has taken to displaying a browser version warning for IE less than 10. SU2017’s installer set “sketchup.exe” IE browser emulation to 11. (previously SU2014+ it was set at 9.) So, installing an older SketchUp version after installing SU2017, can cause this Google Maps error to resurface. (And of course installing a really old SketchUp version can set the emulation back further.)


#13

Dan,
I’d appreciate it if you add the Extension Manager and Instructor panel to the list in the original Wiki post. I could do it, but if you do it, it will show as your contribution (in the edit history) thus giving credit where credit is due!


#14

Add Location is a HtmlDialog on a mac, you can use ‘Show WebTools’ context menu from it…

john


#18

I’m trying to get chromium to show authentication prompt like the independent chromium browser (or chrome or alternatives): I’m authenticating to my proxy (http/s, squid proxy) to access internet but for some reason, the sketchup chromium browser doesn’t prompt anything and fails to authenticate to my proxy. Even when trying through developer console of the integrated browser, and specifying username:password@proxy.net:port, it fails to authenticate. What could be the reason ?? Because of this I can’t access 3D warehouse or services through sketchup as we cannot manually specify a proxy…


#19

Hello guys, I’ve came across this when trying to troubleshoot a problem I’m having with some html dialogs.

As you may or may not know, SketchUp runs pretty well in Linux (via WINE) except maybe a few plugins that use html or web dialogs. (IE does not work well in WINE) It’s mostly hit 'n miss with the more complicated ones.

With this solution I can see all my problems going away. What’s the update on this?


#20

Most of SketchUp’s own web page interfaces (e.g. 3D Warehouse and Extension Warehouse) use the embedded Chromium library, as do HtmlDialogs created by extensions. Older extensions that still use WebDialog will still route to the IE library (or Safari library on Mac).


#21

Which this solution? Does SketchUp have all dependencies it needs? winetricks vcrun2015 ie8, .NET Framework 4.5.2 And which extensions that use HTML dialogs?


#22

I’ve managed to run SketchUp 2018 without .Net 4.5.2 on wine-staging 3.13, though installing it doesn’t make any difference. ie8 does not install on a 64-bit prefix IIRC…

Some of the problematic plugins are Skatter; MSPhysics (opening and closing main UI produces a bugsplat if js ript is not set to disabled); ClothWorks (Licensing window shows html source code); Sketchucation plugin manager (can’t login, licensing window shows html source code)
Some plugins break when disabling jscript, some work.

I’m just speculating that if plugins were to use the built-in chromium thing, everything would be good as I haven’t experienced any problem with SketchUp’s own web dialogs.


#23

The Chromium-based or platform-based browser engine (HtmlDialog or WebDialog) is not something users can choose, only developers. They have almost an identical interface except the changed callback method and asynchronicity. Old extensions are often poorly written to access the callback method directly without wrapping it in a function (single place to patch). They would also fail since many rely on synchronous callbacks.

By the way, if properly designing the code and abstracting the dialog, a developer can use both browser engines interchangeably. But in practice that is mostly never done.


#24

My CabMaker extension allows users to choose HtmlDialog or Web Dialog. When written correctly they can both use the same callback. Personally I still prefer the old IE browser. There are only a couple of lines of code that are different.