From 6eaab69d3c336edc2e6c9eec2aa2f63837fb3526 Mon Sep 17 00:00:00 2001 From: Julia Radzhabova Date: Wed, 6 Mar 2019 11:16:21 +0300 Subject: [PATCH] [DE] Add translation for formula errors --- .../main/app/controller/Main.js | 66 ++++++++++++------- apps/documenteditor/main/locale/en.json | 11 ++++ 2 files changed, 55 insertions(+), 22 deletions(-) diff --git a/apps/documenteditor/main/app/controller/Main.js b/apps/documenteditor/main/app/controller/Main.js index e516475a2..c037839a9 100644 --- a/apps/documenteditor/main/app/controller/Main.js +++ b/apps/documenteditor/main/app/controller/Main.js @@ -130,27 +130,38 @@ define([ var styleNames = ['Normal', 'No Spacing', 'Heading 1', 'Heading 2', 'Heading 3', 'Heading 4', 'Heading 5', 'Heading 6', 'Heading 7', 'Heading 8', 'Heading 9', 'Title', 'Subtitle', 'Quote', 'Intense Quote', 'List Paragraph', 'footnote text'], - translate = { - 'Series': this.txtSeries, - 'Diagram Title': this.txtDiagramTitle, - 'X Axis': this.txtXAxis, - 'Y Axis': this.txtYAxis, - 'Your text here': this.txtArt, - "Error! Bookmark not defined.": this.txtBookmarkError, - "above": this.txtAbove, - "below": this.txtBelow, - "on page ": this.txtOnPage, - "Header": this.txtHeader, - "Footer": this.txtFooter, - " -Section ": this.txtSection, - "First Page ": this.txtFirstPage, - "Even Page ": this.txtEvenPage, - "Odd Page ": this.txtOddPage, - "Same as Previous": this.txtSameAsPrev, - "Current Document": this.txtCurrentDocument, - "No table of contents entries found.": this.txtNoTableOfContents, - "Table of Contents": this.txtTableOfContents - }; + translate = { + 'Series': this.txtSeries, + 'Diagram Title': this.txtDiagramTitle, + 'X Axis': this.txtXAxis, + 'Y Axis': this.txtYAxis, + 'Your text here': this.txtArt, + "Error! Bookmark not defined.": this.txtBookmarkError, + "above": this.txtAbove, + "below": this.txtBelow, + "on page ": this.txtOnPage, + "Header": this.txtHeader, + "Footer": this.txtFooter, + " -Section ": this.txtSection, + "First Page ": this.txtFirstPage, + "Even Page ": this.txtEvenPage, + "Odd Page ": this.txtOddPage, + "Same as Previous": this.txtSameAsPrev, + "Current Document": this.txtCurrentDocument, + "No table of contents entries found.": this.txtNoTableOfContents, + "Table of Contents": this.txtTableOfContents, + "Syntax Error": this.txtSyntaxError, + "Missing Operator": this.txtMissOperator, + "Missing Argument": this.txtMissArg, + "Number Too Large To Format": this.txtTooLarge, + "Zero Divide": this.txtZeroDivide, + "Is Not In Table": this.txtNotInTable, + "Index Too Large": this.txtIndTooLarge, + "The Formula Not In Table": this.txtFormulaNotInTable, + "Table Index Cannot be Zero": this.txtTableInd, + "Undefined Bookmark": this.txtUndefBookmark, + "Unexpected End of Formula": this.txtEndOfFormula + }; styleNames.forEach(function(item){ translate[item] = me.translationTable[item] = me['txtStyle_' + item.replace(/ /g, '_')] || item; }); @@ -2525,7 +2536,18 @@ define([ txtShape_curvedConnector3WithTwoArrows: 'Curved Double-Arrow Connector', txtShape_spline: 'Curve', txtShape_polyline1: 'Scribble', - txtShape_polyline2: 'Freeform' + txtShape_polyline2: 'Freeform', + txtSyntaxError: 'Syntax Error', + txtMissOperator: 'Missing Operator', + txtMissArg: 'Missing Argument', + txtTooLarge: 'Number Too Large To Format', + txtZeroDivide: 'Zero Divide', + txtNotInTable: 'Is Not In Table', + txtIndTooLarge: 'Index Too Large', + txtFormulaNotInTable: 'The Formula Not In Table', + txtTableInd: 'Table Index Cannot be Zero', + txtUndefBookmark: 'Undefined Bookmark', + txtEndOfFormula: 'Unexpected End of Formula' } })(), DE.Controllers.Main || {})) }); \ No newline at end of file diff --git a/apps/documenteditor/main/locale/en.json b/apps/documenteditor/main/locale/en.json index 18e40edad..cd21b38af 100644 --- a/apps/documenteditor/main/locale/en.json +++ b/apps/documenteditor/main/locale/en.json @@ -643,6 +643,17 @@ "DE.Controllers.Main.warnNoLicense": "This version of ONLYOFFICE Editors has certain limitations for concurrent connections to the document server.
If you need more please consider purchasing a commercial license.", "DE.Controllers.Main.warnNoLicenseUsers": "This version of ONLYOFFICE Editors has certain limitations for concurrent users.
If you need more please consider purchasing a commercial license.", "DE.Controllers.Main.warnProcessRightsChange": "You have been denied the right to edit the file.", + "DE.Controllers.Main.txtSyntaxError": "Syntax Error", + "DE.Controllers.Main.txtMissOperator": "Missing Operator", + "DE.Controllers.Main.txtMissArg": "Missing Argument", + "DE.Controllers.Main.txtTooLarge": "Number Too Large To Format", + "DE.Controllers.Main.txtZeroDivide": "Zero Divide", + "DE.Controllers.Main.txtNotInTable": "Is Not In Table", + "DE.Controllers.Main.txtIndTooLarge": "Index Too Large", + "DE.Controllers.Main.txtFormulaNotInTable": "The Formula Not In Table", + "DE.Controllers.Main.txtTableInd": "Table Index Cannot be Zero", + "DE.Controllers.Main.txtUndefBookmark": "Undefined Bookmark", + "DE.Controllers.Main.txtEndOfFormula": "Unexpected End of Formula", "DE.Controllers.Navigation.txtBeginning": "Beginning of document", "DE.Controllers.Navigation.txtGotoBeginning": "Go to the beginning of the document", "DE.Controllers.Statusbar.textHasChanges": "New changes have been tracked",