[Libreoffice-bugs] [Bug 146076] [META] Find & Replace Regular Expressions

2022-06-01 Thread bugzilla-daemon
https://bugs.documentfoundation.org/show_bug.cgi?id=146076

--- Comment #1 from Adalbert Hanßen  ---
Created attachment 180512
  --> https://bugs.documentfoundation.org/attachment.cgi?id=180512=edit
revisited description with screenshots what goes wrong

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

[Libreoffice-commits] core.git: sw/qa

2022-06-01 Thread Miklos Vajna (via logerrit)
 sw/qa/extras/ooxmlexport/ooxmlexport13.cxx |   37 ++---
 1 file changed, 18 insertions(+), 19 deletions(-)

New commits:
commit de6cd24c4c6de0b05a486b138bf46a1c91f17d50
Author: Miklos Vajna 
AuthorDate: Tue May 31 20:18:59 2022 +0200
Commit: Miklos Vajna 
CommitDate: Wed Jun 1 08:26:33 2022 +0200

CppunitTest_sw_ooxmlexport13: avoid mustTestImportOf()

Can use CPPUNIT_TEST_FIXTURE() instead.

See commit a226cec52e536c46e03f57a5f1f7931abbeb0cdd
(CppunitTest_sw_rtfimport: convert one testcase to use
CPPUNIT_TEST_FIXTURE(), 2019-11-05) for motivation.

Change-Id: Ifd4a73bc9f8272ff3f6abdb8d983f9617eb1a959
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135201
Tested-by: Jenkins
Reviewed-by: Miklos Vajna 

diff --git a/sw/qa/extras/ooxmlexport/ooxmlexport13.cxx 
b/sw/qa/extras/ooxmlexport/ooxmlexport13.cxx
index e3525b5991ab..b97b6c241093 100644
--- a/sw/qa/extras/ooxmlexport/ooxmlexport13.cxx
+++ b/sw/qa/extras/ooxmlexport/ooxmlexport13.cxx
@@ -33,16 +33,6 @@ class Test : public SwModelTestBase
 {
 public:
 Test() : SwModelTestBase("/sw/qa/extras/ooxmlexport/data/", "Office Open 
XML Text") {}
-
-protected:
-/**
- * Denylist handling
- */
-bool mustTestImportOf(const char* filename) const override {
-// If the testcase is stored in some other format, it's pointless to 
test.
-return o3tl::ends_with(filename, ".docx")
-|| filename == std::string_view("ooo39250-1-min.rtf");
-}
 };
 
 // TODO: the re-import doesn't work just yet, but that isn't a regression...
@@ -68,8 +58,9 @@ DECLARE_OOXMLEXPORT_TEST(testTdf126994_lostPageBreak, 
"tdf126994_lostPageBreak.d
 CPPUNIT_ASSERT_EQUAL_MESSAGE( "Number of Pages", 3, getPages() );
 }
 
-DECLARE_OOXMLEXPORT_TEST(testTdf121374_sectionHF, "tdf121374_sectionHF.odt")
+CPPUNIT_TEST_FIXTURE(Test, testTdf121374_sectionHF)
 {
+loadAndReload("tdf121374_sectionHF.odt");
 uno::Reference 
xPageStyle(getStyles("PageStyles")->getByName("Standard"), uno::UNO_QUERY);
 uno::Reference xFooterText = getProperty< 
uno::Reference >(xPageStyle, "FooterText");
 CPPUNIT_ASSERT_EQUAL( OUString("footer"), xFooterText->getString() );
@@ -78,8 +69,9 @@ DECLARE_OOXMLEXPORT_TEST(testTdf121374_sectionHF, 
"tdf121374_sectionHF.odt")
 CPPUNIT_ASSERT_EQUAL_MESSAGE( "Number of Pages", 6, getPages() );
 }
 
-DECLARE_OOXMLEXPORT_TEST(testTdf121374_sectionHF2, "tdf121374_sectionHF2.doc")
+CPPUNIT_TEST_FIXTURE(Test, testTdf121374_sectionHF2)
 {
+loadAndReload("tdf121374_sectionHF2.doc");
 uno::Reference 
xPageStyle(getStyles("PageStyles")->getByName("Standard"), uno::UNO_QUERY);
 uno::Reference xHeaderText = getProperty< 
uno::Reference >(xPageStyle, "HeaderText");
 CPPUNIT_ASSERT( xHeaderText->getString().startsWith("virkamatka-anomus") );
@@ -343,8 +335,9 @@ DECLARE_OOXMLEXPORT_TEST(testBtlrShape, "btlr-textbox.docx")
  rFormats[1]->GetAttrSet().GetFrameDir().GetValue());
 }
 
-DECLARE_OOXMLEXPORT_TEST(testTdf127316_autoEscapement, 
"tdf127316_autoEscapement.odt")
+CPPUNIT_TEST_FIXTURE(Test, testTdf127316_autoEscapement)
 {
+loadAndReload("tdf127316_autoEscapement.odt");
 CPPUNIT_ASSERT_EQUAL(1, getPages());
 // This should be roughly .8*35% of the ORIGINAL(non-reduced) size. 
However, during export the
 // proportional height has to be changed into direct formatting, which 
then changes the relative percent.
@@ -385,8 +378,9 @@ DECLARE_OOXMLEXPORT_TEST(testTdf99602_charStyleSubscript, 
"tdf99602_charStyleSub
 CPPUNIT_ASSERT_EQUAL( sal_Int16(DFLT_ESC_PROP), 
getProperty(getRun(xPara, 2), "CharEscapementHeight") );
 }
 
-DECLARE_OOXMLEXPORT_TEST(testTdf99602_charStyleSubscript2, 
"tdf99602_charStyleSubscript2.odt")
+CPPUNIT_TEST_FIXTURE(Test, testTdf99602_charStyleSubscript2)
 {
+loadAndReload("tdf99602_charStyleSubscript2.odt");
 CPPUNIT_ASSERT_EQUAL(1, getPages());
 // *_In styles_*, don't let the proportionality/escapement affect the 
fontsize - otherwise it starts doubling up,
 // so instead just throw away the values and use the default settings 
instead - meaning fontsize is unaffected.
@@ -496,8 +490,9 @@ DECLARE_OOXMLEXPORT_TEST(testTdf118947_tableStyle2, 
"tdf118947_tableStyle2.docx"
  
static_cast(getProperty(xPara, 
"ParaAdjust")));
 }
 
-DECLARE_OOXMLEXPORT_TEST(tdf123912_protectedForm, 
"tdf123912_protectedForm.odt")
+CPPUNIT_TEST_FIXTURE(Test, tdf123912_protectedForm)
 {
+loadAndReload("tdf123912_protectedForm.odt");
 CPPUNIT_ASSERT_EQUAL(1, getPages());
 SwXTextDocument* pTextDoc = dynamic_cast(mxComponent.get());
 CPPUNIT_ASSERT(pTextDoc);
@@ -553,8 +548,9 @@ CPPUNIT_TEST_FIXTURE(Test, testDateControl)
 CPPUNIT_ASSERT_EQUAL(OUString(""), sCurrentDate);
 }
 
-DECLARE_OOXMLEXPORT_TEST(testTdf121867, "tdf121867.odt")
+CPPUNIT_TEST_FIXTURE(Test, testTdf121867)
 {
+loadAndReload("tdf121867.odt");
 

[Libreoffice-bugs] [Bug 105109] Search and Replace does not find empty paragraphs in textfile with CRLF line endings

2022-06-01 Thread bugzilla-daemon
https://bugs.documentfoundation.org/show_bug.cgi?id=105109

--- Comment #9 from Mike Kaganski  ---
FTR: this normal behavior can be also reproduced on Windows, if you open a CRLF
text file using "Text - Choose Encoding" filter, and choose "LF" as paragraph
break.

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

[Libreoffice-bugs] [Bug 105109] Search and Replace does not find empty paragraphs in textfile with CRLF line endings

2022-06-01 Thread bugzilla-daemon
https://bugs.documentfoundation.org/show_bug.cgi?id=105109

Mike Kaganski  changed:

   What|Removed |Added

 Resolution|WORKSFORME  |NOTABUG

--- Comment #8 from Mike Kaganski  ---
This was not a bug at all. Putting it here just for completeness, to help
archaeology.

(In reply to Buovjaga from comment #1)
> LibreOffice 3.3 actually asks me about the line endings on import and the
> finding works, if I say CR & LF! I wonder, why this feature was removed. It
> is already gone in 3.6.

The default filter for TXT files is now "Text", unlike the previous default
choice of "Text - Choose Encoding" (previously "Text Encoded"). The latter can
be chosen manually when opening from LibreOffice's File Open dialog, to allow
customizing. Compare to the long-standing request tdf#74580 to skip the dialog
when opening CSV.

(In reply to Varga Péter from comment #0)
> ... search for ^$ (empty paragraph)
> 4. It works.
> 5. Close file, change it to have CR/LF line endings, for exaple with the
> unix2dos command line tool.
> 6. Repeat steps 2-3.
> 7. Search phrase not found.

This should *not* work. When you open such a file without explicitly saying
that CRLF is the paragraph boundary, the file is opened using system line
ending convention for paragraph boundaries. Thus, on Linux only LF will be
detected, and CR will become a paragraph contents, thus the paragraphs won't be
empty (they will include one invisible character, which is e.g. possible to
find using \x0D or [:control:] regex; also simple navigating through the
document using right arrow key would show that there is one character - the
cursor will not travel to th next paragraph immediately after it reached the
end of current paragraph, and one more keypress will be needed).

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

[Libreoffice-bugs] [Bug 104428] exploded donut uses too small radius

2022-06-01 Thread bugzilla-daemon
https://bugs.documentfoundation.org/show_bug.cgi?id=104428

--- Comment #9 from Martin Koller  ---
"It's not clear exactly what behavior is being requested here."

I would expect the exploded rings to have a larger radius so that they are
shown concentric to the inner ring to not touch the inner ring.

As it is now, it looks ugly

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

<    1   2   3   4