Bug 144141 - Remember last used line width (and other settings) for cell borders
Summary: Remember last used line width (and other settings) for cell borders
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
Inherited From OOo
Hardware: All All
: medium enhancement
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
: 152800 (view as bug list)
Depends on:
Blocks: Cell-Border Dialog-Remember-Settings
  Show dependency treegraph
 
Reported: 2021-08-28 09:54 UTC by snowboard975
Modified: 2023-11-22 10:03 UTC (History)
7 users (show)

See Also:
Crash report or crash signature:


Attachments
Video showing how it works with the patch (174.62 KB, video/mp4)
2023-02-22 13:22 UTC, Rafael Lima
Details

Note You need to log in before you can comment on or make changes to this bug.
Description snowboard975 2021-08-28 09:54:20 UTC
Description:
It would be nice if there is a new feature of setting the line width of default border of cells. 
Some suggests to create a style with the desired line width, however, if there is a feature of setting the default line width in Libreoffice Calc, it would be even more convenient.


Steps to Reproduce:
1. Not applicable (suggestion for a new feature)
2.
3.

Actual Results:
Not applicable (suggestion for a new feature)

Expected Results:
Not applicable (suggestion for a new feature)


Reproducible: Always


User Profile Reset: No



Additional Info:
Not applicable (suggestion for a new feature)
Comment 1 m_a_riosv 2021-08-29 12:54:21 UTC
Have you tried to set up it on Default style, and use the file then as default template?
Comment 2 snowboard975 2021-08-31 11:02:14 UTC
If I use style with border lines with a certain linewidth, whether it is default or not, there are border lines on the cells, which I don’t want.

What I want is no border lines by default. Therefore, I don’t want to have the default style with border lines of specific linewidth. 

When I want to draw border lines, I select the border line icon on the toolbar to draw them. And them, whether or not I use style with specific linewidth, the border lines are drawn with the fixed default line width, 0.05 pt. 

Therefore, using a style with a specific line width does not result in the same user experience. That is why I would like to suggest a new feature of specifying the default linewidth of border lines.

(In reply to m.a.riosv from comment #1)
> Have you tried to set up it on Default style, and use the file then as
> default template?
Comment 3 QA Administrators 2021-09-01 04:18:59 UTC Comment hidden (obsolete)
Comment 4 Rafael Lima 2022-10-20 19:05:29 UTC
Just an update. Recent versions of LibreOffice changed the default line width to 0.75pt instead of using the hairline 0.05pt.

However, it's still not possible to set a default width option for borders.

For instance, if you want to apply 0.5pt (non-default value) to several ranges, you'll have to do it manually for each range.
Comment 5 Heiko Tietze 2022-11-03 10:35:45 UTC
There are plenty of ways to configure the cell layout, via direct setting, per cell style, or with templates. I'm not sure what you want to change, the default background grid, the thickness of lines when using the borders toolbar button, the predefined value of borders. What is it exactly?
Comment 6 snowboard975 2022-11-03 11:00:46 UTC
(In reply to Heiko Tietze from comment #5)
> There are plenty of ways to configure the cell layout, via direct setting,
> per cell style, or with templates. I'm not sure what you want to change, the
> default background grid, the thickness of lines when using the borders
> toolbar button, the predefined value of borders. What is it exactly?

I am referring to the default line width when setting border lines of cells via the "Borders" toolbar button or via the menu Format>Cells>Borders tab.
When changing border lines via the aforementioned methods, a certain default line width such as 0.05 pt (v7.0.6.2) or 0.75 pt (v7.3.6.2) applies. My suggestion is to have a feature that can set the default line width in these methods, so that users do not have to change the line width again when setting border lines via the "Borders" toolbar button or via the menu Format>Cells>Borders tab.
Comment 7 QA Administrators 2022-11-04 03:34:25 UTC Comment hidden (obsolete)
Comment 8 Heiko Tietze 2022-11-08 08:59:25 UTC
(In reply to snowboard975 from comment #6)
> I am referring to the default line width when setting border lines of cells
> via the "Borders" toolbar button or via the menu Format>Cells>Borders tab.

Which means we have to add an option for this simple interaction. Have you considered to use cell styles for your workflow?
Comment 9 snowboard975 2022-11-08 09:12:51 UTC
I considered using cell styles and making it default to a template and using the template as suggested in Comment #1 and answered in Comment #2. However, then all the cell borders are drawn with the cell borderline width of the style, which does not result in the same user experience as using the Borders toolbar or Cell Borders menu. With the toolbar or the menu, only selected cell border linewidths can be defined, which is different from defining all cell borders. That is the reason why I suggest this feature.

(In reply to Heiko Tietze from comment #8)
> (In reply to snowboard975 from comment #6)
> > I am referring to the default line width when setting border lines of cells
> > via the "Borders" toolbar button or via the menu Format>Cells>Borders tab.
> 
> Which means we have to add an option for this simple interaction. Have you
> considered to use cell styles for your workflow?
Comment 10 Rafael Lima 2022-11-08 18:55:09 UTC
I also feel this pain, so I would like to suggest a course of action.

First of all, IMO the default width (0.75 pt) is too thick. So every border is initially formatted with 0.75pt and then I have to reapply the borders so that they have 0.5pt width (which I think is the ideal width). My feeling is that my experience is not very good with formatting borders with the current UI, since I always have to apply the borders and then change the line width.

Using styles is not great either, because sometimes I just want to apply a simple border and the toolbar is the quickest way to do that.

So what we could do is:

1) Make LO Calc remember the last used line width; this way, if I apply 0.5pt width with the toolbar, then subsequent formatting will consider 0.5pt as well. This way we do not need any new configuration UI to set the default line width.

2) We could consider changing the default width to 0.5pt (but this is a matter of taste).
Comment 11 m_a_riosv 2022-11-08 22:27:08 UTC
I have just tested 7.5 and Default style doesn't change line width if the style have not also a border with line.
Comment 12 m_a_riosv 2022-11-08 22:33:49 UTC
Comment#11...

For me that could be the bug, with it set up a line width for the file would be easy, changing default style.
Even more, such issue doesn't let to create a default template with your desire line width.
Comment 13 Heiko Tietze 2022-11-09 13:25:22 UTC
(In reply to m.a.riosv from comment #11)
> I have just tested 7.5 and Default style doesn't change line width...

I derive a new cell style from Default, change border width to 0.5pt, color to black, and apply the lines around the shape (make sure you have done this too). Using this CS changes the border line to what I defined - and switching back to Default reverts everything.

(In reply to Rafael Lima from comment #10)
> 1) Make LO Calc remember the last used line width...

I like this proposal.
Comment 14 Cor Nouws 2022-11-17 12:33:45 UTC
(In reply to Rafael Lima from comment #10)

> 1) Make LO Calc remember the last used line width; this way ..
Looks the easiest and less intrusive way to get this done.
Nice idea :)
Comment 15 Heiko Tietze 2022-11-18 14:36:29 UTC
Topic was on the agenda of the design meeting. We pondered over the question whether one setting should rule all controls, for example the cell border in Calc as well the page style, the tables in Writer, or shapes. This was done having in mind the recent change from 0.05pt to 0.75pt. However, the patch itself might not have an impact on all places nor it would be desired in general. So please continue and remember the last used value per control.
Comment 16 Rafael Lima 2023-02-22 13:22:52 UTC
Created attachment 185528 [details]
Video showing how it works with the patch

This proposed patch fixes the issue for the sidebar controls (CellBorderStylePopup and CellLineStylePopup).

https://gerrit.libreoffice.org/c/core/+/147467

The last used border width is remembered independently for each Calc instance.

See video to see how it works with the patch.
Comment 17 m_a_riosv 2023-02-22 21:48:33 UTC
Nice @Rafael.
Comment 18 Stéphane Guillou (stragu) 2023-11-22 10:03:58 UTC
*** Bug 152800 has been marked as a duplicate of this bug. ***