Bug 92218 - UNO command for Single Toolbar Mode (see comment #13)
Summary: UNO command for Single Toolbar Mode (see comment #13)
Status: VERIFIED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: UI (show other bugs)
Version:
(earliest affected)
5.1.0.0.alpha0+ Master
Hardware: Other All
: medium enhancement
Assignee: Not Assigned
QA Contact:
URL:
Whiteboard: target:5.2.0 target:5.3.0 target:5.2.0.1
Keywords: needsDevEval, topicUI
: 96608 99435 (view as bug list)
Depends on:
Blocks: UNO-Command
  Show dependency treegraph
 
Reported: 2015-06-20 22:57 UTC by Yousuf Philips (jay)
Modified: 2016-09-08 22:47 UTC (History)
10 users (show)

See Also:
Crash report or crash signature:


Attachments
single toolbar (33.57 KB, image/png)
2015-06-20 22:57 UTC, Yousuf Philips (jay)
Details
single toolbar xml (2.52 KB, text/xml)
2015-06-24 16:52 UTC, Yousuf Philips (jay)
Details
single toolbar xml for calc (4.56 KB, text/xml)
2016-03-11 12:26 UTC, Yousuf Philips (jay)
Details
Screenshot with the crash message. (14.12 KB, image/png)
2016-05-10 23:07 UTC, m.a.riosv
Details
Screenshot with the second message. (13.84 KB, image/png)
2016-05-10 23:09 UTC, m.a.riosv
Details
Screenshot (99.45 KB, image/png)
2016-05-19 13:47 UTC, m.a.riosv
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Yousuf Philips (jay) 2015-06-20 22:57:24 UTC
Created attachment 116691 [details]
single toolbar

This was an enhancement that i had previously brought to a design meeting in November 2014 after working on it and posting it in redmine ( https://redmine.documentfoundation.org/boards/1/topics/529 ).

The single toolbar concept can be found in apps like Google Docs and IBM Symphony and it provides a simplified set of highly used toolbar buttons so that the document can take up the majority of the screen and let users focus on creating their documents.

Details of how IBM Symphony achieved this single toolbar mode can be found in this redmine thread ( https://redmine.documentfoundation.org/boards/1/topics/163 ).
Comment 1 tommy27 2015-06-24 04:50:32 UTC
hi Jay,
just to better understand this enhancement request...
do you propose to replace the actual multiple toolbar setup with a single toolbar setup or do you want just to add a new toolbar with all the commands in it (this can already be achieved manually creating a custom toolbar and hiding all the others)

IMHO it would be great to have both things so user can decide which one they prefer.
Comment 2 Yousuf Philips (jay) 2015-06-24 16:52:34 UTC
Created attachment 116810 [details]
single toolbar xml

Hey Tommy,

The current multiple toolbar setup is the default and a user would be able to enable the single toolbar mode, if that is what they prefer. Likely in View > Mode > Single Toolbar Mode.

The custom toolbar xml file used in the screenshot is attached for users who want to play with it. This custom toolbar does handle a user's basic writing needs, but it doesnt handle contextual things like when you select an image and wanting to add a border or selecting a shape and wanting to change its border color, though these things can be formatted using the context menu.

So a decision has to be made to either do the single toolbar mode as a single toolbar that doesnt change or a group of toolbars that fit on a row that can handle context.
Comment 3 Yousuf Philips (jay) 2016-03-01 19:27:58 UTC
So the Writer toolbar is ready and sent as a patch: https://gerrit.libreoffice.org/22818

So that is pending is the creation of an UNO command to do the following.

On Click:
1) Backup to the user profile a list of the module toolbars where the Visible property is true
2) Set all Visible=true toolbars to Visible=false
3) Enable single toolbar mode toolbar (singlemode.xml) by setting its Visible=true
4) Backup the current user profile module 'ToolbarMode' entry in the user profile 
5) Set the user profile module 'ToolbarMode' entry to 'Single'
6) Backup the current icon theme name and size and set it to Breeze small

On Un-Click: (basically the opposite)
1) Restore the backed up user profile module 'ToolbarMode' entry
2) Clear the backed up 'ToolbarMode' entry
3) Hide single toolbar mode toolbar by setting its Visible=false
4) Restore the Visible=true to the backed up toolbars list
5) Clear the backed up toolbar list
6) Restore backed up icon theme name and size

The point of this functionality is so that when a user enables and then disables single toolbar mode, all their previously set toolbars settings wont be reset. The UNO command should be accessible in Writer and Calc as Impress and Draw can easily be set to utilize a single toolbar. This same UNO command functionality is intended for Sidebar Mode (bug 92220), so ideally the code should be written with the intention that it can be used reused/extended. It would be ideal if there was a single UNO command (e.g. .uno:ToolbarMode) which could take an argument for the toolbar mode to be done (e.g. .uno:ToolbarMode?Style:string=Single)
Comment 4 vasya 2016-03-09 07:13:46 UTC
Hi, Yousuf. this work will be continued? because, are working on analogue ribbon https://smehrbrodt.wordpress.com/2015/11/24/improving-the-toolbars-in-libreoffice/
Comment 5 Yousuf Philips (jay) 2016-03-09 08:10:09 UTC
Hi Vasya,

(In reply to vasya from comment #4)
> Hi, Yousuf. this work will be continued? because, are working on analogue
> ribbon
> https://smehrbrodt.wordpress.com/2015/11/24/improving-the-toolbars-in-
> libreoffice/

Notebookbar is another UI mode, but it wont be replacing the current toolbars, but would be an alternative, similar to sidebar mode.
Comment 6 kompilainenn 2016-03-09 14:28:23 UTC
Yousuf, 

1) May be in this mode also hide menu bar? 

2) Add on Single toolbar icons "Normal view"
Comment 7 Yousuf Philips (jay) 2016-03-09 15:29:38 UTC
(In reply to kompilainenn from comment #6)
> 1) May be in this mode also hide menu bar? 

Not a good idea as without the menu bar users wouldnt be able to access the functions that arent available in the single toolbar.

> 2) Add on Single toolbar icons "Normal view"

As its activation would hopefully be in the menu bar as View > Mode > Single Toolbar Mode, its deactivation would likely be in a similar fashion.
Comment 8 Yousuf Philips (jay) 2016-03-11 12:26:54 UTC
Created attachment 123497 [details]
single toolbar xml for calc

For those wanting to test out what a single toolbar would be like on Calc, here it is.
Comment 9 Ljiljan 2016-03-22 07:18:46 UTC
*** Bug 96608 has been marked as a duplicate of this bug. ***
Comment 10 Ljiljan 2016-03-22 07:25:39 UTC
Just additional idea. Is there any way to create drop-down list of all other toolbars (or at least the most important one), which could be selected and displayed over the current single-toolbar in single-toolbar mode? Something I suggested in https://bugs.documentfoundation.org/show_bug.cgi?id=80752 but implementation does not need to include the "line" above single-toolbar with toolbar names, yet simple drop-down list?
Comment 11 Commit Notification 2016-03-27 16:17:32 UTC
Yousuf Philips committed a patch related to this issue.
It has been pushed to "master":

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

tdf#92218 Implement Writer single toolbar mode toolbar

It will be available in 5.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 12 Yousuf Philips (jay) 2016-03-29 15:25:28 UTC
(In reply to Ljiljan from comment #10)
> Just additional idea. Is there any way to create drop-down list of all other
> toolbars (or at least the most important one), which could be selected and
> displayed over the current single-toolbar in single-toolbar mode? Something
> I suggested in https://bugs.documentfoundation.org/show_bug.cgi?id=80752 but
> implementation does not need to include the "line" above single-toolbar with
> toolbar names, yet simple drop-down list?

That is likely something that can be achieved with the notebookbar, so i'd suggest passing your idea onto kendy or samuel along with some mockups of how it would function.
Comment 13 Yousuf Philips (jay) 2016-03-29 16:35:58 UTC
As the suggested functionality in comment 3 is likely to be left for implementation with the notebookbar, the single toolbar mode UNO command should be a toggle/checkbox command that when toggled on enables (i.e. Visible=true)

View > Toolbars > Standard (Single Mode)

and disables (i.e. Visible=false)

View > Toolbars > Standard
View > Toolbars > Formatting
View > Toolbars > Image
View > Toolbars > Drawing Object Properties
View > Toolbars > Frame (Writer)
View > Toolbars > Table (Writer)
View > Toolbars > Bullets and Numbering (Writer)
View > Toolbars > Text Object (Writer)
View > Toolbars > Text Formatting (Calc)

When the single toolbar mode UNO command is toggle off, it does the reverse.
Comment 14 kompilainenn 2016-04-18 07:38:58 UTC
Yousuf, single toolbar in Writer does not fit in 1280 pixel width. It's default resolution of my monitor 19" (1280х1024)
Comment 15 Yousuf Philips (jay) 2016-04-18 20:20:25 UTC
(In reply to kompilainenn from comment #14)
> Yousuf, single toolbar in Writer does not fit in 1280 pixel width. It's
> default resolution of my monitor 19" (1280х1024)

Kompilainenn, it fits if you use small icons, which is how it is intended to fit for users by default, while users with larger screens can use large icons if they choose.

https://wiki.documentfoundation.org/images/9/99/Single_Toolbar_Mode.png
Comment 16 kompilainenn 2016-04-18 20:52:01 UTC
(In reply to Yousuf (Jay) Philips from comment #15)
> (In reply to kompilainenn from comment #14)
> > Yousuf, single toolbar in Writer does not fit in 1280 pixel width. It's
> > default resolution of my monitor 19" (1280х1024)
> 
> Kompilainenn, it fits if you use small icons, which is how it is intended to
> fit for users by default, while users with larger screens can use large
> icons if they choose.
> 
> https://wiki.documentfoundation.org/images/9/99/Single_Toolbar_Mode.png

by default, Windows build uses large icons on Toolbars. 
Maybe envisage verification before activation Single Toolbar? Or show notification to the user..."Your monitor have aspect ratio 5:4. Use mode Single Toolbar with small icons or not use it's!"?
Comment 17 V Stuart Foote 2016-04-18 21:38:16 UTC
(In reply to Yousuf (Jay) Philips from comment #15)
> (In reply to kompilainenn from comment #14)
> > Yousuf, single toolbar in Writer does not fit in 1280 pixel width. It's
> > default resolution of my monitor 19" (1280х1024)
> 
> Kompilainenn, it fits if you use small icons, which is how it is intended to
> fit for users by default, while users with larger screens can use large
> icons if they choose.
> 
> https://wiki.documentfoundation.org/images/9/99/Single_Toolbar_Mode.png

The Standard (Single Mode) toolbar already has the double >> showing a drop menu of the remaining hidden widget buttons. So use on screens narrower than 1280px or when sized narrow the buttons are available.

But can an action of the toggle into the Standard (Single Mode) include adjustment of the Icon size to small? We set Icon Size to Auto by default, can we make use of that?
Comment 18 Yousuf Philips (jay) 2016-04-19 15:56:00 UTC
(In reply to V Stuart Foote from comment #17)
> But can an action of the toggle into the Standard (Single Mode) include
> adjustment of the Icon size to small? We set Icon Size to Auto by default,
> can we make use of that?

Hopefully when a dev looks into creating the uno command mentioned in comment 13, the code can check for the screen resolution and set the icons to small if appropriate.
Comment 19 Ljiljan 2016-04-20 07:06:37 UTC
Regarding default items in toolbar. I don't think that "New" and "Open" should be there. It is not something you use often. You open the document or create a new one and you are working on that document. So most of the time, these two items are useless. On the other hand, clicking on the "File" -> "New" or "Open" does not involve two many steps. 

The missing icon is PDF (dialog with "where to export" appears after clicking, which is different than File -> Export to PDF). That is something LibreOffice user have to use very often when sending files to others since ODT is not standard everywhere yet and it allows us to send document as designed in LibreOffice.

My recommendation is to rearrange font text items as well: Style, Font, Size, Bold/ Italic/ underline and then Alignment. This was standard order in LibreOffice so far as well as in other programs.  

And about this discussion of large vs. small icon size. Large icons provide better visual appearance so I think it should be default size regardless of monitor size/ resolution. The other argument that goes for large icon size is easier clicking. When icons are small, user have to be very precise in order to select the icon. "16px" is two times smaller place than "32px" which means that you have to be very patient with the mouse.
Comment 20 V Stuart Foote 2016-04-21 21:10:45 UTC
*** Bug 99435 has been marked as a duplicate of this bug. ***
Comment 21 Alberto Salvia Novella 2016-04-22 16:00:07 UTC
As I mention in (https://bugs.documentfoundation.org/show_bug.cgi?id=99435), one big drawback of the current tool bars is simply that there are just too many unused buttons used.

Please read that bug for further information.
Comment 22 m.a.riosv 2016-05-10 23:07:19 UTC
Created attachment 124961 [details]
Screenshot with the crash message.

Sometimes moving the toolbar 'Standar (single mode)' from top to left and inverse LibreOffice crash.

Version: 5.2.0.0.alpha1+
Build ID: e76d458422b0f0f713cc17bf47ca94c33ac570a7
CPU Threads: 4; OS Version: Windows 6.19; UI Render: default; 
TinderBox: Win-x86@39, Branch:master, Time: 2016-05-03_06:32:27
Comment 23 m.a.riosv 2016-05-10 23:09:33 UTC
Created attachment 124962 [details]
Screenshot with the second message.

Message after click on [Anular]/[Cancel] to the first message.
Comment 24 m.a.riosv 2016-05-10 23:20:47 UTC
Standar (single mode) not fit stacked to a side, with a 1600x900 screen.
What can be without separators in the toolbar.
Comment 25 Yousuf Philips (jay) 2016-05-19 11:02:18 UTC
(In reply to m.a.riosv from comment #22)
> Created attachment 124961 [details]
> Screenshot with the crash message.
> 
> Sometimes moving the toolbar 'Standar (single mode)' from top to left and
> inverse LibreOffice crash.

Would suggest you submit that as a new bug, so it can be looked into as i dont assume it is directly related to this enhancement.

(In reply to m.a.riosv from comment #24)
> Standar (single mode) not fit stacked to a side, with a 1600x900 screen.
> What can be without separators in the toolbar.

It wasnt intended to fit vertically, especially as the comboboxes (style name, font name, font size) dont function in vertical view.
Comment 26 m.a.riosv 2016-05-19 13:47:16 UTC
Created attachment 125170 [details]
Screenshot

(In reply to Yousuf (Jay) Philips from comment #25)
> (In reply to m.a.riosv from comment #22)
..
> Would suggest you submit that as a new bug, so it can be looked into as i
> dont assume it is directly related to this enhancement.
> 
I'll do it.

> (In reply to m.a.riosv from comment #24)
> > Standar (single mode) not fit stacked to a side, with a 1600x900 screen.
> > What can be without separators in the toolbar.
> 
> It wasnt intended to fit vertically, especially as the comboboxes (style
> name, font name, font size) dont function in vertical view.

I know comboxes when in vertical only show the icon.

With the actual screens usually wider than high, horizontal tool bars are only an space waste (IMO), while there is a lot of unused space on both sides, but only my opinion.
Comment 27 Commit Notification 2016-05-31 13:17:20 UTC
Yousuf Philips committed a patch related to this issue.
It has been pushed to "master":

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

tdf#92218 Implement Calc single toolbar mode toolbar

It will be available in 5.3.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 28 Commit Notification 2016-06-02 10:49:14 UTC
Yousuf Philips committed a patch related to this issue.
It has been pushed to "libreoffice-5-2":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=66a3295a0b87617e912eacb4e1bec390385fee38&h=libreoffice-5-2

tdf#92218 Implement Calc single toolbar mode toolbar

It will be available in 5.2.0.1.

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 29 Commit Notification 2016-06-12 10:22:33 UTC
Yousuf Philips committed a patch related to this issue.
It has been pushed to "master":

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

tdf#92218 tweaks to single toolbar mode toolbars

It will be available in 5.3.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 30 Commit Notification 2016-06-12 19:33:17 UTC
Yousuf Philips committed a patch related to this issue.
It has been pushed to "libreoffice-5-2":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=a10af9dbf2f6ed600f857b2fec9dae8362f9545e&h=libreoffice-5-2

tdf#92218 tweaks to single toolbar mode toolbars

It will be available in 5.2.0.1.

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 31 Commit Notification 2016-08-15 05:43:01 UTC
Yousuf Philips committed a patch related to this issue.
It has been pushed to "master":

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

tdf#92218 Another round of tweaks to single toolbar mode

It will be available in 5.3.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 32 Yousuf Philips (jay) 2016-08-23 15:04:33 UTC
Easy activation of single toolbar mode has been done in bug 101249.
Comment 33 steve -_- 2016-08-23 15:20:34 UTC
verified. takes a few seconds after the selection to actually switch the toolbars which is a bit confusing but works.
Comment 34 Commit Notification 2016-09-08 22:47:13 UTC
Yousuf Philips committed a patch related to this issue.
It has been pushed to "master":

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

tdf#92218 Implement Impress single toolbar mode toolbar

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