Description: Writer crashes due to the following assertion when changing paragraph directions inside text boxes: > soffice.bin: core/include/svl/poolitem.hxx:709: const T& SfxPoolItem::StaticWhichCast(TypedWhichId<T>) const [with T = SfxBoolItem]: Assertion `nId == m_nWhich' failed. Steps to Reproduce: 1. Open a new Writer document 2. Create a text box (Insert -> Text Box, then drag a box) 3. Type some text 4. Press the Right-to-Left button on the toolbar Actual Results: Writer crashes due to an assertion Expected Results: Writer should not crash Reproducible: Always User Profile Reset: No Additional Info: Version: 26.8.0.0.alpha0+ (X86_64) Build ID: 4f1d95b0cc85e0b05c0b97c90f7d5df2d4272b76 CPU threads: 32; OS: Linux 6.17; UI render: default; VCL: kf5 (cairo+wayland) Locale: en-CA (en_CA.UTF-8); UI: en-US Calc: threaded
This is a regression. I bisected a development build to the following commit: > c0b0a18f5c82ff0ea6ceff1c2e3c1fcab9496681 is the first bad commit > commit c0b0a18f5c82ff0ea6ceff1c2e3c1fcab9496681 > Author: Julien Nabet <serval2412@yahoo.fr> > Date: Mon Apr 27 18:19:08 2026 +0200 > > Related tdf#140226: use StaticWhichCast in ww8graf+drwtxtex (sw) > > Change-Id: I869f707b40f57c91994dc68545a8154ea8c70e10 > Reviewed-on: https://gerrit.libreoffice.org/c/core/+/204472 > Reviewed-by: Julien Nabet <serval2412@yahoo.fr> > Tested-by: Jenkins Could you have a look please, Julien?
Thank you Jonathan for having put me in cc. I'm building from scratch and will try to retrieve a backtrace.
Ok re reading the patch, I think I understand why it fails.
Patch on gerrit here: https://gerrit.libreoffice.org/c/core/+/205476
bt: #4 0x00007f4a81630424 in __assert_fail_base (fmt=<optimized out>, assertion=<optimized out>, file=<optimized out>, line=<optimized out>, function=0x7f49f524a32f "const T &SfxPoolItem::StaticWhichCast(TypedWhichId<T>) const [T = SfxBoolItem]") at ./assert/assert.c:118 #5 0x00007f49f68d4bec in SfxPoolItem::StaticWhichCast<SfxBoolItem> (this=0x55560bdf62a0, nId=...) at include/svl/poolitem.hxx:707 #6 0x00007f49f7369c40 in SwDrawTextShell::Execute (this=0x55560be10ee0, rReq=...) at /home/julien/lo/libreoffice/sw/source/uibase/shells/drwtxtex.cxx:620
Julien Nabet committed a patch related to this issue. It has been pushed to "master": https://git.libreoffice.org/core/commit/100fcb9ca39e6de4cb9b2e86c2deac5069440cd0 tdf#172188: Crash when switching para direction in editeng It will be available in 26.8.0. The patch should be included in the daily builds available at https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: https://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback.
I let you verify and reopen this tracker if you still reproduce this with a build containing the patch.
Looks good! Thanks for fixing this so quickly. Verified with a development build: Version: 26.8.0.0.alpha0+ (X86_64) Build ID: b15e1dcaa8d233717569662834f8c4351edf0e69 CPU threads: 32; OS: Linux 6.17; UI render: default; VCL: kf5 (cairo+wayland) Locale: en-CA (en_CA.UTF-8); UI: en-US Calc: threaded
(In reply to Jonathan Clark from comment #8) > Looks good! Thanks for fixing this so quickly. > ... You're welcome (and sorry for this regression).
(In reply to Julien Nabet from comment #9) > (In reply to Jonathan Clark from comment #8) > > Looks good! Thanks for fixing this so quickly. > > ... > You're welcome (and sorry for this regression). No need to apologize. These things happen.