Commit Graph

29 Commits (a4671ba05997cf19b2d424261639280610a07fb8)

Author SHA1 Message Date
Aron Budea a4671ba059 browser: Convert MobileTopBar.js to TypeScript
Signed-off-by: Aron Budea <aron.budea@collabora.com>
Change-Id: Ibced15ed3ebec2c7a7b07539f25270b19d615a1f
2024-04-18 08:35:25 +00:00
Szymon Kłos a214088801 Convert SearchBar.js to TypeScript file
Signed-off-by: Szymon Kłos <szymon.klos@collabora.com>
Change-Id: I12dc1f0f6744d76a863ed0598185340a898a8b58
2024-04-02 15:02:53 +02:00
Hubert Figuière adbe12783f Fix warning for unocommands.py
This resolves the following Python warning.
unocommands.py:319: SyntaxWarning: invalid escape sequence '\('
  f.write('''};

Also make sure the output depends on the script

Signed-off-by: Hubert Figuière <hub@collabora.com>
Change-Id: I11f1e028c9c132f4afc66f9b5a6137b478f00774
2024-02-06 17:50:09 -05:00
Aron Budea a1a6817e4d unocommands.py: Treat JS/TS files as UTF-8
Otherwise eg. non-ASCII shortcuts appearing in files can cause
failures like this.

Traceback (most recent call last):
  File ".../rpmbuild/BUILD/coolwsd-23.05.2.2snapshot/scripts/unocommands.py", line 454, in <module>
    toolbarCommands = extractToolbarCommands(onlineDir)
  File ".../rpmbuild/BUILD/coolwsd-23.05.2.2snapshot/scripts/unocommands.py", line 163, in extractToolbarCommands
    for line in f:
  File "/usr/lib64/python3.6/encodings/ascii.py", line 26, in decode
    return codecs.ascii_decode(input, self.errors)[0]

Encountered after 1a2500c8d3.

This is not ASCII in browser/src/control/Control.NotebookbarWriter.js:
`'accessibility': { focusBack: true,     combination: 'AI',      de: 'ÖI' }

Signed-off-by: Aron Budea <aron.budea@collabora.com>
Change-Id: I72aac2809530c14b9440f73e5072db17770f438a
2023-08-17 11:55:34 +02:00
Dennis Francis 8e05061f9b browser: convert calc header controls to TS
Control.Header.js -> Control.Header.ts
Control.ColumnHeader.js -> Control.ColumnHeader.ts
Control.RowHeader.js -> Control.RowHeader.ts
Control.CornerHeader.js -> Control.CornerHeader.ts

Signed-off-by: Dennis Francis <dennis.francis@collabora.com>
Change-Id: Ib0f111cf715171d91660c0672b2473df89f83b0d
2023-01-18 16:45:02 +05:30
Henry Castro 5864481c13 scripts: rename loleaflet -> browser
Change-Id: I108162981aa66a804a855a18f45f7369c20edfe0
Signed-off-by: Henry Castro <hcastro@collabora.com>
2021-11-10 17:18:56 +01:00
Andras Timar 335d41587c Updated UNO command translations (co-2021)
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: I4bd4bc7eae097c5b2b1bccdfebe191c4f595de9e
2021-04-18 11:18:34 +02:00
Szymon Kłos a47773954f Update unocommands for Control.NotebookbarDraw.js
Change-Id: I575fc13e4db5860bdeca7093bbc64c85b15a63cb
Signed-off-by: Szymon Kłos <szymon.klos@collabora.com>
2021-03-01 13:58:14 +03:00
Szymon Kłos ac0b14ea81 update unocommands script: don't replace characters
use original names as it is required for pulling translations

Change-Id: I0b679d0802afcfacc7db8cb56a08254749811bc1
Signed-off-by: Szymon Kłos <szymon.klos@collabora.com>
2021-02-18 09:16:35 +01:00
umutbayramoglu d08fda9749 Remove unused variables
Signed-off-by: umutbayramoglu <umut265@gmail.com>
Change-Id: I7c2565a01605846201cb4a35564eb52b52491fe8
2021-02-11 02:10:34 +03:00
Szymon Kłos 3919d19b5d Support special characters in uno translations
Some uno commands have '.' or '-' in the name.
eg. .uno:FontworkShapeType.fontwork-inflate

Change-Id: I027aa3b6302280101c0f7cb51ef9809d023ea91d
Signed-off-by: Szymon Kłos <szymon.klos@collabora.com>
2021-02-05 14:27:54 +01:00
Szymon Kłos 3d0000c09a Check for _UNO also in MobileWizardBuilder
Change-Id: I3ab70770a79acc1c4e107b83474fdd96c7ffa3ec
Signed-off-by: Szymon Kłos <szymon.klos@collabora.com>
2021-02-05 14:27:54 +01:00
Andras Timar 9c10822f7d _UNO() takes precedence, it will become the actual label
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: I0e25ebc289179f80eb4231c218feb9af554ec334
2021-01-06 13:54:01 +01:00
Mücahid Aydin e9ea83efa5 pep8 coding style conformance for scripts/unocommands.py
Change-Id: Ic395a0692a808bc8519a05baf9cdd669d94a0fc4
2020-10-15 12:44:54 +03:00
Andras Timar 0002fdfd6c fix license headers
Change-Id: I8623770b32d278a45357dc7f757fabfadd2b4af7
2020-10-01 11:56:43 +02:00
Tor Lillqvist 728d56aa05 Don't use just the basename in the usage help message
That is counter-productive. Use the command name as used by the user
to run the script.

Change-Id: I11b082375db8d8184543cead912cbc556f3695e2
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/102041
Tested-by: Jenkins
Reviewed-by: Tor Lillqvist <tml@collabora.com>
2020-09-04 12:46:42 +02:00
Szymon Kłos 9dd57f8fe1 notebookbar: customize Insert tab in Writer
Change-Id: I531854b4c7361fe5802a64016886feab5cda8979
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/100177
Tested-by: Jenkins
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Szymon Kłos <szymon.klos@collabora.com>
2020-08-06 08:16:19 +02:00
Andras Timar 000c5a9b41 Add more source files to scripts/unocommands.py
Change-Id: I395f1fdd761f94018c75fa5bf48d64aff0335c27
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/96940
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Tested-by: Jenkins
Reviewed-by: Andras Timar <andras.timar@collabora.com>
2020-06-24 09:08:25 +02:00
Tamás Zolnai 7041d5c5b0 Update conext menu code to handle Spelling Popup
* Use unique IDs for sub menus.
* Handle uno command's parameter.
* When there is any parameter, we use the menu text.
* Avoid to enable FontDialog on other conext menus
* Introduce the command ".uno:None" to indicate that the
menu item can't be executed.
* Whitelisted spelling context menu's uno commands.
* Add a black list in unocommands.py to list those uno
commands which have no text in xcu file. In this case,
we can use the text sent in the menu structure.

Change-Id: Ie84fcb7d6c7a2f4cd50c666dbcd8c77cf42731de
Reviewed-on: https://gerrit.libreoffice.org/83606
Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com>
Tested-by: Tamás Zolnai <tamas.zolnai@collabora.com>
2019-11-24 14:12:30 +01:00
Michael Weghorn c1e04e4069 scripts/unocommands.py: Switch to python3
Files not explicitly opened in binary mode are text files and thus
expect a 'str' arg for their write() method.

Python 2 is nearing its EOL and e.g. Debian has already
removed the python2-based 'python-polib' package previously
used here from its testing distribution.

I checked that running the commands

    ./scripts/unocommands.py --update . ../libreoffice
    ./scripts/unocommands.py --translate . ../libreoffice/translations
    ./scripts/unocommands.py --check .

still yields the same results as previously.

Change-Id: I39e1785d3c78416009420dd4c2be58bd1c3647c3
Reviewed-on: https://gerrit.libreoffice.org/81422
Reviewed-by: Michael Stahl <michael.stahl@cib.de>
Tested-by: Michael Stahl <michael.stahl@cib.de>
2019-10-24 14:07:47 +02:00
George 360d5a0956 added server uptime field to admin console
Change-Id: Id23fee1299b87095f186ce7aaa8c2d2e0f3cef52
Signed-off-by: Michael Meeks <michael.meeks@collabora.com>
2019-07-19 21:14:01 +01:00
Henry Castro 59306e2f4c loleaflet: rename toolbar.js to Control.Toolbar.js
Change-Id: Ia8d0c3856ea40b4e342e5bec94c558c78464943f
2019-03-30 16:22:32 -04:00
Henry Castro c1ba96f951 loleaflet: move toolbar.js to src/control directory
Simplify building loleaflet.

TODO. Convert to L.Control.Toolbar

Change-Id: I6abedd19caa6f0c22267c661e67480507dcd8336
2019-03-11 14:51:56 -04:00
Andras Timar 92f3d62882 escape double quotes when generating json files from po files
Change-Id: Iacddaf919161b6843dac2190a5072af8a25e8251
Reviewed-on: https://gerrit.libreoffice.org/63218
Reviewed-by: Andras Timar <andras.timar@collabora.com>
Tested-by: Andras Timar <andras.timar@collabora.com>
2018-11-09 21:59:50 +01:00
Andras Timar e444e3f197 adapth path to new source layout
Change-Id: I5cec0534119fce64bf9409a1f8fd382c259bbb95
2018-10-21 20:37:28 +02:00
Andras Timar 3719faf5e9 loleaflet: remove latin access keys in parentheses (in case of CJK, Indian, etc. langs)
Change-Id: I15763165535771511a4871882dd067fc689baaa3
2018-07-16 09:04:05 +02:00
Andras Timar d239a3b373 adjust paths of toolbar.js and unocommands.js
Change-Id: I0373f1a05d18a85d5e351fd11bf3b81c43367279
2018-07-16 09:04:05 +02:00
Henry Castro 8618885b31 use Makefile to build loleaflet
Concatenate and minify all javascript files in the release build but not
in the debug build. Also, it is enabled to use a build directory

Change-Id: Ia120447a827cfe236241ddf188bf43a088f877a7
Reviewed-on: https://gerrit.libreoffice.org/52802
Reviewed-by: pranavk <pranavk@collabora.co.uk>
Tested-by: pranavk <pranavk@collabora.co.uk>
2018-05-10 20:30:16 +02:00
Jan Holesovsky 1f1a76e5ef l10n: use translations of .uno: commands from LibreOffice
This is a combination of 22 commits.

l10n: New script for collecting the used .uno: commands.

Change-Id: I9c6f3f03a4042f8e5ba1f258ce468fc0f4abd169
Reviewed-on: https://gerrit.libreoffice.org/45981
Reviewed-by: Andras Timar <andras.timar@collabora.com>
Tested-by: Andras Timar <andras.timar@collabora.com>
(cherry picked from commit 99161841dc)

l10n: Don't repeat the strings in the menu definition, use the uno commands.

Change-Id: If8ccd753cd88056c64c10e3f9f7b951208fafdb8
Reviewed-on: https://gerrit.libreoffice.org/45983
Reviewed-by: Andras Timar <andras.timar@collabora.com>
Tested-by: Andras Timar <andras.timar@collabora.com>
(cherry picked from commit 5b87f2fca5)

l10n: "type: 'unocommand'" is implicit when there is "uno:" in the item.

Change-Id: I2fe50e4860848920f551cc6a3fda5ebe5f49b3f2
Reviewed-on: https://gerrit.libreoffice.org/46011
Reviewed-by: Andras Timar <andras.timar@collabora.com>
Tested-by: Andras Timar <andras.timar@collabora.com>
(cherry picked from commit d38664c023)

l10n: Fix mis-typed .uno: commands.

Change-Id: Ia2d695d584d48b92def364c3936655909aabd076
Reviewed-on: https://gerrit.libreoffice.org/46012
Reviewed-by: Andras Timar <andras.timar@collabora.com>
Tested-by: Andras Timar <andras.timar@collabora.com>
(cherry picked from commit e68789ac2c)

l10n: Don't extract uno: when name: is provided for that entry.

Change-Id: I85619915cf66a71c7ab982c2949390bd82df9abb
Reviewed-on: https://gerrit.libreoffice.org/46013
Reviewed-by: Andras Timar <andras.timar@collabora.com>
Tested-by: Andras Timar <andras.timar@collabora.com>
(cherry picked from commit 293c5d4508)

l10n: Implement --check to notice not covered .uno: commands early.

Change-Id: I928f2cef8d9a869c10fa6c6370a7ce1c811631c8
Reviewed-on: https://gerrit.libreoffice.org/46014
Reviewed-by: Andras Timar <andras.timar@collabora.com>
Tested-by: Andras Timar <andras.timar@collabora.com>
(cherry picked from commit 457f929357)

l10n: Further decrease the use of own Online strings...

...if those can be deducted from .uno: commands.

Change-Id: I9c2459a12ee95e936a7ec37f6270012d811cdf86
Reviewed-on: https://gerrit.libreoffice.org/46018
Reviewed-by: Andras Timar <andras.timar@collabora.com>
Tested-by: Andras Timar <andras.timar@collabora.com>
(cherry picked from commit 70ecee2bb6)

l10n: Let's avoid redirect, and write the unocommands.js directly.

Change-Id: Ifda0de27881ba415ff062368483524080dce5189
Reviewed-on: https://gerrit.libreoffice.org/46020
Reviewed-by: Andras Timar <andras.timar@collabora.com>
Tested-by: Andras Timar <andras.timar@collabora.com>
(cherry picked from commit b6fa6f376c)

l10n: Generate translations of the .uno: commands + update the current ones.

Change-Id: I77377412e4776a830f15973a35b83e8eca299f05
Reviewed-on: https://gerrit.libreoffice.org/46047
Reviewed-by: Andras Timar <andras.timar@collabora.com>
Tested-by: Andras Timar <andras.timar@collabora.com>
(cherry picked from commit b2bfb2349e)

l10n: Translate also the right-click menu .uno: commands.

Change-Id: Ie5cedaaa10febe78ba319f9e9b03fdd44c94f468
Reviewed-on: https://gerrit.libreoffice.org/46048
Reviewed-by: Andras Timar <andras.timar@collabora.com>
Tested-by: Andras Timar <andras.timar@collabora.com>
(cherry picked from commit 861c252d52)

l10n: len(sys.argv) is 1, when the command is invoked without options

Change-Id: Ie9a47955e9a031ee0484c0703f67bad7077bbd76
Reviewed-on: https://gerrit.libreoffice.org/46078
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
(cherry picked from commit f096cf3397)

l10n: remove obsolete unocommandsl10n.sh

Change-Id: I4e9945407aff4a4fa1444079f8ecec1782a71c9c
Reviewed-on: https://gerrit.libreoffice.org/46079
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
(cherry picked from commit 4f0d5d7a24)

l10n: Make sure to distinct between apps + between main menu and context menu.

The strings can differ considerably, making some menu entries not
understandable at all.

Change-Id: I36ffa8b01df119a7655a711ec859391af16836c9
Reviewed-on: https://gerrit.libreoffice.org/46097
Reviewed-by: Andras Timar <andras.timar@collabora.com>
Tested-by: Andras Timar <andras.timar@collabora.com>
(cherry picked from commit 53d9593edb)

l10n: Fix the Table menu in Impress.

Change-Id: I2cb8b98ecc1a18174b26dfaa9c96ad3829ff5989
Reviewed-on: https://gerrit.libreoffice.org/46099
Reviewed-by: Andras Timar <andras.timar@collabora.com>
Tested-by: Andras Timar <andras.timar@collabora.com>
(cherry picked from commit be100fe06a)

l10n: first check for 'lang', then require unocommands

Change-Id: Ib8f94bbdd163a89bef4886d68816628e124e9ef8
(cherry picked from commit d94a53a0e3)

l10n: get Language menu translations for free

Change-Id: I8b5628457cf713d8fdb0d4de6935b7e1d54ad093
Reviewed-on: https://gerrit.libreoffice.org/46158
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
(cherry picked from commit 53b8a60d5d)

l10n: Calc and Impress should use _UNO('.uno:LanguageMenu') too.

Change-Id: I987821d9d9b0f40baea1879d28177e8e0c58a3a3
Reviewed-on: https://gerrit.libreoffice.org/46418
Reviewed-by: Andras Timar <andras.timar@collabora.com>
Tested-by: Andras Timar <andras.timar@collabora.com>
(cherry picked from commit ba61ec9da2)

l10n: Calc row, column and sheet tab context menu translations from LibreOffice

Change-Id: I1f566a71e5fdc66304e82bc2bcfb0f9ced2f5d2a
Reviewed-on: https://gerrit.libreoffice.org/46430
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
(cherry picked from commit e8847b9ef1)

l10n: Some toolbar button tooltip translations from LibreOffice

Change-Id: I4a8d050c7ae8efc7d1932f16dc35455f1a182d8a
Reviewed-on: https://gerrit.libreoffice.org/46444
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
(cherry picked from commit d51a760957)

l10n: localize 'Undo' and 'Redo' labels on Document Repair dialog

Change-Id: Ibd4236f85a6db92b7d6456f6f22115b35079da83
Reviewed-on: https://gerrit.libreoffice.org/47252
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
(cherry picked from commit f8bf2c2860)

l10n: 5 more toolbar strings from LO core

Change-Id: I398a0d7c28a8295c3b8e5077903b5fa7d3d5c45c
Reviewed-on: https://gerrit.libreoffice.org/47310
Reviewed-by: Andras Timar <andras.timar@collabora.com>
Tested-by: Andras Timar <andras.timar@collabora.com>
2018-01-03 14:57:08 +01:00