[prev in list] [next in list] [prev in thread] [next in thread] 

List:       koffice-devel
Subject:    Re: QPen
From:       Jos van den Oever <Jos.van.den.Oever () kogmbh ! com>
Date:       2010-03-22 14:37:34
Message-ID: 201003221537.34875.Jos.van.den.Oever () kogmbh ! com
[Download RAW message or body]

On Monday 22 March 2010 15:30:19 Korinek Pavol wrote:
> Hello,
> 
> based on my little experiment I can say we can't display any pen style
> except solid when pen width is between (0, 1) . Every style works fine if
> width is >= 1. Can it be feature of Qt ? I made my experiment in
> KWCanvas:: paintBorderSide. I have set pen width to 1.0f in general and
> every style works well than. Can it be some bug or feature of Qt ? I have
> checked Qt API reference and there is no mention about auto changing pen
> style to solid when width is from (0, 1).
> 
> Do you thing that I can create some fix to set width to 1 if is lower ?
> Than we can see all border styles. It can be later removed after fix in
> Qt. Can we escalate it to Qt development ?

Did you try setting the width with QPen::setWidthF in a small test 
application? Calling QPen::setWidth(0.1) is the same as calling 
QPen::setWidth(0) and according to the documentation:

"A line width of zero indicates a cosmetic pen. This means that the pen width 
is always drawn one pixel wide, independent of the transformation set on the 
painter."

Cheers,
Jos

-- 
Jos van den Oever, software architect
+49 391 25 19 15 53
http://kogmbh.com/legal/
_______________________________________________
koffice-devel mailing list
koffice-devel@kde.org
https://mail.kde.org/mailman/listinfo/koffice-devel
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic