sw/source/core/doc/DocumentStylePoolManager.cxx |   10 ++++++++++
 1 file changed, 10 insertions(+)

New commits:
commit 1dc0c8c8304ebbce0a2e05e89a3b5458d88f3630
Author:     Heiko Tietze <[email protected]>
AuthorDate: Tue Feb 6 16:09:32 2024 +0100
Commit:     Heiko Tietze <[email protected]>
CommitDate: Wed Feb 7 13:45:07 2024 +0100

    Resolves tdf#159531 - Indentation and spacing for comments
    
    Change-Id: I3ce9dd5d399ce9ff1427de0c97a1227dab996d9b
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/163059
    Tested-by: Jenkins
    Reviewed-by: Heiko Tietze <[email protected]>

diff --git a/sw/source/core/doc/DocumentStylePoolManager.cxx 
b/sw/source/core/doc/DocumentStylePoolManager.cxx
index 68d4e5c11855..96392c94b1c9 100644
--- a/sw/source/core/doc/DocumentStylePoolManager.cxx
+++ b/sw/source/core/doc/DocumentStylePoolManager.cxx
@@ -1014,6 +1014,16 @@ SwTextFormatColl* 
DocumentStylePoolManager::GetTextCollFromPool( sal_uInt16 nId,
         case RES_POOLCOLL_COMMENT:       // Comment
             {
                 SetAllScriptItem(aSet, SvxFontHeightItem(PT_10, 100, 
RES_CHRATR_FONTSIZE));
+
+                auto const aIndent(o3tl::convert(0.1, o3tl::Length::cm, 
o3tl::Length::twip));
+                SvxTextLeftMarginItem const leftMargin(aIndent, 
RES_MARGIN_TEXTLEFT);
+                SvxRightMarginItem const rightMargin(aIndent, 
RES_MARGIN_RIGHT);
+                aSet.Put(leftMargin);
+                aSet.Put(rightMargin);
+
+                auto const aSpacing(o3tl::convert(0.1, o3tl::Length::cm, 
o3tl::Length::twip));
+                SvxULSpaceItem topSpacing( aSpacing, 0, RES_UL_SPACE );
+                aSet.Put(topSpacing);
             }
             break;
 

Reply via email to