Bug 167487 - UI: Draw: Navigator redaction shapes not translated
Summary: UI: Draw: Navigator redaction shapes not translated
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Draw (show other bugs)
Version:
(earliest affected)
25.8.0.0 alpha0+
Hardware: All All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords: difficultyMedium, easyHack, skillCpp
Depends on:
Blocks: Not-Localizable
  Show dependency treegraph
 
Reported: 2025-07-13 07:49 UTC by lol
Modified: 2026-03-23 07:44 UTC (History)
5 users (show)

See Also:
Crash report or crash signature:


Attachments
Draw navigator redaction shapes not translated (56.40 KB, image/png)
2025-07-13 07:49 UTC, lol
Details

Note You need to log in before you can comment on or make changes to this bug.
Description lol 2025-07-13 07:49:19 UTC
Created attachment 201780 [details]
Draw navigator redaction shapes not translated

Steps to Reproduce:
1. Open a document in Writer
2. Type same text in the document and insert a image
3. Open Tools - Auto-Redact
4. Set a text target and a all image target 
5. click OK
6. Open the navigator in Draw via F5
7. The entries redaction shapes are not translated

See also attached image.

Version: 25.8.0.0.beta1 (X86_64) / LibreOffice Community
Build ID: 1b25e37a63c5a6f16bdcb365ed3da80ac419e6e4
CPU threads: 16; OS: Windows 11 X86_64 (build 22631); UI render: Skia/Vulkan; VCL: win
Locale: de-DE (de_DE); UI: de-DE
Calc: CL threaded
Comment 1 Buovjaga 2026-03-18 19:06:53 UTC
It seems to me that the code depends on the names: https://git.libreoffice.org/core/+/a9e9175ba6be99bebd82228e78cd77f33b1515ea/sfx2/source/doc/objserv.cxx#950

I suppose they could be made translation-aware. Maybe this could be an easy hack.
Comment 2 Heiko Tietze 2026-03-19 08:39:12 UTC
Sure, do not show internal IDs in the UI. Not sure about the easy hack. This rectangle is a UNO command...? Maybe Jim knows.
Comment 3 Jim Raykowski 2026-03-22 07:04:24 UTC
Here are some hints on one way to go about making the redaction shape names translatable:

Locations "ImageRedactionShape", "RectangleRedactionShape", and "FreeformRedactionsShape" are referenced:

 officecfg/registry/data/org/openoffice/Office/UI/GenericCommands.xcu
 sd/uiconfig/sdraw/menubar/menubar.xml
 sd/uiconfig/sdraw/toolbar/redactionbar.xml
 sfx2/source/doc/SfxRedactionHelper.cxx
 sfx2/source/doc/objserv.cxx

Places to add code to set the redaction shape name to a defined name:

 sd/source/ui/unoidl/unopage.cxx SdDrawPage::add
 sd/source/ui/func/fuconrec.cxx FuConstructRectangle::SetAttributes
 sd/source/ui/func/fuconbez.cxx FuConstructBezierPolygon::SetAttributes

Translation strings can be define in:

 include/sfx2/strings.hrc

Currently all redacted objects of a type receive the same type name, i.e. ImageRedactionShape types are named "ImageRedactionShape", RectangleRedactionShape types are named "RectangleRedactionShape" and FreeformRedactionShape types are named "FreeformRedactionShape". This is a problem for the Navigator which requires unique names to be able to correctly navigate to objects. Possibly we want to include making redaction object names unique in this patch?