[haiku-development] Re: RoundRect ButtonFrame

  • From: John Scipione <jscipione@xxxxxxxxx>
  • To: haiku-development@xxxxxxxxxxxxx
  • Date: Sat, 24 Mar 2012 04:25:30 -0400

On Sat, Mar 24, 2012 at 3:02 AM, Stephan Aßmus <superstippi@xxxxxx> wrote:
> Am 24.03.2012 01:36, schrieb John Scipione:
>> Does StrokeRoundRect() stroke a regular rectangle if the stroke radius
>> is<=0? That would make implementing this a bit cleaner.
>
> It should handle that case, just try it and if not, it should be fixed in
> the app_server.

StrokeRoundRect() seems to work with a 0 radius to stroke a regular
rectangle. However, I am seeing a problem where the outside edge of
the default indicator roundrect is now getting drawn correctly. It is
like there are transparent pixels there. Some sort of clipping
problem.

>> Since yesterday I've done a fairly sizable refactoring of the
>> code and consequently put the drawing of the corner edge, frame, and
>> bevel in the button frame method. Since I have access to the
>> background color in the frame method I brought back the harder look
>> again.
>
> Well, there may be a problem with that. The intention was that the "frame"
> only includes the dark border and anything outside of that. While the
> background includes the very slight inner bevel. You can see the problem
> already in your screen shot with the scroll bars. Those look different now
> (missing the bevel). I haven't thought about what the best solution would
> be.

hmmm, I'll have to redraw the bevel in the background method I guess.

Do you know if the additional virtual methods will pose a problem,
will existing apps break expecting an earlier set of vtables?

John Scipione

Other related posts: