r24383 by jghali - Some more fixes for PdfTextRecognition
scribus-commit
scribus-commit at lists.scribus.net
Thu Jan 7 17:29:24 UTC 2021
Author: jghali
Date: Thu Jan 7 17:29:24 2021
New Revision: 24383
URL: http://scribus.net/websvn/listing.php?repname=Scribus&sc=1&rev=24383
Log:
Some more fixes for PdfTextRecognition
Modified:
trunk/Scribus/scribus/plugins/import/pdf/pdftextrecognition.cpp
Modified: trunk/Scribus/scribus/plugins/import/pdf/pdftextrecognition.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=24383&path=/trunk/Scribus/scribus/plugins/import/pdf/pdftextrecognition.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/import/pdf/pdftextrecognition.cpp (original)
+++ trunk/Scribus/scribus/plugins/import/pdf/pdftextrecognition.cpp Thu Jan 7 17:29:24 2021
@@ -513,6 +513,12 @@
ParagraphStyle pStyle;
pStyle.setLineSpacingMode(pStyle.AutomaticLineSpacing);
pStyle.setHyphenationMode(pStyle.AutomaticHyphenation);
+
+ CharStyle& cStyle = pStyle.charStyle();
+ cStyle.setScaleH(1000.0);
+ cStyle.setScaleV(1000.0);
+ cStyle.setHyphenChar(SpecialChars::BLANK.unicode());
+
Selection tempSelection(nullptr, false);
tempSelection.addItem(textNode);
m_doc->itemSelection_ApplyParagraphStyle(pStyle, &tempSelection);
@@ -549,10 +555,6 @@
QString CurrColorText = getColor(state->getFillColorSpace(), state->getFillColor(), &shade);
applyTextStyleToCharStyle(pStyle.charStyle(), _glyphs[0].style->getFont().family(), CurrColorText, _glyphs[0].style->getFont().pointSizeF());// *_font_scaling);
*/
- CharStyle& cStyle = static_cast<CharStyle&>(pStyle.charStyle());
- cStyle.setScaleH(1000.0);
- cStyle.setScaleV(1000.0);
- cStyle.setHyphenChar(SpecialChars::BLANK.unicode());
textNode->itemText.setDefaultStyle(pStyle);
textNode->invalid = true;
More information about the scribus-commit
mailing list