Bug 154689

Summary: Links in Konsole are not underline properly if they are wrapped
Product: [Applications] konsole Reporter: mutlu inek <mutlu_inek>
Component: generalAssignee: Robert Knight <robertknight>
Status: RESOLVED FIXED    
Severity: normal CC: arvidjaar
Priority: NOR    
Version: unspecified   
Target Milestone: ---   
Platform: Compiled Sources   
OS: Linux   
Latest Commit: Version Fixed In:

Description mutlu inek 2007-12-27 18:55:06 UTC
Version:           1.9.2 (svn r753240) (using KDE Devel)
Installed from:    Compiled sources
Compiler:          gcc 4.2.2 
OS:                Linux

Links in Konsole (e.g. when less'ing a HTML file) are not underline properly if they are spanning more than one line. The link works now (thanks!), but the underlining seems to be reduced to a rather random part of the link.
Comment 1 mutlu inek 2008-07-27 19:13:56 UTC
This is still the case with the final 4.1 (from Arch's testing repo).

More specifically: if a links spans more than one line, only the part in the first line is underlined and clickable. The part is the second line is neither underlined, nor clickable.
Comment 2 Dario Andres 2009-01-03 15:08:14 UTC
*** Bug 179492 has been marked as a duplicate of this bug. ***
Comment 3 Wang Hoi 2009-01-07 03:45:48 UTC
SVN commit 906906 by wkai:

BUG: 154689
use QRegion instead of QRect to represent each HotSpot's valid region 
when a link spans over multiple lines
calculate the unites of QRects as this HotSpot's region
so the link get underlined properly


 M  +1 -2      Filter.cpp  
 M  +73 -18    TerminalDisplay.cpp  
 M  +1 -1      TerminalDisplay.h  


WebSVN link: http://websvn.kde.org/?view=rev&revision=906906
Comment 4 Robert Knight 2009-01-07 10:54:51 UTC
Hi Wang,

Thank-you for fixing this, I think there are several duplicate reports which can now be closed.

The patch is mostly good.  The only comment I have is with regards to style, I prefer to avoid single-letter variable names except for loop counters since in the middle of a non-trivial function, 'r' could stand for any number of regions or rects which are being used at that point.
Comment 5 mutlu inek 2009-01-07 18:50:43 UTC
Awesome! Thank you. You guys rock! :)