Skip to content

Commit

Permalink
Merged in mattbrejza/ugfx/btn-ellipse-fix (pull request qmk#26)
Browse files Browse the repository at this point in the history
fixing ellipse button drawing
  • Loading branch information
Joel Bodenmann committed Jul 14, 2016
2 parents 2b279df + 365b7ac commit 5ad6830
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/gwin/gwin_button.c
Original file line number Diff line number Diff line change
Expand Up @@ -238,9 +238,9 @@ static const GColorSet *getButtonColors(GWidgetObject *gw) {
pcol = getButtonColors(gw);

gdispGFillArea(gw->g.display, gw->g.x, gw->g.y, gw->g.width, gw->g.height, gw->pstyle->background);
gdispGFillEllipse(gw->g.display, gw->g.x+1, gw->g.y+1, gw->g.width/2-1, gw->g.height/2-1, pcol->fill);
gdispGFillEllipse(gw->g.display, gw->g.x+gw->g.width/2, gw->g.y+gw->g.height/2, gw->g.width/2-2, gw->g.height/2-2, pcol->fill);
gdispGDrawStringBox(gw->g.display, gw->g.x+1, gw->g.y+1, gw->g.width-2, gw->g.height-2, gw->text, gw->g.font, pcol->text, justifyCenter);
gdispGDrawEllipse(gw->g.display, gw->g.x, gw->g.y, gw->g.width/2, gw->g.height/2, pcol->edge);
gdispGDrawEllipse(gw->g.display, gw->g.x+gw->g.width/2, gw->g.y+gw->g.height/2, gw->g.width/2-1, gw->g.height/2-1, pcol->edge);
}
#endif

Expand Down

0 comments on commit 5ad6830

Please sign in to comment.