Bug 138607 - Inserting Cross-Reference to Heading Number also inserts separator text with no option to customize it
Summary: Inserting Cross-Reference to Heading Number also inserts separator text with ...
Status: RESOLVED DUPLICATE of bug 138606
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
6.4.6.2 release
Hardware: All All
: medium enhancement
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-12-01 20:14 UTC by William Friedman
Modified: 2020-12-01 22:04 UTC (History)
1 user (show)

See Also:
Crash report or crash signature:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description William Friedman 2020-12-01 20:14:24 UTC
Description:
The Chapter Numbering feature allows customizing the numbering by adding text before and after the numbering, in the separator section. That is excellent functionality.

However, inserting a cross-reference to a Heading -- whether by number, number (no context), and number (full context) -- includes the full separator text without any option for customization. This breaks my use case, which is to configure the separator text to prefix the chapter number before the heading number (e.g., 3.X.Y.Z) and to suffix a period to serve as a separator (thus: 3.X.Y.Z.). However, when I want to cross-reference the header number, I *don't* want the *suffixed* separator text (the period) to appear, while I *do* want the *prefixed* separator text (3.) to appear. So, e.g., let's say I have the following headings (remember that 3. and the final period are separator text):

3.1. Text1
3.2. Text2
3.3. Text3

I want to be able to write something like "In section 3.1 I will discuss ... in section 3.2 I will discuss ..." where 3.1 and 3.2 are the cross-reference field to the appropriate heading with the prefixed text (3.) but not the suffixed period. Right now it looks like this: "In section 3.1. I will discuss ... in section 3.2. I will discuss" which is untenable.

I suppose this is an enhancement request; I certainly would not want to lose the separator text entirely, since I do want the prefixed text. The best solution would be to allow customization in the cross-reference dialog box, e.g., add a section "include separator text?" with checkboxes for "before" and "after". The second best solution (to my mind, although others might prefer this) would be to give the ability to add separator text to cross-references, so that only the actual number of the heading would be inserted (according to the option selected), without any separator text whatsoever.

Steps to Reproduce:
1. Open a new document.
2. Select Tools | Chapter Numbering.
3. In the number field, select "1, 2, 3, ..."
4. In the separator box, add some before text and after text. In my case, the before text is "3." and the after text is ".".
5. Click OK.
6. Select the correct style (by default, Heading 1). Type some text.
7. On a new line, in a non-heading style, go to Insert | Cross-Reference | Cross-References | Type: Headings | Insert reference to: Number. Click Insert.

Actual Results:
The cross-reference with before and after separator text is inserted as the field.

Expected Results:
There should be an option to customize how the cross-reference will be inserted and whether it should also insert the before and/or after separator text.


Reproducible: Always


User Profile Reset: No



Additional Info:
Version: 6.4.6.2 (x64)
Build ID: 0ce51a4fd21bff07a5c061082cc82c5ed232f115
CPU threads: 4; OS: Windows 6.1 Service Pack 1 Build 7601; UI render: default; VCL: win; 
Locale: en-US (en_US); UI-Language: en-US
Calc: CL
Comment 1 m_a_riosv 2020-12-01 22:04:54 UTC

*** This bug has been marked as a duplicate of bug 138606 ***