Bug 97906 - message "References not found" instead of data sources pane
Summary: message "References not found" instead of data sources pane
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
5.1.0.3 release
Hardware: All All
: medium normal
Assignee: Dennis Francis
QA Contact:
URL:
Whiteboard: target:5.2.0
Keywords: bibisected, bisected, regression
Depends on:
Blocks: Shortcuts-Accelerators
  Show dependency treegraph
 
Reported: 2016-02-16 15:38 UTC by Terrence Enger
Modified: 2016-10-25 19:08 UTC (History)
12 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 Terrence Enger 2016-02-16 15:38:35 UTC
STR
(1) In Calc, type "<F4>".
    Expected : The program should display the data sources pane above
               the grid.
    Observed : Program displays message box: "No references found.".

I see this in, for example, daily dbgutil bibisect repository version
2016-02-16.  However, 50max bibisect repository version latest
correctly displays the data sources pane.  So, regression.
Comment 1 Buovjaga 2016-02-17 12:45:58 UTC
Repro.

Win 7 Pro 64-bit, Version: 5.1.0.3 (x64)
Build ID: 5e3e00a007d9b3b6efb6797a8b8e57b51ab1f737
CPU Threads: 4; OS Version: Windows 6.1; UI Render: default; 
Locale: fi-FI (fi_FI)

Ubuntu 15.10 64-bit 
Version: 5.1.0.3
Build ID: 1:5.1.0~rc3-0ubuntu1~wily0
CPU Threads: 2; OS Version: Linux 4.2; UI Render: default; 
Locale: en-US (en_US.UTF-8)
Comment 2 raal 2016-02-18 08:54:23 UTC
This seems to have begun at the below commit.
Adding Cc: to Andras ; Could you possibly take a look at this one? Thanks

ab9bc705744d6287ef830ed32f6947821ff22a94 is the first bad commit
commit ab9bc705744d6287ef830ed32f6947821ff22a94
Author: Norbert Thiebaud <nthiebaud@gmail.com>
Date:   Sat Oct 17 12:26:23 2015 -0700

    source sha:f8f1a0645106a02a926e96d61f5a55c0e8e41a7b

    source sha:f8f1a0645106a02a926e96d61f5a55c0e8e41a7b

:040000 040000 987e75af14d44b1eb4e33840f4e722026472b6e9 14d9fca2e4fd74d0fbe1933a977624a22d779d1b M      instdir

author	Andras Timar <andras.timar@collabora.com>	2015-10-17 18:13:45 (GMT)
committer	Andras Timar <andras.timar@collabora.com>	2015-10-17 19:13:12 (GMT)
commit	f8f1a0645106a02a926e96d61f5a55c0e8e41a7b (patch)
tree	7b56ab47440dbde94e2b3ea4b019966e0bacc6aa
parent	eb911d69221a5491e75ab0ea47985535a0102aad (diff)
deb system integration postinst and postrm scripts are not needed here

Andras, from description of commit it looks like not relevant ... Let me know if bisecting is correct.
Comment 3 Andras Timar 2016-02-18 15:43:50 UTC
Yes, my commit is not relevant. Beluga reproduced the bug on Windows 7, and my commit was about Debian packaging. 

Are you sure that your bibisect repo is granular enough? Maybe more than one source code commits belong to that bibisect range.
Comment 4 raal 2016-02-18 16:10:14 UTC
(In reply to Andras Timar from comment #3)
> 
> Are you sure that your bibisect repo is granular enough? Maybe more than one
> source code commits belong to that bibisect range.

Yes, using only "max" repos -> one commit = one commit in repo
Comment 5 raal 2016-02-23 13:37:12 UTC
This seems to have begun at the below commit.
Adding Cc: to Dennis Francis; Could you possibly take a look at this one? Thanks

7cd033e028672d92ef7406d8f7c4601c12b9ea67 is the first bad commit
commit 7cd033e028672d92ef7406d8f7c4601c12b9ea67
Author: Norbert Thiebaud <nthiebaud@gmail.com>
Date:   Sat Oct 17 08:25:02 2015 -0700

    source sha:893b07c6cb429c2c9815ad2249a803e668e59499

    source sha:893b07c6cb429c2c9815ad2249a803e668e59499

:040000 040000 f61afd2403ebcb1f9b58f214d3c4a92d2a1c67c9 1d0556d27a034ea33661c908cd1805a44d213e56 M      instdir

author	Dennis Francis <dennisfrancis.in@gmail.com>	2015-10-15 18:29:10 (GMT)
committer	Markus Mohrhard <markus.mohrhard@googlemail.com>	2015-10-17 15:21:12 (GMT)
commit	893b07c6cb429c2c9815ad2249a803e668e59499 (patch)
tree	8c93e070d2a119fff24a818a8b86454af70347fa
parent	5718c72ae89fb1a7aa8ee292dc9cb92acbde92db (diff)
tdf#59418 : Use both F4 and SHIFT+F4 for absolute reference toggle in calc
Comment 6 Dennis Francis 2016-02-23 13:58:04 UTC
Please see : 
https://bugs.documentfoundation.org/show_bug.cgi?id=59418

This change was done to match MSO shortcut F4 for reference toggle with advise from UX team.
Comment 7 raal 2016-02-23 14:06:46 UTC
(In reply to Dennis Francis (ldcs.co.in) from comment #6)
> Please see : 
> https://bugs.documentfoundation.org/show_bug.cgi?id=59418
> 
> This change was done to match MSO shortcut F4 for reference toggle with
> advise from UX team.

But it should not trigger error message.
Observed : Program displays message box: "No references found.".
Comment 8 Andras Timar 2016-02-23 14:09:23 UTC
(In reply to raal from comment #7)
> (In reply to Dennis Francis (ldcs.co.in) from comment #6)
> > Please see : 
> > https://bugs.documentfoundation.org/show_bug.cgi?id=59418
> > 
> > This change was done to match MSO shortcut F4 for reference toggle with
> > advise from UX team.
> 
> But it should not trigger error message.
> Observed : Program displays message box: "No references found.".

Ctrl+Shift+F4 = View Data Sources
F4 = Toggle references (when you don't have references in active cell, you get the message box saying 'No references found.') Enter '=B1' into A1, and press F4 to see how it works.
Comment 9 Dennis Francis 2016-02-23 14:10:20 UTC
I checked in version : (before the commit)
Version: 5.0.5.2
Build ID: 5.0.5.2-1.fc23
Locale: en-US (en_US.utf8)

pressing shift f4 will show the same message.
Comment 10 Andras Timar 2016-02-23 14:20:33 UTC
(In reply to Dennis Francis (ldcs.co.in) from comment #9)
> 
> pressing shift f4 will show the same message.

OK, I give up.
Comment 11 Dennis Francis 2016-02-23 14:37:08 UTC
Sorry I think I overwrote Andras' status change of the bug while replying, should it be set as resolved/not a bug ?
Comment 12 raal 2016-02-23 14:44:37 UTC
(In reply to Dennis Francis (ldcs.co.in) from comment #11)
> Sorry I think I overwrote Andras' status change of the bug while replying,
> should it be set as resolved/not a bug ?

I think should be turned into enhancement to disable confusing message: "No references found."

Tested also in excel, when press F4 then program do nothing...
Comment 13 Terrence Enger 2016-02-23 15:56:03 UTC
Well, the menu option View > "Data Sources" is a way to get to the
Data Sources pane.  I shall miss the lack of commonality of <F4>
between Writer and Calc, but if that is what the UX advise team says,
so be it.

So, my original complaint is resolved, but I am leaving the bug open
because raal (comment 7) thinks that the program should not display
the message (even when it is true).  Raal, over to you.

Thank you, all, for the attention you have given this.
Comment 14 raal 2016-02-23 16:13:13 UTC
UX team - take a decision about  message box: "No references found."
Comment 15 Yousuf Philips (jay) 2016-02-23 18:36:59 UTC
I stumbled on the error a few days back and felt it wasnt clear enough and thought the message should be improved to better explain why it didnt work, as i had the same problem as most in the bug report of not understanding why until i created a formula field and then it worked.

So do i think we should disable the error message? No. I think we shouldnt disable the message as its an error message just like when we press F3 in writer and their is no AutoText around.

@Cor, @Heiko, @Stuart: Whats your take?

As mentioned above, improving the error message language would be good and we could also use it as a means of directing people used to the F4 opening Data Sources to its new shortcut key. So i propose we change the message to something like.

No references found in the selected cells.
Use Ctrl+Shift+F4 to open Data Sources.

It would be useful to backport the new shortcut reference part to 5.1, so other confused users are aware of the shortcut change. @Sophie: Your thoughts?

Would be good if we could name the dialog title to 'Toggle References' or something like that.

@Maxim: Can we extend ScDocShell::ErrorMessage() so that we can not only display text in the dialog but also the dialog title, just like we have in LO Basic
https://help.libreoffice.org/Basic/MsgBox_Statement_Runtime
Comment 16 Cor Nouws 2016-02-23 18:41:40 UTC
(In reply to Yousuf (Jay) Philips from comment #15)
> So do i think we should disable the error message? No. I think we shouldnt
> disable the message as its an error message just like when we press F3 in
> writer and their is no AutoText around.

Indeed. Improve the feed back.
Comment 17 sophie 2016-02-24 09:44:37 UTC
Hi Jay, 
(In reply to Yousuf (Jay) Philips from comment #15)
> I stumbled on the error a few days back and felt it wasnt clear enough and
> thought the message should be improved to better explain why it didnt work,
> as i had the same problem as most in the bug report of not understanding why
> until i created a formula field and then it worked.
> 
> So do i think we should disable the error message? No. I think we shouldnt
> disable the message as its an error message just like when we press F3 in
> writer and their is no AutoText around.
> 
> @Cor, @Heiko, @Stuart: Whats your take?
> 
> As mentioned above, improving the error message language would be good and
> we could also use it as a means of directing people used to the F4 opening
> Data Sources to its new shortcut key. So i propose we change the message to
> something like.
> 
> No references found in the selected cells.
> Use Ctrl+Shift+F4 to open Data Sources.

What sound strange here is indicating two different functions in an error message, but I agree with you that the error message is necessary to respect the new design of the F4 shortcut. 
> 
> It would be useful to backport the new shortcut reference part to 5.1, so
> other confused users are aware of the shortcut change. @Sophie: Your
> thoughts?

Ok for the backport, but I'm really not sure about mentioning the Ctrl+shift+F4 in the error message
> 
> Would be good if we could name the dialog title to 'Toggle References' or
> something like that.

+1
> 
> @Maxim: Can we extend ScDocShell::ErrorMessage() so that we can not only
> display text in the dialog but also the dialog title, just like we have in
> LO Basic
> https://help.libreoffice.org/Basic/MsgBox_Statement_Runtime
- Sophie
Comment 18 Cor Nouws 2016-02-24 11:48:12 UTC
(In reply to sophie from comment #17)

> Ok for the backport, but I'm really not sure about mentioning the
> Ctrl+shift+F4 in the error message

Because it is too long?


@all: mind the option that is mentioned here: https://bugs.documentfoundation.org/show_bug.cgi?id=59418#c22
"Tools > Options > Calc > Interoperability has the choice for Default or OOo legacy key bindings.

Could be an option to set F4 for Data source as legacy and F4 for toggle + Ctrl+F4 for Data source as Default ?"
Comment 19 sophie 2016-02-24 12:44:26 UTC
(In reply to Cor Nouws from comment #18)
> (In reply to sophie from comment #17)
> 
> > Ok for the backport, but I'm really not sure about mentioning the
> > Ctrl+shift+F4 in the error message
> 
> Because it is too long?

No, because it has nothing to do with references which is what the error message is about. I find it confusing to have information that concerns another function in an error message. 
> 
> 
> @all: mind the option that is mentioned here:
> https://bugs.documentfoundation.org/show_bug.cgi?id=59418#c22
> "Tools > Options > Calc > Interoperability has the choice for Default or OOo
> legacy key bindings.
> 
> Could be an option to set F4 for Data source as legacy and F4 for toggle +
> Ctrl+F4 for Data source as Default ?"

You're right, that would solve the frustrating behavior for previous users and maybe also the Mac regression?
Sophie
Comment 20 Yousuf Philips (jay) 2016-02-24 15:10:06 UTC
Hi Sophie,

(In reply to sophie from comment #17)
> > No references found in the selected cells.
> > Use Ctrl+Shift+F4 to open Data Sources.
> 
> What sound strange here is indicating two different functions in an error
> message, but I agree with you that the error message is necessary to respect
> the new design of the F4 shortcut. 

The second part of the error is intended as a temporary notice for users who are transitioning, which would be removed in 5.3. We'd done similar types of fixes to help with the transition from one version to the next - e.g. Modes Tab Bar in the toolbar in Impress.

(In reply to Cor Nouws from comment #18)
> @all: mind the option that is mentioned here:
> https://bugs.documentfoundation.org/show_bug.cgi?id=59418#c22
> "Tools > Options > Calc > Interoperability has the choice for Default or OOo
> legacy key bindings.
> 
> Could be an option to set F4 for Data source as legacy and F4 for toggle +
> Ctrl+F4 for Data source as Default ?"

I was reading through the other bug yesterday and felt that this should be implemented if it isnt already. @Dennis: Can you handle this?

(In reply to sophie from comment #19)
> You're right, that would solve the frustrating behavior for previous users
> and maybe also the Mac regression?

I'm presently speaking with steve to see what we can do to get in a functional Mac shortcut key.
Comment 21 Dennis Francis 2016-02-24 15:22:19 UTC
(In reply to Yousuf (Jay) Philips from comment #20)
> (In reply to Cor Nouws from comment #18)
> > @all: mind the option that is mentioned here:
> > https://bugs.documentfoundation.org/show_bug.cgi?id=59418#c22
> > "Tools > Options > Calc > Interoperability has the choice for Default or OOo
> > legacy key bindings.
> > 
> > Could be an option to set F4 for Data source as legacy and F4 for toggle +
> > Ctrl+F4 for Data source as Default ?"
> 
> I was reading through the other bug yesterday and felt that this should be
> implemented if it isnt already. @Dennis: Can you handle this?

Sure, will try to do this. Assigning to me.
Comment 22 Dennis Francis 2016-02-27 08:41:15 UTC
I have submitted a patch at https://gerrit.libreoffice.org/22728

In Default mode :
    F4            = Toggle reference
    Shift F4      = Toggle reference
    Ctrl+Shift+F4 = Show data sources (should work on a Mac as well)
    
    In Legacy mode :
    F4            = Show data sources
    Shift F4      = Toggle reference

Cor, Yousuf could you please test this patch for functionality especially in Mac ? (I do not have access to a Mac)
Comment 23 Commit Notification 2016-02-27 12:04:09 UTC
Dennis Francis committed a patch related to this issue.
It has been pushed to "master":

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

tdf#97906 : Toggle reference and show data sources shortcuts

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 24 Yousuf Philips (jay) 2016-02-27 16:24:36 UTC
@Dennis: Will test the patch as soon as a new daily build comes out with the patch, as the daily builds are still on the 25th. Will speak with steve to see if it now works on Mac (I dont have a Mac either :D). Saw your patch had assigned 'F4_SHIFT_MOD3' and wondered what key combination that was.
Comment 25 Dennis Francis 2016-02-27 16:36:10 UTC
(In reply to Yousuf (Jay) Philips from comment #24)
> @Dennis: Will test the patch as soon as a new daily build comes out with the
> patch, as the daily builds are still on the 25th. Will speak with steve to
> see if it now works on Mac (I dont have a Mac either :D). Saw your patch had
> assigned 'F4_SHIFT_MOD3' and wondered what key combination that was.

In offapi/com/sun/star/awt/KeyModifier.idl it says :
MOD3 refers in the most cases to the "Ctrl" key (Mac OS X)

So in Mac also we should be able to use CTRL+SHIFT+F4 for data sources in default mode (but not tested in a Mac).
Comment 26 steve -_- 2016-02-27 20:54:39 UTC
Dear all, adjusting component to "Calc" removing ux-advise from cc:

Tested Version: 5.2.0.0.alpha0+
Build ID: 1bcccc175e6f2a884740436642056605ec15b92c
CPU Threads: 4; OS Version: Mac OS X 10.11.3; UI Render: default; 
TinderBox: MacOSX-x86_64@49-TDF, Branch:master, Time: 2016-02-27_13:39:59
Locale: de-DE (de.UTF-8)

1. open LO, open new spreadsheet
2. press ctrl + shift + F4 → nothing
3. press Cmd + shift + F4 → nothing

So can't confirm the fix on OS X so far.
Comment 27 steve -_- 2016-02-27 21:33:27 UTC
UPDATE

ctrl + shift + fn + F4
works as expected to open data sources. (default compatability)
Comment 28 Yousuf Philips (jay) 2016-02-27 22:53:25 UTC
So whats left now is about renaming the error message and deciding whether to temporarily include the new shortcut key for Data Sources in it for 5.1. Any thoughts @Stuart or @Adolfo? (comment 15 for more info)

@Dennis: So steve confirmed to me that fn + cmd (aka mod1) + shift + f4 works in 5.1, so the MOD3 parts of the patch can be removed. Also good to backport the patch into 5.1.

He also confirmed that in OO.o legacy mode, F4 for data sources worked (though you had to restart LO for it to work). I'll still double check it on my end when i get a new build.
Comment 29 Adolfo Jayme 2016-02-27 23:40:35 UTC
(In reply to Yousuf (Jay) Philips from comment #28)
> So whats left now is about renaming the error message and deciding whether
> to temporarily include the new shortcut key for Data Sources in it for 5.1.
> Any thoughts @Stuart or @Adolfo? (comment 15 for more info)

+1 on the wording you proposed, but I agree with Sophie in that the new keyboard shortcut should probably not mentioned in it, because I don’t know if we can guarantee that what is displayed there will match the actual shortcut set in each user’s profile. Unless we have a way to ensure that the message matches reality in all cases, we shouldn’t mention the shortcut in the dialog box’s message, especially if it’s going to be hardcoded in a string.
Comment 30 Yousuf Philips (jay) 2016-02-28 05:00:31 UTC
(In reply to Adolfo Jayme from comment #29)
> +1 on the wording you proposed, but I agree with Sophie in that the new
> keyboard shortcut should probably not mentioned in it, because I don’t know
> if we can guarantee that what is displayed there will match the actual
> shortcut set in each user’s profile. Unless we have a way to ensure that the
> message matches reality in all cases, we shouldn’t mention the shortcut in
> the dialog box’s message, especially if it’s going to be hardcoded in a
> string.

What about stating that Data Sources has a new shortcut key and that it can be seen in the View menu. Something like one of these.

The new Data Sources shortcut can be seen in the View menu.

Check the View menu for the new Data Sources shortcut.

I only worry that without some type of notice regarding the shortcut change, we may get alot of duplicate bug reports once 5.1 becomes LO Still/Stable.
Comment 31 Heiko Tietze 2016-02-28 20:55:18 UTC
Sorry for the lengthy reply. Trying to structure it for the tl;dr;-readers :-)

1. Workflow:

The discussion here results from the fact that a message dialog pops up which is good for errors but not in case of a notifications. And for instance miswriting dt+f3 as dz+f3 (same issue as f4) is such an information.

Some time ago I wrote a guideline for user assistance [1] that discriminates between:
a) user-driven information (tooltips)
b) system-driven notification (e.g. message panels)
c) disruptive messages (error dialog)

This case is clearly a system-driven notification that must not interrupt the workflow. Unfortunately we do not have a control for those situations. So I suggest to introduce a nice speech bubble, message panel, or the like, that is more salient than the status bar but not interruptive.

2. Text:

The message text has to be concise, helpful, supplemental, and static. To inform the user that he or she misspelled a function or unintentionally pressed F4 resp. at the wrong cell is clear from the result. So I would show something like

"No references found in the selected cells.\n
Press F4 to toggle between for instance =F4,=$F$4,=$F4,and =F$4"

(just like Andras sugested in #8)

We should also think about renaming the function into (toggle) "reference mode".

3. Shortcut:

Having a legacy mode sounds not intuitive to me. If users want to configure shortcuts they are free to do so. And I wouldn't waste two shortcuts for one function. Terrence' argument about commonality in #13 is valid. And I'd add concerns about F4 in general because it adds the risk to unintentionally close the program. But when it is known from other apps we have to stick with F4. 
So my suggestion is to use F4 for 'Toggle Reference Mode' and ctrl+shift+f4 to 'Show Data Source' in both Calc and Writer.


[1] https://techbase.kde.org/Projects/Usability/HIG/UserAssistance
Comment 32 Yousuf Philips (jay) 2016-03-01 07:55:16 UTC
(In reply to Heiko Tietze from comment #31)
> "No references found in the selected cells.\n
> Press F4 to toggle between for instance =F4,=$F$4,=$F4,and =F$4"

I've gone with a single line and left out the shortcut line as the shortcut is different on Mac and wont be inaccurate if a user or LO changed the shortcut.

> We should also think about renaming the function into (toggle) "reference
> mode".

Yes it is already in my list of menu changes to rename this to 'Cycle Cell References'.

> Having a legacy mode sounds not intuitive to me. If users want to configure
> shortcuts they are free to do so. And I wouldn't waste two shortcuts for one
> function. Terrence' argument about commonality in #13 is valid. And I'd add
> concerns about F4 in general because it adds the risk to unintentionally
> close the program. But when it is known from other apps we have to stick
> with F4. 

Duplicate shortcut in Shift+F4 has been removed.

> So my suggestion is to use F4 for 'Toggle Reference Mode' and ctrl+shift+f4
> to 'Show Data Source' in both Calc and Writer.

Data Sources shortcut has been unified.

Patch includes these changes as well as changes i asked Dennis to do.

https://gerrit.libreoffice.org/22803
Comment 33 Yousuf Philips (jay) 2016-03-01 08:02:44 UTC
No need to backport these changes to 5.1, so 5.1 users who are used to Shift + F4 for cell references have version for the transition.
Comment 34 Commit Notification 2016-03-05 04:18:42 UTC
Yousuf Philips committed a patch related to this issue.
It has been pushed to "master":

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

tdf#97906 Calc: Correct cell reference shortcut keys

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 35 Commit Notification 2016-03-11 06:18:27 UTC
Yousuf Philips committed a patch related to this issue.
It has been pushed to "master":

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

tdf#97906 Ensure that F4 isnt used in Writer for Data Sources

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.