[Libreoffice-bugs] [Bug 151889] CLEAR FORMATTING: Give option to clear every formatting in a single step

2022-11-18 Thread bugzilla-daemon
https://bugs.documentfoundation.org/show_bug.cgi?id=151889

--- Comment #17 from Orwel  ---
(In reply to Rafael Lima from comment #16)
> Hi Orwell, can you please test if this macro does what you need?
> 

Hi Rafael, it works perfect. May be give a thought to the label of the macro as
it clears the whole paragraph formatting although you mark only a part of text
in the paragraph. The behavior is as I intended, but some people not familiar
with our discussion could be confused by the name. What about:
ClearAllFormatsInParagraph or
ClearEverythingInParagraph

instead of simple ClearEverything.

But it is only a thought, it  is on you.

-- 
You are receiving this mail because:
You are the assignee for the bug.

[Libreoffice-bugs] [Bug 151889] CLEAR FORMATTING: Give option to clear every formatting in a single step

2022-11-16 Thread bugzilla-daemon
https://bugs.documentfoundation.org/show_bug.cgi?id=151889

Heiko Tietze  changed:

   What|Removed |Added

 CC|libreoffice-ux-advise@lists |heiko.tietze@documentfounda
   |.freedesktop.org|tion.org
   Keywords|needsUXEval |

-- 
You are receiving this mail because:
You are the assignee for the bug.

[Libreoffice-bugs] [Bug 151889] CLEAR FORMATTING: Give option to clear every formatting in a single step

2022-11-16 Thread bugzilla-daemon
https://bugs.documentfoundation.org/show_bug.cgi?id=151889

--- Comment #16 from Rafael Lima  ---
Hi Orwell, can you please test if this macro does what you need?

Sub ClearEverything
' Get the current selection
Dim oSel as Object
oSel = ThisComponent.CurrentSelection

' Dispatch helper to use the CDF command
Dim oProvider as Object
Dim oDispHelper as Object
oProvider = ThisComponent.CurrentController.Frame
oDispHelper = CreateUnoService("com.sun.star.frame.DispatchHelper")

' First of all apply the CDF command to the entire selection
oDispHelper.executeDispatch(oProvider, ".uno:ResetAttributes", "", ,
Array())

' Traverse all text ranges
Dim rangeCount as Integer, i as Integer
Dim oEnum as object, oElement as Object
rangeCount = oSel.getCount()
For i = 0 To rangeCount - 1
' Traverse all text elements
oTextRange = oSel.getByIndex(i)
oEnum = oTextRange.createEnumeration()
Do While oEnum.hasMoreElements()
oElement = oEnum.nextElement()
With oElement
' Clear paragraph style
.ParaStyleName = "Default Paragraph Style"
' Cleat character style
.CharFontStyleName = ""
.CharFontStyleNameAsian = ""
.CharFontStyleNameComplex = ""
.CharStyleName = "No Character Style"
' Clear list format
.ListId = ""
.NumberingIsNumber = False
.NumberingStyleName = ""
End With
Loop
Next i
End Sub

-- 
You are receiving this mail because:
You are the assignee for the bug.

[Libreoffice-bugs] [Bug 151889] CLEAR FORMATTING: Give option to clear every formatting in a single step

2022-11-16 Thread bugzilla-daemon
https://bugs.documentfoundation.org/show_bug.cgi?id=151889

Rafael Lima  changed:

   What|Removed |Added

 Blocks||145878

--- Comment #15 from Rafael Lima  ---
Let's associate this with bug 145878 (DoAsExtension).

Maybe someone might be interested in implementing this extension. The steps
described by the OP shouldn't be too difficult to implement as a macro and then
converted into an extension.


Referenced Bugs:

https://bugs.documentfoundation.org/show_bug.cgi?id=145878
[Bug 145878] [META] Enhancements that could be realized per extension
-- 
You are receiving this mail because:
You are the assignee for the bug.

[Libreoffice-bugs] [Bug 151889] CLEAR FORMATTING: Give option to clear every formatting in a single step

2022-11-15 Thread bugzilla-daemon
https://bugs.documentfoundation.org/show_bug.cgi?id=151889

--- Comment #14 from Heiko Tietze  ---
(In reply to Orwel from comment #13)
>> You could pack this macro into an extension and share it on our site.
> Sorry, I am not familiar with this procedure. But it is simple:

https://wiki.documentfoundation.org/Development/Create_a_Hello_World_LibreOffice_extension

-- 
You are receiving this mail because:
You are the assignee for the bug.

[Libreoffice-bugs] [Bug 151889] CLEAR FORMATTING: Give option to clear every formatting in a single step

2022-11-15 Thread bugzilla-daemon
https://bugs.documentfoundation.org/show_bug.cgi?id=151889

--- Comment #13 from Orwel  ---
(In reply to Heiko Tietze from comment #12)

> You could pack this macro into an extension and share it on our site.

Sorry, I am not familiar with this procedure. But it is simple:
1. Highlight some text
2. F3 (menu/View/Styles)
3. Tools/Macros/Record macro
4. On Paragraph styles (in F3 window): Default paragraph style,
5. On Character styles (in F3 window): No character style,
6. On List styles (in F3 window): No list,
7. Stop recording macro, save it and set some shortcut.

-- 
You are receiving this mail because:
You are the assignee for the bug.

[Libreoffice-bugs] [Bug 151889] CLEAR FORMATTING: Give option to clear every formatting in a single step

2022-11-15 Thread bugzilla-daemon
https://bugs.documentfoundation.org/show_bug.cgi?id=151889

--- Comment #12 from Heiko Tietze  ---
(In reply to Orwel from comment #11)
> But for people who are not familiar
> with macro recording a possibility in Format menu list of such format change
> would be much more easier.

You could pack this macro into an extension and share it on our site.

-- 
You are receiving this mail because:
You are the assignee for the bug.

[Libreoffice-bugs] [Bug 151889] CLEAR FORMATTING: Give option to clear every formatting in a single step

2022-11-15 Thread bugzilla-daemon
https://bugs.documentfoundation.org/show_bug.cgi?id=151889

--- Comment #11 from Orwel  ---
I would like to amend, that what I was looking for is possible to create with a
Record Macro (with F3/Default Paragraph style, No character Style, No list) and
assigning a shortcut to it. But for people who are not familiar with macro
recording a possibility in Format menu list of such format change would be much
more easier.

-- 
You are receiving this mail because:
You are the assignee for the bug.

[Libreoffice-bugs] [Bug 151889] CLEAR FORMATTING: Give option to clear every formatting in a single step

2022-11-15 Thread bugzilla-daemon
https://bugs.documentfoundation.org/show_bug.cgi?id=151889

--- Comment #10 from Orwel  ---
(In reply to Heiko Tietze from comment #9)
> It makes not much sense to remove all styles.

I do not agree with this summary. I work with lot of .doc and .docx documents,
which other people using MS Word of different versions are correct/annotate.
Although LibreOffice improved in last few years in compatibility, I am often
confronted with some compatibility issues. If the whole document was prepared
by me in LO and some changes are made by people using MS Word I often got
broken paragraphs, numbering...

For this reason a "Clear every format change" (paragraph, character,
numbering...) to get a raw default setting on a specific line/marked text like
it is at the start on a blank document (this means with default values from
template) would bring a lot of time savings, as I would not be forced to look
for the specific change MS Word/LO incompatibility made, because I know, how
should the formatting be like, but the compatibility issues prevent sometimes
the changes made simply by changing paragraph style, numbering, 

-- 
You are receiving this mail because:
You are the assignee for the bug.

[Libreoffice-bugs] [Bug 151889] CLEAR FORMATTING: Give option to clear every formatting in a single step

2022-11-14 Thread bugzilla-daemon
https://bugs.documentfoundation.org/show_bug.cgi?id=151889

Heiko Tietze  changed:

   What|Removed |Added

 CC||mikekagan...@hotmail.com
 Status|UNCONFIRMED |RESOLVED
 Resolution|--- |WONTFIX

--- Comment #9 from Heiko Tietze  ---
Ctrl+M clears direct formatting on the character level (font color, size etc.)
and the paragraph level (manual indention, alignment etc.). It does not reset
any other style like character, page, list or table style.

The shortcut ctrl+0 applies the PS "Text Body" to the current selection. And
the two functions should not get mixed. 

It makes not much sense to remove all styles. And CDF works as expected. What I
could imagine but it's likely not helping you is to have a modifier key (like
shift+ctrl+M) to not only remove DF but also CS.

I disagree with the CC'ed  bug 78371. Splitting CDF into CDCF and CDPF makes
only sense when the format is badly applied.

-- 
You are receiving this mail because:
You are the assignee for the bug.

[Libreoffice-bugs] [Bug 151889] CLEAR FORMATTING: Give option to clear every formatting in a single step

2022-11-10 Thread bugzilla-daemon
https://bugs.documentfoundation.org/show_bug.cgi?id=151889

--- Comment #8 from Orwel  ---
(In reply to Dieter from comment #7)
> O.K., let's ask design-team. I've changes bug summary and hope you agree.
Perfect, thank you Dieter, also for the change in summary.

> CTRL+0 changes text to "Text Body". So not clear to me, if you're talking
> about text body or default paragraph style
I had probably made a change in shortcuts... I have on CTRL+0:
Menu/View/Toolbars/Customize/Keyboard: 
-Category: Styles/Paragraph
-Function: Default paragraph style.

-- 
You are receiving this mail because:
You are the assignee for the bug.

[Libreoffice-bugs] [Bug 151889] CLEAR FORMATTING: Give option to clear every formatting in a single step

2022-11-10 Thread bugzilla-daemon
https://bugs.documentfoundation.org/show_bug.cgi?id=151889

Dieter  changed:

   What|Removed |Added

Summary|Clear direct formatting |CLEAR FORMATTING: Give
   |does not change paragraph   |option to clear every
   |style to default|formatting in a single step
   See Also||https://bugs.documentfounda
   ||tion.org/show_bug.cgi?id=78
   ||371
 CC||libreoffice-ux-advise@lists
   ||.freedesktop.org
 Blocks||107318
   Keywords||needsUXEval

--- Comment #7 from Dieter  ---
(In reply to Orwel from comment #5)
> Hi,
> exactly, shortcut would do it also.
O.K., let's ask design-team. I've changes bug summary and hope you agree.

> I know there is the shortcut CTRL+0
> which set the paragraph style to default.
CTRL+0 changes text to "Text Body". So not clear to me, if you're talking about
text body or default paragraph style


Referenced Bugs:

https://bugs.documentfoundation.org/show_bug.cgi?id=107318
[Bug 107318] [META] Clear formatting and clear direct formatting issues
-- 
You are receiving this mail because:
You are the assignee for the bug.