diff --git a/.gitignore b/.gitignore index d3dd6ed5d..9319f27ea 100644 --- a/.gitignore +++ b/.gitignore @@ -1,14 +1,14 @@ .idea Thumbs.db .DS_Store -deploy +/deploy build/node_modules apps/documenteditor/embed/resources/less/node_modules apps/presentationeditor/embed/resources/less/node_modules apps/spreadsheeteditor/embed/resources/less/node_modules apps/documenteditor/mobile/resources/sass/.sass-cache apps/spreadsheeteditor/mobile/resources/sass/.sass-cache -apps/presentationeditor/mobile/resources/sass/.sass-cache +apps/presentationeditor/mobile/resources/sass/.sass-cache # test documents @@ -18,8 +18,8 @@ apps/presentationeditor/mobile/document apps/spreadsheeteditor/embed/offlinedocs apps/spreadsheeteditor/main/offlinedocs apps/spreadsheeteditor/mobile/offlinedocs - -# tests -selenium-debug.log -**/test/bin + +# tests +selenium-debug.log +**/test/bin **/test/reports \ No newline at end of file diff --git a/CHANGELOG.md b/CHANGELOG.md index 035682adf..ae762ae81 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,19 +1,20 @@ # Change log -## 5.1.1 +## 5.3 ### All Editors -* Customize initial zoom for the embedded editors -* Replace image from context menu (bug #11493) -* Customize availability of help in the editor +* Save to pdfa format +* Add rotation and flip to image and shape settings (bug #19378) +* Save file copy to selected folder (bug #23603, bug #32790) +* Load image from storage +* Add customization parameter 'hideRightMenu' for hiding right panel on first loading (bug #39096) +* Show comments in view mode ### Document Editor -* Create and manage bookmarks -* Create internal hyperlinks to bookmarks and headings -* Export to RTF format +* Search selected text +* Add blank page ### Spreadsheet Editor -* Add Spanish, French formula translations -* Set options for saving in PDF format (bug #34914) -* Change cell format from context menu (bug #16272) +* Set print area ### Presentation Editor -* Add hints to presentation themes (bug #21362) +* Enter the slide number manually for internal hyperlinks +* Add ability to search and replace text \ No newline at end of file diff --git a/apps/api/documents/api.js b/apps/api/documents/api.js index fc8078b13..ed34a79cb 100644 --- a/apps/api/documents/api.js +++ b/apps/api/documents/api.js @@ -23,9 +23,11 @@ key: 'key', vkey: 'vkey', info: { - author: 'author name', + author: 'author name', // must be deprecated, use owner instead + owner: 'owner name', folder: 'path to document', - created: '', + created: '', // must be deprecated, use uploaded instead + uploaded: '', sharingSettings: [ { user: 'user name', @@ -46,6 +48,7 @@ comment: // default = edit, modifyFilter: // default = true modifyContentControl: // default = true + fillForms: // default = edit || review } }, editorConfig: { @@ -56,11 +59,13 @@ canBackToFolder: - deprecated. use "customization.goback" parameter, createUrl: 'create document url', sharingSettingsUrl: 'document sharing settings url', - fileChoiceUrl: 'mail merge sources url', + fileChoiceUrl: 'source url', // for mail merge or image from storage callbackUrl: , - mergeFolderUrl: 'folder for saving merged file', + mergeFolderUrl: 'folder for saving merged file', // must be deprecated, use saveAsUrl instead + saveAsUrl: 'folder for saving files' licenseUrl: , customerId: , + region: // can be 'en-us' or lang code user: { id: 'user id', @@ -88,8 +93,6 @@ imageEmbedded: url, url: http://... }, - backgroundColor: 'header background color', - textColor: 'header text color', customer: { name: 'SuperPuper', address: 'New-York, 125f-25', @@ -114,18 +117,22 @@ compactToolbar: false, leftMenu: true, rightMenu: true, + hideRightMenu: false, // hide or show right panel on first loading toolbar: true, - header: true, statusBar: true, autosave: true, forcesave: false, commentAuthorOnly: false, showReviewChanges: false, - help: true + help: true, + compactHeader: false, + toolbarNoTabs: false, + toolbarHideFileName: false, + reviewDisplay: 'original', + spellcheck: true }, plugins: { autostart: ['asc.{FFE1F462-1EA2-4391-990D-4CC84940B754}'], - url: '../../../../sdkjs-plugins/', pluginsData: [ "helloworld/config.json", "chess/config.json", @@ -135,7 +142,6 @@ } }, events: { - 'onReady': , // deprecated 'onAppReady': , 'onBack': , 'onDocumentStateChange': @@ -170,7 +176,6 @@ } }, events: { - 'onReady': , // deprecated 'onAppReady': , 'onBack': , 'onError': , @@ -194,11 +199,15 @@ _config.editorConfig.canRequestEditRights = _config.events && !!_config.events.onRequestEditRights; _config.editorConfig.canRequestClose = _config.events && !!_config.events.onRequestClose; _config.editorConfig.canRename = _config.events && !!_config.events.onRequestRename; + _config.editorConfig.canMakeActionLink = _config.events && !!_config.events.onMakeActionLink; + _config.editorConfig.canRequestUsers = _config.events && !!_config.events.onRequestUsers; + _config.editorConfig.canRequestSendNotify = _config.events && !!_config.events.onRequestSendNotify; + _config.editorConfig.mergeFolderUrl = _config.editorConfig.mergeFolderUrl || _config.editorConfig.saveAsUrl; + _config.editorConfig.canRequestSaveAs = _config.events && !!_config.events.onRequestSaveAs; + _config.editorConfig.canRequestInsertImage = _config.events && !!_config.events.onRequestInsertImage; + _config.editorConfig.canRequestMailMergeRecipients = _config.events && !!_config.events.onRequestMailMergeRecipients; _config.frameEditorId = placeholderId; - _config.events && !!_config.events.onReady && console.log("Obsolete: The onReady event is deprecated. Please use onAppReady instead."); - _config.events && (_config.events.onAppReady = _config.events.onAppReady || _config.events.onReady); - var onMouseUp = function (evt) { _processMouse(evt); }; @@ -368,6 +377,7 @@ // _config.editorConfig.canBackToFolder = false; if (!_config.editorConfig.customization) _config.editorConfig.customization = {}; _config.editorConfig.customization.about = false; + _config.editorConfig.customization.compactHeader = false; if ( window.AscDesktopEditor ) window.AscDesktopEditor.execCommand('webapps:events', 'loading'); } @@ -504,6 +514,15 @@ }); }; + var _setActionLink = function (data) { + _sendCommand({ + command: 'setActionLink', + data: { + url: data + } + }); + }; + var _processMailMerge = function(enabled, message) { _sendCommand({ command: 'processMailMerge', @@ -521,6 +540,41 @@ }); }; + var _setUsers = function(data) { + _sendCommand({ + command: 'setUsers', + data: data + }); + }; + + var _showSharingSettings = function(data) { + _sendCommand({ + command: 'showSharingSettings', + data: data + }); + }; + + var _setSharingSettings = function(data) { + _sendCommand({ + command: 'setSharingSettings', + data: data + }); + }; + + var _insertImage = function(data) { + _sendCommand({ + command: 'insertImage', + data: data + }); + }; + + var _setMailMergeRecipients = function(data) { + _sendCommand({ + command: 'setMailMergeRecipients', + data: data + }); + }; + var _processMouse = function(evt) { var r = iframe.getBoundingClientRect(); var data = { @@ -554,12 +608,18 @@ refreshHistory : _refreshHistory, setHistoryData : _setHistoryData, setEmailAddresses : _setEmailAddresses, + setActionLink : _setActionLink, processMailMerge : _processMailMerge, downloadAs : _downloadAs, serviceCommand : _serviceCommand, attachMouseEvents : _attachMouseEvents, detachMouseEvents : _detachMouseEvents, - destroyEditor : _destroyEditor + destroyEditor : _destroyEditor, + setUsers : _setUsers, + showSharingSettings : _showSharingSettings, + setSharingSettings : _setSharingSettings, + insertImage : _insertImage, + setMailMergeRecipients: _setMailMergeRecipients } }; @@ -662,7 +722,7 @@ app = appMap[config.documentType.toLowerCase()]; } else if (!!config.document && typeof config.document.fileType === 'string') { - var type = /^(?:(xls|xlsx|ods|csv|xlst|xlsy|gsheet|xlsm|xlt|xltm|xltx|fods)|(pps|ppsx|ppt|pptx|odp|pptt|ppty|gslides|pot|potm|potx|ppsm|pptm|fodp))$/ + var type = /^(?:(xls|xlsx|ods|csv|xlst|xlsy|gsheet|xlsm|xlt|xltm|xltx|fods|ots)|(pps|ppsx|ppt|pptx|odp|pptt|ppty|gslides|pot|potm|potx|ppsm|pptm|fodp|otp))$/ .exec(config.document.fileType); if (type) { if (typeof type[1] === 'string') app = appMap['spreadsheet']; else @@ -676,8 +736,16 @@ : config.type === "embedded" ? "embed" : "main"; - path += "/index.html"; + var index = "/index.html"; + if (config.editorConfig) { + var customization = config.editorConfig.customization; + if ( typeof(customization) == 'object' && ( customization.toolbarNoTabs || + (config.editorConfig.targetApp!=='desktop') && (customization.loaderName || customization.loaderLogo))) { + index = "/index_loader.html"; + } + } + path += index; return path; } @@ -694,6 +762,11 @@ params += "&customer=ONLYOFFICE"; if ( (typeof(config.editorConfig.customization) == 'object') && config.editorConfig.customization.loaderLogo) { if (config.editorConfig.customization.loaderLogo !== '') params += "&logo=" + config.editorConfig.customization.loaderLogo; + } else if ( (typeof(config.editorConfig.customization) == 'object') && config.editorConfig.customization.logo) { + if (config.type=='embedded' && config.editorConfig.customization.logo.imageEmbedded) + params += "&headerlogo=" + config.editorConfig.customization.logo.imageEmbedded; + else if (config.type!='embedded' && config.editorConfig.customization.logo.image) + params += "&headerlogo=" + config.editorConfig.customization.logo.image; } } @@ -715,6 +788,13 @@ iframe.allowFullscreen = true; iframe.setAttribute("allowfullscreen",""); // for IE11 iframe.setAttribute("onmousewheel",""); // for Safari on Mac + + if (config.type == "mobile") + { + iframe.style.position = "fixed"; + iframe.style.overflow = "hidden"; + document.body.style.overscrollBehaviorY = "contain"; + } return iframe; } diff --git a/apps/api/documents/index.html b/apps/api/documents/index.html deleted file mode 100644 index 82fbc7009..000000000 --- a/apps/api/documents/index.html +++ /dev/null @@ -1,346 +0,0 @@ - - - - ONLYOFFICE Documents - - - - - - - - - - - - -
-
-
- - - - - diff --git a/apps/api/documents/index.html.desktop b/apps/api/documents/index.html.desktop index 28857deae..8f6aea8a6 100644 --- a/apps/api/documents/index.html.desktop +++ b/apps/api/documents/index.html.desktop @@ -58,6 +58,7 @@ editorConfig: cfg, events: { onInternalMessage: onInternalMessage, + onRequestClose: e => {return 0;} } }); @@ -100,7 +101,7 @@ mode : urlParams["mode"] || 'edit', lang : urlParams["lang"] || 'en', user: { - id: urlParams["userid"] || 'uid-901', name: urlParams["username"] || 'Chuk.Gek' + id: urlParams["userid"] || urlParams["username"] || 'uid-901', name: urlParams["username"] || 'Chuk.Gek' } }; } diff --git a/apps/common/Analytics.js b/apps/common/Analytics.js index 37a59ab6d..f2985be6c 100644 --- a/apps/common/Analytics.js +++ b/apps/common/Analytics.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under diff --git a/apps/common/Gateway.js b/apps/common/Gateway.js index 7d173d612..b8e90ebad 100644 --- a/apps/common/Gateway.js +++ b/apps/common/Gateway.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -76,6 +76,10 @@ if (Common === undefined) { $me.trigger('setemailaddresses', data); }, + 'setActionLink': function (data) { + $me.trigger('setactionlink', data.url); + }, + 'processMailMerge': function(data) { $me.trigger('processmailmerge', data); }, @@ -94,6 +98,26 @@ if (Common === undefined) { 'resetFocus': function(data) { $me.trigger('resetfocus', data); + }, + + 'setUsers': function(data) { + $me.trigger('setusers', data); + }, + + 'showSharingSettings': function(data) { + $me.trigger('showsharingsettings', data); + }, + + 'setSharingSettings': function(data) { + $me.trigger('setsharingsettings', data); + }, + + 'insertImage': function(data) { + $me.trigger('insertimage', data); + }, + + 'setMailMergeRecipients': function(data) { + $me.trigger('setmailmergerecipients', data); } }; @@ -234,6 +258,16 @@ if (Common === undefined) { }); }, + requestSaveAs: function(url, title) { + _postMessage({ + event: 'onRequestSaveAs', + data: { + url: url, + title: title + } + }); + }, + collaborativeChanges: function() { _postMessage({event: 'onCollaborativeChanges'}); }, @@ -254,6 +288,26 @@ if (Common === undefined) { _postMessage({event: 'onRequestClose'}); }, + requestMakeActionLink: function (config) { + _postMessage({event:'onMakeActionLink', data: config}) + }, + + requestUsers: function () { + _postMessage({event:'onRequestUsers'}) + }, + + requestSendNotify: function (emails) { + _postMessage({event:'onRequestSendNotify', data: emails}) + }, + + requestInsertImage: function () { + _postMessage({event:'onRequestInsertImage'}) + }, + + requestMailMergeRecipients: function () { + _postMessage({event:'onRequestMailMergeRecipients'}) + }, + on: function(event, handler){ var localHandler = function(event, data){ handler.call(me, data) diff --git a/apps/common/IrregularStack.js b/apps/common/IrregularStack.js index 7a9aa5170..4092f0358 100644 --- a/apps/common/IrregularStack.js +++ b/apps/common/IrregularStack.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under diff --git a/apps/common/embed/lib/controller/modals.js b/apps/common/embed/lib/controller/modals.js index bdf8ac2d1..82de2063c 100644 --- a/apps/common/embed/lib/controller/modals.js +++ b/apps/common/embed/lib/controller/modals.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under diff --git a/apps/common/embed/lib/util/utils.js b/apps/common/embed/lib/util/utils.js index 5a4b5db1f..0ad2ed91e 100644 --- a/apps/common/embed/lib/util/utils.js +++ b/apps/common/embed/lib/util/utils.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -44,7 +44,7 @@ newDocumentPage.focus(); } } - , dialogPrint: function(url) { + , dialogPrint: function(url, api) { $('#id-print-frame').remove(); if ( !!url ) { @@ -59,10 +59,14 @@ document.body.appendChild(iframePrint); iframePrint.onload = function () { - iframePrint.contentWindow.focus(); - iframePrint.contentWindow.print(); - iframePrint.contentWindow.blur(); - window.focus(); + try { + iframePrint.contentWindow.focus(); + iframePrint.contentWindow.print(); + iframePrint.contentWindow.blur(); + window.focus(); + } catch (e) { + api.asc_DownloadAs(new Asc.asc_CDownloadOptions(Asc.c_oAscFileType.PDF)); + } }; iframePrint.src = url; diff --git a/apps/common/embed/lib/view/modals.js b/apps/common/embed/lib/view/modals.js index 32b1be5d3..030a8f4bc 100644 --- a/apps/common/embed/lib/view/modals.js +++ b/apps/common/embed/lib/view/modals.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -61,10 +61,10 @@ common.view.modals = new(function() { ''; var _tplbody_embed = '
' + - 'Width:' + + '{width}:' + '' + '' + - 'Height:' + + '{height}:' + '
' + ''; @@ -75,22 +75,29 @@ common.view.modals = new(function() { var _$dlg; if (name == 'share') { _$dlg = $(tplDialog - .replace(/\{title}/, 'Share Link') + .replace(/\{title}/, this.txtShare) .replace(/\{body}/, _tplbody_share) - .replace(/\{footer}/, '')) + .replace(/\{footer}/, '')) .appendTo(parent) .attr('id', 'dlg-share'); } else if (name == 'embed') { _$dlg = $(tplDialog - .replace(/\{title}/, 'Embed') + .replace(/\{title}/, this.txtEmbed) .replace(/\{body}/, _tplbody_embed) - .replace(/\{footer}/, '')) + .replace(/\{width}/, this.txtWidth) + .replace(/\{height}/, this.txtHeight) + .replace(/\{footer}/, '')) .appendTo(parent) .attr('id', 'dlg-embed'); } return _$dlg; - } + }, + txtWidth: 'Width', + txtHeight: 'Height', + txtShare: 'Share Link', + txtCopy: 'Copy to clipboard', + txtEmbed: 'Embed' }; })(); diff --git a/apps/common/embed/resources/less/common.less b/apps/common/embed/resources/less/common.less index d19c6bde5..3a12327a6 100644 --- a/apps/common/embed/resources/less/common.less +++ b/apps/common/embed/resources/less/common.less @@ -187,6 +187,7 @@ .close { font-size: 28px; + font-family: Arial, sans-serif; color: #666666; opacity: 0.8; display: block; diff --git a/apps/common/locale.js b/apps/common/locale.js index b84aa0c37..9cf5cbf96 100644 --- a/apps/common/locale.js +++ b/apps/common/locale.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -35,46 +35,35 @@ if (Common === undefined) { } Common.Locale = new(function() { - var l10n = {}; + "use strict"; + var l10n = null; + var loadcallback, + apply = false; - var _createXMLHTTPObject = function() { - var xmlhttp; + var _applyLocalization = function(callback) { try { - xmlhttp = new ActiveXObject("Msxml2.XMLHTTP"); - } - catch (e) { - try { - xmlhttp = new ActiveXObject("Microsoft.XMLHTTP"); - } - catch (E) { - xmlhttp = false; - } - } - if (!xmlhttp && typeof XMLHttpRequest != 'undefined') { - xmlhttp = new XMLHttpRequest(); - } - return xmlhttp; - }; + callback && (loadcallback = callback); + if (l10n) { + for (var prop in l10n) { + var p = prop.split('.'); + if (p && p.length > 2) { - var _applyLocalization = function() { - try { - for (var prop in l10n) { - var p = prop.split('.'); - if (p && p.length > 2) { - - var obj = window; - for (var i = 0; i < p.length - 1; ++i) { - if (obj[p[i]] === undefined) { - obj[p[i]] = new Object(); + var obj = window; + for (var i = 0; i < p.length - 1; ++i) { + if (obj[p[i]] === undefined) { + obj[p[i]] = new Object(); + } + obj = obj[p[i]]; } - obj = obj[p[i]]; - } - if (obj) { - obj[p[p.length - 1]] = l10n[prop]; + if (obj) { + obj[p[p.length - 1]] = l10n[prop]; + } } } - } + loadcallback && loadcallback(); + } else + apply = true; } catch (e) { } @@ -82,7 +71,7 @@ Common.Locale = new(function() { var _get = function(prop, scope) { var res = ''; - if (scope && scope.name) { + if (l10n && scope && scope.name) { res = l10n[scope.name + '.' + prop]; } @@ -96,25 +85,48 @@ Common.Locale = new(function() { return results == null ? "" : decodeURIComponent(results[1].replace(/\+/g, " ")); }; - try { - var langParam = _getUrlParameterByName('lang'); - var xhrObj = _createXMLHTTPObject(); - if (xhrObj && langParam) { - var lang = langParam.split(/[\-\_]/)[0]; - xhrObj.open('GET', 'locale/' + lang + '.json', false); - xhrObj.send(''); - l10n = eval("(" + xhrObj.responseText + ")"); - } - } - catch (e) { - try { - xhrObj.open('GET', 'locale/en.json', false); - xhrObj.send(''); - l10n = eval("(" + xhrObj.responseText + ")"); - } - catch (e) { - } - } + var _requireLang = function () { + var lang = (_getUrlParameterByName('lang') || 'en').split(/[\-_]/)[0]; + fetch('locale/' + lang + '.json') + .then(function(response) { + if (!response.ok) { + if (lang != 'en') + /* load default lang if fetch failed */ + return fetch('locale/en.json'); + + throw new Error('server error'); + } + return response.json(); + }).then(function(response) { + if ( response.then ) + return response.json(); + else { + l10n = response; + /* to break promises chain */ + throw new Error('loaded'); + } + }).then(function(json) { + l10n = json || {}; + apply && _applyLocalization(); + }).catch(function(e) { + l10n = l10n || {}; + apply && _applyLocalization(); + if ( e.message == 'loaded' ) { + } else + console.log('fetch error: ' + e); + }); + }; + + if ( !window.fetch ) { + /* use fetch polifill if native method isn't supported */ + var polyfills = ['../vendor/fetch/fetch.umd']; + if ( !window.Promise ) { + require(['../vendor/es6-promise/es6-promise.auto.min'], + function () { + require(polyfills, _requireLang); + }); + } else require(polyfills, _requireLang); + } else _requireLang(); return { apply: _applyLocalization, diff --git a/apps/common/main/lib/collection/ChatMessages.js b/apps/common/main/lib/collection/ChatMessages.js index afedde6fb..a8f0ae676 100644 --- a/apps/common/main/lib/collection/ChatMessages.js +++ b/apps/common/main/lib/collection/ChatMessages.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under diff --git a/apps/common/main/lib/collection/Comments.js b/apps/common/main/lib/collection/Comments.js index 1c9fdb4b1..892192457 100644 --- a/apps/common/main/lib/collection/Comments.js +++ b/apps/common/main/lib/collection/Comments.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -52,6 +52,7 @@ define([ Common.Collections.Comments = Backbone.Collection.extend({ model: Common.Models.Comment, + groups: null, clearEditing: function () { this.each(function(comment) { diff --git a/apps/common/main/lib/collection/Fonts.js b/apps/common/main/lib/collection/Fonts.js index de2ddfe9c..8058dc271 100644 --- a/apps/common/main/lib/collection/Fonts.js +++ b/apps/common/main/lib/collection/Fonts.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under diff --git a/apps/common/main/lib/collection/HistoryVersions.js b/apps/common/main/lib/collection/HistoryVersions.js index 00c929c7f..06ac75267 100644 --- a/apps/common/main/lib/collection/HistoryVersions.js +++ b/apps/common/main/lib/collection/HistoryVersions.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under diff --git a/apps/common/main/lib/collection/Plugins.js b/apps/common/main/lib/collection/Plugins.js index 16f491e64..d8d6706cc 100644 --- a/apps/common/main/lib/collection/Plugins.js +++ b/apps/common/main/lib/collection/Plugins.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -49,6 +49,10 @@ define([ 'use strict'; Common.Collections.Plugins = Backbone.Collection.extend({ - model: Common.Models.Plugin + model: Common.Models.Plugin, + + hasVisible: function() { + return !!this.findWhere({visible: true}); + } }); }); diff --git a/apps/common/main/lib/collection/ReviewChanges.js b/apps/common/main/lib/collection/ReviewChanges.js index 9f23da3bd..b45a04cfa 100644 --- a/apps/common/main/lib/collection/ReviewChanges.js +++ b/apps/common/main/lib/collection/ReviewChanges.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under diff --git a/apps/common/main/lib/collection/TextArt.js b/apps/common/main/lib/collection/TextArt.js index 16d19784e..75d361af2 100644 --- a/apps/common/main/lib/collection/TextArt.js +++ b/apps/common/main/lib/collection/TextArt.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under diff --git a/apps/common/main/lib/collection/Users.js b/apps/common/main/lib/collection/Users.js index e3fa41a23..790d87e21 100644 --- a/apps/common/main/lib/collection/Users.js +++ b/apps/common/main/lib/collection/Users.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under diff --git a/apps/common/main/lib/component/BaseView.js b/apps/common/main/lib/component/BaseView.js index 853631472..bab307eab 100644 --- a/apps/common/main/lib/component/BaseView.js +++ b/apps/common/main/lib/component/BaseView.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under diff --git a/apps/common/main/lib/component/Button.js b/apps/common/main/lib/component/Button.js index e65f213fd..687fb3c23 100644 --- a/apps/common/main/lib/component/Button.js +++ b/apps/common/main/lib/component/Button.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -132,7 +132,8 @@ define([ }; ButtonsArray.prototype.setDisabled = function(disable) { - if ( _disabled != disable ) { + // if ( _disabled != disable ) //bug when disable buttons outside the group + { _disabled = disable; this.forEach( function(button) { @@ -319,7 +320,7 @@ define([ me.trigger('render:before', me); - me.cmpEl = $(me.el); + me.cmpEl = me.$el || $(me.el); if (parentEl) { me.setElement(parentEl, false); @@ -386,6 +387,18 @@ define([ if (modalParents.length > 0) { me.btnEl.data('bs.tooltip').tip().css('z-index', parseInt(modalParents.css('z-index')) + 10); me.btnMenuEl && me.btnMenuEl.data('bs.tooltip').tip().css('z-index', parseInt(modalParents.css('z-index')) + 10); + var onModalClose = function(dlg) { + if (modalParents[0] !== dlg.$window[0]) return; + var tip = me.btnEl.data('bs.tooltip'); + if (tip) { + if (tip.dontShow===undefined) + tip.dontShow = true; + + tip.hide(); + } + Common.NotificationCenter.off({'modal:close': onModalClose}); + }; + Common.NotificationCenter.on({'modal:close': onModalClose}); } } @@ -491,6 +504,7 @@ define([ if (isSplit) { $('[data-toggle^=dropdown]', el).on('mousedown', _.bind(menuHandler, this)); $('button', el).on('mousedown', _.bind(onMouseDown, this)); + (me.options.width>0) && $('button:first', el).css('width', me.options.width - $('[data-toggle^=dropdown]', el).outerWidth()); } el.on('hide.bs.dropdown', _.bind(doSplitSelect, me, false, 'arrow')); @@ -512,8 +526,8 @@ define([ }); el.on('mouseout', function(e) { + me.cmpEl.removeClass('over'); if (!me.disabled) { - me.cmpEl.removeClass('over'); me.trigger('mouseout', me, e); } }); @@ -601,6 +615,9 @@ define([ } } + if (disabled && this.menu && _.isObject(this.menu) && this.menu.rendered && this.menu.isVisible()) + setTimeout(function(){ me.menu.hide()}, 1); + if ( !!me.options.signals ) { var opts = me.options.signals; if ( !(opts.indexOf('disabled') < 0) ) { diff --git a/apps/common/main/lib/component/CheckBox.js b/apps/common/main/lib/component/CheckBox.js index 2e3849ac0..0d3d35c75 100644 --- a/apps/common/main/lib/component/CheckBox.js +++ b/apps/common/main/lib/component/CheckBox.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -104,27 +104,25 @@ define([ }, render: function (parentEl) { - var me = this, - el = $(this.el); + var me = this; if (!me.rendered) { if (parentEl) { this.setElement(parentEl, false); parentEl.html(this.template({ labelText: this.options.labelText })); - el = $(this.el); } else { - el.html(this.template({ + me.$el.html(this.template({ labelText: this.options.labelText })); } - this.$chk = el.find('input[type=button]'); - this.$label = el.find('label'); - this.$chk.on('click', _.bind(this.onItemCheck, this)); - } + this.$chk = me.$el.find('input[type=button]'); + this.$label = me.$el.find('label'); + this.$chk.on('click', this.onItemCheck.bind(this)); - this.rendered = true; + this.rendered = true; + } if (this.options.disabled) this.setDisabled(this.options.disabled); @@ -137,6 +135,9 @@ define([ }, setDisabled: function(disabled) { + if (!this.rendered) + return; + disabled = (disabled===true); if (disabled !== this.disabled) { this.$label.toggleClass('disabled', disabled); diff --git a/apps/common/main/lib/component/ColorButton.js b/apps/common/main/lib/component/ColorButton.js index d9d16c840..da3e9cb64 100644 --- a/apps/common/main/lib/component/ColorButton.js +++ b/apps/common/main/lib/component/ColorButton.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under diff --git a/apps/common/main/lib/component/ColorPalette.js b/apps/common/main/lib/component/ColorPalette.js index 1c513290a..ba35ca857 100644 --- a/apps/common/main/lib/component/ColorPalette.js +++ b/apps/common/main/lib/component/ColorPalette.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -91,16 +91,14 @@ define([ this.setElement(parentEl, false); parentEl.html(this.cmpEl); } else { - $(this.el).html(this.cmpEl); + me.$el.html(this.cmpEl); } } else { - this.cmpEl = $(this.el); + this.cmpEl = me.$el || $(this.el); } if (!me.rendered) { - var el = this.cmpEl; - - el.on('click', 'span.color-item', _.bind(this.itemClick, this)); + me.cmpEl.on('click', 'span.color-item', me.itemClick.bind(me)); } me.rendered = true; diff --git a/apps/common/main/lib/component/ColorPaletteExt.js b/apps/common/main/lib/component/ColorPaletteExt.js index d8ad4bbaf..a6b7e9c9a 100644 --- a/apps/common/main/lib/component/ColorPaletteExt.js +++ b/apps/common/main/lib/component/ColorPaletteExt.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -108,12 +108,12 @@ define([ this.setElement(parentEl, false); parentEl.html(this.cmpEl); } else { - $(this.el).html(this.cmpEl); + this.$el.html(this.cmpEl); } - this.cmpEl.on('click', _.bind(this.handleClick, this)); + this.cmpEl.on('click', me.handleClick.bind(me)); } else { - this.cmpEl = $(this.el); + this.cmpEl = me.$el || $(this.el); } me.rendered = true; diff --git a/apps/common/main/lib/component/ComboBorderSize.js b/apps/common/main/lib/component/ComboBorderSize.js index e106b2f4e..a22123a92 100644 --- a/apps/common/main/lib/component/ComboBorderSize.js +++ b/apps/common/main/lib/component/ComboBorderSize.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -77,7 +77,7 @@ define([ Common.UI.ComboBorderSize = Common.UI.ComboBox.extend(_.extend({ template: _.template([ '
', - '
', + '
', '
', '', '
' ].join('')), @@ -298,8 +298,7 @@ define([ initialize : function(options) { Common.UI.BaseView.prototype.initialize.call(this, options); - var me = this, - el = $(this.el); + var me = this; me.width = me.options.width; me.minValue = me.options.minValue; @@ -317,17 +316,18 @@ define([ if (!me.rendered) { this.cmpEl = $(this.template({ - items: this.options.values + items: this.options.values, + thumbTemplate: this.options.thumbTemplate })); if (parentEl) { this.setElement(parentEl, false); parentEl.html(this.cmpEl); } else { - $(this.el).html(this.cmpEl); + this.$el.html(this.cmpEl); } } else { - this.cmpEl = $(this.el); + this.cmpEl = this.$el; } var el = this.cmpEl; @@ -353,8 +353,8 @@ define([ if (need_sort) me.sortThumbs(); - $(document).off('mouseup', onMouseUp); - $(document).off('mousemove', onMouseMove); + $(document).off('mouseup', me.binding.onMouseUp); + $(document).off('mousemove', me.binding.onMouseMove); me._dragstart = undefined; me.trigger('changecomplete', me, value, lastValue); @@ -399,8 +399,8 @@ define([ (index == idx) ? item.thumb.css('z-index', 500) : item.thumb.css('z-index', ''); }); - $(document).on('mouseup', null, e.data, onMouseUp); - $(document).on('mousemove', null, e.data, onMouseMove); + $(document).on('mouseup', null, e.data, me.binding.onMouseUp); + $(document).on('mousemove', null, e.data, me.binding.onMouseMove); }; var onTrackMouseDown = function (e) { @@ -443,6 +443,12 @@ define([ return index; }; + this.binding = { + onMouseUp: _.bind(onMouseUp, this), + onMouseMove: _.bind(onMouseMove, this), + onMouseDown: _.bind(onMouseDown, this) + }; + this.$thumbs = el.find('.thumb'); _.each(this.$thumbs, function(item, index) { var thumb = $(item); @@ -451,7 +457,7 @@ define([ index: index }); me.setValue(index, me.options.values[index]); - thumb.on('mousedown', null, me.thumbs[index], onMouseDown); + thumb.on('mousedown', null, me.thumbs[index], me.binding.onMouseDown); }); me.setActiveThumb(0, true); @@ -481,7 +487,6 @@ define([ this.setThumbPosition(index, Math.round((value-this.minValue)*this.delta)); }, - getValue: function(index) { return this.thumbs[index].value; }, @@ -511,6 +516,35 @@ define([ thumb.index = index; }); return recalc_indexes; + }, + + setThumbs: function(count) { + var length = this.thumbs.length; + if (length==count) return; + + for (var i=0; i0) && this.setValue(index, this.getValue(index-1)); + thumb.on('mousedown', null, this.thumbs[index], this.binding.onMouseDown); + }, + + removeThumb: function(index) { + if (index===undefined) index = this.thumbs.length-1; + if (index>0) { + this.thumbs[index].thumb.remove(); + this.thumbs.splice(index, 1); + } } }); }); diff --git a/apps/common/main/lib/component/Switcher.js b/apps/common/main/lib/component/Switcher.js index db2c2ad2b..a474e40ae 100644 --- a/apps/common/main/lib/component/Switcher.js +++ b/apps/common/main/lib/component/Switcher.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -65,8 +65,7 @@ define([ initialize : function(options) { Common.UI.BaseView.prototype.initialize.call(this, options); - var me = this, - el = $(this.el); + var me = this; me.width = me.options.width; me.thumbWidth = me.options.thumbWidth; @@ -89,10 +88,10 @@ define([ this.setElement(parentEl, false); parentEl.html(this.cmpEl); } else { - $(this.el).html(this.cmpEl); + this.$el.html(this.cmpEl); } } else { - this.cmpEl = $(this.el); + this.cmpEl = this.$el; } this.thumb = this.cmpEl.find('.thumb'); diff --git a/apps/common/main/lib/component/SynchronizeTip.js b/apps/common/main/lib/component/SynchronizeTip.js index d3cce7eaf..57a203492 100644 --- a/apps/common/main/lib/component/SynchronizeTip.js +++ b/apps/common/main/lib/component/SynchronizeTip.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under diff --git a/apps/common/main/lib/component/Tab.js b/apps/common/main/lib/component/Tab.js index 15ac4a025..29e93b32c 100644 --- a/apps/common/main/lib/component/Tab.js +++ b/apps/common/main/lib/component/Tab.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under diff --git a/apps/common/main/lib/component/TabBar.js b/apps/common/main/lib/component/TabBar.js index c52f7f446..0c6868add 100644 --- a/apps/common/main/lib/component/TabBar.js +++ b/apps/common/main/lib/component/TabBar.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -206,6 +206,7 @@ define([ function dragComplete() { if (!_.isUndefined(me.drag)) { + me.drag.tab.removeClass('dragged'); me.drag.tab.$el.css('z-index', ''); me.bar.dragging = false; var tab = null; @@ -250,6 +251,8 @@ define([ } if (!_.isUndefined(bar) && !_.isUndefined(tab) && bar.tabs.length > 1) { + tab.addClass('dragged'); + var index = bar.tabs.indexOf(tab), _clientX = e.clientX*Common.Utils.zoom(); me.bar = bar; diff --git a/apps/common/main/lib/component/TableStyler.js b/apps/common/main/lib/component/TableStyler.js index 7a354e0bd..fab6c9640 100644 --- a/apps/common/main/lib/component/TableStyler.js +++ b/apps/common/main/lib/component/TableStyler.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -335,10 +335,10 @@ define([ this.setElement(parentEl, false); parentEl.html(this.cmpEl); } else { - $(this.el).html(this.cmpEl); + this.$el.html(this.cmpEl); } } else { - this.cmpEl = $(this.el); + this.cmpEl = this.$el; } me.rendered = true; diff --git a/apps/common/main/lib/component/ThemeColorPalette.js b/apps/common/main/lib/component/ThemeColorPalette.js index 73c761b19..10549495c 100644 --- a/apps/common/main/lib/component/ThemeColorPalette.js +++ b/apps/common/main/lib/component/ThemeColorPalette.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -98,7 +98,7 @@ define([ Common.UI.BaseView.prototype.initialize.call(this, options); var me = this, - el = $(this.el); + el = me.$el || $(this.el); this.colors = me.options.colors || this.generateColorData(me.options.themecolors, me.options.effects, me.options.standardcolors, me.options.transparent); @@ -116,7 +116,7 @@ define([ }, render: function () { - $(this.el).html(this.template({colors: this.colors})); + this.$el.html(this.template({colors: this.colors})); return this; }, @@ -144,7 +144,7 @@ define([ }, updateCustomColors: function() { - var el = $(this.el); + var el = this.$el || $(this.el); if (el) { var selected = el.find('a.' + this.selectedCls), color = (selected.length>0 && /color-dynamic/.test(selected[0].className)) ? selected.attr('color') : undefined; @@ -221,7 +221,7 @@ define([ }, setCustomColor: function(color) { - var el = $(this.el); + var el = this.$el || $(this.el); color = /#?([a-fA-F0-9]{6})/.exec(color); if (color) { this.saveCustomColor(color[1]); @@ -272,7 +272,7 @@ define([ }, select: function(color, suppressEvent) { - var el = $(this.el); + var el = this.$el || $(this.el); el.find('a.' + this.selectedCls).removeClass(this.selectedCls); if (typeof(color) == 'object' ) { @@ -320,11 +320,38 @@ define([ } }, + selectByRGB: function(rgb, suppressEvent) { + var el = this.$el || $(this.el); + el.find('a.' + this.selectedCls).removeClass(this.selectedCls); + + var color = (typeof(rgb) == 'object') ? rgb.color : rgb; + if (/#?[a-fA-F0-9]{6}/.test(color)) { + color = /#?([a-fA-F0-9]{6})/.exec(color)[1].toUpperCase(); + } + + if (/^[a-fA-F0-9]{6}|transparent$/.test(color)) { + if (color != this.value || this.options.allowReselect) { + var co = (color == 'transparent') ? el.find('a.color-transparent') : el.find('a.color-' + color).first(); + if (co.length==0) + co = el.find('#'+color).first(); + if (co.length==0) + co = el.find('a[color="'+color+'"]').first(); + if (co.length>0) { + co.addClass(this.selectedCls); + this.value = color; + } + if (suppressEvent !== true) { + this.fireEvent('select', this, color); + } + } + } + }, + updateColors: function(effectcolors, standartcolors, value) { if (effectcolors===undefined || standartcolors===undefined) return; var me = this, - el = $(this.el); + el = me.$el || $(this.el); if (me.aColorElements === undefined) { me.aColorElements = el.find('a.palette-color'); @@ -380,7 +407,7 @@ define([ if (value) this.select(value, true); else { - var selected = $(this.el).find('a.' + this.selectedCls); + var selected = el.find('a.' + this.selectedCls); if (selected.length && selected.hasClass('palette-color-effect')) { this.value = selected[0].className.match(this.colorRe)[1].toUpperCase(); } @@ -389,7 +416,7 @@ define([ }, clearSelection: function(suppressEvent) { - $(this.el).find('a.' + this.selectedCls).removeClass(this.selectedCls); + this.$el.find('a.' + this.selectedCls).removeClass(this.selectedCls); this.value = undefined; }, diff --git a/apps/common/main/lib/component/ToggleManager.js b/apps/common/main/lib/component/ToggleManager.js index dab80c690..f4536a160 100644 --- a/apps/common/main/lib/component/ToggleManager.js +++ b/apps/common/main/lib/component/ToggleManager.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under diff --git a/apps/common/main/lib/component/Tooltip.js b/apps/common/main/lib/component/Tooltip.js index 230cde22b..df02ca406 100644 --- a/apps/common/main/lib/component/Tooltip.js +++ b/apps/common/main/lib/component/Tooltip.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under diff --git a/apps/common/main/lib/component/TreeView.js b/apps/common/main/lib/component/TreeView.js index 1eb299f1b..d8b645e2c 100644 --- a/apps/common/main/lib/component/TreeView.js +++ b/apps/common/main/lib/component/TreeView.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -193,9 +193,9 @@ define([ }); if (view) { - var innerEl = $(this.el).find('.inner').addBack().filter('.inner'); + var innerEl = (this.$el || $(this.el)).find('.inner').addBack().filter('.inner'); if (innerEl) { - innerEl.find('.empty-text').remove(); + (this.dataViewItems.length<1) && innerEl.find('.empty-text').remove(); if (opts && opts.at!==undefined) { var idx = opts.at; diff --git a/apps/common/main/lib/component/Window.js b/apps/common/main/lib/component/Window.js index 1c4511b20..606e98736 100644 --- a/apps/common/main/lib/component/Window.js +++ b/apps/common/main/lib/component/Window.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -63,6 +63,12 @@ * @cfg {Boolean} animate * Makes the window to animate while showing or hiding * + * @cfg {Object} buttons + * Use an array for predefined buttons (ok, cancel, yes, no): @example ['yes', 'no'] + * Use a named array for the custom buttons: {value: caption, ...} + * @param {String} value will be returned in callback function + * @param {String} caption + * * Methods * * @method show @@ -106,12 +112,6 @@ * @window Common.UI.warning * Shows warning message. * @cfg {String} msg - * @cfg {Object} buttons - * Use an array for predefined buttons (ok, cancel, yes, no): @example ['yes', 'no'] - * Use a named array for the custom buttons: {value: caption, ...} - * @param {String} value will be returned in callback function - * @param {String} caption - * * @cfg {Function} callback * @param {String} button * If the window is closed via shortcut or header's close tool, the 'button' will be 'close' @@ -164,10 +164,18 @@ define([ '<% if (closable!==false) %>' + '
' + '<% %>' + - '<%= title %> ' + + '
<%= title %>
' + '' + '<% } %>' + - '
<%= tpl %>
' + + '
<%= tpl %>' + + '<% if (typeof (buttons) !== "undefined" && _.size(buttons) > 0) { %>' + + '' + + '<% } %>' + + '
' + ''; function _getMask() { @@ -235,6 +243,21 @@ define([ this.$window.css('top',top); } + function _setVisible() { + if (window.innerHeight == undefined) { + var main_width = document.documentElement.offsetWidth; + var main_height = document.documentElement.offsetHeight; + } else { + main_width = Common.Utils.innerWidth(); + main_height = Common.Utils.innerHeight(); + } + + if (this.getLeft() + this.getWidth() > main_width) + this.$window.css('left', main_width - this.getWidth()); + if (this.getTop() + this.getHeight() > main_height) + this.$window.css('top', main_height - this.getHeight()); + } + function _getTransformation(end) { return { '-webkit-transition': '0.3s opacity', @@ -384,31 +407,9 @@ define([ Common.UI.alert = function(options) { var me = this.Window.prototype; - var arrBtns = {ok: me.okButtonText, cancel: me.cancelButtonText, - yes: me.yesButtonText, no: me.noButtonText, - close: me.closeButtonText}; if (!options.buttons) { - options.buttons = {}; - options.buttons['ok'] = {text: arrBtns['ok'], cls: 'primary'}; - } else { - if (_.isArray(options.buttons)) { - if (options.primary==undefined) - options.primary = 'ok'; - var newBtns = {}; - _.each(options.buttons, function(b){ - if (typeof(b) == 'object') { - if (b.value !== undefined) - newBtns[b.value] = {text: b.caption, cls: 'custom' + ((b.primary || options.primary==b.value) ? ' primary' : '')}; - } else { - newBtns[b] = {text: (b=='custom') ? options.customButtonText : arrBtns[b], cls: (options.primary==b) ? 'primary' : ''}; - if (b=='custom') - newBtns[b].cls += ' custom'; - } - }); - - options.buttons = newBtns; - } + options.buttons = ['ok']; } options.dontshow = options.dontshow || false; @@ -420,14 +421,7 @@ define([ '<% if (dontshow) { %>
<% } %>' + '' + '' + - '<% if (dontshow) { %>
<% } %>' + - '<% if (_.size(buttons) > 0) { %>' + - '' + - '<% } %>'; + '<% if (dontshow) { %>
<% } %>'; _.extend(options, { cls: 'alert', @@ -485,7 +479,9 @@ define([ win.on({ 'render:after': function(obj){ - obj.getChild('.footer .dlg-btn').on('click', onBtnClick); + var footer = obj.getChild('.footer'); + options.dontshow && footer.addClass('dontshow'); + footer.find('.dlg-btn').on('click', onBtnClick); chDontShow = new Common.UI.CheckBox({ el: win.$window.find('.dont-show-checkbox'), labelText: win.textDontShow @@ -557,6 +553,29 @@ define([ this.initConfig = {}; this.binding = {}; + var arrBtns = {ok: this.okButtonText, cancel: this.cancelButtonText, + yes: this.yesButtonText, no: this.noButtonText, + close: this.closeButtonText}; + + if (options.buttons && _.isArray(options.buttons)) { + if (options.primary==undefined) + options.primary = 'ok'; + var newBtns = {}; + _.each(options.buttons, function(b){ + if (typeof(b) == 'object') { + if (b.value !== undefined) + newBtns[b.value] = {text: b.caption, cls: 'custom' + ((b.primary || options.primary==b.value) ? ' primary' : '')}; + } else { + newBtns[b] = {text: (b=='custom') ? options.customButtonText : arrBtns[b], cls: (options.primary==b) ? 'primary' : ''}; + if (b=='custom') + newBtns[b].cls += ' custom'; + } + }); + + options.buttons = newBtns; + options.footerCls = options.footerCls || 'center'; + } + _.extend(this.initConfig, config, options || {}); !this.initConfig.id && (this.initConfig.id = 'window-' + this.cid); @@ -612,9 +631,12 @@ define([ this.setResizable(this.initConfig.resizable); var me = this; - Common.NotificationCenter.on('window:close', function() { - if (me.$window && me.isVisible()) me.close(); - }); + this.binding.winclose = function(obj) { + if (me.$window && me.isVisible() && me.$window == obj.$window) me.close(); + }; + Common.NotificationCenter.on('window:close', this.binding.winclose); + + this.initConfig.footerCls && this.$window.find('.footer').addClass(this.initConfig.footerCls); this.fireEvent('render:after',this); return this; @@ -623,7 +645,10 @@ define([ show: function(x,y) { if (this.initConfig.modal) { var mask = _getMask(); - if (this.options.animate !== false) { + if (this.options.animate === false || this.options.animate && this.options.animate.mask === false) { // animate.mask = false -> don't animate mask + mask.attr('counter', parseInt(mask.attr('counter'))+1); + mask.show(); + } else { var opacity = mask.css('opacity'); mask.css('opacity', 0); mask.attr('counter', parseInt(mask.attr('counter'))+1); @@ -632,9 +657,6 @@ define([ setTimeout(function () { mask.css(_getTransformation(opacity)); }, 1); - } else { - mask.attr('counter', parseInt(mask.attr('counter'))+1); - mask.show(); } Common.NotificationCenter.trigger('modal:show', this); @@ -652,6 +674,7 @@ define([ } else if (!this.$window.is(':visible')) { this.$window.css({opacity: 0}); + _setVisible.call(this); this.$window.show() } @@ -704,6 +727,7 @@ define([ if ( this.initConfig.header ) { this.$window.find('.header').off('mousedown', this.binding.dragStart); } + Common.NotificationCenter.off({'window:close': this.binding.winclose}); if (this.initConfig.modal) { var mask = _getMask(), diff --git a/apps/common/main/lib/controller/Chat.js b/apps/common/main/lib/controller/Chat.js index 4ced54e87..5731e4721 100644 --- a/apps/common/main/lib/controller/Chat.js +++ b/apps/common/main/lib/controller/Chat.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -68,7 +68,7 @@ define([ var me = this; Common.NotificationCenter.on('layout:changed', function(area){ Common.Utils.asyncCall(function(e) { - if ( e == 'toolbar' && me.panelChat.$el.is(':visible') ) { + if ( (e == 'toolbar' || e == 'status') && me.panelChat.$el.is(':visible') ) { me.panelChat.updateLayout(true); me.panelChat.setupAutoSizingTextBox(); } @@ -122,17 +122,7 @@ define([ this._isCoAuthoringStopped = true; this.api.asc_coAuthoringDisconnect(); Common.NotificationCenter.trigger('api:disconnect'); - /* - setTimeout(_.bind(function(){ - Common.UI.alert({ - closable: false, - title: this.notcriticalErrorTitle, - msg: this.textUserLimit, - iconCls: 'warn', - buttons: ['ok'] - }); - }, this), 100); - */ + return; } } @@ -225,7 +215,6 @@ define([ } }, - notcriticalErrorTitle: 'Warning', - textUserLimit: 'You are using ONLYOFFICE Editors free version.
Only two users can co-edit the document simultaneously.
Want more? Consider buying ONLYOFFICE Editors Pro version.
Read more' + notcriticalErrorTitle: 'Warning' }, Common.Controllers.Chat || {})); }); \ No newline at end of file diff --git a/apps/common/main/lib/controller/Comments.js b/apps/common/main/lib/controller/Comments.js index 1c1b28ee3..b8f30b6c4 100644 --- a/apps/common/main/lib/controller/Comments.js +++ b/apps/common/main/lib/controller/Comments.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -74,7 +74,7 @@ define([ subEditStrings : {}, filter : undefined, hintmode : false, - previewmode: false, + viewmode: false, isSelectedComment : false, uids : [], oldUids : [], @@ -133,7 +133,7 @@ define([ Common.NotificationCenter.on('app:comment:add', _.bind(this.onAppAddComment, this)); Common.NotificationCenter.on('layout:changed', function(area){ Common.Utils.asyncCall(function(e) { - if ( e == 'toolbar' && this.view.$el.is(':visible') ) { + if ( (e == 'toolbar' || e == 'status') && this.view.$el.is(':visible') ) { this.onAfterShow(); } }, this, area); @@ -147,9 +147,11 @@ define([ this.popoverComments = new Common.Collections.Comments(); if (this.popoverComments) { - this.popoverComments.comparator = function (collection) { return -collection.get('time'); }; + this.popoverComments.comparator = function (collection) { return collection.get('time'); }; } + this.groupCollection = []; + this.view = this.createView('Common.Views.Comments', { store: this.collection }); this.view.render(); @@ -167,7 +169,7 @@ define([ this.currentUserName = data.config.user.fullname; this.sdkViewName = data['sdkviewname'] || this.sdkViewName; this.hintmode = data['hintmode'] || false; - this.previewmode = data['previewmode'] || false; + this.viewmode = data['viewmode'] || false; } }, setApi: function (api) { @@ -192,6 +194,8 @@ define([ setMode: function(mode) { this.mode = mode; this.isModeChanged = true; // change show-comment mode from/to hint mode using canComments flag + this.view.viewmode = !this.mode.canComments; + this.view.changeLayout(mode); return this; }, // @@ -229,12 +233,12 @@ define([ this.api.asc_removeComment(id); } }, - onResolveComment: function (uid, id) { + onResolveComment: function (uid) { var t = this, reply = null, addReply = null, ascComment = buildCommentData(), // new asc_CCommentData(null), - comment = t.findComment(uid, id); + comment = t.findComment(uid); if (_.isUndefined(uid)) { uid = comment.get('uid'); @@ -248,6 +252,7 @@ define([ ascComment.asc_putUserId(comment.get('userid')); ascComment.asc_putUserName(comment.get('username')); ascComment.asc_putSolved(!comment.get('resolved')); + ascComment.asc_putGuid(comment.get('guid')); if (!_.isUndefined(ascComment.asc_putDocumentFlag)) { ascComment.asc_putDocumentFlag(comment.get('unattached')); @@ -277,9 +282,7 @@ define([ return false; }, onShowComment: function (id, selected) { - if (this.previewmode) return; - - var comment = this.findComment(id, undefined); + var comment = this.findComment(id); if (comment) { if (null !== comment.get('quote')) { if (this.api) { @@ -295,7 +298,9 @@ define([ } } else { var model = this.popoverComments.findWhere({uid: id}); - if (model) { + if (model && !this.getPopover().isVisible()) { + this.getPopover().showComments(true); + this.api.asc_selectComment(id); return; } } @@ -340,6 +345,7 @@ define([ ascComment.asc_putUserId(t.currentUserId); ascComment.asc_putUserName(t.currentUserName); ascComment.asc_putSolved(comment.get('resolved')); + ascComment.asc_putGuid(comment.get('guid')); if (!_.isUndefined(ascComment.asc_putDocumentFlag)) { ascComment.asc_putDocumentFlag(comment.get('unattached')); @@ -396,6 +402,7 @@ define([ ascComment.asc_putUserId(comment.get('userid')); ascComment.asc_putUserName(comment.get('username')); ascComment.asc_putSolved(comment.get('resolved')); + ascComment.asc_putGuid(comment.get('guid')); if (!_.isUndefined(ascComment.asc_putDocumentFlag)) { ascComment.asc_putDocumentFlag(comment.get('unattached')); @@ -458,6 +465,7 @@ define([ ascComment.asc_putUserId(comment.get('userid')); ascComment.asc_putUserName(comment.get('username')); ascComment.asc_putSolved(comment.get('resolved')); + ascComment.asc_putGuid(comment.get('guid')); if (!_.isUndefined(ascComment.asc_putDocumentFlag)) { ascComment.asc_putDocumentFlag(comment.get('unattached')); @@ -491,6 +499,7 @@ define([ ascComment.asc_addReply(addReply); me.api.asc_changeComment(id, ascComment); + me.mode && me.mode.canRequestUsers && me.view.pickEMail(ascComment.asc_getGuid(), replyVal); return true; } @@ -515,6 +524,7 @@ define([ ascComment.asc_putUserId(comment.get('userid')); ascComment.asc_putUserName(comment.get('username')); ascComment.asc_putSolved(comment.get('resolved')); + ascComment.asc_putGuid(comment.get('guid')); if (!_.isUndefined(ascComment.asc_putDocumentFlag)) { ascComment.asc_putDocumentFlag(comment.get('unattached')); @@ -596,47 +606,40 @@ define([ if (filter) { if (!this.view.isVisible()) { this.view.needUpdateFilter = filter; - this.filter = { - property : filter.property, - value : filter.value - }; - return; + applyOnly = true; } - this.view.needUpdateFilter = false; + this.filter = filter; - this.filter = { - property : filter.property, - value : filter.value - }; + var me = this, + comments = []; + this.filter.forEach(function(item){ + if (!me.groupCollection[item]) + me.groupCollection[item] = new Backbone.Collection([], { model: Common.Models.Comment}); + comments = comments.concat(me.groupCollection[item].models); + }); + this.collection.reset(comments); + this.collection.groups = this.filter; if (!applyOnly) { if (this.getPopover()) { this.getPopover().hide(); } - } + this.view.needUpdateFilter = false; - var t = this, endComment = null; - - this.collection.each(function (model) { - var prop = model.get(t.filter.property); - if (prop) { - model.set('hide', (null === prop.match(t.filter.value)), {silent: !!applyOnly}); + var end = true; + for (var i = this.collection.length - 1; i >= 0; --i) { + if (end) { + this.collection.at(i).set('last', true, {silent: true}); + } else { + if (this.collection.at(i).get('last')) { + this.collection.at(i).set('last', false, {silent: true}); + } + } + end = false; } - - if (model.get('last')) { - model.set('last', false, {silent:!!applyOnly}); - } - - if (!model.get('hide')) { - endComment = model; - } - }); - - if (endComment) { - endComment.set('last', true, {silent: !!applyOnly}); - } - if (!applyOnly) + this.view.render(); this.view.update(); + } } }, onAppAddComment: function (sender, to_doc) { @@ -644,12 +647,23 @@ define([ this.addDummyComment(); }, + addCommentToGroupCollection: function(comment) { + var groupname = comment.get('groupName'); + if (!this.groupCollection[groupname]) + this.groupCollection[groupname] = new Backbone.Collection([], { model: Common.Models.Comment}); + this.groupCollection[groupname].push(comment); + }, + // SDK onApiAddComment: function (id, data) { var comment = this.readSDKComment(id, data); if (comment) { - this.collection.push(comment); + if (comment.get('groupName')) { + this.addCommentToGroupCollection(comment); + (_.indexOf(this.collection.groups, comment.get('groupName'))>-1) && this.collection.push(comment); + } else + this.collection.push(comment); this.updateComments(true); @@ -668,12 +682,20 @@ define([ onApiAddComments: function (data) { for (var i = 0; i < data.length; ++i) { var comment = this.readSDKComment(data[i].asc_getId(), data[i]); - this.collection.push(comment); + comment.get('groupName') ? this.addCommentToGroupCollection(comment) : this.collection.push(comment); } this.updateComments(true); }, onApiRemoveComment: function (id, silentUpdate) { + for (var name in this.groupCollection) { + var store = this.groupCollection[name], + model = store.findWhere({uid: id}); + if (model) { + store.remove(model); + break; + } + } if (this.collection.length) { var model = this.collection.findWhere({uid: id}); if (model) { @@ -717,7 +739,7 @@ define([ replies = null, repliesCount = 0, dateReply = null, - comment = this.findComment(id); + comment = this.findComment(id) || this.findCommentInGroup(id); if (comment) { t = this; @@ -762,7 +784,6 @@ define([ })); } - replies.sort(function (a,b) { return a.get('time') - b.get('time');}); comment.set('replys', replies); if (!silentUpdate) { @@ -776,7 +797,7 @@ define([ } }, onApiLockComment: function (id,userId) { - var cur = this.findComment(id), + var cur = this.findComment(id) || this.findCommentInGroup(id), user = null; if (cur) { @@ -792,7 +813,7 @@ define([ } }, onApiUnLockComment: function (id) { - var cur = this.findComment(id); + var cur = this.findComment(id) || this.findCommentInGroup(id); if (cur) { cur.set('lock', false); this.getPopover() && this.getPopover().loadText(); @@ -800,11 +821,9 @@ define([ } }, onApiShowComment: function (uids, posX, posY, leftX, opts, hint) { - if (this.previewmode) return; - this.isModeChanged = false; var same_uids = (0 === _.difference(this.uids, uids).length) && (0 === _.difference(uids, this.uids).length); - if (hint && this.isSelectedComment && same_uids) { + if (hint && this.isSelectedComment && same_uids && !this.isModeChanged) { // хотим показать тот же коментарий что был и выбран return; } @@ -815,7 +834,7 @@ define([ if (popover) { this.clearDummyComment(); - if (this.isSelectedComment && same_uids) { + if (this.isSelectedComment && same_uids && !this.isModeChanged) { //NOTE: click to sdk view ? if (this.api) { //this.view.txtComment.blur(); @@ -831,9 +850,8 @@ define([ saveTxtReplyId = '', comment = null, text = '', - animate = true; - - this.popoverComments.reset(); + animate = true, + comments = []; for (i = 0; i < uids.length; ++i) { saveTxtId = uids[i]; @@ -871,11 +889,15 @@ define([ this.isSelectedComment = !hint || !this.hintmode; this.uids = _.clone(uids); - this.popoverComments.push(comment); + comments.push(comment); if (!this._dontScrollToComment) this.view.commentsView.scrollToRecord(comment); this._dontScrollToComment = false; } + comments.sort(function (a, b) { + return a.get('time') - b.get('time'); + }); + this.popoverComments.reset(comments); if (popover.isVisible()) { popover.hide(); @@ -884,6 +906,7 @@ define([ popover.setLeftTop(posX, posY, leftX); popover.showComments(animate, false, true, text); } + this.isModeChanged = false; }, onApiHideComment: function (hint) { var t = this; @@ -919,8 +942,6 @@ define([ } }, onApiUpdateCommentPosition: function (uids, posX, posY, leftX) { - if (this.previewmode) return; - var i, useAnimation = false, comment = null, text = undefined, @@ -937,9 +958,7 @@ define([ if (this.isModeChanged) this.onApiShowComment(uids, posX, posY, leftX); if (0 === this.popoverComments.length) { - - this.popoverComments.reset(); - + var comments = []; for (i = 0; i < uids.length; ++i) { saveTxtId = uids[i]; saveTxtReplyId = uids[i] + '-R'; @@ -956,8 +975,12 @@ define([ text = this.subEditStrings[saveTxtReplyId]; } - this.popoverComments.push(comment); + comments.push(comment); } + comments.sort(function (a, b) { + return a.get('time') - b.get('time'); + }); + this.popoverComments.reset(comments); useAnimation = true; this.getPopover().showComments(useAnimation, undefined, undefined, text); @@ -993,12 +1016,7 @@ define([ // internal - updateComments: function (needRender, disableSort) { - if (needRender && !this.view.isVisible()) { - this.view.needRender = needRender; - return; - } - + updateComments: function (needRender, disableSort, loadText) { var me = this; me.updateCommentsTime = new Date(); if (me.timerUpdateComments===undefined) @@ -1006,12 +1024,18 @@ define([ if ((new Date()) - me.updateCommentsTime>100) { clearInterval(me.timerUpdateComments); me.timerUpdateComments = undefined; - me.updateCommentsView(needRender, disableSort); + me.updateCommentsView(needRender, disableSort, loadText); } }, 25); }, - updateCommentsView: function (needRender, disableSort) { + updateCommentsView: function (needRender, disableSort, loadText) { + if (needRender && !this.view.isVisible()) { + this.view.needRender = needRender; + this.onUpdateFilter(this.filter, true); + return; + } + var i, end = true; if (_.isUndefined(disableSort)) { @@ -1019,6 +1043,8 @@ define([ } if (needRender) { + this.onUpdateFilter(this.filter, true); + for (i = this.collection.length - 1; i >= 0; --i) { if (end) { this.collection.at(i).set('last', true, {silent: true}); @@ -1030,24 +1056,27 @@ define([ end = false; } - this.onUpdateFilter(this.filter, true); - this.view.render(); this.view.needRender = false; } this.view.update(); - }, - findComment: function (uid, id) { - if (_.isUndefined(uid)) { - return this.collection.findWhere({id: id}); - } + loadText && this.view.loadText(); + }, + findComment: function (uid) { return this.collection.findWhere({uid: uid}); }, findPopupComment: function (id) { return this.popoverComments.findWhere({id: id}); }, + findCommentInGroup: function (id) { + for (var name in this.groupCollection) { + var store = this.groupCollection[name], + model = store.findWhere({uid: id}); + if (model) return model; + } + }, closeEditing: function (id) { var t = this; @@ -1102,7 +1131,9 @@ define([ if (_.isUndefined(this.popover)) { this.popover = Common.Views.ReviewPopover.prototype.getPopover({ commentsStore : this.popoverComments, - renderTo : this.sdkViewName + renderTo : this.sdkViewName, + canRequestUsers: (this.mode) ? this.mode.canRequestUsers : undefined, + canRequestSendNotify: (this.mode) ? this.mode.canRequestSendNotify : undefined }); this.popover.setCommentsStore(this.popoverComments); } @@ -1112,27 +1143,62 @@ define([ // helpers onUpdateUsers: function() { - var users = this.userCollection; - this.collection.each(function (model) { - var user = users.findOriginalUser(model.get('userid')); - model.set('usercolor', (user) ? user.get('color') : null, {silent: true}); + var users = this.userCollection, + hasGroup = false; + for (var name in this.groupCollection) { + hasGroup = true; + this.groupCollection[name].each(function (model) { + var user = users.findOriginalUser(model.get('userid')), + color = (user) ? user.get('color') : null, + needrender = false; + if (color !== model.get('usercolor')) { + needrender = true; + model.set('usercolor', color, {silent: true}); + } + + model.get('replys').forEach(function (reply) { + user = users.findOriginalUser(reply.get('userid')); + color = (user) ? user.get('color') : null; + if (color !== reply.get('usercolor')) { + needrender = true; + reply.set('usercolor', color, {silent: true}); + } + }); + + if (needrender) + model.trigger('change'); + }); + } + !hasGroup && this.collection.each(function (model) { + var user = users.findOriginalUser(model.get('userid')), + color = (user) ? user.get('color') : null, + needrender = false; + if (color !== model.get('usercolor')) { + needrender = true; + model.set('usercolor', color, {silent: true}); + } model.get('replys').forEach(function (reply) { user = users.findOriginalUser(reply.get('userid')); - reply.set('usercolor', (user) ? user.get('color') : null, {silent: true}); + color = (user) ? user.get('color') : null; + if (color !== reply.get('usercolor')) { + needrender = true; + reply.set('usercolor', color, {silent: true}); + } }); + if (needrender) + model.trigger('change'); }); - this.updateComments(true); - if (this.getPopover().isVisible()) - this.getPopover().update(true); }, readSDKComment: function (id, data) { var date = (data.asc_getOnlyOfficeTime()) ? new Date(this.stringOOToLocalDate(data.asc_getOnlyOfficeTime())) : ((data.asc_getTime() == '') ? new Date() : new Date(this.stringUtcToLocalDate(data.asc_getTime()))); - var user = this.userCollection.findOriginalUser(data.asc_getUserId()); + var user = this.userCollection.findOriginalUser(data.asc_getUserId()), + groupname = id.substr(0, id.lastIndexOf('_')+1).match(/^(doc|sheet[0-9_]+)_/); var comment = new Common.Models.Comment({ uid : id, + guid : data.asc_getGuid(), userid : data.asc_getUserId(), username : data.asc_getUserName(), usercolor : (user) ? user.get('color') : null, @@ -1150,7 +1216,9 @@ define([ showReplyInPopover : false, hideAddReply : !_.isUndefined(this.hidereply) ? this.hidereply : (this.showPopover ? true : false), scope : this.view, - editable : this.mode.canEditComments || (data.asc_getUserId() == this.currentUserId) + editable : this.mode.canEditComments || (data.asc_getUserId() == this.currentUserId), + hint : !this.mode.canComments, + groupName : (groupname && groupname.length>1) ? groupname[1] : null }); if (comment) { var replies = this.readSDKReplies(data); @@ -1187,10 +1255,6 @@ define([ editable : this.mode.canEditComments || (data.asc_getReply(i).asc_getUserId() == this.currentUserId) })); } - - replies.sort(function (a, b) { - return a.get('time') - b.get('time'); - }); } return replies; @@ -1202,11 +1266,14 @@ define([ if (this.api) { var me = this, anchor = null, date = new Date(), dialog = this.getPopover(); if (dialog) { - if (this.popoverComments.length) { - _.delay(function() { - dialog.commentsView.setFocusToTextBox(); - }, 200); - return; + if (this.popoverComments.length) {// can add new comment to text with other comments + if (this.isDummyComment) {//don't hide previous dummy comment + _.delay(function() { + dialog.commentsView.setFocusToTextBox(); + }, 200); + return; + } else + this.closeEditing(); // add dummy comment and close editing for existing comment } var user = this.userCollection.findOriginalUser(this.currentUserId); @@ -1242,8 +1309,8 @@ define([ dialog.hide(); } - dialog.handlerHide = (function () { - me.clearDummyComment(); + dialog.handlerHide = (function (clear) { + me.clearDummyComment(clear); }); anchor = this.api.asc_getAnchorPosition(); @@ -1252,7 +1319,8 @@ define([ anchor.asc_getY(), this.hintmode ? anchor.asc_getX() : undefined); - dialog.showComments(true, false, true); + Common.NotificationCenter.trigger('comments:showdummy'); + dialog.showComments(true, false, true, dialog.getDummyText()); } } } @@ -1266,12 +1334,14 @@ define([ this.hidereply = false; this.isSelectedComment = false; this.uids = []; - this.isDummyComment = false; this.popoverComments.reset(); if (this.getPopover().isVisible()) { this.getPopover().hideComments(); } + + this.isDummyComment = false; + comment.asc_putText(commentVal); comment.asc_putTime(this.utcDateToString(new Date())); comment.asc_putOnlyOfficeTime(this.ooDateToString(new Date())); @@ -1284,14 +1354,14 @@ define([ this.api.asc_addComment(comment); this.view.showEditContainer(false); - + this.mode && this.mode.canRequestUsers && this.view.pickEMail(comment.asc_getGuid(), commentVal); if (!_.isUndefined(this.api.asc_SetDocumentPlaceChangedEnabled)) { this.api.asc_SetDocumentPlaceChangedEnabled(false); } } } }, - clearDummyComment: function () { + clearDummyComment: function (clear) { if (this.isDummyComment) { this.isDummyComment = false; @@ -1303,6 +1373,9 @@ define([ var dialog = this.getPopover(); if (dialog) { + clear && dialog.clearDummyText(); + dialog.saveDummyText(); + dialog.handlerHide = (function () { }); @@ -1316,6 +1389,8 @@ define([ if (!_.isUndefined(this.api.asc_SetDocumentPlaceChangedEnabled)) { this.api.asc_SetDocumentPlaceChangedEnabled(false); } + + Common.NotificationCenter.trigger('comments:cleardummy'); } }, @@ -1365,12 +1440,12 @@ define([ if ('none' !== panel.css('display')) { this.view.txtComment.focus(); } - if (this.view.needRender) - this.updateComments(true); - else if (this.view.needUpdateFilter) - this.onUpdateFilter(this.view.needUpdateFilter); - this.view.update(); } + if (this.view.needRender) + this.updateComments(true); + else if (this.view.needUpdateFilter) + this.onUpdateFilter(this.view.needUpdateFilter); + this.view.update(); } }, @@ -1437,9 +1512,21 @@ define([ }, setPreviewMode: function(mode) { - this.previewmode = mode; + if (this.viewmode === mode) return; + this.viewmode = mode; + if (mode) + this.prevcanComments = this.mode.canComments; + this.mode.canComments = (mode) ? false : this.prevcanComments; + this.closeEditing(); + this.setMode(this.mode); + this.updateComments(true); if (this.getPopover()) - this.getPopover().hide(); + mode ? this.getPopover().hide() : this.getPopover().update(true); + }, + + clearCollections: function() { + this.collection.reset(); + this.groupCollection = []; } }, Common.Controllers.Comments || {})); diff --git a/apps/common/main/lib/controller/Desktop.js b/apps/common/main/lib/controller/Desktop.js index fd5ae4b4c..ba7bd7336 100644 --- a/apps/common/main/lib/controller/Desktop.js +++ b/apps/common/main/lib/controller/Desktop.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -45,6 +45,53 @@ define([ var config = {}; var app = window.AscDesktopEditor; + if ( !!app ) { + window.on_native_message = function (cmd, param) { + if (/^style:change/.test(cmd)) { + var obj = JSON.parse(param); + + if ( obj.element == 'toolbar' ) { + if ( obj.action == 'off' && obj.style == 'native-color' ) { + $('.toolbar').removeClass('editor-native-color'); + } + } else + if ( obj.element == 'body' ) { + if ( obj.action == 'merge' ) { + var style = document.createElement('style'); + style.innerHTML = obj.style; + document.body.appendChild(style); + } + } + } else + if (/window:features/.test(cmd)) { + var obj = JSON.parse(param); + + if ( obj.canUndock == 'true' ) { + if ( !config.canUndock ) { + config.canUndock = true; + + if ( !_.isEmpty(config) ) + Common.NotificationCenter.trigger('app:config', {canUndock:true}); + } + } + } else + if (/window:status/.test(cmd)) { + var obj = JSON.parse(param); + + if ( obj.action == 'undocking' ) { + Common.NotificationCenter.trigger('undock:status', {status:obj.status=='undocked'?'undocked':'docked'}); + } + } else + if (/editor:config/.test(cmd)) { + if ( param == 'request' ) + app.execCommand('editor:config', JSON.stringify({user: config.user, 'extraleft': $('#box-document-title #slot-btn-dt-save').parent().width()})); + } + }; + + app.execCommand('webapps:events', 'loading'); + app.execCommand('window:features', 'request'); + } + return { init: function (opts) { _.extend(config, opts); @@ -53,6 +100,18 @@ define([ Common.NotificationCenter.on('app:ready', function (opts) { _.extend(config, opts); !!app && app.execCommand('doc:onready', ''); + + $('.toolbar').addClass('editor-native-color'); + }); + + Common.NotificationCenter.on('action:undocking', function (opts) { + app.execCommand('editor:event', JSON.stringify({action:'undocking', state: opts == 'dock' ? 'dock' : 'undock'})); + }); + + Common.NotificationCenter.on('app:face', function (mode) { + if ( config.canUndock ) { + Common.NotificationCenter.trigger('app:config', {canUndock: true}); + } }); } }, @@ -66,10 +125,21 @@ define([ if ( opts == 'preloader:hide' ) { app.execCommand('editor:onready', ''); return true; + } else + if ( opts == 'create:new' ) { + if (config.createUrl == 'desktop://create.new') { + app.LocalFileCreate(!!window.SSE ? 2 : !!window.PE ? 1 : 0); + return true; + } } } return false; + }, + requestClose: function () { + if ( config.isDesktopApp && !!app ) { + app.execCommand('editor:event', JSON.stringify({action:'close', url: config.customization.goback.url})); + } } }; }; diff --git a/apps/common/main/lib/controller/ExternalDiagramEditor.js b/apps/common/main/lib/controller/ExternalDiagramEditor.js index a1b6c1930..df8e41e32 100644 --- a/apps/common/main/lib/controller/ExternalDiagramEditor.js +++ b/apps/common/main/lib/controller/ExternalDiagramEditor.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -51,7 +51,8 @@ define([ var appLang = 'en', customization = undefined, targetApp = '', - externalEditor = null; + externalEditor = null, + isAppFirstOpened = true; var createExternalEditor = function() { @@ -106,6 +107,11 @@ define([ if (externalEditor) { externalEditor.serviceCommand('setAppDisabled',false); + if (isAppFirstOpened && this.diagramEditorView._isExternalDocReady) { + isAppFirstOpened = false; + this.diagramEditorView._chartData && this.setChartData(); + } + if (this.needDisableEditing && this.diagramEditorView._isExternalDocReady) { this.onDiagrammEditingDisabled(); } @@ -150,8 +156,10 @@ define([ }, setChartData: function() { - externalEditor && externalEditor.serviceCommand('setChartData', this.diagramEditorView._chartData); - this.diagramEditorView._chartData = null; + if (!isAppFirstOpened) { + externalEditor && externalEditor.serviceCommand('setChartData', this.diagramEditorView._chartData); + this.diagramEditorView._chartData = null; + } }, loadConfig: function(data) { @@ -190,10 +198,8 @@ define([ if (this.diagramEditorView) { if (eventData.type == 'documentReady') { this.diagramEditorView._isExternalDocReady = true; - if (this.diagramEditorView._chartData) { - externalEditor && externalEditor.serviceCommand('setChartData', this.diagramEditorView._chartData); - this.diagramEditorView._chartData = null; - } + this.isExternalEditorVisible && (isAppFirstOpened = false); + this.diagramEditorView._chartData && this.setChartData(); if (this.needDisableEditing) { this.onDiagrammEditingDisabled(); } diff --git a/apps/common/main/lib/controller/ExternalMergeEditor.js b/apps/common/main/lib/controller/ExternalMergeEditor.js index 6e3cfdfc5..d9ac85562 100644 --- a/apps/common/main/lib/controller/ExternalMergeEditor.js +++ b/apps/common/main/lib/controller/ExternalMergeEditor.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under diff --git a/apps/common/main/lib/controller/Fonts.js b/apps/common/main/lib/controller/Fonts.js index 364478fcb..a20c68604 100644 --- a/apps/common/main/lib/controller/Fonts.js +++ b/apps/common/main/lib/controller/Fonts.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -48,10 +48,10 @@ define([ 'common/main/lib/collection/Fonts' ], function () { 'use strict'; Common.Controllers.Fonts = Backbone.Controller.extend((function() { - var FONT_TYPE_USERUSED = 4; + var FONT_TYPE_RECENT = 4; function isFontSaved(store, rec) { - var out = rec.get('type') == FONT_TYPE_USERUSED, + var out = rec.get('type') == FONT_TYPE_RECENT, i = -1, c = store.length, su, @@ -59,7 +59,7 @@ define([ while (!out && ++i < c) { su = store.at(i); - if (su.get('type') != FONT_TYPE_USERUSED) + if (su.get('type') != FONT_TYPE_RECENT) break; out = su.get('name') == n; @@ -78,7 +78,7 @@ define([ // name: data.name, // imgidx: data.imgidx, // cloneid: node.querySelector('img').id, -// type: FONT_TYPE_USERUSED +// type: FONT_TYPE_RECENT // }; // combo.getStore().insert(0,[font]); // @@ -93,7 +93,7 @@ define([ // } // // font = combo.getStore().getAt(5); -// if (font.data.type==FONT_TYPE_USERUSED) { +// if (font.data.type==FONT_TYPE_RECENT) { // combo.getStore().remove(font); // } else { // var plugin = combo.getPlugin('scrollpane'); diff --git a/apps/common/main/lib/controller/History.js b/apps/common/main/lib/controller/History.js index 3d68ca4b4..056183ee3 100644 --- a/apps/common/main/lib/controller/History.js +++ b/apps/common/main/lib/controller/History.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -113,7 +113,7 @@ define([ Common.Gateway.requestRestore(record.get('revision')); else { this.isFromSelectRevision = record.get('revision'); - this.api.asc_DownloadAs(Asc.c_oAscFileType.DOCX, true); + this.api.asc_DownloadAs(new Asc.asc_CDownloadOptions(Asc.c_oAscFileType.DOCX, true)); } return; } @@ -152,7 +152,13 @@ define([ this.api.asc_showRevision(hist); var commentsController = this.getApplication().getController('Common.Controllers.Comments'); - if (commentsController) commentsController.onApiHideComment(); + if (commentsController) { + commentsController.onApiHideComment(); + commentsController.clearCollections(); + } + var reviewController = this.getApplication().getController('Common.Controllers.ReviewChanges'); + if (reviewController) + reviewController.onApiShowChange(); } }, @@ -202,7 +208,13 @@ define([ this.api.asc_showRevision(hist); var commentsController = this.getApplication().getController('Common.Controllers.Comments'); - if (commentsController) commentsController.onApiHideComment(); + if (commentsController) { + commentsController.onApiHideComment(); + commentsController.clearCollections(); + } + var reviewController = this.getApplication().getController('Common.Controllers.ReviewChanges'); + if (reviewController) + reviewController.onApiShowChange(); } } }, diff --git a/apps/common/main/lib/controller/Plugins.js b/apps/common/main/lib/controller/Plugins.js index 829877051..c55a79656 100644 --- a/apps/common/main/lib/controller/Plugins.js +++ b/apps/common/main/lib/controller/Plugins.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -45,6 +45,9 @@ define([ Common.Controllers.Plugins = Backbone.Controller.extend(_.extend({ models: [], + appOptions: {}, + configPlugins: {autostart:[]},// {config: 'from editor config', plugins: 'loaded plugins', UIplugins: 'loaded customization plugins', autostart: 'autostart guids'} + serverPlugins: {autostart:[]},// {config: 'from editor config', plugins: 'loaded plugins', autostart: 'autostart guids'} collections: [ 'Common.Collections.Plugins' ], @@ -63,7 +66,7 @@ define([ var tab = {action: 'plugins', caption: me.panelPlugins.groupCaption}; me.$toolbarPanelPlugins = me.panelPlugins.getPanel(); - toolbar.addTab(tab, me.$toolbarPanelPlugins, 4); // TODO: clear plugins list in left panel + toolbar.addTab(tab, me.$toolbarPanelPlugins, 10); // TODO: clear plugins list in left panel } } }, @@ -95,7 +98,54 @@ define([ this._moveOffset = {x:0, y:0}; - this.autostart = null; + this.autostart = []; + + Common.Gateway.on('init', this.loadConfig.bind(this)); + Common.NotificationCenter.on('app:face', this.onAppShowed.bind(this)); + }, + + loadConfig: function(data) { + var me = this; + me.configPlugins.config = data.config.plugins; + me.editor = !!window.DE ? 'word' : !!window.PE ? 'slide' : 'cell'; + }, + + loadPlugins: function() { + if (this.configPlugins.config) { + this.getPlugins(this.configPlugins.config.pluginsData) + .then(function(loaded) + { + me.configPlugins.plugins = loaded; + me.mergePlugins(); + }) + .catch(function(err) + { + me.configPlugins.plugins = false; + }); + } else + this.configPlugins.plugins = false; + + var server_plugins_url = '../../../../plugins.json', + me = this; + Common.Utils.loadConfig(server_plugins_url, function (obj) { + if ( obj != 'error' ) { + me.serverPlugins.config = obj; + me.getPlugins(me.serverPlugins.config.pluginsData) + .then(function(loaded) + { + me.serverPlugins.plugins = loaded; + me.mergePlugins(); + }) + .catch(function(err) + { + me.serverPlugins.plugins = false; + }); + } else + me.serverPlugins.plugins = false; + }); + }, + + onAppShowed: function (config) { }, setApi: function(api) { @@ -106,19 +156,23 @@ define([ this.api.asc_registerCallback("asc_onPluginResize", _.bind(this.onPluginResize, this)); this.api.asc_registerCallback("asc_onPluginMouseUp", _.bind(this.onPluginMouseUp, this)); this.api.asc_registerCallback("asc_onPluginMouseMove", _.bind(this.onPluginMouseMove, this)); + this.api.asc_registerCallback('asc_onPluginsReset', _.bind(this.resetPluginsList, this)); + this.api.asc_registerCallback('asc_onPluginsInit', _.bind(this.onPluginsInit, this)); + this.loadPlugins(); return this; }, setMode: function(mode) { - if (mode.canPlugins) { - this.updatePluginsList(); - } + this.appOptions = mode; + this.customPluginsComplete = !this.appOptions.canBrandingExt; + if (this.appOptions.canBrandingExt) + this.getAppCustomPlugins(this.configPlugins); return this; }, onAfterRender: function(panelPlugins) { - panelPlugins.viewPluginsList.on('item:click', _.bind(this.onSelectPlugin, this)); + panelPlugins.viewPluginsList && panelPlugins.viewPluginsList.on('item:click', _.bind(this.onSelectPlugin, this)); this.bindViewEvents(this.panelPlugins, this.events); var me = this; Common.NotificationCenter.on({ @@ -138,7 +192,7 @@ define([ }); }, - updatePluginsList: function() { + refreshPluginsList: function() { var me = this; var storePlugins = this.getApplication().getCollection('Common.Collections.Plugins'), arr = []; @@ -147,6 +201,7 @@ define([ plugin.set_Name(item.get('name')); plugin.set_Guid(item.get('guid')); plugin.set_BaseUrl(item.get('baseUrl')); + var variations = item.get('variations'), variationsArr = []; variations.forEach(function(itemVar){ @@ -156,6 +211,7 @@ define([ variation.set_Icons(itemVar.get('icons')); variation.set_Visual(itemVar.get('isVisual')); variation.set_CustomWindow(itemVar.get('isCustomWindow')); + variation.set_System(itemVar.get('isSystem')); variation.set_Viewer(itemVar.get('isViewer')); variation.set_EditorsSupport(itemVar.get('EditorsSupport')); variation.set_Modal(itemVar.get('isModal')); @@ -166,14 +222,17 @@ define([ variation.set_Buttons(itemVar.get('buttons')); variation.set_Size(itemVar.get('size')); variation.set_InitOnSelectionChanged(itemVar.get('initOnSelectionChanged')); + variation.set_Events(itemVar.get('events')); + variationsArr.push(variation); }); + plugin.set_Variations(variationsArr); item.set('pluginObj', plugin); arr.push(plugin); }); this.api.asc_pluginsRegister('', arr); - if (storePlugins.length>0) + if (storePlugins.hasVisible()) Common.NotificationCenter.trigger('tab:visible', 'plugins', true); }, @@ -191,6 +250,7 @@ define([ onResetPlugins: function (collection) { var me = this; + me.appOptions.canPlugins = !collection.isEmpty(); if ( me.$toolbarPanelPlugins ) { me.$toolbarPanelPlugins.empty(); @@ -215,6 +275,8 @@ define([ rank = new_rank; }); _group.appendTo(me.$toolbarPanelPlugins); + } else { + console.error('toolbar panel isnot created'); } }, @@ -291,12 +353,13 @@ define([ this.api.asc_pluginRun(record.get('guid'), 0, ''); }, - onPluginShow: function(plugin, variationIndex, frameId) { + onPluginShow: function(plugin, variationIndex, frameId, urlAddition) { var variation = plugin.get_Variations()[variationIndex]; if (variation.get_Visual()) { var url = variation.get_Url(); url = ((plugin.get_BaseUrl().length == 0) ? url : plugin.get_BaseUrl()) + url; - + if (urlAddition) + url += urlAddition; if (variation.get_InsideMode()) { if (!this.panelPlugins.openInsideMode(plugin.get_Name(), url, frameId)) this.api.asc_pluginButtonClick(-1); @@ -310,7 +373,8 @@ define([ if (_.isArray(arrBtns)) { _.each(arrBtns, function(b, index){ - newBtns[index] = {text: b.text, cls: 'custom' + ((b.primary) ? ' primary' : '')}; + if (b.visible) + newBtns[index] = {text: b.text, cls: 'custom' + ((b.primary) ? ' primary' : '')}; }); } @@ -353,7 +417,7 @@ define([ else if (this.panelPlugins.iframePlugin) this.panelPlugins.closeInsideMode(); this.panelPlugins.closedPluginMode(plugin.get_Guid()); - this.runAutoStartPlugins(this.autostart); + this.runAutoStartPlugins(); }, onPluginResize: function(size, minSize, maxSize, callback ) { @@ -392,13 +456,229 @@ define([ Common.NotificationCenter.trigger('frame:mousemove', { pageX: x*Common.Utils.zoom()+this._moveOffset.x, pageY: y*Common.Utils.zoom()+this._moveOffset.y }); }, - runAutoStartPlugins: function(autostart) { - if (autostart && autostart.length>0) { - var guid = autostart.shift(); - this.autostart = autostart; - this.api.asc_pluginRun(guid, 0, ''); - } - } + onPluginsInit: function(pluginsdata) { + !(pluginsdata instanceof Array) && (pluginsdata = pluginsdata["pluginsData"]); + this.parsePlugins(pluginsdata) + }, + runAutoStartPlugins: function() { + if (this.autostart && this.autostart.length > 0) { + this.api.asc_pluginRun(this.autostart.shift(), 0, ''); + } + }, + + resetPluginsList: function() { + this.getApplication().getCollection('Common.Collections.Plugins').reset(); + }, + + applyUICustomization: function () { + var me = this; + return new Promise(function(resolve, reject) { + var timer_sl = setInterval(function() { + if ( me.customPluginsComplete ) { + clearInterval(timer_sl); + try { + me.configPlugins.UIplugins && me.configPlugins.UIplugins.forEach(function (c) { + if ( c.code ) eval(c.code); + }); + } catch (e) {} + resolve(); + } + }, 10); + }); + }, + + parsePlugins: function(pluginsdata, uiCustomize) { + var me = this; + var pluginStore = this.getApplication().getCollection('Common.Collections.Plugins'), + isEdit = me.appOptions.isEdit, + editor = me.editor; + if ( pluginsdata instanceof Array ) { + var arr = [], arrUI = [], + lang = me.appOptions.lang.split(/[\-_]/)[0]; + pluginsdata.forEach(function(item){ + if ( arr.some(function(i) { + return (i.get('baseUrl') == item.baseUrl || i.get('guid') == item.guid); + } + ) || pluginStore.findWhere({baseUrl: item.baseUrl}) || pluginStore.findWhere({guid: item.guid})) + { + return; + } + + var variationsArr = [], + pluginVisible = false; + item.variations.forEach(function(itemVar){ + var visible = (isEdit || itemVar.isViewer && (itemVar.isDisplayedInViewer!==false)) && _.contains(itemVar.EditorsSupport, editor) && !itemVar.isSystem; + if ( visible ) pluginVisible = true; + + if (item.isUICustomizer ) { + visible && arrUI.push({ + url: item.baseUrl + itemVar.url + }); + } else { + var model = new Common.Models.PluginVariation(itemVar); + var description = itemVar.description; + if (typeof itemVar.descriptionLocale == 'object') + description = itemVar.descriptionLocale[lang] || itemVar.descriptionLocale['en'] || description || ''; + + _.each(itemVar.buttons, function(b, index){ + if (typeof b.textLocale == 'object') + b.text = b.textLocale[lang] || b.textLocale['en'] || b.text || ''; + b.visible = (isEdit || b.isViewer !== false); + }); + + model.set({ + description: description, + index: variationsArr.length, + url: itemVar.url, + icons: itemVar.icons, + buttons: itemVar.buttons, + visible: visible + }); + + variationsArr.push(model); + } + }); + + if (variationsArr.length > 0 && !item.isUICustomizer) { + var name = item.name; + if (typeof item.nameLocale == 'object') + name = item.nameLocale[lang] || item.nameLocale['en'] || name || ''; + + arr.push(new Common.Models.Plugin({ + name : name, + guid: item.guid, + baseUrl : item.baseUrl, + variations: variationsArr, + currentVariation: 0, + visible: pluginVisible, + groupName: (item.group) ? item.group.name : '', + groupRank: (item.group) ? item.group.rank : 0 + })); + } + }); + + if ( uiCustomize!==false ) // from ui customizer in editor config or desktop event + me.configPlugins.UIplugins = arrUI; + + if ( !uiCustomize && pluginStore) + { + arr = pluginStore.models.concat(arr); + arr.sort(function(a, b){ + var rank_a = a.get('groupRank'), + rank_b = b.get('groupRank'); + if (rank_a < rank_b) + return (rank_a==0) ? 1 : -1; + if (rank_a > rank_b) + return (rank_b==0) ? -1 : 1; + return 0; + }); + pluginStore.reset(arr); + this.appOptions.canPlugins = !pluginStore.isEmpty(); + } + } + else if (!uiCustomize){ + this.appOptions.canPlugins = false; + } + + if (!uiCustomize) + this.getApplication().getController('LeftMenu').enablePlugins(); + + if (this.appOptions.canPlugins) { + this.refreshPluginsList(); + this.runAutoStartPlugins(); + } + }, + + getPlugins: function(pluginsData, fetchFunction) { + if (!pluginsData || pluginsData.length<1) + return Promise.resolve([]); + + fetchFunction = fetchFunction || function (url) { + return fetch(url) + .then(function(response) { + if ( response.ok ) return response.json(); + else return Promise.reject(url); + }).then(function(json) { + json.baseUrl = url.substring(0, url.lastIndexOf("config.json")); + return json; + }); + }; + + var loaded = []; + return pluginsData.map(fetchFunction).reduce(function (previousPromise, currentPromise) { + return previousPromise + .then(function() + { + return currentPromise; + }) + .then(function(item) + { + loaded.push(item); + return Promise.resolve(item); + }) + .catch(function(item) + { + return Promise.resolve(item); + }); + + }, Promise.resolve()) + .then(function () + { + return Promise.resolve(loaded); + }); + }, + + mergePlugins: function() { + if (this.serverPlugins.plugins !== undefined && this.configPlugins.plugins !== undefined) { // undefined - plugins are loading + var autostart = [], + arr = [], + plugins = this.configPlugins, + warn = false; + if (plugins.plugins && plugins.plugins.length>0) { + arr = plugins.plugins; + var val = plugins.config.autostart || plugins.config.autoStartGuid; + if (typeof (val) == 'string') + val = [val]; + warn = !!plugins.config.autoStartGuid; + autostart = val || []; + } + plugins = this.serverPlugins; + if (plugins.plugins && plugins.plugins.length>0) { + arr = arr.concat(plugins.plugins); + var val = plugins.config.autostart || plugins.config.autoStartGuid; + if (typeof (val) == 'string') + val = [val]; + (warn || plugins.config.autoStartGuid) && console.warn("Obsolete: The autoStartGuid parameter is deprecated. Please check the documentation for new plugin connection configuration."); + autostart = autostart.concat(val || []); + } + this.autostart = autostart; + this.parsePlugins(arr, false); + } + }, + + getAppCustomPlugins: function (plugins) { + var me = this, + funcComplete = function() {me.customPluginsComplete = true;}; + if ( plugins.config ) { + this.getPlugins(plugins.config.UIpluginsData) + .then(function(loaded) + { + me.parsePlugins(loaded, true); + me.getPlugins(plugins.UIplugins, function(item) { + return fetch(item.url) + .then(function(response) { + if ( response.ok ) return response.text(); + else return Promise.reject(); + }) + .then(function(text) { + item.code = text; + return text; + }); + }).then(funcComplete, funcComplete); + }, funcComplete); + } else + funcComplete(); + } }, Common.Controllers.Plugins || {})); }); diff --git a/apps/common/main/lib/controller/Protection.js b/apps/common/main/lib/controller/Protection.js index 145dad9ad..d7a45c1c6 100644 --- a/apps/common/main/lib/controller/Protection.js +++ b/apps/common/main/lib/controller/Protection.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -87,14 +87,13 @@ define([ if (api) { this.api = api; - if (this.appConfig.isDesktopApp && this.appConfig.isOffline) { + if (this.appConfig.isPasswordSupport) this.api.asc_registerCallback('asc_onDocumentPassword', _.bind(this.onDocumentPassword, this)); - if (this.appConfig.canProtect) { - Common.NotificationCenter.on('protect:sign', _.bind(this.onSignatureRequest, this)); - Common.NotificationCenter.on('protect:signature', _.bind(this.onSignatureClick, this)); - this.api.asc_registerCallback('asc_onSignatureClick', _.bind(this.onSignatureSign, this)); - this.api.asc_registerCallback('asc_onUpdateSignatures', _.bind(this.onApiUpdateSignatures, this)); - } + if (this.appConfig.isSignatureSupport) { + Common.NotificationCenter.on('protect:sign', _.bind(this.onSignatureRequest, this)); + Common.NotificationCenter.on('protect:signature', _.bind(this.onSignatureClick, this)); + this.api.asc_registerCallback('asc_onSignatureClick', _.bind(this.onSignatureSign, this)); + this.api.asc_registerCallback('asc_onUpdateSignatures', _.bind(this.onApiUpdateSignatures, this)); } this.api.asc_registerCallback('asc_onCoAuthoringDisconnect',_.bind(this.onCoAuthoringDisconnect, this)); } diff --git a/apps/common/main/lib/controller/ReviewChanges.js b/apps/common/main/lib/controller/ReviewChanges.js index d0bf1aefb..e291dc5c0 100644 --- a/apps/common/main/lib/controller/ReviewChanges.js +++ b/apps/common/main/lib/controller/ReviewChanges.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -86,7 +86,8 @@ define([ 'Common.Views.ReviewPopover': { 'reviewchange:accept': _.bind(this.onAcceptClick, this), 'reviewchange:reject': _.bind(this.onRejectClick, this), - 'reviewchange:delete': _.bind(this.onDeleteClick, this) + 'reviewchange:delete': _.bind(this.onDeleteClick, this), + 'reviewchange:goto': _.bind(this.onGotoClick, this) } }); }, @@ -108,6 +109,7 @@ define([ this.setApi(api); if (data) { + this.currentUserId = data.config.user.id; this.sdkViewName = data['sdkviewname'] || this.sdkViewName; } }, @@ -115,7 +117,7 @@ define([ if (api) { this.api = api; - if (this.appConfig.canReview) { + if (this.appConfig.canReview || this.appConfig.canViewReview) { this.api.asc_registerCallback('asc_onShowRevisionsChange', _.bind(this.onApiShowChange, this)); this.api.asc_registerCallback('asc_onUpdateRevisionsChangesPosition', _.bind(this.onApiUpdateChangePosition, this)); } @@ -135,6 +137,19 @@ define([ if (this.dlgChanges) this.dlgChanges.close(); this.view && this.view.SetDisabled(state, this.langs); + this.setPreviewMode(state); + }, + + setPreviewMode: function(mode) { //disable accept/reject in popover + if (this.viewmode === mode) return; + this.viewmode = mode; + if (mode) + this.prevcanReview = this.appConfig.canReview; + this.appConfig.canReview = (mode) ? false : this.prevcanReview; + var me = this; + this.popoverChanges && this.popoverChanges.each(function (model) { + model.set('hint', !me.appConfig.canReview); + }); }, onApiShowChange: function (sdkchange) { @@ -148,6 +163,7 @@ define([ lock = (sdkchange[0].get_LockUserId()!==null), lockUser = this.getUserName(sdkchange[0].get_LockUserId()); + this.getPopover().hideTips(); this.popoverChanges.reset(changes); if (animate) { @@ -157,7 +173,7 @@ define([ this.getPopover().showReview(animate, lock, lockUser); - if (!this.appConfig.isReviewOnly && this._state.lock !== lock) { + if (this.appConfig.canReview && !this.appConfig.isReviewOnly && this._state.lock !== lock) { this.view.btnAccept.setDisabled(lock==true); this.view.btnReject.setDisabled(lock==true); if (this.dlgChanges) { @@ -174,6 +190,7 @@ define([ this._state.posx = this._state.posy = -1000; this._state.changes_length = 0; this._state.popoverVisible = false; + this.getPopover().hideTips(); this.popoverChanges.reset(); this.getPopover().hideReview(); } @@ -207,7 +224,7 @@ define([ }, getPopover: function () { - if (this.appConfig.canReview && _.isUndefined(this.popover)) { + if ((this.appConfig.canReview || this.appConfig.canViewReview) && _.isUndefined(this.popover)) { this.popover = Common.Views.ReviewPopover.prototype.getPopover({ reviewStore : this.popoverChanges, renderTo : this.sdkViewName @@ -224,10 +241,11 @@ define([ _.each(data, function(item) { var changetext = '', proptext = '', value = item.get_Value(), + movetype = item.get_MoveType(), settings = false; switch (item.get_Type()) { case Asc.c_oAscRevisionsChangeType.TextAdd: - changetext = me.textInserted; + changetext = (movetype==Asc.c_oAscRevisionsMove.NoMove) ? me.textInserted : me.textParaMoveTo; if (typeof value == 'object') { _.each(value, function(obj) { if (typeof obj === 'string') @@ -254,7 +272,7 @@ define([ } break; case Asc.c_oAscRevisionsChangeType.TextRem: - changetext = me.textDeleted; + changetext = (movetype==Asc.c_oAscRevisionsMove.NoMove) ? me.textDeleted : (item.is_MovedDown() ? me.textParaMoveFromDown : me.textParaMoveFromUp); if (typeof value == 'object') { _.each(value, function(obj) { if (typeof obj === 'string') @@ -392,7 +410,15 @@ define([ changetext += ''; changetext += proptext; break; - + case Asc.c_oAscRevisionsChangeType.TablePr: + changetext = me.textTableChanged; + break; + case Asc.c_oAscRevisionsChangeType.RowsAdd: + changetext = me.textTableRowsAdd; + break; + case Asc.c_oAscRevisionsChangeType.RowsRem: + changetext = me.textTableRowsDel; + break; } var date = (item.get_DateTime() == '') ? new Date() : new Date(item.get_DateTime()), user = me.userCollection.findOriginalUser(item.get_UserId()), @@ -405,10 +431,13 @@ define([ changetext : changetext, id : Common.UI.getId(), lock : (item.get_LockUserId()!==null), - lockuser : item.get_LockUserId(), + lockuser : me.getUserName(item.get_LockUserId()), type : item.get_Type(), changedata : item, - scope : me.view + scope : me.view, + hint : !me.appConfig.canReview, + goto : (item.get_MoveType() == Asc.c_oAscRevisionsMove.MoveTo || item.get_MoveType() == Asc.c_oAscRevisionsMove.MoveFrom), + editable : (item.get_UserId() == me.currentUserId) }); arr.push(change); @@ -489,6 +518,13 @@ define([ Common.NotificationCenter.trigger('edit:complete', this.view); }, + onGotoClick: function(change) { + if (this.api) { + this.api.asc_FollowRevisionMove(change); + } + Common.NotificationCenter.trigger('edit:complete', this.view); + }, + onTurnPreview: function(state) { if ( this.appConfig.isReviewOnly ) { this.view.turnChanges(true); @@ -497,7 +533,7 @@ define([ state = (state == 'on'); this.api.asc_SetTrackRevisions(state); - Common.localStorage.setItem(this.view.appPrefix + "track-changes", state ? 1 : 0); + Common.localStorage.setItem(this.view.appPrefix + "track-changes-" + (this.appConfig.fileKey || ''), state ? 1 : 0); this.view.turnChanges(state); } @@ -509,21 +545,26 @@ define([ Common.localStorage.setItem(this.view.appPrefix + "settings-spellcheck", state ? 1 : 0); this.api.asc_setSpellCheck(state); - Common.Utils.InternalSettings.set("de-settings-spellcheck", state); + Common.Utils.InternalSettings.set(this.view.appPrefix + "settings-spellcheck", state); }, onReviewViewClick: function(menu, item, e) { + this.turnDisplayMode(item.value); + !this.appConfig.canReview && Common.localStorage.setItem(this.view.appPrefix + "review-mode", item.value); + Common.NotificationCenter.trigger('edit:complete', this.view); + }, + + turnDisplayMode: function(mode) { if (this.api) { - if (item.value === 'final') + if (mode === 'final') this.api.asc_BeginViewModeInReview(true); - else if (item.value === 'original') + else if (mode === 'original') this.api.asc_BeginViewModeInReview(false); else this.api.asc_EndViewModeInReview(); } - this.disableEditing(item.value !== 'markup'); - this._state.previewMode = (item.value !== 'markup'); - Common.NotificationCenter.trigger('edit:complete', this.view); + this.disableEditing(mode == 'final' || mode == 'original'); + this._state.previewMode = (mode == 'final' || mode == 'original'); }, isPreviewChangesMode: function() { @@ -561,29 +602,31 @@ define([ disableEditing: function(disable) { var app = this.getApplication(); - app.getController('RightMenu').getView('RightMenu').clearSelection(); app.getController('Toolbar').DisableToolbar(disable, false, true); - app.getController('RightMenu').SetDisabled(disable, false); - app.getController('Statusbar').getView('Statusbar').SetDisabled(disable); app.getController('DocumentHolder').getView().SetDisabled(disable); - app.getController('Navigation') && app.getController('Navigation').SetDisabled(disable); - app.getController('Common.Controllers.Plugins').getView('Common.Views.Plugins').disableControls(disable); - var leftMenu = app.getController('LeftMenu').leftMenu; - leftMenu.btnComments.setDisabled(disable); - if (disable) leftMenu.close(); + if (this.appConfig.canReview) { + app.getController('RightMenu').getView('RightMenu').clearSelection(); + app.getController('RightMenu').SetDisabled(disable, false); + app.getController('Statusbar').getView('Statusbar').SetDisabled(disable); + app.getController('Navigation') && app.getController('Navigation').SetDisabled(disable); + app.getController('Common.Controllers.Plugins').getView('Common.Views.Plugins').disableControls(disable); + } + var comments = app.getController('Common.Controllers.Comments'); if (comments) comments.setPreviewMode(disable); - leftMenu.getMenu('file').miProtect.setDisabled(disable); + var leftMenu = app.getController('LeftMenu'); + leftMenu.leftMenu.getMenu('file').getButton('protect').setDisabled(disable); + leftMenu.setPreviewMode(disable); if (this.view) { this.view.$el.find('.no-group-mask').css('opacity', 1); this.view.btnsDocLang && this.view.btnsDocLang.forEach(function(button) { if ( button ) { - button.setDisabled(disable || this.langs.length<1); + button.setDisabled(disable || !this.langs || this.langs.length<1); } }, this); } @@ -600,7 +643,7 @@ define([ onAppReady: function (config) { var me = this; - if ( me.view && Common.localStorage.getBool(me.view.appPrefix + "settings-spellcheck", true) ) + if ( me.view && Common.localStorage.getBool(me.view.appPrefix + "settings-spellcheck", !(config.customization && config.customization.spellcheck===false))) me.view.turnSpelling(true); if ( config.canReview ) { @@ -612,17 +655,9 @@ define([ me.api.asc_SetTrackRevisions(state); }; - if ( config.isReviewOnly ) { - me.api.asc_HaveRevisionsChanges() && me.view.markChanges(true); - - _setReviewStatus(true); - } else - if ( !me.api.asc_IsTrackRevisions() ) { - _setReviewStatus(false); - } else { - me.api.asc_HaveRevisionsChanges() && me.view.markChanges(true); - _setReviewStatus(Common.localStorage.getBool(me.view.appPrefix + "track-changes")); - } + var state = config.isReviewOnly || Common.localStorage.getBool(me.view.appPrefix + "track-changes-" + (config.fileKey || '')); + me.api.asc_HaveRevisionsChanges() && me.view.markChanges(true); + _setReviewStatus(state); if ( typeof (me.appConfig.customization) == 'object' && (me.appConfig.customization.showReviewChanges==true) ) { me.dlgChanges = (new Common.Views.ReviewChangesDialog({ @@ -634,6 +669,15 @@ define([ me.dlgChanges.show(Math.max(10, offset.left + sdk.width() - 300), Math.max(10, offset.top + sdk.height() - 150)); } }); + } else if (config.canViewReview) { + config.canViewReview = (config.isEdit || me.api.asc_HaveRevisionsChanges(true)); // check revisions from all users + if (config.canViewReview) { + var val = Common.localStorage.getItem(me.view.appPrefix + "review-mode"); + if (val===null) + val = me.appConfig.customization && /^(original|final|markup)$/i.test(me.appConfig.customization.reviewDisplay) ? me.appConfig.customization.reviewDisplay.toLocaleLowerCase() : 'original'; + me.turnDisplayMode((config.isEdit || config.isRestrictedEdit) ? 'markup' : val); // load display mode only in viewer + me.view.turnDisplayMode((config.isEdit || config.isRestrictedEdit) ? 'markup' : val); + } } if (me.view && me.view.btnChat) { @@ -666,21 +710,13 @@ define([ }, onDocLanguage: function() { - var langs = _.map(this.langs, function(item){ - return { - displayValue: item.title, - value: item.tip, - code: item.code - } - }); - var me = this; (new Common.Views.LanguageDialog({ - languages: langs, + languages: me.langs, current: me.api.asc_getDefaultLanguage(), - handler: function(result, tip) { + handler: function(result, value) { if (result=='ok') { - var record = _.findWhere(langs, {'value':tip}); + var record = _.findWhere(me.langs, {'value':value}); record && me.api.asc_setDefaultLanguage(record.code); } } @@ -755,7 +791,12 @@ define([ textEquation: 'Equation', textImage: 'Image', textChart: 'Chart', - textShape: 'Shape' - + textShape: 'Shape', + textTableChanged: 'Table Settings Changed', + textTableRowsAdd: 'Table Rows Added', + textTableRowsDel: 'Table Rows Deleted', + textParaMoveTo: 'Moved:', + textParaMoveFromUp: 'Moved Up:', + textParaMoveFromDown: 'Moved Down:' }, Common.Controllers.ReviewChanges || {})); }); \ No newline at end of file diff --git a/apps/common/main/lib/core/NotificationCenter.js b/apps/common/main/lib/core/NotificationCenter.js index 20d733284..4415acffd 100644 --- a/apps/common/main/lib/core/NotificationCenter.js +++ b/apps/common/main/lib/core/NotificationCenter.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under diff --git a/apps/common/main/lib/extend/Bootstrap.js b/apps/common/main/lib/extend/Bootstrap.js index 4ae829c2d..b7d4a582f 100755 --- a/apps/common/main/lib/extend/Bootstrap.js +++ b/apps/common/main/lib/extend/Bootstrap.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -41,8 +41,8 @@ function onDropDownKeyDown(e) { var $this = $(this), $parent = $this.parent(), - beforeEvent = jQuery.Event('keydown.before.bs.dropdown'), - afterEvent = jQuery.Event('keydown.after.bs.dropdown'); + beforeEvent = jQuery.Event('keydown.before.bs.dropdown', {keyCode: e.keyCode}), + afterEvent = jQuery.Event('keydown.after.bs.dropdown', {keyCode: e.keyCode}); $parent.trigger(beforeEvent); @@ -111,17 +111,9 @@ function patchDropDownKeyDown(e) { var mnu = $('> [role=menu]', li), $subitems = mnu.find('> li:not(.divider):not(.disabled):visible > a'), $dataviews = mnu.find('> li:not(.divider):not(.disabled):visible .dataview'), - focusIdx = 0; - if (mnu.find('> .menu-scroll').length>0) { - var offset = mnu.scrollTop(); - for (var i=0; i<$subitems.length; i++) { - if ($subitems[i].offsetTop > offset) { - focusIdx = i; break; - } - } - } - if ($subitems.length>0 && $dataviews.length<1) - $subitems.eq(focusIdx).focus(); + $internal_menu = mnu.find('> li:not(.divider):not(.disabled):visible ul.internal-menu'); + if ($subitems.length>0 && $dataviews.length<1 && $internal_menu.length<1) + ($subitems.index($subitems.filter(':focus'))<0) && $subitems.eq(0).focus(); }, 250); } } else if (e.keyCode == 37) { // left @@ -165,13 +157,25 @@ function patchDropDownKeyDownAdditional(e) { // only for formula menu when typin if (!$items.length) return; - var index = $items.index($items.filter('.focus')); + var index = $items.index($items.filter('.focus')), + previndex = index; if (e.keyCode == 38) { index > 0 ? index-- : ($this.hasClass('no-cyclic') ? (index = 0) : (index = $items.length - 1));} else // up if (e.keyCode == 40) { index < $items.length - 1 ? index++ : ($this.hasClass('no-cyclic') ? (index = $items.length - 1) : (index = 0));} // down if (!~index) index=0; $items.removeClass('focus'); $items.eq(index).addClass('focus'); + + if (previndex !== index) { + var tip = $items.eq(previndex).parent().data('bs.tooltip'); + if (tip) { + tip.hide(); + } + tip = $items.eq(index).parent().data('bs.tooltip'); + if (tip) { + tip.show(); + } + } } function getParent($this) { diff --git a/apps/common/main/lib/model/ChatMessage.js b/apps/common/main/lib/model/ChatMessage.js index 941947f12..cff5fda7d 100644 --- a/apps/common/main/lib/model/ChatMessage.js +++ b/apps/common/main/lib/model/ChatMessage.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under diff --git a/apps/common/main/lib/model/Comment.js b/apps/common/main/lib/model/Comment.js index 6fea9f6e1..776de9c22 100644 --- a/apps/common/main/lib/model/Comment.js +++ b/apps/common/main/lib/model/Comment.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -53,6 +53,7 @@ define([ Common.Models.Comment = Backbone.Model.extend({ defaults: { uid : 0, // asc + guid : '', userid : 0, username : 'Guest', usercolor : null, diff --git a/apps/common/main/lib/model/Font.js b/apps/common/main/lib/model/Font.js index 818829ffc..563c406aa 100644 --- a/apps/common/main/lib/model/Font.js +++ b/apps/common/main/lib/model/Font.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under diff --git a/apps/common/main/lib/model/HistoryVersion.js b/apps/common/main/lib/model/HistoryVersion.js index f6ef20c46..5c4341806 100644 --- a/apps/common/main/lib/model/HistoryVersion.js +++ b/apps/common/main/lib/model/HistoryVersion.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under diff --git a/apps/common/main/lib/model/Plugin.js b/apps/common/main/lib/model/Plugin.js index 6456647d1..9de8d7ea8 100644 --- a/apps/common/main/lib/model/Plugin.js +++ b/apps/common/main/lib/model/Plugin.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -55,7 +55,9 @@ define([ url: "", index: 0, icons: undefined, + isSystem: false, isViewer: false, + isDisplayedInViewer: true, EditorsSupport: ["word", "cell", "slide"], isVisual: false, isCustomWindow: false, diff --git a/apps/common/main/lib/model/ReviewChange.js b/apps/common/main/lib/model/ReviewChange.js index b9c55ec3f..f31939279 100644 --- a/apps/common/main/lib/model/ReviewChange.js +++ b/apps/common/main/lib/model/ReviewChange.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -62,7 +62,8 @@ define([ lockuser : '', type : 0, changedata : null, - + hint : false, + editable : false, id : Common.UI.getId(), // internal scope : null } diff --git a/apps/common/main/lib/model/User.js b/apps/common/main/lib/model/User.js index cf7ba46fc..6f71c3de8 100644 --- a/apps/common/main/lib/model/User.js +++ b/apps/common/main/lib/model/User.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under diff --git a/apps/common/main/lib/mods/perfect-scrollbar-patch-x-margins.diff b/apps/common/main/lib/mods/perfect-scrollbar-patch-x-margins.diff new file mode 100644 index 000000000..628d58055 --- /dev/null +++ b/apps/common/main/lib/mods/perfect-scrollbar-patch-x-margins.diff @@ -0,0 +1,89 @@ +From d16a11fb136ef9ff06d20810e56e4a944173c977 Mon Sep 17 00:00:00 2001 +From: Julia Radzhabova +Date: Fri, 19 Apr 2019 17:54:45 +0300 +Subject: [PATCH] [Common] perfect-scrollbar: set width and position for + scrollbarXRail based on margins. + +--- + apps/common/main/lib/mods/perfect-scrollbar.js | 18 ++++++++++-------- + 1 file changed, 10 insertions(+), 8 deletions(-) + +diff --git a/apps/common/main/lib/mods/perfect-scrollbar.js b/apps/common/main/lib/mods/perfect-scrollbar.js +index 9b6f650..778009d 100644 +--- a/apps/common/main/lib/mods/perfect-scrollbar.js ++++ b/apps/common/main/lib/mods/perfect-scrollbar.js +@@ -95,6 +95,7 @@ + scrollbarXWidth, + scrollbarXLeft, + scrollbarXBottom = parseInt($scrollbarXRail.css('bottom'), 10), ++ scrollbarXRailWidth, + scrollbarYHeight, + scrollbarYTop, + scrollbarYRight = parseInt($scrollbarYRail.css('right'), 10), +@@ -122,7 +123,7 @@ + + var updateContentScrollLeft = function (currentLeft, deltaX) { + var newLeft = currentLeft + deltaX, +- maxLeft = containerWidth - scrollbarXWidth; ++ maxLeft = scrollbarXRailWidth - scrollbarXWidth; + + if (newLeft < 0) { + scrollbarXLeft = 0; +@@ -134,7 +135,7 @@ + scrollbarXLeft = newLeft; + } + +- var scrollLeft = parseInt(scrollbarXLeft * (contentWidth - containerWidth) / (containerWidth - scrollbarXWidth), 10); ++ var scrollLeft = parseInt(scrollbarXLeft * (contentWidth - containerWidth) / (scrollbarXRailWidth - scrollbarXWidth), 10); + $this.scrollLeft(scrollLeft); + $scrollbarYRail.css({right: scrollbarYRight - scrollLeft}); + }; +@@ -147,7 +148,7 @@ + }; + + var updateScrollbarCss = function () { +- $scrollbarXRail.css({left: $this.scrollLeft(), bottom: scrollbarXBottom - $this.scrollTop(), width: containerWidth, display: scrollbarXActive ? "inherit": "none"}); ++ $scrollbarXRail.css({left: $this.scrollLeft(), bottom: scrollbarXBottom - $this.scrollTop(), width: scrollbarXRailWidth, display: scrollbarXActive ? "inherit": "none"}); + + if ($scrollbarYRail.hasClass('in-scrolling')) + $scrollbarYRail.css({/*top: $this.scrollTop(),*/ right: scrollbarYRight - $this.scrollLeft(), height: scrollbarYRailHeight, display: scrollbarYActive ? "inherit": "none"}); +@@ -162,13 +163,14 @@ + containerWidth = settings.includePadding ? $this.innerWidth() : $this.width(); + containerHeight = settings.includePadding ? $this.innerHeight() : $this.height(); + scrollbarYRailHeight = containerHeight - (settings.includeMargin ? (parseInt($scrollbarYRail.css('margin-top')) + parseInt($scrollbarYRail.css('margin-bottom'))): 0); ++ scrollbarXRailWidth = containerWidth - (settings.includeMargin ? (parseInt($scrollbarXRail.css('margin-left')) + parseInt($scrollbarXRail.css('margin-right'))): 0); + contentWidth = $this.prop('scrollWidth'); + contentHeight = $this.prop('scrollHeight'); + + if (!settings.suppressScrollX && containerWidth + settings.scrollXMarginOffset < contentWidth) { + scrollbarXActive = true; +- scrollbarXWidth = getSettingsAdjustedThumbSize(parseInt(containerWidth * containerWidth / contentWidth, 10)); +- scrollbarXLeft = parseInt($this.scrollLeft() * (containerWidth - scrollbarXWidth) / (contentWidth - containerWidth), 10); ++ scrollbarXWidth = getSettingsAdjustedThumbSize(parseInt(scrollbarXRailWidth * containerWidth / contentWidth, 10)); ++ scrollbarXLeft = parseInt($this.scrollLeft() * (scrollbarXRailWidth - scrollbarXWidth) / (contentWidth - containerWidth), 10); + } + else { + scrollbarXActive = false; +@@ -192,8 +194,8 @@ + if (scrollbarYTop >= scrollbarYRailHeight - scrollbarYHeight) { + scrollbarYTop = scrollbarYRailHeight - scrollbarYHeight; + } +- if (scrollbarXLeft >= containerWidth - scrollbarXWidth) { +- scrollbarXLeft = containerWidth - scrollbarXWidth; ++ if (scrollbarXLeft >= scrollbarXRailWidth - scrollbarXWidth) { ++ scrollbarXLeft = scrollbarXRailWidth - scrollbarXWidth; + } + + updateScrollbarCss(); +@@ -461,7 +463,7 @@ + $scrollbarXRail.bind('click' + eventClassName, function (e) { + var halfOfScrollbarLength = parseInt(scrollbarXWidth / 2, 10), + positionLeft = e.pageX - $scrollbarXRail.offset().left - halfOfScrollbarLength, +- maxPositionLeft = containerWidth - scrollbarXWidth, ++ maxPositionLeft = scrollbarXRailWidth - scrollbarXWidth, + positionRatio = positionLeft / maxPositionLeft; + + if (positionRatio < 0) { +-- +2.6.1.windows.1 + diff --git a/apps/common/main/lib/mods/perfect-scrollbar.js b/apps/common/main/lib/mods/perfect-scrollbar.js index 9b6f650db..778009db9 100644 --- a/apps/common/main/lib/mods/perfect-scrollbar.js +++ b/apps/common/main/lib/mods/perfect-scrollbar.js @@ -95,6 +95,7 @@ scrollbarXWidth, scrollbarXLeft, scrollbarXBottom = parseInt($scrollbarXRail.css('bottom'), 10), + scrollbarXRailWidth, scrollbarYHeight, scrollbarYTop, scrollbarYRight = parseInt($scrollbarYRail.css('right'), 10), @@ -122,7 +123,7 @@ var updateContentScrollLeft = function (currentLeft, deltaX) { var newLeft = currentLeft + deltaX, - maxLeft = containerWidth - scrollbarXWidth; + maxLeft = scrollbarXRailWidth - scrollbarXWidth; if (newLeft < 0) { scrollbarXLeft = 0; @@ -134,7 +135,7 @@ scrollbarXLeft = newLeft; } - var scrollLeft = parseInt(scrollbarXLeft * (contentWidth - containerWidth) / (containerWidth - scrollbarXWidth), 10); + var scrollLeft = parseInt(scrollbarXLeft * (contentWidth - containerWidth) / (scrollbarXRailWidth - scrollbarXWidth), 10); $this.scrollLeft(scrollLeft); $scrollbarYRail.css({right: scrollbarYRight - scrollLeft}); }; @@ -147,7 +148,7 @@ }; var updateScrollbarCss = function () { - $scrollbarXRail.css({left: $this.scrollLeft(), bottom: scrollbarXBottom - $this.scrollTop(), width: containerWidth, display: scrollbarXActive ? "inherit": "none"}); + $scrollbarXRail.css({left: $this.scrollLeft(), bottom: scrollbarXBottom - $this.scrollTop(), width: scrollbarXRailWidth, display: scrollbarXActive ? "inherit": "none"}); if ($scrollbarYRail.hasClass('in-scrolling')) $scrollbarYRail.css({/*top: $this.scrollTop(),*/ right: scrollbarYRight - $this.scrollLeft(), height: scrollbarYRailHeight, display: scrollbarYActive ? "inherit": "none"}); @@ -162,13 +163,14 @@ containerWidth = settings.includePadding ? $this.innerWidth() : $this.width(); containerHeight = settings.includePadding ? $this.innerHeight() : $this.height(); scrollbarYRailHeight = containerHeight - (settings.includeMargin ? (parseInt($scrollbarYRail.css('margin-top')) + parseInt($scrollbarYRail.css('margin-bottom'))): 0); + scrollbarXRailWidth = containerWidth - (settings.includeMargin ? (parseInt($scrollbarXRail.css('margin-left')) + parseInt($scrollbarXRail.css('margin-right'))): 0); contentWidth = $this.prop('scrollWidth'); contentHeight = $this.prop('scrollHeight'); if (!settings.suppressScrollX && containerWidth + settings.scrollXMarginOffset < contentWidth) { scrollbarXActive = true; - scrollbarXWidth = getSettingsAdjustedThumbSize(parseInt(containerWidth * containerWidth / contentWidth, 10)); - scrollbarXLeft = parseInt($this.scrollLeft() * (containerWidth - scrollbarXWidth) / (contentWidth - containerWidth), 10); + scrollbarXWidth = getSettingsAdjustedThumbSize(parseInt(scrollbarXRailWidth * containerWidth / contentWidth, 10)); + scrollbarXLeft = parseInt($this.scrollLeft() * (scrollbarXRailWidth - scrollbarXWidth) / (contentWidth - containerWidth), 10); } else { scrollbarXActive = false; @@ -192,8 +194,8 @@ if (scrollbarYTop >= scrollbarYRailHeight - scrollbarYHeight) { scrollbarYTop = scrollbarYRailHeight - scrollbarYHeight; } - if (scrollbarXLeft >= containerWidth - scrollbarXWidth) { - scrollbarXLeft = containerWidth - scrollbarXWidth; + if (scrollbarXLeft >= scrollbarXRailWidth - scrollbarXWidth) { + scrollbarXLeft = scrollbarXRailWidth - scrollbarXWidth; } updateScrollbarCss(); @@ -461,7 +463,7 @@ $scrollbarXRail.bind('click' + eventClassName, function (e) { var halfOfScrollbarLength = parseInt(scrollbarXWidth / 2, 10), positionLeft = e.pageX - $scrollbarXRail.offset().left - halfOfScrollbarLength, - maxPositionLeft = containerWidth - scrollbarXWidth, + maxPositionLeft = scrollbarXRailWidth - scrollbarXWidth, positionRatio = positionLeft / maxPositionLeft; if (positionRatio < 0) { diff --git a/apps/common/main/lib/template/Comments.template b/apps/common/main/lib/template/Comments.template index 3899e288c..8fac3d9ad 100644 --- a/apps/common/main/lib/template/Comments.template +++ b/apps/common/main/lib/template/Comments.template @@ -10,7 +10,7 @@ <% if (quote!==null && quote!=='') { %>
<%=scope.getFixedQuote(quote)%>
<% } %> - <% if (!editText) { %> + <% if (!editText || scope.viewmode) { %>
<%=scope.pickLink(comment)%>
<% } else { %>
@@ -24,20 +24,22 @@ <% if (replys.length) { %>
- <% _.each(replys, function (item) { %> -
+ <% _.each(replys, function (item, index) { %> +
style="padding-bottom: 0;" <% } %>;>
<%=item.get("usercolor")%><% } else { %> #cfcfcf <% } %>; " >
<%= scope.getUserName(item.get("username")) %>
<%=item.get("date")%>
<% if (!item.get("editText")) { %>
<%=scope.pickLink(item.get("reply"))%>
+ <% if (!scope.viewmode) { %>
<% if (item.get("editable")) { %>
">
+
">
<% } %> -
">
-
+
+ <%}%> <% } else { %>
@@ -51,7 +53,7 @@ - <% if (!showReply) { %> + <% if (!showReply && !scope.viewmode) { %> <% if (replys.length) { %> <% } else { %> @@ -61,12 +63,12 @@ - <% if (!editText && !lock) { %> + <% if (!editText && !lock && !scope.viewmode) { %>
<% if (editable) { %>
+
<% } %> -
<% if (resolved) { %>
<% } else { %> diff --git a/apps/common/main/lib/template/CommentsPopover.template b/apps/common/main/lib/template/CommentsPopover.template index 7eb3b8933..78f0d4a5a 100644 --- a/apps/common/main/lib/template/CommentsPopover.template +++ b/apps/common/main/lib/template/CommentsPopover.template @@ -10,7 +10,7 @@
<%=scope.pickLink(comment)%>
<% } else { %>
- + <% if (hideAddReply) { %> <% } else { %> @@ -36,13 +36,13 @@
<% if (item.get("editable")) { %>
">
+
">
<%}%> -
">
<%}%> <% } else { %>
- +
@@ -68,8 +68,8 @@
<% if (editable) { %>
+
<% } %> -
<% if (resolved) { %>
<% } else { %> @@ -82,7 +82,7 @@ <% if (showReplyInPopover) { %>
- +
diff --git a/apps/common/main/lib/template/ReviewChangesPopover.template b/apps/common/main/lib/template/ReviewChangesPopover.template index e3b12c32b..0f6ed8e70 100644 --- a/apps/common/main/lib/template/ReviewChangesPopover.template +++ b/apps/common/main/lib/template/ReviewChangesPopover.template @@ -5,11 +5,22 @@
<%=date%>
<%=changetext%>
- <% if (scope.appConfig.isReviewOnly) { %> -
- <% } else { %> -
-
+ <% if (goto) { %> +
+ <% } %> + <% if (!hint) { %> + <% if (scope.appConfig.isReviewOnly) { %> + <% if (editable) { %> +
+ <% } %> + <% } else { %> +
+
+ <% } %> <% } %>
+ <% if (!hint && lock) { %> +
+
<%=lockuser%>
+ <% } %>
\ No newline at end of file diff --git a/apps/common/main/lib/util/LanguageInfo.js b/apps/common/main/lib/util/LanguageInfo.js index 6c2917964..b672b15c6 100644 --- a/apps/common/main/lib/util/LanguageInfo.js +++ b/apps/common/main/lib/util/LanguageInfo.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -45,399 +45,401 @@ if (Common === undefined) { Common.util = Common.util||{}; Common.util.LanguageInfo = new(function() { - var localLanguageName = { + var localLanguageName = { // code: [short-name, native-name, english-name] - fill 3 field when need to add language to editor interface 0x0036 : ["af", "Afrikaans"], - 0x0436 : ["af-ZA", "Afrikaans (Suid Afrika)"], + 0x0436 : ["af-ZA", "Afrikaans (Suid Afrika)", "Afrikaans (South Africa)"], 0x001C : ["sq", "Shqipe"], - 0x041C : ["sq-AL", "Shqipe (Shqipëria)"], + 0x041C : ["sq-AL", "Shqipe (Shqipëria)", "Albanian (Albania)"], 0x0084 : ["gsw", "Elsässisch"], - 0x0484 : ["gsw-FR", "Elsässisch (Frànkrisch)"], + 0x0484 : ["gsw-FR", "Elsässisch (Frànkrisch)", "Alsatian (France)"], 0x005E : ["am", "አማርኛ"], - 0x045E : ["am-ET", "አማርኛ (ኢትዮጵያ)"], + 0x045E : ["am-ET", "አማርኛ (ኢትዮጵያ)", "Amharic (Ethiopia)"], 0x0001 : ["ar", "العربية‏"], - 0x1401 : ["ar-DZ", "العربية (الجزائر)‏"], - 0x3C01 : ["ar-BH", "العربية (البحرين)‏"], - 0x0C01 : ["ar-EG", "العربية (مصر)‏"], - 0x0801 : ["ar-IQ", "العربية (العراق)‏"], - 0x2C01 : ["ar-JO", "العربية (الأردن)‏"], - 0x3401 : ["ar-KW", "العربية (الكويت)‏"], - 0x3001 : ["ar-LB", "العربية (لبنان)‏"], - 0x1001 : ["ar-LY", "العربية (ليبيا)‏"], - 0x1801 : ["ar-MA", "العربية (المملكة المغربية)‏"], - 0x2001 : ["ar-OM", "العربية (عمان)‏"], - 0x4001 : ["ar-QA", "العربية (قطر)‏"], - 0x0401 : ["ar-SA", "العربية (المملكة العربية السعودية)‏"], - 0x2801 : ["ar-SY", "العربية (سوريا)‏"], - 0x1C01 : ["ar-TN", "العربية (تونس)‏"], - 0x3801 : ["ar-AE", "العربية (الإمارات العربية المتحدة)‏"], - 0x2401 : ["ar-YE", "العربية (اليمن)‏"], + 0x1401 : ["ar-DZ", "العربية (الجزائر)‏", "Arabic (Algeria)"], + 0x3C01 : ["ar-BH", "العربية (البحرين)‏", "Arabic (Bahrain)"], + 0x0C01 : ["ar-EG", "العربية (مصر)‏", "Arabic (Egypt)"], + 0x0801 : ["ar-IQ", "العربية (العراق)‏", "Arabic (Iraq)"], + 0x2C01 : ["ar-JO", "العربية (الأردن)‏", "Arabic (Jordan)"], + 0x3401 : ["ar-KW", "العربية (الكويت)‏", "Arabic (Kuwait)"], + 0x3001 : ["ar-LB", "العربية (لبنان)‏", "Arabic (Lebanon)"], + 0x1001 : ["ar-LY", "العربية (ليبيا)‏", "Arabic (Libya)"], + 0x1801 : ["ar-MA", "العربية (المملكة المغربية)‏", "Arabic (Morocco)"], + 0x2001 : ["ar-OM", "العربية (عمان)‏", "Arabic (Oman)"], + 0x4001 : ["ar-QA", "العربية (قطر)‏", "Arabic (Qatar)"], + 0x0401 : ["ar-SA", "العربية (المملكة العربية السعودية)‏", "Arabic (Saudi Arabia)"], + 0x2801 : ["ar-SY", "العربية (سوريا)‏", "Arabic (Syria)"], + 0x1C01 : ["ar-TN", "العربية (تونس)‏", "Arabic (Tunisia)"], + 0x3801 : ["ar-AE", "العربية (الإمارات العربية المتحدة)‏", "Arabic (U.A.E.)"], + 0x2401 : ["ar-YE", "العربية (اليمن)‏", "Arabic (Yemen)"], 0x002B : ["hy", "Հայերեն"], - 0x042B : ["hy-AM", "Հայերեն (Հայաստան)"], + 0x042B : ["hy-AM", "Հայերեն (Հայաստան)", "Armenian (Armenia)"], 0x004D : ["as", "অসমীয়া"], - 0x044D : ["as-IN", "অসমীয়া (ভাৰত)"], + 0x044D : ["as-IN", "অসমীয়া (ভাৰত)", "Assamese (India)"], 0x002C : ["az", "Azərbaycan­ılı"], 0x742C : ["az-Cyrl", "Азәрбајҹан дили"], - 0x082C : ["az-Cyrl-AZ", "Азәрбајҹан (Азәрбајҹан)"], + 0x082C : ["az-Cyrl-AZ", "Азәрбајҹан (Азәрбајҹан)", "Azeri (Cyrillic, Azerbaijan)"], 0x782C : ["az-Latn", "Azərbaycan­ılı"], - 0x042C : ["az-Latn-AZ", "Azərbaycan­ılı (Azərbaycan)"], + 0x042C : ["az-Latn-AZ", "Azərbaycan­ılı (Azərbaycan)", "Azeri (Latin, Azerbaijan)"], 0x006D : ["ba", "Башҡорт"], - 0x046D : ["ba-RU", "Башҡорт (Россия)"], + 0x046D : ["ba-RU", "Башҡорт (Россия)", "Bashkir (Russia)"], 0x002D : ["eu", "Euskara"], - 0x042D : ["eu-ES", "Euskara (Euskara)"], + 0x042D : ["eu-ES", "Euskara (Euskara)", "Basque (Basque)"], 0x0023 : ["be", "Беларускі"], - 0x0423 : ["be-BY", "Беларускі (Беларусь)"], + 0x0423 : ["be-BY", "Беларускі (Беларусь)", "Belarusian (Belarus)"], 0x0045 : ["bn", "বাংলা"], - 0x0845 : ["bn-BD", "বাংলা (বাংলাদেশ)"], - 0x0445 : ["bn-IN", "বাংলা (ভারত)"], + 0x0845 : ["bn-BD", "বাংলা (বাংলাদেশ)", "Bengali (Bangladesh)"], + 0x0445 : ["bn-IN", "বাংলা (ভারত)", "Bengali (India)"], 0x781A : ["bs", "bosanski"], 0x641A : ["bs-Cyrl", "Босански (Ћирилица)"], - 0x201A : ["bs-Cyrl-BA", "Босански (Босна и Херцеговина)"], + 0x201A : ["bs-Cyrl-BA", "Босански (Босна и Херцеговина)", "Bosnian (Cyrillic) (Bosnia and Herzegovina)"], 0x681A : ["bs-Latn", "Bosanski (Latinica)"], - 0x141A : ["bs-Latn-BA", "Bosanski (Bosna i Hercegovina)"], + 0x141A : ["bs-Latn-BA", "Bosanski (Bosna i Hercegovina)", "Bosnian (Latin) (Bosnia and Herzegovina)"], 0x007E : ["br", "Brezhoneg"], - 0x047E : ["br-FR", "Brezhoneg (Frañs)"], + 0x047E : ["br-FR", "Brezhoneg (Frañs)", "Breton (France)"], 0x0002 : ["bg", "Български"], - 0x0402 : ["bg-BG", "Български (България)"], + 0x0402 : ["bg-BG", "Български (България)", "Bulgarian (Bulgaria)"], 0x0003 : ["ca", "Català"], - 0x0403 : ["ca-ES", "Català (Català)"], - 0x0803 : ["ca-ES-valencia", "Català (Valencià)"], + 0x0403 : ["ca-ES", "Català (Català)", "Catalan (Catalan)"], + 0x0803 : ["ca-ES-valencia", "Català (Valencià)", "Catalan (Valencia)"], 0x7804 : ["zh", "中文"], - 0x0004 : ["zh-Hans", "中文(简体)"], - 0x0804 : ["zh-CN", "中文(中华人民共和国)"], - 0x1004 : ["zh-SG", "中文(新加坡)"], - 0x7C04 : ["zh-Hant", "中文(繁體)"], - 0x0C04 : ["zh-HK", "中文(香港特別行政區)"], - 0x1404 : ["zh-MO", "中文(澳門特別行政區)"], - 0x0404 : ["zh-TW", "中文(台灣)"], + 0x0004 : ["zh-Hans", "中文(简体)", "Chinese (Simplified)"], + 0x0804 : ["zh-CN", "中文(中华人民共和国)", "Chinese (People's Republic of China)"], + 0x1004 : ["zh-SG", "中文(新加坡)", "Chinese (Simplified, Singapore)"], + 0x7C04 : ["zh-Hant", "中文(繁體)", "Chinese (Traditional)"], + 0x0C04 : ["zh-HK", "中文(香港特別行政區)", "Chinese (Traditional, Hong Kong S.A.R.)"], + 0x1404 : ["zh-MO", "中文(澳門特別行政區)", "Chinese (Traditional, Macao S.A.R.)"], + 0x0404 : ["zh-TW", "中文(台灣)", "Chinese (Traditional, Taiwan)"], 0x0083 : ["co", "Corsu"], - 0x0483 : ["co-FR", "Corsu (France)"], + 0x0483 : ["co-FR", "Corsu (France)", "Corsican (France)"], 0x001A : ["hr", "Hrvatski"], - 0x041A : ["hr-HR", "Hrvatski (Hrvatska)"], - 0x101A : ["hr-BA", "Hrvatski (Bosna i Hercegovina)"], + 0x041A : ["hr-HR", "Hrvatski (Hrvatska)", "Croatian (Croatia)"], + 0x101A : ["hr-BA", "Hrvatski (Bosna i Hercegovina)", "Croatian (Bosnia and Herzegovina)"], 0x0005 : ["cs", "Čeština"], - 0x0405 : ["cs-CZ", "Čeština (Česká republika)"], + 0x0405 : ["cs-CZ", "Čeština (Česká republika)", "Czech (Czech Republic)"], 0x0006 : ["da", "Dansk"], - 0x0406 : ["da-DK", "Dansk (Danmark)"], + 0x0406 : ["da-DK", "Dansk (Danmark)", "Danish (Denmark)"], 0x008C : ["prs", "درى‏"], - 0x048C : ["prs-AF", "درى (افغانستان)‏"], + 0x048C : ["prs-AF", "درى (افغانستان)‏", "Dari (Afghanistan)"], 0x0065 : ["dv", "ދިވެހިބަސް‏"], - 0x0465 : ["dv-MV", "ދިވެހިބަސް (ދިވެހި ރާއްޖެ)‏"], + 0x0465 : ["dv-MV", "ދިވެހިބަސް (ދިވެހި ރާއްޖެ)‏", "Divehi (Maldives)"], 0x0013 : ["nl", "Nederlands"], - 0x0813 : ["nl-BE", "Nederlands (België)"], - 0x0413 : ["nl-NL", "Nederlands (Nederland)"], + 0x0813 : ["nl-BE", "Nederlands (België)", "Dutch (Belgium)"], + 0x0413 : ["nl-NL", "Nederlands (Nederland)", "Dutch (Netherlands)"], 0x0009 : ["en", "English"], - 0x0C09 : ["en-AU", "English (Australia)"], - 0x2809 : ["en-BZ", "English (Belize)"], - 0x1009 : ["en-CA", "English (Canada)"], - 0x2409 : ["en-029", "English (Caribbean)"], - 0x4009 : ["en-IN", "English (India)"], - 0x1809 : ["en-IE", "English (Ireland)"], - 0x2009 : ["en-JM", "English (Jamaica)"], - 0x4409 : ["en-MY", "English (Malaysia)"], - 0x1409 : ["en-NZ", "English (New Zealand)"], - 0x3409 : ["en-PH", "English (Philippines)"], - 0x4809 : ["en-SG", "English (Singapore)"], - 0x1C09 : ["en-ZA", "English (South Africa)"], - 0x2C09 : ["en-TT", "English (Trinidad y Tobago)"], - 0x0809 : ["en-GB", "English (United Kingdom)"], - 0x0409 : ["en-US", "English (United States)"], - 0x3009 : ["en-ZW", "English (Zimbabwe)"], - 0x3c09 : ["en-HK", "English (Hong Kong)"], - 0x3809 : ["en-ID", "English (Indonesia)"], + 0x0C09 : ["en-AU", "English (Australia)", "English (Australia)"], + 0x2809 : ["en-BZ", "English (Belize)", "English (Belize)"], + 0x1009 : ["en-CA", "English (Canada)", "English (Canada)"], + 0x2409 : ["en-029", "English (Caribbean)", "English (Caribbean)"], + 0x4009 : ["en-IN", "English (India)", "English (India)"], + 0x1809 : ["en-IE", "English (Ireland)", "English (Ireland)"], + 0x2009 : ["en-JM", "English (Jamaica)", "English (Jamaica)"], + 0x4409 : ["en-MY", "English (Malaysia)", "English (Malaysia)"], + 0x1409 : ["en-NZ", "English (New Zealand)", "English (New Zealand)"], + 0x3409 : ["en-PH", "English (Philippines)", "English (Philippines)"], + 0x4809 : ["en-SG", "English (Singapore)", "English (Singapore)"], + 0x1C09 : ["en-ZA", "English (South Africa)", "English (South Africa)"], + 0x2C09 : ["en-TT", "English (Trinidad y Tobago)", "English (Trinidad y Tobago)"], + 0x0809 : ["en-GB", "English (United Kingdom)", "English (United Kingdom)"], + 0x0409 : ["en-US", "English (United States)", "English (United States)"], + 0x3009 : ["en-ZW", "English (Zimbabwe)", "English (Zimbabwe)"], + 0x3c09 : ["en-HK", "English (Hong Kong)", "English (Hong Kong)"], + 0x3809 : ["en-ID", "English (Indonesia)", "English (Indonesia)"], 0x0025 : ["et", "Eesti"], - 0x0425 : ["et-EE", "Eesti (Eesti)"], + 0x0425 : ["et-EE", "Eesti (Eesti)", "Estonian (Estonia)"], 0x0038 : ["fo", "Føroyskt"], - 0x0438 : ["fo-FO", "Føroyskt (Føroyar)"], + 0x0438 : ["fo-FO", "Føroyskt (Føroyar)", "Faroese (Faroe Islands)"], 0x0064 : ["fil", "Filipino"], - 0x0464 : ["fil-PH", "Filipino (Pilipinas)"], + 0x0464 : ["fil-PH", "Filipino (Pilipinas)", "Filipino (Philippines)"], 0x000B : ["fi", "Suomi"], - 0x040B : ["fi-FI", "Suomi (Suomi)"], + 0x040B : ["fi-FI", "Suomi (Suomi)", "Finnish (Finland)"], 0x000C : ["fr", "Français"], - 0x080C : ["fr-BE", "Français (Belgique)"], - 0x0C0C : ["fr-CA", "Français (Canada)"], - 0x040C : ["fr-FR", "Français (France)"], - 0x140C : ["fr-LU", "Français (Luxembourg)"], - 0x180C : ["fr-MC", "Français (Principauté de Monaco)"], - 0x100C : ["fr-CH", "Français (Suisse)"], - 0x3c0c : ["fr-HT", "French (Haiti)"], - 0x240c : ["fr-CG", "French (Congo)"], - 0x300c : ["fr-CI", "French (Cote d'Ivoire)"], - 0x2c0c : ["fr-CM", "French (Cameroon)"], - 0x380c : ["fr-MA", "French (Morocco)"], - 0x340c : ["fr-ML", "French (Mali)"], - 0x200c : ["fr-RE", "French (Reunion)"], - 0x280c : ["fr-SN", "French (Senegal)"], + 0x080C : ["fr-BE", "Français (Belgique)", "French (Belgium)"], + 0x0C0C : ["fr-CA", "Français (Canada)", "French (Canada)"], + 0x040C : ["fr-FR", "Français (France)", "French (France)"], + 0x140C : ["fr-LU", "Français (Luxembourg)", "French (Luxembourg)"], + 0x180C : ["fr-MC", "Français (Principauté de Monaco)", "French (Principality of Monaco)"], + 0x100C : ["fr-CH", "Français (Suisse)", "French (Switzerland)"], + 0x3c0c : ["fr-HT", "Français (Haïti)", "French (Haiti)"], + 0x240c : ["fr-CG", "Français (Congo-Brazzaville)", "French (Congo)"], + 0x300c : ["fr-CI", "Français (Côte d’Ivoire)", "French (Cote d'Ivoire)"], + 0x2c0c : ["fr-CM", "Français (Cameroun)", "French (Cameroon)"], + 0x380c : ["fr-MA", "Français (Maroc)", "French (Morocco)"], + 0x340c : ["fr-ML", "Français (Mali)", "French (Mali)"], + 0x200c : ["fr-RE", "Français (La Réunion)", "French (Reunion)"], + 0x280c : ["fr-SN", "Français (Sénégal)", "French (Senegal)"], 0x1c0c : ["fr-West", "French"], 0x0062 : ["fy", "Frysk"], - 0x0462 : ["fy-NL", "Frysk (Nederlân)"], + 0x0462 : ["fy-NL", "Frysk (Nederlân)", "Frisian (Netherlands)"], 0x0056 : ["gl", "Galego"], - 0x0456 : ["gl-ES", "Galego (Galego)"], + 0x0456 : ["gl-ES", "Galego (Galego)", "Galician (Galician)"], 0x0037 : ["ka", "ქართული"], - 0x0437 : ["ka-GE", "ქართული (საქართველო)"], + 0x0437 : ["ka-GE", "ქართული (საქართველო)", "Georgian (Georgia)"], 0x0007 : ["de", "Deutsch"], - 0x0C07 : ["de-AT", "Deutsch (Österreich)"], - 0x0407 : ["de-DE", "Deutsch (Deutschland)"], - 0x1407 : ["de-LI", "Deutsch (Liechtenstein)"], - 0x1007 : ["de-LU", "Deutsch (Luxemburg)"], - 0x0807 : ["de-CH", "Deutsch (Schweiz)"], + 0x0C07 : ["de-AT", "Deutsch (Österreich)", "German (Austria)"], + 0x0407 : ["de-DE", "Deutsch (Deutschland)", "German (Germany)"], + 0x1407 : ["de-LI", "Deutsch (Liechtenstein)", "German (Liechtenstein)"], + 0x1007 : ["de-LU", "Deutsch (Luxemburg)", "German (Luxembourg)"], + 0x0807 : ["de-CH", "Deutsch (Schweiz)", "German (Switzerland)"], 0x0008 : ["el", "Ελληνικά"], - 0x0408 : ["el-GR", "Ελληνικά (Ελλάδα)"], + 0x0408 : ["el-GR", "Ελληνικά (Ελλάδα)", "Greek (Greece)"], 0x006F : ["kl", "Kalaallisut"], - 0x046F : ["kl-GL", "Kalaallisut (Kalaallit Nunaat)"], + 0x046F : ["kl-GL", "Kalaallisut (Kalaallit Nunaat)", "Greenlandic (Greenland)"], 0x0047 : ["gu", "ગુજરાતી"], - 0x0447 : ["gu-IN", "ગુજરાતી (ભારત)"], + 0x0447 : ["gu-IN", "ગુજરાતી (ભારત)", "Gujarati (India)"], 0x0068 : ["ha", "Hausa"], 0x7C68 : ["ha-Latn", "Hausa (Latin)"], - 0x0468 : ["ha-Latn-NG", "Hausa (Nigeria)"], + 0x0468 : ["ha-Latn-NG", "Hausa (Nigeria)", "Hausa (Latin) (Nigeria)"], 0x000D : ["he", "עברית‏"], - 0x040D : ["he-IL", "עברית (ישראל)‏"], + 0x040D : ["he-IL", "עברית (ישראל)‏", "Hebrew (Israel)"], 0x0039 : ["hi", "हिंदी"], - 0x0439 : ["hi-IN", "हिंदी (भारत)"], + 0x0439 : ["hi-IN", "हिंदी (भारत)", "Hindi (India)"], 0x000E : ["hu", "Magyar"], - 0x040E : ["hu-HU", "Magyar (Magyarország)"], + 0x040E : ["hu-HU", "Magyar (Magyarország)", "Hungarian (Hungary)"], 0x000F : ["is", "Íslenska"], - 0x040F : ["is-IS", "Íslenska (Ísland)"], + 0x040F : ["is-IS", "Íslenska (Ísland)", "Icelandic (Iceland)"], 0x0070 : ["ig", "Igbo"], - 0x0470 : ["ig-NG", "Igbo (Nigeria)"], + 0x0470 : ["ig-NG", "Igbo (Nigeria)", "Igbo (Nigeria)"], 0x0021 : ["id", "Bahasa Indonesia"], - 0x0421 : ["id-ID", "Bahasa Indonesia (Indonesia)"], + 0x0421 : ["id-ID", "Bahasa Indonesia (Indonesia)", "Indonesian (Indonesia)"], 0x005D : ["iu", "Inuktitut"], 0x7C5D : ["iu-Latn", "Inuktitut (Qaliujaaqpait)"], - 0x085D : ["iu-Latn-CA", "Inuktitut"], + 0x085D : ["iu-Latn-CA", "Inuktitut (Kanatami) (kanata)", "Inuktitut (Latin) (Canada)"], 0x785D : ["iu-Cans", "ᐃᓄᒃᑎᑐᑦ (ᖃᓂᐅᔮᖅᐸᐃᑦ)"], - 0x045D : ["iu-Cans-CA", "ᐃᓄᒃᑎᑐᑦ (ᑲᓇᑕᒥ)"], + 0x045D : ["iu-Cans-CA", "ᐃᓄᒃᑎᑐᑦ (ᑲᓇᑕᒥ)", "Inuktitut (Canada)"], 0x003C : ["ga", "Gaeilge"], - 0x083C : ["ga-IE", "Gaeilge (Éire)"], + 0x083C : ["ga-IE", "Gaeilge (Éire)", "Irish (Ireland)"], 0x0034 : ["xh", "isiXhosa"], - 0x0434 : ["xh-ZA", "isiXhosa (uMzantsi Afrika)"], + 0x0434 : ["xh-ZA", "isiXhosa (uMzantsi Afrika)", "isiXhosa (South Africa)"], 0x0035 : ["zu", "isiZulu"], - 0x0435 : ["zu-ZA", "isiZulu (iNingizimu Afrika)"], + 0x0435 : ["zu-ZA", "isiZulu (iNingizimu Afrika)", "isiZulu (South Africa)"], 0x0010 : ["it", "Italiano"], - 0x0410 : ["it-IT", "Italiano (Italia)"], - 0x0810 : ["it-CH", "Italiano (Svizzera)"], + 0x0410 : ["it-IT", "Italiano (Italia)", "Italian (Italy)"], + 0x0810 : ["it-CH", "Italiano (Svizzera)", "Italian (Switzerland)"], 0x0011 : ["ja", "日本語"], - 0x0411 : ["ja-JP", "日本語 (日本)"], + 0x0411 : ["ja-JP", "日本語 (日本)", "Japanese (Japan)"], 0x004B : ["kn", "ಕನ್ನಡ"], - 0x044B : ["kn-IN", "ಕನ್ನಡ (ಭಾರತ)"], + 0x044B : ["kn-IN", "ಕನ್ನಡ (ಭಾರತ)", "Kannada (India)"], 0x003F : ["kk", "Қазақ"], - 0x043F : ["kk-KZ", "Қазақ (Қазақстан)"], + 0x043F : ["kk-KZ", "Қазақ (Қазақстан)", "Kazakh (Kazakhstan)"], 0x0053 : ["km", "ខ្មែរ"], - 0x0453 : ["km-KH", "ខ្មែរ (កម្ពុជា)"], + 0x0453 : ["km-KH", "ខ្មែរ (កម្ពុជា)", "Khmer (Cambodia)"], 0x0086 : ["qut", "K'iche"], - 0x0486 : ["qut-GT", "K'iche (Guatemala)"], + 0x0486 : ["qut-GT", "K'iche (Guatemala)", "K'iche (Guatemala)"], 0x0087 : ["rw", "Kinyarwanda"], - 0x0487 : ["rw-RW", "Kinyarwanda (Rwanda)"], + 0x0487 : ["rw-RW", "Kinyarwanda (Rwanda)", "Kinyarwanda (Rwanda)"], 0x0041 : ["sw", "Kiswahili"], - 0x0441 : ["sw-KE", "Kiswahili (Kenya)"], + 0x0441 : ["sw-KE", "Kiswahili (Kenya)", "Kiswahili (Kenya)"], 0x0057 : ["kok", "कोंकणी"], - 0x0457 : ["kok-IN", "कोंकणी (भारत)"], + 0x0457 : ["kok-IN", "कोंकणी (भारत)", "Konkani (India)"], 0x0012 : ["ko", "한국어"], - 0x0412 : ["ko-KR", "한국어 (대한민국)"], + 0x0412 : ["ko-KR", "한국어 (대한민국)", "Korean (Korea)"], 0x0040 : ["ky", "Кыргыз"], - 0x0440 : ["ky-KG", "Кыргыз (Кыргызстан)"], + 0x0440 : ["ky-KG", "Кыргыз (Кыргызстан)", "Kyrgyz (Kyrgyzstan)"], 0x0054 : ["lo", "ລາວ"], - 0x0454 : ["lo-LA", "ລາວ (ສ.ປ.ປ. ລາວ)"], + 0x0454 : ["lo-LA", "ລາວ (ສ.ປ.ປ. ລາວ)", "Lao (Lao P.D.R.)"], 0x0026 : ["lv", "Latviešu"], - 0x0426 : ["lv-LV", "Latviešu (Latvija)"], + 0x0426 : ["lv-LV", "Latviešu (Latvija)", "Latvian (Latvia)"], 0x0027 : ["lt", "Lietuvių"], - 0x0427 : ["lt-LT", "Lietuvių (Lietuva)"], + 0x0427 : ["lt-LT", "Lietuvių (Lietuva)", "Lithuanian (Lithuania)"], 0x7C2E : ["dsb", "Dolnoserbšćina"], - 0x082E : ["dsb-DE", "Dolnoserbšćina (Nimska)"], + 0x082E : ["dsb-DE", "Dolnoserbšćina (Nimska)", "Lower Sorbian (Germany)"], 0x006E : ["lb", "Lëtzebuergesch"], - 0x046E : ["lb-LU", "Lëtzebuergesch (Luxembourg)"], - 0x042F : ["mk-MK", "Македонски јазик (Македонија)"], + 0x046E : ["lb-LU", "Lëtzebuergesch (Luxembourg)", "Luxembourgish (Luxembourg)"], + 0x042F : ["mk-MK", "Македонски јазик (Македонија)", "Macedonian (Former Yugoslav Republic of Macedonia)"], 0x002F : ["mk", "Македонски јазик"], 0x003E : ["ms", "Bahasa Melayu"], - 0x083E : ["ms-BN", "Bahasa Melayu (Brunei Darussalam)"], - 0x043E : ["ms-MY", "Bahasa Melayu (Malaysia)"], + 0x083E : ["ms-BN", "Bahasa Melayu (Brunei Darussalam)", "Malay (Brunei Darussalam)"], + 0x043E : ["ms-MY", "Bahasa Melayu (Malaysia)", "Malay (Malaysia)"], 0x004C : ["ml", "മലയാളം"], - 0x044C : ["ml-IN", "മലയാളം (ഭാരതം)"], + 0x044C : ["ml-IN", "മലയാളം (ഭാരതം)", "Malayalam (India)"], 0x003A : ["mt", "Malti"], - 0x043A : ["mt-MT", "Malti (Malta)"], + 0x043A : ["mt-MT", "Malti (Malta)", "Maltese (Malta)"], 0x0081 : ["mi", "Reo Māori"], - 0x0481 : ["mi-NZ", "Reo Māori (Aotearoa)"], + 0x0481 : ["mi-NZ", "Reo Māori (Aotearoa)", "Maori (New Zealand)"], 0x007A : ["arn", "Mapudungun"], - 0x047A : ["arn-CL", "Mapudungun (Chile)"], + 0x047A : ["arn-CL", "Mapudungun (Chile)", "Mapudungun (Chile)"], 0x004E : ["mr", "मराठी"], - 0x044E : ["mr-IN", "मराठी (भारत)"], + 0x044E : ["mr-IN", "मराठी (भारत)", "Marathi (India)"], 0x007C : ["moh", "Kanien'kéha"], - 0x047C : ["moh-CA", "Kanien'kéha"], + 0x047C : ["moh-CA", "Kanien'kéha (Canada)", "Mohawk (Canada)"], 0x0050 : ["mn", "Монгол хэл"], 0x7850 : ["mn-Cyrl", "Монгол хэл"], - 0x0450 : ["mn-MN", "Монгол хэл (Монгол улс)"], + 0x0450 : ["mn-MN", "Монгол хэл (Монгол улс)", "Mongolian (Cyrillic, Mongolia)"], 0x7C50 : ["mn-Mong", "ᠮᠤᠨᠭᠭᠤᠯ ᠬᠡᠯᠡ"], - 0x0850 : ["mn-Mong-CN", "ᠮᠤᠨᠭᠭᠤᠯ ᠬᠡᠯᠡ (ᠪᠦᠭᠦᠳᠡ ᠨᠠᠢᠷᠠᠮᠳᠠᠬᠤ ᠳᠤᠮᠳᠠᠳᠤ ᠠᠷᠠᠳ ᠣᠯᠣᠰ)"], + 0x0850 : ["mn-Mong-CN", "ᠮᠤᠨᠭᠭᠤᠯ ᠬᠡᠯᠡ (ᠪᠦᠭᠦᠳᠡ ᠨᠠᠢᠷᠠᠮᠳᠠᠬᠤ ᠳᠤᠮᠳᠠᠳᠤ ᠠᠷᠠᠳ ᠣᠯᠣᠰ)", "Mongolian (Traditional Mongolian) (People's Republic of China)"], 0x0061 : ["ne", "नेपाली"], - 0x0461 : ["ne-NP", "नेपाली (नेपाल)"], + 0x0461 : ["ne-NP", "नेपाली (नेपाल)", "Nepali (Nepal)"], + 0x0861 : ["ne-IN", "नेपाली (भारत)", "Nepali (India)"], 0x0014 : ["no", "Norsk"], 0x7C14 : ["nb", "Norsk (bokmål)"], + 0x0414 : ["nb-NO", "Norsk, bokmål (Norge)", "Norwegian, Bokmål (Norway)"], 0x7814 : ["nn", "Norsk (Nynorsk)"], - 0x0414 : ["nb-NO", "Norsk, bokmål (Norge)"], - 0x0814 : ["nn-NO", "Norsk, nynorsk (Noreg)"], + 0x0814 : ["nn-NO", "Norsk, nynorsk (Noreg)", "Norwegian, Nynorsk (Norway)"], 0x0082 : ["oc", "Occitan"], - 0x0482 : ["oc-FR", "Occitan (França)"], + 0x0482 : ["oc-FR", "Occitan (França)", "Occitan (France)"], 0x0048 : ["or", "ଓଡ଼ିଆ"], - 0x0448 : ["or-IN", "ଓଡ଼ିଆ (ଭାରତ)"], + 0x0448 : ["or-IN", "ଓଡ଼ିଆ (ଭାରତ)", "Oriya (India)"], 0x0063 : ["ps", "پښتو‏"], - 0x0463 : ["ps-AF", "پښتو (افغانستان)‏"], + 0x0463 : ["ps-AF", "پښتو (افغانستان)‏", "Pashto (Afghanistan)"], 0x0029 : ["fa", "فارسى‏"], - 0x0429 : ["fa-IR", "فارسى (ایران)‏"], + 0x0429 : ["fa-IR", "فارسى (ایران)‏", "Persian (Iran)"], 0x0015 : ["pl", "Polski"], - 0x0415 : ["pl-PL", "Polski (Polska)"], + 0x0415 : ["pl-PL", "Polski (Polska)", "Polish (Poland)"], 0x0016 : ["pt", "Português"], - 0x0416 : ["pt-BR", "Português (Brasil)"], - 0x0816 : ["pt-PT", "Português (Portugal)"], + 0x0416 : ["pt-BR", "Português (Brasil)", "Portuguese (Brazil)"], + 0x0816 : ["pt-PT", "Português (Portugal)", "Portuguese (Portugal)"], 0x0046 : ["pa", "ਪੰਜਾਬੀ"], - 0x0446 : ["pa-IN", "ਪੰਜਾਬੀ (ਭਾਰਤ)"], + 0x0446 : ["pa-IN", "ਪੰਜਾਬੀ (ਭਾਰਤ)", "Punjabi (India)"], 0x006B : ["quz", "Runasimi"], - 0x046B : ["quz-BO", "Runasimi (Qullasuyu)"], - 0x086B : ["quz-EC", "Runasimi (Ecuador)"], - 0x0C6B : ["quz-PE", "Runasimi (Piruw)"], + 0x046B : ["quz-BO", "Runasimi (Qullasuyu)", "Quechua (Bolivia)"], + 0x086B : ["quz-EC", "Runasimi (Ecuador)", "Quechua (Ecuador)"], + 0x0C6B : ["quz-PE", "Runasimi (Piruw)", "Quechua (Peru)"], 0x0018 : ["ro", "Română"], - 0x0418 : ["ro-RO", "Română (România)"], - 0x0818 : ["ro-MD", "Română (Moldova)"], + 0x0418 : ["ro-RO", "Română (România)", "Romanian (Romania)"], + 0x0818 : ["ro-MD", "Română (Moldova)", "Romanian (Republic of Moldova)"], 0x0017 : ["rm", "Rumantsch"], - 0x0417 : ["rm-CH", "Rumantsch (Svizra)"], + 0x0417 : ["rm-CH", "Rumantsch (Svizra)", "Romansh (Switzerland)"], 0x0019 : ["ru", "Русский"], - 0x0419 : ["ru-RU", "Русский (Россия)"], - 0x0819 : ["ru-MD", "Русский (Молдавия)"], + 0x0419 : ["ru-RU", "Русский (Россия)", "Russian (Russia)"], + 0x0819 : ["ru-MD", "Русский (Молдавия)", "Russian (Republic of Moldova)"], 0x703B : ["smn", "Sämikielâ"], + 0x243B : ["smn-FI", "Sämikielâ (Suomâ)", "Sami (Inari) (Finland)"], 0x7C3B : ["smj", "Julevusámegiella"], + 0x103B : ["smj-NO", "Julevusámegiella (Vuodna)", "Sami (Lule) (Norway)"], + 0x143B : ["smj-SE", "Julevusámegiella (Svierik)", "Sami (Lule) (Sweden)"], 0x003B : ["se", "Davvisámegiella"], + 0x0C3B : ["se-FI", "Davvisámegiella (Suopma)", "Sami (Northern) (Finland)"], + 0x043B : ["se-NO", "Davvisámegiella (Norga)", "Sami (Northern) (Norway)"], + 0x083B : ["se-SE", "Davvisámegiella (Ruoŧŧa)", "Sami (Northern) (Sweden)"], 0x743B : ["sms", "Sääm´ǩiõll"], + 0x203B : ["sms-FI", "Sääm´ǩiõll (Lää´ddjânnam)", "Sami (Skolt) (Finland)"], 0x783B : ["sma", "åarjelsaemiengiele"], - 0x243B : ["smn-FI", "Sämikielâ (Suomâ)"], - 0x103B : ["smj-NO", "Julevusámegiella (Vuodna)"], - 0x143B : ["smj-SE", "Julevusámegiella (Svierik)"], - 0x0C3B : ["se-FI", "Davvisámegiella (Suopma)"], - 0x043B : ["se-NO", "Davvisámegiella (Norga)"], - 0x083B : ["se-SE", "Davvisámegiella (Ruoŧŧa)"], - 0x203B : ["sms-FI", "Sääm´ǩiõll (Lää´ddjânnam)"], - 0x183B : ["sma-NO", "åarjelsaemiengiele (Nöörje)"], - 0x1C3B : ["sma-SE", "åarjelsaemiengiele (Sveerje)"], + 0x183B : ["sma-NO", "åarjelsaemiengiele (Nöörje)", "Sami (Southern) (Norway)"], + 0x1C3B : ["sma-SE", "åarjelsaemiengiele (Sveerje)", "Sami (Southern) (Sweden)"], 0x004F : ["sa", "संस्कृत"], - 0x044F : ["sa-IN", "संस्कृत (भारतम्)"], + 0x044F : ["sa-IN", "संस्कृत (भारतम्)", "Sanskrit (India)"], 0x0091 : ["gd", "Gàidhlig"], - 0x0491 : ["gd-GB", "Gàidhlig (An Rìoghachd Aonaichte)"], + 0x0491 : ["gd-GB", "Gàidhlig (An Rìoghachd Aonaichte)", "Scottish Gaelic (United Kingdom)"], 0x7C1A : ["sr", "Srpski"], 0x6C1A : ["sr-Cyrl", "Српски (Ћирилица)"], - 0x1C1A : ["sr-Cyrl-BA", "Српски (Босна и Херцеговина)"], - 0x301A : ["sr-Cyrl-ME", "Српски (Црна Гора)"], - 0x0C1A : ["sr-Cyrl-CS", "Српски (Србија и Црна Гора (Претходно))"], - 0x281A : ["sr-Cyrl-RS", "Српски (Србија)"], + 0x1C1A : ["sr-Cyrl-BA", "Српски (Босна и Херцеговина)", "Serbian (Cyrillic) (Bosnia and Herzegovina)"], + 0x301A : ["sr-Cyrl-ME", "Српски (Црна Гора)", "Serbian (Cyrillic, Montenegro)"], + 0x0C1A : ["sr-Cyrl-CS", "Српски (Србија и Црна Гора (Претходно))", "Serbian (Cyrillic, Serbia and Montenegro (Former))"], + 0x281A : ["sr-Cyrl-RS", "Српски (Србија)", "Serbian (Cyrillic, Serbia)"], 0x701A : ["sr-Latn", "Srpski (Latinica)"], - 0x181A : ["sr-Latn-BA", "Srpski (Bosna i Hercegovina)"], - 0x2C1A : ["sr-Latn-ME", "Srpski (Crna Gora)"], - 0x081A : ["sr-Latn-CS", "Srpski (Srbija i Crna Gora (Prethodno))"], - 0x241A : ["sr-Latn-RS", "Srpski (Srbija, Latinica)"], + 0x181A : ["sr-Latn-BA", "Srpski (Bosna i Hercegovina)", "Serbian (Latin, Bosnia and Herzegovina)"], + 0x2C1A : ["sr-Latn-ME", "Srpski (Crna Gora)", "Serbian (Latin, Montenegro)"], + 0x081A : ["sr-Latn-CS", "Srpski (Srbija i Crna Gora (Prethodno))", "Serbian (Latin, Serbia and Montenegro (Former))"], + 0x241A : ["sr-Latn-RS", "Srpski (Srbija, Latinica)", "Serbian (Latin, Serbia)"], 0x006C : ["nso", "Sesotho sa Leboa"], - 0x046C : ["nso-ZA", "Sesotho sa Leboa (Afrika Borwa)"], + 0x046C : ["nso-ZA", "Sesotho sa Leboa (Afrika Borwa)", "Sesotho sa Leboa (South Africa)"], 0x0032 : ["tn", "Setswana"], - 0x0432 : ["tn-ZA", "Setswana (Aforika Borwa)"], + 0x0432 : ["tn-ZA", "Setswana (Aforika Borwa)", "Setswana (South Africa)"], 0x005B : ["si", "සිංහ"], - 0x045B : ["si-LK", "සිංහ (ශ්‍රී ලංකා)"], + 0x045B : ["si-LK", "සිංහ (ශ්‍රී ලංකා)", "Sinhala (Sri Lanka)"], 0x001B : ["sk", "Slovenčina"], - 0x041B : ["sk-SK", "Slovenčina (Slovenská republika)"], + 0x041B : ["sk-SK", "Slovenčina (Slovenská republika)", "Slovak (Slovakia)"], 0x0024 : ["sl", "Slovenski"], - 0x0424 : ["sl-SI", "Slovenski (Slovenija)"], + 0x0424 : ["sl-SI", "Slovenski (Slovenija)", "Slovenian (Slovenia)"], 0x000A : ["es", "Español"], - 0x2C0A : ["es-AR", "Español (Argentina)"], - 0x400A : ["es-BO", "Español (Bolivia)"], - 0x340A : ["es-CL", "Español (Chile)"], - 0x240A : ["es-CO", "Español (Colombia)"], - 0x140A : ["es-CR", "Español (Costa Rica)"], - 0x1C0A : ["es-DO", "Español (República Dominicana)"], - 0x300A : ["es-EC", "Español (Ecuador)"], - 0x440A : ["es-SV", "Español (El Salvador)"], - 0x100A : ["es-GT", "Español (Guatemala)"], - 0x480A : ["es-HN", "Español (Honduras)"], - 0x080A : ["es-MX", "Español (México)"], - 0x4C0A : ["es-NI", "Español (Nicaragua)"], - 0x180A : ["es-PA", "Español (Panamá)"], - 0x3C0A : ["es-PY", "Español (Paraguay)"], - 0x280A : ["es-PE", "Español (Perú)"], - 0x500A : ["es-PR", "Español (Puerto Rico)"], - 0x0C0A : ["es-ES", "Español (España, alfabetización internacional)"], - 0x540A : ["es-US", "Español (Estados Unidos)"], - 0x380A : ["es-UY", "Español (Uruguay)"], - 0x200A : ["es-VE", "Español (Republica Bolivariana de Venezuela)"], + 0x2C0A : ["es-AR", "Español (Argentina)", "Spanish (Argentina)"], + 0x400A : ["es-BO", "Español (Bolivia)", "Spanish (Bolivia)"], + 0x340A : ["es-CL", "Español (Chile)", "Spanish (Chile)"], + 0x240A : ["es-CO", "Español (Colombia)", "Spanish (Colombia)"], + 0x140A : ["es-CR", "Español (Costa Rica)", "Spanish (Costa Rica)"], + 0x1C0A : ["es-DO", "Español (República Dominicana)", "Spanish (Dominican Republic)"], + 0x300A : ["es-EC", "Español (Ecuador)", "Spanish (Ecuador)"], + 0x440A : ["es-SV", "Español (El Salvador)", "Spanish (El Salvador)"], + 0x100A : ["es-GT", "Español (Guatemala)", "Spanish (Guatemala)"], + 0x480A : ["es-HN", "Español (Honduras)", "Spanish (Honduras)"], + 0x080A : ["es-MX", "Español (México)", "Spanish (Mexico)"], + 0x4C0A : ["es-NI", "Español (Nicaragua)", "Spanish (Nicaragua)"], + 0x180A : ["es-PA", "Español (Panamá)", "Spanish (Panama)"], + 0x3C0A : ["es-PY", "Español (Paraguay)", "Spanish (Paraguay)"], + 0x280A : ["es-PE", "Español (Perú)", "Spanish (Peru)"], + 0x500A : ["es-PR", "Español (Puerto Rico)", "Spanish (Puerto Rico)"], + 0x0C0A : ["es-ES", "Español (España, alfabetización internacional)", "Spanish (Spain)"], + 0x540A : ["es-US", "Español (Estados Unidos)", "Spanish (United States)"], + 0x380A : ["es-UY", "Español (Uruguay)", "Spanish (Uruguay)"], + 0x200A : ["es-VE", "Español (Republica Bolivariana de Venezuela)", "Spanish (Venezuela)"], 0x040a : ["es-ES_tradnl", "Spanish"], + 0x580a : ["es-419", "Español (América Latina y el Caribe)", "Spanish (Latin America and the Caribbean)"], + 0x5C0a : ["es-CU", "Español (Cuba)", "Spanish (Cuba)"], 0x001D : ["sv", "Svenska"], - 0x081D : ["sv-FI", "Svenska (Finland)"], - 0x041D : ["sv-SE", "Svenska (Sverige)"], + 0x081D : ["sv-FI", "Svenska (Finland)", "Swedish (Finland)"], + 0x041D : ["sv-SE", "Svenska (Sverige)", "Swedish (Sweden)"], 0x005A : ["syr", "ܣܘܪܝܝܐ‏"], - 0x045A : ["syr-SY", "ܣܘܪܝܝܐ (سوريا)‏"], + 0x045A : ["syr-SY", "ܣܘܪܝܝܐ (سوريا)‏", "Syriac (Syria)"], 0x0028 : ["tg", "Тоҷикӣ"], 0x7C28 : ["tg-Cyrl", "Тоҷикӣ"], - 0x0428 : ["tg-Cyrl-TJ", "Тоҷикӣ (Тоҷикистон)"], + 0x0428 : ["tg-Cyrl-TJ", "Тоҷикӣ (Тоҷикистон)", "Tajik (Cyrillic) (Tajikistan)"], 0x005F : ["tzm", "Tamazight"], 0x7C5F : ["tzm-Latn", "Tamazight (Latin)"], - 0x085F : ["tzm-Latn-DZ", "Tamazight (Djazaïr)"], + 0x085F : ["tzm-Latn-DZ", "Tamazight (Djazaïr)", "Tamazight (Latin) (Algeria)"], 0x0049 : ["ta", "தமிழ்"], - 0x0449 : ["ta-IN", "தமிழ் (இந்தியா)"], + 0x0449 : ["ta-IN", "தமிழ் (இந்தியா)", "Tamil (India)"], 0x0044 : ["tt", "Татар"], - 0x0444 : ["tt-RU", "Татар (Россия)"], + 0x0444 : ["tt-RU", "Татар (Россия)", "Tatar (Russia)"], 0x004A : ["te", "తెలుగు"], - 0x044A : ["te-IN", "తెలుగు (భారత దేశం)"], + 0x044A : ["te-IN", "తెలుగు (భారత దేశం)", "Telugu (India)"], 0x001E : ["th", "ไทย"], - 0x041E : ["th-TH", "ไทย (ไทย)"], + 0x041E : ["th-TH", "ไทย (ไทย)", "Thai (Thailand)"], 0x0051 : ["bo", "བོད་ཡིག"], - 0x0451 : ["bo-CN", "བོད་ཡིག (ཀྲུང་ཧྭ་མི་དམངས་སྤྱི་མཐུན་རྒྱལ་ཁབ།)"], + 0x0451 : ["bo-CN", "བོད་ཡིག (ཀྲུང་ཧྭ་མི་དམངས་སྤྱི་མཐུན་རྒྱལ་ཁབ།)", "Tibetan (People's Republic of China)"], + 0x0851 : ["bo-BT", "Tibetan (Bhutan)", "Tibetan (Bhutan)"], 0x001F : ["tr", "Türkçe"], - 0x041F : ["tr-TR", "Türkçe (Türkiye)"], + 0x041F : ["tr-TR", "Türkçe (Türkiye)", "Turkish (Turkey)"], 0x0042 : ["tk", "Türkmençe"], - 0x0442 : ["tk-TM", "Türkmençe (Türkmenistan)"], + 0x0442 : ["tk-TM", "Türkmençe (Türkmenistan)", "Turkmen (Turkmenistan)"], 0x0022 : ["uk", "Українська"], - 0x0422 : ["uk-UA", "Українська (Україна)"], + 0x0422 : ["uk-UA", "Українська (Україна)", "Ukrainian (Ukraine)"], 0x002E : ["hsb", "Hornjoserbšćina"], - 0x042E : ["hsb-DE", "Hornjoserbšćina (Němska)"], + 0x042E : ["hsb-DE", "Hornjoserbšćina (Němska)", "Upper Sorbian (Germany)"], 0x0020 : ["ur", "اُردو‏"], - 0x0420 : ["ur-PK", "اُردو (پاکستان)‏"], + 0x0420 : ["ur-PK", "اُردو (پاکستان)‏", "Urdu (Islamic Republic of Pakistan)"], + 0x0820 : ["ur-IN", "اُردو (بھارت)‏", "Urdu (India)"], 0x0080 : ["ug", "ئۇيغۇر يېزىقى‏"], - 0x0480 : ["ug-CN", "(ئۇيغۇر يېزىقى (جۇڭخۇا خەلق جۇمھۇرىيىتى‏"], + 0x0480 : ["ug-CN", "(ئۇيغۇر يېزىقى (جۇڭخۇا خەلق جۇمھۇرىيىتى‏", "Uighur (People's Republic of China)"], 0x7843 : ["uz-Cyrl", "Ўзбек"], - 0x0843 : ["uz-Cyrl-UZ", "Ўзбек (Ўзбекистон)"], + 0x0843 : ["uz-Cyrl-UZ", "Ўзбек (Ўзбекистон)", "Uzbek (Cyrillic, Uzbekistan)"], 0x0043 : ["uz", "U'zbek"], 0x7C43 : ["uz-Latn", "U'zbek"], - 0x0443 : ["uz-Latn-UZ", "U'zbek (U'zbekiston Respublikasi)"], + 0x0443 : ["uz-Latn-UZ", "U'zbek (U'zbekiston Respublikasi)", "Uzbek (Latin, Uzbekistan)"], 0x002A : ["vi", "Tiếng Việt"], - 0x042A : ["vi-VN", "Tiếng Việt (Việt Nam)"], + 0x042A : ["vi-VN", "Tiếng Việt (Việt Nam)", "Vietnamese (Vietnam)"], 0x0052 : ["cy", "Cymraeg"], - 0x0452 : ["cy-GB", "Cymraeg (y Deyrnas Unedig)"], + 0x0452 : ["cy-GB", "Cymraeg (y Deyrnas Unedig)", "Welsh (United Kingdom)"], 0x0088 : ["wo", "Wolof"], - 0x0488 : ["wo-SN", "Wolof (Sénégal)"], + 0x0488 : ["wo-SN", "Wolof (Sénégal)", "Wolof (Senegal)"], 0x0085 : ["sah", "Саха"], - 0x0485 : ["sah-RU", "Саха (Россия)"], + 0x0485 : ["sah-RU", "Саха (Россия)", "Yakut (Russia)"], 0x0078 : ["ii", "ꆈꌠꁱꂷ"], - 0x0478 : ["ii-CN", "ꆈꌠꁱꂷ (ꍏꉸꏓꂱꇭꉼꇩ)"], + 0x0478 : ["ii-CN", "ꆈꌠꁱꂷ (ꍏꉸꏓꂱꇭꉼꇩ)", "Yi (People's Republic of China)"], 0x006A : ["yo", "Yoruba"], - 0x046A : ["yo-NG", "Yoruba (Nigeria)"], - 0x0851 : ["bo-BT", "Tibetan (Bhutan)"], - 0x0466 : ["bin-NG", "Bini (Nigeria)"], - 0x045c : ["chr-US", "Cherokee (United States)"], - 0x0467 : ["fuv-NG", "Nigerian Fulfulde (Nigeria)"], - 0x0472 : ["gaz-ET", "West Central Oromo (Ethiopia)"], - 0x0474 : ["gn-PY", "Guarani (Paraguay)"], - 0x0475 : ["haw-US", "Hawaiian (United States)"], - 0x0469 : ["ibb-NG", "Ibibio (Nigeria)"], - 0x0471 : ["kr-NG", "Kanuri (Nigeria)"], - 0x0458 : ["mni", "Manipuri"], - 0x0455 : ["my-MM", "Burmese (Myanmar)"], - 0x0861 : ["ne-IN", "Nepali (India)"], - 0x0479 : ["pap-AN", "Papiamento, Netherlands Antilles"], - 0x0846 : ["pa-PK", "Panjabi (Pakistan)"], - 0x048d : ["plt-MG", "Plateau Malagasy (Madagascar)"], - 0x0459 : ["sd-IN", "Sindhi (India)"], - 0x0859 : ["sd-PK", "Sindhi (Pakistan)"], - 0x0477 : ["so-SO", "Somali (Somalia)"], - 0x0430 : ["st-ZA", "Southern Sotho (South Africa)"], - 0x0473 : ["ti-ER", "Tigrinya (Eritrea)"], - 0x0873 : ["ti-ET", "Tigrinya (Ethiopia)"], + 0x046A : ["yo-NG", "Yoruba (Nigeria)", "Yoruba (Nigeria)"], + 0x0466 : ["bin-NG", "Bini (Nigeria)", "Bini (Nigeria)"], + 0x045c : ["chr-US", "ᏣᎳᎩ (ᏌᏊ ᎢᏳᎾᎵᏍᏔᏅ ᏍᎦᏚᎩ)", "Cherokee (United States)"], + 0x0467 : ["fuv-NG", "Nigerian Fulfulde (Nigeria)", "Nigerian Fulfulde (Nigeria)"], + 0x0472 : ["gaz-ET", "West Central Oromo (Ethiopia)", "West Central Oromo (Ethiopia)"], + 0x0474 : ["gn-PY", "Guarani (Paraguay)", "Guarani (Paraguay)"], + 0x0475 : ["haw-US", "ʻŌlelo Hawaiʻi (ʻAmelika Hui Pū ʻIa)", "Hawaiian (United States)"], + 0x0469 : ["ibb-NG", "Ibibio (Nigeria)", "Ibibio (Nigeria)"], + 0x0471 : ["kr-NG", "Kanuri (Nigeria)", "Kanuri (Nigeria)"], + 0x0458 : ["mni", "Manipuri", "Manipuri"], + 0x0455 : ["my-MM", "Burmese (Myanmar)", "Burmese (Myanmar)"], + 0x0479 : ["pap-AN", "Papiamento, Netherlands Antilles", "Papiamento, Netherlands Antilles"], + 0x0846 : ["pa-PK", "Panjabi (Pakistan)", "Panjabi (Pakistan)"], + 0x048d : ["plt-MG", "Plateau Malagasy (Madagascar)", "Plateau Malagasy (Madagascar)"], + 0x0459 : ["sd-IN", "Sindhi (India)", "Sindhi (India)"], + 0x0859 : ["sd-PK", "Sindhi (Pakistan)", "Sindhi (Pakistan)"], + 0x0477 : ["so-SO", "Soomaali (Soomaaliya)", "Somali (Somalia)"], + 0x0430 : ["st-ZA", "Southern Sotho (South Africa)", "Southern Sotho (South Africa)"], + 0x0473 : ["ti-ER", "ትግርኛ (ኤርትራ)", "Tigrinya (Eritrea)"], + 0x0873 : ["ti-ET", "ትግርኛ (ኢትዮጵያ)", "Tigrinya (Ethiopia)"], 0x045f : ["tmz", "Tamanaku"], - 0x0c5f : ["tmz-MA", "Tamanaku (Morocco)"], - 0x0431 : ["ts-ZA", "Tsonga (South Africa)"], - 0x0820 : ["ur-IN", "Urdu (India)"], - 0x0433 : ["ven-ZA", "South Africa"] + 0x0c5f : ["tmz-MA", "Tamaziɣt n laṭlaṣ (Meṛṛuk)", "Tamanaku (Morocco)"], + 0x0431 : ["ts-ZA", "Tsonga (South Africa)", "Tsonga (South Africa)"], + 0x0433 : ["ven-ZA", "South Africa", "South Africa"] }; return { @@ -446,11 +448,17 @@ Common.util.LanguageInfo = new(function() { }, getLocalLanguageCode: function(name) { - for (var code in localLanguageName) { - if (localLanguageName[code][0].toLowerCase()===name.toLowerCase()) - return code; + if (name) { + for (var code in localLanguageName) { + if (localLanguageName[code][0].toLowerCase()===name.toLowerCase()) + return code; + } } return null; + }, + + getLanguages: function() { + return localLanguageName; } } })(); \ No newline at end of file diff --git a/apps/common/main/lib/util/LocalStorage.js b/apps/common/main/lib/util/LocalStorage.js index fba918a1b..764492111 100644 --- a/apps/common/main/lib/util/LocalStorage.js +++ b/apps/common/main/lib/util/LocalStorage.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under diff --git a/apps/common/main/lib/util/Shortcuts.js b/apps/common/main/lib/util/Shortcuts.js index 97c1aedfd..430646a83 100644 --- a/apps/common/main/lib/util/Shortcuts.js +++ b/apps/common/main/lib/util/Shortcuts.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under diff --git a/apps/common/main/lib/util/Tip.js b/apps/common/main/lib/util/Tip.js index f04507b9a..b0521586d 100644 --- a/apps/common/main/lib/util/Tip.js +++ b/apps/common/main/lib/util/Tip.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -127,15 +127,12 @@ if (this.hasContent() && this.enabled && !this.dontShow) { if (!this.$element.is(":visible") && this.$element.closest('[role=menu]').length>0) return; var $tip = this.tip(); - var placement = typeof this.options.placement === 'function' ? - this.options.placement.call(this, $tip[0], this.$element[0]) : this.options.placement; if (this.options.arrow === false) $tip.addClass('arrow-free'); if (this.options.cls) $tip.addClass(this.options.cls); - - var placementEx = /^([a-zA-Z]+)-?([a-zA-Z]*)$/.exec(placement); - if (!at && !placementEx[2].length) { + var placementEx = (typeof this.options.placement !== 'function') ? /^([a-zA-Z]+)-?([a-zA-Z]*)$/.exec(this.options.placement) : null; + if (!at && placementEx && !placementEx[2].length) { _superclass.prototype.show.apply(this, arguments); } else { var e = $.Event('show.bs.tooltip'); @@ -152,7 +149,9 @@ this.options.container ? $tip.appendTo(this.options.container) : $tip.insertAfter(this.$element); - if (typeof at == 'object') { + if (typeof this.options.placement === 'function') { + this.options.placement.call(this, $tip[0], this.$element[0]); + } else if (typeof at == 'object') { var tp = {top: at[1] + 15, left: at[0] + 18}, innerWidth = Common.Utils.innerWidth(), innerHeight = Common.Utils.innerHeight(); diff --git a/apps/common/main/lib/util/define.js b/apps/common/main/lib/util/define.js index 562df9121..0b04adfec 100644 --- a/apps/common/main/lib/util/define.js +++ b/apps/common/main/lib/util/define.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under diff --git a/apps/common/main/lib/util/utils.js b/apps/common/main/lib/util/utils.js index 3df28c180..2268d5764 100644 --- a/apps/common/main/lib/util/utils.js +++ b/apps/common/main/lib/util/utils.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -87,11 +87,12 @@ Common.Utils = _.extend(new(function() { isSecure = /^https/i.test(window.location.protocol), emailRe = /^(mailto:)?([a-z0-9'\._-]+@[a-z0-9\.-]+\.[a-z0-9]{2,4})([a-яё0-9\._%+-=\? :&]*)/i, ipRe = /^(((https?)|(ftps?)):\/\/)?([\-\wа-яё]*:?[\-\wа-яё]*@)?(((1[0-9]{2}|2[0-4][0-9]|25[0-5]|[1-9][0-9]|[0-9])\.){3}(1[0-9]{2}|2[0-4][0-9]|25[0-5]|[1-9][0-9]|[0-9]))(:\d+)?(\/[%\-\wа-яё]*(\.[\wа-яё]{2,})?(([\wа-яё\-\.\?\\\/+@&#;:`~=%!,\(\)]*)(\.[\wа-яё]{2,})?)*)*\/?/i, - hostnameRe = /^(((https?)|(ftps?)):\/\/)?([\-\wа-яё]*:?[\-\wа-яё]*@)?(([\-\wа-яё]+\.)+[\wа-яё\-]{2,}(:\d+)?(\/[%\-\wа-яё]*(\.[\wа-яё]{2,})?(([\wа-яё\-\.\?\\\/+@&#;:`'~=%!,\(\)]*)(\.[\wа-яё]{2,})?)*)*\/?)/i, - localRe = /^(((https?)|(ftps?)):\/\/)([\-\wа-яё]*:?[\-\wа-яё]*@)?(([\-\wа-яё]+)(:\d+)?(\/[%\-\wа-яё]*(\.[\wа-яё]{2,})?(([\wа-яё\-\.\?\\\/+@&#;:`'~=%!,\(\)]*)(\.[\wа-яё]{2,})?)*)*\/?)/i, + hostnameRe = /^(((https?)|(ftps?)):\/\/)?([\-\wа-яё]*:?[\-\wа-яё]*@)?(([\-\wа-яё]+\.)+[\wа-яё\-]{2,}(:\d+)?(\/[%\-\wа-яё]*(\.[\wа-яё]{2,})?(([\wа-яё\-\.\?\\\/\+@&#;:`'~=%!,\(\)]*)(\.[\wа-яё]{2,})?)*)*\/?)/i, + localRe = /^(((https?)|(ftps?)):\/\/)([\-\wа-яё]*:?[\-\wа-яё]*@)?(([\-\wа-яё]+)(:\d+)?(\/[%\-\wа-яё]*(\.[\wа-яё]{2,})?(([\wа-яё\-\.\?\\\/\+@&#;:`'~=%!,\(\)]*)(\.[\wа-яё]{2,})?)*)*\/?)/i, emailStrongRe = /(mailto:)?([a-z0-9'\._-]+@[a-z0-9\.-]+\.[a-z0-9]{2,4})([a-яё0-9\._%+-=\?:&]*)/ig, - ipStrongRe = /(((https?)|(ftps?)):\/\/([\-\wа-яё]*:?[\-\wа-яё]*@)?)(((1[0-9]{2}|2[0-4][0-9]|25[0-5]|[1-9][0-9]|[0-9])\.){3}(1[0-9]{2}|2[0-4][0-9]|25[0-5]|[1-9][0-9]|[0-9]))(:\d+)?(\/[%\-\wа-яё]*(\.[\wа-яё]{2,})?(([\wа-яё\-\.\?\\\/+@&#;:`~=%!,\(\)]*)(\.[\wа-яё]{2,})?)*)*\/?/ig, - hostnameStrongRe = /((((https?)|(ftps?)):\/\/([\-\wа-яё]*:?[\-\wа-яё]*@)?)|(([\-\wа-яё]*:?[\-\wа-яё]*@)?www\.))((([\-\wа-яё]+\.)+[\wа-яё\-]{2,}|([\-\wа-яё]+))(:\d+)?(\/[%\-\wа-яё]*(\.[\wа-яё]{2,})?(([\wа-яё\-\.\?\\\/+@&#;:`~=%!,\(\)]*)(\.[\wа-яё]{2,})?)*)*\/?)/ig, + emailAddStrongRe = /(mailto:|\s[@]|\s[+])?([a-z0-9'\._-]+@[a-z0-9\.-]+\.[a-z0-9]{2,4})([a-яё0-9\._%\+-=\?:&]*)/ig, + ipStrongRe = /(((https?)|(ftps?)):\/\/([\-\wа-яё]*:?[\-\wа-яё]*@)?)(((1[0-9]{2}|2[0-4][0-9]|25[0-5]|[1-9][0-9]|[0-9])\.){3}(1[0-9]{2}|2[0-4][0-9]|25[0-5]|[1-9][0-9]|[0-9]))(:\d+)?(\/[%\-\wа-яё]*(\.[\wа-яё]{2,})?(([\wа-яё\-\.\?\\\/\+@&#;:`~=%!,\(\)]*)(\.[\wа-яё]{2,})?)*)*\/?/ig, + hostnameStrongRe = /((((https?)|(ftps?)):\/\/([\-\wа-яё]*:?[\-\wа-яё]*@)?)|(([\-\wа-яё]*:?[\-\wа-яё]*@)?www\.))((([\-\wа-яё]+\.)+[\wа-яё\-]{2,}|([\-\wа-яё]+))(:\d+)?(\/[%\-\wа-яё]*(\.[\wа-яё]{2,})?(([\wа-яё\-\.\?\\\/\+@&#;:`~=%!,\(\)]*)(\.[\wа-яё]{2,})?)*)*\/?)/ig, documentSettingsType = { Paragraph : 0, Table : 1, @@ -106,6 +107,13 @@ Common.Utils = _.extend(new(function() { Pivot : 10, Cell : 11 }, + importTextType = { + DRM: 0, + CSV: 1, + TXT: 2, + Paste: 3, + Columns: 4 + }, isMobile = /android|avantgo|blackberry|blazer|compal|elaine|fennec|hiptop|iemobile|ip(hone|od|ad)|iris|kindle|lge |maemo|midp|mmp|opera m(ob|in)i|palm( os)?|phone|p(ixi|re)\/|plucker|pocket|psp|symbian|treo|up\.(browser|link)|vodafone|wap|windows (ce|phone)|xda|xiino/i.test(navigator.userAgent || navigator.vendor || window.opera), me = this, checkSize = function() { @@ -201,9 +209,11 @@ Common.Utils = _.extend(new(function() { hostnameRe: hostnameRe, localRe: localRe, emailStrongRe: emailStrongRe, + emailAddStrongRe: emailAddStrongRe, ipStrongRe: ipStrongRe, hostnameStrongRe: hostnameStrongRe, documentSettingsType: documentSettingsType, + importTextType: importTextType, zoom: function() {return me.zoom;}, innerWidth: function() {return me.innerWidth;}, innerHeight: function() {return me.innerHeight;} @@ -535,6 +545,8 @@ Common.Utils.String = new (function() { return { format: function(format) { var args = _.toArray(arguments).slice(1); + if (args.length && typeof args[0] == 'object') + args = args[0]; return format.replace(/\{(\d+)\}/g, function(s, i) { return args[i]; }); @@ -587,6 +599,7 @@ Common.Utils.isBrowserSupported = function() { }; Common.Utils.showBrowserRestriction = function() { + if (document.getElementsByClassName && document.getElementsByClassName('app-error-panel').length>0) return; var editor = (window.DE ? 'Document' : window.SSE ? 'Spreadsheet' : window.PE ? 'Presentation' : 'that'); var newDiv = document.createElement("div"); newDiv.innerHTML = '
' + @@ -634,20 +647,22 @@ Common.Utils.applyCustomizationPlugins = function(plugins) { var _createXMLHTTPObject = function() { var xmlhttp; - try { - xmlhttp = new ActiveXObject("Msxml2.XMLHTTP"); - } - catch (e) { - try { - xmlhttp = new ActiveXObject("Microsoft.XMLHTTP"); - } - catch (E) { - xmlhttp = false; - } - } - if (!xmlhttp && typeof XMLHttpRequest != 'undefined') { + if (typeof XMLHttpRequest != 'undefined') { xmlhttp = new XMLHttpRequest(); + } else { + try { + xmlhttp = new ActiveXObject("Msxml2.XMLHTTP"); + } + catch (e) { + try { + xmlhttp = new ActiveXObject("Microsoft.XMLHTTP"); + } + catch (E) { + xmlhttp = false; + } + } } + return xmlhttp; }; @@ -674,33 +689,26 @@ Common.Utils.applyCustomizationPlugins = function(plugins) { Common.Utils.fillUserInfo = function(info, lang, defname) { var _user = info || {}; !_user.id && (_user.id = ('uid-' + Date.now())); - if (_.isEmpty(_user.name)) { - _.isEmpty(_user.firstname) && _.isEmpty(_user.lastname) && (_user.firstname = defname); - if (_.isEmpty(_user.firstname)) - _user.fullname = _user.lastname; - else if (_.isEmpty(_user.lastname)) - _user.fullname = _user.firstname; - else - _user.fullname = /^ru/.test(lang) ? _user.lastname + ' ' + _user.firstname : _user.firstname + ' ' + _user.lastname; - } else - _user.fullname = _user.name; + _user.fullname = _.isEmpty(_user.name) ? defname : _user.name; return _user; }; Common.Utils.createXhr = function () { var xmlhttp; - try { - xmlhttp = new ActiveXObject("Msxml2.XMLHTTP"); - } catch (e) { - try { - xmlhttp = new ActiveXObject("Microsoft.XMLHTTP"); - } catch (E) { - xmlhttp = false; - } - } - if (!xmlhttp && typeof XMLHttpRequest != 'undefined') { + + if (typeof XMLHttpRequest != 'undefined') { xmlhttp = new XMLHttpRequest(); + } else { + try { + xmlhttp = new ActiveXObject("Msxml2.XMLHTTP"); + } catch (e) { + try { + xmlhttp = new ActiveXObject("Microsoft.XMLHTTP"); + } catch (E) { + xmlhttp = false; + } + } } return xmlhttp; @@ -722,21 +730,18 @@ Common.Utils.getConfigJson = function (url) { return null; }; -Common.Utils.getConfigJson = function (url) { - if ( url ) { - try { - var xhrObj = Common.Utils.createXhr(); - if ( xhrObj ) { - xhrObj.open('GET', url, false); - xhrObj.send(''); +Common.Utils.loadConfig = function(url, callback) { + "use strict"; - return JSON.parse(xhrObj.responseText); - } - } catch (e) {} - } - - return null; -} + fetch(url) + .then(function(response){ + if ( response.ok ) + return response.json(); + else return 'error'; + }).then(function(json){ + callback(json); + }); +}; Common.Utils.asyncCall = function (callback, scope, args) { (new Promise(function (resolve, reject) { @@ -772,6 +777,117 @@ Common.Utils.InternalSettings = new(function() { } }); +Common.Utils.lockControls = function(causes, lock, opts, defControls) { + !opts && (opts = {}); + + var controls = opts.array || defControls; + opts.merge && (controls = _.union(defControls,controls)); + + function doLock(cmp, cause) { + if ( cmp && _.contains(cmp.options.lock, cause) ) { + var index = cmp.keepState.indexOf(cause); + if (lock) { + if (index < 0) { + cmp.keepState.push(cause); + } + } else { + if (!(index < 0)) { + cmp.keepState.splice(index, 1); + } + } + } + } + + _.each(controls, function(item) { + if (item && _.isFunction(item.setDisabled)) { + !item.keepState && (item.keepState = []); + if (opts.clear && opts.clear.length > 0 && item.keepState.length > 0) { + item.keepState = _.difference(item.keepState, opts.clear); + } + + _.isArray(causes) ? _.each(causes, function(c) {doLock(item, c)}) : doLock(item, causes); + + if (!(item.keepState.length > 0)) { + item.isDisabled() && item.setDisabled(false); + } else { + !item.isDisabled() && item.setDisabled(true); + } + } + }); +}; + +Common.Utils.injectButtons = function($slots, id, iconCls, caption, lock, split, menu, toggle) { + var btnsArr = createButtonSet(); + btnsArr.setDisabled(true); + id = id || ("id-toolbar-" + iconCls); + $slots.each(function(index, el) { + var _cls = 'btn-toolbar'; + /x-huge/.test(el.className) && (_cls += ' x-huge icon-top'); + + var button = new Common.UI.Button({ + id: id + index, + cls: _cls, + iconCls: iconCls, + caption: caption, + split: split || false, + menu: menu || false, + enableToggle: toggle || false, + lock: lock, + disabled: true + }).render( $slots.eq(index) ); + + btnsArr.add(button); + }); + return btnsArr; +}; + +Common.Utils.injectComponent = function ($slot, cmp) { + if (cmp && $slot.length) { + cmp.rendered ? $slot.append(cmp.$el) : cmp.render($slot); + } +}; + +jQuery.fn.extend({ + elementById: function (id, parent) { + /** + * usage: $obj.findById('#id') + * $().findById('#id', $obj | node) + * $.fn.findById('#id', $obj | node) + * + * return: dom element + * */ + var _el = document.getElementById(id.substring(1)); + if ( !_el ) { + parent = parent || this; + if ( parent instanceof jQuery ) { + parent.each(function (i, node) { + _el = node.querySelectorAll(id); + if ( _el.length == 0 ) { + if ( ('#' + node.id) == id ) { + _el = node; + return false; + } + } else + if ( _el.length ) { + _el = _el[0]; + return false; + } + }) + } else { + _el = parent.querySelectorAll(id); + if ( _el && _el.length ) return _el[0]; + } + } + + return _el; + }, + + findById: function (id, parent) { + var _el = $.fn.elementById.apply(this, arguments); + return !!_el ? $(_el) : $(); + } +}); + Common.Utils.InternalSettings.set('toolbar-height-tabs', 32); Common.Utils.InternalSettings.set('toolbar-height-tabs-top-title', 28); Common.Utils.InternalSettings.set('toolbar-height-controls', 67); diff --git a/apps/common/main/lib/view/About.js b/apps/common/main/lib/view/About.js index d40c8610f..5bf6bf72a 100644 --- a/apps/common/main/lib/view/About.js +++ b/apps/common/main/lib/view/About.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -45,6 +45,7 @@ define([ Common.Views.About = Common.UI.BaseView.extend(_.extend({ menu: undefined, + rendered: false, options: { alias: 'Common.Views.About' }, @@ -53,15 +54,11 @@ define([ Common.UI.BaseView.prototype.initialize.call(this,arguments); this.txtVersionNum = '{{PRODUCT_VERSION}}'; - this.txtAscMail = 'support@onlyoffice.com'; - this.txtAscTelNum = '+371 660-16425'; - this.txtAscUrl = 'www.onlyoffice.com'; - this.txtAscName = 'Ascensio System SIA'; this.template = _.template([ '', '', - '', + '', '', '', '', @@ -72,29 +69,29 @@ define([ '', '', '', - '', + '', '', '', '', '', '', '', '', '', '', '', '', '', '', '
', '', - '', + '', '
', '', - '' + this.txtAscMail + '', + '<%= supportemail %>', '
', '', - '', + '', '
', - '' + this.txtAscUrl + '', + '<% print(publisherurl.replace(/https?:\\/{2}/, "").replace(/\\/$/,"")) %>', '
', @@ -143,11 +140,11 @@ define([ '
', '', '', - '', + '', '', '', '', - '', + '', '', '', '' @@ -156,76 +153,95 @@ define([ }, render: function() { - var el = $(this.el); - el.html(this.template({ - scope: this - })); + if ( !this.rendered ) { + this.rendered = true; - el.addClass('about-dlg'); - this.cntLicenseeInfo = $('#id-about-licensee-info'); - this.cntLicensorInfo = $('#id-about-licensor-info'); - this.divCompanyLogo = $('#id-about-company-logo'); - this.lblCompanyName = $('#id-about-company-name'); - this.lblCompanyAddress = $('#id-about-company-address'); - this.lblCompanyMail = $('#id-about-company-mail'); - this.lblCompanyUrl = $('#id-about-company-url'); - this.lblCompanyLic = $('#id-about-company-lic'); + var _$l = $(this.template({ + publishername: '{{PUBLISHER_NAME}}', + publisheraddr: '{{PUBLISHER_ADDRESS}}', + publisherurl: '{{PUBLISHER_URL}}', + supportemail: '{{SUPPORT_EMAIL}}', + phonenum: '{{PUBLISHER_PHONE}}', + scope: this + })); - if (_.isUndefined(this.scroller)) { - this.scroller = new Common.UI.Scroller({ - el: $(this.el), - suppressScrollX: true - }); + this.cntLicenseeInfo = _$l.findById('#id-about-licensee-info'); + this.cntLicensorInfo = _$l.findById('#id-about-licensor-info'); + this.divCompanyLogo = _$l.findById('#id-about-company-logo'); + this.lblCompanyName = _$l.findById('#id-about-company-name'); + this.lblCompanyAddress = _$l.findById('#id-about-company-address'); + this.lblCompanyMail = _$l.findById('#id-about-company-mail'); + this.lblCompanyUrl = _$l.findById('#id-about-company-url'); + this.lblCompanyLic = _$l.findById('#id-about-company-lic'); + + if ( this.licData ) + this.setLicInfo(this.licData); + + this.$el.html(_$l); + this.$el.addClass('about-dlg'); + + if (_.isUndefined(this.scroller)) { + this.scroller = new Common.UI.Scroller({ + el: this.$el, + suppressScrollX: true + }); + } } return this; }, setLicInfo: function(data){ - if (data && typeof data == 'object' && typeof(data.customer)=='object') { - var customer = data.customer; - - $('#id-about-licensor-logo').addClass('hidden'); - $('#id-about-licensor-short').removeClass('hidden'); - this.cntLicensorInfo.addClass('hidden'); + if ( !this.rendered ) { + this.licData = data || true; + } else { + if (data && typeof data == 'object' && typeof(data.customer)=='object') { + var customer = data.customer; - this.cntLicenseeInfo.removeClass('hidden'); - this.cntLicensorInfo.removeClass('margin-bottom'); + $('#id-about-licensor-logo').addClass('hidden'); + $('#id-about-licensor-short').removeClass('hidden'); + this.cntLicensorInfo.addClass('hidden'); - var value = customer.name; - value && value.length ? + this.cntLicenseeInfo.removeClass('hidden'); + this.cntLicensorInfo.removeClass('margin-bottom'); + + var value = customer.name; + value && value.length ? this.lblCompanyName.text(value) : this.lblCompanyName.parents('tr').addClass('hidden'); - value = customer.address; - value && value.length ? + value = customer.address; + value && value.length ? this.lblCompanyAddress.text(value) : this.lblCompanyAddress.parents('tr').addClass('hidden'); - (value = customer.mail) && value.length ? + (value = customer.mail) && value.length ? this.lblCompanyMail.attr('href', "mailto:"+value).text(value) : this.lblCompanyMail.parents('tr').addClass('hidden'); - if ((value = customer.www) && value.length) { - var http = !/^https?:\/{2}/i.test(value) ? "http:\/\/" : ''; - this.lblCompanyUrl.attr('href', http+value).text(value); - } else - this.lblCompanyUrl.parents('tr').addClass('hidden'); + if ((value = customer.www) && value.length) { + var http = !/^https?:\/{2}/i.test(value) ? "http:\/\/" : ''; + this.lblCompanyUrl.attr('href', http+value).text(value); + } else + this.lblCompanyUrl.parents('tr').addClass('hidden'); - (value = customer.info) && value.length ? + (value = customer.info) && value.length ? this.lblCompanyLic.text(value) : this.lblCompanyLic.parents('tr').addClass('hidden'); - (value = customer.logo) && value.length ? + (value = customer.logo) && value.length ? this.divCompanyLogo.html('') : this.divCompanyLogo.parents('tr').addClass('hidden'); - } else { - this.cntLicenseeInfo.addClass('hidden'); - this.cntLicensorInfo.addClass('margin-bottom'); + } else { + this.cntLicenseeInfo.addClass('hidden'); + this.cntLicensorInfo.addClass('margin-bottom'); + } } }, show: function () { + if ( !this.rendered ) this.render(); + Common.UI.BaseView.prototype.show.call(this,arguments); this.fireEvent('show', this ); }, @@ -247,7 +263,6 @@ define([ txtLicensor: 'LICENSOR', txtLicensee: 'LICENSEE', txtAddress: 'address: ', - txtAscAddress: 'Lubanas st. 125a-25, Riga, Latvia, EU, LV-1021', txtMail: 'email: ', txtTel: 'tel.: ', txtEdition: 'Integration Edition ' diff --git a/apps/common/main/lib/view/AdvancedSettingsWindow.js b/apps/common/main/lib/view/AdvancedSettingsWindow.js index 14fe6c10b..153bf86b2 100644 --- a/apps/common/main/lib/view/AdvancedSettingsWindow.js +++ b/apps/common/main/lib/view/AdvancedSettingsWindow.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -51,7 +51,8 @@ define([ cls: 'advanced-settings-dlg', toggleGroup: 'advanced-settings-group', contentTemplate: '', - items: [] + items: [], + buttons: ['ok', 'cancel'] }, options); this.template = options.template || [ @@ -64,11 +65,7 @@ define([ '
', '
' + _options.contentTemplate + '
', '
', - '
', - '' + '
' ].join(''); _options.tpl = _.template(this.template)(_options); @@ -110,6 +107,22 @@ define([ this.content_panels = $window.find('.settings-panel'); if (this.btnsCategory.length>0) this.btnsCategory[0].toggle(true, true); + + me.menuAddAlign = function(menuRoot, left, top) { + var self = this; + if (!$window.hasClass('notransform')) { + $window.addClass('notransform'); + menuRoot.addClass('hidden'); + setTimeout(function() { + menuRoot.removeClass('hidden'); + menuRoot.css({left: left, top: top}); + self.options.additionalAlign = null; + }, 300); + } else { + menuRoot.css({left: left, top: top}); + self.options.additionalAlign = null; + } + } }, setHeight: function(height) { @@ -174,9 +187,6 @@ define([ if (this.storageName) Common.localStorage.setItem(this.storageName, this.getActiveCategory()); Common.UI.Window.prototype.close.call(this, suppressevent); - }, - - cancelButtonText: 'Cancel', - okButtonText : 'Ok' + } }, Common.Views.AdvancedSettingsWindow || {})); }); \ No newline at end of file diff --git a/apps/common/main/lib/view/Chat.js b/apps/common/main/lib/view/Chat.js index 2ad7b383b..03bee46be 100644 --- a/apps/common/main/lib/view/Chat.js +++ b/apps/common/main/lib/view/Chat.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -60,8 +60,7 @@ define([ storeMessages: undefined, tplUser: ['
  • "<% if (!user.get("online")) { %> class="offline"<% } %>>', - '
    <%= scope.getUserName(user.get("username")) %>', - '
    ;" >
    ', + '
    ;" >
    <%= scope.getUserName(user.get("username")) %>', '
    ', '
  • '].join(''), @@ -217,6 +216,9 @@ define([ var arr = [], offset, len; message.replace(Common.Utils.ipStrongRe, function(subStr) { + var result = /[\.,\?\+;:=!\(\)]+$/.exec(subStr); + if (result) + subStr = subStr.substring(0, result.index); offset = arguments[arguments.length-2]; arr.push({start: offset, end: subStr.length+offset, str: '' + subStr + ''}); return ''; @@ -224,6 +226,9 @@ define([ if (message.length<1000 || message.search(/\S{255,}/)<0) message.replace(Common.Utils.hostnameStrongRe, function(subStr) { + var result = /[\.,\?\+;:=!\(\)]+$/.exec(subStr); + if (result) + subStr = subStr.substring(0, result.index); var ref = (! /(((^https?)|(^ftp)):\/\/)/i.test(subStr) ) ? ('http://' + subStr) : subStr; offset = arguments[arguments.length-2]; len = subStr.length; diff --git a/apps/common/main/lib/view/Comments.js b/apps/common/main/lib/view/Comments.js index b6888f435..5dc3bcd5b 100644 --- a/apps/common/main/lib/view/Comments.js +++ b/apps/common/main/lib/view/Comments.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -72,6 +72,99 @@ define([ return tpl; } + var CommentsPanelDataView = Common.UI.DataView.extend((function() { + return { + options : { + handleSelect: false, + scrollable: true, + listenStoreEvents: false, + template: _.template('
    ') + }, + + getTextBox: function () { + var text = $(this.el).find('textarea'); + return (text && text.length) ? text : undefined; + }, + setFocusToTextBox: function () { + var text = $(this.el).find('textarea'); + if (text && text.length) { + var val = text.val(); + text.focus(); + text.val(''); + text.val(val); + } + }, + getActiveTextBoxVal: function () { + var text = $(this.el).find('textarea'); + return (text && text.length) ? text.val().trim() : ''; + }, + autoHeightTextBox: function () { + var view = this, + textBox = $(this.el).find('textarea'), + domTextBox = null, + minHeight = 50, + lineHeight = 0, + scrollPos = 0, + oldHeight = 0, + newHeight = 0; + + function updateTextBoxHeight() { + if (domTextBox.scrollHeight > domTextBox.clientHeight) { + textBox.css({height: (domTextBox.scrollHeight + lineHeight) + 'px'}); + } else { + oldHeight = domTextBox.clientHeight; + if (oldHeight >= minHeight) { + + textBox.css({height: minHeight + 'px'}); + + if (domTextBox.scrollHeight > domTextBox.clientHeight) { + newHeight = Math.max(domTextBox.scrollHeight + lineHeight, minHeight); + textBox.css({height: newHeight + 'px'}); + } + } + } + + view.autoScrollToEditButtons(); + } + + if (textBox && textBox.length) { + domTextBox = textBox.get(0); + + if (domTextBox) { + lineHeight = parseInt(textBox.css('lineHeight'), 10) * 0.25; + updateTextBoxHeight(); + textBox.bind('input propertychange', updateTextBoxHeight) + } + } + + this.textBox = textBox; + }, + clearTextBoxBind: function () { + if (this.textBox) { + this.textBox.unbind('input propertychange'); + this.textBox = undefined; + } + }, + autoScrollToEditButtons: function () { + var button = $('#id-comments-change'), // TODO: add to cache + btnBounds = null, + contentBounds = this.el.getBoundingClientRect(), + moveY = 0, + padding = 7; + + if (button.length) { + btnBounds = button.get(0).getBoundingClientRect(); + if (btnBounds && contentBounds) { + moveY = contentBounds.bottom - (btnBounds.bottom + padding); + if (moveY < 0) { + this.scroller.scrollTop(this.scroller.getScrollTop() - moveY); + } + } + } + } + } + })()); + Common.Views.Comments = Common.UI.BaseView.extend(_.extend({ el: '#left-panel-comments', template: _.template(panelTemplate), @@ -79,12 +172,128 @@ define([ addCommentHeight: 45, newCommentHeight: 110, textBoxAutoSizeLocked: undefined, // disable autosize textbox + viewmode: false, + + _commentsViewOnItemClick: function (picker, item, record, e) { + var me = this; + var btn, showEditBox, showReplyBox, commentId, replyId, hideAddReply; + + function readdresolves() { + me.update(); + } + + btn = $(e.target); + if (btn) { + showEditBox = record.get('editText'); + showReplyBox = record.get('showReply'); + commentId = record.get('uid'); + replyId = btn.attr('data-value'); + + if (btn.hasClass('btn-edit')) { + if (!_.isUndefined(replyId)) { + me.fireEvent('comment:closeEditing', [commentId]); + me.fireEvent('comment:editReply', [commentId, replyId]); + + me.commentsView.reply = replyId; + + this.autoHeightTextBox(); + + readdresolves(); + + me.hookTextBox(); + + this.autoScrollToEditButtons(); + this.setFocusToTextBox(); + } else { + + if (!showEditBox) { + me.fireEvent('comment:closeEditing'); + record.set('editText', true); + + this.autoHeightTextBox(); + readdresolves(); + this.setFocusToTextBox(); + me.hookTextBox(); + } + } + } else if (btn.hasClass('btn-delete')) { + if (!_.isUndefined(replyId)) { + me.fireEvent('comment:removeReply', [commentId, replyId]); + } else { + me.fireEvent('comment:remove', [commentId]); + Common.NotificationCenter.trigger('edit:complete', me); + } + + me.fireEvent('comment:closeEditing'); + readdresolves(); + } else if (btn.hasClass('user-reply')) { + me.fireEvent('comment:closeEditing'); + record.set('showReply', true); + + readdresolves(); + + this.autoHeightTextBox(); + me.hookTextBox(); + + this.autoScrollToEditButtons(); + this.setFocusToTextBox(); + } else if (btn.hasClass('btn-reply', false)) { + if (showReplyBox) { + me.fireEvent('comment:addReply', [commentId, this.getActiveTextBoxVal()]); + me.fireEvent('comment:closeEditing'); + + readdresolves(); + } + } else if (btn.hasClass('btn-close', false)) { + + me.fireEvent('comment:closeEditing', [commentId]); + + } else if (btn.hasClass('btn-inner-edit', false)) { + if (!_.isUndefined(me.commentsView.reply)) { + me.fireEvent('comment:changeReply', [commentId, me.commentsView.reply, this.getActiveTextBoxVal()]); + me.commentsView.reply = undefined; + } else if (showEditBox) { + me.fireEvent('comment:change', [commentId, this.getActiveTextBoxVal()]); + } + + me.fireEvent('comment:closeEditing'); + + readdresolves(); + + } else if (btn.hasClass('btn-inner-close', false)) { + me.fireEvent('comment:closeEditing'); + + me.commentsView.reply = undefined; + + readdresolves(); + } else if (btn.hasClass('btn-resolve', false)) { + var tip = btn.data('bs.tooltip'); + if (tip) tip.dontShow = true; + + me.fireEvent('comment:resolve', [commentId]); + + readdresolves(); + } else if (btn.hasClass('btn-resolve-check', false)) { + var tip = btn.data('bs.tooltip'); + if (tip) tip.dontShow = true; + + me.fireEvent('comment:resolve', [commentId]); + + readdresolves(); + } else if (!btn.hasClass('msg-reply') && + !btn.hasClass('btn-resolve-check') && + !btn.hasClass('btn-resolve')) { + me.fireEvent('comment:show', [commentId, false]); + } + } + }, initialize: function (options) { Common.UI.BaseView.prototype.initialize.call(this, options); this.store = this.options.store; }, + render: function () { var me = this; @@ -133,255 +342,51 @@ define([ } }); } - var CommentsPanelDataView = Common.UI.DataView.extend((function() { - return { + if (this.commentsView) { + this.commentsView.onResetItems(); + } else { + this.commentsView = new CommentsPanelDataView({ + el: $('.messages-ct',me.el), + store: me.store, + itemTemplate: _.template(replaceWords(commentsTemplate, { + textAddReply: me.textAddReply, + textAdd: me.textAdd, + textCancel: me.textCancel, + textEdit: me.textEdit, + textReply: me.textReply, + textClose: me.textClose, + maxCommLength: Asc.c_oAscMaxCellOrCommentLength + })) + }); - options : { - handleSelect: false, - scrollable: true, - listenStoreEvents: false, - template: _.template('
    ') - }, - - getTextBox: function () { - var text = $(this.el).find('textarea'); - return (text && text.length) ? text : undefined; - }, - setFocusToTextBox: function () { - var text = $(this.el).find('textarea'); - if (text && text.length) { - var val = text.val(); - text.focus(); - text.val(''); - text.val(val); - } - }, - getActiveTextBoxVal: function () { - var text = $(this.el).find('textarea'); - return (text && text.length) ? text.val().trim() : ''; - }, - autoHeightTextBox: function () { - var view = this, - textBox = $(this.el).find('textarea'), - domTextBox = null, - minHeight = 50, - lineHeight = 0, - scrollPos = 0, - oldHeight = 0, - newHeight = 0; - - function updateTextBoxHeight() { - if (domTextBox.scrollHeight > domTextBox.clientHeight) { - textBox.css({height: (domTextBox.scrollHeight + lineHeight) + 'px'}); - } else { - oldHeight = domTextBox.clientHeight; - if (oldHeight >= minHeight) { - - textBox.css({height: minHeight + 'px'}); - - if (domTextBox.scrollHeight > domTextBox.clientHeight) { - newHeight = Math.max(domTextBox.scrollHeight + lineHeight, minHeight); - textBox.css({height: newHeight + 'px'}); - } - } - } - - view.autoScrollToEditButtons(); - } - - if (textBox && textBox.length) { - domTextBox = textBox.get(0); - - if (domTextBox) { - lineHeight = parseInt(textBox.css('lineHeight'), 10) * 0.25; - updateTextBoxHeight(); - textBox.bind('input propertychange', updateTextBoxHeight) - } - } - - this.textBox = textBox; - }, - clearTextBoxBind: function () { - if (this.textBox) { - this.textBox.unbind('input propertychange'); - this.textBox = undefined; - } - }, - autoScrollToEditButtons: function () { - var button = $('#id-comments-change'), // TODO: add to cache - btnBounds = null, - contentBounds = this.el.getBoundingClientRect(), - moveY = 0, - padding = 7; - - if (button.length) { - btnBounds = button.get(0).getBoundingClientRect(); - if (btnBounds && contentBounds) { - moveY = contentBounds.bottom - (btnBounds.bottom + padding); - if (moveY < 0) { - this.scroller.scrollTop(this.scroller.getScrollTop() - moveY); - } - } - } + var addtooltip = function (dataview, view, record) { + if (view.tipsArray) { + view.tipsArray.forEach(function(item){ + item.remove(); + }); } - } - })()); - if (CommentsPanelDataView) { - if (this.commentsView) { - this.commentsView.onResetItems(); - } else { - this.commentsView = new CommentsPanelDataView({ - el: $('.messages-ct',me.el), - store: me.store, - itemTemplate: _.template(replaceWords(commentsTemplate, { - textAddReply: me.textAddReply, - textAdd: me.textAdd, - textCancel: me.textCancel, - textEdit: me.textEdit, - textReply: me.textReply, - textClose: me.textClose, - maxCommLength: Asc.c_oAscMaxCellOrCommentLength - })) + + var arr = [], + btns = $(view.el).find('.btn-resolve'); + btns.tooltip({title: me.textResolve, placement: 'cursor'}); + btns.each(function(idx, item){ + arr.push($(item).data('bs.tooltip').tip()); }); - - var addtooltip = function (dataview, view, record) { - if (view.tipsArray) { - view.tipsArray.forEach(function(item){ - item.remove(); - }); - } - - var arr = [], - btns = $(view.el).find('.btn-resolve'); - btns.tooltip({title: me.textResolve, placement: 'cursor'}); - btns.each(function(idx, item){ - arr.push($(item).data('bs.tooltip').tip()); - }); - btns = $(view.el).find('.btn-resolve-check'); - btns.tooltip({title: me.textOpenAgain, placement: 'cursor'}); - btns.each(function(idx, item){ - arr.push($(item).data('bs.tooltip').tip()); - }); - view.tipsArray = arr; - }; - this.commentsView.on('item:add', addtooltip); - this.commentsView.on('item:remove', addtooltip); - this.commentsView.on('item:change', addtooltip); - - this.commentsView.on('item:click', function (picker, item, record, e) { - var btn, showEditBox, showReplyBox, commentId, replyId, hideAddReply; - - function readdresolves() { - me.update(); - } - - btn = $(e.target); - if (btn) { - showEditBox = record.get('editText'); - showReplyBox = record.get('showReply'); - commentId = record.get('uid'); - replyId = btn.attr('data-value'); - - if (btn.hasClass('btn-edit')) { - if (!_.isUndefined(replyId)) { - me.fireEvent('comment:closeEditing', [commentId]); - me.fireEvent('comment:editReply', [commentId, replyId]); - - me.commentsView.reply = replyId; - - this.autoHeightTextBox(); - - readdresolves(); - - me.hookTextBox(); - - this.autoScrollToEditButtons(); - this.setFocusToTextBox(); - } else { - - if (!showEditBox) { - me.fireEvent('comment:closeEditing'); - record.set('editText', true); - - this.autoHeightTextBox(); - readdresolves(); - this.setFocusToTextBox(); - me.hookTextBox(); - } - } - } else if (btn.hasClass('btn-delete')) { - if (!_.isUndefined(replyId)) { - me.fireEvent('comment:removeReply', [commentId, replyId]); - } else { - me.fireEvent('comment:remove', [commentId]); - Common.NotificationCenter.trigger('edit:complete', me); - } - - me.fireEvent('comment:closeEditing'); - readdresolves(); - } else if (btn.hasClass('user-reply')) { - me.fireEvent('comment:closeEditing'); - record.set('showReply', true); - - readdresolves(); - - this.autoHeightTextBox(); - me.hookTextBox(); - - this.autoScrollToEditButtons(); - this.setFocusToTextBox(); - } else if (btn.hasClass('btn-reply', false)) { - if (showReplyBox) { - me.fireEvent('comment:addReply', [commentId, this.getActiveTextBoxVal()]); - me.fireEvent('comment:closeEditing'); - - readdresolves(); - } - } else if (btn.hasClass('btn-close', false)) { - - me.fireEvent('comment:closeEditing', [commentId]); - - } else if (btn.hasClass('btn-inner-edit', false)) { - if (!_.isUndefined(me.commentsView.reply)) { - me.fireEvent('comment:changeReply', [commentId, me.commentsView.reply, this.getActiveTextBoxVal()]); - me.commentsView.reply = undefined; - } else if (showEditBox) { - me.fireEvent('comment:change', [commentId, this.getActiveTextBoxVal()]); - } - - me.fireEvent('comment:closeEditing'); - - readdresolves(); - - } else if (btn.hasClass('btn-inner-close', false)) { - me.fireEvent('comment:closeEditing'); - - me.commentsView.reply = undefined; - - readdresolves(); - } else if (btn.hasClass('btn-resolve', false)) { - var tip = btn.data('bs.tooltip'); - if (tip) tip.dontShow = true; - - me.fireEvent('comment:resolve', [commentId]); - - readdresolves(); - } else if (btn.hasClass('btn-resolve-check', false)) { - var tip = btn.data('bs.tooltip'); - if (tip) tip.dontShow = true; - - me.fireEvent('comment:resolve', [commentId]); - - readdresolves(); - } else if (!btn.hasClass('msg-reply') && - !btn.hasClass('btn-resolve-check') && - !btn.hasClass('btn-resolve')) { - me.fireEvent('comment:show', [commentId, false]); - } - } + btns = $(view.el).find('.btn-resolve-check'); + btns.tooltip({title: me.textOpenAgain, placement: 'cursor'}); + btns.each(function(idx, item){ + arr.push($(item).data('bs.tooltip').tip()); }); - } + view.tipsArray = arr; + }; + + this.commentsView.on({ + 'item:add': addtooltip, + 'item:remove': addtooltip, + 'item:change': addtooltip, + 'item:click': this._commentsViewOnItemClick.bind(this) + }); } if (!this.rendered) this.setupLayout(); @@ -481,7 +486,7 @@ define([ }, setupLayout: function () { - var me = this, parent = $(me.el); + var me = this, parent = me.$el; var add = $('.new-comment-ct', me.el), to = $('.add-link-ct', me.el), @@ -549,6 +554,42 @@ define([ this.autoHeightTextBox(); }, + changeLayout: function(mode) { + var me = this, + add = $('.new-comment-ct', this.el), + to = $('.add-link-ct', this.el), + msgs = $('.messages-ct', this.el); + msgs.toggleClass('stretch', !mode.canComments); + if (!mode.canComments) { + add.hide(); to.hide(); + this.layout.changeLayout([{el: msgs[0], rely: false, stretch: true}]); + } else { + var container = $('#comments-box', this.el), + items = container.find(' > .layout-item'); + to.show(); + this.layout.changeLayout([{el: items[0], rely: true, + resize: { + hidden: false, + autohide: false, + fmin: (function () { + var height = container.height(); + if (add.css('display') !== 'none') { + if (height * 0.5 < me.newCommentHeight) + return height - me.newCommentHeight; + } + return height * 0.5; + }), + fmax: (function () { + if (add.css('display') !== 'none') + return container.height() - me.newCommentHeight; + return container.height() - me.addCommentHeight; + }) + }}, + {el: items[1], stretch: true}, + {el: items[2], stretch: true}]); + } + }, + updateLayout: function () { var container = $('#comments-box', this.el), add = $('.new-comment-ct', this.el); if (add.css('display') !== 'none') { @@ -561,6 +602,7 @@ define([ autoHeightTextBox: function () { var me = this, domTextBox = null, lineHeight = 0, minHeight = 44; var textBox = $('#comment-msg-new', this.el); + if (textBox.length<1) return; function updateTextBoxHeight() { @@ -617,6 +659,9 @@ define([ message = Common.Utils.String.htmlEncode(message); message.replace(Common.Utils.ipStrongRe, function(subStr) { + var result = /[\.,\?\+;:=!\(\)]+$/.exec(subStr); + if (result) + subStr = subStr.substring(0, result.index); offset = arguments[arguments.length-2]; arr.push({start: offset, end: subStr.length+offset, str: '' + subStr + ''}); return ''; @@ -624,6 +669,9 @@ define([ if (message.length<1000 || message.search(/\S{255,}/)<0) message.replace(Common.Utils.hostnameStrongRe, function(subStr) { + var result = /[\.,\?\+;:=!\(\)]+$/.exec(subStr); + if (result) + subStr = subStr.substring(0, result.index); var ref = (! /(((^https?)|(^ftp)):\/\/)/i.test(subStr) ) ? ('http://' + subStr) : subStr; offset = arguments[arguments.length-2]; len = subStr.length; @@ -662,6 +710,24 @@ define([ return str_res; }, + pickEMail: function (commentId, message) { + var arr = Common.Utils.String.htmlEncode(message).match(/\B[@+][A-Z0-9._%+-]+@[A-Z0-9._]+\.[A-Z]+\b/gi); + arr = _.map(arr, function(str){ + return str.slice(1, str.length); + }); + (arr.length>0) && Common.Gateway.requestSendNotify({ + emails: arr, + actionId: commentId, // comment id + actionLink: { + action: { + type: "comment", + data: commentId + } + }, + message: message //comment text + }); + }, + textComments : 'Comments', textAnonym : 'Guest', textAddCommentToDoc : 'Add Comment to Document', diff --git a/apps/common/main/lib/view/CopyWarningDialog.js b/apps/common/main/lib/view/CopyWarningDialog.js index 427949e05..95b1150b0 100644 --- a/apps/common/main/lib/view/CopyWarningDialog.js +++ b/apps/common/main/lib/view/CopyWarningDialog.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -50,12 +50,14 @@ define([ options: { width : 500, height : 325, - cls : 'modal-dlg copy-warning' + cls : 'modal-dlg copy-warning', + buttons: ['ok'] }, initialize : function(options) { _.extend(this.options, { - title: this.textTitle + title: this.textTitle, + buttons: ['ok'] }, options || {}); this.template = [ @@ -77,10 +79,7 @@ define([ '
    ', '
    ', '
    ', - '
    ', - '' + '
    ' ].join(''); this.options.tpl = _.template(this.template)(this.options); diff --git a/apps/common/main/lib/view/DocumentAccessDialog.js b/apps/common/main/lib/view/DocumentAccessDialog.js index 0826a0824..ecdfa56c1 100644 --- a/apps/common/main/lib/view/DocumentAccessDialog.js +++ b/apps/common/main/lib/view/DocumentAccessDialog.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under diff --git a/apps/common/main/lib/view/ExtendedColorDialog.js b/apps/common/main/lib/view/ExtendedColorDialog.js index ff6e6e86d..2790ee764 100644 --- a/apps/common/main/lib/view/ExtendedColorDialog.js +++ b/apps/common/main/lib/view/ExtendedColorDialog.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -280,7 +280,12 @@ define([ },50); }, - cancelButtonText: 'Cancel', + onPrimary: function() { + this.trigger('onmodalresult', 1); + this.close(true); + return false; + }, + addButtonText: 'Add', textNew: 'New', textCurrent: 'Current', diff --git a/apps/common/main/lib/view/ExternalDiagramEditor.js b/apps/common/main/lib/view/ExternalDiagramEditor.js index 2056186e9..c5f26a44c 100644 --- a/apps/common/main/lib/view/ExternalDiagramEditor.js +++ b/apps/common/main/lib/view/ExternalDiagramEditor.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -61,7 +61,7 @@ define([ '
    ', '
    ', '' ].join(''); diff --git a/apps/common/main/lib/view/ExternalMergeEditor.js b/apps/common/main/lib/view/ExternalMergeEditor.js index f4917af17..3fd1e79f1 100644 --- a/apps/common/main/lib/view/ExternalMergeEditor.js +++ b/apps/common/main/lib/view/ExternalMergeEditor.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -61,7 +61,7 @@ define([ '
    ', '
    ', '' ].join(''); diff --git a/apps/common/main/lib/view/Header.js b/apps/common/main/lib/view/Header.js index 059a732c3..156b67cde 100644 --- a/apps/common/main/lib/view/Header.js +++ b/apps/common/main/lib/view/Header.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -54,6 +54,7 @@ define([ var storeUsers, appConfig; var $userList, $panelUsers, $btnUsers; var $saveStatus; + var _readonlyRights = false; var templateUserItem = '
  • " class="<% if (!user.get("online")) { %> offline <% } if (user.get("view")) {%> viewmode <% } %>">' + @@ -73,7 +74,7 @@ define([ var templateRightBox = '
    ' + '
    ' + - '' + + '' + '
    ' + '<%= textSaveEnd %>' + '
    ' + @@ -99,6 +100,7 @@ define([ '
    '+ '
  • ' + '
    ' + + '
    ' + '
    ' + '
    ' + '
    ' + @@ -109,6 +111,7 @@ define([ ''; var templateTitleBox = '
    ' + + '
    ' + '
    ' + '
    ' + '
    ' + @@ -116,27 +119,26 @@ define([ '
    ' + '
    ' + '
    ' + - '' + + '' + '' + '
    '; function onResetUsers(collection, opts) { var usercount = collection.getEditingCount(); if ( $userList ) { - if ( usercount > 1 || usercount > 0 && appConfig && !appConfig.isEdit && !appConfig.canComments) { + if ( usercount > 1 || usercount > 0 && appConfig && !appConfig.isEdit && !appConfig.isRestrictedEdit) { $userList.html(templateUserList({ users: collection.chain().filter(function(item){return item.get('online') && !item.get('view')}).groupBy(function(item) {return item.get('idOriginal');}).value(), usertpl: _.template(templateUserItem), fnEncode: Common.Utils.String.htmlEncode })); - if (!$userList.scroller) - $userList.scroller = new Common.UI.Scroller({ - el: $userList.find('ul'), - useKeyboard: true, - minScrollbarLength: 40, - alwaysVisibleY: true - }); + $userList.scroller = new Common.UI.Scroller({ + el: $userList.find('ul'), + useKeyboard: true, + minScrollbarLength: 40, + alwaysVisibleY: true + }); $userList.scroller.update({minScrollbarLength : 40, alwaysVisibleY: true}); } else { $userList.empty(); @@ -151,7 +153,9 @@ define([ }; function applyUsers(count, originalCount) { - var has_edit_users = count > 1 || count > 0 && appConfig && !appConfig.isEdit && !appConfig.canComments; // has other user(s) who edit document + if (!$btnUsers) return; + + var has_edit_users = count > 1 || count > 0 && appConfig && !appConfig.isEdit && !appConfig.isRestrictedEdit; // has other user(s) who edit document if ( has_edit_users ) { $btnUsers .attr('data-toggle', 'dropdown') @@ -165,7 +169,7 @@ define([ .removeClass('dropdown-toggle') .menu = false; - $panelUsers[(appConfig && !appConfig.isReviewOnly && appConfig.sharingSettingsUrl && appConfig.sharingSettingsUrl.length) ? 'show' : 'hide'](); + $panelUsers[(!_readonlyRights && appConfig && !appConfig.isReviewOnly && appConfig.sharingSettingsUrl && appConfig.sharingSettingsUrl.length) ? 'show' : 'hide'](); } $btnUsers.find('.caption') @@ -180,20 +184,24 @@ define([ } } + function onLostEditRights() { + _readonlyRights = true; + $panelUsers.find('#tlb-change-rights').hide(); + $btnUsers && !$btnUsers.menu && $panelUsers.hide(); + } + function onUsersClick(e) { if ( !$btnUsers.menu ) { $panelUsers.removeClass('open'); this.fireEvent('click:users', this); + } else { + var usertip = $btnUsers.data('bs.tooltip'); + if ( usertip ) { + if ( usertip.dontShow===undefined) + usertip.dontShow = true; - return false; - } - - var usertip = $btnUsers.data('bs.tooltip'); - if ( usertip ) { - if ( usertip.dontShow===undefined) - usertip.dontShow = true; - - usertip.hide(); + usertip.hide(); + } } } @@ -209,11 +217,12 @@ define([ if ( me.logo ) me.logo.children(0).on('click', function (e) { - var _url = !!me.branding && !!me.branding.logo && !!me.branding.logo.url ? - me.branding.logo.url : 'http://www.onlyoffice.com'; - - var newDocumentPage = window.open(_url); - newDocumentPage && newDocumentPage.focus(); + var _url = !!me.branding && !!me.branding.logo && (me.branding.logo.url!==undefined) ? + me.branding.logo.url : '{{PUBLISHER_URL}}'; + if (_url) { + var newDocumentPage = window.open(_url); + newDocumentPage && newDocumentPage.focus(); + } }); onResetUsers(storeUsers); @@ -227,7 +236,7 @@ define([ var editingUsers = storeUsers.getEditingCount(); $btnUsers.tooltip({ - title: (editingUsers > 1 || editingUsers>0 && !appConfig.isEdit && !appConfig.canComments) ? me.tipViewUsers : me.tipAccessRights, + title: (editingUsers > 1 || editingUsers>0 && !appConfig.isEdit && !appConfig.isRestrictedEdit) ? me.tipViewUsers : me.tipAccessRights, titleNorm: me.tipAccessRights, titleExt: me.tipViewUsers, placement: 'bottom', @@ -243,7 +252,7 @@ define([ }); $labelChangeRights[(!mode.isOffline && !mode.isReviewOnly && mode.sharingSettingsUrl && mode.sharingSettingsUrl.length)?'show':'hide'](); - $panelUsers[(editingUsers > 1 || editingUsers > 0 && !appConfig.isEdit && !appConfig.canComments || !mode.isOffline && !mode.isReviewOnly && mode.sharingSettingsUrl && mode.sharingSettingsUrl.length) ? 'show' : 'hide'](); + $panelUsers[(editingUsers > 1 || editingUsers > 0 && !appConfig.isEdit && !appConfig.isRestrictedEdit || !mode.isOffline && !mode.isReviewOnly && mode.sharingSettingsUrl && mode.sharingSettingsUrl.length) ? 'show' : 'hide'](); if ( $saveStatus ) { $saveStatus.attr('data-width', me.textSaveExpander); @@ -304,6 +313,24 @@ define([ me.btnOptions.updateHint(me.tipViewSettings); } + function onAppConfig(config) { + var me = this; + if ( config.canUndock ) { + me.btnUndock = new Common.UI.Button({ + cls: 'btn-header no-caret', + iconCls: 'svgicon svg-btn-undock', + hint: me.tipUndock, + split: true + }); + + me.btnUndock.on('click', function (e) { + Common.NotificationCenter.trigger('action:undocking', 'undock'); + }); + + me.btnUndock.render($('#toolbar .box-tabs #slot-btn-undock')); + } + } + function onDocNameKeyDown(e) { var me = this; @@ -338,6 +365,13 @@ define([ } } + function onAppUndocked(c) { + var me = this; + if ( me.btnUndock ) { + c.status == 'undocked' ? me.btnUndock.hide() : me.btnUndock.show(); + } + } + return { options: { branding: {}, @@ -385,12 +419,13 @@ define([ me.mnuZoom = {options: {value: 100}}; - Common.NotificationCenter.on('app:ready', function(mode) { - Common.Utils.asyncCall(onAppReady, me, mode); - }); - Common.NotificationCenter.on('app:face', function(mode) { - Common.Utils.asyncCall(onAppShowed, me, mode); + Common.NotificationCenter.on({ + 'app:ready': function(mode) {Common.Utils.asyncCall(onAppReady, me, mode);}, + 'app:face': function(mode) {Common.Utils.asyncCall(onAppShowed, me, mode);}, + 'app:config' : function (c) {Common.Utils.asyncCall(onAppConfig, me, c);}, + 'undock:status': onAppUndocked.bind(this) }); + Common.NotificationCenter.on('collaboration:sharingdeny', onLostEditRights); }, render: function (el, role) { @@ -417,6 +452,7 @@ define([ if (this.branding && this.branding.logo && this.branding.logo.image && this.logo) { this.logo.html(''); this.logo.css({'background-image': 'none', width: 'auto'}); + (this.branding.logo.url || this.branding.logo.url===undefined) && this.logo.addClass('link'); } return $html; @@ -456,13 +492,13 @@ define([ if ( !config.isEdit ) { if ( (config.canDownload || config.canDownloadOrigin) && !config.isOffline ) - this.btnDownload = createTitleButton('svg-btn-download', $html.find('#slot-hbtn-download')); + this.btnDownload = createTitleButton('svg-btn-download', $html.findById('#slot-hbtn-download')); if ( config.canPrint ) - this.btnPrint = createTitleButton('svg-btn-print', $html.find('#slot-hbtn-print')); + this.btnPrint = createTitleButton('svg-btn-print', $html.findById('#slot-hbtn-print')); if ( config.canEdit && config.canRequestEditRights ) - this.btnEdit = createTitleButton('svg-btn-edit', $html.find('#slot-hbtn-edit')); + this.btnEdit = createTitleButton('svg-btn-edit', $html.findById('#slot-hbtn-edit')); } me.btnOptions.render($html.find('#slot-btn-options')); @@ -486,12 +522,12 @@ define([ me.setUserName(me.options.userName); if ( config.canPrint && config.isEdit ) { - me.btnPrint = createTitleButton('svg-btn-print', $('#slot-btn-dt-print', $html)); + me.btnPrint = createTitleButton('svg-btn-print', $html.findById('#slot-btn-dt-print'), true); } - me.btnSave = createTitleButton('svg-btn-save', $('#slot-btn-dt-save', $html), true); - me.btnUndo = createTitleButton('svg-btn-undo', $('#slot-btn-dt-undo', $html), true); - me.btnRedo = createTitleButton('svg-btn-redo', $('#slot-btn-dt-redo', $html), true); + me.btnSave = createTitleButton('svg-btn-save', $html.findById('#slot-btn-dt-save'), true); + me.btnUndo = createTitleButton('svg-btn-undo', $html.findById('#slot-btn-dt-undo'), true); + me.btnRedo = createTitleButton('svg-btn-redo', $html.findById('#slot-btn-dt-redo'), true); if ( me.btnSave.$icon.is('svg') ) { me.btnSave.$icon.addClass('icon-save'); @@ -527,6 +563,7 @@ define([ if (element) { element.html(''); element.css({'background-image': 'none', width: 'auto'}); + (value.logo.url || value.logo.url===undefined) && element.addClass('link'); } } } @@ -645,7 +682,7 @@ define([ $btnUsers.addClass('disabled').attr('disabled', 'disabled'); else $btnUsers.removeClass('disabled').attr('disabled', ''); } else { - function _lockButton(btn) { + var _lockButton = function (btn) { if ( btn ) { if ( lock ) { btn.keepState = { @@ -657,7 +694,7 @@ define([ delete btn.keepState; } } - } + }; switch ( alias ) { case 'undo': _lockButton(me.btnUndo); break; @@ -692,6 +729,7 @@ define([ tipSave: 'Save', tipUndo: 'Undo', tipRedo: 'Redo', + tipUndock: 'Undock', textCompactView: 'Hide Toolbar', textHideStatusBar: 'Hide Status Bar', textHideLines: 'Hide Rulers', diff --git a/apps/common/main/lib/view/History.js b/apps/common/main/lib/view/History.js index e915c66ae..aabc4aa31 100644 --- a/apps/common/main/lib/view/History.js +++ b/apps/common/main/lib/view/History.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -83,7 +83,7 @@ define([ 'style="display: block; ' + '<% if (!isRevision) { %>' + 'padding-left: 40px;' + '<% } %>' + '<% if (canRestore && selected) { %>' + 'padding-bottom: 6px;' + '<% } %>' +'">', '
    <%= created %>
    ', '<% if (markedAsVersion) { %>', - '
    ver.<%=version%>
    ', + '
    ' + this.textVer + '<%=version%>
    ', '<% } %>', '<% if (isRevision && hasChanges) { %>', '
    ', @@ -150,7 +150,8 @@ define([ textHide: 'Collapse', textCloseHistory: 'Close History', textHideAll: 'Hide detailed changes', - textShowAll: 'Show detailed changes' + textShowAll: 'Show detailed changes', + textVer: 'ver.' }, Common.Views.History || {})) }); \ No newline at end of file diff --git a/apps/common/main/lib/view/ImageFromUrlDialog.js b/apps/common/main/lib/view/ImageFromUrlDialog.js index 5f92912fc..0f8cfff5e 100644 --- a/apps/common/main/lib/view/ImageFromUrlDialog.js +++ b/apps/common/main/lib/view/ImageFromUrlDialog.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -46,7 +46,9 @@ define([ options: { width: 330, header: false, - cls: 'modal-dlg' + cls: 'modal-dlg', + buttons: ['ok', 'cancel'], + footerCls: 'right' }, initialize : function(options) { @@ -58,10 +60,6 @@ define([ '', '
    ', '
    ', - '
    ', - '' ].join(''); @@ -87,7 +85,6 @@ define([ var $window = this.getChild(); $window.find('.btn').on('click', _.bind(this.onBtnClick, this)); - $window.find('input').on('keypress', _.bind(this.onKeyPress, this)); }, show: function() { @@ -99,10 +96,9 @@ define([ },500); }, - onKeyPress: function(event) { - if (event.keyCode == Common.UI.Keys.RETURN) { - this._handleInput('ok'); - } + onPrimary: function(event) { + this._handleInput('ok'); + return false; }, onBtnClick: function(event) { @@ -125,8 +121,6 @@ define([ }, textUrl : 'Paste an image URL:', - cancelButtonText: 'Cancel', - okButtonText : 'Ok', txtEmpty : 'This field is required', txtNotUrl : 'This field should be a URL in the format \"http://www.example.com\"' }, Common.Views.ImageFromUrlDialog || {})); diff --git a/apps/common/main/lib/view/InsertTableDialog.js b/apps/common/main/lib/view/InsertTableDialog.js index 08ededc93..b4b65d017 100644 --- a/apps/common/main/lib/view/InsertTableDialog.js +++ b/apps/common/main/lib/view/InsertTableDialog.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -51,7 +51,8 @@ define([ height: 156, style: 'min-width: 230px;', cls: 'modal-dlg', - split: false + split: false, + buttons: ['ok', 'cancel'] }, initialize : function(options) { @@ -67,10 +68,6 @@ define([ '
    ', '
    ', '
    ', - '
    ', - '' ].join(''); @@ -138,8 +135,6 @@ define([ txtColumns: 'Number of Columns', txtRows: 'Number of Rows', textInvalidRowsCols: 'You need to specify valid rows and columns count.', - cancelButtonText: 'Cancel', - okButtonText: 'Ok', txtMinText: 'The minimum value for this field is {0}', txtMaxText: 'The maximum value for this field is {0}' }, Common.Views.InsertTableDialog || {})) diff --git a/apps/common/main/lib/view/LanguageDialog.js b/apps/common/main/lib/view/LanguageDialog.js index 26f87e7c3..ad4216a15 100644 --- a/apps/common/main/lib/view/LanguageDialog.js +++ b/apps/common/main/lib/view/LanguageDialog.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -51,25 +51,22 @@ define([ options: { header: false, width: 350, - cls: 'modal-dlg' + cls: 'modal-dlg', + buttons: ['ok', 'cancel'], + footerCls: 'right' }, template: '
    ' + - '
    ' + - '' + - '
    ' + - '
    ' + - '
    ' + - '
    ' + - '', + '
    ' + + '' + + '
    ' + + '
    ' + + '
    ' + + '
    ', initialize : function(options) { _.extend(this.options, options || {}, { - label: this.labelSelect, - btns: {ok: this.btnOk, cancel: this.btnCancel} + label: this.labelSelect }); this.options.tpl = _.template(this.template)(this.options); @@ -85,31 +82,33 @@ define([ this.cmbLanguage = new Common.UI.ComboBox({ el: $window.find('#id-document-language'), cls: 'input-group-nr', - menuStyle: 'min-width: 318px; max-height: 300px;', + menuStyle: 'min-width: 318px; max-height: 285px;', editable: false, template: _.template([ '', - '', - '', - '', - '', + '', + '', + '', + '', '' ].join('')), - data: this.options.languages + data: this.options.languages, + search: true }); if (this.cmbLanguage.scroller) this.cmbLanguage.scroller.update({alwaysVisibleY: true}); this.cmbLanguage.on('selected', _.bind(this.onLangSelect, this)); - this.cmbLanguage.setValue(Common.util.LanguageInfo.getLocalLanguageName(this.options.current)[0]); + var langname = Common.util.LanguageInfo.getLocalLanguageName(this.options.current); + this.cmbLanguage.setValue(langname[0], langname[1]); this.onLangSelect(this.cmbLanguage, this.cmbLanguage.getSelectedRecord()); }, @@ -129,15 +128,19 @@ define([ }, onLangSelect: function(cmb, rec, e) { - var icon = cmb.$el.find('.input-icon'), - plang = icon.attr('lang'); - - if (plang) icon.removeClass(plang); - icon.addClass(rec.value).attr('lang',rec.value); + cmb.$el.find('.input-icon').toggleClass('spellcheck-lang', rec && rec.spellcheck); + cmb._input.css('padding-left', rec && rec.spellcheck ? 25 : 3); }, - labelSelect : 'Select document language', - btnCancel : 'Cancel', - btnOk : 'Ok' + onPrimary: function() { + if (this.options.handler) { + this.options.handler.call(this, 'ok', this.cmbLanguage.getValue()); + } + + this.close(); + return false; + }, + + labelSelect : 'Select document language' }, Common.Views.LanguageDialog || {})) }); \ No newline at end of file diff --git a/apps/common/main/lib/view/OpenDialog.js b/apps/common/main/lib/view/OpenDialog.js index 1157b7184..467717eb6 100644 --- a/apps/common/main/lib/view/OpenDialog.js +++ b/apps/common/main/lib/view/OpenDialog.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -53,24 +53,35 @@ define([ var t = this, _options = {}; + var width, height; + + if (options.preview) { + width = 414; + height = 277; + } else { + width = (options.type !== Common.Utils.importTextType.DRM) ? 340 : (options.warning ? 370 : 262); + height = (options.type == Common.Utils.importTextType.CSV || options.type == Common.Utils.importTextType.Paste || options.type == Common.Utils.importTextType.Columns) ? 190 : (options.warning ? 187 : 147); + } + _.extend(_options, { - closable : false, + closable : false, // true if save settings preview : options.preview, warning : options.warning, - width : (options.preview) ? 414 : ((options.type == Asc.c_oAscAdvancedOptionsID.DRM && options.warning) ? 370 : 262), - height : (options.preview) ? 277 : ((options.type == Asc.c_oAscAdvancedOptionsID.CSV) ? 190 : (options.warning ? 187 : 147)), + codepages : options.codepages, + width : width, + height : height, header : true, cls : 'open-dlg', contentTemplate : '', - title : (options.type == Asc.c_oAscAdvancedOptionsID.DRM) ? t.txtTitleProtected : t.txtTitle.replace('%1', (options.type == Asc.c_oAscAdvancedOptionsID.CSV) ? 'CSV' : 'TXT'), - toolcallback : _.bind(t.onToolClose, t) + toolcallback : _.bind(t.onToolClose, t), + closeFile : false }, options); this.template = options.template || [ '
    ', '
    ', - '<% if (type == Asc.c_oAscAdvancedOptionsID.DRM) { %>', + '<% if (type == Common.Utils.importTextType.DRM) { %>', '<% if (warning) { %>', '
    ', '
    ', @@ -85,13 +96,15 @@ define([ '
    ', '<% } %>', '<% } else { %>', - '
    ', + '<% if (codepages && codepages.length>0) { %>', + '
    ', '', '
    ', - '
    ', + '
    ', '
    ', '
    ', - '<% if (type == Asc.c_oAscAdvancedOptionsID.CSV) { %>', + '<% } %>', + '<% if (type == Common.Utils.importTextType.CSV || type == Common.Utils.importTextType.Paste || type == Common.Utils.importTextType.Columns) { %>', '
    ', '', '
    ', @@ -119,15 +132,19 @@ define([ '
    ', '' ].join(''); this.handler = _options.handler; this.type = _options.type; this.preview = _options.preview; + this.previewData = _options.previewData; this.warning = _options.warning || false; this.closable = _options.closable; this.codepages = _options.codepages; @@ -153,7 +170,7 @@ define([ this.previewScrolled = this.$window.find('#id-preview'); this.previewInner = this.previewScrolled.find('div:first-child'); - if (this.type == Asc.c_oAscAdvancedOptionsID.DRM) { + if (this.type == Common.Utils.importTextType.DRM) { this.inputPwd = new Common.UI.InputField({ el: $('#id-password-txt'), type: 'text', @@ -162,7 +179,7 @@ define([ return me.txtIncorrectPwd; } }); - this.$window.find('input').on('keypress', _.bind(this.onKeyPress, this)); + this.$window.find('input').on('input', function(){ if ($(this).val() !== '') { ($(this).attr('type') !== 'password') && $(this).attr('type', 'password'); @@ -172,20 +189,21 @@ define([ }); } else { this.initCodePages(); - if (this.preview) - this.updatePreview(); - this.onPrimary = function() { - me._handleInput('ok'); - return false; - }; + if (this.preview) { + (this.previewData) ? this.previewCallback(this.previewData) : this.updatePreview(); + } } + this.onPrimary = function() { + me._handleInput('ok'); + return false; + }; } }, show: function() { Common.UI.Window.prototype.show.apply(this, arguments); - if (this.type == Asc.c_oAscAdvancedOptionsID.DRM) { + if (this.type == Common.Utils.importTextType.DRM) { var me = this; setTimeout(function(){ me.inputPwd.cmpEl.find('input').focus(); @@ -195,13 +213,6 @@ define([ } }, - onKeyPress: function(event) { - if (event.keyCode == Common.UI.Keys.RETURN) { - this._handleInput('ok'); - } else if (this.closable && event.keyCode == Common.UI.Keys.ESC) - this._handleInput('cancel'); - }, - onBtnClick: function(event) { this._handleInput(event.currentTarget.attributes['result'].value); }, @@ -212,15 +223,18 @@ define([ _handleInput: function(state) { if (this.handler) { - if (this.cmbEncoding) { - var encoding = (!this.cmbEncoding.isDisabled()) ? this.cmbEncoding.getValue() : - ((this.settings && this.settings.asc_getCodePage()) ? this.settings.asc_getCodePage() : 0), + if (this.type == Common.Utils.importTextType.DRM) { + this.handler.call(this, state, this.inputPwd.getValue()); + } else { + var encoding = (this.cmbEncoding && !this.cmbEncoding.isDisabled()) ? this.cmbEncoding.getValue() : + ((this.settings && this.settings.asc_getCodePage()) ? this.settings.asc_getCodePage() : 0), delimiter = this.cmbDelimiter ? this.cmbDelimiter.getValue() : null, delimiterChar = (delimiter == -1) ? this.inputDelimiter.getValue() : null; (delimiter == -1) && (delimiter = null); - this.handler.call(this, encoding, delimiter, delimiterChar); - } else { - this.handler.call(this, state, this.inputPwd.getValue()); + if (!this.closable && this.type == Common.Utils.importTextType.TXT) { //save last encoding only for opening txt files + Common.localStorage.setItem("de-settings-open-encoding", encoding); + } + this.handler.call(this, state, encoding, delimiter, delimiterChar); } } @@ -245,49 +259,55 @@ define([ } length = encodedata.length; - for (i = 0; i < length; ++i) { - listItems.push({ - value: encodedata[i][0], - displayValue: Common.Utils.String.htmlEncode(encodedata[i][1]), - lcid: encodedata[i][2] || '' - }); - } - - var itemsTemplate = - _.template([ - '<% _.each(items, function(item) { %>', - '
  • ', - '
    <%= item.displayValue %>
    ', - '', - '
  • ', - '<% }); %>' - ].join('')); - - this.cmbEncoding = new Common.UI.ComboBox({ - el: $('#id-codepages-combo', this.$window), - style: 'width: 230px;', - menuStyle: 'min-width: 230px; max-height: 200px;', - cls: 'input-group-nr', - menuCls: 'scrollable-menu', - data: listItems, - editable: false, - disabled: true, - itemsTemplate: itemsTemplate - }); - if (length) { + for (i = 0; i < length; ++i) { + listItems.push({ + value: encodedata[i][0], + displayValue: Common.Utils.String.htmlEncode(encodedata[i][1]), + lcid: encodedata[i][2] || '' + }); + } + + var itemsTemplate = + _.template([ + '<% _.each(items, function(item) { %>', + '
  • ', + '
    <%= item.displayValue %>
    ', + '', + '
  • ', + '<% }); %>' + ].join('')); + + this.cmbEncoding = new Common.UI.ComboBox({ + el: $('#id-codepages-combo', this.$window), + style: 'width: 100%;', + menuStyle: 'min-width: 100%; max-height: 200px;', + cls: 'input-group-nr', + menuCls: 'scrollable-menu', + data: listItems, + editable: false, + disabled: true, + search: true, + itemsTemplate: itemsTemplate + }); + this.cmbEncoding.setDisabled(false); - this.cmbEncoding.setValue((this.settings && this.settings.asc_getCodePage()) ? this.settings.asc_getCodePage() : encodedata[0][0]); + var encoding = (this.settings && this.settings.asc_getCodePage()) ? this.settings.asc_getCodePage() : encodedata[0][0]; + if (!this.closable && this.type == Common.Utils.importTextType.TXT) { // only for opening txt files + var value = Common.localStorage.getItem("de-settings-open-encoding"); + value && (encoding = parseInt(value)); + } + this.cmbEncoding.setValue(encoding); if (this.preview) this.cmbEncoding.on('selected', _.bind(this.onCmbEncodingSelect, this)); var ul = this.cmbEncoding.cmpEl.find('ul'), a = ul.find('li:nth(0) a'), width = ul.width() - parseInt(a.css('padding-left')) - parseInt(a.css('padding-right')) - 50; - ul.find('li div').width(width + 10); + ul.find('li div').width(width); } - if (this.type == Asc.c_oAscAdvancedOptionsID.CSV) { + if (this.type == Common.Utils.importTextType.CSV || this.type == Common.Utils.importTextType.Paste || this.type == Common.Utils.importTextType.Columns) { this.cmbDelimiter = new Common.UI.ComboBox({ el: $('#id-delimiters-combo', this.$window), style: 'width: 100px;', @@ -320,16 +340,23 @@ define([ }, updatePreview: function() { - var encoding = (!this.cmbEncoding.isDisabled()) ? this.cmbEncoding.getValue() : + var encoding = (this.cmbEncoding && !this.cmbEncoding.isDisabled()) ? this.cmbEncoding.getValue() : ((this.settings && this.settings.asc_getCodePage()) ? this.settings.asc_getCodePage() : 0); + var delimiter = this.cmbDelimiter ? this.cmbDelimiter.getValue() : null, + delimiterChar = (delimiter == -1) ? this.inputDelimiter.getValue() : null; + (delimiter == -1) && (delimiter = null); - if (this.type == Asc.c_oAscAdvancedOptionsID.CSV) { - var delimiter = this.cmbDelimiter ? this.cmbDelimiter.getValue() : null, - delimiterChar = (delimiter == -1) ? this.inputDelimiter.getValue() : null; - (delimiter == -1) && (delimiter = null); - this.api.asc_decodeBuffer(this.preview, new Asc.asc_CCSVAdvancedOptions(encoding, delimiter, delimiterChar), _.bind(this.previewCallback, this)); - } else { - this.api.asc_decodeBuffer(this.preview, new Asc.asc_CTXTAdvancedOptions(encoding), _.bind(this.previewCallback, this)); + switch (this.type) { + case Common.Utils.importTextType.CSV: + this.api.asc_decodeBuffer(this.preview, new Asc.asc_CTextOptions(encoding, delimiter, delimiterChar), _.bind(this.previewCallback, this)); + break; + case Common.Utils.importTextType.TXT: + this.api.asc_decodeBuffer(this.preview, new Asc.asc_CTextOptions(encoding), _.bind(this.previewCallback, this)); + break; + case Common.Utils.importTextType.Paste: + case Common.Utils.importTextType.Columns: + this.api.asc_TextImport(new Asc.asc_CTextOptions(encoding, delimiter, delimiterChar), _.bind(this.previewCallback, this), this.type == Common.Utils.importTextType.Paste); + break; } }, @@ -371,7 +398,7 @@ define([ delete this.scrollerX; } - if (this.type == Asc.c_oAscAdvancedOptionsID.CSV) { + if (this.type == Common.Utils.importTextType.CSV || this.type == Common.Utils.importTextType.Paste || this.type == Common.Utils.importTextType.Columns) { var maxlength = 0; for (var i=0; imaxlength) @@ -379,7 +406,7 @@ define([ } var tpl = ''; for (var i=0; i'; } @@ -392,7 +419,7 @@ define([ } else { var tpl = '
    '; for (var i=0; i'; + tpl += ''; } tpl += '
    ' + Common.Utils.String.htmlEncode(data[i]) + '
    '; } @@ -408,6 +435,7 @@ define([ onCmbDelimiterSelect: function(combo, record){ this.inputDelimiter.setVisible(record.value == -1); + (record.value == -1) && this.inputDelimiter.cmpEl.find('input').focus(); if (this.preview) this.updatePreview(); }, @@ -416,8 +444,6 @@ define([ this.updatePreview(); }, - okButtonText : "OK", - cancelButtonText : "Cancel", txtDelimiter : "Delimiter", txtEncoding : "Encoding ", txtSpace : "Space", diff --git a/apps/common/main/lib/view/PasswordDialog.js b/apps/common/main/lib/view/PasswordDialog.js index 02ab68cf1..09ed9007c 100644 --- a/apps/common/main/lib/view/PasswordDialog.js +++ b/apps/common/main/lib/view/PasswordDialog.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -59,7 +59,8 @@ define([ header : true, cls : 'modal-dlg', contentTemplate : '', - title : t.txtTitle + title : t.txtTitle, + buttons: ['ok', 'cancel'] }, options); @@ -77,11 +78,7 @@ define([ '
    ', '
    ', '
    ', - '
    ', - '' + '
    ' ].join(''); this.handler = options.handler; @@ -114,7 +111,6 @@ define([ return me.txtIncorrectPwd; } }); - this.$window.find('input').on('keypress', _.bind(this.onKeyPress, this)); } }, @@ -127,10 +123,9 @@ define([ }, 500); }, - onKeyPress: function(event) { - if (event.keyCode == Common.UI.Keys.RETURN) { - this._handleInput('ok'); - } + onPrimary: function(event) { + this._handleInput('ok'); + return false; }, onBtnClick: function(event) { @@ -156,8 +151,6 @@ define([ this.close(); }, - okButtonText : "OK", - cancelButtonText : "Cancel", txtTitle : "Set Password", txtPassword : "Password", txtDescription : "A Password is required to open this document", diff --git a/apps/common/main/lib/view/Plugins.js b/apps/common/main/lib/view/Plugins.js index 6a98e3200..0036808f2 100644 --- a/apps/common/main/lib/view/Plugins.js +++ b/apps/common/main/lib/view/Plugins.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -88,22 +88,22 @@ define([ el && (this.$el = $(el)); this.$el.html(this.template({scope: this})); - this.viewPluginsList = new Common.UI.DataView({ - el: $('#plugins-list'), - store: this.storePlugins, - enableKeyEvents: false, - itemTemplate: _.template([ - '
    ', - '
    1) ? 1 : 0) + (variations[currentVariation].get("icons").length>2 ? 2 : 0)] %>);">
    ', - '<% if (variations.length>1) { %>', - '
    ', - '<% } %>', - '<%= name %>', - '
    ' - ].join('')) - }); - this.lockedControls.push(this.viewPluginsList); - this.viewPluginsList.cmpEl.off('click'); + // this.viewPluginsList = new Common.UI.DataView({ + // el: $('#plugins-list'), + // store: this.storePlugins, + // enableKeyEvents: false, + // itemTemplate: _.template([ + // '
    ', + // '
    1) ? 1 : 0) + (variations[currentVariation].get("icons").length>2 ? 2 : 0)] %>);">
    ', + // '<% if (variations.length>1) { %>', + // '
    ', + // '<% } %>', + // '<%= name %>', + // '
    ' + // ].join('')) + // }); + // this.lockedControls.push(this.viewPluginsList); + // this.viewPluginsList.cmpEl.off('click'); this.pluginName = $('#current-plugin-header label'); this.pluginsPanel = $('#plugins-box'); @@ -190,7 +190,7 @@ define([ item.setDisabled(disable); }); - this.pluginsMask.css('display', disable ? 'block' : 'none'); + this.pluginsMask && this.pluginsMask.css('display', disable ? 'block' : 'none'); } }, @@ -368,7 +368,7 @@ define([ '
    ', '', '<% } %>' diff --git a/apps/common/main/lib/view/Protection.js b/apps/common/main/lib/view/Protection.js index 71d7b0397..6bcf79d6d 100644 --- a/apps/common/main/lib/view/Protection.js +++ b/apps/common/main/lib/view/Protection.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -65,7 +65,7 @@ define([ function setEvents() { var me = this; - if ( me.appConfig.isDesktopApp && me.appConfig.isOffline ) { + if (me.appConfig.isPasswordSupport) { this.btnsAddPwd.concat(this.btnsChangePwd).forEach(function(button) { button.on('click', function (b, e) { me.fireEvent('protect:password', [b, 'add']); @@ -81,19 +81,19 @@ define([ this.btnPwd.menu.on('item:click', function (menu, item, e) { me.fireEvent('protect:password', [menu, item.value]); }); + } - if (me.appConfig.canProtect) { - if (this.btnSignature.menu) - this.btnSignature.menu.on('item:click', function (menu, item, e) { - me.fireEvent('protect:signature', [item.value, false]); - }); - - this.btnsInvisibleSignature.forEach(function(button) { - button.on('click', function (b, e) { - me.fireEvent('protect:signature', ['invisible']); - }); + if (me.appConfig.isSignatureSupport) { + if (this.btnSignature.menu) + this.btnSignature.menu.on('item:click', function (menu, item, e) { + me.fireEvent('protect:signature', [item.value, false]); }); - } + + this.btnsInvisibleSignature.forEach(function(button) { + button.on('click', function (b, e) { + me.fireEvent('protect:signature', ['invisible']); + }); + }); } } @@ -111,12 +111,12 @@ define([ this.btnsDelPwd = []; this.btnsChangePwd = []; - this._state = {disabled: false, hasPassword: false, disabledPassword: false}; + this._state = {disabled: false, hasPassword: false, disabledPassword: false, invisibleSignDisabled: false}; var filter = Common.localStorage.getKeysFilter(); this.appPrefix = (filter && filter.length) ? filter.split(',')[0] : ''; - if ( this.appConfig.isDesktopApp && this.appConfig.isOffline ) { + if ( this.appConfig.isPasswordSupport ) { this.btnAddPwd = new Common.UI.Button({ cls: 'btn-toolbar x-huge icon-top', iconCls: 'btn-ic-protect', @@ -131,18 +131,18 @@ define([ menu: true, visible: false }); - - if (this.appConfig.canProtect) { - this.btnSignature = new Common.UI.Button({ - cls: 'btn-toolbar x-huge icon-top', - iconCls: 'btn-ic-signature', - caption: this.txtSignature, - menu: (this.appPrefix !== 'pe-') - }); - if (!this.btnSignature.menu) - this.btnsInvisibleSignature.push(this.btnSignature); - } } + if (this.appConfig.isSignatureSupport) { + this.btnSignature = new Common.UI.Button({ + cls: 'btn-toolbar x-huge icon-top', + iconCls: 'btn-ic-signature', + caption: this.txtSignature, + menu: (this.appPrefix !== 'pe-') + }); + if (!this.btnSignature.menu) + this.btnsInvisibleSignature.push(this.btnSignature); + } + Common.NotificationCenter.on('app:ready', this.onAppReady.bind(this)); }, @@ -159,25 +159,26 @@ define([ (new Promise(function (accept, reject) { accept(); })).then(function(){ - if ( config.isDesktopApp && config.isOffline) { - me.btnAddPwd.updateHint(me.hintAddPwd); - me.btnPwd.updateHint(me.hintPwd); - - me.btnPwd.setMenu( - new Common.UI.Menu({ - items: [ - { - caption: me.txtChangePwd, - value: 'add' - }, - { - caption: me.txtDeletePwd, - value: 'delete' - } - ] - }) - ); + if ( config.canProtect) { + if ( config.isPasswordSupport) { + me.btnAddPwd.updateHint(me.hintAddPwd); + me.btnPwd.updateHint(me.hintPwd); + me.btnPwd.setMenu( + new Common.UI.Menu({ + items: [ + { + caption: me.txtChangePwd, + value: 'add' + }, + { + caption: me.txtDeletePwd, + value: 'delete' + } + ] + }) + ); + } if (me.btnSignature) { me.btnSignature.updateHint((me.btnSignature.menu) ? me.hintSignature : me.txtInvisibleSignature); me.btnSignature.menu && me.btnSignature.setMenu( @@ -206,9 +207,9 @@ define([ getPanel: function () { this.$el = $(_.template(template)( {} )); - if ( this.appConfig.isDesktopApp && this.appConfig.isOffline ) { - this.btnAddPwd.render(this.$el.find('#slot-btn-add-password')); - this.btnPwd.render(this.$el.find('#slot-btn-change-password')); + if ( this.appConfig.canProtect ) { + this.btnAddPwd && this.btnAddPwd.render(this.$el.find('#slot-btn-add-password')); + this.btnPwd && this.btnPwd.render(this.$el.find('#slot-btn-change-password')); this.btnSignature && this.btnSignature.render(this.$el.find('#slot-btn-signature')); } return this.$el; @@ -225,7 +226,7 @@ define([ cls: 'btn-text-default', style: 'width: 100%;', caption: this.txtInvisibleSignature, - disabled: this._state.disabled + disabled: this._state.invisibleSignDisabled }); this.btnsInvisibleSignature.push(button); @@ -268,6 +269,7 @@ define([ SetDisabled: function (state, canProtect) { this._state.disabled = state; + this._state.invisibleSignDisabled = state && !canProtect; this.btnsInvisibleSignature && this.btnsInvisibleSignature.forEach(function(button) { if ( button ) { button.setDisabled(state && !canProtect); diff --git a/apps/common/main/lib/view/RenameDialog.js b/apps/common/main/lib/view/RenameDialog.js index 241b8c589..023cff6ba 100644 --- a/apps/common/main/lib/view/RenameDialog.js +++ b/apps/common/main/lib/view/RenameDialog.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -47,7 +47,9 @@ define([ width: 330, header: false, cls: 'modal-dlg', - filename: '' + filename: '', + buttons: ['ok', 'cancel'], + footerCls: 'right' }, initialize : function(options) { @@ -59,10 +61,6 @@ define([ '', '
    ', '
    ', - '
    ', - '' ].join(''); @@ -88,23 +86,24 @@ define([ $window.find('.btn').on('click', _.bind(this.onBtnClick, this)); me.inputNameEl = $window.find('input'); - me.inputNameEl.on('keypress', _.bind(this.onKeyPress, this)); }, show: function() { Common.UI.Window.prototype.show.apply(this, arguments); var me = this; + var idx = me.options.filename.lastIndexOf('.'); + if (idx>0) + me.options.filename = me.options.filename.substring(0, idx); _.delay(function(){ me.inputName.setValue(me.options.filename); me.inputNameEl.focus().select(); },100); }, - onKeyPress: function(event) { - if (event.keyCode == Common.UI.Keys.RETURN) { - this._handleInput('ok'); - } + onPrimary: function(event) { + this._handleInput('ok'); + return false; }, onBtnClick: function(event) { @@ -127,8 +126,6 @@ define([ }, textName : 'File name', - cancelButtonText: 'Cancel', - okButtonText : 'Ok', txtInvalidName : 'The file name cannot contain any of the following characters: ' }, Common.Views.RenameDialog || {})); }); \ No newline at end of file diff --git a/apps/common/main/lib/view/ReviewChanges.js b/apps/common/main/lib/view/ReviewChanges.js index 22a9a62b3..2325f1b31 100644 --- a/apps/common/main/lib/view/ReviewChanges.js +++ b/apps/common/main/lib/view/ReviewChanges.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -99,14 +99,6 @@ define([ var me = this; if ( me.appConfig.canReview ) { - this.btnPrev.on('click', function (e) { - me.fireEvent('reviewchange:preview', [me.btnPrev, 'prev']); - }); - - this.btnNext.on('click', function (e) { - me.fireEvent('reviewchange:preview', [me.btnNext, 'next']); - }); - this.btnAccept.on('click', function (e) { me.fireEvent('reviewchange:accept', [me.btnAccept, 'current']); }); @@ -126,8 +118,17 @@ define([ this.btnsTurnReview.forEach(function (button) { button.on('click', _click_turnpreview.bind(me)); }); + } + if (this.appConfig.canViewReview) { + this.btnPrev.on('click', function (e) { + me.fireEvent('reviewchange:preview', [me.btnPrev, 'prev']); + }); - this.btnReviewView.menu.on('item:click', function (menu, item, e) { + this.btnNext.on('click', function (e) { + me.fireEvent('reviewchange:preview', [me.btnNext, 'next']); + }); + + this.btnReviewView && this.btnReviewView.menu.on('item:click', function (menu, item, e) { me.fireEvent('reviewchanges:view', [menu, item]); }); } @@ -173,18 +174,6 @@ define([ this.appConfig = options.mode; if ( this.appConfig.canReview ) { - this.btnPrev = new Common.UI.Button({ - cls: 'btn-toolbar x-huge icon-top', - iconCls: 'review-prev', - caption: this.txtPrev - }); - - this.btnNext = new Common.UI.Button({ - cls: 'btn-toolbar x-huge icon-top', - iconCls: 'review-next', - caption: this.txtNext - }); - this.btnAccept = new Common.UI.Button({ cls: 'btn-toolbar x-huge icon-top', caption: this.txtAccept, @@ -206,13 +195,63 @@ define([ enableToggle: true }); this.btnsTurnReview = [this.btnTurnOn]; - - this.btnReviewView = new Common.UI.Button({ + } + if (this.appConfig.canViewReview) { + this.btnPrev = new Common.UI.Button({ cls: 'btn-toolbar x-huge icon-top', - iconCls: 'btn-ic-reviewview', - caption: this.txtView, - menu: true + iconCls: 'review-prev', + caption: this.txtPrev }); + + this.btnNext = new Common.UI.Button({ + cls: 'btn-toolbar x-huge icon-top', + iconCls: 'review-next', + caption: this.txtNext + }); + + if (!this.appConfig.isRestrictedEdit) {// hide Display mode option for fillForms and commenting mode + var menuTemplate = _.template('
    <%= caption %>
    ' + + '<% if (options.description !== null) { %>' + + '<% } %>
    '); + + this.btnReviewView = new Common.UI.Button({ + cls: 'btn-toolbar x-huge icon-top', + iconCls: 'btn-ic-reviewview', + caption: this.txtView, + menu: new Common.UI.Menu({ + cls: 'ppm-toolbar', + items: [ + { + caption: this.txtMarkupCap, + checkable: true, + toggleGroup: 'menuReviewView', + checked: true, + value: 'markup', + template: menuTemplate, + description: this.txtMarkup + }, + { + caption: this.txtFinalCap, + checkable: true, + toggleGroup: 'menuReviewView', + checked: false, + template: menuTemplate, + description: this.txtFinal, + value: 'final' + }, + { + caption: this.txtOriginalCap, + checkable: true, + toggleGroup: 'menuReviewView', + checked: false, + template: menuTemplate, + description: this.txtOriginal, + value: 'original' + } + ] + }) + }); + } } if (!!this.appConfig.sharingSettingsUrl && this.appConfig.sharingSettingsUrl.length && this._readonlyRights!==true) { @@ -223,7 +262,7 @@ define([ }); } - if (!this.appConfig.isOffline && this.appConfig.canCoAuthoring) { + if (this.appConfig.isEdit && !this.appConfig.isOffline && this.appConfig.canCoAuthoring) { this.btnCoAuthMode = new Common.UI.Button({ cls: 'btn-toolbar x-huge icon-top', iconCls: 'btn-ic-coedit', @@ -275,8 +314,6 @@ define([ '<% } %>'); if ( config.canReview ) { - me.btnPrev.updateHint(me.hintPrev); - me.btnNext.updateHint(me.hintNext); me.btnTurnOn.updateHint(me.tipReview); me.btnAccept.setMenu( @@ -311,45 +348,15 @@ define([ ); me.btnReject.updateHint([me.tipRejectCurrent, me.txtRejectChanges]); - me.btnReviewView.setMenu( - new Common.UI.Menu({ - cls: 'ppm-toolbar', - items: [ - { - caption: me.txtMarkupCap, - checkable: true, - toggleGroup: 'menuReviewView', - checked: true, - value: 'markup', - template: menuTemplate, - description: me.txtMarkup - }, - { - caption: me.txtFinalCap, - checkable: true, - toggleGroup: 'menuReviewView', - checked: false, - template: menuTemplate, - description: me.txtFinal, - value: 'final' - }, - { - caption: me.txtOriginalCap, - checkable: true, - toggleGroup: 'menuReviewView', - checked: false, - template: menuTemplate, - description: me.txtOriginal, - value: 'original' - } - ] - })); - me.btnReviewView.updateHint(me.tipReviewView); - me.btnAccept.setDisabled(config.isReviewOnly); me.btnReject.setDisabled(config.isReviewOnly); } + if (me.appConfig.canViewReview) { + me.btnPrev.updateHint(me.hintPrev); + me.btnNext.updateHint(me.hintNext); + me.btnReviewView && me.btnReviewView.updateHint(me.tipReviewView); + } me.btnSharing && me.btnSharing.updateHint(me.tipSharing); me.btnHistory && me.btnHistory.updateHint(me.tipHistory); me.btnChat && me.btnChat.updateHint(me.txtChat + Common.Utils.String.platformKey('Alt+Q')); @@ -392,7 +399,7 @@ define([ var separator_sharing = !(me.btnSharing || me.btnCoAuthMode) ? me.$el.find('.separator.sharing') : '.separator.sharing', separator_comments = !(config.canComments && config.canCoAuthoring) ? me.$el.find('.separator.comments') : '.separator.comments', - separator_review = !config.canReview ? me.$el.find('.separator.review') : '.separator.review', + separator_review = !(config.canReview || config.canViewReview) ? me.$el.find('.separator.review') : '.separator.review', separator_chat = !me.btnChat ? me.$el.find('.separator.chat') : '.separator.chat', separator_last; @@ -419,7 +426,7 @@ define([ if (!me.btnHistory && separator_last) me.$el.find(separator_last).hide(); - Common.NotificationCenter.trigger('tab:visible', 'review', true); + Common.NotificationCenter.trigger('tab:visible', 'review', config.isEdit || config.canViewReview); setEvents.call(me); }); @@ -429,13 +436,13 @@ define([ this.$el = $(_.template(template)( {} )); if ( this.appConfig.canReview ) { - this.btnPrev.render(this.$el.find('#btn-change-prev')); - this.btnNext.render(this.$el.find('#btn-change-next')); this.btnAccept.render(this.$el.find('#btn-change-accept')); this.btnReject.render(this.$el.find('#btn-change-reject')); this.btnTurnOn.render(this.$el.find('#btn-review-on')); - this.btnReviewView.render(this.$el.find('#btn-review-view')); } + this.btnPrev && this.btnPrev.render(this.$el.find('#btn-change-prev')); + this.btnNext && this.btnNext.render(this.$el.find('#btn-change-next')); + this.btnReviewView && this.btnReviewView.render(this.$el.find('#btn-review-view')); this.btnSharing && this.btnSharing.render(this.$el.find('#slot-btn-sharing')); this.btnCoAuthMode && this.btnCoAuthMode.render(this.$el.find('#slot-btn-coauthmode')); @@ -529,6 +536,14 @@ define([ this.btnChat && this.btnChat.toggle(state, true); }, + turnDisplayMode: function(mode) { + if (this.btnReviewView) { + this.btnReviewView.menu.items[0].setChecked(mode=='markup', true); + this.btnReviewView.menu.items[1].setChecked(mode=='final', true); + this.btnReviewView.menu.items[2].setChecked(mode=='original', true); + } + }, + SetDisabled: function (state, langs) { this.btnsSpelling && this.btnsSpelling.forEach(function(button) { if ( button ) { diff --git a/apps/common/main/lib/view/ReviewPopover.js b/apps/common/main/lib/view/ReviewPopover.js index d2738d796..a3f507da5 100644 --- a/apps/common/main/lib/view/ReviewPopover.js +++ b/apps/common/main/lib/view/ReviewPopover.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -100,14 +100,23 @@ define([ this.commentsStore = options.commentsStore; this.reviewStore = options.reviewStore; + this.canRequestUsers = options.canRequestUsers; + this.canRequestSendNotify = options.canRequestSendNotify; + this.externalUsers = []; this._state = {commentsVisible: false, reviewVisible: false}; _options.tpl = _.template(this.template)(_options); - this.arrow = {margin: 20, width: 12, height: 34}; + this.arrow = {margin: 20, width: 10, height: 30}; this.sdkBounds = {width: 0, height: 0, padding: 10, paddingTop: 20}; Common.UI.Window.prototype.initialize.call(this, _options); + + if (this.canRequestUsers) { + Common.Gateway.on('setusers', _.bind(this.setUsers, this)); + Common.NotificationCenter.on('mentions:clearusers', _.bind(this.clearUsers, this)); + } + return this; }, render: function (comments, review) { @@ -196,7 +205,7 @@ define([ } parentView.scroller.scrollTop(scrollPos); - view.autoScrollToEditButtons(); + parentView.autoScrollToEditButtons(); } if (textBox && textBox.length) { @@ -216,23 +225,6 @@ define([ this.textBox.unbind('input propertychange'); this.textBox = undefined; } - }, - autoScrollToEditButtons: function () { - var button = $('#id-comments-change-popover'), // TODO: add to cache - btnBounds = null, - contentBounds = this.el.getBoundingClientRect(), - moveY = 0, - padding = 7; - - if (button.length) { - btnBounds = button.get(0).getBoundingClientRect(); - if (btnBounds && contentBounds) { - moveY = contentBounds.bottom - (btnBounds.bottom + padding); - if (moveY < 0) { - parentView.scroller.scrollTop(parentView.scroller.getScrollTop() - moveY); - } - } - } } } })()); @@ -251,7 +243,8 @@ define([ textEdit: me.textEdit, textReply: me.textReply, textClose: me.textClose, - maxCommLength: Asc.c_oAscMaxCellOrCommentLength + maxCommLength: Asc.c_oAscMaxCellOrCommentLength, + textMention: me.canRequestSendNotify ? me.textMention : '' }) ) }); @@ -328,7 +321,7 @@ define([ me.hookTextBox(); - this.autoScrollToEditButtons(); + me.autoScrollToEditButtons(); this.setFocusToTextBox(); } else { if (!showEditBox) { @@ -347,7 +340,7 @@ define([ me.hookTextBox(); - this.autoScrollToEditButtons(); + me.autoScrollToEditButtons(); this.setFocusToTextBox(); } } @@ -380,7 +373,7 @@ define([ this.autoHeightTextBox(); me.hookTextBox(); - this.autoScrollToEditButtons(); + me.autoScrollToEditButtons(); this.setFocusToTextBox(); } else if (btn.hasClass('btn-reply', false)) { if (showReplyBox) { @@ -388,6 +381,7 @@ define([ me.fireEvent('comment:addReply', [commentId, this.getActiveTextBoxVal()]); me.fireEvent('comment:closeEditing'); + me.calculateSizeOfContent(); readdresolves(); } @@ -402,6 +396,7 @@ define([ if (record.get('dummy')) { var commentVal = this.getActiveTextBoxVal(); + me.clearDummyText(); if (commentVal.length > 0) me.fireEvent('comment:addDummyComment', [commentVal]); else { @@ -430,6 +425,7 @@ define([ } else if (btn.hasClass('btn-inner-close', false)) { if (record.get('dummy')) { + me.clearDummyText(); me.hide(); return; } @@ -471,12 +467,31 @@ define([ } } }); + + this.emailMenu = new Common.UI.Menu({ + maxHeight: 190, + cyclic: false, + items: [] + }).on('render:after', function(mnu) { + this.scroller = new Common.UI.Scroller({ + el: $(this.el).find('.dropdown-menu '), + useKeyboard: this.enableKeyEvents && !this.handleSelect, + minScrollbarLength : 40, + alwaysVisibleY: true + }); + }).on('show:after', function () { + this.scroller.update({alwaysVisibleY: true}); + me.$window.css({zIndex: '1001'}); + }).on('hide:after', function () { + me.$window.css({zIndex: '990'}); + }); + me.on({ 'show': function () { me.commentsView.autoHeightTextBox(); me.$window.find('textarea').keydown(function (event) { if (event.keyCode == Common.UI.Keys.ESC) { - me.hide(); + me.hide(true); // clear text in dummy comment } }); }, @@ -496,9 +511,7 @@ define([ handleSelect: false, scrollable: true, template: _.template('
    '+ - '
    ' + - '
    ' + - '
    ' + '
    ' ) } } @@ -514,6 +527,26 @@ define([ itemTemplate: _.template(reviewTemplate) }); + var addtooltip = function (dataview, view, record) { + if (view.tipsArray) { + view.tipsArray.forEach(function (item) { + item.remove(); + }); + } + + var arr = [], + btns = $(view.el).find('.btn-goto'); + btns.tooltip({title: me.textFollowMove, placement: 'cursor'}); + btns.each(function (idx, item) { + arr.push($(item).data('bs.tooltip').tip()); + }); + view.tipsArray = arr; + }; + + this.reviewChangesView.on('item:add', addtooltip); + this.reviewChangesView.on('item:remove', addtooltip); + this.reviewChangesView.on('item:change', addtooltip); + this.reviewChangesView.on('item:click', function (picker, item, record, e) { var btn = $(e.target); if (btn) { @@ -523,6 +556,11 @@ define([ me.fireEvent('reviewchange:reject', [record.get('changedata')]); } else if (btn.hasClass('btn-delete')) { me.fireEvent('reviewchange:delete', [record.get('changedata')]); + } else if (btn.hasClass('btn-goto')) { + var tip = btn.data('bs.tooltip'); + if (tip) tip.dontShow = true; + + me.fireEvent('reviewchange:goto', [record.get('changedata')]); } } }); @@ -560,8 +598,8 @@ define([ showReview: function (animate, lock, lockuser) { this.show(animate); - this.reviewChangesView.cmpEl.find('.lock-area').toggleClass('hidden', !lock); - this.reviewChangesView.cmpEl.find('.lock-author').toggleClass('hidden', !lock || _.isEmpty(lockuser)).text(lockuser); + // this.reviewChangesView.cmpEl.find('.lock-area').toggleClass('hidden', !lock); + // this.reviewChangesView.cmpEl.find('.lock-author').toggleClass('hidden', !lock || _.isEmpty(lockuser)).text(lockuser); this._state.reviewVisible = true; }, @@ -601,7 +639,7 @@ define([ hide: function () { if (this.handlerHide) { - this.handlerHide(); + this.handlerHide.apply(this, arguments); } this.hideTips(); @@ -744,6 +782,10 @@ define([ topPos = Math.min(sdkBoundsTop + sdkBoundsHeight - outerHeight, this.arrowPosY + sdkBoundsTop - this.arrow.height); topPos = Math.max(topPos, sdkBoundsTopPos); + if (parseInt(arrowView.css('top')) + this.arrow.height > outerHeight) { + arrowView.css({top: (outerHeight-this.arrow.height) + 'px'}); + } + this.$window.css('top', topPos + 'px'); } } @@ -774,6 +816,8 @@ define([ sdkBoundsTopPos = 0; if (commentsView && arrowView && commentsView.get(0)) { + var scrollPos = this.scroller.getScrollTop(); + commentsView.css({height: '100%'}); contentBounds = commentsView.get(0).getBoundingClientRect(); @@ -810,9 +854,10 @@ define([ commentsView.css({height: sdkBoundsHeight - sdkPanelHeight - 3 + 'px'}); // arrowPosY = Math.max(this.arrow.margin, this.arrowPosY - sdkPanelHeight - this.arrow.width); - arrowPosY = Math.min(arrowPosY, sdkBoundsHeight - (sdkPanelHeight + this.arrow.margin + this.arrow.width)); + arrowPosY = Math.min(arrowPosY, sdkBoundsHeight - (sdkPanelHeight + this.arrow.margin + this.arrow.height)); arrowView.css({top: arrowPosY + 'px'}); + this.scroller.scrollTop(scrollPos); } else { outerHeight = windowHeight; @@ -826,8 +871,8 @@ define([ } } - arrowPosY = Math.max(this.arrow.margin, this.arrowPosY - (sdkBoundsHeight - outerHeight) - this.arrow.width); - arrowPosY = Math.min(arrowPosY, outerHeight - this.arrow.margin - this.arrow.width); + arrowPosY = Math.max(this.arrow.margin, this.arrowPosY - (sdkBoundsHeight - outerHeight) - this.arrow.height); + arrowPosY = Math.min(arrowPosY, outerHeight - this.arrow.margin - this.arrow.height); arrowView.css({top: arrowPosY + 'px'}); } @@ -837,6 +882,9 @@ define([ } this.$window.css({overflow: ''}); + if (this.scroller) { + this.scroller.update({minScrollbarLength: 40, alwaysVisibleY: true}); + } }, saveText: function (clear) { if (this.commentsView && this.commentsView.cmpEl.find('.lock-area').length < 1) { @@ -861,6 +909,22 @@ define([ return undefined; }, + saveDummyText: function () { + if (this.commentsView && this.commentsView.cmpEl.find('.lock-area').length < 1) { + this.textDummyVal = this.commentsView.getActiveTextBoxVal(); + } + }, + clearDummyText: function () { + if (this.commentsView && this.commentsView.cmpEl.find('.lock-area').length < 1) { + this.textDummyVal = undefined; + var textBox = this.commentsView.getTextBox(); + textBox && textBox.val(''); + this.commentsView.clearTextBoxBind(); + } + }, + getDummyText: function() { + return this.textDummyVal || ''; + }, hookTextBox: function () { var me = this, textBox = this.commentsView.getTextBox(); @@ -881,12 +945,56 @@ define([ $this.val($this.val().substring(0, start) + '\t' + $this.val().substring(end)); this.selectionStart = this.selectionEnd = start + 1; - event.stopImmediatePropagation(); + // event.stopImmediatePropagation(); event.preventDefault(); } me.e = event; }); + + if (this.canRequestUsers) { + textBox && textBox.keydown(function (event) { + if ( event.keyCode == Common.UI.Keys.SPACE || event.keyCode === Common.UI.Keys.TAB || + event.keyCode == Common.UI.Keys.HOME || event.keyCode == Common.UI.Keys.END || event.keyCode == Common.UI.Keys.RIGHT || + event.keyCode == Common.UI.Keys.LEFT || event.keyCode == Common.UI.Keys.UP) { + // hide email menu + me.onEmailListMenu(); + } else if (event.keyCode == Common.UI.Keys.DOWN) { + if (me.emailMenu && me.emailMenu.rendered && me.emailMenu.isVisible()) { + _.delay(function () { + var selected = me.emailMenu.cmpEl.find('li:not(.divider):first'); + selected = selected.find('a'); + selected.focus(); + }, 10); + event.preventDefault(); + } + } + me.e = event; + }); + textBox && textBox.on('input', function (event) { + var $this = $(this), + start = this.selectionStart, + val = $this.val(), + left = 0, right = val.length-1; + for (var i=start-1; i>=0; i--) { + if (val.charCodeAt(i) == 32 /*space*/ || val.charCodeAt(i) == 13 /*enter*/ || val.charCodeAt(i) == 10 /*new line*/ || val.charCodeAt(i) == 9 /*tab*/) { + left = i+1; break; + } + } + for (var i=start; i<=right; i++) { + if (val.charCodeAt(i) == 32 || val.charCodeAt(i) == 13 || val.charCodeAt(i) == 10 || val.charCodeAt(i) == 9) { + right = i-1; break; + } + } + var str = val.substring(left, right+1), + res = str.match(/^(?:[@]|[+](?!1))(\S*)/); + if (res && res.length>1) { + str = res[1]; // send to show email menu + me.onEmailListMenu(str, left, right); + } else + me.onEmailListMenu(); // hide email menu + }); + } }, hideTips: function () { @@ -898,6 +1006,14 @@ define([ }); } }, this); + if (this.reviewChangesView) + _.each(this.reviewChangesView.dataViewItems, function (item) { + if (item.tipsArray) { + item.tipsArray.forEach(function (item) { + item.hide(); + }); + } + }, this); }, isCommentsViewMouseOver: function () { @@ -916,12 +1032,142 @@ define([ this.commentsView.setStore(this.commentsStore); }, + setUsers: function(data) { + this.externalUsers = data.users || []; + this.isUsersLoading = false; + this._state.emailSearch && this.onEmailListMenu(this._state.emailSearch.str, this._state.emailSearch.left, this._state.emailSearch.right); + this._state.emailSearch = null; + }, + + clearUsers: function() { + this.externalUsers = []; + }, + getPopover: function(options) { if (!this.popover) this.popover = new Common.Views.ReviewPopover(options); return this.popover; }, + autoScrollToEditButtons: function () { + var button = $('#id-comments-change-popover'), // TODO: add to cache + btnBounds = null, + contentBounds = this.$window[0].getBoundingClientRect(), + moveY = 0, + padding = 7; + + if (button.length) { + btnBounds = button.get(0).getBoundingClientRect(); + if (btnBounds && contentBounds) { + moveY = contentBounds.bottom - (btnBounds.bottom + padding); + if (moveY < 0) { + this.scroller.scrollTop(this.scroller.getScrollTop() - moveY); + } + } + } + }, + + onEmailListMenu: function(str, left, right, show) { + var me = this, + users = me.externalUsers, + menu = me.emailMenu; + + if (users.length<1) { + this._state.emailSearch = { + str: str, + left: left, + right: right + }; + + if (this.isUsersLoading) return; + + this.isUsersLoading = true; + Common.Gateway.requestUsers(); + return; + } + if (typeof str == 'string') { + var menuContainer = me.$window.find(Common.Utils.String.format('#menu-container-{0}', menu.id)), + textbox = this.commentsView.getTextBox(), + textboxDom = textbox ? textbox[0] : null, + showPoint = textboxDom ? [textboxDom.offsetLeft, textboxDom.offsetTop + textboxDom.clientHeight + 3] : [0, 0]; + + if (!menu.rendered) { + // Prepare menu container + if (menuContainer.length < 1) { + menuContainer = $(Common.Utils.String.format('', menu.id)); + me.$window.append(menuContainer); + } + + menu.render(menuContainer); + menu.cmpEl.css('min-width', textboxDom ? textboxDom.clientWidth : 220); + menu.cmpEl.attr({tabindex: "-1"}); + menu.on('hide:after', function(){ + setTimeout(function(){ + var tb = me.commentsView.getTextBox(); + tb && tb.focus(); + }, 10); + }); + } + + for (var i = 0; i < menu.items.length; i++) { + menu.removeItem(menu.items[i]); + i--; + } + + if (users.length>0) { + str = str.toLowerCase(); + if (str.length>0) { + users = _.filter(users, function(item) { + return (item.email && 0 === item.email.toLowerCase().indexOf(str) || item.name && 0 === item.name.toLowerCase().indexOf(str)) + }); + } + var tpl = _.template('
    <%= Common.Utils.String.htmlEncode(caption) %>
    <%= Common.Utils.String.htmlEncode(options.value) %>
    '), + divider = false; + _.each(users, function(menuItem, index) { + if (divider && !menuItem.hasAccess) { + divider = false; + menu.addItem(new Common.UI.MenuItem({caption: '--'})); + } + + if (menuItem.email && menuItem.name) { + var mnu = new Common.UI.MenuItem({ + caption : menuItem.name, + value : menuItem.email, + template : tpl + }).on('click', function(item, e) { + me.insertEmailToTextbox(item.options.value, left, right); + }); + menu.addItem(mnu); + if (menuItem.hasAccess) + divider = true; + } + }); + } + + if (menu.items.length>0) { + menuContainer.css({left: showPoint[0], top : showPoint[1]}); + menu.menuAlignEl = textbox; + menu.show(); + menu.cmpEl.css('display', ''); + menu.alignPosition('bl-tl', -5); + menu.scroller.update({alwaysVisibleY: true}); + } else { + menu.rendered && menu.cmpEl.css('display', 'none'); + } + } else { + menu.rendered && menu.cmpEl.css('display', 'none'); + } + }, + + insertEmailToTextbox: function(str, left, right) { + var textBox = this.commentsView.getTextBox(), + val = textBox.val(); + textBox.val(val.substring(0, left) + '+' + str + ' ' + val.substring(right+1, val.length)); + setTimeout(function(){ + textBox[0].selectionStart = textBox[0].selectionEnd = left + str.length + 2; + }, 10); + }, + textAddReply : 'Add Reply', textAdd : "Add", textCancel : 'Cancel', @@ -929,7 +1175,8 @@ define([ textReply : 'Reply', textClose : 'Close', textResolve : 'Resolve', - textOpenAgain : "Open Again" - + textOpenAgain : "Open Again", + textFollowMove : 'Follow Move', + textMention : '+mention will provide access to the document and send an email' }, Common.Views.ReviewPopover || {})) }); \ No newline at end of file diff --git a/apps/documenteditor/main/app/view/MailMergeSaveDlg.js b/apps/common/main/lib/view/SaveAsDlg.js similarity index 78% rename from apps/documenteditor/main/app/view/MailMergeSaveDlg.js rename to apps/common/main/lib/view/SaveAsDlg.js index 832f1bc6b..04f1b3c57 100644 --- a/apps/documenteditor/main/app/view/MailMergeSaveDlg.js +++ b/apps/common/main/lib/view/SaveAsDlg.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -31,9 +31,8 @@ * */ /** - * User: Julia.Radzhabova - * Date: 15.04.15 - * Time: 13:56 + * Created by Julia.Radzhabova on 9/27/18 + * Copyright (c) 2018 Ascensio System SIA. All rights reserved. */ define([ @@ -41,7 +40,7 @@ define([ 'common/main/lib/component/LoadMask' ], function () { 'use strict'; - DE.Views.MailMergeSaveDlg = Common.UI.Window.extend(_.extend({ + Common.Views.SaveAsDlg = Common.UI.Window.extend(_.extend({ initialize : function(options) { var _options = {}; _.extend(_options, { @@ -52,15 +51,15 @@ define([ }, options); this.template = [ - '
    ' + '
    ' ].join(''); _options.tpl = _.template(this.template)(_options); - this.mergeFolderUrl = options.mergeFolderUrl || ''; - this.mergedFileUrl = options.mergedFileUrl || ''; + this.saveFolderUrl = options.saveFolderUrl || ''; + this.saveFileUrl = options.saveFileUrl || ''; this.defFileName = options.defFileName || ''; - this.mergeFolderUrl = this.mergeFolderUrl.replace("{title}", encodeURIComponent(this.defFileName)).replace("{fileuri}", encodeURIComponent(this.mergedFileUrl)); + this.saveFolderUrl = this.saveFolderUrl.replace("{title}", encodeURIComponent(this.defFileName)).replace("{fileuri}", encodeURIComponent(this.saveFileUrl)); Common.UI.Window.prototype.initialize.call(this, _options); }, @@ -75,13 +74,13 @@ define([ iframe.frameBorder = 0; iframe.scrolling = "no"; iframe.onload = _.bind(this._onLoad,this); - $('#id-mail-merge-folder-placeholder').append(iframe); + $('#id-saveas-folder-placeholder').append(iframe); - this.loadMask = new Common.UI.LoadMask({owner: $('#id-mail-merge-folder-placeholder')}); + this.loadMask = new Common.UI.LoadMask({owner: $('#id-saveas-folder-placeholder')}); this.loadMask.setTitle(this.textLoading); this.loadMask.show(); - iframe.src = this.mergeFolderUrl; + iframe.src = this.saveFolderUrl; var me = this; this._eventfunc = function(msg) { @@ -122,10 +121,12 @@ define([ _onMessage: function(msg) { if (msg && msg.Referer == "onlyoffice") { if ( !_.isEmpty(msg.error) ) { - this.trigger('mailmergeerror', this, msg.error); + this.trigger('saveaserror', this, msg.error); + } else if (!_.isEmpty(msg.message)) { + Common.NotificationCenter.trigger('showmessage', {msg: msg.message}); } // if ( !_.isEmpty(msg.folder) ) { -// this.trigger('mailmergefolder', this, msg.folder); // save last folder url +// this.trigger('saveasfolder', this, msg.folder); // save last folder url // } Common.NotificationCenter.trigger('window:close', this); } @@ -138,6 +139,6 @@ define([ textTitle : 'Folder for save', textLoading : 'Loading' - }, DE.Views.MailMergeSaveDlg || {})); + }, Common.Views.SaveAsDlg || {})); }); diff --git a/apps/common/main/lib/view/SearchDialog.js b/apps/common/main/lib/view/SearchDialog.js index e266784d0..683a89eb1 100644 --- a/apps/common/main/lib/view/SearchDialog.js +++ b/apps/common/main/lib/view/SearchDialog.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -87,10 +87,10 @@ '
    ', '
    ', '', - '', + '', '
    ', '
    ', - '', + '', '
    ', '
    ', '', @@ -98,10 +98,10 @@ '
    ', '
    ', '' ].join(''); @@ -176,12 +176,14 @@ return this; }, - show: function(mode) { + show: function(mode, text) { Common.UI.Window.prototype.show.call(this); !this.mode && !mode && (mode = 'search'); if (mode && this.mode != mode) this.setMode(mode); + text && this.setSearchText(text); + if (this.options.markresult && this.miHighlight.checked) { this.fireEvent('search:highlight', [this, true]); } @@ -247,6 +249,7 @@ this.txtSearch.addClass('clear'); this.btnOptions.hide(); } + this.menuLookin && this.menuLookin.menu.items[1].setDisabled(false); this.setHeight(170); } else { @@ -259,6 +262,7 @@ $inputs.eq(1).hide(); this.$window.find('.btn[result=replace]').hide(); this.$window.find('.btn[result=replaceall]').hide(); + this.menuLookin && this.menuLookin.menu.items[1].setDisabled(false); this.setHeight(200); } else { $inputs.eq(2).show(); @@ -266,11 +270,19 @@ $inputs.eq(1).show(); this.$window.find('.btn[result=replace]').show(); this.$window.find('.btn[result=replaceall]').show(); + if (this.menuLookin) { + this.menuLookin.menu.items[0].setChecked(true); + this.menuLookin.menu.items[1].setDisabled(true); + } this.setHeight(230); } } }, + setSearchText: function(value) { + this.txtSearch && this.txtSearch.val(value); + }, + onShowReplace: function(e) { this.setMode((this.mode=='replace') ? 'search' : 'replace'); @@ -287,8 +299,8 @@ getSettings: function() { return { textsearch: this.txtSearch.val(), - casesensitive: this.miMatchCase.checked, - wholewords: this.miMatchWord.checked }; + matchcase: this.miMatchCase.checked, + matchword: this.miMatchWord.checked }; }, textTitle : 'Search & Replace', diff --git a/apps/documenteditor/main/app/view/MailMergeRecepients.js b/apps/common/main/lib/view/SelectFileDlg.js similarity index 90% rename from apps/documenteditor/main/app/view/MailMergeRecepients.js rename to apps/common/main/lib/view/SelectFileDlg.js index 38f4d6ef7..89613f610 100644 --- a/apps/documenteditor/main/app/view/MailMergeRecepients.js +++ b/apps/common/main/lib/view/SelectFileDlg.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -40,7 +40,7 @@ define([ 'common/main/lib/component/LoadMask' ], function () { 'use strict'; - DE.Views.MailMergeRecepients = Common.UI.Window.extend(_.extend({ + Common.Views.SelectFileDlg = Common.UI.Window.extend(_.extend({ initialize : function(options) { var _options = {}; _.extend(_options, { @@ -51,7 +51,7 @@ define([ }, options); this.template = [ - '
    ' + '
    ' ].join(''); _options.tpl = _.template(this.template)(_options); @@ -71,9 +71,9 @@ define([ iframe.frameBorder = 0; iframe.scrolling = "no"; iframe.onload = _.bind(this._onLoad,this); - $('#id-mail-recepients-placeholder').append(iframe); + $('#id-select-file-placeholder').append(iframe); - this.loadMask = new Common.UI.LoadMask({owner: $('#id-mail-recepients-placeholder')}); + this.loadMask = new Common.UI.LoadMask({owner: $('#id-select-file-placeholder')}); this.loadMask.setTitle(this.textLoading); this.loadMask.show(); @@ -121,7 +121,7 @@ define([ var me = this; setTimeout(function() { if ( !_.isEmpty(msg.file) ) { - me.trigger('mailmergerecepients', me, msg.file); + me.trigger('selectfile', me, msg.file); } }, 50); } @@ -134,5 +134,5 @@ define([ textTitle : 'Select Data Source', textLoading : 'Loading' - }, DE.Views.MailMergeRecepients || {})); + }, Common.Views.SelectFileDlg || {})); }); diff --git a/apps/common/main/lib/view/SignDialog.js b/apps/common/main/lib/view/SignDialog.js index 0745e8da1..73e64e658 100644 --- a/apps/common/main/lib/view/SignDialog.js +++ b/apps/common/main/lib/view/SignDialog.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -53,7 +53,8 @@ define([ options: { width: 370, style: 'min-width: 350px;', - cls: 'modal-dlg' + cls: 'modal-dlg', + buttons: ['ok', 'cancel'] }, initialize : function(options) { @@ -106,10 +107,6 @@ define([ '', '', - '' ].join(''); @@ -145,7 +142,7 @@ define([ cls : 'input-group-nr', style : 'width: 234px;', menuCls : 'scrollable-menu', - menuStyle : 'min-width: 55px;max-height: 270px;', + menuStyle : 'min-width: 234px;max-height: 270px;', store : new Common.Collections.Fonts(), recent : 0, hint : me.tipFontName @@ -179,7 +176,8 @@ define([ { value: 28, displayValue: "28" }, { value: 36, displayValue: "36" }, { value: 48, displayValue: "48" }, - { value: 72, displayValue: "72" } + { value: 72, displayValue: "72" }, + { value: 96, displayValue: "96" } ] }).on('selected', function(combo, record) { if (me.signObject) { @@ -239,7 +237,6 @@ define([ (me.signType == 'visible') ? me.cntInvisibleSign.addClass('hidden') : me.cntVisibleSign.addClass('hidden'); $window.find('.dlg-btn').on('click', _.bind(me.onBtnClick, me)); - $window.find('input').on('keypress', _.bind(me.onKeyPress, me)); me.afterRender(); }, @@ -297,11 +294,9 @@ define([ this._handleInput(event.currentTarget.attributes['result'].value); }, - onKeyPress: function(event) { - if (event.keyCode == Common.UI.Keys.RETURN) { - this._handleInput('ok'); - return false; - } + onPrimary: function(event) { + this._handleInput('ok'); + return false; }, _handleInput: function(state) { @@ -344,8 +339,6 @@ define([ textCertificate: 'Certificate', textValid: 'Valid from %1 to %2', textChange: 'Change', - cancelButtonText: 'Cancel', - okButtonText: 'Ok', textInputName: 'Input signer name', textUseImage: 'or click \'Select Image\' to use a picture as signature', textSelectImage: 'Select Image', diff --git a/apps/common/main/lib/view/SignSettingsDialog.js b/apps/common/main/lib/view/SignSettingsDialog.js index 4d284c8cd..d402926ac 100644 --- a/apps/common/main/lib/view/SignSettingsDialog.js +++ b/apps/common/main/lib/view/SignSettingsDialog.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under @@ -86,7 +86,7 @@ define([ '
    ', '
    ', ' diff --git a/apps/documenteditor/main/resources/help/de/UsageInstructions/SetPageParameters.htm b/apps/documenteditor/main/resources/help/de/UsageInstructions/SetPageParameters.htm index 0cade2688..a2612a7ba 100644 --- a/apps/documenteditor/main/resources/help/de/UsageInstructions/SetPageParameters.htm +++ b/apps/documenteditor/main/resources/help/de/UsageInstructions/SetPageParameters.htm @@ -19,40 +19,40 @@

    Seitenausrichtung

    Die aktuelle Seitenausrichtung ändern Sie mit einem Klick auf das Symbol Ausrichtung Seitenausrichtung. Die Standardeinstellung ist Hochformat. Diese kann jedoch auf Querformat gewechselt werden.

    Seitengröße

    -

    Das A4-Standardformat ändern Sie, indem Sie das Symbol Größe Größe anklicken und das gewünschte Format in der Liste wählen. Die verfügbaren Formate sind:

    +

    Das A4-Standardformat ändern Sie, indem Sie das Symbol Größe Größe anklicken und das gewünschte Format aus der Liste auswählen. Die verfügbaren Formate sind:

    • US Letter (21,59 cm x 27,94 cm)
    • US Legal (21,59 cm x 35,56 cm)
    • A4 (21 cm x 29,7 cm)
    • -
    • A5 (14,81 cm x 20,99 cm)
    • -
    • B5 (17,6 cm x 25,01 cm)
    • -
    • Briefumschlag #10 (10,48 cm x 24,13 cm)
    • +
    • A5 (14,81cm x 20,99cm)
    • +
    • B5 (17,6cm x 25,01cm)
    • +
    • Umschlag #10 (10,48 cm x 24,13 cm)
    • Umschlag DL (11,01 cm x 22,01 cm)
    • Tabloid (27,94 cm x 43,17 cm)
    • AЗ (29,7 cm x 42,01 cm)
    • Tabloid Übergröße (30,48 cm x 45,71 cm)
    • ROC 16K (19,68 cm x 27,3 cm)
    • -
    • Envelope Choukei 3 (11,99 cm x 23,49 cm)
    • +
    • Umschlag Choukei 3 (11,99 cm x 23,49 cm)
    • Super B/A3 (33,02 cm x 48,25 cm)
    -

    Sie können die Seitengröße auch individuell festlegen, wählen Sie dazu die Option Benutzerdefinierte Seitengröße aus der Liste aus. Das Fenster Seitengröße öffnet sich und Sie können die gewünschten Werte für Breite und Höhe festlegen. Geben Sie Ihre gewünschten Werte in die Eingabefelder ein oder passen Sie die vorhandenen Werte über die Pfeile an. Wenn Sie fertig sind, klicken Sie auf OK, um die Änderungen anzuwenden.

    +

    Sie können die Seitengröße auch individuell festlegen, wählen Sie dazu die Option Benutzerdefinierte Seitengröße aus der Liste aus. Das Fenster Seitengröße öffnet sich und Sie können die gewünschte Voreinstellung auswählen (US Letter, US Legal, A4, A5, B5, Umschlag #10, Umschlag DL, Tabloid, A3, Tabloid Übergröße, ROC 16K, Umschlag Choukei 3, Super B/A3, A0, A1, A2, A6) oder benutzerdefinierte Werte für Breite und Höhe festlegen. Geben Sie Ihre gewünschten Werte in die Eingabefelder ein oder passen Sie die vorhandenen Werte über die Pfeile an. Wenn Sie fertig sind, klicken Sie auf OK, um die Änderungen anzuwenden.

    Benutzerdefinierte Seitengröße

    Seitenränder

    -

    Ändern Sie die Standardränder, also den Abstand zwischen den linken, rechten, oberen und unteren Seitenkanten und dem Absatztext, klicken Sie dazu auf das Symbol Ränder Ränder wählen Sie eine der verfügbaren Voreinstellungen aus: Normal, US Normal, Schmal, Mittel, Breit. Sie können auch die Option Benutzerdefinierte Ränder verwenden, um Ihre eigenen Werte im geöffneten Fenster Ränder einzugeben. Geben Sie Ihre gewünschten Werte für die Oberen, Unteren, Linken und Rechten Seitenränder in die Eingabefelder ein oder passen Sie die vorhandenen Werte über die Pfeile an. Wenn Sie fertig sind, klicken Sie auf OK. Die benutzerdefinierten Ränder werden auf das aktuelle Dokument angewendet und die Letzte Benutzerdefinierte mit den angegebenen Parametern wird in der Liste mit verfügbaren Ränder Rändern angezeigt, damit Sie Ihre Einstellungen auch auf andere Dokumente anwenden können.

    +

    Ändern Sie die Standardränder, also den Abstand zwischen den linken, rechten, oberen und unteren Seitenkanten und dem Absatztext, klicken Sie dazu auf das Symbol Ränder Ränder und wählen Sie eine der verfügbaren Voreinstellungen aus: Normal, US Normal, Schmal, Mittel, Breit. Sie können auch die Option Benutzerdefinierte Seitenränder verwenden, um Ihre eigenen Werte im geöffneten Fenster Ränder einzugeben. Geben Sie Ihre gewünschten Werte für die Oberen, Unteren, Linken und Rechten Seitenränder in die Eingabefelder ein oder passen Sie die vorhandenen Werte über die Pfeile an. Wenn Sie fertig sind, klicken Sie auf OK. Die benutzerdefinierten Ränder werden auf das aktuelle Dokument angewendet. In der Liste Ränder Ränder wird die Option letzte benutzerdefinierte Einstellung mit den entsprechenden Parametern angezeigt, so dass Sie diese auf alle gewünschten anderen Dokumente anwenden können.

    Benutzerdefinierte Seitenränder

    Sie können die Seitenränder auch manuell ändern, indem Sie die Ränder zwischen den grauen und weißen Bereichen der Lineale verschieben (die grauen Bereiche der Lineale weisen auf Seitenränder hin):

    Seitenränder anpassen

    Spalten

    -

    Sie können Ihren Text in zwei oder mehr Spalten aufteilen, klicken Sie dazu auf das Symbol Spalten Spalten und wählen Sie die gewünschte Spaltenzahl aus der Liste aus. Folgende Optionen sind verfügbar:

    +

    Sie können Ihren Text in zwei oder mehr Spalten aufteilen, klicken Sie dazu auf das Symbol Spalten Spalten und wählen Sie die gewünschte Spaltenzahl aus der Liste aus. Folgende Optionen stehen zur Verfügung:

      -
    • Zwei Zwei Spalten - Zwei Spalten mit der gleichen Breite.
    • -
    • Drei Drei Spalten - Drei Spalten mit der gleichen Breite.
    • -
    • Links Spalte links - zwei Spalten: eine schmale auf der linken Seite und eine breite auf der rechten.
    • -
    • Rechts Spalte rechts - zwei Spalten: eine schmale auf der rechten Seite und eine breite auf der linken.
    • +
    • Zwei Zwei Spalten - Zwei Spalten mit der gleichen Breite hinzufügen.
    • +
    • Drei Drei Spalten - Drei Spalten mit der gleichen Breite hinzufügen.
    • +
    • Links Spalte links - zwei Spalten hinzufügen: eine schmale auf der linken Seite und eine breite auf der rechten.
    • +
    • Rechts Spalte rechts - zwei Spalten hinzufügen: eine schmale auf der rechten Seite und eine breite auf der linken.
    -

    Wenn Sie die Spalteneinstellungen anpassen wollen, wählen Sie die Option Benutzerdefinierte Spalten aus der Liste aus. Das Fenster Spalten öffnet sich und Sie können die gewünschte Spaltenanzahl und den Abstand zwischen Spalten festlegen (es ist möglich, bis zu 12 Spalten einzufügen). Geben Sie Ihre gewünschten Werte in die Eingabefelder ein oder passen Sie die vorhandenen Werte über die Pfeile an. Aktivieren Sie das Kontrollkästchen Spaltentrennung, um eine vertikale Linie zwischen den Spalten einzufügen. Wenn Sie fertig sind, klicken Sie auf OK, um die Änderungen anzuwenden.

    +

    Wenn Sie die Spalteneinstellungen anpassen wollen, wählen Sie die Option Benutzerdefinierte Spalten aus der Liste aus. Das Fenster Spalten öffnet sich und Sie können die gewünschte Spaltenanzahl und den Abstand zwischen den Spalten festlegen (es ist möglich bis zu 12 Spalten einzufügen). Geben Sie Ihre gewünschten Werte in die Eingabefelder ein oder passen Sie die vorhandenen Werte über die Pfeile an. Aktivieren Sie das Kontrollkästchen Spaltentrennung, um eine vertikale Linie zwischen den Spalten einzufügen. Wenn Sie fertig sind, klicken Sie auf OK, um die Änderungen anzuwenden.

    Benutzerdefinierte Spalten

    -

    Wenn Sie genau festlegen wollen, wo eine neue spalte beginnt, positionieren Sie den Cursor vor dem Text, den Sie in eine neue Spalte verschieben wollen, klicken Sie in der oberen Symbolleiste auf das Symbol Umbrüche Umbrüche und wählen Sie die Option Spaltenumbruch einfügen. Der Text wird in die nächste Spalte verschoben.

    +

    Wenn Sie genau festlegen wollen, wo eine neue Spalte beginnt, positionieren Sie den Cursor vor dem Text, den Sie in eine neue Spalte verschieben wollen, klicken Sie in der oberen Symbolleiste auf das Symbol Umbrüche Umbrüche und wählen Sie die Option Spaltenumbruch einfügen. Der Text wird in die nächste Spalte verschoben.

    Spaltenumbrüche werden in Ihrem Dokument durch eine gepunktete Linie angezeigt: Spaltenumbruch. Wenn die eingefügten Spaltenumbrüche nicht angezeigt werden, klicken Sie in der Registerkarte Start auf das SymbolFormatierungssymbole. Um einen Spaltenumbruch zu entfernen, wählen Sie diesen mit der Maus aus und drücken Sie die Taste ENTF.

    Um die Spaltenbreite und den Abstand manuell zu ändern, können Sie das horizontale Lineal verwenden.

    Spaltenabstand

    diff --git a/apps/documenteditor/main/resources/help/de/callback.js b/apps/documenteditor/main/resources/help/de/callback.js index b8087d149..ed573d83e 100644 --- a/apps/documenteditor/main/resources/help/de/callback.js +++ b/apps/documenteditor/main/resources/help/de/callback.js @@ -1,6 +1,6 @@ /* * - * (c) Copyright Ascensio System Limited 2010-2018 + * (c) Copyright Ascensio System SIA 2010-2019 * * This program is a free software product. You can redistribute it and/or * modify it under the terms of the GNU Affero General Public License (AGPL) @@ -13,8 +13,8 @@ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For * details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html * - * You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, - * EU, LV-1021. + * You can contact Ascensio System SIA at 20A-12 Ernesta Birznieka-Upisha + * street, Riga, Latvia, EU, LV-1050. * * The interactive user interfaces in modified source and object code versions * of the Program must display Appropriate Legal Notices, as required under diff --git a/apps/documenteditor/main/resources/help/de/editor.css b/apps/documenteditor/main/resources/help/de/editor.css index cf3e4f141..465b9fbe1 100644 --- a/apps/documenteditor/main/resources/help/de/editor.css +++ b/apps/documenteditor/main/resources/help/de/editor.css @@ -60,7 +60,11 @@ th { font-size: 14px; font-weight: bold; -padding-top: 20px; +} + +th.keyboard_section { +font-size: 16px; +padding-top: 30px; } td.function @@ -68,7 +72,13 @@ td.function width: 35%; } -td.shortfunction +th.function +{ +width: 25%; +} + +td.shortfunction, +th.shortfunction { width: 20%; } @@ -78,12 +88,23 @@ td.combination width: 15%; } +th.combination +{ +width: 20%; +} + td.description { width: 50%; } -td.longdescription +th.description +{ +width: 35%; +} + +td.longdescription, +th.longdescription { width: 80%; } @@ -152,4 +173,16 @@ text-decoration: none; font-size: 1em; font-weight: bold; color: #444; +} +kbd { + display: inline-block; + padding: 0.2em 0.3em; + border-radius: .2em; + line-height: 1em; + background-color: #f2f2f2; + font-family: monospace; + white-space: nowrap; + box-shadow: 0 1px 3px rgba(85,85,85,.35); + margin: 0.2em 0.1em; + color: #000; } \ No newline at end of file diff --git a/apps/documenteditor/main/resources/help/de/images/viewsettingsicon.png b/apps/documenteditor/main/resources/help/de/images/viewsettingsicon.png index 02a46ce28..e13ec992d 100644 Binary files a/apps/documenteditor/main/resources/help/de/images/viewsettingsicon.png and b/apps/documenteditor/main/resources/help/de/images/viewsettingsicon.png differ diff --git a/apps/documenteditor/main/resources/help/de/search/indexes.js b/apps/documenteditor/main/resources/help/de/search/indexes.js index 0b093406f..9752a3f68 100644 --- a/apps/documenteditor/main/resources/help/de/search/indexes.js +++ b/apps/documenteditor/main/resources/help/de/search/indexes.js @@ -13,7 +13,7 @@ var indexes = { "id": "HelpfulHints/CollaborativeEditing.htm", "title": "Gemeinsame Bearbeitung von Dokumenten", - "body": "Im Dokumenteneditor haben Sie die Möglichkeit, gemeinsam mit anderen Nutzern an einem Dokument zu arbeiten. Diese Funktion umfasst: gleichzeitiger Zugriff von mehreren Benutzern auf das bearbeitete Dokument visuelle Markierung von Textabschnitten, die aktuell von anderen Benutzern bearbeitet werden Synchronisierung von Änderungen mit einem Klick. Chat zum Austauschen von Ideen zu bestimmten Abschnitten des Dokuments Kommentare mit der Beschreibung von Aufgaben oder Problemen, die Folgehandlungen erforderlich machen. Co-Bearbeitung Im Dokumenteneditor stehen die folgenden Modelle für die Co-Bearbeitung zur Verfügung. Standardmäßig ist der Schnellmodus aktiviert. Die Änderungen von anderen Benutzern werden in Echtzeit angezeigt. Im Modus Strikt werden die Änderungen von anderen Nutzern verborgen, bis Sie auf das Symbol Speichern klicken, um Ihre eigenen Änderungen zu speichern und die Änderungen von anderen anzunehmen. Der Modus kann unter Erweiterte Einstellungen festgelegt werden. Sie können den gewünschten Modus auch in der Registerkarte Zusammenarbeit in der oberen Symbolleiste festlegen, klicken Sie dazu einfach auf das Symbol Co-Bearbeitung. Wenn ein Dokument im Modus Strikt von mehreren Benutzern gleichzeitig bearbeitet wird, werden die bearbeiteten Textpassagen mit gestrichelten Linien in verschiedenen Farben markiert. Wenn Sie den Mauszeiger über eine der bearbeiteten Passagen bewegen, wird der Name des Benutzers angezeigt, der diese Passage aktuell bearbeitet. Im Schnellmodus werden die Aktionen und die Namen der Co-Editoren angezeigt, sobald sie eine Textstelle bearbeitet haben. Die Anzahl der Benutzer, die am aktuellen Dokument arbeiten, wird in der linken unteren Ecke auf der Statusleiste angegeben - . Wenn Sie sehen möchten wer die Datei aktuell bearbeitet, können Sie auf dieses Symbol klicken oder den Bereich Chat öffnen, der eine vollständige Liste aller Benutzer enthält. Wenn niemand die Datei anzeigt oder bearbeitet, sieht das Symbol in der Kopfzeile des Editors folgendermaßen aus: über dieses Symbol können Sie die Benutzer verwalten, die direkt aus dem Dokument auf die Datei zugreifen können; neue Benutzer einladen und ihnen die Berechtigung zum Bearbeiten, Lesen oder Überprüfen erteilen oder Benutzern Zugriffsrechte für die Datei verweigern. Klicken Sie auf dieses Symbol , um den Zugriff auf die Datei zu verwalten. Sie können die Datei auch verwalten, wenn andere Benutzer aktuell mit der Bearbeitung oder Anzeige des Dokuments beschäftigt sind. Sie können die Zugriffsrechte auch in der Registerkarte Zusammenarbeit in der oberen Symbolleiste festlegen, klicken Sie dazu einfach auf das Symbol Teilen. Sobald einer der Benutzer Änderungen durch Klicken auf das Symbol speichert, sehen die anderen Benutzer in der Statusleiste eine Notiz über vorliegende Aktualisierungen. Um Ihre eigenen Änderungen zu speichern, so dass diese auch von den anderen Benutzern eingesehen werden können und um die Aktualisierungen Ihrer Co-Editoren einzusehen, klicken die Aktualisierungen zu erhalten, klicken Sie in der oberen linken Ecke der oberen Symbolleiste auf . Die Updates werden hervorgehoben, damit Sie nachvollziehen können, was genau geändert wurde. Sie können festlegen, welche Änderungen bei der Co-Bearbeitung hervorgehoben werden sollen: Klicken Sie dazu in der Registerkarte Datei auf die Option Erweiterte Einstellungen und wählen Sie zwischen keine, alle und letzte Änderungen in Echtzeit. Wenn Sie die Option Alle anzeigen auswählen, werden alle während der aktuellen Sitzung vorgenommenen Änderungen hervorgehoben. Wenn Sie die Option Letzte anzeigen auswählen, werden alle Änderungen hervorgehoben, die Sie vorgenommen haben, seit Sie das letzte Mal das Symbol Speichern angeklickt haben. Wenn Sie die Option Keine anzeigen auswählen, werden die während der aktuellen Sitzung vorgenommenen Änderungen nicht hervorgehoben. Chat Mit diesem Tool können Sie die Co-Bearbeitung spontan bei Bedarf koordinieren, beispielsweise um mit Ihren Mitarbeitern zu vereinbaren, wer was macht, welchen Absatz Sie jetzt bearbeiten usw. Die Chat-Nachrichten werden nur während einer aktiven Sitzung gespeichert. Um den Inhalt der Präsentation zu besprechen, ist es besser die Kommentarfunktion zu verwenden, da Kommentare bis zum Löschen gespeichert werden. Chat nutzen und Nachrichten für andere Benutzer erstellen: Klicken Sie im linken Seitenbereich auf das Symbol oder wechseln Sie in der oberen Symbolleiste in die Registerkarte Zusammenarbeit und klicken Sie auf die Schaltfläche Chat. Geben Sie Ihren Text ins entsprechende Feld unten ein. klicken Sie auf Senden. Alle Nachrichten, die von Benutzern hinterlassen wurden, werden links in der Leiste angezeigt. Liegen ungelesene neue Nachrichten vor, sieht das Chat-Symbol wie folgt aus - . Um die Leiste mit den Chat-Nachrichten zu schließen, klicken Sie in der linken Seitenleiste auf das Symbol oder klicken Sie in der oberen Symbolleiste erneut auf Chat. Kommentare Einen Kommentar hinterlassen: Wählen Sie einen Textabschnitt, der Ihrer Meinung nach einen Fehler oder ein Problem enthält. Wechseln Sie in der oberen Symbolleiste in die Registerkarte Einfügen oder Zusammenarbeit und klicken Sie in der rechten Seitenleiste auf Kommentare, oder nutzen Sie das Symbol in der linken Seitenleiste, um das Kommentarfeld zu öffnen, klicken Sie anschließend auf Kommentar hinzufügen oder klicken Sie mit der rechten Maustaste auf den gewünschten Textabschnitt und wählen Sie die Option Kommentar hinzufügen aus dem Kontextmenü aus. Geben Sie den gewünschten Text ein. Klicken Sie auf Kommentar hinzufügen/Hinzufügen. Der Kommentar wird im linken Seitenbereich angezeigt. Alle Nutzer können nun auf hinzugefügte Kommentare antworten, Fragen stellen oder über durchgeführte Aktionen berichten. Klicken Sie dazu einfach in das Feld Antworten, direkt unter dem Kommentar. Der von Ihnen kommentierte Textabschnitt wird im Dokument markiert. Um den Kommentar einzusehen, klicken Sie innerhalb des Abschnitts mit der Maus. Wenn Sie diese Funktion deaktivieren möchten, wechseln Sie in die Registerkarte Datei, wählen Sie die Option Erweiterte Einstellungen... und deaktivieren Sie das Kästchen Live-Kommentare einblenden. In diesem Fall werden die kommentierten Abschnitte nur markiert, wenn Sie auf klicken. Hinzugefügte Kommentare verwalten: bearbeiten - klicken Sie dazu auf löschen - klicken Sie dazu auf die Diskussion schließen - klicken Sie dazu auf , wenn die im Kommentar angegebene Aufgabe oder das Problem gelöst wurde. Danach erhält die Diskussion, die Sie mit Ihrem Kommentar geöffnet haben, den Status aufgelöst. Um die Diskussion wieder zu öffnen, klicken Sie auf . Wenn Sie diese Funktion deaktivieren möchten, wechseln Sie in die Registerkarte Datei, wählen Sie die Option Erweiterte Einstellungen... und deaktivieren Sie das Kästchen Gelöste Kommentare einblenden, klicken Sie anschließend auf Anwenden. In diesem Fall werden die kommentierten Abschnitte nur markiert, wenn Sie auf klicken. Wenn Sie im Modus Strikt arbeiten, werden neue Kommentare, die von den anderen Benutzern hinzugefügt wurden, erst eingeblendet, wenn Sie in der linken oberen Ecke der oberen Symbolleiste auf geklickt haben. Um die Leiste mit den Kommentaren zu schließen, klicken Sie in der linken Seitenleiste erneut auf ." + "body": "Im Dokumenteneditor haben Sie die Möglichkeit, gemeinsam mit anderen Nutzern an einem Dokument zu arbeiten. Diese Funktion umfasst: gleichzeitiger Zugriff von mehreren Benutzern auf das bearbeitete Dokument visuelle Markierung von Textabschnitten, die aktuell von anderen Benutzern bearbeitet werden Anzeige von Änderungen in Echtzeit oder Synchronisierung von Änderungen mit einem Klick. Chat zum Austauschen von Ideen zu bestimmten Abschnitten des Dokuments Kommentare mit der Beschreibung von Aufgaben oder Problemen, die Folgehandlungen erforderlich machen. Co-Bearbeitung Im Dokumenteneditor stehen die folgenden Modelle für die Co-Bearbeitung zur Verfügung. Standardmäßig ist der Schnellmodus aktiviert. Die Änderungen von anderen Benutzern werden in Echtzeit angezeigt. Im Modus Strikt werden die Änderungen von anderen Nutzern verborgen, bis Sie auf das Symbol Speichern klicken, um Ihre eigenen Änderungen zu speichern und die Änderungen von anderen anzunehmen. Der Modus kann unter Erweiterte Einstellungen festgelegt werden. Sie können den gewünschten Modus auch in der Registerkarte Zusammenarbeit in der oberen Symbolleiste festlegen, klicken Sie dazu einfach auf das Symbol Co-Bearbeitung. Wenn ein Dokument im Modus Strikt von mehreren Benutzern gleichzeitig bearbeitet wird, werden die bearbeiteten Textpassagen mit gestrichelten Linien in verschiedenen Farben markiert. Wenn Sie den Mauszeiger über eine der bearbeiteten Passagen bewegen, wird der Name des Benutzers angezeigt, der diese Passage aktuell bearbeitet. Im Schnellmodus werden die Aktionen und die Namen der Co-Editoren angezeigt, sobald sie eine Textstelle bearbeitet haben. Die Anzahl der Benutzer, die am aktuellen Dokument arbeiten, wird in der linken unteren Ecke auf der Statusleiste angegeben - . Wenn Sie sehen möchten wer die Datei aktuell bearbeitet, können Sie auf dieses Symbol klicken oder den Bereich Chat öffnen, der eine vollständige Liste aller Benutzer enthält. Wenn niemand die Datei anzeigt oder bearbeitet, sieht das Symbol in der Kopfzeile des Editors folgendermaßen aus: über dieses Symbol können Sie die Benutzer verwalten, die direkt aus dem Dokument auf die Datei zugreifen können; neue Benutzer einladen und ihnen die Berechtigung zum Bearbeiten, Lesen oder Überprüfen erteilen oder Benutzern Zugriffsrechte für die Datei verweigern. Klicken Sie auf dieses Symbol , um den Zugriff auf die Datei zu verwalten. Sie können die Datei auch verwalten, wenn andere Benutzer aktuell mit der Bearbeitung oder Anzeige des Dokuments beschäftigt sind. Sie können die Zugriffsrechte auch in der Registerkarte Zusammenarbeit in der oberen Symbolleiste festlegen, klicken Sie dazu einfach auf das Symbol Teilen. Sobald einer der Benutzer Änderungen durch Klicken auf das Symbol speichert, sehen die anderen Benutzer in der Statusleiste eine Notiz über vorliegende Aktualisierungen. Um Ihre eigenen Änderungen zu speichern, so dass diese auch von den anderen Benutzern eingesehen werden können und um die Aktualisierungen Ihrer Co-Editoren einzusehen, klicken Sie in der oberen linken Ecke der oberen Symbolleiste auf . Die Updates werden hervorgehoben, damit Sie nachvollziehen können, was genau geändert wurde. Sie können festlegen, welche Änderungen bei der Co-Bearbeitung hervorgehoben werden sollen: Klicken Sie dazu in der Registerkarte Datei auf die Option Erweiterte Einstellungen und wählen Sie zwischen keine, alle und letzte Änderungen in Echtzeit. Wenn Sie die Option Alle anzeigen auswählen, werden alle während der aktuellen Sitzung vorgenommenen Änderungen hervorgehoben. Wenn Sie die Option Letzte anzeigen auswählen, werden alle Änderungen hervorgehoben, die Sie vorgenommen haben, seit Sie das letzte Mal das Symbol Speichern angeklickt haben. Wenn Sie die Option Keine anzeigen auswählen, werden die während der aktuellen Sitzung vorgenommenen Änderungen nicht hervorgehoben. Chat Mit diesem Tool können Sie die Co-Bearbeitung spontan bei Bedarf koordinieren, beispielsweise um mit Ihren Mitarbeitern zu vereinbaren, wer was macht, welchen Absatz Sie jetzt bearbeiten usw. Die Chat-Nachrichten werden nur während einer aktiven Sitzung gespeichert. Um den Inhalt der Präsentation zu besprechen, ist es besser die Kommentarfunktion zu verwenden, da Kommentare bis zum Löschen gespeichert werden. Chat nutzen und Nachrichten für andere Benutzer erstellen: Klicken Sie im linken Seitenbereich auf das Symbol oder wechseln Sie in der oberen Symbolleiste in die Registerkarte Zusammenarbeit und klicken Sie auf die Schaltfläche Chat. Geben Sie Ihren Text in das entsprechende Feld unten ein. klicken Sie auf Senden. Alle Nachrichten, die von Benutzern hinterlassen wurden, werden links in der Leiste angezeigt. Liegen ungelesene neue Nachrichten vor, sieht das Chat-Symbol wie folgt aus - . Um die Leiste mit den Chat-Nachrichten zu schließen, klicken Sie in der linken Seitenleiste auf das Symbol oder klicken Sie in der oberen Symbolleiste erneut auf Chat. Kommentare Einen Kommentar hinterlassen: Wählen Sie einen Textabschnitt, der Ihrer Meinung nach einen Fehler oder ein Problem enthält. Wechseln Sie in der oberen Symbolleiste in die Registerkarte Einfügen oder Zusammenarbeit und klicken Sie in der rechten Seitenleiste auf Kommentare, oder nutzen Sie das Symbol in der linken Seitenleiste, um das Kommentarfeld zu öffnen, klicken Sie anschließend auf Kommentar hinzufügen oder klicken Sie mit der rechten Maustaste auf den gewünschten Textabschnitt und wählen Sie die Option Kommentar hinzufügen aus dem Kontextmenü aus. Geben Sie den gewünschten Text ein. Klicken Sie auf Kommentar hinzufügen/Hinzufügen. Der Kommentar wird im linken Seitenbereich angezeigt. Alle Nutzer können nun auf hinzugefügte Kommentare antworten, Fragen stellen oder über durchgeführte Aktionen berichten. Klicken Sie dazu einfach in das Feld Antworten, direkt unter dem Kommentar. Der von Ihnen kommentierte Textabschnitt wird im Dokument markiert. Um den Kommentar einzusehen, klicken Sie einfach auf den entsprechenden Abschnitt. Wenn Sie diese Funktion deaktivieren möchten, wechseln Sie in die Registerkarte Datei, wählen Sie die Option Erweiterte Einstellungen... und deaktivieren Sie das Kästchen Live-Kommentare einblenden. In diesem Fall werden die kommentierten Abschnitte nur markiert, wenn Sie auf klicken. Hinzugefügte Kommentare verwalten: bearbeiten - klicken Sie dazu auf löschen - klicken Sie dazu auf die Diskussion schließen - klicken Sie dazu auf , wenn die im Kommentar angegebene Aufgabe oder das Problem gelöst wurde. Danach erhält die Diskussion, die Sie mit Ihrem Kommentar geöffnet haben, den Status aufgelöst. Um die Diskussion wieder zu öffnen, klicken Sie auf . Wenn Sie diese Funktion deaktivieren möchten, wechseln Sie in die Registerkarte Datei, wählen Sie die Option Erweiterte Einstellungen... und deaktivieren Sie das Kästchen Gelöste Kommentare einblenden, klicken Sie anschließend auf Anwenden. In diesem Fall werden die kommentierten Abschnitte nur markiert, wenn Sie auf klicken. Wenn Sie im Modus Strikt arbeiten, werden neue Kommentare, die von den anderen Benutzern hinzugefügt wurden, erst eingeblendet, wenn Sie in der linken oberen Ecke der oberen Symbolleiste auf geklickt haben. Um die Leiste mit den Kommentaren zu schließen, klicken Sie in der linken Seitenleiste erneut auf ." }, { "id": "HelpfulHints/KeyboardShortcuts.htm", @@ -43,7 +43,7 @@ var indexes = { "id": "HelpfulHints/SupportedFormats.htm", "title": "Unterstützte Formate von elektronischen Dokumenten", - "body": "Elektronische Dokumente stellen die am meisten benutzte Computerdateien dar. Dank des inzwischen hoch entwickelten Computernetzwerks ist es bequemer anstatt von gedruckten Dokumenten elektronische Dokumente zu verbreiten. Aufgrund der Vielfältigkeit der Geräte, die für die Anzeige der Dokumente verwendet werden, gibt es viele proprietäre und offene Dateiformate. Der Dokumenteneditor unterstützt die geläufigsten Formate. Format Beschreibung Anzeigen Bearbeiten Download DOC Dateierweiterung für Textverarbeitungsdokumente, die mit Microsoft Word erstellt werden + + DOCX Office Open XML Gezipptes, XML-basiertes, von Microsoft entwickeltes Dateiformat zur Präsentation von Kalkulationstabellen, Diagrammen, Präsentationen und Textverarbeitungsdokumenten + + + ODT Textverarbeitungsformat von OpenDocument, ein offener Standard für elektronische Dokumente + + + RTF Rich Text Format Plattformunabhängiges Datei- und Datenaustauschformat von Microsoft für formatierte Texte + + + TXT Dateierweiterung reiner Textdateien mit wenig Formatierung + + + PDF Portable Document Format Dateiformat, mit dem Dokumente unabhängig vom ursprünglichen Anwendungsprogramm, Betriebssystem und der Hardware originalgetreu wiedergegeben werden können + + HTML HyperText Markup Language Hauptauszeichnungssprache für Webseiten + EPUB Electronic Publication Offener Standard für E-Books vom International Digital Publishing Forum + XPS Open XML Paper Specification Offenes, lizenzfreies Dokumentenformat von Microsoft mit festem Layout + DjVu Dateiformat, das hauptsächlich zur Speicherung gescannter Dokumente (vor allem solcher mit Text, Rastergrafiken und Fotos) konzipiert wurde +" + "body": "Elektronische Dokumente stellen die am meisten benutzte Computerdateien dar. Dank des inzwischen hoch entwickelten Computernetzwerks ist es bequemer anstatt von gedruckten Dokumenten elektronische Dokumente zu verbreiten. Aufgrund der Vielfältigkeit der Geräte, die für die Anzeige der Dokumente verwendet werden, gibt es viele proprietäre und offene Dateiformate. Der Dokumenteneditor unterstützt die geläufigsten Formate. Format Beschreibung Anzeigen Bearbeiten Download DOC Dateierweiterung für Textverarbeitungsdokumente, die mit Microsoft Word erstellt werden + DOCX Office Open XML Gezipptes, XML-basiertes, von Microsoft entwickeltes Dateiformat zur Präsentation von Kalkulationstabellen, Diagrammen, Präsentationen und Textverarbeitungsdokumenten + + + ODT Textverarbeitungsformat von OpenDocument, ein offener Standard für elektronische Dokumente + + + RTF Rich Text Format Plattformunabhängiges Datei- und Datenaustauschformat von Microsoft für formatierte Texte + + + TXT Dateierweiterung reiner Textdateien mit wenig Formatierung + + + PDF Portable Document Format Dateiformat, mit dem Dokumente unabhängig vom ursprünglichen Anwendungsprogramm, Betriebssystem und der Hardware originalgetreu wiedergegeben werden können + + HTML HyperText Markup Language Hauptauszeichnungssprache für Webseiten + EPUB Electronic Publication Offener Standard für E-Books vom International Digital Publishing Forum + XPS Open XML Paper Specification Offenes, lizenzfreies Dokumentenformat von Microsoft mit festem Layout + DjVu Dateiformat, das hauptsächlich zur Speicherung gescannter Dokumente (vor allem solcher mit Text, Rastergrafiken und Fotos) konzipiert wurde +" }, { "id": "ProgramInterface/FileTab.htm", @@ -57,8 +57,8 @@ var indexes = }, { "id": "ProgramInterface/InsertTab.htm", - "title": "Registerkarte einfügen", - "body": "Die Registerkarte Einfügen ermöglicht das Hinzufügen einiger Seitenformatierungselemente sowie visueller Objekte und Kommentare. Sie können: Seitenumbrüche, Abschnittsumbrüche und Spaltenumbrüche einfügen, Kopf- und Fußzeilen und Seitenzahlen einfügen, Tabellen, Bilder, Diagramme und Formen einfügen Hyperlinks, Kommentare einfügen, Textboxen und TextArt Objekte, Gleichungen, Initialbuchstaben und Inhaltskontrollen einfügen." + "title": "Registerkarte Einfügen", + "body": "Die Registerkarte Einfügen ermöglicht das Hinzufügen einiger Seitenformatierungselemente sowie visueller Objekte und Kommentare. Sie können: Seitenumbrüche, Abschnittsumbrüche und Spaltenumbrüche einfügen, Kopf- und Fußzeilen und Seitenzahlen einfügen, Tabellen, Bilder, Diagramme und Formen einfügen Hyperlinks und Kommentare einfügen, Textboxen und TextArt Objekte, Gleichungen, Initialbuchstaben und Inhaltskontrollen einfügen." }, { "id": "ProgramInterface/LayoutTab.htm", @@ -73,7 +73,7 @@ var indexes = { "id": "ProgramInterface/ProgramInterface.htm", "title": "Einführung in die Benutzeroberfläche des Dokumenteneditors", - "body": "Der Dokumenteneditor verfügt über eine Benutzeroberfläche mit Registerkarten, in der Bearbeitungsbefehle nach Funktionalität in Registerkarten gruppiert sind. Die Oberfläche des Editors besteht aus folgenden Hauptelementen: In der Kopfzeile des Editors werden das Logo, die Menü-Registerkarten und der Name des Dokuments angezeigt sowie zwei Symbole auf der rechten Seite, über die Sie Zugriffsrechte festlegen und zur Dokumentenliste zurückkehren können. Abhängig von der ausgewählten Registerkarten werden in der oberen Symbolleiste eine Reihe von Bearbeitungsbefehlen angezeigt. Aktuell stehen die folgenden Registerkarten zur Verfügung: Datei, Start, Einfügen, Layout, Referenzen, Zusammenarbeit, Plug-ins.Die Befehle Drucken, Speichern, Kopieren, Einfügen, Rückgängig machen und Wiederholen stehen unabhängig von der ausgewählten Registerkarte jederzeit im linken Teil der oberen Menüleiste zur Verfügung. In der Statusleiste am unteren Rand des Editorfensters finden Sie die Anzeige der Seitennummer und Benachrichtigungen vom System (wie beispielsweise „Alle Änderungen wurden gespeichert\" etc.), außerdem können Sie die Textsprache festlegen und die Rechtschreibprüfung aktivieren, den Modus Änderungen nachverfolgen einschalten und den Zoom anpassen. Über die Symbole der linken Seitenleiste können Sie die Funktion Suchen und Ersetzen nutzen, Kommentare, Chats und die Navigation öffnen, unser Support-Team kontaktieren und Informationen über das Programm einsehen. Über die rechte Seitenleiste können zusätzliche Parameter von verschiedenen Objekten eingestellt werden. Wenn Sie im Text ein bestimmtes Objekt auswählen, wird das entsprechende Symbol in der rechten Seitenleiste aktiviert. Klicken Sie auf dieses Symbol, um die rechte Seitenleiste zu erweitern. Horizontale und vertikale Lineale ermöglichen das Ausrichten von Text und anderen Elementen in einem Dokument sowie das Festlegen von Rändern, Tabstopps und Absatzeinzügen. Über den Arbeitsbereich können Sie den Dokumentinhalt anzeigen und Daten eingeben und bearbeiten. Über die Scroll-Leiste auf der rechten Seite können Sie mehrseitige Dokumente nach oben oder unten scrollen. Zur Vereinfachung können Sie bestimmte Komponenten verbergen und bei Bedarf erneut anzeigen. Weitere Informationen zum Anpassen der Ansichtseinstellungen finden Sie auf dieser Seite." + "body": "Der Dokumenteneditor verfügt über eine Benutzeroberfläche mit Registerkarten, in der Bearbeitungsbefehle nach Funktionalität in Registerkarten gruppiert sind. Die Oberfläche des Editors besteht aus folgenden Hauptelementen: In der Kopfzeile des Editors werden das Logo, die Menü-Registerkarten und der Name des Dokuments angezeigt sowie drei Symbole auf der rechten Seite, über die Sie Zugriffsrechte festlegen, zur Dokumentenliste zurückkehren, Einstellungen anzeigen und auf die Erweiterten Einstellungen des Editors zugreifen können. Abhängig von der ausgewählten Registerkarte werden in der oberen Symbolleiste eine Reihe von Bearbeitungsbefehlen angezeigt. Aktuell stehen die folgenden Registerkarten zur Verfügung: Datei, Start, Einfügen, Layout, Referenzen, Zusammenarbeit, Plug-ins.Die Befehle Drucken, Speichern, Kopieren, Einfügen, Rückgängig machen und Wiederholen stehen unabhängig von der ausgewählten Registerkarte jederzeit im linken Teil der oberen Menüleiste zur Verfügung. In der Statusleiste am unteren Rand des Editorfensters finden Sie die Anzeige der Seitennummer und Benachrichtigungen vom System (wie beispielsweise „Alle Änderungen wurden gespeichert\" etc.), außerdem können Sie die Textsprache festlegen und die Rechtschreibprüfung aktivieren, den Modus Änderungen nachverfolgen einschalten und den Zoom anpassen. Über die Symbole der linken Seitenleiste können Sie die Funktion Suchen und Ersetzen nutzen, Kommentare, Chats und die Navigation öffnen, unser Support-Team kontaktieren und Informationen über das Programm einsehen. Über die rechte Seitenleiste können zusätzliche Parameter von verschiedenen Objekten angepasst werden. Wenn Sie im Text ein bestimmtes Objekt auswählen, wird das entsprechende Symbol in der rechten Seitenleiste aktiviert. Klicken Sie auf dieses Symbol, um die rechte Seitenleiste zu erweitern. Horizontale und vertikale Lineale ermöglichen das Ausrichten von Text und anderen Elementen in einem Dokument sowie das Festlegen von Rändern, Tabstopps und Absatzeinzügen. Über den Arbeitsbereich können Sie den Dokumentinhalt anzeigen und Daten eingeben und bearbeiten. Über die Scroll-Leiste auf der rechten Seite können Sie mehrseitige Dokumente nach oben oder unten scrollen. Zur Vereinfachung können Sie bestimmte Komponenten verbergen und bei Bedarf erneut anzeigen. Weitere Informationen zum Anpassen der Ansichtseinstellungen finden Sie auf dieser Seite." }, { "id": "ProgramInterface/ReferencesTab.htm", @@ -93,7 +93,7 @@ var indexes = { "id": "UsageInstructions/AddHyperlinks.htm", "title": "Hyperlink einfügen", - "body": "Einfügen eines Hyperlinks Platzieren Sie Ihren Mauszeiger an die Stelle im Text, die Sie in den Link integrieren möchten. Wechseln Sie in der oberen Symbolleiste auf die Registerkarte Einfügen oder Verweise. Klicken Sie auf das Symbol Hyperlink in der oberen Symbolleiste. Im sich nun öffnenden Fenster Einstellungen Hyperlink, können Sie die Parameter für den Hyperlink bestimmen: Link zu - geben Sie eine URL im Format http://www.example.com ein. Angezeigter Text - geben Sie den klickbaren Text ein, der zu der im oberen Feld angegebenen Webadresse führt. Infobox - geben Sie einen Text ein, der in einem Dialogfenster angezeigt wird und den Nutzer über den Inhalt des Verweises informiert. Klicken Sie auf OK. Um einen Hyperlink hinzuzufügen, können Sie auch mit der rechten Maustaste irgendwo im Dokument klicken und die Option Hyperlink im Kontextmenü auswählen, dadurch wird das oben angezeigte Fenster geöffnet. Hinweis: Es ist auch möglich, ein Zeichen, Wort, eine Wortverbindung oder einen Textabschnitt mit der Maus oder über die Tastatur auszuwählen. Klicken Sie anschließend in den Registerkarten Einfügen oder Referenzen auf Hyperlink oder klicken Sie mit der rechten Maustaste auf die Auswahl und wählen Sie im Kontextmenü die Option Hyperlink aus. Danach öffnet sich das oben dargestellte Fenster und im Feld Angezeigter Text erscheint der ausgewählte Textabschnitt. Wenn Sie den Mauszeiger über den eingefügten Hyperlink bewegen, wird der von Ihnen im Feld QuickInfo eingebene Text angezeigt. Sie können dem Link folgen, indem Sie die Taste STRG drücken und dann auf den Link in Ihrem Dokument klicken. Um den hinzugefügten Hyperlink zu bearbeiten oder zu entfernen, klicken Sie mit der rechten Maustaste auf den Link und wählen Sie Hyperlink Optionen und anschließend Hyperlink bearbeiten oder Hyperlink entfernen." + "body": "Einfügen eines Hyperlinks: Platzieren Sie Ihren Mauszeiger an der Position wo der Hyperlink eingefügt werden soll. Wechseln Sie in der oberen Symbolleiste auf die Registerkarte Einfügen oder Verweise. Klicken Sie auf das Symbol Hyperlink in der oberen Symbolleiste. Im sich nun öffnenden Fenster Einstellungen Hyperlink können Sie die Parameter für den Hyperlink festlegen: Wählen Sie den gewünschten Linktyp aus:Wenn Sie einen Hyperlink einfügen möchten, der auf eine externe Website verweist, wählen Sie Website und geben Sie eine URL im Format http://www.example.com in das Feld Link zu ein. Wenn Sie einen Hyperlink einfügen möchten, der zu einer bestimmten Stelle im gleichen Dokument führt, dann wählen Sie die Option In Dokument einfügen, wählen Sie dann eine der vorhandenen Überschriften im Dokumenttext oder eines der zuvor hinzugefügten Lesezeichen aus. Angezeigter Text - geben Sie den klickbaren Text ein, der zu der im oberen Feld angegebenen Webadresse führt. Infobox - geben Sie einen Text ein, der in einem Dialogfenster angezeigt wird und den Nutzer über den Inhalt des Verweises informiert. Klicken Sie auf OK. Um einen Hyperlink einzufügen können Sie auch die Tastenkombination STRG+K nutzen oder klicken Sie mit der rechten Maustaste an die Stelle an der Sie den Hyperlink einfügen möchten und wählen Sie die Option Hyperlink im Rechtsklickmenü aus. Hinweis: Es ist auch möglich, ein Zeichen, Wort, eine Wortverbindung oder einen Textabschnitt mit der Maus oder über die Tastatur auszuwählen. Öffnen Sie anschließend das Menü für die Hyperlink-Einstellungen wie zuvor beschrieben. In diesem Fall erscheint im Feld Angezeigter Text der ausgewählte Textabschnitt. Wenn Sie den Mauszeiger über den eingefügten Hyperlink bewegen, wird der von Ihnen im Feld QuickInfo eingebene Text angezeigt. Sie können dem Link folgen, indem Sie die Taste STRG drücken und dann auf den Link in Ihrem Dokument klicken. Um den hinzugefügten Hyperlink zu bearbeiten oder zu entfernen, klicken Sie mit der rechten Maustaste auf den Link, wählen Sie dann das Optionsmenü für den Hyperlink aus und klicken Sie anschließend auf Hyperlink bearbeiten oder Hyperlink entfernen." }, { "id": "UsageInstructions/AlignArrangeObjects.htm", @@ -133,7 +133,7 @@ var indexes = { "id": "UsageInstructions/CreateLists.htm", "title": "Listen erstellen", - "body": "Liste in einem Dokument erstellen: Bewegen Sie den Cursor an die Stelle, wo Sie die Liste beginnen möchten (dabei kann es sich um eine neue Zeile handeln oder eine bereits vorhandene). Wechseln Sie in der oberen Symbolleiste auf die Registerkarte Start. Wählen Sie einen Listentyp: Aufzählung mit Markern - klicken Sie in der Menüleiste auf das Symbol Aufzählungszeichen Nummerierte Liste mit Zahlen oder Buchstaben - klicken Sie in der Menüleiste auf das Symbol Nummerierte Liste Hinweis: Über den schwarzen Pfeil neben dem Symbol Aufzählungszeichen oder Nummerierte Liste, können Sie das Format der Liste näher bestimmen. Jedes Mal, wenn Sie nun zum Ende der Zeile die Eingabetaste drücken, erscheint eine neue Aufzählung oder eine neue Position der Nummerierten Liste. Um die Liste zu beenden, drücken Sie die Rücktaste und fahren Sie mit einem üblichen Textabsatz fort. Sie können den Texteinzug in den Listen und die dazugehörigen Verschachtelung ändern. Klicken Sie dazu auf Listeneinzug anpassen , Einzug verkleinern und Einzug vergrößern in der Registerkarte Start. Hinweis: Die zusätzlichen Einzugs- und Abstandparameter können im rechten Seitenbereich und im Fenster mit den erweiterten Einstellungen geändert werden. Weitere Informationen dazu erhalten in den Abschnitten Absatzeinzüge ändern und Zeilenabstand festlegen." + "body": "Liste in einem Dokument erstellen: Bewegen Sie den Cursor an die Stelle, wo Sie die Liste beginnen möchten (dabei kann es sich um eine neue Zeile handeln oder eine bereits vorhandene). Wechseln Sie in der oberen Symbolleiste auf die Registerkarte Start. Wählen Sie den gewünschten Listentyp aus: Aufzählung mit Markern - klicken Sie in der oberen Symbolleiste auf das Symbol Aufzählungszeichen Nummerierte Liste mit Zahlen oder Buchstaben - klicken Sie in der oberen Symbolleiste auf das Symbol Nummerierte Liste Hinweis: Mit dem schwarzen Pfeil neben dem Symbol Aufzählungszeichen oder Nummerierung, können Sie das Format der Liste näher bestimmen. Jedes Mal, wenn Sie nun am Zeilenende die Eingabetaste drücken, erscheint eine neue Aufzählung oder eine neue Position der nummerierten Liste. Um die Liste zu beenden, drücken Sie die Rücktaste und fahren Sie mit einem üblichen Textabsatz fort. Das Programm erstellt automatisch nummerierte Listen, wenn Sie die Ziffer 1 mit einem Punkt oder einer Klammer und einem Leerzeichen eingeben: 1., 1). Listen mit Aufzählungszeichen können automatisch erstellt werden, wenn Sie die Zeichen -, * mit einem nachfolgenden Leerzeichen eingeben. Sie können den Texteinzug in den Listen und die dazugehörigen Verschachtelung ändern. Klicken Sie dazu auf in der oberen Symbolleiste auf der Registerkarte Start auf Mehrstufige Liste , Einzung verkleinern und Einzug vergrößern . Hinweis: Die zusätzlichen Einzugs- und Abstandparameter können im rechten Seitenbereich und im Fenster mit den erweiterten Einstellungen geändert werden. Weitere Informationen dazu erhalten Sie in den Abschnitten Absatzeinzüge ändern und Zeilenabstand festlegen. Listen verbinden und trennen Eine Liste mit der vorherigen Liste zusammenfügen: Klicken Sie mit der rechten Maustaste auf den ersten Eintrag der zweiten Liste. Wählen Sie im Kontextmenü die Option Mit vorheriger Liste verbinden. Die Listen werden zusammengefügt und die Nummerierung wird gemäß der ersten Listennummerierung fortgesetzt. Eine Liste trennen: Klicken Sie mit der rechten Maustaste auf das Listenelement, mit dem Sie eine neue Liste beginnen möchten. Wählen Sie im Kontextmenü die Option Liste trennen. Die Liste wird getrennt und die Nummerierung in der zweiten Liste beginnt von vorne. Nummerierung ändern So können Sie die fortlaufende Nummerierung in der zweiten Liste gemäß der vorherigen Listennummerierung fortsetzen: Klicken Sie mit der rechten Maustaste auf den ersten Eintrag der zweiten Liste. Wählen Sie im Kontextmenü die Option Fortlaufende Nummerierung. Die Nummerierung wird gemäß der ersten Listennummerierung fortgesetzt. Einen individuellen Anfangswert für die Nummerierung festlegen: Klicken Sie mit der rechten Maustaste auf das Listenelement, dem Sie einen neuen Nummerierungswert zuweisen möchten. Wählen Sie im Kontextmenü die Option Nummerierungswert festlegen. Legen Sie im sich nun öffnenden Fester den gewünschten Zahlenwert fest und klicken Sie dann auf OK." }, { "id": "UsageInstructions/CreateTableOfContents.htm", @@ -160,6 +160,11 @@ var indexes = "title": "AutoFormen einfügen", "body": "Eine AutoForm einfügen Eine AutoForm in einem Dokument einfügen: Wechseln Sie in der oberen Symbolleiste auf die Registerkarte Einfügen. Klicken Sie auf der oberen Symbolleiste auf das Symbol Form Wählen Sie eine der verfügbaren Gruppen für AutoFormen aus: Standardformen, geformte Pfeile, Mathe, Diagramme, Sterne und Bänder, Legenden, Schaltflächen, Rechtecke, Linien. Klicken Sie auf in der gewählten Gruppe auf die gewünschte AutoForm. Positionieren Sie den Mauszeiger an der Stelle, an der Sie eine Form einfügen möchten. Sobald die AutoForm hinzugefügt wurde, können Sie Größe, Position und Eigenschaften ändern.Hinweis: Um der AutoForm eine Beschriftung hinzuzufügen, wählen Sie die Form auf der Seite aus und geben Sie den gewünschten Text ein. Ein solcher Text wird Bestandteil der AutoForm (wenn Sie die AutoForm verschieben oder drehen, wird der Text ebenfalls verschoben oder gedreht). AutoFormen bewegen und die Größe ändern Um die Formgröße zu ändern, ziehen Sie die kleinen Quadrate an den Kanten der Formen. Um die ursprünglichen Proportionen der ausgewählten AutoFormen während der Größenänderung beizubehalten, halten Sie Taste UMSCHALT gedrückt und ziehen Sie eines der Ecksymbole. Bei der Änderung einiger Formen, z.B. geformte Pfeile oder Legenden, ist auch ein gelbes diamantartiges Symbol verfügbar. Über dieses Symbol können verschiedene Aspekte einer Form geändert werden, z.B. die Länge des Pfeilkopfes. Um die Formposition zu ändern, nutzen Sie das Symbol, das eingeblendet wird, wenn Sie mit dem Mauszeiger über die AutoForm fahren. Ziehen Sie die Form in die gewünschten Position, ohne die Maustaste loszulassen. Wenn Sie die AutoForm verschieben, werden Hilfslinien angezeigt, damit Sie das Objekt auf der Seite präzise positionieren können (wenn ein anderer Umbruchstil als mit Text in Zeile ausgewählt haben). Um die AutoForm in 1-Pixel-Stufen zu verschieben, halten Sie die Taste STRG gedrückt und verwenden Sie die Pfeile auf der Tastatur. Um die AutoForm streng horizontal/vertikal zu verschieben und sie in perpendikulare Richtung nicht rutschen zu lassen, halten Sie die UMSCHALT-Taste beim Drehen gedrückt. Um die Form zu drehen, richten Sie den Mauszeiger auf den Drehpunkt und ziehen Sie ihn im Uhrzeigersinn oder gegen Uhrzeigersinn. Um die Drehung in 15-Grad-Stufen durchzuführen, halten Sie die UMSCHALT-Taste bei der Drehung gedrückt. AutoFormeinstellungen anpassen Nutzen Sie zum ausrichten und anordnen von AutoFormen das Rechtsklickmenü. Die Menüoptionen sind: Ausschneiden, Kopieren, Einfügen - Standardoptionen zum Ausschneiden oder Kopieren ausgewählter Textpassagen/Objekte und zum Einfügen von zuvor ausgeschnittenen/kopierten Textstellen oder Objekten an der aktuellen Cursorposition. Anordnen - um eine ausgewählte Form in den Vordergrund bzw. Hintergrund oder eine Ebene nach vorne bzw. hinten zu verschieben sowie Formen zu gruppieren und die Gruppierung aufzuheben (um diese wie ein einzelnes Objekt behandeln zu können). Weitere Informationen zum Anordnen von Objekten finden Sie auf dieser Seite. Ausrichten - um eine Form linksbündig, zentriert, rechtsbündig, oben, mittig oder unten auszurichten. Weitere Informationen zum Ausrichten von Objekten finden Sie auf dieser Seite. Textumbruch - der Stil für den Textumbruch wird aus den verfügbaren Vorlagen ausgewählt: Mit Text in Zeile, Quadrat, Eng, Transparent, Oben und unten, Vorne, Hinten (für weitere Information lesen Sie die folgende Beschreibung der erweiterten Einstellungen). Die Option Umbruchsgrenze bearbeiten ist nur verfügbar, wenn Sie einen anderen Umbruchstil als „Mit Text in Zeile“ auswählen. Ziehen Sie die Umbruchpunkte, um die Grenze benutzerdefiniert anzupassen. Um einen neuen Rahmenpunkt zu erstellen, klicken Sie auf eine beliebige Stelle auf der roten Linie und ziehen Sie diese an die gewünschte Position. Form - Erweiterte Einstellungen wird verwendet, um das Fenster „Absatz - Erweiterte Einstellungen“ zu öffnen. Einige Eigenschaften der AutoFormen können in der Registerkarte Formeinstellungen in der rechten Seitenleiste geändert werden. Klicken Sie dazu auf die Form und wählen Sie das Symbol Formeinstellungen in der rechten Seitenleiste aus. Die folgenden Eigenschaften können geändert werden: Füllung - zum Ändern der Füllung einer AutoForm. Folgende Optionen stehen Ihnen zur Verfügung: Einfarbige Füllung - wählen Sie diese Option, um die Volltonfarbe festzulegen, mit der Sie die innere Fläche der ausgewählten Autoform ausfüllen möchten. Klicken Sie auf das Farbfeld unten und wählen Sie die gewünschte Farbe aus den verfügbaren Farbpaletten aus oder legen Sie eine beliebige Farbe fest: Farbverlauf - Wählen Sie diese Option, um die Form mit zwei Farben zu füllen, die sich sanft von einer zur anderen ändern. Stil - wählen Sie eine der verfügbaren Optionen: Linear (Farben ändern sich linear, d.h. entlang der horizontalen/vertikalen Achse oder diagonal in einem 45-Grad Winkel) oder Radial (Farben ändern sich kreisförmig vom Zentrum zu den Kanten). Richtung - wählen Sie eine Vorlage aus dem Menü aus. Wenn der Farbverlauf Linear ausgewählt ist, sind die folgenden Richtungen verfügbar: von oben links nach unten rechts, von oben nach unten, von oben rechts nach unten links, von rechts nach links, von unten rechts nach oben links, von unten nach oben, von unten links nach oben rechts, von links nach rechts. Wenn der Farbverlauf Radial ausgewählt ist, steht nur eine Vorlage zur Verfügung. Farbverlauf - klicken Sie auf den linken Schieberegler unter der Farbverlaufsleiste, um das Farbfeld für die erste Farbe zu aktivieren. Klicken Sie auf das Farbfeld auf der rechten Seite, um die erste Farbe in der Farbpalette auszuwählen. Nutzen Sie den rechten Schieberegler unter der Farbverlaufsleiste, um den Wechselpunkt festzulegen, an dem eine Farbe in die andere übergeht. Nutzen Sie den rechten Schieberegler unter der Farbverlaufsleiste, um die zweite Farbe anzugeben und den Wechselpunkt festzulegen. Bild- oder Texturfüllung - wählen Sie diese Option, um ein Bild oder eine vorgegebene Textur als Formhintergrund zu benutzen. Wenn Sie ein Bild als Hintergrund für eine Form verwenden möchten, können Sie ein Bild aus Datei einfügen, indem Sie über das geöffnete Fenstern den Speicherort auf Ihrem Computer auswählen, oder aus URL, indem Sie die entsprechende URL-Adresse ins geöffnete Fenster einfügen. Wenn Sie eine Textur als Hintergrund für eine Form nutzen möchten, öffnen Sie das Menü Textur und wählen Sie die gewünschte Texturvoreinstellung aus.Momentan sind die folgenden Texturen vorhanden: Leinwand, Karton, dunkler Stoff, Korn, Granit, graues Papier, stricken, Leder, braunes Papier, Papyrus, Holz. Wenn das gewählte Bild kleiner oder größer als die AutoForm ist, können Sie die Option Strecken oder Kacheln aus dem Listenmenü auswählen.Die Option Strecken ermöglicht Ihnen die Größe des Bildes so anzupassen, dass es den kompletten Bereich der AutoForm füllen kann. Die Option Kacheln ermöglicht Ihnen nur einen Teil eines größeren Bildes zu verwenden und die Originalgröße beizubehalten oder ein kleines Bild unter Beibehaltung der Originalgröße zu wiederholen und durch diese Wiederholungen die gesamte Fläche der AutoForm auszufüllen. Hinweis: Jede Voreinstellung für Texturfüllungen ist dahingehend festgelegt, den gesamten Bereich auszufüllen, aber Sie können nach Bedarf auch den Effekt Strecken anwenden. Muster - wählen Sie diese Option, um die Form mit einem zweifarbigen Design zu füllen, dass aus regelmäßig wiederholten Elementen besteht. Muster - wählen Sie eine der Designvorgaben aus dem Menü aus. Vordergrundfarbe - klicken Sie auf dieses Farbfeld, um die Farbe der Musterelemente zu ändern. Hintergrundfarbe - klicken Sie auf dieses Farbfeld, um die Farbe des Hintergrundmusters zu ändern. Keine Füllung - wählen Sie diese Option, wenn Sie keine Füllung verwenden möchten. Transparenz - hier können Sie den Grad der gewünschten Transparenz auswählen, bringen Sie dazu den Schieberegler in die gewünschte Position oder geben Sie manuell einen Prozentwert ein. Der Standardwert beträgt 100%. Also volle Deckkraft. Der Wert 0% steht für vollständige Transparenz. Strich - nutzen Sie diese Sektion, um die Konturbreite und -farbe der AutoForm zu ändern. Um die Strichstärke zu ändern, wählen Sie eine der verfügbaren Optionen im Listenmenü Größe aus. Die verfügbaren Optionen sind: 0,5 Pt., 1 Pt., 1,5 Pt., 2,25 Pt., 3 Pt., 4,5 Pt., 6 Pt. Alternativ können Sie die Option Keine Linie auswählen, wenn Sie keine Umrandung wünschen. Um die Konturfarbe zu ändern, klicken Sie auf das farbige Feld und wählen Sie die gewünschte Farbe aus. Um den Stil der Kontur zu ändern, wählen Sie die gewünschte Option aus der entsprechenden Dropdown-Liste aus (standardmäßig wird eine durchgezogene Linie verwendet, diese können Sie in eine der verfügbaren gestrichelten Linien ändern). Textumbruch - wählen Sie den Stil für den Textumbruch aus den verfügbaren Stilen aus: Mit Text verschieben, Quadrat, Eng, Transparent, Oben und unten, Vorne, Hinten (weitere Informationen finden Sie in der nachfolgenden Beschreibung der erweiterten Einstellungen). AutoForm ändern - ersetzen Sie die aktuelle AutoForm durch eine andere, die Sie im Listenmenü wählen können. Um die erweiterte Einstellungen der AutoForm zu ändern, klicken Sie mit der rechten Maustaste auf die Form und wählen Sie die Option Erweiterte Einstellungen im Menü aus, oder klicken Sie in der rechten Seitenleiste auf die Verknüpfung Erweiterte Einstellungen anzeigen. Das Fenster „Form - Erweiterte Einstellungen“ wird geöffnet: Die Registerkarte Größe enthält die folgenden Parameter: Breite - ändern Sie die Breite der AutoForm mit den verfügbaren Optionen. Absolut - geben Sie einen exakten Wert in absoluten Einheiten an, wie Zentimeter/Punkte/Zoll (abhängig von der Voreinstellung in der Registerkarte Datei -> Erweiterte Einstellungen...). Relativ - geben Sie einen Prozentwert an, gemessen von linker Seitenrandbreite, Seitenrand (der Abstand zwischen dem linken und rechten Seitenrand), Seitenbreite oder der rechten Seitenrandbreite. Höhe - ändern Sie die Höhe der AutoForm. Absolut - geben Sie einen exakten Wert in absoluten Einheiten an, wie Zentimeter/Punkte/Zoll (abhängig von der Voreinstellung in der Registerkarte Datei -> Erweiterte Einstellungen...). Relativ - geben Sie einen Prozentwert an, gemessen vom Seitenrand (der Abstand zwischen dem linken und rechten Seitenrand), der unteren Randhöhe, der Seitenhöhe oder der oberen Randhöhe. Wenn die Funktion Seitenverhältnis sperren aktivieren ist, werden Breite und Höhe gleichmäßig geändert und das ursprünglichen Seitenverhältnis wird beibehalten. Die Registerkarte Textumbruch enthält die folgenden Parameter: Textumbruch - legen Sie fest, wie die Form im Verhältnis zum Text positioniert wird: entweder als Teil des Textes (wenn Sie die Option „Mit Text verschieben“ auswählen) oder an allen Seiten von Text umgeben (wenn Sie einen anderen Stil wählen). Mit Text verschieben - die Form wird Teil des Textes (wie ein Zeichen) und wenn der Text verschoben wird, wird auch die Form verschoben. In diesem Fall sind die Positionsoptionen nicht verfügbar. Ist eine der folgenden Umbrucharten ausgewählt, kann die Form unabhängig vom Text verschoben und auf der Seite positioniert werden: Quadrat - der Text bricht um den rechteckigen Kasten, der die Form umgibt. Eng - der Text bricht um die Formkanten herum. Transparent - der Text bricht um die Formkanten herum und füllt den offenen weißen Leerraum innerhalb der Form. Wählen Sie für diesen Effekt die Option Umbruchsgrenze bearbeiten aus dem Rechtsklickmenü aus. Oben und unten - der Text ist nur oberhalb und unterhalb der Form. Vorne - die Form überlappt mit dem Text. Hinten - der Text überlappt mit der Form. Wenn Sie die Stile Quadrat, Eng, Transparent oder Oben und unten auswählen, haben Sie die Möglichkeit zusätzliche Parameter einzugeben - Abstand vom Text auf allen Seiten (oben, unten, links, rechts). Die Registerkarte Position ist nur verfügbar, wenn Sie einen anderen Umbruchstil als „Mit Text in Zeile“ auswählen. Hier können Sie abhängig vom gewählten Format des Textumbruchs die folgenden Parameter festlegen: In der Gruppe Horizontal, können Sie eine der folgenden drei AutoFormpositionierungstypen auswählen: Ausrichtung (links, zentriert, rechts) gemessen an Zeichen, Spalte, linker Seitenrand, Seitenrand, Seite oder rechter Seitenrand. Absolute Position, gemessen in absoluten Einheiten wie Zentimeter/Punkte/Zoll (abhängig von der Voreinstellung in Datei -> Erweiterte Einstellungen...), rechts von Zeichen, Spalte, linker Seitenrand, Seitenrand, Seite oder rechter Seitenrand. Relative Position in Prozent, gemessen von linker Seitenrand, Seitenrand, Seite oder rechter Seitenrand. In der Gruppe Vertikal, können Sie eine der folgenden drei AutoFormpositionierungstypen auswählen: Ausrichtung (oben, zentriert, unten) gemessen von Zeile, Seitenrand, unterer Rand, Abschnitt, Seite oder oberer Rand. Absolute Position, gemessen in absoluten Einheiten wie Zentimeter/Punkte/Zoll (abhängig von der Voreinstellung in Datei -> Erweiterte Einstellungen...), unterhalb Zeile, Seitenrand, unterer Seitenrand, Absatz, Seite oder oberer Seitenrand. Relative Position in Prozent, gemessen von Seitenrand, unterer Seitenrand, Seite oder oberer Seitenrand. Im Kontrollkästchen Objekt mit Text verschieben können Sie festlegen, ob sich die AutoForm zusammen mit dem Text bewegen lässt, mit dem sie verankert wurde. Überlappen zulassen bestimmt, ob zwei AutoFormen einander überlagern können oder nicht, wenn Sie diese auf einer Seite dicht aneinander bringen. Die Registerkarte Formeinstellungen enthält die folgenden Parameter: Linienart - in dieser Gruppe können Sie die folgenden Parameter bestimmen: Abschlusstyp - legen Sie den Stil für den Abschluss der Linie fest, diese Option besteht nur bei Formen mit offener Kontur wie Linien, Polylinien usw.: Flach - flacher Abschluss Rund - runder Abschluss Quadratisch - quadratisches Linienende Anschlusstyp - legen Sie die Art der Verknüpfung von zwei Linien fest, z.B. kann diese Option auf Polylinien oder die Ecken von Dreiecken bzw. Vierecken angewendet werden: Rund - abgerundete Ecke Schräge Kante - die Ecke wird schräg abgeschnitten Winkel - spitze Ecke Dieser Typ passt gut bei AutoFormen mit spitzen Winkeln. Hinweis: Der Effekt wird auffälliger, wenn Sie eine hohe Konturbreite verwenden. Pfeile - Gruppe ist verfügbar, wenn eine Form aus der Gruppe Linien ausgewählt wurde. Dadurch können Sie die Form von Startpfeil und Endpfeil festlegen und die jeweilige Größe bestimmen. Wählen Sie dazu einfach die gewünschte Option aus der Liste aus. Über die Registerkarte Textränder können Sie die oberen, unteren, linken und rechten inneren Ränder der AutoForm ändern (also den Abstand zwischen dem Text innerhalb der Form und dem Rahmen der AutoForm). Hinweis: diese Registerkarte ist nur verfügbar, wenn der AutoForm ein Text hinzugefügt wurde, ansonsten wird die Registerkarte ausgeblendet. Die Registerkarte Alternativtext ermöglicht die Eingabe eines Titels und einer Beschreibung die Personen mit Sehbehinderungen oder kognitiven Beeinträchtigungen vorgelesen werden kann damit sie besser verstehen können, welche Informationen in der Form vorhanden sind." }, + { + "id": "UsageInstructions/InsertBookmarks.htm", + "title": "Lesezeichen hinzufügen", + "body": "Lesezeichen ermöglichen den schnellen Wechsel zu einer bestimmten Position im aktuellen Dokument oder das Hinzufügen eines Links an dieser Position im Dokument. Einfügen eines Lesezeichens: Positionieren Sie den Mauszeiger an den Anfang der Textpassage, in die das Lesezeichen eingefügt werden soll. Wechseln Sie in der oberen Symbolleiste auf die Registerkarte Verweise. Klicken Sie in der oberen Symbolleiste auf das Symbol Lesezeichen. Geben Sie im sich öffnenden Fenster Lesezeichen den Namen des Lesezeichens ein und klicken Sie auf die Schaltfläche Hinzufügen - das Lesezeichen wird der unten angezeigten Lesezeichenliste hinzugefügt.Hinweis: Der Name des Lesezeichens sollte mit einem Buchstaben beginnen, er kann jedoch auch Zahlen enthalten. Der Name des Lesezeichens darf keine Leerzeichen enthalten, ein Unterstrich \"_\" ist jedoch möglich. So wechseln Sie zu einem der hinzugefügten Lesezeichen im Dokumenttext: Klicken Sie in der oberen Symbolleiste unter der Registerkarte Verweise auf das Symbol Lesezeichen. Wählen Sie im sich öffnenden Fenster Lesezeichen das Lesezeichen aus, zu dem Sie springen möchten. Um das erforderliche Lesezeichen in der Liste zu finden, können Sie die Liste nach Name oder Position eines Lesezeichens im Dokumenttext sortieren. Aktivieren Sie die Option Versteckte Lesezeichen, um ausgeblendete Lesezeichen in der Liste anzuzeigen (z. B. die vom Programm automatisch erstellten Lesezeichen, wenn Sie Verweise auf einen bestimmten Teil des Dokuments hinzufügen. Wenn Sie beispielsweise einen Hyperlink zu einer bestimmten Überschrift innerhalb des Dokuments erstellen, erzeugt der Dokumenteditor automatisch ein ausgeblendetes Lesezeichen für das Ziel dieses Links). Klicken Sie auf die Schaltfläche Gehe zu - der Cursor wird an der Stelle innerhalb des Dokuments positioniert, an der das ausgewählte Lesezeichen hinzugefügt wurde, klicken Sie auf die Schaltfläche Schließen, um das Dialogfenster zu schließen. Um ein Lesezeichen zu löschen, wählen Sie den entsprechenden Namen aus der Liste der Lesezeichen aus und klicken Sie auf Löschen. Informationen zum Verwenden von Lesezeichen beim Erstellen von Links finden Sie im Abschnitt Hyperlinks hinzufügen." + }, { "id": "UsageInstructions/InsertCharts.htm", "title": "Diagramme einfügen", @@ -168,7 +173,7 @@ var indexes = { "id": "UsageInstructions/InsertContentControls.htm", "title": "Inhaltssteuerelemente einfügen", - "body": "Mithilfe von Inhaltssteuerelementen können Sie ein Formular mit Eingabefeldern erstellen, die von anderen Benutzern ausgefüllt werden können; oder Sie können Teile des Dokuments davor schützen, bearbeitet oder gelöscht zu werden. Inhaltssteuerelemente sind Objekte die Text enthalten, der formatiert werden kann. Inhaltssteuerelemente für einfachen Text können nur einen Absatz enthalten, während Steuerelemente für Rich-Text-Inhalte mehrere Absätze, Listen und Objekte (Bilder, Formen, Tabellen usw.) enthalten können. Inhaltssteuerelemente hinzufügen Neues Inhaltssteuerelement für einfachen Text erstellen: Positionieren Sie den Einfügepunkt innerhalb einer Textzeile, in der das Steuerelement hinzugefügt werden soll oder wählen Sie eine Textpassage aus, die Sie zum Steuerungsinhalt machen wollen. Wechseln Sie in der oberen Symbolleiste auf die Registerkarte Einfügen. Klicken Sie auf den Pfeil neben dem Symbol Inhaltssteuerelemente. Wählen sie die Option Inhaltssteuerelement für einfachen Text einfügen aus dem Menü aus. Das Steuerelement wird an der Einfügemarke innerhalb einer Zeile des vorhandenen Texts eingefügt. Bei Steuerelementen für einfachen Text können keine Zeilenumbrüche hinzugefügt werden und sie dürfen keine anderen Objekte wie Bilder, Tabellen usw. enthalten. Neues Inhaltssteuerelement für Rich-Text erstellen: Positionieren Sie den Einfügemarke am Ende eines Absatzes, nach dem das Steuerelement hinzugefügt werden soll oder wählen Sie einen oder mehrere der vorhandenen Absätze aus, die Sie zum Steuerungsinhalt machen wollen. Wechseln Sie in der oberen Symbolleiste auf die Registerkarte Einfügen. Klicken Sie auf den Pfeil neben dem Symbol Inhaltssteuerelemente. Wählen sie die Option Inhaltssteuerelement für Rich-Text einfügen aus dem Menü aus. Das Steuerungselement wird in einem neuen Paragraphen eingefügt. Rich-Text-Inhaltssteuerelemente ermöglichen das Hinzufügen von Zeilenumbrüchen und Sie können multiple Absätze sowie auch Objekte enthalten, z. B. Bilder, Tabellen, andere Inhaltssteuerelemente usw. Hinweis: Der Rahmen des Textfelds für das Inhaltssteuerelement ist nur sichtbar, wenn das Steuerelement ausgewählt ist. In der gedruckten Version sind die Ränder nicht zu sehen. Inhaltssteuerelemente verschieben Steuerelemente können an eine andere Stelle im Dokument verschoben werden: Klicken Sie auf die Schaltfläche links neben dem Rahmen des Steuerelements, um das Steuerelement auszuwählen und ziehen Sie mit gedrückter Maustaste an die gewünschte Position. Sie können Inhaltssteuerelemente auch kopieren und einfügen: wählen Sie das entsprechende Steuerelement aus und verwenden Sie die Tastenkombinationen STRG+C/STRG+V. Inhaltssteuerelemente bearbeiten Ersetzen Sie den Standardtext im Steuerelement („Text eingeben\") durch Ihren eigenen Text: Wählen Sie den Standardtext aus und geben Sie einen neuen Text ein oder kopieren Sie eine beliebige Textpassage und fügen Sie diese in das Inhaltssteuerelement ein. Der Text im Inhaltssteuerelement eines beliebigen Typs (für einfachen Text und Rich-Text) kann mithilfe der Symbole in der oberen Symbolleiste formatiert werden: Sie können Schriftart, Größe und Farbe anpassen und DekoSchriften und Formatierungsvorgaben anwenden. Es ist auch möglich die Texteigenschaften im Fenster Paragraph - Erweiterte Einstellungen zu ändern, das Ihnen im Kontextmenü oder in der rechten Seitenleiste zur Verfügung steht. Text in Rich-Text-Inhaltssteuerelementen kann wie ein normaler Text im Dokument formatiert werden, so können Sie beispielsweise den Zeilenabstand festlegen, Absatzeinzüge ändern oder Tab-Stopps anpassen. Einstellungen für Inhaltssteuerelemente ändern Die Einstellungen für Inhaltssteuerelemente öffnen Sie wie folgt: Wählen Sie das gewünschte Inhaltssteuerelement aus und klicken Sie auf den Pfeil neben dem Symbol Inhaltssteuerelemente in der oberen Symbolleiste und wählen Sie dann die Option Einstellungen Steuerelemente aus dem Menü aus. Klicken Sie mit der rechten Maustaste auf eine beliebige Stelle im Inhaltssteuerelement und nutzen Sie die Option Einstellungen Steuerungselement im Kontextmenü. Im sich nun öffnenden Fenstern können Sie die folgenden Parameter festlegen: Legen Sie in den entsprechenden Feldern Titel oder Tag des Steuerelements fest. Im Abschnitt Sperren können Sie das Inhaltssteuerelement mit der entsprechenden Option vor dem ungewollten Löschen oder Bearbeiten schützen: Inhaltssteuerelement kann nicht gelöscht werden - Aktivieren Sie dieses Kontrollkästchen, um ein Löschen des Steuerelements zu verhindern. Inhaltssteuerelement kann nicht bearbeitet werden - Aktivieren Sie dieses Kontrollkästchen, um ein Bearbeiten des Steuerelements zu verhindern. Klicken Sie im Fenster Einstellungen auf OK, um die Änderungen zu bestätigen. Inhaltssteuerelemente entfernen Um ein Steuerelement zu entfernen ohne den Inhalt zu löschen, klicken Sie auf das entsprechende Ssteuerelement und gehen Sie vor wie folgt: Klicken Sie auf den Pfeil neben dem Symbol Inhaltssteuerelemente in der oberen Symbolleiste und wählen Sie dann die Option Steuerelement entfernen aus dem Menü aus. Klicken Sie mit der rechten Maustaste auf das Steuerungselement und wählen Sie die Option Steuerungselement entfernen im Kontextmenü aus. Um ein Steuerelement einschließlich Inhalt zu entfernen, wählen Sie das entsprechende Steuerelement aus und drücken Sie die Taste Löschen auf der Tastatur." + "body": "Mithilfe von Inhaltssteuerelementen können Sie ein Formular mit Eingabefeldern erstellen, die von anderen Benutzern ausgefüllt werden können; oder Sie können Teile des Dokuments davor schützen, bearbeitet oder gelöscht zu werden. Inhaltssteuerelemente sind Objekte die Text enthalten, der formatiert werden kann. Inhaltssteuerelemente für einfachen Text können nur einen Absatz enthalten, während Steuerelemente für Rich-Text-Inhalte mehrere Absätze, Listen und Objekte (Bilder, Formen, Tabellen usw.) enthalten können. Inhaltssteuerelemente hinzufügen Neues Inhaltssteuerelement für einfachen Text erstellen: Positionieren Sie den Einfügepunkt innerhalb einer Textzeile, in die das Steuerelement eingefügt werden soll oder wählen Sie eine Textpassage aus, die Sie zum Steuerungsinhalt machen wollen. Wechseln Sie in der oberen Symbolleiste auf die Registerkarte Einfügen. Klicken Sie auf den Pfeil neben dem Symbol Inhaltssteuerelemente. Wählen sie die Option Inhaltssteuerelement für einfachen Text einfügen aus dem Menü aus. Das Steuerelement wird an der Einfügemarke innerhalb einer Zeile des vorhandenen Texts eingefügt. Bei Steuerelementen für einfachen Text können keine Zeilenumbrüche hinzugefügt werden und sie dürfen keine anderen Objekte wie Bilder, Tabellen usw. enthalten. Neues Inhaltssteuerelement für Rich-Text erstellen: Positionieren Sie die Einfügemarke am Ende eines Absatzes, nach dem das Steuerelement hinzugefügt werden soll oder wählen Sie einen oder mehrere der vorhandenen Absätze aus die Sie zum Steuerungsinhalt machen wollen. Wechseln Sie in der oberen Symbolleiste auf die Registerkarte Einfügen. Klicken Sie auf den Pfeil neben dem Symbol Inhaltssteuerelemente. Wählen sie die Option Inhaltssteuerelement für Rich-Text einfügen aus dem Menü aus. Das Steuerungselement wird in einem neuen Paragraphen eingefügt. Rich-Text-Inhaltssteuerelemente ermöglichen das Hinzufügen von Zeilenumbrüchen und Sie können multiple Absätze sowie auch Objekte enthalten, z. B. Bilder, Tabellen, andere Inhaltssteuerelemente usw. Hinweis: Der Rahmen des Textfelds für das Inhaltssteuerelement ist nur sichtbar, wenn das Steuerelement ausgewählt ist. In der gedruckten Version sind die Ränder nicht zu sehen. Inhaltssteuerelemente verschieben Steuerelemente können an eine andere Stelle im Dokument verschoben werden: Klicken Sie auf die Schaltfläche links neben dem Rahmen des Steuerelements, um das Steuerelement auszuwählen, und ziehen Sie es bei gedrückter Maustaste an die gewünschte Position. Sie können Inhaltssteuerelemente auch kopieren und einfügen: wählen Sie das entsprechende Steuerelement aus und verwenden Sie die Tastenkombinationen STRG+C/STRG+V. Inhaltssteuerelemente bearbeiten Ersetzen Sie den Standardtext im Steuerelement („Text eingeben\") durch Ihren eigenen Text: Wählen Sie den Standardtext aus und geben Sie einen neuen Text ein oder kopieren Sie eine beliebige Textpassage und fügen Sie diese in das Inhaltssteuerelement ein. Der Text im Inhaltssteuerelement eines beliebigen Typs (für einfachen Text und Rich-Text) kann mithilfe der Symbole in der oberen Symbolleiste formatiert werden: Sie können Schriftart, -größe und -farbe anpassen und DekoSchriften und Formatierungsvorgaben anwenden. Es ist auch möglich die Texteigenschaften im Fenster Paragraph - Erweiterte Einstellungen zu ändern, das Ihnen im Kontextmenü oder in der rechten Seitenleiste zur Verfügung steht. Text in Rich-Text-Inhaltssteuerelementen kann wie normaler Dokumententext formatiert werden, Sie können beispielsweise den Zeilenabstand festlegen, Absatzeinzüge ändern oder Tab-Stopps anpassen. Einstellungen für Inhaltssteuerelemente ändern Die Einstellungen für Inhaltssteuerelemente öffnen Sie wie folgt: Wählen Sie das gewünschte Inhaltssteuerelement aus und klicken Sie auf den Pfeil neben dem Symbol Inhaltssteuerelemente in der oberen Symbolleiste und wählen Sie dann die Option Einstellungen Steuerelemente aus dem Menü aus. Klicken Sie mit der rechten Maustaste auf eine beliebige Stelle im Inhaltssteuerelement und nutzen Sie die Option Einstellungen Steuerungselement im Kontextmenü. Im sich nun öffnenden Fenstern können Sie die folgenden Parameter festlegen: Legen Sie in den entsprechenden Feldern Titel oder Tag des Steuerelements fest. Der Titel wird angezeigt, wenn das Steuerelement im Dokument ausgewählt wird. Tags werden verwendet, um Inhaltssteuerelemente zu identifizieren, damit Sie im Code darauf verweisen können. Wählen Sie aus, ob Sie Steuerelemente mit einem Begrenzungsrahmen anzeigen möchten oder nicht. Wählen Sie die Option Keine, um das Steuerelement ohne Begrenzungsrahmen anzuzeigen. Wenn Sie die Option Begrenzungsrahmen auswählen, können Sie die Feldfarbe im untenstehenden Feld auswählen. Im Abschnitt Sperren können Sie das Inhaltssteuerelement mit der entsprechenden Option vor ungewolltem Löschen oder Bearbeiten schützen: Inhaltssteuerelement kann nicht gelöscht werden - Aktivieren Sie dieses Kontrollkästchen, um ein Löschen des Steuerelements zu verhindern. Inhaltssteuerelement kann nicht bearbeitet werden - Aktivieren Sie dieses Kontrollkästchen, um ein Bearbeiten des Steuerelements zu verhindern. Klicken Sie im Fenster Einstellungen auf OK, um die Änderungen zu bestätigen. Es ist auch möglich, Inhaltssteuerelemente mit einer bestimmten Farbe hervorzuheben. Inhaltssteuerelemente farblich hervorheben: Klicken Sie auf die Schaltfläche links neben dem Rahmen des Steuerelements, um das Steuerelement auszuwählen. Klicken Sie auf der oberen Symbolleiste auf den Pfeil neben dem Symbol Inhaltssteuerelemente. Wählen Sie die Option Einstellungen hervorheben aus dem Menü aus. Wählen Sie die gewünschte Farbe auf den verfügbaren Paletten aus: Themenfarben, Standardfarben oder neue benutzerdefinierte Farbe angeben. Um zuvor angewendete Farbmarkierungen zu entfernen, verwenden Sie die Option Keine Markierung. Die ausgewählten Hervorhebungsoptionen werden auf alle Inhaltssteuerelemente im Dokument angewendet. Inhaltssteuerelemente entfernen Um ein Steuerelement zu entfernen ohne den Inhalt zu löschen, klicken Sie auf das entsprechende Ssteuerelement und gehen Sie vor wie folgt: Klicken Sie auf den Pfeil neben dem Symbol Inhaltssteuerelemente in der oberen Symbolleiste und wählen Sie dann die Option Steuerelement entfernen aus dem Menü aus. Klicken Sie mit der rechten Maustaste auf das Steuerelement und wählen Sie die Option Steuerungselement entfernen im Kontextmenü aus. Um ein Steuerelement einschließlich Inhalt zu entfernen, wählen Sie das entsprechende Steuerelement aus und drücken Sie die Taste Löschen auf der Tastatur." }, { "id": "UsageInstructions/InsertDropCap.htm", @@ -193,7 +198,7 @@ var indexes = { "id": "UsageInstructions/InsertImages.htm", "title": "Bilder einfügen", - "body": "Im Dokumenteneditor können Sie Bilder in den gängigen Formaten in Ihr Dokument einfügen. Die folgenden Formate werden unterstützt: BMP, GIF, JPEG, JPG, PNG. Ein Bild einfügen Ein Bild in das aktuelle Dokument einfügen: Positionieren Sie den Cursor an der Stelle, an der Sie das Bild einfügen möchten. Wechseln Sie in der oberen Symbolleiste auf die Registerkarte Einfügen. Klicken Sie in der oberen Symbolleiste auf Bild. Wählen Sie eine der folgenden Optionen um das Bild hochzuladen: Mit der Option Bild aus Datei öffnen Sie das Windows-Standarddialogfenster zur Dateiauswahl. Durchsuchen Sie die Festplatte Ihres Computers nach der gewünschten Bilddatei und klicken Sie auf Öffnen. Mit der Option Bild aus URL öffnen Sie das Fenster zum Eingeben der erforderlichen Webadresse, wenn Sie die Adresse eingegeben haben, klicken Sie auf OK. Wenn Sie das Bild hinzugefügt haben, können Sie Größe, Eigenschaften und Position ändern. Bilder bewegen und die Größe ändern Um die Bildgröße zu ändern, ziehen Sie die kleine Quadrate an den Rändern. Um das Originalseitenverhältnis des gewählten Bildes bei der Größenänderung beizubehalten, halten Sie die UMSCHALT-Taste gedrückt und ziehen Sie an einem der Ecksymbole. Verwenden Sie zum Ändern der Bildposition das Symbol , das angezeigt wird, wenn Sie den Mauszeiger über das Bild bewegen. Ziehen Sie das Bild an die gewünschte Position, ohne die Maustaste loszulassen. Wenn Sie die das Bild verschieben, werden Hilfslinien angezeigt, damit Sie das Objekt präzise auf der Seite positionieren können (wenn Sie einen anderen Umbruchstil als mit Text in Zeile ausgewählt haben). Um das Bild zu drehen, bewegen Sie den Mauszeiger über den Drehpunkt und ziehen Sie das Bild im oder gegen den Uhrzeigersinn. Um ein Objekt in 15-Grad-Stufen zu drehen, halten Sie die UMSCHALT-Taste bei der Drehung gedrückt. Bildeinstellungen anpassen Einige der Bildeinstellungen können mithilfe der Registerkarte Bildeinstellungen auf der rechten Seitenleiste geändert werden. Um diese zu aktivieren, klicken Sie auf das Bild und wählen Sie rechts das Symbol Bildeinstellungen aus. Hier können die folgenden Eigenschaften geändert werden: Größe - wird genutzt, um Breite und Höhe des aktuellen Bildes einzusehen. Bei Bedarf können Sie die Standardbildgröße wiederherstellen, indem Sie auf die Schaltfläche Standardgröße klicken. An Seitenränder anpassen - ändern Sie die Bildgröße und passen Sie das Bild an den linken und rechten Seitenrand an. Textumbruch - der Stil für den Textumbruch wird aus den verfügbaren Vorlagen ausgewählt: Mit Text in Zeile, Quadrat, Eng, Transparent, Oben und unten, Vorne, Hinten (für weitere Information lesen Sie die folgende Beschreibung der erweiterten Einstellungen). Bild ersetzen - um das aktuelle Bild durch ein anderes Bild aus Datei oder Onlinebilder zu ersetzen. Einige dieser Optionen finden Sie auch im Rechtsklickmenü. Die Menüoptionen sind: Ausschneiden, Kopieren, Einfügen - Standardoptionen zum Ausschneiden oder Kopieren ausgewählter Textpassagen/Objekte und zum Einfügen von zuvor ausgeschnittenen/kopierten Textstellen oder Objekten an der aktuellen Cursorposition. Anordnen - um das ausgewählte Bild in den Vordergrund bzw. Hintergrund oder eine Ebene nach vorne bzw. hinten zu verschieben sowie Bilder zu gruppieren und die Gruppierung aufzuheben (um diese wie ein einzelnes Objekt behandeln zu können). Weitere Informationen zum Anordnen von Objekten finden Sie auf dieser Seite. Ausrichten wird verwendet, um das Bild linksbündig, zentriert, rechtsbündig, oben, mittig oder unten auszurichten. Weitere Informationen zum Ausrichten von Objekten finden Sie auf dieser Seite. Textumbruch - der Stil für den Textumbruch wird aus den verfügbaren Vorlagen ausgewählt: Mit Text in Zeile, Quadrat, Eng, Transparent, Oben und unten, Vorne, Hinten (für weitere Information lesen Sie die folgende Beschreibung der erweiterten Einstellungen). Die Option Umbruchgrenze bearbeiten ist nur verfügbar, wenn Sie einen anderen Umbruchstil als „Mit Text in Zeile“ auswählen. Ziehen Sie die Umbruchpunkte, um die Grenze benutzerdefiniert anzupassen. Um einen neuen Rahmenpunkt zu erstellen, klicken Sie auf eine beliebige Stelle auf der roten Linie und ziehen Sie diese an die gewünschte Position. Standardgröße - die aktuelle Bildgröße auf die Standardgröße ändern. Erweiterte Einstellungen - das Fenster „Bild - Erweiterte Einstellungen“ öffnen. Ist das Bild ausgewählt, ist rechts auch das Symbol Formeinstellungen verfügbar. Klicken Sie auf dieses Symbol, um die Registerkarte Formeinstellungen in der rechten Seitenleiste zu öffnen und passen Sie Form Linientyp, Größe und Farbe an oder ändern Sie die Form und wählen Sie im Menü AutoForm ändern eine neue Form aus. Entsprechend ändern sich die Form des Bildes. Um die erweiterte Einstellungen des Bildes zu ändern, klicken Sie mit der rechten Maustaste auf das Bild und wählen Sie die Option Bild - Erweiterte Einstellungen im Rechtsklickmenü oder klicken Sie einfach in der rechten Seitenleiste auf Erweiterte Einstellungen anzeigen. Das Fenster mit den Bildeigenschaften wird geöffnet: Die Registerkarte Größe enthält die folgenden Parameter: Breite und Höhe - mit diesen Optionen können Sie die Breite bzw. Höhe des Bildes ändern. Wenn Sie die Funktion Seitenverhältnis sperren aktivieren (in diesem Fall sieht das Symbol so aus ), werden Breite und Höhe gleichmäßig geändert und das ursprüngliche Bildseitenverhältnis wird beibehalten. Um die Standardgröße des hinzugefügten Bildes wiederherzustellen, klicken Sie auf Standardgröße. Die Registerkarte Textumbruch enthält die folgenden Parameter: Textumbruch - legen Sie fest, wie das Bild im Verhältnis zum Text positioniert wird: entweder als Teil des Textes (wenn Sie die Option „Mit Text in Zeile“ auswählen) oder an allen Seiten von Text umgeben (wenn Sie einen anderen Stil auswählen). Mit Text verschieben - das Bild wird Teil des Textes (wie ein Zeichen) und wenn der Text verschoben wird, wird auch das Bild verschoben. In diesem Fall sind die Positionsoptionen nicht verfügbar. Ist eine der folgenden Umbrucharten ausgewählt, kann das Bild unabhängig vom Text verschoben und auf der Seite positioniert werden: Quadrat - der Text bricht um den rechteckigen Kasten herum, der das Bild begrenzt. Eng - der Text bricht um die Bildkanten herum. Transparent - der Text bricht um die Bildkanten herum und füllt den offenen weißen Leerraum innerhalb des Bildes. Wählen Sie für diesen Effekt die Option Umbruchsgrenze bearbeiten aus dem Rechtsklickmenü aus. Oben und unten - der Text ist nur oberhalb und unterhalb des Bildes. Vorne - das Bild überlappt mit dem Text. Hinten - der Text überlappt sich mit dem Bild. Wenn Sie die Formate Quadrat, Eng, Transparent oder Oben und unten auswählen, haben Sie die Möglichkeit zusätzliche Parameter festzulegen - Abstand vom Text auf allen Seiten (oben, unten, links, rechts). Die Registerkarte Position ist nur verfügbar, wenn Sie einen anderen Umbruchstil als „Mit Text in Zeile“ auswählen. Hier können Sie abhängig vom gewählten Format des Textumbruchs die folgenden Parameter festlegen: In der Gruppe Horizontal, können Sie eine der folgenden drei Bildpositionierungstypen auswählen: Ausrichtung (links, zentriert, rechts) gemessen an Zeichen, Spalte, linker Seitenrand, Seitenrand, Seite oder rechter Seitenrand. Absolute Position, gemessen in absoluten Einheiten wie Zentimeter/Punkte/Zoll (abhängig von der Voreinstellung in Datei -> Erweiterte Einstellungen...), rechts von Zeichen, Spalte, linker Seitenrand, Seitenrand, Seite oder rechter Seitenrand. Relative Position in Prozent, gemessen von linker Seitenrand, Seitenrand, Seite oder rechter Seitenrand. In der Gruppe Vertikal, können Sie eine der folgenden drei Bildpositionierungstypen auswählen: Ausrichtung (oben, zentriert, unten) gemessen von Zeile, Seitenrand, unterer Rand, Abschnitt, Seite oder oberer Rand. Absolute Position, gemessen in absoluten Einheiten wie Zentimeter/Punkte/Zoll (abhängig von der Voreinstellung in Datei -> Erweiterte Einstellungen...), unterhalb Zeile, Seitenrand, unterer Seitenrand, Absatz, Seite oder oberer Seitenrand. Relative Position in Prozent, gemessen von Seitenrand, unterer Seitenrand, Seite oder oberer Seitenrand. Im Kontrollkästchen Objekt mit Text verschieben können Sie festlegen, ob sich das Bild zusammen mit dem Text bewegen lässt, mit dem es verankert wurde. Überlappen zulassen legt fest, ob zwei Bilder einander überlagern können oder nicht, wenn Sie diese auf einer Seite dicht aneinander bringen. Die Registerkarte Alternativtext ermöglicht die Eingabe eines Titels und einer Beschreibung, die Personen mit Sehbehinderungen oder kognitiven Beeinträchtigungen vorgelesen werden kann, damit sie besser verstehen können, welche Informationen im Bild enthalten sind." + "body": "Im Dokumenteneditor können Sie Bilder in den gängigen Formaten in Ihr Dokument einfügen. Die folgenden Formate werden unterstützt: BMP, GIF, JPEG, JPG, PNG. Ein Bild einfügen Ein Bild in das aktuelle Dokument einfügen: Positionieren Sie den Cursor an der Stelle, an der Sie das Bild einfügen möchten. Wechseln Sie in der oberen Symbolleiste auf die Registerkarte Einfügen. Klicken Sie auf das Symbol Bild in der oberen Symbolleiste. Wählen Sie eine der folgenden Optionen um das Bild hochzuladen: Mit der Option Bild aus Datei öffnen Sie das Standarddialogfenster zur Dateiauswahl. Durchsuchen Sie die Festplatte Ihres Computers nach der gewünschten Bilddatei und klicken Sie auf Öffnen. Mit der Option Bild aus URL öffnen Sie das Fenster zum Eingeben der erforderlichen Webadresse, wenn Sie die Adresse eingegeben haben, klicken Sie auf OK. Wenn Sie das Bild hinzugefügt haben, können Sie Größe, Eigenschaften und Position ändern. Bilder bewegen und die Größe ändern Um die Bildgröße zu ändern, ziehen Sie die kleine Quadrate an den Rändern. Um das Originalseitenverhältnis des gewählten Bildes bei der Größenänderung beizubehalten, halten Sie die UMSCHALT-Taste gedrückt und ziehen Sie an einem der Ecksymbole. Verwenden Sie zum Ändern der Bildposition das Symbol , das angezeigt wird, wenn Sie den Mauszeiger über das Bild bewegen. Ziehen Sie das Bild an die gewünschte Position, ohne die Maustaste loszulassen. Wenn Sie die das Bild verschieben, werden Hilfslinien angezeigt, damit Sie das Objekt präzise auf der Seite positionieren können (wenn Sie einen anderen Umbruchstil als mit Text in Zeile ausgewählt haben). Um das Bild zu drehen, bewegen Sie den Mauszeiger über den Drehpunkt und ziehen Sie das Bild im oder gegen den Uhrzeigersinn. Um ein Objekt in 15-Grad-Stufen zu drehen, halten Sie die UMSCHALT-Taste bei der Drehung gedrückt. Hinweis: Hier finden Sie eine Übersicht über die gängigen Tastenkombinationen für die Arbeit mit Objekten. Bildeinstellungen anpassen Einige der Bildeinstellungen können mithilfe der Registerkarte Bildeinstellungen auf der rechten Seitenleiste geändert werden. Um diese zu aktivieren, klicken Sie auf das Bild und wählen Sie rechts das Symbol Bildeinstellungen aus. Hier können die folgenden Eigenschaften geändert werden: Größe - wird genutzt, um Breite und Höhe des aktuellen Bildes einzusehen. Bei Bedarf können Sie die Standardbildgröße wiederherstellen, indem Sie auf die Schaltfläche Standardgröße klicken. An Seitenränder anpassen - ändern Sie die Bildgröße und passen Sie das Bild an den linken und rechten Seitenrand an. Textumbruch - der Stil für den Textumbruch wird aus den verfügbaren Vorlagen ausgewählt: Mit Text in Zeile, Quadrat, Eng, Transparent, Oben und unten, Vorne, Hinten (für weitere Information lesen Sie die folgende Beschreibung der erweiterten Einstellungen). Bild ersetzen - um das aktuelle Bild durch ein anderes Bild aus Datei oder Onlinebilder zu ersetzen. Einige dieser Optionen finden Sie auch im Rechtsklickmenü. Die Menüoptionen sind: Ausschneiden, Kopieren, Einfügen - Standardoptionen zum Ausschneiden oder Kopieren ausgewählter Textpassagen/Objekte und zum Einfügen von zuvor ausgeschnittenen/kopierten Textstellen oder Objekten an der aktuellen Cursorposition. Anordnen - um das ausgewählte Bild in den Vordergrund bzw. Hintergrund oder eine Ebene nach vorne bzw. hinten zu verschieben sowie Bilder zu gruppieren und die Gruppierung aufzuheben (um diese wie ein einzelnes Objekt behandeln zu können). Weitere Informationen zum Anordnen von Objekten finden Sie auf dieser Seite. Ausrichten wird verwendet, um das Bild linksbündig, zentriert, rechtsbündig, oben, mittig oder unten auszurichten. Weitere Informationen zum Ausrichten von Objekten finden Sie auf dieser Seite. Textumbruch - der Stil für den Textumbruch wird aus den verfügbaren Vorlagen ausgewählt: Mit Text in Zeile, Quadrat, Eng, Transparent, Oben und unten, Vorne, Hinten (für weitere Information lesen Sie die folgende Beschreibung der erweiterten Einstellungen). Die Option Umbruchgrenze bearbeiten ist nur verfügbar, wenn Sie einen anderen Umbruchstil als „Mit Text in Zeile“ auswählen. Ziehen Sie die Umbruchpunkte, um die Grenze benutzerdefiniert anzupassen. Um einen neuen Rahmenpunkt zu erstellen, klicken Sie auf eine beliebige Stelle auf der roten Linie und ziehen Sie diese an die gewünschte Position. Standardgröße - die aktuelle Bildgröße auf die Standardgröße ändern. Bild ersetzen - um das aktuelle Bild durch ein anderes Bild aus Datei oder Onlinebilder zu ersetzen. Erweiterte Einstellungen - das Fenster „Bild - Erweiterte Einstellungen“ öffnen. Ist das Bild ausgewählt, ist rechts auch das Symbol Formeinstellungen verfügbar. Klicken Sie auf dieses Symbol, um die Registerkarte Formeinstellungen in der rechten Seitenleiste zu öffnen und passen Sie Form, Linientyp, Größe und Farbe an oder ändern Sie die Form und wählen Sie im Menü AutoForm ändern eine neue Form aus. Die Form des Bildes ändert sich entsprechend Ihrer Auswahl. Um die erweiterte Einstellungen des Bildes zu ändern, klicken Sie mit der rechten Maustaste auf das Bild und wählen Sie die Option Bild - Erweiterte Einstellungen im Rechtsklickmenü oder klicken Sie einfach in der rechten Seitenleiste auf Erweiterte Einstellungen anzeigen. Das Fenster mit den Bildeigenschaften wird geöffnet: Die Registerkarte Größe enthält die folgenden Parameter: Breite und Höhe - mit diesen Optionen können Sie die Breite bzw. Höhe des Bildes ändern. Wenn Sie die Funktion Seitenverhältnis sperren aktivieren (in diesem Fall sieht das Symbol so aus ), werden Breite und Höhe gleichmäßig geändert und das ursprüngliche Bildseitenverhältnis wird beibehalten. Um die Standardgröße des hinzugefügten Bildes wiederherzustellen, klicken Sie auf Standardgröße. Die Registerkarte Textumbruch enthält die folgenden Parameter: Textumbruch - legen Sie fest, wie das Bild im Verhältnis zum Text positioniert wird: entweder als Teil des Textes (wenn Sie die Option „Mit Text in Zeile“ auswählen) oder an allen Seiten von Text umgeben (wenn Sie einen anderen Stil auswählen). Mit Text verschieben - das Bild wird Teil des Textes (wie ein Zeichen) und wenn der Text verschoben wird, wird auch das Bild verschoben. In diesem Fall sind die Positionsoptionen nicht verfügbar. Ist eine der folgenden Umbrucharten ausgewählt, kann das Bild unabhängig vom Text verschoben und auf der Seite positioniert werden: Quadrat - der Text bricht um den rechteckigen Kasten herum, der das Bild begrenzt. Eng - der Text bricht um die Bildkanten herum. Transparent - der Text bricht um die Bildkanten herum und füllt den offenen weißen Leerraum innerhalb des Bildes. Wählen Sie für diesen Effekt die Option Umbruchsgrenze bearbeiten aus dem Rechtsklickmenü aus. Oben und unten - der Text ist nur oberhalb und unterhalb des Bildes. Vorne - das Bild überlappt mit dem Text. Hinten - der Text überlappt sich mit dem Bild. Wenn Sie die Formate Quadrat, Eng, Transparent oder Oben und unten auswählen, haben Sie die Möglichkeit zusätzliche Parameter festzulegen - Abstand vom Text auf allen Seiten (oben, unten, links, rechts). Die Registerkarte Position ist nur verfügbar, wenn Sie einen anderen Umbruchstil als „Mit Text in Zeile“ auswählen. Hier können Sie abhängig vom gewählten Format des Textumbruchs die folgenden Parameter festlegen: In der Gruppe Horizontal, können Sie eine der folgenden drei Bildpositionierungstypen auswählen: Ausrichtung (links, zentriert, rechts) gemessen an Zeichen, Spalte, linker Seitenrand, Seitenrand, Seite oder rechter Seitenrand. Absolute Position, gemessen in absoluten Einheiten wie Zentimeter/Punkte/Zoll (abhängig von der Voreinstellung in Datei -> Erweiterte Einstellungen...), rechts von Zeichen, Spalte, linker Seitenrand, Seitenrand, Seite oder rechter Seitenrand. Relative Position in Prozent, gemessen von linker Seitenrand, Seitenrand, Seite oder rechter Seitenrand. In der Gruppe Vertikal, können Sie eine der folgenden drei Bildpositionierungstypen auswählen: Ausrichtung (oben, zentriert, unten) gemessen von Zeile, Seitenrand, unterer Rand, Abschnitt, Seite oder oberer Rand. Absolute Position, gemessen in absoluten Einheiten wie Zentimeter/Punkte/Zoll (abhängig von der Voreinstellung in Datei -> Erweiterte Einstellungen...), unterhalb Zeile, Seitenrand, unterer Seitenrand, Absatz, Seite oder oberer Seitenrand. Relative Position in Prozent, gemessen von Seitenrand, unterer Seitenrand, Seite oder oberer Seitenrand. Im Kontrollkästchen Objekt mit Text verschieben können Sie festlegen, ob sich das Bild zusammen mit dem Text bewegen lässt, mit dem es verankert wurde. Überlappen zulassen legt fest, ob zwei Bilder einander überlagern können oder nicht, wenn Sie diese auf einer Seite dicht aneinander bringen. Die Registerkarte Alternativtext ermöglicht die Eingabe eines Titels und einer Beschreibung, die Personen mit Sehbehinderungen oder kognitiven Beeinträchtigungen vorgelesen werden kann, damit sie besser verstehen können, welche Informationen im Bild enthalten sind." }, { "id": "UsageInstructions/InsertPageNumbers.htm", @@ -248,7 +253,7 @@ var indexes = { "id": "UsageInstructions/SetPageParameters.htm", "title": "Seitenparameter festlegen", - "body": "Um das Seitenlayout zu ändern, d. H. Seitenausrichtung und Seitengröße festzulegen, die Ränder anzupassen und Spalten einzufügen, verwenden Sie die entsprechenden Symbole auf der Registerkarte Layout der oberen Symbolleiste. Hinweis: alle festgelegten Parameter werden auf das gesamte Dokument angewendet. Wie Sie für einzelnen Teile Ihres Dokuments unterschiedliche Seitenränder, Ausrichtungen, Größen oder Spaltenanzahlen festlegen, lesen Sie bitte auf dieser Seite nach. Seitenausrichtung Die aktuelle Seitenausrichtung ändern Sie mit einem Klick auf das Symbol Seitenausrichtung. Die Standardeinstellung ist Hochformat. Diese kann jedoch auf Querformat gewechselt werden. Seitengröße Das A4-Standardformat ändern Sie, indem Sie das Symbol Größe anklicken und das gewünschte Format in der Liste wählen. Die verfügbaren Formate sind: US Letter (21,59 cm x 27,94 cm) US Legal (21,59 cm x 35,56 cm) A4 (21 cm x 29,7 cm) A5 (14,81 cm x 20,99 cm) B5 (17,6 cm x 25,01 cm) Briefumschlag #10 (10,48 cm x 24,13 cm) Umschlag DL (11,01 cm x 22,01 cm) Tabloid (27,94 cm x 43,17 cm) AЗ (29,7 cm x 42,01 cm) Tabloid Übergröße (30,48 cm x 45,71 cm) ROC 16K (19,68 cm x 27,3 cm) Envelope Choukei 3 (11,99 cm x 23,49 cm) Super B/A3 (33,02 cm x 48,25 cm) Sie können die Seitengröße auch individuell festlegen, wählen Sie dazu die Option Benutzerdefinierte Seitengröße aus der Liste aus. Das Fenster Seitengröße öffnet sich und Sie können die gewünschten Werte für Breite und Höhe festlegen. Geben Sie Ihre gewünschten Werte in die Eingabefelder ein oder passen Sie die vorhandenen Werte über die Pfeile an. Wenn Sie fertig sind, klicken Sie auf OK, um die Änderungen anzuwenden. Seitenränder Ändern Sie die Standardränder, also den Abstand zwischen den linken, rechten, oberen und unteren Seitenkanten und dem Absatztext, klicken Sie dazu auf das Symbol Ränder wählen Sie eine der verfügbaren Voreinstellungen aus: Normal, US Normal, Schmal, Mittel, Breit. Sie können auch die Option Benutzerdefinierte Ränder verwenden, um Ihre eigenen Werte im geöffneten Fenster Ränder einzugeben. Geben Sie Ihre gewünschten Werte für die Oberen, Unteren, Linken und Rechten Seitenränder in die Eingabefelder ein oder passen Sie die vorhandenen Werte über die Pfeile an. Wenn Sie fertig sind, klicken Sie auf OK. Die benutzerdefinierten Ränder werden auf das aktuelle Dokument angewendet und die Letzte Benutzerdefinierte mit den angegebenen Parametern wird in der Liste mit verfügbaren Rändern angezeigt, damit Sie Ihre Einstellungen auch auf andere Dokumente anwenden können. Sie können die Seitenränder auch manuell ändern, indem Sie die Ränder zwischen den grauen und weißen Bereichen der Lineale verschieben (die grauen Bereiche der Lineale weisen auf Seitenränder hin): Spalten Sie können Ihren Text in zwei oder mehr Spalten aufteilen, klicken Sie dazu auf das Symbol Spalten und wählen Sie die gewünschte Spaltenzahl aus der Liste aus. Folgende Optionen sind verfügbar: Zwei - Zwei Spalten mit der gleichen Breite. Drei - Drei Spalten mit der gleichen Breite. Links - zwei Spalten: eine schmale auf der linken Seite und eine breite auf der rechten. Rechts - zwei Spalten: eine schmale auf der rechten Seite und eine breite auf der linken. Wenn Sie die Spalteneinstellungen anpassen wollen, wählen Sie die Option Benutzerdefinierte Spalten aus der Liste aus. Das Fenster Spalten öffnet sich und Sie können die gewünschte Spaltenanzahl und den Abstand zwischen Spalten festlegen (es ist möglich, bis zu 12 Spalten einzufügen). Geben Sie Ihre gewünschten Werte in die Eingabefelder ein oder passen Sie die vorhandenen Werte über die Pfeile an. Aktivieren Sie das Kontrollkästchen Spaltentrennung, um eine vertikale Linie zwischen den Spalten einzufügen. Wenn Sie fertig sind, klicken Sie auf OK, um die Änderungen anzuwenden. Wenn Sie genau festlegen wollen, wo eine neue spalte beginnt, positionieren Sie den Cursor vor dem Text, den Sie in eine neue Spalte verschieben wollen, klicken Sie in der oberen Symbolleiste auf das Symbol Umbrüche und wählen Sie die Option Spaltenumbruch einfügen. Der Text wird in die nächste Spalte verschoben. Spaltenumbrüche werden in Ihrem Dokument durch eine gepunktete Linie angezeigt: . Wenn die eingefügten Spaltenumbrüche nicht angezeigt werden, klicken Sie in der Registerkarte Start auf das Symbol. Um einen Spaltenumbruch zu entfernen, wählen Sie diesen mit der Maus aus und drücken Sie die Taste ENTF. Um die Spaltenbreite und den Abstand manuell zu ändern, können Sie das horizontale Lineal verwenden. Um Spalten zu entfernen und zu einem normalen einspaltigen Layout zurückzukehren, klicken Sie in der oberen Symbolleiste auf das Symbol Spalten und wählen Sie die Option Eine aus der angezeigten Liste aus." + "body": "Um das Seitenlayout zu ändern, d. H. Seitenausrichtung und Seitengröße festzulegen, die Ränder anzupassen und Spalten einzufügen, verwenden Sie die entsprechenden Symbole auf der Registerkarte Layout der oberen Symbolleiste. Hinweis: alle festgelegten Parameter werden auf das gesamte Dokument angewendet. Wie Sie für einzelnen Teile Ihres Dokuments unterschiedliche Seitenränder, Ausrichtungen, Größen oder Spaltenanzahlen festlegen, lesen Sie bitte auf dieser Seite nach. Seitenausrichtung Die aktuelle Seitenausrichtung ändern Sie mit einem Klick auf das Symbol Seitenausrichtung. Die Standardeinstellung ist Hochformat. Diese kann jedoch auf Querformat gewechselt werden. Seitengröße Das A4-Standardformat ändern Sie, indem Sie das Symbol Größe anklicken und das gewünschte Format aus der Liste auswählen. Die verfügbaren Formate sind: US Letter (21,59 cm x 27,94 cm) US Legal (21,59 cm x 35,56 cm) A4 (21 cm x 29,7 cm) A5 (14,81cm x 20,99cm) B5 (17,6cm x 25,01cm) Umschlag #10 (10,48 cm x 24,13 cm) Umschlag DL (11,01 cm x 22,01 cm) Tabloid (27,94 cm x 43,17 cm) AЗ (29,7 cm x 42,01 cm) Tabloid Übergröße (30,48 cm x 45,71 cm) ROC 16K (19,68 cm x 27,3 cm) Umschlag Choukei 3 (11,99 cm x 23,49 cm) Super B/A3 (33,02 cm x 48,25 cm) Sie können die Seitengröße auch individuell festlegen, wählen Sie dazu die Option Benutzerdefinierte Seitengröße aus der Liste aus. Das Fenster Seitengröße öffnet sich und Sie können die gewünschte Voreinstellung auswählen (US Letter, US Legal, A4, A5, B5, Umschlag #10, Umschlag DL, Tabloid, A3, Tabloid Übergröße, ROC 16K, Umschlag Choukei 3, Super B/A3, A0, A1, A2, A6) oder benutzerdefinierte Werte für Breite und Höhe festlegen. Geben Sie Ihre gewünschten Werte in die Eingabefelder ein oder passen Sie die vorhandenen Werte über die Pfeile an. Wenn Sie fertig sind, klicken Sie auf OK, um die Änderungen anzuwenden. Seitenränder Ändern Sie die Standardränder, also den Abstand zwischen den linken, rechten, oberen und unteren Seitenkanten und dem Absatztext, klicken Sie dazu auf das Symbol Ränder und wählen Sie eine der verfügbaren Voreinstellungen aus: Normal, US Normal, Schmal, Mittel, Breit. Sie können auch die Option Benutzerdefinierte Seitenränder verwenden, um Ihre eigenen Werte im geöffneten Fenster Ränder einzugeben. Geben Sie Ihre gewünschten Werte für die Oberen, Unteren, Linken und Rechten Seitenränder in die Eingabefelder ein oder passen Sie die vorhandenen Werte über die Pfeile an. Wenn Sie fertig sind, klicken Sie auf OK. Die benutzerdefinierten Ränder werden auf das aktuelle Dokument angewendet. In der Liste Ränder wird die Option letzte benutzerdefinierte Einstellung mit den entsprechenden Parametern angezeigt, so dass Sie diese auf alle gewünschten anderen Dokumente anwenden können. Sie können die Seitenränder auch manuell ändern, indem Sie die Ränder zwischen den grauen und weißen Bereichen der Lineale verschieben (die grauen Bereiche der Lineale weisen auf Seitenränder hin): Spalten Sie können Ihren Text in zwei oder mehr Spalten aufteilen, klicken Sie dazu auf das Symbol Spalten und wählen Sie die gewünschte Spaltenzahl aus der Liste aus. Folgende Optionen stehen zur Verfügung: Zwei - Zwei Spalten mit der gleichen Breite hinzufügen. Drei - Drei Spalten mit der gleichen Breite hinzufügen. Links - zwei Spalten hinzufügen: eine schmale auf der linken Seite und eine breite auf der rechten. Rechts - zwei Spalten hinzufügen: eine schmale auf der rechten Seite und eine breite auf der linken. Wenn Sie die Spalteneinstellungen anpassen wollen, wählen Sie die Option Benutzerdefinierte Spalten aus der Liste aus. Das Fenster Spalten öffnet sich und Sie können die gewünschte Spaltenanzahl und den Abstand zwischen den Spalten festlegen (es ist möglich bis zu 12 Spalten einzufügen). Geben Sie Ihre gewünschten Werte in die Eingabefelder ein oder passen Sie die vorhandenen Werte über die Pfeile an. Aktivieren Sie das Kontrollkästchen Spaltentrennung, um eine vertikale Linie zwischen den Spalten einzufügen. Wenn Sie fertig sind, klicken Sie auf OK, um die Änderungen anzuwenden. Wenn Sie genau festlegen wollen, wo eine neue Spalte beginnt, positionieren Sie den Cursor vor dem Text, den Sie in eine neue Spalte verschieben wollen, klicken Sie in der oberen Symbolleiste auf das Symbol Umbrüche und wählen Sie die Option Spaltenumbruch einfügen. Der Text wird in die nächste Spalte verschoben. Spaltenumbrüche werden in Ihrem Dokument durch eine gepunktete Linie angezeigt: . Wenn die eingefügten Spaltenumbrüche nicht angezeigt werden, klicken Sie in der Registerkarte Start auf das Symbol. Um einen Spaltenumbruch zu entfernen, wählen Sie diesen mit der Maus aus und drücken Sie die Taste ENTF. Um die Spaltenbreite und den Abstand manuell zu ändern, können Sie das horizontale Lineal verwenden. Um Spalten zu entfernen und zu einem normalen einspaltigen Layout zurückzukehren, klicken Sie in der oberen Symbolleiste auf das Symbol Spalten und wählen Sie die Option Eine aus der angezeigten Liste aus." }, { "id": "UsageInstructions/SetTabStops.htm", diff --git a/apps/documenteditor/main/resources/help/de/search/search.html b/apps/documenteditor/main/resources/help/de/search/search.html index b5c8869af..80906ec81 100644 --- a/apps/documenteditor/main/resources/help/de/search/search.html +++ b/apps/documenteditor/main/resources/help/de/search/search.html @@ -5,6 +5,7 @@ + @@ -90,7 +91,8 @@ info.title.slice(position[0], position[0] + position[1]), "", info.title.slice(position[0] + position[1]) - ].join('') + ].join(''), + onclick: "onhyperlinkclick(this)" }) ) .append($('

    ').text(info.body.substring(0, 250) + "...")) @@ -124,7 +126,7 @@ } if (commonLength > 450 && sentenceCount > 2) { - displayBody = displayBody.substring(0, 450) + "..." + displayBody = displayBody.substring(0, 450) + "..."; return false; } }); @@ -134,7 +136,8 @@ .append( $('', { href: "../" + result.ref, - html: info.title.substring(0, 150) + html: info.title.substring(0, 150), + onclick: "onhyperlinkclick(this)" }) ) .append( diff --git a/apps/documenteditor/main/resources/help/en/Contents.json b/apps/documenteditor/main/resources/help/en/Contents.json index 45f80b50a..4695a3980 100644 --- a/apps/documenteditor/main/resources/help/en/Contents.json +++ b/apps/documenteditor/main/resources/help/en/Contents.json @@ -7,15 +7,16 @@ {"src": "ProgramInterface/ReferencesTab.htm", "name": "References tab"}, {"src": "ProgramInterface/ReviewTab.htm", "name": "Collaboration tab"}, {"src": "ProgramInterface/PluginsTab.htm", "name": "Plugins tab"}, - {"src": "UsageInstructions/ChangeColorScheme.htm", "name": "Change color scheme", "headername": "Basic operations"}, + {"src": "UsageInstructions/OpenCreateNew.htm", "name": "Create a new document or open an existing one", "headername": "Basic operations"}, {"src": "UsageInstructions/CopyPasteUndoRedo.htm", "name": "Copy/paste text passages, undo/redo your actions"}, - {"src": "UsageInstructions/OpenCreateNew.htm", "name": "Create a new document or open an existing one"}, + {"src": "UsageInstructions/ChangeColorScheme.htm", "name": "Change color scheme"}, {"src": "UsageInstructions/SetPageParameters.htm", "name": "Set page parameters", "headername": "Page formatting"}, {"src": "UsageInstructions/NonprintingCharacters.htm", "name": "Show/hide nonprinting characters" }, {"src": "UsageInstructions/SectionBreaks.htm", "name": "Insert section breaks" }, {"src": "UsageInstructions/InsertHeadersFooters.htm", "name": "Insert headers and footers"}, {"src": "UsageInstructions/InsertPageNumbers.htm", "name": "Insert page numbers"}, - {"src": "UsageInstructions/InsertFootnotes.htm", "name": "Insert footnotes"}, + { "src": "UsageInstructions/InsertFootnotes.htm", "name": "Insert footnotes" }, + {"src": "UsageInstructions/InsertBookmarks.htm", "name": "Add bookmarks"}, {"src": "UsageInstructions/AlignText.htm", "name": "Align your text in a paragraph", "headername": "Paragraph formatting"}, {"src": "UsageInstructions/BackgroundColor.htm", "name": "Select background color for a paragraph"}, {"src": "UsageInstructions/ParagraphIndents.htm", "name": "Change paragraph indents"}, @@ -30,7 +31,8 @@ {"src": "UsageInstructions/CopyClearFormatting.htm", "name": "Copy/clear text formatting" }, {"src": "UsageInstructions/AddHyperlinks.htm", "name": "Add hyperlinks"}, {"src": "UsageInstructions/InsertDropCap.htm", "name": "Insert a drop cap"}, - {"src": "UsageInstructions/InsertTables.htm", "name": "Insert tables", "headername": "Operations on objects"}, + { "src": "UsageInstructions/InsertTables.htm", "name": "Insert tables", "headername": "Operations on objects" }, + {"src": "UsageInstructions/AddFormulasInTables.htm", "name": "Use formulas in tables"}, {"src": "UsageInstructions/InsertImages.htm", "name": "Insert images"}, {"src": "UsageInstructions/InsertAutoshapes.htm", "name": "Insert autoshapes"}, {"src": "UsageInstructions/InsertCharts.htm", "name": "Insert charts" }, @@ -40,7 +42,7 @@ {"src": "UsageInstructions/AlignArrangeObjects.htm", "name": "Align and arrange objects on a page" }, {"src": "UsageInstructions/ChangeWrappingStyle.htm", "name": "Change wrapping style" }, {"src": "UsageInstructions/UseMailMerge.htm", "name": "Use mail merge", "headername": "Mail Merge"}, - {"src": "UsageInstructions/InsertEquation.htm", "name": "Insert equations", "headername": "Math equations"}, + {"src": "UsageInstructions/InsertEquation.htm", "name": "Insert equations", "headername": "Math equations" }, {"src": "HelpfulHints/CollaborativeEditing.htm", "name": "Collaborative document editing", "headername": "Document co-editing"}, {"src": "HelpfulHints/Review.htm", "name": "Document Review"}, {"src": "UsageInstructions/ViewDocInfo.htm", "name": "View document information", "headername": "Tools and settings"}, diff --git a/apps/documenteditor/main/resources/help/en/HelpfulHints/About.htm b/apps/documenteditor/main/resources/help/en/HelpfulHints/About.htm index e853f1609..4eb3a18d1 100644 --- a/apps/documenteditor/main/resources/help/en/HelpfulHints/About.htm +++ b/apps/documenteditor/main/resources/help/en/HelpfulHints/About.htm @@ -18,8 +18,8 @@ and edit documents directly in your browser.

    Using Document Editor, you can perform various editing operations like in any desktop editor, print the edited documents keeping all the formatting details or download them onto your computer hard disk drive - as DOCX, PDF, TXT, ODT, RTF, or HTML files.

    -

    To view the current software version and licensor details, click the About icon icon at the left sidebar.

    + as DOCX, PDF, ODT, TXT, DOTX, PDF/A, OTT, RTF, HTML files.

    +

    To view the current software version and licensor details in the online version, click the About icon icon at the left sidebar. To view the current software version and licensor details in the desktop version, select the About menu item at the left sidebar of the main program window.

    \ No newline at end of file diff --git a/apps/documenteditor/main/resources/help/en/HelpfulHints/AdvancedSettings.htm b/apps/documenteditor/main/resources/help/en/HelpfulHints/AdvancedSettings.htm index 5a96e26c6..b1d283d23 100644 --- a/apps/documenteditor/main/resources/help/en/HelpfulHints/AdvancedSettings.htm +++ b/apps/documenteditor/main/resources/help/en/HelpfulHints/AdvancedSettings.htm @@ -26,15 +26,15 @@
  • Spell Checking is used to turn on/off the spell checking option.
  • Alternate Input is used to turn on/off hieroglyphs.
  • Alignment Guides is used to turn on/off alignment guides that appear when you move objects and allow you to position them on the page precisely.
  • -
  • Autosave is used to turn on/off automatic saving of changes you make while editing.
  • +
  • Autosave is used in the online version to turn on/off automatic saving of changes you make while editing. Autorecover - is used in the desktop version to turn on/off the option that allows to automatically recover documents in case of the unexpected program closing.
  • Co-editing Mode is used to select the display of the changes made during the co-editing:
      -
    • By default the Fast mode is selected, the users who take part in the document co-editing will see the changes in realtime once they are made by other users.
    • +
    • By default the Fast mode is selected, the users who take part in the document co-editing will see the changes in real time once they are made by other users.
    • If you prefer not to see other user changes (so that they do not disturb you, or for some other reason), select the Strict mode and all the changes will be shown only after you click the Save Save icon icon notifying you that there are changes from other users.
  • - Realtime Collaboration Changes is used to specify what changes you want to be highlighted during co-editing: + Real-time Collaboration Changes is used to specify what changes you want to be highlighted during co-editing:
    • Selecting the View None option, changes made during the current session will not be highlighted.
    • Selecting the View All option, all the changes made during the current session will be highlighted.
    • diff --git a/apps/documenteditor/main/resources/help/en/HelpfulHints/CollaborativeEditing.htm b/apps/documenteditor/main/resources/help/en/HelpfulHints/CollaborativeEditing.htm index 5efa4d43d..9c193e186 100644 --- a/apps/documenteditor/main/resources/help/en/HelpfulHints/CollaborativeEditing.htm +++ b/apps/documenteditor/main/resources/help/en/HelpfulHints/CollaborativeEditing.htm @@ -18,19 +18,31 @@
      • simultaneous multi-user access to the edited document
      • visual indication of passages that are being edited by other users
      • -
      • synchronization of changes with one button click
      • +
      • real-time changes display or synchronization of changes with one button click
      • chat to share ideas concerning particular document parts
      • -
      • comments containing the description of a task or problem that should be solved
      • +
      • comments containing the description of a task or problem that should be solved (it's also possible to work with comments in the offline mode, without connecting to the online version)
      +
      +

      Connecting to the online version

      +

      In the desktop editor, open the Connect to cloud option of the left-side menu in the main program window. Connect to your cloud office specifying your account login and password.

      +

      Co-editing

      -

      Document Editor allows to select one of the two available co-editing modes. Fast is used by default and shows the changes made by other users in realtime. Strict is selected to hide other user changes until you click the Save Save icon icon to save your own changes and accept the changes made by others. The mode can be selected in the Advanced Settings. It's also possible to choose the necessary mode using the Co-editing Mode icon Co-editing Mode icon at the Collaboration tab of the top toolbar:

      -

      Co-editing Mode menu

      +

      Document Editor allows to select one of the two available co-editing modes:

      +
        +
      • Fast is used by default and shows the changes made by other users in real time.
      • +
      • Strict is selected to hide other user changes until you click the Save Save icon icon to save your own changes and accept the changes made by others.
      • +
      +

      The mode can be selected in the Advanced Settings. It's also possible to choose the necessary mode using the Co-editing Mode icon Co-editing Mode icon at the Collaboration tab of the top toolbar:

      +

      Co-editing Mode menu

      +

      + Note: when you co-edit a document in the Fast mode, the possibility to Redo the last undone operation is not available. +

      When a document is being edited by several users simultaneously in the Strict mode, the edited text passages are marked with dashed lines of different colors. By hovering the mouse cursor over one of the edited passages, the name of the user who is editing it at the moment is displayed. The Fast mode will show the actions and the names of the co-editors once they are editing the text.

      The number of users who are working at the current document is specified on the right side of the editor header - Number of users icon. If you want to see who exactly are editing the file now, you can click this icon or open the Chat panel with the full list of the users.

      -

      When no users are viewing or editing the file, the icon in the editor header will look like Manage document access rights icon allowing you to manage the users who have access to the file right from the document: invite new users giving them permissions to edit, read or review the document, or deny some users access rights to the file. Click this icon to manage the access to the file; this can be done both when there are no other users who view or co-edit the document at the moment and when there are other users and the icon looks like Number of users icon. It's also possible to set access rights using the Sharing icon Sharing icon at the Collaboration tab of the top toolbar.

      +

      When no users are viewing or editing the file, the icon in the editor header will look like Manage document access rights icon allowing you to manage the users who have access to the file right from the document: invite new users giving them permissions to edit, read, comment, fill forms or review the document, or deny some users access rights to the file. Click this icon to manage the access to the file; this can be done both when there are no other users who view or co-edit the document at the moment and when there are other users and the icon looks like Number of users icon. It's also possible to set access rights using the Sharing icon Sharing icon at the Collaboration tab of the top toolbar.

      As soon as one of the users saves his/her changes by clicking the Save icon icon, the others will see a note within the status bar stating that they have updates. To save the changes you made, so that other users can view them, and get the updates saved by your co-editors, click the Save icon icon in the left upper corner of the top toolbar. The updates will be highlighted for you to check what exactly has been changed.

      -

      You can specify what changes you want to be highlighted during co-editing if you click the File tab at the top toolbar, select the Advanced Settings... option and choose between none, all and last realtime collaboration changes. Selecting View all changes, all the changes made during the current session will be highlighted. Selecting View last changes, only the changes made since you last time clicked the Save icon icon will be highlighted. Selecting View None changes, changes made during the current session will not be highlighted.

      +

      You can specify what changes you want to be highlighted during co-editing if you click the File tab at the top toolbar, select the Advanced Settings... option and choose between none, all and last real-time collaboration changes. Selecting View all changes, all the changes made during the current session will be highlighted. Selecting View last changes, only the changes made since you last time clicked the Save icon icon will be highlighted. Selecting View None changes, changes made during the current session will not be highlighted.

      Chat

      You can use this tool to coordinate the co-editing process on-the-fly, for example, to arrange with your collaborators about who is doing what, which paragraph you are going to edit now etc.

      The chat messages are stored during one session only. To discuss the document content it is better to use comments which are stored until you decide to delete them.

      @@ -46,6 +58,7 @@

      To close the panel with chat messages, click the Chat icon icon at the left sidebar or the Chat icon Chat button at the top toolbar once again.

      Comments

      +

      It's possible to work with comments in the offline mode, without connecting to the online version.

      To leave a comment,

      1. select a text passage where you think there is an error or problem,
      2. diff --git a/apps/documenteditor/main/resources/help/en/HelpfulHints/KeyboardShortcuts.htm b/apps/documenteditor/main/resources/help/en/HelpfulHints/KeyboardShortcuts.htm index 9043572c0..baa6f8176 100644 --- a/apps/documenteditor/main/resources/help/en/HelpfulHints/KeyboardShortcuts.htm +++ b/apps/documenteditor/main/resources/help/en/HelpfulHints/KeyboardShortcuts.htm @@ -7,6 +7,8 @@ + +
        @@ -14,156 +16,201 @@

        Keyboard Shortcuts

        - +
          +
        • Windows/Linux
        • Mac OS
        • +
        +
        - + - - - + + + + - + + - + + + + + + + + - + + - + + - + + - + + - + + - - + + + - + + - + + - - - + + + + + + + + + + - + + - - - - - - - - - - - + - + + - + + - + + - + + + + + + + + + + + + + + - + + - + + - + + - + + - + + - + + - + + - + + - + + - + + - + + - + + - + - + + - + + - - + + + + + + + + + + + + + + + - + + - + + - + - + + - + + - + - + + - + + - + + - + + - + + - + + - + - + + - + + - + + - + + - + + - + + - + + - + + - + + - + + + + + + + + + + + + + + - + - + + - + + - + + - + + - + + - + + - + + - + + - + + - + + - + + - + + - + + - + + - + + - + + - + + - + + - + + - + + - + + - + + - + + - + + - + + - + - + + - + + - + + - + + - - + + + - + - + + - + + - + + - + + - + + - + + - + - + +
        Working with DocumentWorking with Document
        Open 'File' panelAlt+FOpen the File panel to save, download, print the current document, view its info, create a new document or open an existing one, access Document Editor help or advanced settings.Open 'File' panelAlt+F⌥ Option+FOpen the File panel to save, download, print the current document, view its info, create a new document or open an existing one, access Document Editor help or advanced settings.
        Open 'Find and Replace' dialog boxCtrl+FCtrl+F^ Ctrl+F,
        ⌘ Cmd+F
        Open the Find and Replace dialog box to start searching for a character/word/phrase in the currently edited document.
        Open 'Find and Replace' dialog box with replacement fieldCtrl+HCtrl+H^ Ctrl+H Open the Find and Replace dialog box with the replacement field to replace one or more occurrences of the found characters.
        Repeat the last 'Find' action⇧ Shift+F4⇧ Shift+F4,
        ⌘ Cmd+G,
        ⌘ Cmd+⇧ Shift+F4
        Repeat the Find action which has been performed before the key combination press.
        Open 'Comments' panelCtrl+Shift+HCtrl+⇧ Shift+H^ Ctrl+⇧ Shift+H,
        ⌘ Cmd+⇧ Shift+H
        Open the Comments panel to add your own comment or reply to other users' comments.
        Open comment fieldAlt+HAlt+H⌥ Option+H Open a data entry field where you can add the text of your comment.
        Open 'Chat' panelAlt+QAlt+Q⌥ Option+Q Open the Chat panel and send a message.
        Save documentCtrl+SCtrl+S^ Ctrl+S,
        ⌘ Cmd+S
        Save all the changes to the document currently edited with Document Editor. The active file will be saved with its current file name, location, and file format.
        Print documentCtrl+PCtrl+P^ Ctrl+P,
        ⌘ Cmd+P
        Print the document with one of the available printers or save it to a file.
        Download As...Ctrl+Shift+SOpen the Download as... panel to save the currently edited document to the computer hard disk drive in one of the supported formats: DOCX, PDF, TXT, ODT, RTF, HTML.Ctrl+⇧ Shift+S^ Ctrl+⇧ Shift+S,
        ⌘ Cmd+⇧ Shift+S
        Open the Download as... panel to save the currently edited document to the computer hard disk drive in one of the supported formats: DOCX, PDF, ODT, TXT, DOTX, PDF/A, OTT, RTF, HTML.
        Full screenF11F11 Switch to the full screen view to fit Document Editor into your screen.
        Help menuF1F1F1 Open Document Editor Help menu.
        Open existing fileCtrl+OOn the Open local file tab in desktop editors, opens the standard dialog box that allows to select an existing file.Open existing file (Desktop Editors)Ctrl+OOn the Open local file tab in Desktop Editors, opens the standard dialog box that allows to select an existing file.
        Close file (Desktop Editors)Ctrl+W,
        Ctrl+F4
        ^ Ctrl+W,
        ⌘ Cmd+W
        Close the current document window in Desktop Editors.
        Element contextual menuShift+F10⇧ Shift+F10⇧ Shift+F10 Open the selected element contextual menu.
        Close fileCtrl+WClose the selected document window.
        Close the window (tab)Ctrl+F4Close the tab in a browser.
        NavigationNavigation
        Jump to the beginning of the lineHomeHomeHome Put the cursor to the beginning of the currently edited line.
        Jump to the beginning of the documentCtrl+HomeCtrl+Home^ Ctrl+Home Put the cursor to the very beginning of the currently edited document.
        Jump to the end of the lineEndEndEnd Put the cursor to the end of the currently edited line.
        Jump to the end of the documentCtrl+EndCtrl+End^ Ctrl+End Put the cursor to the very end of the currently edited document.
        Jump to the beginning of the previous pageAlt+Ctrl+Page UpPut the cursor to the very beginning of the page which preceeds the currently edited one.
        Jump to the beginning of the next pageAlt+Ctrl+Page Down⌥ Option+⌘ Cmd+⇧ Shift+Page DownPut the cursor to the very beginning of the page which follows the currently edited one.
        Scroll downPage DownPage DownPage Down,
        ⌥ Option+Fn+
        Scroll the document approximately one visible page down.
        Scroll upPage UpPage UpPage Up,
        ⌥ Option+Fn+
        Scroll the document approximately one visible page up.
        Next pageAlt+Page DownAlt+Page Down⌥ Option+Page Down Go to the next page in the currently edited document.
        Previous pageAlt+Page UpAlt+Page Up⌥ Option+Page Up Go to the previous page in the currently edited document.
        Zoom InCtrl+Plus sign (+)Ctrl++^ Ctrl+=,
        ⌘ Cmd+=
        Zoom in the currently edited document.
        Zoom OutCtrl+Minus sign (-)Ctrl+-^ Ctrl+-,
        ⌘ Cmd+-
        Zoom out the currently edited document.
        Move one character to the leftLeft arrow Move the cursor one character to the left.
        Move one character to the rightRight arrow Move the cursor one character to the right.
        Move to the beginning of a word or one word to the leftCtrl+Left arrowCtrl+^ Ctrl+,
        ⌘ Cmd+
        Move the cursor to the beginning of a word or one word to the left.
        Move one word to the rightCtrl+Right arrowCtrl+^ Ctrl+,
        ⌘ Cmd+
        Move the cursor one word to the right.
        Move one line upUp arrow Move the cursor one line up.
        Move one line downDown arrow Move the cursor one line down.
        WritingWriting
        End paragraphEnter↵ Enter↵ Return End the current paragraph and start a new one.
        Add line breakShift+Enter⇧ Shift+↵ Enter⇧ Shift+↵ Return Add a line break without starting a new paragraph.
        DeleteBackspace, DeleteDelete one character to the left (Backspace) or to the right (Delete) of the cursor.← Backspace,
        Delete
        ← Backspace,
        Delete
        Delete one character to the left (← Backspace) or to the right (Delete) of the cursor.
        Delete word to the left of cursorCtrl+← Backspace^ Ctrl+← Backspace,
        ⌘ Cmd+← Backspace
        Delete one word to the left of the cursor.
        Delete word to the right of cursorCtrl+Delete^ Ctrl+Delete,
        ⌘ Cmd+Delete
        Delete one word to the right of the cursor.
        Create nonbreaking spaceCtrl+Shift+SpacebarCtrl+⇧ Shift+␣ Spacebar^ Ctrl+⇧ Shift+␣ Spacebar Create a space between characters which cannot be used to start a new line.
        Create nonbreaking hyphenCtrl+Shift+HyphenCtrl+⇧ Shift+Hyphen^ Ctrl+⇧ Shift+Hyphen Create a hyphen between characters which cannot be used to start a new line.
        Undo and RedoUndo and Redo
        UndoCtrl+ZCtrl+Z^ Ctrl+Z,
        ⌘ Cmd+Z
        Reverse the latest performed action.
        RedoCtrl+YCtrl+Y^ Ctrl+Y,
        ⌘ Cmd+Y,
        ⌘ Cmd+⇧ Shift+Z
        Repeat the latest undone action.
        Cut, Copy, and PasteCut, Copy, and Paste
        CutCtrl+X, Shift+DeleteCtrl+X,
        ⇧ Shift+Delete
        ⌘ Cmd+X,
        ⇧ Shift+Delete
        Delete the selected text fragment and send it to the computer clipboard memory. The copied text can be later inserted to another place in the same document, into another document, or into some other program.
        CopyCtrl+C, Ctrl+InsertCtrl+C,
        Ctrl+Insert
        ⌘ Cmd+C Send the selected text fragment to the computer clipboard memory. The copied text can be later inserted to another place in the same document, into another document, or into some other program.
        PasteCtrl+V, Shift+InsertCtrl+V,
        ⇧ Shift+Insert
        ⌘ Cmd+V Insert the previously copied text fragment from the computer clipboard memory to the current cursor position. The text can be previously copied from the same document, from another document, or from some other program.
        Insert hyperlinkCtrl+KCtrl+K⌘ Cmd+K Insert a hyperlink which can be used to go to a web address.
        Copy styleCtrl+Shift+CCtrl+⇧ Shift+C⌘ Cmd+⇧ Shift+C Copy the formatting from the selected fragment of the currently edited text. The copied formatting can be later applied to another text fragment in the same document.
        Apply styleCtrl+Shift+VCtrl+⇧ Shift+V⌘ Cmd+⇧ Shift+V Apply the previously copied formatting to the text in the currently edited document.
        Text SelectionText Selection
        Select allCtrl+ACtrl+A⌘ Cmd+A Select all the document text with tables and images.
        Select fragmentShift+Arrow⇧ Shift+ ⇧ Shift+ Select the text character by character.
        Select from cursor to beginning of lineShift+Home⇧ Shift+Home⇧ Shift+Home Select a text fragment from the cursor to the beginning of the current line.
        Select from cursor to end of lineShift+End⇧ Shift+End⇧ Shift+End Select a text fragment from the cursor to the end of the current line.
        Select one character to the rightShift+Right arrow⇧ Shift+⇧ Shift+ Select one character to the right of the cursor position.
        Select one character to the leftShift+Left arrow⇧ Shift+⇧ Shift+ Select one character to the left of the cursor position.
        Select to the end of a wordCtrl+Shift+Right arrowCtrl+⇧ Shift+ Select a text fragment from the cursor to the end of a word.
        Select to the beginning of a wordCtrl+Shift+Left arrowCtrl+⇧ Shift+ Select a text fragment from the cursor to the beginning of a word.
        Select one line upShift+Up arrow⇧ Shift+⇧ Shift+ Select one line up (with the cursor at the beginning of a line).
        Select one line downShift+Down arrow⇧ Shift+⇧ Shift+ Select one line down (with the cursor at the beginning of a line).
        Select the page up⇧ Shift+Page Up⇧ Shift+Page UpSelect the page part from the cursor position to the upper part of the screen.
        Select the page down⇧ Shift+Page Down⇧ Shift+Page DownSelect the page part from the cursor position to the lower part of the screen.
        Text StylingText Styling
        BoldCtrl+BCtrl+B^ Ctrl+B,
        ⌘ Cmd+B
        Make the font of the selected text fragment bold giving it more weight.
        ItalicCtrl+ICtrl+I^ Ctrl+I,
        ⌘ Cmd+I
        Make the font of the selected text fragment italicized giving it some right side tilt.
        UnderlineCtrl+UCtrl+U^ Ctrl+U,
        ⌘ Cmd+U
        Make the selected text fragment underlined with the line going under the letters.
        StrikeoutCtrl+5Ctrl+5^ Ctrl+5,
        ⌘ Cmd+5
        Make the selected text fragment struck out with the line going through the letters.
        SubscriptCtrl+dot (.)Ctrl+.^ Ctrl+⇧ Shift+>,
        ⌘ Cmd+⇧ Shift+>
        Make the selected text fragment smaller and place it to the lower part of the text line, e.g. as in chemical formulas.
        SuperscriptCtrl+comma (,)Ctrl+,^ Ctrl+⇧ Shift+<,
        ⌘ Cmd+⇧ Shift+<
        Make the selected text fragment smaller and place it to the upper part of the text line, e.g. as in fractions.
        Heading 1 styleAlt+1 (for Windows and Linux browsers) -
        Alt+Ctrl+1 (for Mac browsers) -
        Alt+1⌥ Option+^ Ctrl+1 Apply the style of the heading 1 to the selected text fragment.
        Heading 2 styleAlt+2 (for Windows and Linux browsers) -
        Alt+Ctrl+2 (for Mac browsers) -
        Alt+2⌥ Option+^ Ctrl+2 Apply the style of the heading 2 to the selected text fragment.
        Heading 3 styleAlt+3 (for Windows and Linux browsers) -
        Alt+Ctrl+3 (for Mac browsers) -
        Alt+3⌥ Option+^ Ctrl+3 Apply the style of the heading 3 to the selected text fragment.
        Bulleted listCtrl+Shift+LCtrl+⇧ Shift+L^ Ctrl+⇧ Shift+L,
        ⌘ Cmd+⇧ Shift+L
        Create an unordered bulleted list from the selected text fragment or start a new one.
        Remove formattingCtrl+SpacebarCtrl+␣ Spacebar Remove formatting from the selected text fragment.
        Increase fontCtrl+]Ctrl+]⌘ Cmd+] Increase the size of the font for the selected text fragment 1 point.
        Decrease fontCtrl+[Ctrl+[⌘ Cmd+[ Decrease the size of the font for the selected text fragment 1 point.
        Align center/leftCtrl+ECtrl+E^ Ctrl+E,
        ⌘ Cmd+E
        Switch a paragraph between centered and left-aligned.
        Align justified/leftCtrl+J, Ctrl+LCtrl+J,
        Ctrl+L
        ^ Ctrl+J,
        ⌘ Cmd+J
        Switch a paragraph between justified and left-aligned.
        Align right/leftCtrl+RCtrl+R^ Ctrl+R Switch a paragraph between right-aligned and left-aligned.
        Apply subscript formatting (automatic spacing)Ctrl+Equal sign (=)Ctrl+= Apply subscript formatting to the selected text fragment.
        Apply superscript formatting (automatic spacing)Ctrl+Shift+Plus sign (+)Ctrl+⇧ Shift++ Apply superscript formatting to the selected text fragment.
        Insert page breakCtrl+EnterCtrl+↵ Enter^ Ctrl+↵ Return Insert a page break at the current cursor position.
        Increase indentCtrl+MCtrl+M^ Ctrl+M Indent a paragraph from the left incrementally.
        Decrease indentCtrl+Shift+MCtrl+⇧ Shift+M^ Ctrl+⇧ Shift+M Remove a paragraph indent from the left incrementally.
        Add page numberCtrl+Shift+PCtrl+⇧ Shift+P^ Ctrl+⇧ Shift+P Add the current page number at the current cursor position.
        Nonprinting charactersCtrl+Shift+Num8Ctrl+⇧ Shift+Num8 Show or hide the display of nonprinting characters.
        Delete one character to the leftBackspace← Backspace← Backspace Delete one character to the left of the cursor.
        Delete one character to the rightDeleteDeleteDelete Delete one character to the right of the cursor.
        Modifying ObjectsModifying Objects
        Constrain movementShift+drag⇧ Shift + drag⇧ Shift + drag Constrain the movement of the selected object horizontally or vertically.
        Set 15-degree rotationShift+drag (when rotating)⇧ Shift + drag (when rotating)⇧ Shift + drag (when rotating) Constrain the rotation angle to 15-degree increments.
        Maintain proportionsShift+drag (when resizing)⇧ Shift + drag (when resizing)⇧ Shift + drag (when resizing) Maintain the proportions of the selected object when resizing.
        Draw straight line or arrowShift+drag (when drawing lines/arrows)⇧ Shift + drag (when drawing lines/arrows)⇧ Shift + drag (when drawing lines/arrows) Draw a straight vertical/horizontal/45-degree line or arrow.
        Movement by one-pixel incrementsCtrl+Arrow keysHold down the Ctrl key and use the keybord arrows to move the selected object by one pixel at a time.Ctrl+ Hold down the Ctrl key and use the keybord arrows to move the selected object by one pixel at a time.
        Working with TablesWorking with Tables
        Move to the next cell in a rowTab↹ Tab↹ Tab Go to the next cell in a table row.
        Move to the previous cell in a rowShift+Tab⇧ Shift+↹ Tab⇧ Shift+↹ Tab Go to the previous cell in a table row.
        Move to the next rowDown arrow Go to the next row in a table.
        Move to the previous rowUp arrow Go to the previous row in a table.
        Start new paragraphEnter↵ Enter↵ Return Start a new paragraph within a cell.
        Add new rowTab in the lower right table cell.↹ Tab in the lower right table cell.↹ Tab in the lower right table cell. Add a new row at the bottom of the table.
        Inserting special charactersInserting special characters
        Insert formulaAlt+Equal sign (=)Alt+= Insert a formula at the current cursor position.
        diff --git a/apps/documenteditor/main/resources/help/en/HelpfulHints/Navigation.htm b/apps/documenteditor/main/resources/help/en/HelpfulHints/Navigation.htm index 445b96aa9..f8d603c2e 100644 --- a/apps/documenteditor/main/resources/help/en/HelpfulHints/Navigation.htm +++ b/apps/documenteditor/main/resources/help/en/HelpfulHints/Navigation.htm @@ -28,7 +28,7 @@
      3. Hide Rulers - hides rulers which are used to align text, graphics, tables, and other elements in a document, set up margins, tab stops, and paragraph indents. To show the hidden Rulers click this option once again.

    The right sidebar is minimized by default. To expand it, select any object (e.g. image, chart, shape) or text passage and click the icon of the currently activated tab on the right. To minimize the right sidebar, click the icon once again.

    -

    When the Comments or Chat panel is opened, the left sidebar width is adjusted by simple drag-and-drop: +

    When the Comments or Chat panel is opened, the left sidebar width is adjusted by simple drag-and-drop: move the mouse cursor over the left sidebar border so that it turns into the bidirectional arrow and drag the border to the right to extend the sidebar width. To restore its original width move the border to the left.

    Use the Navigation Tools

    To navigate through your document, use the following tools:

    diff --git a/apps/documenteditor/main/resources/help/en/HelpfulHints/SupportedFormats.htm b/apps/documenteditor/main/resources/help/en/HelpfulHints/SupportedFormats.htm index c92a6bbb0..5f399abfe 100644 --- a/apps/documenteditor/main/resources/help/en/HelpfulHints/SupportedFormats.htm +++ b/apps/documenteditor/main/resources/help/en/HelpfulHints/SupportedFormats.htm @@ -40,6 +40,13 @@ + + + + DOTX + Word Open XML Document Template
    Zipped, XML-based file format developed by Microsoft for text document templates. A DOTX template contains formatting settings, styles etc. and can be used to create multiple documents with the same formatting + + + + + + + ODT Word processing file format of OpenDocument, an open standard for electronic documents @@ -47,6 +54,13 @@ + + + + OTT + OpenDocument Document Template
    OpenDocument file format for text document templates. An OTT template contains formatting settings, styles etc. and can be used to create multiple documents with the same formatting + + + + + in the online version + RTF Rich Text Format
    Document file format developed by Microsoft for cross-platform document interchange @@ -68,12 +82,19 @@ + + + PDF/A + Portable Document Format / A
    An ISO-standardized version of the Portable Document Format (PDF) specialized for use in the archiving and long-term preservation of electronic documents. + + + + + + HTML HyperText Markup Language
    The main markup language for web pages - - + + + + in the online version EPUB diff --git a/apps/documenteditor/main/resources/help/en/ProgramInterface/FileTab.htm b/apps/documenteditor/main/resources/help/en/ProgramInterface/FileTab.htm index b34aa506a..66c07a910 100644 --- a/apps/documenteditor/main/resources/help/en/ProgramInterface/FileTab.htm +++ b/apps/documenteditor/main/resources/help/en/ProgramInterface/FileTab.htm @@ -15,16 +15,26 @@
  • File tab

    The File tab allows to perform some basic operations on the current file.

    -

    File tab

    +
    +

    Online Document Editor window:

    +

    File tab

    +
    +
    +

    Desktop Document Editor window:

    +

    File tab

    +

    Using this tab, you can:

      -
    • save the current file (in case the Autosave option is disabled), download, print or rename it,
    • -
    • create a new document or open a recently edited one,
    • +
    • in the online version, save the current file (in case the Autosave option is disabled), download as (save the document in the selected format to the computer hard disk drive), save copy as (save a copy of the document in the selected format to the portal documents), print or rename it, + in the desktop version, save the current file keeping the current format and location using the Save option or save the current file with a different name, location or format using the Save as option, print the file. +
    • +
    • protect the file using a password, change or remove the password (available in the desktop version only);
    • +
    • create a new document or open a recently edited one (available in the online version only),
    • view general information about the document,
    • -
    • manage access rights,
    • -
    • track version history,
    • +
    • manage access rights (available in the online version only),
    • +
    • track version history (available in the online version only),
    • access the editor Advanced Settings,
    • -
    • return to the Documents list.
    • +
    • in the desktop version, open the folder where the file is stored in the File explorer window. In the online version, open the folder of the Documents module where the file is stored in a new browser tab.
    diff --git a/apps/documenteditor/main/resources/help/en/ProgramInterface/HomeTab.htm b/apps/documenteditor/main/resources/help/en/ProgramInterface/HomeTab.htm index 7dd5ad011..faa3d620f 100644 --- a/apps/documenteditor/main/resources/help/en/ProgramInterface/HomeTab.htm +++ b/apps/documenteditor/main/resources/help/en/ProgramInterface/HomeTab.htm @@ -14,8 +14,15 @@

    Home tab

    -

    The Home tab opens by default when you open a document. It allows to format font and paragraphs. Some other options are also available here, such as Mail Merge and color schemes.

    -

    Home tab

    +

    The Home tab opens by default when you open a document. It allows to format font and paragraphs. Some other options are also available here, such as Mail Merge and color schemes.

    +
    +

    Online Document Editor window:

    +

    Home tab

    +
    +
    +

    Desktop Document Editor window:

    +

    Home tab

    +

    Using this tab, you can:

    diff --git a/apps/documenteditor/main/resources/help/en/ProgramInterface/InsertTab.htm b/apps/documenteditor/main/resources/help/en/ProgramInterface/InsertTab.htm index 1e2e32785..938c52f4f 100644 --- a/apps/documenteditor/main/resources/help/en/ProgramInterface/InsertTab.htm +++ b/apps/documenteditor/main/resources/help/en/ProgramInterface/InsertTab.htm @@ -15,12 +15,20 @@

    Insert tab

    The Insert tab allows to add some page formatting elements, as well as visual objects and comments.

    -

    Insert tab

    +
    +

    Online Document Editor window:

    +

    Insert tab

    +
    +
    +

    Desktop Document Editor window:

    +

    Insert tab

    +

    Using this tab, you can:

    diff --git a/apps/documenteditor/main/resources/help/en/ProgramInterface/LayoutTab.htm b/apps/documenteditor/main/resources/help/en/ProgramInterface/LayoutTab.htm index 32b10a7a9..6a4758fda 100644 --- a/apps/documenteditor/main/resources/help/en/ProgramInterface/LayoutTab.htm +++ b/apps/documenteditor/main/resources/help/en/ProgramInterface/LayoutTab.htm @@ -15,7 +15,14 @@

    Layout tab

    The Layout tab allows to change the document appearance: set up page parameters and define the arrangement of visual elements.

    -

    Layout tab

    +
    +

    Online Document Editor window:

    +

    Layout tab

    +
    +
    +

    Desktop Document Editor window:

    +

    Layout tab

    +

    Using this tab, you can:

    • adjust page margins, orientation, size,
    • diff --git a/apps/documenteditor/main/resources/help/en/ProgramInterface/PluginsTab.htm b/apps/documenteditor/main/resources/help/en/ProgramInterface/PluginsTab.htm index 5bef60a2e..92aea945d 100644 --- a/apps/documenteditor/main/resources/help/en/ProgramInterface/PluginsTab.htm +++ b/apps/documenteditor/main/resources/help/en/ProgramInterface/PluginsTab.htm @@ -15,19 +15,29 @@

    Plugins tab

    The Plugins tab allows to access advanced editing features using available third-party components. Here you can also use macros to simplify routine operations.

    -

    Plugins tab

    +
    +

    Online Document Editor window:

    +

    Plugins tab

    +
    +
    +

    Desktop Document Editor window:

    +

    Plugins tab

    +
    +

    The Settings button allows to open the window where you can view and manage all installed plugins and add your own ones.

    The Macros button allows to open the window where you can create your own macros and run them. To learn more about macros you can refer to our API Documentation.

    Currently, the following plugins are available by default:

    • ClipArt allows to add images from the clipart collection into your document,
    • +
    • Highlight code allows to highlight syntax of the code selecting the necessary language, style, background color,
    • OCR allows to recognize text included into a picture and insert it into the document text,
    • PhotoEditor allows to edit images: crop, resize them, apply effects etc.,
    • -
    • Speech allows to convert the selected text into speech,
    • +
    • Speech allows to convert the selected text into speech,
    • Symbol Table allows to insert special symbols into your text,
    • +
    • Thesaurus allows to search for synonyms and antonyms of a word and replace it with the selected one,
    • Translator allows to translate the selected text into other languages,
    • YouTube allows to embed YouTube videos into your document.
    -

    The Wordpress and EasyBib plugins can be used if you connect the corresponding services in your portal settings. You can use the following instructions for the server version or for the SaaS version.

    +

    The Wordpress and EasyBib plugins can be used if you connect the corresponding services in your portal settings. You can use the following instructions for the server version or for the SaaS version.

    To learn more about plugins please refer to our API Documentation. All the currently existing open source plugin examples are available on GitHub.

    diff --git a/apps/documenteditor/main/resources/help/en/ProgramInterface/ProgramInterface.htm b/apps/documenteditor/main/resources/help/en/ProgramInterface/ProgramInterface.htm index ebb9517ae..a3a7d211e 100644 --- a/apps/documenteditor/main/resources/help/en/ProgramInterface/ProgramInterface.htm +++ b/apps/documenteditor/main/resources/help/en/ProgramInterface/ProgramInterface.htm @@ -15,18 +15,38 @@

    Introducing the Document Editor user interface

    Document Editor uses a tabbed interface where editing commands are grouped into tabs by functionality.

    -

    Editor window

    +
    +

    Online Document Editor window:

    +

    Online Document Editor window

    +
    +
    +

    Desktop Document Editor window:

    +

    Desktop Document Editor window

    +

    The editor interface consists of the following main elements:

      -
    1. Editor header displays the logo, menu tabs, document name as well as three icons on the right that allow to set access rights, return to the Documents list, adjust View Settings and access the editor Advanced Settings. -

      Icons in the editor header

      +
    2. Editor header displays the logo, opened documents tabs, document name and menu tabs. +

      In the left part of the Editor header there are the Save, Print file, Undo and Redo buttons.

      +

      Icons in the editor header

      +

      In the right part of the Editor header the user name is displayed as well as the following icons:

      +
        +
      • Open file location Open file location - in the desktop version, it allows to open the folder where the file is stored in the File explorer window. In the online version, it allows to open the folder of the Documents module where the file is stored in a new browser tab.
      • +
      • View Settings icon - allows to adjust View Settings and access the editor Advanced Settings.
      • +
      • Manage document access rights icon Manage document access rights - (available in the online version only) allows to set access rights for the documents stored in the cloud.
      • +
    3. -
    4. Top toolbar displays a set of editing commands depending on the selected menu tab. Currently, the following tabs are available: File, Home, Insert, Layout, References, Collaboration, Plugins. -

      The Print, Save, Copy, Paste, Undo and Redo options are always available at the left part of the Top toolbar regardless of the selected tab.

      -

      Icons on the top toolbar

      +
    5. Top toolbar displays a set of editing commands depending on the selected menu tab. Currently, the following tabs are available: File, Home, Insert, Layout, References, Collaboration, Protection, Plugins. +

      The Copy icon Copy and Paste icon Paste options are always available at the left part of the Top toolbar regardless of the selected tab.

    6. Status bar at the bottom of the editor window contains the page number indicator, displays some notifications (such as "All changes saved" etc.), allows to set text language, enable spell checking, turn on the track changes mode, adjust zoom.
    7. -
    8. Left sidebar contains icons that allow to use the Search and Replace tool, open the Comments, Chat and Navigation panel, contact our support team and view the information about the program.
    9. +
    10. Left sidebar contains the following icons: +
        +
      • Search icon - allows to use the Search and Replace tool,
      • +
      • Comments icon - allows to open the Comments panel,
      • +
      • Navigation icon - allows to go to the Navigation panel and manage headings,
      • +
      • Chat icon - (available in the online version only) allows to open the Chat panel, as well as the icons that allow to contact our support team and view the information about the program.
      • +
      +
    11. Right sidebar allows to adjust additional parameters of different objects. When you select a particular object in the text, the corresponding icon is activated at the right sidebar. Click this icon to expand the right sidebar.
    12. Horizontal and vertical Rulers allow to align text and other elements in a document, set up margins, tab stops, and paragraph indents.
    13. Working area allows to view document content, enter and edit data.
    14. diff --git a/apps/documenteditor/main/resources/help/en/ProgramInterface/ReferencesTab.htm b/apps/documenteditor/main/resources/help/en/ProgramInterface/ReferencesTab.htm index bd622df09..96370d49a 100644 --- a/apps/documenteditor/main/resources/help/en/ProgramInterface/ReferencesTab.htm +++ b/apps/documenteditor/main/resources/help/en/ProgramInterface/ReferencesTab.htm @@ -15,12 +15,20 @@

      References tab

      The References tab allows to manage different types of references: add and refresh a table of contents, create and edit footnotes, insert hyperlinks.

      -

      References tab

      +
      +

      Online Document Editor window:

      +

      References tab

      +
      +
      +

      Desktop Document Editor window:

      +

      References tab

      +

      Using this tab, you can:

      diff --git a/apps/documenteditor/main/resources/help/en/ProgramInterface/ReviewTab.htm b/apps/documenteditor/main/resources/help/en/ProgramInterface/ReviewTab.htm index 0fd056100..636ff2b0e 100644 --- a/apps/documenteditor/main/resources/help/en/ProgramInterface/ReviewTab.htm +++ b/apps/documenteditor/main/resources/help/en/ProgramInterface/ReviewTab.htm @@ -14,18 +14,25 @@

      Collaboration tab

      -

      The Collaboration tab allows to organize collaborative work on the document: share the file, select a co-editing mode, manage comments, track changes made by a reviewer, view all versions and revisions.

      -

      Collaboration tab

      +

      The Collaboration tab allows to organize collaborative work on the document. In the online version, you can share the file, select a co-editing mode, manage comments, track changes made by a reviewer, view all versions and revisions. In the desktop version, you can manage comments and use the Track Changes feature.

      +
      +

      Online Document Editor window:

      +

      Collaboration tab

      +
      +
      +

      Desktop Document Editor window:

      +

      Collaboration tab

      +

      Using this tab, you can:

      diff --git a/apps/documenteditor/main/resources/help/en/UsageInstructions/AddFormulasInTables.htm b/apps/documenteditor/main/resources/help/en/UsageInstructions/AddFormulasInTables.htm new file mode 100644 index 000000000..a70d2bd2a --- /dev/null +++ b/apps/documenteditor/main/resources/help/en/UsageInstructions/AddFormulasInTables.htm @@ -0,0 +1,167 @@ + + + + Use formulas in tables + + + + + + + +
      +
      + +
      +

      Use formulas in tables

      +

      Insert a formula

      +

      You can perform simple calculations on data in table cells by adding formulas. To insert a formula into a table cell,

      +
        +
      1. place the cursor within the cell where you want to display the result,
      2. +
      3. click the Add formula button at the right sidebar,
      4. +
      5. in the Formula Settings window that opens, enter the necessary formula into the Formula field. +

        You can enter a needed formula manually using the common mathematical operators (+, -, *, /), e.g. =A1*B2 or use the Paste Function drop-down list to select one of the embedded functions, e.g. =PRODUCT(A1,B2).

        +

        Add formula

        +
      6. +
      7. manually specify necessary arguments within the parentheses in the Formula field. If the function requires several arguments, they must be separated by commas.
      8. +
      9. use the Number Format drop-down list if you want to display the result in a certain number format,
      10. +
      11. click OK.
      12. +
      +

      The result will be displayed in the selected cell.

      +

      To edit the added formula, select the result in the cell and click the Add formula button at the right sidebar, make the necessary changes in the Formula Settings window and click OK.

      +
      +

      Add references to cells

      +

      You can use the following arguments to quickly add references to cell ranges:

      +
        +
      • ABOVE - a reference to all the cells in the column above the selected cell
      • +
      • LEFT - a reference to all the cells in the row to the left of the selected cell
      • +
      • BELOW - a reference to all the cells in the column below the selected cell
      • +
      • RIGHT - a reference to all the cells in the row to the right of the selected cell
      • +
      +

      These arguments can be used with the AVERAGE, COUNT, MAX, MIN, PRODUCT, SUM functions.

      +

      You can also manually enter references to a certain cell (e.g., A1) or a range of cells (e.g., A1:B3).

      +

      Use bookmarks

      +

      If you have added some bookmarks to certain cells within your table, you can use these bookmarks as arguments when entering formulas.

      +

      In the Formula Settings window, place the cursor within the parentheses in the Formula entry field where you want the argument to be added and use the Paste Bookmark drop-down list to select one of the previously added bookmarks.

      +

      Update formula results

      +

      If you change some values in the table cells, you will need to manually update formula results:

      +
        +
      • To update a single formula result, select the necessary result and press F9 or right-click the result and use the Update field option from the menu.
      • +
      • To update several formula results, select the necessary cells or the entire table and press F9.
      • +
      +
      +

      Embedded functions

      +

      You can use the following standard math, statistical and logical functions:

      + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
      CategoryFunctionDescriptionExample
      MathematicalABS(x)The function is used to return the absolute value of a number.=ABS(-10)
      Returns 10
      LogicalAND(logical1, logical2, ...)The function is used to check if the logical value you enter is TRUE or FALSE. The function returns 1 (TRUE) if all the arguments are TRUE.=AND(1>0,1>3)
      Returns 0
      StatisticalAVERAGE(argument-list)The function is used to analyze the range of data and find the average value.=AVERAGE(4,10)
      Returns 7
      StatisticalCOUNT(argument-list)The function is used to count the number of the selected cells which contain numbers ignoring empty cells or those contaning text.=COUNT(A1:B3)
      Returns 6
      LogicalDEFINED()The function evaluates if a value in the cell is defined. The function returns 1 if the value is defined and calculated without errors and returns 0 if the value is not defined or calculated with an error.=DEFINED(A1)
      LogicalFALSE()The function returns 0 (FALSE) and does not require any argument.=FALSE
      Returns 0
      MathematicalINT(x)The function is used to analyze and return the integer part of the specified number.=INT(2.5)
      Returns 2
      StatisticalMAX(number1, number2, ...)The function is used to analyze the range of data and find the largest number.=MAX(15,18,6)
      Returns 18
      StatisticalMIN(number1, number2, ...)The function is used to analyze the range of data and find the smallest number.=MIN(15,18,6)
      Returns 6
      MathematicalMOD(x, y)The function is used to return the remainder after the division of a number by the specified divisor.=MOD(6,3)
      Returns 0
      LogicalNOT(logical)The function is used to check if the logical value you enter is TRUE or FALSE. The function returns 1 (TRUE) if the argument is FALSE and 0 (FALSE) if the argument is TRUE.=NOT(2<5)
      Returns 0
      LogicalOR(logical1, logical2, ...)The function is used to check if the logical value you enter is TRUE or FALSE. The function returns 0 (FALSE) if all the arguments are FALSE.=OR(1>0,1>3)
      Returns 1
      MathematicalPRODUCT(argument-list)The function is used to multiply all the numbers in the selected range of cells and return the product.=PRODUCT(2,5)
      Returns 10
      MathematicalROUND(x, num_digits)The function is used to round the number to the desired number of digits.=ROUND(2.25,1)
      Returns 2.3
      MathematicalSIGN(x)The function is used to return the sign of a number. If the number is positive, the function returns 1. If the number is negative, the function returns -1. If the number is 0, the function returns 0.=SIGN(-12)
      Returns -1
      MathematicalSUM(argument-list)The function is used to add all the numbers in the selected range of cells and return the result.=SUM(5,3,2)
      Returns 10
      LogicalTRUE()The function returns 1 (TRUE) and does not require any argument.=TRUE
      Returns 1
      +
      + + \ No newline at end of file diff --git a/apps/documenteditor/main/resources/help/en/UsageInstructions/AddHyperlinks.htm b/apps/documenteditor/main/resources/help/en/UsageInstructions/AddHyperlinks.htm index f413784a5..45d6139d1 100644 --- a/apps/documenteditor/main/resources/help/en/UsageInstructions/AddHyperlinks.htm +++ b/apps/documenteditor/main/resources/help/en/UsageInstructions/AddHyperlinks.htm @@ -20,12 +20,17 @@
    15. switch to the Insert or References tab of the top toolbar,
    16. click the Hyperlink icon Hyperlink icon at the top toolbar,
    17. after that the Hyperlink Settings window will appear where you can specify the hyperlink parameters: -
        -
      • Link to - enter a URL in the format http://www.example.com.
      • -
      • Display - enter a text that will get clickable and lead to the web address specified in the upper field.
      • -
      • ScreenTip text - enter a text that will become visible in a small pop-up window that provides a brief note or label pertaining to the hyperlink being pointed to.
      • -
      -

      Hyperlink Settings window

      +
        +
      • + Select a link type you wish to insert: +

        Use the External Link option and enter a URL in the format http://www.example.com in the Link to field below if you need to add a hyperlink leading to an external website.

        +

        Hyperlink Settings window

        +

        Use the Place in Document option and select one of the existing headings in the document text or one of previously added bookmarks if you need to add a hyperlink leading to a certain place in the same document.

        +

        Hyperlink Settings window

        +
      • +
      • Display - enter a text that will get clickable and lead to the address specified in the upper field.
      • +
      • ScreenTip text - enter a text that will become visible in a small pop-up window that provides a brief note or label pertaining to the hyperlink being pointed to.
      • +
    18. Click the OK button.
    diff --git a/apps/documenteditor/main/resources/help/en/UsageInstructions/AlignArrangeObjects.htm b/apps/documenteditor/main/resources/help/en/UsageInstructions/AlignArrangeObjects.htm index e9cc928e2..464482ca9 100644 --- a/apps/documenteditor/main/resources/help/en/UsageInstructions/AlignArrangeObjects.htm +++ b/apps/documenteditor/main/resources/help/en/UsageInstructions/AlignArrangeObjects.htm @@ -16,22 +16,57 @@

    Align and arrange objects on a page

    The added autoshapes, images, charts or text boxes can be aligned, grouped and ordered on a page. To perform any of these actions, first select a separate object or several objects on the page. To select several objects, hold down the Ctrl key and left-click the necessary objects. To select a text box, click on its border, not the text within it. After that you can use either the icons at the Layout tab of the top toolbar described below or the analogous options from the right-click menu.

    Align objects

    -

    To align the selected object(s), click the Align icon Align icon at the Layout tab of the top toolbar and select the necessary alignment type from the list:

    -
      -
    • Align Left Align Left icon - to line up the object(s) horizontally by the left side of the page,
    • -
    • Align Center Align Center icon - to line up the object(s) horizontally by the center of the page,
    • -
    • Align Right Align Right icon - to line up the object(s) horizontally by the right side of the page,
    • -
    • Align Top Align Top icon - to line up the object(s) vertically by the top side of the page,
    • -
    • Align Middle Align Middle icon - to line up the object(s) vertically by the middle of the page,
    • -
    • Align Bottom Align Bottom icon - to line up the object(s) vertically by the bottom side of the page.
    • -
    +

    To align two or more selected objects,

    +
      +
    1. Click the Align icon Align icon at the Layout tab of the top toolbar and select one of the following options: +
        +
      • Align to Page to align objects relative to the edges of the page,
      • +
      • Align to Margin to align objects relative to the page margins,
      • +
      • Align Selected Objects (this option is selected by default) to align objects relative to each other,
      • +
      +
    2. +
    3. Click the Align icon Align icon once again and select the necessary alignment type from the list: +
        +
      • Align Left Align Left icon - to line up the objects horizontally by the left edge of the leftmost object/left edge of the page/left page margin,
      • +
      • Align Center Align Center icon - to line up the objects horizontally by their centers/center of the page/center of the space between the left and right page margins,
      • +
      • Align Right Align Right icon - to line up the objects horizontally by the right edge of the rightmost object/right edge of the page/right page margin,
      • +
      • Align Top Align Top icon - to line up the objects vertically by the top edge of the topmost object/top edge of the page/top page margin,
      • +
      • Align Middle Align Middle icon - to line up the objects vertically by their middles/middle of the page/middle of the space between the top and bottom page margins,
      • +
      • Align Bottom Align Bottom icon - to line up the objects vertically by the bottom edge of the bottommost object/bottom edge of the page/bottom page margin.
      • +
      +
    4. +
    +

    Alternatively, you can right-click the selected objects, choose the Align option from the contextual menu and then use one of the available alignment options.

    +

    If you want to align a single object, it can be aligned relative to the edges of the page or to the page margins. The Align to Margin option is selected by default in this case.

    +

    Distribute objects

    +

    To distribute three or more selected objects horizontally or vertically so that the equal distance appears between them,

    +
      +
    1. + Click the Align icon Align icon at the Layout tab of the top toolbar and select one of the following options: +
        +
      • Align to Page to distribute objects between the edges of the page,
      • +
      • Align to Margin to distribute objects between the page margins,
      • +
      • Align Selected Objects (this option is selected by default) to distribute objects between two outermost selected objects,
      • +
      +
    2. +
    3. + Click the Align icon Align icon once again and select the necessary distribution type from the list: +
        +
      • Distribute Horizontally Distribute Horizontally icon - to distribute objects evenly between the leftmost and rightmost selected objects/left and right edges of the page/left and right page margins.
      • +
      • Distribute Vertically Distribute Vertically icon - to distribute objects evenly between the topmost and bottommost selected objects/top and bottom edges of the page/top and bottom page margins.
      • +
      +
    4. +
    +

    Alternatively, you can right-click the selected objects, choose the Align option from the contextual menu and then use one of the available distribution options.

    +

    Note: the distribution options are disabled if you select less than three objects.

    Group objects

    -

    To group two or more selected objects or ungroup them, click the arrow next to the Group icon Group icon at the Layout tab of the top toolbar and select the necessary option from the list:

    +

    To group two or more selected objects or ungroup them, click the arrow next to the Group icon Group icon at the Layout tab of the top toolbar and select the necessary option from the list:

    • Group Group icon - to join several objects into a group so that they can be simultaneously rotated, moved, resized, aligned, arranged, copied, pasted, formatted like a single object.
    • Ungroup Ungroup icon - to ungroup the selected group of the previously joined objects.

    Alternatively, you can right-click the selected objects, choose the Arrange option from the contextual menu and then use the Group or Ungroup option.

    +

    Note: the Group option is disabled if you select less than two objects. The Ungroup option is available only when a group of the previously joined objects is selected.

    Arrange objects

    To arrange objects (i.e. to change their order when several objects overlap each other), you can use the Bring Forward icon Bring Forward and Send Backward icon Send Backward icons at the Layout tab of the top toolbar and select the necessary arrangement type from the list.

    To move the selected object(s) forward, click the arrow next to the Bring Forward icon Bring Forward icon at the Layout tab of the top toolbar and select the necessary arrangement type from the list:

    @@ -44,6 +79,7 @@
  • Send To Background Send To Background icon - to move the object(s) behind all other objects,
  • Send Backward Send Backward icon - to move the selected object(s) by one level backward as related to other objects.
  • +

    Alternatively, you can right-click the selected object(s), choose the Arrange option from the contextual menu and then use one of the available arrangement options.

    \ No newline at end of file diff --git a/apps/documenteditor/main/resources/help/en/UsageInstructions/CopyPasteUndoRedo.htm b/apps/documenteditor/main/resources/help/en/UsageInstructions/CopyPasteUndoRedo.htm index 88c53f3bf..5279b54dc 100644 --- a/apps/documenteditor/main/resources/help/en/UsageInstructions/CopyPasteUndoRedo.htm +++ b/apps/documenteditor/main/resources/help/en/UsageInstructions/CopyPasteUndoRedo.htm @@ -17,12 +17,12 @@

    Use basic clipboard operations

    To cut, copy and paste text passages and inserted objects (autoshapes, images, charts) within the current document use the corresponding options from the right-click menu or icons available at any tab of the top toolbar:

      -
    • Cut – select a text fragment or an object and use the Cut option from the right-click menu to delete the selection and send it to the computer clipboard memory. The cut data can be later inserted to another place in the same document.
    • -
    • Copy – select a text fragment or an object and use the Copy option from the right-click menu, or the Copy Copy icon icon at the top toolbar to copy the selection to the computer clipboard memory. The copied data can be later inserted to another place in the same document.
    • +
    • Cut – select a text fragment or an object and use the Cut option from the right-click menu to delete the selection and send it to the computer clipboard memory. The cut data can be later inserted to another place in the same document.
    • +
    • Copy – select a text fragment or an object and use the Copy option from the right-click menu, or the Copy Copy icon icon at the top toolbar to copy the selection to the computer clipboard memory. The copied data can be later inserted to another place in the same document.
    • Paste – find the place in your document where you need to paste the previously copied text fragment/object and use the Paste option from the right-click menu, or the Paste Paste icon icon at the top toolbar. - The text/object will be inserted at the current cursor position. The data can be previously copied from the same document.
    • + The text/object will be inserted at the current cursor position. The data can be previously copied from the same document.
    -

    To copy or paste data from/into another document or some other program use the following key combinations:

    +

    In the online version, the following key combinations are only used to copy or paste data from/into another document or some other program, in the desktop version, both the corresponding buttons/menu options and key combinations can be used for any copy/paste operations:

    • Ctrl+X key combination for cutting;
    • Ctrl+C key combination for copying;
    • @@ -43,11 +43,14 @@
    • Keep text only - allows to paste the table contents as text values separated by the tab character.

    Undo/redo your actions

    -

    To perform the undo/redo operations, use the corresponding icons available at any tab of the top toolbar or keyboard shortcuts:

    +

    To perform the undo/redo operations, use the corresponding icons in the editor header or keyboard shortcuts:

      -
    • Undo – use the Undo Undo icon icon at the top toolbar or the Ctrl+Z key combination to undo the last operation you performed.
    • -
    • Redo – use the Redo Redo icon icon at the top toolbar or the Ctrl+Y key combination to redo the last undone operation.
    • +
    • Undo – use the Undo Undo icon icon at the left part of the editor header or the Ctrl+Z key combination to undo the last operation you performed.
    • +
    • Redo – use the Redo Redo icon icon at the left part of the editor header or the Ctrl+Y key combination to redo the last undone operation.
    +

    + Note: when you co-edit a document in the Fast mode, the possibility to Redo the last undone operation is not available. +

    \ No newline at end of file diff --git a/apps/documenteditor/main/resources/help/en/UsageInstructions/CreateLists.htm b/apps/documenteditor/main/resources/help/en/UsageInstructions/CreateLists.htm index e5ca35649..44a1a40f9 100644 --- a/apps/documenteditor/main/resources/help/en/UsageInstructions/CreateLists.htm +++ b/apps/documenteditor/main/resources/help/en/UsageInstructions/CreateLists.htm @@ -28,8 +28,39 @@
  • now each time you press the Enter key at the end of the line a new ordered or unordered list item will appear. To stop that, press the Backspace key and continue with the common text paragraph.
  • -

    You can also change the text indentation in the lists and their nesting using the Multilevel list Multilevel list icon, Decrease indent Decrease indent icon, and Increase indent Increase indent icon icons at the Home tab of the top toolbar.

    +

    The program also creates numbered lists automatically when you enter digit 1 with a dot or a bracket and a space after it: 1., 1). Bulleted lists can be created automatically when you enter the -, * characters and a space after them.

    +

    You can also change the text indentation in the lists and their nesting using the Multilevel list Multilevel list icon, Decrease indent Decrease indent icon, and Increase indent Increase indent icon icons at the Home tab of the top toolbar.

    Note: the additional indentation and spacing parameters can be changed at the right sidebar and in the advanced settings window. To learn more about it, read the Change paragraph indents and Set paragraph line spacing section.

    + +

    Join and separate lists

    +

    To join a list to the preceding one:

    +
      +
    1. click the first item of the second list with the right mouse button,
    2. +
    3. use the Join to previous list option from the contextual menu.
    4. +
    +

    The lists will be joined and the numbering will continue in accordance with the first list numbering.

    + +

    To separate a list:

    +
      +
    1. click the list item where you want to begin a new list with the right mouse button,
    2. +
    3. use the Separate list option from the contextual menu.
    4. +
    +

    The list will be separated, and the numbering in the second list will begin anew.

    + +

    Change numbering

    +

    To continue sequential numbering in the second list according to the previous list numbering:

    +
      +
    1. click the first item of the second list with the right mouse button,
    2. +
    3. use the Continue numbering option from the contextual menu.
    4. +
    +

    The numbering will continue in accordance with the first list numbering.

    + +

    To set a certain numbering initial value:

    +
      +
    1. click the list item where you want to apply a new numbering value with the right mouse button,
    2. +
    3. use the Set numbering value option from the contextual menu,
    4. +
    5. in a new window that opens, set the necessary numeric value and click the OK button.
    6. +
    \ No newline at end of file diff --git a/apps/documenteditor/main/resources/help/en/UsageInstructions/DecorationStyles.htm b/apps/documenteditor/main/resources/help/en/UsageInstructions/DecorationStyles.htm index 37c15b971..bdf90b6cb 100644 --- a/apps/documenteditor/main/resources/help/en/UsageInstructions/DecorationStyles.htm +++ b/apps/documenteditor/main/resources/help/en/UsageInstructions/DecorationStyles.htm @@ -57,8 +57,10 @@
  • Subscript is used to make the text smaller and place it to the lower part of the text line, e.g. as in chemical formulas.
  • Small caps is used to make all letters lower case.
  • All caps is used to make all letters upper case.
  • -
  • Spacing is used to set the space between the characters.
  • -
  • Position is used to set the characters position in the line.
  • +
  • Spacing is used to set the space between the characters. Increase the default value to apply the Expanded spacing, or decrease the default value to apply the Condensed spacing. Use the arrow buttons or enter the necessary value in the box.
  • +
  • Position is used to set the characters position (vertical offset) in the line. Increase the default value to move characters upwards, or decrease the default value to move characters downwards. Use the arrow buttons or enter the necessary value in the box. +

    All the changes will be displayed in the preview field below.

    +
  • Paragraph Advanced Settings - Font

    diff --git a/apps/documenteditor/main/resources/help/en/UsageInstructions/FontTypeSizeColor.htm b/apps/documenteditor/main/resources/help/en/UsageInstructions/FontTypeSizeColor.htm index 869698c01..cf5e18650 100644 --- a/apps/documenteditor/main/resources/help/en/UsageInstructions/FontTypeSizeColor.htm +++ b/apps/documenteditor/main/resources/help/en/UsageInstructions/FontTypeSizeColor.htm @@ -20,12 +20,12 @@ Font Font - Is used to select one of the fonts from the list of the available ones. + Is used to select one of the fonts from the list of the available ones. If a required font is not available in the list, you can download and install it on your operating system, after that the font will be available for use in the desktop version. Font size Font size - Is used to select among the preset font size values from the dropdown list, or can be entered manually to the font size field. + Is used to select among the preset font size values from the dropdown list (the default values are: 8, 9, 10, 11, 12, 14, 16, 18, 20, 22, 24, 26, 28, 36, 48, 72 and 96). It's also possible to manually enter a custom value to the font size field and then press Enter. Increment font size diff --git a/apps/documenteditor/main/resources/help/en/UsageInstructions/InsertAutoshapes.htm b/apps/documenteditor/main/resources/help/en/UsageInstructions/InsertAutoshapes.htm index ec461e8a3..38b6b851b 100644 --- a/apps/documenteditor/main/resources/help/en/UsageInstructions/InsertAutoshapes.htm +++ b/apps/documenteditor/main/resources/help/en/UsageInstructions/InsertAutoshapes.htm @@ -45,7 +45,8 @@
  • Arrange is used to bring the selected autoshape to foreground, send to background, move forward or backward as well as group or ungroup shapes to perform operations with several of them at once. To learn more on how to arrange objects you can refer to this page.
  • Align is used to align the shape left, center, right, top, middle, bottom. To learn more on how to align objects you can refer to this page.
  • Wrapping Style is used to select a text wrapping style from the available ones - inline, square, tight, through, top and bottom, in front, behind - or edit the wrap boundary. The Edit Wrap Boundary option is available only if you select a wrapping style other than Inline. Drag wrap points to customize the boundary. To create a new wrap point, click anywhere on the red line and drag it to the necessary position. Editing Wrap Boundary
  • -
  • Shape Advanced Settings is used to open the 'Shape - Advanced Settings' window.
  • +
  • Rotate is used to rotate the shape by 90 degrees clockwise or counterclockwise as well as to flip the shape horizontally or vertically.
  • +
  • Shape Advanced Settings is used to open the 'Shape - Advanced Settings' window.

  • Some of the autoshape settings can be altered using the Shape settings tab of the right sidebar. To activate it click the shape and choose the Shape settings Shape settings icon icon on the right. Here you can change the following properties:

    @@ -102,6 +103,14 @@
  • To change the stroke type, select the necessary option from the corresponding dropdown list (a solid line is applied by default, you can change it to one of the available dashed lines).
  • +
  • Rotation is used to rotate the shape by 90 degrees clockwise or counterclockwise as well as to flip the shape horizontally or vertically. Click one of the buttons: +
      +
    • Rotate counterclockwise icon to rotate the shape by 90 degrees counterclockwise
    • +
    • Rotate clockwise icon to rotate the shape by 90 degrees clockwise
    • +
    • Flip horizontally icon to flip the shape horizontally (left to right)
    • +
    • Flip vertically icon to flip the shape vertically (upside down)
    • +
    +
  • Wrapping Style - use this section to select a text wrapping style from the available ones - inline, square, tight, through, top and bottom, in front, behind (for more information see the advanced settings description below).
  • Change Autoshape - use this section to replace the current autoshape with another one selected from the dropdown list.
  • @@ -124,6 +133,12 @@
  • If the Lock aspect ratio option is checked, the width and height will be changed together preserving the original shape aspect ratio.
  • +

    Shape - Advanced Settings

    +

    The Rotation tab contains the following parameters:

    +
      +
    • Angle - use this option to rotate the shape by an exactly specified angle. Enter the necessary value measured in degrees into the field or adjust it using the arrows on the right.
    • +
    • Flipped - check the Horizontally box to flip the shape horizontally (left to right) or check the Vertically box to flip the shape vertically (upside down).
    • +

    Shape - Advanced Settings

    The Text Wrapping tab contains the following parameters:

      @@ -165,7 +180,7 @@
    • Allow overlap controls whether two autoshapes overlap or not if you drag them near each other on the page.

    Shape - Advanced Settings

    -

    The Shape Settings tab contains the following parameters:

    +

    The Weights & Arrows tab contains the following parameters: