Commit Graph
186 Commits
Author SHA1 Message Date
Balazs Varga 0467a68ff9 tdf#78486 sc: add calculated field dialog for pivot tables
New dialog (Insert > Calculated Field) to add, modify, and delete
calculated fields. Accessible from the menu bar, pivot table context
menu. Insert, modify, delete a calculated field properly.

TODO: maybe more warnings during formula entry edit

Change-Id: Ifdf50de96ff6f7b736b6307e9bea3ae56108679f
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/200314
Tested-by: Jenkins
Reviewed-by: Balazs Varga <balazs.varga@collabora.com>
2026-03-13 08:06:56 +01:00
Michael Weghorn 75ec5ccd93 wasm: Add .ui file for hyperlink dialog
Since

    commit 1c6eb5324d
    Date:   Sun Dec 7 18:46:28 2025 +0000

        tdf#147630 Transform Hyperlink dialog into a standard SfxTabDialog

had introduced cui/uiconfig/ui/hyperlinkdlg.ui for the new
.ui file to be used for the hyperlink dialog
instead of cui/uiconfig/ui/hyperlinkdialog.ui, add
that .ui file to the list of .ui files to include in the
wasm/emscripten file system image.

This makes the dialog show up for a wasm build
when using "Insert" -> "Hyperlink" in Writer,
instead of triggering a crash/abort.

Change-Id: I589433b4aa22c52b2c6b94cf45933eea6683df20
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/201359
Tested-by: Jenkins
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
2026-03-11 04:32:56 +01:00
Michael Weghorn 08a4f2734b cui: Remove unused hyperlinkdialog.ui
It's unused now after

    commit 1c6eb5324d
    Date:   Sun Dec 7 18:46:28 2025 +0000

        tdf#147630 Transform Hyperlink dialog into a standard SfxTabDialog

which instead added the new cui/uiconfig/ui/hyperlinkdlg.ui

Previous commit

    Change-Id: I42b2ca3facde4b0338d0e897a06a68c8cb7323f5
    Author: Michael Weghorn <m.weghorn@posteo.de>
    Date:   Tue Mar 10 10:51:44 2026 +0100

        Don't rely on icons in otherwise unused hyperlinkdialog.ui

also dropped the need to keep the file just to make
the tab icons still available.

Change-Id: If96053d4b242f8ddb6737a6ef128e42fb64d3d57
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/201352
Tested-by: Jenkins
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
2026-03-11 04:32:49 +01:00
Aditya Lohuni 6af6d599d6 static: fix typos in README.wasm.md
Fix various typos and grammatical errors in the WASM documentation.
Corrections include:
- "dlload" -> "dlopen"
- "is build" -> "is built"
- "know problems" -> "known problems"
- and other minor grammar fixes.

Change-Id: I25bc660593273df256d1fc6ae07d52f225a232bf
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/196272
Reviewed-by: Adolfo Jayme Barrientos <fitojb@ubuntu.com>
Tested-by: Jenkins
Tested-by: Adolfo Jayme Barrientos <fitojb@ubuntu.com>
2026-02-08 13:20:11 +01:00
Balazs Varga 0d7be893f5 Table Style: introduce insert/delete Table... command available from
menubar Insert and Data. With that command a new Table Style area (context) can be
added to the sheet with a defalt table style name (Table1, Table2 etc.).
If the default ooxml table styles are available the "TableStyleMedium2"
style will be automatically applied (same as in Mso), which can be modified
to any other available style after that.

Also add new command for delete a table context. It is also available
from Insert and Data menubar.

For simplifying the dbrange behaviour, it will not possible to change DbRange
properties of those DbRanges which has Table context. (same as in MSO)
from the older DbRange dialog

Includes cleanup for unused-but-set variables (-Werror).

Change-Id: I98067e895d9595ba07206759deff6848dc299216
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/194408
Tested-by: Balazs Varga <balazs.varga@collabora.com>
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Balazs Varga <balazs.varga@collabora.com>
Code-Style: Balazs Varga <balazs.varga@collabora.com>
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/196768
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/197994
Tested-by: Jenkins
2026-01-29 09:32:11 +01:00
Balazs Varga aac69b44a3 Table style: add the missing .ui files to jsdialog and wasm
Add new .ui file to jsdialog and wasm

Change-Id: Ifd7b0654eff398639e46f69830002ebb85d52394
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/193687
Reviewed-by: Andras Timar <andras.timar@collabora.com>
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/196755
Reviewed-by: Balazs Varga <balazs.varga@collabora.com>
Tested-by: Balazs Varga <balazs.varga@collabora.com>
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/197981
2026-01-29 09:29:31 +01:00
Caolán McNamara dead7810f8 sw/uiconfig/swriter/ui/charurlpage.ui isn't used anymore
since:

commit 63315d6012
Date:   Tue Apr 23 17:20:47 2024 +0200

    Resolves tdf#132253 - Remove hyperlink tab from character dialog

Change-Id: I35d5e1af6dc7cdb1ea8661ea5661bf183becc0ef
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/195474
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2025-12-12 09:23:24 +01:00
Ilmari Lauhakangas 3a855b3802 tdf#169649 Fix typo in static/README.wasm.md
Change-Id: I1304b0a3567a6a8a213bc163eb05c50b37f94d78
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/195267
Reviewed-by: Ilmari Lauhakangas <ilmari.lauhakangas@libreoffice.org>
Tested-by: Jenkins
2025-12-09 09:25:59 +01:00
Stephan Bergmann 77ed394924 Bump the Emscripten build to emsdk 4.0.10
...as building against emsdk 3.1.46 now started to fail with

> /home/tdf/lode/jenkins/workspace/lo_gerrit/tb/src_wasm/svx/source/svdraw/svdmrkv.cxx:1231:78: error: no member named 'view' in 'std::stringstream'
>  1231 |                 handleArrayStr = OString::Concat(", \"handles\":") + aStream.view();
>       |                                                                      ~~~~~~~ ^
> /home/tdf/lode/jenkins/workspace/lo_gerrit/tb/src_wasm/svx/source/svdraw/svdmrkv.cxx:1236:86: error: no member named 'view' in 'std::stringstream'
>  1236 |                     handleArrayStr += OString::Concat(", \"GluePoints\":") + aStream.view();
>       |                                                                              ~~~~~~~ ^

(<https://ci.libreoffice.org//job/lo_daily_tb_linux_wasm/1251/>) after
47da2ff20e "Avoid some std::string creation".

So just bump to the most recent emsdk version that works out of the box.
Anything newer than emsdk 4.0.10 (like the current emsdk 4.0.20) would currently
fail for us with the issue described at
<https://gerrit.libreoffice.org/c/core/+/188465> "Emscripten: Adapt to internal
emscripten/val.h change in Emscripten 4.0.11", though, so stick with emsdk
4.0.10 for now.

Change-Id: I540569e43454c222424895b1e552b8b07d1d5066
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/194331
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <stephan.bergmann@collabora.com>
2025-11-22 11:11:21 +01:00
NickWingate 20088bd544 Detach QuickFindPanel
Main changes are:
1) new jsontype: `quickfind`
2) send the full json when constructed
3) create new .uno:QuickFind
4) create wrapper and window to register
   QuickFindPanel as a DockingWindow so that we
   can create it from CreateChildWinow without
   going through sidebar
5) Register SID_QUICKFIND as a ChildWindow in
   the SwView interface

Signed-off-by: NickWingate <nick.wingate@collabora.com>
Change-Id: I2086316b932c1495b0adee7a062bdbbcb104f1ee
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/188667
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Szymon Kłos <szymon.klos@collabora.com>
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/194144
Tested-by: Jenkins
2025-11-18 10:46:42 +01:00
Stephan Bergmann 6647890535 Emscripten: Missing include
...after fd2e467ba3 "tdf#146619 Run IWYU in fw
decl mode on include/[a-c]*"

Change-Id: I73003f176f13cff87dca28d0feb77986448dd6ac
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/193942
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <stephan.bergmann@collabora.com>
2025-11-13 13:06:18 +01:00
Irgaliev Amin 4520c70fa4 tdf#79356 - Adding connector support for Writer.
Currently, the connector functionality in Writer is only available after copying such lines from Draw.
This patch adds connector functionality directly to Writer.

This functionality is available in:
1.  "Insert" -> "Shape" -> "Connectors" in Standart Toolbar (UI variants)
2.  "Insert" -> "Connectors" in Tabbed (UI variants)

Change-Id: I51b517f160a69248458100ebe4fb97695bbfe1d7
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/189911
Tested-by: Jenkins
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2025-09-17 09:00:59 +02:00
Irgaliev Amin 34e6b6a7c1 tdf#79356 - Adding connector support for Calc.
Currently, the connector functionality in Calc is only available after copying such lines from Draw.
This patch adds connector functionality directly to Calc.

This functionality is available in:
1.  "Insert" -> "Shape" -> "Connectors" in Standart Toolbar (UI variants)
2.  "Insert" -> "Connectors" in Tabbed (UI variants)

Change-Id: Icae023bf123e867dbef152789d1a015ea0dfe52d
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/189266
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
Tested-by: Jenkins
2025-08-19 10:22:28 +02:00
Stephan Bergmann 0ac30d2afd embindmaker-generated files should first include sal/config.h, by convention
Change-Id: I9e4d843c85d45171c238e3c25c968cb5241eb82d
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/188575
Reviewed-by: Stephan Bergmann <stephan.bergmann@collabora.com>
Tested-by: Jenkins
2025-07-30 12:20:25 +02:00
Stephan Bergmann 271343a4ba Emscripten: Use unique_ptr for any and sequence values returned from JS to C++
...improving the code introduced in 04658a7067
"Embind: Fix lifecycle of UNO any and sequence values returned from JS to C++"
and 4b80b643c1 "Embind: Add the lifecylce fix also
for attribute getter return value" (and which had started to cause compilation
failures with Emscripten 4.0.11, see
<https://github.com/emscripten-core/emscripten/issues/24801> "'[emval] Prevent
creating lvalue refs from thin air (#24606)' breaks existing code")

Change-Id: I1af74be31bfde2e5fa09c1690e23a4c9cc941bc3
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/188560
Reviewed-by: Stephan Bergmann <stephan.bergmann@collabora.com>
Tested-by: Jenkins
2025-07-30 07:51:01 +02:00
Michael Weghorn d925df3929 tdf#130857 weld: Drop unused weld::MenuToggleButton
It was introduced specifically for the Start
Center in

    commit fb3c3b2861
    Author: Caolán McNamara <caolanm@redhat.com>
    Date:   Mon Oct 19 09:35:00 2020 +0100

        add MenuToggleButton for split toggle/menu button

        which is uniquely used in the start center

but is no longer used there since

    commit 164a1f4c33
    Author: Heiko Tietze <tietze.heiko@gmail.com>
    Date:   Fri Sep 9 16:07:28 2022 +0200

        Resolves tdf#80934 - GUI means to filter thumbnails in start center

For use within toolbars, there's GtkMenuToolButton [1]
which seems to provide a similar logic (one button
to toggle, and another small one with an arrow to
open the menu) without having to implement so much
custom logic for the GTK implementation.

[1] https://docs.gtk.org/gtk3/class.MenuToolButton.html

Change-Id: I356c50f95da300a82965710010b41dea7dba6325
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/188393
Tested-by: Jenkins
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
2025-07-29 10:01:05 +02:00
Heiko Tietze 043b186d10 Related tdf#158880 - [API CHANGE] Rename ToolbarModeDialog to UIPicker
The scope of this dialog has changed with 98d1ac254bd62dff9d0aa9c72ba879d1d52495ef
and it's not just an UI for the ToolbarMode namespace

* Toolbarmodedlg* renamed to UIPIckerdlg*
* UNO command ToolbarModeUI renamed to UIPicker
* SID_TOOLBAR_MODE_UI renamed to SID_UI_PICKER

Change-Id: Id4d617aeee83ae1800d4b9a2d207d28c391dcdb4
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/185789
Tested-by: Jenkins
Reviewed-by: Heiko Tietze <heiko.tietze@documentfoundation.org>
2025-05-28 14:48:35 +02:00
Marco Cecchetti e85be68352 chart color palette for data series: sidebar panel
Change-Id: I6f661515e2de11ea1ead0b79435413d6a0e81c9d
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/184264
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/185142
Tested-by: Jenkins
2025-05-13 14:29:46 +02:00
Stephan Bergmann fae15203e8 Emscripten: Provide Module.script
...which is useful for some downstream scripts

Change-Id: Ibf9d336fb4ad018dcaa5ed460cac1e8e5030ab50
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/184334
Reviewed-by: Stephan Bergmann <stephan.bergmann@allotropia.de>
Tested-by: Jenkins
2025-04-17 19:49:21 +02:00
Balazs Varga 557941fda4 Add unique accelerators config file for wasm builds
Remove/disable hotkeys which brings up certain dialogs - and sometimes these dialogs loses the focus and they disappear but still keep the document waiting for them to close - for wasm app with wasm-accelerators.xcu

TODO for later: better solution would be to have the props that are removed here rather be install:module="..."-conditional in officecfg/registry/data/org/openoffice/Office/Accelerators.xcu
See details: https://gerrit.libreoffice.org/c/core/+/183389/comment/064afee4_47e66b62/

Change-Id: Ia44390fd7682327feb56e944d30a9fd7ff4cbd82
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/183389
Tested-by: Jenkins
Reviewed-by: Balazs Varga <balazs.varga.extern@allotropia.de>
2025-03-28 16:56:29 +01:00
Ilmari Lauhakangas 14f8c60896 static/README.wasm.md: tweak code blocks for consistency
Change-Id: I1f98d8477f9e19fddaca13953a674bfd470c2256
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/183413
Tested-by: Jenkins
Tested-by: Ilmari Lauhakangas <ilmari.lauhakangas@libreoffice.org>
Reviewed-by: Ilmari Lauhakangas <ilmari.lauhakangas@libreoffice.org>
2025-03-27 21:15:20 +01:00
Moritz Duge 3918e3e22e WASM clarified --with-wasm-module
Option is for WASM only, so shouldn't be named --with-main-module.

Also the option's default value changed since it was introduced, so the
documentation became outdated. See commits:

fe678ffc6f Emscripten: No need to pass --with-main-module into build configure
437b4d802c Fix default value of Emscripten --with-main-module
8aef8c3a14 Make it possible to run either Writer or Calc in the same Emscripten thing
97ee126d69 WASM add Calc as optional build result, make it build & run

Change-Id: I29aeeb9a840ec07e46cbf153c535b3fca9d88cd1
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/182798
Tested-by: Jenkins
Reviewed-by: Moritz Duge <moritz.duge@allotropia.de>
2025-03-12 18:37:20 +01:00
Moritz Duge 3cf71eec36 WASM enable Impress for WASM builds
Change-Id: Ib0e8f073f9fb74bd0fd3b00e8f31f620f8aa9f39
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/182750
Tested-by: Jenkins
Reviewed-by: Moritz Duge <moritz.duge@allotropia.de>
2025-03-12 17:37:50 +01:00
Stephan Bergmann 12ed25fb94 Support Emscripten --with-main-module=
...i.e., stripping both Calc and Writer, which comes in handy when trying e.g.
-fsanitize=address and the resulting binary would otherwise become too large.

(Which also unearthed that the StartModule/menubar/menubar.xml had erroneously
been added to the Writer section of static/CustomTarget_emscripten_fs_image.mk
ever since 88b94aafc2 "WASM create and link the
Emscripten FS image".)

Change-Id: Ia880040f51f15d33ed447a1c69838fa807f48ade
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/181188
Reviewed-by: Stephan Bergmann <stephan.bergmann@allotropia.de>
Tested-by: Jenkins
2025-02-05 20:31:58 +01:00
Heiko Tietze 7f4901ded7 More appealing design for alientformat warn dialog
Change-Id: I575f24e6b8f9dd08bd8797343a86ac25b49f19b2
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/180713
Reviewed-by: Heiko Tietze <heiko.tietze@documentfoundation.org>
Tested-by: Jenkins
2025-01-30 09:52:31 +01:00
Sahil Gautam ddeeca35d9 tdf#163620 [API CHANGE] Add UI for libreoffice themes
Instead of Color, we have Light and  Dark in the registry. So each theme extension
will specify  dark and  light color  values for  each "customizable  element" like
DocColor etc. Under appearance we have three radio buttons - light/dark/system. If
system  is selected  then light/dark  colors are  switched based  on the  system's
theme.  if  explicitly light/dark  is  selected  - that  color  is  used from  the
registry.

ColorConfigValue now has three entries  nColor, nLightColor, nDarkColor. nColor is
used as a cache for the color being used at the moment. This is to avoid otherwise
expensive  function calls  + hundreds  of modifications  in the  codebase just  to
change nColor. nColor  is cached either when  the theme is loaded  or when changes
are committed in `ColorConfig_Impl::ImplCommit()`.

Now, if  Automatic theme is selected  then themes is disabled  and the application
uses the system  colors. If some other scheme is  selected like "CustomTheme" etc,
then LibreOffice themes/UI color customization is enabled and the theme colors are
used.

Instead of a scroll window, now we have  a combobox for the registry entries and a
single  color dropdown  to select  the  color value.  This color  dropdown is  for
convinience in case the user wants  to change some specific color that's bothering
him. For themeing, theme extensions should be used.

API CHANGE
+ remove Color in favour of Light and Dark
+ AppBackground has additional two - BackgroundType and Bitmap
+ remove officecfg::Office::Common::Misc::Appearnce in favor of
  officecfg::Office::Common::Appearance::ApplicationAppearance
+ move LibreofficeTheme under officecfg::Office::Common::Appearance

UI
+ it looks like https://i.imgur.com/UMxjfuC.png which is a little
  different from how the [mockup] on the ticket describes it, and that's
  because of lack of time due to upcomming feature freeze.

+ system/light/dark allow the user to switch between light/dark modes
  based on either the system theme (system) or by manually specifying
  light/dark.

+ ui themeing and color customization is disabled when automatic theme
  is selected, and enabled otherwise.

[mockup]: https://bug-attachments.documentfoundation.org/attachment.cgi?id=197469

Change-Id: I1a7f70dfe44b81f863814f87e8d46e146c0e3d5a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/174835
Reviewed-by: Heiko Tietze <heiko.tietze@documentfoundation.org>
Tested-by: Jenkins
Reviewed-by: Sahil Gautam <sahil.gautam.extern@allotropia.de>
2024-12-18 16:24:08 +01:00
Sahil Gautam c4962247e4 tdf#163620 [API CHANGE] remove persona/appearance-toggle related code
- remove ui and source files related to app colors and personalization tabs
- remove persona entries from registry
- remove functions related to persona settings from StyleSettings, vcl..
- remove ui and code related to tools - options - view - appearance combo box

Change-Id: I98f0c38dc1facddd0e8dd03197c61a92287fdbc4
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/176836
Tested-by: Jenkins
Reviewed-by: Sahil Gautam <sahil.gautam.extern@allotropia.de>
2024-12-18 16:23:39 +01:00
Balazs Varga 13ac356a32 tdf#164048 sw a11y: improve error/warning levels with
adding two A11y issue level: Error and warning level, and
categorizing our accesibility issues based on how the
PAC 2024 tools and WCAG behave with the different warnings/errors.

Change-Id: If4e4800497340318bb990326c64de655f24a47e8
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/177389
Tested-by: Gabor Kelemen <gabor.kelemen.extern@allotropia.de>
Tested-by: Jenkins
Reviewed-by: Balazs Varga <balazs.varga.extern@allotropia.de>
2024-11-29 12:08:48 +01:00
Mike Kaganski 56f3dbffdf Simplify a bit
Change-Id: I618b0f8bcb2e8032ee12367c73e1136685f66b3e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/176183
Tested-by: Jenkins
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2024-11-08 05:34:20 +01:00
Stephan Bergmann 9416bafc23 Adapt to generation of .worker.js files gone from 3.1.68
...and just unused dummies since 3.1.58, so don't install them for >= 3.1.58,
even if the dummies would still be available for < 3.1.68

Change-Id: Ida55be2fa3b75982bfd764b7b2676e63c092fe79
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/175822
Reviewed-by: Stephan Bergmann <stephan.bergmann@allotropia.de>
Tested-by: Jenkins
2024-10-30 13:51:40 +01:00
Stephan Bergmann 32ce555c9d Explicitly .delete() one more interface object in uno.js
...accidentally left over from 9184272423
"Explicitly .delete() type and interface objects in uno.js"

Change-Id: I84b1b7b5ee283a1a87f5d3aa894776b1bf23c607
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/172731
Reviewed-by: Stephan Bergmann <stephan.bergmann@allotropia.de>
Tested-by: Jenkins
2024-09-02 10:57:36 +02:00
Stephan Bergmann 9184272423 Explicitly .delete() type and interface objects in uno.js
These objects use smart proxies, so Embind adds them to a JS finalizer (in JS
runtimes where FinalizationRegistry is available), so it shouldn't be necessary
to manually .delete() them, but Embind then emits "Embind found a leaked C++
instance..." warnings about them, which clutter the JS console.

While it is probably impractical for client code to manually .delete() all such
instances, we can at least explicitly .delete() those that occur in uno.js
itself.

Change-Id: Ia21ca5f0bdb246cc5ea272599befd9a16bc970a8
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/172661
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <stephan.bergmann@allotropia.de>
2024-08-31 08:29:23 +02:00
Stephan Bergmann 1732bf1c47 Consistenly terminate statements with semicolons in JS code
Change-Id: Ie52917f6f487f5de2d67179f67f2935a1f6c838a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/172662
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <stephan.bergmann@allotropia.de>
2024-08-30 22:34:29 +02:00
Balazs Varga 3eac847927 tdf#161826 - Add uniform Glow effect for texts in shapes
- Add new text Glow effect properties for shapes

- Using TextGlowPrimitive for rendering uniform text glow in shapes

- Add/allow new UI Glow Effect for texts in shapes on sidebar
  (Only for Impress/Draw and Calc)

- Import/Export ooxml files with Glow effect on texts in shapes
  (Only PPTX/XLSX)

- Import/Export odf files with Glow effect on texts in shapes

- Add unit test for glow text attributes in ODF

- Add uni tests for OOXML import/export

Note: Also this patch effects on
tdf#144061 - Effects: Allow GLOW to apply to Text (as we have for shapes)

Change-Id: I16586c01654f197f532129e4e06aa2ef9f214395
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/172216
Reviewed-by: Balazs Varga <balazs.varga.extern@allotropia.de>
Tested-by: Jenkins
Reviewed-by: Regina Henschel <rb.henschel@t-online.de>
2024-08-29 19:59:24 +02:00
Moritz Duge c888329adf use emrun with explicit "--hostname 127.0.0.1" for testing
Minor security improvement. See
https://github.com/emscripten-core/emscripten/issues/22077

Change-Id: I05d632f6023883672d0e1b2586f53df87dd7d874
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/172540
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <stephan.bergmann@allotropia.de>
Reviewed-by: Moritz Duge <moritz.duge@allotropia.de>
2024-08-29 07:22:31 +02:00
Stephan Bergmann 39de116b73 +WARN is the default with an unset SAL_LOG env var, anyway
Change-Id: Ia8bbc1bdc09705f1ecab783d0d73a417f0ef84e5
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/172378
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <stephan.bergmann@allotropia.de>
2024-08-26 16:30:12 +02:00
Stephan Bergmann a3a71ed916 'use strict' is of no use here...
...in snippets that are included with --pre-js/--post-js

Change-Id: I928aa16b78284314796a0645479dce0dfc7b42cc
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/172383
Reviewed-by: Stephan Bergmann <stephan.bergmann@allotropia.de>
Tested-by: Jenkins
2024-08-26 16:29:28 +02:00
Stephan Bergmann b88b5f53a2 More useful to have an EMSCRIPTEN_EXTRA_SOFFICE_PRE_JS
...than an EMSCRIPTEN_EXTRA_SOFFICE_POST_JS.  That way, we can e.g. set up
Module.arguments there.

Change-Id: I4990ab6daac2f74326ab2ee9508828f1b79bceb7
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/172154
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <stephan.bergmann@allotropia.de>
2024-08-20 23:16:49 +02:00
Stephan Bergmann af6a5ba20f Remove wasm-qt-mandelbrot demo
...that had been added with f90c68316c "WASM: add
Emscripten demo application".  Whatever the original intention, it has probably
served its purpose by now---and now only negatively impacts (re-)build times.

Change-Id: I2bda8d12b91e741c4d0f7d3f02597e0e9505a73a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/172087
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <stephan.bergmann@allotropia.de>
2024-08-20 07:58:01 +02:00
Andrea Gelmini 1565181908 Fix typo
Change-Id: I3277386244f3a00c2756525829924870e3a3d2bb
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/172030
Tested-by: Julien Nabet <serval2412@yahoo.fr>
Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2024-08-19 08:55:14 +02:00
Andrea Gelmini 56c33b87e1 Fix typo
Change-Id: I3fac3dcde5aad559dcbc4c64aeedfd0f6fc1cd6c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/172029
Tested-by: Julien Nabet <serval2412@yahoo.fr>
Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2024-08-19 08:54:22 +02:00
Stephan Bergmann e0178cfdba Emscripten: Document how Qt builds its own freetype, but we link against LO's
Change-Id: I6413c64db3d50f163ee9cc4feda395a54aab3cf2
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/172012
Reviewed-by: Stephan Bergmann <stephan.bergmann@allotropia.de>
Tested-by: Jenkins
2024-08-18 17:43:51 +02:00
Stephan Bergmann e952204b40 Emscripten: Establish a channel between browser and LO main threads
...to be used by external code, to mitigate the issue mentioned in the commit
message of cccc983eb3 "Emscripten: Run external
code on LO's main thread":  "Alternatively, running external code on the
browser's main thread rather than on LO's main thread could be more ideal in the
sense that the external code would then have access to the browser's document
object."

On the browser main thread, external JS code can now await a Module.uno_main
Promise that provides one port of a MessageChannel.  And on the LO main thread,
external JS code has access to the other port of that MessageChannel as
Module.uno_mainPort.  (And the external code is completely free in what
onmessage handlers to set up and what form of postMessage calls to use on those
two MessagePorts.)

Change-Id: Iab6bc7676c744eacb70ddd9f3f80f64e9efd1cf1
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/171907
Reviewed-by: Stephan Bergmann <stephan.bergmann@allotropia.de>
Tested-by: Jenkins
2024-08-15 17:16:27 +02:00
Stephan Bergmann cccc983eb3 Emscripten: Run external code on LO's main thread
...and not the browser's main thread.  Those are different threads now since
6e6451ce96 "Emscripten: Move the Qt event loop off
the JS main thread".  Running `Module.uno_init.then` on the browser's main
thread would never trigger, as that promise is only resolved on LO's main
thread.

When external code was included in soffice.js via
EMSCRIPTEN_EXTRA_SOFFICE_POST_JS, that didn't make a difference:  Emscripten
effectively replicates that code to all the worker threads, so whatever worker
thread resolved the Module.uno_init promise (i.e., the LO main thread) had the
external code available and ran it.  But when external code was included
directly in some HTML file (which "manually" provides a canvas and loads
soffice.js, not relying on the qt_soffice.html convenience functionality), it
was available in the browser's main thread but not in LO's main thread.  For
that use case, introduce a new Module.uno_scripts array that can be set up in
the HTML file to contain an array of URLs (represented as strings) of scripts to
load into LO's main thread.

(Alternatively, running external code on the browser's main thread rather than
on LO's main thread could be more ideal in the sense that the external code
would then have access to the browser's document object.  But, for one, it would
be less ideal in the sense that we would then potentially again execute LO code
(which we call into from the external code via UNO) on the browser's main
thread, which would bring back the issues that
6e6451ce96 "Emscripten: Move the Qt event loop off
the JS main thread" solved.  And, for another, when I experimentally tried it
out, it caused massive Qt threading issues, so I quickly gave up again.)

Change-Id: If01a7859751706f168e93ccac75758ae5ce17cd2
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/171870
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <stephan.bergmann@allotropia.de>
2024-08-14 21:57:00 +02:00
Stephan Bergmann 6e6451ce96 Emscripten: Move the Qt event loop off the JS main thread
...so that spawning and joining new threads works now and we no longer need a
hardcoded -sPTHREAD_POOL_SIZE of pre-spawned threads (see
b84ef4d67e "Adapt comphelper::ThreadPool to
Emscripten's threading needs"; lets keep MAX_CONCURRENCY capped at 4, at least
for now, though).

This requires
<https://github.com/allotropia/qtbase/commit/167b08844df06e3cea85c98161b26e97442ab242>
"Minimal support for Emscripten -sPROXY_TO_PTHREAD=1" and
<https://github.com/allotropia/qtbase/commit/c722a25630a5390f18a4d974aa942f6376fcb8e1>
"Implement QWasmCursor::changeCursor for Emscripten PROXY_TO_PTHREAD case" (see
TODOs there).

Change-Id: I8cea827bd7786e3c9fd9401b4b2bef9d3ec00d5a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/171758
Reviewed-by: Stephan Bergmann <stephan.bergmann@allotropia.de>
Tested-by: Jenkins
2024-08-12 16:31:35 +02:00
Stephan Bergmann 146fafa691 I finally understand why we need that hack
...that 77129fbb74 "Emscripten: Add hack to
prepare for --enable-wasm-exceptions" was puzzled about

Change-Id: Iba54a77e3c2a71fe45b97795ca2da0606c3adf41
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/171594
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <stephan.bergmann@allotropia.de>
2024-08-07 17:18:34 +02:00
Stephan Bergmann f504bd1ac9 Embind: Missing support for UNO polymorphic struct types
Change-Id: I6bb29a951e6e5a3ed7d825172ba7b92ef95a5619
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/171228
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <stephan.bergmann@allotropia.de>
2024-07-30 11:00:49 +02:00
Stephan Bergmann 7d5c62537c Add --with-package-format=emscripten
...to have $(WORKDIR)/installation/LibreOffice/emscripten populated with just
the relevant files from $(INSTDIR).  (This doesn't reuse the complicated
CustomTarget_instsetoo_native/install used for other PKGFORMATs; as a special
case, it uses a much simpler CustomTarget_instsetoo_native/emscripten-install.)

Change-Id: I9c7509aadbc0e6e49ec95bf51c748c2ff9f778b9
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/171066
Reviewed-by: Stephan Bergmann <stephan.bergmann@allotropia.de>
Tested-by: Jenkins
2024-07-26 13:02:11 +02:00
Stephan Bergmann 6148e1a0e0 Looks like Emscripten LO doesn't need explicit --norestore --nologo
...mostly because the relevant parts of the code are hard-disabled (even if you
would --disable-wasm-strip) with ENABLE_WASM_STRIP_RECOVERYUI=TRUE and
ENABLE_WASM_STRIP_SPLASH=TRUE.  (And if there are places in the code that would
need the equivalent of either --norestore or --nologo after all, we could
probably better add explicit #if EMSCRIPTEN there instead.)  This allows to get
rid of hard-coding the Qt Emscripten LO command line arguments, which means that
e.g. web applications embedding LO would now be able to specify them themselves.

Change-Id: I8e2dcfd170cc32276bfb9007f098f6ae6a7f9ec1
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/171063
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <stephan.bergmann@allotropia.de>
2024-07-26 11:22:37 +02:00
Stephan Bergmann ac175a43c9 Add a toDelete parameter to Module.throwUnoException
...as there can be situations (cf. the newly added test code in embindtest.js)
where objects that need to be deleted are passed as payload of the exception
value to be thrown.  So there now is a (mandatory, as Embind doesn't allow to
implicitly pass undefined) third parameter now that must be an array of objects
on which to call .delete().

(75fe059974 "Embind: throwUnoException from JS"
had deliberately made throwUnoException take two arguments, because if it
"directly took a css::uno::Any argument, JS client code would need to create one
with `new Module.uno_Any(...)` and call .delete() on it, but there is no place
where it could call .delete()".  There now would be such a place, but it would
probably still be tedious most of the time to explicitly construct a new uno_Any
to pass into throwUnoException both as the exception and in the toDelete array.
So keep that design decision to have throwUnoException take individual type and
value arguments.)

Change-Id: Idec029d9e500457b02d20d899b9a2328cd7a5d7e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/171024
Reviewed-by: Stephan Bergmann <stephan.bergmann@allotropia.de>
Tested-by: Jenkins
2024-07-25 22:39:23 +02:00