Bug 47674 - calc: remember settings in dialogs
Summary: calc: remember settings in dialogs
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
unspecified
Hardware: Other All
: medium enhancement
Assignee: Laurent BP
QA Contact:
URL:
Whiteboard: target:3.7.0
Keywords: easyHack, skillCpp, topicUI
Depends on:
Blocks:
 
Reported: 2012-03-21 11:57 UTC by almos
Modified: 2015-12-16 00:44 UTC (History)
3 users (show)

See Also:


Attachments
Save settings of Import Text from clipboard (13.09 KB, patch)
2012-08-04 20:34 UTC, Laurent BP
Details
Proposed patch (26.99 KB, patch)
2012-08-10 13:31 UTC, Laurent BP
Details

Note You need to log in before you can comment on or make changes to this bug.
Description almos 2012-03-21 11:57:32 UTC
Currently calc always wants tab as separator in the text input dialog, even if there is no tab character in the text on clipboard (I always use ; as separator). This dialog should at least remember what I selected last time.

The chart wizard should also remember the last used type. I never wanted a column chart, so I have to click a lot each time.
Comment 1 Joel Madero 2012-07-02 21:56:41 UTC
Sounds reasonable and with charts I think especially it would help quite a few people. I'm going to mark this as a high enhancement request and as NEW (confirmed). Thanks for the suggestion
Comment 2 Eike Rathke 2012-07-04 11:56:28 UTC
Making this an EasyHack. For the text import that is, please don't mix in other dialogues such as Chart wizard.

For that specific text import dialog it shouldn't be too difficult to implement that for the clipboard variant given that something similar already exists for the file variant that uses the same dialog.

Take a look at sc/source/ui/dbgui/scuiasciiopt.cxx for where the mbFileImport variable is evaluated and load_Separators() and save_Separators() are called, the not-file case then could take a second configuration option into account (keep file and non-file separated!). However, care has to be taken for calls to this dialog that may set a specific separator via cSep argument, check calls to CreateScImportAsciiDlg()

For how to preset configuration with sensible values see
officecfg/registry/schema/org/openoffice/Office/Calc.xcs
section of group CSVImport the Separators property. Another group can be created on the same level and named e.g. "ClipboardTextImport". Add only the "Separators" property.

Btw, really, I don't see any 'high' importance on this bug ...
Comment 3 almos 2012-07-04 15:01:21 UTC
(In reply to comment #2)
> please don't mix in other
> dialogues such as Chart wizard.
I think this behaviour should be implemented either for all dialogs or none of them. Consistency is one of the most important things in a UI.

> Btw, really, I don't see any 'high' importance on this bug ...
It's not high importance, but it can save lots of mundane work. I'm not familiar with the LO codebase, but implementing this sounds easier than finding *really* sensible defaults.
Comment 4 Joel Madero 2012-07-05 10:49:23 UTC
I primarily marked it as high because I thought quite a few people could benefit from it (even if minor) and because I figured it was an easyhack. For relatively easy things that can benefit a large group of people (even if it's just a minor improvement), I feel like a high enhancement can be justified, but feel free to lower the priority.

I don't think I'll be able to handle this one at the moment so if someone else wants to assign themselves to it, I already am working on a few others that are taking more time than anticipated.

Thanks for the comments
Comment 5 Laurent BP 2012-08-04 20:34:48 UTC
Created attachment 65131 [details]
Save settings of Import Text from clipboard

Hello,

Thanks to the detailed steps given by Eike Rathke Comment 2, I propose this first patch. It concerns only the case of Paste unformatted text from clipboard.
Next step will be to save also for Text to column
Third step will be to remove unnecessary parameter cSep.
Comment 6 Joel Madero 2012-08-04 20:47:34 UTC
Can you send the patch out through mailing list or gerritt? We don't really put patches on FDO. Please see:

http://wiki.documentfoundation.org/Development#Preparing_patches

Thanks for managing this bug!
Comment 7 Laurent BP 2012-08-05 12:51:04 UTC
(In reply to comment #6)
> Can you send the patch out through mailing list or gerritt?
Yes, I plan to post it through mailing list, as soon as all 3 steps are carried out.
Comment 8 Laurent BP 2012-08-10 13:31:13 UTC
Created attachment 65388 [details]
Proposed patch

Hello,

A complete patch was proposed to dev list.
It saves settings for both cases: Paste Unformatted Text and Text to Columns. It removes unnecessary parameter cSep in ScImportAsciiDlg constructor.

Laurent BP
Comment 9 Joel Madero 2012-08-13 21:12:27 UTC
Excellent! Once it's pushed will you close the bug? Thanks Laurent for taking care of this one
Comment 10 Joel Madero 2012-08-13 21:13:33 UTC
Did you see almost also mentions column charts in his report? was this solved in your patch?
Comment 11 Eike Rathke 2012-08-14 12:56:33 UTC
(In reply to comment #10)
> Did you see almost also mentions column charts in his report? was this solved
> in your patch?

This is only about the CSV/TextToColumns/Clipboard dialog, see also comment #2.
Comment 12 Not Assigned 2012-08-14 13:43:05 UTC
Laurent Balland-Poirier committed a patch related to this issue.
It has been pushed to "master":

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

fdo#47674 Save settings for Import Ascii Text Dlg
Comment 13 Not Assigned 2012-08-14 13:43:24 UTC
Eike Rathke committed a patch related to this issue.
It has been pushed to "master":

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

changes to "fdo#47674 Save settings for Import Ascii Text Dlg"
Comment 14 Eike Rathke 2012-08-14 13:45:49 UTC
(In reply to comment #8)
> Created attachment 65388 [details] [review]
> Proposed patch

Nice one, thanks :-)

I made a few changes, please see the second commit and my comments therein.
Comment 15 Not Assigned 2012-08-20 14:39:05 UTC
Laurent Balland-Poirier committed a patch related to this issue.
It has been pushed to "master":

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

fdo#47674 Save setting for Import Ascii Text Dlg
Comment 16 Joel Madero 2012-08-20 15:07:09 UTC
Has another bug been started to deal with the chart aspect of this request? If not would someone do it or let me know so I can do it. Thanks. Also thanks for the fast push of this patch, always appreciated :)
Comment 17 Robinson Tryon (qubit) 2015-12-16 00:44:20 UTC
Migrating Whiteboard tags to Keywords: (EasyHack,SkillCpp,TopicUI )
[NinjaEdit]