View Issue Details

IDProjectCategoryView StatusLast Update
0010033ScribusStory Editor / Text Framespublic2016-01-23 13:18
Reportercezaryece Assigned To 
PrioritynormalSeverityminorReproducibilityalways
Status newResolutionopen 
Product Version1.4.0svn 
Summary0010033: [Patch] DropCap dont comply First Line Offset settings
DescriptionIf in first of frame paragraph DropCap is used then this paragraph doesn’t comply settings of First Line Offset and that can break equality of vertical positions of text lines in text columns (layout error).

Patch fix that behaviour.
Tagsdropcap
PatchYes

Activities

cezaryece

2011-06-08 09:21

updater  

dropcap_FLO.patch (1,554 bytes)   
Index: Version135/Scribus/scribus/pageitem_textframe.cpp
===================================================================
--- Version135/Scribus/scribus/pageitem_textframe.cpp	(wersja 16641)
+++ Version135/Scribus/scribus/pageitem_textframe.cpp	(kopia robocza)
@@ -696,23 +698,29 @@
 	{
 		if (itemsInLine <= 0)
 			return;
-		if ((!hasDropCap) && (startOfCol) && (style.lineSpacingMode() != ParagraphStyle::BaselineGridLineSpacing))
+		if (startOfCol && (style.lineSpacingMode() != ParagraphStyle::BaselineGridLineSpacing))
 		{
-			//FIXME: use glyphs, not chars
-			double firstasce = itemText.charStyle(line.firstItem).font().ascent(itemText.charStyle(line.firstItem).fontSize() / 10.0);
 			double adj (0.0);
 			double currasce (this->getLineAscent(itemText));
-			if( offsetPolicy == FLOPRealGlyphHeight )
+			if( offsetPolicy == FLOPFontAscent )
 			{
-				adj = firstasce - currasce;
-			}
-			else if( offsetPolicy == FLOPFontAscent )
-			{
 				adj = 0.0;
 			}
-			else if( offsetPolicy == FLOPLineSpacing )
+			else
 			{
-				adj = firstasce - style.lineSpacing();
+				//FIXME: use glyphs, not chars
+				double firstasce = itemText.charStyle(line.firstItem).font().ascent(itemText.charStyle(line.firstItem).fontSize() / 10.0);
+				if( offsetPolicy == FLOPRealGlyphHeight )
+				{
+					if (!hasDropCap)
+						adj = firstasce - currasce;
+					else
+						adj = 0.0;
+				}
+				else if( offsetPolicy == FLOPLineSpacing )
+				{
+					adj = firstasce - style.lineSpacing();
+				}
 			}
 			line.ascent = currasce;
 			line.y -= adj;
dropcap_FLO.patch (1,554 bytes)   

Issue History

Date Modified Username Field Change
2011-06-08 09:21 cezaryece New Issue
2011-06-08 09:21 cezaryece File Added: dropcap_FLO.patch
2015-04-29 01:46 Kunda Patch => No
2015-04-29 01:46 Kunda Summary [BUG & FIX] DropCap dont comply First Line Offset settings => [Patch] DropCap dont comply First Line Offset settings
2015-04-29 01:46 Kunda Patch No => Yes
2015-09-17 20:08 Kunda Category Story Editor / Text Frames => Story Ed/Txt Frames
2015-09-17 20:12 Kunda Category Story Ed/Txt Frames => Story Editor / Text Frames
2016-01-23 13:18 Kunda Tag Attached: dropcap