General XMetaL Discussion

XMetaL Community Forum General XMetaL Discussion Deal with the onclick event when using displaying SVG image

  • bk

    Deal with the onclick event when using displaying SVG image

    Participants 0
    Replies 1
    Last Activity 4 years, 9 months ago

    On XMetal Author Entreprise 12, when rendering SVG image in XMetal using the Shell.Explorer.2 ActiveX, we are unable to catch the “onClick” event (we want to do it to launch the SVG authoring program).

    My understanding is that the ActiveX doesn't forward the click event to Xmetal.

    Are there any ideas to catch this events ? (setting something in the activeX for instance)
    Are there any other way to display SVG image in Xmetal ?

    Thanks in advance for your answers.


    Derek Read

    Reply to: Deal with the onclick event when using displaying SVG image

    It would be the IE WebBrowser control (Shell.Explorer) that is not passing the message through in this case.

    I don't know how easy it would be to do this, but I think you would need to handle the click in an HTML page. That likely means opening an HTML page in IE (instead of opening the SVG in IE) then passing the file path for the SVG from XMetaL to the web page (instead of passing it to IE), and then having the HTML file load the SVG file (likely through script so that the path can be varied). Now that an HTML page is loaded you may have the ability to process an OnClick event in there, but that depends on how the SVG is being displayed by IE (natively or via another control) and whether it exposes the OnClick event when you click on an SVG image.

    There is no native support for rendering SVG in XMetaL Author, which is why the IE WebBrowser control (Shell.Explorer) is usually used. There are other ActiveX controls that render SVG but I believe any that are currently supported (by their maker) are commercial.

    Adobe used to make an ActiveX control and was providing it for free for use with Internet Explorer, but it was specifically designed for use with IE so it had some quirks that made it unusable in other software. They stopped supporting it long ago.


  • You must be logged in to reply to this topic.

Lost Your Password?