Constructors

Properties

basePath: string = '.'

Base path for all URLs in the core without trailing slash.

When using a relative path, the path is relative to the URL of the page that contains the assignment. Trailing slashes are automatically removed.

'.'
defaultLanguage: string = 'en'

Defines the default language which is used in the common resource files. Any resources for this language will only load the common resource file, but not the language-specific resource file.

'en'
imageBasePath: string = '.'

Base path for all images URLs in the core without trailing slash.

When using a relative path, the path is relative to the URL of the page that contains the assignment. Trailing slashes are automatically removed.

'.'
IS_ANDROID: boolean = ...

Returns true if the user agent contains Android.

IS_CHROMEAPP: boolean = ...

True if the this is running inside a Chrome App.

IS_CHROMEOS: boolean = ...

True if the client is a Chrome OS.

IS_EDGE: boolean = ...

True if the current browser is Microsoft Edge.

IS_FF: boolean = ...

True if the current browser is Firefox.

IS_GC: boolean = ...

True if the current browser is Google Chrome.

IS_IOS: boolean = ...

Returns true if the user agent is an iPad, iPhone or iPod.

IS_LOCAL: boolean = ...

True if the documents location does not start with http:// or https://.

IS_MAC: boolean = ...

True if the client is a Mac.

IS_MT: boolean = ...

True if -moz-transform is available as a CSS style. This is the case for all Firefox-based browsers newer than or equal 3, such as Camino, Iceweasel, Seamonkey and Iceape.

IS_NS: boolean = ...

True if the current browser is Netscape (including Firefox).

IS_POINTER: boolean = ...

True if this device supports Microsoft pointer events (always false on Macs).

IS_SF: boolean = ...

True if the current browser is Safari.

IS_SVG: boolean = ...

True if the browser supports SVG.

IS_TOUCH: boolean = ...

True if this device supports touchstart/-move/-end events (Apple iOS, Android, Chromebook and Chrome Browser on touch-enabled devices).

IS_WIN: boolean = ...

True if the client is a Windows.

language: string = ...

Defines the language of the client, eg. en for english, de for german etc. The special value none will disable all built-in internationalization and resource loading. See Resources#getSpecialBundle for handling identifiers with and without a dash.

If internationalization is disabled, then the following variables should be overridden to reflect the current language of the system. These variables are cleared when i18n is disabled. Editor.askZoomResource, Editor.lastSavedResource, Editor.currentFileResource, Editor.propertiesResource, Editor.tasksResource, Editor.helpResource, Editor.outlineResource, ElbowEdgeHandler#doubleClickOrientationResource, Utils#errorResource, Utils#closeResource, GraphSelectionModel#doneResource, GraphSelectionModel#updatingSelectionResource, GraphView#doneResource, GraphView#updatingDocumentResource, CellRenderer#collapseExpandResource, Graph#containsValidationErrorsResource and Graph#alreadyConnectedResource.

languages: null | string[] = null

Defines the optional array of all supported language extensions. The default language does not have to be part of this list. See Translations#isLanguageSupported.

This is used to avoid unnecessary requests to language files, ie. if a 404 will be returned.

null
NO_FO: boolean = ...

True if foreignObject support is not available. This is the case for Opera, older SVG-based browsers and all versions of IE.

VERSION: string = '0.13.0'

The version of the maxGraph library.

Methods

  • Returns true if the current browser is supported, that is, if <Client.IS_SVG> is true.

    Example:

    if (!Client.isBrowserSupported())
    {
    mxUtils.error('Browser is not supported!', 200, false);
    }

    Returns boolean

  • Parameters

    • value: string

    Returns void

  • Parameters

    • value: undefined | null | string

    Returns void

  • Parameters

    • value: string

    Returns void

  • Parameters

    • value: undefined | null | string

    Returns void

  • Parameters

    • value: undefined | null | string[]

    Returns void