mirror of
				https://github.com/kovidgoyal/calibre.git
				synced 2025-11-04 03:27:00 -05:00 
			
		
		
		
	Fixing stroke-dasharray rendering bug (#1821923)
This commit is contained in:
		
							parent
							
								
									9a676b0e06
								
							
						
					
					
						commit
						c22c03b76a
					
				@ -430,9 +430,12 @@ class Graphics(object):
 | 
				
			|||||||
        pdf.current_page.write('%d j '%join)
 | 
					        pdf.current_page.write('%d j '%join)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        # Dash pattern
 | 
					        # Dash pattern
 | 
				
			||||||
 | 
					        if pen.style() == Qt.CustomDashLine:
 | 
				
			||||||
 | 
					            pdf.serialize(Array(pen.dashPattern()))
 | 
				
			||||||
 | 
					            pdf.current_page.write(' %d d ' % pen.dashOffset())
 | 
				
			||||||
 | 
					        else:
 | 
				
			||||||
            ps = {Qt.DashLine:[3], Qt.DotLine:[1,2], Qt.DashDotLine:[3,2,1,2],
 | 
					            ps = {Qt.DashLine:[3], Qt.DotLine:[1,2], Qt.DashDotLine:[3,2,1,2],
 | 
				
			||||||
                  Qt.DashDotDotLine:[3, 2, 1, 2, 1, 2]}.get(pen.style(), [])
 | 
					                  Qt.DashDotDotLine:[3, 2, 1, 2, 1, 2]}.get(pen.style(), [])
 | 
				
			||||||
        if ps:
 | 
					 | 
				
			||||||
            pdf.serialize(Array(ps))
 | 
					            pdf.serialize(Array(ps))
 | 
				
			||||||
            pdf.current_page.write(' 0 d ')
 | 
					            pdf.current_page.write(' 0 d ')
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user