Bug 119506 - Draw Contextmenu in Writer, Calc, Draw and Impress
Summary: Draw Contextmenu in Writer, Calc, Draw and Impress
Status: VERIFIED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: UI (show other bugs)
Version:
(earliest affected)
unspecified
Hardware: All All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard: target:6.2.0
Keywords:
Depends on:
Blocks: Context-Menu Unify-Across-Apps
  Show dependency treegraph
 
Reported: 2018-08-26 13:32 UTC by andreas_k
Modified: 2020-03-09 00:53 UTC (History)
5 users (show)

See Also:
Crash report or crash signature:


Attachments
Contextmenu Draw for Writer, Calc, Draw and Impress (200.03 KB, image/png)
2018-08-26 13:32 UTC, andreas_k
Details
Contextmenu Draw for Writer, Calc, Draw and Impress v2 (436.92 KB, image/png)
2018-08-26 20:51 UTC, andreas_k
Details
Contextmenu Draw for Writer, Calc, Draw and Impress v3 (544.63 KB, image/png)
2018-08-29 07:58 UTC, andreas_k
Details

Note You need to log in before you can comment on or make changes to this bug.
Description andreas_k 2018-08-26 13:32:28 UTC
Created attachment 144451 [details]
Contextmenu Draw for Writer, Calc, Draw and Impress

Contextual menu when you draw something and use right click in the different LibO apps:

writer
------
- Insert Caption to the bottom like in graphic
- Group submenu is always empty and should not be available (only LeaveGroup command)
- Flip change to Rotate or Flip like in graphic where you have also the rotate shape feature

calc
----
- Layout similar to what graphic contextmenu show (BUG:119412) and what draw contextmenu from writer look like

draw
----
- Add Points cause they are available in writer
- Flip added also the rotate features so it's Rotate or Flip
- Transformations was added cause this features for similar to rotate but more advanced and draw is the "shape" app
- Text Box like in writer

impress
-------
- look like draw + Interaction
Comment 1 Drew Jensen 2018-08-26 14:38:49 UTC
Would add 

Base 
------- 

Embedded Form: 
The context menu is same as a stand alone Writer file and includes 'add caption'item which IMO has no meaning here. 

Report:
The context here has none of the items you would expect for a shape.
Comment 2 Maxim Monastirsky 2018-08-26 15:25:58 UTC
(In reply to andreas_k from comment #0)
> writer
> ------
> - Group submenu is always empty and should not be available (only LeaveGroup
> command)
It isn't empty if you select 2 shapes.

> draw
> ----
> - Text Box like in writer
I'm not against adding this entry in Draw, just want to point out that it won't have the same effect as in Writer. The "Add Text Box" command in Writer is actually about attaching a Writer text frame to the given shape, not about activating the shape built-in text engine like in Draw. It's not the same as if you double click the shape, or press F2. That's why I think we should rename this "Add Text Box" to "Add Text Frame" to avoid further confusion.

Also a general note about Impress/Draw:

Unlike Writer/Calc which have a single "draw" context menu for all kinds of shapes, Impress/Draw have separate context menus for lines, curves, measure lines etc. So whenever we change the context menu structure, it should be reflected in all those popupmenus as well, for consistency. On the other hand, if you could propose a single "draw" menu structure that could work across several kinds of shapes, I'll be happy to look at making the necessary code changes to use such a unified menu. Just let me know.
Comment 3 andreas_k 2018-08-26 15:34:05 UTC
> > draw
> > ----
> > - Text Box like in writer
> I'm not against adding this entry in Draw, just want to point out that it
> won't have the same effect as in Writer. The "Add Text Box" command in
> Writer is actually about attaching a Writer text frame to the given shape,
> not about activating the shape built-in text engine like in Draw. It's not
> the same as if you double click the shape, or press F2. That's why I think
> we should rename this "Add Text Box" to "Add Text Frame" to avoid further
> confusion.

I would keep it there "only" for consistency in addition it's alway nice to see in the UI that you can add text to whatever shape use draw.

> Also a general note about Impress/Draw:
> 
> Unlike Writer/Calc which have a single "draw" context menu for all kinds of
> shapes, Impress/Draw have separate context menus for lines, curves, measure
> lines etc. So whenever we change the context menu structure, it should be
> reflected in all those popupmenus as well, for consistency. On the other
> hand, if you could propose a single "draw" menu structure that could work
> across several kinds of shapes, I'll be happy to look at making the
> necessary code changes to use such a unified menu. Just let me know.

I will investigate to reduce the different .xml popupmenu files for different shapes cause it's way easier in writer and I also think (like you) this complexity (maintanance work) can be reduced.
Comment 4 andreas_k 2018-08-26 20:51:35 UTC
Created attachment 144468 [details]
Contextmenu Draw for Writer, Calc, Draw and Impress v2
Comment 5 Drew Jensen 2018-08-26 20:54:51 UTC
(In reply to andreas_k from comment #4)
> Created attachment 144468 [details]
> Contextmenu Draw for Writer, Calc, Draw and Impress v2

Any chance you could let me know which source XML files you are working with, perhaps I can work on the Base versions.

Thanks
Comment 6 andreas_k 2018-08-27 04:29:48 UTC
> Any chance you could let me know which source XML files you are working
> with, perhaps I can work on the Base versions.

I'm not very familar with base so your help is very welcome. I think the context menu files for the reporter are here.

core/sw/uiconfig/swreport/popupmenu/
Comment 7 Drew Jensen 2018-08-27 17:18:17 UTC
(In reply to andreas_k from comment #6)
> > Any chance you could let me know which source XML files you are working
> > with, perhaps I can work on the Base versions.
> 
> I'm not very familar with base so your help is very welcome. I think the
> context menu files for the reporter are here.
> 
> core/sw/uiconfig/swreport/popupmenu/

I'll see what I can make of that. 

Meantime started an image only mockup of what I thought made sense yesterday. Could attach that here, with some explanation, later today, if you like.  

I have not built LibrOffice in many years but the files are coming down my machine as I type this, so will get off to looking at the files when that is done.

Thanks much.
Comment 8 Roman Kuznetsov 2018-08-27 20:04:02 UTC
For Writer:

Align - doesn't work, cause you cannot select more one shape
Comment 9 andreas_k 2018-08-27 20:08:29 UTC
(In reply to Roman Kuznetsov from comment #8)
> For Writer:
> 
> Align - doesn't work, cause you cannot select more one shape

You can use AlignFrameMenu in the image the wrong align element was shown.
Comment 10 andreas_k 2018-08-27 20:10:22 UTC
And for select more than one graphic I suggest Bug 119526
Comment 11 andreas_k 2018-08-29 07:58:44 UTC
Created attachment 144529 [details]
Contextmenu Draw for Writer, Calc, Draw and Impress v3

Same layout than all the other context menues.

First Points cause this it the action where you can edit shapes. 
Than Position, line and area where you define the layout and where it was located.
Than all the align, arrange, rotate, transforms and convert items (in writer and calc only rotate and flip is available in draw and impress all is available)
Last Description and Style
Comment 12 Martin Srebotnjak 2018-08-29 18:04:45 UTC
I suggest we get rid of “Rotate or Flip…” - it is simply not OK (for the same reason we are not using “Copy, Cut or Paste…” or “Arrange or Align…” as a command with submenu in context menus).
If no other better solution pops up, I suggest to rename this submenu title with "Transform...".
Comment 13 Heiko Tietze 2018-08-29 18:13:04 UTC
Seems to me that this effort is appreciated though details are still in discussion.
Comment 14 andreas_k 2018-08-29 20:36:13 UTC
(In reply to Martin Srebotnjak from comment #12)
> I suggest we get rid of “Rotate or Flip…” - it is simply not OK 

Thanks for the feedback I already have an separate bug report for this toppic BUG 119410
Comment 15 andreas_k 2018-09-07 22:27:05 UTC
(In reply to Martin Srebotnjak from comment #12)
> I suggest we get rid of “Rotate or Flip…” - it is simply not OK (for the
> same reason we are not using “Copy, Cut or Paste…” or “Arrange or Align…” as
> a command with submenu in context menus).
> If no other better solution pops up, I suggest to rename this submenu title
> with "Transform...".

Transformations is still available in draw and impress. Where rotate is also available but not "simple" mirror.

Rotate and Flip is already available in writer for graphic context menu.
Comment 16 Thomas Lendo 2018-09-08 13:07:54 UTC
(In reply to Martin Srebotnjak from comment #12)
> I suggest we get rid of “Rotate or Flip…” - it is simply not OK (for the
> same reason we are not using “Copy, Cut or Paste…” or “Arrange or Align…” as
> a command with submenu in context menus).
> If no other better solution pops up, I suggest to rename this submenu title
> with "Transform...".
As there is a Transformations sub-menu in Draw's draw context menu (see https://colibreoffice.files.wordpress.com/2018/08/contextmenudraw.png?w=1100), Transform is not usable
Comment 17 andreas_k 2018-09-25 10:34:33 UTC
Use Flip as it is now. So no Change from Flip to Rotate or Flip. If the suggestion is to combine it in BUG 119410 I will add an additional patch.
Comment 18 Commit Notification 2018-10-22 12:28:43 UTC
andreas kainz committed a patch related to this issue.
It has been pushed to "master":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=cf8b3a74e8c093dd0ffc7e2f431a26864958f6fb

tdf#119506 Draw Contextmenu in Writer, Calc, Draw, Impress

It will be available in 6.2.0.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 19 Thomas Lendo 2018-10-27 21:03:36 UTC
Thanks, Andreas!
Verified fixed.

Version: 6.2.0.0.alpha1+
Build ID: 5d2ab49cbda1d7aea1019478abe0163e1f40a121
CPU threads: 4; OS: Linux 4.15; UI render: default; VCL: gtk3; 
Locale: de-DE (de_DE.UTF-8); Calc: threaded
from today