Bug 118335 - Writer's Groupedbar. Print preview called "Close Preview" in drop-down menu File
Summary: Writer's Groupedbar. Print preview called "Close Preview" in drop-down menu File
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: UI (show other bugs)
Version:
(earliest affected)
6.1.0.0.beta2+
Hardware: All All
: medium normal
Assignee: Justin L
URL:
Whiteboard: target:24.2.0
Keywords:
: 124811 128097 139459 142140 (view as bug list)
Depends on:
Blocks: Notebookbar-Groupedbar
  Show dependency treegraph
 
Reported: 2018-06-23 20:22 UTC by Roman Kuznetsov
Modified: 2023-07-04 10:53 UTC (History)
11 users (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 Roman Kuznetsov 2018-06-23 20:22:00 UTC
Description:
Writer's Groupedbar. Wrong name of item Print preview in drop-down menu File. It is "Close preview" in 6.1 beta 2

Steps to Reproduce:
0. Make sure that you activated experimental features
1. Open Writer
2. Select menu View->User interface->Groupedbar
3. Open drop-down menu File and look at item "Close preview"

Actual Results:
Item has wrong name "Close preview"

Expected Results:
Item has correctly name "Print preview"


Reproducible: Always


User Profile Reset: No



Additional Info:
Comment 1 Julien Nabet 2018-06-23 20:57:35 UTC
On pc Debian x86-64 with master sources updated today, I could reproduce this.
Comment 2 andreas_k 2018-06-25 21:31:09 UTC
GenericCommands.xcu


      <node oor:name=".uno:PrintPreview" oor:op="replace">
        <prop oor:name="Label" oor:type="xs:string">
          <value xml:lang="en-US">Print Pr~eview</value>
        </prop>
        <prop oor:name="TooltipLabel" oor:type="xs:string">
          <value xml:lang="en-US">Toggle Print Preview</value>
        </prop>
        <prop oor:name="PopupLabel" oor:type="xs:string">
          <value xml:lang="en-US">Close Preview</value>
        </prop>
        <prop oor:name="Properties" oor:type="xs:int">
          <value>9</value>
        </prop>
      </node>

it look like NB use PopupLabel how can I change the behavior that NB use the default name?
Comment 3 Maxim Monastirsky 2018-06-25 22:16:24 UTC
(In reply to andreas_k from comment #2)
> it look like NB use PopupLabel how can I change the behavior that NB use the
> default name?

You can try this (didn't test, but it should work):

1) Extract the "Close Preview" string to a new command like this:

      <node oor:name=".uno:ClosePrintPreview" oor:op="replace">
        <prop oor:name="Label" oor:type="xs:string">
          <value xml:lang="en-US">Close Preview</value>
        </prop>
        <prop oor:name="TargetURL" oor:type="xs:string">
          <value>.uno:PrintPreview</value>
        </prop>
        <prop oor:name="Properties" oor:type="xs:int">
          <value>1</value>
        </prop>
      </node>

2) Link the menu icon of .uno:ClosePrintPreview to .uno:PrintPreview in various links.txt files.

3) Change the various sw/uiconfig/*/popupmenu/preview.xml to use .uno:ClosePrintPreview instead of .uno:PrintPreview. (and test it to make sure it still works).

4) Remove the PopupLabel of .uno:PrintPreview.
Comment 4 andreas_k 2018-07-13 21:09:20 UTC
I don't know how to fix it, sorry. Should be fixed
Comment 5 Xisco Faulí 2018-07-14 10:59:25 UTC Comment hidden (obsolete)
Comment 6 Xisco Faulí 2018-07-17 19:16:52 UTC
*** Bug 118763 has been marked as a duplicate of this bug. ***
Comment 7 Xisco Faulí 2018-07-17 19:59:45 UTC
(In reply to Maxim Monastirsky from comment #3)
> (In reply to andreas_k from comment #2)
> > it look like NB use PopupLabel how can I change the behavior that NB use the
> > default name?
> 
> You can try this (didn't test, but it should work):
> 
Hi Maxim,
Any chance you could provide a fix for this issue?
Comment 8 Maxim Monastirsky 2019-04-22 10:42:39 UTC
*** Bug 124811 has been marked as a duplicate of this bug. ***
Comment 9 Roman Kuznetsov 2019-10-12 20:52:55 UTC
*** Bug 128097 has been marked as a duplicate of this bug. ***
Comment 10 Dieter 2021-01-22 18:08:23 UTC
*** Bug 139459 has been marked as a duplicate of this bug. ***
Comment 11 Justin L 2023-06-16 22:06:50 UTC
*** Bug 142140 has been marked as a duplicate of this bug. ***
Comment 12 Commit Notification 2023-06-16 23:15:48 UTC
Justin Luth committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/506db23af4da2c5c8775fb0fd6fb9b8668e2fe86

tdf#118335 notebookbar: set visible false for PrintPreview in MenuFile

It will be available in 24.2.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.
Comment 13 Justin L 2023-06-16 23:18:13 UTC
This bug report is not fixed, just mitigated. Leaving it open.
Comment 14 Justin L 2023-06-29 01:09:38 UTC
Strange. Already in 2004 there was .uno:ClosePreview, so not sure why that wasn't recommended for the preview.xml. SC uses that, so do the same for SW.

That seems to be the only place where PopupLabel is desired AFAICS, so after that it should be safe to remove PopupLabel from PrintPreview (except I imagine for customized extensions or stuff saved in LO profiles).
Comment 15 Commit Notification 2023-06-29 21:17:17 UTC
Justin Luth committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/736cf835b9edb7a18fa52a12b03c252a9b63ff7c

tdf#118335 use .uno:ClosePreview instead of PrintPreview

It will be available in 24.2.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.
Comment 16 Commit Notification 2023-06-30 13:21:06 UTC
Justin Luth committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/cc836756d35df4ab8f54a24bd495dd1b8e1c6be9

tdf#118335 remove "Close Preview" PopupLabel from uno:PrintPreview

It will be available in 24.2.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.
Comment 17 Commit Notification 2023-06-30 17:10:34 UTC
Justin Luth committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/3f35fd1a37b22ac0d501ae2aa1d39e12969c7628

Revert "tdf#118335 notebookbar: set visible false for PrintPreview in MenuFile"

It will be available in 24.2.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.