summary refs log tree commit diff
path: root/src/ui
diff options
context:
space:
mode:
authorAidan Hahn <aidan@aidanis.online>2019-08-28 21:36:28 -0700
committerAidan Hahn <aidan@aidanis.online>2019-08-28 21:36:28 -0700
commitb10d453bd5341587e94702f98b86f307ed2a4c92 (patch)
treec5c863a62bc9fd9ffe61124e064ac65572c22d4b /src/ui
parentrounding options for Avatar class (diff)
downloadnheko-b10d453bd5341587e94702f98b86f307ed2a4c92.tar.xz
add controll bits for avatar rounding
Diffstat (limited to 'src/ui')
-rw-r--r--src/ui/Avatar.cpp3
-rw-r--r--src/ui/Avatar.h2
2 files changed, 3 insertions, 2 deletions
diff --git a/src/ui/Avatar.cpp b/src/ui/Avatar.cpp

index 94e330f6..6a87e002 100644 --- a/src/ui/Avatar.cpp +++ b/src/ui/Avatar.cpp
@@ -104,11 +104,12 @@ Avatar::setIcon(const QIcon &icon) } void -Avatar::rounded(bool setting) +Avatar::setRounded(bool setting) { rounded_ = setting; } +void Avatar::paintEvent(QPaintEvent *) { QPainter painter(this); diff --git a/src/ui/Avatar.h b/src/ui/Avatar.h
index e5e4d873..5732da27 100644 --- a/src/ui/Avatar.h +++ b/src/ui/Avatar.h
@@ -45,5 +45,5 @@ private: QImage image_; QPixmap pixmap_; int size_; - bool rounded_; + bool rounded_ = true; };